Branch: refs/heads/main Home: https://github.com/WebKit/WebKit Commit: 3c4dcc0a6eb027415d5416a96f03550e09220a78 https://github.com/WebKit/WebKit/commit/3c4dcc0a6eb027415d5416a96f03550e09220a78 Author: Tyler Wilcock <tyle...@apple.com> Date: 2023-07-18 (Tue, 18 Jul 2023)
Changed paths: M LayoutTests/accessibility-isolated-tree/TestExpectations A LayoutTests/accessibility/multiple-label-input-expected.txt A LayoutTests/accessibility/multiple-label-input.html M LayoutTests/accessibility/title-ui-element-correctness-expected.txt M LayoutTests/accessibility/title-ui-element-correctness.html A LayoutTests/platform/glib/accessibility/multiple-label-input-expected.txt A LayoutTests/platform/glib/accessibility/title-ui-element-correctness-expected.txt A LayoutTests/platform/ios/accessibility/multiple-label-input-expected.txt M Source/WebCore/accessibility/AccessibilityNodeObject.cpp M Source/WebCore/accessibility/AccessibilityNodeObject.h M Source/WebCore/accessibility/cocoa/AccessibilityObjectCocoa.mm M Source/WebCore/dom/TreeScope.cpp M Source/WebCore/dom/TreeScope.h M Source/WebCore/dom/TreeScopeOrderedMap.cpp M Source/WebCore/dom/TreeScopeOrderedMap.h Log Message: ----------- AX: incorrect accessible name from multiple label elements https://bugs.webkit.org/show_bug.cgi?id=152663 rdar://problem/24033482 Reviewed by Chris Fleizach. Per https://www.w3.org/TR/html-aam-1.0/#input-type-text-input-type-password-input-type-number-input-type-search-input-type-tel-input-type-email-input-type-url-and-textarea-element-accessible-name-computation: > Otherwise use the associated label element(s) accessible name(s) - if more > than one label is associated; concatenate by DOM order, delimited by spaces. Prior to this patch, we only used accessible text from the first associated label element. * LayoutTests/accessibility-isolated-tree/TestExpectations: * LayoutTests/accessibility/multiple-label-input-expected.txt: Added. * LayoutTests/accessibility/multiple-label-input.html: Added. * LayoutTests/accessibility/title-ui-element-correctness-expected.txt: * LayoutTests/accessibility/title-ui-element-correctness.html: * LayoutTests/platform/ios/accessibility/multiple-label-input-expected.txt: Added. * Source/WebCore/accessibility/AccessibilityNodeObject.cpp: (WebCore::labelForNode): (WebCore::AccessibilityNodeObject::checkboxOrRadioRect const): (WebCore::AccessibilityNodeObject::correspondingLabelForControlElement const): (WebCore::AccessibilityNodeObject::textForLabelElements const): (WebCore::AccessibilityNodeObject::titleElementText const): (WebCore::AccessibilityNodeObject::titleUIElement const): (WebCore::AccessibilityNodeObject::exposesTitleUIElement const): (WebCore::AccessibilityNodeObject::title const): (WebCore::AccessibilityNodeObject::labelForElement const): Deleted. (WebCore::AccessibilityNodeObject::textForLabelElement const): Deleted. * Source/WebCore/accessibility/AccessibilityNodeObject.h: * Source/WebCore/accessibility/cocoa/AccessibilityObjectCocoa.mm: (WebCore::AccessibilityObject::descriptionAttributeValue const): (WebCore::AccessibilityObject::helpTextAttributeValue const): * Source/WebCore/dom/TreeScope.cpp: (WebCore::TreeScope::labelElementForId): Deleted. * Source/WebCore/dom/TreeScope.h: * Source/WebCore/dom/TreeScopeOrderedMap.cpp: (WebCore:: const): (WebCore::TreeScopeOrderedMap::getElementByLabelForAttribute const): Deleted. * Source/WebCore/dom/TreeScopeOrderedMap.h: Canonical link: https://commits.webkit.org/266151@main _______________________________________________ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes