Bug 244221

Summary: AX: SVG symbols in <img src> included in VoiceOver Images web rotor
Product: WebKit Reporter: Curtis Wilcox <webkit.org>
Component: AccessibilityAssignee: Tyler Wilcock <tyler_w>
Status: NEW    
Severity: Normal CC: andresg_22, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Safari Technology Preview   
Hardware: All   
OS: All   

Curtis Wilcox
Reported 2022-08-22 14:32:35 PDT
If an <img> element has an SVG as its source (linked file or `data` encoded) and that SVG contains <use> elements that reference a <symbol> element, VoiceOver's Images web rotor includes each one as an unnamed image in addition to the <img> element with whatever name. For example, if an <img> element with alt="Boxes" has an SVG that uses two <use> elements to make the same <symbol> appear twice, the web rotor's list of images would be: * Boxes image * image * image As each unnamed image is selected in the rotor, VoiceOver's cursor outline appears around the <use> element. It does not appear possible to navigate into the SVG from the page, they're only accessed through the rotor. Adding role="img" to the <img> element has no effect. Examples: https://codepen.io/ccwilcox/full/VwXRBLN This was tested using Safari 15.6.1 and Safari Technology Preview Release 151 on macOS 12.5.1. Inspecting the SVG, each <use> element contains Shadow Content which is an <svg> containing the referenced <symbol> element's contents. Adding role="none" to a <use> element prevents it from appearing in the rotor, adding role='none' to either the <symbol> or the <path> within has no effect. Adding aria-label="one box" to a <use> element adds it to the web rotor list but the Shadow <svg> within is still also included as an unnamed image. For comparison, only the <img> element appears in the web rotor when VoiceOver is used with Chrome (104) or Firefox (103.0.2).
Attachments
Radar WebKit Bug Importer
Comment 1 2022-08-22 14:32:45 PDT
Curtis Wilcox
Comment 2 2026-02-10 18:31:59 PST
In Safari 26.2 on macOS 15.7.3, adding role="img" to the <img> element does prevent the <use> elements from being in the VoiceOver reading order and Images Rotor.
Tyler Wilcock
Comment 3 2026-02-13 07:51:43 PST
Note You need to log in before you can comment on or make changes to this bug.