diff options
Diffstat (limited to 'js/reveal.js')
-rw-r--r-- | js/reveal.js | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/js/reveal.js b/js/reveal.js index 41be56b..b229453 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -1118,7 +1118,11 @@ var Reveal = (function(){ } // Apply scale transform as a fallback else { - transformElement( dom.slides, 'translate(-50%, -50%) scale('+ scale +') translate(50%, 50%)' ); + dom.slides.style.left = '50%'; + dom.slides.style.top = '50%'; + dom.slides.style.bottom = 'auto'; + dom.slides.style.right = 'auto'; + transformElement( dom.slides, 'translate(-50%, -50%) scale('+ scale +')' ); } // Select all slides, vertical and horizontal @@ -1139,7 +1143,7 @@ var Reveal = (function(){ slide.style.top = 0; } else { - slide.style.top = Math.max( - ( getAbsoluteHeight( slide ) / 2 ) - slidePadding, -slideHeight / 2 ) + 'px'; + slide.style.top = Math.max( ( ( slideHeight - getAbsoluteHeight( slide ) ) / 2 ) - slidePadding, 0 ) + 'px'; } } else { |