RESOLVED FIXED 245212
AX: Dynamic changes to subtrees of AccessibilityNodeObjects can cause missing or stale content
https://bugs.webkit.org/show_bug.cgi?id=245212
Summary AX: Dynamic changes to subtrees of AccessibilityNodeObjects can cause missing...
Tyler Wilcock
Reported 2022-09-15 00:35:54 PDT
AccessibilityNodeObject is missing a few key method implementations that can cause incorrect AX tree construction (either missing or stale content) after dynamic page updates. These methods are: - updateChildrenIfNecessary - setNeedsToUpdateChildren - needsToUpdateChildren - setNeedsToUpdateSubtree
Attachments
Patch (13.51 KB, patch)
2022-09-15 00:38 PDT, Tyler Wilcock
no flags
Radar WebKit Bug Importer
Comment 1 2022-09-15 00:36:05 PDT
Tyler Wilcock
Comment 2 2022-09-15 00:38:56 PDT
Andres Gonzalez
Comment 3 2022-09-15 06:58:07 PDT
(In reply to Tyler Wilcock from comment #2) > Created attachment 462352 [details] > Patch Good catch! --- a/LayoutTests/accessibility/display-contents-dynamically-added-children.html +++ a/LayoutTests/accessibility/display-contents-dynamically-added-children.html + function traversePage() { ... + let textContent = accessibilityController.platformName === "ios" ? searchResult.description : searchResult.stringValue; + testOutput += `\n${textContent}`; This could be a single line. + } + testOutput += "\n"; + } + } Don't really need this second \n. You also have function dumpAccessibilityTree(accessibilityObject, stopElement, indent, allAttributesIfNeeded, getValueFromTitle, includeSubrole) in accessibility-helper.js that would also do the trick.
Andres Gonzalez
Comment 4 2022-09-15 07:02:39 PDT
Shouldn't the bug title reflect that this is a display:contents problem?
Tyler Wilcock
Comment 5 2022-09-15 14:59:44 PDT
(In reply to Andres Gonzalez from comment #4) > Shouldn't the bug title reflect that this is a display:contents problem? This isn't specific to display:contents. Any AccessibilityNodeObject is affected. Also, I acknowledge and agree with your suggestions regarding the test. I would prefer not to wait 12 hours for another round of EWS, so I can try to cover those changes in a later patch.
EWS
Comment 6 2022-09-15 15:39:32 PDT
Committed 254534@main (c6e7fc8ecc94): <https://commits.webkit.org/254534@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 462352 [details].
Note You need to log in before you can comment on or make changes to this bug.