Skip to content

Commit

Permalink
docs: update docs (#192)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mister-Hope authored Mar 2, 2023
1 parent 896253a commit a4446be
Show file tree
Hide file tree
Showing 64 changed files with 622 additions and 559 deletions.
240 changes: 99 additions & 141 deletions CHANGELOG.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
- [x] 强大的 Markdown 编辑器,支持图表和数学公式,一键插入 more 标记,一键剪切板及本地图片上传,支持自定义高亮块语法,支持 Emoji 表情选取。
- [x] TOC、草稿、代码复制、访客数、评论数、分类、标签、搜索、加密、友链、打赏、自定义导航栏。
- [x] 多个布局设置,可自定义页面细节。
- [x] 高度客制化,可添加自定义 CSS、HTML 和 JS 代码。
- [x] 高度定制化,可添加自定义 CSS、HTML 和 JS 代码。
- [x] 支持自定义页面。
- [x] 可添加具有指定权限的协作者。
- [x] 内置图床,并支持各种 OSS 图床、github 图床(外部图床基于 picgo)等。
Expand Down
14 changes: 0 additions & 14 deletions docs/.vuepress/navbar.ts

This file was deleted.

31 changes: 0 additions & 31 deletions docs/.vuepress/sidebar.ts

This file was deleted.

24 changes: 18 additions & 6 deletions docs/.vuepress/theme.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import { getDirname, path } from "@vuepress/utils";
import { hopeTheme } from "vuepress-theme-hope";
import navbar from "./navbar.js";
import sidebar from "./sidebar.js";

const __dirname = getDirname(import.meta.url);

Expand All @@ -17,17 +15,31 @@ export default hopeTheme({
},

darkmode: "switch",
iconAssets: "iconfont",
iconAssets: "fontawesome-with-brands",

logo: "/logo.svg",

repo: "mereithhh/van-blog",

// navbar
navbar: navbar,
navbar: [
{ text: "介绍", icon: "circle-info", link: "/intro" },
{ text: "快速上手", icon: "lightbulb", link: "/guide/get-started" },
{ text: "功能", icon: "star", link: "/features/" },
{ text: "常见问题", icon: "circle-question", link: "/faq/" },
{
text: "Demo",
icon: "laptop-code",
link: "https://blog-demo.mereith.com",
},
{
text: "交流群",
icon: "fab fa-qq",
link: "https://jq.qq.com/?_wv=1027&k=5NRyK2Sw",
},
],

// sidebar
sidebar: sidebar,
sidebar: "structure",

footer: "GPL-3.0 协议",

Expand Down
12 changes: 7 additions & 5 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
---
index: false
home: true
icon: home
heroImage: /合并.png
Expand Down Expand Up @@ -26,16 +27,16 @@ features:
icon: contrast
details: 草稿、分类、标签、搜索、TOC、内嵌评论系统、图标和数学公式支持

- title: 客制化
icon: vscode
- title: 定制化
icon: wand-magic-sparkles
details: 可添加自定义 HTML、CSS、JS,后续将支持主题与插件

- title: 内置图床
icon: pic
icon: image
details: 本地图床,OSS 图床,Github 图床都支持,可一键上传剪切板图片,自动添加水印

- title: 高性能
icon: light
icon: bolt
details: 快到极致的静态页面,秒响应的增量渲染,Lighthouse 近满分

- title: SEO 友好
Expand All @@ -51,12 +52,13 @@ features:
details: 功能齐全的后台,精心优化的编辑器,极致的写作体验

- title: 安全第一
icon: token
icon: key
details: 内置了可以自定义权限的协作者模式,未来将支持更多登录安全策略

- title: 易于部署
icon: linux
details: Docker 一键部署,全自动 HTTPS 证书自动申请续期,支持 ARM

copyright: false
footer: GPL-3.0 协议 | Copyright © 2022-present Mereith
---
9 changes: 9 additions & 0 deletions docs/advanced/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
title: 高级
icon: gem
dir:
order: 4
index: false
---

<AutoCatalog />
1 change: 1 addition & 0 deletions docs/advanced/backup.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 导入导出
icon: right-to-bracket
redirectFrom: /feature/advance/backup.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/collaborator.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 协作者
icon: users
redirectFrom: /feature/advance/collaborator.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/custom-nav.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 自定义导航栏
icon: window-maximize
redirectFrom: /feature/advance/customNav.html
---

Expand Down
3 changes: 2 additions & 1 deletion docs/advanced/custom-page.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 自定义页面
icon: file
redirectFrom: /feature/advance/custom-page.html
---

Expand All @@ -13,7 +14,7 @@ VanBlog 支持自定义页面,但首先请您明确自己的需求。
- 设置文章为隐藏
- 在后台布局设置中开启 `通过 URL 访问隐藏文章`
- 在后台自定义导航栏中添加这篇文章
- 或者在客制化中,嵌入自己的代码把这篇文章的 URL 嵌入到合适的位置
- 或者在定制化中,嵌入自己的代码把这篇文章的 URL 嵌入到合适的位置

## 完整的自定义页面

Expand Down
13 changes: 7 additions & 6 deletions docs/advanced/customizing.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
---
title: 客制化(嵌入自定义 HTML、CSS、JS)
title: 定制化(嵌入自定义 HTML、CSS、JS)
icon: wand-magic-sparkles
redirectFrom: /feature/advance/customizing.html
---

VanBlog 客制化,也就是可以在页面嵌入自己的 HTML、CSS、JS 片段。
VanBlog 定制化,也就是可以在页面嵌入自己的 HTML、CSS、JS 片段。

具体在 `站点管理/系统设置/客制化` 选项卡:
具体在 `站点管理/系统设置/定制化` 选项卡:

![客制化](https://www.mereith.com/static/img/9489039722c6c97a5232fad790356d9c.clipboard-2022-09-02.png)
![定制化](https://www.mereith.com/static/img/9489039722c6c97a5232fad790356d9c.clipboard-2022-09-02.png)

默认客制化功能是开启的,你也可以在布局设置中关闭它。这样即便设置了客制化相关的代码,也不会生效。
默认定制化功能是开启的,你也可以在布局设置中关闭它。这样即便设置了定制化相关的代码,也不会生效。

PS: 我很自豪地用了 vscode 同款的代码编辑器,带有代码自动补全哦。

Expand Down Expand Up @@ -48,7 +49,7 @@ window.onload = () => {

可以实现很多好玩的功能,比如最近我发现了一个项目: [Sakana! Widget](https://github.com/dsrkafuu/sakana-widget)

就完全可以通过客制化来自己加个小挂件
就完全可以通过定制化来自己加个小挂件

![配置展示](https://www.mereith.com/static/img/d2964344217c8db07f80e3e9350495c3.clipboard-2022-09-02.png)

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/darkmode.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 黑暗模式与响应式
icon: circle-half-stroke
redirectFrom: /feature/advance/dark-mode.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/donate.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 捐赠管理
icon: circle-dollar-to-slot
redirectFrom: /feature/advance/donate.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/encrypt.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 加密文章
icon: lock
redirectFrom: /feature/advance/private.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/friend-link.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 友情链接
icon: heart
redirectFrom: /feature/advance/links.html
---

Expand Down
14 changes: 0 additions & 14 deletions docs/advanced/hidden.md

This file was deleted.

19 changes: 19 additions & 0 deletions docs/advanced/hide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
title: 隐藏文章
icon: eye-slash
redirectFrom: /feature/advance/hidden.html
---

VanBlog 支持对文章进行**隐藏**

隐藏一篇文章后,博客的任何位置都不会包含此文章的入口(如:文章列表、时间线),此文章的信息也不会计入任何统计 (如:总字数、标签、分类数量统计)。

在管理后台,可以搜索并查看此文章,并可以取消隐藏状态。

默认情况下,隐藏文章无法通过 URL 访问(会出现 404),但你可以手动在后台的 `站点管理/系统设置/站点配置/布局设置` 中开启 `隐藏文章通过 URL 访问`,这可以在某种程度上实现自定义页面的效果。

## 隐藏方法

- 在创建文章时勾选隐藏
- 在编辑器页面点击 `修改信息`,勾选隐藏
- 在发布草稿时勾选隐藏
2 changes: 1 addition & 1 deletion docs/advanced/https.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
icon: selection
title: HTTPS
icon: certificate
order: -3
redirectFrom:
- /guide/https.html
Expand Down
1 change: 1 addition & 0 deletions docs/advanced/isr.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 静态页面更新策略
icon: circle-up
redirectFrom: /feature/advance/isr.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/restore.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 忘记密码
icon: question
redirectFrom: /feature/advance/restore.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/rss.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: RSS
icon: rss
redirectFrom: /feature/advance/rss.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/secure.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 登录安全策略
icon: key
redirectFrom: /feature/advance/secure.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/seo.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 搜索引擎优化
icon: dumbbell
redirectFrom: /feature/advance/seo.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/social.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 联系方式配置
icon: phone
redirectFrom: /feature/advance/social.html
---

Expand Down
1 change: 1 addition & 0 deletions docs/advanced/sticky.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: 置顶
icon: circle-arrow-up
redirectFrom: /feature/advance/top.html
---

Expand Down
14 changes: 0 additions & 14 deletions docs/advanced/version.md

This file was deleted.

Loading

0 comments on commit a4446be

Please sign in to comment.