RESOLVED FIXED 117706
AX: display: -webkit-box formatted <li> elements are not assigned correct accessibility roles
https://bugs.webkit.org/show_bug.cgi?id=117706
Summary AX: display: -webkit-box formatted <li> elements are not assigned correct acc...
Brent Fulgham
Reported 2013-06-17 09:58:45 PDT
The logic that determines accessibility roles for different HTML tokens does the wrong thing for <li> elements that have been given the "-webkit-box" display style. List items should be assigned the "ListItemRole" Web Role, but are instead given a "GroupingRole".
Attachments
This patch includes some unintended changes. Do not bother reviewing. (19.86 KB, patch)
2013-06-17 11:07 PDT, Brent Fulgham
no flags
Patch (10.43 KB, patch)
2013-06-17 11:18 PDT, Brent Fulgham
cfleizach: review+
Brent Fulgham
Comment 1 2013-06-17 11:00:08 PDT
Brent Fulgham
Comment 2 2013-06-17 11:07:00 PDT
Created attachment 204840 [details] This patch includes some unintended changes. Do not bother reviewing.
Brent Fulgham
Comment 3 2013-06-17 11:18:27 PDT
chris fleizach
Comment 4 2013-06-17 11:21:02 PDT
Comment on attachment 204842 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=204842&action=review looking good. i would suggest updating the layout test to make it more specific. > LayoutTests/accessibility/box-styled-lists.html:46 > + var bodyElement = document.getElementById("body"); I try to avoid the attributesofChildren() method these days because it's not very specific if something breaks. For this test I would probably do var listItem = document.accessibleElementById("test 1"); shouldBe("listeItem.role", "'AXRole: AX...'");
Brent Fulgham
Comment 5 2013-06-17 11:24:29 PDT
(In reply to comment #4) > (From update of attachment 204842 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=204842&action=review > > var listItem = document.accessibleElementById("test 1"); > shouldBe("listeItem.role", "'AXRole: AX...'"); I looked at using this, but I'd have to have a custom test for mac and one for windows, since it would be: Mac: shouldBe("listItem.role", "'AXRole: AX...'"); Win: shouldBe("listItem.role", "'list item'"); and so forth. But I'll definitely change the "attributesOfChildren()" call to "accessibleElementById()".
chris fleizach
Comment 6 2013-06-17 11:25:50 PDT
Comment on attachment 204842 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=204842&action=review >> LayoutTests/accessibility/box-styled-lists.html:46 >> + var bodyElement = document.getElementById("body"); > > I try to avoid the attributesofChildren() method these days because it's not very specific if something breaks. > > For this test I would probably do > > var listItem = document.accessibleElementById("test 1"); > shouldBe("listeItem.role", "'AXRole: AX...'"); I've also done debug("List item role: " + listItem.role) so that you can just use different expectations
Brent Fulgham
Comment 7 2013-06-17 18:37:16 PDT
Note You need to log in before you can comment on or make changes to this bug.