[wpt-sync] Sync PR 36827 - Implement "focus fixup" for popovers
Categories
(Core :: DOM: Core & HTML, task, P4)
Tracking
()
People
(Reporter: mozilla.org, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 36827 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/36827
Details from upstream follow.
Mason Freed <masonf@chromium.org> wrote:
Implement "focus fixup" for popovers
This implements the focus fixup described in [1], which:
- Moves focus from an invoking element to its invoked popover,
regardless of where in the DOM that popover lives.- Moves focus back to the next focusable element after the
invoking element once focus leaves the invoked popover.- Skips over an open invoked popover otherwise.
The logic follows very closely the case of slotted light DOM content,
for which focus moves from the shadow root content to the slotted
light DOM content and back.[1] https://github.com/w3c/html-aam/wiki/HTML-Popup-Attribute-A11y-Proposal-%28manual-and-auto%29
Bug: 1307772
Change-Id: Ic12441fc3b8d2f1c405bf912234dd24e4b05dc69
Reviewed-on: https://chromium-review.googlesource.com/4006714
WPT-Export-Revision: ea368755bb84097e216cb01761c210d7f7dc0344
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Comment 1•2 years ago
|
||
Pushed to try (stability) https://treeherder.mozilla.org/#/jobs?repo=try&revision=80a489423ed34d873b3909b237d289054e097504
Assignee | ||
Comment 2•2 years ago
|
||
CI Results
Ran 9 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI
Total 10 tests
Status Summary
Firefox
OK
: 6
PASS
: 3
FAIL
: 65
ERROR
: 2
Chrome
OK
: 6
PASS
: 3
FAIL
: 67
ERROR
: 2
Safari
OK
: 6
PASS
: 3
FAIL
: 65
ERROR
: 2
Links
Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base
Details
New Tests That Don't Pass
- /html/semantics/popovers/popover-anchor-nesting.tentative.html [wpt.fyi]:
ERROR
(Chrome:ERROR
, Safari:ERROR
) - /html/semantics/popovers/popover-animated-hide-cleanup.tentative.html [wpt.fyi]
- Ensure no crashes if running animations are immediately cancelled (document removal):
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Ensure no crashes if running animations are immediately cancelled (dialog showModal):
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Ensure no crashes if running transitions are immediately cancelled (button click):
FAIL
(Chrome:FAIL
, Safari:FAIL
)
- Ensure no crashes if running animations are immediately cancelled (document removal):
- /html/semantics/popovers/popover-animation-corner-cases.tentative.html [wpt.fyi]
- Descendent animations should keep the pop up visible until the animation ends:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Pre-existing animations should not keep the pop up visible until the animation ends:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - It should be possible to use the "popoverhide" event handler to animate the hide:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - It should not be possible to use the "popoverhide" event handler to animate the hide, if the hide is due to dialog.showModal:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - hide event cannot be cancelled:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Closing animations are triggered by changing the popover type:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - animation finish/cancel events must be trusted in order to finish closing the popover.:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Capturing event listeners can't affect popover animations.:
FAIL
(Chrome:FAIL
, Safari:FAIL
)
- Descendent animations should keep the pop up visible until the animation ends:
- /html/semantics/popovers/popover-attribute-basic.tentative.html [wpt.fyi]
- The element <div popover="" id="boolean">Pop up</div> should behave as a popover.:
FAIL
(Chrome:FAIL
, Safari:FAIL
)
- The element <div popover="" id="boolean">Pop up</div> should behave as a popover.:
- /html/semantics/popovers/popover-events.tentative.html [wpt.fyi]
- Popovershow and popoverhide events (listener) get properly dispatched for popovers:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popovershow and popoverhide events (attribute) get properly dispatched for popovers:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popovershow event is cancelable:
FAIL
(Chrome:FAIL
, Safari:FAIL
)
- Popovershow and popoverhide events (listener) get properly dispatched for popovers:
- /html/semantics/popovers/popover-focus.tentative.html [wpt.fyi]
- Popover focus test: default behavior - popover is not focused:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover button click focus test: default behavior - popover is not focused:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover focus test: autofocus popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover button click focus test: autofocus popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover corner cases test: autofocus popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover focus test: autofocus empty popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover button click focus test: autofocus empty popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover corner cases test: autofocus empty popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover focus test: autofocus popover with button:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover button click focus test: autofocus popover with button:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover corner cases test: autofocus popover with button:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover focus test: autofocus child:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover button click focus test: autofocus child:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover corner cases test: autofocus child:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover focus test: autofocus on tabindex=0 element:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover button click focus test: autofocus on tabindex=0 element:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover corner cases test: autofocus on tabindex=0 element:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover focus test: autofocus multiple children:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover button click focus test: autofocus multiple children:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover corner cases test: autofocus multiple children:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover focus test: autofocus popover and multiple autofocus children:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover button click focus test: autofocus popover and multiple autofocus children:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover corner cases test: autofocus popover and multiple autofocus children:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popover focus navigation:
FAIL
(Chrome:FAIL
, Safari:FAIL
)
- Popover focus test: default behavior - popover is not focused:
- /html/semantics/popovers/popover-light-dismiss.tentative.html [wpt.fyi]:
ERROR
(Chrome:ERROR
, Safari:ERROR
)- Clicking outside a popover will dismiss the popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Canceling pointer events should not keep clicks from light dismissing popovers:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Clicking inside a popover does not close that popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Popovers close on pointerup, not pointerdown:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Synthetic events can't close popovers:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Moving focus outside the popover should not dismiss the popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Clicking inside a child popover shouldn't close either popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Clicking inside a parent popover should close child popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Clicking on invoking element, after using it for activation, shouldn't close its popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Clicking on invoking element, after using it for activation, shouldn't close its popover (nested case):
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Clicking on invoking element, after using it for activation, shouldn't close its popover (nested case, not used for invocation):
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Clicking on invoking element, even if it wasn't used for activation, shouldn't close its popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Clicking on popovertoggletarget element, even if it wasn't used for activation, should hide it exactly once:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Clicking on anchor element (that isn't an invoking element) shouldn't close its popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Dragging from an open popover outside an open popover should leave the popover open:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - An invoking element should be part of the ancestor chain:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - An invoking element that was not used to invoke the popover can still be part of the ancestor chain:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Scrolling within a popover should not close the popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Moving focus back to the anchor element should not dismiss the popover:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Ensure circular/convoluted ancestral relationships are functional:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Ensure circular/convoluted ancestral relationships are functional, with a direct showPopover():
FAIL
(Chrome:FAIL
, Safari:FAIL
) - Hide the target popover during "hide all popovers until":
FAIL
(Chrome:FAIL
, Safari:FAIL
)
- Clicking outside a popover will dismiss the popover:
- /html/semantics/popovers/popover-shadow-dom.tentative.html [wpt.fyi]
- Popovers located inside shadow DOM can still be shown:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - anchor references do not cross shadow boundaries:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - anchor references use the flat tree not the DOM tree:
FAIL
(Chrome:FAIL
, Safari:FAIL
) - The popover stack is preserved across shadow-inclusive ancestors:
FAIL
(Chrome:FAIL
, Safari:FAIL
)
- Popovers located inside shadow DOM can still be shown:
Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/24af96e8c941 [wpt PR 36827] - Implement correct focus behavior for popovers, a=testonly https://hg.mozilla.org/integration/autoland/rev/3b432bd386d0 [wpt PR 36827] - Update wpt metadata, a=testonly
Comment 4•1 year ago
|
||
bugherder |
Description
•