From d545d79cd70ed09dbb15cc61e1f4dd84829dbe1b Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Fri, 6 Mar 2020 10:22:53 +0100 Subject: [PATCH] drop config, had no effect in modern browsers --- README.md | 3 --- js/reveal.js | 31 ------------------------------- 2 files changed, 34 deletions(-) diff --git a/README.md b/README.md index d069dd9..49a66fe 100644 --- a/README.md +++ b/README.md @@ -398,9 +398,6 @@ Reveal.initialize({ // Time before the cursor is hidden (in ms) hideCursorTime: 5000, - // Hides the address bar on mobile devices - hideAddressBar: true, - // Opens links in an iframe preview overlay // Add `data-preview-link` and `data-preview-link="false"` to customise each link // individually diff --git a/js/reveal.js b/js/reveal.js index 12dbcab..edd7c1f 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -246,9 +246,6 @@ // Apply a 3D roll to links on hover rollingLinks: false, - // Hides the address bar on mobile devices - hideAddressBar: true, - // Opens links in an iframe preview overlay // Add `data-preview-link` and `data-preview-link="false"` to customise each link // individually @@ -479,9 +476,6 @@ extend( config, options ); extend( config, query ); - // Hide the address bar in mobile browsers - hideAddressBar(); - // Loads dependencies and continues to #start() once done load(); @@ -1979,31 +1973,6 @@ } - /** - * Hides the address bar if we're on a mobile device. - */ - function hideAddressBar() { - - if( config.hideAddressBar && isMobileDevice ) { - // Events that should trigger the address bar to hide - window.addEventListener( 'load', removeAddressBar, false ); - window.addEventListener( 'orientationchange', removeAddressBar, false ); - } - - } - - /** - * Causes the address bar to hide on mobile devices, - * more vertical space ftw. - */ - function removeAddressBar() { - - setTimeout( function() { - window.scrollTo( 0, 1 ); - }, 10 ); - - } - /** * Dispatches an event of the specified type from the * reveal DOM element.