dequelabs / dequelabs/axe-core

Color-contrast should skip elements behind a non-native modal backdrop

Open
#4,441 0 comments 0 reactions 0 assignees View on GitHub
color contrast fix rules
Dominant language
JavaScript
Stars
7.5k
Forks
933
Avg merge
2d 23h
Merged PRs (30d)
17

Description

Spotted this problem here:
https://kanecohen.github.io/modal-vanilla/

![Screenshot of axe extension reporting a color contrast issue](https://github.com/dequelabs/axe-core/assets/530687/f4dad813-6209-4c5e-9375-a8cff2c74d6e)

Axe-core does not run color-contrast against texts when they are covered by a backdrop op a native HTML `` element. However when you do the same with javascript modal (one that doesn't set aria-hidden=true) the text behind the backdrop is failed for having low contrast when the backdrop is on top of it.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.