Skip to content

Commit 5ce1e24

Browse files
authored
update fonts for better readability, removed satoshi font (#419)
1 parent 42285df commit 5ce1e24

File tree

11 files changed

+37
-50
lines changed

11 files changed

+37
-50
lines changed

docs/.vitepress/config.ts

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -62,17 +62,7 @@ export default defineConfig({
6262
"link",
6363
{
6464
rel: "preload",
65-
href: "/fonts/Satoshi/Satoshi-Regular.woff2",
66-
as: "font",
67-
type: "font/woff2",
68-
crossorigin: "anonymous",
69-
},
70-
],
71-
[
72-
"link",
73-
{
74-
rel: "preload",
75-
href: "/fonts/Satoshi/Satoshi-Medium.woff2",
65+
href: "/fonts/Inter/InterVariable.woff2",
7666
as: "font",
7767
type: "font/woff2",
7868
crossorigin: "anonymous",

docs/.vitepress/theme/style.css

Lines changed: 36 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -93,45 +93,13 @@
9393
}
9494

9595
/* ================================================
96-
SATOSHI FONT
96+
INTER VARIABLE FONT
9797
================================================ */
9898

9999
@font-face {
100-
font-family: "Satoshi";
101-
src:
102-
url("/fonts/Satoshi/Satoshi-Light.woff2") format("woff2"),
103-
url("/fonts/Satoshi/Satoshi-Light.woff") format("woff");
104-
font-weight: 300;
105-
font-style: normal;
106-
font-display: swap;
107-
}
108-
109-
@font-face {
110-
font-family: "Satoshi";
111-
src:
112-
url("/fonts/Satoshi/Satoshi-Regular.woff2") format("woff2"),
113-
url("/fonts/Satoshi/Satoshi-Regular.woff") format("woff");
114-
font-weight: 400;
115-
font-style: normal;
116-
font-display: swap;
117-
}
118-
119-
@font-face {
120-
font-family: "Satoshi";
121-
src:
122-
url("/fonts/Satoshi/Satoshi-Medium.woff2") format("woff2"),
123-
url("/fonts/Satoshi/Satoshi-Medium.woff") format("woff");
124-
font-weight: 500;
125-
font-style: normal;
126-
font-display: swap;
127-
}
128-
129-
@font-face {
130-
font-family: "Satoshi";
131-
src:
132-
url("/fonts/Satoshi/Satoshi-Bold.woff2") format("woff2"),
133-
url("/fonts/Satoshi/Satoshi-Bold.woff") format("woff");
134-
font-weight: 700;
100+
font-family: "Inter";
101+
src: url("/fonts/Inter/InterVariable.woff2") format("woff2");
102+
font-weight: 100 900;
135103
font-style: normal;
136104
font-display: swap;
137105
}
@@ -187,13 +155,42 @@
187155

188156
/* Fonts */
189157
--vp-font-family-base:
190-
"Satoshi", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell,
158+
"Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell,
191159
sans-serif;
192160
--vp-font-family-mono:
193161
"IBM Plex Mono", ui-monospace, SFMono-Regular, "SF Mono", Menlo, Monaco, Consolas,
194162
"Liberation Mono", "Courier New", monospace;
195163
}
196164

165+
/* Font rendering optimizations */
166+
body {
167+
-webkit-font-smoothing: antialiased;
168+
-moz-osx-font-smoothing: grayscale;
169+
text-rendering: optimizeLegibility;
170+
font-feature-settings: "cv01", "cv02", "zero";
171+
}
172+
173+
/* Typography tuning */
174+
.vp-doc {
175+
line-height: 1.7;
176+
letter-spacing: -0.011em;
177+
}
178+
179+
.vp-doc h1 {
180+
letter-spacing: -0.022em;
181+
line-height: 1.2;
182+
}
183+
184+
.vp-doc h2 {
185+
letter-spacing: -0.017em;
186+
line-height: 1.3;
187+
}
188+
189+
.vp-doc h3 {
190+
letter-spacing: -0.014em;
191+
line-height: 1.4;
192+
}
193+
197194
/* Dark mode */
198195
.dark {
199196
--vp-c-bg: #0a0a0a;
@@ -300,7 +297,7 @@
300297
font-weight: 700;
301298
padding: 5px 12px;
302299
border-radius: 6px;
303-
font-family: ui-monospace, SFMono-Regular, monospace;
300+
font-family: var(--vp-font-family-mono);
304301
text-transform: uppercase;
305302
}
306303

@@ -347,7 +344,7 @@
347344
}
348345

349346
.api-endpoint-badge .path {
350-
font-family: ui-monospace, SFMono-Regular, monospace;
347+
font-family: var(--vp-font-family-mono);
351348
font-size: 14px;
352349
color: #6b7280;
353350
}
344 KB
Binary file not shown.
-32.2 KB
Binary file not shown.
-24.7 KB
Binary file not shown.
-28.6 KB
Binary file not shown.
-22.3 KB
Binary file not shown.
-32.5 KB
Binary file not shown.
-25 KB
Binary file not shown.
-32.3 KB
Binary file not shown.

0 commit comments

Comments
 (0)