dequelabs / axe-core

Accessibility engine for automated Web UI testing
https://www.deque.com/axe/
Mozilla Public License 2.0
5.75k stars 746 forks source link

fix(target-size): pass for element that has nearby elements that are obscured #4422

Closed straker closed 2 months ago

straker commented 2 months ago

Had to update how we handled the too many rects break early since it would return an empty array, which when looking at the lengths of the arrays in getOffset made it difficult to know which case needed to be handled (returned empty due to too many rects or returned empty because there wasn't any visible rect). Talked to Wilco and we agreed that when we encountered too many rects we could throw and handle the error case in both checks.

Closes: #4387