Closed
Description
π Bug report
Calling api.collapse()
causes an error to be thrown.
π₯ Steps to reproduce
- Go to the tree view component
- Click on Collapse All
- See error
π» Link to reproduction
This bug is reproducible in production
https://zagjs.com/components/react/tree-view
https://stackblitz.com/run?file=src%2FApp.tsx,src%2FTreeView.tsx&showSidebar=0
π§ Expected behavior
If no nodes are expanded nothing should happen. If any nodes are expanded all should be collapsed.
π§ Possible Solution
Looks like the error is thrown here:
And may be related to:
#2512
π System information
Software | Version(s) |
---|---|
Zag Version | 1.15.7 |
Browser | Chrome |
Operating System | MacOS 15.5 |
Metadata
Metadata
Assignees
Labels
No labels