diff --git a/docs-site/docusaurus.config.ts b/docs-site/docusaurus.config.ts
index 3cf703b..22e7d12 100644
--- a/docs-site/docusaurus.config.ts
+++ b/docs-site/docusaurus.config.ts
@@ -76,20 +76,25 @@ const config: Config = {
label: 'Docs',
},
{
- href: 'https://github.com/Awuqing/BackupX/releases',
- label: 'Downloads',
+ to: '/docs/deployment/docker',
+ label: 'Deployment',
position: 'left',
},
{
- to: '/community',
- label: 'Community',
+ to: '/docs/operations/monitoring',
+ label: 'Operations',
position: 'left',
},
{
- to: '/sponsors',
- label: 'Sponsors',
+ to: '/docs/reference/api',
+ label: 'API',
position: 'left',
},
+ {
+ to: '/community',
+ label: 'Community',
+ position: 'right',
+ },
{
type: 'localeDropdown',
position: 'right',
@@ -105,44 +110,27 @@ const config: Config = {
style: 'dark',
links: [
{
- title: 'Docs',
+ title: 'Documentation',
items: [
{label: 'Introduction', to: '/docs/intro'},
{label: 'Quick Start', to: '/docs/getting-started/quick-start'},
- {label: 'Upgrade & Recovery', to: '/docs/operations/upgrade-recovery'},
+ {label: 'Configuration', to: '/docs/deployment/configuration'},
],
},
{
- title: 'Features',
+ title: 'Operations',
items: [
- {label: 'SAP HANA', to: '/docs/features/sap-hana'},
- {label: 'Multi-Node Cluster', to: '/docs/features/multi-node'},
- {label: 'API Reference', to: '/docs/reference/api'},
+ {label: 'Monitoring', to: '/docs/operations/monitoring'},
+ {label: 'Security', to: '/docs/operations/security'},
+ {label: 'Troubleshooting', to: '/docs/operations/troubleshooting'},
],
},
{
- title: 'More',
+ title: 'Project',
items: [
{label: 'GitHub', href: 'https://github.com/Awuqing/BackupX'},
{label: 'Releases', href: 'https://github.com/Awuqing/BackupX/releases'},
- {label: 'Docker Hub', href: 'https://hub.docker.com/r/awuqing/backupx'},
- {label: 'Issues', href: 'https://github.com/Awuqing/BackupX/issues'},
- ],
- },
- {
- title: 'Community',
- items: [
- {label: 'Contributors', href: 'https://github.com/Awuqing/BackupX/graphs/contributors'},
- {label: 'Pull Requests', href: 'https://github.com/Awuqing/BackupX/pulls'},
- {label: 'Sponsor', to: '/sponsors'},
- ],
- },
- {
- title: 'Sponsors',
- items: [
- {label: 'Sponsor BackupX', href: 'https://github.com/sponsors/Awuqing'},
- {label: 'Partnership', href: 'https://github.com/Awuqing/BackupX/issues/new/choose'},
- {label: 'Sponsor tiers', to: '/sponsors'},
+ {label: 'Community', to: '/community'},
],
},
],
diff --git a/docs-site/i18n/zh-CN/code.json b/docs-site/i18n/zh-CN/code.json
index e22bb85..0d158c3 100644
--- a/docs-site/i18n/zh-CN/code.json
+++ b/docs-site/i18n/zh-CN/code.json
@@ -1,160 +1,115 @@
{
- "home.badge": {
- "message": "开源备份控制平面 · v2.2.1",
- "description": "Version badge on the hero"
- },
- "home.title.part1": {
- "message": "面向自托管服务器的",
- "description": "Hero title, first line"
- },
- "home.title.part2": {
- "message": "备份编排平台。",
- "description": "Hero title accent second line"
- },
- "home.tagline": {
- "message": "在一个清爽控制台中管理文件、数据库、SAP HANA 和远程节点备份。控制平面自己掌握,存储后端灵活选择。",
- "description": "Tagline on the home page"
- },
- "home.pageTitle": {
- "message": "面向自托管服务器的备份编排",
- "description": "Page
element on the home page"
- },
- "home.getStarted": {
- "message": "快速开始",
- "description": "Primary CTA on the home page"
- },
- "home.metric.backends": {
- "message": "存储后端",
- "description": "Hero metric label: storage backends"
- },
- "home.metric.backupTypes": {
- "message": "远程执行",
- "description": "Hero metric label: backup types"
- },
- "home.metric.license": {
- "message": "开源协议",
- "description": "Hero metric label: license"
- },
- "home.visual.eyebrow": {"message": "BackupX 控制台"},
- "home.visual.title": {"message": "运维概览"},
- "home.visual.status": {"message": "健康"},
- "home.visual.success": {"message": "成功率"},
- "home.visual.nodes": {"message": "活跃节点"},
- "home.visual.targets": {"message": "存储目标"},
- "home.visual.row1.title": {"message": "PostgreSQL 夜间备份"},
- "home.visual.row1.desc": {"message": "加密归档已上传至 S3"},
- "home.visual.row2.title": {"message": "SAP HANA 快照"},
- "home.visual.row2.desc": {"message": "正在 agent-shanghai-02 上运行"},
- "home.visual.row3.title": {"message": "保留策略清理"},
- "home.visual.row3.desc": {"message": "下一次执行在 4 小时后"},
- "home.command.title": {"message": "使用 Docker 启动"},
+ "home.badge": {"message": "BackupX 文档 · v2.2.1"},
+ "home.title.part1": {"message": "可靠地运维 BackupX,"},
+ "home.title.part2": {"message": "每一步都有依据。"},
+ "home.tagline": {"message": "从部署控制平面、连接存储与远程 Agent,到持续观测和验证恢复,一套务实文档覆盖完整运维路径。"},
+ "home.pageTitle": {"message": "面向自托管服务器的备份编排"},
+ "home.getStarted": {"message": "使用 Docker 开始"},
+ "home.viewSource": {"message": "查看源码"},
+ "home.supported.label": {"message": "支持的运行环境"},
+ "home.supported.docker": {"message": "Docker"},
+ "home.supported.linux": {"message": "Linux"},
+ "home.supported.windows": {"message": "Windows Agent"},
+ "home.guide.label": {"message": "推荐文档路径"},
+ "home.guide.kicker": {"message": "从这里开始"},
+ "home.guide.hint": {"message": "为下一项工作选择指南"},
+ "home.guide.install.title": {"message": "安装 BackupX"},
+ "home.guide.install.desc": {"message": "Docker、Compose 或独立二进制"},
+ "home.guide.cluster.title": {"message": "连接远程节点"},
+ "home.guide.cluster.desc": {"message": "Agent、代理、私有 CA 与堡垒机"},
+ "home.guide.security.title": {"message": "加固运维环境"},
+ "home.guide.security.desc": {"message": "安全控制、监控与审计记录"},
+ "home.guide.recovery.title": {"message": "准备恢复方案"},
+ "home.guide.recovery.desc": {"message": "升级、回滚、恢复与故障排查"},
- "section.features.tag": {
- "message": "核心能力",
- "description": "FEATURES section tag"
- },
- "section.features.title": {
- "message": "该有的都有,多余的没有",
- "description": "Features section title"
- },
- "section.features.subtitle": {
- "message": "备份 Runner、存储 Provider、调度、集群 — 每一块都经过打磨。",
- "description": "Features section subtitle"
- },
-
- "feat.types.title": {"message": "多种备份类型"},
- "feat.types.desc": {"message": "文件与目录(支持多源路径),以及 MySQL、PostgreSQL、SQLite、SAP HANA 统一管理。"},
- "feat.storage.title": {"message": "70+ 存储后端"},
- "feat.storage.desc": {"message": "内置阿里云 OSS、腾讯云 COS、七牛、S3、Google Drive、WebDAV、FTP,以及 SFTP、Azure Blob、Dropbox 等 rclone 后端。"},
- "feat.scheduling.title": {"message": "调度与保留策略"},
- "feat.scheduling.desc": {"message": "基于 Cron 的可视化调度编辑器,支持按天数/份数自动保留和空目录清理。"},
- "feat.cluster.title": {"message": "多节点集群"},
- "feat.cluster.desc": {"message": "Master-Agent 采用 Agent 主动出站轮询。支持代理、私有 CA 与 SSH 堡垒机,无需反向连通性。"},
- "feat.security.title": {"message": "默认安全"},
- "feat.security.desc": {"message": "JWT 认证、bcrypt、AES-256-GCM 加密配置、可选备份加密、完整审计日志。"},
- "feat.deploy.title": {"message": "部署轻量"},
- "feat.deploy.desc": {"message": "单个静态二进制 + 内嵌 SQLite。Docker 一键启动或裸机 — 零外部依赖。"},
- "feat.learnMore": {"message": "了解更多"},
+ "section.features.tag": {"message": "文档路径"},
+ "section.features.title": {"message": "从部署到恢复,不依赖猜测"},
+ "section.features.subtitle": {"message": "每条路径都把产品能力与生产环境所需的配置、安全和运维决策直接关联。"},
+ "feat.install.title": {"message": "安装与升级"},
+ "feat.install.desc": {"message": "选择 Docker、Compose 或独立二进制,并保持部署过程可重复。"},
+ "feat.types.title": {"message": "保护文件与数据库"},
+ "feat.types.desc": {"message": "配置文件、MySQL、PostgreSQL、SQLite 和 SAP HANA 备份工作负载。"},
+ "feat.storage.title": {"message": "连接存储目标"},
+ "feat.storage.desc": {"message": "通过一致流程使用原生 Provider 或任意受支持的 rclone 后端。"},
+ "feat.cluster.title": {"message": "构建远程节点集群"},
+ "feat.cluster.desc": {"message": "通过代理、私有 CA 或 SSH 堡垒机部署仅出站连接的 Agent。"},
+ "feat.monitor.title": {"message": "监控日常运行"},
+ "feat.monitor.desc": {"message": "持续查看任务健康、存储容量、通知、日志和服务就绪状态。"},
+ "feat.recovery.title": {"message": "按验证过的方案恢复"},
+ "feat.recovery.desc": {"message": "预先准备升级、回滚点、恢复验证和事件故障排查。"},
"showcase.tag": {"message": "产品界面"},
- "showcase.title": {"message": "精心打磨的控制台,而非 DIY 脚本"},
- "showcase.subtitle": {"message": "每个页面都为运维而生 — 可观测优先,可配置次之。"},
+ "showcase.title": {"message": "部署前先了解完整操作流程"},
+ "showcase.subtitle": {"message": "每张产品截图都连接到对应指南,说明背后的任务、配置和运行模型。"},
+ "showcase.tabs.label": {"message": "BackupX 产品界面"},
+ "showcase.preview.label": {"message": "BackupX 控制台"},
"showcase.tab.dashboard": {"message": "仪表盘"},
"showcase.tab.tasks": {"message": "备份任务"},
"showcase.tab.storage": {"message": "存储目标"},
"showcase.tab.nodes": {"message": "多节点"},
+ "showcase.dashboard.alt": {"message": "显示备份健康和存储使用情况的 BackupX 仪表盘"},
"showcase.dashboard.title": {"message": "一眼掌握全局"},
- "showcase.dashboard.desc": {"message": "备份成功率、存储使用量、最近执行记录、即将触发的计划 — 一页实时数据。"},
+ "showcase.dashboard.desc": {"message": "备份成功率、存储使用量、最近执行记录和即将触发的计划集中显示在一个实时页面。"},
+ "showcase.tasks.alt": {"message": "BackupX 备份任务管理界面"},
"showcase.tasks.title": {"message": "可视化任务编辑器"},
- "showcase.tasks.desc": {"message": "文件、MySQL、PostgreSQL、SQLite、SAP HANA — 三步完成。Cron 编辑器、多目标分发、保留策略、压缩、加密 — 点击即用。"},
- "showcase.storage.title": {"message": "70+ 后端,统一体验"},
- "showcase.storage.desc": {"message": "阿里云 OSS、腾讯云 COS、S3、Google Drive、WebDAV — 加上每一种 rclone 后端。测试连接、收藏、查看实时容量。"},
- "showcase.nodes.title": {"message": "几分钟搭起 Master-Agent"},
- "showcase.nodes.desc": {"message": "创建节点、复制令牌、在任意远程主机启动 Agent。路由到节点的任务在本地执行并直接上传到存储 — 无需反向连通性。"},
+ "showcase.tasks.desc": {"message": "通过三步向导配置文件、MySQL、PostgreSQL、SQLite 和 SAP HANA,并绑定调度、多目标、保留、压缩和加密。"},
+ "showcase.storage.alt": {"message": "BackupX 存储目标管理界面"},
+ "showcase.storage.title": {"message": "多种后端,统一流程"},
+ "showcase.storage.desc": {"message": "以一致表单管理阿里云 OSS、腾讯云 COS、S3、Google Drive、WebDAV 及 rclone 后端,并测试连接和查看容量。"},
+ "showcase.nodes.alt": {"message": "BackupX 远程节点管理界面"},
+ "showcase.nodes.title": {"message": "快速搭建 Master-Agent"},
+ "showcase.nodes.desc": {"message": "创建节点、复制令牌并启动远程 Agent。任务在节点本地执行并直接上传存储,无需反向网络连通。"},
"showcase.cta": {"message": "开始阅读文档"},
"community.tag": {"message": "社区"},
- "community.pageTitle": {"message": "社区、赞助商与贡献者"},
- "community.pageDescription": {"message": "赞助 BackupX,了解贡献者,并找到务实的参与方式。"},
- "community.title": {"message": "开放协作,面向长期运维"},
- "community.subtitle": {"message": "备份软件的信任来自透明发布、真实部署反馈,以及足够务实的贡献路径。"},
- "community.sponsor.kicker": {"message": "赞助商"},
- "community.sponsor.wallTitle": {"message": "赞助商"},
- "community.sponsor.title": {"message": "支持你依赖的备份基础设施"},
+ "community.pageTitle": {"message": "社区、赞助与贡献者"},
+ "community.pageDescription": {"message": "反馈真实部署约束、完善文档,或为 BackupX 提交可验证的改进。"},
+ "community.title": {"message": "开放协作让运维知识持续完善"},
+ "community.subtitle": {"message": "反馈真实部署约束、完善运行手册,或通过可复现验证提交聚焦的改动。"},
+ "community.path.kicker": {"message": "贡献路径"},
+ "community.path.guide": {"message": "贡献指南"},
+ "community.path.issues.title": {"message": "反馈生产环境问题"},
+ "community.path.issues.desc": {"message": "提交日志、部署拓扑和恢复预期。"},
+ "community.path.docs.title": {"message": "完善文档与示例"},
+ "community.path.docs.desc": {"message": "贡献存储、Agent 和数据库部署指南。"},
+ "community.path.code.title": {"message": "提交聚焦的 Pull Request"},
+ "community.path.code.desc": {"message": "保持改动可测试、可审查,并贴合现有架构。"},
+ "community.contributor.kicker": {"message": "贡献者"},
+ "community.contributor.all": {"message": "查看全部"},
+ "community.contributor.source": {"message": "通过 GitHub contributors API 加载,并提供本地回退数据。"},
+ "community.contributor.botRole": {"message": "自动化贡献者"},
+ "community.contributor.githubRole": {"message": "GitHub 贡献者"},
+ "community.contributor.contributions": {"message": "{count} 次贡献"},
+ "community.sponsor.bandTitle": {"message": "支持长期维护"},
+ "community.sponsor.bandDesc": {"message": "支持兼容性测试、恢复工作和面向运维者的文档。"},
+ "community.sponsor.learnMore": {"message": "了解赞助方案"},
+ "community.sponsor.title": {"message": "支持可靠的备份基础设施"},
+ "community.sponsor.programDesc": {"message": "赞助将用于测试覆盖、恢复可信度、Provider 兼容性,以及运维人员可以直接应用的文档。"},
"community.sponsor.cta": {"message": "赞助 BackupX"},
- "community.sponsor.openSlot": {"message": "赞助席位开放"},
- "community.sponsor.logo.project": {"message": "项目赞助"},
- "community.sponsor.logo.cloud": {"message": "云服务伙伴"},
- "community.sponsor.logo.object": {"message": "对象存储"},
- "community.sponsor.logo.cdn": {"message": "CDN 伙伴"},
- "community.sponsor.logo.database": {"message": "数据库伙伴"},
- "community.sponsor.logo.security": {"message": "安全审计"},
- "community.sponsor.logo.agent": {"message": "远程节点实验室"},
- "community.sponsor.logo.docs": {"message": "文档赞助"},
- "community.sponsor.logo.release": {"message": "发布赞助"},
- "community.sponsor.logo.s3": {"message": "S3 兼容"},
- "community.sponsor.logo.webdav": {"message": "WebDAV 伙伴"},
- "community.sponsor.logo.sftp": {"message": "SFTP 伙伴"},
- "community.sponsor.logo.docker": {"message": "容器伙伴"},
- "community.sponsor.logo.mirror": {"message": "镜像伙伴"},
- "community.sponsor.logo.restore": {"message": "恢复演练"},
- "community.sponsor.logo.qa": {"message": "测试实验室"},
- "community.sponsor.logo.oss": {"message": "开源支持"},
- "community.sponsor.logo.open": {"message": "赞助席位开放"},
"community.sponsor.infrastructure.label": {"message": "基础设施"},
- "community.sponsor.infrastructure.title": {"message": "云与存储生态伙伴"},
- "community.sponsor.infrastructure.desc": {"message": "帮助 BackupX 覆盖对象存储、WebDAV、SFTP 以及区域云平台的真实验证。"},
- "community.sponsor.security.label": {"message": "安全"},
- "community.sponsor.security.title": {"message": "审计与可靠性支持者"},
- "community.sponsor.security.desc": {"message": "支持加密、恢复演练、发布签名和运维检查等强化工作。"},
+ "community.sponsor.infrastructure.title": {"message": "云与存储兼容性"},
+ "community.sponsor.infrastructure.desc": {"message": "支持对象存储、WebDAV、SFTP 和区域云平台的真实验证。"},
+ "community.sponsor.security.label": {"message": "可靠性"},
+ "community.sponsor.security.title": {"message": "安全与恢复工作"},
+ "community.sponsor.security.desc": {"message": "支持加密审查、恢复演练、发布签名和运维检查。"},
"community.sponsor.community.label": {"message": "社区"},
- "community.sponsor.community.title": {"message": "开源支持者"},
- "community.sponsor.community.desc": {"message": "支持文档、示例、平台测试和贡献者引导。"},
+ "community.sponsor.community.title": {"message": "文档与贡献者支持"},
+ "community.sponsor.community.desc": {"message": "改善指南、示例、平台测试和贡献者体验。"},
+ "community.sponsor.tier.title": {"message": "支持方式"},
+ "community.sponsor.tier.subtitle": {"message": "根据团队依赖 BackupX 的方式选择合适层级。"},
"community.sponsor.tier.backer.name": {"message": "Backer"},
"community.sponsor.tier.backer.amount": {"message": "适合个人与小团队"},
- "community.sponsor.tier.backer.desc": {"message": "支持文档、Issue 分流、兼容性测试和小型体验改进。"},
+ "community.sponsor.tier.backer.desc": {"message": "支持文档、Issue 分流、兼容性测试和聚焦的易用性改进。"},
"community.sponsor.tier.partner.name": {"message": "Partner"},
"community.sponsor.tier.partner.amount": {"message": "适合存储与基础设施厂商"},
"community.sponsor.tier.partner.desc": {"message": "支持 Provider 验证、部署示例、基准说明和集成指南。"},
"community.sponsor.tier.enterprise.name": {"message": "Enterprise"},
"community.sponsor.tier.enterprise.amount": {"message": "适合生产环境使用方"},
- "community.sponsor.tier.enterprise.desc": {"message": "赞助恢复演练、发布加固、审计和长期维护等可靠性工作。"},
- "community.contributor.kicker": {"message": "贡献者"},
- "community.contributor.all": {"message": "查看全部"},
- "community.contributor.source": {"message": "浏览器端通过 GitHub contributors API 获取。"},
- "community.contributor.botRole": {"message": "自动化贡献者"},
- "community.contributor.githubRole": {"message": "GitHub 贡献者"},
- "community.contributor.contributions": {"message": "{count} 次贡献"},
- "community.path.kicker": {"message": "贡献路径"},
- "community.path.issues.title": {"message": "反馈生产问题"},
- "community.path.issues.desc": {"message": "提交日志、部署拓扑和恢复预期。"},
- "community.path.docs.title": {"message": "完善文档与示例"},
- "community.path.docs.desc": {"message": "贡献存储、Agent 和数据库部署指南。"},
- "community.path.code.title": {"message": "提交聚焦的 PR"},
- "community.path.code.desc": {"message": "保持改动小而可测,并贴合现有架构。"},
- "sponsors.pageTitle": {"message": "赞助商"},
- "sponsors.pageDescription": {"message": "赞助 BackupX 的可靠性、文档、存储兼容性和长期维护。"},
- "sponsors.tag": {"message": "赞助商"},
- "sponsors.title": {"message": "赞助 BackupX 生态"},
- "sponsors.subtitle": {"message": "赞助帮助 BackupX 更贴近真实运维:经过验证的存储 Provider、可靠发布、恢复信心和更完善的文档。"}
+ "community.sponsor.tier.enterprise.desc": {"message": "支持恢复演练、发布加固、审计和长期维护。"},
+
+ "sponsors.pageTitle": {"message": "赞助 BackupX"},
+ "sponsors.pageDescription": {"message": "支持 BackupX 的可靠性、文档、存储兼容性和长期维护。"},
+ "sponsors.tag": {"message": "赞助"},
+ "sponsors.title": {"message": "让关键维护工作持续进行"},
+ "sponsors.subtitle": {"message": "赞助用于真实 Provider 验证、可靠发布、恢复演练和更完善的运维文档。"}
}
diff --git a/docs-site/i18n/zh-CN/docusaurus-theme-classic/footer.json b/docs-site/i18n/zh-CN/docusaurus-theme-classic/footer.json
index f84afbe..ff1fab9 100644
--- a/docs-site/i18n/zh-CN/docusaurus-theme-classic/footer.json
+++ b/docs-site/i18n/zh-CN/docusaurus-theme-classic/footer.json
@@ -1,23 +1,14 @@
{
- "link.title.Docs": {"message": "文档"},
- "link.title.Features": {"message": "功能"},
- "link.title.More": {"message": "更多"},
- "link.title.Community": {"message": "社区"},
- "link.title.Sponsors": {"message": "赞助商"},
+ "link.title.Documentation": {"message": "文档"},
+ "link.title.Operations": {"message": "运维"},
+ "link.title.Project": {"message": "项目"},
"link.item.label.Introduction": {"message": "简介"},
"link.item.label.Quick Start": {"message": "快速开始"},
- "link.item.label.Upgrade & Recovery": {"message": "升级与恢复"},
- "link.item.label.SAP HANA": {"message": "SAP HANA"},
- "link.item.label.Multi-Node Cluster": {"message": "多节点集群"},
- "link.item.label.API Reference": {"message": "API 参考"},
+ "link.item.label.Configuration": {"message": "配置"},
+ "link.item.label.Monitoring": {"message": "监控"},
+ "link.item.label.Security": {"message": "安全"},
+ "link.item.label.Troubleshooting": {"message": "故障排查"},
"link.item.label.GitHub": {"message": "GitHub"},
- "link.item.label.Releases": {"message": "Releases"},
- "link.item.label.Docker Hub": {"message": "Docker Hub"},
- "link.item.label.Issues": {"message": "Issues"},
- "link.item.label.Contributors": {"message": "贡献者"},
- "link.item.label.Pull Requests": {"message": "Pull Requests"},
- "link.item.label.Sponsor": {"message": "赞助"},
- "link.item.label.Sponsor BackupX": {"message": "赞助 BackupX"},
- "link.item.label.Partnership": {"message": "合作伙伴"},
- "link.item.label.Sponsor tiers": {"message": "赞助层级"}
+ "link.item.label.Releases": {"message": "发布版本"},
+ "link.item.label.Community": {"message": "社区"}
}
diff --git a/docs-site/i18n/zh-CN/docusaurus-theme-classic/navbar.json b/docs-site/i18n/zh-CN/docusaurus-theme-classic/navbar.json
index 96c2044..d2e2e51 100644
--- a/docs-site/i18n/zh-CN/docusaurus-theme-classic/navbar.json
+++ b/docs-site/i18n/zh-CN/docusaurus-theme-classic/navbar.json
@@ -1,22 +1,8 @@
{
- "item.label.Docs": {
- "message": "文档",
- "description": "Navbar item: Docs"
- },
- "item.label.Downloads": {
- "message": "下载",
- "description": "Navbar item: Downloads"
- },
- "item.label.Community": {
- "message": "社区",
- "description": "Navbar item: Community"
- },
- "item.label.Sponsors": {
- "message": "赞助商",
- "description": "Navbar item: Sponsors"
- },
- "item.label.GitHub": {
- "message": "GitHub",
- "description": "Navbar item: GitHub"
- }
+ "item.label.Docs": {"message": "文档"},
+ "item.label.Deployment": {"message": "部署"},
+ "item.label.Operations": {"message": "运维"},
+ "item.label.API": {"message": "API"},
+ "item.label.Community": {"message": "社区"},
+ "item.label.GitHub": {"message": "GitHub"}
}
diff --git a/docs-site/src/components/DocIcon/index.tsx b/docs-site/src/components/DocIcon/index.tsx
new file mode 100644
index 0000000..b2f1ade
--- /dev/null
+++ b/docs-site/src/components/DocIcon/index.tsx
@@ -0,0 +1,172 @@
+import type {ReactNode} from 'react';
+
+export type DocIconName =
+ | 'arrowRight'
+ | 'bookOpen'
+ | 'box'
+ | 'check'
+ | 'clock'
+ | 'cloud'
+ | 'database'
+ | 'download'
+ | 'external'
+ | 'github'
+ | 'heart'
+ | 'monitor'
+ | 'network'
+ | 'restore'
+ | 'server'
+ | 'shield'
+ | 'storage'
+ | 'terminal'
+ | 'users'
+ | 'wrench';
+
+type DocIconProps = {
+ name: DocIconName;
+ size?: number;
+ className?: string;
+};
+
+const ICON_PATHS: Record, ReactNode> = {
+ arrowRight: (
+ <>
+
+
+ >
+ ),
+ bookOpen: (
+ <>
+
+
+ >
+ ),
+ box: (
+ <>
+
+
+
+ >
+ ),
+ check: ,
+ clock: (
+ <>
+
+
+ >
+ ),
+ cloud: ,
+ database: (
+ <>
+
+
+
+ >
+ ),
+ download: (
+ <>
+
+
+
+ >
+ ),
+ external: (
+ <>
+
+
+
+ >
+ ),
+ heart: ,
+ monitor: (
+ <>
+
+
+
+ >
+ ),
+ network: (
+ <>
+
+
+
+
+ >
+ ),
+ restore: (
+ <>
+
+
+
+ >
+ ),
+ server: (
+ <>
+
+
+
+ >
+ ),
+ shield: (
+ <>
+
+
+ >
+ ),
+ storage: (
+ <>
+
+
+ >
+ ),
+ terminal: (
+ <>
+
+
+ >
+ ),
+ users: (
+ <>
+
+
+
+ >
+ ),
+ wrench: (
+ <>
+
+ >
+ ),
+};
+
+export default function DocIcon({name, size = 20, className}: DocIconProps): ReactNode {
+ if (name === 'github') {
+ return (
+
+
+
+ );
+ }
+
+ return (
+
+ {ICON_PATHS[name]}
+
+ );
+}
diff --git a/docs-site/src/components/HomepageCommunity/index.tsx b/docs-site/src/components/HomepageCommunity/index.tsx
index b363eee..ecc3e0f 100644
--- a/docs-site/src/components/HomepageCommunity/index.tsx
+++ b/docs-site/src/components/HomepageCommunity/index.tsx
@@ -3,14 +3,9 @@ import {useEffect, useState} from 'react';
import Heading from '@theme/Heading';
import Translate from '@docusaurus/Translate';
import Link from '@docusaurus/Link';
+import DocIcon, {type DocIconName} from '@site/src/components/DocIcon';
import styles from './styles.module.css';
-type SponsorSlot = {
- brand: ReactNode;
- name: ReactNode;
- href?: string;
-};
-
type Contributor = {
login: string;
avatarUrl?: string;
@@ -28,86 +23,26 @@ type GitHubContributor = {
};
type CommunityPath = {
+ icon: DocIconName;
title: ReactNode;
description: ReactNode;
href: string;
};
-const SPONSOR_SLOTS: SponsorSlot[] = [
- {
- brand: 'BackupX',
- name: ,
- href: 'https://github.com/sponsors/Awuqing',
- },
- {
- brand: 'Cloud',
- name: ,
- },
- {
- brand: 'Object',
- name: ,
- },
- {
- brand: 'CDN',
- name: ,
- },
- {
- brand: 'DB',
- name: ,
- },
- {
- brand: 'Security',
- name: ,
- },
- {
- brand: 'Agent',
- name: ,
- },
- {
- brand: 'Docs',
- name: ,
- },
- {
- brand: 'Release',
- name: ,
- },
- {
- brand: 'S3',
- name: ,
- },
- {
- brand: 'WebDAV',
- name: ,
- },
- {
- brand: 'SFTP',
- name: ,
- },
- {
- brand: 'Docker',
- name: ,
- },
- {
- brand: 'Mirror',
- name: ,
- },
- {
- brand: 'Restore',
- name: ,
- },
- {
- brand: 'QA',
- name: ,
- },
- {
- brand: 'OSS',
- name: ,
- },
- {
- brand: 'Open Slot',
- name: ,
- },
-];
+type SponsorFocus = {
+ id: string;
+ icon: DocIconName;
+ label: ReactNode;
+ title: ReactNode;
+ description: ReactNode;
+};
+
+type SponsorTier = {
+ id: string;
+ name: ReactNode;
+ audience: ReactNode;
+ description: ReactNode;
+};
const FALLBACK_CONTRIBUTORS: Contributor[] = [
{
@@ -126,30 +61,69 @@ const FALLBACK_CONTRIBUTORS: Contributor[] = [
const COMMUNITY_PATHS: CommunityPath[] = [
{
+ icon: 'wrench',
title: ,
- description: ,
+ description: ,
href: 'https://github.com/Awuqing/BackupX/issues',
},
{
+ icon: 'bookOpen',
title: ,
- description: ,
+ description: ,
href: '/docs/development/contributing',
},
{
- title: ,
- description: ,
+ icon: 'github',
+ title: ,
+ description: ,
href: 'https://github.com/Awuqing/BackupX/pulls',
},
];
-function SponsorLogoCard({brand, name, href}: SponsorSlot) {
- return (
-
- {brand}
- {name}
-
- );
-}
+const SPONSOR_FOCUS: SponsorFocus[] = [
+ {
+ id: 'infrastructure',
+ icon: 'cloud',
+ label: ,
+ title: ,
+ description: ,
+ },
+ {
+ id: 'reliability',
+ icon: 'shield',
+ label: ,
+ title: ,
+ description: ,
+ },
+ {
+ id: 'community',
+ icon: 'users',
+ label: ,
+ title: ,
+ description: ,
+ },
+];
+
+const SPONSOR_TIERS: SponsorTier[] = [
+ {
+ id: 'backer',
+ name: ,
+ audience: ,
+ description: ,
+ },
+ {
+ id: 'partner',
+ name: ,
+ audience: ,
+ description: ,
+ },
+ {
+ id: 'enterprise',
+ name: ,
+ audience: ,
+ description: ,
+ },
+];
function getInitials(login: string): string {
return login
@@ -180,11 +154,9 @@ function useGitHubContributors(): Contributor[] {
useEffect(() => {
const controller = new AbortController();
- fetch('https://api.github.com/repos/Awuqing/BackupX/contributors?per_page=12', {
+ fetch('https://api.github.com/repos/Awuqing/BackupX/contributors?per_page=8', {
signal: controller.signal,
- headers: {
- Accept: 'application/vnd.github+json',
- },
+ headers: {Accept: 'application/vnd.github+json'},
})
.then(response => {
if (!response.ok) {
@@ -213,28 +185,28 @@ function useGitHubContributors(): Contributor[] {
return contributors;
}
-function ContributorCard({login, avatarUrl, contributions, type, href}: Contributor) {
+function ContributorRow({login, avatarUrl, contributions, type, href}: Contributor): ReactNode {
return (
-
+
{avatarUrl ? (
) : (
{getInitials(login)}
)}
- {login}
-
+ {login}
+
{type === 'Bot' ? (
) : (
)}
-
-
-
+
+
+
);
@@ -242,22 +214,54 @@ function ContributorCard({login, avatarUrl, contributions, type, href}: Contribu
export function HomepageSponsors(): ReactNode {
return (
-
-
-
-
-
-
+
+
-
- {SPONSOR_SLOTS.map((slot, index) => (
-
+
+ {SPONSOR_FOCUS.map(focus => (
+
+
+
+ {focus.label}
+ {focus.title}
+ {focus.description}
+
+
))}
+
+
+
+
+ {SPONSOR_TIERS.map(tier => (
+
+ {tier.name}
+ {tier.audience}
+ {tier.description}
+
+ ))}
+
+
);
}
@@ -269,59 +273,74 @@ export default function HomepageCommunity(): ReactNode {