mirror of
https://github.com/vrtmrz/obsidian-livesync.git
synced 2026-08-27 22:07:07 +00:00
i18n(zh-tw): complete the catalogue coverage
Continues the zh-tw work from commit 0f50f290, which only translated the
190 keys `$msg()` calls in `src/` resolved through the catalogue at the
time. This closes the remaining gap: 573 of 1450 keys (39.5%) to 1446 of
1450 (99.7%), matching es (99.9%) and comfortably ahead of every other
locale except it.
While re-scanning to find the next batch, the earlier "code-referenced"
count turned out to be wrong: the previous grep only matched single-line
`$msg("literal")` calls and missed multi-line calls and the `msg`, `_msg`,
and `translateMessage` aliases various Svelte components import (e.g.
`import { $msg as msg } from "@/common/translation"`). A corrected scan
found 624 referenced keys, not 309, of which 350 were still untranslated —
mostly the P2P Sync status panes and several SetupWizard dialogues. Since
this pass translates everything remaining regardless of reference status,
that gap closes as a side effect; it is called out here only because it
explains why some of the newly translated strings are already visible in
today's UI rather than being pure catalogue completeness.
- Translated by area: P2P Sync replicator panes and the `P2P.*` runtime
messages; ConfigSync's plugin/snippet/theme comparison UI; the
SetupWizard's remote-setup, rebuild/fetch, and outro dialogues (both the
legacy flat-key strings and the newer `Ui.SetupWizard.*` Svelte
component keys); the Svelte-based `Ui.Settings.*` settings panels
(Maintenance, Patches, Hatch, Remote, Common, Selector, PowerUsers,
CustomisationSync, Advanced, Setup, SyncSettings); Setting Doctor
(`Doctor.*`); the remote-size warning flow (`moduleCheckRemoteSize.*`);
the redflag3 fetch-method chooser (`RedFlag.*`); the remaining
`moduleMigration.*`, `liveSyncReplicator.*`, `Replicator.*`, and
`TweakMismatchResolve.*` entries; and the rest of the plain
English-sentence keys, including the language-picker's native-script
entries (added `lang-he: עברית`, matching how `lang-de`/`lang-ja`/etc.
already show each language's own name rather than a Chinese gloss).
- Wording follows docs/terms.md and the register already established in
this file: `Setup URI`, `Vault`, `chunk(s)`, `Peer`, `Peer-to-Peer`,
`Hatch`, and `CouchDB` stay untranslated as proper nouns; `resolved`
(device/database state) is consistently 已處理, matching the existing
Scram-dialogue usage.
- `${...}` placeholders and `%{...}` keyword references are kept
byte-identical to the English source, including the multi-paragraph
`RedFlag.Fetch.Method.Desc` and `moduleCheckRemoteSize.msgDatabaseGrowing`
callout blocks; verified programmatically against all 1446 zh-tw
entries.
- 4 keys are still deliberately left untranslated, unchanged from the
previous commit: `moduleMigration.docUri` and
`obsidianLiveSyncSettingTab.linkTroubleshooting` are a URL and a doc
path, `obsidianLiveSyncSettingTab.logServerConfigurationCheck`'s English
value is the key name itself, and `moduleLiveSyncMain.logPluginVersion`
is a version-number template.
- Regenerated `messagesJson/zh-tw.json` and `combinedMessages.prod.ts`
through the documented `i18n:bake` pipeline; no other language's
entries changed.
Verified with tsc-check, tsc-check:apps, lint, lint:community,
lint:community:tools, svelte-check, check:compatibility, and test:unit
(604 tests, 86 files) — all pass.
Not in scope, unchanged from the previous commit: the ~137 Commonlib-owned
setting labels/descriptions never reach any translator because
`getConfig()` call sites in SettingDialogue omit the `translate` argument;
German is staged in the catalogue but never imported by
`combinedMessages.dev.ts`; Hebrew keyword references are never expanded by
`expandKeywords()`. None of these are specific to zh-tw and none are
touched here.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
committed by
Hao Chu
co-authored by
Claude Opus 5
parent
df8c79538e
commit
b939687cb3