From 0bc7e68e83141cb87373dc26708efec3c9d207f6 Mon Sep 17 00:00:00 2001 From: Yannik Schmidt Date: Wed, 9 Sep 2020 20:45:36 +0200 Subject: [PATCH] fix lazyloading on high pd displays --- static/lazyload.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/static/lazyload.js b/static/lazyload.js index 4cb21ba..4fbf505 100644 --- a/static/lazyload.js +++ b/static/lazyload.js @@ -1,8 +1,9 @@ /* determine which size of image to load */ function getSize(src){ - var trueRes = screen.width/window.devicePixelRatio + var trueRes = screen.width/Math.min(window.devicePixelRatio, 4) if(src.indexOf("scale_fullscreen") > -1 || src.indexOf("wallpaper") > -1 ){ + trueRes = Math.max(trueRes, 800) return '?scalex=' + trueRes }