From 740915de8c5227610c0a2ae0dee0dfc9bbaa1048 Mon Sep 17 00:00:00 2001 From: avvvvvv Date: Tue, 19 Nov 2024 11:03:31 +0100 Subject: [PATCH] Bugfix long schedule (#150) * adjust spacing for longer schedules * adjust font size for longer schedules --- pages/api/schedule-artwork.tsx | 39 +++++++++++++++++++++++----------- 1 file changed, 27 insertions(+), 12 deletions(-) diff --git a/pages/api/schedule-artwork.tsx b/pages/api/schedule-artwork.tsx index 08b800c..5603469 100644 --- a/pages/api/schedule-artwork.tsx +++ b/pages/api/schedule-artwork.tsx @@ -64,6 +64,7 @@ async function handle(request: Request) { }); const longSchedule = todaysSchedule.length > 10; + const extraLongSchedule = todaysSchedule.length > 11; const fontLight = await fetch( new URL("../../assets/VisueltLight.otf", import.meta.url) @@ -79,11 +80,7 @@ async function handle(request: Request) { return new ImageResponse( ( -
+
{todaysSchedule.map((item, index) => (
{dayjs(item.date.slice(0, -1)) @@ -154,7 +157,11 @@ async function handle(request: Request) { .format("HH:mm")}
{item.title} @@ -163,7 +170,11 @@ async function handle(request: Request) { ))}
{dayjs( @@ -173,7 +184,11 @@ async function handle(request: Request) { .format("HH:mm")}
Repeats Playlist @@ -182,7 +197,7 @@ async function handle(request: Request) {
refugeworldwide.com