Follow the core's whole roll-out: 18 more languages, the Canadian variants included #44
No reviewers
Labels
No labels
bug
documentation
enhancement
performance
security
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Postulo/postulo-chromium!44
Loading…
Reference in a new issue
No description provided.
Delete branch "43-languages"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #43
What changed
scripts/languages.py:SPELLEDgains the five codes it stopped on. English and French keep the bare folder a browser falls back to from any region (en,fr), and a second variety is named by its region:en_CA,fr_CA, andes_MXbesidees. Chinese is told apart by script, which a folder cannot say, so it is named by region as Chrome names its own catalogues,zh_CNandzh_TW, and keepszh-Hansandzh-Hantin its tag.src/lib/languages.js, regenerated from the core'smain: 58 languages, up from 40. The core has started 57 (one translated string or more, instatus.json), plus English. The other 27 of its 84 catalogues are still empty, so the extension does not follow them yet;languages.pyadds each one when the core starts it.{}:arazbebncnren_CAes_MXfofr_CAhiidkknnrmswurzh_CNzh_TW. Weblate fills them (postulo/postulo#706).scripts/build.mjsalready leaves an incomplete catalogue out of the package, so none of them ships, and no unfamiliar folder reaches a browser, before it is complete.test/i18n.test.mjs:Intl.Localeapplies CLDR's aliases and turned Montenegrin'scnrintosr-ME;cnris kept as the core writes it, and named as the one tag whose canonical form Intl disagrees with.Right to left
arandurare the first right-to-left languages here. Nothing more was needed: the build writes each catalogue'sdirectionfromlanguages.js(rtlfor both), andi18n.jssetsdocument.documentElement.dirfrom it on every page.Not done here (from #43's checklist)
new_lang: none. Once this is merged, Weblate should pick the 18 files up on its next pull; check thatextension-chromiumlists them.fr-CAanden-CA, and packing with folders Chrome does not know (fr_CA,cnr,kablater), belongs to #29, in a real Chromium. Until a catalogue is complete the build leaves it out, so the question only arises once Weblate has filled one.Tests
npm test: 184 passed.npm run build: both targets build; the new languages are reported as left out until complete.npm run lint:firefox: 0 errors, 0 warnings.node scripts/guard.mjsagainstmain: no translation written outside Weblate.python scripts/languages.py --checkagainst the core'smain: matches.🤖 Generated with Claude Code