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

Disabled buttons contrast ratio is not WCAG 2.1 compliant #18954

Closed
micamp opened this issue Mar 30, 2020 · 3 comments
Closed

Disabled buttons contrast ratio is not WCAG 2.1 compliant #18954

micamp opened this issue Mar 30, 2020 · 3 comments
Labels
Accessibility This issue is related to accessibility (a11y) area: material/button material spec Issue related to the Material Design spec https://material.io/design/ P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent

Comments

@micamp
Copy link

micamp commented Mar 30, 2020

Bug, feature request, or proposal:

Disabled buttons color should contrast with the background with at least a 3:1 ratio to meet new WCAG 2.1 requirements.

What is the expected behavior?

Disabled buttons color should contrast with the background with at least a 3:1 ratio to meet new WCAG 2.1 requirements.

What is the current behavior?

Disabled buttons color contrast compared to the background is less than the required 3:1 ratio.

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://material.angular.io/components/button/examples
Use a color contrast tool to measure the contrast of a disabled button text color and the background.

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

The WCAG 2.1 standard will go into effect June 30, 2020.

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

Latest, all browsers.

Is there anything else we should know?

Thank you

@manklu
Copy link

manklu commented Mar 31, 2020

@micamp

Disabled buttons color should contrast with the background with at least a 3:1 ratio to meet new WCAG 2.1 requirements.

Can you state the source of the requirement? AFAIK inactive user interface components don't have a contrast requirement.

See https://www.w3.org/TR/WCAG21/#contrast-minimum and https://www.w3.org/TR/WCAG21/#contrast-enhanced

The visual presentation of text and images of text has a contrast ratio of at least ..., except for the following:
...
Incidental: Text or images of text that are part of an inactive user interface component ...
...

Same for non text contrast
https://www.w3.org/TR/WCAG21/#non-text-contrast and

@jelbourn jelbourn added Accessibility This issue is related to accessibility (a11y) material spec Issue related to the Material Design spec https://material.io/design/ P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent labels Apr 2, 2020
@amysorto
Copy link
Contributor

As mentioned by @manklu, disabled elements don't seem to need to meet color contrast requirements in WCAG 2.1 and the same is true for WCAG 2.2: https://www.w3.org/TR/WCAG22/#contrast-minimum. Closing this bug.

@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 Nov 28, 2022
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) area: material/button material spec Issue related to the Material Design spec https://material.io/design/ P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent
Projects
None yet
Development

No branches or pull requests

5 participants