Repository navigation
chore(i18n): add Azerbaijani (az) translations - #7906
Conversation
Summary
Signals
Requested Follow-upClearer issue linkage would help: since the issue was authored by the same person immediately before opening the PR with no independent triage, it would strengthen ownership evidence to have the issue reflect genuine prior discussion or reports from other users hitting this locale gap, or for the PR author to explain in-thread why this was raised as a personal request rather than a reported bug. Label Outcome
|
|
No earlier report existed. contributing asks for a linked issue, so #7905 was opened before the pull request. |
|
Important There're 2 concerns of maintainers:
If you're using Windows |
2b4e4ca to
5415895
Compare
5415895 to
1c080d3
Compare
1c080d3 to
f55e836
Compare
Dragon1573
left a comment
There was a problem hiding this comment.
- Related #7906 (comment)
✅ After manual validation, I can't find prominent bugs of Azerbaijani translations. Pull request is acceptable to be merged.
Problem
Fixes #7905
Clash Verge Rev ships thirteen interface languages (ar, de, en, es, fa, id, jp, ko, ru, tr, tt, zh, zhtw) and Azerbaijani is not one of them.
resolveLanguageinsrc/services/i18n.tsandresolve_supported_languagein theclash-verge-i18ncrate both fall back tozh, so a user with anazsystem locale gets Simplified Chinese in the window and in the tray menu.Approach
Both locale layers are discovered at runtime, so a new language needs the two bundles plus the two registration points that are not discovered automatically. The frontend loads
src/locales/<lang>/*.jsonthroughimport.meta.glob, and the backend crate readscrates/clash-verge-i18n/locales/<lang>.ymlthroughrust_i18n::available_locales!(). What is not automatic issupportedLanguages, which gatesresolveLanguage, and the label map in the settings dropdown, which falls back to the raw language code when a code is missing. These are the steps listed under "Adding a new language" indocs/CONTRIBUTING_i18n.md.Scope
New directory
src/locales/az/with the ten namespaces thatsrc/locales/en/defines: connections, home, layout, logs, profiles, proxies, rules, settings, shared, tests. 926 strings, all filled in, key names and key order taken fromen.New file
crates/clash-verge-i18n/locales/az.yml: 74 strings for the tray menu, notifications and service dialogs.src/services/i18n.ts:azappended tosupportedLanguages.src/components/setting/setting-verge-basic.tsx:azadded to the language label map asAzərbaycan dili.Nothing else changed.
pnpm i18n:formatandpnpm i18n:typesleave the tree unchanged after this commit, since the generated typings are derived fromsrc/locales/en/alone.Assisted by: OpenAI Codex (translation drafting and review pass) and Claude Opus (repository changes)