From: Vincent Vanwaelscappel Date: Wed, 26 Nov 2025 11:00:21 +0000 (+0100) Subject: wip #7867 @0.25 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=a933b461b59f88a8bc2c2f04a7001afc6f3bebe2;p=fluidbook-html5.git wip #7867 @0.25 --- diff --git a/js/libs/fluidbook/fluidbook.mobilefirst.js b/js/libs/fluidbook/fluidbook.mobilefirst.js index e510306d..9b5de5f6 100644 --- a/js/libs/fluidbook/fluidbook.mobilefirst.js +++ b/js/libs/fluidbook/fluidbook.mobilefirst.js @@ -23,7 +23,7 @@ FluidbookMobileFirst.prototype = { document.getElementById('scroll').addEventListener('scroll', function () { $this.isScrolling = true; - $this.checkScroll($(this).scrollTop()); + $this.checkScroll(); }, {passive: true}); document.getElementById('scroll').addEventListener('touchend', function () { @@ -68,8 +68,12 @@ FluidbookMobileFirst.prototype = { } var $this = this; if (delay === undefined) { - delay = 800; + if (this.fluidbook.settings.mobilefirstLinksRevealDelay === undefined || null == this.fluidbook.settings.mobilefirstLinksRevealDelay) { + this.fluidbook.settings.mobilefirstLinksRevealDelay = 0.8; + } + delay = Math.max(0, parseFloat(this.fluidbook.settings.mobilefirstLinksRevealDelay) * 1000); } + $("#links .link:not(.revealed):visible, .clinks [data-animations]:not(.revealed), .ctlinks [data-animations]:not(.revealed)").each(function () { var rect = $(this).get(0).getBoundingClientRect(); if (rect.top === 0 && rect.left === 0 && rect.width === 0 && rect.height === 0) {