Opened 3 months ago

Closed 3 months ago

#36511 closed Cleanup/optimization (fixed)

Optimize accessibility of filters in django admin

Reported by: laurenherregodts Owned by: Antoliny
Component: contrib.admin Version: 5.2
Severity: Normal Keywords: accessibility, filtering
Cc: Antoliny 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 Thibaud Colas)

When using keyboard tabs to navigate a page in the django admin interface, the filter panel is only accessed as last part of the page. This means users will have to tab through entire tables. The issue was identified using AXE tab stops during accessibility testing.

I believe there are no changes to the styles needed, just move the template so the DOM order is more correct and filter panel is accessed earlier.

Change History (9)

comment:1 by Thibaud Colas, 3 months ago

Description: modified (diff)
Summary: Optimize accessibility of filters in django admin consoleOptimize accessibility of filters in django admin
Triage Stage: UnreviewedAccepted

Thank you @laurenherregodts, makes sense based on our testing.

Sample page: django static demo releases changelist. On this page, here are the numbers of tab stops as-is, with 4 items in the changelist, each with three fields

  • Worst case: 78
  • Skipping the sidebar: 43
  • Using "skip to main content": 41

The target would be for the number of tab stops to be the same regardless of the content of the table. Ideally:

  • 3 or 5 tab stops. Placing the filters after the "Add" button in object-tools, or after the search bar
  • Or worst case after the toplinks (number of tab stops dependent on number of top links)

comment:2 by Antoliny, 3 months ago

Cc: Antoliny added

comment:3 by Antoliny, 3 months ago

Thank you for submitting the ticket!
It seems like a great improvement! As Thibaud Colas mentioned, placing the filter after the object-tools would make it accessible before the table.

comment:4 by Antoliny, 3 months ago

Owner: set to Antoliny
Status: newassigned

comment:5 by Antoliny, 3 months ago

Has patch: set

comment:6 by Sarah Boyce, 3 months ago

Needs tests: set

comment:7 by Antoliny, 3 months ago

Needs tests: unset

comment:8 by Sarah Boyce, 3 months ago

Triage Stage: AcceptedReady for checkin

comment:9 by Sarah Boyce <42296566+sarahboyce@…>, 3 months ago

Resolution: fixed
Status: assignedclosed

In 6ea33190:

Fixed #36511 -- Ensured filters came before table in keyboard navigation in admin changelist.

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