|
|
há 3 meses atrás | |
|---|---|---|
| .. | ||
| README.md | há 3 meses atrás | |
| i18n-tool.js | há 3 meses atrás | |
The script in this dir allow the efficient addition of new translations to the dashboard.
packages/dashboard/lingui.config.jslingui extractThis will create the new, empty .po file in packages/dashboard/src/i18n/locales
When you add new localized strings to the Dashboard app, you can generate translations in each supported language like this:
npm run i18n:extractmissing-translations.txt file in the dashboard dirtranslations.txt in the dashboard dirnpm run i18n:apply translations.txt{0}, {formattedDiff}, {entityName}Explicit ID Translations: For entries marked with "js-lingui-explicit-id" (e.g., orderState.PartiallyDelivered), translate ONLY the human-readable part, NOT the namespace:
"orderState.PartiallyDelivered" → "Partiellement livré" (French)"orderState.PartiallyDelivered" → "orderState.Partiellement livré"E-commerce Domain Context: Always assume e-commerce context unless clearly indicated otherwise:
"order" = e-commerce order (goods being purchased)"customer" = e-commerce customer (buyer)"product" = e-commerce product (item for sale)"variant" = product variant (size, color, etc.)packages/dashboard/src/i18n/locales/
├── en.po # Source English file
├── de.po # German translations
├── fr.po # French translations (after creation)
└── ... # Other language files