Repository navigation
Enable de, fr, and nl docs locales - #38
Conversation
zzzoryn
left a comment
There was a problem hiding this comment.
Review of head 64ca741 (base cursor/tsk-193-admin-account = #37). Verdict: the change itself is correct, but this PR must not be merged until the blockers from #36 and #37 are fixed, because this is the PR that makes them public.
What I checked (#38 merged onto v1.0.0-beta.4 cc88c01 locally):
- CI
buildgreen on 64ca741; draft; mergeable clean. The diff against #37 is onlydocusaurus.config.ts,scripts/sync-docs-version.mjsandREADME.md. #36 (c62d00e) and #37 (431df0e) heads are unchanged since my reviews there. docusaurus.config.ts:66-96:localesandlocaleConfigsare correct - labels Deutsch / Français / Nederlands,htmlLangde/fr/nl,direction: 'ltr', paths/de/,/fr/,/nl/; ru stays at/, en at/en/.onBrokenLinks/onBrokenAnchors/onBrokenMarkdownLinksstay 'throw'.- Full
npm run build(prebuilddocs:check+ 5 locales) passes. - Built output:
<html lang="fr" dir="ltr">; each page hashreflangalternates for ru/en/de/fr/nl plusx-default-> ru, and a canonical on its own locale;build/{de,fr,nl}/sitemap.xmlexist with 47 URLs each, same as ru; the locale dropdown lists all five. README.md: public-safe - no internal task numbers or trackers, no comparisons with other products, hyphens only.
Blockers (not in this diff, but enabling the locales here exposes them):
- From #36:
src/theme/PlanBadges/index.tsx:57falls back to Russian for every locale except en. With this PR every de/fr/nl page shows "Тариф / Бесплатный / Предприятие" (checked inbuild/de/workspace/roles/index.html). Alsoi18n/nl/code.json:186(informal "je" on the 404 page). - From #37: 5 pages in de/fr/nl are translated from the pre-#35 EN (
getting-started/first-setup.md,install/free.md,install/email.md,install/troubleshooting.md,security/keys.md) and describe the old first-run flow, plus the UI-string and dash fixes listed in the #37 review. With this PR they go live at/de/,/fr/,/nl/.
Non-blocking:
scripts/sync-docs-version.mjs:25-30: the description saysdocs:checknow requires the locales, butlistFiles()returns[]for a missing folder, so if bothcurrentandversion-v1.0of a locale are missing the check still passes (tested: removing both nl folders -> exit 0). For a missing page Docusaurus then silently serves the Russian default-locale page under/nl/. Suggest failing whencurrentof a configured locale does not exist, and comparing each locale's file list withi18n/en/.../current.README.md:124still says "Feature names follow the product UI in Russian and English"; with five locales that should cover de/fr/nl too (the UI wording of each locale).- FYI for after merge (outside this repo): the app's
packages/i18n/src/locales/manifest.jsonhasdocsPathPrefix: "/en"for de/fr/nl, so the app will keep linking German/French/Dutch users to/en/until that is switched. - The PR title starts with an internal task number; please drop it from the squash title.
| ]; | ||
|
|
||
| for (const locale of OPTIONAL_LOCALES) { | ||
| for (const locale of TRANSLATED_LOCALES) { |
There was a problem hiding this comment.
A missing locale folder pair still passes docs:check (listFiles() returns [] for a missing dir; removing both nl folders gives exit 0). Suggest an explicit fs.existsSync(src) failure for these locales.
Generate and translate Docusaurus UI strings for German, French, and Dutch without publishing those locales yet. Extend docs:check to sync optional locale current/version-v1.0 content folders when they exist. Co-authored-by: Alexander Zorin <zzzoryn@users.noreply.github.com>
Add de/fr/nl plan badge copy with app tier names (Free/Gratuit/Gratis, Enterprise) and fall back to English for unknown locales. Use formal Dutch "u" on the NotFound page string. Co-authored-by: Alexander Zorin <zzzoryn@users.noreply.github.com>
Add TSK-193 batch 1 page translations for Administration and Account sections, sync version-v1.0 copies, and keep UI labels aligned with the Okkey web locale files. Co-authored-by: Alexander Zorin <zzzoryn@users.noreply.github.com>
Complete TSK-193 batch 2: translate all remaining English docs (install, getting-started, workspace, items, tools, apps, security, intro, plans, monitoring, capsules) plus category metadata into German, French, and Dutch. Sync version-v1.0 copies. Keep UI labels aligned with app locales; leave docusaurus locales disabled. Co-authored-by: Alexander Zorin <zzzoryn@users.noreply.github.com>
…w nits Re-translate getting-started/first-setup, install/email, install/free, install/troubleshooting and security/keys from the v1.0.0-beta.4 English source (setup wizard at /setup, one-time setup code, presets in the Mail step). Align quoted UI labels with packages/i18n web locales (Tresor- Einstellungen, Paramètres du coffre, Auswahl abbrechen, Dateien in Einträgen zulassen, Die neuen Passwörter stimmen nicht überein, Onbeperkte opslagruimte, nein/non/nee, 1 Minuten/1 minuten). Replace em and en dashes with hyphens in docs text. Sync version-v1.0 copies. Co-authored-by: Alexander Zorin <zzzoryn@users.noreply.github.com>
Replace the plural "1 Minuten" / "1 minuten" idle-timeout examples with correct singular "1 Minute" / "1 minuut" in current and version-v1.0. Co-authored-by: Alexander Zorin <zzzoryn@users.noreply.github.com>
361ba3e to
f5dfdde
Compare
Add German, French, and Dutch to i18n.locales so the navbar locale dropdown, docs:check sync pairs, and full builds cover all five locales. Co-authored-by: Alexander Zorin <zzzoryn@users.noreply.github.com>
Co-authored-by: Alexander Zorin <zzzoryn@users.noreply.github.com>
Make docs:check fail when a translated locale lacks current or version-v1.0, and compare each locale's file list with English for both trees so missing pages cannot slip through silently. Co-authored-by: Alexander Zorin <zzzoryn@users.noreply.github.com>
2aae0f4 to
9c5d8cc
Compare
zzzoryn
left a comment
There was a problem hiding this comment.
Re-review of head 9c5d8cc (base cursor/tsk-193-admin-account = #37 f5dfdde). Verdict: OK to merge after #36 and #37 and Alex's "merge". The blockers from #36 and #37 that this PR would have exposed are fixed there.
- CI
buildgreen; draft; mergeable clean; rebased on #37. docusaurus.config.ts: locale config unchanged from my previous review and correct (/de/, /fr/, /nl/, Deutsch / Français / Nederlands, htmlLang, ltr).- Local
npm run buildwith all five locales and 'throw' on broken links/anchors/markdown links passes; hreflang alternates, canonical and per-locale sitemaps are generated; the plan badge is localized on /de/, /fr/, /nl/ with no Russian text left. scripts/sync-docs-version.mjsnow really requires the locales. Tested on this head: baseline exit 0;plans.mdremoved from frcurrentandversion-v1.0-> exit 1 ("missing: plans.md" against the EN list); both nl folders removed -> exit 1; only nlcurrentremoved -> exit 1; a changed file in deversion-v1.0-> exit 1.README.md:124now covers all five locales; README is public-safe (no internal task numbers or trackers, no product comparisons, hyphens only). Title fixed.
Non-blocking:
- With only nl
currentmissing, the "is missing" line is printed twice (once from the file-list check, once from the pair check). Cosmetic. - Merge order matters. I simulated squash-merging #36 and then #37 into v1.0.0-beta.4: #37 applies cleanly, but #38 then conflicts in
scripts/sync-docs-version.mjs, because squash drops the shared history. After #37 is merged, retarget this PR to v1.0.0-beta.4 and rebase it, then re-run CI before merging. - FYI, outside this repo: the app's
packages/i18n/src/locales/manifest.jsonstill hasdocsPathPrefix: "/en"for de/fr/nl. - Please clear the squash body when merging (some commit messages carry the internal task number).
Summary
Enable German, French, and Dutch on the docs site.
Base is
cursor/tsk-193-admin-account(PR #37). After #36 and #37 merge, retarget this PR tov1.0.0-beta.4.Changes
docusaurus.config.ts: addde,fr,nltoi18n.localeswithlocaleConfigs(Deutsch / Français / Nederlands;htmlLangde/fr/nl; paths/de/,/fr/,/nl/).rustays at/,enat/en/.localeDropdownlists all five locales. Version dropdown (v1.0) works for the new locales. No local search plugin is configured.scripts/sync-docs-version.mjs:docs:check/docs:syncalways coveren/de/fr/nlcurrent toversion-v1.0pairs.docs:checkfails when a locale'scurrentorversion-v1.0folder is missing, and when a locale's file list differs from English in either tree.README.md: document the five locales and that feature names follow the product UI in ru/en/de/fr/nl. No separate CONTRIBUTING file in this repo.npm run build, which builds every locale from config, so there is no workflow locale list to update.Checks
npm run docs:check- pass (also verified to fail with a missing localecurrentfolder, a missing page, and aversion-v1.0file-list mismatch vs EN)npm run build(ru + en + de + fr + nl) - pass