Skip to content

fix(web): use smaller text in the composer context row - #171

Merged
nixuuu merged 1 commit into
devfrom
fix/composer-row-compact-text
Nov 5, 2026
Merged

nixuuu merged 1 commit into
devfrom
fix/composer-row-compact-text

Conversation

@nixuuu

@nixuuu nixuuu commented Nov 5, 2026

Copy link
Copy Markdown
Member

The pickers under the composer (project, worker, checkout, branch, permission) looked too large and cut names short, e.g. "Pinp…" and "Mac-Studi… · This comp…".

Before After
Text / line height desktop 13/20, phone 14/20 12/16
Icons and chevrons 14 px 12 px
Project mark / initials 18/9 px 16/8 px
Gaps 6 px 4 px
Picker height 32 px 32 px desktop, 40 px phone

Typical names now fit in full ("Pinpoint", "Current checkout", "feat/gpt-plugin"). The model and effort chips and the pickers' menus keep their size. Phone text inputs stay 16 px.

Compared current, 13 px and 12 px with short, typical and long names, at 1440, 768 and 390 px, in light and dark.

Use 12 px labels and icons in the row under the composer, with 4 px gaps and 16 px project marks. Preserve normal menu and model/effort sizing, and keep controls at least 32 px tall on desktop and 40 px on phones or touch screens.

Compared current, 13 px and 12 px controls with short, typical and long names at 1440, 768 and 390 px in light and dark. Checked picker menus, read-only branch labels and worker previews.

Verified: bun install, bun run typecheck, bun run lint, bun run format:check, web build.

Related: #115, #150
@nixuuu
nixuuu merged commit da97129 into dev Nov 5, 2026
9 checks passed
@nixuuu
nixuuu deleted the fix/composer-row-compact-text branch November 5, 2026 12:14
nixuuu added a commit that referenced this pull request Nov 5, 2026
Text and controls were too large in popovers, menus and pickers, and
each screen set its own sizes. This adds one documented scale, applied
through the UI kit.

**The scale** (`docs/ui-scale.md`, linked from AGENTS.md "UI rules")
- Each context has text, row, icon and control sizes for desktop and
phone:
  - content;
  - standard controls (forms, dialogs);
  - settings;
  - compact chrome (sidebar, toolbars);
  - the composer context row;
  - overlays (popovers, menus, pickers, command palette);
  - tooltips.
- Overlays are compact:
  - desktop rows 28 px, 40–44 px on touch;
- buttons `sm` (28 px), checkboxes, switches and search fields one step
smaller;
- user-provided names stay on one line and truncate, with the full name
in a tooltip.
- Typed fields stay 16 px on phones.

**The kit**
- `shared/ui/scale.css` holds the tokens. The standard, chrome and
overlay scopes redefine the text steps for their subtree.
- Popover marks its panel as an overlay; its trigger keeps the parent's
size. DropdownMenu, Select, SearchPicker and HoverCard use Popover, so
they follow. The command palette sets the overlay scope itself, and
Dialog switches back to standard.
- Inside an overlay, Button, ButtonLink and IconButton default to `sm`
unless a size is passed. Checkbox, Switch, SearchField and Input use
their compact sizes.
- New `TruncatedText` component. `clipped` moved into the kit.
- Sidebar density and settings density are folded into the shared tokens
with the same sizes. So are the hand-set sizes from #171 and #172.

**Screens adjusted by hand**
- The project filter: kit search field, one-line rows, a 28 px "Clear
filters" button.
- The model picker and the command palette.
- The worker chip under the composer: "laptop · This computer", with one
separator and no odd gap.

**Unchanged on purpose:** dialogs with forms (connect, add project) keep
the standard size.

Checked before and after for the project filter, model, worker and
thread menus, the command palette, the updates popover, a settings
select, a connect dialog, and the sidebar with the composer. Desktop and
phone, light and dark, long names.
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