From 931751ed697a10317e990306b88dcfb9f3015692 Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Tue, 26 Aug 2025 10:48:31 +0000 Subject: [PATCH 1/2] Refactor og image generation with simplified design and dynamic title Co-authored-by: hey --- pages/api/og.tsx | 169 +++++++++++++++++------------------------------ 1 file changed, 62 insertions(+), 107 deletions(-) diff --git a/pages/api/og.tsx b/pages/api/og.tsx index 5322349..0d381c1 100644 --- a/pages/api/og.tsx +++ b/pages/api/og.tsx @@ -8,144 +8,99 @@ export const config = { export default async function handler(req: NextRequest) { try { const { searchParams } = new URL(req.url) - - // Get dynamic parameters - const title = searchParams.get('title') || 'Tilekit' - const description = searchParams.get('description') || 'Monorepo hosting both in-house and vendored libraries and tools powering the Tiles Launcher.' - const type = searchParams.get('type') || 'default' - - // Note: Using system fonts for better compatibility + + const title = searchParams.get('title') || 'Tiles Launcher' return new ImageResponse( (
- {/* Header with logo */}
-
- T -
- - Tilekit - -
- - {/* Main content */} -
-

- {title} -

- -

- {description} -

-
- - {/* Footer */} -
- tileslauncher - - {type} -
- -
- tiles.run +
+
+
+
+
+
+
+
+
+ + Tiles Launcher +
+ {title !== 'Tiles Launcher' && ( +
+ {title} +
+ )}
), { width: 1200, height: 630, - } ) } catch (e: any) { From e57a1da510ebfbe9b1398558c304802304a74495 Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Tue, 26 Aug 2025 11:01:31 +0000 Subject: [PATCH 2/2] Update OG image to use Tilekit branding instead of Tiles Launcher Co-authored-by: hey --- pages/api/og.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pages/api/og.tsx b/pages/api/og.tsx index 0d381c1..15e4d38 100644 --- a/pages/api/og.tsx +++ b/pages/api/og.tsx @@ -9,7 +9,7 @@ export default async function handler(req: NextRequest) { try { const { searchParams } = new URL(req.url) - const title = searchParams.get('title') || 'Tiles Launcher' + const title = searchParams.get('title') || 'Tilekit' return new ImageResponse( ( @@ -39,7 +39,7 @@ export default async function handler(req: NextRequest) { display: 'flex', alignItems: 'center', justifyContent: 'center', - marginBottom: title !== 'Tiles Launcher' ? 40 : 0, + marginBottom: title !== 'Tilekit' ? 40 : 0, }} >
- Tiles Launcher + Tilekit
- {title !== 'Tiles Launcher' && ( + {title !== 'Tilekit' && (