diff --git a/serverside/hs2-last-updated.ts b/serverside/hs2-last-updated.ts index 528de4a..2aba00e 100644 --- a/serverside/hs2-last-updated.ts +++ b/serverside/hs2-last-updated.ts @@ -118,7 +118,21 @@ const font = await fetch("https://static.pyrope.net/courier-std-bold.otf") function make_image(n: number): Image { const days = Math.floor(n).toString().padStart(3, "0"); - const image = new Image(106, 44); + let image = new Image(110, 44); + + const outline = Image.renderText( + font, + 64, + days, + 0xff_ff_ff_ff, + new TextLayout({ verticalAlign: "center", horizontalAlign: "middle" }), + ); + + for (const hshift of [-2, 0, 2]) { + for (const vshift of [-2, 0, 2]) { + image = image.composite(outline, hshift - 4, vshift); + } + } const text = Image.renderText( font, 64, @@ -127,7 +141,7 @@ function make_image(n: number): Image { new TextLayout({ verticalAlign: "center", horizontalAlign: "middle" }), ); - return image.composite(text, -5); + return image.composite(text, -4); } async function update_images() {