Skip to content

fix(gui): size the composer model picker to its label - #834

Draft
pj991207 wants to merge 1 commit into
andrewyng:mainfrom
pj991207:fix/composer-picker-width
Draft

pj991207 wants to merge 1 commit into
andrewyng:mainfrom
pj991207:fix/composer-picker-width

Conversation

@pj991207

@pj991207 pj991207 commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Draft status

Draft for layout feedback. The spacing change is measured, but its desirability and the value of a geometry regression test need agreement on the intended composer design.

Problem

The composer's model picker reserves 240px even when its label is shorter. With a 1280px fixture window the wrapper is 240px wide and its button 134.4px wide, leaving 105.6px after the label.

Change

Use the intrinsic flex basis with a 240px maximum. Keep shrinking enabled so the send/stop row retains the protection added for #208. The same wrapper now measures 134.4px.

Reproduction

At a 1280px fixture viewport, select the short-label model used by the regression. Compare the picker wrapper and button widths: baseline 240px vs 134.4px; patched both approximately 134.4px.

cd surfaces/gui
npx playwright test e2e/composer-picker-width.spec.ts --workers=1 --retries=0

Validation

The short-label regression fails on 5e3d726 and passes with the fix. All 622 GUI unit tests and 4 Chromium E2E tests pass, covering the width change, send/stop containment at 900/1100px and the existing composer overflow case. Extra probes at 760/640/520px found existing action overflow on both main and this branch; broader responsive layout needs separate work.

Tested PR head: 405734b5a1345d7bddad7245a4958902b780599c. At this documentation update, pytest, gui-unit and gui-e2e all report success for this head: CI run. Local results above are the previously recorded checks; this body update does not claim a new local test run.

Evidence and limitations

Before After
Before After

These captures show the actual Chromium GUI with the same fixture. The change is the reserved space beside a short label; it does not fix the pre-existing narrow-width overflow. The measured gap alone does not establish that the layout should change.

Related work

Retains the shrink behavior protecting the composer actions from #208. No upstream user request or blocked interaction has been established for the short-label spacing.

@pj991207
pj991207 marked this pull request as draft November 3, 2026 10:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant