You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(mobile): show a computer's connection in its page subtitle, with one action per list state - #48655
When a computer went offline, its page stacked up to five banners in four styles above the title, and offered Retry or Reconnect up to three times. Now the line under the computer's name is the only status: "Offline since 9:41 PM" with one Reconnect, and the rows stay readable but quieter. The page's empty and error states each get one clear action, and the options sheet uses plain words.
Files
Added
Deleted
Net
Test
0
0
0
0
Prod
27
$\color{#1a7f37}{\Huge{\mathbf{+}}}$289
$\color{#cf222e}{\Huge{\mathbf{−}}}$645
$\color{#cf222e}{\Huge{\mathbf{−}}}$356
What Changed
Status line (host-screen-header.tsx): offline reads "Offline since " (when the drop was seen) with one 44 pt Reconnect on the right of the page title's line. A relay's own reason ("Sign in…", "… is off") still shows instead; a Tailscale hint is kept after the time. A refused pairing reads "Not connected". The bar's collapsed title shows the same line without Reconnect.
No banners (host-workspace-list.tsx): the offline banner, auth banner, "View network diagnostics" card and notice banners are gone. Diagnostics and Edit stay in ⋯. Action errors, server notices and route notices are toasts; an error raised while a sheet is open waits until it closes.
Offline rows dim to 60% and stay readable; the bottom bar's + and the project + hide until a new workspace can start.
States (host-workspace-list-states.tsx, host-screen-view.tsx):
Refused pairing replaces the list with "Pairing was refused" and Re-pair (plus Retry where the app can rebuild the connection).
Empty: "No workspaces" + New workspace (only while connected); with filters on: Clear filters.
Load failure: "Couldn’t load workspaces" + Retry.
"Host not found" is a state view with Back instead of bare red text.
Words: "Floating workspace", Back reads "Back".
Workspace options sheet (workspace-options-sheet.tsx): "Hosts" → "Computers"; "Hide automation workspaces", "Hide CLI workspaces", "Hide other devices’ workspaces", "Hide workspaces with no branch". "Synced across your devices" and the "Saving to the host" row are replaced by a "Saving…" subtitle while the computer hasn't taken a change.
Deleted AuthFailedBanner (+ its web variant and override entry) and HostDiagnosticsLink.
Rebuilt on main without #48649 (the one-line row redesign, which isn't landing). Card layout, Show properties and Card display stay in the options sheet, since today's rows still draw what they choose; only their neighbours' words changed.
Why
The audit (R2, P5, P7, P8) found connection trouble shown in four styles and up to three Reconnects, 25–31 pt targets, and states with no way forward. The status line follows the page title pattern the phone already uses; the states use MobileStateView with one action, like Tasks and Files.
Linked Issue
None. This is the approved phone UX round (host connection state, list states, options words).
Visual Proof
Re-shot on the real page in Chromium over a shell double; offline and refused are real state frames from the shell. Before = main, after = this branch.
Testing
I manually tested these changes locally. Chromium, dark and light: connected, offline with rows, refused pairing, empty, the options sheet, the ⋯ menu.
Automated tests added/updated, or explained why not below. UI-only; no new tests, per the repo's test policy.
Every added test fails without this change and avoids the test anti-patterns
pnpm check:changed passes. pnpm build:mobile-web passes; eager bytes +4.3 KB across the stack (11,513,830 of 11,550,720).
Performance
None, because the status line reuses the offline banner's own state hook and the toasts replace banners one for one.
Risk
The riskiest part is the status line: if the time were wrong, a user would read when the computer dropped incorrectly. It uses the same drop-or-read time the old banner's "As of" did. Removing the auth banner's Remove button leaves removal on Home and the Edit page. A plain revert backs it out.
Level: Low
Review
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
Ensure no issues in: Security, Cross-platform support (Linux, Windows, Mac), Remote SSH, Mobile, general backwards compatibility, performance
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)
The host screen updates its status display, reconnect behavior, error state, and primary action. The workspace list adds authentication-refusal handling, revised empty and catalog-error actions, dimmed outage rows, and timed notice toasts. The workspace-options sheet changes filter labels and displays save progress for pending view changes. Related components, styles, web overrides, and locale strings are removed or updated.
Merge Risk: Low · up to cd7c5
Some toast notices can expire while a bot-group sheet covers them. The offline timestamp, a hidden-project edge case, and a few untranslated filter labels are minor open issues. None blocks core workflows, and the risk is low.
Pre-merge checks: 4
Check name
Status
Explanation
Title check
The title names the main change: a computer's connection status now appears in its page subtitle, and each list state gets one action. The diff matches this. It removes the banners and adds a status l…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Description check
The description follows the repository template and fills in most sections. The ELI5, What Changed, Why, Visual Proof, Testing, Performance, Risk, and Checklist sections are all substantive. The Perfo…
Full details: Title check
Explanation
The title names the main change: a computer's connection status now appears in its page subtitle, and each list state gets one action. The diff matches this. It removes the banners and adds a status line to the header, and it adds one action per state in the list-state component. The title is specific and uses the conventional feat(mobile) prefix, though it is long at 95 characters.
Full details: Description check
Explanation
The description follows the repository template and fills in most sections. The ELI5, What Changed, Why, Visual Proof, Testing, Performance, Risk, and Checklist sections are all substantive. The Performance section gives a reason, and the Risk section names the riskiest part and a rollback method. The Linked Issue section says "None" and explains that this is an approved UX round. The template says outside contributors must link an actual issue, but the author's context suggests an internal change, so this is a gap to flag rather than a failure. The Visual Proof section uses before and after images. The AI Disclosure section is blank, which is acceptable only if the author is a StablyAI team member. The Review section has an unchecked upstream-boundary item that the author marked as not applicable, so it is not an issue. The Testing checklist does not show that automated tests were added, but the author explains why none were added.
Finishing Touches
Fix failing CI checks
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 0 remain after this review.
The reason will be displayed to describe this comment to others. Learn more.
Minor · Functional Correctness · Quick win
Date "Offline since" from the observed drop, not from a stale read.
When the rows were read before this status component mounted, the hook returns that earlier read time as "Offline since" if the client connects and then drops before another successful catalog read. The hook records the drop in droppedAt, but the readThisDocument gate discards it. The status then reports the cache time instead of the time the connection was lost.
Use the observed drop time when one is recorded. Fall back to the read time only when no drop has been observed. This matches the later decision to date the offline state from the drop.
The reason will be displayed to describe this comment to others. Learn more.
Minor · Functional Correctness · Quick win
Catalog refreshes clear action errors before the deferred notice can show.
While Workspace options or an action sheet is open, notice is null. The catalog success effect still runs on each successful read and calls setActionError(''). Its only sheet check covers the new-workspace sheet (showNewWorktree), and the catalog query receives no sheet state. An action error raised while a sheet is open can therefore be cleared by the next poll or refetch. When the sheet closes, notice is null and the error does not appear.
An action error raised while a sheet is open must stay available until the sheet closes. The clear on a confirmed catalog read must not remove it while either sheet is open. Errors that already reached the notice, or that were raised outside a sheet, keep the current clear behavior.
The reason will be displayed to describe this comment to others. Learn more.
Minor · Functional Correctness · Quick win
Add localized values for the four renamed workspace filter keys.
The workspace options sheet now reads hostScreen.workspaceOptionsSheet.hideAutomationWorkspaces, hideCliWorkspaces, hideOtherDevicesWorkspaces, and hideNoBranch. These keys exist only in en.json. The de, es, fr, ja, ko, and pt catalogs drop the old keys (hideAutomationCreated, hideCliCreated, hideOtherClientWorkspaces, hideDetachedHead) and do not add the replacements. Those locales therefore show English for these four filter labels. Before this change, the same controls showed localized text.
Add the four replacement keys to the hostScreen.workspaceOptionsSheet object in each non-English catalog. Translate the current English text for each key. Use the removed values only where the meaning matches:
hideNoBranch does not replace hideDetachedHead. The new label covers workspaces with no branch. The old label covers detached HEAD workspaces. Translate the new label from its own text.
The reason will be displayed to describe this comment to others. Learn more.
Minor · Functional Correctness · Quick win
Match the hidden-project exception on execution host, not only repository ID.
When onlyInitialRepoHost is false, pickerRepos(..., initialRepoId) keeps every hidden repo whose ID equals the initial repo's ID, on any host. The host filter that ran before this PR removed those rows, but it now runs only when onlyInitialRepoHost is true. A hidden repo with the same ID on another host therefore reaches the returned repos list. Apply the exception only to the initial repo's own host copy. Keep the shared pickerRepos helper unchanged.
Suggested fix
-import { pickerRepos } from '../../../../../src/shared/project/catalog/hidden-projects'+import { isRepoHidden } from '../../../../../src/shared/project/catalog/hidden-projects'
Files skipped from review as they are similar to previous changes: 11
mobile/src/i18n/locales/de.json
mobile/src/i18n/locales/en.json
mobile/src/i18n/locales/es.json
mobile/src/i18n/locales/fr.json
mobile/src/i18n/locales/ja.json
mobile/src/i18n/locales/ko.json
mobile/src/i18n/locales/pt.json
mobile/src/i18n/locales/ru.json
mobile/src/i18n/locales/tr.json
mobile/src/i18n/locales/zh-Hant.json
mobile/src/i18n/locales/zh.json
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 4 remain after this review.
The reason will be displayed to describe this comment to others. Learn more.
Minor · Functional Correctness · Quick win
Keep the workspace notice held while bot-group sheets are open.
The notice gate at lines 87-89 checks only the workspace options, workspace actions, and new-workspace sheets. The bot-group sheets from useMobileBotGroupEditor render through bots.sheets at line 321, but they use separate open state. While one of them is visible, sheetOpen stays false. A serverNotice or actionError then stays on screen behind the native sheet, and the three-second timer at lines 96-104 clears it before the user can read it.
Expose a sheet-open signal from useMobileBotGroupEditor, pass it through useMobileBotsListParts, and include it in sheetOpen. The signal should be true while any of these is visible:
newBot !== null
reordering && canReorder
actions !== null
editing !== null with client
deleting !== null
deleteFailure !== null
Match the visibility conditions of MobileBotGroupDeleteConfirm and MobileBotGroupMembers to this list.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ELI5
When a computer went offline, its page stacked up to five banners in four styles above the title, and offered Retry or Reconnect up to three times. Now the line under the computer's name is the only status: "Offline since 9:41 PM" with one Reconnect, and the rows stay readable but quieter. The page's empty and error states each get one clear action, and the options sheet uses plain words.
What Changed
host-screen-header.tsx): offline reads "Offline since " (when the drop was seen) with one 44 pt Reconnect on the right of the page title's line. A relay's own reason ("Sign in…", "… is off") still shows instead; a Tailscale hint is kept after the time. A refused pairing reads "Not connected". The bar's collapsed title shows the same line without Reconnect.host-workspace-list.tsx): the offline banner, auth banner, "View network diagnostics" card and notice banners are gone. Diagnostics and Edit stay in ⋯. Action errors, server notices and route notices are toasts; an error raised while a sheet is open waits until it closes.host-workspace-list-states.tsx,host-screen-view.tsx):workspace-options-sheet.tsx): "Hosts" → "Computers"; "Hide automation workspaces", "Hide CLI workspaces", "Hide other devices’ workspaces", "Hide workspaces with no branch". "Synced across your devices" and the "Saving to the host" row are replaced by a "Saving…" subtitle while the computer hasn't taken a change.AuthFailedBanner(+ its web variant and override entry) andHostDiagnosticsLink.Rebuilt on main without #48649 (the one-line row redesign, which isn't landing). Card layout, Show properties and Card display stay in the options sheet, since today's rows still draw what they choose; only their neighbours' words changed.
Why
The audit (R2, P5, P7, P8) found connection trouble shown in four styles and up to three Reconnects, 25–31 pt targets, and states with no way forward. The status line follows the page title pattern the phone already uses; the states use
MobileStateViewwith one action, like Tasks and Files.Linked Issue
None. This is the approved phone UX round (host connection state, list states, options words).
Visual Proof
Re-shot on the real page in Chromium over a shell double; offline and refused are real
stateframes from the shell. Before = main, after = this branch.Testing
pnpm check:changedpasses.pnpm build:mobile-webpasses; eager bytes +4.3 KB across the stack (11,513,830 of 11,550,720).Performance
None, because the status line reuses the offline banner's own state hook and the toasts replace banners one for one.
Risk
The riskiest part is the status line: if the time were wrong, a user would read when the computer dropped incorrectly. It uses the same drop-or-read time the old banner's "As of" did. Removing the auth banner's Remove button leaves removal on Home and the Edit page. A plain revert backs it out.
Level: Low
Review
Agent skill upstream boundary
Notes
Ensure no issues in: Security, Cross-platform support (Linux, Windows, Mac), Remote SSH, Mobile, general backwards compatibility, performance
Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred)