#36394: Accessibility improvements for anchor tags in the admin page.
-------------------------------------+-------------------------------------
Reporter: Antoliny | Type:
| Cleanup/optimization
Status: new | Component:
| contrib.admin
Version: 5.1 | Severity: Normal
Keywords: accessibility | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
In a recent task where I added underlines to links in the main content
area of the admin page([
https://code.djangoproject.com/ticket/34917
ticket34917]), We added `role="button"` to elements where the underline
shouldn't be visually displayed.
However, this approach is not ideal from an accessibility perspective.
When a screen reader accesses an element with `role="button"`, it is read
as a "button." However, since it is fundamentally an anchor tag, this may
lead screen reader users to experience unexpected behavior.
Additionally, although it is announced as a "button," it does not support
spacebar interaction because it remains as anchor tag at its core.
It seems we need to find an alternative way to remove the underline
without adding `role="button"`, while keeping the current underline
styling intact elsewhere.
--
Ticket URL: <
https://code.djangoproject.com/ticket/36394>
Django <
https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.