feat(console): bring the elicitation card back to its design - #1823
Conversation
The card drifted from the design in four places: every question stood a labelled "Other" box open beneath its options, the description sat on its own line under the label, the counter and the primary read as bare "2/3"/"Submit", and a long ask filled the head as a paragraph-long title. A question's box is now disclosed by its own "Other…" chip and closing it drops the draft, so a hidden value is never part of the answer. Literal option chips render in mono, the description rides the label's baseline, "optional" loses its parentheses, the head keeps one line with the rest of the ask as a preamble above the questions, and the row's clock sits at the far edge. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
There was a problem hiding this comment.
Reviewed revision 305ef8e. No blocking regressions found. The “Other…” toggle clears hidden drafts while preserving option selections, and the existing answer validation remains intact.
Validation: all 26 elicitation tests passed; web typecheck, ESLint, and Prettier checks passed.
sent by review-bot (Codex · gpt-6-astra) · open in session
Read from the canvas source (Webchat Elicitation.dc.html): a question whose options are sentences is not a chip row there. One option past ~22 characters turns the whole question into full-width rows — a radio-style indicator, the label wrapping at 1.45 — so no answer is truncated away and the options stay comparable by being shaped alike. A chip row that has to shrink its own options is the failure this avoids. Chips and rows are now one control: `ElicitOption` renders either shape, marks a held pick only where the card actually holds one (a single-choice card answers on the tap), and gives the "Other…" affordance the soft accent the design uses for an option the agent never offered. A chips question's box is a narrow mono literal, a row question's spans the list, and the head wears the design's message-square-dot. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
Read the canvas source this was drawn from (
Two deliberate deviations from the canvas, both because the wire disagrees with it:
|
There was a problem hiding this comment.
Reviewed updated revision 54ddc45, including the long-option row layout and shared option component. No blocking regressions found; selection limits, submission behavior, and clearing hidden custom answers remain intact.
Validation: all 26 elicitation tests passed; web typecheck, ESLint, and Prettier checks passed.
sent by review-bot (Codex · gpt-6-astra) · open in session
|
Both deviations preserve the existing answer contract: blank optional fields are omitted, and a required selection can accompany custom text. My approval of sent by |
The webchat elicitation card (#1816, #1817) had drifted from the design it was drawn from. Four things read wrong on a real AskUserQuestion form:
Otherbox open beneath its options, so a three-question form was mostly empty inputs2/3/Submit, with no clockWhat changed
Other…chip. Opening it discloses the input; closing it drops the draft, so a value the reader can no longer see is never part of the answer. A box the schema handed a default opens showing it.optionalloses its parentheses;requiredkeeps the brand color.2/3 answered, and the row's own clock sits at the far edge.Submit answers(a single-value card still saysSubmit).Not adopted from the design
The design's footer reads
Blank optional answers are sent as null, but the implementation omits an untouched optional field entirely rather than sending null —formAnswerbuilds the record that way and the daemon accepts it. The truthfulOptional answers left blank are not sentstays; changing it would mean changing the answer semantics, not the copy.Tests
SessionDetailView.elicitation.test.tsxfollows the new interaction (it opens a question's box before typing) and gains one case: closing the box drops the draft, and the card then answers with the options alone. 74 passed across theSessionDetailView*files; typecheck, prettier and eslint clean.🤖 Generated with Claude Code