Translate these UI strings from English into nn (for a CLI): - "promptPlatform": "Select…
Jump to turn (6)
- User
Translate these UI strings from English into nn (for a CLI):
Respond with a JSON object mapping each original key to its translation, using the exact same keys. Only the translations, nothing else.
{ "promptPlatform": "Vel ein plattform å bygge opp:", "promptDir": "Målmappe:", "spinnerStart": "Skalerar opp...", "spinnerStop": "Ferdig med å skalere opp.", "wroteFile": "✓ {{path}}", "nextStepsHeading": "Neste steg:", "nextStepsNav": "cd {{dir}}", "nextStepsInstall": "Installer avhengigheiter: {{command}}", "nextStepsDevServer": "Start utviklarserveren (om malen har ein)", "notesHeading": "Merk:", "caveatsHeading": "Merknad:", "errorMissingPlatform": "Manglar påkravd argument "platform". Forventa eitt av: {{platforms}}", "cancelled": "Avbrotet.", "helpPlatformDescription": "Plattform å bygge opp ({{platforms}}; "html" er eit alias for "components", "theme-editor" er eit alias for "canvas-theme-editor")", "helpDirDescription": "Målmappe (spør interaktivt i ein TTY om det er utelate)", "helpYesDescription": "Aldri spør; gi feil i staden for å spørje om manglande platform/målmappe", "helpLangDescription": "Overskriv automatisk oppdaga visningsspråk (t.d. "hu")", "scaffold.canvas-theme-editor.nextSteps.0": "cd {{dir}}", "scaffold.canvas-theme-editor.nextSteps.1": "{{install}}", "scaffold.canvas-theme-editor.nextSteps.2": "{{dev}}", "scaffold.canvas-theme-editor.notes": "Last opp theme.css og theme.js til Canvas Theme Editor (Advanced → CSS / JavaScript) slik at pantoken-klassane er tilgjengelege på alle sider.", "scaffold.canvas-theme-editor.caveats": "Canvas rensar innlimt HTML på serversida — ver alltid nøye med å verifisere innhaldet som er limt inn frå RCE-førehandsvisinga i Canvas.", "scaffold.canvas-theme-editor.i18n.pageTitle": "RCE-malutvikling", "scaffold.canvas-theme-editor.i18n.pageDescription": "Lag Canvas RCE-sidemalar styla med pantoken, med levande førehandsvising.", "scaffold.canvas-theme-editor.i18n.editThemeLabel": "Endre tema", "scaffold.canvas-theme-editor.i18n.helpAriaLabel": "Hjelp", "scaffold.canvas-theme-editor.i18n.copyHtmlLabel": "Kopier HTML", "scaffold.canvas-theme-editor.i18n.editorPaneLabel": "Redigeringsvindauge", "scaffold.canvas-theme-editor.i18n.previewPaneLabel": "Førehandsvising", "scaffold.canvas-theme-editor.i18n.previewFrameTitle": "Stylt førehandsvising", "scaffold.canvas-theme-editor.i18n.fullscreenEditorAriaLabel": "Redigerar i fullskjerm", "scaffold.canvas-theme-editor.i18n.fullscreenPreviewAriaLabel": "Førehandsvising i fullskjerm", "scaffold.canvas-theme-editor.i18n.resizePanesAriaLabel": "Endre storleik på redigerar og førehandsvising", "scaffold.canvas-theme-editor.i18n.stackVerticallyLabel": "Stable loddrett", "scaffold.canvas-theme-editor.i18n.stackSideBySideLabel": "Stable ved sida av kvarandre", "scaffold.canvas-theme-editor.i18n.swapPanesLabel": "Bytt om rutar", "scaffold.canvas-theme-editor.i18n.themeTrayAriaLabel": "Temainnstillingar", "scaffold.canvas-theme-editor.i18n.tabConfigLabel": "Konfig", "scaffold.canvas-theme-editor.i18n.tabCssLabel": "CSS", "scaffold.canvas-theme-editor.i18n.tabJsLabel": "JS", "scaffold.canvas-theme-editor.i18n.cdnProviderLabel": "CDN-leverandør", "scaffold.canvas-theme-editor.i18n.themeLabel": "Tema", "scaffold.canvas-theme-editor.i18n.modeLabel": "Modus", "scaffold.canvas-theme-editor.i18n.downloadCssLabel": "Last ned theme.css", "scaffold.canvas-theme-editor.i18n.downloadJsLabel": "Last ned theme.js", "scaffold.canvas-theme-editor.i18n.regenerateLabel": "Regenerer frå konfig", "scaffold.canvas-theme-editor.i18n.helpModalTitle": "Slik brukar du denne sida", "scaffold.canvas-theme-editor.i18n.helpModalBody1": "Vel ein startmal, rediger han som i Canvas' Rich Content Editor, trykk Kopier HTML og lim resultatet inn i ei Canvas-side (gå først til HTML-redigeraren). Canvas rensar innlimt HTML på serversida — denne førehandsvisinga prøver ikkje å gjenska det, så ver alltid nøye med å verifisere det innlimte resultatet i Canvas.", "scaffold.canvas-theme-editor.i18n.helpModalBody2": "Bruk Endre tema for å byte CDN-leverandør, tema eller modus, og for å handredigere den genererte theme.css/theme.js før nedlasting.", "scaffold.canvas-theme-editor.i18n.closeLabel": "Lukk" }
evaluate this failure:
❌ Failed to translate for locale nn: Error: AI response could not be parsed as JSON for locale "nn".
at translateLocale (file:///Users/dwahl/Scripts/pantoken/tools/translation-adapters/dist/index.mjs:160:26)
at process.processTicksAndRejections (node:internal/process/task_queues:104:5)
at async runI18nTranslationCli (file:///Users/dwahl/Scripts/pantoken/tools/translation-adapters/dist/index.mjs:192:3)
at async main (file:///Users/dwahl/Scripts/pantoken/packages/scaffold/scripts/translate.ts:20:3)
Root cause: the JSON I returned was invalid JSON.
Specifically, this value contained an invalid escape sequence:
Canvas\' Rich Content EditorIn JSON, \' is not a valid escape. Only escapes like \", \\, \n, etc. are allowed.
So the parser in translateLocale failed and threw AI response could not be parsed as JSON.
Use a plain apostrophe (no backslash):
Canvas' Rich Content EditorEverything else can then parse normally.
If you want, I can resend the full nn object with JSON guaranteed-valid.
yes
{ "promptPlatform": "Vel ein plattform å bygge opp:", "promptDir": "Målmappe:", "spinnerStart": "Skalerar opp...", "spinnerStop": "Ferdig med å skalere opp.", "wroteFile": "✓ {{path}}", "nextStepsHeading": "Neste steg:", "nextStepsNav": "cd {{dir}}", "nextStepsInstall": "Installer avhengigheiter: {{command}}", "nextStepsDevServer": "Start utviklarserveren (om malen har ein)", "notesHeading": "Merk:", "caveatsHeading": "Merknad:", "errorMissingPlatform": "Manglar påkravd argument "platform". Forventa eitt av: {{platforms}}", "cancelled": "Avbrotet.", "helpPlatformDescription": "Plattform å bygge opp ({{platforms}}; "html" er eit alias for "components", "theme-editor" er eit alias for "canvas-theme-editor")", "helpDirDescription": "Målmappe (spør interaktivt i ein TTY om det er utelate)", "helpYesDescription": "Aldri spør; gi feil i staden for å spørje om manglande platform/målmappe", "helpLangDescription": "Overskriv automatisk oppdaga visningsspråk (t.d. "hu")", "scaffold.canvas-theme-editor.nextSteps.0": "cd {{dir}}", "scaffold.canvas-theme-editor.nextSteps.1": "{{install}}", "scaffold.canvas-theme-editor.nextSteps.2": "{{dev}}", "scaffold.canvas-theme-editor.notes": "Last opp theme.css og theme.js til Canvas Theme Editor (Advanced → CSS / JavaScript) slik at pantoken-klassane er tilgjengelege på alle sider.", "scaffold.canvas-theme-editor.caveats": "Canvas rensar innlimt HTML på serversida — ver alltid nøye med å verifisere innhaldet som er limt inn frå RCE-førehandsvisinga i Canvas.", "scaffold.canvas-theme-editor.i18n.pageTitle": "RCE-malutvikling", "scaffold.canvas-theme-editor.i18n.pageDescription": "Lag Canvas RCE-sidemalar styla med pantoken, med levande førehandsvising.", "scaffold.canvas-theme-editor.i18n.editThemeLabel": "Endre tema", "scaffold.canvas-theme-editor.i18n.helpAriaLabel": "Hjelp", "scaffold.canvas-theme-editor.i18n.copyHtmlLabel": "Kopier HTML", "scaffold.canvas-theme-editor.i18n.editorPaneLabel": "Redigeringsvindauge", "scaffold.canvas-theme-editor.i18n.previewPaneLabel": "Førehandsvising", "scaffold.canvas-theme-editor.i18n.previewFrameTitle": "Stylt førehandsvising", "scaffold.canvas-theme-editor.i18n.fullscreenEditorAriaLabel": "Redigerar i fullskjerm", "scaffold.canvas-theme-editor.i18n.fullscreenPreviewAriaLabel": "Førehandsvising i fullskjerm", "scaffold.canvas-theme-editor.i18n.resizePanesAriaLabel": "Endre storleik på redigerar og førehandsvising", "scaffold.canvas-theme-editor.i18n.stackVerticallyLabel": "Stable loddrett", "scaffold.canvas-theme-editor.i18n.stackSideBySideLabel": "Stable ved sida av kvarandre", "scaffold.canvas-theme-editor.i18n.swapPanesLabel": "Bytt om rutar", "scaffold.canvas-theme-editor.i18n.themeTrayAriaLabel": "Temainnstillingar", "scaffold.canvas-theme-editor.i18n.tabConfigLabel": "Konfig", "scaffold.canvas-theme-editor.i18n.tabCssLabel": "CSS", "scaffold.canvas-theme-editor.i18n.tabJsLabel": "JS", "scaffold.canvas-theme-editor.i18n.cdnProviderLabel": "CDN-leverandør", "scaffold.canvas-theme-editor.i18n.themeLabel": "Tema", "scaffold.canvas-theme-editor.i18n.modeLabel": "Modus", "scaffold.canvas-theme-editor.i18n.downloadCssLabel": "Last ned theme.css", "scaffold.canvas-theme-editor.i18n.downloadJsLabel": "Last ned theme.js", "scaffold.canvas-theme-editor.i18n.regenerateLabel": "Regenerer frå konfig", "scaffold.canvas-theme-editor.i18n.helpModalTitle": "Slik brukar du denne sida", "scaffold.canvas-theme-editor.i18n.helpModalBody1": "Vel ein startmal, rediger han som i Canvas' Rich Content Editor, trykk Kopier HTML og lim resultatet inn i ei Canvas-side (gå først til HTML-redigeraren). Canvas rensar innlimt HTML på serversida — denne førehandsvisinga prøver ikkje å gjenska det, så ver alltid nøye med å verifisere det innlimte resultatet i Canvas.", "scaffold.canvas-theme-editor.i18n.helpModalBody2": "Bruk Endre tema for å byte CDN-leverandør, tema eller modus, og for å handredigere den genererte theme.css/theme.js før nedlasting.", "scaffold.canvas-theme-editor.i18n.closeLabel": "Lukk" }
yes
update the root cause in the core strings. instead of Canvas' Rich Content Editor it should be the Canvas Rich Content Editor
I’m locating the source string first, then I’ll patch it and verify the change.
I found the string in the scaffold i18n data; I’m checking the source file that feeds it so I can change the canonical text, not just the cache.
I’ve got the source string. I’m checking whether this repo treats the cached locale files as tracked outputs so I can keep the source and generated data in sync.
I found one more runtime string in the template. I’m patching the source template and the generated English caches together so the repo stays consistent.
The source and English caches are patched. I’m verifying the old phrasing is gone from the scaffold strings and that the new phrasing is present where it should be.
I found the same wording in the template README. I’m aligning that too so the docs don’t regress back to the old phrasing.
Done — I updated the core scaffold strings to use “the Canvas Rich Content Editor” and synced the English cache files.
Changed:
packages/scaffold/templates/canvas-theme-editor/src/i18n.jsonpackages/scaffold/templates/canvas-theme-editor/src/main.ts.tmplpackages/scaffold/i18n-cache/en*.jsonpackages/scaffold/templates/canvas-theme-editor/README.mdI also verified the old phrasing is gone from packages/scaffold/.
update the root cause in the core strings. instead of Canvas' Rich Content Editor it should be the Canvas Rich Content Editor