From aad9c251646e518641e2b9a7e6d6e30dfca2963c Mon Sep 17 00:00:00 2001 From: Bohdan Triapitsyn Date: Mon, 24 Aug 2026 20:11:18 +0300 Subject: [PATCH] fix(vscode): adjust expanded layout threshold for showing sessions sidebar Keeps enough space for the chat panel when the sessions sidebar stays visible Bases the expanded layout breakpoint on the sidebar width instead of a fixed value --- packages/ui/src/components/layout/VSCodeLayout.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/ui/src/components/layout/VSCodeLayout.tsx b/packages/ui/src/components/layout/VSCodeLayout.tsx index 5ccf8a46..0b81613c 100644 --- a/packages/ui/src/components/layout/VSCodeLayout.tsx +++ b/packages/ui/src/components/layout/VSCodeLayout.tsx @@ -55,10 +55,10 @@ const formatTime = (timestamp: number | null, timeFormatPreference: TimeFormatPr // Width threshold for mobile vs desktop layout in settings const MOBILE_WIDTH_THRESHOLD = 550; -// Width threshold for expanded layout (sidebar + chat side by side) -const EXPANDED_LAYOUT_THRESHOLD = 1400; // Sessions sidebar width in expanded layout const SESSIONS_SIDEBAR_WIDTH = 280; +// Keep enough room for the chat after adding the persistent sessions sidebar. +const EXPANDED_LAYOUT_THRESHOLD = SESSIONS_SIDEBAR_WIDTH + 520; const SESSIONS_SIDEBAR_MIN_WIDTH = Math.round(SESSIONS_SIDEBAR_WIDTH * 0.7); const SESSIONS_SIDEBAR_MAX_WIDTH = 520;