mirror of
https://github.com/halo-dev/docs.git
synced 2025-10-21 18:24:58 +00:00
docs: add documentation for author template variables (#176)
添加主题端作者归档页面的文档。后端改动可查阅:https://github.com/halo-dev/docs/issues/144 /kind documentation Fixes #143 ```release-note None ```
This commit is contained in:
@@ -3,7 +3,7 @@ title: 作者
|
|||||||
description: 作者 - ContributorFinder
|
description: 作者 - ContributorFinder
|
||||||
---
|
---
|
||||||
|
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
|
|
||||||
## getContributor(name)
|
## getContributor(name)
|
||||||
|
|
||||||
@@ -21,7 +21,7 @@ contributorFinder.getContributor(name)
|
|||||||
|
|
||||||
### 返回值
|
### 返回值
|
||||||
|
|
||||||
[#Contributor](#contributor)
|
[#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### 示例
|
### 示例
|
||||||
|
|
||||||
@@ -47,7 +47,7 @@ contributorFinder.getContributors(names)
|
|||||||
|
|
||||||
### 返回值
|
### 返回值
|
||||||
|
|
||||||
List<[#Contributor](#contributor)>
|
List<[#ContributorVo](#contributorvo)>
|
||||||
|
|
||||||
### 示例
|
### 示例
|
||||||
|
|
||||||
@@ -59,6 +59,6 @@ List<[#Contributor](#contributor)>
|
|||||||
|
|
||||||
## 类型定义
|
## 类型定义
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
@@ -7,7 +7,7 @@ import CategoryVo from "../vo/CategoryVo.md";
|
|||||||
import TagVo from "../vo/TagVo.md";
|
import TagVo from "../vo/TagVo.md";
|
||||||
import PostVo from "../vo/PostVo.md";
|
import PostVo from "../vo/PostVo.md";
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## getByName(postName)
|
## getByName(postName)
|
||||||
@@ -340,9 +340,9 @@ postFinder.archives(page, size, year, month);
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### PostVo
|
### PostVo
|
||||||
|
|
||||||
@@ -350,7 +350,7 @@ postFinder.archives(page, size, year, month);
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
|
|
||||||
### ContentVo
|
### ContentVo
|
||||||
@@ -375,7 +375,7 @@ postFinder.archives(page, size, year, month);
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### ListResult<ListedPostVo\>
|
### ListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -5,7 +5,7 @@ description: 独立页面 - SinglePageFinder
|
|||||||
|
|
||||||
import SinglePageVo from "../vo/SinglePageVo.md"
|
import SinglePageVo from "../vo/SinglePageVo.md"
|
||||||
import ListedSinglePageVo from "../vo/ListedSinglePageVo.md"
|
import ListedSinglePageVo from "../vo/ListedSinglePageVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
|
|
||||||
## getByName(pageName)
|
## getByName(pageName)
|
||||||
@@ -95,12 +95,12 @@ singlePageFinder.list(page,size)
|
|||||||
|
|
||||||
<SinglePageVo />
|
<SinglePageVo />
|
||||||
|
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
|
|
||||||
### ListedSinglePageVo
|
### ListedSinglePageVo
|
||||||
|
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
<ListedSinglePageVo />
|
<ListedSinglePageVo />
|
||||||
|
|
||||||
@@ -126,6 +126,6 @@ singlePageFinder.list(page,size)
|
|||||||
|
|
||||||
<ContentVo />
|
<ContentVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
@@ -5,7 +5,7 @@ description: archives.html - /archives
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md";
|
import CategoryVo from "../vo/CategoryVo.md";
|
||||||
import TagVo from "../vo/TagVo.md";
|
import TagVo from "../vo/TagVo.md";
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md";
|
import ListedPostVo from "../vo/ListedPostVo.md";
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -59,9 +59,9 @@ import ListedPostVo from "../vo/ListedPostVo.md";
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -69,7 +69,7 @@ import ListedPostVo from "../vo/ListedPostVo.md";
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### PostArchiveVo
|
### PostArchiveVo
|
||||||
|
|
||||||
|
104
docs/developer-guide/theme/template-variables/author.md
Normal file
104
docs/developer-guide/theme/template-variables/author.md
Normal file
@@ -0,0 +1,104 @@
|
|||||||
|
---
|
||||||
|
title: 作者归档
|
||||||
|
description: author.html - /authors/:name
|
||||||
|
---
|
||||||
|
|
||||||
|
import UserVo from "../vo/UserVo.md"
|
||||||
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
|
import TagVo from "../vo/TagVo.md"
|
||||||
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
|
## 路由信息
|
||||||
|
|
||||||
|
- 模板路径:`/templates/author.html`
|
||||||
|
- 访问路径:`/authors/:name`
|
||||||
|
|
||||||
|
## 变量
|
||||||
|
|
||||||
|
### author
|
||||||
|
|
||||||
|
#### 变量类型
|
||||||
|
|
||||||
|
[#UserVo](#uservo)
|
||||||
|
|
||||||
|
### posts
|
||||||
|
|
||||||
|
#### 变量类型
|
||||||
|
|
||||||
|
[#UrlContextListResult<ListedPostVo\>](#urlcontextlistresultlistedpostvo)
|
||||||
|
|
||||||
|
#### 示例
|
||||||
|
|
||||||
|
```html title="/templates/author.html"
|
||||||
|
<div>
|
||||||
|
<h1 th:text="${author.spec.displayName}"></h1>
|
||||||
|
<ul>
|
||||||
|
<li th:each="post : ${posts.items}">
|
||||||
|
<a
|
||||||
|
th:text="${post.spec.title}"
|
||||||
|
th:href="${post.status.permalink}"
|
||||||
|
></a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
<div th:if="${posts.hasPrevious() || posts.hasNext()}">
|
||||||
|
<a
|
||||||
|
th:href="@{${posts.prevUrl}}"
|
||||||
|
>
|
||||||
|
<span>上一页</span>
|
||||||
|
</a>
|
||||||
|
<span th:text="${posts.page} +' / '+ ${posts.total}"></span>
|
||||||
|
<a
|
||||||
|
th:href="@{${posts.nextUrl}}"
|
||||||
|
>
|
||||||
|
<span>下一页</span>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
```
|
||||||
|
|
||||||
|
## 类型定义
|
||||||
|
|
||||||
|
### UserVo
|
||||||
|
|
||||||
|
<UserVo />
|
||||||
|
|
||||||
|
### CategoryVo
|
||||||
|
|
||||||
|
<CategoryVo />
|
||||||
|
|
||||||
|
### TagVo
|
||||||
|
|
||||||
|
<TagVo />
|
||||||
|
|
||||||
|
### ContributorVo
|
||||||
|
|
||||||
|
<ContributorVo />
|
||||||
|
|
||||||
|
### ListedPostVo
|
||||||
|
|
||||||
|
<ListedPostVo />
|
||||||
|
|
||||||
|
- [#CategoryVo](#categoryvo)
|
||||||
|
- [#TagVo](#tagvo)
|
||||||
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
```json title="UrlContextListResult<ListedPostVo>"
|
||||||
|
{
|
||||||
|
"page": 0, // 当前页码
|
||||||
|
"size": 0, // 每页条数
|
||||||
|
"total": 0, // 总条数
|
||||||
|
"items": "List<#ListedPostVo>", // 文章列表数据
|
||||||
|
"first": true, // 是否为第一页
|
||||||
|
"last": true, // 是否为最后一页
|
||||||
|
"hasNext": true, // 是否有下一页
|
||||||
|
"hasPrevious": true, // 是否有上一页
|
||||||
|
"totalPages": 0, // 总页数
|
||||||
|
"nextUrl": "string", // 下一页链接
|
||||||
|
"prevUrl": "string" // 上一页链接
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
- [#ListedPostVo](#listedpostvo)
|
@@ -5,7 +5,7 @@ description: category.html - /categories/:slug
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -72,9 +72,9 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -82,7 +82,7 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### UrlContextListResult<ListedPostVo\>
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -5,7 +5,7 @@ description: index.html - /
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -65,9 +65,9 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -75,7 +75,7 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### UrlContextListResult<ListedPostVo\>
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -4,7 +4,7 @@ description: page.html - /:slug
|
|||||||
---
|
---
|
||||||
|
|
||||||
import SinglePageVo from "../vo/SinglePageVo.md"
|
import SinglePageVo from "../vo/SinglePageVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -42,12 +42,12 @@ import ContentVo from "../vo/ContentVo.md"
|
|||||||
<SinglePageVo />
|
<SinglePageVo />
|
||||||
|
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### ContentVo
|
### ContentVo
|
||||||
|
|
||||||
<ContentVo />
|
<ContentVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
@@ -6,7 +6,7 @@ description: post.html - /archives/:slug
|
|||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import PostVo from "../vo/PostVo.md"
|
import PostVo from "../vo/PostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -47,9 +47,9 @@ import PostVo from "../vo/PostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ContentVo
|
### ContentVo
|
||||||
|
|
||||||
@@ -61,5 +61,5 @@ import PostVo from "../vo/PostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
|
@@ -5,7 +5,7 @@ description: tag.html - /tags/:slug
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -72,9 +72,9 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -82,7 +82,7 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### UrlContextListResult<ListedPostVo\>
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -1,8 +1,9 @@
|
|||||||
```json title="Contributor"
|
```json title="ContributorVo"
|
||||||
{
|
{
|
||||||
"name": "string", // 用户名
|
"name": "string", // 用户名
|
||||||
"displayName": "string", // 显示名称
|
"displayName": "string", // 显示名称
|
||||||
"avatar": "string", // 头像
|
"avatar": "string", // 头像
|
||||||
"bio": "string" // 描述
|
"bio": "string", // 描述
|
||||||
|
"permalink": "string" // 作者的文章归档页面链接
|
||||||
}
|
}
|
||||||
```
|
```
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -54,8 +54,8 @@
|
|||||||
},
|
},
|
||||||
"categories": "List<#CategoryVo>", // 分类的集合
|
"categories": "List<#CategoryVo>", // 分类的集合
|
||||||
"tags": "List<#TagVo>", // 标签的集合
|
"tags": "List<#TagVo>", // 标签的集合
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor", // 创建者
|
"owner": "#ContributorVo", // 创建者
|
||||||
"stats": {
|
"stats": {
|
||||||
"visit": 0, // 访问数量
|
"visit": 0, // 访问数量
|
||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -51,7 +51,7 @@
|
|||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
"comment": 0 // 评论数量
|
"comment": 0 // 评论数量
|
||||||
},
|
},
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor" // 创建者
|
"owner": "#ContributorVo" // 创建者
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -54,8 +54,8 @@
|
|||||||
},
|
},
|
||||||
"categories": "List<#CategoryVo>", // 分类的集合
|
"categories": "List<#CategoryVo>", // 分类的集合
|
||||||
"tags": "List<#TagVo>", // 标签的集合
|
"tags": "List<#TagVo>", // 标签的集合
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor", // 创建者
|
"owner": "#ContributorVo", // 创建者
|
||||||
"stats": {
|
"stats": {
|
||||||
"visit": 0, // 访问数量
|
"visit": 0, // 访问数量
|
||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -51,8 +51,8 @@
|
|||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
"comment": 0 // 评论数量
|
"comment": 0 // 评论数量
|
||||||
},
|
},
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor", // 创建者
|
"owner": "#ContributorVo", // 创建者
|
||||||
"content": "#ContentVo" // 内容
|
"content": "#ContentVo" // 内容
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
28
docs/developer-guide/theme/vo/UserVo.md
Normal file
28
docs/developer-guide/theme/vo/UserVo.md
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
```json title="UserVo"
|
||||||
|
{
|
||||||
|
"metadata": {
|
||||||
|
"name": "string", // 唯一标识
|
||||||
|
"labels": {
|
||||||
|
"additionalProp1": "string"
|
||||||
|
},
|
||||||
|
"annotations": {
|
||||||
|
"additionalProp1": "string"
|
||||||
|
},
|
||||||
|
"creationTimestamp": "2022-11-20T13:06:38.512Z" // 创建时间
|
||||||
|
},
|
||||||
|
"spec": {
|
||||||
|
"displayName": "string", // 显示名称
|
||||||
|
"avatar": "string", // 头像链接
|
||||||
|
"email": "string", // 邮箱地址
|
||||||
|
"phone": "string", // 电话号码
|
||||||
|
"bio": 0, // 描述
|
||||||
|
"registeredAt": "2022-11-20T13:06:38.512Z", // 注册时间
|
||||||
|
"twoFactorAuthEnabled": false, // 是否启用二次验证
|
||||||
|
"disabled": false // 是否禁用
|
||||||
|
},
|
||||||
|
"status": {
|
||||||
|
"lastLoginAt": "2022-11-20T13:06:38.512Z", // 最后登录时间
|
||||||
|
"permalink": "string" // 作者的文章归档页面链接
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
@@ -128,6 +128,7 @@ module.exports = {
|
|||||||
"developer-guide/theme/template-variables/tag",
|
"developer-guide/theme/template-variables/tag",
|
||||||
"developer-guide/theme/template-variables/categories",
|
"developer-guide/theme/template-variables/categories",
|
||||||
"developer-guide/theme/template-variables/category",
|
"developer-guide/theme/template-variables/category",
|
||||||
|
"developer-guide/theme/template-variables/author",
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@@ -3,7 +3,7 @@ title: 作者
|
|||||||
description: 作者 - ContributorFinder
|
description: 作者 - ContributorFinder
|
||||||
---
|
---
|
||||||
|
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
|
|
||||||
## getContributor(name)
|
## getContributor(name)
|
||||||
|
|
||||||
@@ -21,7 +21,7 @@ contributorFinder.getContributor(name)
|
|||||||
|
|
||||||
### 返回值
|
### 返回值
|
||||||
|
|
||||||
[#Contributor](#contributor)
|
[#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### 示例
|
### 示例
|
||||||
|
|
||||||
@@ -47,7 +47,7 @@ contributorFinder.getContributors(names)
|
|||||||
|
|
||||||
### 返回值
|
### 返回值
|
||||||
|
|
||||||
List<[#Contributor](#contributor)>
|
List<[#ContributorVo](#contributorvo)>
|
||||||
|
|
||||||
### 示例
|
### 示例
|
||||||
|
|
||||||
@@ -59,6 +59,6 @@ List<[#Contributor](#contributor)>
|
|||||||
|
|
||||||
## 类型定义
|
## 类型定义
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
@@ -7,7 +7,7 @@ import CategoryVo from "../vo/CategoryVo.md";
|
|||||||
import TagVo from "../vo/TagVo.md";
|
import TagVo from "../vo/TagVo.md";
|
||||||
import PostVo from "../vo/PostVo.md";
|
import PostVo from "../vo/PostVo.md";
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## getByName(postName)
|
## getByName(postName)
|
||||||
@@ -340,9 +340,9 @@ postFinder.archives(page, size, year, month);
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### PostVo
|
### PostVo
|
||||||
|
|
||||||
@@ -350,7 +350,7 @@ postFinder.archives(page, size, year, month);
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
|
|
||||||
### ContentVo
|
### ContentVo
|
||||||
@@ -375,7 +375,7 @@ postFinder.archives(page, size, year, month);
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### ListResult<ListedPostVo\>
|
### ListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -5,7 +5,7 @@ description: 独立页面 - SinglePageFinder
|
|||||||
|
|
||||||
import SinglePageVo from "../vo/SinglePageVo.md"
|
import SinglePageVo from "../vo/SinglePageVo.md"
|
||||||
import ListedSinglePageVo from "../vo/ListedSinglePageVo.md"
|
import ListedSinglePageVo from "../vo/ListedSinglePageVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
|
|
||||||
## getByName(pageName)
|
## getByName(pageName)
|
||||||
@@ -95,12 +95,12 @@ singlePageFinder.list(page,size)
|
|||||||
|
|
||||||
<SinglePageVo />
|
<SinglePageVo />
|
||||||
|
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
|
|
||||||
### ListedSinglePageVo
|
### ListedSinglePageVo
|
||||||
|
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
<ListedSinglePageVo />
|
<ListedSinglePageVo />
|
||||||
|
|
||||||
@@ -126,6 +126,6 @@ singlePageFinder.list(page,size)
|
|||||||
|
|
||||||
<ContentVo />
|
<ContentVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
@@ -5,7 +5,7 @@ description: archives.html - /archives
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md";
|
import CategoryVo from "../vo/CategoryVo.md";
|
||||||
import TagVo from "../vo/TagVo.md";
|
import TagVo from "../vo/TagVo.md";
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md";
|
import ListedPostVo from "../vo/ListedPostVo.md";
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -59,9 +59,9 @@ import ListedPostVo from "../vo/ListedPostVo.md";
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -69,7 +69,7 @@ import ListedPostVo from "../vo/ListedPostVo.md";
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### PostArchiveVo
|
### PostArchiveVo
|
||||||
|
|
||||||
|
@@ -0,0 +1,104 @@
|
|||||||
|
---
|
||||||
|
title: 作者归档
|
||||||
|
description: author.html - /authors/:name
|
||||||
|
---
|
||||||
|
|
||||||
|
import UserVo from "../vo/UserVo.md"
|
||||||
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
|
import TagVo from "../vo/TagVo.md"
|
||||||
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
|
## 路由信息
|
||||||
|
|
||||||
|
- 模板路径:`/templates/author.html`
|
||||||
|
- 访问路径:`/authors/:name`
|
||||||
|
|
||||||
|
## 变量
|
||||||
|
|
||||||
|
### author
|
||||||
|
|
||||||
|
#### 变量类型
|
||||||
|
|
||||||
|
[#UserVo](#uservo)
|
||||||
|
|
||||||
|
### posts
|
||||||
|
|
||||||
|
#### 变量类型
|
||||||
|
|
||||||
|
[#UrlContextListResult<ListedPostVo\>](#urlcontextlistresultlistedpostvo)
|
||||||
|
|
||||||
|
#### 示例
|
||||||
|
|
||||||
|
```html title="/templates/author.html"
|
||||||
|
<div>
|
||||||
|
<h1 th:text="${author.spec.displayName}"></h1>
|
||||||
|
<ul>
|
||||||
|
<li th:each="post : ${posts.items}">
|
||||||
|
<a
|
||||||
|
th:text="${post.spec.title}"
|
||||||
|
th:href="${post.status.permalink}"
|
||||||
|
></a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
<div th:if="${posts.hasPrevious() || posts.hasNext()}">
|
||||||
|
<a
|
||||||
|
th:href="@{${posts.prevUrl}}"
|
||||||
|
>
|
||||||
|
<span>上一页</span>
|
||||||
|
</a>
|
||||||
|
<span th:text="${posts.page} +' / '+ ${posts.total}"></span>
|
||||||
|
<a
|
||||||
|
th:href="@{${posts.nextUrl}}"
|
||||||
|
>
|
||||||
|
<span>下一页</span>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
```
|
||||||
|
|
||||||
|
## 类型定义
|
||||||
|
|
||||||
|
### UserVo
|
||||||
|
|
||||||
|
<UserVo />
|
||||||
|
|
||||||
|
### CategoryVo
|
||||||
|
|
||||||
|
<CategoryVo />
|
||||||
|
|
||||||
|
### TagVo
|
||||||
|
|
||||||
|
<TagVo />
|
||||||
|
|
||||||
|
### ContributorVo
|
||||||
|
|
||||||
|
<ContributorVo />
|
||||||
|
|
||||||
|
### ListedPostVo
|
||||||
|
|
||||||
|
<ListedPostVo />
|
||||||
|
|
||||||
|
- [#CategoryVo](#categoryvo)
|
||||||
|
- [#TagVo](#tagvo)
|
||||||
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
```json title="UrlContextListResult<ListedPostVo>"
|
||||||
|
{
|
||||||
|
"page": 0, // 当前页码
|
||||||
|
"size": 0, // 每页条数
|
||||||
|
"total": 0, // 总条数
|
||||||
|
"items": "List<#ListedPostVo>", // 文章列表数据
|
||||||
|
"first": true, // 是否为第一页
|
||||||
|
"last": true, // 是否为最后一页
|
||||||
|
"hasNext": true, // 是否有下一页
|
||||||
|
"hasPrevious": true, // 是否有上一页
|
||||||
|
"totalPages": 0, // 总页数
|
||||||
|
"nextUrl": "string", // 下一页链接
|
||||||
|
"prevUrl": "string" // 上一页链接
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
- [#ListedPostVo](#listedpostvo)
|
@@ -5,7 +5,7 @@ description: category.html - /categories/:slug
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -72,9 +72,9 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -82,7 +82,7 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### UrlContextListResult<ListedPostVo\>
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -5,7 +5,7 @@ description: index.html - /
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -65,9 +65,9 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -75,7 +75,7 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### UrlContextListResult<ListedPostVo\>
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -4,7 +4,7 @@ description: page.html - /:slug
|
|||||||
---
|
---
|
||||||
|
|
||||||
import SinglePageVo from "../vo/SinglePageVo.md"
|
import SinglePageVo from "../vo/SinglePageVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -42,12 +42,12 @@ import ContentVo from "../vo/ContentVo.md"
|
|||||||
<SinglePageVo />
|
<SinglePageVo />
|
||||||
|
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### ContentVo
|
### ContentVo
|
||||||
|
|
||||||
<ContentVo />
|
<ContentVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
@@ -6,7 +6,7 @@ description: post.html - /archives/:slug
|
|||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import PostVo from "../vo/PostVo.md"
|
import PostVo from "../vo/PostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -47,9 +47,9 @@ import PostVo from "../vo/PostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ContentVo
|
### ContentVo
|
||||||
|
|
||||||
@@ -61,5 +61,5 @@ import PostVo from "../vo/PostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
|
@@ -5,7 +5,7 @@ description: tag.html - /tags/:slug
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -72,9 +72,9 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -82,7 +82,7 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### UrlContextListResult<ListedPostVo\>
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -1,8 +1,9 @@
|
|||||||
```json title="Contributor"
|
```json title="ContributorVo"
|
||||||
{
|
{
|
||||||
"name": "string", // 用户名
|
"name": "string", // 用户名
|
||||||
"displayName": "string", // 显示名称
|
"displayName": "string", // 显示名称
|
||||||
"avatar": "string", // 头像
|
"avatar": "string", // 头像
|
||||||
"bio": "string" // 描述
|
"bio": "string", // 描述
|
||||||
|
"permalink": "string" // 作者的文章归档页面链接
|
||||||
}
|
}
|
||||||
```
|
```
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -47,14 +47,14 @@
|
|||||||
"excerpt": "string", // 最终生成的摘要
|
"excerpt": "string", // 最终生成的摘要
|
||||||
"inProgress": true,
|
"inProgress": true,
|
||||||
"commentsCount": 0, // 评论数
|
"commentsCount": 0, // 评论数
|
||||||
"contributors": [ // 贡献者名称,Contributor 的 metadata.name 的集合
|
"contributors": [ // 贡献者名称,ContributorVo 的 metadata.name 的集合
|
||||||
"string"
|
"string"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"categories": "List<#CategoryVo>", // 分类的集合
|
"categories": "List<#CategoryVo>", // 分类的集合
|
||||||
"tags": "List<#TagVo>", // 标签的集合
|
"tags": "List<#TagVo>", // 标签的集合
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor", // 创建者
|
"owner": "#ContributorVo", // 创建者
|
||||||
"stats": {
|
"stats": {
|
||||||
"visit": 0, // 访问数量
|
"visit": 0, // 访问数量
|
||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -41,7 +41,7 @@
|
|||||||
"excerpt": "string", // 最终生成的摘要
|
"excerpt": "string", // 最终生成的摘要
|
||||||
"inProgress": true,
|
"inProgress": true,
|
||||||
"commentsCount": 0, // 评论数
|
"commentsCount": 0, // 评论数
|
||||||
"contributors": [ // 贡献者名称,Contributor 的 metadata.name 的集合
|
"contributors": [ // 贡献者名称,ContributorVo 的 metadata.name 的集合
|
||||||
"string"
|
"string"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@@ -50,7 +50,7 @@
|
|||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
"comment": 0 // 评论数量
|
"comment": 0 // 评论数量
|
||||||
},
|
},
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor" // 创建者
|
"owner": "#ContributorVo" // 创建者
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -47,14 +47,14 @@
|
|||||||
"excerpt": "string", // 最终生成的摘要
|
"excerpt": "string", // 最终生成的摘要
|
||||||
"inProgress": true,
|
"inProgress": true,
|
||||||
"commentsCount": 0, // 评论数
|
"commentsCount": 0, // 评论数
|
||||||
"contributors": [ // 贡献者名称,Contributor 的 metadata.name 的集合
|
"contributors": [ // 贡献者名称,ContributorVo 的 metadata.name 的集合
|
||||||
"string"
|
"string"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"categories": "List<#CategoryVo>", // 分类的集合
|
"categories": "List<#CategoryVo>", // 分类的集合
|
||||||
"tags": "List<#TagVo>", // 标签的集合
|
"tags": "List<#TagVo>", // 标签的集合
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor", // 创建者
|
"owner": "#ContributorVo", // 创建者
|
||||||
"stats": {
|
"stats": {
|
||||||
"visit": 0, // 访问数量
|
"visit": 0, // 访问数量
|
||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -41,7 +41,7 @@
|
|||||||
"excerpt": "string", // 最终生成的摘要
|
"excerpt": "string", // 最终生成的摘要
|
||||||
"inProgress": true,
|
"inProgress": true,
|
||||||
"commentsCount": 0, // 评论数
|
"commentsCount": 0, // 评论数
|
||||||
"contributors": [ // 贡献者名称,Contributor 的 metadata.name 的集合
|
"contributors": [ // 贡献者名称,ContributorVo 的 metadata.name 的集合
|
||||||
"string"
|
"string"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@@ -50,8 +50,8 @@
|
|||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
"comment": 0 // 评论数量
|
"comment": 0 // 评论数量
|
||||||
},
|
},
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor", // 创建者
|
"owner": "#ContributorVo", // 创建者
|
||||||
"content": "#ContentVo" // 内容
|
"content": "#ContentVo" // 内容
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
@@ -0,0 +1,28 @@
|
|||||||
|
```json title="UserVo"
|
||||||
|
{
|
||||||
|
"metadata": {
|
||||||
|
"name": "string", // 唯一标识
|
||||||
|
"labels": {
|
||||||
|
"additionalProp1": "string"
|
||||||
|
},
|
||||||
|
"annotations": {
|
||||||
|
"additionalProp1": "string"
|
||||||
|
},
|
||||||
|
"creationTimestamp": "2022-11-20T13:06:38.512Z" // 创建时间
|
||||||
|
},
|
||||||
|
"spec": {
|
||||||
|
"displayName": "string", // 显示名称
|
||||||
|
"avatar": "string", // 头像链接
|
||||||
|
"email": "string", // 邮箱地址
|
||||||
|
"phone": "string", // 电话号码
|
||||||
|
"bio": 0, // 描述
|
||||||
|
"registeredAt": "2022-11-20T13:06:38.512Z", // 注册时间
|
||||||
|
"twoFactorAuthEnabled": false, // 是否启用二次验证
|
||||||
|
"disabled": false // 是否禁用
|
||||||
|
},
|
||||||
|
"status": {
|
||||||
|
"lastLoginAt": "2022-11-20T13:06:38.512Z", // 最后登录时间
|
||||||
|
"permalink": "string" // 作者的文章归档页面链接
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
@@ -3,7 +3,7 @@ title: 作者
|
|||||||
description: 作者 - ContributorFinder
|
description: 作者 - ContributorFinder
|
||||||
---
|
---
|
||||||
|
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
|
|
||||||
## getContributor(name)
|
## getContributor(name)
|
||||||
|
|
||||||
@@ -21,7 +21,7 @@ contributorFinder.getContributor(name)
|
|||||||
|
|
||||||
### 返回值
|
### 返回值
|
||||||
|
|
||||||
[#Contributor](#contributor)
|
[#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### 示例
|
### 示例
|
||||||
|
|
||||||
@@ -47,7 +47,7 @@ contributorFinder.getContributors(names)
|
|||||||
|
|
||||||
### 返回值
|
### 返回值
|
||||||
|
|
||||||
List<[#Contributor](#contributor)>
|
List<[#ContributorVo](#contributorvo)>
|
||||||
|
|
||||||
### 示例
|
### 示例
|
||||||
|
|
||||||
@@ -59,6 +59,6 @@ List<[#Contributor](#contributor)>
|
|||||||
|
|
||||||
## 类型定义
|
## 类型定义
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
@@ -7,7 +7,7 @@ import CategoryVo from "../vo/CategoryVo.md";
|
|||||||
import TagVo from "../vo/TagVo.md";
|
import TagVo from "../vo/TagVo.md";
|
||||||
import PostVo from "../vo/PostVo.md";
|
import PostVo from "../vo/PostVo.md";
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## getByName(postName)
|
## getByName(postName)
|
||||||
@@ -340,9 +340,9 @@ postFinder.archives(page, size, year, month);
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### PostVo
|
### PostVo
|
||||||
|
|
||||||
@@ -350,7 +350,7 @@ postFinder.archives(page, size, year, month);
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
|
|
||||||
### ContentVo
|
### ContentVo
|
||||||
@@ -375,7 +375,7 @@ postFinder.archives(page, size, year, month);
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### ListResult<ListedPostVo\>
|
### ListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -5,7 +5,7 @@ description: 独立页面 - SinglePageFinder
|
|||||||
|
|
||||||
import SinglePageVo from "../vo/SinglePageVo.md"
|
import SinglePageVo from "../vo/SinglePageVo.md"
|
||||||
import ListedSinglePageVo from "../vo/ListedSinglePageVo.md"
|
import ListedSinglePageVo from "../vo/ListedSinglePageVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
|
|
||||||
## getByName(pageName)
|
## getByName(pageName)
|
||||||
@@ -95,12 +95,12 @@ singlePageFinder.list(page,size)
|
|||||||
|
|
||||||
<SinglePageVo />
|
<SinglePageVo />
|
||||||
|
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
|
|
||||||
### ListedSinglePageVo
|
### ListedSinglePageVo
|
||||||
|
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
<ListedSinglePageVo />
|
<ListedSinglePageVo />
|
||||||
|
|
||||||
@@ -126,6 +126,6 @@ singlePageFinder.list(page,size)
|
|||||||
|
|
||||||
<ContentVo />
|
<ContentVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
@@ -5,7 +5,7 @@ description: archives.html - /archives
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md";
|
import CategoryVo from "../vo/CategoryVo.md";
|
||||||
import TagVo from "../vo/TagVo.md";
|
import TagVo from "../vo/TagVo.md";
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md";
|
import ListedPostVo from "../vo/ListedPostVo.md";
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -59,9 +59,9 @@ import ListedPostVo from "../vo/ListedPostVo.md";
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -69,7 +69,7 @@ import ListedPostVo from "../vo/ListedPostVo.md";
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### PostArchiveVo
|
### PostArchiveVo
|
||||||
|
|
||||||
|
@@ -0,0 +1,104 @@
|
|||||||
|
---
|
||||||
|
title: 作者归档
|
||||||
|
description: author.html - /authors/:name
|
||||||
|
---
|
||||||
|
|
||||||
|
import UserVo from "../vo/UserVo.md"
|
||||||
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
|
import TagVo from "../vo/TagVo.md"
|
||||||
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
|
## 路由信息
|
||||||
|
|
||||||
|
- 模板路径:`/templates/author.html`
|
||||||
|
- 访问路径:`/authors/:name`
|
||||||
|
|
||||||
|
## 变量
|
||||||
|
|
||||||
|
### author
|
||||||
|
|
||||||
|
#### 变量类型
|
||||||
|
|
||||||
|
[#UserVo](#uservo)
|
||||||
|
|
||||||
|
### posts
|
||||||
|
|
||||||
|
#### 变量类型
|
||||||
|
|
||||||
|
[#UrlContextListResult<ListedPostVo\>](#urlcontextlistresultlistedpostvo)
|
||||||
|
|
||||||
|
#### 示例
|
||||||
|
|
||||||
|
```html title="/templates/author.html"
|
||||||
|
<div>
|
||||||
|
<h1 th:text="${author.spec.displayName}"></h1>
|
||||||
|
<ul>
|
||||||
|
<li th:each="post : ${posts.items}">
|
||||||
|
<a
|
||||||
|
th:text="${post.spec.title}"
|
||||||
|
th:href="${post.status.permalink}"
|
||||||
|
></a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
<div th:if="${posts.hasPrevious() || posts.hasNext()}">
|
||||||
|
<a
|
||||||
|
th:href="@{${posts.prevUrl}}"
|
||||||
|
>
|
||||||
|
<span>上一页</span>
|
||||||
|
</a>
|
||||||
|
<span th:text="${posts.page} +' / '+ ${posts.total}"></span>
|
||||||
|
<a
|
||||||
|
th:href="@{${posts.nextUrl}}"
|
||||||
|
>
|
||||||
|
<span>下一页</span>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
```
|
||||||
|
|
||||||
|
## 类型定义
|
||||||
|
|
||||||
|
### UserVo
|
||||||
|
|
||||||
|
<UserVo />
|
||||||
|
|
||||||
|
### CategoryVo
|
||||||
|
|
||||||
|
<CategoryVo />
|
||||||
|
|
||||||
|
### TagVo
|
||||||
|
|
||||||
|
<TagVo />
|
||||||
|
|
||||||
|
### ContributorVo
|
||||||
|
|
||||||
|
<ContributorVo />
|
||||||
|
|
||||||
|
### ListedPostVo
|
||||||
|
|
||||||
|
<ListedPostVo />
|
||||||
|
|
||||||
|
- [#CategoryVo](#categoryvo)
|
||||||
|
- [#TagVo](#tagvo)
|
||||||
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
```json title="UrlContextListResult<ListedPostVo>"
|
||||||
|
{
|
||||||
|
"page": 0, // 当前页码
|
||||||
|
"size": 0, // 每页条数
|
||||||
|
"total": 0, // 总条数
|
||||||
|
"items": "List<#ListedPostVo>", // 文章列表数据
|
||||||
|
"first": true, // 是否为第一页
|
||||||
|
"last": true, // 是否为最后一页
|
||||||
|
"hasNext": true, // 是否有下一页
|
||||||
|
"hasPrevious": true, // 是否有上一页
|
||||||
|
"totalPages": 0, // 总页数
|
||||||
|
"nextUrl": "string", // 下一页链接
|
||||||
|
"prevUrl": "string" // 上一页链接
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
- [#ListedPostVo](#listedpostvo)
|
@@ -5,7 +5,7 @@ description: category.html - /categories/:slug
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -72,9 +72,9 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -82,7 +82,7 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### UrlContextListResult<ListedPostVo\>
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -5,7 +5,7 @@ description: index.html - /
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -65,9 +65,9 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -75,7 +75,7 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### UrlContextListResult<ListedPostVo\>
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -4,7 +4,7 @@ description: page.html - /:slug
|
|||||||
---
|
---
|
||||||
|
|
||||||
import SinglePageVo from "../vo/SinglePageVo.md"
|
import SinglePageVo from "../vo/SinglePageVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -42,12 +42,12 @@ import ContentVo from "../vo/ContentVo.md"
|
|||||||
<SinglePageVo />
|
<SinglePageVo />
|
||||||
|
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### ContentVo
|
### ContentVo
|
||||||
|
|
||||||
<ContentVo />
|
<ContentVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
@@ -6,7 +6,7 @@ description: post.html - /archives/:slug
|
|||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import ContentVo from "../vo/ContentVo.md"
|
import ContentVo from "../vo/ContentVo.md"
|
||||||
import Contributor from "../vo/Contributor.md"
|
import ContributorVo from "../vo/ContributorVo.md"
|
||||||
import PostVo from "../vo/PostVo.md"
|
import PostVo from "../vo/PostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -47,9 +47,9 @@ import PostVo from "../vo/PostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ContentVo
|
### ContentVo
|
||||||
|
|
||||||
@@ -61,5 +61,5 @@ import PostVo from "../vo/PostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
- [#ContentVo](#contentvo)
|
- [#ContentVo](#contentvo)
|
||||||
|
@@ -5,7 +5,7 @@ description: tag.html - /tags/:slug
|
|||||||
|
|
||||||
import CategoryVo from "../vo/CategoryVo.md"
|
import CategoryVo from "../vo/CategoryVo.md"
|
||||||
import TagVo from "../vo/TagVo.md"
|
import TagVo from "../vo/TagVo.md"
|
||||||
import Contributor from "../vo/Contributor.md";
|
import ContributorVo from "../vo/ContributorVo.md";
|
||||||
import ListedPostVo from "../vo/ListedPostVo.md"
|
import ListedPostVo from "../vo/ListedPostVo.md"
|
||||||
|
|
||||||
## 路由信息
|
## 路由信息
|
||||||
@@ -72,9 +72,9 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
<TagVo />
|
<TagVo />
|
||||||
|
|
||||||
### Contributor
|
### ContributorVo
|
||||||
|
|
||||||
<Contributor />
|
<ContributorVo />
|
||||||
|
|
||||||
### ListedPostVo
|
### ListedPostVo
|
||||||
|
|
||||||
@@ -82,7 +82,7 @@ import ListedPostVo from "../vo/ListedPostVo.md"
|
|||||||
|
|
||||||
- [#CategoryVo](#categoryvo)
|
- [#CategoryVo](#categoryvo)
|
||||||
- [#TagVo](#tagvo)
|
- [#TagVo](#tagvo)
|
||||||
- [#Contributor](#contributor)
|
- [#ContributorVo](#contributorvo)
|
||||||
|
|
||||||
### UrlContextListResult<ListedPostVo\>
|
### UrlContextListResult<ListedPostVo\>
|
||||||
|
|
||||||
|
@@ -1,8 +1,9 @@
|
|||||||
```json title="Contributor"
|
```json title="ContributorVo"
|
||||||
{
|
{
|
||||||
"name": "string", // 用户名
|
"name": "string", // 用户名
|
||||||
"displayName": "string", // 显示名称
|
"displayName": "string", // 显示名称
|
||||||
"avatar": "string", // 头像
|
"avatar": "string", // 头像
|
||||||
"bio": "string" // 描述
|
"bio": "string", // 描述
|
||||||
|
"permalink": "string" // 作者的文章归档页面链接
|
||||||
}
|
}
|
||||||
```
|
```
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -54,8 +54,8 @@
|
|||||||
},
|
},
|
||||||
"categories": "List<#CategoryVo>", // 分类的集合
|
"categories": "List<#CategoryVo>", // 分类的集合
|
||||||
"tags": "List<#TagVo>", // 标签的集合
|
"tags": "List<#TagVo>", // 标签的集合
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor", // 创建者
|
"owner": "#ContributorVo", // 创建者
|
||||||
"stats": {
|
"stats": {
|
||||||
"visit": 0, // 访问数量
|
"visit": 0, // 访问数量
|
||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -51,7 +51,7 @@
|
|||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
"comment": 0 // 评论数量
|
"comment": 0 // 评论数量
|
||||||
},
|
},
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor" // 创建者
|
"owner": "#ContributorVo" // 创建者
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -54,8 +54,8 @@
|
|||||||
},
|
},
|
||||||
"categories": "List<#CategoryVo>", // 分类的集合
|
"categories": "List<#CategoryVo>", // 分类的集合
|
||||||
"tags": "List<#TagVo>", // 标签的集合
|
"tags": "List<#TagVo>", // 标签的集合
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor", // 创建者
|
"owner": "#ContributorVo", // 创建者
|
||||||
"stats": {
|
"stats": {
|
||||||
"visit": 0, // 访问数量
|
"visit": 0, // 访问数量
|
||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
"releaseSnapshot": "string",
|
"releaseSnapshot": "string",
|
||||||
"headSnapshot": "string",
|
"headSnapshot": "string",
|
||||||
"baseSnapshot": "string",
|
"baseSnapshot": "string",
|
||||||
"owner": "string", // 创建者名称,即 Contributor 的 metadata.name,非显示名称
|
"owner": "string", // 创建者名称,即 ContributorVo 的 metadata.name,非显示名称
|
||||||
"template": "string", // 自定义渲染模板
|
"template": "string", // 自定义渲染模板
|
||||||
"cover": "string", // 封面图
|
"cover": "string", // 封面图
|
||||||
"deleted": false,
|
"deleted": false,
|
||||||
@@ -51,8 +51,8 @@
|
|||||||
"upvote": 0, // 点赞数量
|
"upvote": 0, // 点赞数量
|
||||||
"comment": 0 // 评论数量
|
"comment": 0 // 评论数量
|
||||||
},
|
},
|
||||||
"contributors": "List<#Contributor>", // 贡献者的集合
|
"contributors": "List<#ContributorVo>", // 贡献者的集合
|
||||||
"owner": "#Contributor", // 创建者
|
"owner": "#ContributorVo", // 创建者
|
||||||
"content": "#ContentVo" // 内容
|
"content": "#ContentVo" // 内容
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
@@ -0,0 +1,28 @@
|
|||||||
|
```json title="UserVo"
|
||||||
|
{
|
||||||
|
"metadata": {
|
||||||
|
"name": "string", // 唯一标识
|
||||||
|
"labels": {
|
||||||
|
"additionalProp1": "string"
|
||||||
|
},
|
||||||
|
"annotations": {
|
||||||
|
"additionalProp1": "string"
|
||||||
|
},
|
||||||
|
"creationTimestamp": "2022-11-20T13:06:38.512Z" // 创建时间
|
||||||
|
},
|
||||||
|
"spec": {
|
||||||
|
"displayName": "string", // 显示名称
|
||||||
|
"avatar": "string", // 头像链接
|
||||||
|
"email": "string", // 邮箱地址
|
||||||
|
"phone": "string", // 电话号码
|
||||||
|
"bio": 0, // 描述
|
||||||
|
"registeredAt": "2022-11-20T13:06:38.512Z", // 注册时间
|
||||||
|
"twoFactorAuthEnabled": false, // 是否启用二次验证
|
||||||
|
"disabled": false // 是否禁用
|
||||||
|
},
|
||||||
|
"status": {
|
||||||
|
"lastLoginAt": "2022-11-20T13:06:38.512Z", // 最后登录时间
|
||||||
|
"permalink": "string" // 作者的文章归档页面链接
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
@@ -109,7 +109,8 @@
|
|||||||
"developer-guide/theme/template-variables/tags",
|
"developer-guide/theme/template-variables/tags",
|
||||||
"developer-guide/theme/template-variables/tag",
|
"developer-guide/theme/template-variables/tag",
|
||||||
"developer-guide/theme/template-variables/categories",
|
"developer-guide/theme/template-variables/categories",
|
||||||
"developer-guide/theme/template-variables/category"
|
"developer-guide/theme/template-variables/category",
|
||||||
|
"developer-guide/theme/template-variables/author"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@@ -109,7 +109,8 @@
|
|||||||
"developer-guide/theme/template-variables/tags",
|
"developer-guide/theme/template-variables/tags",
|
||||||
"developer-guide/theme/template-variables/tag",
|
"developer-guide/theme/template-variables/tag",
|
||||||
"developer-guide/theme/template-variables/categories",
|
"developer-guide/theme/template-variables/categories",
|
||||||
"developer-guide/theme/template-variables/category"
|
"developer-guide/theme/template-variables/category",
|
||||||
|
"developer-guide/theme/template-variables/author"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user