diff --git a/Dockerfile b/Dockerfile index 41db56e..e65ccde 100644 --- a/Dockerfile +++ b/Dockerfile @@ -32,10 +32,8 @@ ENV NODE_ENV production # Install fonts for Sharp text rendering RUN apk add --no-cache \ fontconfig \ - ttf-dejavu \ - ttf-liberation \ - ttf-opensans \ font-noto \ + font-noto-emoji \ && fc-cache -f RUN addgroup --system --gid 1001 nodejs diff --git a/scripts/lib/discord.ts b/scripts/lib/discord.ts index 166b760..4133c55 100644 --- a/scripts/lib/discord.ts +++ b/scripts/lib/discord.ts @@ -179,7 +179,7 @@ export function formatMeshcoreMessageForDiscord( const content = `${text}\n-# _Heard ${heardCount} times by [MeshExplorer](https://map.w0z.is/messages)_`; // Generate profile picture URL using the new API - const profilePictureUrl = `https://map.w0z.is/api/meshcore/profilepicture.png?name=${encodeURIComponent(sender)}`; + const profilePictureUrl = `https://map.w0z.is/api/meshcore/profilepicture.png?name=${encodeURIComponent(sender)}&v=2`; return { username: sender, diff --git a/src/app/api/meshcore/profilepicture.png/route.ts b/src/app/api/meshcore/profilepicture.png/route.ts index 329b647..4f018e2 100644 --- a/src/app/api/meshcore/profilepicture.png/route.ts +++ b/src/app/api/meshcore/profilepicture.png/route.ts @@ -52,7 +52,7 @@ async function generateProfilePicturePNG(backgroundColor: string, label: string) y="50%" text-anchor="middle" dominant-baseline="central" - font-family="DejaVu Sans, Liberation Sans, Arial, sans-serif" + font-family="Noto Sans, Noto Color Emoji, sans-serif" font-size="${fontSize}" fill="white" >${escapeXml(label)} diff --git a/src/app/globals.css b/src/app/globals.css index c6441cd..d74507a 100644 --- a/src/app/globals.css +++ b/src/app/globals.css @@ -4,8 +4,8 @@ @theme inline { --color-background: var(--background); --color-foreground: var(--foreground); - --font-sans: var(--font-geist-sans); - --font-mono: var(--font-geist-mono); + --font-sans: var(--font-noto-sans), "Noto Sans", sans-serif; + --font-mono: var(--font-noto-sans), "Noto Sans", sans-serif; --color-sidebar-ring: var(--sidebar-ring); --color-sidebar-border: var(--sidebar-border); --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);