From 1b9565fa2eeb2635f2233161f920963bf514b524 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Sat, 4 Dec 2021 18:55:49 +0100 Subject: Use img srcset for cover images of differing resolutions. --- views/head.pug | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'views/head.pug') diff --git a/views/head.pug b/views/head.pug index 294a911..d5350ac 100644 --- a/views/head.pug +++ b/views/head.pug @@ -12,6 +12,10 @@ link(rel="preload" as="font" type="font/woff2" crossorigin href="/fonts/SourceSa //- link(rel="preload" as="font" type="font/woff2" crossorigin href="/fonts/Dingbats.woff2") //- link(rel="preload" as="font" type="font/woff2" crossorigin href="/fonts/NotoEmoji.woff2") +mixin gamecover(title_id) + a(href="/info/"+title_id) + img(src=`/${title_id}/cover.1x.jpg` srcset=`/${title_id}/cover.2x.jpg 2x`) + mixin forumpost(row,show_buttons) .post .head -- cgit v1.2.3