Branch: refs/heads/main Home: https://github.com/WebKit/WebKit Commit: 6e3d19b20a3743ff9679d3362dd577ce21838f4f https://github.com/WebKit/WebKit/commit/6e3d19b20a3743ff9679d3362dd577ce21838f4f Author: Tim Nguyen <n...@apple.com> Date: 2024-07-20 (Sat, 20 Jul 2024)
Changed paths: M LayoutTests/imported/w3c/web-platform-tests/html/semantics/popovers/popover-focus-2-expected.txt M Source/WebCore/dom/Element.cpp M Source/WebCore/html/HTMLFormControlElement.h M Source/WebCore/page/FocusController.cpp Log Message: ----------- [popover] Improve tab navigation https://bugs.webkit.org/show_bug.cgi?id=276843 rdar://132129060 Reviewed by Darin Adler. This change: - Changes the scope owner to be the popover rather than the invoker - Makes popovers with invokers themselves not focusable, since they delegate focus - In backwards navigation, makes the popover return to its invoker, rather than the node preceding the invoker - In the nested popovers case, ensures popovers without focusable contents are ignored from backwards tab navigation Test: LayoutTests/imported/w3c/web-platform-tests/html/semantics/popovers/popover-focus-2.html * LayoutTests/imported/w3c/web-platform-tests/html/semantics/popovers/popover-focus-2-expected.txt: * Source/WebCore/dom/Element.cpp: (WebCore::Element::isKeyboardFocusable const): * Source/WebCore/html/HTMLFormControlElement.h: * Source/WebCore/page/FocusController.cpp: (WebCore::invokerForOpenPopover): (WebCore::openPopoverForInvoker): (WebCore::isFocusScopeOwner): (WebCore::FocusNavigationScope::firstChildInScope const): (WebCore::FocusNavigationScope::lastChildInScope const): (WebCore::FocusNavigationScope::nextSiblingInScope const): (WebCore::FocusNavigationScope::previousSiblingInScope const): (WebCore::FocusNavigationScope::firstNodeInScope const): (WebCore::FocusNavigationScope::lastNodeInScope const): (WebCore::FocusNavigationScope::previousInScope const): (WebCore::FocusNavigationScope::owner const): (WebCore::FocusNavigationScope::scopeOf): (WebCore::FocusNavigationScope::scopeOwnedByScopeOwner): (WebCore::FocusController::findFocusableElementAcrossFocusScope): (WebCore::isOpenPopoverWithInvoker): Deleted. (WebCore::invokerForPopoverShowingState): Deleted. (WebCore::FocusNavigationScope::scopeOwnedByPopoverInvoker): Deleted. Canonical link: https://commits.webkit.org/281167@main To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications _______________________________________________ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes