-
Notifications
You must be signed in to change notification settings - Fork 779
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(color-contrast): skip ligature icons #3867
Conversation
@@ -537,4 +537,32 @@ describe('color-contrast-matches', function () { | |||
assert.isTrue(rule.matches(input, axe.utils.getNodeFromTree(input))); | |||
}); | |||
} | |||
|
|||
describe('with font icons', () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs a true test case (there are only 2 false cases)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The way I figured it, pretty much every other test in this suite shows that text that isn't an icon font can pass or fail the check. Whatever I add here would basically just be a copy of the default "true" case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The test that's missing is making sure that at least 1 non-ligature icon text passes the matchers when there is an icon ligature present https://github.com/dequelabs/axe-core/pull/3867/files#diff-3d333c18371db80de7813d5146a4dd966928b3463664813bcb8a99289136e542R171-R173
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We talked about this. Due to how font icons work and our font icon detection strategy, having non-icons ligatures in the same text node as icon ligatures doesn't really work. We'll open a pr to add a comment about this in a different pr.
Closes: #3659