feat(i18n): add Italian (it) locale#30719
Open
bedirhancode wants to merge 1 commit into
Open
Conversation
Adds Italian as a selectable language. Translation dict comes from the submission in anomalyco#28641. Restored the diacritics that were stripped from the original submission (più, può, sarà, attività, etc.) and the native scripts on the other-language labels in the dict (Español, Français, Türkçe, Português (Brasil)) to match en.ts. Wired it through the loader in packages/app/src/context/language.tsx (type union, LOCALES, INTL, LABEL_KEY, loaders, localeMatchers), added language.it: Italiano to every existing locale file, and registered the new locale in the parity test. packages/ui/src/i18n/it.ts is an empty placeholder so the loader's dynamic import succeeds; UI keys fall through to the English dict via the merge. Happy to leave that for a native speaker to fill in. Closes anomalyco#28641
Contributor
|
The following comment was made by an LLM, it may be inaccurate: Potential Duplicate Found:
This appears to be a duplicate of the current PR #30719. Both are adding the Italian (it) locale to the i18n system. You should check the status of PR #28232 to see if it's already been merged or closed, and whether the current PR #30719 should be closed in favor of it or vice versa. |
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.
Issue for this PR
Closes #28641
Type of change
What does this PR do?
Adds Italian (
it) as a selectable language in the Desktop / Web UI. The translation dictionary is the one the original reporter pasted in the issue — I used their work as the source and didn't invent any new translations.Two small adjustments I made to that source before committing:
The submission had the diacritics stripped from everything — words like
più,può,sarà,attività,già,cosìwere all written without their accents, and the other-language labels in the dict were"Espanol","Francais","Turkce","Portugues (Brasil)". I restored the diacritics on the obvious Italian words and put the language labels back into their native scripts so they matchen.ts("Español","Français","Türkçe","Português (Brasil)"). I did not do a full linguistic review — a native Italian speaker should follow up if any phrasing reads off.I wrote
packages/ui/src/i18n/it.tsas an empty placeholder (export const dict: Record<string, string> = {}) so the loader's dynamic import inlanguage.tsxdoesn't fail. UI keys fall through to the English base dict via the existing merge logic. I didn't want to invent translations for the UI strings either — leaving that for a native speaker.Other changes:
itintopackages/app/src/context/language.tsx: type union,LOCALES,INTL,LABEL_KEY,loaders,localeMatchers. New entries appended at the end, matching thetrprecedent."language.it": "Italiano"to every existing locale file (18 files, one line each).itinpackages/app/src/i18n/parity.test.ts.How did you verify your code works?
bun run typecheck— clean, 22/22 tasks successful.bun run lint— 0 errors (the 3486 pre-existing warnings are untouched).bun test packages/app/src/i18n/parity.test.ts— passes including the newitlocale.en.tsandit.tsside-by-side to confirm the dict has at least the requiredcommand.session.previous.unseen/command.session.next.unseenkeys and they differ from English.bun typecheckbefore the push and passed.Screenshots / recordings
No UI rendering change — strings only. The language picker will now list Italian as an option; selecting it switches the visible labels to the Italian dict.
Checklist