feat(rule): add new color-contrast-enhanced rule (WCAG AAA)#3235
feat(rule): add new color-contrast-enhanced rule (WCAG AAA)#3235WilcoFiers merged 22 commits intodequelabs:developfrom
Conversation
|
Hold on. I think I accidentally put code from another PR of mine into this PR. I'll try to fix that. |
|
Thanks for updating all the locales as well! My only concern is that this will run by default, which I don't think we want. @WilcoFiers how should we handle that? |
|
When Wilco wrote "This rule will have to be off by default" I figured I should put |
|
Ha, you are correct! I completely missed that part. I'll look this over more thoroughly later today. |
|
I think disabling it is the right thing to do here. |
straker
left a comment
There was a problem hiding this comment.
Looked this over, looks good! Thanks again for taking care of all the locale strings and even updating their text with WCAG 2 AAA.
@WilcoFiers I have reviewed the pr and it all looks good. I made sure that all the locale strings were exact copies of their color-contrast equivalent so that should all be good. I'll wait for your approval before merging.
| axe.run( | ||
| '#fixture', | ||
| { runOnly: { type: 'rule', values: ['color-contrast'] } }, | ||
| { runOnly: { type: 'rule', values: ['color-contrast-enhanced', 'color-contrast'] } }, |
There was a problem hiding this comment.
For clarity, I prefer we give color-contrast-enhanced its own set of integration tests, focused specifically on showing the higher contrast values are properly applied. This PR has no test that shows that a test with 6:1 fails this rule for example.
There was a problem hiding this comment.
Sure thing, I can add those tests. In the next few days, I hope.
There was a problem hiding this comment.
I've been otherwise occupied for the last few weeks but I hope to address this soon.
There was a problem hiding this comment.
Is something like this what you have in mind? My latest commit, ./test/integration/full/contrast-enhanced/simple.html
|
@dan-tripp do you need any help adding separate tests for AAA color-contrast? |
|
I have some ideas but haven't implemented them yet because life got in the way. Soon I hope to add them to this PR. |
This reverts commit 9f996bc.
…ractive" Closes issue dequelabs#2934
Work in progress.
…ted-interactive"" This reverts commit 30f0e01.
Co-authored-by: Wilco Fiers <WilcoFiers@users.noreply.github.com>
WilcoFiers
left a comment
There was a problem hiding this comment.
Great work! Thank you @dan-tripp Much appreciated.
And for the books, I reviewed this PR for security.
|
Nice! Thank you. |
feat(rule): add new color-contrast-enhanced rule (WCAG AAA)
Same code as color-contrast rule, but with different default thresholds.
Closes issue: #3189