fix: zooming inside a parent dialog that has a close handler #798
+17
−1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Closes #746
I added all the deps from https://stackblitz.com/edit/vitejs-vite-djxwwz?file=src%2FApp.tsx,package.json and set up a Storybook demo that recreated the issue. I then tried a few things and realized that the zoom component's
<dialog>
'sclose
event firing was what was causing the issue with this specific library, so stopping ourclose
event propagation is the fix here.