@@ -1786,22 +1786,7 @@ function PullRequestsRouteView() {
17861786 }
17871787 />
17881788 ) ,
1789- titlebarControls :
1790- // While the panel is closed the strip lives inside the header: a no-drag
1791- // descendant beats the header's desktop drag-region, where a floating
1792- // sibling loses (app-region hit-testing ignores z-index). While the
1793- // floating strip crosses the header during motion, the narrow extension
1794- // keeps that overlap non-draggable without moving the toggle.
1795- pullRequestsSupported ? (
1796- rightPanelPresent ? (
1797- < span
1798- aria-hidden
1799- className = "pointer-events-none absolute inset-y-0 left-full w-7 [-webkit-app-region:no-drag]"
1800- />
1801- ) : (
1802- openPanelControls
1803- )
1804- ) : null ,
1789+ titlebarControls : pullRequestsSupported && ! rightPanelPresent ? openPanelControls : null ,
18051790 rightPanelOpen : rightPanelState . isOpen ,
18061791 listBody,
18071792 scrollRef,
@@ -1884,7 +1869,6 @@ function PullRequestsRouteView() {
18841869 return (
18851870 < SidebarInset className = "h-dvh min-h-0 overflow-hidden overscroll-y-none bg-background text-foreground" >
18861871 < div className = "relative flex min-h-0 flex-1" >
1887- { pullRequestsSupported && rightPanelPresent ? openPanelControls : null }
18881872 < PullRequestsColumn { ...columnProps } />
18891873
18901874 { rightPanelPresent && renderedPullRequestSurface && panelEnvironmentId !== null ? (
@@ -1955,6 +1939,10 @@ function PullRequestsRouteView() {
19551939 />
19561940 </ RightPanelTabs >
19571941 ) : null }
1942+ { /* Native drag regions follow layout-tree order, not z-index. Keep the
1943+ actual control's no-drag rectangle after both titlebars, including
1944+ while the panel closes, without putting it in the clipped panel. */ }
1945+ { pullRequestsSupported && rightPanelPresent ? openPanelControls : null }
19581946 </ div >
19591947 </ SidebarInset >
19601948 ) ;
@@ -2213,19 +2201,14 @@ function PullRequestsColumn({
22132201 // Painted flat like the chat column: the inset underneath carries the chrome grain, and a
22142202 // content surface that lets it show reads as a different background than every thread.
22152203 < div className = "@container/pr-list flex min-h-0 min-w-0 flex-1 flex-col bg-background" >
2216- { /* A closed right panel leaves this column full-width, so the shared header
2217- reserves native window controls and hosts the controls strip itself: on
2218- desktop the header is a drag-region, and only a no-drag descendant wins
2219- clicks from it - a floating sibling loses to app-region hit-testing no
2220- matter its z-index. While the panel is open, the strip mounts back at
2221- the route level, whose box spans the panel too, so the toggle keeps one
2222- fixed top-right anchor. */ }
2204+ { /* Keep the closed-panel controls inside this titlebar. The open-panel
2205+ controls mount after both columns at the route level, preserving the
2206+ same top-right anchor while excluding both native drag regions. */ }
22232207 < WorkspacePageHeader
22242208 electron = { isElectron }
22252209 reserveNativeControls = { ! rightPanelOpen }
22262210 className = "relative bg-background"
22272211 >
2228- { titlebarControls }
22292212 { condensed ? (
22302213 < WorkspaceBreadcrumb ariaLabel = "Pull request scope" className = "overflow-hidden" >
22312214 { /* An expanded search owns the scarce horizontal space. The page title stays
@@ -2282,6 +2265,7 @@ function PullRequestsColumn({
22822265 </ div >
22832266 ) : null }
22842267 { rightPanelControl }
2268+ { titlebarControls }
22852269 </ WorkspacePageHeader >
22862270
22872271 < div
0 commit comments