Skip to content

Commit 397e5e7

Browse files
authored
use Fira Sans for UI elements (#232)
* use Fira Sans * simplify font stacks * fixes * fixes
1 parent b9e4401 commit 397e5e7

File tree

24 files changed

+53
-22
lines changed

24 files changed

+53
-22
lines changed

apps/svelte.dev/src/routes/(authed)/playground/[id]/AppControls.svelte

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -317,6 +317,7 @@ export default app;`
317317
margin: 0 0.2em 0 0.4rem;
318318
padding-top: 0.2em;
319319
border-bottom: 1px solid transparent;
320+
font-size: var(--sk-font-size-ui-medium);
320321
}
321322
322323
input:hover {

apps/svelte.dev/src/routes/_home/Hero.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@
9494
background: var(--sk-theme-1);
9595
padding: 0.35em 0.8em;
9696
font-family: var(--sk-font-ui);
97-
letter-spacing: 0.05em;
97+
font-size: var(--sk-font-size-ui-medium);
9898
font-weight: 600;
9999
white-space: nowrap;
100100
border-radius: var(--sk-border-radius);

apps/svelte.dev/src/routes/blog/[slug]/card.png/+server.ts

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ import { read } from '$app/server';
55
import satori from 'satori';
66
import { html as toReactNode } from 'satori-html';
77
import Card from './Card.svelte';
8-
import YantramanavRegular from './Yantramanav-Regular.ttf?url';
8+
import DMSerifDisplay from './DMSerifDisplay-Regular.ttf?url';
9+
import FiraSans from './FiraSans-Regular.ttf?url';
910
import { blog_posts } from '$lib/server/content';
1011

1112
export const prerender = true;
@@ -18,7 +19,8 @@ export function entries() {
1819

1920
const height = 630;
2021
const width = 1200;
21-
const data = await read(YantramanavRegular).arrayBuffer();
22+
const dm_serif_display = await read(DMSerifDisplay).arrayBuffer();
23+
const fira_sans = await read(FiraSans).arrayBuffer();
2224

2325
export async function GET({ params }) {
2426
const post = blog_posts.find((post) => post.slug === `blog/${params.slug}`);
@@ -31,8 +33,14 @@ export async function GET({ params }) {
3133
const svg = await satori(element, {
3234
fonts: [
3335
{
34-
name: 'Overpass',
35-
data,
36+
name: 'DMSerif Display',
37+
data: dm_serif_display,
38+
style: 'normal',
39+
weight: 400
40+
},
41+
{
42+
name: 'Fira Sans',
43+
data: fira_sans,
3644
style: 'normal',
3745
weight: 400
3846
}

apps/svelte.dev/src/routes/blog/[slug]/card.png/Card.svelte

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
display: flex;
1919
width: 100%;
2020
height: 100%;
21-
font-family: 'Yantramanav';
2221
background: white;
2322
}
2423
@@ -49,12 +48,14 @@
4948
font-weight: 400;
5049
line-height: 80px;
5150
margin: 0 0 0.5em 0;
51+
font-family: 'DM Serif Display';
5252
}
5353
5454
.date {
5555
font-size: 32px;
5656
margin: 0;
5757
color: #555;
5858
text-transform: uppercase;
59+
font-family: 'Fira Sans';
5960
}
6061
</style>
70.5 KB
Binary file not shown.
431 KB
Binary file not shown.
-166 KB
Binary file not shown.
-150 KB
Binary file not shown.

apps/svelte.dev/src/routes/docs/+page.svelte

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,4 +86,8 @@
8686
max-width: 50rem;
8787
}
8888
}
89+
90+
a {
91+
font-size: var(--sk-font-size-body-small);
92+
}
8993
</style>

apps/svelte.dev/src/routes/docs/[...path]/+page.svelte

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,10 @@
115115
color: var(--sk-text-3);
116116
}
117117
118+
.controls a {
119+
font-size: var(--sk-font-size-body-small);
120+
}
121+
118122
.controls span.faded {
119123
opacity: 0.4;
120124
}

0 commit comments

Comments
 (0)