Repository navigation
Description
Context
Part of #3690. #3692 shipped MicButton (packages/ui-kit/src/voice/MicButton.tsx:50) and VoiceField (packages/ui-kit/src/voice/VoiceField.tsx:52) with signed-off stories. Every story that draws the mic at rest or in review places it in a bare compact VoiceField: D1 (packages/ui-kit/stories/voice/_voice.tsx:78), D6 (_voice.tsx:100), S1 (_voice.tsx:143) and L10. That field holds only a placeholder or static words, the mic and, in D6, Send. The mockups on #3690 draw the same simplified field and caption D6 "back to a normal composer with Send".
The app's resting composer is not that field. It is the kit Composer (packages/ui-react/src/components/chat/composer-view.tsx:279), which draws the attach-menu trigger, an editable textarea, its own 28px mic IconButton (packages/ui-kit/src/chrome/Composer.tsx:332), the provider chip and hint line, and Send or Stop. Composer takes no caller-supplied control in the mic position, so MicButton cannot be placed there without a kit change. MicButton is also a 44px button with a 36px raised disc (packages/ui-kit/src/tokens.css:2832), while the composer field is drawn around 28px targets with 8px 10px padding (Composer.tsx:242). Its hint and "Talk live…" bubbles are positioned above the mic (tokens.css:2839).
No signed-off story shows MicButton inside the real composer. #3693 (hold the mic to open Start) and the D1/D6 states of #3694 cannot be wired with the components unchanged and no new visual design until this composition is designed and the kit can host it.
Scope
- Design how
MicButtonsits in the resting composer beside the attach trigger, the editable textarea, the provider chip and hint line, and Send or Stop, at 320px and desktop widths in both themes. This includes the S1 hold state with its ring and the "Keep holding to talk live" hint, and the focused "Talk live…" action. - Design the D6 review composer: the editable dictated text with Send, and the mic ("Dictate more"). Say whether an uncertain-word mark can appear while the text stays editable, or whether D6 shows no mark in an editable field.
- After sign-off, an additive kit
Composerchange that renders the caller'sMicButtonin the mic position, with stories and per-state visual baselines for D1, S1 and D6 in the real composer.
Out of scope
- Any change to
MicButton,VoiceFieldor the other ui-kit: voice components and stories for every dictation, Start and live state #3692 components beyond what the design rules. - The hold gesture, the dictation state mapping and the live entry. Those are ui-react: wire the composer mic — tap to dictate, hold to start a live conversation #3693 and ui-react: wire dictation (D1–D8) to the voice field components #3694.
- The Start card (ui-react: wire the Start card (S1–S5) — service, persona and recovery #3698) and the live panel (ui-react: wire live conversation (L1–L10) to the tall voice field #3699).
Acceptance criteria
- A design ruling is recorded on this issue, with drawings at 320px and desktop, covering D1, S1, the focused "Talk live…" action and D6 in the real composer, including the local-recording mic ("Record on this device", ui-react: open the microphone for local recording without a server voice session #1012).
- The kit
Composercan render a caller-supplied mic control. Without one, it renders exactly as before, proven by unchanged existing baselines. - Stories and baselines exist for the resting composer with
MicButton(idle, holding with hint, focused "Talk live…") and for D6 review, in both themes at 320px and desktop. - The package-api contract component and the API report record the new prop.
Verification
Visual baselines from the pinned container. A story play test proves the composer row does not overflow at 320px with the hint showing.
Contract impact
Additive: one new optional kit Composer prop, recorded in the package-api contract component in the same commit.
Design prompt
Read first:
- Epic #3690 (direction 3a, rulings V1-V5) and #3692 (the signed-off voice components).
- packages/ui-kit/src/voice/MicButton.tsx:50 and packages/ui-kit/src/tokens.css:2831-2843 (44px mic, 36px disc, hint and Talk live positions).
- packages/ui-kit/stories/voice/_voice.tsx:78 (D1), :100 (D6), :143 (S1): the mic only ever appears in a bare VoiceField.
- packages/ui-kit/src/chrome/Composer.tsx:230-243 (field box) and :332 (today's 28px mic IconButton).
- packages/ui-react/src/components/chat/composer-view.tsx:279 (the real composer: attach menu, textarea, provider chip, hint line, send/stop).
- docs/decisions/design-kit/navigation.md (D37: the composer is kit-owned; capture is a menu behind the paperclip).
- docs/decisions/live-conversation.md and docs/decisions/voice-permission.md (nothing is captured during a hold; approvals are never by voice).
Problem: the signed-off voice stories draw the resting composer as "Message + mic". The real composer also has an attach trigger, an editable multi-line textarea, a provider chip and hint line, and Send or Stop. The 44px raised MicButton has never been drawn inside it.
Design:
1. Where MicButton sits in the composer field, and whether the field grows from today's height to fit a 44px target or the mic sits outside the field. Draw it at 320px and desktop.
2. Where the "Keep holding to talk live" hint and the focused "Talk live…" action appear when the provider chip and hint line are present.
3. D6 review: the dictated words are editable in the textarea. Decide whether an uncertain word is marked in an editable field, or whether D6 shows no mark there.
4. The local-recording mic ("Record on this device", used when the host is unreachable): does it use MicButton with no hold, or keep today's control?
Requirements to hold: no change to MicButton's own visuals unless ruled here; 320px with no horizontal overflow; 44px touch targets; accessible names "Dictate" and "Talk live…"; amber is you and your mic, teal is brain; no capture during a hold.
Deliverable: ASCII or image mocks at 320px and desktop for D1, S1, focused Talk live and D6 in the real composer, and the kit prop shape. The hold ring itself is settled (V1, V4) and stays.
Decisions (maintainer, 2026-11-08)
- M1: the offline "Record on this device" mic has no hold. It is a
MicButtonwith no hint and no "Talk live…", and a hold acts as a tap. V4 (the ring fills, then explains) applies only while the host is reachable. - M2: D6 shows no honesty cue in the editable composer: no uncertain-word mark and no hint line. The dictated words appear as plain editable text, with "Dictate more" and Send. Drop the brief's
dictated · check the words, then sendhint.
2026-11-08: open decision questions answered by the maintainer and recorded above.
Activity
schlessera commentedon Nov 8, 2026
Design needed. Already settled: the MicButton's own look, the 0.6 s hold (V1), the ring filling even when live conversation is unavailable (V4), and the D1–D8 and S1–S5 states as bare-field stories (#3692). Still open: how the 44px MicButton, its hint and its "Talk live…" action sit inside the real composer, next to the attach menu, the editable textarea, the provider chip, the hint line and Send. The code cannot decide this because no signed-off drawing shows them together. It blocks #3693 and the D1/D6 states of #3694. A self-contained prompt follows.
schlessera commentedon Nov 8, 2026
Design brief: MicButton in the real composer (D1, S1, Talk live…, D6)
ui-kit components:
Composeris extended with one optional prop.MicButtonis reused unchanged. Nothing new.1. Placement and height
The MicButton takes today's mic slot inside the field. Row order stays
attach · text · mic · send(D37).8px 10px. The mic slot is MicButton's 44×44 box withmargin-block: -4px, so its layout height is 36px. That makes the field 46 → 54px instead of 62px. The 44px target stays inside the border with 4px to spare.align-items: flex-end. On a multi-line draft, attach, mic and Send sit on the last line, and attach and Send getmargin-bottom: 8px. A plain single-line field looks centred anyway.2. Hint and "Talk live…"
Both use MicButton's own absolute positions, above the field and right-aligned to the mic (their right edge sits 4px inside the mic). They overlay the last transcript line or the recall chips. They never move the layout and never touch the hint line.
3. D6 review: no mark in an editable field
D6 is the ordinary editable composer, with the dictated words in the textarea, focus in the text and the caret at the end. No uncertain-word mark. A textarea cannot hold styled runs, and once the text is edited the confidence no longer matches it. The mic is named "Dictate more" and Send is live.
The honesty cue moves to the hint line:
hint="dictated · check the words, then send". It shows until the first edit or Send.4. Local recording ("Record on this device", #1012)
This uses MicButton with no hold:
name="Record on this device", noonTalkLive, nohint, and the phase staysidle, so a hold acts as a tap. Live needs the host, so a ring that cannot lead anywhere would teach the wrong gesture. V4 (the ring fills when live is unavailable) applies to a reachable host only.Kit prop
Without the prop, the composer renders exactly as before, and the existing baselines stay unchanged.
Stories (320 + desktop, light + dark)
Composer/With MicButton: Idle · Holding + hint · Talk live focused · D6 review (one line, three lines) · Offline local recording. Play test: no row overflow at 320 with the hint showing.Open questions (
needs: decision)schlessera commentedon Nov 8, 2026
Decision (maintainer, 2026-11-08):
MicButtonwith no hint and no "Talk live…", and a hold acts as a tap. V4 (the ring fills, then explains) applies only while the host is reachable.dictated · check the words, then sendhint.The design brief above is otherwise unchanged. Its sign-off is still pending, so this issue now carries
needs: designinstead ofneeds: decision.schlessera commentedon Nov 8, 2026
Design sign-off: MicButton in the real composer (final, M1 and M2 folded in)
Signed off. This comment is the complete spec. It replaces the brief above where they differ. Only D6 changed (M2).
ui-kit components:
Composeris extended withmicControl?: ReactNode.MicButtonis reused unchanged.Geometry (all states)
attach · text · mic · send(D37). Field padding stays8px 10px.margin-block: -4px, so the field is 54px (46 today).micControlset, the field usesalign-items: flex-end, and attach and Send getmargin-bottom: 8px, so they sit on the last line of a multi-line draft.States
readycontent.MicButtonnamed "Record on this device", with noonTalkLive, nohint, and the phase alwaysidle, so a hold acts as a tap. V4 applies only while the host is reachable.Kit prop
Stories and baselines (320 + desktop, light + dark, reduced motion)
Composer/With MicButton: Idle · Holding + hint · Talk live focused · D6 one line · D6 three lines · Offline local recording. Play test: no row overflow at 320 with the hint showing. The existingComposerbaselines stay unchanged.No open questions remain.
schlessera commentedon Nov 8, 2026
Claimed (claim
wi-3727-c1), branchfeat/3727-composer-mic-control, building to the 2026-11-08 21:35Z design sign-off (M1 and M2 folded in). Readiness: the acceptance criteria are checkable and every design question is ruled, soagent-readyis added and the milestone is 0.45.0.Collision noted: #3724 (open, ready) also edits the props of
packages/ui-kit/src/chrome/Composer.tsx(micTipand a disabled mic). The two changes are additive and independent, and whichever lands second rebases.schlessera commentedon Nov 8, 2026
Implementation in #3742. I applied one number differently from the sign-off, and the change is recorded there.
With
micControlthe field isalign-items: flex-end, and the mic slot is 36px of layout (44 − 2 × 4). In Chromium, the spec'smargin-bottom: 8pxon Attach and Send puts them 4px above the mic disc's centre. A single line of text in the same field sits 8.2px below it. That is neither the drawing (everything centred on one line) nor "sit on the last line". The PR uses(36 − 28) / 2 = 4pxfor Attach and Send (and Stop, which holds Send's place) and(36 − 19.575) / 2 = 8.2125pxfor the text. The field is still 54px. The stories assert the centring at rest and on a three-line D6 draft.Smaller measured facts:
CONTRACT: feat(ui-kit): let the composer host the hold-to-talk MicButton
CONTRACT: feat(ui-kit): let the composer host the hold-to-talk MicButton
CONTRACT: feat(ui-kit): let the composer host the hold-to-talk MicBut…
schlessera commentedon Nov 9, 2026
Delivered in #3742, squashed to main as
fb999b8b(milestone 0.45.0). Confirmation passed in candidate run https://github.com/schlessera/brain-kit/actions/runs/42577219825, at headccf20041on baseedce87b2.ComposergainsmicControl?: ReactNode. When it is set, the kit mic's props are ignored, the field is 54px, and the controls sit on the last line. Without it, the composer is unchanged, and the full visual project ran with no existing baseline changing.api-report/ui-kit.txtrecord the prop.#3693 can now wire the hold onto the real composer.
feat(ui-react): tap the composer mic to dictate, hold it to open Start (
feat(ui-react): dictate in the voice field and remove the dictation s…