docs: document generated locale bundles

This commit is contained in:
Peter Steinberger
2026-06-04 22:11:00 -04:00
parent 8f85f94946
commit b311fd607f
37 changed files with 74 additions and 55 deletions

View File

@@ -480,9 +480,10 @@ function renderTranslationValue(value: TranslationValue, indent = 0): string {
function renderLocaleModule(entry: LocaleEntry, value: TranslationMap): string {
return [
"// Generated locale bundle for Control UI translations.",
"// Run `pnpm ui:i18n:sync` instead of editing this file directly.",
'import type { TranslationMap } from "../lib/types.ts";',
"",
"// Generated by scripts/control-ui-i18n.ts.",
`export const ${entry.exportName}: TranslationMap = ${renderTranslationValue(value)};`,
"",
].join("\n");