-
Notifications
You must be signed in to change notification settings - Fork 191
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
[selectmenu] button click behavior when the popup is open #486
Comments
Thanks @luncheon for pointing this out. I agree it would make more sense to match the behavior of The draft at https://open-ui.org/components/select is ambiguous about what the behavior should be, because it depends on whether the button's handling the click or the listbox's light dismiss behavior happens first. The order of these isn't specified. After resolving on the desired behavior we could probably just add a note about which way it should work (and update the prototype accordingly). |
The decision here should probably be generalized to apply to the interaction between |
I think I'm in favor of redefining (or likely just more-carefully defining) the popup light dismiss behavior to not light dismiss if the |
The Open UI Community Group just discussed The full IRC log of that discussion<hdv> Topic: [selectmenu] button click behavior when the popup is open #486<hdv> github: https://github.com//issues/486 <hdv> dandclark: we wanted the behavior if popup is open and you click on a button, we wanted the correct behavior for it to close and stay closed… we want to avoid popups close and open again <hdv> dandclark: the order does matter <JonathanNeal> yay on the previous toggle discussion helping assist this discussion <hdv> masonf: I think we agreed on the behavior for it to toggle… spec wise we'll have to figure out how we do it, both in lightdismiss part of the spec, that clicking on the button is a lightdismiss behavior, agree it is something to spec <hdv> dandclark: sounds good |
Just to highlight the discussion here and on #508: the tentative conclusion we reached is that the default behavior for declaratively invoked popups is for the popup to "toggle". I.e. clicking the button will open the popup if it is currently closed, and close it if it's already open. |
We've now discussed this behavior in even more detail (e.g. see #523). The resolved behavior is that |
Currently, in Chrome Canary, if a
<selectmenu>
's button is clicked when the popup is open, the popup closes while the button is pressed and re-opens when the button is released.open-ui_486.mp4
But I think it is preferable to close the popup on a button click when it is open, like
<select>
. What do you think?(I don't know whether this is a specification or a Chromium implementation.)
The text was updated successfully, but these errors were encountered: