-
Notifications
You must be signed in to change notification settings - Fork 0
Localization
The app supports Follow System, English, and Simplified Chinese. English is the development fallback for identifiers, comments, logs, diagnostics, and missing UI translations. User-visible application text is localized; logs and protocol/error details do not change with UI language.
Localizable.xcstrings is the String Catalog. The persisted app language is loaded with application settings and exposed through AppState.resolvedLocale; app scenes and hosted presentation roots receive that locale environment. AppLocalization in MacOSCompatibility.swift resolves runtime keys for AppKit menus and other independently hosted/transient UI so they honor the in-app language instead of silently following only the macOS system language.
Use String(localized:), SwiftUI localization keys, or the shared app-aware resolver. Do not introduce Android-style TextPair, hard-coded English/Chinese branches, or page-local translations.
- Add an English key and Simplified Chinese translation to
Localizable.xcstrings. - Use the localization mechanism appropriate to SwiftUI or an AppKit/transient surface.
- Localize labels, errors shown to users, prompts, help text, empty states, and accessibility descriptions together.
- Keep technical diagnostic detail in English; map it to a safe localized summary when it reaches UI.
Test Follow System, English, and Simplified Chinese for normal pages, sheets/alerts, menus, prompts, and accessibility text. Check interpolation/plural formatting in both languages and retain in-progress state while switching when the framework permits it.