[dialog] Removing a closed nested dialog from the tree increments parent's nested open dialog count #1279
Labels
bug 🐛
Something doesn't work
component: dialog
This is the name of the generic UI component, not the React module!
Bug report
Current behavior
When you are in a dialog and for whatever reason a nested dialog that isn't open yet is removed from the tree, the parent dialog will set
--nested-dialogs
to1
despite no nested dialog being open.Expected behavior
Removing a nested dialog doesn't affect its parent.
Reproducible example
https://codesandbox.io/p/sandbox/friendly-maria-ctqgff?file=%2Fsrc%2FApp.tsx%3A20%2C32
Base UI version
v1.0.0 alpha 4
Which browser are you using?
Edge 131
Which OS are you using?
Windows 11 24H2
Which assistive tech are you using (if applicable)?
N/A
Additional context
N/A
The text was updated successfully, but these errors were encountered: