You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(tab-group): keep a window-drag handle when tabs fill the strip - #33988
You move the Orca window by grabbing its top row. When the side panels are closed and you open lots of tabs, the tabs fill that whole row and there is nowhere left to grab. This keeps a small empty slot next to the tabs so the window can always be grabbed there.
What Changed
TabGroupPanel.tsx: while the right sidebar is closed, the top-right tab strip renders a 40px (w-[40px]) spacer after the tab bar. It uses the same reserveClosedExplorerToggleSpace && !rightSidebarOpen condition as the existing reservation for the floating explorer toggle, and the same 40px width.
The spacer has no -webkit-app-region of its own, so it inherits the strip's drag region. The tab bar wrapper is flex-1 min-w-0, so it gives up 40px and the tab list starts scrolling a little earlier instead of covering the drag area.
New E2E spec tests/e2e/tab-strip-window-drag-handle.spec.ts.
Before: with a full strip, the widest draggable run inside the strip is 9px. After: there is always a run of at least 40px between the "+" button and the action buttons.
Nothing changes when the tabs fit (the slot sits inside whitespace that already exists) or when the right sidebar is open (its header is already a drag area, so the spacer is not rendered).
Why
The strip has [tab list][+][whitespace][actions], and the whitespace is the only part that drags the window. flex-[0_1_auto] lets the tab list take all of it before overflowing, so a full strip leaves no handle near the window controls.
Alternatives considered:
A setting: no reason to make it optional. The cost is 40px of tab-strip width, only while the right sidebar is closed.
Reserving space in every top-edge strip (split layouts): costs tab width in panes that don't need it. One handle at the top-right, where a native title bar is usually grabbed, is enough.
Shrinking tabs or adding a separate title row: bigger visual changes for every user.
Relation to #17425 / #17426 / #27429: those cover the first press being swallowed while a terminal is focused (#6301). This PR does not touch that rule. The new slot inherits the strip's region, so it follows the same focus behavior as the rest of the strip. If #27429 lands, the slot drags on the first press as well. No file overlap with #27429; #17426 also touches TabGroupPanel.tsx, but only the strip's marker attribute a few lines above this change.
Title row with the tab strip full, both sidebars closed, 1280px wide (hidden renderer screenshots). The red box marks the same area in both: before, the tabs push "+" into it and nothing there drags; after, it is the empty drag slot.
Before
After
This is a hit-testing change, so the screenshots only show where the slot is. The table below and the E2E spec measure whether the area is actually draggable.
Measured on main351705b by resolving -webkit-app-region for every pixel column of the title row (terminal not focused):
Scenario
Draggable px before
Draggable px after
Few tabs, sidebars closed
692
692 (identical segments)
Full strip, sidebars closed
84 (widest run in strip: 9)
125 (new 46px run next to "+")
Full strip, both sidebars open
373
373 (spacer not rendered)
Testing
tests/e2e/tab-strip-window-drag-handle.spec.ts fails on main (Expected: >= 40, Received: 9) and passes with this change. Run with ORCA_BACKGROUND_LAUNCH=1 pnpm run test:e2e tests/e2e/tab-strip-window-drag-handle.spec.ts.
Manual, Windows 11: with both sidebars closed and the strip full, the window can't be dragged from the tab row on installed 1.4.239; on this branch (pnpm dev) it drags from the new slot between "+" and the action buttons.
Not tested locally: macOS and Linux. The change is plain flex layout with no platform branch. On macOS, --window-controls-width is 0px (no custom window controls), so the existing reservation shrinks to 40px and the new slot still sits next to the tabs.
I manually tested these changes locally
Automated tests added/updated, or explained why not below
AI Disclosure
Investigated, implemented and tested with Claude Code (Claude Opus 5.5). I verified the drag behavior on Windows 11 myself.
Review
Cross-platform: layout only, no platform-specific code. Windows/Linux window controls and the macOS traffic lights keep their existing reservations.
SSH/remote: renderer chrome only, no runtime or wire changes.
Mobile: N/A, mobile has no window title bar.
Folder workspaces: same tab strip, no git assumptions.
Performance: one static element, rendered only while the right sidebar is closed.
Security: none.
Agent skill upstream boundary
Not applicable, or this change copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.
Notes
Security, cross-platform, SSH/remote, mobile, backwards compatibility and performance are covered under Review above.
Checklist
This PR is small and focused
I explained what changed and why (ELI5, the user-facing before/after, the mechanism, and why over the alternatives)
Before/after screenshots or videos attached for UI changes, or N/A with reason
Self-reviewed for correctness, security, and performance
Cross-platform, SSH/remote, and path/shortcut impact considered (or N/A)
pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass (or CI will cover; local preferred)
When the right sidebar is closed and closed-explorer space is reserved, the panel adds a spacer to the attached tab strip and uses that condition for the no-drag area. An end-to-end test closes both sidebars, overflows the tab strip, and checks that its widest contiguous draggable region is at least 40 pixels.
Severity of issue fixed: Medium
Merge Risk: Low · up to 73360
With the right sidebar closed, a very narrow rightmost split may clip the pane-actions button because of the new 40px drag spacer. This only affects an edge-case layout, so it is mergeable with a small follow-up.
Pre-merge checks: 4
Check name
Status
Explanation
Title check
The title clearly and concisely describes the main change: preserving a window-drag handle when the tab strip is full.
Description check
The description is mostly complete and explains the user impact, implementation, rationale, linked issue, visual proof, testing, platform coverage, and review considerations. The template's explicit R…
Linked Issues check
Issue [#33979] requires a window-drag area when the tab strip overflows, the workspace sidebar is collapsed, and the right sidebar is closed. TabGroupPanel.tsx renders a w-10 shrink-0 spacer when …
Out of Scope Changes check
The changes are limited to the tab-strip layout and an E2E test for the linked drag-handle issue. The spacer uses the existing sidebar condition. The changes do not modify the separate terminal first-…
Full details: Description check
Explanation
The description is mostly complete and explains the user impact, implementation, rationale, linked issue, visual proof, testing, platform coverage, and review considerations. The template's explicit Risk section and Level field are missing, although related risk information appears under Review.
Full details: Linked Issues check
Explanation
Issue [#33979] requires a window-drag area when the tab strip overflows, the workspace sidebar is collapsed, and the right sidebar is closed. TabGroupPanel.tsx renders a w-10 shrink-0 spacer when reserveClosedExplorerToggleSpace && !rightSidebarOpen. The tab bar remains flex-1 min-w-0, so overflow occurs before the spacer. The new E2E test creates 14 tabs, verifies overflow, clears terminal focus, and requires a draggable strip run of at least 40 pixels.
Full details: Out of Scope Changes check
Explanation
The changes are limited to the tab-strip layout and an E2E test for the linked drag-handle issue. The spacer uses the existing sidebar condition. The changes do not modify the separate terminal first-press behavior.
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
When the rightmost split is narrow, the fixed 40px spacer can push the pane-actions button beyond the panel’s clipped edge. Make the spacer adapt to narrow panels while retaining the 40px drag area when space permits.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ELI5
You move the Orca window by grabbing its top row. When the side panels are closed and you open lots of tabs, the tabs fill that whole row and there is nowhere left to grab. This keeps a small empty slot next to the tabs so the window can always be grabbed there.
What Changed
TabGroupPanel.tsx: while the right sidebar is closed, the top-right tab strip renders a 40px (w-[40px]) spacer after the tab bar. It uses the samereserveClosedExplorerToggleSpace && !rightSidebarOpencondition as the existing reservation for the floating explorer toggle, and the same 40px width.-webkit-app-regionof its own, so it inherits the strip's drag region. The tab bar wrapper isflex-1 min-w-0, so it gives up 40px and the tab list starts scrolling a little earlier instead of covering the drag area.tests/e2e/tab-strip-window-drag-handle.spec.ts.Before: with a full strip, the widest draggable run inside the strip is 9px. After: there is always a run of at least 40px between the "+" button and the action buttons.
Nothing changes when the tabs fit (the slot sits inside whitespace that already exists) or when the right sidebar is open (its header is already a drag area, so the spacer is not rendered).
Why
The strip has
[tab list][+][whitespace][actions], and the whitespace is the only part that drags the window.flex-[0_1_auto]lets the tab list take all of it before overflowing, so a full strip leaves no handle near the window controls.Alternatives considered:
Relation to #17425 / #17426 / #27429: those cover the first press being swallowed while a terminal is focused (#6301). This PR does not touch that rule. The new slot inherits the strip's region, so it follows the same focus behavior as the rest of the strip. If #27429 lands, the slot drags on the first press as well. No file overlap with #27429; #17426 also touches
TabGroupPanel.tsx, but only the strip's marker attribute a few lines above this change.Linked Issue
Fixes #33979
Visual Proof
Title row with the tab strip full, both sidebars closed, 1280px wide (hidden renderer screenshots). The red box marks the same area in both: before, the tabs push "+" into it and nothing there drags; after, it is the empty drag slot.
This is a hit-testing change, so the screenshots only show where the slot is. The table below and the E2E spec measure whether the area is actually draggable.
Measured on
main351705b by resolving-webkit-app-regionfor every pixel column of the title row (terminal not focused):Testing
tests/e2e/tab-strip-window-drag-handle.spec.tsfails onmain(Expected: >= 40, Received: 9) and passes with this change. Run withORCA_BACKGROUND_LAUNCH=1 pnpm run test:e2e tests/e2e/tab-strip-window-drag-handle.spec.ts.pnpm check:changed --maxWorkers=2 --base=upstream/main(format, lint, typecheck, affected tests, ratchets): 23/23 checks pass.Manual, Windows 11: with both sidebars closed and the strip full, the window can't be dragged from the tab row on installed 1.4.239; on this branch (
pnpm dev) it drags from the new slot between "+" and the action buttons.Not tested locally: macOS and Linux. The change is plain flex layout with no platform branch. On macOS,
--window-controls-widthis 0px (no custom window controls), so the existing reservation shrinks to 40px and the new slot still sits next to the tabs.I manually tested these changes locally
Automated tests added/updated, or explained why not below
AI Disclosure
Investigated, implemented and tested with Claude Code (Claude Opus 5.5). I verified the drag behavior on Windows 11 myself.
Review
Agent skill upstream boundary
Notes
Security, cross-platform, SSH/remote, mobile, backwards compatibility and performance are covered under Review above.
Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred)