#10043 closed (fixed)
widthratio tag does not accept a variable as the max_width argument
Reported by: | Oliver Beattie | Owned by: | nobody |
---|---|---|---|
Component: | Template system | Version: | 1.0 |
Severity: | Keywords: | widthratio | |
Cc: | Triage Stage: | Ready for checkin | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
When using the widthratio
template tag, it isn't possible to use a template variable as the max_width
argument. This would have been useful for me recently, and I can't see a reason why this functionality shouldn't exist. I've attached a patch which adds the feature.
Attachments (3)
Change History (8)
by , 16 years ago
Attachment: | widthratio-variable.diff added |
---|
comment:1 by , 16 years ago
milestone: | → 1.1 |
---|---|
Triage Stage: | Unreviewed → Accepted |
by , 16 years ago
Attachment: | 10043-with-tests.diff added |
---|
by , 16 years ago
Attachment: | 10043-with-tests.2.diff added |
---|
comment:2 by , 16 years ago
Triage Stage: | Accepted → Ready for checkin |
---|
comment:3 by , 16 years ago
Note that I changed widthratio10 from a test to a working implementation. It is now possible to pass a float to the max_width argument instead of it failing on floats.
I talked to Jacob and Brian about this and they said it made sense.
comment:4 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
Patch to the
widthratio
template tag to allow variables to be passed for themax_width
argument