From 055e31f82ea948896c1654fc15d77970b74084be Mon Sep 17 00:00:00 2001 From: Shaojin Wen Date: Tue, 7 Jul 2026 20:05:09 +0800 Subject: [PATCH 1/3] fix(web-shell): remove meaningless "current" badge from split-view panes In the split view every pane is an equal, independently interactive session (its own DaemonSessionProvider, SSE, transcript, and approvals), so tagging one pane as the workspace's "current" session carried no operational meaning. It only leaked a single-view concept into a peer-of-equals layout and reliably prompted "what is this?" questions from users. Panes are already identified by their titles. Drop the isCurrent badge and its border highlight from ChatPane, and stop passing isCurrent from SplitView. The sidebar and session overview keep their "current" indicators, which are legitimate "you are here" navigation. currentSessionId is retained only to seed the initial pane. --- .../client/components/ChatPane.module.css | 14 ----------- .../web-shell/client/components/ChatPane.tsx | 17 ++++---------- .../client/components/SplitView.test.tsx | 23 ++++++++----------- .../web-shell/client/components/SplitView.tsx | 6 ++--- 4 files changed, 16 insertions(+), 44 deletions(-) diff --git a/packages/web-shell/client/components/ChatPane.module.css b/packages/web-shell/client/components/ChatPane.module.css index 9e502a92127..b08a96e10fe 100644 --- a/packages/web-shell/client/components/ChatPane.module.css +++ b/packages/web-shell/client/components/ChatPane.module.css @@ -10,10 +10,6 @@ overflow: hidden; } -.paneCurrent { - border-color: color-mix(in srgb, var(--primary) 60%, var(--border)); -} - .header { display: flex; align-items: center; @@ -52,16 +48,6 @@ color: var(--foreground); } -.currentBadge { - flex: 0 0 auto; - padding: 1px 7px; - border-radius: 999px; - font-size: 11px; - font-weight: 600; - color: var(--primary); - background: color-mix(in srgb, var(--primary) 14%, transparent); -} - .closeButton { flex: 0 0 auto; display: inline-flex; diff --git a/packages/web-shell/client/components/ChatPane.tsx b/packages/web-shell/client/components/ChatPane.tsx index f7f7e1c1390..7a4afb0ab31 100644 --- a/packages/web-shell/client/components/ChatPane.tsx +++ b/packages/web-shell/client/components/ChatPane.tsx @@ -30,8 +30,6 @@ const EMPTY_TOOLBAR: never[] = []; export interface ChatPaneProps { /** Header label; falls back to the session's own display name / id. */ title?: string; - /** Marks the pane bound to the window's primary (sidebar-selected) session. */ - isCurrent?: boolean; onClose?: () => void; onError?: (error: unknown, fallback: string) => void; } @@ -43,7 +41,7 @@ export interface ChatPaneProps { * state, approvals, and composer, and the browser scopes keyboard focus to the * pane the user clicks into — so there is no cross-pane approval arbitration. */ -export function ChatPane({ title, isCurrent, onClose, onError }: ChatPaneProps) { +export function ChatPane({ title, onClose, onError }: ChatPaneProps) { const { t } = useI18n(); const connection = useConnection(); const actions = useActions(); @@ -119,7 +117,9 @@ export function ChatPane({ title, isCurrent, onClose, onError }: ChatPaneProps) const handleCancel = useCallback(() => { actions .cancel() - .catch((error: unknown) => reportError(error, 'Failed to cancel request')); + .catch((error: unknown) => + reportError(error, 'Failed to cancel request'), + ); }, [actions, reportError]); const headerLabel = @@ -127,9 +127,7 @@ export function ChatPane({ title, isCurrent, onClose, onError }: ChatPaneProps) return (
@@ -137,11 +135,6 @@ export function ChatPane({ title, isCurrent, onClose, onError }: ChatPaneProps) {headerLabel} - {isCurrent && ( - - {t('sessionsOverview.current')} - - )} {onClose && (