-
Notifications
You must be signed in to change notification settings - Fork 95
Description
Describe the bug
When running the checker on a page that contains scrollable regions (especially but not only if those regions are iframes), the logic that determines the location of the bounding rectangle for highlighting the element is failing.
One part of the issue is that it isn't scrolling the element into view before calculating the position, it's drawing the rectangle farther down the screen where the element would appear were it not hidden by the scroll.
Another issue I'm seeing is that elements inside an iframe are calculate relative to that iframes window without adjusting for the iframes location within it's parent.
To Reproduce
Steps to reproduce the behavior:
- Attaching an example project that contains two scrollable regions, one is in an iframe.
- Run a scan.
- Select the issue it reports on "/document[1] /main[1] /list[1] /listitem[9] /button[1]" for not having an associated label.
- This should highlight the button in that first scrollable list, but since it is not scrolled into view the rectangle does not highlight the button.
- Select the issue it reports on "/document[1] /main[1] /document[1] /textbox[1]".
- This should highlight the textbox that has no label, but since it isn't accounting for the bounds of the iframe being contained within the parent window the position that is highlighted does not match up.
Expected behavior
It should highlight the element that contains the issue. If it needs to scroll that element into view then it should do that.
Screenshots
Desktop (please complete the following information):
- OS: Windows
- Browser Chrome
- Version 137
Definition of Done
- Design artifacts reviewed
- Work item implemented
- Automated test case created (when applicable)
- Unit test completed
- Run Checker (when applicable)
- Manual and Screen Reader Testing (when applicable)
- Video recording of user experience walkthrough (if impact to UX)
- PR created