Skip to content

Commit

Permalink
Merge branch 'release-3.4.0' of github.com:browserstack/a11y-engine-a…
Browse files Browse the repository at this point in the history
…xe-core into release-3.4.0
  • Loading branch information
Utkarsh Chaudhary committed Dec 19, 2024
2 parents 74dc2c9 + 777c20b commit 80b022c
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lib/checks/color/link-in-text-block-evaluate.js
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,14 @@ function getColorContrast(node, parentBlock) {
nodeColor = getForegroundColor(node);
parentColor = getForegroundColor(parentBlock);

if (!nodeColor) {
nodeColor = new axe.commons.color.Color(0, 0, 0, 0);
}

if (!parentColor) {
parentColor = new axe.commons.color.Color(0, 0, 0, 0);
}

if (!nodeColor || !parentColor) {
return undefined;
}
Expand Down

0 comments on commit 80b022c

Please sign in to comment.