Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#17138 closed Cleanup/optimization (fixed)

Admin sets the "summary" attribute on table, which is obsolete

Reported by: Aymeric Augustin Owned by: teraom
Component: contrib.admin Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

The admin templates were recently converted to HTML5. Since then, the W3C validator raises the following error on the admin index:

The summary attribute is obsolete. Consider describing the structure of the table in a caption element or in a figure element containing the table; or, simplify the structure of the table so that no description is needed.

Attachments (1)

html5-remove-summary-17138.diff (861 bytes ) - added by teraom 13 years ago.

Download all attachments as: .zip

Change History (12)

comment:1 by Julien Phalip, 13 years ago

Triage Stage: UnreviewedAccepted

comment:2 by teraom, 13 years ago

Owner: changed from nobody to teraom
Status: newassigned

by teraom, 13 years ago

comment:3 by teraom, 13 years ago

Has patch: set

comment:4 by Jannis Leidel, 13 years ago

Triage Stage: AcceptedReady for checkin

comment:5 by Claude Paroz, 13 years ago

I'm not sure this is ready. Summary attribute was not displayed by default in browsers, while caption tag is. I'm not sure we suddenly want to display the summary content.

comment:6 by Julien Phalip, 13 years ago

I agree with claudep. That would look weird.

comment:7 by Ramiro Morales, 13 years ago

Triage Stage: Ready for checkinAccepted

Yes, the problem reported might be real but the proposed solution isn't semantically right for our use case. Moving back to accepted.

Last edited 13 years ago by Ramiro Morales (previous) (diff)

comment:8 by Samuel Sutch <sam@…>, 13 years ago

Created a pull request for this: https://github.com/django/django/pull/104

It moves the contents of the summary attribute into the title attribute of the a tag. This may be more useful than before because the summary tag was usually completely thrown away by most browsers. In this case, in most browsers, hovering over the text in the table caption will show the desired "summary"

comment:9 by Julien Phalip <jphalip@…>, 13 years ago

Resolution: fixed
Status: assignedclosed

In [f29234167ad0193f35360023c65212c39cf87d1b]:

Merge pull request #104 from samuraisam/17138-html5-remove-summary

Fixed #17138 -- Removed the 'summary' attribute from the admin index tables to be html5-valid.

comment:10 by Julien Phalip <jphalip@…>, 13 years ago

In [f699641161a4ec8b6cbee938fd3a4379e7889ff2]:

Fixed #17138 -- Made the sensitive_variables decorator work with object methods.

comment:11 by Julien Phalip, 13 years ago

Sorry, I've referenced the wrong ticket in the commit message above. It should have been #18379.

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