-
Notifications
You must be signed in to change notification settings - Fork 211
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
[Overlay] Close Active-Overlay on right mouse click or contextmenu event #1559
Comments
Steps:
Can you share some expanded use cases here? I'm not sure that's a default functionality that we want to add. It may be that this needs to be a configuration option, or we need to outline how to do this easily in user space, but I can't quite tell from the information currently available. |
Yes, our use case is a @contextmenu event triggers a contextmenu to render via an VirtualTrigger:
If we then right click outside the menu this overlay should be closed and another menu should be triggered. |
Looking into this a bit closer, and want some information on step 3 above. Is closing an Overlay enough? As I build up some test contexts to develop against, it seems like the desire in the context of a Closing on right click, and only when it's not in the Overlay content, is relatively straight forward, but there's a good bit more infrastructure to get subsequent context menus to open... |
@Westbrook The optimal behaviour would be to open a subsequent menu on the second right-click, like you said. But as a short term improvement I would also appreciate just closing the previous overlay on an outside right-click. |
Expected Behaviour
When an active overlay is open the user can (left) click outside the popover content to close it while a right mouse click (or contextmenu event) would not close the overlay.
Actual Behaviour
Right mouse click outside popover content doesn't trigger the active overlay to close.
Reproduce Scenario (including but not limited to)
Steps to Reproduce
Platform and Version
MacOS, Chrome V91
Sample Code that illustrates the problem
Logs taken while reproducing problem
The text was updated successfully, but these errors were encountered: