This repository was archived by the owner on Jun 28, 2026. It is now read-only.
This repository was archived by the owner on Jun 28, 2026. It is now read-only.
SplitterPanel: size property doesn't take effect after the drag event fired #6016
Closed as not planned
Describe the bug
I have a requirement of using toggle feature in SplitterPanel to set it expanded and collapsed mode. Let's say when the left SplitterPanel is collapsed it's size is 4 and 35 when expanded. This works fine with useState until I don't use the splitter to drag. After the drag event the toggle mode doesn't work. Though it set's the sizes state correctly.
Reproducer
https://stackblitz.com/edit/mb76rz?file=src%2FApp.jsx
PrimeReact version
^10.1.1
React version
18.x
Language
ES6
Build / Runtime
Create React App (CRA)
Browser(s)
Chrome, Safari
Steps to reproduce the behavior
Use this link stackblitz to see the issue
https://stackblitz.com/edit/mb76rz?file=src%2FApp.jsx
Expected behavior
The collapse/expand feature should work after drag also