Opened 10 years ago

Closed 9 years ago

#3698 closed (fixed)

Smarter newforms labling

Reported by: Chris Beaven Owned by: Adrian Holovaty
Component: Forms Version: master
Severity: Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

I have been using some labels on my newforms fields. Some end with punctuation, which makes the added ":" look a bit silly after it (when using the lazy form rendering methods like as_p())

The patch makes it so the label is not appended with a colon if the field label ends in punctuation.

Attachments (2)

newforms_labling.patch (916 bytes) - added by Chris Beaven 10 years ago.
newforms_labling.2.patch (2.7 KB) - added by Chris Beaven 10 years ago.
with tests

Download all attachments as: .zip

Change History (6)

Changed 10 years ago by Chris Beaven

Attachment: newforms_labling.patch added

comment:1 Changed 10 years ago by Chris Beaven

Needs documentation: unset
Needs tests: unset
Patch needs improvement: unset
Triage Stage: UnreviewedDesign decision needed

comment:2 Changed 10 years ago by Adrian Holovaty

Triage Stage: Design decision neededAccepted

Good idea. Write up some unit tests, and we'll put it in.

Changed 10 years ago by Chris Beaven

Attachment: newforms_labling.2.patch added

with tests

comment:3 Changed 10 years ago by Chris Beaven

Triage Stage: AcceptedReady for checkin

comment:4 Changed 9 years ago by Russell Keith-Magee

Resolution: fixed
Status: newclosed

(In [5112]) Fixed #3698 -- Modified newforms labels to only add a colon if the label text doesn't end with punctuation. Thanks, SmileyChris.

Note: See TracTickets for help on using tickets.
Back to Top