Skip to content

Commit dd44bde

Browse files
authored
feat: 基于VipOpenSource组件,优化文档首页 (142vip#713)
* feat(@142vip/vitepress): 新增`VipOpenSource`组件,支持自定义开源仓库 * feat: 基于`VipOpenSource`组件,优化文档首页
1 parent 0eec7ad commit dd44bde

1 file changed

Lines changed: 3 additions & 89 deletions

File tree

.vitepress/theme/components/HomePage.vue

Lines changed: 3 additions & 89 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,13 @@
22
import {
33
VipBackTop,
44
VipContactAuthor,
5+
VipOpenSource,
56
VipProjectTable,
67
VipTeam,
78
} from '@142vip/vitepress/components'
8-
import { useData } from 'vitepress'
99
import { onMounted, ref } from 'vue'
1010
import { getCoreProjectData, getExampleDemoTableData } from '../../sidebar'
1111
12-
const { isDark } = useData()
1312
const coreProjectTableData = ref<any[]>([])
1413
const exampleDemoTableData = ref()
1514
@@ -31,96 +30,11 @@ onMounted(async () => {
3130

3231
<VipTeam />
3332

34-
<section id="sponsors">
35-
<h2>赞赏列表</h2>
36-
<blockquote>
37-
排名不分先后, <strong>赞赏过的一定要微信跟我说呀!!!!!!</strong>
38-
</blockquote>
39-
<div>
40-
<a href="https://github.com/ChiefPing" target="_blank">
41-
<img
42-
alt="ChiefPing"
43-
class="image-border"
44-
src="https://avatars2.githubusercontent.com/u/34122068?s=460&v=4"
45-
title="ChiefPing"
46-
>
47-
</a>
48-
<a href="https://github.com/xiaoliuxin" target="_blank">
49-
<img
50-
alt="xiaoliuxin"
51-
class="image-border"
52-
src="https://avatars2.githubusercontent.com/u/60652527?s=460&v=4"
53-
title="xiaoliuxin"
54-
>
55-
</a>
56-
</div>
57-
<h2>赞助商</h2>
58-
<blockquote>
59-
以下排名不分先后! 还木有收到赞助,哈哈哈,先留坑
60-
</blockquote>
61-
</section>
62-
63-
<section id="contributions">
64-
<h2>贡献</h2>
65-
66-
<blockquote>
67-
感谢所有参与仓库建设的开发者
68-
</blockquote>
69-
70-
<a href="https://github.com/142vip/core-x/graphs/contributors">
71-
<img
72-
alt="感谢向仓库提交PR的所有开发者"
73-
src="https://contrib.rocks/image?repo=142vip/core-x"
74-
title="@142vip/core-x"
75-
>
76-
</a>
77-
</section>
78-
79-
<section id="trending">
80-
<h2>趋势</h2>
81-
<!-- 支持黑色主题 -->
82-
<div class="star-history">
83-
<img
84-
:src="`https://api.star-history.com/svg?repos=142vip/core-x,142vip/408CSFamily,142vip/JavaScriptCollection&type=Date${
85-
isDark ? '&theme=dark' : ''
86-
}`"
87-
class="img-border"
88-
alt="Github Star History"
89-
title="Github Star History"
90-
>
91-
</div>
92-
</section>
33+
<!-- 开源项目 -->
34+
<VipOpenSource />
9335

9436
<section id="contact-author">
9537
<VipContactAuthor />
9638
</section>
9739
<VipBackTop />
9840
</template>
99-
100-
<style scoped>
101-
#trending {
102-
.img-border {
103-
border-radius: 5px;
104-
}
105-
}
106-
107-
#sponsors {
108-
div {
109-
display: flex;
110-
justify-content: left;
111-
}
112-
.image-border {
113-
border-radius: 5px;
114-
width: 50px;
115-
}
116-
a {
117-
margin: 5px;
118-
}
119-
}
120-
121-
.star-history {
122-
display: flex;
123-
justify-content: center;
124-
align-content: center;
125-
}
126-
</style>

0 commit comments

Comments
 (0)