-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
1. 更新 vuepress 版本 2. 切换 yarn 到 pnpm 3. 国际化功能
- Loading branch information
Showing
35 changed files
with
2,886 additions
and
8,159 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
shamefully-hoist=true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
import type { DefaultThemeOptions } from 'vuepress'; | ||
import { defineUserConfig } from 'vuepress'; | ||
import { navbar, sidebar } from './configs'; | ||
|
||
export default defineUserConfig<DefaultThemeOptions>({ | ||
// 站点配置 | ||
lang: 'zh-CN', | ||
title: 'Distributed Update System', | ||
description: 'Upgrade anything any where', | ||
head: [['link', { rel: 'icon', href: '/logo.png' }]], | ||
|
||
// 语言配置 | ||
locales: { | ||
'/': { | ||
lang: 'zh-CN', | ||
title: 'Distributed Update System', | ||
description: 'Upgrade anything any where', | ||
}, | ||
'/en/': { | ||
lang: 'en-US', | ||
title: 'Distributed Update System', | ||
description: 'Upgrade anything any where', | ||
}, | ||
}, | ||
|
||
// 主题配置 | ||
theme: '@vuepress/theme-default', | ||
themeConfig: { | ||
logo: '/logo.png', | ||
repo: 'DUpdateSystem', | ||
locales: { | ||
'/': { | ||
// navbar | ||
navbar: navbar.zh, | ||
selectLanguageName: '简体中文', | ||
selectLanguageText: '选择语言', | ||
selectLanguageAriaLabel: '选择语言', | ||
|
||
// sidebar | ||
sidebar: sidebar.zh, | ||
|
||
// page meta | ||
editLinkText: '在 GitHub 上编辑此页', | ||
lastUpdatedText: '上次更新', | ||
contributorsText: '贡献者', | ||
|
||
// custom containers | ||
tip: '提示', | ||
warning: '注意', | ||
danger: '警告', | ||
|
||
// 404 page | ||
notFound: [ | ||
'这里什么都没有', | ||
'我们怎么到这来了?', | ||
'这是一个 404 页面', | ||
'看起来我们进入了错误的链接', | ||
], | ||
backToHome: '返回首页', | ||
|
||
// a11y | ||
openInNewWindow: '在新窗口打开', | ||
toggleDarkMode: '切换夜间模式', | ||
toggleSidebar: '切换侧边栏', | ||
}, | ||
|
||
'/en/': { | ||
// navbar | ||
navbar: navbar.en, | ||
selectLanguageName: 'English', | ||
|
||
// sidebar | ||
sidebar: sidebar.en, | ||
|
||
// page meta | ||
editLinkText: 'Edit this page on GitHub', | ||
}, | ||
}, | ||
|
||
docsRepo: 'DUpdateSystem/docs', | ||
docsBranch: 'master', | ||
}, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
export * as navbar from './navbar'; | ||
export * as sidebar from './sidebar'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import type { NavbarConfig } from '@vuepress/theme-default'; | ||
|
||
export const en: NavbarConfig = [ | ||
{ text: 'User Guide', link: '/en/guide/' }, | ||
{ text: 'FAQ', link: '/en/faq/' }, | ||
{ text: 'Developer Documentation', link: '/en/dev/' }, | ||
{ text: 'Discussion', link: '/en/discussion/' }, | ||
{ | ||
text: 'Client Downloads', | ||
children: [ | ||
{ | ||
text: 'Github', | ||
link: '/~https://github.com/DUpdateSystem/UpgradeAll/releases', | ||
}, | ||
{ | ||
text: 'F-Droid', | ||
link: 'https://f-droid.org/packages/net.xzos.upgradeall', | ||
}, | ||
{ | ||
text: 'Telegram CI', | ||
link: 'https://t.me/upallci', | ||
}, | ||
], | ||
}, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
export * from './en'; | ||
export * from './zh'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import type { NavbarConfig } from '@vuepress/theme-default'; | ||
|
||
export const zh: NavbarConfig = [ | ||
{ text: '用户指南', link: '/guide/' }, | ||
{ text: '常见问题', link: '/faq/' }, | ||
{ text: '开发者文档', link: '/dev/' }, | ||
{ text: '参与讨论', link: '/discussion/' }, | ||
{ | ||
text: '客户端下载', | ||
children: [ | ||
{ | ||
text: '酷安', | ||
link: 'https://www.coolapk.com/apk/net.xzos.upgradeall', | ||
}, | ||
{ | ||
text: 'Github', | ||
link: '/~https://github.com/DUpdateSystem/UpgradeAll/releases', | ||
}, | ||
{ | ||
text: 'F-Droid', | ||
link: 'https://f-droid.org/packages/net.xzos.upgradeall', | ||
}, | ||
{ | ||
text: 'Telegram CI', | ||
link: 'https://t.me/upallci', | ||
}, | ||
], | ||
}, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import type { SidebarConfig } from '@vuepress/theme-default'; | ||
|
||
export const en: SidebarConfig = [ | ||
'/en/guide/README.md', | ||
'/en/faq/README.md', | ||
{ | ||
text: 'Developer Documention', | ||
link: '/en/dev/', | ||
collapsible: true, | ||
children: [ | ||
'/en/dev/README.md', | ||
'/en/dev/contributing.md', | ||
'/en/dev/file-dir-structure.md', | ||
'/en/dev/app-json-rules.md', | ||
'/en/dev/hub-json-rules.md', | ||
'/en/dev/python-scripts.md', | ||
'/en/dev/bs4-function.md', | ||
'/en/dev/docs.md', | ||
], | ||
}, | ||
'/en/discussion/README.md', | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
export * from './en'; | ||
export * from './zh'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import type { SidebarConfig } from '@vuepress/theme-default'; | ||
|
||
export const zh: SidebarConfig = [ | ||
'/guide/README.md', | ||
'/faq/README.md', | ||
{ | ||
text: 'Developer Documention', | ||
link: '/dev/', | ||
collapsible: true, | ||
children: [ | ||
'/dev/README.md', | ||
'/dev/contributing.md', | ||
'/dev/file-dir-structure.md', | ||
'/dev/app-json-rules.md', | ||
'/dev/hub-json-rules.md', | ||
'/dev/python-scripts.md', | ||
'/dev/bs4-function.md', | ||
'/dev/docs.md', | ||
], | ||
}, | ||
'/discussion/README.md', | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,11 @@ | ||
--- | ||
home: true | ||
heroImage: /logo.png | ||
actionText: 快速上手 → | ||
actionLink: /guide/ | ||
features: | ||
actions: | ||
- text: '用户指南' | ||
link: /guide/ | ||
- text: 'English' | ||
link: /en/ | ||
type: secondary | ||
footer: GPL-3.0 Licensed | Copyright © 2019-present DUpdateSystem | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,7 +17,7 @@ | |
|
||
无论你选择何种方式提交,我们都将及时处理 | ||
|
||
::: tip 提示 | ||
::: tip | ||
无论你选择何种方法提交,为了便于我们快速地处理,请遵循[贡献准则](./contributing)。 | ||
::: | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.