feat: add i18n support#232
Merged
Merged
Conversation
- Integrated translation functionality using react-i18next in the following files: - Conversations page - Document editor page - Backlog page - Sprint page - Timeline page - Settings page - Task detail page - Team management page - Change password page - Login page - Updated static text to use translation keys for better localization support. - Added LanguageToggle component to the header for language switching. - Configured TypeScript to resolve JSON modules for translation files.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Adds a full i18n foundation to
apps/weband translates the entire UI into 7 languages: English, Vietnamese, Korean, Simplified Chinese, Japanese, Spanish, and French.Architecture
i18next+react-i18next+i18next-browser-languagedetector.localStorage, keylocale), mirroring how theme is already handled — no backend changes, no new user-preference column.import.meta.glob), no runtime fetch/lazy-loading.t("wrong.key")fails the build at compile time.common,auth,appShell,profile,admin,projects,plugins,shared,errors(63 JSON files total: 9 namespaces × 7 languages).<html lang>sync: now kept in sync with the active locale (previously hardcoded to"en"), which also unlocks locale-scoped CSS (see font fix below).Scope
t()calls — essentially the entire authenticated app (admin, projects, profile, app shell/nav, shared components) plus the public auth pages.Intl.DateTimeFormat-based helper (lib/format-date.ts) instead of a hardcoded"en-US"locale.Be Vietnam Pro) swapped in viahtml[lang="vi"], since the default fonts (Syne/DM Sans) render Vietnamese tone marks with visible hinting glitches.Translation caveat
The 6 non-English locales (vi, ko, zh-CN, ja, es, fr) are LLM-translated with no human reviewer in the loop. Each was independently verified for key parity and
{{interpolation}}placeholder integrity against the English source, so nothing is missing or broken — but the wording should get a native-speaker pass before this is the language real non-English users see in production.Verification
tsc -b,biome check, and the full Vitest suite (261 tests) all pass.vite build) verified — confirmed the locale-loading and CSS cascade (font override) resolve correctly in the compiled bundle, not just in dev.LanguageToggle.test.tsx(opens the language dropdown, selects a language, asserts the locale andlocalStorageupdate).Out of scope / follow-ups