Skip to content

Conversation

@tbusillo
Copy link
Contributor

@tbusillo tbusillo commented May 31, 2022

What:

This PR fixes #343 by improving the color contrast between foreground and background colors used with several interactive UI elements.

Why:

Insufficient color contrast was causing the expand/collapse trigger element difficult to see for non-impaired and impaired users. This is an interactive element and its clickable target is small, so if a user cannot see the <IconButton>, they cannot expand/collapse certain elements.

How:

The default color used for gray-500 was overridden with a darker shade via extending the tailwind.config.js. In addition, the <IconButton> component was updated to make its light and dark variants use the new color.

Checklist:

  • Tests
  • Ready to be merged

Below artifacts show examples of the fix and new contrast ratios ("pass" for graphical objects is the relevant one):

Screen Shot 2022-05-30 at 10 58 12 PM

Screen Shot 2022-05-30 at 10 58 04 PM

Screen Shot 2022-05-30 at 11 02 04 PM

Screen Shot 2022-05-30 at 11 00 55 PM

@tbusillo tbusillo marked this pull request as ready for review May 31, 2022 03:06
@smeijer smeijer merged commit 1375ffc into testing-library:develop Jun 7, 2022
@tbusillo
Copy link
Contributor Author

tbusillo commented Jun 7, 2022

Thank you @smeijer!

@smeijer
Copy link
Member

smeijer commented Jun 7, 2022

Deployed to testing-playground.com 🙂 thanks @tbusillo!

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.

Improve the color contrast of IconButton when used in Expandable component

2 participants