Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: 各模块README文档增加版本标记,优化静态站点内容显示 #78

Merged
merged 2 commits into from
Aug 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/CD.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,8 @@ jobs:

# 编译 打包成dist
- name: Build with VitePress
run: pnpm build:docs
run: |
pnpm build && pnpm build:docs

# 上传dist文件
- name: Upload artifact
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,12 @@ jobs:
run: |
npx eslint .

# 编辑模块代码
- name: Build Package Code
run: |
pnpm build

# 编译静态网站
- name: Build Core-X Docs
run: |
pnpm build:docs

- name: Build Code
run: |
pnpm build
14 changes: 7 additions & 7 deletions .vitepress/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ const GithubLinks = {
* 页脚
*/
export const footer = {
message: `Released Under The License <a href="${GithubLinks.CoreXLicense}">MIT </a>`,
copyright: `Copyright © 2019-present <a href="${GithubLinks.VipOrg}" style="margin-right:5px;">142vip</a> <a href=${GithubLinks.MainAccount}>👉储凡</a>`,
message: `The License <a href="${GithubLinks.CoreXLicense}">📖 MIT </a>`,
copyright: `Release ${packageName}@${currentPackageVersion} 😏<br> Copyright © 2019-present. Repo <a href="${GithubLinks.VipOrg}" style="margin-right:5px;">@142vip</a> Author. <a href=${GithubLinks.MainAccount}>👉储凡</a>`,
}

/**
Expand All @@ -29,8 +29,8 @@ export const navbarConfig: DefaultTheme.NavItem[] = [
link: '/docs/index.md',
},
{
text: '开发计划',
link: '/docs/road-map.md',
text: '自媒体',
link: '/docs/media.md',
},
{
text: currentPackageVersion,
Expand All @@ -46,8 +46,8 @@ export const navbarConfig: DefaultTheme.NavItem[] = [
],
},
{
text: '自媒体',
link: '/docs/media.md',
text: '开发计划',
link: 'https://142vip-cn.feishu.cn/share/base/view/shrcnpwFKWmMu5zXE9WaxjuCYAg',
},
]

Expand All @@ -70,7 +70,7 @@ const sidebarConfig: DefaultTheme.Sidebar = [
{ text: '@142vip/axios', link: '/packages/axios' },
{ text: '@142vip/oauth', link: '/packages/oauth' },
{ text: '@142vip/redis', link: '/packages/redis' },
{ text: '@142vip/typeorm', link: '/packages/redis' },
{ text: '@142vip/typeorm', link: '/packages/typeorm' },
],
},
{
Expand Down
30 changes: 11 additions & 19 deletions .vitepress/theme/components/ContactAuthor.vue
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
<script>

<script lang="ts" setup>
</script>

<template>
<div class="contact-author">
<h2 style="text-align: left">
<h2>
联系作者
</h2>
若系列文章对你有所帮助,欢迎订阅公众号或微信”骚扰“,获取更多内容。<strong>商务合作请备注来意</strong>
若系列文章对你有所帮助,欢迎订阅微信公众号或微信”骚扰“,获取更多内容。<strong>商务合作请备注来意</strong>
<div class="wechat">
<img
src="https://cdn.statically.io/gh/142vip/cdn_service@main/media/main-code.png"
Expand All @@ -30,39 +29,31 @@
>
</a>
<a
href="https://juejin.im/user/448256476724807" rel="nofollow noreferrer" target="_blank"
title="点击跳转掘金主页"
href="https://juejin.im/user/448256476724807" rel="nofollow noreferrer" target="_blank" title="点击跳转掘金主页"
>
<img
src="https://cdn.statically.io/gh/142vip/cdn_service@main/main-vip/svg/juejin.svg" alt="掘金"
class="platform-img"
>
</a>
<a
href="https://space.bilibili.com/350937042"
rel="nofollow noreferrer"
target="_blank"
title="点击跳转B站主页"
>
<a href="https://space.bilibili.com/350937042" rel="nofollow noreferrer" target="_blank" title="点击跳转B站主页">
<img
src="https://cdn.statically.io/gh/142vip/cdn_service@main/main-vip/svg/bilibili.svg"
alt="Bilibili"
class="platform-img"
>
</a>
<a
href="https://blog.csdn.net/Mmdapl"
rel="nofollow noreferrer"
target="_blank"
title="点击跳转CSDN博客主页"
>
<a href="https://blog.csdn.net/Mmdapl" rel="nofollow noreferrer" target="_blank" title="点击跳转CSDN博客主页">
<img
src="https://cdn.statically.io/gh/142vip/cdn_service@main/main-vip/svg/csdn.svg"
title="点击跳转CSDN博客主页" alt="CSDN" class="platform-img"
>
</a>
</div>
交流/加群/互看朋友圈、<strong>聊天/提问/建议/提需求</strong> 可以在公众号直接<strong>私信</strong>,有时间即会回复,偶尔的延迟和疏漏还请小伙伴们谅解,蟹蟹。

<div>
交流/加群/互看朋友圈、<strong>聊天/提问/建议/提需求</strong> 可以在公众号直接<strong>私信</strong>,有时间即会回复,偶尔的延迟和疏漏还请小伙伴们谅解,蟹蟹。
</div>
</div>
</template>

Expand All @@ -89,6 +80,7 @@
justify-content: center;
align-items: center;
padding: 5px;
margin-bottom: 10px;
}

.platform-img {
Expand Down
94 changes: 94 additions & 0 deletions .vitepress/theme/components/HomePage.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
<script lang="ts" setup>
import { VPTeamMembers } from 'vitepress/theme'
import { vipTeamMembers } from '@142vip/vitepress'
import ContactAuthor from './ContactAuthor.vue'
</script>

<template>
<section id="team">
<h2>团队</h2>
<VPTeamMembers :members="vipTeamMembers" size="small" />
</section>

<section id="team">
<h2>赞赏列表</h2>
<blockquote>
排名不分先后, <strong>赞赏过的一定要微信跟我说呀!!!!!!</strong>
</blockquote>
<div>
<a href="https://github.com/ChiefPing" target="_blank">
<img
alt="ChiefPing"
class="image-border"
src="https://avatars2.githubusercontent.com/u/34122068?s=460&v=4"
title="ChiefPing"
>
</a>
<a href="https://github.com/xiaoliuxin" target="_blank">
<img
alt="xiaoliuxin"
class="image-border"
src="https://avatars2.githubusercontent.com/u/60652527?s=460&v=4"
title="xiaoliuxin"
>
</a>
</div>
</section>

<section id="Sponsors">
<h2>赞助商</h2>
<blockquote>
以下排名不分先后! 还木有收到赞助,哈哈哈,先留坑
</blockquote>
</section>

<section id="contributions">
<h2>贡献</h2>

<blockquote>
感谢所有参与仓库建设的开发者
</blockquote>

<a href="https://github.com/142vip/core-x/graphs/contributors">
<img
alt="感谢向仓库提交PR的所有开发者"
src="https://contrib.rocks/image?repo=142vip/core-x"
title="@142vip/core-x"
>
</a>
</section>

<section id="trending">
<h2>趋势</h2>
<div align="center" style="text-align: center">
<img
alt="Github Star History"
class="img-border"
src="https://api.star-history.com/svg?repos=142vip/core-x&type=Date"
title="Github Star History"
>
</div>
</section>

<section id="contact-author">
<ContactAuthor />
</section>
</template>

<style scoped>
#trending {
.img-border {
border-radius: 5px;
}
}

#team {
.image-border {
border-radius: 5px;
width: 50px;
}
a {
margin: 5px;
}
}
</style>
43 changes: 0 additions & 43 deletions .vitepress/theme/components/TeamMembers.ts

This file was deleted.

1 change: 0 additions & 1 deletion .vitepress/theme/components/index.ts

This file was deleted.

72 changes: 7 additions & 65 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,14 @@ hero:
tagline: "易学易用、性能出色,适用工程化的通用工具包"
actions:
- theme: brand
text: 快速上手 →
text: 快速开始 🚀
link: /packages/fairy-cli
- theme: alt
text: 408CSFamily
text: 🤡 408CSFamily
link: https://github.com/142vip/408CSFamily
- theme: alt
text: 📘 JavaScriptCollection
link: https://github.com/142vip/JavaScriptCollection
# 功能页
features:
- title: 易学易用
Expand All @@ -25,68 +28,7 @@ features:
---

<script setup>
import { VPTeamPage, VPTeamPageTitle, VPTeamMembers, VPTeamPageSection} from 'vitepress/theme';

import ContactAuthor from '@theme/components/ContactAuthor.vue';
import {teamMembers} from "@theme/components";

const coreMembers = [];
const partners = [];
import HomePage from '@theme/components/HomePage.vue'
</script>

## @142vip/core-x

### 贡献

<VPTeamMembers size="small" :members="teamMembers" />

## 赞赏列表

以下排名不分先后, **赞赏过的一定要微信跟我说呀!!!!!!**

<div>
<a href="https://github.com/ChiefPing" target="_blank" style="margin: 5px">
<img
src="https://avatars2.githubusercontent.com/u/34122068?s=460&v=4"
alt="ChiefPing"
style="border-radius:5px;" width="50px"
/>
</a>
<a href="https://github.com/xiaoliuxin" target="_blank" style="margin: 5px">
<img
src="https://avatars2.githubusercontent.com/u/60652527?s=460&v=4"
alt="xiaoliuxin"
style="border-radius:5px;" width="50px"
/>
</a>
</div>

## 赞助商

以下排名不分先后! 还木有收到赞助,哈哈哈,先留坑

## 贡献

> 感谢所有参与仓库建设的开发者

<a href="https://github.com/142vip/core-x/graphs/contributors">
<img
src="https://contrib.rocks/image?repo=142vip/core-x"
alt="感谢向仓库提交PR的所有开发者"
title="@142vip/core-x"
/>
</a>

## 趋势

<div style="text-align: center" align="center">
<img
src="https://api.star-history.com/svg?repos=142vip/core-x&type=Date"
alt="Star History"
style="border-radius: 5px"
>
</div>

<ContactAuthor/>

<!-- #endregion we-media -->
<HomePage/>
2 changes: 2 additions & 0 deletions packages/axios/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# @142vip/axios

[![NPM version](https://img.shields.io/npm/v/@142vip/axios?color=a1b858&label=version)](https://www.npmjs.com/package/@142vip/axios)

## 参考

- [axios](https://github.com/axios/axios)
Expand Down
2 changes: 2 additions & 0 deletions packages/egg-axios/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# @142vip/egg-axios

[![NPM version](https://img.shields.io/npm/v/@142vip/egg-axios?color=a1b858&label=version)](https://www.npmjs.com/package/@142vip/egg-axios)

## 证书

[MIT](https://opensource.org/license/MIT)
Expand Down
2 changes: 2 additions & 0 deletions packages/egg-grpc-client/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# @142vip/egg-grpc-client

[![NPM version](https://img.shields.io/npm/v/@142vip/egg-grpc-client?color=a1b858&label=version)](https://www.npmjs.com/package/@142vip/egg-grpc-client)

## 证书

[MIT](https://opensource.org/license/MIT)
Expand Down
Loading
Loading