From 9d5e632d4d41ca3f6932506255134dc297ba0278 Mon Sep 17 00:00:00 2001 From: Julius Marminge Date: Mon, 15 Jun 2026 16:05:36 -0700 Subject: [PATCH] Tighten workspace control spacing in the header - Align header controls with the 12px right inset - Use a smaller control offset in window controls overlay mode --- apps/web/src/components/ChatView.browser.tsx | 2 ++ apps/web/src/index.css | 10 ++-------- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/apps/web/src/components/ChatView.browser.tsx b/apps/web/src/components/ChatView.browser.tsx index 0ef7764325194cfe7775ceb871cbd1934120c23c..f576a47329afff6d67adc26f831b5a591f8723a1 100644 --- a/apps/web/src/components/ChatView.browser.tsx +++ b/apps/web/src/components/ChatView.browser.tsx @@ -2151,6 +2151,7 @@ describe("ChatView timeline estimator parity (full app)", () => { ).toBe("no-drag"); expect(chatHeader.classList.contains("drag-region")).toBe(false); expect(chatHeader.contains(panelLayoutControls)).toBe(true); + expect(window.innerWidth - panelLayoutControls.getBoundingClientRect().right).toBe(12); const initialTerminalRect = terminalToggle.getBoundingClientRect(); const initialRightPanelRect = rightPanelToggle.getBoundingClientRect(); const initialControlRects = [initialTerminalRect, initialRightPanelRect]; @@ -2172,6 +2173,7 @@ describe("ChatView timeline estimator parity (full app)", () => { expect(panelLayoutControls.getBoundingClientRect().top).toBe( chatHeader.getBoundingClientRect().top, ); + expect(window.innerWidth - panelLayoutControls.getBoundingClientRect().right).toBe(12); document.documentElement.classList.remove("wco"); rightPanelToggle.click(); diff --git a/apps/web/src/index.css b/apps/web/src/index.css index e9d2b50275a60f9478615f3de6e8cf6cd7e03c79..9048e2074ed0d15d610c233f2a73646c6ab00bdb 100644 --- a/apps/web/src/index.css +++ b/apps/web/src/index.css @@ -11,20 +11,14 @@ --workspace-native-controls-inset: 0px; } -@media (width >= 40rem) { - :root { - --workspace-controls-right: calc(env(safe-area-inset-right) + 1.25rem); - } -} - .wco { --workspace-topbar-height: env(titlebar-area-height, 52px); --workspace-controls-top: env(titlebar-area-y, 0px); --workspace-controls-right: calc( - 100vw - env(titlebar-area-width, 100vw) - env(titlebar-area-x, 0px) + 1em + 100vw - env(titlebar-area-width, 100vw) - env(titlebar-area-x, 0px) + 0.75rem ); --workspace-native-controls-inset: calc( - 100vw - env(titlebar-area-width, 100vw) - env(titlebar-area-x, 0px) + 1em + 100vw - env(titlebar-area-width, 100vw) - env(titlebar-area-x, 0px) + 0.75rem ); } -- 2.54.0