From d57927f3bbb5eb54b9cd95a6864fad1b69a72f4c Mon Sep 17 00:00:00 2001 From: Brooklyn Nicholson Date: Sat, 8 Aug 2026 01:45:02 -0500 Subject: [PATCH] fix(desktop): stop the composer's two collapse stages landing together MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The model pill shed its label at 440px and the row stacked at almost the same width, so the chevron bought nothing — which is the one thing a progressive collapse is meant to avoid. Sized off what the controls actually cost rather than a guess. With the full pill they take ~284px, so at 440 the inline input was ~156px against a 128px minimum: a few words wrapped, and wrapping is what stacks the row. Compacting at 560 sheds the label while the input still has ~276px, and spends the ~110px the chevron frees on keeping the row single for another stretch. Global, not HUD-only. --- .../src/app/chat/composer/composer-utils.ts | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/apps/desktop/src/app/chat/composer/composer-utils.ts b/apps/desktop/src/app/chat/composer/composer-utils.ts index 21e3c1ac4a..617e650511 100644 --- a/apps/desktop/src/app/chat/composer/composer-utils.ts +++ b/apps/desktop/src/app/chat/composer/composer-utils.ts @@ -9,10 +9,18 @@ import type { TriggerState } from './text-utils' export const COMPOSER_STACK_BREAKPOINT_PX = 320 // Above the stack breakpoint but still cramped: the model pill sheds its label -// for its chevron icon (freeing ~120px) so the controls stop crowding the input -// before the whole row has to stack. Progressive collapse: full pill → icon -// pill → stacked. -export const COMPOSER_COMPACT_PILL_PX = 440 +// for its chevron icon so the controls stop crowding the input before the whole +// row has to stack. Progressive collapse: full pill → icon pill → stacked. +// +// Sized off what the controls actually cost, because guessing put the two +// stages on top of each other. With the full pill the controls take ~284px +// (pill 111 + the icon cluster), so at the old 440 the inline input was ~156px +// — barely over its 128px minimum. A few words wrapped, wrapping is what +// stacks the row, and the pill's chevron arrived at the same moment the row +// gave up, which is the one thing progressive collapse is supposed to avoid. +// At 560 the label goes while the input still has ~276px, and the ~110px the +// chevron frees is spent keeping the row single for another stretch. +export const COMPOSER_COMPACT_PILL_PX = 560 // A single editor line is ~28px (--composer-input-min-height 1.625rem + 0.5rem // vertical padding). Anything taller means the text wrapped to a second line,