diff --git a/docs/.vitepress/config/en.ts b/docs/.vitepress/config/en.ts index 95c0178..52a1bf9 100644 --- a/docs/.vitepress/config/en.ts +++ b/docs/.vitepress/config/en.ts @@ -21,11 +21,8 @@ export const en = defineConfig({ ), footer: { message: 'Documentation built with VitePress | API references generated by litedoc', - copyright: 'Copyright (C) 2020-2024 SnowyKami. All Rights Reserved' + copyright: ThemeConfig.copyright }, - outline: { - label: "On this page", - level: [2, 6] - } + outline: ThemeConfig.getOutLine("Page Content") }, }) \ No newline at end of file diff --git a/docs/.vitepress/config/ja.ts b/docs/.vitepress/config/ja.ts index 47d00a2..bb0a0a7 100644 --- a/docs/.vitepress/config/ja.ts +++ b/docs/.vitepress/config/ja.ts @@ -21,11 +21,8 @@ export const ja = defineConfig({ ), footer: { message: 'VitePress で構築されたドキュメント | litedoc によって生成されたAPIリファレンス', - copyright: 'Copyright (C) 2020-2024 SnowyKami. All Rights Reserved' + copyright: ThemeConfig.copyright }, - outline: { - label: "このページについて", - level: [2, 6] - } + outline: ThemeConfig.getOutLine("ページの内容") }, }) \ No newline at end of file diff --git a/docs/.vitepress/config/utils.ts b/docs/.vitepress/config/utils.ts index 8e65fd1..a2c6613 100644 --- a/docs/.vitepress/config/utils.ts +++ b/docs/.vitepress/config/utils.ts @@ -1,3 +1,5 @@ +// 本模块储存一些工具函数和引用 + /** * GetEditLink Options * @param text Edit link text @@ -19,5 +21,14 @@ export const ThemeConfig = { }, text: editPageText }; - } + }, + + getOutLine: (label: string): { label: string; level: [number, number]; } => { + return { + label: label, + level: [2, 6] + }; + }, + + copyright: 'Copyright (C) 2020-2024 SnowyKami. All Rights Reserved' } \ No newline at end of file diff --git a/docs/.vitepress/config/zh.ts b/docs/.vitepress/config/zh.ts index ff3ca89..38a2fd3 100644 --- a/docs/.vitepress/config/zh.ts +++ b/docs/.vitepress/config/zh.ts @@ -21,11 +21,8 @@ export const zh = defineConfig({ ), footer: { message: '文档由 VitePress 构建 | API引用由 litedoc 生成', - copyright: 'Copyright (C) 2020-2024 SnowyKami. All Rights Reserved' + copyright: ThemeConfig.copyright }, - outline: { - label: "页面内容", - level: [2, 6] - } + outline: ThemeConfig.getOutLine("页面内容") }, }) \ No newline at end of file diff --git a/docs/.vitepress/config/zht.ts b/docs/.vitepress/config/zht.ts index 918d0d6..d491f5c 100644 --- a/docs/.vitepress/config/zht.ts +++ b/docs/.vitepress/config/zht.ts @@ -21,11 +21,8 @@ export const zht = defineConfig({ ), footer: { message: '文檔由 VitePress 構建 | API引用由 litedoc 生成', - copyright: 'Copyright (C) 2020-2024 SnowyKami. All Rights Reserved' + copyright: ThemeConfig.copyright }, - outline: { - label: "頁面內容", - level: [2, 6] - } + outline: ThemeConfig.getOutLine("頁面內容") }, }) \ No newline at end of file