|
| 1 | +import { defineConfig } from 'vitepress' |
| 2 | + |
| 3 | +// 本地开发默认为 '/'。部署到 GitHub Pages 项目页时 CI 会设置 VITEPRESS_BASE=/connect/ |
| 4 | +const base = process.env.VITEPRESS_BASE ?? '/' |
| 5 | + |
| 6 | +export default defineConfig({ |
| 7 | + base, |
| 8 | + lang: 'zh-CN', |
| 9 | + title: 'GoZoox Connect', |
| 10 | + description: |
| 11 | + '轻量、强大的认证连接器(Auth Connect),支持 OAuth2、Doreamon、GitHub、飞书等。', |
| 12 | + cleanUrls: false, |
| 13 | + themeConfig: { |
| 14 | + logo: '/logo.svg', |
| 15 | + nav: [ |
| 16 | + { text: '指南', link: '/guide/introduction', activeMatch: '^/guide/' }, |
| 17 | + { text: '示例', link: '/examples/', activeMatch: '^/examples/' }, |
| 18 | + { text: 'GitHub', link: 'https://github.com/go-zoox/connect' } |
| 19 | + ], |
| 20 | + sidebar: { |
| 21 | + '/guide/': [ |
| 22 | + { |
| 23 | + text: '入门', |
| 24 | + items: [ |
| 25 | + { text: '简介', link: '/guide/introduction' }, |
| 26 | + { text: '安装', link: '/guide/installation' }, |
| 27 | + { text: '快速开始', link: '/guide/quick-start' }, |
| 28 | + { text: '部署形态', link: '/guide/architecture' } |
| 29 | + ] |
| 30 | + }, |
| 31 | + { |
| 32 | + text: '使用手册', |
| 33 | + items: [ |
| 34 | + { text: '命令行', link: '/guide/cli' }, |
| 35 | + { text: '配置', link: '/guide/config' }, |
| 36 | + { text: 'Docker 与编排', link: '/guide/docker' } |
| 37 | + ] |
| 38 | + } |
| 39 | + ], |
| 40 | + '/examples/': [ |
| 41 | + { |
| 42 | + text: '示例', |
| 43 | + items: [ |
| 44 | + { text: '概览', link: '/examples/' }, |
| 45 | + { text: 'Doreamon 模式', link: '/examples/doreamon' }, |
| 46 | + { text: 'GitHub OAuth', link: '/examples/github' }, |
| 47 | + { text: '飞书 OAuth', link: '/examples/feishu' }, |
| 48 | + { text: '上游代理(单站点)', link: '/examples/upstream' }, |
| 49 | + { text: '无认证穿透', link: '/examples/none' } |
| 50 | + ] |
| 51 | + } |
| 52 | + ] |
| 53 | + }, |
| 54 | + socialLinks: [{ icon: 'github', link: 'https://github.com/go-zoox/connect' }], |
| 55 | + footer: { |
| 56 | + message: '基于 MIT 许可证发布', |
| 57 | + copyright: 'Copyright © GoZoox' |
| 58 | + }, |
| 59 | + search: { provider: 'local' }, |
| 60 | + outline: { level: [2, 3] } |
| 61 | + } |
| 62 | +}) |
0 commit comments