Make WordPress Core

Opened 4 years ago

Last modified 18 months ago

#47111 new defect (bug)

Dynamically added notifications need ARIA role alert or status

Reported by: afercia's profile afercia Owned by:
Milestone: Future Release Priority: normal
Severity: normal Version:
Component: Administration Keywords: needs-patch
Focuses: ui, accessibility Cc:

Description

Follow up to #46995.

In the various admin screens, all the notifications / warnings and the like that are rendered "on the fly" and injected in the DOM need either an ARIA role alert or status to be properly perceived by assistive technologies and users using these technologies.

This doesn't apply to the standard "admin notices" that are normally rendered on page load. It only applies to JavaScript-rendered notices that appear at some point in a page. There are a few of them across the admin that would greatly benefit from a standardized component.

References:
https://www.w3.org/TR/wai-aria-1.1/#alert
https://www.w3.org/TR/wai-aria-1.1/#status

Quoting from the Aria Authoring Practices (emphasis mine):

Dynamically rendered alerts are automatically announced by most screen readers, and in some operating systems, they may trigger an alert sound. It is important to note that, at this time, screen readers do not inform users of alerts that are present on the page before page load completes.

W3C role=alert example:
https://www.w3.org/TR/wai-aria-practices/examples/alert/alert.html

Change History (3)

#1 @afercia
4 years ago

Related, as a good example of dynamically added notifications: #47147.

#2 @afercia
4 years ago

Related: #47147.

#3 @NomNom99
18 months ago

  • Keywords needs-patch added
Note: See TracTickets for help on using tickets.