#35386 closed Bug (fixed)
Incorrect checkbox help text alignment in multi-field rows
Reported by: | Adam Johnson | Owned by: | Adam Johnson |
---|---|---|---|
Component: | contrib.admin | Version: | 4.2 |
Severity: | Normal | Keywords: | |
Cc: | Tom Carrick | Triage Stage: | Ready for checkin |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | yes |
Description (last modified by )
For a single checkbox, styles align the help under the checkbox:
When the checkbox appears with any other field in the same line, this is undone:
Example admin:
from django.contrib import admin from example.models import Switcher class SwitcherAdmin(admin.ModelAdmin): fieldsets = [ ( None, { "fields": [ ("up", "down"), ], }, ), ] admin.site.register(Switcher, SwitcherAdmin)
(It doesn’t matter if the other field is a checkbox or not.)
Changing fieldset.html
so checkbox-row
is applied unconditionally to checkbox-containing field boxes fixes this regression, plus #34994:
Attachments (4)
Change History (18)
by , 7 months ago
Attachment: | Xnapper-2024-04-16-10.31.32.png added |
---|
comment:1 by , 7 months ago
Description: | modified (diff) |
---|---|
Has patch: | set |
Owner: | changed from | to
Status: | new → assigned |
comment:2 by , 7 months ago
I ran a bisect and confirmed this was a regression in 96a598356a9ea8c2c05b22cadc12e256a3b295fd, before which checkboxes would be densely packed:
comment:3 by , 7 months ago
Cc: | added |
---|---|
Triage Stage: | Unreviewed → Accepted |
UI/UX: | set |
Thank you Adam, great catch!
comment:4 by , 7 months ago
Version: | dev → 4.2 |
---|
comment:5 by , 7 months ago
Triage Stage: | Accepted → Ready for checkin |
---|
comment:6 by , 7 months ago
Triage Stage: | Ready for checkin → Accepted |
---|
(need to confirm if this needs backporting, if so I think this will need a release note for 4.2 and 5.0)
comment:7 by , 7 months ago
Triage Stage: | Accepted → Ready for checkin |
---|
follow-up: 14 comment:13 by , 2 months ago
I noticed this was reverted in the stable branches? Was there some technical issue with the fix, or was this a policy issue (i.e. it should not have been backported to those releases per policy)?
comment:14 by , 2 months ago
Replying to Richard Laager:
I noticed this was reverted in the stable branches? Was there some technical issue with the fix, or was this a policy issue (i.e. it should not have been backported to those releases per policy)?
That's right Richard, this should not have been backported per policy. Details of that conversation are in these comments.
single-correct