2020-08-23 17:03:59 +08:00
|
|
|
|
const path = require("path");
|
|
|
|
|
|
2020-10-18 02:30:01 +08:00
|
|
|
|
module.exports = context => ({
|
2020-06-30 12:10:57 +08:00
|
|
|
|
title: "NoneBot",
|
|
|
|
|
description: "基于 酷Q 的 Python 异步 QQ 机器人框架",
|
|
|
|
|
markdown: {
|
2020-10-18 02:30:01 +08:00
|
|
|
|
lineNumbers: true
|
2020-06-30 12:10:57 +08:00
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* Extra tags to be injected to the page HTML `<head>`
|
|
|
|
|
*
|
|
|
|
|
* ref:https://v1.vuepress.vuejs.org/config/#head
|
|
|
|
|
*/
|
|
|
|
|
head: [
|
|
|
|
|
["link", { rel: "icon", href: "/logo.png" }],
|
2020-10-19 15:49:18 +08:00
|
|
|
|
["link", { rel: "manifest", href: "/manifest.json" }],
|
|
|
|
|
["meta", { name: "theme-color", content: "#ea5252" }],
|
2020-06-30 12:10:57 +08:00
|
|
|
|
["meta", { name: "application-name", content: "NoneBot" }],
|
|
|
|
|
["meta", { name: "apple-mobile-web-app-title", content: "NoneBot" }],
|
|
|
|
|
["meta", { name: "apple-mobile-web-app-capable", content: "yes" }],
|
|
|
|
|
[
|
|
|
|
|
"meta",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
{ name: "apple-mobile-web-app-status-bar-style", content: "black" }
|
2020-09-17 13:12:48 +08:00
|
|
|
|
],
|
2020-10-19 15:49:18 +08:00
|
|
|
|
[
|
|
|
|
|
"link",
|
|
|
|
|
{ rel: "apple-touch-icon", href: "/icons/apple-touch-icon-180x180.png" }
|
|
|
|
|
],
|
|
|
|
|
[
|
|
|
|
|
"link",
|
|
|
|
|
{
|
|
|
|
|
rel: "mask-icon",
|
|
|
|
|
href: "/icons/safari-pinned-tab.svg",
|
|
|
|
|
color: "#ea5252"
|
|
|
|
|
}
|
|
|
|
|
],
|
|
|
|
|
[
|
|
|
|
|
"meta",
|
|
|
|
|
{
|
|
|
|
|
name: "msapplication-TileImage",
|
|
|
|
|
content: "/icons/mstile-150x150.png"
|
|
|
|
|
}
|
|
|
|
|
],
|
|
|
|
|
["meta", { name: "msapplication-TileColor", content: "#ea5252" }],
|
2020-09-17 13:12:48 +08:00
|
|
|
|
[
|
|
|
|
|
"link",
|
|
|
|
|
{
|
|
|
|
|
rel: "stylesheet",
|
|
|
|
|
href:
|
2020-10-18 02:30:01 +08:00
|
|
|
|
"https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@5/css/all.min.css"
|
|
|
|
|
}
|
|
|
|
|
]
|
2020-06-30 12:10:57 +08:00
|
|
|
|
],
|
2020-08-23 17:03:59 +08:00
|
|
|
|
locales: {
|
|
|
|
|
"/": {
|
|
|
|
|
lang: "zh-CN",
|
|
|
|
|
title: "NoneBot",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
description: "基于 酷Q 的 Python 异步 QQ 机器人框架"
|
|
|
|
|
}
|
2020-08-23 17:03:59 +08:00
|
|
|
|
},
|
2020-06-30 12:10:57 +08:00
|
|
|
|
|
2020-10-18 01:39:34 +08:00
|
|
|
|
theme: "nonebot",
|
2020-06-30 12:10:57 +08:00
|
|
|
|
themeConfig: {
|
2020-08-23 17:03:59 +08:00
|
|
|
|
logo: "/logo.png",
|
2020-10-11 14:51:37 +08:00
|
|
|
|
repo: "nonebot/nonebot2",
|
2020-08-20 16:34:07 +08:00
|
|
|
|
docsDir: "docs",
|
2020-10-11 14:51:37 +08:00
|
|
|
|
docsBranch: "dev",
|
2020-08-23 17:03:59 +08:00
|
|
|
|
docsDirVersioned: "archive",
|
|
|
|
|
docsDirPages: "pages",
|
2020-06-30 12:10:57 +08:00
|
|
|
|
editLinks: true,
|
2020-08-20 16:34:07 +08:00
|
|
|
|
smoothScroll: true,
|
2020-08-23 17:03:59 +08:00
|
|
|
|
|
|
|
|
|
locales: {
|
|
|
|
|
"/": {
|
|
|
|
|
label: "简体中文",
|
|
|
|
|
selectText: "Languages",
|
|
|
|
|
editLinkText: "在 GitHub 上编辑此页",
|
|
|
|
|
lastUpdated: "上次更新",
|
2020-09-12 13:45:03 +08:00
|
|
|
|
nav: [
|
|
|
|
|
{ text: "主页", link: "/" },
|
|
|
|
|
{ text: "指南", link: "/guide/" },
|
2020-10-21 00:55:23 +08:00
|
|
|
|
{ text: "API", link: "/api/" },
|
|
|
|
|
{ text: "插件广场", link: "/plugin-store" }
|
2020-09-12 13:45:03 +08:00
|
|
|
|
],
|
2020-09-22 15:41:56 +08:00
|
|
|
|
sidebarDepth: 2,
|
2020-08-23 17:03:59 +08:00
|
|
|
|
sidebar: {
|
2020-09-12 13:45:03 +08:00
|
|
|
|
"/guide/": [
|
|
|
|
|
{
|
|
|
|
|
title: "指南",
|
|
|
|
|
path: "",
|
|
|
|
|
collapsable: false,
|
|
|
|
|
sidebar: "auto",
|
2020-09-17 13:12:48 +08:00
|
|
|
|
children: [
|
|
|
|
|
"",
|
|
|
|
|
"installation",
|
|
|
|
|
"getting-started",
|
2020-09-17 18:23:41 +08:00
|
|
|
|
"creating-a-project",
|
2020-09-19 22:08:06 +08:00
|
|
|
|
"basic-configuration",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
"writing-a-plugin"
|
|
|
|
|
]
|
|
|
|
|
}
|
2020-09-12 13:45:03 +08:00
|
|
|
|
],
|
2020-08-23 17:03:59 +08:00
|
|
|
|
"/api/": [
|
2020-08-20 15:07:05 +08:00
|
|
|
|
{
|
2020-08-23 17:03:59 +08:00
|
|
|
|
title: "NoneBot Api Reference",
|
|
|
|
|
path: "",
|
|
|
|
|
collapsable: false,
|
|
|
|
|
children: [
|
|
|
|
|
{
|
|
|
|
|
title: "nonebot 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "nonebot"
|
2020-08-23 17:03:59 +08:00
|
|
|
|
},
|
2020-09-13 00:18:31 +08:00
|
|
|
|
{
|
|
|
|
|
title: "nonebot.config 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "config"
|
2020-09-13 00:18:31 +08:00
|
|
|
|
},
|
2020-10-18 15:04:45 +08:00
|
|
|
|
{
|
|
|
|
|
title: "nonebot.plugin 模块",
|
|
|
|
|
path: "plugin"
|
|
|
|
|
},
|
2020-09-13 00:18:31 +08:00
|
|
|
|
{
|
2020-10-06 02:08:48 +08:00
|
|
|
|
title: "nonebot.matcher 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "matcher"
|
2020-08-23 17:03:59 +08:00
|
|
|
|
},
|
2020-09-13 13:01:23 +08:00
|
|
|
|
{
|
|
|
|
|
title: "nonebot.rule 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "rule"
|
2020-09-13 13:01:23 +08:00
|
|
|
|
},
|
2020-09-14 20:48:03 +08:00
|
|
|
|
{
|
|
|
|
|
title: "nonebot.permission 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "permission"
|
2020-09-14 20:48:03 +08:00
|
|
|
|
},
|
2020-10-06 02:08:48 +08:00
|
|
|
|
{
|
|
|
|
|
title: "nonebot.sched 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "sched"
|
2020-10-06 02:08:48 +08:00
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: "nonebot.log 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "log"
|
2020-10-06 02:08:48 +08:00
|
|
|
|
},
|
2020-09-13 00:43:31 +08:00
|
|
|
|
{
|
|
|
|
|
title: "nonebot.utils 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "utils"
|
2020-09-13 00:43:31 +08:00
|
|
|
|
},
|
2020-08-23 17:03:59 +08:00
|
|
|
|
{
|
2020-10-06 02:08:48 +08:00
|
|
|
|
title: "nonebot.typing 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "typing"
|
2020-10-06 02:08:48 +08:00
|
|
|
|
},
|
|
|
|
|
{
|
2020-08-23 17:03:59 +08:00
|
|
|
|
title: "nonebot.exception 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "exception"
|
2020-09-29 22:33:08 +08:00
|
|
|
|
},
|
2020-10-11 13:17:40 +08:00
|
|
|
|
{
|
|
|
|
|
title: "nonebot.drivers 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "drivers/"
|
2020-10-11 13:17:40 +08:00
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: "nonebot.drivers.fastapi 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "drivers/fastapi"
|
2020-10-11 13:17:40 +08:00
|
|
|
|
},
|
2020-09-29 23:10:29 +08:00
|
|
|
|
{
|
|
|
|
|
title: "nonebot.adapters 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "adapters/"
|
2020-09-29 23:10:29 +08:00
|
|
|
|
},
|
2020-09-29 22:33:08 +08:00
|
|
|
|
{
|
|
|
|
|
title: "nonebot.adapters.cqhttp 模块",
|
2020-10-18 02:30:01 +08:00
|
|
|
|
path: "adapters/cqhttp"
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
2020-06-30 12:10:57 +08:00
|
|
|
|
},
|
|
|
|
|
|
2020-08-23 17:03:59 +08:00
|
|
|
|
plugins: [
|
|
|
|
|
"@vuepress/plugin-back-to-top",
|
|
|
|
|
"@vuepress/plugin-medium-zoom",
|
2020-10-19 15:49:18 +08:00
|
|
|
|
[
|
|
|
|
|
"@vuepress/pwa",
|
|
|
|
|
{
|
|
|
|
|
serviceWorker: true,
|
|
|
|
|
updatePopup: {
|
|
|
|
|
message: "发现新内容",
|
|
|
|
|
buttonText: "刷新"
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
],
|
2020-08-23 17:03:59 +08:00
|
|
|
|
[
|
|
|
|
|
"versioning",
|
|
|
|
|
{
|
|
|
|
|
versionedSourceDir: path.resolve(context.sourceDir, "..", "archive"),
|
|
|
|
|
pagesSourceDir: path.resolve(context.sourceDir, "..", "pages"),
|
|
|
|
|
onNewVersion(version, versionDestPath) {
|
|
|
|
|
console.log(`Created version ${version} in ${versionDestPath}`);
|
2020-10-18 02:30:01 +08:00
|
|
|
|
}
|
|
|
|
|
}
|
2020-09-17 13:12:48 +08:00
|
|
|
|
],
|
|
|
|
|
[
|
|
|
|
|
"container",
|
|
|
|
|
{
|
|
|
|
|
type: "vue",
|
|
|
|
|
before: '<pre class="vue-container"><code>',
|
2020-10-18 02:30:01 +08:00
|
|
|
|
after: "</code></pre>"
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
]
|
2020-08-23 17:03:59 +08:00
|
|
|
|
});
|