Skip to content

Commit fc0f689

Browse files
committed
docs(sponsor): update sponsor page and refactor sidebar items
- Update sponsor page to use VPSponsors component - Refactor sidebar items in config.ts for better readability - Adjust formatting and indentation in config.ts
1 parent fd4cfaa commit fc0f689

2 files changed

Lines changed: 51 additions & 49 deletions

File tree

‎docs/.vitepress/config.ts‎

Lines changed: 29 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ import {
1515
} from '@nolebase/vitepress-plugin-page-properties/vite';
1616
import { ThumbnailHashImages } from '@nolebase/vitepress-plugin-thumbnail-hash/vite';
1717
import { transformerTwoslash } from '@shikijs/vitepress-twoslash';
18-
import { transformHeadMeta } from '@nolebase/vitepress-plugin-meta/vitepress'
18+
import { transformHeadMeta } from '@nolebase/vitepress-plugin-meta/vitepress';
1919

2020
export default defineConfig({
2121
lang: 'zh-CN',
2222
title: 'ChatLuna',
23-
base: "/",
23+
base: '/',
2424
description: 'ChatLuna',
2525
ignoreDeadLinks: true,
2626
lastUpdated: true,
@@ -143,14 +143,13 @@ export default defineConfig({
143143
],
144144
},
145145
async transformHead(context) {
146-
let head = [...context.head]
147-
148-
const returnedHead = await transformHeadMeta()(head, context)
149-
if (typeof returnedHead !== 'undefined')
150-
head = returnedHead
151-
152-
return head
153-
},
146+
let head = [...context.head];
147+
148+
const returnedHead = await transformHeadMeta()(head, context);
149+
if (typeof returnedHead !== 'undefined') head = returnedHead;
150+
151+
return head;
152+
},
154153
});
155154

156155
function sidebarGuide(): DefaultTheme.SidebarItem[] {
@@ -227,7 +226,7 @@ function sidebarGuide(): DefaultTheme.SidebarItem[] {
227226
{
228227
text: 'RWKV',
229228
link: '/guide/configure-model-platform/rwkv',
230-
}
229+
},
231230
],
232231
},
233232
{
@@ -422,7 +421,7 @@ function sidebarGuide(): DefaultTheme.SidebarItem[] {
422421
{
423422
text: '知识库客服 Bot',
424423
link: '/guide/best-practice/knowledge-base-and-customer-service-robot',
425-
}
424+
},
426425
],
427426
},
428427
{
@@ -540,7 +539,7 @@ function sidebarDevelopment(): DefaultTheme.SidebarItem[] {
540539
{
541540
text: '模型 (Model)',
542541
link: '/development/api-reference/llm-core/model',
543-
}
542+
},
544543
],
545544
},
546545
{
@@ -626,18 +625,18 @@ function sidebarEcosystem(): DefaultTheme.SidebarItem[] {
626625
function about(): DefaultTheme.SidebarItem[] {
627626
return [
628627
{
629-
text: "参与讨论",
630-
link: "/about/contact"
628+
text: '参与讨论',
629+
link: '/about/contact',
631630
},
632631
{
633-
text: "赞助者",
634-
link: "/about/sponsor"
632+
text: '赞助者',
633+
link: '/about/sponsor',
635634
},
636635
{
637-
text: "关于",
638-
link: "/about/about"
639-
}
640-
]
636+
text: '关于',
637+
link: '/about/about',
638+
},
639+
];
641640
}
642641

643642
function nav(): DefaultTheme.NavItem[] {
@@ -658,22 +657,22 @@ function nav(): DefaultTheme.NavItem[] {
658657
activeMatch: '/ecosystem/',
659658
},
660659
{
661-
text: "更多",
660+
text: '更多',
662661
items: [
663662
{
664-
text: "参与讨论",
665-
link: "/about/contact"
663+
text: '参与讨论',
664+
link: '/about/contact',
666665
},
667666
{
668-
text: "赞助者",
669-
link: "/about/sponsor"
667+
text: '赞助者',
668+
link: '/about/sponsor',
670669
},
671670
{
672-
text: "关于",
673-
link: "/about/about"
674-
}
671+
text: '关于',
672+
link: '/about/about',
673+
},
675674
],
676675
activeMatch: '/about/',
677-
}
676+
},
678677
];
679678
}

‎docs/about/sponsor.md‎

Lines changed: 22 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,51 @@
11
<script setup>
2-
import { VPTeamMembers, VPTeamPageSection } from 'vitepress/theme'
2+
import { VPTeamMembers, VPTeamPageSection, VPSponsors } from 'vitepress/theme'
33

44
const thinks = [
55
{
6-
avatar: "https://avatar.viki.moe?qq=766949709",
6+
img: "https://q1.qlogo.cn/g?b=qq&nk=766949709&s=0",
77
name: "EF台风",
8+
url: "#EF台风",
89
},
910
{
10-
avatar: "https://avatar.viki.moe?qq=2371124484",
11+
img: "https://q1.qlogo.cn/g?b=qq&nk=2371124484&s=0",
1112
name: "TR0MX",
13+
url: "#TR0MX",
1214
},
1315
{
14-
avatar: "https://avatar.viki.moe?qq=52473342",
16+
img: "https://q1.qlogo.cn/g?b=qq&nk=52473342&s=0",
1517
name: "僵尸尸",
18+
url: "#僵尸尸",
1619
},
1720
{
18-
avatar: "https://avatar.viki.moe?qq=3373167460",
21+
img: "https://q1.qlogo.cn/g?b=qq&nk=3373167460&s=0",
1922
name: "Nawyjx",
23+
url: "#Nawyjx",
2024
},
2125
{
22-
avatar: "https://avatar.viki.moe?qq=3283406743",
26+
img: "https://q1.qlogo.cn/g?b=qq&nk=3283406743&s=0",
2327
name: "Ling",
28+
url: "#Ling",
2429
},
2530
{
26-
avatar: "https://avatar.viki.moe?qq=1919892171",
31+
img: "https://q1.qlogo.cn/g?b=qq&nk=1919892171&s=0",
2732
name: "上学",
33+
url: "#上学",
2834
},
2935
{
30-
avatar: "https://avatar.viki.moe?qq=503753255",
36+
img: "https://q1.qlogo.cn/g?b=qq&nk=503753255&s=0",
3137
name: "飞@^O^",
38+
url: "#飞@^O^",
3239
},
3340
{
34-
avatar: "https://avatar.viki.moe?qq=3374687501",
41+
img: "https://q1.qlogo.cn/g?b=qq&nk=3374687501&s=0",
3542
name: "WhiteGivenMan",
43+
url: "#WhiteGivenMan",
3644
},
3745
{
38-
avatar: "https://pic1.afdiancdn.com/default/avatar/avatar-blue.png?imageView2/1/w/120/h/120",
46+
img: "https://pic1.afdiancdn.com/default/avatar/avatar-blue.png?imageView2/1/w/120/h/120",
3947
name: "KaleElus",
48+
url: "#KaleElus",
4049
}
4150
];
4251
</script>
@@ -47,12 +56,6 @@ ChatLuna 是一个开源项目,在开发过程中,我们也收到了很多
4756

4857
[爱发电](https://afdian.com/a/dingyi222666)
4958

50-
<VPTeamPage>
51-
<VPTeamPageSection>
52-
<template #title>Sponsors</template>
53-
<template #lead>排名不分先后</template>
54-
<template #members>
55-
<VPTeamMembers size="small" :members="thinks" />
56-
</template>
57-
</VPTeamPageSection>
58-
</VPTeamPage>
59+
> 以下排名不分先后
60+
61+
<VPSponsors :tier="排名不分先后" :data="thinks" />

0 commit comments

Comments
 (0)