Skip to content

Commit

Permalink
🚚 Move zh-CN to zh-Hans and zh-TW to zh-Hant
Browse files Browse the repository at this point in the history
Ref: #793
  • Loading branch information
jpanther committed Apr 30, 2024
1 parent 62a8c97 commit 527140f
Show file tree
Hide file tree
Showing 32 changed files with 153 additions and 32 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
languageCode = "zh-CN"
languageCode = "zh-Hans"
languageName = "简体中文"
languageDirection = "ltr"
weight = 2
Expand Down
File renamed without changes.
File renamed without changes.
64 changes: 33 additions & 31 deletions exampleSite/content/docs/configuration/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,37 +48,39 @@ Congo is optimised for full multilingual websites and theme assets are translate

The theme currently supports the following languages out of the box:

| Language | Code |
| --------------------------------------- | ------- |
| :gb: **English (default)** | `en` |
| :egypt: Arabic | `ar` |
| :bangladesh: Bengali | `bn` |
| :bulgaria: Bulgarian | `bg` |
| :cn: Chinese - Simplified (China) | `zh-cn` |
| :taiwan: Chinese - Traditional (Taiwan) | `zh-tw` |
| :flag-cz: Czech | `cs` |
| :netherlands: Dutch | `nl` |
| :finland: Finnish | `fi` |
| :fr: French | `fr` |
| :de: German | `de` |
| :israel: Hebrew | `he` |
| :hungary: Hungarian | `hu` |
| :indonesia: Indonesian | `id` |
| :it: Italian | `it` |
| :jp: Japanese | `ja` |
| :kr: Korean | `ko` |
| :poland: Polish | `pl` |
| :brazil: Portuguese (Brazil) | `pt-br` |
| :portugal: Portuguese (Portugal) | `pt-pt` |
| :romania: Romanian | `ro` |
| :ru: Russian | `ru` |
| :slovakia: Slovak | `sk` |
| :es: Spanish (Spain) | `es` |
| :sweden: Swedish | `sv` |
| :flag-lk: Tamil | `ta` |
| :tr: Turkish | `tr` |
| :ukraine: Ukrainian | `uk` |
| :vietnam: Vietnamese | `vi` |
| Language | Code |
| --------------------------------------- | ------------ |
| :gb: **English (default)** | `en` |
| :egypt: Arabic | `ar` |
| :bangladesh: Bengali | `bn` |
| :bulgaria: Bulgarian | `bg` |
| :cn: Chinese - Simplified | `zh-Hans` |
| :cn: Chinese - Simplified (China) | `zh-Hans-CN` |
| :taiwan: Chinese - Traditional | `zh-Hant` |
| :taiwan: Chinese - Traditional (Taiwan) | `zh-Hant-TW` |
| :flag-cz: Czech | `cs` |
| :netherlands: Dutch | `nl` |
| :finland: Finnish | `fi` |
| :fr: French | `fr` |
| :de: German | `de` |
| :israel: Hebrew | `he` |
| :hungary: Hungarian | `hu` |
| :indonesia: Indonesian | `id` |
| :it: Italian | `it` |
| :jp: Japanese | `ja` |
| :kr: Korean | `ko` |
| :poland: Polish | `pl` |
| :brazil: Portuguese (Brazil) | `pt-br` |
| :portugal: Portuguese (Portugal) | `pt-pt` |
| :romania: Romanian | `ro` |
| :ru: Russian | `ru` |
| :slovakia: Slovak | `sk` |
| :es: Spanish (Spain) | `es` |
| :sweden: Swedish | `sv` |
| :flag-lk: Tamil | `ta` |
| :tr: Turkish | `tr` |
| :ukraine: Ukrainian | `uk` |
| :vietnam: Vietnamese | `vi` |

The default translations can be overridden by creating a custom file in `i18n/[code].yaml` that contains the translation strings. You can also use this method to add new languages. If you'd like to share a new translation with the community, please [open a pull request](https://github.com/jpanther/congo/pulls).

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
59 changes: 59 additions & 0 deletions i18n/zh-Hans.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
article:
anchor_label: "锚点"
date: "{{ .Date }}"
date_updated: "更新于 {{ .Date }}"
draft: "草稿"
edit_title: "编辑内容"
reading_time:
other: "{{ .Count }} 分钟"
reading_time_title: "预计阅读"
table_of_contents: "目录"
word_count:
one: "{{ .Count }} 字"
other: "{{ .Count }} 字"

author:
byline_title: "作者"

code:
copy: "复制"
copied: "已复制"

error:
404_title: "找不到网页 :confused:"
404_error: "404 错误"
404_description: "您请求的页面似乎不存在。"

footer:
dark_appearance: "切换为深色模式"
light_appearance: "切换为浅色模式"
powered_by: "由 {{ .Hugo }} & {{ .Congo }} 强力驱动"

list:
externalurl_title: "链接到外部网站"
no_articles: "这里还没有任何文章可以列出。"

nav:
scroll_to_top_title: "回到顶部"
skip_to_main: "跳到主要内容"

search:
open_button_title: "搜索 (/)"
close_button_title: "关闭 (Esc)"
input_placeholder: "搜索"

sharing:
email: "通过电子邮件发送"
facebook: "分享到 Facebook"
linkedin: "分享到 LinkedIn"
mastodon: "嘟嘟到 Mastodon"
pinterest: "钉到 Pinterest"
reddit: "提交到 Reddit"
twitter: "分享到 Twitter"
telegram: "分享到 Telegram"
line: "分享到 LINE"
weibo: "分享到 微博"
# x-twitter: "Post on X"

shortcode:
recent_articles: "最近的文章"
File renamed without changes.
60 changes: 60 additions & 0 deletions i18n/zh-Hant.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
article:
anchor_label: "定位點"
date: "{{ .Date }}"
date_updated: "上次編輯: {{ .Date }}"
draft: "草稿"
edit_title: "編輯內容"
reading_time:
one: "{{ .Count }} 分鐘"
other: "{{ .Count }} 分鐘"
reading_time_title: "預計閱讀時間"
table_of_contents: "目錄"
word_count:
one: "{{ .Count }} 字"
other: "{{ .Count }} 字"

author:
byline_title: "作者"

code:
copy: "複製"
copied: "已複製"

error:
404_title: "找不到網頁 :confused:"
404_error: "404 錯誤"
404_description: "您在尋找的頁面似乎不存在。"

footer:
dark_appearance: "切換為深色模式"
light_appearance: "切換為淺色模式"
powered_by: "以 {{ .Hugo }} & {{ .Congo }} 製作"

list:
externalurl_title: "外部網站連結"
no_articles: "這裡還沒有任何文章。"

nav:
scroll_to_top_title: "捲動到頁頂"
skip_to_main: "快轉到主要內容"

search:
open_button_title: "搜尋 (/)"
close_button_title: "關閉 (Esc)"
input_placeholder: "搜尋"

sharing:
email: "以電子郵件發送"
facebook: "分享到 Facebook"
linkedin: "分享到 LinkedIn"
mastodon: "嘟到 Mastodon"
pinterest: "釘到 Pinterest"
reddit: "發送到 Reddit"
twitter: "推到 Twitter"
telegram: "分享到 Telegram"
line: "分享到 LINE"
weibo: "分享到 微博"
# x-twitter: "Post on X"

shortcode:
recent_articles: "最近的文章"

0 comments on commit 527140f

Please sign in to comment.