Skip to content

fix(mobile): translate built-in workspace status names and this computer's name - #52318

Merged
nwparker merged 1 commit into
stablyai:mainfrom
x-Ai:fix/mobile-zh-status-host-pickers
Nov 29, 2026
Merged

nwparker merged 1 commit into
stablyai:mainfrom
x-Ai:fix/mobile-zh-status-host-pickers

Conversation

@x-Ai

@x-Ai x-Ai commented Nov 29, 2026 •

Copy link
Copy Markdown
Contributor

ELI5

Some names in the mobile app stayed in English even when the app was set to another language. These are the four built-in status names (Todo, In progress, In review, Done) and the built-in name for your own computer (Local Mac, Local Windows, Local Linux, This computer). They now show in your language. A name you typed yourself stays exactly as you wrote it.

What Changed

Before: the phone showed the host's English status labels in the Group by Status section headers, the Status sheet and the row menu's Status row. The new-workspace "Run on" picker and its selected value showed "Local Mac" (or Windows/Linux) in English in every locale.

After: these places use the mobile catalog when the name is still a built-in one. Renamed or custom statuses, and computers with their own name, stay literal.

How:

  • New mobile/src/worktree/workspace-list/workspace-status-label.ts (translateWorkspaceStatusLabel). It uses the same rule as desktop's translateWorkspaceBoardStatusLabel: a status is translated only if its id is one of DEFAULT_WORKSPACE_STATUSES and its label is blank or still the shipped default. The status section headers (workspace-list-sections.ts), the Status sheet and the row menu's current status use it.
  • New getTranslatedHostContextLabel in worktree-host-context-labels.ts. A host with its own label, or a host that is not local, goes through the shared getHostContextLabel unchanged. Otherwise it picks this computer's name by platform from the existing hostScreen.workspaceOptionsSheet.local* / thisComputer keys. The workspace options sheet's inline version of this logic is replaced by the helper, with the same keys and the same result. getNewWorkspaceRunTarget and buildNewWorkspaceRunTargetOptions now take t and use it as well.
  • Four keys worktree.workspaceStatus.{todo,inProgress,inReview,done} in all 11 mobile locales. Each value matches the desktop workspaceBoardStatus string, so a status reads the same on both.

Why

The status a user picks on the phone should read the same as the lane it lands in on desktop. "Run on" was the only place in the new-workspace form that named the computer in English, while the workspace options sheet, two taps away, already translated it. Matching desktop's rule keeps user-set names untouched, and moving the options sheet's logic into one shared helper means the two pickers can't drift apart.

Linked Issue

Refs #32207 (localization tracking issue; this covers part of it)

Still English, out of scope here: mixed-host row badges, the tasks repository detail line, and the gated-off feed path.

Visual Proof

N/A. These are React Native phone screens with no component fixtures, so there are no screenshots. Instead, the changed functions were run with the real catalogs. On main a zh-backed buildMobileWorkspacePlan grouped by status gives Todo / In progress / In review / Done and the Run on picker gives Local Mac. On this branch they give 待办 / 进行中 / 评审中 / 完成 and 本地 Mac. A renamed status ("Backlog"), a custom status ("Blocked"), a named local host and an SSH host all stay literal.

Testing

  • Reproduced on main with a scratch vitest probe (zh and ja catalogs): the status headers and the Run on label come out in English. The same probe passes on this branch.

  • Added workspace-status-label.test.ts (shipped and blank labels are translated, renamed and custom labels pass through) and worktree-host-context-labels.test.ts (darwin/win32/linux/unknown platform, a local host with its own name, and an SSH host whose name is "Local Mac").

  • Targeted mobile vitest passes. pnpm -C mobile typecheck passes. pnpm verify:mobile-localization passes.

  • CI static gates on the touched files are clean: anti-slop oxlint, code-quality native oxlint, ast-grep, changed-code quality, oxfmt, and the render-path-translate and mobile React Compiler hazard ratchets.

  • Platforms: the logic is platform-agnostic and was checked in unit tests for darwin, win32, linux and an unknown platform. Not rendered on a device.

  • I manually tested these changes locally

  • Automated tests added/updated, or explained why not below

  • Every added test fails without this change and avoids the test anti-patterns

Performance

None that matters, because these are render-time label lookups inside existing memos, with no I/O, polling or subprocess work.

  • The status helper runs once per status section, not once per row. At N=200 worktrees in 4 statuses it is 4 calls per plan rebuild, the same count as main's label reads. Micro-benchmark: 5 status labels take 7 ns on main and 42 ns here.
  • Host labels: 200 hosts take 2.3 µs on main and 4.3 µs here, per options-sheet memo run.
  • t from useMobileTranslation changes identity only when the language changes, so the new t dependency in NewWorktreeModal's memo adds no recomputation.
  • The row menu hook runs only while a row's menu is open.

Risk

The main risk is a wrong translated string, which would show up as a mistranslated status or computer name. Names the user set are never translated, so their data is not affected. Nothing is persisted, and the phone/host protocol is unchanged, so this is safe with older desktops and SSH hosts. A status whose label exactly matches a default spelling is translated, which is also how desktop behaves. Back out with a plain revert.

Level: Low

Review

Reviewed by two independent passes, both approved. Fixed during review: the row menu's Status row now matches the sheet it opens, the host helper picks the name by platform instead of matching English copy, and host-label tests were added.

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

Original fix by @x-Ai in #52318 (authorship preserved on the commit).

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)

@greptile-apps

greptile-apps Bot commented Nov 29, 2026 •

Copy link
Copy Markdown

Confidence Score: 5/5 · The PR appears safe to merge; no blocking issue was found.RetriggerView in GreptileConfidence Score: 5/5

[Low impact] The PR appears safe to merge; no blocking issue was found.

Summary

The mobile screens now translate built-in status names and default computer names while keeping custom names unchanged.

  • Built-in workspace statuses use the phone’s language.
  • The Run on picker shows this computer’s name in the phone’s language.

Reviews (3) · Last reviewed commit: "fix(mobile): show built-in status and co..." · Reviewed by Greptile

@coderabbitai

coderabbitai Bot commented Nov 29, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

Workspace status actions, list sections, and local row menus now display translated labels for supported shipped statuses while preserving unknown statuses and custom labels. Workspace options and new-workspace run-target options use a shared helper to translate built-in local host labels. Locale files add translations for workspace statuses.

Merge Risk: Minimal · up to 511d9

This change translates built-in workspace status names and the local computer's name in the mobile app, and leaves custom and renamed names untouched. No concrete defects were found, so the merge risk is minimal. The author notes the change was not checked on a device.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the two changes in the PR: translating built-in workspace status names and this computer's host name in the mobile app. The changeset adds a status label translator, a translated host-…
Description check Passed The description follows the repository template. It covers ELI5, What Changed, Why, Linked Issue, Visual Proof, Testing, Performance, Risk, AI Disclosure, Review, Agent skill boundary, Notes, and Chec…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the two changes in the PR: translating built-in workspace status names and this computer's host name in the mobile app. The changeset adds a status label translator, a translated host-context label helper, and locale keys for both. The title is specific and matches the main change.

Full details: Description check

Explanation

The description follows the repository template. It covers ELI5, What Changed, Why, Linked Issue, Visual Proof, Testing, Performance, Risk, AI Disclosure, Review, Agent skill boundary, Notes, and Checklist. The Visual Proof section gives a reason for N/A and describes the before and after output from the real catalogs. The Linked Issue cites a localization tracking issue (Refs #32207) rather than an issue that the PR fixes, and the template asks for 'Fixes #'. The Risk section names the riskiest part and gives a revert path. The AI Disclosure section is empty. The PR's own pre-merge checklist leaves the lint, typecheck, test and build item unchecked.

Resolution

Consider linking an issue that this PR fixes, rather than a tracking issue that it only partly covers. Fill in the AI Disclosure section if an AI model was used, or confirm it does not apply. Confirm the lint, typecheck, test and build run, or note that CI covers them.

  • 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.

Share

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 12a7ec7f-6b7a-40c6-be1e-a78b3d7d8a14
Commits

Reviewing files that changed from the base of the PR and between 063a6d7 and 511d90c.

Files selected for processing: 14

  • mobile/src/host-screen/workspace-actions/use-workspace-row-menu-actions.ts
  • mobile/src/i18n/locales/de.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/new-workspace/source-selection/presentation/new-workspace-project-targets.ts
  • mobile/src/worktree/row-presentation/worktree-host-context-labels.test.ts
  • mobile/src/worktree/row-presentation/worktree-host-context-labels.ts
  • mobile/src/worktree/workspace-list/workspace-status-label.test.ts
Files skipped from review as they are similar to previous changes: 9

  • mobile/src/i18n/locales/de.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

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

nwparker added a commit to x-Ai/orca that referenced this pull request Nov 29, 2026
The mobile app showed the shipped workspace status names (Todo, In
progress, In review, Done) and this computer's built-in name (Local Mac,
Local Windows, Local Linux, This computer) in English in the status
sections, the status sheet, the row menu, the workspace options host
list, and the new-workspace run target picker.

Translate a status name only when it is still the shipped default, and
translate this computer's name only when the host has no name of its
own, so names users set stay literal, as on desktop.

Original fix by @x-Ai in stablyai#52318.

Co-authored-by: Neil <[email protected]>
@nwparker
nwparker force-pushed the fix/mobile-zh-status-host-pickers branch from 063a6d7 to 36d2478 Compare November 29, 2026 07:03
The mobile app showed the shipped workspace status names (Todo, In
progress, In review, Done) and this computer's built-in name (Local Mac,
Local Windows, Local Linux, This computer) in English in the status
sections, the status sheet, the row menu, the workspace options host
list, and the new-workspace run target picker.

Translate a status name only when it is still the shipped default, and
translate this computer's name only when the host has no name of its
own, so names users set stay literal, as on desktop.

Original fix by @x-Ai in stablyai#52318.

Refs stablyai#32207

Co-authored-by: Neil <[email protected]>
@nwparker
nwparker force-pushed the fix/mobile-zh-status-host-pickers branch from 36d2478 to 511d90c Compare November 29, 2026 07:04
@nwparker nwparker changed the title fix(mobile): show built-in status and computer names in the UI language fix(mobile): translate built-in workspace status names and this computer's name Nov 29, 2026
@nwparker
nwparker merged commit 8ee032c into stablyai:main Nov 29, 2026
29 of 30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants