i18n-rtl-l10n

Enforces gen-l10n ARB localization, RTL geometry, and numeral normalization in Flutter apps.

Updated Aug 22, 2026
One-click install
npx skills add https://github.com/zakariaf/NearlyStop --skill i18n-rtl-l10n-zakariaf
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: i18n-rtl-l10n
Source: https://github.com/zakariaf/NearlyStop/tree/main/.claude/skills/i18n-rtl-l10n
Command: npx skills add https://github.com/zakariaf/NearlyStop --skill i18n-rtl-l10n-zakariaf

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve? Flutter apps shipping multiple locales or RTL languages (Arabic, Persian, Hebrew, Sorani Kurdish) silently break: hardcoded strings bypass translation, physical left/right geometry fails to mirror, Persian and Arabic digits get mixed up, and raw numeric input like ۱۲۳ crashes int.parse. This Skill enforces one contract — store canonical, localize at render — so every string, number, date, and layout is correct by construction. ## Core Features & Use Cases - ARB workflow with compile-time safety: Template-first app_en.arb authoring, nullable-getter: false so a missing key is a compile error, ICU plural/select instead of string concatenation, and a check_arb_parity.sh script that gates key and placeholder parity across all locales. - RTL by construction: Directional-only geometry (EdgeInsetsDirectional, AlignmentDirectional, Icons.adaptive), FSI/PDI bidi isolation for technical IDs, and a check_i18n_bans.sh grep gate that rejects physical-side APIs, legacy bidi embeddings, and runtime font fetches. - Numerals and calendars: Per-locale NumberFormat with pinned numbering systems (fa/ckb share the Extended Arabic-Indic block), normalizeToAscii before any numeric parse, and UTC-epoch storage with Jalali/Hijri projection only at render. - Use Case: Adding a new screen to an app shipping English, German, Persian, Arabic, and Sorani Kurdish — the Skill walks you through adding the ARB keys with typed placeholders, mirroring translations with correct Arabic six-category plurals, building the layout with directional geometry, and passing both parity and ban checks before the PR. ## Quick Start Ask the AI to add a new localized string with a plural count to your Flutter app's ARB files and build the RTL-safe widget that displays it.

Frequently Asked Questions about i18n-rtl-l10n

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

FAQPage Schema
How do I add a new localized string to a Flutter app using gen-l10n?

Add the key plus its @key metadata with typed placeholders to the template app_en.arb first, then mirror the same key into every other locale file with identical placeholder names. Run the parity check script, regenerate with flutter gen-l10n, and read the string via AppLocalizations.of(context).

How do I handle plurals in Arabic Flutter localization?

Use ICU plural messages in the ARB file with all six CLDR categories: zero, one, two, few, many, and other. Never use a ternary like count == 1 or string concatenation, since Arabic grammar requires all six forms and word order differs per language.

How do I make a Flutter layout work in RTL languages?

Use directional-only geometry: EdgeInsetsDirectional, AlignmentDirectional, PositionedDirectional, TextAlign.start/end, and Icons.adaptive for directional icons. Direction comes from the resolved locale via GlobalWidgetsLocalizations, never from a hardcoded root Directionality widget.

Why does int.parse fail on Persian or Arabic numeric input?

Persian and Arabic soft keyboards emit native digits (U+06F0–U+06F9 or U+0660–U+0669) and separators like U+066B, which int.parse cannot read. Normalize input to ASCII digits and separators first with a normalizeToAscii helper, then call double.parse.

Does intl NumberFormat support Sorani Kurdish (ckb) numerals?

No, intl has no number symbols for ckb and silently falls back to Latin digits. Pin ckb to the fa formatter, which shares the same Extended Arabic-Indic digit block and separators, and assert the emitted digit range in a test.

How do I display order numbers or codes inside RTL text without scrambling?

Wrap strong-LTR technical runs like account numbers, phone numbers, and URLs in bidi isolate characters (LRI/FSI plus PDI) at the view layer only. Strip the isolate characters before storage, search, or export, and never use legacy LRE/RLE embeddings.