Skip to content

feat(items): one-row reply box with the actions inline - #49439

Merged
orca-remote-automation[bot] merged 6 commits into
mainfrom
ux/reply-box-one-row
Nov 26, 2026
Merged

orca-remote-automation[bot] merged 6 commits into
mainfrom
ux/reply-box-one-row

Conversation

@orca-remote-automation

@orca-remote-automation orca-remote-automation Bot commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

ELI5

The reply box under an agent's question was tall: the question chip, then four empty lines, then a row of buttons. It now starts as one row, with the buttons beside the text, and grows only as you type.

Files Added Deleted Net
Test 0 0 0 0
Prod 8 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​275 $\color{#cf222e}{\Huge{\mathbf{−}}}$​69 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​206

What Changed

  • While an agent's question waits, the comment box opens on one row: + on the left of the text, then the N / M counter with its arrows, then mic and send on the right. With the chip it is 76px tall (the same fixture on main is 167px).
  • Placeholder is now "Reply or pick an option" (en, zh and tr shortened).
  • The text grows up to six lines, then scrolls. Once it wraps past one line, or the pane is narrower than 520px, or a question's placeholder ("Reply or pick an option", "Reply to …") would be cut beside the controls, the text takes the full width and the buttons drop to the row below it (+ left, counter, arrows, mic and send right).
  • Alignment: the chip's edges sit on the + and send buttons' edges, its dot on the + column and its × on the send column. When the text has its own row it starts on that same left edge, and so do attached image thumbnails (inset 2px so the first one's focus ring still shows). The arrows now center on + and send; on main they sat 4px low. They also sit exactly where the arrows do in the no-box placeholder row (main was 2px/6px off).
  • Padding 6→8px, text 14→13px, chip 24→22px.
  • Mechanism: useBotItemCommentStacked loses its "tall" reply mode (four lines minimum, eleven max). Replies use the same one-row-then-stack rule as every comment. A container query on the item pane stacks narrow panes; the placeholder is measured in the editor's own font against the room beside the controls (read while the text sits there, so stacking never feeds back; a box that opens stacked tries one row once there is room), and stacks the box rather than falling back to "Add a comment…". The arrows get a wrapper that keeps their own width beside the text and takes the free space on their own row.
  • Same box, so ordinary comments (no question waiting) get the same layout, minus the chip.

Why

The tall default took vertical space from the Activity feed while the answer is usually one line. This is the approved layout of the options that were mocked up. Checked against how comparable products handle this: a one-line default that grows as you type, with actions inline. Alternatives considered: keep a separate button row under a one-line input (two rows by default), or hide the chip (loses which question you are answering).

Linked Issue

N/A: maintainer change, no pre-existing issue.

Visual Proof

Component fixtures (bots/items/BotItemStepper:ask*), 2x, both themes, isolated fixture data.

Before / after (167px → 76px):

wide

Narrow panes stack:

narrow

Break at 520px: 519px stacked, 520px inline, and at 520px with 3- and 4-digit counters the placeholder still fits:

break

Turkish and Chinese at 440, 480 and 520px:

locales

Attached image while replying: chip, thumbnail and text share one left edge. Plus the plain box stacked in a narrow pane:

image

Question without quick replies ("Reply to …", long bot name) in en/tr/zh at 520-760px: it stays one row where the placeholder fits and stacks where it would cut:

open

Long text: full width with the buttons below, capped at six lines, then it scrolls:

long

Measured in the DOM: dot center x 53 = + icon center x 53 (all widths); in a 340px pane chip right 335 = send right 335 and × center x 319 = send center x 319 (a question line that fits whole keeps the chip hugging its text); + / arrows / send centers share one y (75 inline at 560px, 109 stacked at 340px). Stacked text left 37 = chip left 37 = image thumbnail left 37 = + button left 37.

Testing

  • I manually tested these changes locally (component fixtures, light and dark, widths 220 to 560, en/zh/tr, 2-4 digit counters, attached image, empty, long and over-cap text, DOM measurements as above)
  • Automated tests added/updated, or explained why not below: layout and styling only. Per repo rules, this gets visual proof rather than a unit test. New fixtures cover the reply states.
  • Every added test fails without this change and avoids the test anti-patterns (no tests added)

pnpm check:changed passes (31/31). Platforms: renderer-only CSS/layout, checked on macOS.

Performance

Negligible. While a question waits, one ResizeObserver per open item pane measures the placeholder (one hidden span laid out per box resize, not per keystroke). The existing line-wrap observer now also runs for an empty reply box.

Risk

Layout of the item comment box only. The riskiest part is the 520px container-query break: a pane right at 520px shows a ~220px text field beside the controls. No data, settings, IPC or remote behavior is touched. Back out with a plain revert.

Level: Low

Agent skill upstream boundary

  • Not applicable, or this change copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

Notes

Cross-platform: CSS only, no platform branches. Touch pointers keep their larger hit targets (the arrow wrapper follows the 44px button height). Remote/SSH and mobile: no change to data paths. Folder workspaces: unaffected.

In very narrow panes (roughly 240-440px depending on language and bot name) even the text's own row cannot fit a question's placeholder, so it falls back to "Add a comment…", as before.

Checklist

  • This PR is small and focused
  • I explained what changed and why (ELI5, the user-facing before/after, the mechanism, and why over the alternatives)
  • I stated the risk: what could break, for whom, and how to back it out
  • Before/after screenshots or videos attached for UI changes, or N/A with reason
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote, and path/shortcut impact considered (or N/A)
  • pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass (or CI will cover; local preferred)

@orca-remote-automation

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

@orca-remote-automation
orca-remote-automation Bot force-pushed the ux/reply-box-one-row branch 2 times, most recently from b85da2e to 7dce9c8 Compare November 26, 2026 07:07
@orca-remote-automation
orca-remote-automation Bot merged commit 284bf84 into main Nov 26, 2026
55 of 56 checks passed
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.

0 participants