Skip to content

Commit 0abcb8b

Browse files
authored
docs: 创建 PR 模板+格式化+贡献指南 (#306)
1 parent 3b5974f commit 0abcb8b

13 files changed

Lines changed: 208 additions & 74 deletions

File tree

.github/pull_request_template.md

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
<!--
2+
💡 提示:这部分是注释,只在编辑时可见,提交后会被 GitHub 隐藏。
3+
感谢你提交 PR!请在提交前花一分钟阅读并填写以下内容。
4+
-->
5+
6+
## 📌 关联的 Issue
7+
8+
<!--
9+
请输入该 PR 关联的 Issue 编号(例如 Closes #123)。
10+
这样当 PR 被合并时,对应的 Issue 会自动关闭。
11+
-->
12+
13+
Closes #
14+
15+
---
16+
17+
## 📝 更改类型
18+
19+
<!-- 请在符合的选项 `[ ]` 中,把空格改成 `x` 变为 `[x]` 来进行勾选 -->
20+
21+
- [ ] 格式化
22+
- [ ] 新增 API
23+
- [ ] 修正错误
24+
- [ ] 更改依赖
25+
- [ ] 更改工作流
26+
- [ ] 其他(请在更改描述里面填写类型)
27+
28+
---
29+
30+
## 📖 更改描述
31+
32+
<!-- 请简要描述这个 PR 解决了什么问题,以及具体的修改思路和核心改动 -->
33+
34+
---
35+
36+
## 🧪 测试与验证说明
37+
38+
<!-- 请说明你是如何测试这些更改的,方便 Reviewer 验证 -->
39+
40+
- [ ] 我确认文档能够正常构建
41+
42+
---
43+
44+
## 🏁 自查清单
45+
46+
<!-- 在提交 PR 前,请确认你已经完成了以下事项 -->
47+
48+
- [ ] 我提交的内容符合本项目的[内容规范](https://yh-api.yyyyt.top/contribution_guide.html#内容规范)
49+
- [ ] 我已经对提交内容进行了初步的审查

src/.vuepress/navbar.ts

Lines changed: 30 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -3,31 +3,36 @@ import { navbar } from "vuepress-theme-hope";
33
export default navbar([
44
"/",
55
{
6-
text: "API文档",
7-
icon: "book",
8-
prefix: "/api/",
9-
children: [
10-
{
11-
text: "v1",
12-
link: "v1/"
13-
},
14-
{
15-
text: "wss",
16-
link: "wss/"
17-
},
18-
{
19-
text: "web",
20-
link: "web/"
21-
},
22-
{
23-
text: "bot",
24-
link: "bot/"
25-
},
26-
]
6+
text: "API文档",
7+
icon: "book",
8+
prefix: "/api/",
9+
children: [
10+
{
11+
text: "v1",
12+
link: "v1/",
13+
},
14+
{
15+
text: "wss",
16+
link: "wss/",
17+
},
18+
{
19+
text: "web",
20+
link: "web/",
21+
},
22+
{
23+
text: "bot",
24+
link: "bot/",
25+
},
26+
],
2727
},
2828
{
29-
text: "API吐槽",
30-
icon: "comment",
31-
link: "/云湖API吐槽/",
29+
text: "API吐槽",
30+
icon: "comment",
31+
link: "/云湖API吐槽/",
3232
},
33-
])
33+
{
34+
text: "贡献指南",
35+
icon: "book",
36+
link: "/contribution_guide",
37+
},
38+
]);

src/api/url_scheme.md

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,13 @@ yunhu://chat-add
88

99
参数:
1010

11-
| 名称 | 必须 | 备注 |
12-
| ----- | ---- | ---- |
13-
| id || 要添加的目标对象ID |
14-
| type || 要添加的目标对象类别,用户-user,群聊-group,机器人-bot |
11+
| 名称 | 必须 | 备注 |
12+
| ---- | ---- | ------------------------------------------------------- |
13+
| id || 要添加的目标对象ID |
14+
| type || 要添加的目标对象类别,用户-user,群聊-group,机器人-bot |
1515

1616
实例(添加ID为123的用户):
17+
1718
```text
1819
yunhu://chat-add?id=123&type=user
1920
```
@@ -24,11 +25,12 @@ yunhu://post-detail
2425

2526
参数:
2627

27-
| 名称 | 必须 | 备注 |
28-
| ----- | ---- | ---- |
29-
| id || 要跳转的目标文章ID |
28+
| 名称 | 必须 | 备注 |
29+
| ---- | ---- | ------------------ |
30+
| id || 要跳转的目标文章ID |
3031

3132
实例(跳转到ID为111的文章):
33+
3234
```text
3335
yunhu://post-detail?id=111
3436
```
@@ -39,11 +41,12 @@ yunhu://alley-detail
3941

4042
参数:
4143

42-
| 名称 | 必须 | 备注 |
43-
| ----- | ---- | ---- |
44-
| id || 要跳转的目标文章分区ID |
44+
| 名称 | 必须 | 备注 |
45+
| ---- | ---- | ---------------------- |
46+
| id || 要跳转的目标文章分区ID |
4547

4648
实例(跳转到ID为41的文章分区):
49+
4750
```text
4851
yunhu://post-detail?id=41
4952
```
@@ -54,11 +57,12 @@ yunhu://ad
5457

5558
参数:
5659

57-
| 名称 | 必须 | 备注 |
58-
| ----- | ---- | ---- |
59-
| id || 要观看的广告ID |
60+
| 名称 | 必须 | 备注 |
61+
| ---- | ---- | -------------- |
62+
| id || 要观看的广告ID |
6063

6164
实例(观看广告ID为123的广告):
65+
6266
```text
6367
yunhu://ad?id=123
6468
```

src/api/v1/group.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ POST /v1/group/remove-member
384384
### 请求头
385385

386386
| 名称 | 必须 | 备注 |
387-
| ----- | ---- |-------------------------|
387+
| ----- | ---- | ----------------------- |
388388
| token || 必须为群主或管理员token |
389389

390390
### 请求体
@@ -414,7 +414,7 @@ POST /v1/group/gag-member
414414
### 请求头
415415

416416
| 名称 | 必须 | 备注 |
417-
| ----- | ---- |-------------------------|
417+
| ----- | ---- | ----------------------- |
418418
| token || 必须为群主或管理员token |
419419

420420
### 请求体
@@ -1086,9 +1086,9 @@ POST /v1/group/create-group
10861086

10871087
### 请求头
10881088

1089-
| 名称 | 必须 | 备注 |
1090-
| ----- | ---- |--------------|
1091-
| token |||
1089+
| 名称 | 必须 | 备注 |
1090+
| ----- | ---- | ---- |
1091+
| token || |
10921092

10931093
### 请求体
10941094

@@ -1140,8 +1140,8 @@ POST /v1/group/dismiss-group
11401140

11411141
### 请求头
11421142

1143-
| 名称 | 必须 | 备注 |
1144-
| ----- | ---- |--------------|
1143+
| 名称 | 必须 | 备注 |
1144+
| ----- | ---- | ---- |
11451145
| token || 群主 |
11461146

11471147
### 请求体
@@ -1232,9 +1232,9 @@ POST /v1/group/agree-invite
12321232

12331233
请求头:
12341234

1235-
| 名称 | 必须 | 备注 |
1236-
| ----- | ---- |--------------|
1237-
| token |||
1235+
| 名称 | 必须 | 备注 |
1236+
| ----- | ---- | ---- |
1237+
| token || |
12381238

12391239
请求体:
12401240

@@ -1262,9 +1262,9 @@ POST /v1/group/member-is-removed
12621262

12631263
请求头:
12641264

1265-
| 名称 | 必须 | 备注 |
1266-
| ----- | ---- |--------------|
1267-
| token |||
1265+
| 名称 | 必须 | 备注 |
1266+
| ----- | ---- | ---- |
1267+
| token || |
12681268

12691269
请求体:
12701270

@@ -1292,9 +1292,9 @@ POST /v1/group/switch
12921292

12931293
请求头:
12941294

1295-
| 名称 | 必须 | 备注 |
1296-
| ----- | ---- |--------------|
1297-
| token |||
1295+
| 名称 | 必须 | 备注 |
1296+
| ----- | ---- | ---- |
1297+
| token || |
12981298

12991299
请求体:
13001300

src/api/v1/instruction.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,4 +234,4 @@ message instruction_list {
234234
}
235235
```
236236

237-
:::
237+
:::

src/api/v1/live.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -216,8 +216,8 @@ POST /v1/live/stream-info
216216

217217
请求头:
218218

219-
| 名称 | 必须 | 备注 |
220-
| ----- | ---- | ------- |
219+
| 名称 | 必须 | 备注 |
220+
| ----- | ---- | -------- |
221221
| token || VIP 用户 |
222222

223223
请求体:
@@ -255,4 +255,4 @@ POST /v1/live/stream-info
255255
{ "code":-1, "msg":"功能仅限VIP用户使用" }
256256
```
257257

258-
:::
258+
:::

src/api/v1/mount-setting.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ POST /v1/mount-setting/create
1111

1212
请求头:
1313

14-
| 名称 | 必须 | 备注 |
15-
| ----- | ---- | ----------------- |
14+
| 名称 | 必须 | 备注 |
15+
| ----- | ---- | ---------------------------------------- |
1616
| token || 普通用户的 token 也可(若后续改了欢迎 PR) |
1717

1818
请求体:
@@ -43,8 +43,8 @@ POST /v1/mount-setting/delete
4343

4444
请求头:
4545

46-
| 名称 | 必须 | 备注 |
47-
| ----- | ---- | ----------------- |
46+
| 名称 | 必须 | 备注 |
47+
| ----- | ---- | ---------------------------------------- |
4848
| token || 普通用户的 token 也可(若后续改了欢迎 PR) |
4949

5050
请求体:

src/api/v1/msg.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ message send_message_send {
9090

9191
### 任何消息
9292

93-
下面说的各种消息是需要额外注意/填写部分,填写内容建议看 proto 的注释.
93+
下面说的各种消息是需要额外注意/填写部分,填写内容建议看 proto 的注释.
9494

9595
必填:
9696

@@ -115,7 +115,7 @@ message send_message_send {
115115
此处文本类消息指 `普通文本`,`html 消息`,`markdown 消息`.
116116
必填:
117117

118-
- `data.text`
118+
- `data.text`
119119

120120
@tab 图片消息
121121

@@ -1071,9 +1071,9 @@ POST /v1/msg/delete
10711071

10721072
请求头:
10731073

1074-
| 名称 | 必须 | 备注 |
1075-
| ----- | ---- |--------------|
1076-
| token |||
1074+
| 名称 | 必须 | 备注 |
1075+
| ----- | ---- | ---- |
1076+
| token || |
10771077

10781078
请求体:
10791079

src/api/v1/user.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -732,7 +732,7 @@ POST /v1/user/gold-coin-increase-decrease-record
732732

733733
POST /v1/user/bing-phone
734734

735-
!!不要问为什么是 bing,我也不知道.!!
735+
!!不要问为什么是 bing,我也不知道.!!
736736

737737
请求头:
738738

@@ -762,7 +762,7 @@ POST /v1/user/bing-phone
762762

763763
POST /v1/user/bing-email
764764

765-
!!不要问为什么是 bing,我也不知道.!!
765+
!!不要问为什么是 bing,我也不知道.!!
766766

767767
请求头:
768768

@@ -993,7 +993,7 @@ POST /v1/user/save-user-remarks
993993

994994
POST /v1/user/cancel-user
995995

996-
!!谁 TMD 想出来的这种命名?!!
996+
!!谁 TMD 想出来的这种命名?!!
997997

998998
请求头:
999999

0 commit comments

Comments
 (0)