Skip to content

fix: set role on tooltip description element #20953

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

Merged
merged 2 commits into from
Nov 17, 2020

Conversation

crisbeto
Copy link
Member

@crisbeto crisbeto commented Nov 2, 2020

Includes two separate commits that:

  1. Add support for setting a role through the AriaDescriber.
  2. Uses the new option to set a tooltip role on the tooltip's description elements.

Fixes #20593.

Allows for an optional `role` to be assigned to the description element.
This is required for some cases like tooltips (see angular#20593).
Sets the `tooltip` role on the tooltip's description element so it conveys more
information to assistive technology.

Fixes angular#20593.
@crisbeto crisbeto 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) target: minor This PR is targeted for the next minor release labels Nov 2, 2020
@google-cla google-cla bot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Nov 2, 2020
@crisbeto crisbeto added merge: preserve commits When the PR is merged, a rebase and merge should be performed and removed cla: yes PR author has agreed to Google's Contributor License Agreement labels Nov 2, 2020
@google-cla google-cla bot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Nov 2, 2020
@google-cla

This comment has been minimized.

@jelbourn
Copy link
Member

jelbourn commented Nov 6, 2020

Did you see if this substantively changes the behavior of the tooltip in a scree-reader?

@crisbeto
Copy link
Member Author

crisbeto commented Nov 6, 2020

I didn't really notice a change in NVDA, but all of the examples of accessible tooltips that I've been looking at had a role on the description element so I figured that there has to be a reason behind it. I decided to do it since it isn't a lot of maintenance on our part.

Copy link
Member

@jelbourn jelbourn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jelbourn jelbourn added the action: merge The PR is ready for merge by the caretaker label Nov 9, 2020
@wagnermaciel wagnermaciel merged commit eda397c into angular:master Nov 17, 2020
@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 Dec 18, 2020
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) action: merge The PR is ready for merge by the caretaker cla: yes PR author has agreed to Google's Contributor License Agreement merge: preserve commits When the PR is merged, a rebase and merge should be performed P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent target: minor This PR is targeted for the next minor release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bug(MatTooltip): A11y - tooltip role is missing
3 participants