ansilove.js

A script to display ANSi and artscene related file formats on web pages
Log | Files | Refs | README | LICENSE

commit 40f25672d484241e4c6f77a9020c02e4c1448d5d
parent cddb7a94fe13c82320ecf7348501f61e22a1bb91
Author: Andy Herbert <andy.herbert@gmail.com>
Date:   Sun, 10 Nov 2013 19:15:13 +0000

Hide the scrollbars until the overlay has slid into view.

Diffstat:
Mansilove.js | 5++++-
1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/ansilove.js b/ansilove.js @@ -2200,6 +2200,9 @@ var AnsiLove = (function () { applyStyle(divOverlay, {"background-image": "none"}); } transitionCSS(divCanvasContainer, "top", "0.6s", "ease-in-out", {"top": "0"}); + setTimeout(function () { + applyStyle(divOverlay, {"overflow": "auto"}); + }, 750); } // Applies styles to a <canvas> element, depending on which <browser> is detected. Makes sure each <canvas> element is displayed vertically without a gap, by setting vertical-align: bottom. "image-rendering" is set to prevent image smoothing on retina type displays. @@ -2247,7 +2250,7 @@ var AnsiLove = (function () { } // Create the overlay element with various css styles. - divOverlay = createDiv({"position": "fixed", "left": "0px", "top": "0px", "width": "100%", "height": "100%", "background-color": "rgba(0, 0, 0, 0.8)", "overflow": "scroll", "z-index": (findHighestZIndex() + 1).toString(10), "opacity": "0"}); + divOverlay = createDiv({"position": "fixed", "left": "0px", "top": "0px", "width": "100%", "height": "100%", "background-color": "rgba(0, 0, 0, 0.8)", "overflow": "hidden", "z-index": (findHighestZIndex() + 1).toString(10), "opacity": "0"}); // If a spinner url is provided in <options>, add it to the backdrop of the overlay element... if (options.spinner) { applyStyle(divOverlay, {"background-image": "url(" + options.spinner + ")", "background-position": "center center", "background-repeat": "no-repeat"});