Skip to content

Commit a54b440

Browse files
committed
Update OG / Twitter metadata and image to read/compute/write framing
Old description ('Lit is a key management network for decentralized signing and encryption…') and the static og-image.png / twitter-image.png both pushed the previous positioning, so Slack and Twitter unfurls were still selling the old network. Replace the description with the new framing and serve a dynamic OG image via an edge route handler at /api/og. Tried the file-based opengraph-image.tsx convention first but it inherits the app layout's Mantine import, which doesn't compile under edge runtime. The /api/og route doesn't bundle the layout, so the edge ImageResponse renders cleanly. Added metadataBase so relative URLs resolve in production. Deleted the stale static PNGs.
1 parent 6366216 commit a54b440

4 files changed

Lines changed: 126 additions & 10 deletions

File tree

public/og-image.png

-629 KB
Binary file not shown.

public/twitter-image.png

-606 KB
Binary file not shown.

src/app/api/og/route.tsx

Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
import { ImageResponse } from 'next/server';
2+
3+
export const runtime = 'edge';
4+
5+
export async function GET() {
6+
return new ImageResponse(
7+
(
8+
<div
9+
style={{
10+
width: '100%',
11+
height: '100%',
12+
display: 'flex',
13+
flexDirection: 'column',
14+
justifyContent: 'center',
15+
padding: '80px',
16+
background:
17+
'linear-gradient(135deg, #0a1226 0%, #1a2347 45%, #0e1a2e 100%)',
18+
color: 'white',
19+
position: 'relative',
20+
}}
21+
>
22+
<div
23+
style={{
24+
position: 'absolute',
25+
top: -200,
26+
right: -200,
27+
width: 700,
28+
height: 700,
29+
background:
30+
'radial-gradient(circle, rgba(167,243,208,0.18) 0%, transparent 65%)',
31+
display: 'flex',
32+
}}
33+
/>
34+
<div
35+
style={{
36+
position: 'absolute',
37+
bottom: -200,
38+
left: -200,
39+
width: 600,
40+
height: 600,
41+
background:
42+
'radial-gradient(circle, rgba(255,66,5,0.16) 0%, transparent 65%)',
43+
display: 'flex',
44+
}}
45+
/>
46+
47+
<div
48+
style={{
49+
display: 'flex',
50+
alignItems: 'center',
51+
gap: 14,
52+
fontSize: 24,
53+
color: 'rgba(255,255,255,0.65)',
54+
letterSpacing: '0.2em',
55+
marginBottom: 36,
56+
fontFamily: 'monospace',
57+
}}
58+
>
59+
<span
60+
style={{
61+
width: 10,
62+
height: 10,
63+
borderRadius: 999,
64+
background: '#a7f3d0',
65+
display: 'flex',
66+
}}
67+
/>
68+
LIT PROTOCOL · TEE-SECURED COMPUTE
69+
</div>
70+
71+
<div
72+
style={{
73+
display: 'flex',
74+
flexDirection: 'column',
75+
fontSize: 80,
76+
lineHeight: 1.05,
77+
fontWeight: 500,
78+
letterSpacing: '-0.02em',
79+
}}
80+
>
81+
<div style={{ display: 'flex' }}>Read anywhere.</div>
82+
<div style={{ display: 'flex' }}>
83+
<span style={{ color: '#a7f3d0' }}>Compute</span>
84+
<span style={{ marginLeft: '0.3em' }}>in a TEE.</span>
85+
</div>
86+
<div style={{ display: 'flex' }}>Write to any chain or API.</div>
87+
</div>
88+
89+
<div
90+
style={{
91+
display: 'flex',
92+
justifyContent: 'space-between',
93+
alignItems: 'center',
94+
marginTop: 56,
95+
color: 'rgba(255,255,255,0.55)',
96+
fontSize: 24,
97+
fontFamily: 'monospace',
98+
letterSpacing: '0.15em',
99+
}}
100+
>
101+
<span>litprotocol.com</span>
102+
<span>READ · COMPUTE · WRITE</span>
103+
</div>
104+
</div>
105+
),
106+
{
107+
width: 1200,
108+
height: 630,
109+
}
110+
);
111+
}

src/app/layout.tsx

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,30 +11,35 @@ import {
1111
mantineHtmlProps,
1212
} from '@mantine/core';
1313

14+
const DESCRIPTION =
15+
'Read anywhere. Compute in a TEE. Write to any chain or API. Lit is a programmable runtime that pulls data from any source, runs your logic in a chain-secured TEE, and signs on any chain or API.';
16+
1417
export const metadata: Metadata = {
18+
metadataBase: new URL('https://litprotocol.com'),
1519
title: 'Lit Protocol',
16-
description:
17-
'Lit is a key management network for decentralized signing and encryption. Create apps and wallets that use secrets without single points of failure.',
20+
description: DESCRIPTION,
1821
openGraph: {
1922
title: 'Lit Protocol',
20-
description:
21-
'Lit is a key management network for decentralized signing and encryption. Create apps and wallets that use secrets without single points of failure.',
23+
description: DESCRIPTION,
2224
url: 'https://litprotocol.com',
2325
siteName: 'Lit Protocol',
2426
images: {
25-
url: '/og-image.png',
26-
alt: 'Description of Lit Protocol over a blue and orange gradient background',
27+
url: '/api/og',
28+
width: 1200,
29+
height: 630,
30+
alt: 'Lit Protocol — Read anywhere. Compute in a TEE. Write to any chain or API.',
2731
},
2832
},
2933
twitter: {
3034
card: 'summary_large_image',
3135
title: 'Lit Protocol',
32-
description:
33-
'Lit is a key management network for decentralized signing and encryption. Create apps and wallets that use secrets without single points of failure.',
36+
description: DESCRIPTION,
3437
creator: '@LitProtocol',
3538
images: {
36-
url: '/twitter-image.png',
37-
alt: 'Description of Lit Protocol over a blue and orange gradient background',
39+
url: '/api/og',
40+
width: 1200,
41+
height: 630,
42+
alt: 'Lit Protocol — Read anywhere. Compute in a TEE. Write to any chain or API.',
3843
},
3944
},
4045
};

0 commit comments

Comments
 (0)