Skip to content

Commit f8f98dc

Browse files
committed
更新样式和字体
1 parent 78f42c0 commit f8f98dc

File tree

2 files changed

+18
-36
lines changed

2 files changed

+18
-36
lines changed

.vitepress/config.mts

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,20 @@ export default defineConfig({
2121
},
2222
head: [
2323
['link', { rel: 'icon', href: '/logo.svg', type: 'image/svg+xml' }],
24+
[
25+
'link',
26+
{
27+
rel: 'stylesheet',
28+
href: 'https://chinese-fonts-cdn.deno.dev/packages/lxgwwenkaibright/dist/LXGWBright-Medium/result.css',
29+
},
30+
],
31+
['link', { rel: 'preconnect', href: 'https://fonts.googleapis.com' }],
32+
[
33+
'link',
34+
{
35+
rel: 'stylesheet',
36+
href: 'https://fonts.googleapis.com/css2?family=DM+Mono:ital,wght@0,300;0,400;0,500;1,300;1,400;1,500&display=swap',
37+
},
38+
],
2439
],
2540
})

.vitepress/theme/style.css

Lines changed: 3 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,14 @@
11
:root {
2+
--vp-font-family-base: 'LXGW Bright Medium', serif;
3+
--vp-font-family-mono: "DM Mono", monospace;
24
--vp-doc-top-height: 5rem;
35
}
46

57
#VPSidebarNav {
68
margin-top: var(--vp-doc-top-height);
79
}
810

9-
.main p {
10-
font-size: 1.1rem;
11-
line-height: 2.2rem;
12-
}
13-
14-
.main h1 {
15-
margin-top: 3rem;
16-
margin-bottom: 2rem;
17-
font-weight: bolder;
18-
font-size: 3.8rem;
19-
line-height: 1.2em;
20-
}
21-
2211
.main h2 {
23-
margin-bottom: 2rem;
12+
margin-top: 1rem;
2413
border-top: 0;
25-
font-size: 2.2rem;
26-
line-height: 1.2em;
27-
}
28-
29-
h2 > a {
30-
text-decoration: none;
31-
opacity: 0.3;
32-
}
33-
34-
h2 > a:hover {
35-
opacity: 0.9;
36-
}
37-
38-
.VPSidebarItem.level-0 > .item > .text {
39-
font-size: 0.8rem;
40-
letter-spacing: 2px;
41-
text-transform: uppercase;
42-
opacity: 0.5;
43-
}
44-
45-
.vp-doc :not(pre) > code {
46-
text-wrap: nowrap;
4714
}

0 commit comments

Comments
 (0)