Translation Manager

Add and synchronize translation keys in en.json and fr.json files.

5|2|Updated Sep 4, 2024
One-click install
npx skills add https://github.com/tsiresymila1/youtube-dl-mobile --skill translation-manager
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Translation Manager
Source: https://github.com/tsiresymila1/youtube-dl-mobile/tree/main/.agent/skills/add-translation
Command: npx skills add https://github.com/tsiresymila1/youtube-dl-mobile --skill translation-manager

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This tool automates the safe addition and synchronization of translation keys across English and French localization files, reducing errors and speeding up UI updates.

Core Features & Use Cases

  • Two-way localization updates: Add or update keys in en.json and fr.json while keeping them in sync.
  • Key generation: If a key is not provided, generate one from the English text using snake_case.
  • JSON integrity: Ensures valid JSON syntax and consistent formatting.
  • Usage scenario: Ideal when onboarding new UI strings or updating translations for a new feature.
  • Dart/Flutter integration: Keys can be referenced in Dart code with the standard localization idioms (e.g., 'key_name'.tr()).

Quick Start

Provide the English text and optionally a key; the tool will read assets/translations/en.json and assets/translations/fr.json, generate a key if needed, insert the English key-value pair, add the French translation, and ensure the JSON remains valid. Then use the key in your code as 'key_name'.tr().

Frequently Asked Questions about Translation Manager

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add a new translation key to en.json and fr.json without breaking JSON formatting?

To add translation keys safely, provide English text and optionally a key; the tool inserts the pair into en.json and fr.json, generates a snake_case key if missing, and enforces valid JSON syntax to maintain parallel English and French mappings.

Can I generate a snake_case key automatically from English text when updating Flutter localization files?

Yes, you can generate a snake_case key automatically from English text when a key is not provided. The tool reads assets/translations/en.json and fr.json, creates the key, inserts the English value, and adds the French translation.

What's the best way to keep English and French localization files in sync when onboarding new UI strings?

The best way to keep English and French localization files in sync is using two-way localization updates. The tool adds or updates keys in both en.json and fr.json simultaneously, ensuring JSON integrity and consistent formatting across both files.

Does this tool work with Dart and Flutter i18n workflows that use the .tr() method?

Yes, this tool works with Dart and Flutter i18n workflows. After inserting keys into en.json and fr.json, you can reference them in Dart code using standard localization idioms like 'key_name'.tr() for your UI string translations.

Can I add multiple translation keys at once for bulk updates to my localization files?

Yes, you can add multiple translation keys at once. The tool supports bulk translations alongside single-key additions, safely inserting multiple English and French pairs into assets/translations/en.json and fr.json while enforcing valid JSON formatting.

Why does my localization JSON break when I manually add new UI strings, and how can I prevent it?

Localization JSON breaks from manual edits due to syntax errors or mismatched keys. This tool prevents it by enforcing valid JSON formatting and maintaining parallel English and French mappings automatically during every key addition or update.