Skip to content

Commit bd96e09

Browse files
Aaron LeventhalDanielRyanSmith
authored andcommitted
Avoid adding nested pseudo elements twice in a11y tree
Some nested pseudo elements can get added twice in the tree, when their layout parent and DOM parent lead to different AXObjects that can both add them. A good solution will pass both of these tests: All/DumpAccessibilityTreeTest.AccessibilityCSSFirstLetter/blink external/wpt/accessibility/crashtests/bdo-table-cell.html This code will go away once legacy layout is completely removed. See discussion in CL. Bug: 1314808 Change-Id: I6a993cd3981719240737a79be79afd3b65ca42b5 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3591572 Reviewed-by: Rune Lillesveen <[email protected]> Auto-Submit: Aaron Leventhal <[email protected]> Reviewed-by: Daniel Libby <[email protected]> Reviewed-by: Mason Freed <[email protected]> Commit-Queue: Aaron Leventhal <[email protected]> Cr-Commit-Position: refs/heads/main@{#996484}
1 parent b6c8672 commit bd96e09

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<!doctype html>
2+
<link rel="help" href="https://crbug.com/1314808">
3+
<style>
4+
item:after { display: block; content: open-quote; }
5+
item { display: list-item; }
6+
</style>
7+
<bdo style="direction:rtl">
8+
x<mark></mark>
9+
</bdo>
10+
<span style="display: table-cell; column-width: 0px;"></span>
11+
<script>
12+
const new_listitem_child = document.createElement('item');
13+
document.querySelector('mark').appendChild(new_listitem_child);
14+
</script>
15+
16+
17+
<!--
18+
ax_object.cc(739)] Check failed: child != this. Previous parent still has |this| child:\n
19+
ERR: "\\"ListMarker\\" axid#14 <::marker> needsToUpdateChildren" should be a child of "\\"ListItem\\" axid#12 <item> needsToUpdateChildren" not of "\\"GenericContainer\\" axid#13 <::after> #children=2"\n
20+
21+
-->

0 commit comments

Comments
 (0)