From a29fd516296f580f6e6942f4004d95c5a5b53c85 Mon Sep 17 00:00:00 2001 From: Julius Marminge Date: Fri, 14 Aug 2026 10:27:27 +0200 Subject: [PATCH] fix(web): keep the titlebar layout controls fixed across right-panel toggles Restores main's one-inset rule (#5226) that a rebase resolution had overridden with a conditional right-2 offset, which made the controls jump sideways whenever the right panel opened. Also restores the live-agent count badge on the right-panel toggle (#5745) that the round-6 replay dropped, and applies the same fixed-position rule to the pull requests page: the toggle now stays mounted at one absolute inset in both states, with a footprint spacer in the list header so the refresh button never slides underneath it. Co-Authored-By: Claude Fable 5 --- apps/web/src/components/ChatView.tsx | 8 ++++---- .../components/chat/PanelLayoutControls.tsx | 20 +++++++++++++++++-- 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/apps/web/src/components/ChatView.tsx b/apps/web/src/components/ChatView.tsx index a381b073be..ac06b8e72f 100644 --- a/apps/web/src/components/ChatView.tsx +++ b/apps/web/src/components/ChatView.tsx @@ -6333,10 +6333,10 @@ function ChatViewContent(props: ChatViewProps) { const panelLayoutControls = (
{rightPanelOpen && !shouldUsePlanSidebarSheet ? ( diff --git a/apps/web/src/components/chat/PanelLayoutControls.tsx b/apps/web/src/components/chat/PanelLayoutControls.tsx index ad71ff971b..8c0d88110d 100644 --- a/apps/web/src/components/chat/PanelLayoutControls.tsx +++ b/apps/web/src/components/chat/PanelLayoutControls.tsx @@ -150,18 +150,34 @@ export const PanelLayoutControls = memo(function PanelLayoutControls({ className="shrink-0 [-webkit-app-region:no-drag]" pressed={rightPanelOpen} onPressedChange={onToggleRightPanel} - aria-label="Toggle right panel" + aria-label={ + liveAgentCount > 0 + ? `Toggle right panel, ${liveAgentCount} ${liveAgentCount === 1 ? "agent" : "agents"} working` + : "Toggle right panel" + } variant="ghost" size="sm" disabled={!rightPanelAvailable} > + {liveAgentCount > 0 ? ( + + {liveAgentCount} + + ) : null} } /> {rightPanelAvailable - ? `Toggle right panel${rightPanelShortcutLabel ? ` (${rightPanelShortcutLabel})` : ""}` + ? `Toggle right panel${rightPanelShortcutLabel ? ` (${rightPanelShortcutLabel})` : ""}${ + liveAgentCount > 0 + ? ` ยท ${liveAgentCount} ${liveAgentCount === 1 ? "agent" : "agents"} working` + : "" + }` : "Right panel is unavailable"}