From 687cfb8e8b77291828621408de77a4b0ba885121 Mon Sep 17 00:00:00 2001 From: JJ Lee Date: Mon, 7 Sep 2026 01:29:12 -0400 Subject: [PATCH] fix(app): tighten side-panel right-edge gap MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Three changes that together reduce the visible right-side gap: 1. panelRow padding: p-2 (8px all sides) → px-1.5 py-2 (6px horizontal, 8px vertical) + gap-2 → gap-1.5. The 8px inset was visually amplified on the right because macOS traffic lights fill the left edge above the content, while nothing fills the right. Tightening the horizontal inset brings the panels closer to the window edges on both sides. 2. DEFAULT_PANEL_COLUMN_WIDTH: 320 → 330 to match WORK_COLUMN_WIDTH_MIN. The work column container used clampWorkColumnWidth (floor 330) but the side panel aside used the raw stored width (320), leaving a 10px transparent gap inside the container. 3. floorPanelColumnWidth helper: the side panel's panelWidth() memo now floors at WORK_COLUMN_WIDTH_MIN so existing stored widths below 330 can't reintroduce the mismatch. sessionPanelAvailable gap subtraction updated 8 → 6 to match the new gap-1.5. --- packages/app/src/context/layout.tsx | 5 ++++- packages/app/src/pages/session.tsx | 4 ++-- .../pages/session/session-panel-width.test.ts | 16 ++++++++++++++++ .../app/src/pages/session/session-panel-width.ts | 9 +++++++++ .../app/src/pages/session/session-side-panel.tsx | 7 +++++-- 5 files changed, 36 insertions(+), 5 deletions(-) diff --git a/packages/app/src/context/layout.tsx b/packages/app/src/context/layout.tsx index 2a17460fe7..3c7144ed87 100644 --- a/packages/app/src/context/layout.tsx +++ b/packages/app/src/context/layout.tsx @@ -32,7 +32,10 @@ const DEFAULT_FILE_TREE_WIDTH = 200 // amicode#105: single-pane Work Column — it no longer hosts the review // panel's two-pane split, so it doesn't need the old 400px. Resize handle // retained; persisted widths still override this default. -const DEFAULT_PANEL_COLUMN_WIDTH = 320 +// Must be >= WORK_COLUMN_WIDTH_MIN (330) so the default never triggers the +// floor in clampWorkColumnWidth, which would make the container wider than +// the side panel's