Skip to content

Show Icarus in Japanese and Simplified Chinese - #545

Merged
SunkenInTime merged 6 commits into
mainfrom
t3/plan-multilanguage-support
Nov 11, 2026
Merged

SunkenInTime merged 6 commits into
mainfrom
t3/plan-multilanguage-support

Conversation

@SunkenInTime

@SunkenInTime SunkenInTime commented Nov 11, 2026 •

Copy link
Copy Markdown
Owner

Editor in Japanese: the pages bar, tools, agents and an ability's name

Japanese Simplified Chinese
Library in Japanese Editor in Chinese with a placed agent's menu
Keybinds in Japanese Language picker in settings, in Chinese
Export video in Japanese Web build in Japanese, signed out

Icarus was English only. Players in Japan and China can now read it in their own language: it opens in the system's language (the browser's on web), and settings has a Language section to pick another.

What existed before

Every string was an English literal in the widget, provider or service that produced it, about 1,270 of them across 200 files.

What this does

  • One file per language. lib/l10n/app_en.arb is the source; app_ja.arb and app_zh.arb hold the same keys. Flutter's gen-l10n builds a typed AppLocalizations from them on every pub get and build (the output is git-ignored). Widgets read context.l10n, code without a widget reads l10nProvider. A mistyped key does not compile. test/l10n_test.dart fails when a language is missing a key or drops a placeholder.
  • Saved and compared text is untouched. Sync reasons kept in the outbox, startup reasons, replay decoder codes and everything written into the library or an .ica stay English, byte for byte, where they are produced, stored and matched. The words a user reads are chosen where they are drawn: friendlyCloudSyncError and its two siblings moved from lib/collab to lib/l10n/cloud_sync_error_text.dart with the same branch order. lib/collab still imports no UI, and convex/ is not touched.
  • Game names come from the game. Agents, abilities, roles, weapons and maps use Valorant's own Japanese and Chinese names, written into lib/l10n/official_game_names.dart by tool/fetch_game_names.dart (run it when a new agent ships). Icarus's data keeps its English names; the lookup happens at draw time.
  • Unnamed pages. A page nobody named is still saved as "Page 3". The pages bar and the export dialogs show it in the viewer's language, so a shared strategy reads right for each teammate.
  • Language preference. A nullable languageCode on AppPreferences (Hive field 28). Old records read as null, which means "follow the system"; a test writes a record without the field and reads it back.
  • Layout. The library strip's menus had widths sized for English and cut every Japanese label short; they now grow to fit.

English text and behaviour are meant to be unchanged. The lineup conflict summary ("renamed, notes edited") became typed change kinds, because it was glued from English fragments.

How far this got in a running app

  • Full test suite at the first commit: 3,553 passed, 14 skipped, none failed. Affected tests rerun after each later fix.
  • Windows, a build of this PR run on the Windows PC (system language English, so Japanese and Chinese were picked in settings): library, menus, folder and map dialogs, editor with agent and ability names, weapon menu, shapes, pages bar, export video, settings through keybinds, sign-in and sign-up, 28 screenshots per language. Text renders in Windows' own fonts with no missing characters, clipping or overlap. It found "Page 1" stamped inside screenshot images; fixed and rechecked.
Windows, Japanese Windows, Chinese
Editor on Windows in Japanese with the shapes panel Editor on Windows in Chinese
  • Linux desktop build on the t3os box, Japanese and Chinese each walked page by page by a second agent with screenshots (74 Japanese, 40 Chinese): first launch and welcome cards, library and its menus and dialogs, sign-in views and validation, the editor (agents, abilities, weapon menus, shapes, text, captions, lineups, map selector, pages bar), screenshot and video dialogs, every settings section, language switching live, replays empty state. Both opened in the system's language by themselves. The walks found the menu clipping, "Page 1" in the export dialogs, "Lotus" in the welcome picture and the rename issue below; all are fixed and I rechecked each on screen.
  • Web: the web build opened in Chrome with Japanese as the browser language came up in Japanese, signed out.
  • Two independent reviews of the diff (a second model, and Greptile) each found one issue: confirming an unnamed page's translated name saved it as that page's name, and KAY/O kept Icarus's spelling "Kayo". Both fixed.
  • The first CI run had one Windows test fail on a temp-folder "Access is denied" in image-cache code this PR does not touch; it passed on the next run.

Not covered

  • macOS was not run. Following the system language was seen on Linux and in Chrome, not on Windows (that PC is set to English).
  • Signed-in screens (share dialog, sync popover, move to cloud, signed-in web) were not seen in either language. Their strings are translated and checked for structure only.
  • Narrow windows were not checked.
  • Still English on purpose: release notes in What's new, built-in map theme names ("Default", "Lotus Moss"), default names saved into the library ("New Folder", "Bind 1", "(Copy)", replay capture names), the window title, native file pickers.
  • Web fonts: the browser fetches the Japanese and Chinese font from Google's font servers on first use. Not tested from mainland China.
  • Translations were written by agents against a glossary of the game's own terms and spot-checked by a second model, not read by a native player. Strategy is 作戦 / 战术, lineup is 定点 / 点位.
  • A Chinese system set to Traditional gets Simplified.
  • The driver scripts under tool/drive/scripts find controls by their English text, so a driver run needs an English system or English picked in settings.

ci: analyze test web desktop

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; no new blocking issue was found.

Summary

Adds Japanese and Simplified Chinese throughout Icarus, with a saved language choice and translated game names. The latest changes also translate automatic page names inside screenshots and video frames.

  • Icarus shows its screens in Japanese or Simplified Chinese.
  • The language picker remembers a player's choice between launches.
  • Game names and unnamed pages appear in the viewer's language.
  • Sync and lineup messages are built in the viewer's language.

Reviews (7) · Last reviewed commit: "Stamp exports with the page name as the ..." · Reviewed by Greptile

Every word the app shows now comes from lib/l10n/app_en.arb and its
translations, read through the generated AppLocalizations. The app follows
the system language and settings has a picker to override it.

Text that is saved, sent or compared stays English where it is produced and
is put into words where it is drawn: sync reasons in the outbox, startup
reasons, replay decoder codes. Agent, ability, weapon and map names come
from the game's own text (tool/fetch_game_names.dart).
The library strip's menus had fixed widths sized for English, which cut
every Japanese label short. Confirming an unnamed page's name unchanged
saved its translation; it keeps the saved "Page 3" now. The welcome tour's
picture names its map as the game does.
@coderabbitai

coderabbitai Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Pre-merge checks: Passed 1 · Inconclusive 1

Failed Failed checks: 1 inconclusive

Check name Status Explanation Resolution
Title check Pending This assessment has not completed. The check will be retried on the next pre-merge check run.
Passed Passed checks: 1 passed

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
  • 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

Comment thread lib/widgets/pages_bar.dart Resolved
The screenshot and video dialogs listed an unnamed page as "Page 1" beside a
pages bar that read it in the viewer's language. Confirming such a page's
translated name unchanged leaves it unnamed, where it used to save a name
teammates would read in the wrong language.
@SunkenInTime
SunkenInTime marked this pull request as ready for review November 11, 2026 09:38
Comment thread lib/l10n/game_names.dart Resolved
lib/const spells the agent "Kayo" for its asset folder, which matched no
name in the game's table, so Japanese and Chinese read "Kayo".
A screenshot or video of an unnamed page printed "Page 1" in its corner and
was saved as "Page 1.png" beside a dialog that named it in the viewer's
language.
@SunkenInTime
SunkenInTime merged commit 68e1c5e into main Nov 11, 2026
17 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.

1 participant