Localization — Foundations Skill
Purpose
Route Apple-platform localization implementation tasks to the minimum
required Knowledge Contracts. v1 covers how an app's user-facing strings
and resources are extracted, stored, varied, and resolved across languages
and regions -- not Xcode project configuration, translator XLIFF workflow,
runtime content translation, source-copy style rules, value formatting, or
RTL visual design. Baseline is Xcode 16+ with an iOS 17+ API surface;
String Catalogs impose no deployment-target cost, since .xcstrings
compiles to .strings/.stringsdict at build time.
Routing
Load only the contracts relevant to the task. All paths relative to knowledge/localization/.
- Creating or populating a
.xcstringsString Catalog; extraction and the literal requirement; translatorcomment:; New/Needs Review/Translated/Stale states; explicit keys vs. value-as-key; manually-managed entries; "Don't Translate"; migrating a.strings/.stringsdicttable -> string-catalogs-and-extraction.md - Calling
String(localized:),LocalizedStringResource,LocalizedStringKey,Text/Text(verbatim:),AttributedString(localized:), orNSLocalizedString; format specifiers; thelocale:parameter -> localized-string-apis.md - Varying a string by count or device; CLDR plural categories;
substitutions;
.stringsdict;^[...](inflect: true)-> plural-and-device-variations.md Locale.current/autoupdatingCurrent;preferredLanguages/preferredLocalizations;Locale.Language/Locale.Region;CFBundleDevelopmentRegion; the.lprojfallback chain -> locale-and-language-resolution.md- RTL layout;
\.layoutDirection;flipsForRightToLeftLayoutDirection;semanticContentAttribute;effectiveUserInterfaceLayoutDirection; SF Symbols mirroring;characterDirection; RTL pseudolanguages -> layout-direction-and-rtl-apis.md InfoPlist.xcstrings/InfoPlist.strings;CFBundleDisplayName/CFBundleName;.lprojstructure; localizing assets;Bundle.module/defaultLocalization;Bundle.localizedString(forKey:value:table:)-> localized-resources-and-infoplist.md
Never load more than the contracts relevant to the specific question.
Stop Conditions
Stop and report if the requested topic has no matching Knowledge Contract in knowledge/localization/ -- do not guess or fall back to general knowledge.
- Adding a language to an Xcode project and the
.xcloc/XLIFF export-and-import round trip — owned byxcode - The iOS 18 Translation framework (
TranslationSession,.translationTask,.translationPresentation) — Excluded; real and documented, so neither fabricate guidance for it nor claim it does not exist - Source-copy wording, capitalization, punctuation, and international
representation/formatting — owned by
style-guide - Date, time, number, and measurement formatting — owned by
foundation - RTL visual-design decisions — owned by
human-interface-guidelines - App Shortcuts phrase and
AppEnumlocalization — owned byapp-intents - App Store Connect localized metadata, APNs
loc-key/loc-argspayloads, macOS/watchOS/tvOS-specific behavior — Excluded - Apple publishes no
.xcstringsschema -- never assert its JSON field names
