Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 8ee95fe74bfa89ffc9369cc128ec58ed7eb127f6
      
https://github.com/WebKit/WebKit/commit/8ee95fe74bfa89ffc9369cc128ec58ed7eb127f6
  Author: Tyler Wilcock <[email protected]>
  Date:   2024-04-10 (Wed, 10 Apr 2024)

  Changed paths:
    A LayoutTests/accessibility/hidden-slot-expected.txt
    A LayoutTests/accessibility/hidden-slot.html
    M LayoutTests/platform/ios/TestExpectations
    M Source/WebCore/Headers.cmake
    M Source/WebCore/WebCore.xcodeproj/project.pbxproj
    M Source/WebCore/accessibility/AXObjectCache.cpp
    M Source/WebCore/accessibility/AccessibilityObject.cpp
    M Source/WebCore/dom/Element.cpp
    M Source/WebCore/dom/Element.h
    M Source/WebCore/dom/ElementInlines.h

  Log Message:
  -----------
  AX: Setting aria-hidden on a slot does not hide the slots assigned nodes
https://bugs.webkit.org/show_bug.cgi?id=256186
rdar://problem/108762653

Reviewed by Andres Gonzalez.

Fix this by changing AccessibilityObject::isARIAHidden to check if the given 
object is within a hidden slot.

To help accomplish this, a new Element::attributeWithDefaultARIA function is 
added, as it is needed to check the
slot's aria-hidden attribute, and this logic was repeated several times 
throughout accessibility code.

* LayoutTests/accessibility/hidden-slot-expected.txt: Added.
* LayoutTests/accessibility/hidden-slot.html: Added.
* LayoutTests/platform/ios/TestExpectations: Enable new test.
* Source/WebCore/Headers.cmake:
CustomElementDefaultARIA.h should have been present in this file, but
wasn't — this patch adds it.
* Source/WebCore/WebCore.xcodeproj/project.pbxproj:
CustomElementDefaultARIA.h should have been under Private membership to
WebCore, but was Public. This is wrong per 
https://github.com/WebKit/WebKit/blob/main/Introduction.md#how-to-add-a-new-h-or-cpp-file,
and caused compilation failures. It's now Private.
* Source/WebCore/accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::isModalElement const):
(WebCore::nodeHasRole):
* Source/WebCore/accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::getAttribute const):
(WebCore::AccessibilityObject::isARIAHidden const):
* Source/WebCore/dom/Element.cpp:
(WebCore::Element::customElementDefaultARIAIfExists const):
(WebCore::Element::customElementDefaultARIAIfExists): Deleted.
* Source/WebCore/dom/Element.h:
* Source/WebCore/dom/ElementInlines.h:
(WebCore::Element::attributeWithDefaultARIA const):

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to