Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 60d5c002f82a1a0cdec16395924f392da15890b4
      
https://github.com/WebKit/WebKit/commit/60d5c002f82a1a0cdec16395924f392da15890b4
  Author: Tyler Wilcock <[email protected]>
  Date:   2026-02-24 (Tue, 24 Feb 2026)

  Changed paths:
    A LayoutTests/accessibility/mac/svg-use-symbol-in-img-element-expected.txt
    A LayoutTests/accessibility/mac/svg-use-symbol-in-img-element.html
    A LayoutTests/accessibility/resources/svg-with-use-symbol.svg
    M Source/WebCore/accessibility/AXCoreObject.h
    M Source/WebCore/accessibility/AXSearchManager.cpp

  Log Message:
  -----------
  AX: SVG symbols in <img src> included in VoiceOver Images web rotor
https://bugs.webkit.org/show_bug.cgi?id=244221
rdar://98999595

Reviewed by Joshua Hoffman.

When an <img> element references an SVG file containing <use> elements
(which reference <symbol> elements), VoiceOver's Images web rotor
incorrectly lists each symbol/use instance as a separate unnamed image
alongside the main <img> element.

Fix this by adding an isInImage() helper method to AXCoreObject that
checks if an accessibility object is a descendant of an image element.
Then modify the Graphic search key to exclude such descendants.

* LayoutTests/accessibility/mac/svg-use-symbol-in-img-element-expected.txt: 
Added.
* LayoutTests/accessibility/mac/svg-use-symbol-in-img-element.html: Added.
* LayoutTests/accessibility/resources/svg-with-use-symbol.svg: Added.
* Source/WebCore/accessibility/AXCoreObject.h:
(WebCore::AXCoreObject::isInImage const):
* Source/WebCore/accessibility/AXSearchManager.cpp:
(WebCore::AXSearchManager::matchForSearchKeyAtIndex):

Canonical link: https://commits.webkit.org/308126@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to