提交 d0ff84b9 编写于 作者: S Sebastian Florek 提交者: Kubernetes Prow Robot

Add additional locale directories for zh (#4792)

上级 6cd61343
......@@ -9,6 +9,10 @@ Based on current browser locale the Dashboard can be displayed in one of the sup
| Japanese | ja |
| Korean | ko |
| Simplified Chinese | zh |
| Chinese (PRC) | zh-cn|
| Chinese (Hong Kong)| zh-hk|
| Chinese (Singapore)| zh-sg|
| Chinese (Taiwan) | zh-tw|
## Building localized dashboard
......@@ -40,11 +44,12 @@ Find new localizable texts in `i18n/[locale]/messages.[locale].xlf` file and tra
Since dashboard team can not review translation files in your language, so dashboard team transfers authority to review and approve for updating your translation file. At first, you need to organize translation team for your language that manages dashboard translation file.
1. Add your locale, e.g. `fr` or `ja`, into `"languages"` array of `"xfillmergeOptions"` in `package.json` file.
**Impotant: Locales should be written in lower case to be handled by Dashboard, e.g. `zh-tw`, not `zh-TW`**
2. Run `npm run fix:i18n`. Then translation file for your language, e.g. `i18n/fr/messages.fr.xlf`, would be generated.
3. Open your translation file and translate texts in `<target>` element into your language.
**Important: Locales should be written in lower case to be handled by Dashboard, e.g. `zh-tw`, not `zh-TW`**
2. Run `npm run fix:i18n`. Then translation file for your language, e.g. `i18n/messages.fr.xlf`, would be generated.
3. Create a new directory for generated file, e.g. `i18n/fr` and move generated file there.
4. Open your translation file and translate texts in `<target>` element into your language.
After preparation of new translation file, configure `i18n/locale conf.json` file to build newly translation dashboard as follows:
After preparation of new translation file, configure `i18n/locale conf.json` file to build translated dashboard as follows:
```
{"translations": [ "en", "fr", "ko", "zh" ]}
......
{"translations": [ "en", "fr", "ja", "ko", "zh" ]}
{"translations": [ "en", "fr", "ja", "ko", "zh", "zh-cn", "zh-hk", "zh-sg", "zh-tw" ]}
approvers:
- hwdef
- tanjunchen
labels:
- language/zh
此差异已折叠。
approvers:
- hwdef
- tanjunchen
labels:
- language/zh
此差异已折叠。
approvers:
- hwdef
- tanjunchen
labels:
- language/zh
此差异已折叠。
approvers:
- hwdef
- tanjunchen
labels:
- language/zh
此差异已折叠。
......@@ -87,7 +87,11 @@
"fr",
"ja",
"ko",
"zh"
"zh",
"zh-cn",
"zh-hk",
"zh-sg",
"zh-tw"
],
"beautifyOutput": true
},
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册