[CtW] Bounds incorrect when an element becomes scrollable later without reflow
Categories
(Core :: Disability Access APIs, defect)
Tracking
()
People
(Reporter: Jamie, Assigned: morgan)
References
(Blocks 2 open bugs)
Details
Attachments
(1 file)
(deleted),
text/x-phabricator-request
|
Details |
Spun off bug 1809082. Causes problems in LinkedIn and Google Bard.
From bug 1809082 comment 38:
data:text/html,<div style="height:100px; overflow:scroll;"><div id="text"></div></div><button onClick="let html=''; for (let i = 1; i <= 20; ++i) { html += i; html += '<br>'; } document.getElementById('text').innerHTML = html;">Add Text</button>
Click the "Add Text" button, then note the bounds of the "text" id. Scroll the scrollable region to the bottom. Note that the bounds of the text id have not changed accordingly. At this point, hit testing the scrolled text will report results as if it's unscrolled.
The contenteditable bit doesn't matter, but it does seem important that the text be entered after page load.
From bug 1809082 comment 39:
- What's happening here is that the overflow div isn't getting an Accessible, so we can't cache scroll data on it.
- Normally, when something is scrollable, it gets an Accessible because its scrollability makes it focusable and focusable things always get Accessibles.
- In this case, the div wasn't scrollable initially, so we didn't create an Accessible for it.
- Often, when something becomes scrollable, it causes reflow, in which case we would re-evaluate the div and create an Accessible for it.
- In this case, I guess it doesn't get reflowed, perhaps because the size of the div itself doesn't change. Thus, we don't create an Accessible for it.
We can fix this by always creating an Accessible for elements which have overflow: scroll or overflow: auto. To do that, we should be able to extend Morgan's creation patch over in bug 1825611.
Reporter | ||
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Comment 1•2 years ago
|
||
Comment 3•2 years ago
|
||
Backed out with Bug 1825611 and Bug 1825411 for accessible failures on on /browser_general.js
Comment 4•2 years ago
|
||
Backout merged to central: https://hg.mozilla.org/mozilla-central/rev/8d8d99e75818
Comment 6•2 years ago
|
||
bugherder |
Reporter | ||
Updated•2 years ago
|
Comment 7•2 years ago
|
||
The patch landed in nightly and beta is affected.
:morgan, is this bug important enough to require an uplift?
- If yes, please nominate the patch for beta approval.
- If no, please set
status-firefox114
towontfix
.
For more information, please visit BugBot documentation.
Assignee | ||
Comment 8•2 years ago
|
||
I think we will want to uplift this, but not yet -- it's a pretty big patch stack and it could use some more time to bake. I'll leave this NI and revisit
Assignee | ||
Comment 9•1 years ago
|
||
We've deemed this too risky to upload at this point in the cycle, marking 114 as wontfix
Comment 10•1 year ago
|
||
backed out in 115 beta (115.0rc1) for causing bug 1840200 (backout patch is in bug 1840200)
Description
•