-
Notifications
You must be signed in to change notification settings - Fork 43
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
Unfullscreening unconditionally removes from top layer, ignoring other qualities #222
Comments
Fullscreen explicitly outlaws fullscreening any dialog: https://fullscreen.spec.whatwg.org/#dom-element-requestfullscreen |
Right, I missed that at the time, but the same problem occurs with popovers that are then fullscreened. |
So we discussed other such "interactions" between things that can be in the top layer in multiple ways, here: whatwg/html#9045 The general conclusion/direction seems to be that these things should only be allowed to be in the top layer in one of the ways at a time. So @josepharhar has a PR against fullscreen, I think, to do the above. Is that right? |
Yes, this PR will hide all popovers when making any element fullscreen. So that means that when an open popover is fullscreened, it will have hidePopover called on it before making it fullscreen: #204 |
I suppose that makes sense also - to hide the popovers before going fullscreen. I suppose it's likely that will happen anyway, given that the user must click a button to make something fullscreen, and that'll likely light dismiss the entire popover stack. |
https://fullscreen.spec.whatwg.org/commit-snapshots/a69e295f652ec2b524e8429ecbe7bad61a57be21/#model
This means, for example, if you open a modal dialog, then fullscreen it, then unfullscreen it, it will no longer be in the top layer despite, presumably, still being modal.
Am I missing something? Is a fullscreened element supposed to forget its modalness (and if so, is that actually happening in one of the algos, somewhere I'm missing)? Or do we need to get a little more complex with this?
Assuming we do, I assume it might be something like giving an element a set of "top-layer reasons", and when we clean up the top layer we only remove it when all of its reasons are gone. Fullscreen would just add/remove "fullscreened" from the, modal dialogs would add/remove a "modal" reason, etc.
The text was updated successfully, but these errors were encountered: