w3c / wai-website

This repository hosts the WAI Website.
https://www.w3.org/WAI/
Other
46 stars 153 forks source link

Standard <code> element styling violate WCAG 1.4.1 Use of color #345

Open WilcoFiers opened 1 year ago

WilcoFiers commented 1 year ago

ACT is having difficulties with the styles the WAI site uses for code elements and code blocks.

Here's an example of the issue: https://www.w3.org/WAI/standards-guidelines/act/rules/aizyf1/proposed/#passed-example-1

Screenshot Passed example 1 and 2

The contrast between the code and the rest of the text is 1.34:1. It is very easily missed. There is also no other style changes like you see on many other sites. For example code blocks often get an outline, change in background, and a change of font. Any one of these might be sufficient, but more would probably be better.

yatil commented 11 months ago

That does not – by definition – violate Use of Color because the font is also changed. That said, I’m sure WAI welcomes a better layout in a pull request.

shawna-slh commented 11 months ago

@iadawn just one example of the backlog...