Skip to content

[Question] Question for the specification of an alert role #2401

Open
@ungjinPark

Description

Describe your concern

Hello, I am visually impaired and work in accessibility research, testing, and quality assurance for websites and applications in South Korea.

I have a question regarding the specification of role="alert".

Initially, I understood that live regions can only notify changes to their child nodes. This understanding is also reflected in the MDN (Mozilla Developer Network) documentation. According to the documentation, it states:

As with all other live regions, alerts will only be announced when the content of the element with role="alert" is updated. Make sure that the element with the role is present in the page's markup first - this will "prime" the browser and screen reader to keep watching the element for changes. After this, any changes to the content will be announced. Do not try to dynamically add/generate an element with role="alert" that is already populated with the alert message you want announced - this generally does not lead to an announcement, as it is not a content change.

However, I’ve observed that when hidden alerts (via CSS) are made visible or when new alert elements are dynamically added to the DOM, various screen readers such as iOS VoiceOver, Android TalkBack, and NVDA announce them.

What is the correct specification in this case?

Link to the version of the specification or documentation you were looking at at.

Link to documentation: https://www.w3.org/TR/wai-aria-1.3#alert

Does the issue exists in the editors draft (the editors draft is the most recent draft of the specification)?

Sorry, I don't know

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions