Skip to content

Commit f553a56

Browse files
committed
chore: set i18n for mkdocs
1 parent 439b45f commit f553a56

2 files changed

Lines changed: 24 additions & 2 deletions

File tree

.github/workflows/docs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ jobs:
3939
- name: Install MkDocs and theme
4040
run: |
4141
python -m pip install --upgrade pip
42-
pip install "mkdocs>=1.6.0" "mkdocs-material>=9.0.0"
42+
pip install "mkdocs>=1.6.0" "mkdocs-material>=9.0.0" "mkdocs-static-i18n"
4343
4444
- name: Build site
4545
run: mkdocs build --strict

mkdocs.yml

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ nav:
2222

2323
theme:
2424
name: material
25-
language: en
2625

2726
markdown_extensions:
2827
- admonition
@@ -32,3 +31,26 @@ markdown_extensions:
3231

3332
plugins:
3433
- search
34+
- i18n:
35+
docs_structure: folder
36+
reconfigure_material: true
37+
languages:
38+
- locale: en
39+
name: English
40+
default: true
41+
build: true
42+
- locale: zh
43+
name: 中文
44+
build: true
45+
nav_translations:
46+
Home: 首页
47+
Quickstart: 快速开始
48+
Core: 核心组件
49+
Async client: 异步客户端
50+
Base bot: Bot 基类
51+
Bot runner: Bot 运行器
52+
Commands: 命令系统
53+
Config: 配置
54+
Logging: 日志
55+
Models: 数据模型
56+
Storage: 存储

0 commit comments

Comments
 (0)