Repository navigation
i18n: add Persian (fa-IR) translation - #91
Merged
Merged
Conversation
Adds a complete fa-IR locale: all 814 neutral keys are translated, placeholders are preserved verbatim, and no em dashes are used. Technical terms follow the existing per-locale convention: Registry, Driver, Firmware, Secure Boot, VBS, UEFI, DDR/SSD/NVMe, MT/s, MHz, Shell, Hibernation, GPU/CPU/RAM and product names stay English, while Service, Scheduled Task and Power Plan get natural Persian equivalents. Registered in SupportedLanguages.All, which the test gate reads, so EveryNeutralKey_ResolvesInEverySupportedLanguage and EveryLocale_PreservesNeutralPlaceholderSets cover fa-IR.
itsfatduck
approved these changes
Oct 7, 2026
itsfatduck
left a comment
Owner
There was a problem hiding this comment.
Thank you so much for the Persian translation and for taking the time to verify everything so thoroughly!
Also, thanks for pointing out the RTL layout issues. I'll look into those separately.
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.
Adds the Persian (fa-IR) locale.
What
Translations.fa-IR.resxwith all 814 neutral keys translatedDomain/UI/SupportedLanguages.csTranslation decisions
Follows the per-locale convention already documented in
AGENTS.md:Snap Layouts,Widgets,Click To Do.{0}are preserved verbatim, including multi-placeholder sets ({0}/{1}/{2}).50 مگابایت,24 ساعت,64 بیتی) becausefa-IRon .NET rendersDigitSubstitution=Context, i.e.Loc.Instance["Key", value]also produces Latin digits. Persian digits for the literals would have mixed with the code-supplied ones on the same screen.Verification
resx_audit: 0 missing, 0 empty, 15 values identical to English (DDR/SDRAM/UEFI/NVMe and similar identifiers)dotnet build optimizerDuck.slnx --configuration Release: 0 warnings, 0 errorsLanguageManagerTests.EveryNeutralKey_ResolvesInEverySupportedLanguageandEveryLocale_PreservesNeutralPlaceholderSetspass with fa-IR registered-longRunning 30:Total: 738, Errors: 0, Failed: 0, Skipped: 5csharpier check .: clean (302 files)Review notes
15 values are byte-identical to English on purpose (hardware and firmware identifiers). Everything else is translated.
RTL is picked up automatically:
Loc.DirectionflipsFlowDirectionon the root grid, sofa-IRrenders right-to-left likear-SAandhe-IL.One pre-existing limitation is worth flagging, since it shows up in this locale: WPF mirrors only text direction and
TextAlignment, never layout. The optimization card template hardcodes LTR layout (HorizontalAlignment="Left"for the tag row,StackPanel Orientation="Horizontal"inside a tag,Grid ColumnDefinitions="*,Auto"for the footer), so three spots read wrong in any RTL language: the tag row, the icon inside a tag, and the footer order. I left it alone to keep this PR translation-only, but it affectsar-SAandhe-ILequally and is worth a separate fix.Closes the Persian translation request.