diff --git a/.vitepress/config/en.ts b/.vitepress/config/en.ts index 6d334f0..f039fe4 100644 --- a/.vitepress/config/en.ts +++ b/.vitepress/config/en.ts @@ -18,12 +18,12 @@ export const config = defineConfig({ sidebar: [ { text: "Quickstart", - base: locale == 'en' ? '/quickstart' : `/${locale}/quickstart`, + base: locale == 'zh_CN' ? '/quickstart' : `/${locale}/quickstart`, items: sidebarQuickstart() }, { text: "Advanced", - base: locale == 'en' ? '/advanced' : `/${locale}/advanced`, + base: locale == 'zh_CN' ? '/advanced' : `/${locale}/advanced`, items: sidebarAdvanced() }, { @@ -33,7 +33,7 @@ export const config = defineConfig({ ...versions.map((version: string) => { return { text: version, - link: locale == 'en' ? `/version-${version}` : `/${locale}/version-${version}` + link: locale == 'zh_CN' ? `/version-${version}` : `/${locale}/version-${version}` } }) ] @@ -76,23 +76,23 @@ function nav(): DefaultTheme.NavItem[] { return [ { text: 'Home', - link: locale == 'en' ? '/' : `/${locale}/` + link: locale == 'zh_CN' ? '/' : `/${locale}/` }, { text: 'Document', - link: locale == 'en' ? '/quickstart/install' : `/${locale}/quickstart/install` + link: locale == 'zh_CN' ? '/quickstart/install' : `/${locale}/quickstart/install` }, { text: 'Support', - link: locale == 'en' ? '/support' : `/${locale}/support` + link: locale == 'zh_CN' ? '/support' : `/${locale}/support` }, { text: '🔥Certificate', - link: locale == 'en' ? '/cert' : `/${locale}/cert` + link: locale == 'zh_CN' ? '/cert' : `/${locale}/cert` }, { text: 'About', - link: locale == 'en' ? '/about' : `/${locale}/about` + link: locale == 'zh_CN' ? '/about' : `/${locale}/about` }, ] } diff --git a/.vitepress/config/index.ts b/.vitepress/config/index.ts index d302660..1c4c70d 100644 --- a/.vitepress/config/index.ts +++ b/.vitepress/config/index.ts @@ -9,8 +9,8 @@ import {config as zh_TW} from './zh_TW' export default defineConfig({ ...shared, locales: { - root: { label: 'English', ...en }, - zh_CN: {label: '简体中文', ...zh_CN}, + root: {label: '简体中文', ...zh_CN}, zh_TW: {label: '繁體中文', ...zh_TW}, + en: { label: 'English', ...en }, }, }) \ No newline at end of file diff --git a/.vitepress/config/shared.ts b/.vitepress/config/shared.ts index 33480bf..d5cdce8 100644 --- a/.vitepress/config/shared.ts +++ b/.vitepress/config/shared.ts @@ -10,7 +10,7 @@ export const shared = defineConfig({ title: 'AcePanel', rewrites: { - 'en/:rest*': ':rest*' + 'zh_CN/:rest*': ':rest*' }, lastUpdated: true,