New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement ARIA id-ref reflection for ElementInternals #4452
Conversation
EWS run on previous version of this PR (hash a4d9155) |
EWS run on previous version of this PR (hash 630d892) |
EWS run on previous version of this PR (hash 8bc1cd9) |
EWS run on current version of this PR (hash 985cac2) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, not sure if you also want to ask for review to someone with more experience on the accessibility code.
https://bugs.webkit.org/show_bug.cgi?id=245328 Reviewed by Manuel Rego Casasnovas. This patch adds the support for id-ref ARIA attributes to ElementInternals. * LayoutTests/accessibility/custom-elements/controls-expected.txt: Added. * LayoutTests/accessibility/custom-elements/controls.html: Added. * LayoutTests/accessibility/custom-elements/describedby-expected.txt: Added. * LayoutTests/accessibility/custom-elements/describedby.html: Added. * LayoutTests/accessibility/custom-elements/flowto-expected.txt: Added. * LayoutTests/accessibility/custom-elements/flowto.html: Added. * LayoutTests/accessibility/custom-elements/menuitem-expected.txt: * LayoutTests/accessibility/custom-elements/menuitem.html: * LayoutTests/imported/w3c/web-platform-tests/custom-elements/form-associated/ElementInternals-accessibility-expected.txt: * LayoutTests/platform/gtk/accessibility/custom-elements/describedby-expected.txt: Added. * LayoutTests/platform/mac-wk1/TestExpectations: * Source/WebCore/Sources.txt: * Source/WebCore/WebCore.xcodeproj/project.pbxproj: * Source/WebCore/accessibility/AXObjectCache.cpp: (WebCore::AXObjectCache::isModalElement const): (WebCore::nodeHasRole): (WebCore::AXObjectCache::updateRelationsIfNeeded): Add the support for defining relations via ElementInternals. * Source/WebCore/accessibility/AccessibilityObject.cpp: (WebCore::AccessibilityObject::getAttribute const): (WebCore::AccessibilityObject::elementsFromAttribute const): Ditto. * Source/WebCore/bindings/js/JSElementInternalsCustom.cpp: Added. (WebCore::getElementsArrayAttribute): Added. (WebCore::JSElementInternals::ariaControlsElements const): Added. (WebCore::JSElementInternals::ariaDescribedByElements const): Added. (WebCore::JSElementInternals::ariaDetailsElements const): Added. (WebCore::JSElementInternals::ariaErrorMessageElements const): (WebCore::JSElementInternals::ariaFlowToElements const): Added. (WebCore::JSElementInternals::ariaLabelledByElements const): Added. (WebCore::JSElementInternals::ariaOwnsElements const): Added. * Source/WebCore/dom/CustomElementDefaultARIA.cpp: (WebCore::isElementVisible): Added. (WebCore::CustomElementDefaultARIA::valueForAttribute const): Added the support for converting WeakPtr<Element> and Vector<WeakPtr<Element>> to ID strings. (WebCore::CustomElementDefaultARIA::elementForAttribute const): Added. (WebCore::CustomElementDefaultARIA::setElementForAttribute): Added. (WebCore::CustomElementDefaultARIA::elementsForAttribute const): Added. (WebCore::CustomElementDefaultARIA::setElementsForAttribute): Added. * Source/WebCore/dom/CustomElementDefaultARIA.h: * Source/WebCore/dom/ElementInternals.cpp: (WebCore::computeValueForAttribute): Extracted out of setAttributeWithoutSynchronization. (WebCore::ElementInternals::setAttributeWithoutSynchronization): (WebCore::ElementInternals::attributeWithoutSynchronization const): (WebCore::ElementInternals::getElementAttribute const): Added. (WebCore::ElementInternals::setElementAttribute): Added. (WebCore::ElementInternals::getElementsArrayAttribute const): Added. (WebCore::ElementInternals::setElementsArrayAttribute): Added. * Source/WebCore/dom/ElementInternals.h: * Source/WebCore/dom/ElementInternals.idl: Canonical link: https://commits.webkit.org/254709@main
985cac2
to
6989a5b
Compare
Committed 254709@main (6989a5b): https://commits.webkit.org/254709@main Reviewed commits have been landed. Closing PR #4452 and removing active labels. |
6989a5b
985cac2