From 027593b3502617dc62bdaa32346225c1d27ae26b Mon Sep 17 00:00:00 2001 From: Mark Date: Thu, 19 Feb 2026 15:42:23 -0800 Subject: [PATCH] Resizable sidebar --- .../workspace/chat-sessions-sidebar.tsx | 6 +- .../components/workspace/profile-switcher.tsx | 77 ++++-- .../workspace/workspace-sidebar.tsx | 95 ++++--- apps/web/app/workspace/page.tsx | 234 ++++++++++++++---- 4 files changed, 290 insertions(+), 122 deletions(-) diff --git a/apps/web/app/components/workspace/chat-sessions-sidebar.tsx b/apps/web/app/components/workspace/chat-sessions-sidebar.tsx index 694785e5a9c..0aa8d09f94d 100644 --- a/apps/web/app/components/workspace/chat-sessions-sidebar.tsx +++ b/apps/web/app/components/workspace/chat-sessions-sidebar.tsx @@ -38,6 +38,8 @@ type ChatSessionsSidebarProps = { mobile?: boolean; /** Close the mobile drawer. */ onClose?: () => void; + /** Fixed width in px when not mobile (overrides default 260). */ + width?: number; }; /** Format a timestamp into a human-readable relative time string. */ @@ -123,6 +125,7 @@ export function ChatSessionsSidebar({ onSelectSubagent, mobile, onClose, + width: widthProp, }: ChatSessionsSidebarProps) { const [hoveredId, setHoveredId] = useState(null); @@ -160,11 +163,12 @@ export function ChatSessionsSidebar({ // Group sessions: today, yesterday, this week, this month, older const grouped = groupSessions(sessions); + const width = mobile ? "280px" : (widthProp ?? 260); const sidebar = (