-
Notifications
You must be signed in to change notification settings - Fork 577
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
If two modal boxes are opened in order, clicking on the mask layer will cause both modal boxes to be closed simultaneously #1204
Comments
This won't work unfortunately due to a limitation of Headless UI. You have to either nest your modals or close the first modal and open the second one in a timeout equal of the delay of the first modal. Some references: |
Will the switch away from Headless UI resolve this in v3? |
Amazing thank you so much! |
You did this using |
@alayasan This is not Nuxt UI v2 but v3: https://ui3.nuxt.dev/components/modal#nested-modals |
Environment
Version
v3.9.0
Reproduction
https://stackblitz.com/edit/nuxt-ui-7tatth?file=app.vue
Description
Without setting prevent close, if Modal Box 1 and Modal Box 2 are opened in order, clicking on the mask layer will cause both dialog boxes to be closed simultaneously. The correct logic should be to close Modal Box 2 the first time the mask layer is clicked, and Modal Box 1 will only be closed the second time the mask layer is clicked
Additional context
No response
Logs
No response
The text was updated successfully, but these errors were encountered: