Skip to content
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

[Bug Report][3.3.22] v-menu doesn't close when menu item opens a dialog #18526

Closed
zub0r opened this issue Oct 23, 2023 · 1 comment
Closed

[Bug Report][3.3.22] v-menu doesn't close when menu item opens a dialog #18526

zub0r opened this issue Oct 23, 2023 · 1 comment
Labels
S: stale This issue is untriaged and hasn't seen any activity in at least six months. S: triage

Comments

@zub0r
Copy link

zub0r commented Oct 23, 2023

Environment

Vuetify Version: 3.3.22
Vue Version: 3.3.6
Browsers: Chrome 118.0.0.0
OS: Linux x86_64

Steps to reproduce

  • open the menu and click any menu item to open a dialog
  • close the dialog
  • the menu stays opened

Expected Behavior

the menu closes right after the dialog is opened

Actual Behavior

the menu never closes

Reproduction Link

https://play.vuetifyjs.com/#...

Other comments

In vuetify 2 this could be handled manually by changing menu model value. (#11521)
This is not the case for vuetify 3, because changing the model value closes all nested components, including the dialog.

@hanaTsuk1
Copy link

I modified vuetify in the local environment and it works normally

The following are the factors that affect normal work:
1.dialog's activator (v-list-item) click event called stopPropagation , causing the click event of the menu content (v-list) not to be triggered.

2.Closing the menu will cause the dialog to disappear altogether

Solution:
1.The function of stopPropagation may be to prevent the entire menu from being closed directly after clicking instead of opening the inner menu when nesting multi-layer menus. That is to say, conditions are needed to determine whether to call stopPropagation.
For dialog, my idea is to add "allow-propagation"
Check props.activatorProps["allow-propagation"] when availableEvents onClick

2.menu props eager set to true

@github-actions github-actions bot added the S: stale This issue is untriaged and hasn't seen any activity in at least six months. label May 6, 2024
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale May 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S: stale This issue is untriaged and hasn't seen any activity in at least six months. S: triage
Projects
None yet
Development

No branches or pull requests

2 participants