Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
b316b93
fix(sidebar): keep the toolbar labels in the selected UI language (#1…
5Hyeons Aug 4, 2026
a1fe9c5
fix(i18n): format the stats date with the selected UI language (#12105)
smwbev Aug 4, 2026
5aab004
fix(plugins): let language packs translate plugin chrome (#12455)
smwbev Aug 4, 2026
853c204
fix(i18n): localize the integration card status pills (#12208)
smwbev Aug 4, 2026
ae3fa00
fix(i18n): localize the Link Routing description in browser settings …
m-a-king Aug 4, 2026
4a71d26
fix(i18n): localize automation contextual tour (#12270)
5Hyeons Aug 4, 2026
f65e7a7
fix(i18n): correct the ko and zh Orca Mobile "New" badge (#10664)
AmethystLiang Aug 4, 2026
4ee8ffc
fix(i18n): pin the Orca Mobile "New" badge override and correct ja
nwparker Aug 4, 2026
5b2eaaa
fix(i18n): translate remaining zh.json strings (#12368)
qiuyongjin Aug 4, 2026
b9bb0a9
fix(i18n): localize browser load-failure and certificate copy (#10672)
MumuTW Aug 4, 2026
d0d5eb0
fix(i18n): correct ja Push/Pull button translations (#12301)
Iris-Fla Aug 4, 2026
0c490c2
fix(i18n): correct semantic errors in Korean UI copy (#11169)
kyu4583 Aug 4, 2026
2381051
fix(localization): stop the repair policy rewriting translated generi…
AnddyAgudelo Aug 4, 2026
3823e88
fix(i18n): repair the stale SshTargetForm ko override
nwparker Aug 4, 2026
c39972b
fix(i18n): stop repairCatalog crashing on un-bootstrapped locale keys…
Turtle-Hwan Aug 4, 2026
32d3016
fix(i18n): format relative times with the configured UI language (#8662)
moseoh Aug 4, 2026
641d295
fix(i18n): localize the remaining pull-policy and PR-action reasons (…
AmethystLiang Aug 4, 2026
cd02c21
fix(i18n/ko): standard loanword transcription and terminology fixes (…
tykimseoul Aug 4, 2026
4188a9d
fix(i18n): stop the repair policy de-localizing CJK UI labels
nwparker Aug 4, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions config/scripts/locale-cross-locale-key-overrides.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -134,5 +134,30 @@ export const CROSS_LOCALE_KEY_OVERRIDES = {
'auto.hooks.useSettingsNavigationMetadata.40d80bad8a': {
zh: '测试版',
ja: 'ベータ'
},
// Issue/PR state picker; it sits beside 已关闭, so 进行中 is a different state.
'auto.components.PullRequestPage.7b8f6bf6d8': {
zh: '开放'
},
// This "Open" is the button that opens the config file, not an issue state.
'auto.components.settings.McpConfigFileRow.e720c139cd': {
zh: '打开'
},
// Terminal cursor-color group: the on-screen cursor, not the Cursor editor.
'auto.components.settings.TerminalWindowSection.c9e1fdf42f': {
ko: '커서',
zh: '光标'
},
'auto.components.onboarding.ThemeStep.ab2a583a97': {
ko: '커서',
zh: '光标'
},
// Tailwind swatch labels: bare 天空 (the sky), 锌 and 空 (the metal, the sky) are not colors.
'auto.components.sidebar.workspace.status.6437a8c253': {
zh: '天蓝',
ja: '空色'
},
'auto.components.sidebar.workspace.status.caabd5ca85': {
zh: '锌灰'
}
}
102 changes: 102 additions & 0 deletions config/scripts/locale-generic-ui-terms.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
// Ordinary UI vocabulary that reads like a brand but is not one. Every locale should translate
// these, so the policy must neither pin the whole value to English nor revert the translation
// inside a sentence. The product-name homonyms (Continue.dev, the agent entries) stay Latin
// through ENGLISH_ONLY_KEY_PREFIXES, which matches on the catalog key rather than the word.

// Renderings a locale is expected to use. They are translations, never machine-translation
// errors, so a brand revert must leave them alone. Nonsense forms that share the same English
// term (zh 回购 "repurchase agreement", ja 端子 "electrical connector", es "Comprometerse")
// stay in BRAND_MISTRANSLATIONS and keep getting reverted.
const GENERIC_TERM_FAMILIES = [
{
terms: ['Agent', 'Agents', 'agent', 'agents'],
renderings: {
ko: ['에이전트'],
ja: ['エージェント'],
zh: ['代理', '智能体'],
es: ['Agente', 'agente', 'Agentes', 'agentes']
}
},
{
terms: ['Commit', 'Commits', 'commit', 'commits'],
renderings: {
ko: ['커밋'],
ja: ['コミット'],
zh: ['提交'],
es: [
'Confirmación',
'confirmación',
'Confirmaciones',
'confirmaciones',
'Confirmar',
'confirmar'
]
}
},
{
terms: ['Continue'],
renderings: {
ko: ['계속하다', '계속'],
ja: ['続ける', '続行'],
zh: ['继续'],
es: ['Continuar', 'continuar']
}
},
{
terms: ['Repo', 'Repos', 'repo', 'repos'],
renderings: {
ko: ['저장소', '레포'],
ja: ['リポジトリ', 'リポ'],
zh: ['存储库', '仓库'],
es: ['Repositorio', 'repositorio', 'Repositorios', 'repositorios']
}
},
{
terms: ['Terminal', 'Terminals', 'terminal', 'terminals'],
renderings: {
ko: ['터미널'],
ja: ['ターミナル'],
zh: ['终端'],
es: ['Terminales', 'terminales']
}
}
]

export const LOCALIZABLE_GENERIC_TERMS = new Set(
GENERIC_TERM_FAMILIES.flatMap((family) => family.terms)
)

const RENDERINGS_BY_TERM = new Map(
GENERIC_TERM_FAMILIES.flatMap((family) => family.terms.map((term) => [term, family.renderings]))
)

export function isLocalizableGenericTerm(term) {
return LOCALIZABLE_GENERIC_TERMS.has(term)
}

export function isCanonicalGenericRendering(term, locale, form) {
return RENDERINGS_BY_TERM.get(term)?.[locale]?.includes(form) ?? false
}

export function canonicalGenericRenderings(locale) {
return GENERIC_TERM_FAMILIES.flatMap((family) =>
(family.renderings[locale] ?? []).map((form) => ({ form, terms: family.terms }))
)
}

function spansOf(value, needle) {
const spans = []
for (let at = value.indexOf(needle); at !== -1; at = value.indexOf(needle, at + 1)) {
spans.push([at, at + needle.length])
}
return spans
}

// Why: zh 终端子进程 ("terminal sub-process") contains 端子, so a blind revert of the
// electrical-connector mistranslation would cut a valid word in half.
export function overlapsCanonicalRendering(term, locale, value, start, end) {
const renderings = RENDERINGS_BY_TERM.get(term)?.[locale] ?? []
return renderings.some((form) =>
spansOf(value, form).some(([from, to]) => start < to && from < end)
)
}
174 changes: 174 additions & 0 deletions config/scripts/locale-generic-ui-terms.test.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,174 @@
import { describe, expect, it } from 'vitest'

import { LOCALIZABLE_GENERIC_TERMS } from './locale-generic-ui-terms.mjs'
import { NEVER_TRANSLATE_VALUES, repairTranslatedValue } from './locale-translation-policy.mjs'

// Why: #12113 — repair-locale-catalog rewrote ~2000 translated values back to English because
// generic UI words (agent, terminal, commit, repo, Continue) were treated as brands. These pin
// the boundary: generic words stay translated, real brand names stay Latin.
describe('locale generic UI terms', () => {
it('keeps a translated generic term when the whole value is that term', () => {
expect(
repairTranslatedValue({
key: 'auto.components.settings.AppearancePane.terminalTitle',
enValue: 'Terminal',
localeValue: '터미널',
locale: 'ko'
})
).toBe('터미널')
expect(
repairTranslatedValue({
key: 'auto.components.settings.QuickCommandsPane.4ccc63da87',
enValue: 'Agent',
localeValue: '에이전트',
locale: 'ko'
})
).toBe('에이전트')
expect(
repairTranslatedValue({
key: 'auto.components.mobile.MobileHero.a8fb43cf1c',
enValue: 'Continue',
localeValue: '继续',
locale: 'zh'
})
).toBe('继续')
})

it('keeps a translated generic term inside a sentence', () => {
expect(
repairTranslatedValue({
key: 'auto.components.settings.EditorFontSection.matchTerminal',
enValue: 'Match terminal font',
localeValue: '터미널 글꼴과 동일',
locale: 'ko'
})
).toBe('터미널 글꼴과 동일')
expect(
repairTranslatedValue({
key: 'auto.components.settings.ExperimentalPane.agentDashboard.toggleLabel',
enValue: 'Toggle Agent Dashboard',
localeValue: '에이전트 대시보드 전환',
locale: 'ko'
})
).toBe('에이전트 대시보드 전환')
expect(
repairTranslatedValue({
key: 'components.agentSessionContinuation.dialogTitle',
enValue: 'Continue in New Session',
localeValue: '新しいセッションで続ける',
locale: 'ja'
})
// 新しい → 新規 is an unrelated phrase fix; 続ける is what must survive.
).toBe('新規セッションで続ける')
})

it('still reverts real brand names that machine translation localized', () => {
expect(
repairTranslatedValue({
key: 'auto.stats.StatsPane.7d26110cea',
enValue: 'Codex',
localeValue: '사본',
locale: 'ko'
})
).toBe('Codex')
expect(
repairTranslatedValue({
key: 'auto.components.settings.appearance.search.9ae151b26b',
enValue: 'linear',
localeValue: '线性',
locale: 'zh'
})
).toBe('Linear')
expect(
repairTranslatedValue({
key: 'auto.components.settings.NetworkPane.tailscale',
enValue: 'Connect over Tailscale',
localeValue: '通过尾鳞连接',
locale: 'zh'
})
).toBe('通过 Tailscale 连接')
})

it('still reverts nonsense renderings of a generic term', () => {
// 端子 is an electrical connector, 回购 a repurchase agreement, Comprometerse "to pledge".
expect(
repairTranslatedValue({
key: 'auto.components.agent.AgentCombobox.986f946354',
enValue: 'Blank Terminal',
localeValue: '空白端子',
locale: 'zh'
})
).toBe('空白 Terminal')
expect(
repairTranslatedValue({
key: 'auto.components.right.sidebar.source.control.primary.action.ed93b4f14f',
enValue: 'Commit',
localeValue: 'Comprometerse',
locale: 'es'
})
).toBe('Commit')
expect(
repairTranslatedValue({
key: 'auto.components.LinearIssueMarkdownDescriptionEditor.d9c47069ef',
enValue: 'Markdown',
localeValue: '가격 인하',
locale: 'ko'
})
).toBe('Markdown')
})

it('does not cut a valid word that contains a nonsense rendering', () => {
// 终端子进程 is "terminal sub-process" — 端子 sits inside 终端 + 子.
expect(
repairTranslatedValue({
key: 'auto.components.settings.AdvancedNetworkSettingsSection.823e0f15b1',
enValue: 'Proxy URL for Orca network requests and local terminal subprocesses.',
localeValue: '用于 Orca 网络请求和本地终端子进程的代理 URL。',
locale: 'zh'
})
).toBe('用于 Orca 网络请求和本地终端子进程的代理 URL。')
})

it('still fills in a translation when the catalog holds English', () => {
expect(
repairTranslatedValue({
key: 'auto.components.feature.wall.BrowserAnimatedVisual.04096318ab',
enValue: 'Terminal 1',
localeValue: 'Terminal 1',
locale: 'ko'
})
).toBe('터미널 1')
expect(
repairTranslatedValue({
key: 'auto.store.slices.worktrees.889487d8bb',
enValue: 'Dismiss',
localeValue: '해고하다',
locale: 'ko'
})
).toBe('닫기')
})

it('keeps agent catalog product names in English by key, not by word', () => {
expect(
repairTranslatedValue({
key: 'auto.lib.agent.catalog.9e2a9bb87b',
enValue: 'Continue',
localeValue: '继续',
locale: 'zh'
})
).toBe('Continue')
expect(
repairTranslatedValue({
key: 'auto.lib.agent.catalog.760bc6883d',
enValue: 'Codex',
localeValue: '사본',
locale: 'ko'
})
).toBe('Codex')
})

it('does not list a generic term as never-translatable', () => {
const pinned = [...LOCALIZABLE_GENERIC_TERMS].filter((term) => NEVER_TRANSLATE_VALUES.has(term))
expect(pinned).toEqual([])
})
})
4 changes: 2 additions & 2 deletions config/scripts/locale-ja-value-overrides.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ export const JA_VALUE_OVERRIDES = {
'Launch plan': '起動プラン',
'Launch agent': 'エージェントを起動',
'Launch {{value0}} in a new terminal': '新規ターミナルで {{value0}} を起動',
Play: 'Play',
Play: '再生',
Action: '操作',
Actions: '操作',
action: '操作',
Expand Down Expand Up @@ -135,7 +135,7 @@ export const JA_VALUE_OVERRIDES = {
'Pick a base branch below': '以下のベースブランチを選択',
'Choose floating workspace directory': 'フローティング ワークスペース ディレクトリを選択',
'Local project, Git repo, or folder with many repos':
'ローカルプロジェクト、Git repo、または多数の repos を含むフォルダー',
'ローカルプロジェクト、Git リポジトリ、または多数のリポジトリを含むフォルダー',
'Enter passphrase': 'パスフレーズを入力',
'Enter password': 'パスワードを入力',
'Enter the passphrase for': 'のパスフレーズを入力',
Expand Down
11 changes: 6 additions & 5 deletions config/scripts/locale-key-overrides.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,8 @@ const BASE_LOCALE_KEY_OVERRIDES = {
ja: 'クローズ'
},
'auto.components.GitHubItemDialog.dc1ca081a8': {
ko: '진행 중',
zh: '进行中',
ko: '열림',
zh: '开放',
ja: 'オープン'
},
'auto.components.tab.bar.TabBarCreateEntry.b27864279e': {
Expand All @@ -176,10 +176,11 @@ const BASE_LOCALE_KEY_OVERRIDES = {
zh: '打开 Linear 任务',
ja: 'Linear タスクを開く'
},
// Onboarding pill beside Orca Mobile: "New" marks a new feature, not a create action.
'auto.components.sidebar.SidebarNav.c86d83b5c3': {
ko: '새로 만들기',
zh: '新建',
ja: '新規'
ko: '신규',
zh: '新功能',
ja: '新機能'
},
'auto.components.sidebar.SidebarSettingsHelpMenu.eb9884e55b': {
ko: 'Discord',
Expand Down
Loading
Loading