Zum Inhalt springen
Skillpedia
Websites & UI (Frontend)7.6k · #13165

internationalization

Was er macht

Dieser Skill beschreibt, wie man nutzersichtbaren Text in den Übersetzungskatalogen der App pflegt. Er behandelt, welche Sprachen genutzt werden, wie Schlüssel benannt werden und wie die Übersetzungsprüfung läuft. Er richtet sich an Entwickler, die Text in mehrsprachigen Apps hinzufügen oder ändern.

Wann du ihn nutzt

  • ✓Wenn du sichtbaren Text, Beschriftungen, Hinweismeldungen oder Leerzustände in einer App hinzufügst oder änderst.
  • ✓Wenn eine App weitere Sprachen freigegeben hat und deren Kataloge aktualisiert werden müssen.
  • ✓Wenn eine Sprachauswahl Sprachen zeigt, die die App nicht wirklich laden kann.

Link zum Skill

https://github.com/BuilderIO/agent-native/blob/main/.agents/skills/internationalization/SKILL.md

Kopiere ihn und füge ihn in deine KI ein (Claude, ChatGPT oder Cursor) mit der Bitte, den Anweisungen zu folgen.

So nutzt du ihn

Am einfachsten: Kopiere die Nachricht und füge sie in deine KI ein. Sie liest den Skill und folgt den Anweisungen.

Fertige Nachricht zum Einfügen

Nutze diesen Skill, um mir zu helfen: https://github.com/BuilderIO/agent-native/blob/main/.agents/skills/internationalization/SKILL.md Lies die SKILL.md unter diesem Link und folge ihren Anweisungen für meine Aufgabe.
Soll deine KI Skills wie diesen selbst finden?Installiere den kostenlosen Skillpedia-MCP: eine Zeile, und sie durchsucht vor jeder Aufgabe 15.000+ Skills.In 1 Minute installieren →

Beispielanfrage an deine KI

“Kannst du dem Einstellungsbildschirm eine neue Beschriftung hinzufügen und auch die französische und deutsche Übersetzung aktualisieren?”

5 neue Skills pro Woche. 1 Minute Lesezeit.

So funktioniert es

Der Agent fügt den Text zuerst dem englischen Katalog hinzu und aktualisiert dann nur die Sprachen, die die App aufführt. Er behält dieselben Schlüssel und Platzhalter bei und führt die i18n-Prüfung aus.

Technischer Inhalt (originale SKILL.md)

Originaltext des Autors, auf Englisch, direkt von GitHub.

Internationalization — opt-in translations

English (en-US) is the default source locale. Do not create or update additional locale catalogs unless the app's agent-native.config.ts lists them under translations.locales.

Rule

Visible framework/template UI copy belongs in the app's i18n catalog, not inline in components. When you add or edit UI text, update the English source catalog first, then update only the locale catalogs listed in translations.locales, and run the i18n guard.

Catalogs

Templates use app/i18n/:

  • en-US.ts is the canonical source tree and fallback.
  • Other locale files keep the same non-plural keys and the same placeholders.
  • index.ts exports an AgentNativeI18nCatalog with English bundled and non-English catalogs loaded by dynamic import.

Use BCP-47 filenames from the supported set: en-US, zh-CN, es-ES, fr-FR, de-DE, ja-JP, ko-KR, pt-BR, hi-IN, ar-SA.

If an app only ships translations for a subset of that set, set supportedLocales on the AgentNativeI18nCatalog to that subset. Without it, <LanguagePicker /> lists every framework-supported locale regardless of whether loadMessages can actually resolve it.

UI Pattern

  • Wrap apps with AppProviders i18n={{ catalog: i18nCatalog }}.
  • Read strings with useT() and keep keys stable.
  • Apps expose a /settings route without a sidebar item for it: Settings opens from the account menu in the sidebar footer and from ⌘, (Ctrl+, elsewhere). Core's Account › Preferences page already renders the Interface language row (with Timezone; both are the per-user localization record, so a change applies in every app); don't add a second picker to an app's Settings page. Keep the header language icon only as a quick-access shortcut.
  • Don't add an "Agent settings" row to an app's settings page: the Agent group's pages are part of Settings. Link to a page with buildSettingsRoute(page, sub?), and localize the link's label.
  • Settings copy follows the same rules: page and group labels are core agentChat.settingsShell.* keys, and an app's own rows, areas, and search entries take already translated strings from the app catalog.
  • Use useFormatters() for dates, numbers, relative time, and lists instead of embedding formatted values in translation strings.
  • Do not translate stable identifiers: action names, route names, enum values, app-state keys, database values, protocol fields, env var names, or provider names.

Plurals And Placeholders

Plural strings use i18next/CLDR suffixes. Do not force every locale to copy English plural categories:

  • English uses _one and _other.
  • Chinese and Japanese usually use _other.
  • Arabic uses _zero, _one, _two, _few, _many, and _other.

Keep interpolation placeholders identical across locales, such as {{count}}, {{name}}, or ICU-style {count} arguments.

RTL

New UI should be RTL-safe. Prefer logical CSS utilities/properties such as ms-*, me-*, ps-*, pe-*, start-*, end-*, text-start, and text-end when direction matters. Avoid hardcoded left/right positioning for new localized UI unless it is genuinely physical.

Verification

Run:

pnpm guard:i18n-catalogs

For broader changes, also run the affected template tests and pnpm typecheck. Machine translation is only a starting point; high-visibility strings need human review.

Häufige Fragen

Ist Übersetzung standardmäßig aktiv?

Nein. Apps müssen andere Sprachen in ihrer Konfiguration freigeben. Englisch ist die Standardsprache.

Muss ich jede Sprachdatei ändern?

Nur die Sprachen, die die App als aktiviert auflistet. Der englische Katalog wird immer zuerst aktualisiert.

Darf ich Text direkt in eine Komponente schreiben?

Der Skill sagt, sichtbarer Text gehört in den Katalog und nicht direkt in Komponenten.

Details

Originalbeschreibung des Autors

How to add or edit localized UI copy in agent-native apps. Use when adding, removing, or changing user-visible interface text, prompts, toasts, labels, empty states, or date/number/list formatting. Apps opt in to additional locales from `agent-native.config.ts`.

repo: BuilderIO/agent-native

Beliebtheit

GitHub-Sterne
7.6k
Platz im Ranking
#13165
Lizenz
MIT
Aktualisiert
2.11.2026

Ist dieser Skill nützlich?

0

Anmelden um abzustimmen.

Kommentare

  • …

Weitere Skills aus diesem Repository

Ähnliche Skills