﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
34622	RelatedFieldWidgetWrapper links don’t convey their state for screen reader users	Thibaud Colas	Coen van der Kamp	"Fields using `RelatedFieldWidgetWrapper` have three links/buttons next to them to go to the Change/Add/View views for their model. Those links use a bit of JS to toggle whether the link is active or not based on whether the field has a value.

This link state (disabled/enabled) isn’t communicated to screen reader users in any way. We should be able to solve this by adding a `aria-disabled=""true""` attribute on those links when they are disabled (making sure to remove the attribute when the links are enabled).

- Template: https://github.com/django/django/blob/main/django/contrib/admin/templates/admin/widgets/related_widget_wrapper.html
- And I believe the ""link enabled/disabled"" logic happens here: https://github.com/django/django/blob/main/django/contrib/admin/static/admin/js/admin/RelatedObjectLookups.js


_In addition_ this is unrelated but it’d be much nicer for screen reader users if the images within those links had `alt=""""`. Right now the presence of `alt` means screen reader users will hear ""link, image, Change"" – the fact there’s an image is completely irrelevant here. It’d be much better to instead have `link, Change selected <thing>` (coming from the title attribute)."	Bug	closed	contrib.admin	4.2	Normal	fixed	accessibility, screen reader		Ready for checkin	1	0	0	0	0	1
