-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Reland "Add popover attribute" #8717
Conversation
So it would appear that these are the only open conversation threads from the prior PR: |
As per the resolution in openui/open-ui#342 (comment) I have added the "aftertoggle" event which is like "beforetoggle" but is fired asynchronously |
This was at the request of @smaug---- but had good consensus in the meeting. The important use cases are a) programmatically setting focus (via imperative logic) both before the popover shows and returning it after it hides, and b) allowing similar code (that uses |
As per the HTML meeting today, I renamed "aftertoggle" to "toggle" because it matches the details element, and I prevented it from being fired on removal |
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.
Still spotting a couple issues, including one that's assert-related.
The toggle
event index entry needs to be updated to say it's used for more than the details
element.
source
Outdated
false is false, then:</p> | ||
|
||
<ol> | ||
<li><p><span>Assert</span>: <var>throwExceptions</var> is true.</p></li> |
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.
Can't you hit this assert if a click
event listener on a button
element removes the popover target?
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.
I tried adding a test for this, and realized that the popover target attribute activation behavior is missing some calls to "check popover validity". I added the checks, so this shouldn't be possible anymore.
To recap a bit on what we discussed in that meeting (and got agreement on from the various attendees):
Note: Given how many things I ended up noting above as un-discussed, it might be prudent to schedule another sync meeting of some sort for the |
Thanks for summarizing the discussion in such detail, and for raising the new points! Universally, I think your conclusions about the "extra" stuff sound totally reasonable. In particular:
Your proposed naming (
I had forgotten about this behavior. Since we're re-using the
+1, I think they will indeed get two events, and that's ok. |
Ok, I just pushed a patch for the following:
|
@annevk, any objections to the recent event changes? I've incorporated all of the points in Domenic's last comment into the PR. Do you have any other things that you still need to review? |
This CL updates the post-toggle event in the following ways: 1. Rename the 'aftertoggle' event to 'toggle'. 2. Rename PopoverToggleEvent to ToggleEvent. 3. Rename the currentState attribute to oldState. 4. Add event coalescing behavior. If two transitions occur before the first 'toggle' event has been fired, cancel the first event and queue a replacement that has oldState === newState. These changes were driven by the corresponding changes to the spec PR: whatwg/html#8717 Bug: 1307772 Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568
Tests: https://wpt.fyi/results/html/semantics/popovers. Additional context: https://open-ui.org/components/popup.research.explainer. Prior PR: whatwg#8221. Closes whatwg#7785.
I rebased this to resolve some merge conflicts with recent focus changes. I also refactored the coalescing to use a shared algorithm. And further addressed a couple nits. (So please pull in those changes before doing more work on this.) While looking around I noticed that the Pointer Events integration has an unresolved comment from @foolip that needs to be addressed as it likely impacts the text in this PR: w3c/pointerevents#460 (review). If that is addressed and my changes look good I think we can land this @josepharhar. I will be out next week, but I'll be around until 7pm UTC+1 today or so. (Also, let me take this opportunity to encourage you to hang out at https://whatwg.org/chat. I'm still behind on GitHub notifications so I might not always notice when something is ready for review. And it's generally nice to be able to chat through certain aspects of a change or proposal.) |
I addressed the pointerevents comment and updated this PR |
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.
@josepharhar thank you so much for your patience and excellent work on getting this feature standardized! May it make many end users (and web developers) happy. 🎉
🎉 Thanks to everyone involved in getting this landed! A PR so large that it broke Github several times. |
This CL updates the post-toggle event in the following ways: 1. Rename the 'aftertoggle' event to 'toggle'. 2. Rename PopoverToggleEvent to ToggleEvent. 3. Rename the currentState attribute to oldState. 4. Add event coalescing behavior. If two transitions occur before the first 'toggle' event has been fired, cancel the first event and queue a replacement that has oldState === newState. These changes were driven by the corresponding changes to the spec PR: whatwg/html#8717 Bug: 1307772 Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568
This CL updates the post-toggle event in the following ways: 1. Rename the 'aftertoggle' event to 'toggle'. 2. Rename PopoverToggleEvent to ToggleEvent. 3. Rename the currentState attribute to oldState. 4. Add event coalescing behavior. If two transitions occur before the first 'toggle' event has been fired, cancel the first event and queue a replacement that has oldState === newState. These changes were driven by the corresponding changes to the spec PR: whatwg/html#8717 Bug: 1307772 Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 Auto-Submit: Mason Freed <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Joey Arhar <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098728}
This CL updates the post-toggle event in the following ways: 1. Rename the 'aftertoggle' event to 'toggle'. 2. Rename PopoverToggleEvent to ToggleEvent. 3. Rename the currentState attribute to oldState. 4. Add event coalescing behavior. If two transitions occur before the first 'toggle' event has been fired, cancel the first event and queue a replacement that has oldState === newState. These changes were driven by the corresponding changes to the spec PR: whatwg/html#8717 Bug: 1307772 Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 Auto-Submit: Mason Freed <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Joey Arhar <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098728}
This reverts commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8. Reason for revert: cause test failures on Linux Tests (dbg) Example failures: https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111061/ https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111062/ Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: I6e466ecffe4726b4ec69ca14704b24842e45f5d6 No-Presubmit: true No-Tree-Checks: true No-Try: true
This reverts commit 2e5ee12. Reason for revert: cause test failures on Linux Tests (dbg) Example failures: https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111061/ https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111062/ Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: I6e466ecffe4726b4ec69ca14704b24842e45f5d6 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205308 Owners-Override: Phillis Tang <[email protected]> Bot-Commit: Rubber Stamper <[email protected]> Commit-Queue: Phillis Tang <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098927}
This reverts commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8. Reason for revert: cause test failures on Linux Tests (dbg) Example failures: https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111061/ https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111062/ Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: I6e466ecffe4726b4ec69ca14704b24842e45f5d6 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205308 Owners-Override: Phillis Tang <[email protected]> Bot-Commit: Rubber Stamper <[email protected]> Commit-Queue: Phillis Tang <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098927}
This reverts commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8. Reason for revert: cause test failures on Linux Tests (dbg) Example failures: https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111061/ https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111062/ Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: I6e466ecffe4726b4ec69ca14704b24842e45f5d6 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205308 Owners-Override: Phillis Tang <[email protected]> Bot-Commit: Rubber Stamper <[email protected]> Commit-Queue: Phillis Tang <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098927}
This is a reland of commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8 It seems that the event coalescing behavior changes cause a segfault in the event dispatch code. This reland (compare to Patchset 1) just includes the event renaming, and not the new behavior. I'll land the new behavior in a separate CL to make it smaller if it gets reverted again. This part should be safe. Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: Iede18bbf05516cec4ee881f1afc663c45380c82e
This is a reland of commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8 It seems that the event coalescing behavior changes cause a segfault in the event dispatch code. This reland (compare to Patchset 1) just includes the event renaming, and not the new behavior. I'll land the new behavior in a separate CL to make it smaller if it gets reverted again. This part should be safe. Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: Iede18bbf05516cec4ee881f1afc663c45380c82e
This is a reland of commit 2e5ee12 It seems that the event coalescing behavior changes cause a segfault in the event dispatch code. This reland (compare to Patchset 1) just includes the event renaming, and not the new behavior. I'll land the new behavior in a separate CL to make it smaller if it gets reverted again. This part should be safe. Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: Iede18bbf05516cec4ee881f1afc663c45380c82e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205710 Reviewed-by: Joey Arhar <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Auto-Submit: Mason Freed <[email protected]> Cr-Commit-Position: refs/heads/main@{#1099397}
This is a reland of commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8 It seems that the event coalescing behavior changes cause a segfault in the event dispatch code. This reland (compare to Patchset 1) just includes the event renaming, and not the new behavior. I'll land the new behavior in a separate CL to make it smaller if it gets reverted again. This part should be safe. Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: Iede18bbf05516cec4ee881f1afc663c45380c82e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205710 Reviewed-by: Joey Arhar <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Auto-Submit: Mason Freed <[email protected]> Cr-Commit-Position: refs/heads/main@{#1099397}
This is a reland of commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8 It seems that the event coalescing behavior changes cause a segfault in the event dispatch code. This reland (compare to Patchset 1) just includes the event renaming, and not the new behavior. I'll land the new behavior in a separate CL to make it smaller if it gets reverted again. This part should be safe. Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: Iede18bbf05516cec4ee881f1afc663c45380c82e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205710 Reviewed-by: Joey Arhar <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Auto-Submit: Mason Freed <[email protected]> Cr-Commit-Position: refs/heads/main@{#1099397}
…and behavior, a=testonly Automatic update from web-platform-tests Update popover post-toggle event naming and behavior This CL updates the post-toggle event in the following ways: 1. Rename the 'aftertoggle' event to 'toggle'. 2. Rename PopoverToggleEvent to ToggleEvent. 3. Rename the currentState attribute to oldState. 4. Add event coalescing behavior. If two transitions occur before the first 'toggle' event has been fired, cancel the first event and queue a replacement that has oldState === newState. These changes were driven by the corresponding changes to the spec PR: whatwg/html#8717 Bug: 1307772 Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 Auto-Submit: Mason Freed <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Joey Arhar <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098728} -- wpt-commits: 2f69c8fe9d5aef171860f20457c97ce008715de1 wpt-pr: 38206
… naming and behavior", a=testonly Automatic update from web-platform-tests Revert "Update popover post-toggle event naming and behavior" This reverts commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8. Reason for revert: cause test failures on Linux Tests (dbg) Example failures: https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111061/ https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111062/ Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: I6e466ecffe4726b4ec69ca14704b24842e45f5d6 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205308 Owners-Override: Phillis Tang <[email protected]> Bot-Commit: Rubber Stamper <[email protected]> Commit-Queue: Phillis Tang <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098927} -- wpt-commits: 938aa51f7b95a331b3c269fa5eb6c8f68b28991d wpt-pr: 38268
… naming and behavior", a=testonly Automatic update from web-platform-tests Reland "Update popover post-toggle event naming and behavior" This is a reland of commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8 It seems that the event coalescing behavior changes cause a segfault in the event dispatch code. This reland (compare to Patchset 1) just includes the event renaming, and not the new behavior. I'll land the new behavior in a separate CL to make it smaller if it gets reverted again. This part should be safe. Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: Iede18bbf05516cec4ee881f1afc663c45380c82e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205710 Reviewed-by: Joey Arhar <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Auto-Submit: Mason Freed <[email protected]> Cr-Commit-Position: refs/heads/main@{#1099397} -- wpt-commits: 1effa5f2e38566fde9acd65c6a92a08cc0d830c3 wpt-pr: 38269
…and behavior, a=testonly Automatic update from web-platform-tests Update popover post-toggle event naming and behavior This CL updates the post-toggle event in the following ways: 1. Rename the 'aftertoggle' event to 'toggle'. 2. Rename PopoverToggleEvent to ToggleEvent. 3. Rename the currentState attribute to oldState. 4. Add event coalescing behavior. If two transitions occur before the first 'toggle' event has been fired, cancel the first event and queue a replacement that has oldState === newState. These changes were driven by the corresponding changes to the spec PR: whatwg/html#8717 Bug: 1307772 Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 Auto-Submit: Mason Freed <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Joey Arhar <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098728} -- wpt-commits: 2f69c8fe9d5aef171860f20457c97ce008715de1 wpt-pr: 38206
… naming and behavior", a=testonly Automatic update from web-platform-tests Revert "Update popover post-toggle event naming and behavior" This reverts commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8. Reason for revert: cause test failures on Linux Tests (dbg) Example failures: https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111061/ https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111062/ Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: I6e466ecffe4726b4ec69ca14704b24842e45f5d6 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205308 Owners-Override: Phillis Tang <[email protected]> Bot-Commit: Rubber Stamper <[email protected]> Commit-Queue: Phillis Tang <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098927} -- wpt-commits: 938aa51f7b95a331b3c269fa5eb6c8f68b28991d wpt-pr: 38268
… naming and behavior", a=testonly Automatic update from web-platform-tests Reland "Update popover post-toggle event naming and behavior" This is a reland of commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8 It seems that the event coalescing behavior changes cause a segfault in the event dispatch code. This reland (compare to Patchset 1) just includes the event renaming, and not the new behavior. I'll land the new behavior in a separate CL to make it smaller if it gets reverted again. This part should be safe. Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: Iede18bbf05516cec4ee881f1afc663c45380c82e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205710 Reviewed-by: Joey Arhar <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Auto-Submit: Mason Freed <[email protected]> Cr-Commit-Position: refs/heads/main@{#1099397} -- wpt-commits: 1effa5f2e38566fde9acd65c6a92a08cc0d830c3 wpt-pr: 38269
This CL updates the post-toggle event in the following ways: 1. Rename the 'aftertoggle' event to 'toggle'. 2. Rename PopoverToggleEvent to ToggleEvent. 3. Rename the currentState attribute to oldState. 4. Add event coalescing behavior. If two transitions occur before the first 'toggle' event has been fired, cancel the first event and queue a replacement that has oldState === newState. These changes were driven by the corresponding changes to the spec PR: whatwg/html#8717 Bug: 1307772 Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 Auto-Submit: Mason Freed <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Joey Arhar <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098728}
This reverts commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8. Reason for revert: cause test failures on Linux Tests (dbg) Example failures: https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111061/ https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111062/ Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: I6e466ecffe4726b4ec69ca14704b24842e45f5d6 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205308 Owners-Override: Phillis Tang <[email protected]> Bot-Commit: Rubber Stamper <[email protected]> Commit-Queue: Phillis Tang <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098927}
This is a reland of commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8 It seems that the event coalescing behavior changes cause a segfault in the event dispatch code. This reland (compare to Patchset 1) just includes the event renaming, and not the new behavior. I'll land the new behavior in a separate CL to make it smaller if it gets reverted again. This part should be safe. Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: Iede18bbf05516cec4ee881f1afc663c45380c82e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205710 Reviewed-by: Joey Arhar <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Auto-Submit: Mason Freed <[email protected]> Cr-Commit-Position: refs/heads/main@{#1099397}
…and behavior, a=testonly Automatic update from web-platform-tests Update popover post-toggle event naming and behavior This CL updates the post-toggle event in the following ways: 1. Rename the 'aftertoggle' event to 'toggle'. 2. Rename PopoverToggleEvent to ToggleEvent. 3. Rename the currentState attribute to oldState. 4. Add event coalescing behavior. If two transitions occur before the first 'toggle' event has been fired, cancel the first event and queue a replacement that has oldState === newState. These changes were driven by the corresponding changes to the spec PR: whatwg/html#8717 Bug: 1307772 Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 Auto-Submit: Mason Freed <[email protected]> Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Joey Arhar <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098728} -- wpt-commits: 2f69c8fe9d5aef171860f20457c97ce008715de1 wpt-pr: 38206
… naming and behavior", a=testonly Automatic update from web-platform-tests Revert "Update popover post-toggle event naming and behavior" This reverts commit 2e5ee120d7fc5df4b6c101e88d03a5f62a73d8b8. Reason for revert: cause test failures on Linux Tests (dbg) Example failures: https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111061/ https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20Tests%20(dbg)(1)/111062/ Original change's description: > Update popover post-toggle event naming and behavior > > This CL updates the post-toggle event in the following ways: > 1. Rename the 'aftertoggle' event to 'toggle'. > 2. Rename PopoverToggleEvent to ToggleEvent. > 3. Rename the currentState attribute to oldState. > 4. Add event coalescing behavior. If two transitions occur before the > first 'toggle' event has been fired, cancel the first event and > queue a replacement that has oldState === newState. > > These changes were driven by the corresponding changes to the spec PR: > whatwg/html#8717 > > Bug: 1307772 > Change-Id: Iabc5a9093d7cef3bbd6e54e488d8e571c51ea568 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4195120 > Auto-Submit: Mason Freed <[email protected]> > Commit-Queue: Joey Arhar <[email protected]> > Reviewed-by: Joey Arhar <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1098728} Bug: 1307772 Change-Id: I6e466ecffe4726b4ec69ca14704b24842e45f5d6 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4205308 Owners-Override: Phillis Tang <[email protected]> Bot-Commit: Rubber Stamper <[email protected]> Commit-Queue: Phillis Tang <[email protected]> Cr-Commit-Position: refs/heads/main@{#1098927} -- wpt-commits: 938aa51f7b95a331b3c269fa5eb6c8f68b28991d wpt-pr: 38268
Previous PR: #8221
Feature proposal issue: #7785
Explainer: https://open-ui.org/components/popup.research.explainer
/browsers.html ( diff )
/dnd.html ( diff )
/dom.html ( diff )
/form-elements.html ( diff )
/index.html ( diff )
/indices.html ( diff )
/infrastructure.html ( diff )
/input.html ( diff )
/interaction.html ( diff )
/interactive-elements.html ( diff )
/rendering.html ( diff )
/semantics-other.html ( diff )
/webappapis.html ( diff )
/popover.html ( diff )