webviews: the Options chip truncates only when its row is full (chip-fixed-width, agent-pane-no-capsules base reds)
Closed
TE
16d ago+22+22+01234567890123456789-6-6-0123456789
Two webview tests have been red on feat-cmux-next since fe0e57b3e1c (pushed directly to base) added the composer's Options chip. This PR fixes both. Neither has the font or metrics cause that compaction-rows is fixing; both are stylesheet rules the tests read.
| Test | Base failure | Change |
|---|---|---|
chip-fixed-width | composerControls.css .acpmux-options-text => 180px | Code: the Options chip's face no longer stops at 180px. The chip shrinks with its row (flex: 0 1 auto; min-width: 0, button max-width: 100%) and ellipsizes only when the row is full, as #22731 did for the other chips. In the chat bar a more specific rule wins over the bar's > span { overflow: visible } so the face still ellipsizes. |
agent-pane-no-capsules | .acpmux-options .acpmux-picker-button (radius 999px, height 28px) | Test list: the Options chip sits in the same row as the model, effort and access chips, which the test lists as the Claude app's soft pill (#22107). The commit drew it "a quiet pill like the access chip" on purpose, so it joins that list with the reason in the comment. Every other selector is still checked. |
Changelog
- Fixed: the composer's Options chip no longer cuts off its label at a fixed width while the row has room.
Observed / Not run
- Base failures: from react-apps-check on #23034 (run 39553495850) and #20393 (run 39554271195), same messages on both.
scripts/web-lint.sh: clean on these files (the one warning is base'sHistoryPage.tsxjsx-a11y).prepush-gate.py: no new violations.- Not run locally (no tests on this Mac): both files run in this PR's react-apps-check shards.
Agent session: cosmic-gray
🤖 Generated with Claude Code
Need help on this PR? Tag @codesmith-bot with what you need.
Summary by cubic
Fixes two webview tests that went red when the composer's Options chip was added to base.
- The chip's label no longer truncates at a fixed 180px; the chip shrinks with its row and ellipsizes only when the row is full.
- The row counts the chip's whole width first (via a
data-fit-naturalmarker) so label steps occur before the chip gives up any text, and the chip keeps a 56px floor. - The chip joins the
agent-pane-no-capsulespill list alongside the model, effort, and access chips, since it deliberately takes the access chip's shape.