Skip to content

Commit

Permalink
chore: Update Open Graph image
Browse files Browse the repository at this point in the history
  • Loading branch information
dnys1 committed Oct 17, 2024
1 parent d98a001 commit 0109f7c
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 6 deletions.
25 changes: 19 additions & 6 deletions pages/api/og.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,13 @@ export default async function handler(request: NextRequest) {
).then((res) => res.arrayBuffer());
const poppinsBold = await fetch(
new URL(
"../../public/fonts/Poppins/Poppins-SemiBold.ttf",
"../../public/fonts/Poppins/Poppins-Medium.ttf",
import.meta.url
)
).then((res) => res.arrayBuffer());
const berkeleyMono = await fetch(
new URL(
"../../public/fonts/BerkeleyMono-Regular.ttf",
import.meta.url
)
).then((res) => res.arrayBuffer());
Expand Down Expand Up @@ -43,9 +49,9 @@ export default async function handler(request: NextRequest) {
alignItems: "center",
justifyContent: "center",
background:
"linear-gradient(100deg, #027dfd 26.96%, #92ebfe 109.1%)",
"linear-gradient(115deg, #010512 26.96%, #121f30 80%)",
color: "white",
fontFamily: "Poppins, sans-serif",
fontFamily: "Berkeley Mono, Poppins, sans-serif",
textAlign: "center",
}}
>
Expand All @@ -70,15 +76,16 @@ export default async function handler(request: NextRequest) {
style={{
paddingTop: 24,
marginLeft: 24,
fontSize: 100,
fontWeight: 600,
fontSize: 130,
fontWeight: 500,
fontFamily: 'Poppins',
}}
>
Celest
</div>
</div>
{title && (
<div style={{ marginTop: 24, fontSize: 56, maxWidth: "50%" }}>
<div style={{ marginTop: 28, fontSize: 56, maxWidth: "50%" }}>
{title}
</div>
)}
Expand All @@ -104,6 +111,12 @@ export default async function handler(request: NextRequest) {
style: "normal",
weight: 600,
},
{
name: "Berkeley Mono",
data: berkeleyMono,
style: "normal",
weight: 400,
},
],
}
);
Expand Down
Binary file added public/fonts/BerkeleyMono-Regular.ttf
Binary file not shown.

0 comments on commit 0109f7c

Please sign in to comment.