You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Lighthouse Accessibility Contrast test Background and foreground colors do not have a sufficient contrast ratio. should return correct results when a brightness filter is applied.
Actual
Describe what the product actually does.
The Lighthouse Accessibility Contrast test Background and foreground colors do not have a sufficient contrast ratio. returns incorrect results when a brightness filter is applied.
How to Reproduce
Provide a code sample or link to a webpage that reproduces the issue. Without this, your issue may be closed without investigation.
Here is my minimal example. Name this file index.html and place in a folder called test. Then you can run a command like python -m http.server -d test 3000 to serve the html file to run the Lighthouse test in Chrome.
<htmllang="en"><head><title>Lighthouse Accessibility Test</title></head><body><!-- should pass, passes --><h2style="color: rgb(0, 0, 0)">Black with no brightness adjustment.</h2><!-- should pass, passes --><h2style="color: rgb(147, 147, 147)">Middle gray with no brightness adjustment</h2><!-- should fail, passes --><h2style="color: rgb(147, 147, 147); filter: brightness(1000%)">Middle gray with 1000% brightness</h2><!-- should fail, fails --><h2style="color: rgb(241, 241, 241)">95% white with no brightness adjustment</h2><!-- should pass, fails --><h2style="color: rgb(241, 241, 241); filter: brightness(0%)">95% white with 0% brightness</h2></body></html>
Here is what the rendered example looks like.
It is pretty clear that the first, second, and fifth lines should pass the Lighthouse contrast test. However, the first, second, and third lines are the ones that pass the Lighthouse contrast test.
Additional context
Any thing else we should know about the issue?
The text was updated successfully, but these errors were encountered:
Product
axe-core
Product Version
No response
Latest Version
Issue Description
I initially opened this issue in the Google Chrome lighthouse repo, but was told to open it here. GoogleChrome/lighthouse#16209 (comment)
Expectation
Describe what you expected the product to do.
The Lighthouse Accessibility Contrast test
Background and foreground colors do not have a sufficient contrast ratio.
should return correct results when a brightness filter is applied.Actual
Describe what the product actually does.
The Lighthouse Accessibility Contrast test
Background and foreground colors do not have a sufficient contrast ratio.
returns incorrect results when a brightness filter is applied.How to Reproduce
Provide a code sample or link to a webpage that reproduces the issue. Without this, your issue may be closed without investigation.
Here is my minimal example. Name this file
index.html
and place in a folder calledtest
. Then you can run a command likepython -m http.server -d test 3000
to serve the html file to run the Lighthouse test in Chrome.Here is what the rendered example looks like.
It is pretty clear that the first, second, and fifth lines should pass the Lighthouse contrast test. However, the first, second, and third lines are the ones that pass the Lighthouse contrast test.
Additional context
Any thing else we should know about the issue?
The text was updated successfully, but these errors were encountered: