Repository navigation
fix(dashboard): show a calm reconnecting view while a relay Crew window retries - #36430
Conversation
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Nothing blocks: the retrying state is built from signals the page already reads, the change only applies in a relay window, and five screenshots of this revision are attached. Notes
[DESIGN-REVIEWED] e2ac23d Description read[DESCRIPTION-READ] a2c889379a96ddb94fd771e6dfdcf3c5c87460a445fbd5fdabf047d70c4d1108 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 |
First Principles Review (Opus 5.5) — ✅ PASSPremise-level review of First-Principles-Verdict: PASS Nothing blocks. Every item addresses the red styling on a self-healing relay retry (#36427). The only extra is a defaulted parameter that no caller relies on. Notes
What this change shipsInventory (9 items) — 8 justifiedIntent: a relay Crew window teammate waiting out a transient drop sees a calm "reconnecting" state, not an outage alarm — FIX.
[FIRST-PRINCIPLES-REVIEWED] e2ac23d Description read[DESCRIPTION-READ] bb157a2daa8086d7af390e058077faadaff29df8b31dc9da6b5d05c703c474d0 That sha256 names the PR description this verdict read. Recompute it with |
UX Review (Opus 5.5) — ✅ PASSUX-level review of UX-Verdict: PASS Nothing blocks. The blind reader understood the reconnecting view correctly and with confidence ("fixing it by itself… sure… I would just wait"), and screenshots cover every changed control in dark, light and 420 px. Notes
[UX-REVIEWED] e2ac23d Description read[DESCRIPTION-READ] 4c443ca0799debf352c10825151babdced3039ed06a3388160515d626776e708 That sha256 names everything this verdict read: the PR description, plus the 8 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: |
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: |
cd44794 to
15a54a8
Compare
|
target=fable span=18e45ae36123 disposition=fixed sha=15a54a88bead
|
15a54a8 to
090947e
Compare
|
target=gpt disposition=fixed sha=090947e9f7ba
|
090947e to
9352e90
Compare
The reconnecting view makes <main> and the docked terminal inert, which drops the focused composer to <body>. Remember the focused element as the retry starts and focus it again on reconnect, unless the user focused something else meanwhile.
bolichen97
left a comment
There was a problem hiding this comment.
I read the whole diff, including all 14 locale files and the tests. This is a UI-only change, and it looks good to me:
isRelayRetryingonly treats a plain drop in a relay Crew window as retrying.refusedandsession_endedkeep the danger styling and their own text, and the tests pin both.- While retrying,
<main>and the docked terminal are inert and isolated under the new view, and focus is given back on reconnect unless the user moved it. A maximized terminal is left alone, because it paints above the view. - Exactly one live region speaks the state.
gatewayStatusAnnouncestays blank only while the centre view is active. - Spinners respect
motion-reduce. Each locale adds the same three keys.
There is no regex, no new refusal and no change to the connection itself, and CI is green.
Problem / Motivation
Goal: A relay Crew window that is still reconnecting on its own shows a calm "Reconnecting…" view instead of red outage styling.
When a remote Crew's connection drops in the desktop app's relay Crew window and the page is retrying, the top bar shows a red pulsing unplugged plug, a red-tinted readout capsule and a red inline "Reconnecting…" notice. Nothing is wrong that the user can fix. The desktop app already says when retrying stops ("currently unavailable" + Check again, #35167) and when access is refused (#35144).
Why it matters
Red tells the user something failed and they should act. During a transient drop the right action is to wait, so the red is alarming and wrong for every relay teammate who hits a network blip or a relay reconnect.
Not a goal
/api/status, or the desktop app's notices.What changed (motivation → approach → change)
The page already knows it is in a relay Crew window (the
kiroCrewRelayWindowuser-agent marker) and why it is offline (#34372), so the retrying state is readable without a new signal: offline after the first connect, no refusal, no ended session, no expired sign-in.isRelayRetryinginwebsite/src/utils/offlineReason.tsnames it anduseAppShell(website/src/shell/appShell.tsx) combines it with the transport state.In that state only:
RelayReconnectingView(website/src/shell/RelayReconnectingView.tsx, mounted inwebsite/src/App.tsx) covers the content area: a neutral spinner (still under reduced motion), "Reconnecting…" and two muted lines. Theme variables only.<main>and a docked terminal panel, through the existinghiddenChromeProps, so keystrokes cannot reach a composer the user cannot see. A maximized terminal paints above the view and stays usable.<main>also gets a stacking context while retrying (mainStackingClassinwebsite/src/utils/terminalFullscreen.ts), so its own fixed layers, such as the phone sessions drawer, stay under the view.website/src/shell/topbar/shellHeader.tsx) drops the red: a warn-coloured spinner in place of the red plug, noglass-dangertint, and a warn dot with "connecting…" in place of the redErrorNotice. The phone strip stays hidden there too.gatewayStatusAnnounce, which is blank only in this state, so screen readers hear one announcement, not two.Three new strings (
app.relay_crew_dropped,app.relay_crew_reconnects_on_its_own,app.relay_crew_connecting) in all 12 locale files underwebsite/src/i18n/locales/;en-XAregenerated.Backwards compatibility
Compatible: only the retrying state in a relay Crew window renders differently; every other connection state, the desktop app's notices and the APIs are unchanged.
Removes nothing: the red notice and tint still render in every state that had them except a relay Crew window's retrying state, where the centre view replaces them.
Tests
website/src/test/App.offlinePill.test.tsx: in a relay Crew window, a drop after connect shows the centre view (live region mounted before the drop, spinner withmotion-reduce:animate-none), noglass-danger, no error notice, the warn "connecting…" label a blank capsule status and an inert#main-content; reconnecting empties it and clearsinert.refusedandsession_endedkeep the danger styling and notice.website/src/utils/terminalFullscreen.test.ts:mainStackingClassisolates while retrying and not otherwise; the App test also assertsisolateon#main-contentwhile retrying.website/src/test/offlineReason.test.ts:isRelayRetryingis true only for a plain drop in a relay window.website/src/test/agentSwitchNotice.surfacePairing.test.ts: the silenced notice and its live region now pair ongatewayStatusAnnounce.Revert check: with
relayRetryingforced tofalse, the new App test fails and the two failure-state tests still pass.Proof: not provable -- frontend test (prove.py runs Python only)
Ran locally: 156 related frontend test files (2,111 tests) green,
tsc -p tsconfig.app.json, eslint on the changed files,npm run i18n:check.Manual verification
Rendered the built SPA against the stub router with the relay user agent (Playwright, 2x): retrying in dark, light and at 420 px, plus the refused relay state and a plain dashboard drop as controls. Each scene asserted the centre view, the capsule tint, the notice and the "connecting…" label. Not run in the real desktop relay window.
Screenshots / video
Relay Crew window, retrying (dark):
Retrying (light) and at 420 px wide:
Unchanged controls: a refused relay connection and a plain dashboard drop stay red
Related Issues
Closes #36427
Related: #35167, #34372, #34119, #35125, #35144. Follow-up: #36428.
Sibling sweep
Swept: git grep -n "offlineReason|gatewayStatusMsg|glass-danger" -- website/src
Sibling: website/src/components/chat-input/offlinePlaceholder.ts -- not affected -- the composer sits under the centre view while it shows
Sibling: website/src/App.tsx -- changed here
Pattern harvest
Not generalizable: the defect is one surface styling a self-healing state as a failure; the retrying/failed split is specific to the relay window's cause model.
Checklist