feat(webui): add Brazilian Portuguese (pt-BR) locale
Translate the WebUI common.json to pt-BR, register the locale in config.ts (with normalizeLocale rules for "pt", "pt-BR", "pt-PT", ...) and index.ts resources, and add a Brazilian Portuguese overview assertion in i18n.test.tsx. Notes: - Generic "pt" and any "pt-*" variant resolve to pt-BR. A future pt-PT locale can be added without affecting existing users. - Universally borrowed technical terms (nanobot, BYOK, MCP, JSON, URL, Web, Apps when used as a product name, Skills) are kept in English, matching the pattern used by es/fr/ja/ko/vi/id. - Empty-thread greetings, quick-action prompts, and slash command descriptions are translated; quick-action prompts are intentionally phrased so the agent still receives a clear task spec. Verified with bun run test (536 passing), bun run lint (clean), and bun run build (7.18s).
This commit is contained in:
committed by
chengyongru
parent
4a3818e03c
commit
1e7518a207
@@ -19,6 +19,7 @@ import frCommon from "./locales/fr/common.json";
|
||||
import jaCommon from "./locales/ja/common.json";
|
||||
import koCommon from "./locales/ko/common.json";
|
||||
import esCommon from "./locales/es/common.json";
|
||||
import ptBRCommon from "./locales/pt-BR/common.json";
|
||||
import viCommon from "./locales/vi/common.json";
|
||||
import idCommon from "./locales/id/common.json";
|
||||
|
||||
@@ -30,6 +31,7 @@ export const resources = {
|
||||
ja: { common: jaCommon },
|
||||
ko: { common: koCommon },
|
||||
es: { common: esCommon },
|
||||
"pt-BR": { common: ptBRCommon },
|
||||
vi: { common: viCommon },
|
||||
id: { common: idCommon },
|
||||
} as const;
|
||||
|
||||
Reference in New Issue
Block a user