Repository navigation
fix(stt): put the error hand-off on its own line on a phone - #34541
Conversation
Below the sm breakpoint the inline error rows of the speech-to-text settings kept Ask the agent beside the message, so the sentence got about 60% of a phone's width and a long refusal wrapped to seven lines. Those rows now wrap there: the message keeps the first line with its icon and the hand-off moves to the line under it. From sm up nothing changes.
First Principles Review (Opus 5.5) — ✅ PASSPremise-level review of First-Principles-Verdict: PASS Nothing blocks. This is a layout fix to seven existing error rows, built on the What this change shipsInventory (3 items) — 3 justifiedIntent: let a phone user read a speech-to-text error sentence at full width when voice input breaks. This is a FIX.
[FIRST-PRINCIPLES-REVIEWED] 4c0a608 Description read[DESCRIPTION-READ] 588bee00b122d35eca57c53c88e86dbc3f93dfc557d264f2d17b9af9a5170be7 That sha256 names the PR description this verdict read. Recompute it with |
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Nothing blocks: this is a local layout fix with rendered before/after evidence, and it removes nothing. Notes
[DESIGN-REVIEWED] 4c0a608 Description read[DESCRIPTION-READ] 132a0fc6ae09ca49f4d9a981aa8f6018ecefbbe7d6f317dae05be26bee6e1596 That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
UX Review (Opus 5.5) — ✅ PASSUX-level review of UX-Verdict: PASS Nothing blocks. The blind reader saw the change working: after it, Ask the agent "clearly belongs to the error message, which is easier to read than shot 1." Notes
[UX-REVIEWED] 4c0a608 Description read[DESCRIPTION-READ] 3cb7fc3d7c43b663b4867bb0a6bf4c61fcbba6ad4020bb985b93b954dd579ca0 That sha256 names everything this verdict read: the PR description, plus the 11 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
KiroCrewCaptain
left a comment
There was a problem hiding this comment.
Tier 1 auto-approve: fix (2 files). Criteria: no conflict, no requested changes, security path denylist clean, design-doc gate clean, security checklist all-NO, no reviewer-lane findings, readiness signal fresh for this head SHA, declared category matches the diff. Category: bug fix: the STT settings error hand-off wraps onto its own line on narrow screens; frontend class change plus a test.
buluoray
left a comment
There was a problem hiding this comment.
Approve on 4c0a608. Layout-only fix: seven inline STT error rows wrap below sm so the sentence takes the row and Ask the agent drops to its own line; desktop classes unchanged, shared ErrorNotice untouched. Decisive lines: website/src/pages/settings/SttSettings.tsx:233-234, website/src/pages/settings/SttSettings.tsx:1511-1512, website/src/components/ErrorNotice.tsx:344-350, website/src/test/SttSettings.modelDownloadDisclosure.test.tsx:135-148
Problem / Motivation
Goal: On a phone, a speech-to-text error row gives its sentence the full width of the row and puts Ask the agent on its own line under it.
In Settings → Voice, below the
smbreakpoint (640px), the inline error rows of the speech-to-text card keep Ask the agent beside the sentence. The sentence is squeezed into a narrow column: at 375px it gets 218 of 343px, at 320px 163 of 288px, and the "speech model crashed while loading" refusal wraps to seven lines with the icon and the link floating halfway down.Why it matters
These rows show up when voice input is broken: a model download failed, the recogniser refused to load, the status check failed, a custom model file cannot be used, the vocabulary list or a push-to-talk save failed. That is exactly when the user has to read the sentence to know what to do, and on a phone it is the hardest thing on the screen to read.
Not a goal
ErrorNoticeinline layout for other pages.SpeechProviderNoticeandMicTestStriprows and the two boxed banners of this card, tracked in Voice settings: on phones, four more error notices squeeze their sentence beside Ask the agent #34540.main.What changed (motivation → approach → change)
On a phone, the sentence of each of these rows now uses the whole width of the row beside its warning icon, and Ask the agent sits on the line below it. From
smup nothing moves.The inline
ErrorNoticeis one row that never wraps, and the hand-off button never shrinks, so on a narrow screen the sentence is the only thing that gives way.SttSettings.tsxgives each inline notice that carries the hand-off two class strings: the row may wrap belowsm, and the message's flex basis leaves room for the icon only, so the hand-off is pushed to the next line while the icon stays beside the sentence. A plain full-width message would have moved the sentence under the icon and left the icon alone on the first line. The shared component is untouched.Backwards compatibility
Compatible: only layout classes on seven call sites change; no prop, string, route or API changes.
Removes nothing: no field, control or text is removed; the hand-off is still rendered, only on its own line on a phone.
Tests
SttSettings.modelDownloadDisclosure.test.tsx— new: a failed model download renders its notice as a row that wraps belowsmwith the message holding the line, and Ask the agent is still inside the notice. jsdom has no layout, so the wrap is read off the classes; the screenshots below show the rendered lines. Red on the parent commit, green on this one.--sequence.shuffle --sequence.seed=11499).Proof: not provable -- frontend test (prove.py runs Python only)
Manual verification
Built the SPA from this head and rendered Settings → Voice with stubbed gateway answers (the repository's screenshot harness, no gateway) at 320, 375 and 1180px for three states: a failed model download, the recogniser refusing to load, and a failed status check. Below
smthe sentence takes the row and Ask the agent sits on the next line; at 1180px the rows are pixel-identical tomain.Screenshots / video
The recogniser refused to load, 375px (dark):
A failed model download, 320px (dark):
Light theme, the status check failure, and desktop
The refusal row after the change, 375px, light theme:
The status check failed, 375px (dark):
Desktop, 1180px, after the change (byte-identical to the shot taken on
main):Related Issues
Closes #20721
Sibling sweep
Swept: git grep -n 'variant="inline"' -- website/src/pages/settings/SttSettings.tsx website/src/components/MicTestStrip.tsx website/src/components/SpeechProviderNotice.tsx
Sibling: website/src/pages/settings/SttSettings.tsx -- changed here
Sibling: website/src/components/MicTestStrip.tsx:151 -- tracked in #34540
Sibling: website/src/components/SpeechProviderNotice.tsx:29 -- tracked in #34540
Pattern harvest
Not generalizable: whether an inline notice should wrap depends on how wide its row is, which no static rule can see; the narrow-viewport guidance already says an action cluster leaves the text row.
Checklist
feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)Contribution License Agreement
Contributions are accepted under the project's Apache-2.0 license; see the Licensing section of CONTRIBUTING.md.