Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MatSnackbar politeness overruled by role="alert" #13493

Closed
bsteffl opened this issue Oct 8, 2018 · 1 comment · Fixed by #13864
Closed

MatSnackbar politeness overruled by role="alert" #13493

bsteffl opened this issue Oct 8, 2018 · 1 comment · Fixed by #13864
Assignees
Labels
Accessibility This issue is related to accessibility (a11y) P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent

Comments

@bsteffl
Copy link

bsteffl commented Oct 8, 2018

Bug, feature request, or proposal:

Bug

What is the expected behavior?

Setting the politeness is overruled by role="alert". Role="alert" has inherent value of aria-live="assertive" and therefore interrupts user flow and is read immediately.

What is the current behavior?

Current behavior is that any toast message is deemed as assertive because of role="alert".

What are the steps to reproduce?

Providing a StackBlitz reproduction is the best way to share your issue.

StackBlitz starter: https://goo.gl/wwnhMV

https://stackblitz.com/edit/angular-nyilhm

image

What is the use-case or motivation for changing an existing behavior?

To allow proper announcement of chosen assertiveness. https://www.w3.org/WAI/PF/aria/roles#alert See "Alerts are assertive live regions"

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

Angular 6.1.0, Material 6.4.2

Is there anything else we should know?

@jelbourn jelbourn added P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent Accessibility This issue is related to accessibility (a11y) labels Oct 10, 2018
@crisbeto crisbeto self-assigned this Oct 29, 2018
crisbeto added a commit to crisbeto/material2 that referenced this issue Oct 29, 2018
Currently we always have a `role` of `alert` on the snack bar container which has an implicit politeness of `assertive` and which can override the message announced by the live announcer. These changes set the role to `status` if it's set to `polite` or remove the role completely if the politeness is turned off.

Fixes angular#13493.
jelbourn pushed a commit that referenced this issue Nov 3, 2018
…13864)

Currently we always have a `role` of `alert` on the snack bar container which has an implicit politeness of `assertive` and which can override the message announced by the live announcer. These changes set the role to `status` if it's set to `polite` or remove the role completely if the politeness is turned off.

Fixes #13493.
atscott pushed a commit to atscott/components that referenced this issue Nov 5, 2018
…ngular#13864)

Currently we always have a `role` of `alert` on the snack bar container which has an implicit politeness of `assertive` and which can override the message announced by the live announcer. These changes set the role to `status` if it's set to `polite` or remove the role completely if the politeness is turned off.

Fixes angular#13493.
jelbourn pushed a commit that referenced this issue Nov 6, 2018
…13864)

Currently we always have a `role` of `alert` on the snack bar container which has an implicit politeness of `assertive` and which can override the message announced by the live announcer. These changes set the role to `status` if it's set to `polite` or remove the role completely if the politeness is turned off.

Fixes #13493.
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Accessibility This issue is related to accessibility (a11y) P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants