Skip to content

Fix assertion in hide all popovers until #11197

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

Merged
merged 1 commit into from
Apr 23, 2025

Conversation

josepharhar
Copy link
Contributor

@josepharhar josepharhar commented Apr 8, 2025

This PR prevents an assertion from being hit in hide all popovers until by changing the conditions in which hide all popovers until gets called by the hide popover algorithm to use the opened in popover mode instead of looking at the current value of the popover attribute.

Fixes #10996

(See WHATWG Working Mode: Changes for more details.)


/popover.html ( diff )

This PR prevents an assertion from being hit in hide all popovers until
by changing the conditions in which hide all popovers until gets called
by the hide popover algorithm to use the opened in popover mode instead
of looking at the current value of the popover attribute.

Fixes whatwg#10996
Copy link
Member

@domenic domenic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, this looks good to me!

Can you fill out the OP? I think most of it will be N/A, and based on the discussion in #10996 I suspect many tests already cover this code path, but I would like to have that confirmed.

@josepharhar
Copy link
Contributor Author

I verified that the assert gets hit in two tests if I undo this spec change change in chromium. I added them to the OP and filled out the rest. Thanks!

@domenic domenic merged commit 4ae3173 into whatwg:main Apr 23, 2025
2 checks passed
Gingeh added a commit to Gingeh/ladybird that referenced this pull request Apr 23, 2025
tcl3 pushed a commit to LadybirdBrowser/ladybird that referenced this pull request Apr 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: popover The popover attribute and friends
Development

Successfully merging this pull request may close these issues.

Assertion in "hide all popovers until" will fail when changing a showing "hint" popover to "auto"
2 participants