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

Accessible Color Warnings #334

Merged
merged 3 commits into from
Oct 20, 2017
Merged

Accessible Color Warnings #334

merged 3 commits into from
Oct 20, 2017

Conversation

zeke
Copy link
Contributor

@zeke zeke commented Oct 19, 2017

The pick-a-good-color module will always pick an accessible color, but sometimes the color just doesn't look quite right.

To work around this, #325 enabled app developers to choose their own colors. This PR is a followup that ensures sure the human-provided colors are in fact accessible according to the WCAG guidelines..

When a color's contrast ratio is not high enough, this kind of error is produced:

AssertionError: google-play-music-desktop-player: contrast ratio too low for goodColorOnWhite. Try: #DE2811

cc @MarshallOfSound. I took the liberty of adding custom colors for GPMDP as a test case, based on the icon and the website.

cc @codebytere

@zeke
Copy link
Contributor Author

zeke commented Oct 19, 2017

This also updates the CONTRIBUTING doc to explain the contrast requirements and link to a site that makes it easy to pick accessible colors.

Also broke the doc up a bit with more headings so we can more easily deep-link to sections in the doc.

Copy link
Member

@codebytere codebytere left a comment

Choose a reason for hiding this comment

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

looks 💯

zeke added a commit that referenced this pull request Oct 20, 2017
* set color overrides for GPMDP

* verify that human-provided colors are accessible

* update contributing
@zeke zeke merged commit 4f2ad43 into master Oct 20, 2017
@zeke zeke deleted the accessible-color-warnings branch October 20, 2017 05:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants