From: Vincent Vanwaelscappel Date: Wed, 24 Oct 2018 12:36:43 +0000 (+0200) Subject: fix #1730 @1 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=30781603f0181841baf9907831d14a1e4f82e2e3;p=fluidbook-html5.git fix #1730 @1 --- diff --git a/js/libs/fluidbook/fluidbook.zoom.js b/js/libs/fluidbook/fluidbook.zoom.js index 8e8015a9..d1d40ce8 100644 --- a/js/libs/fluidbook/fluidbook.zoom.js +++ b/js/libs/fluidbook/fluidbook.zoom.js @@ -170,20 +170,21 @@ FluidbookZoom.prototype = { if (this.zoom != 1) { this.fluidbook.help.hide(); // Hide the help view if it's showing - $("#shadow").hide(); + $("#shadow").addClass('hidden'); if (!$('header').hasClass('hidden')) { $(hiddenElements).addClass('hidden'); this.hideInterfaceTimeout = setTimeout(function () { $(hiddenElements).hide(); - $("#shadow").addClass('hidden'); }, 500); } } else { - clearTimeout(this.hideInterfaceTimeout); $(hiddenElements).show().removeClass('hidden'); - $("#shadow").show().removeClass('hidden'); + setTimeout(function () { + $("#shadow").removeClass('hidden'); + }, 250); + } $("#z").transform(animation, {preserve: true}); $this.triggerEvent(((this.zoom == 1) ? 'out' : 'in') + '.start'); diff --git a/style/fluidbook.less b/style/fluidbook.less index 61aa35a4..6435f758 100644 --- a/style/fluidbook.less +++ b/style/fluidbook.less @@ -391,6 +391,14 @@ body, html { pointer-events: none; mix-blend-mode: multiply; + transition-property: opacity; + transition-duration: 250s; + + &.hidden { + transition-duration: 50ms; + opacity: 0; + } + > .shadow { position: absolute; left: 0;