The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
fix(desktop): Hide tabs works again in a zone holding more than one tab
Brooklyn Nicholson2c52945974ad
diff --git a/apps/desktop/src/components/pane-shell/tree/renderer/strip-visibility.ts b/apps/desktop/src/components/pane-shell/tree/renderer/strip-visibility.tsindex e16cef2075c..201d6275893 100644--- a/apps/desktop/src/components/pane-shell/tree/renderer/strip-visibility.ts+++ b/apps/desktop/src/components/pane-shell/tree/renderer/strip-visibility.ts@@ -41,26 +41,37 @@ export interface StripZone {/*** A pane is STRANDED without a strip when the strip is the only thing carrying- * its handle: a closeable tile needs its ✕, a lone tool panel needs a chip to- * grab, hide-only chrome (sessions / Bots) needs the chip that show/hide lives- * on. The uncloseable workspace is not strandable — it cannot be closed or- * lost, so a lone chat is free to be chromeless.+ * its handle: a lone closeable tile needs its ✕, a lone tool panel needs a chip+ * to grab, hide-only chrome (sessions / Bots) needs the chip that show/hide+ * lives on. The uncloseable workspace is not strandable — it cannot be closed+ * or lost, so a lone chat is free to be chromeless.** This outranks an explicit `never` on purpose. "Hide the strip" is a request* about chrome, never a request to make a surface unreachable, and a zone that* answers no gesture at all is not a state any setting should be able to* produce. Hiding still works everywhere it cannot trap you.+ *+ * IT IS THE LAST HANDLE THAT IS PROTECTED, NOT THE PRESENCE OF TABS. A stack+ * of two or more answers tab cycling and ⌘1…⌘9, so hiding its strip costs+ * chrome and no handle. Scoping the tile and tool-panel rungs to a LONE pane is+ * what keeps "Hide tabs" a working command in the zone that actually+ * accumulates tabs: unscoped, one session tab in main pinned the strip on and+ * both the menu row and ⌘⌥T became silent no-ops.*/function stranded(shown: readonly StripPane[]): boolean {- if (shown.some(pane => !pane.uncloseable && pane.placement === 'main')) {+ // Hide-only chrome is stranded at ANY count: it has no close verb at all, and+ // both the chips and the Show/Hide rows that replace one live on the strip.+ if (shown.some(pane => pane.hideOnly)) {return true}- if (shown.some(pane => pane.hideOnly)) {- return true+ if (shown.length !== 1) {+ return false}- return shown.length === 1 && shown[0].collapsePane+ const [only] = shown++ return only.collapsePane || (!only.uncloseable && only.placement === 'main')}export function resolveTabStripVisible(zone: StripZone): boolean {