Skip to content

Commit 5de71d7

Browse files
Reset temporary sidebar expansion on toggle
Clear forceExpand when pin/unpin toggles so the sidebar can collapse again after focusing the search field. Prevents the edge case where the panel appears stuck expanded if the user changes pin state while search has focus. No functional UI changes beyond fixing this state leak.
1 parent 4923f35 commit 5de71d7

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/pages/IndependentPanel/App.jsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,8 @@ function App() {
9494

9595
const toggleSidebar = async () => {
9696
const next = !collapsed
97+
// Ensure temporary expansion is cleared when toggling pin state
98+
setForceExpand(false)
9799
setCollapsed(next)
98100
try {
99101
await setUserConfig({ independentPanelCollapsed: next })

0 commit comments

Comments
 (0)