From: Vincent Vanwaelscappel Date: Thu, 25 Mar 2021 17:51:34 +0000 (+0100) Subject: wait #4346 @1 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=ffe62eb9b412e814a1178e30ca4b1b43561f59b2;p=fluidbook-html5.git wait #4346 @1 --- diff --git a/js/libs/fluidbook/slideshow/fluidbook.slideshow.vacheron.js b/js/libs/fluidbook/slideshow/fluidbook.slideshow.vacheron.js index a524c601..14bb1443 100644 --- a/js/libs/fluidbook/slideshow/fluidbook.slideshow.vacheron.js +++ b/js/libs/fluidbook/slideshow/fluidbook.slideshow.vacheron.js @@ -135,7 +135,13 @@ FluidbookVacheronSlideshow.prototype = { $(s).css({width: w, height: h}); var nav = $(s).find('.fb-slideshow-nav'); - $(nav).css('left', (w - $(nav).outerWidth()) / 2); + var navLeft = (w - $(nav).outerWidth()) / 2; + var transform = ''; + if (navLeft < 0) { + navLeft = 0; + transform = 'scale(' + (w / $(nav).outerWidth()) + ')'; + } + $(nav).css({left: navLeft, transform: transform}); return {w: w, h: h, fullscreen: fullscreen}; diff --git a/style/slideshow/vacheron.less b/style/slideshow/vacheron.less index 280a84ac..98aa2df2 100644 --- a/style/slideshow/vacheron.less +++ b/style/slideshow/vacheron.less @@ -82,6 +82,7 @@ opacity: 0; transition: opacity 250ms; white-space: nowrap; + transform-origin: 0 0; .fb-slideshow-nav-prev, .fb-slideshow-nav-next { @w: 40px;