From 86a1f8ac253e7eebdecef914ea825385bd31bae5 Mon Sep 17 00:00:00 2001 From: Sanjay B Date: Fri, 29 Oct 2021 15:03:15 +0530 Subject: [PATCH] android seems to report width of video fractionally higher than width of screen, round down value to fix #38 --- app/static/js/ascroll.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/static/js/ascroll.js b/app/static/js/ascroll.js index d25ac76..bbeae73 100755 --- a/app/static/js/ascroll.js +++ b/app/static/js/ascroll.js @@ -79,7 +79,7 @@ function isElementInViewport (el) { rect.top >= 0 && rect.left >= 0 && rect.bottom <= (window.innerHeight || document.documentElement.clientHeight) && /* or $(window).height() */ - rect.right <= (window.innerWidth || document.documentElement.clientWidth) /* or $(window).width() */ + Math.floor(rect.right) <= (window.innerWidth || document.documentElement.clientWidth) /* or $(window).width() */ ); }