Skip to content

Commit 6aded38

Browse files
committed
feat: done products
1 parent a6094e4 commit 6aded38

File tree

8 files changed

+56
-15
lines changed

8 files changed

+56
-15
lines changed

src/config.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ export const navBarConfig: NavBarConfig = {
4141
links: [
4242
LinkPreset.Home,
4343
LinkPreset.Archive,
44+
LinkPreset.Products,
4445
LinkPreset.About,
4546
{
4647
name: 'GitHub',

src/constants/link-presets.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ export const LinkPresets: { [key in LinkPreset]: NavBarLink } = {
1111
name: i18n(I18nKey.about),
1212
url: '/about/',
1313
},
14+
[LinkPreset.Products]: {
15+
name: '作品',
16+
url: '/products/',
17+
},
1418
[LinkPreset.Archive]: {
1519
name: i18n(I18nKey.archive),
1620
url: '/archive/',

src/content/spec/about.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
# About
2-
This is the demo site for [Fuwari](https://github.com/saicaca/fuwari).
1+
# 关于
32

4-
::github{repo="saicaca/fuwari"}
3+
嘿,我是 wsafight。
54

6-
> ### Sources of images used in this site
7-
> - [Unsplash](https://unsplash.com/)
8-
> - [星と少女](https://www.pixiv.net/artworks/108916539) by [Stella](https://www.pixiv.net/users/93273965)
9-
> - [Rabbit - v1.4 Showcase](https://civitai.com/posts/586908) by [Rabbit_YourMajesty](https://civitai.com/user/Rabbit_YourMajesty)
5+
主业前端,副业后端,也曾在互联网公司担任技术负责人,带过 10 人的技术团队。
6+
7+
目前赋闲在家。
8+
9+
偶尔在此停留。

src/content/spec/products.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# 作品
2+
3+
::github{repo="wsafight/mpt"}
4+
5+
::github{repo="wsafight/business-util"}
6+
7+
::github{repo="LazierGame/react-mobile-range-selector"}
8+
9+
::github{repo="wsafight/memoizee-proxy"}
10+
11+
::github{repo="wsafight/try-run-js"}
12+
13+
::github{repo="wsafight/diff-helper"}
14+
15+
::github{repo="wsafight/storage-tools"}
16+
17+
::github{repo="wsafight/little-virtual-computer"}
18+
19+
::github{repo="wsafight/front-end-checklist"}
20+
21+
::github{repo="wsafight/sync-time"}

src/pages/about.astro

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,14 @@
11
---
2-
32
import MainGridLayout from '../layouts/MainGridLayout.astro'
43
54
import { getEntry } from 'astro:content'
6-
import { i18n } from '../i18n/translation'
7-
import I18nKey from '../i18n/i18nKey'
85
import Markdown from '@components/misc/Markdown.astro'
96
107
const aboutPost = await getEntry('spec', 'about')
118
129
const { Content } = await aboutPost.render()
1310
---
14-
<MainGridLayout title={i18n(I18nKey.about)} description={i18n(I18nKey.about)}>
11+
<MainGridLayout title="关于" description="关于">
1512
<div class="flex w-full rounded-[var(--radius-large)] overflow-hidden relative min-h-32">
1613
<div class="card-base z-10 px-9 py-6 relative w-full ">
1714
<Markdown class="mt-2">

src/pages/archive/index.astro

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
---
22
import MainGridLayout from '@layouts/MainGridLayout.astro'
33
import ArchivePanel from '@components/ArchivePanel.astro'
4-
import { i18n } from '@i18n/translation'
5-
import I18nKey from '@i18n/i18nKey'
64
---
75

8-
<MainGridLayout title={i18n(I18nKey.archive)}>
6+
<MainGridLayout title='归档'>
97
<ArchivePanel></ArchivePanel>
108
</MainGridLayout>
119

src/pages/products.astro

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
import MainGridLayout from '../layouts/MainGridLayout.astro'
3+
4+
import { getEntry } from 'astro:content'
5+
import Markdown from '@components/misc/Markdown.astro'
6+
7+
const productsPost = await getEntry('spec', 'products')
8+
9+
const { Content } = await productsPost.render()
10+
---
11+
<MainGridLayout title="作品" description="作品">
12+
<div class="flex w-full rounded-[var(--radius-large)] overflow-hidden relative min-h-32">
13+
<div class="card-base z-10 px-9 py-6 relative w-full ">
14+
<Markdown class="mt-2">
15+
<Content />
16+
</Markdown>
17+
</div>
18+
</div>
19+
</MainGridLayout>

src/types/config.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@ export type Favicon = {
3737
export enum LinkPreset {
3838
Home = 0,
3939
Archive = 1,
40-
About = 2,
40+
Products = 2,
41+
About = 3,
4142
}
4243

4344
export type NavBarLink = {

0 commit comments

Comments
 (0)