Add Korean - #503
Merged
Merged
Conversation
A tenth table, 474 keys. Nothing about the machinery needed changing; it was
built to take another language.
Korean does not inflect nouns for number, so every plural family here is .other
only, the way ja, zhHans and id already do it. Copying the English key set would
have produced a table full of .one keys the resolver never reads, and the
coverage check compares plural families rather than raw keys precisely so that
does not look like a gap.
The register is the plain 해요체 the interface wants rather than the stiffer
합니다체, and the audio loanwords a Korean musician already uses stay loanwords:
보컬, 드럼, 베이스, 루프. Translating those would read as odd to anyone who has
opened a DAW. Korean is verb-final, so several strings reorder around their
placeholders rather than substituting in place; every {placeholder} and every
HTML tag was checked to survive that.
The locale test caught what it was written to catch. Adding a language to
LANGUAGES without a matching branch in _detectDefault ships a table nobody's
browser can reach on its own, and that is exactly what the first run reported:
FAIL ko has locales covering it -- add this language's locales to LOCALES
So ko and ko-KR route to it, and the test knows about them.
Closes #501
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #501
A tenth language table, 474 keys. Nothing about the machinery needed changing;
it was built to take another one.
What needed care
The plural shape. Korean does not inflect nouns for number, so every plural
family is
.otheronly, the wayja,zhHansandidalready do it. Copyingthe English key set would have produced a table full of
.onekeys the resolvernever reads. The coverage check compares plural families rather than raw keys
precisely so that does not read as a gap.
Register. Plain 해요체 rather than the stiffer 합니다체, matching how direct
the other tables are. The audio loanwords a Korean musician already uses stay
loanwords: 보컬, 드럼, 베이스, 루프. Translating those would read as odd to
anyone who has opened a DAW.
Word order. Korean is verb-final, so several strings reorder around their
placeholders rather than substituting in place. Every
{placeholder}and everyHTML tag was checked to survive that: 474 strings compared against English, zero
mismatches.
The test that earned its place
tests/js/i18n-detect.test.mjsexists because adding a table toLANGUAGESandforgetting the matching branch in
_detectDefaultships a language nobody'sbrowser can reach on its own. That is exactly what the first run reported:
So
koandko-KRroute to it now, and the test knows about them. 45 pass.Verified
Coverage script clean: all eleven tables complete at 474 keys, no orphans in the
European Portuguese variant.
Rendered in a browser with the language set to Korean, checked across the app
rather than in one place:
That last one is the plural family resolving through
.othercorrectly.83 browser tests pass,
node --checkclean on every file.