Skip to content

feat(app): explore tighter composer layouts - #57320

Draft
kitlangton wants to merge 1 commit into
betafrom
composer-tighter
Draft

kitlangton wants to merge 1 commit into
betafrom
composer-tighter

Conversation

@kitlangton

Copy link
Copy Markdown
Contributor

Exploration for Kit's "why is this composer so big?" note. Draft: the default layout is unchanged (layout defaults to "today", and nothing in the app passes another value). The variants live behind a layout prop on Composer/ComposerEditor so they can be compared in Storybook: OpenCode/Composer/Flow → Layouts (layout × scenario × width) and Layout In Session (with the "7 subagents" chip).

side by side

Today, measured (CSS px, 720px composer)

  • 104px at rest. The editor is min-h-[60px] with pt-4 pb-2 and a 20px line, so 16px of its height has no job. The text line ends at y=36 and the controls start at y=68, a 32px gap. The form also has min-h-[96px].
  • Control row: 44px tall with 28px controls, 8px from the edges. + at x=8, model text at x=51, variant text about 22px after the model chevron. Those gaps are the ghost buttons' 11px padding plus ms-1/gap-1.
  • For reference on Kit's screen: ChatGPT is 82pt with model and effort in one chip ("GPT-6 Astra Medium"). Claude is a 36pt single-row box, with its "Opus 5.5 Medium" chip outside it.

Layouts

Layout Empty height What changes
today 104 Shipped
tight 88 (−16) Drops the 60/96px minimums. Text→controls goes from 32px to 16px, the same as the 16px top inset. No rule changes.
joined 88 (−16) tight, with the variant inside the model chip ("Anthropic / Claude Opus 5.5 High ⌄"). The model dialog already changes the variant with ←/→.
slim 76 (−28) joined with a 12px text inset and 24px controls 8px from the edges. The + glyph sits on the text's 12px spine.
inline 44 (−60) One row at rest (+ · input · chip · send). It becomes joined once the draft wraps or has context, and stays two rows until it is cleared.

Verification

  • bun typecheck (packages/app)
  • One headless capture run of every layout and state (Storybook on pro, via hivemind)
  • Default path: the only changes are a data-layout="today" attribute, two data-slots and a CSS variable whose default is the old 16px value

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant