From 25f3884bf4deb315aaf9a5236ec1c05f85e3ff42 Mon Sep 17 00:00:00 2001 From: Lars Kappert Date: Tue, 29 Jan 2013 23:49:17 +0100 Subject: [PATCH 01/22] Support for external markdown files, including configurable (vertical) slide separator --- demo.md | 29 +++++++++ index-markdown.html | 105 ++++++++++++++++++++++++++++++ plugin/markdown/markdown.js | 126 +++++++++++++++++++++++++++++++++--- 3 files changed, 252 insertions(+), 8 deletions(-) create mode 100644 demo.md create mode 100644 index-markdown.html diff --git a/demo.md b/demo.md new file mode 100644 index 0000000..1efe5f9 --- /dev/null +++ b/demo.md @@ -0,0 +1,29 @@ +# External markdown + + + +## Slide 1.1 + +Content 1.1 + + +## Slide 1.2 + +Content 1.2 + + + +## Slide 2 + +Content 2.1 + + + +## Slide 3.1 + +Content 3.1 + + +## Slide 3.2 + +Content 3.2 diff --git a/index-markdown.html b/index-markdown.html new file mode 100644 index 0000000..f46575b --- /dev/null +++ b/index-markdown.html @@ -0,0 +1,105 @@ + + + + + + + reveal.js - The HTML Presentation Framework + + + + + + + + + + + + + + + + + + + + + +
+ + +
+ + +
+ + +
+ +
+ + +
+ +
+ +
+
+ + + + + + + + diff --git a/plugin/markdown/markdown.js b/plugin/markdown/markdown.js index b1660a1..8d40019 100644 --- a/plugin/markdown/markdown.js +++ b/plugin/markdown/markdown.js @@ -6,11 +6,7 @@ throw 'The reveal.js Markdown plugin requires Showdown to be loaded'; } - var sections = document.querySelectorAll( '[data-markdown]' ); - - for( var i = 0, len = sections.length; i < len; i++ ) { - var section = sections[i]; - var notes = section.querySelector( 'aside.notes' ); + var stripLeadingWhitespace = function(section) { var template = section.querySelector( 'script' ); @@ -27,11 +23,125 @@ text = text.replace( new RegExp('\\n? {' + leadingWs + '}','g'), '\n' ); } - section.innerHTML = (new Showdown.converter()).makeHtml(text); + return text; + + }; + + var slidifyMarkdown = function(markdown, separator, vertical) { + + separator = separator || '^\n---\n$'; + + var reSeparator = new RegExp(separator + (vertical ? '|' + vertical : ''), 'mg'), + reHorSeparator = new RegExp(separator), + matches, + lastIndex = 0, + isHorizontal, + wasHorizontal = true, + content, + sectionStack = [], + markdownSections = ''; + + // iterate until all blocks between separators are stacked up + while( matches = reSeparator.exec(markdown) ) { + + // determine direction (horizontal by default) + isHorizontal = reHorSeparator.test(matches[0]); + + if( !isHorizontal && wasHorizontal ) { + // create vertical stack + sectionStack.push([]); + } + + // pluck slide content from markdown input + content = markdown.substring(lastIndex, matches.index); + + if( isHorizontal && wasHorizontal ) { + // add to horizontal stack + sectionStack.push(content); + } else { + // add to vertical stack + sectionStack[sectionStack.length-1].push(content); + } + + lastIndex = reSeparator.lastIndex; + wasHorizontal = isHorizontal; + + } + + // add the remaining slide + (wasHorizontal ? sectionStack : sectionStack[sectionStack.length-1]).push(markdown.substring(lastIndex)); + + // flatten the hierarchical stack, and insert
tags + for( var k = 0, klen = sectionStack.length; k < klen; k++ ) { + markdownSections += typeof sectionStack[k] === 'string' + ? '
' + sectionStack[k] + '
' + : '
' + sectionStack[k].join('
') + '
'; + } + + return markdownSections; + }; + + var queryMarkdownSlides = function() { + + var sections = document.querySelectorAll( '[data-markdown]'), + section; + + for( var j = 0, jlen = sections.length; j < jlen; j++ ) { + + section = sections[j]; + + if( section.getAttribute('data-markdown').length ) { + + var xhr = new XMLHttpRequest(), + url = section.getAttribute('data-markdown'); + + xhr.onreadystatechange = function () { + if( xhr.readyState === 4 ) { + section.outerHTML = slidifyMarkdown( xhr.responseText, section.getAttribute('data-separator'), section.getAttribute('data-vertical') ); + } + }; + + xhr.open('GET', url, false); + xhr.send(); + + } else if( section.getAttribute('data-separator') ) { + + var markdown = stripLeadingWhitespace(section); + section.outerHTML = slidifyMarkdown( markdown, section.getAttribute('data-separator'), section.getAttribute('data-vertical') ); + + } + } + + querySlides(); + + }; + + var querySlides = function() { + + var sections = document.querySelectorAll( '[data-markdown]'); + + for( var j = 0, jlen = sections.length; j < jlen; j++ ) { + + makeHtml(sections[j]); + + } + + }; + + var makeHtml = function(section) { + + var notes = section.querySelector( 'aside.notes' ); + + var markdown = stripLeadingWhitespace(section); + + section.innerHTML = (new Showdown.converter()).makeHtml(markdown); if( notes ) { section.appendChild( notes ); } - } -})(); \ No newline at end of file + }; + + queryMarkdownSlides(); + +})(); From 5dd63e4919b58bde83591590bacf37a1f091fa2a Mon Sep 17 00:00:00 2001 From: Lars Kappert Date: Tue, 29 Jan 2013 23:59:57 +0100 Subject: [PATCH 02/22] More/better examples in markdown demo --- index-markdown.html | 39 +++++++++++++++++++++++++-------------- 1 file changed, 25 insertions(+), 14 deletions(-) diff --git a/index-markdown.html b/index-markdown.html index f46575b..367c879 100644 --- a/index-markdown.html +++ b/index-markdown.html @@ -38,33 +38,44 @@
- -
+ +
- + +
+ +
+ +
From 7207122c75137c0d2c7dfd0e1d9a1a0e9bf0a88f Mon Sep 17 00:00:00 2001 From: Lars Kappert Date: Wed, 30 Jan 2013 00:09:02 +0100 Subject: [PATCH 03/22] Slightly refactored "slidify" flow --- plugin/markdown/markdown.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/plugin/markdown/markdown.js b/plugin/markdown/markdown.js index 8d40019..ae4d08b 100644 --- a/plugin/markdown/markdown.js +++ b/plugin/markdown/markdown.js @@ -81,7 +81,7 @@ return markdownSections; }; - var queryMarkdownSlides = function() { + var querySlidingMarkdown = function() { var sections = document.querySelectorAll( '[data-markdown]'), section; @@ -112,11 +112,9 @@ } } - querySlides(); - }; - var querySlides = function() { + var queryMarkdownSlides = function() { var sections = document.querySelectorAll( '[data-markdown]'); @@ -142,6 +140,8 @@ }; + querySlidingMarkdown(); + queryMarkdownSlides(); })(); From c00de0a24d5140c74a96952135d96c63f3a0cae3 Mon Sep 17 00:00:00 2001 From: James Bergstra Date: Thu, 21 Feb 2013 11:23:07 -0500 Subject: [PATCH 04/22] ENH: fragment-pos attribute for ordering fragments --- js/reveal.js | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/js/reveal.js b/js/reveal.js index 7572569..15cfbae 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -138,6 +138,30 @@ var Reveal = (function(){ handled: false, threshold: 80 }; + /** + * Return a sorted fragments list, ordered by an increasing "fragment-pos" attribute. + * + * Fragments will be revealed in the order that they are returned by + * this function, so you can use "fragment-pos" attributes to control + * the order of fragment appearance. + * + * To maintain a sensible default fragment order, fragments are presumed + * to be passed in document order. This function adds a "fragment-pos" + * attribute to each node if such an attribute is not already present, + * and sets that attribute to an integer value which is the position of + * the fragment within the fragments list. + * + */ + function sort_fragments( fragments ) { + var a = toArray(fragments) + a.forEach( function (el, idx) { + if (!el.hasAttribute('fragment-pos')) { + el.setAttribute('fragment-pos', idx) }}) + a.sort(function(l, r) { + return l.getAttribute( 'fragment-pos' ) + - r.getAttribute( 'fragment-pos') }) + return a + } /** * Starts up the presentation if the client is capable. @@ -997,6 +1021,7 @@ var Reveal = (function(){ // Show fragment, if specified if( typeof f !== 'undefined' ) { var fragments = currentSlide.querySelectorAll( '.fragment' ); + fragments = sort_fragments(fragments) toArray( fragments ).forEach( function( fragment, indexf ) { if( indexf < f ) { @@ -1368,6 +1393,7 @@ var Reveal = (function(){ // Vertical slides: if( document.querySelector( VERTICAL_SLIDES_SELECTOR + '.present' ) ) { var verticalFragments = document.querySelectorAll( VERTICAL_SLIDES_SELECTOR + '.present .fragment:not(.visible)' ); + verticalFragments = sort_fragments(verticalFragments) if( verticalFragments.length ) { verticalFragments[0].classList.add( 'visible' ); @@ -1379,6 +1405,7 @@ var Reveal = (function(){ // Horizontal slides: else { var horizontalFragments = document.querySelectorAll( HORIZONTAL_SLIDES_SELECTOR + '.present .fragment:not(.visible)' ); + horizontalFragments = sort_fragments(horizontalFragments) if( horizontalFragments.length ) { horizontalFragments[0].classList.add( 'visible' ); @@ -1403,6 +1430,7 @@ var Reveal = (function(){ // Vertical slides: if( document.querySelector( VERTICAL_SLIDES_SELECTOR + '.present' ) ) { var verticalFragments = document.querySelectorAll( VERTICAL_SLIDES_SELECTOR + '.present .fragment.visible' ); + verticalFragments = sort_fragments(verticalFragments) if( verticalFragments.length ) { verticalFragments[ verticalFragments.length - 1 ].classList.remove( 'visible' ); @@ -1414,6 +1442,7 @@ var Reveal = (function(){ // Horizontal slides: else { var horizontalFragments = document.querySelectorAll( HORIZONTAL_SLIDES_SELECTOR + '.present .fragment.visible' ); + horizontalFragments = sort_fragments(horizontalFragments) if( horizontalFragments.length ) { horizontalFragments[ horizontalFragments.length - 1 ].classList.remove( 'visible' ); @@ -1919,4 +1948,4 @@ var Reveal = (function(){ } }; -})(); \ No newline at end of file +})(); From e4016792dd3da16e858a47f855388e0fc91b5341 Mon Sep 17 00:00:00 2001 From: James Bergstra Date: Thu, 21 Feb 2013 13:16:26 -0500 Subject: [PATCH 05/22] FIX: indent level of sort_fragments --- js/reveal.js | 49 +++++++++++++++++++++++++------------------------ 1 file changed, 25 insertions(+), 24 deletions(-) diff --git a/js/reveal.js b/js/reveal.js index 15cfbae..ded2e86 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -138,30 +138,31 @@ var Reveal = (function(){ handled: false, threshold: 80 }; - /** - * Return a sorted fragments list, ordered by an increasing "fragment-pos" attribute. - * - * Fragments will be revealed in the order that they are returned by - * this function, so you can use "fragment-pos" attributes to control - * the order of fragment appearance. - * - * To maintain a sensible default fragment order, fragments are presumed - * to be passed in document order. This function adds a "fragment-pos" - * attribute to each node if such an attribute is not already present, - * and sets that attribute to an integer value which is the position of - * the fragment within the fragments list. - * - */ - function sort_fragments( fragments ) { - var a = toArray(fragments) - a.forEach( function (el, idx) { - if (!el.hasAttribute('fragment-pos')) { - el.setAttribute('fragment-pos', idx) }}) - a.sort(function(l, r) { - return l.getAttribute( 'fragment-pos' ) - - r.getAttribute( 'fragment-pos') }) - return a - } + + /** + * Return a sorted fragments list, ordered by an increasing "fragment-pos" attribute. + * + * Fragments will be revealed in the order that they are returned by + * this function, so you can use "fragment-pos" attributes to control + * the order of fragment appearance. + * + * To maintain a sensible default fragment order, fragments are presumed + * to be passed in document order. This function adds a "fragment-pos" + * attribute to each node if such an attribute is not already present, + * and sets that attribute to an integer value which is the position of + * the fragment within the fragments list. + * + */ + function sort_fragments( fragments ) { + var a = toArray(fragments) + a.forEach( function (el, idx) { + if (!el.hasAttribute('fragment-pos')) { + el.setAttribute('fragment-pos', idx) }}) + a.sort(function(l, r) { + return l.getAttribute( 'fragment-pos' ) + - r.getAttribute( 'fragment-pos') }) + return a + } /** * Starts up the presentation if the client is capable. From f795cb02690dd9f3a6ea64f880797840dc675c89 Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Sun, 24 Feb 2013 00:44:20 -0500 Subject: [PATCH 06/22] add configure api method for update config after initialization --- js/reveal.js | 107 ++++++++++++++++++++++++++++------------------- js/reveal.min.js | 4 +- 2 files changed, 65 insertions(+), 46 deletions(-) diff --git a/js/reveal.js b/js/reveal.js index 7572569..a559090 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -335,40 +335,40 @@ var Reveal = (function(){ /** * Applies the configuration settings from the config object. */ - function configure() { + function configure( options ) { - if( supports3DTransforms === false ) { - config.transition = 'linear'; - } + dom.wrapper.classList.remove( config.transition ); - if( config.controls && dom.controls ) { - dom.controls.style.display = 'block'; - } + // New config options may be passed when this method + // is invoked through the API after initialization + if( typeof options === 'object' ) extend( config, options ); - if( config.progress && dom.progress ) { - dom.progress.style.display = 'block'; - } + // Force linear transition based on browser capabilities + if( supports3DTransforms === false ) config.transition = 'linear'; - if( config.transition !== 'default' ) { - dom.wrapper.classList.add( config.transition ); - } + dom.wrapper.classList.add( config.transition ); - if( config.rtl ) { - dom.wrapper.classList.add( 'rtl' ); - } + dom.controls.style.display = ( config.controls && dom.controls ) ? 'block' : 'none'; + dom.progress.style.display = ( config.progress && dom.progress ) ? 'block' : 'none'; - if( config.center ) { - dom.wrapper.classList.add( 'center' ); - } + dom.wrapper.classList.toggle( 'rtl', config.rtl ); + dom.wrapper.classList.toggle( 'center', config.center ); if( config.mouseWheel ) { document.addEventListener( 'DOMMouseScroll', onDocumentMouseScroll, false ); // FF document.addEventListener( 'mousewheel', onDocumentMouseScroll, false ); } + else { + document.removeEventListener( 'DOMMouseScroll', onDocumentMouseScroll, false ); // FF + document.removeEventListener( 'mousewheel', onDocumentMouseScroll, false ); + } // 3D links if( config.rollingLinks ) { - linkify(); + enable3DLinks(); + } + else { + disable3DLinks(); } // Load the theme in the config, if it's not already loaded @@ -524,28 +524,47 @@ var Reveal = (function(){ /** * Wrap all links in 3D goodness. */ - function linkify() { + function enable3DLinks() { if( supports3DTransforms && !( 'msPerspective' in document.body.style ) ) { - var nodes = document.querySelectorAll( SLIDES_SELECTOR + ' a:not(.image)' ); + var anchors = document.querySelectorAll( SLIDES_SELECTOR + ' a:not(.image)' ); - for( var i = 0, len = nodes.length; i < len; i++ ) { - var node = nodes[i]; + for( var i = 0, len = anchors.length; i < len; i++ ) { + var anchor = anchors[i]; - if( node.textContent && !node.querySelector( '*' ) && ( !node.className || !node.classList.contains( node, 'roll' ) ) ) { + if( anchor.textContent && !anchor.querySelector( '*' ) && ( !anchor.className || !anchor.classList.contains( anchor, 'roll' ) ) ) { var span = document.createElement('span'); - span.setAttribute('data-title', node.text); - span.innerHTML = node.innerHTML; + span.setAttribute('data-title', anchor.text); + span.innerHTML = anchor.innerHTML; - node.classList.add( 'roll' ); - node.innerHTML = ''; - node.appendChild(span); + anchor.classList.add( 'roll' ); + anchor.innerHTML = ''; + anchor.appendChild(span); } } } } + /** + * Unwrap all 3D links. + */ + function disable3DLinks() { + + var anchors = document.querySelectorAll( SLIDES_SELECTOR + ' a.roll' ); + + for( var i = 0, len = anchors.length; i < len; i++ ) { + var anchor = anchors[i]; + var span = anchor.querySelector( 'span' ); + + if( span ) { + anchor.classList.remove( 'roll' ); + anchor.innerHTML = span.innerHTML; + } + } + + } + /** * Applies JavaScript-controlled layout rules to the * presentation. @@ -602,31 +621,30 @@ var Reveal = (function(){ dom.slides.style.transform = transform; } - if( config.center ) { + // Select all slides, vertical and horizontal + var slides = toArray( document.querySelectorAll( SLIDES_SELECTOR ) ); - // Select all slides, vertical and horizontal - var slides = toArray( document.querySelectorAll( SLIDES_SELECTOR ) ); + for( var i = 0, len = slides.length; i < len; i++ ) { + var slide = slides[ i ]; - // Determine the minimum top offset for slides - var minTop = -slideHeight / 2; - - for( var i = 0, len = slides.length; i < len; i++ ) { - var slide = slides[ i ]; - - // Don't bother updating invisible slides - if( slide.style.display === 'none' ) { - continue; - } + // Don't bother updating invisible slides + if( slide.style.display === 'none' ) { + continue; + } + if( config.center ) { // Vertical stacks are not centered since their section // children will be if( slide.classList.contains( 'stack' ) ) { slide.style.top = 0; } else { - slide.style.top = Math.max( - ( slide.offsetHeight / 2 ) - 20, minTop ) + 'px'; + slide.style.top = Math.max( - ( slide.offsetHeight / 2 ) - 20, -slideHeight / 2 ) + 'px'; } } + else { + slide.style.top = ''; + } } @@ -1812,6 +1830,7 @@ var Reveal = (function(){ return { initialize: initialize, + configure: configure, // Navigation methods slide: slide, diff --git a/js/reveal.min.js b/js/reveal.min.js index 8023e69..e1fb8aa 100644 --- a/js/reveal.min.js +++ b/js/reveal.min.js @@ -1,8 +1,8 @@ /*! - * reveal.js 2.3 (2013-02-13, 18:00) + * reveal.js 2.3 (2013-02-24, 00:42) * http://lab.hakim.se/reveal-js * MIT licensed * * Copyright (C) 2013 Hakim El Hattab, http://hakim.se */ -var Reveal=function(){"use strict";function E(e){if(!d&&!p){document.body.setAttribute("class","no-transforms");return}window.addEventListener("load",H,!1),A(i,e),x(),T()}function S(){h.theme=document.querySelector("#theme"),h.wrapper=document.querySelector(".reveal"),h.slides=document.querySelector(".reveal .slides");if(!h.wrapper.querySelector(".progress")&&i.progress){var e=document.createElement("div");e.classList.add("progress"),e.innerHTML="",h.wrapper.appendChild(e)}if(!h.wrapper.querySelector(".controls")&&i.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='',h.wrapper.appendChild(t)}if(!h.wrapper.querySelector(".state-background")){var n=document.createElement("div");n.classList.add("state-background"),h.wrapper.appendChild(n)}if(!h.wrapper.querySelector(".pause-overlay")){var r=document.createElement("div");r.classList.add("pause-overlay"),h.wrapper.appendChild(r)}h.progress=document.querySelector(".reveal .progress"),h.progressbar=document.querySelector(".reveal .progress span"),i.controls&&(h.controls=document.querySelector(".reveal .controls"),h.controlsLeft=O(document.querySelectorAll(".navigate-left")),h.controlsRight=O(document.querySelectorAll(".navigate-right")),h.controlsUp=O(document.querySelectorAll(".navigate-up")),h.controlsDown=O(document.querySelectorAll(".navigate-down")),h.controlsPrev=O(document.querySelectorAll(".navigate-prev")),h.controlsNext=O(document.querySelectorAll(".navigate-next")))}function x(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",_,!1),window.addEventListener("orientationchange",_,!1))}function T(){function o(){t.length&&head.js.apply(null,t),N()}var e=[],t=[];for(var n=0,r=i.dependencies.length;n3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),ot&&n[o].classList.add("future"),u.querySelector("section")&&n[o].classList.add("stack")}n[t].classList.add("present");var f=n[t].getAttribute("data-state");f&&(l=l.concat(f.split(" ")));var c=n[t].getAttribute("data-autoslide");c?s=parseInt(c,10):s=i.autoSlide}else t=0;return t}function K(){if(i.progress&&h.progress){var n=O(document.querySelectorAll(t)),r=document.querySelectorAll(e+":not(.stack)").length,s=0;e:for(var o=0;o0,right:o0,down:u0||u>0)t+=o;u>0&&(t+="/"+u)}window.location.hash=t}}}function et(e){var n=o,r=u;if(e){var i=!!e.parentNode.nodeName.match(/section/gi),s=i?e.parentNode:e,a=O(document.querySelectorAll(t));n=Math.max(a.indexOf(s),0),i&&(r=Math.max(O(e.parentNode.querySelectorAll("section")).indexOf(e),0))}return{h:n,v:r}}function tt(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment:not(.visible)");if(e.length)return e[0].classList.add("visible"),D("fragmentshown",{fragment:e[0]}),!0}else{var r=document.querySelectorAll(t+".present .fragment:not(.visible)");if(r.length)return r[0].classList.add("visible"),D("fragmentshown",{fragment:r[0]}),!0}return!1}function nt(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment.visible");if(e.length)return e[e.length-1].classList.remove("visible"),D("fragmenthidden",{fragment:e[e.length-1]}),!0}else{var r=document.querySelectorAll(t+".present .fragment.visible");if(r.length)return r[r.length-1].classList.remove("visible"),D("fragmenthidden",{fragment:r[r.length-1]}),!0}return!1}function rt(){clearTimeout(m),s&&!V()&&!R()&&(m=setTimeout(lt,s))}function it(){clearTimeout(m)}function st(){(G().left&&R()||nt()===!1)&&$(o-1)}function ot(){(G().right&&R()||tt()===!1)&&$(o+1)}function ut(){(G().up&&R()||nt()===!1)&&$(o,u-1)}function at(){(G().down&&R()||tt()===!1)&&$(o,u+1)}function ft(){if(nt()===!1)if(G().up)ut();else{var e=document.querySelector(t+".past:nth-child("+o+")");e&&(u=e.querySelectorAll("section").length+1||undefined,o--,$())}}function lt(){tt()===!1&&(G().down?at():ot()),rt()}function ct(e){var t=document.activeElement,n=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&document.activeElement.contentEditable==="inherit");if(n||e.shiftKey||e.altKey||e.ctrlKey||e.metaKey)return;var r=!0;if(V()&&[66,190,191].indexOf(e.keyCode)===-1)return!1;switch(e.keyCode){case 80:case 33:ft();break;case 78:case 34:lt();break;case 72:case 37:st();break;case 76:case 39:ot();break;case 75:case 38:ut();break;case 74:case 40:at();break;case 36:$(0);break;case 35:$(Number.MAX_VALUE);break;case 32:R()?I():lt();break;case 13:R()?I():r=!1;break;case 66:case 190:case 191:X();break;case 70:U();break;default:r=!1}r?e.preventDefault():e.keyCode===27&&p&&(q(),e.preventDefault()),rt()}function ht(e){w.startX=e.touches[0].clientX,w.startY=e.touches[0].clientY,w.startCount=e.touches.length,e.touches.length===2&&i.overview&&(w.startSpan=M({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:w.startX,y:w.startY}))}function pt(e){if(!w.handled){var t=e.touches[0].clientX,n=e.touches[0].clientY;if(e.touches.length===2&&w.startCount===2&&i.overview){var r=M({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:w.startX,y:w.startY});Math.abs(w.startSpan-r)>w.threshold&&(w.handled=!0,rw.threshold&&Math.abs(s)>Math.abs(o)?(w.handled=!0,st()):s<-w.threshold&&Math.abs(s)>Math.abs(o)?(w.handled=!0,ot()):o>w.threshold?(w.handled=!0,ut()):o<-w.threshold&&(w.handled=!0,at()),e.preventDefault()}}else navigator.userAgent.match(/android/gi)&&e.preventDefault()}function dt(e){w.handled=!1}function vt(e){clearTimeout(v),v=setTimeout(function(){var t=e.detail||-e.wheelDelta;t>0?lt():ft()},100)}function mt(e){e.preventDefault();var n=O(document.querySelectorAll(t)).length,r=Math.floor(e.clientX/h.wrapper.offsetWidth*n);$(r)}function gt(e){e.preventDefault(),st()}function yt(e){e.preventDefault(),ot()}function bt(e){e.preventDefault(),ut()}function wt(e){e.preventDefault(),at()}function Et(e){e.preventDefault(),ft()}function St(e){e.preventDefault(),lt()}function xt(e){Y()}function Tt(e){H()}function Nt(e){if(R()){e.preventDefault(),I();var t=e.target;while(t&&!t.nodeName.match(/section/gi))t=t.parentNode;if(t.nodeName.match(/section/gi)){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);$(n,r)}}}var e=".reveal .slides section",t=".reveal .slides>section",n=".reveal .slides>section.present>section",r=".reveal .slides>section:first-child",i={width:960,height:700,margin:.1,minScale:.2,maxScale:1,controls:!0,progress:!0,history:!1,keyboard:!0,overview:!0,center:!0,touch:!0,loop:!1,rtl:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!0,theme:null,transition:"default",dependencies:[]},s=i.autoSlide,o=0,u=0,a,f,l=[],c=1,h={},p="WebkitPerspective"in document.body.style||"MozPerspective"in document.body.style||"msPerspective"in document.body.style||"OPerspective"in document.body.style||"perspective"in document.body.style,d="WebkitTransform"in document.body.style||"MozTransform"in document.body.style||"msTransform"in document.body.style||"OTransform"in document.body.style||"transform"in document.body.style,v=0,m=0,g=0,y=0,b=0,w={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:E,slide:$,left:st,right:ot,up:ut,down:at,prev:ft,next:lt,prevFragment:nt,nextFragment:tt,navigateTo:$,navigateLeft:st,navigateRight:ot,navigateUp:ut,navigateDown:at,navigatePrev:ft,navigateNext:lt,layout:H,toggleOverview:q,togglePause:X,isOverview:R,isPaused:V,addEventListeners:k,removeEventListeners:L,getIndices:et,getSlide:function(e,n){var r=document.querySelectorAll(t)[e],i=r&&r.querySelectorAll("section");return typeof n!="undefined"?i?i[n]:undefined:r},getPreviousSlide:function(){return a},getCurrentSlide:function(){return f},getScale:function(){return c},getQueryHash:function(){var e={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(t){e[t.split("=").shift()]=t.split("=").pop()}),e},isFirstSlide:function(){return document.querySelector(e+".past")==null?!0:!1},isLastSlide:function(){return f&&f.classList.contains(".stack")?f.querySelector(e+".future")==null?!0:!1:document.querySelector(e+".future")==null?!0:!1},addEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file +var Reveal=function(){"use strict";function E(e){if(!d&&!p){document.body.setAttribute("class","no-transforms");return}window.addEventListener("load",B,!1),A(i,e),x(),T()}function S(){h.theme=document.querySelector("#theme"),h.wrapper=document.querySelector(".reveal"),h.slides=document.querySelector(".reveal .slides");if(!h.wrapper.querySelector(".progress")&&i.progress){var e=document.createElement("div");e.classList.add("progress"),e.innerHTML="",h.wrapper.appendChild(e)}if(!h.wrapper.querySelector(".controls")&&i.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='',h.wrapper.appendChild(t)}if(!h.wrapper.querySelector(".state-background")){var n=document.createElement("div");n.classList.add("state-background"),h.wrapper.appendChild(n)}if(!h.wrapper.querySelector(".pause-overlay")){var r=document.createElement("div");r.classList.add("pause-overlay"),h.wrapper.appendChild(r)}h.progress=document.querySelector(".reveal .progress"),h.progressbar=document.querySelector(".reveal .progress span"),i.controls&&(h.controls=document.querySelector(".reveal .controls"),h.controlsLeft=O(document.querySelectorAll(".navigate-left")),h.controlsRight=O(document.querySelectorAll(".navigate-right")),h.controlsUp=O(document.querySelectorAll(".navigate-up")),h.controlsDown=O(document.querySelectorAll(".navigate-down")),h.controlsPrev=O(document.querySelectorAll(".navigate-prev")),h.controlsNext=O(document.querySelectorAll(".navigate-next")))}function x(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",_,!1),window.addEventListener("orientationchange",_,!1))}function T(){function o(){t.length&&head.js.apply(null,t),N()}var e=[],t=[];for(var n=0,r=i.dependencies.length;n3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),ot&&n[o].classList.add("future"),u.querySelector("section")&&n[o].classList.add("stack")}n[t].classList.add("present");var f=n[t].getAttribute("data-state");f&&(l=l.concat(f.split(" ")));var c=n[t].getAttribute("data-autoslide");c?s=parseInt(c,10):s=i.autoSlide}else t=0;return t}function Q(){if(i.progress&&h.progress){var n=O(document.querySelectorAll(t)),r=document.querySelectorAll(e+":not(.stack)").length,s=0;e:for(var o=0;o0,right:o0,down:u0||u>0)t+=o;u>0&&(t+="/"+u)}window.location.hash=t}}}function tt(e){var n=o,r=u;if(e){var i=!!e.parentNode.nodeName.match(/section/gi),s=i?e.parentNode:e,a=O(document.querySelectorAll(t));n=Math.max(a.indexOf(s),0),i&&(r=Math.max(O(e.parentNode.querySelectorAll("section")).indexOf(e),0))}return{h:n,v:r}}function nt(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment:not(.visible)");if(e.length)return e[0].classList.add("visible"),D("fragmentshown",{fragment:e[0]}),!0}else{var r=document.querySelectorAll(t+".present .fragment:not(.visible)");if(r.length)return r[0].classList.add("visible"),D("fragmentshown",{fragment:r[0]}),!0}return!1}function rt(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment.visible");if(e.length)return e[e.length-1].classList.remove("visible"),D("fragmenthidden",{fragment:e[e.length-1]}),!0}else{var r=document.querySelectorAll(t+".present .fragment.visible");if(r.length)return r[r.length-1].classList.remove("visible"),D("fragmenthidden",{fragment:r[r.length-1]}),!0}return!1}function it(){clearTimeout(m),s&&!$()&&!U()&&(m=setTimeout(ct,s))}function st(){clearTimeout(m)}function ot(){(Y().left&&U()||rt()===!1)&&J(o-1)}function ut(){(Y().right&&U()||nt()===!1)&&J(o+1)}function at(){(Y().up&&U()||rt()===!1)&&J(o,u-1)}function ft(){(Y().down&&U()||nt()===!1)&&J(o,u+1)}function lt(){if(rt()===!1)if(Y().up)at();else{var e=document.querySelector(t+".past:nth-child("+o+")");e&&(u=e.querySelectorAll("section").length+1||undefined,o--,J())}}function ct(){nt()===!1&&(Y().down?ft():ut()),it()}function ht(e){var t=document.activeElement,n=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&document.activeElement.contentEditable==="inherit");if(n||e.shiftKey||e.altKey||e.ctrlKey||e.metaKey)return;var r=!0;if($()&&[66,190,191].indexOf(e.keyCode)===-1)return!1;switch(e.keyCode){case 80:case 33:lt();break;case 78:case 34:ct();break;case 72:case 37:ot();break;case 76:case 39:ut();break;case 75:case 38:at();break;case 74:case 40:ft();break;case 36:J(0);break;case 35:J(Number.MAX_VALUE);break;case 32:U()?q():ct();break;case 13:U()?q():r=!1;break;case 66:case 190:case 191:V();break;case 70:z();break;default:r=!1}r?e.preventDefault():e.keyCode===27&&p&&(R(),e.preventDefault()),it()}function pt(e){w.startX=e.touches[0].clientX,w.startY=e.touches[0].clientY,w.startCount=e.touches.length,e.touches.length===2&&i.overview&&(w.startSpan=M({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:w.startX,y:w.startY}))}function dt(e){if(!w.handled){var t=e.touches[0].clientX,n=e.touches[0].clientY;if(e.touches.length===2&&w.startCount===2&&i.overview){var r=M({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:w.startX,y:w.startY});Math.abs(w.startSpan-r)>w.threshold&&(w.handled=!0,rw.threshold&&Math.abs(s)>Math.abs(o)?(w.handled=!0,ot()):s<-w.threshold&&Math.abs(s)>Math.abs(o)?(w.handled=!0,ut()):o>w.threshold?(w.handled=!0,at()):o<-w.threshold&&(w.handled=!0,ft()),e.preventDefault()}}else navigator.userAgent.match(/android/gi)&&e.preventDefault()}function vt(e){w.handled=!1}function mt(e){clearTimeout(v),v=setTimeout(function(){var t=e.detail||-e.wheelDelta;t>0?ct():lt()},100)}function gt(e){e.preventDefault();var n=O(document.querySelectorAll(t)).length,r=Math.floor(e.clientX/h.wrapper.offsetWidth*n);J(r)}function yt(e){e.preventDefault(),ot()}function bt(e){e.preventDefault(),ut()}function wt(e){e.preventDefault(),at()}function Et(e){e.preventDefault(),ft()}function St(e){e.preventDefault(),lt()}function xt(e){e.preventDefault(),ct()}function Tt(e){Z()}function Nt(e){B()}function Ct(e){if(U()){e.preventDefault(),q();var t=e.target;while(t&&!t.nodeName.match(/section/gi))t=t.parentNode;if(t.nodeName.match(/section/gi)){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);J(n,r)}}}var e=".reveal .slides section",t=".reveal .slides>section",n=".reveal .slides>section.present>section",r=".reveal .slides>section:first-child",i={width:960,height:700,margin:.1,minScale:.2,maxScale:1,controls:!0,progress:!0,history:!1,keyboard:!0,overview:!0,center:!0,touch:!0,loop:!1,rtl:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!0,theme:null,transition:"default",dependencies:[]},s=i.autoSlide,o=0,u=0,a,f,l=[],c=1,h={},p="WebkitPerspective"in document.body.style||"MozPerspective"in document.body.style||"msPerspective"in document.body.style||"OPerspective"in document.body.style||"perspective"in document.body.style,d="WebkitTransform"in document.body.style||"MozTransform"in document.body.style||"msTransform"in document.body.style||"OTransform"in document.body.style||"transform"in document.body.style,v=0,m=0,g=0,y=0,b=0,w={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:E,configure:C,slide:J,left:ot,right:ut,up:at,down:ft,prev:lt,next:ct,prevFragment:rt,nextFragment:nt,navigateTo:J,navigateLeft:ot,navigateRight:ut,navigateUp:at,navigateDown:ft,navigatePrev:lt,navigateNext:ct,layout:B,toggleOverview:R,togglePause:V,isOverview:U,isPaused:$,addEventListeners:k,removeEventListeners:L,getIndices:tt,getSlide:function(e,n){var r=document.querySelectorAll(t)[e],i=r&&r.querySelectorAll("section");return typeof n!="undefined"?i?i[n]:undefined:r},getPreviousSlide:function(){return a},getCurrentSlide:function(){return f},getScale:function(){return c},getQueryHash:function(){var e={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(t){e[t.split("=").shift()]=t.split("=").pop()}),e},isFirstSlide:function(){return document.querySelector(e+".past")==null?!0:!1},isLastSlide:function(){return f&&f.classList.contains(".stack")?f.querySelector(e+".future")==null?!0:!1:document.querySelector(e+".future")==null?!0:!1},addEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file From 40759435e48891f32e72b8da8c7df332976eef48 Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Sun, 24 Feb 2013 00:52:54 -0500 Subject: [PATCH 07/22] prevent overview click events after calling Reveal.removeEventListeners --- js/reveal.js | 9 ++++++++- js/reveal.min.js | 4 ++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/js/reveal.js b/js/reveal.js index a559090..5c658ad 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -129,6 +129,9 @@ var Reveal = (function(){ // A delay used to deactivate the overview mode deactivateOverviewTimeout = 0, + // Flags if the interaction event listeners are bound + eventsAreBound = false, + // Holds information about the currently ongoing touch input touch = { startX: 0, @@ -390,6 +393,8 @@ var Reveal = (function(){ */ function addEventListeners() { + eventsAreBound = true; + window.addEventListener( 'hashchange', onWindowHashChange, false ); window.addEventListener( 'resize', onWindowResize, false ); @@ -424,6 +429,8 @@ var Reveal = (function(){ */ function removeEventListeners() { + eventsAreBound = false; + document.removeEventListener( 'keydown', onDocumentKeyDown, false ); window.removeEventListener( 'hashchange', onWindowHashChange, false ); window.removeEventListener( 'resize', onWindowResize, false ); @@ -1801,7 +1808,7 @@ var Reveal = (function(){ // TODO There's a bug here where the event listeners are not // removed after deactivating the overview. - if( isOverview() ) { + if( eventsAreBound && isOverview() ) { event.preventDefault(); deactivateOverview(); diff --git a/js/reveal.min.js b/js/reveal.min.js index e1fb8aa..a37d1ff 100644 --- a/js/reveal.min.js +++ b/js/reveal.min.js @@ -1,8 +1,8 @@ /*! - * reveal.js 2.3 (2013-02-24, 00:42) + * reveal.js 2.3 (2013-02-24, 00:51) * http://lab.hakim.se/reveal-js * MIT licensed * * Copyright (C) 2013 Hakim El Hattab, http://hakim.se */ -var Reveal=function(){"use strict";function E(e){if(!d&&!p){document.body.setAttribute("class","no-transforms");return}window.addEventListener("load",B,!1),A(i,e),x(),T()}function S(){h.theme=document.querySelector("#theme"),h.wrapper=document.querySelector(".reveal"),h.slides=document.querySelector(".reveal .slides");if(!h.wrapper.querySelector(".progress")&&i.progress){var e=document.createElement("div");e.classList.add("progress"),e.innerHTML="",h.wrapper.appendChild(e)}if(!h.wrapper.querySelector(".controls")&&i.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='',h.wrapper.appendChild(t)}if(!h.wrapper.querySelector(".state-background")){var n=document.createElement("div");n.classList.add("state-background"),h.wrapper.appendChild(n)}if(!h.wrapper.querySelector(".pause-overlay")){var r=document.createElement("div");r.classList.add("pause-overlay"),h.wrapper.appendChild(r)}h.progress=document.querySelector(".reveal .progress"),h.progressbar=document.querySelector(".reveal .progress span"),i.controls&&(h.controls=document.querySelector(".reveal .controls"),h.controlsLeft=O(document.querySelectorAll(".navigate-left")),h.controlsRight=O(document.querySelectorAll(".navigate-right")),h.controlsUp=O(document.querySelectorAll(".navigate-up")),h.controlsDown=O(document.querySelectorAll(".navigate-down")),h.controlsPrev=O(document.querySelectorAll(".navigate-prev")),h.controlsNext=O(document.querySelectorAll(".navigate-next")))}function x(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",_,!1),window.addEventListener("orientationchange",_,!1))}function T(){function o(){t.length&&head.js.apply(null,t),N()}var e=[],t=[];for(var n=0,r=i.dependencies.length;n3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),ot&&n[o].classList.add("future"),u.querySelector("section")&&n[o].classList.add("stack")}n[t].classList.add("present");var f=n[t].getAttribute("data-state");f&&(l=l.concat(f.split(" ")));var c=n[t].getAttribute("data-autoslide");c?s=parseInt(c,10):s=i.autoSlide}else t=0;return t}function Q(){if(i.progress&&h.progress){var n=O(document.querySelectorAll(t)),r=document.querySelectorAll(e+":not(.stack)").length,s=0;e:for(var o=0;o0,right:o0,down:u0||u>0)t+=o;u>0&&(t+="/"+u)}window.location.hash=t}}}function tt(e){var n=o,r=u;if(e){var i=!!e.parentNode.nodeName.match(/section/gi),s=i?e.parentNode:e,a=O(document.querySelectorAll(t));n=Math.max(a.indexOf(s),0),i&&(r=Math.max(O(e.parentNode.querySelectorAll("section")).indexOf(e),0))}return{h:n,v:r}}function nt(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment:not(.visible)");if(e.length)return e[0].classList.add("visible"),D("fragmentshown",{fragment:e[0]}),!0}else{var r=document.querySelectorAll(t+".present .fragment:not(.visible)");if(r.length)return r[0].classList.add("visible"),D("fragmentshown",{fragment:r[0]}),!0}return!1}function rt(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment.visible");if(e.length)return e[e.length-1].classList.remove("visible"),D("fragmenthidden",{fragment:e[e.length-1]}),!0}else{var r=document.querySelectorAll(t+".present .fragment.visible");if(r.length)return r[r.length-1].classList.remove("visible"),D("fragmenthidden",{fragment:r[r.length-1]}),!0}return!1}function it(){clearTimeout(m),s&&!$()&&!U()&&(m=setTimeout(ct,s))}function st(){clearTimeout(m)}function ot(){(Y().left&&U()||rt()===!1)&&J(o-1)}function ut(){(Y().right&&U()||nt()===!1)&&J(o+1)}function at(){(Y().up&&U()||rt()===!1)&&J(o,u-1)}function ft(){(Y().down&&U()||nt()===!1)&&J(o,u+1)}function lt(){if(rt()===!1)if(Y().up)at();else{var e=document.querySelector(t+".past:nth-child("+o+")");e&&(u=e.querySelectorAll("section").length+1||undefined,o--,J())}}function ct(){nt()===!1&&(Y().down?ft():ut()),it()}function ht(e){var t=document.activeElement,n=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&document.activeElement.contentEditable==="inherit");if(n||e.shiftKey||e.altKey||e.ctrlKey||e.metaKey)return;var r=!0;if($()&&[66,190,191].indexOf(e.keyCode)===-1)return!1;switch(e.keyCode){case 80:case 33:lt();break;case 78:case 34:ct();break;case 72:case 37:ot();break;case 76:case 39:ut();break;case 75:case 38:at();break;case 74:case 40:ft();break;case 36:J(0);break;case 35:J(Number.MAX_VALUE);break;case 32:U()?q():ct();break;case 13:U()?q():r=!1;break;case 66:case 190:case 191:V();break;case 70:z();break;default:r=!1}r?e.preventDefault():e.keyCode===27&&p&&(R(),e.preventDefault()),it()}function pt(e){w.startX=e.touches[0].clientX,w.startY=e.touches[0].clientY,w.startCount=e.touches.length,e.touches.length===2&&i.overview&&(w.startSpan=M({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:w.startX,y:w.startY}))}function dt(e){if(!w.handled){var t=e.touches[0].clientX,n=e.touches[0].clientY;if(e.touches.length===2&&w.startCount===2&&i.overview){var r=M({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:w.startX,y:w.startY});Math.abs(w.startSpan-r)>w.threshold&&(w.handled=!0,rw.threshold&&Math.abs(s)>Math.abs(o)?(w.handled=!0,ot()):s<-w.threshold&&Math.abs(s)>Math.abs(o)?(w.handled=!0,ut()):o>w.threshold?(w.handled=!0,at()):o<-w.threshold&&(w.handled=!0,ft()),e.preventDefault()}}else navigator.userAgent.match(/android/gi)&&e.preventDefault()}function vt(e){w.handled=!1}function mt(e){clearTimeout(v),v=setTimeout(function(){var t=e.detail||-e.wheelDelta;t>0?ct():lt()},100)}function gt(e){e.preventDefault();var n=O(document.querySelectorAll(t)).length,r=Math.floor(e.clientX/h.wrapper.offsetWidth*n);J(r)}function yt(e){e.preventDefault(),ot()}function bt(e){e.preventDefault(),ut()}function wt(e){e.preventDefault(),at()}function Et(e){e.preventDefault(),ft()}function St(e){e.preventDefault(),lt()}function xt(e){e.preventDefault(),ct()}function Tt(e){Z()}function Nt(e){B()}function Ct(e){if(U()){e.preventDefault(),q();var t=e.target;while(t&&!t.nodeName.match(/section/gi))t=t.parentNode;if(t.nodeName.match(/section/gi)){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);J(n,r)}}}var e=".reveal .slides section",t=".reveal .slides>section",n=".reveal .slides>section.present>section",r=".reveal .slides>section:first-child",i={width:960,height:700,margin:.1,minScale:.2,maxScale:1,controls:!0,progress:!0,history:!1,keyboard:!0,overview:!0,center:!0,touch:!0,loop:!1,rtl:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!0,theme:null,transition:"default",dependencies:[]},s=i.autoSlide,o=0,u=0,a,f,l=[],c=1,h={},p="WebkitPerspective"in document.body.style||"MozPerspective"in document.body.style||"msPerspective"in document.body.style||"OPerspective"in document.body.style||"perspective"in document.body.style,d="WebkitTransform"in document.body.style||"MozTransform"in document.body.style||"msTransform"in document.body.style||"OTransform"in document.body.style||"transform"in document.body.style,v=0,m=0,g=0,y=0,b=0,w={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:E,configure:C,slide:J,left:ot,right:ut,up:at,down:ft,prev:lt,next:ct,prevFragment:rt,nextFragment:nt,navigateTo:J,navigateLeft:ot,navigateRight:ut,navigateUp:at,navigateDown:ft,navigatePrev:lt,navigateNext:ct,layout:B,toggleOverview:R,togglePause:V,isOverview:U,isPaused:$,addEventListeners:k,removeEventListeners:L,getIndices:tt,getSlide:function(e,n){var r=document.querySelectorAll(t)[e],i=r&&r.querySelectorAll("section");return typeof n!="undefined"?i?i[n]:undefined:r},getPreviousSlide:function(){return a},getCurrentSlide:function(){return f},getScale:function(){return c},getQueryHash:function(){var e={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(t){e[t.split("=").shift()]=t.split("=").pop()}),e},isFirstSlide:function(){return document.querySelector(e+".past")==null?!0:!1},isLastSlide:function(){return f&&f.classList.contains(".stack")?f.querySelector(e+".future")==null?!0:!1:document.querySelector(e+".future")==null?!0:!1},addEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file +var Reveal=function(){"use strict";function S(e){if(!d&&!p){document.body.setAttribute("class","no-transforms");return}window.addEventListener("load",j,!1),O(i,e),T(),N()}function x(){h.theme=document.querySelector("#theme"),h.wrapper=document.querySelector(".reveal"),h.slides=document.querySelector(".reveal .slides");if(!h.wrapper.querySelector(".progress")&&i.progress){var e=document.createElement("div");e.classList.add("progress"),e.innerHTML="",h.wrapper.appendChild(e)}if(!h.wrapper.querySelector(".controls")&&i.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='',h.wrapper.appendChild(t)}if(!h.wrapper.querySelector(".state-background")){var n=document.createElement("div");n.classList.add("state-background"),h.wrapper.appendChild(n)}if(!h.wrapper.querySelector(".pause-overlay")){var r=document.createElement("div");r.classList.add("pause-overlay"),h.wrapper.appendChild(r)}h.progress=document.querySelector(".reveal .progress"),h.progressbar=document.querySelector(".reveal .progress span"),i.controls&&(h.controls=document.querySelector(".reveal .controls"),h.controlsLeft=M(document.querySelectorAll(".navigate-left")),h.controlsRight=M(document.querySelectorAll(".navigate-right")),h.controlsUp=M(document.querySelectorAll(".navigate-up")),h.controlsDown=M(document.querySelectorAll(".navigate-down")),h.controlsPrev=M(document.querySelectorAll(".navigate-prev")),h.controlsNext=M(document.querySelectorAll(".navigate-next")))}function T(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",D,!1),window.addEventListener("orientationchange",D,!1))}function N(){function o(){t.length&&head.js.apply(null,t),C()}var e=[],t=[];for(var n=0,r=i.dependencies.length;n3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),ot&&n[o].classList.add("future"),u.querySelector("section")&&n[o].classList.add("stack")}n[t].classList.add("present");var f=n[t].getAttribute("data-state");f&&(l=l.concat(f.split(" ")));var c=n[t].getAttribute("data-autoslide");c?s=parseInt(c,10):s=i.autoSlide}else t=0;return t}function G(){if(i.progress&&h.progress){var n=M(document.querySelectorAll(t)),r=document.querySelectorAll(e+":not(.stack)").length,s=0;e:for(var o=0;o0,right:o0,down:u0||u>0)t+=o;u>0&&(t+="/"+u)}window.location.hash=t}}}function nt(e){var n=o,r=u;if(e){var i=!!e.parentNode.nodeName.match(/section/gi),s=i?e.parentNode:e,a=M(document.querySelectorAll(t));n=Math.max(a.indexOf(s),0),i&&(r=Math.max(M(e.parentNode.querySelectorAll("section")).indexOf(e),0))}return{h:n,v:r}}function rt(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment:not(.visible)");if(e.length)return e[0].classList.add("visible"),P("fragmentshown",{fragment:e[0]}),!0}else{var r=document.querySelectorAll(t+".present .fragment:not(.visible)");if(r.length)return r[0].classList.add("visible"),P("fragmentshown",{fragment:r[0]}),!0}return!1}function it(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment.visible");if(e.length)return e[e.length-1].classList.remove("visible"),P("fragmenthidden",{fragment:e[e.length-1]}),!0}else{var r=document.querySelectorAll(t+".present .fragment.visible");if(r.length)return r[r.length-1].classList.remove("visible"),P("fragmenthidden",{fragment:r[r.length-1]}),!0}return!1}function st(){clearTimeout(m),s&&!J()&&!z()&&(m=setTimeout(ht,s))}function ot(){clearTimeout(m)}function ut(){(Z().left&&z()||it()===!1)&&K(o-1)}function at(){(Z().right&&z()||rt()===!1)&&K(o+1)}function ft(){(Z().up&&z()||it()===!1)&&K(o,u-1)}function lt(){(Z().down&&z()||rt()===!1)&&K(o,u+1)}function ct(){if(it()===!1)if(Z().up)ft();else{var e=document.querySelector(t+".past:nth-child("+o+")");e&&(u=e.querySelectorAll("section").length+1||undefined,o--,K())}}function ht(){rt()===!1&&(Z().down?lt():at()),st()}function pt(e){var t=document.activeElement,n=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&document.activeElement.contentEditable==="inherit");if(n||e.shiftKey||e.altKey||e.ctrlKey||e.metaKey)return;var r=!0;if(J()&&[66,190,191].indexOf(e.keyCode)===-1)return!1;switch(e.keyCode){case 80:case 33:ct();break;case 78:case 34:ht();break;case 72:case 37:ut();break;case 76:case 39:at();break;case 75:case 38:ft();break;case 74:case 40:lt();break;case 36:K(0);break;case 35:K(Number.MAX_VALUE);break;case 32:z()?R():ht();break;case 13:z()?R():r=!1;break;case 66:case 190:case 191:$();break;case 70:W();break;default:r=!1}r?e.preventDefault():e.keyCode===27&&p&&(U(),e.preventDefault()),st()}function dt(e){E.startX=e.touches[0].clientX,E.startY=e.touches[0].clientY,E.startCount=e.touches.length,e.touches.length===2&&i.overview&&(E.startSpan=_({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:E.startX,y:E.startY}))}function vt(e){if(!E.handled){var t=e.touches[0].clientX,n=e.touches[0].clientY;if(e.touches.length===2&&E.startCount===2&&i.overview){var r=_({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:E.startX,y:E.startY});Math.abs(E.startSpan-r)>E.threshold&&(E.handled=!0,rE.threshold&&Math.abs(s)>Math.abs(o)?(E.handled=!0,ut()):s<-E.threshold&&Math.abs(s)>Math.abs(o)?(E.handled=!0,at()):o>E.threshold?(E.handled=!0,ft()):o<-E.threshold&&(E.handled=!0,lt()),e.preventDefault()}}else navigator.userAgent.match(/android/gi)&&e.preventDefault()}function mt(e){E.handled=!1}function gt(e){clearTimeout(v),v=setTimeout(function(){var t=e.detail||-e.wheelDelta;t>0?ht():ct()},100)}function yt(e){e.preventDefault();var n=M(document.querySelectorAll(t)).length,r=Math.floor(e.clientX/h.wrapper.offsetWidth*n);K(r)}function bt(e){e.preventDefault(),ut()}function wt(e){e.preventDefault(),at()}function Et(e){e.preventDefault(),ft()}function St(e){e.preventDefault(),lt()}function xt(e){e.preventDefault(),ct()}function Tt(e){e.preventDefault(),ht()}function Nt(e){et()}function Ct(e){j()}function kt(e){if(w&&z()){e.preventDefault(),R();var t=e.target;while(t&&!t.nodeName.match(/section/gi))t=t.parentNode;if(t.nodeName.match(/section/gi)){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);K(n,r)}}}var e=".reveal .slides section",t=".reveal .slides>section",n=".reveal .slides>section.present>section",r=".reveal .slides>section:first-child",i={width:960,height:700,margin:.1,minScale:.2,maxScale:1,controls:!0,progress:!0,history:!1,keyboard:!0,overview:!0,center:!0,touch:!0,loop:!1,rtl:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!0,theme:null,transition:"default",dependencies:[]},s=i.autoSlide,o=0,u=0,a,f,l=[],c=1,h={},p="WebkitPerspective"in document.body.style||"MozPerspective"in document.body.style||"msPerspective"in document.body.style||"OPerspective"in document.body.style||"perspective"in document.body.style,d="WebkitTransform"in document.body.style||"MozTransform"in document.body.style||"msTransform"in document.body.style||"OTransform"in document.body.style||"transform"in document.body.style,v=0,m=0,g=0,y=0,b=0,w=!1,E={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:S,configure:k,slide:K,left:ut,right:at,up:ft,down:lt,prev:ct,next:ht,prevFragment:it,nextFragment:rt,navigateTo:K,navigateLeft:ut,navigateRight:at,navigateUp:ft,navigateDown:lt,navigatePrev:ct,navigateNext:ht,layout:j,toggleOverview:U,togglePause:$,isOverview:z,isPaused:J,addEventListeners:L,removeEventListeners:A,getIndices:nt,getSlide:function(e,n){var r=document.querySelectorAll(t)[e],i=r&&r.querySelectorAll("section");return typeof n!="undefined"?i?i[n]:undefined:r},getPreviousSlide:function(){return a},getCurrentSlide:function(){return f},getScale:function(){return c},getQueryHash:function(){var e={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(t){e[t.split("=").shift()]=t.split("=").pop()}),e},isFirstSlide:function(){return document.querySelector(e+".past")==null?!0:!1},isLastSlide:function(){return f&&f.classList.contains(".stack")?f.querySelector(e+".future")==null?!0:!1:document.querySelector(e+".future")==null?!0:!1},addEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file From f095af212ee2b6009412a89fe17ae46860efd8df Mon Sep 17 00:00:00 2001 From: asmod3us <4sm0d3us@gmail.com> Date: Tue, 26 Feb 2013 16:06:18 +0100 Subject: [PATCH 08/22] Update plugin/markdown/markdown.js Use textContent instead of innerHTML to prevent encoding of certain characters in Markdown code blocks. --- plugin/markdown/markdown.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugin/markdown/markdown.js b/plugin/markdown/markdown.js index ae4d08b..39e1168 100644 --- a/plugin/markdown/markdown.js +++ b/plugin/markdown/markdown.js @@ -11,7 +11,7 @@ var template = section.querySelector( 'script' ); // strip leading whitespace so it isn't evaluated as code - var text = ( template || section ).innerHTML; + var text = ( template || section ).textContent; var leadingWs = text.match(/^\n?(\s*)/)[1].length, leadingTabs = text.match(/^\n?(\t*)/)[1].length; From 3b822c33e42c562403f057a98f7bc193b5c0327d Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Tue, 26 Feb 2013 12:08:04 -0500 Subject: [PATCH 09/22] disabled overview clicks on slides with disabled class --- index.html | 46 ++++++++++++++++++++++++++++++++++++++++++++++ js/reveal.js | 16 ++++++++++------ js/reveal.min.js | 4 ++-- 3 files changed, 58 insertions(+), 8 deletions(-) diff --git a/index.html b/index.html index bc2f360..0608eb8 100644 --- a/index.html +++ b/index.html @@ -373,5 +373,51 @@ function linkify( selector ) { + + + + + + + + + + + + + + diff --git a/js/reveal.js b/js/reveal.js index 5c658ad..f47006f 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -1811,19 +1811,23 @@ var Reveal = (function(){ if( eventsAreBound && isOverview() ) { event.preventDefault(); - deactivateOverview(); - var element = event.target; while( element && !element.nodeName.match( /section/gi ) ) { element = element.parentNode; } - if( element.nodeName.match( /section/gi ) ) { - var h = parseInt( element.getAttribute( 'data-index-h' ), 10 ), - v = parseInt( element.getAttribute( 'data-index-v' ), 10 ); + if( element && !element.classList.contains( 'disabled' ) ) { + + deactivateOverview(); + + if( element.nodeName.match( /section/gi ) ) { + var h = parseInt( element.getAttribute( 'data-index-h' ), 10 ), + v = parseInt( element.getAttribute( 'data-index-v' ), 10 ); + + slide( h, v ); + } - slide( h, v ); } } diff --git a/js/reveal.min.js b/js/reveal.min.js index a37d1ff..5c19b22 100644 --- a/js/reveal.min.js +++ b/js/reveal.min.js @@ -1,8 +1,8 @@ /*! - * reveal.js 2.3 (2013-02-24, 00:51) + * reveal.js 2.3 (2013-02-24, 11:58) * http://lab.hakim.se/reveal-js * MIT licensed * * Copyright (C) 2013 Hakim El Hattab, http://hakim.se */ -var Reveal=function(){"use strict";function S(e){if(!d&&!p){document.body.setAttribute("class","no-transforms");return}window.addEventListener("load",j,!1),O(i,e),T(),N()}function x(){h.theme=document.querySelector("#theme"),h.wrapper=document.querySelector(".reveal"),h.slides=document.querySelector(".reveal .slides");if(!h.wrapper.querySelector(".progress")&&i.progress){var e=document.createElement("div");e.classList.add("progress"),e.innerHTML="",h.wrapper.appendChild(e)}if(!h.wrapper.querySelector(".controls")&&i.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='',h.wrapper.appendChild(t)}if(!h.wrapper.querySelector(".state-background")){var n=document.createElement("div");n.classList.add("state-background"),h.wrapper.appendChild(n)}if(!h.wrapper.querySelector(".pause-overlay")){var r=document.createElement("div");r.classList.add("pause-overlay"),h.wrapper.appendChild(r)}h.progress=document.querySelector(".reveal .progress"),h.progressbar=document.querySelector(".reveal .progress span"),i.controls&&(h.controls=document.querySelector(".reveal .controls"),h.controlsLeft=M(document.querySelectorAll(".navigate-left")),h.controlsRight=M(document.querySelectorAll(".navigate-right")),h.controlsUp=M(document.querySelectorAll(".navigate-up")),h.controlsDown=M(document.querySelectorAll(".navigate-down")),h.controlsPrev=M(document.querySelectorAll(".navigate-prev")),h.controlsNext=M(document.querySelectorAll(".navigate-next")))}function T(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",D,!1),window.addEventListener("orientationchange",D,!1))}function N(){function o(){t.length&&head.js.apply(null,t),C()}var e=[],t=[];for(var n=0,r=i.dependencies.length;n3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),ot&&n[o].classList.add("future"),u.querySelector("section")&&n[o].classList.add("stack")}n[t].classList.add("present");var f=n[t].getAttribute("data-state");f&&(l=l.concat(f.split(" ")));var c=n[t].getAttribute("data-autoslide");c?s=parseInt(c,10):s=i.autoSlide}else t=0;return t}function G(){if(i.progress&&h.progress){var n=M(document.querySelectorAll(t)),r=document.querySelectorAll(e+":not(.stack)").length,s=0;e:for(var o=0;o0,right:o0,down:u0||u>0)t+=o;u>0&&(t+="/"+u)}window.location.hash=t}}}function nt(e){var n=o,r=u;if(e){var i=!!e.parentNode.nodeName.match(/section/gi),s=i?e.parentNode:e,a=M(document.querySelectorAll(t));n=Math.max(a.indexOf(s),0),i&&(r=Math.max(M(e.parentNode.querySelectorAll("section")).indexOf(e),0))}return{h:n,v:r}}function rt(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment:not(.visible)");if(e.length)return e[0].classList.add("visible"),P("fragmentshown",{fragment:e[0]}),!0}else{var r=document.querySelectorAll(t+".present .fragment:not(.visible)");if(r.length)return r[0].classList.add("visible"),P("fragmentshown",{fragment:r[0]}),!0}return!1}function it(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment.visible");if(e.length)return e[e.length-1].classList.remove("visible"),P("fragmenthidden",{fragment:e[e.length-1]}),!0}else{var r=document.querySelectorAll(t+".present .fragment.visible");if(r.length)return r[r.length-1].classList.remove("visible"),P("fragmenthidden",{fragment:r[r.length-1]}),!0}return!1}function st(){clearTimeout(m),s&&!J()&&!z()&&(m=setTimeout(ht,s))}function ot(){clearTimeout(m)}function ut(){(Z().left&&z()||it()===!1)&&K(o-1)}function at(){(Z().right&&z()||rt()===!1)&&K(o+1)}function ft(){(Z().up&&z()||it()===!1)&&K(o,u-1)}function lt(){(Z().down&&z()||rt()===!1)&&K(o,u+1)}function ct(){if(it()===!1)if(Z().up)ft();else{var e=document.querySelector(t+".past:nth-child("+o+")");e&&(u=e.querySelectorAll("section").length+1||undefined,o--,K())}}function ht(){rt()===!1&&(Z().down?lt():at()),st()}function pt(e){var t=document.activeElement,n=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&document.activeElement.contentEditable==="inherit");if(n||e.shiftKey||e.altKey||e.ctrlKey||e.metaKey)return;var r=!0;if(J()&&[66,190,191].indexOf(e.keyCode)===-1)return!1;switch(e.keyCode){case 80:case 33:ct();break;case 78:case 34:ht();break;case 72:case 37:ut();break;case 76:case 39:at();break;case 75:case 38:ft();break;case 74:case 40:lt();break;case 36:K(0);break;case 35:K(Number.MAX_VALUE);break;case 32:z()?R():ht();break;case 13:z()?R():r=!1;break;case 66:case 190:case 191:$();break;case 70:W();break;default:r=!1}r?e.preventDefault():e.keyCode===27&&p&&(U(),e.preventDefault()),st()}function dt(e){E.startX=e.touches[0].clientX,E.startY=e.touches[0].clientY,E.startCount=e.touches.length,e.touches.length===2&&i.overview&&(E.startSpan=_({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:E.startX,y:E.startY}))}function vt(e){if(!E.handled){var t=e.touches[0].clientX,n=e.touches[0].clientY;if(e.touches.length===2&&E.startCount===2&&i.overview){var r=_({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:E.startX,y:E.startY});Math.abs(E.startSpan-r)>E.threshold&&(E.handled=!0,rE.threshold&&Math.abs(s)>Math.abs(o)?(E.handled=!0,ut()):s<-E.threshold&&Math.abs(s)>Math.abs(o)?(E.handled=!0,at()):o>E.threshold?(E.handled=!0,ft()):o<-E.threshold&&(E.handled=!0,lt()),e.preventDefault()}}else navigator.userAgent.match(/android/gi)&&e.preventDefault()}function mt(e){E.handled=!1}function gt(e){clearTimeout(v),v=setTimeout(function(){var t=e.detail||-e.wheelDelta;t>0?ht():ct()},100)}function yt(e){e.preventDefault();var n=M(document.querySelectorAll(t)).length,r=Math.floor(e.clientX/h.wrapper.offsetWidth*n);K(r)}function bt(e){e.preventDefault(),ut()}function wt(e){e.preventDefault(),at()}function Et(e){e.preventDefault(),ft()}function St(e){e.preventDefault(),lt()}function xt(e){e.preventDefault(),ct()}function Tt(e){e.preventDefault(),ht()}function Nt(e){et()}function Ct(e){j()}function kt(e){if(w&&z()){e.preventDefault(),R();var t=e.target;while(t&&!t.nodeName.match(/section/gi))t=t.parentNode;if(t.nodeName.match(/section/gi)){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);K(n,r)}}}var e=".reveal .slides section",t=".reveal .slides>section",n=".reveal .slides>section.present>section",r=".reveal .slides>section:first-child",i={width:960,height:700,margin:.1,minScale:.2,maxScale:1,controls:!0,progress:!0,history:!1,keyboard:!0,overview:!0,center:!0,touch:!0,loop:!1,rtl:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!0,theme:null,transition:"default",dependencies:[]},s=i.autoSlide,o=0,u=0,a,f,l=[],c=1,h={},p="WebkitPerspective"in document.body.style||"MozPerspective"in document.body.style||"msPerspective"in document.body.style||"OPerspective"in document.body.style||"perspective"in document.body.style,d="WebkitTransform"in document.body.style||"MozTransform"in document.body.style||"msTransform"in document.body.style||"OTransform"in document.body.style||"transform"in document.body.style,v=0,m=0,g=0,y=0,b=0,w=!1,E={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:S,configure:k,slide:K,left:ut,right:at,up:ft,down:lt,prev:ct,next:ht,prevFragment:it,nextFragment:rt,navigateTo:K,navigateLeft:ut,navigateRight:at,navigateUp:ft,navigateDown:lt,navigatePrev:ct,navigateNext:ht,layout:j,toggleOverview:U,togglePause:$,isOverview:z,isPaused:J,addEventListeners:L,removeEventListeners:A,getIndices:nt,getSlide:function(e,n){var r=document.querySelectorAll(t)[e],i=r&&r.querySelectorAll("section");return typeof n!="undefined"?i?i[n]:undefined:r},getPreviousSlide:function(){return a},getCurrentSlide:function(){return f},getScale:function(){return c},getQueryHash:function(){var e={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(t){e[t.split("=").shift()]=t.split("=").pop()}),e},isFirstSlide:function(){return document.querySelector(e+".past")==null?!0:!1},isLastSlide:function(){return f&&f.classList.contains(".stack")?f.querySelector(e+".future")==null?!0:!1:document.querySelector(e+".future")==null?!0:!1},addEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file +var Reveal=function(){"use strict";function S(e){if(!d&&!p){document.body.setAttribute("class","no-transforms");return}window.addEventListener("load",j,!1),O(i,e),T(),N()}function x(){h.theme=document.querySelector("#theme"),h.wrapper=document.querySelector(".reveal"),h.slides=document.querySelector(".reveal .slides");if(!h.wrapper.querySelector(".progress")&&i.progress){var e=document.createElement("div");e.classList.add("progress"),e.innerHTML="",h.wrapper.appendChild(e)}if(!h.wrapper.querySelector(".controls")&&i.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='',h.wrapper.appendChild(t)}if(!h.wrapper.querySelector(".state-background")){var n=document.createElement("div");n.classList.add("state-background"),h.wrapper.appendChild(n)}if(!h.wrapper.querySelector(".pause-overlay")){var r=document.createElement("div");r.classList.add("pause-overlay"),h.wrapper.appendChild(r)}h.progress=document.querySelector(".reveal .progress"),h.progressbar=document.querySelector(".reveal .progress span"),i.controls&&(h.controls=document.querySelector(".reveal .controls"),h.controlsLeft=M(document.querySelectorAll(".navigate-left")),h.controlsRight=M(document.querySelectorAll(".navigate-right")),h.controlsUp=M(document.querySelectorAll(".navigate-up")),h.controlsDown=M(document.querySelectorAll(".navigate-down")),h.controlsPrev=M(document.querySelectorAll(".navigate-prev")),h.controlsNext=M(document.querySelectorAll(".navigate-next")))}function T(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",D,!1),window.addEventListener("orientationchange",D,!1))}function N(){function o(){t.length&&head.js.apply(null,t),C()}var e=[],t=[];for(var n=0,r=i.dependencies.length;n3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),ot&&n[o].classList.add("future"),u.querySelector("section")&&n[o].classList.add("stack")}n[t].classList.add("present");var f=n[t].getAttribute("data-state");f&&(l=l.concat(f.split(" ")));var c=n[t].getAttribute("data-autoslide");c?s=parseInt(c,10):s=i.autoSlide}else t=0;return t}function G(){if(i.progress&&h.progress){var n=M(document.querySelectorAll(t)),r=document.querySelectorAll(e+":not(.stack)").length,s=0;e:for(var o=0;o0,right:o0,down:u0||u>0)t+=o;u>0&&(t+="/"+u)}window.location.hash=t}}}function nt(e){var n=o,r=u;if(e){var i=!!e.parentNode.nodeName.match(/section/gi),s=i?e.parentNode:e,a=M(document.querySelectorAll(t));n=Math.max(a.indexOf(s),0),i&&(r=Math.max(M(e.parentNode.querySelectorAll("section")).indexOf(e),0))}return{h:n,v:r}}function rt(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment:not(.visible)");if(e.length)return e[0].classList.add("visible"),P("fragmentshown",{fragment:e[0]}),!0}else{var r=document.querySelectorAll(t+".present .fragment:not(.visible)");if(r.length)return r[0].classList.add("visible"),P("fragmentshown",{fragment:r[0]}),!0}return!1}function it(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment.visible");if(e.length)return e[e.length-1].classList.remove("visible"),P("fragmenthidden",{fragment:e[e.length-1]}),!0}else{var r=document.querySelectorAll(t+".present .fragment.visible");if(r.length)return r[r.length-1].classList.remove("visible"),P("fragmenthidden",{fragment:r[r.length-1]}),!0}return!1}function st(){clearTimeout(m),s&&!J()&&!z()&&(m=setTimeout(ht,s))}function ot(){clearTimeout(m)}function ut(){(Z().left&&z()||it()===!1)&&K(o-1)}function at(){(Z().right&&z()||rt()===!1)&&K(o+1)}function ft(){(Z().up&&z()||it()===!1)&&K(o,u-1)}function lt(){(Z().down&&z()||rt()===!1)&&K(o,u+1)}function ct(){if(it()===!1)if(Z().up)ft();else{var e=document.querySelector(t+".past:nth-child("+o+")");e&&(u=e.querySelectorAll("section").length+1||undefined,o--,K())}}function ht(){rt()===!1&&(Z().down?lt():at()),st()}function pt(e){var t=document.activeElement,n=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&document.activeElement.contentEditable==="inherit");if(n||e.shiftKey||e.altKey||e.ctrlKey||e.metaKey)return;var r=!0;if(J()&&[66,190,191].indexOf(e.keyCode)===-1)return!1;switch(e.keyCode){case 80:case 33:ct();break;case 78:case 34:ht();break;case 72:case 37:ut();break;case 76:case 39:at();break;case 75:case 38:ft();break;case 74:case 40:lt();break;case 36:K(0);break;case 35:K(Number.MAX_VALUE);break;case 32:z()?R():ht();break;case 13:z()?R():r=!1;break;case 66:case 190:case 191:$();break;case 70:W();break;default:r=!1}r?e.preventDefault():e.keyCode===27&&p&&(U(),e.preventDefault()),st()}function dt(e){E.startX=e.touches[0].clientX,E.startY=e.touches[0].clientY,E.startCount=e.touches.length,e.touches.length===2&&i.overview&&(E.startSpan=_({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:E.startX,y:E.startY}))}function vt(e){if(!E.handled){var t=e.touches[0].clientX,n=e.touches[0].clientY;if(e.touches.length===2&&E.startCount===2&&i.overview){var r=_({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:E.startX,y:E.startY});Math.abs(E.startSpan-r)>E.threshold&&(E.handled=!0,rE.threshold&&Math.abs(s)>Math.abs(o)?(E.handled=!0,ut()):s<-E.threshold&&Math.abs(s)>Math.abs(o)?(E.handled=!0,at()):o>E.threshold?(E.handled=!0,ft()):o<-E.threshold&&(E.handled=!0,lt()),e.preventDefault()}}else navigator.userAgent.match(/android/gi)&&e.preventDefault()}function mt(e){E.handled=!1}function gt(e){clearTimeout(v),v=setTimeout(function(){var t=e.detail||-e.wheelDelta;t>0?ht():ct()},100)}function yt(e){e.preventDefault();var n=M(document.querySelectorAll(t)).length,r=Math.floor(e.clientX/h.wrapper.offsetWidth*n);K(r)}function bt(e){e.preventDefault(),ut()}function wt(e){e.preventDefault(),at()}function Et(e){e.preventDefault(),ft()}function St(e){e.preventDefault(),lt()}function xt(e){e.preventDefault(),ct()}function Tt(e){e.preventDefault(),ht()}function Nt(e){et()}function Ct(e){j()}function kt(e){if(w&&z()){e.preventDefault();var t=e.target;while(t&&!t.nodeName.match(/section/gi))t=t.parentNode;if(t&&!t.classList.contains("disabled")){R();if(t.nodeName.match(/section/gi)){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);K(n,r)}}}}var e=".reveal .slides section",t=".reveal .slides>section",n=".reveal .slides>section.present>section",r=".reveal .slides>section:first-child",i={width:960,height:700,margin:.1,minScale:.2,maxScale:1,controls:!0,progress:!0,history:!1,keyboard:!0,overview:!0,center:!0,touch:!0,loop:!1,rtl:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!0,theme:null,transition:"default",dependencies:[]},s=i.autoSlide,o=0,u=0,a,f,l=[],c=1,h={},p="WebkitPerspective"in document.body.style||"MozPerspective"in document.body.style||"msPerspective"in document.body.style||"OPerspective"in document.body.style||"perspective"in document.body.style,d="WebkitTransform"in document.body.style||"MozTransform"in document.body.style||"msTransform"in document.body.style||"OTransform"in document.body.style||"transform"in document.body.style,v=0,m=0,g=0,y=0,b=0,w=!1,E={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:S,configure:k,slide:K,left:ut,right:at,up:ft,down:lt,prev:ct,next:ht,prevFragment:it,nextFragment:rt,navigateTo:K,navigateLeft:ut,navigateRight:at,navigateUp:ft,navigateDown:lt,navigatePrev:ct,navigateNext:ht,layout:j,toggleOverview:U,togglePause:$,isOverview:z,isPaused:J,addEventListeners:L,removeEventListeners:A,getIndices:nt,getSlide:function(e,n){var r=document.querySelectorAll(t)[e],i=r&&r.querySelectorAll("section");return typeof n!="undefined"?i?i[n]:undefined:r},getPreviousSlide:function(){return a},getCurrentSlide:function(){return f},getScale:function(){return c},getQueryHash:function(){var e={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(t){e[t.split("=").shift()]=t.split("=").pop()}),e},isFirstSlide:function(){return document.querySelector(e+".past")==null?!0:!1},isLastSlide:function(){return f&&f.classList.contains(".stack")?f.querySelector(e+".future")==null?!0:!1:document.querySelector(e+".future")==null?!0:!1},addEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file From 5978b7fb646b3c8e981b79a904d7958353eba2c5 Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Tue, 26 Feb 2013 12:08:44 -0500 Subject: [PATCH 10/22] remove share buttons --- index.html | 46 ---------------------------------------------- 1 file changed, 46 deletions(-) diff --git a/index.html b/index.html index 0608eb8..bc2f360 100644 --- a/index.html +++ b/index.html @@ -373,51 +373,5 @@ function linkify( selector ) { - - - - - - - - - - - - - - From 14105feb102829a42e8ef2a213ea88f896bea26d Mon Sep 17 00:00:00 2001 From: Boaz Sender Date: Wed, 27 Feb 2013 02:26:24 -0500 Subject: [PATCH 11/22] upgrading to grunt 0.4. resolves #349. --- grunt.js => gruntfile.js | 43 ++++++++++++++-------------- package.json | 61 +++++++++++++++++++++------------------- 2 files changed, 53 insertions(+), 51 deletions(-) rename grunt.js => gruntfile.js (52%) diff --git a/grunt.js b/gruntfile.js similarity index 52% rename from grunt.js rename to gruntfile.js index 00f4350..bb86019 100644 --- a/grunt.js +++ b/gruntfile.js @@ -3,19 +3,11 @@ module.exports = function(grunt) { // Project configuration grunt.initConfig({ - pkg: '', - - inputJS: 'js/reveal.js', - inputCSS: 'css/reveal.css', - - outputJS: 'js/reveal.min.js', - outputCSS: 'css/reveal.min.css', - + pkg: grunt.file.readJSON('package.json'), meta: { - version: '2.3', banner: '/*!\n' + - ' * reveal.js <%= meta.version %> (<%= grunt.template.today("yyyy-mm-dd, HH:MM") %>)\n' + + ' * reveal.js <%= pkg.version %> (<%= grunt.template.today("yyyy-mm-dd, HH:MM") %>)\n' + ' * http://lab.hakim.se/reveal-js\n' + ' * MIT licensed\n' + ' *\n' + @@ -23,8 +15,8 @@ module.exports = function(grunt) { ' */' }, - lint: { - files: [ 'grunt.js', '<%= inputJS %>' ] + jshint: { + files: [ 'gruntfile.js', 'js/reveal.js' ] }, // Tests will be added soon @@ -32,17 +24,20 @@ module.exports = function(grunt) { files: [ 'test/**/*.html' ] }, - min: { - dist: { - src: [ '', '<%= inputJS %>' ], - dest: '<%= outputJS %>' - } + uglify: { + options: { + banner: '<%= meta.banner %> \n' + }, + build: { + src: 'js/reveal.js', + dest: 'js/reveal.min.js' + } }, - mincss: { + cssmin: { compress: { files: { - '<%= outputCSS %>': [ '<%= inputCSS %>' ] + 'css/reveal.min.css': [ 'css/reveal.css' ] } } }, @@ -69,16 +64,20 @@ module.exports = function(grunt) { }, watch: { - files: [ 'grunt.js', '<%= inputJS %>', '<%= inputCSS %>' ], + files: [ 'gruntfile.js', 'js/reveal.js', 'css/reveal.css' ], tasks: 'default' } }); // Dependencies - grunt.loadNpmTasks( 'grunt-contrib-mincss' ); + grunt.loadNpmTasks( 'grunt-contrib-jshint' ); + grunt.loadNpmTasks( 'grunt-contrib-cssmin' ); + grunt.loadNpmTasks( 'grunt-contrib-uglify' ); + grunt.loadNpmTasks( 'grunt-contrib-watch' ); // Default task - grunt.registerTask( 'default', [ 'lint', 'mincss', 'min' ] ); + grunt.registerTask( 'default', [ 'jshint', 'cssmin', 'uglify' ] ); }; + \ No newline at end of file diff --git a/package.json b/package.json index 3164f04..e9ab1e1 100644 --- a/package.json +++ b/package.json @@ -1,31 +1,34 @@ { - "name": "reveal.js", - "version": "2.3.0", - "description": "The HTML Presentation Framework", - "homepage": "http://lab.hakim.se/reveal-js", - "author": { - "name": "Hakim El Hattab", - "email": "hakim.elhattab@gmail.com", - "web": "http://hakim.se" - }, - "repository": { - "type": "git", - "url": "git://github.com/hakimel/reveal.js.git" - }, - "engines": { - "node": "~0.8.0" - }, - "scripts": { - "test": "grunt lint qunit" - }, - "dependencies": { - "underscore" : "~1.3.3", - "express" : "~2.5.9", - "socket.io" : "~0.9.6", - "mustache" : "~0.4.0" - }, - "devDependencies": { - "grunt-contrib-mincss": "~0.3.1", - "grunt": "~0.3.17" - } + "name": "reveal.js", + "version": "2.3.0", + "description": "The HTML Presentation Framework", + "homepage": "http://lab.hakim.se/reveal-js", + "author": { + "name": "Hakim El Hattab", + "email": "hakim.elhattab@gmail.com", + "web": "http://hakim.se" + }, + "repository": { + "type": "git", + "url": "git://github.com/hakimel/reveal.js.git" + }, + "engines": { + "node": "~0.8.0" + }, + "scripts": { + "test": "grunt lint qunit" + }, + "dependencies": { + "underscore": "~1.3.3", + "express": "~2.5.9", + "socket.io": "~0.9.6", + "mustache": "~0.4.0" + }, + "devDependencies": { + "grunt-contrib-jshint": "~0.2.0", + "grunt-contrib-cssmin": "~0.4.1", + "grunt-contrib-uglify": "~0.1.1", + "grunt-contrib-watch": "~0.2.0", + "grunt": "~0.4.0" + } } From 3f740c8553e4a961f552a8ec01e0a8b1d2599b6f Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Wed, 27 Feb 2013 13:20:24 -0500 Subject: [PATCH 12/22] merge grunt update to 0.4 (#350) --- css/reveal.min.css | 2 +- gruntfile.js | 17 ++++++++--------- js/reveal.min.js | 4 ++-- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/css/reveal.min.css b/css/reveal.min.css index d806c03..7dd814a 100644 --- a/css/reveal.min.css +++ b/css/reveal.min.css @@ -4,4 +4,4 @@ * MIT licensed * * Copyright (C) 2013 Hakim El Hattab, http://hakim.se - */html,body,.reveal div,.reveal span,.reveal applet,.reveal object,.reveal iframe,.reveal h1,.reveal h2,.reveal h3,.reveal h4,.reveal h5,.reveal h6,.reveal p,.reveal blockquote,.reveal pre,.reveal a,.reveal abbr,.reveal acronym,.reveal address,.reveal big,.reveal cite,.reveal code,.reveal del,.reveal dfn,.reveal em,.reveal img,.reveal ins,.reveal kbd,.reveal q,.reveal s,.reveal samp,.reveal small,.reveal strike,.reveal strong,.reveal sub,.reveal sup,.reveal tt,.reveal var,.reveal b,.reveal u,.reveal i,.reveal center,.reveal dl,.reveal dt,.reveal dd,.reveal ol,.reveal ul,.reveal li,.reveal fieldset,.reveal form,.reveal label,.reveal legend,.reveal table,.reveal caption,.reveal tbody,.reveal tfoot,.reveal thead,.reveal tr,.reveal th,.reveal td,.reveal article,.reveal aside,.reveal canvas,.reveal details,.reveal embed,.reveal figure,.reveal figcaption,.reveal footer,.reveal header,.reveal hgroup,.reveal menu,.reveal nav,.reveal output,.reveal ruby,.reveal section,.reveal summary,.reveal time,.reveal mark,.reveal audio,video{margin:0;padding:0;border:0;font-size:100%;font:inherit;vertical-align:baseline}.reveal article,.reveal aside,.reveal details,.reveal figcaption,.reveal figure,.reveal footer,.reveal header,.reveal hgroup,.reveal menu,.reveal nav,.reveal section{display:block}html,body{width:100%;height:100%;overflow:hidden}body{position:relative;line-height:1}::selection{background:#FF5E99;color:#fff;text-shadow:none}.reveal h1,.reveal h2,.reveal h3,.reveal h4,.reveal h5,.reveal h6{-webkit-hyphens:auto;-moz-hyphens:auto;hyphens:auto;word-wrap:break-word}.reveal h1{font-size:3.77em}.reveal h2{font-size:2.11em}.reveal h3{font-size:1.55em}.reveal h4{font-size:1em}.reveal .slides section .fragment{opacity:0;-webkit-transition:all .2s ease;-moz-transition:all .2s ease;-ms-transition:all .2s ease;-o-transition:all .2s ease;transition:all .2s ease}.reveal .slides section .fragment.visible{opacity:1}.reveal .slides section .fragment.grow{opacity:1}.reveal .slides section .fragment.grow.visible{-webkit-transform:scale( 1.3 );-moz-transform:scale( 1.3 );-ms-transform:scale( 1.3 );-o-transform:scale( 1.3 );transform:scale( 1.3 )}.reveal .slides section .fragment.shrink{opacity:1}.reveal .slides section .fragment.shrink.visible{-webkit-transform:scale( .7 );-moz-transform:scale( .7 );-ms-transform:scale( .7 );-o-transform:scale( .7 );transform:scale( .7 )}.reveal .slides section .fragment.roll-in{opacity:0;-webkit-transform:rotateX( 90deg );-moz-transform:rotateX( 90deg );-ms-transform:rotateX( 90deg );-o-transform:rotateX( 90deg );transform:rotateX( 90deg )}.reveal .slides section .fragment.roll-in.visible{opacity:1;-webkit-transform:rotateX( 0 );-moz-transform:rotateX( 0 );-ms-transform:rotateX( 0 );-o-transform:rotateX( 0 );transform:rotateX( 0 )}.reveal .slides section .fragment.fade-out{opacity:1}.reveal .slides section .fragment.fade-out.visible{opacity:0}.reveal .slides section .fragment.highlight-red,.reveal .slides section .fragment.highlight-green,.reveal .slides section .fragment.highlight-blue{opacity:1}.reveal .slides section .fragment.highlight-red.visible{color:#ff2c2d}.reveal .slides section .fragment.highlight-green.visible{color:#17ff2e}.reveal .slides section .fragment.highlight-blue.visible{color:#1b91ff}.reveal:after{content:'';font-style:italic}.reveal img,.reveal video,.reveal iframe{max-width:95%;max-height:95%}.reveal a{position:relative}.reveal strong,.reveal b{font-weight:700}.reveal em,.reveal i{font-style:italic}.reveal ol,.reveal ul{display:inline-block;text-align:left;margin:0 0 0 1em}.reveal ol{list-style-type:decimal}.reveal ul{list-style-type:disc}.reveal ul ul{list-style-type:square}.reveal ul ul ul{list-style-type:circle}.reveal ul ul,.reveal ul ol,.reveal ol ol,.reveal ol ul{display:block;margin-left:40px}.reveal p{margin-bottom:10px;line-height:1.2em}.reveal q,.reveal blockquote{quotes:none}.reveal blockquote{display:block;position:relative;width:70%;margin:5px auto;padding:5px;font-style:italic;background:rgba(255,255,255,.05);box-shadow:0 0 2px rgba(0,0,0,.2)}.reveal blockquote p:first-child,.reveal blockquote p:last-child{display:inline-block}.reveal blockquote:before{content:'\201C'}.reveal blockquote:after{content:'\201D'}.reveal q{font-style:italic}.reveal q:before{content:'\201C'}.reveal q:after{content:'\201D'}.reveal pre{display:block;position:relative;width:90%;margin:15px auto;text-align:left;font-size:.55em;font-family:monospace;line-height:1.2em;word-wrap:break-word;box-shadow:0 0 6px rgba(0,0,0,.3)}.reveal pre code{padding:5px}.reveal code{font-family:monospace;overflow:auto;max-height:400px}.reveal table th,.reveal table td{text-align:left;padding-right:.3em}.reveal table th{text-shadow:#fff 1px 1px 2px}.reveal sup{vertical-align:super}.reveal sub{vertical-align:sub}.reveal small{display:inline-block;font-size:.6em;line-height:1.2em;vertical-align:top}.reveal small *{vertical-align:top}.reveal .controls{display:none;position:fixed;width:110px;height:110px;z-index:30;right:10px;bottom:10px}.reveal .controls div{position:absolute;opacity:.1;width:0;height:0;border:12px solid transparent;-webkit-transition:opacity .2s ease;-moz-transition:opacity .2s ease;-ms-transition:opacity .2s ease;-o-transition:opacity .2s ease;transition:opacity .2s ease}.reveal .controls div.enabled{opacity:.6;cursor:pointer}.reveal .controls div.enabled:active{margin-top:1px}.reveal .controls div.navigate-left{top:42px;border-right-width:22px;border-right-color:#eee}.reveal .controls div.navigate-right{left:74px;top:42px;border-left-width:22px;border-left-color:#eee}.reveal .controls div.navigate-up{left:42px;border-bottom-width:22px;border-bottom-color:#eee}.reveal .controls div.navigate-down{left:42px;top:74px;border-top-width:22px;border-top-color:#eee}.reveal .progress{position:fixed;display:none;height:3px;width:100%;bottom:0;left:0;z-index:10}.reveal .progress:after{content:'';display:'block';position:absolute;height:20px;width:100%;top:-20px}.reveal .progress span{display:block;height:100%;width:0;-webkit-transition:width 800ms cubic-bezier(0.260,.860,.440,.985);-moz-transition:width 800ms cubic-bezier(0.260,.860,.440,.985);-ms-transition:width 800ms cubic-bezier(0.260,.860,.440,.985);-o-transition:width 800ms cubic-bezier(0.260,.860,.440,.985);transition:width 800ms cubic-bezier(0.260,.860,.440,.985)}.reveal .roll{display:inline-block;line-height:1.2;overflow:hidden;vertical-align:top;-webkit-perspective:400px;-moz-perspective:400px;-ms-perspective:400px;perspective:400px;-webkit-perspective-origin:50% 50%;-moz-perspective-origin:50% 50%;-ms-perspective-origin:50% 50%;perspective-origin:50% 50%}.reveal .roll:hover{background:0;text-shadow:none}.reveal .roll span{display:block;position:relative;padding:0 2px;pointer-events:none;-webkit-transition:all 400ms ease;-moz-transition:all 400ms ease;-ms-transition:all 400ms ease;transition:all 400ms ease;-webkit-transform-origin:50% 0;-moz-transform-origin:50% 0;-ms-transform-origin:50% 0;transform-origin:50% 0;-webkit-transform-style:preserve-3d;-moz-transform-style:preserve-3d;-ms-transform-style:preserve-3d;transform-style:preserve-3d;-webkit-backface-visibility:hidden;-moz-backface-visibility:hidden;backface-visibility:hidden}.reveal .roll:hover span{background:rgba(0,0,0,.5);-webkit-transform:translate3d( 0,0,-45px ) rotateX( 90deg );-moz-transform:translate3d( 0,0,-45px ) rotateX( 90deg );-ms-transform:translate3d( 0,0,-45px ) rotateX( 90deg );transform:translate3d( 0,0,-45px ) rotateX( 90deg )}.reveal .roll span:after{content:attr(data-title);display:block;position:absolute;left:0;top:0;padding:0 2px;-webkit-transform-origin:50% 0;-moz-transform-origin:50% 0;-ms-transform-origin:50% 0;transform-origin:50% 0;-webkit-transform:translate3d( 0,110%,0 ) rotateX( -90deg );-moz-transform:translate3d( 0,110%,0 ) rotateX( -90deg );-ms-transform:translate3d( 0,110%,0 ) rotateX( -90deg );transform:translate3d( 0,110%,0 ) rotateX( -90deg )}.reveal{position:relative;width:100%;height:100%}.reveal .slides{position:absolute;width:100%;height:100%;left:50%;top:50%;overflow:visible;z-index:1;text-align:center;-webkit-transition:-webkit-perspective .4s ease;-moz-transition:-moz-perspective .4s ease;-ms-transition:-ms-perspective .4s ease;-o-transition:-o-perspective .4s ease;transition:perspective .4s ease;-webkit-perspective:600px;-moz-perspective:600px;-ms-perspective:600px;perspective:600px;-webkit-perspective-origin:0 -100px;-moz-perspective-origin:0 -100px;-ms-perspective-origin:0 -100px;perspective-origin:0 -100px}.reveal .slides>section,.reveal .slides>section>section{display:none;position:absolute;width:100%;padding:20px 0;z-index:10;line-height:1.2em;font-weight:400;-webkit-transform-style:preserve-3d;-moz-transform-style:preserve-3d;-ms-transform-style:preserve-3d;transform-style:preserve-3d;-webkit-transition:-webkit-transform-origin 800ms cubic-bezier(0.260,.860,.440,.985),-webkit-transform 800ms cubic-bezier(0.260,.860,.440,.985),visibility 800ms cubic-bezier(0.260,.860,.440,.985),opacity 800ms cubic-bezier(0.260,.860,.440,.985);-moz-transition:-moz-transform-origin 800ms cubic-bezier(0.260,.860,.440,.985),-moz-transform 800ms cubic-bezier(0.260,.860,.440,.985),visibility 800ms cubic-bezier(0.260,.860,.440,.985),opacity 800ms cubic-bezier(0.260,.860,.440,.985);-ms-transition:-ms-transform-origin 800ms cubic-bezier(0.260,.860,.440,.985),-ms-transform 800ms cubic-bezier(0.260,.860,.440,.985),visibility 800ms cubic-bezier(0.260,.860,.440,.985),opacity 800ms cubic-bezier(0.260,.860,.440,.985);-o-transition:-o-transform-origin 800ms cubic-bezier(0.260,.860,.440,.985),-o-transform 800ms cubic-bezier(0.260,.860,.440,.985),visibility 800ms cubic-bezier(0.260,.860,.440,.985),opacity 800ms cubic-bezier(0.260,.860,.440,.985);transition:transform-origin 800ms cubic-bezier(0.260,.860,.440,.985),transform 800ms cubic-bezier(0.260,.860,.440,.985),visibility 800ms cubic-bezier(0.260,.860,.440,.985),opacity 800ms cubic-bezier(0.260,.860,.440,.985)}.reveal .slides>section{left:-50%;top:-50%}.reveal .slides>section.stack{padding-top:0;padding-bottom:0}.reveal .slides>section.present,.reveal .slides>section>section.present{display:block;z-index:11;opacity:1}.reveal.center,.reveal.center .slides,.reveal.center .slides section{min-height:auto!important}.reveal .slides>section.past{display:block;opacity:0;-webkit-transform:translate3d(-100%,0,0) rotateY(-90deg) translate3d(-100%,0,0);-moz-transform:translate3d(-100%,0,0) rotateY(-90deg) translate3d(-100%,0,0);-ms-transform:translate3d(-100%,0,0) rotateY(-90deg) translate3d(-100%,0,0);transform:translate3d(-100%,0,0) rotateY(-90deg) translate3d(-100%,0,0)}.reveal .slides>section.future{display:block;opacity:0;-webkit-transform:translate3d(100%,0,0) rotateY(90deg) translate3d(100%,0,0);-moz-transform:translate3d(100%,0,0) rotateY(90deg) translate3d(100%,0,0);-ms-transform:translate3d(100%,0,0) rotateY(90deg) translate3d(100%,0,0);transform:translate3d(100%,0,0) rotateY(90deg) translate3d(100%,0,0)}.reveal .slides>section>section.past{display:block;opacity:0;-webkit-transform:translate3d(0,-300px,0) rotateX(70deg) translate3d(0,-300px,0);-moz-transform:translate3d(0,-300px,0) rotateX(70deg) translate3d(0,-300px,0);-ms-transform:translate3d(0,-300px,0) rotateX(70deg) translate3d(0,-300px,0);transform:translate3d(0,-300px,0) rotateX(70deg) translate3d(0,-300px,0)}.reveal .slides>section>section.future{display:block;opacity:0;-webkit-transform:translate3d(0,300px,0) rotateX(-70deg) translate3d(0,300px,0);-moz-transform:translate3d(0,300px,0) rotateX(-70deg) translate3d(0,300px,0);-ms-transform:translate3d(0,300px,0) rotateX(-70deg) translate3d(0,300px,0);transform:translate3d(0,300px,0) rotateX(-70deg) translate3d(0,300px,0)}.reveal.concave .slides>section.past{-webkit-transform:translate3d(-100%,0,0) rotateY(90deg) translate3d(-100%,0,0);-moz-transform:translate3d(-100%,0,0) rotateY(90deg) translate3d(-100%,0,0);-ms-transform:translate3d(-100%,0,0) rotateY(90deg) translate3d(-100%,0,0);transform:translate3d(-100%,0,0) rotateY(90deg) translate3d(-100%,0,0)}.reveal.concave .slides>section.future{-webkit-transform:translate3d(100%,0,0) rotateY(-90deg) translate3d(100%,0,0);-moz-transform:translate3d(100%,0,0) rotateY(-90deg) translate3d(100%,0,0);-ms-transform:translate3d(100%,0,0) rotateY(-90deg) translate3d(100%,0,0);transform:translate3d(100%,0,0) rotateY(-90deg) translate3d(100%,0,0)}.reveal.concave .slides>section>section.past{-webkit-transform:translate3d(0,-80%,0) rotateX(-70deg) translate3d(0,-80%,0);-moz-transform:translate3d(0,-80%,0) rotateX(-70deg) translate3d(0,-80%,0);-ms-transform:translate3d(0,-80%,0) rotateX(-70deg) translate3d(0,-80%,0);transform:translate3d(0,-80%,0) rotateX(-70deg) translate3d(0,-80%,0)}.reveal.concave .slides>section>section.future{-webkit-transform:translate3d(0,80%,0) rotateX(70deg) translate3d(0,80%,0);-moz-transform:translate3d(0,80%,0) rotateX(70deg) translate3d(0,80%,0);-ms-transform:translate3d(0,80%,0) rotateX(70deg) translate3d(0,80%,0);transform:translate3d(0,80%,0) rotateX(70deg) translate3d(0,80%,0)}.reveal.zoom .slides>section.past{opacity:0;visibility:hidden;-webkit-transform:scale(16);-moz-transform:scale(16);-ms-transform:scale(16);-o-transform:scale(16);transform:scale(16)}.reveal.zoom .slides>section.future{opacity:0;visibility:hidden;-webkit-transform:scale(0.2);-moz-transform:scale(0.2);-ms-transform:scale(0.2);-o-transform:scale(0.2);transform:scale(0.2)}.reveal.zoom .slides>section>section.past{-webkit-transform:translate(0,-150%);-moz-transform:translate(0,-150%);-ms-transform:translate(0,-150%);-o-transform:translate(0,-150%);transform:translate(0,-150%)}.reveal.zoom .slides>section>section.future{-webkit-transform:translate(0,150%);-moz-transform:translate(0,150%);-ms-transform:translate(0,150%);-o-transform:translate(0,150%);transform:translate(0,150%)}.reveal.linear .slides>section.past{-webkit-transform:translate(-150%,0);-moz-transform:translate(-150%,0);-ms-transform:translate(-150%,0);-o-transform:translate(-150%,0);transform:translate(-150%,0)}.reveal.linear .slides>section.future{-webkit-transform:translate(150%,0);-moz-transform:translate(150%,0);-ms-transform:translate(150%,0);-o-transform:translate(150%,0);transform:translate(150%,0)}.reveal.linear .slides>section>section.past{-webkit-transform:translate(0,-150%);-moz-transform:translate(0,-150%);-ms-transform:translate(0,-150%);-o-transform:translate(0,-150%);transform:translate(0,-150%)}.reveal.linear .slides>section>section.future{-webkit-transform:translate(0,150%);-moz-transform:translate(0,150%);-ms-transform:translate(0,150%);-o-transform:translate(0,150%);transform:translate(0,150%)}.reveal.cube .slides{-webkit-perspective:1300px;-moz-perspective:1300px;-ms-perspective:1300px;perspective:1300px}.reveal.cube .slides section{padding:30px;min-height:600px;-webkit-backface-visibility:hidden;-moz-backface-visibility:hidden;-ms-backface-visibility:hidden;backface-visibility:hidden;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.reveal.center.cube .slides section{min-height:auto}.reveal.cube .slides section:not(.stack):before{content:'';position:absolute;display:block;width:100%;height:100%;left:0;top:0;background:rgba(0,0,0,.1);border-radius:4px;-webkit-transform:translateZ( -20px );-moz-transform:translateZ( -20px );-ms-transform:translateZ( -20px );-o-transform:translateZ( -20px );transform:translateZ( -20px )}.reveal.cube .slides section:not(.stack):after{content:'';position:absolute;display:block;width:90%;height:30px;left:5%;bottom:0;background:0;z-index:1;border-radius:4px;box-shadow:0 95px 25px rgba(0,0,0,.2);-webkit-transform:translateZ(-90px) rotateX( 65deg );-moz-transform:translateZ(-90px) rotateX( 65deg );-ms-transform:translateZ(-90px) rotateX( 65deg );-o-transform:translateZ(-90px) rotateX( 65deg );transform:translateZ(-90px) rotateX( 65deg )}.reveal.cube .slides>section.stack{padding:0;background:0}.reveal.cube .slides>section.past{-webkit-transform-origin:100% 0;-moz-transform-origin:100% 0;-ms-transform-origin:100% 0;transform-origin:100% 0;-webkit-transform:translate3d(-100%,0,0) rotateY(-90deg);-moz-transform:translate3d(-100%,0,0) rotateY(-90deg);-ms-transform:translate3d(-100%,0,0) rotateY(-90deg);transform:translate3d(-100%,0,0) rotateY(-90deg)}.reveal.cube .slides>section.future{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;-webkit-transform:translate3d(100%,0,0) rotateY(90deg);-moz-transform:translate3d(100%,0,0) rotateY(90deg);-ms-transform:translate3d(100%,0,0) rotateY(90deg);transform:translate3d(100%,0,0) rotateY(90deg)}.reveal.cube .slides>section>section.past{-webkit-transform-origin:0 100%;-moz-transform-origin:0 100%;-ms-transform-origin:0 100%;transform-origin:0 100%;-webkit-transform:translate3d(0,-100%,0) rotateX(90deg);-moz-transform:translate3d(0,-100%,0) rotateX(90deg);-ms-transform:translate3d(0,-100%,0) rotateX(90deg);transform:translate3d(0,-100%,0) rotateX(90deg)}.reveal.cube .slides>section>section.future{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;-webkit-transform:translate3d(0,100%,0) rotateX(-90deg);-moz-transform:translate3d(0,100%,0) rotateX(-90deg);-ms-transform:translate3d(0,100%,0) rotateX(-90deg);transform:translate3d(0,100%,0) rotateX(-90deg)}.reveal.page .slides{-webkit-perspective-origin:0 50%;-moz-perspective-origin:0 50%;-ms-perspective-origin:0 50%;perspective-origin:0 50%;-webkit-perspective:3000px;-moz-perspective:3000px;-ms-perspective:3000px;perspective:3000px}.reveal.page .slides section{padding:30px;min-height:600px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.reveal.page .slides section.past{z-index:12}.reveal.page .slides section:not(.stack):before{content:'';position:absolute;display:block;width:100%;height:100%;left:0;top:0;background:rgba(0,0,0,.1);-webkit-transform:translateZ( -20px );-moz-transform:translateZ( -20px );-ms-transform:translateZ( -20px );-o-transform:translateZ( -20px );transform:translateZ( -20px )}.reveal.page .slides section:not(.stack):after{content:'';position:absolute;display:block;width:90%;height:30px;left:5%;bottom:0;background:0;z-index:1;border-radius:4px;box-shadow:0 95px 25px rgba(0,0,0,.2);-webkit-transform:translateZ(-90px) rotateX( 65deg )}.reveal.page .slides>section.stack{padding:0;background:0}.reveal.page .slides>section.past{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;-webkit-transform:translate3d(-40%,0,0) rotateY(-80deg);-moz-transform:translate3d(-40%,0,0) rotateY(-80deg);-ms-transform:translate3d(-40%,0,0) rotateY(-80deg);transform:translate3d(-40%,0,0) rotateY(-80deg)}.reveal.page .slides>section.future{-webkit-transform-origin:100% 0;-moz-transform-origin:100% 0;-ms-transform-origin:100% 0;transform-origin:100% 0;-webkit-transform:translate3d(0,0,0);-moz-transform:translate3d(0,0,0);-ms-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}.reveal.page .slides>section>section.past{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;-webkit-transform:translate3d(0,-40%,0) rotateX(80deg);-moz-transform:translate3d(0,-40%,0) rotateX(80deg);-ms-transform:translate3d(0,-40%,0) rotateX(80deg);transform:translate3d(0,-40%,0) rotateX(80deg)}.reveal.page .slides>section>section.future{-webkit-transform-origin:0 100%;-moz-transform-origin:0 100%;-ms-transform-origin:0 100%;transform-origin:0 100%;-webkit-transform:translate3d(0,0,0);-moz-transform:translate3d(0,0,0);-ms-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}.reveal.fade .slides section,.reveal.fade .slides>section>section{-webkit-transform:none;-moz-transform:none;-ms-transform:none;-o-transform:none;transform:none;-webkit-transition:opacity .5s;-moz-transition:opacity .5s;-ms-transition:opacity .5s;-o-transition:opacity .5s;transition:opacity .5s}.reveal.fade.overview .slides section,.reveal.fade.overview .slides>section>section,.reveal.fade.exit-overview .slides section,.reveal.fade.exit-overview .slides>section>section{-webkit-transition:none;-moz-transition:none;-ms-transition:none;-o-transition:none;transition:none}.reveal.none .slides section{-webkit-transform:none;-moz-transform:none;-ms-transform:none;-o-transform:none;transform:none;-webkit-transition:none;-moz-transition:none;-ms-transition:none;-o-transition:none;transition:none}.reveal.overview .slides{-webkit-perspective-origin:0 0;-moz-perspective-origin:0 0;-ms-perspective-origin:0 0;perspective-origin:0 0;-webkit-perspective:700px;-moz-perspective:700px;-ms-perspective:700px;perspective:700px}.reveal.overview .slides section{height:600px;overflow:hidden;opacity:1!important;visibility:visible!important;cursor:pointer;background:rgba(0,0,0,.1)}.reveal.overview .slides section .fragment{opacity:1}.reveal.overview .slides section:after,.reveal.overview .slides section:before{display:none!important}.reveal.overview .slides section>section{opacity:1;cursor:pointer}.reveal.overview .slides section:hover{background:rgba(0,0,0,.3)}.reveal.overview .slides section.present{background:rgba(0,0,0,.3)}.reveal.overview .slides>section.stack{padding:0;background:0;overflow:visible}.reveal .pause-overlay{position:absolute;top:0;left:0;width:100%;height:100%;background:#000;visibility:hidden;opacity:0;z-index:100;-webkit-transition:all 1s ease;-moz-transition:all 1s ease;-ms-transition:all 1s ease;-o-transition:all 1s ease;transition:all 1s ease}.reveal.paused .pause-overlay{visibility:visible;opacity:1}.no-transforms{overflow-y:auto}.no-transforms .slides{width:80%;top:0;left:50%;margin:0;text-align:center}.no-transforms .slides section{display:block!important;opacity:1!important;position:relative!important;height:auto;min-height:auto;top:0;left:-50%;margin:70px 0;-webkit-transform:none;-moz-transform:none;-ms-transform:none;transform:none}.no-transforms .slides section section{left:0}.no-transition{-webkit-transition:none;-moz-transition:none;-ms-transition:none;-o-transition:none;transition:none}.reveal .state-background{position:absolute;width:100%;height:100%;background:rgba( 0,0,0,0 );-webkit-transition:background 800ms ease;-moz-transition:background 800ms ease;-ms-transition:background 800ms ease;-o-transition:background 800ms ease;transition:background 800ms ease}.alert .reveal .state-background{background:rgba( 200,50,30,.6 )}.soothe .reveal .state-background{background:rgba( 50,200,90,.4 )}.blackout .reveal .state-background{background:rgba( 0,0,0,.6 )}.reveal.rtl .slides,.reveal.rtl .slides h1,.reveal.rtl .slides h2,.reveal.rtl .slides h3,.reveal.rtl .slides h4,.reveal.rtl .slides h5,.reveal.rtl .slides h6{direction:rtl;font-family:sans-serif}.reveal.rtl pre,.reveal.rtl code{direction:ltr}.reveal.rtl ol,.reveal.rtl ul{text-align:right}.reveal aside.notes{display:none}.zoomed .reveal *,.zoomed .reveal :before,.zoomed .reveal :after{-webkit-transform:none!important;-moz-transform:none!important;-ms-transform:none!important;transform:none!important;-webkit-backface-visibility:visible!important;-moz-backface-visibility:visible!important;-ms-backface-visibility:visible!important;backface-visibility:visible!important}.zoomed .reveal .progress,.zoomed .reveal .controls{opacity:0}.zoomed .reveal .roll span{background:0}.zoomed .reveal .roll span:after{visibility:hidden} \ No newline at end of file + */ html,body,.reveal div,.reveal span,.reveal applet,.reveal object,.reveal iframe,.reveal h1,.reveal h2,.reveal h3,.reveal h4,.reveal h5,.reveal h6,.reveal p,.reveal blockquote,.reveal pre,.reveal a,.reveal abbr,.reveal acronym,.reveal address,.reveal big,.reveal cite,.reveal code,.reveal del,.reveal dfn,.reveal em,.reveal img,.reveal ins,.reveal kbd,.reveal q,.reveal s,.reveal samp,.reveal small,.reveal strike,.reveal strong,.reveal sub,.reveal sup,.reveal tt,.reveal var,.reveal b,.reveal u,.reveal i,.reveal center,.reveal dl,.reveal dt,.reveal dd,.reveal ol,.reveal ul,.reveal li,.reveal fieldset,.reveal form,.reveal label,.reveal legend,.reveal table,.reveal caption,.reveal tbody,.reveal tfoot,.reveal thead,.reveal tr,.reveal th,.reveal td,.reveal article,.reveal aside,.reveal canvas,.reveal details,.reveal embed,.reveal figure,.reveal figcaption,.reveal footer,.reveal header,.reveal hgroup,.reveal menu,.reveal nav,.reveal output,.reveal ruby,.reveal section,.reveal summary,.reveal time,.reveal mark,.reveal audio,video{margin:0;padding:0;border:0;font-size:100%;font:inherit;vertical-align:baseline}.reveal article,.reveal aside,.reveal details,.reveal figcaption,.reveal figure,.reveal footer,.reveal header,.reveal hgroup,.reveal menu,.reveal nav,.reveal section{display:block}html,body{width:100%;height:100%;overflow:hidden}body{position:relative;line-height:1}::selection{background:#FF5E99;color:#fff;text-shadow:none}.reveal h1,.reveal h2,.reveal h3,.reveal h4,.reveal h5,.reveal h6{-webkit-hyphens:auto;-moz-hyphens:auto;hyphens:auto;word-wrap:break-word}.reveal h1{font-size:3.77em}.reveal h2{font-size:2.11em}.reveal h3{font-size:1.55em}.reveal h4{font-size:1em}.reveal .slides section .fragment{opacity:0;-webkit-transition:all .2s ease;-moz-transition:all .2s ease;-ms-transition:all .2s ease;-o-transition:all .2s ease;transition:all .2s ease}.reveal .slides section .fragment.visible{opacity:1}.reveal .slides section .fragment.grow{opacity:1}.reveal .slides section .fragment.grow.visible{-webkit-transform:scale(1.3);-moz-transform:scale(1.3);-ms-transform:scale(1.3);-o-transform:scale(1.3);transform:scale(1.3)}.reveal .slides section .fragment.shrink{opacity:1}.reveal .slides section .fragment.shrink.visible{-webkit-transform:scale(0.7);-moz-transform:scale(0.7);-ms-transform:scale(0.7);-o-transform:scale(0.7);transform:scale(0.7)}.reveal .slides section .fragment.roll-in{opacity:0;-webkit-transform:rotateX(90deg);-moz-transform:rotateX(90deg);-ms-transform:rotateX(90deg);-o-transform:rotateX(90deg);transform:rotateX(90deg)}.reveal .slides section .fragment.roll-in.visible{opacity:1;-webkit-transform:rotateX(0);-moz-transform:rotateX(0);-ms-transform:rotateX(0);-o-transform:rotateX(0);transform:rotateX(0)}.reveal .slides section .fragment.fade-out{opacity:1}.reveal .slides section .fragment.fade-out.visible{opacity:0}.reveal .slides section .fragment.highlight-red,.reveal .slides section .fragment.highlight-green,.reveal .slides section .fragment.highlight-blue{opacity:1}.reveal .slides section .fragment.highlight-red.visible{color:#ff2c2d}.reveal .slides section .fragment.highlight-green.visible{color:#17ff2e}.reveal .slides section .fragment.highlight-blue.visible{color:#1b91ff}.reveal:after{content:'';font-style:italic}.reveal img,.reveal video,.reveal iframe{max-width:95%;max-height:95%}.reveal a{position:relative}.reveal strong,.reveal b{font-weight:700}.reveal em,.reveal i{font-style:italic}.reveal ol,.reveal ul{display:inline-block;text-align:left;margin:0 0 0 1em}.reveal ol{list-style-type:decimal}.reveal ul{list-style-type:disc}.reveal ul ul{list-style-type:square}.reveal ul ul ul{list-style-type:circle}.reveal ul ul,.reveal ul ol,.reveal ol ol,.reveal ol ul{display:block;margin-left:40px}.reveal p{margin-bottom:10px;line-height:1.2em}.reveal q,.reveal blockquote{quotes:none}.reveal blockquote{display:block;position:relative;width:70%;margin:5px auto;padding:5px;font-style:italic;background:rgba(255,255,255,.05);box-shadow:0 0 2px rgba(0,0,0,.2)}.reveal blockquote p:first-child,.reveal blockquote p:last-child{display:inline-block}.reveal blockquote:before{content:'\201C'}.reveal blockquote:after{content:'\201D'}.reveal q{font-style:italic}.reveal q:before{content:'\201C'}.reveal q:after{content:'\201D'}.reveal pre{display:block;position:relative;width:90%;margin:15px auto;text-align:left;font-size:.55em;font-family:monospace;line-height:1.2em;word-wrap:break-word;box-shadow:0 0 6px rgba(0,0,0,.3)}.reveal pre code{padding:5px}.reveal code{font-family:monospace;overflow:auto;max-height:400px}.reveal table th,.reveal table td{text-align:left;padding-right:.3em}.reveal table th{text-shadow:#fff 1px 1px 2px}.reveal sup{vertical-align:super}.reveal sub{vertical-align:sub}.reveal small{display:inline-block;font-size:.6em;line-height:1.2em;vertical-align:top}.reveal small *{vertical-align:top}.reveal .controls{display:none;position:fixed;width:110px;height:110px;z-index:30;right:10px;bottom:10px}.reveal .controls div{position:absolute;opacity:.1;width:0;height:0;border:12px solid transparent;-webkit-transition:opacity .2s ease;-moz-transition:opacity .2s ease;-ms-transition:opacity .2s ease;-o-transition:opacity .2s ease;transition:opacity .2s ease}.reveal .controls div.enabled{opacity:.6;cursor:pointer}.reveal .controls div.enabled:active{margin-top:1px}.reveal .controls div.navigate-left{top:42px;border-right-width:22px;border-right-color:#eee}.reveal .controls div.navigate-right{left:74px;top:42px;border-left-width:22px;border-left-color:#eee}.reveal .controls div.navigate-up{left:42px;border-bottom-width:22px;border-bottom-color:#eee}.reveal .controls div.navigate-down{left:42px;top:74px;border-top-width:22px;border-top-color:#eee}.reveal .progress{position:fixed;display:none;height:3px;width:100%;bottom:0;left:0;z-index:10}.reveal .progress:after{content:'';display:'block';position:absolute;height:20px;width:100%;top:-20px}.reveal .progress span{display:block;height:100%;width:0;-webkit-transition:width 800ms cubic-bezier(0.26,.86,.44,.985);-moz-transition:width 800ms cubic-bezier(0.26,.86,.44,.985);-ms-transition:width 800ms cubic-bezier(0.26,.86,.44,.985);-o-transition:width 800ms cubic-bezier(0.26,.86,.44,.985);transition:width 800ms cubic-bezier(0.26,.86,.44,.985)}.reveal .roll{display:inline-block;line-height:1.2;overflow:hidden;vertical-align:top;-webkit-perspective:400px;-moz-perspective:400px;-ms-perspective:400px;perspective:400px;-webkit-perspective-origin:50% 50%;-moz-perspective-origin:50% 50%;-ms-perspective-origin:50% 50%;perspective-origin:50% 50%}.reveal .roll:hover{background:0;text-shadow:none}.reveal .roll span{display:block;position:relative;padding:0 2px;pointer-events:none;-webkit-transition:all 400ms ease;-moz-transition:all 400ms ease;-ms-transition:all 400ms ease;transition:all 400ms ease;-webkit-transform-origin:50% 0;-moz-transform-origin:50% 0;-ms-transform-origin:50% 0;transform-origin:50% 0;-webkit-transform-style:preserve-3d;-moz-transform-style:preserve-3d;-ms-transform-style:preserve-3d;transform-style:preserve-3d;-webkit-backface-visibility:hidden;-moz-backface-visibility:hidden;backface-visibility:hidden}.reveal .roll:hover span{background:rgba(0,0,0,.5);-webkit-transform:translate3d(0px,0,-45px) rotateX(90deg);-moz-transform:translate3d(0px,0,-45px) rotateX(90deg);-ms-transform:translate3d(0px,0,-45px) rotateX(90deg);transform:translate3d(0px,0,-45px) rotateX(90deg)}.reveal .roll span:after{content:attr(data-title);display:block;position:absolute;left:0;top:0;padding:0 2px;-webkit-transform-origin:50% 0;-moz-transform-origin:50% 0;-ms-transform-origin:50% 0;transform-origin:50% 0;-webkit-transform:translate3d(0px,110%,0) rotateX(-90deg);-moz-transform:translate3d(0px,110%,0) rotateX(-90deg);-ms-transform:translate3d(0px,110%,0) rotateX(-90deg);transform:translate3d(0px,110%,0) rotateX(-90deg)}.reveal{position:relative;width:100%;height:100%}.reveal .slides{position:absolute;width:100%;height:100%;left:50%;top:50%;overflow:visible;z-index:1;text-align:center;-webkit-transition:-webkit-perspective .4s ease;-moz-transition:-moz-perspective .4s ease;-ms-transition:-ms-perspective .4s ease;-o-transition:-o-perspective .4s ease;transition:perspective .4s ease;-webkit-perspective:600px;-moz-perspective:600px;-ms-perspective:600px;perspective:600px;-webkit-perspective-origin:0 -100px;-moz-perspective-origin:0 -100px;-ms-perspective-origin:0 -100px;perspective-origin:0 -100px}.reveal .slides>section,.reveal .slides>section>section{display:none;position:absolute;width:100%;padding:20px 0;z-index:10;line-height:1.2em;font-weight:400;-webkit-transform-style:preserve-3d;-moz-transform-style:preserve-3d;-ms-transform-style:preserve-3d;transform-style:preserve-3d;-webkit-transition:-webkit-transform-origin 800ms cubic-bezier(0.26,.86,.44,.985),-webkit-transform 800ms cubic-bezier(0.26,.86,.44,.985),visibility 800ms cubic-bezier(0.26,.86,.44,.985),opacity 800ms cubic-bezier(0.26,.86,.44,.985);-moz-transition:-moz-transform-origin 800ms cubic-bezier(0.26,.86,.44,.985),-moz-transform 800ms cubic-bezier(0.26,.86,.44,.985),visibility 800ms cubic-bezier(0.26,.86,.44,.985),opacity 800ms cubic-bezier(0.26,.86,.44,.985);-ms-transition:-ms-transform-origin 800ms cubic-bezier(0.26,.86,.44,.985),-ms-transform 800ms cubic-bezier(0.26,.86,.44,.985),visibility 800ms cubic-bezier(0.26,.86,.44,.985),opacity 800ms cubic-bezier(0.26,.86,.44,.985);-o-transition:-o-transform-origin 800ms cubic-bezier(0.26,.86,.44,.985),-o-transform 800ms cubic-bezier(0.26,.86,.44,.985),visibility 800ms cubic-bezier(0.26,.86,.44,.985),opacity 800ms cubic-bezier(0.26,.86,.44,.985);transition:transform-origin 800ms cubic-bezier(0.26,.86,.44,.985),transform 800ms cubic-bezier(0.26,.86,.44,.985),visibility 800ms cubic-bezier(0.26,.86,.44,.985),opacity 800ms cubic-bezier(0.26,.86,.44,.985)}.reveal .slides>section{left:-50%;top:-50%}.reveal .slides>section.stack{padding-top:0;padding-bottom:0}.reveal .slides>section.present,.reveal .slides>section>section.present{display:block;z-index:11;opacity:1}.reveal.center,.reveal.center .slides,.reveal.center .slides section{min-height:auto!important}.reveal .slides>section.past{display:block;opacity:0;-webkit-transform:translate3d(-100%,0,0) rotateY(-90deg) translate3d(-100%,0,0);-moz-transform:translate3d(-100%,0,0) rotateY(-90deg) translate3d(-100%,0,0);-ms-transform:translate3d(-100%,0,0) rotateY(-90deg) translate3d(-100%,0,0);transform:translate3d(-100%,0,0) rotateY(-90deg) translate3d(-100%,0,0)}.reveal .slides>section.future{display:block;opacity:0;-webkit-transform:translate3d(100%,0,0) rotateY(90deg) translate3d(100%,0,0);-moz-transform:translate3d(100%,0,0) rotateY(90deg) translate3d(100%,0,0);-ms-transform:translate3d(100%,0,0) rotateY(90deg) translate3d(100%,0,0);transform:translate3d(100%,0,0) rotateY(90deg) translate3d(100%,0,0)}.reveal .slides>section>section.past{display:block;opacity:0;-webkit-transform:translate3d(0,-300px,0) rotateX(70deg) translate3d(0,-300px,0);-moz-transform:translate3d(0,-300px,0) rotateX(70deg) translate3d(0,-300px,0);-ms-transform:translate3d(0,-300px,0) rotateX(70deg) translate3d(0,-300px,0);transform:translate3d(0,-300px,0) rotateX(70deg) translate3d(0,-300px,0)}.reveal .slides>section>section.future{display:block;opacity:0;-webkit-transform:translate3d(0,300px,0) rotateX(-70deg) translate3d(0,300px,0);-moz-transform:translate3d(0,300px,0) rotateX(-70deg) translate3d(0,300px,0);-ms-transform:translate3d(0,300px,0) rotateX(-70deg) translate3d(0,300px,0);transform:translate3d(0,300px,0) rotateX(-70deg) translate3d(0,300px,0)}.reveal.concave .slides>section.past{-webkit-transform:translate3d(-100%,0,0) rotateY(90deg) translate3d(-100%,0,0);-moz-transform:translate3d(-100%,0,0) rotateY(90deg) translate3d(-100%,0,0);-ms-transform:translate3d(-100%,0,0) rotateY(90deg) translate3d(-100%,0,0);transform:translate3d(-100%,0,0) rotateY(90deg) translate3d(-100%,0,0)}.reveal.concave .slides>section.future{-webkit-transform:translate3d(100%,0,0) rotateY(-90deg) translate3d(100%,0,0);-moz-transform:translate3d(100%,0,0) rotateY(-90deg) translate3d(100%,0,0);-ms-transform:translate3d(100%,0,0) rotateY(-90deg) translate3d(100%,0,0);transform:translate3d(100%,0,0) rotateY(-90deg) translate3d(100%,0,0)}.reveal.concave .slides>section>section.past{-webkit-transform:translate3d(0,-80%,0) rotateX(-70deg) translate3d(0,-80%,0);-moz-transform:translate3d(0,-80%,0) rotateX(-70deg) translate3d(0,-80%,0);-ms-transform:translate3d(0,-80%,0) rotateX(-70deg) translate3d(0,-80%,0);transform:translate3d(0,-80%,0) rotateX(-70deg) translate3d(0,-80%,0)}.reveal.concave .slides>section>section.future{-webkit-transform:translate3d(0,80%,0) rotateX(70deg) translate3d(0,80%,0);-moz-transform:translate3d(0,80%,0) rotateX(70deg) translate3d(0,80%,0);-ms-transform:translate3d(0,80%,0) rotateX(70deg) translate3d(0,80%,0);transform:translate3d(0,80%,0) rotateX(70deg) translate3d(0,80%,0)}.reveal.zoom .slides>section.past{opacity:0;visibility:hidden;-webkit-transform:scale(16);-moz-transform:scale(16);-ms-transform:scale(16);-o-transform:scale(16);transform:scale(16)}.reveal.zoom .slides>section.future{opacity:0;visibility:hidden;-webkit-transform:scale(0.2);-moz-transform:scale(0.2);-ms-transform:scale(0.2);-o-transform:scale(0.2);transform:scale(0.2)}.reveal.zoom .slides>section>section.past{-webkit-transform:translate(0,-150%);-moz-transform:translate(0,-150%);-ms-transform:translate(0,-150%);-o-transform:translate(0,-150%);transform:translate(0,-150%)}.reveal.zoom .slides>section>section.future{-webkit-transform:translate(0,150%);-moz-transform:translate(0,150%);-ms-transform:translate(0,150%);-o-transform:translate(0,150%);transform:translate(0,150%)}.reveal.linear .slides>section.past{-webkit-transform:translate(-150%,0);-moz-transform:translate(-150%,0);-ms-transform:translate(-150%,0);-o-transform:translate(-150%,0);transform:translate(-150%,0)}.reveal.linear .slides>section.future{-webkit-transform:translate(150%,0);-moz-transform:translate(150%,0);-ms-transform:translate(150%,0);-o-transform:translate(150%,0);transform:translate(150%,0)}.reveal.linear .slides>section>section.past{-webkit-transform:translate(0,-150%);-moz-transform:translate(0,-150%);-ms-transform:translate(0,-150%);-o-transform:translate(0,-150%);transform:translate(0,-150%)}.reveal.linear .slides>section>section.future{-webkit-transform:translate(0,150%);-moz-transform:translate(0,150%);-ms-transform:translate(0,150%);-o-transform:translate(0,150%);transform:translate(0,150%)}.reveal.cube .slides{-webkit-perspective:1300px;-moz-perspective:1300px;-ms-perspective:1300px;perspective:1300px}.reveal.cube .slides section{padding:30px;min-height:600px;-webkit-backface-visibility:hidden;-moz-backface-visibility:hidden;-ms-backface-visibility:hidden;backface-visibility:hidden;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.reveal.center.cube .slides section{min-height:auto}.reveal.cube .slides section:not(.stack):before{content:'';position:absolute;display:block;width:100%;height:100%;left:0;top:0;background:rgba(0,0,0,.1);border-radius:4px;-webkit-transform:translateZ(-20px);-moz-transform:translateZ(-20px);-ms-transform:translateZ(-20px);-o-transform:translateZ(-20px);transform:translateZ(-20px)}.reveal.cube .slides section:not(.stack):after{content:'';position:absolute;display:block;width:90%;height:30px;left:5%;bottom:0;background:0;z-index:1;border-radius:4px;box-shadow:0 95px 25px rgba(0,0,0,.2);-webkit-transform:translateZ(-90px) rotateX(65deg);-moz-transform:translateZ(-90px) rotateX(65deg);-ms-transform:translateZ(-90px) rotateX(65deg);-o-transform:translateZ(-90px) rotateX(65deg);transform:translateZ(-90px) rotateX(65deg)}.reveal.cube .slides>section.stack{padding:0;background:0}.reveal.cube .slides>section.past{-webkit-transform-origin:100% 0;-moz-transform-origin:100% 0;-ms-transform-origin:100% 0;transform-origin:100% 0;-webkit-transform:translate3d(-100%,0,0) rotateY(-90deg);-moz-transform:translate3d(-100%,0,0) rotateY(-90deg);-ms-transform:translate3d(-100%,0,0) rotateY(-90deg);transform:translate3d(-100%,0,0) rotateY(-90deg)}.reveal.cube .slides>section.future{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;-webkit-transform:translate3d(100%,0,0) rotateY(90deg);-moz-transform:translate3d(100%,0,0) rotateY(90deg);-ms-transform:translate3d(100%,0,0) rotateY(90deg);transform:translate3d(100%,0,0) rotateY(90deg)}.reveal.cube .slides>section>section.past{-webkit-transform-origin:0 100%;-moz-transform-origin:0 100%;-ms-transform-origin:0 100%;transform-origin:0 100%;-webkit-transform:translate3d(0,-100%,0) rotateX(90deg);-moz-transform:translate3d(0,-100%,0) rotateX(90deg);-ms-transform:translate3d(0,-100%,0) rotateX(90deg);transform:translate3d(0,-100%,0) rotateX(90deg)}.reveal.cube .slides>section>section.future{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;-webkit-transform:translate3d(0,100%,0) rotateX(-90deg);-moz-transform:translate3d(0,100%,0) rotateX(-90deg);-ms-transform:translate3d(0,100%,0) rotateX(-90deg);transform:translate3d(0,100%,0) rotateX(-90deg)}.reveal.page .slides{-webkit-perspective-origin:0 50%;-moz-perspective-origin:0 50%;-ms-perspective-origin:0 50%;perspective-origin:0 50%;-webkit-perspective:3000px;-moz-perspective:3000px;-ms-perspective:3000px;perspective:3000px}.reveal.page .slides section{padding:30px;min-height:600px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.reveal.page .slides section.past{z-index:12}.reveal.page .slides section:not(.stack):before{content:'';position:absolute;display:block;width:100%;height:100%;left:0;top:0;background:rgba(0,0,0,.1);-webkit-transform:translateZ(-20px);-moz-transform:translateZ(-20px);-ms-transform:translateZ(-20px);-o-transform:translateZ(-20px);transform:translateZ(-20px)}.reveal.page .slides section:not(.stack):after{content:'';position:absolute;display:block;width:90%;height:30px;left:5%;bottom:0;background:0;z-index:1;border-radius:4px;box-shadow:0 95px 25px rgba(0,0,0,.2);-webkit-transform:translateZ(-90px) rotateX(65deg)}.reveal.page .slides>section.stack{padding:0;background:0}.reveal.page .slides>section.past{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;-webkit-transform:translate3d(-40%,0,0) rotateY(-80deg);-moz-transform:translate3d(-40%,0,0) rotateY(-80deg);-ms-transform:translate3d(-40%,0,0) rotateY(-80deg);transform:translate3d(-40%,0,0) rotateY(-80deg)}.reveal.page .slides>section.future{-webkit-transform-origin:100% 0;-moz-transform-origin:100% 0;-ms-transform-origin:100% 0;transform-origin:100% 0;-webkit-transform:translate3d(0,0,0);-moz-transform:translate3d(0,0,0);-ms-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}.reveal.page .slides>section>section.past{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;-webkit-transform:translate3d(0,-40%,0) rotateX(80deg);-moz-transform:translate3d(0,-40%,0) rotateX(80deg);-ms-transform:translate3d(0,-40%,0) rotateX(80deg);transform:translate3d(0,-40%,0) rotateX(80deg)}.reveal.page .slides>section>section.future{-webkit-transform-origin:0 100%;-moz-transform-origin:0 100%;-ms-transform-origin:0 100%;transform-origin:0 100%;-webkit-transform:translate3d(0,0,0);-moz-transform:translate3d(0,0,0);-ms-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}.reveal.fade .slides section,.reveal.fade .slides>section>section{-webkit-transform:none;-moz-transform:none;-ms-transform:none;-o-transform:none;transform:none;-webkit-transition:opacity .5s;-moz-transition:opacity .5s;-ms-transition:opacity .5s;-o-transition:opacity .5s;transition:opacity .5s}.reveal.fade.overview .slides section,.reveal.fade.overview .slides>section>section,.reveal.fade.exit-overview .slides section,.reveal.fade.exit-overview .slides>section>section{-webkit-transition:none;-moz-transition:none;-ms-transition:none;-o-transition:none;transition:none}.reveal.none .slides section{-webkit-transform:none;-moz-transform:none;-ms-transform:none;-o-transform:none;transform:none;-webkit-transition:none;-moz-transition:none;-ms-transition:none;-o-transition:none;transition:none}.reveal.overview .slides{-webkit-perspective-origin:0 0;-moz-perspective-origin:0 0;-ms-perspective-origin:0 0;perspective-origin:0 0;-webkit-perspective:700px;-moz-perspective:700px;-ms-perspective:700px;perspective:700px}.reveal.overview .slides section{height:600px;overflow:hidden;opacity:1!important;visibility:visible!important;cursor:pointer;background:rgba(0,0,0,.1)}.reveal.overview .slides section .fragment{opacity:1}.reveal.overview .slides section:after,.reveal.overview .slides section:before{display:none!important}.reveal.overview .slides section>section{opacity:1;cursor:pointer}.reveal.overview .slides section:hover{background:rgba(0,0,0,.3)}.reveal.overview .slides section.present{background:rgba(0,0,0,.3)}.reveal.overview .slides>section.stack{padding:0;background:0;overflow:visible}.reveal .pause-overlay{position:absolute;top:0;left:0;width:100%;height:100%;background:#000;visibility:hidden;opacity:0;z-index:100;-webkit-transition:all 1s ease;-moz-transition:all 1s ease;-ms-transition:all 1s ease;-o-transition:all 1s ease;transition:all 1s ease}.reveal.paused .pause-overlay{visibility:visible;opacity:1}.no-transforms{overflow-y:auto}.no-transforms .slides{width:80%;top:0;left:50%;margin:0;text-align:center}.no-transforms .slides section{display:block!important;opacity:1!important;position:relative!important;height:auto;min-height:auto;top:0;left:-50%;margin:70px 0;-webkit-transform:none;-moz-transform:none;-ms-transform:none;transform:none}.no-transforms .slides section section{left:0}.no-transition{-webkit-transition:none;-moz-transition:none;-ms-transition:none;-o-transition:none;transition:none}.reveal .state-background{position:absolute;width:100%;height:100%;background:rgba(0,0,0,0);-webkit-transition:background 800ms ease;-moz-transition:background 800ms ease;-ms-transition:background 800ms ease;-o-transition:background 800ms ease;transition:background 800ms ease}.alert .reveal .state-background{background:rgba(200,50,30,.6)}.soothe .reveal .state-background{background:rgba(50,200,90,.4)}.blackout .reveal .state-background{background:rgba(0,0,0,.6)}.reveal.rtl .slides,.reveal.rtl .slides h1,.reveal.rtl .slides h2,.reveal.rtl .slides h3,.reveal.rtl .slides h4,.reveal.rtl .slides h5,.reveal.rtl .slides h6{direction:rtl;font-family:sans-serif}.reveal.rtl pre,.reveal.rtl code{direction:ltr}.reveal.rtl ol,.reveal.rtl ul{text-align:right}.reveal aside.notes{display:none}.zoomed .reveal *,.zoomed .reveal :before,.zoomed .reveal :after{-webkit-transform:none!important;-moz-transform:none!important;-ms-transform:none!important;transform:none!important;-webkit-backface-visibility:visible!important;-moz-backface-visibility:visible!important;-ms-backface-visibility:visible!important;backface-visibility:visible!important}.zoomed .reveal .progress,.zoomed .reveal .controls{opacity:0}.zoomed .reveal .roll span{background:0}.zoomed .reveal .roll span:after{visibility:hidden} \ No newline at end of file diff --git a/gruntfile.js b/gruntfile.js index bb86019..bd6858a 100644 --- a/gruntfile.js +++ b/gruntfile.js @@ -5,7 +5,7 @@ module.exports = function(grunt) { grunt.initConfig({ pkg: grunt.file.readJSON('package.json'), meta: { - banner: + banner: '/*!\n' + ' * reveal.js <%= pkg.version %> (<%= grunt.template.today("yyyy-mm-dd, HH:MM") %>)\n' + ' * http://lab.hakim.se/reveal-js\n' + @@ -25,13 +25,13 @@ module.exports = function(grunt) { }, uglify: { - options: { - banner: '<%= meta.banner %> \n' - }, - build: { - src: 'js/reveal.js', - dest: 'js/reveal.min.js' - } + options: { + banner: '<%= meta.banner %>\n' + }, + build: { + src: 'js/reveal.js', + dest: 'js/reveal.min.js' + } }, cssmin: { @@ -80,4 +80,3 @@ module.exports = function(grunt) { grunt.registerTask( 'default', [ 'jshint', 'cssmin', 'uglify' ] ); }; - \ No newline at end of file diff --git a/js/reveal.min.js b/js/reveal.min.js index 5c19b22..5fd0c86 100644 --- a/js/reveal.min.js +++ b/js/reveal.min.js @@ -1,8 +1,8 @@ /*! - * reveal.js 2.3 (2013-02-24, 11:58) + * reveal.js 2.3.0 (2013-02-27, 13:19) * http://lab.hakim.se/reveal-js * MIT licensed * * Copyright (C) 2013 Hakim El Hattab, http://hakim.se */ -var Reveal=function(){"use strict";function S(e){if(!d&&!p){document.body.setAttribute("class","no-transforms");return}window.addEventListener("load",j,!1),O(i,e),T(),N()}function x(){h.theme=document.querySelector("#theme"),h.wrapper=document.querySelector(".reveal"),h.slides=document.querySelector(".reveal .slides");if(!h.wrapper.querySelector(".progress")&&i.progress){var e=document.createElement("div");e.classList.add("progress"),e.innerHTML="",h.wrapper.appendChild(e)}if(!h.wrapper.querySelector(".controls")&&i.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='',h.wrapper.appendChild(t)}if(!h.wrapper.querySelector(".state-background")){var n=document.createElement("div");n.classList.add("state-background"),h.wrapper.appendChild(n)}if(!h.wrapper.querySelector(".pause-overlay")){var r=document.createElement("div");r.classList.add("pause-overlay"),h.wrapper.appendChild(r)}h.progress=document.querySelector(".reveal .progress"),h.progressbar=document.querySelector(".reveal .progress span"),i.controls&&(h.controls=document.querySelector(".reveal .controls"),h.controlsLeft=M(document.querySelectorAll(".navigate-left")),h.controlsRight=M(document.querySelectorAll(".navigate-right")),h.controlsUp=M(document.querySelectorAll(".navigate-up")),h.controlsDown=M(document.querySelectorAll(".navigate-down")),h.controlsPrev=M(document.querySelectorAll(".navigate-prev")),h.controlsNext=M(document.querySelectorAll(".navigate-next")))}function T(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",D,!1),window.addEventListener("orientationchange",D,!1))}function N(){function o(){t.length&&head.js.apply(null,t),C()}var e=[],t=[];for(var n=0,r=i.dependencies.length;n3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),ot&&n[o].classList.add("future"),u.querySelector("section")&&n[o].classList.add("stack")}n[t].classList.add("present");var f=n[t].getAttribute("data-state");f&&(l=l.concat(f.split(" ")));var c=n[t].getAttribute("data-autoslide");c?s=parseInt(c,10):s=i.autoSlide}else t=0;return t}function G(){if(i.progress&&h.progress){var n=M(document.querySelectorAll(t)),r=document.querySelectorAll(e+":not(.stack)").length,s=0;e:for(var o=0;o0,right:o0,down:u0||u>0)t+=o;u>0&&(t+="/"+u)}window.location.hash=t}}}function nt(e){var n=o,r=u;if(e){var i=!!e.parentNode.nodeName.match(/section/gi),s=i?e.parentNode:e,a=M(document.querySelectorAll(t));n=Math.max(a.indexOf(s),0),i&&(r=Math.max(M(e.parentNode.querySelectorAll("section")).indexOf(e),0))}return{h:n,v:r}}function rt(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment:not(.visible)");if(e.length)return e[0].classList.add("visible"),P("fragmentshown",{fragment:e[0]}),!0}else{var r=document.querySelectorAll(t+".present .fragment:not(.visible)");if(r.length)return r[0].classList.add("visible"),P("fragmentshown",{fragment:r[0]}),!0}return!1}function it(){if(document.querySelector(n+".present")){var e=document.querySelectorAll(n+".present .fragment.visible");if(e.length)return e[e.length-1].classList.remove("visible"),P("fragmenthidden",{fragment:e[e.length-1]}),!0}else{var r=document.querySelectorAll(t+".present .fragment.visible");if(r.length)return r[r.length-1].classList.remove("visible"),P("fragmenthidden",{fragment:r[r.length-1]}),!0}return!1}function st(){clearTimeout(m),s&&!J()&&!z()&&(m=setTimeout(ht,s))}function ot(){clearTimeout(m)}function ut(){(Z().left&&z()||it()===!1)&&K(o-1)}function at(){(Z().right&&z()||rt()===!1)&&K(o+1)}function ft(){(Z().up&&z()||it()===!1)&&K(o,u-1)}function lt(){(Z().down&&z()||rt()===!1)&&K(o,u+1)}function ct(){if(it()===!1)if(Z().up)ft();else{var e=document.querySelector(t+".past:nth-child("+o+")");e&&(u=e.querySelectorAll("section").length+1||undefined,o--,K())}}function ht(){rt()===!1&&(Z().down?lt():at()),st()}function pt(e){var t=document.activeElement,n=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&document.activeElement.contentEditable==="inherit");if(n||e.shiftKey||e.altKey||e.ctrlKey||e.metaKey)return;var r=!0;if(J()&&[66,190,191].indexOf(e.keyCode)===-1)return!1;switch(e.keyCode){case 80:case 33:ct();break;case 78:case 34:ht();break;case 72:case 37:ut();break;case 76:case 39:at();break;case 75:case 38:ft();break;case 74:case 40:lt();break;case 36:K(0);break;case 35:K(Number.MAX_VALUE);break;case 32:z()?R():ht();break;case 13:z()?R():r=!1;break;case 66:case 190:case 191:$();break;case 70:W();break;default:r=!1}r?e.preventDefault():e.keyCode===27&&p&&(U(),e.preventDefault()),st()}function dt(e){E.startX=e.touches[0].clientX,E.startY=e.touches[0].clientY,E.startCount=e.touches.length,e.touches.length===2&&i.overview&&(E.startSpan=_({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:E.startX,y:E.startY}))}function vt(e){if(!E.handled){var t=e.touches[0].clientX,n=e.touches[0].clientY;if(e.touches.length===2&&E.startCount===2&&i.overview){var r=_({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:E.startX,y:E.startY});Math.abs(E.startSpan-r)>E.threshold&&(E.handled=!0,rE.threshold&&Math.abs(s)>Math.abs(o)?(E.handled=!0,ut()):s<-E.threshold&&Math.abs(s)>Math.abs(o)?(E.handled=!0,at()):o>E.threshold?(E.handled=!0,ft()):o<-E.threshold&&(E.handled=!0,lt()),e.preventDefault()}}else navigator.userAgent.match(/android/gi)&&e.preventDefault()}function mt(e){E.handled=!1}function gt(e){clearTimeout(v),v=setTimeout(function(){var t=e.detail||-e.wheelDelta;t>0?ht():ct()},100)}function yt(e){e.preventDefault();var n=M(document.querySelectorAll(t)).length,r=Math.floor(e.clientX/h.wrapper.offsetWidth*n);K(r)}function bt(e){e.preventDefault(),ut()}function wt(e){e.preventDefault(),at()}function Et(e){e.preventDefault(),ft()}function St(e){e.preventDefault(),lt()}function xt(e){e.preventDefault(),ct()}function Tt(e){e.preventDefault(),ht()}function Nt(e){et()}function Ct(e){j()}function kt(e){if(w&&z()){e.preventDefault();var t=e.target;while(t&&!t.nodeName.match(/section/gi))t=t.parentNode;if(t&&!t.classList.contains("disabled")){R();if(t.nodeName.match(/section/gi)){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);K(n,r)}}}}var e=".reveal .slides section",t=".reveal .slides>section",n=".reveal .slides>section.present>section",r=".reveal .slides>section:first-child",i={width:960,height:700,margin:.1,minScale:.2,maxScale:1,controls:!0,progress:!0,history:!1,keyboard:!0,overview:!0,center:!0,touch:!0,loop:!1,rtl:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!0,theme:null,transition:"default",dependencies:[]},s=i.autoSlide,o=0,u=0,a,f,l=[],c=1,h={},p="WebkitPerspective"in document.body.style||"MozPerspective"in document.body.style||"msPerspective"in document.body.style||"OPerspective"in document.body.style||"perspective"in document.body.style,d="WebkitTransform"in document.body.style||"MozTransform"in document.body.style||"msTransform"in document.body.style||"OTransform"in document.body.style||"transform"in document.body.style,v=0,m=0,g=0,y=0,b=0,w=!1,E={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:S,configure:k,slide:K,left:ut,right:at,up:ft,down:lt,prev:ct,next:ht,prevFragment:it,nextFragment:rt,navigateTo:K,navigateLeft:ut,navigateRight:at,navigateUp:ft,navigateDown:lt,navigatePrev:ct,navigateNext:ht,layout:j,toggleOverview:U,togglePause:$,isOverview:z,isPaused:J,addEventListeners:L,removeEventListeners:A,getIndices:nt,getSlide:function(e,n){var r=document.querySelectorAll(t)[e],i=r&&r.querySelectorAll("section");return typeof n!="undefined"?i?i[n]:undefined:r},getPreviousSlide:function(){return a},getCurrentSlide:function(){return f},getScale:function(){return c},getQueryHash:function(){var e={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(t){e[t.split("=").shift()]=t.split("=").pop()}),e},isFirstSlide:function(){return document.querySelector(e+".past")==null?!0:!1},isLastSlide:function(){return f&&f.classList.contains(".stack")?f.querySelector(e+".future")==null?!0:!1:document.querySelector(e+".future")==null?!0:!1},addEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(h.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file +var Reveal=function(){"use strict";function e(e){return wt||Lt?(window.addEventListener("load",p,!1),c(vt,e),n(),r(),void 0):(document.body.setAttribute("class","no-transforms"),void 0)}function t(){if(gt.theme=document.querySelector("#theme"),gt.wrapper=document.querySelector(".reveal"),gt.slides=document.querySelector(".reveal .slides"),!gt.wrapper.querySelector(".progress")&&vt.progress){var e=document.createElement("div");e.classList.add("progress"),e.innerHTML="",gt.wrapper.appendChild(e)}if(!gt.wrapper.querySelector(".controls")&&vt.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='',gt.wrapper.appendChild(t)}if(!gt.wrapper.querySelector(".state-background")){var n=document.createElement("div");n.classList.add("state-background"),gt.wrapper.appendChild(n)}if(!gt.wrapper.querySelector(".pause-overlay")){var r=document.createElement("div");r.classList.add("pause-overlay"),gt.wrapper.appendChild(r)}gt.progress=document.querySelector(".reveal .progress"),gt.progressbar=document.querySelector(".reveal .progress span"),vt.controls&&(gt.controls=document.querySelector(".reveal .controls"),gt.controlsLeft=l(document.querySelectorAll(".navigate-left")),gt.controlsRight=l(document.querySelectorAll(".navigate-right")),gt.controlsUp=l(document.querySelectorAll(".navigate-up")),gt.controlsDown=l(document.querySelectorAll(".navigate-down")),gt.controlsPrev=l(document.querySelectorAll(".navigate-prev")),gt.controlsNext=l(document.querySelectorAll(".navigate-next")))}function n(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",u,!1),window.addEventListener("orientationchange",u,!1))}function r(){function e(){n.length&&head.js.apply(null,n),o()}for(var t=[],n=[],r=0,s=vt.dependencies.length;s>r;r++){var a=vt.dependencies[r];(!a.condition||a.condition())&&(a.async?n.push(a.src):t.push(a.src),"function"==typeof a.callback&&head.ready(a.src.match(/([\w\d_\-]*)\.?js$|[^\\\/]*$/i)[0],a.callback))}t.length?(head.ready(e),head.js.apply(null,t)):e()}function o(){t(),a(),s(),p(),C(),I(),setTimeout(function(){v("ready",{indexh:mt,indexv:pt,currentSlide:it})},1)}function s(e){if(gt.wrapper.classList.remove(vt.transition),"object"==typeof e&&c(vt,e),Lt===!1&&(vt.transition="linear"),gt.wrapper.classList.add(vt.transition),gt.controls.style.display=vt.controls&>.controls?"block":"none",gt.progress.style.display=vt.progress&>.progress?"block":"none",gt.wrapper.classList.toggle("rtl",vt.rtl),gt.wrapper.classList.toggle("center",vt.center),vt.mouseWheel?(document.addEventListener("DOMMouseScroll",Q,!1),document.addEventListener("mousewheel",Q,!1)):(document.removeEventListener("DOMMouseScroll",Q,!1),document.removeEventListener("mousewheel",Q,!1)),vt.rollingLinks?f():m(),vt.theme&>.theme){var t=gt.theme.getAttribute("href"),n=/[^\/]*?(?=\.css)/,r=t.match(n)[0];vt.theme!==r&&(t=t.replace(n,vt.theme),gt.theme.setAttribute("href",t))}}function a(){if(At=!0,window.addEventListener("hashchange",rt,!1),window.addEventListener("resize",ot,!1),vt.touch&&(document.addEventListener("touchstart",$,!1),document.addEventListener("touchmove",Z,!1),document.addEventListener("touchend",_,!1)),vt.keyboard&&document.addEventListener("keydown",K,!1),vt.progress&>.progress&>.progress.addEventListener("click",V,!1),vt.controls&>.controls){var e="ontouchstart"in window&&null!=window.ontouchstart?"touchstart":"click";gt.controlsLeft.forEach(function(t){t.addEventListener(e,B,!1)}),gt.controlsRight.forEach(function(t){t.addEventListener(e,G,!1)}),gt.controlsUp.forEach(function(t){t.addEventListener(e,J,!1)}),gt.controlsDown.forEach(function(t){t.addEventListener(e,et,!1)}),gt.controlsPrev.forEach(function(t){t.addEventListener(e,tt,!1)}),gt.controlsNext.forEach(function(t){t.addEventListener(e,nt,!1)})}}function i(){if(At=!1,document.removeEventListener("keydown",K,!1),window.removeEventListener("hashchange",rt,!1),window.removeEventListener("resize",ot,!1),vt.touch&&(document.removeEventListener("touchstart",$,!1),document.removeEventListener("touchmove",Z,!1),document.removeEventListener("touchend",_,!1)),vt.progress&>.progress&>.progress.removeEventListener("click",V,!1),vt.controls&>.controls){var e="ontouchstart"in window&&null!=window.ontouchstart?"touchstart":"click";gt.controlsLeft.forEach(function(t){t.removeEventListener(e,B,!1)}),gt.controlsRight.forEach(function(t){t.removeEventListener(e,G,!1)}),gt.controlsUp.forEach(function(t){t.removeEventListener(e,J,!1)}),gt.controlsDown.forEach(function(t){t.removeEventListener(e,et,!1)}),gt.controlsPrev.forEach(function(t){t.removeEventListener(e,tt,!1)}),gt.controlsNext.forEach(function(t){t.removeEventListener(e,nt,!1)})}}function c(e,t){for(var n in t)e[n]=t[n]}function l(e){return Array.prototype.slice.call(e)}function d(e,t){var n=e.x-t.x,r=e.y-t.y;return Math.sqrt(n*n+r*r)}function u(){0===window.orientation?(document.documentElement.style.overflow="scroll",document.body.style.height="120%"):(document.documentElement.style.overflow="",document.body.style.height="100%"),setTimeout(function(){window.scrollTo(0,1)},10)}function v(e,t){var n=document.createEvent("HTMLEvents",1,2);n.initEvent(e,!0,!0),c(n,t),gt.wrapper.dispatchEvent(n)}function f(){if(Lt&&!("msPerspective"in document.body.style))for(var e=document.querySelectorAll(ct+" a:not(.image)"),t=0,n=e.length;n>t;t++){var r=e[t];if(!(!r.textContent||r.querySelector("*")||r.className&&r.classList.contains(r,"roll"))){var o=document.createElement("span");o.setAttribute("data-title",r.text),o.innerHTML=r.innerHTML,r.classList.add("roll"),r.innerHTML="",r.appendChild(o)}}}function m(){for(var e=document.querySelectorAll(ct+" a.roll"),t=0,n=e.length;n>t;t++){var r=e[t],o=r.querySelector("span");o&&(r.classList.remove("roll"),r.innerHTML=o.innerHTML)}}function p(){if(gt.wrapper){var e=gt.wrapper.offsetWidth,t=gt.wrapper.offsetHeight;e-=t*vt.margin,t-=t*vt.margin;var n=vt.width,r=vt.height;if("string"==typeof n&&/%$/.test(n)&&(n=parseInt(n,10)/100*e),"string"==typeof r&&/%$/.test(r)&&(r=parseInt(r,10)/100*t),gt.slides.style.width=n+"px",gt.slides.style.height=r+"px",yt=Math.min(e/n,t/r),yt=Math.max(yt,vt.minScale),yt=Math.min(yt,vt.maxScale),void 0===gt.slides.style.zoom||navigator.userAgent.match(/(iphone|ipod|ipad|android)/gi)){var o="translate(-50%, -50%) scale("+yt+") translate(50%, 50%)";gt.slides.style.WebkitTransform=o,gt.slides.style.MozTransform=o,gt.slides.style.msTransform=o,gt.slides.style.OTransform=o,gt.slides.style.transform=o}else gt.slides.style.zoom=yt;for(var s=l(document.querySelectorAll(ct)),a=0,i=s.length;i>a;a++){var c=s[a];"none"!==c.style.display&&(c.style.top=vt.center?c.classList.contains("stack")?0:Math.max(-(c.offsetHeight/2)-20,-r/2)+"px":"")}}}function h(e,t){e&&e.setAttribute("data-previous-indexv",t||0)}function y(e){return e&&e.classList.contains("stack")?parseInt(e.getAttribute("data-previous-indexv")||0,10):0}function g(){if(vt.overview){R();var e=gt.wrapper.classList.contains("overview");gt.wrapper.classList.add("overview"),gt.wrapper.classList.remove("exit-overview"),clearTimeout(qt),clearTimeout(kt),qt=setTimeout(function(){for(var t=document.querySelectorAll(lt),n=0,r=t.length;r>n;n++){var o=t[n],s="translateZ(-2500px) translate("+105*(n-mt)+"%, 0%)";if(o.setAttribute("data-index-h",n),o.style.display="block",o.style.WebkitTransform=s,o.style.MozTransform=s,o.style.msTransform=s,o.style.OTransform=s,o.style.transform=s,o.classList.contains("stack"))for(var a=o.querySelectorAll("section"),i=0,c=a.length;c>i;i++){var l=n===mt?pt:y(o),d=a[i],u="translate(0%, "+105*(i-l)+"%)";d.setAttribute("data-index-h",n),d.setAttribute("data-index-v",i),d.style.display="block",d.style.WebkitTransform=u,d.style.MozTransform=u,d.style.msTransform=u,d.style.OTransform=u,d.style.transform=u,d.addEventListener("click",st,!0)}else o.addEventListener("click",st,!0)}p(),e||v("overviewshown",{indexh:mt,indexv:pt,currentSlide:it})},10)}}function L(){if(vt.overview){clearTimeout(qt),clearTimeout(kt),gt.wrapper.classList.remove("overview"),gt.wrapper.classList.add("exit-overview"),kt=setTimeout(function(){gt.wrapper.classList.remove("exit-overview")},10);for(var e=l(document.querySelectorAll(ct)),t=0,n=e.length;n>t;t++){var r=e[t];r.style.display="",r.style.WebkitTransform="",r.style.MozTransform="",r.style.msTransform="",r.style.OTransform="",r.style.transform="",r.removeEventListener("click",st,!0)}x(mt,pt),I(),v("overviewhidden",{indexh:mt,indexv:pt,currentSlide:it})}}function w(e){"boolean"==typeof e?e?g():L():b()?L():g()}function b(){return gt.wrapper.classList.contains("overview")}function E(){var e=document.body,t=e.requestFullScreen||e.webkitRequestFullScreen||e.mozRequestFullScreen||e.msRequestFullScreen;t&&t.apply(e)}function S(){R(),gt.wrapper.classList.add("paused")}function q(){I(),gt.wrapper.classList.remove("paused")}function k(){A()?q():S()}function A(){return gt.wrapper.classList.contains("paused")}function x(e,t,n){at=it;var r=document.querySelectorAll(lt);void 0===t&&(t=y(r[e])),at&&at.parentNode&&at.parentNode.classList.contains("stack")&&h(at.parentNode,pt);var o=ht.concat();ht.length=0;var s=mt,a=pt;mt=T(lt,void 0===e?mt:e),pt=T(dt,void 0===t?pt:t),p();e:for(var i=0,c=ht.length;c>i;i++){for(var d=0;o.length>d;d++)if(o[d]===ht[i]){o.splice(d,1);continue e}document.documentElement.classList.add(ht[i]),v(ht[i])}for(;o.length;)document.documentElement.classList.remove(o.pop());b()&&g(),P(1500);var u=r[mt],f=u.querySelectorAll("section");if(it=f[pt]||u,n!==void 0){var m=it.querySelectorAll(".fragment");l(m).forEach(function(e,t){n>t?e.classList.add("visible"):e.classList.remove("visible")})}mt!==s||pt!==a?v("slidechanged",{indexh:mt,indexv:pt,previousSlide:at,currentSlide:it}):at=null,at&&(at.classList.remove("present"),document.querySelector(ut).classList.contains("present")&&setTimeout(function(){var e,t=l(document.querySelectorAll(lt+".stack"));for(e in t)t[e]&&h(t[e],0)},0)),D(),M()}function T(e,t){var n=l(document.querySelectorAll(e)),r=n.length;if(r){vt.loop&&(t%=r,0>t&&(t=r+t)),t=Math.max(Math.min(t,r-1),0);for(var o=0;r>o;o++){var s=n[o];if(b()===!1){var a=Math.abs((t-o)%(r-3))||0;s.style.display=a>3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),t>o?n[o].classList.add("past"):o>t&&n[o].classList.add("future"),s.querySelector("section")&&n[o].classList.add("stack")}n[t].classList.add("present");var i=n[t].getAttribute("data-state");i&&(ht=ht.concat(i.split(" ")));var c=n[t].getAttribute("data-autoslide");ft=c?parseInt(c,10):vt.autoSlide}else t=0;return t}function M(){if(vt.progress&>.progress){var e=l(document.querySelectorAll(lt)),t=document.querySelectorAll(ct+":not(.stack)").length,n=0;e:for(var r=0;e.length>r;r++){for(var o=e[r],s=l(o.querySelectorAll("section")),a=0;s.length>a;a++){if(s[a].classList.contains("present"))break e;n++}if(o.classList.contains("present"))break;o.classList.contains("stack")===!1&&n++}gt.progressbar.style.width=n/(t-1)*window.innerWidth+"px"}}function D(){if(vt.controls&>.controls){var e=N();gt.controlsLeft.concat(gt.controlsRight).concat(gt.controlsUp).concat(gt.controlsDown).concat(gt.controlsPrev).concat(gt.controlsNext).forEach(function(e){e.classList.remove("enabled")}),e.left&>.controlsLeft.forEach(function(e){e.classList.add("enabled")}),e.right&>.controlsRight.forEach(function(e){e.classList.add("enabled")}),e.up&>.controlsUp.forEach(function(e){e.classList.add("enabled")}),e.down&>.controlsDown.forEach(function(e){e.classList.add("enabled")}),(e.left||e.up)&>.controlsPrev.forEach(function(e){e.classList.add("enabled")}),(e.right||e.down)&>.controlsNext.forEach(function(e){e.classList.add("enabled")})}}function N(){var e=document.querySelectorAll(lt),t=document.querySelectorAll(dt);return{left:mt>0,right:e.length-1>mt,up:pt>0,down:t.length-1>pt}}function C(){var e=window.location.hash,t=e.slice(2).split("/"),n=e.replace(/#|\//gi,"");if(isNaN(parseInt(t[0],10))&&n.length){var r=document.querySelector("#"+n);if(r){var o=Reveal.getIndices(r);x(o.h,o.v)}else x(mt,pt)}else{var s=parseInt(t[0],10)||0,a=parseInt(t[1],10)||0;x(s,a)}}function P(e){if(vt.history)if(clearTimeout(St),"number"==typeof e)St=setTimeout(P,e);else{var t="/";it&&"string"==typeof it.getAttribute("id")?t="/"+it.getAttribute("id"):((mt>0||pt>0)&&(t+=mt),pt>0&&(t+="/"+pt)),window.location.hash=t}}function O(e){var t=mt,n=pt;if(e){var r=!!e.parentNode.nodeName.match(/section/gi),o=r?e.parentNode:e,s=l(document.querySelectorAll(lt));t=Math.max(s.indexOf(o),0),r&&(n=Math.max(l(e.parentNode.querySelectorAll("section")).indexOf(e),0))}return{h:t,v:n}}function z(){if(document.querySelector(dt+".present")){var e=document.querySelectorAll(dt+".present .fragment:not(.visible)");if(e.length)return e[0].classList.add("visible"),v("fragmentshown",{fragment:e[0]}),!0}else{var t=document.querySelectorAll(lt+".present .fragment:not(.visible)");if(t.length)return t[0].classList.add("visible"),v("fragmentshown",{fragment:t[0]}),!0}return!1}function H(){if(document.querySelector(dt+".present")){var e=document.querySelectorAll(dt+".present .fragment.visible");if(e.length)return e[e.length-1].classList.remove("visible"),v("fragmenthidden",{fragment:e[e.length-1]}),!0}else{var t=document.querySelectorAll(lt+".present .fragment.visible");if(t.length)return t[t.length-1].classList.remove("visible"),v("fragmenthidden",{fragment:t[t.length-1]}),!0}return!1}function I(){clearTimeout(Et),!ft||A()||b()||(Et=setTimeout(j,ft))}function R(){clearTimeout(Et)}function W(){(N().left&&b()||H()===!1)&&x(mt-1)}function X(){(N().right&&b()||z()===!1)&&x(mt+1)}function Y(){(N().up&&b()||H()===!1)&&x(mt,pt-1)}function F(){(N().down&&b()||z()===!1)&&x(mt,pt+1)}function U(){if(H()===!1)if(N().up)Y();else{var e=document.querySelector(lt+".past:nth-child("+mt+")");e&&(pt=e.querySelectorAll("section").length+1||void 0,mt--,x())}}function j(){z()===!1&&(N().down?F():X()),I()}function K(e){document.activeElement;var t=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&"inherit"===document.activeElement.contentEditable);if(!(t||e.shiftKey||e.altKey||e.ctrlKey||e.metaKey)){var n=!0;if(A()&&-1===[66,190,191].indexOf(e.keyCode))return!1;switch(e.keyCode){case 80:case 33:U();break;case 78:case 34:j();break;case 72:case 37:W();break;case 76:case 39:X();break;case 75:case 38:Y();break;case 74:case 40:F();break;case 36:x(0);break;case 35:x(Number.MAX_VALUE);break;case 32:b()?L():j();break;case 13:b()?L():n=!1;break;case 66:case 190:case 191:k();break;case 70:E();break;default:n=!1}n?e.preventDefault():27===e.keyCode&&Lt&&(w(),e.preventDefault()),I()}}function $(e){xt.startX=e.touches[0].clientX,xt.startY=e.touches[0].clientY,xt.startCount=e.touches.length,2===e.touches.length&&vt.overview&&(xt.startSpan=d({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:xt.startX,y:xt.startY}))}function Z(e){if(xt.handled)navigator.userAgent.match(/android/gi)&&e.preventDefault();else{var t=e.touches[0].clientX,n=e.touches[0].clientY;if(2===e.touches.length&&2===xt.startCount&&vt.overview){var r=d({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:xt.startX,y:xt.startY});Math.abs(xt.startSpan-r)>xt.threshold&&(xt.handled=!0,xt.startSpan>r?g():L()),e.preventDefault()}else if(1===e.touches.length&&2!==xt.startCount){var o=t-xt.startX,s=n-xt.startY;o>xt.threshold&&Math.abs(o)>Math.abs(s)?(xt.handled=!0,W()):-xt.threshold>o&&Math.abs(o)>Math.abs(s)?(xt.handled=!0,X()):s>xt.threshold?(xt.handled=!0,Y()):-xt.threshold>s&&(xt.handled=!0,F()),e.preventDefault()}}}function _(){xt.handled=!1}function Q(e){clearTimeout(bt),bt=setTimeout(function(){var t=e.detail||-e.wheelDelta;t>0?j():U()},100)}function V(e){e.preventDefault();var t=l(document.querySelectorAll(lt)).length,n=Math.floor(e.clientX/gt.wrapper.offsetWidth*t);x(n)}function B(e){e.preventDefault(),W()}function G(e){e.preventDefault(),X()}function J(e){e.preventDefault(),Y()}function et(e){e.preventDefault(),F()}function tt(e){e.preventDefault(),U()}function nt(e){e.preventDefault(),j()}function rt(){C()}function ot(){p()}function st(e){if(At&&b()){e.preventDefault();for(var t=e.target;t&&!t.nodeName.match(/section/gi);)t=t.parentNode;if(t&&!t.classList.contains("disabled")&&(L(),t.nodeName.match(/section/gi))){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);x(n,r)}}}var at,it,ct=".reveal .slides section",lt=".reveal .slides>section",dt=".reveal .slides>section.present>section",ut=".reveal .slides>section:first-child",vt={width:960,height:700,margin:.1,minScale:.2,maxScale:1,controls:!0,progress:!0,history:!1,keyboard:!0,overview:!0,center:!0,touch:!0,loop:!1,rtl:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!0,theme:null,transition:"default",dependencies:[]},ft=vt.autoSlide,mt=0,pt=0,ht=[],yt=1,gt={},Lt="WebkitPerspective"in document.body.style||"MozPerspective"in document.body.style||"msPerspective"in document.body.style||"OPerspective"in document.body.style||"perspective"in document.body.style,wt="WebkitTransform"in document.body.style||"MozTransform"in document.body.style||"msTransform"in document.body.style||"OTransform"in document.body.style||"transform"in document.body.style,bt=0,Et=0,St=0,qt=0,kt=0,At=!1,xt={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:e,configure:s,slide:x,left:W,right:X,up:Y,down:F,prev:U,next:j,prevFragment:H,nextFragment:z,navigateTo:x,navigateLeft:W,navigateRight:X,navigateUp:Y,navigateDown:F,navigatePrev:U,navigateNext:j,layout:p,toggleOverview:w,togglePause:k,isOverview:b,isPaused:A,addEventListeners:a,removeEventListeners:i,getIndices:O,getSlide:function(e,t){var n=document.querySelectorAll(lt)[e],r=n&&n.querySelectorAll("section");return t!==void 0?r?r[t]:void 0:n},getPreviousSlide:function(){return at},getCurrentSlide:function(){return it},getScale:function(){return yt},getQueryHash:function(){var e={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(t){e[t.split("=").shift()]=t.split("=").pop()}),e},isFirstSlide:function(){return null==document.querySelector(ct+".past")?!0:!1},isLastSlide:function(){return it&&it.classList.contains(".stack")?null==it.querySelector(ct+".future")?!0:!1:null==document.querySelector(ct+".future")?!0:!1},addEventListener:function(e,t,n){"addEventListener"in window&&(gt.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(gt.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file From 2e8e73a847a0cb4317722bde2e2ff4b5a0d93c97 Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Wed, 27 Feb 2013 13:40:42 -0500 Subject: [PATCH 13/22] fragment sorting tweaks, sort attribute is now called data-fragment-index (#342) --- README.md | 10 +++++++ js/reveal.js | 76 ++++++++++++++++++++++++++---------------------- js/reveal.min.js | 4 +-- 3 files changed, 53 insertions(+), 37 deletions(-) diff --git a/README.md b/README.md index adf7a3a..4375933 100644 --- a/README.md +++ b/README.md @@ -270,6 +270,16 @@ Multiple fragments can be applied to the same element sequentially by wrapping i
``` +The display order of fragments can be controlled using the ```data-fragment-index``` attribute. + +```html +
+

Appears last

+

Appears first

+

Appears second

+
+``` + ### Fragment events When a slide fragment is either shown or hidden reveal.js will dispatch an event. diff --git a/js/reveal.js b/js/reveal.js index 456f418..f048b07 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -142,31 +142,6 @@ var Reveal = (function(){ threshold: 80 }; - /** - * Return a sorted fragments list, ordered by an increasing "fragment-pos" attribute. - * - * Fragments will be revealed in the order that they are returned by - * this function, so you can use "fragment-pos" attributes to control - * the order of fragment appearance. - * - * To maintain a sensible default fragment order, fragments are presumed - * to be passed in document order. This function adds a "fragment-pos" - * attribute to each node if such an attribute is not already present, - * and sets that attribute to an integer value which is the position of - * the fragment within the fragments list. - * - */ - function sort_fragments( fragments ) { - var a = toArray(fragments) - a.forEach( function (el, idx) { - if (!el.hasAttribute('fragment-pos')) { - el.setAttribute('fragment-pos', idx) }}) - a.sort(function(l, r) { - return l.getAttribute( 'fragment-pos' ) - - r.getAttribute( 'fragment-pos') }) - return a - } - /** * Starts up the presentation if the client is capable. */ @@ -597,6 +572,38 @@ var Reveal = (function(){ } + /** + * Return a sorted fragments list, ordered by an increasing + * "data-fragment-index" attribute. + * + * Fragments will be revealed in the order that they are returned by + * this function, so you can use the index attributes to control the + * order of fragment appearance. + * + * To maintain a sensible default fragment order, fragments are presumed + * to be passed in document order. This function adds a "fragment-index" + * attribute to each node if such an attribute is not already present, + * and sets that attribute to an integer value which is the position of + * the fragment within the fragments list. + */ + function sortFragments( fragments ) { + + var a = toArray( fragments ); + + a.forEach( function( el, idx ) { + if( !el.hasAttribute( 'data-fragment-index' ) ) { + el.setAttribute( 'data-fragment-index', idx ); + } + } ); + + a.sort( function( l, r ) { + return l.getAttribute( 'data-fragment-index' ) - r.getAttribute( 'data-fragment-index'); + } ); + + return a + + } + /** * Applies JavaScript-controlled layout rules to the * presentation. @@ -1046,8 +1053,7 @@ var Reveal = (function(){ // Show fragment, if specified if( typeof f !== 'undefined' ) { - var fragments = currentSlide.querySelectorAll( '.fragment' ); - fragments = sort_fragments(fragments) + var fragments = sortFragments( currentSlide.querySelectorAll( '.fragment' ) ); toArray( fragments ).forEach( function( fragment, indexf ) { if( indexf < f ) { @@ -1418,8 +1424,8 @@ var Reveal = (function(){ // Vertical slides: if( document.querySelector( VERTICAL_SLIDES_SELECTOR + '.present' ) ) { - var verticalFragments = document.querySelectorAll( VERTICAL_SLIDES_SELECTOR + '.present .fragment:not(.visible)' ); - verticalFragments = sort_fragments(verticalFragments) + var verticalFragments = sortFragments( document.querySelectorAll( VERTICAL_SLIDES_SELECTOR + '.present .fragment:not(.visible)' ) ); + if( verticalFragments.length ) { verticalFragments[0].classList.add( 'visible' ); @@ -1430,8 +1436,8 @@ var Reveal = (function(){ } // Horizontal slides: else { - var horizontalFragments = document.querySelectorAll( HORIZONTAL_SLIDES_SELECTOR + '.present .fragment:not(.visible)' ); - horizontalFragments = sort_fragments(horizontalFragments) + var horizontalFragments = sortFragments( document.querySelectorAll( HORIZONTAL_SLIDES_SELECTOR + '.present .fragment:not(.visible)' ) ); + if( horizontalFragments.length ) { horizontalFragments[0].classList.add( 'visible' ); @@ -1455,8 +1461,8 @@ var Reveal = (function(){ // Vertical slides: if( document.querySelector( VERTICAL_SLIDES_SELECTOR + '.present' ) ) { - var verticalFragments = document.querySelectorAll( VERTICAL_SLIDES_SELECTOR + '.present .fragment.visible' ); - verticalFragments = sort_fragments(verticalFragments) + var verticalFragments = sortFragments( document.querySelectorAll( VERTICAL_SLIDES_SELECTOR + '.present .fragment.visible' ) ); + if( verticalFragments.length ) { verticalFragments[ verticalFragments.length - 1 ].classList.remove( 'visible' ); @@ -1467,8 +1473,8 @@ var Reveal = (function(){ } // Horizontal slides: else { - var horizontalFragments = document.querySelectorAll( HORIZONTAL_SLIDES_SELECTOR + '.present .fragment.visible' ); - horizontalFragments = sort_fragments(horizontalFragments) + var horizontalFragments = sortFragments( document.querySelectorAll( HORIZONTAL_SLIDES_SELECTOR + '.present .fragment.visible' ) ); + if( horizontalFragments.length ) { horizontalFragments[ horizontalFragments.length - 1 ].classList.remove( 'visible' ); diff --git a/js/reveal.min.js b/js/reveal.min.js index 5fd0c86..9b8a7ce 100644 --- a/js/reveal.min.js +++ b/js/reveal.min.js @@ -1,8 +1,8 @@ /*! - * reveal.js 2.3.0 (2013-02-27, 13:19) + * reveal.js 2.3.0 (2013-02-27, 13:36) * http://lab.hakim.se/reveal-js * MIT licensed * * Copyright (C) 2013 Hakim El Hattab, http://hakim.se */ -var Reveal=function(){"use strict";function e(e){return wt||Lt?(window.addEventListener("load",p,!1),c(vt,e),n(),r(),void 0):(document.body.setAttribute("class","no-transforms"),void 0)}function t(){if(gt.theme=document.querySelector("#theme"),gt.wrapper=document.querySelector(".reveal"),gt.slides=document.querySelector(".reveal .slides"),!gt.wrapper.querySelector(".progress")&&vt.progress){var e=document.createElement("div");e.classList.add("progress"),e.innerHTML="",gt.wrapper.appendChild(e)}if(!gt.wrapper.querySelector(".controls")&&vt.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='',gt.wrapper.appendChild(t)}if(!gt.wrapper.querySelector(".state-background")){var n=document.createElement("div");n.classList.add("state-background"),gt.wrapper.appendChild(n)}if(!gt.wrapper.querySelector(".pause-overlay")){var r=document.createElement("div");r.classList.add("pause-overlay"),gt.wrapper.appendChild(r)}gt.progress=document.querySelector(".reveal .progress"),gt.progressbar=document.querySelector(".reveal .progress span"),vt.controls&&(gt.controls=document.querySelector(".reveal .controls"),gt.controlsLeft=l(document.querySelectorAll(".navigate-left")),gt.controlsRight=l(document.querySelectorAll(".navigate-right")),gt.controlsUp=l(document.querySelectorAll(".navigate-up")),gt.controlsDown=l(document.querySelectorAll(".navigate-down")),gt.controlsPrev=l(document.querySelectorAll(".navigate-prev")),gt.controlsNext=l(document.querySelectorAll(".navigate-next")))}function n(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",u,!1),window.addEventListener("orientationchange",u,!1))}function r(){function e(){n.length&&head.js.apply(null,n),o()}for(var t=[],n=[],r=0,s=vt.dependencies.length;s>r;r++){var a=vt.dependencies[r];(!a.condition||a.condition())&&(a.async?n.push(a.src):t.push(a.src),"function"==typeof a.callback&&head.ready(a.src.match(/([\w\d_\-]*)\.?js$|[^\\\/]*$/i)[0],a.callback))}t.length?(head.ready(e),head.js.apply(null,t)):e()}function o(){t(),a(),s(),p(),C(),I(),setTimeout(function(){v("ready",{indexh:mt,indexv:pt,currentSlide:it})},1)}function s(e){if(gt.wrapper.classList.remove(vt.transition),"object"==typeof e&&c(vt,e),Lt===!1&&(vt.transition="linear"),gt.wrapper.classList.add(vt.transition),gt.controls.style.display=vt.controls&>.controls?"block":"none",gt.progress.style.display=vt.progress&>.progress?"block":"none",gt.wrapper.classList.toggle("rtl",vt.rtl),gt.wrapper.classList.toggle("center",vt.center),vt.mouseWheel?(document.addEventListener("DOMMouseScroll",Q,!1),document.addEventListener("mousewheel",Q,!1)):(document.removeEventListener("DOMMouseScroll",Q,!1),document.removeEventListener("mousewheel",Q,!1)),vt.rollingLinks?f():m(),vt.theme&>.theme){var t=gt.theme.getAttribute("href"),n=/[^\/]*?(?=\.css)/,r=t.match(n)[0];vt.theme!==r&&(t=t.replace(n,vt.theme),gt.theme.setAttribute("href",t))}}function a(){if(At=!0,window.addEventListener("hashchange",rt,!1),window.addEventListener("resize",ot,!1),vt.touch&&(document.addEventListener("touchstart",$,!1),document.addEventListener("touchmove",Z,!1),document.addEventListener("touchend",_,!1)),vt.keyboard&&document.addEventListener("keydown",K,!1),vt.progress&>.progress&>.progress.addEventListener("click",V,!1),vt.controls&>.controls){var e="ontouchstart"in window&&null!=window.ontouchstart?"touchstart":"click";gt.controlsLeft.forEach(function(t){t.addEventListener(e,B,!1)}),gt.controlsRight.forEach(function(t){t.addEventListener(e,G,!1)}),gt.controlsUp.forEach(function(t){t.addEventListener(e,J,!1)}),gt.controlsDown.forEach(function(t){t.addEventListener(e,et,!1)}),gt.controlsPrev.forEach(function(t){t.addEventListener(e,tt,!1)}),gt.controlsNext.forEach(function(t){t.addEventListener(e,nt,!1)})}}function i(){if(At=!1,document.removeEventListener("keydown",K,!1),window.removeEventListener("hashchange",rt,!1),window.removeEventListener("resize",ot,!1),vt.touch&&(document.removeEventListener("touchstart",$,!1),document.removeEventListener("touchmove",Z,!1),document.removeEventListener("touchend",_,!1)),vt.progress&>.progress&>.progress.removeEventListener("click",V,!1),vt.controls&>.controls){var e="ontouchstart"in window&&null!=window.ontouchstart?"touchstart":"click";gt.controlsLeft.forEach(function(t){t.removeEventListener(e,B,!1)}),gt.controlsRight.forEach(function(t){t.removeEventListener(e,G,!1)}),gt.controlsUp.forEach(function(t){t.removeEventListener(e,J,!1)}),gt.controlsDown.forEach(function(t){t.removeEventListener(e,et,!1)}),gt.controlsPrev.forEach(function(t){t.removeEventListener(e,tt,!1)}),gt.controlsNext.forEach(function(t){t.removeEventListener(e,nt,!1)})}}function c(e,t){for(var n in t)e[n]=t[n]}function l(e){return Array.prototype.slice.call(e)}function d(e,t){var n=e.x-t.x,r=e.y-t.y;return Math.sqrt(n*n+r*r)}function u(){0===window.orientation?(document.documentElement.style.overflow="scroll",document.body.style.height="120%"):(document.documentElement.style.overflow="",document.body.style.height="100%"),setTimeout(function(){window.scrollTo(0,1)},10)}function v(e,t){var n=document.createEvent("HTMLEvents",1,2);n.initEvent(e,!0,!0),c(n,t),gt.wrapper.dispatchEvent(n)}function f(){if(Lt&&!("msPerspective"in document.body.style))for(var e=document.querySelectorAll(ct+" a:not(.image)"),t=0,n=e.length;n>t;t++){var r=e[t];if(!(!r.textContent||r.querySelector("*")||r.className&&r.classList.contains(r,"roll"))){var o=document.createElement("span");o.setAttribute("data-title",r.text),o.innerHTML=r.innerHTML,r.classList.add("roll"),r.innerHTML="",r.appendChild(o)}}}function m(){for(var e=document.querySelectorAll(ct+" a.roll"),t=0,n=e.length;n>t;t++){var r=e[t],o=r.querySelector("span");o&&(r.classList.remove("roll"),r.innerHTML=o.innerHTML)}}function p(){if(gt.wrapper){var e=gt.wrapper.offsetWidth,t=gt.wrapper.offsetHeight;e-=t*vt.margin,t-=t*vt.margin;var n=vt.width,r=vt.height;if("string"==typeof n&&/%$/.test(n)&&(n=parseInt(n,10)/100*e),"string"==typeof r&&/%$/.test(r)&&(r=parseInt(r,10)/100*t),gt.slides.style.width=n+"px",gt.slides.style.height=r+"px",yt=Math.min(e/n,t/r),yt=Math.max(yt,vt.minScale),yt=Math.min(yt,vt.maxScale),void 0===gt.slides.style.zoom||navigator.userAgent.match(/(iphone|ipod|ipad|android)/gi)){var o="translate(-50%, -50%) scale("+yt+") translate(50%, 50%)";gt.slides.style.WebkitTransform=o,gt.slides.style.MozTransform=o,gt.slides.style.msTransform=o,gt.slides.style.OTransform=o,gt.slides.style.transform=o}else gt.slides.style.zoom=yt;for(var s=l(document.querySelectorAll(ct)),a=0,i=s.length;i>a;a++){var c=s[a];"none"!==c.style.display&&(c.style.top=vt.center?c.classList.contains("stack")?0:Math.max(-(c.offsetHeight/2)-20,-r/2)+"px":"")}}}function h(e,t){e&&e.setAttribute("data-previous-indexv",t||0)}function y(e){return e&&e.classList.contains("stack")?parseInt(e.getAttribute("data-previous-indexv")||0,10):0}function g(){if(vt.overview){R();var e=gt.wrapper.classList.contains("overview");gt.wrapper.classList.add("overview"),gt.wrapper.classList.remove("exit-overview"),clearTimeout(qt),clearTimeout(kt),qt=setTimeout(function(){for(var t=document.querySelectorAll(lt),n=0,r=t.length;r>n;n++){var o=t[n],s="translateZ(-2500px) translate("+105*(n-mt)+"%, 0%)";if(o.setAttribute("data-index-h",n),o.style.display="block",o.style.WebkitTransform=s,o.style.MozTransform=s,o.style.msTransform=s,o.style.OTransform=s,o.style.transform=s,o.classList.contains("stack"))for(var a=o.querySelectorAll("section"),i=0,c=a.length;c>i;i++){var l=n===mt?pt:y(o),d=a[i],u="translate(0%, "+105*(i-l)+"%)";d.setAttribute("data-index-h",n),d.setAttribute("data-index-v",i),d.style.display="block",d.style.WebkitTransform=u,d.style.MozTransform=u,d.style.msTransform=u,d.style.OTransform=u,d.style.transform=u,d.addEventListener("click",st,!0)}else o.addEventListener("click",st,!0)}p(),e||v("overviewshown",{indexh:mt,indexv:pt,currentSlide:it})},10)}}function L(){if(vt.overview){clearTimeout(qt),clearTimeout(kt),gt.wrapper.classList.remove("overview"),gt.wrapper.classList.add("exit-overview"),kt=setTimeout(function(){gt.wrapper.classList.remove("exit-overview")},10);for(var e=l(document.querySelectorAll(ct)),t=0,n=e.length;n>t;t++){var r=e[t];r.style.display="",r.style.WebkitTransform="",r.style.MozTransform="",r.style.msTransform="",r.style.OTransform="",r.style.transform="",r.removeEventListener("click",st,!0)}x(mt,pt),I(),v("overviewhidden",{indexh:mt,indexv:pt,currentSlide:it})}}function w(e){"boolean"==typeof e?e?g():L():b()?L():g()}function b(){return gt.wrapper.classList.contains("overview")}function E(){var e=document.body,t=e.requestFullScreen||e.webkitRequestFullScreen||e.mozRequestFullScreen||e.msRequestFullScreen;t&&t.apply(e)}function S(){R(),gt.wrapper.classList.add("paused")}function q(){I(),gt.wrapper.classList.remove("paused")}function k(){A()?q():S()}function A(){return gt.wrapper.classList.contains("paused")}function x(e,t,n){at=it;var r=document.querySelectorAll(lt);void 0===t&&(t=y(r[e])),at&&at.parentNode&&at.parentNode.classList.contains("stack")&&h(at.parentNode,pt);var o=ht.concat();ht.length=0;var s=mt,a=pt;mt=T(lt,void 0===e?mt:e),pt=T(dt,void 0===t?pt:t),p();e:for(var i=0,c=ht.length;c>i;i++){for(var d=0;o.length>d;d++)if(o[d]===ht[i]){o.splice(d,1);continue e}document.documentElement.classList.add(ht[i]),v(ht[i])}for(;o.length;)document.documentElement.classList.remove(o.pop());b()&&g(),P(1500);var u=r[mt],f=u.querySelectorAll("section");if(it=f[pt]||u,n!==void 0){var m=it.querySelectorAll(".fragment");l(m).forEach(function(e,t){n>t?e.classList.add("visible"):e.classList.remove("visible")})}mt!==s||pt!==a?v("slidechanged",{indexh:mt,indexv:pt,previousSlide:at,currentSlide:it}):at=null,at&&(at.classList.remove("present"),document.querySelector(ut).classList.contains("present")&&setTimeout(function(){var e,t=l(document.querySelectorAll(lt+".stack"));for(e in t)t[e]&&h(t[e],0)},0)),D(),M()}function T(e,t){var n=l(document.querySelectorAll(e)),r=n.length;if(r){vt.loop&&(t%=r,0>t&&(t=r+t)),t=Math.max(Math.min(t,r-1),0);for(var o=0;r>o;o++){var s=n[o];if(b()===!1){var a=Math.abs((t-o)%(r-3))||0;s.style.display=a>3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),t>o?n[o].classList.add("past"):o>t&&n[o].classList.add("future"),s.querySelector("section")&&n[o].classList.add("stack")}n[t].classList.add("present");var i=n[t].getAttribute("data-state");i&&(ht=ht.concat(i.split(" ")));var c=n[t].getAttribute("data-autoslide");ft=c?parseInt(c,10):vt.autoSlide}else t=0;return t}function M(){if(vt.progress&>.progress){var e=l(document.querySelectorAll(lt)),t=document.querySelectorAll(ct+":not(.stack)").length,n=0;e:for(var r=0;e.length>r;r++){for(var o=e[r],s=l(o.querySelectorAll("section")),a=0;s.length>a;a++){if(s[a].classList.contains("present"))break e;n++}if(o.classList.contains("present"))break;o.classList.contains("stack")===!1&&n++}gt.progressbar.style.width=n/(t-1)*window.innerWidth+"px"}}function D(){if(vt.controls&>.controls){var e=N();gt.controlsLeft.concat(gt.controlsRight).concat(gt.controlsUp).concat(gt.controlsDown).concat(gt.controlsPrev).concat(gt.controlsNext).forEach(function(e){e.classList.remove("enabled")}),e.left&>.controlsLeft.forEach(function(e){e.classList.add("enabled")}),e.right&>.controlsRight.forEach(function(e){e.classList.add("enabled")}),e.up&>.controlsUp.forEach(function(e){e.classList.add("enabled")}),e.down&>.controlsDown.forEach(function(e){e.classList.add("enabled")}),(e.left||e.up)&>.controlsPrev.forEach(function(e){e.classList.add("enabled")}),(e.right||e.down)&>.controlsNext.forEach(function(e){e.classList.add("enabled")})}}function N(){var e=document.querySelectorAll(lt),t=document.querySelectorAll(dt);return{left:mt>0,right:e.length-1>mt,up:pt>0,down:t.length-1>pt}}function C(){var e=window.location.hash,t=e.slice(2).split("/"),n=e.replace(/#|\//gi,"");if(isNaN(parseInt(t[0],10))&&n.length){var r=document.querySelector("#"+n);if(r){var o=Reveal.getIndices(r);x(o.h,o.v)}else x(mt,pt)}else{var s=parseInt(t[0],10)||0,a=parseInt(t[1],10)||0;x(s,a)}}function P(e){if(vt.history)if(clearTimeout(St),"number"==typeof e)St=setTimeout(P,e);else{var t="/";it&&"string"==typeof it.getAttribute("id")?t="/"+it.getAttribute("id"):((mt>0||pt>0)&&(t+=mt),pt>0&&(t+="/"+pt)),window.location.hash=t}}function O(e){var t=mt,n=pt;if(e){var r=!!e.parentNode.nodeName.match(/section/gi),o=r?e.parentNode:e,s=l(document.querySelectorAll(lt));t=Math.max(s.indexOf(o),0),r&&(n=Math.max(l(e.parentNode.querySelectorAll("section")).indexOf(e),0))}return{h:t,v:n}}function z(){if(document.querySelector(dt+".present")){var e=document.querySelectorAll(dt+".present .fragment:not(.visible)");if(e.length)return e[0].classList.add("visible"),v("fragmentshown",{fragment:e[0]}),!0}else{var t=document.querySelectorAll(lt+".present .fragment:not(.visible)");if(t.length)return t[0].classList.add("visible"),v("fragmentshown",{fragment:t[0]}),!0}return!1}function H(){if(document.querySelector(dt+".present")){var e=document.querySelectorAll(dt+".present .fragment.visible");if(e.length)return e[e.length-1].classList.remove("visible"),v("fragmenthidden",{fragment:e[e.length-1]}),!0}else{var t=document.querySelectorAll(lt+".present .fragment.visible");if(t.length)return t[t.length-1].classList.remove("visible"),v("fragmenthidden",{fragment:t[t.length-1]}),!0}return!1}function I(){clearTimeout(Et),!ft||A()||b()||(Et=setTimeout(j,ft))}function R(){clearTimeout(Et)}function W(){(N().left&&b()||H()===!1)&&x(mt-1)}function X(){(N().right&&b()||z()===!1)&&x(mt+1)}function Y(){(N().up&&b()||H()===!1)&&x(mt,pt-1)}function F(){(N().down&&b()||z()===!1)&&x(mt,pt+1)}function U(){if(H()===!1)if(N().up)Y();else{var e=document.querySelector(lt+".past:nth-child("+mt+")");e&&(pt=e.querySelectorAll("section").length+1||void 0,mt--,x())}}function j(){z()===!1&&(N().down?F():X()),I()}function K(e){document.activeElement;var t=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&"inherit"===document.activeElement.contentEditable);if(!(t||e.shiftKey||e.altKey||e.ctrlKey||e.metaKey)){var n=!0;if(A()&&-1===[66,190,191].indexOf(e.keyCode))return!1;switch(e.keyCode){case 80:case 33:U();break;case 78:case 34:j();break;case 72:case 37:W();break;case 76:case 39:X();break;case 75:case 38:Y();break;case 74:case 40:F();break;case 36:x(0);break;case 35:x(Number.MAX_VALUE);break;case 32:b()?L():j();break;case 13:b()?L():n=!1;break;case 66:case 190:case 191:k();break;case 70:E();break;default:n=!1}n?e.preventDefault():27===e.keyCode&&Lt&&(w(),e.preventDefault()),I()}}function $(e){xt.startX=e.touches[0].clientX,xt.startY=e.touches[0].clientY,xt.startCount=e.touches.length,2===e.touches.length&&vt.overview&&(xt.startSpan=d({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:xt.startX,y:xt.startY}))}function Z(e){if(xt.handled)navigator.userAgent.match(/android/gi)&&e.preventDefault();else{var t=e.touches[0].clientX,n=e.touches[0].clientY;if(2===e.touches.length&&2===xt.startCount&&vt.overview){var r=d({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:xt.startX,y:xt.startY});Math.abs(xt.startSpan-r)>xt.threshold&&(xt.handled=!0,xt.startSpan>r?g():L()),e.preventDefault()}else if(1===e.touches.length&&2!==xt.startCount){var o=t-xt.startX,s=n-xt.startY;o>xt.threshold&&Math.abs(o)>Math.abs(s)?(xt.handled=!0,W()):-xt.threshold>o&&Math.abs(o)>Math.abs(s)?(xt.handled=!0,X()):s>xt.threshold?(xt.handled=!0,Y()):-xt.threshold>s&&(xt.handled=!0,F()),e.preventDefault()}}}function _(){xt.handled=!1}function Q(e){clearTimeout(bt),bt=setTimeout(function(){var t=e.detail||-e.wheelDelta;t>0?j():U()},100)}function V(e){e.preventDefault();var t=l(document.querySelectorAll(lt)).length,n=Math.floor(e.clientX/gt.wrapper.offsetWidth*t);x(n)}function B(e){e.preventDefault(),W()}function G(e){e.preventDefault(),X()}function J(e){e.preventDefault(),Y()}function et(e){e.preventDefault(),F()}function tt(e){e.preventDefault(),U()}function nt(e){e.preventDefault(),j()}function rt(){C()}function ot(){p()}function st(e){if(At&&b()){e.preventDefault();for(var t=e.target;t&&!t.nodeName.match(/section/gi);)t=t.parentNode;if(t&&!t.classList.contains("disabled")&&(L(),t.nodeName.match(/section/gi))){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);x(n,r)}}}var at,it,ct=".reveal .slides section",lt=".reveal .slides>section",dt=".reveal .slides>section.present>section",ut=".reveal .slides>section:first-child",vt={width:960,height:700,margin:.1,minScale:.2,maxScale:1,controls:!0,progress:!0,history:!1,keyboard:!0,overview:!0,center:!0,touch:!0,loop:!1,rtl:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!0,theme:null,transition:"default",dependencies:[]},ft=vt.autoSlide,mt=0,pt=0,ht=[],yt=1,gt={},Lt="WebkitPerspective"in document.body.style||"MozPerspective"in document.body.style||"msPerspective"in document.body.style||"OPerspective"in document.body.style||"perspective"in document.body.style,wt="WebkitTransform"in document.body.style||"MozTransform"in document.body.style||"msTransform"in document.body.style||"OTransform"in document.body.style||"transform"in document.body.style,bt=0,Et=0,St=0,qt=0,kt=0,At=!1,xt={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:e,configure:s,slide:x,left:W,right:X,up:Y,down:F,prev:U,next:j,prevFragment:H,nextFragment:z,navigateTo:x,navigateLeft:W,navigateRight:X,navigateUp:Y,navigateDown:F,navigatePrev:U,navigateNext:j,layout:p,toggleOverview:w,togglePause:k,isOverview:b,isPaused:A,addEventListeners:a,removeEventListeners:i,getIndices:O,getSlide:function(e,t){var n=document.querySelectorAll(lt)[e],r=n&&n.querySelectorAll("section");return t!==void 0?r?r[t]:void 0:n},getPreviousSlide:function(){return at},getCurrentSlide:function(){return it},getScale:function(){return yt},getQueryHash:function(){var e={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(t){e[t.split("=").shift()]=t.split("=").pop()}),e},isFirstSlide:function(){return null==document.querySelector(ct+".past")?!0:!1},isLastSlide:function(){return it&&it.classList.contains(".stack")?null==it.querySelector(ct+".future")?!0:!1:null==document.querySelector(ct+".future")?!0:!1},addEventListener:function(e,t,n){"addEventListener"in window&&(gt.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(gt.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file +var Reveal=function(){"use strict";function e(e){return bt||wt?(window.addEventListener("load",h,!1),c(ft,e),n(),r(),void 0):(document.body.setAttribute("class","no-transforms"),void 0)}function t(){if(Lt.theme=document.querySelector("#theme"),Lt.wrapper=document.querySelector(".reveal"),Lt.slides=document.querySelector(".reveal .slides"),!Lt.wrapper.querySelector(".progress")&&ft.progress){var e=document.createElement("div");e.classList.add("progress"),e.innerHTML="",Lt.wrapper.appendChild(e)}if(!Lt.wrapper.querySelector(".controls")&&ft.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='',Lt.wrapper.appendChild(t)}if(!Lt.wrapper.querySelector(".state-background")){var n=document.createElement("div");n.classList.add("state-background"),Lt.wrapper.appendChild(n)}if(!Lt.wrapper.querySelector(".pause-overlay")){var r=document.createElement("div");r.classList.add("pause-overlay"),Lt.wrapper.appendChild(r)}Lt.progress=document.querySelector(".reveal .progress"),Lt.progressbar=document.querySelector(".reveal .progress span"),ft.controls&&(Lt.controls=document.querySelector(".reveal .controls"),Lt.controlsLeft=l(document.querySelectorAll(".navigate-left")),Lt.controlsRight=l(document.querySelectorAll(".navigate-right")),Lt.controlsUp=l(document.querySelectorAll(".navigate-up")),Lt.controlsDown=l(document.querySelectorAll(".navigate-down")),Lt.controlsPrev=l(document.querySelectorAll(".navigate-prev")),Lt.controlsNext=l(document.querySelectorAll(".navigate-next")))}function n(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",u,!1),window.addEventListener("orientationchange",u,!1))}function r(){function e(){n.length&&head.js.apply(null,n),o()}for(var t=[],n=[],r=0,s=ft.dependencies.length;s>r;r++){var a=ft.dependencies[r];(!a.condition||a.condition())&&(a.async?n.push(a.src):t.push(a.src),"function"==typeof a.callback&&head.ready(a.src.match(/([\w\d_\-]*)\.?js$|[^\\\/]*$/i)[0],a.callback))}t.length?(head.ready(e),head.js.apply(null,t)):e()}function o(){t(),a(),s(),h(),P(),R(),setTimeout(function(){v("ready",{indexh:pt,indexv:ht,currentSlide:ct})},1)}function s(e){if(Lt.wrapper.classList.remove(ft.transition),"object"==typeof e&&c(ft,e),wt===!1&&(ft.transition="linear"),Lt.wrapper.classList.add(ft.transition),Lt.controls.style.display=ft.controls&&Lt.controls?"block":"none",Lt.progress.style.display=ft.progress&&Lt.progress?"block":"none",Lt.wrapper.classList.toggle("rtl",ft.rtl),Lt.wrapper.classList.toggle("center",ft.center),ft.mouseWheel?(document.addEventListener("DOMMouseScroll",V,!1),document.addEventListener("mousewheel",V,!1)):(document.removeEventListener("DOMMouseScroll",V,!1),document.removeEventListener("mousewheel",V,!1)),ft.rollingLinks?f():m(),ft.theme&&Lt.theme){var t=Lt.theme.getAttribute("href"),n=/[^\/]*?(?=\.css)/,r=t.match(n)[0];ft.theme!==r&&(t=t.replace(n,ft.theme),Lt.theme.setAttribute("href",t))}}function a(){if(xt=!0,window.addEventListener("hashchange",ot,!1),window.addEventListener("resize",st,!1),ft.touch&&(document.addEventListener("touchstart",Z,!1),document.addEventListener("touchmove",_,!1),document.addEventListener("touchend",Q,!1)),ft.keyboard&&document.addEventListener("keydown",$,!1),ft.progress&&Lt.progress&&Lt.progress.addEventListener("click",B,!1),ft.controls&&Lt.controls){var e="ontouchstart"in window&&null!=window.ontouchstart?"touchstart":"click";Lt.controlsLeft.forEach(function(t){t.addEventListener(e,G,!1)}),Lt.controlsRight.forEach(function(t){t.addEventListener(e,J,!1)}),Lt.controlsUp.forEach(function(t){t.addEventListener(e,et,!1)}),Lt.controlsDown.forEach(function(t){t.addEventListener(e,tt,!1)}),Lt.controlsPrev.forEach(function(t){t.addEventListener(e,nt,!1)}),Lt.controlsNext.forEach(function(t){t.addEventListener(e,rt,!1)})}}function i(){if(xt=!1,document.removeEventListener("keydown",$,!1),window.removeEventListener("hashchange",ot,!1),window.removeEventListener("resize",st,!1),ft.touch&&(document.removeEventListener("touchstart",Z,!1),document.removeEventListener("touchmove",_,!1),document.removeEventListener("touchend",Q,!1)),ft.progress&&Lt.progress&&Lt.progress.removeEventListener("click",B,!1),ft.controls&&Lt.controls){var e="ontouchstart"in window&&null!=window.ontouchstart?"touchstart":"click";Lt.controlsLeft.forEach(function(t){t.removeEventListener(e,G,!1)}),Lt.controlsRight.forEach(function(t){t.removeEventListener(e,J,!1)}),Lt.controlsUp.forEach(function(t){t.removeEventListener(e,et,!1)}),Lt.controlsDown.forEach(function(t){t.removeEventListener(e,tt,!1)}),Lt.controlsPrev.forEach(function(t){t.removeEventListener(e,nt,!1)}),Lt.controlsNext.forEach(function(t){t.removeEventListener(e,rt,!1)})}}function c(e,t){for(var n in t)e[n]=t[n]}function l(e){return Array.prototype.slice.call(e)}function d(e,t){var n=e.x-t.x,r=e.y-t.y;return Math.sqrt(n*n+r*r)}function u(){0===window.orientation?(document.documentElement.style.overflow="scroll",document.body.style.height="120%"):(document.documentElement.style.overflow="",document.body.style.height="100%"),setTimeout(function(){window.scrollTo(0,1)},10)}function v(e,t){var n=document.createEvent("HTMLEvents",1,2);n.initEvent(e,!0,!0),c(n,t),Lt.wrapper.dispatchEvent(n)}function f(){if(wt&&!("msPerspective"in document.body.style))for(var e=document.querySelectorAll(lt+" a:not(.image)"),t=0,n=e.length;n>t;t++){var r=e[t];if(!(!r.textContent||r.querySelector("*")||r.className&&r.classList.contains(r,"roll"))){var o=document.createElement("span");o.setAttribute("data-title",r.text),o.innerHTML=r.innerHTML,r.classList.add("roll"),r.innerHTML="",r.appendChild(o)}}}function m(){for(var e=document.querySelectorAll(lt+" a.roll"),t=0,n=e.length;n>t;t++){var r=e[t],o=r.querySelector("span");o&&(r.classList.remove("roll"),r.innerHTML=o.innerHTML)}}function p(e){var t=l(e);return t.forEach(function(e,t){e.hasAttribute("data-fragment-index")||e.setAttribute("data-fragment-index",t)}),t.sort(function(e,t){return e.getAttribute("data-fragment-index")-t.getAttribute("data-fragment-index")}),t}function h(){if(Lt.wrapper){var e=Lt.wrapper.offsetWidth,t=Lt.wrapper.offsetHeight;e-=t*ft.margin,t-=t*ft.margin;var n=ft.width,r=ft.height;if("string"==typeof n&&/%$/.test(n)&&(n=parseInt(n,10)/100*e),"string"==typeof r&&/%$/.test(r)&&(r=parseInt(r,10)/100*t),Lt.slides.style.width=n+"px",Lt.slides.style.height=r+"px",yt=Math.min(e/n,t/r),yt=Math.max(yt,ft.minScale),yt=Math.min(yt,ft.maxScale),void 0===Lt.slides.style.zoom||navigator.userAgent.match(/(iphone|ipod|ipad|android)/gi)){var o="translate(-50%, -50%) scale("+yt+") translate(50%, 50%)";Lt.slides.style.WebkitTransform=o,Lt.slides.style.MozTransform=o,Lt.slides.style.msTransform=o,Lt.slides.style.OTransform=o,Lt.slides.style.transform=o}else Lt.slides.style.zoom=yt;for(var s=l(document.querySelectorAll(lt)),a=0,i=s.length;i>a;a++){var c=s[a];"none"!==c.style.display&&(c.style.top=ft.center?c.classList.contains("stack")?0:Math.max(-(c.offsetHeight/2)-20,-r/2)+"px":"")}}}function g(e,t){e&&e.setAttribute("data-previous-indexv",t||0)}function y(e){return e&&e.classList.contains("stack")?parseInt(e.getAttribute("data-previous-indexv")||0,10):0}function L(){if(ft.overview){W();var e=Lt.wrapper.classList.contains("overview");Lt.wrapper.classList.add("overview"),Lt.wrapper.classList.remove("exit-overview"),clearTimeout(At),clearTimeout(kt),At=setTimeout(function(){for(var t=document.querySelectorAll(dt),n=0,r=t.length;r>n;n++){var o=t[n],s="translateZ(-2500px) translate("+105*(n-pt)+"%, 0%)";if(o.setAttribute("data-index-h",n),o.style.display="block",o.style.WebkitTransform=s,o.style.MozTransform=s,o.style.msTransform=s,o.style.OTransform=s,o.style.transform=s,o.classList.contains("stack"))for(var a=o.querySelectorAll("section"),i=0,c=a.length;c>i;i++){var l=n===pt?ht:y(o),d=a[i],u="translate(0%, "+105*(i-l)+"%)";d.setAttribute("data-index-h",n),d.setAttribute("data-index-v",i),d.style.display="block",d.style.WebkitTransform=u,d.style.MozTransform=u,d.style.msTransform=u,d.style.OTransform=u,d.style.transform=u,d.addEventListener("click",at,!0)}else o.addEventListener("click",at,!0)}h(),e||v("overviewshown",{indexh:pt,indexv:ht,currentSlide:ct})},10)}}function w(){if(ft.overview){clearTimeout(At),clearTimeout(kt),Lt.wrapper.classList.remove("overview"),Lt.wrapper.classList.add("exit-overview"),kt=setTimeout(function(){Lt.wrapper.classList.remove("exit-overview")},10);for(var e=l(document.querySelectorAll(lt)),t=0,n=e.length;n>t;t++){var r=e[t];r.style.display="",r.style.WebkitTransform="",r.style.MozTransform="",r.style.msTransform="",r.style.OTransform="",r.style.transform="",r.removeEventListener("click",at,!0)}T(pt,ht),R(),v("overviewhidden",{indexh:pt,indexv:ht,currentSlide:ct})}}function b(e){"boolean"==typeof e?e?L():w():E()?w():L()}function E(){return Lt.wrapper.classList.contains("overview")}function S(){var e=document.body,t=e.requestFullScreen||e.webkitRequestFullScreen||e.mozRequestFullScreen||e.msRequestFullScreen;t&&t.apply(e)}function q(){W(),Lt.wrapper.classList.add("paused")}function A(){R(),Lt.wrapper.classList.remove("paused")}function k(){x()?A():q()}function x(){return Lt.wrapper.classList.contains("paused")}function T(e,t,n){it=ct;var r=document.querySelectorAll(dt);void 0===t&&(t=y(r[e])),it&&it.parentNode&&it.parentNode.classList.contains("stack")&&g(it.parentNode,ht);var o=gt.concat();gt.length=0;var s=pt,a=ht;pt=M(dt,void 0===e?pt:e),ht=M(ut,void 0===t?ht:t),h();e:for(var i=0,c=gt.length;c>i;i++){for(var d=0;o.length>d;d++)if(o[d]===gt[i]){o.splice(d,1);continue e}document.documentElement.classList.add(gt[i]),v(gt[i])}for(;o.length;)document.documentElement.classList.remove(o.pop());E()&&L(),O(1500);var u=r[pt],f=u.querySelectorAll("section");if(ct=f[ht]||u,n!==void 0){var m=p(ct.querySelectorAll(".fragment"));l(m).forEach(function(e,t){n>t?e.classList.add("visible"):e.classList.remove("visible")})}pt!==s||ht!==a?v("slidechanged",{indexh:pt,indexv:ht,previousSlide:it,currentSlide:ct}):it=null,it&&(it.classList.remove("present"),document.querySelector(vt).classList.contains("present")&&setTimeout(function(){var e,t=l(document.querySelectorAll(dt+".stack"));for(e in t)t[e]&&g(t[e],0)},0)),N(),D()}function M(e,t){var n=l(document.querySelectorAll(e)),r=n.length;if(r){ft.loop&&(t%=r,0>t&&(t=r+t)),t=Math.max(Math.min(t,r-1),0);for(var o=0;r>o;o++){var s=n[o];if(E()===!1){var a=Math.abs((t-o)%(r-3))||0;s.style.display=a>3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),t>o?n[o].classList.add("past"):o>t&&n[o].classList.add("future"),s.querySelector("section")&&n[o].classList.add("stack")}n[t].classList.add("present");var i=n[t].getAttribute("data-state");i&&(gt=gt.concat(i.split(" ")));var c=n[t].getAttribute("data-autoslide");mt=c?parseInt(c,10):ft.autoSlide}else t=0;return t}function D(){if(ft.progress&&Lt.progress){var e=l(document.querySelectorAll(dt)),t=document.querySelectorAll(lt+":not(.stack)").length,n=0;e:for(var r=0;e.length>r;r++){for(var o=e[r],s=l(o.querySelectorAll("section")),a=0;s.length>a;a++){if(s[a].classList.contains("present"))break e;n++}if(o.classList.contains("present"))break;o.classList.contains("stack")===!1&&n++}Lt.progressbar.style.width=n/(t-1)*window.innerWidth+"px"}}function N(){if(ft.controls&&Lt.controls){var e=C();Lt.controlsLeft.concat(Lt.controlsRight).concat(Lt.controlsUp).concat(Lt.controlsDown).concat(Lt.controlsPrev).concat(Lt.controlsNext).forEach(function(e){e.classList.remove("enabled")}),e.left&&Lt.controlsLeft.forEach(function(e){e.classList.add("enabled")}),e.right&&Lt.controlsRight.forEach(function(e){e.classList.add("enabled")}),e.up&&Lt.controlsUp.forEach(function(e){e.classList.add("enabled")}),e.down&&Lt.controlsDown.forEach(function(e){e.classList.add("enabled")}),(e.left||e.up)&&Lt.controlsPrev.forEach(function(e){e.classList.add("enabled")}),(e.right||e.down)&&Lt.controlsNext.forEach(function(e){e.classList.add("enabled")})}}function C(){var e=document.querySelectorAll(dt),t=document.querySelectorAll(ut);return{left:pt>0,right:e.length-1>pt,up:ht>0,down:t.length-1>ht}}function P(){var e=window.location.hash,t=e.slice(2).split("/"),n=e.replace(/#|\//gi,"");if(isNaN(parseInt(t[0],10))&&n.length){var r=document.querySelector("#"+n);if(r){var o=Reveal.getIndices(r);T(o.h,o.v)}else T(pt,ht)}else{var s=parseInt(t[0],10)||0,a=parseInt(t[1],10)||0;T(s,a)}}function O(e){if(ft.history)if(clearTimeout(qt),"number"==typeof e)qt=setTimeout(O,e);else{var t="/";ct&&"string"==typeof ct.getAttribute("id")?t="/"+ct.getAttribute("id"):((pt>0||ht>0)&&(t+=pt),ht>0&&(t+="/"+ht)),window.location.hash=t}}function z(e){var t=pt,n=ht;if(e){var r=!!e.parentNode.nodeName.match(/section/gi),o=r?e.parentNode:e,s=l(document.querySelectorAll(dt));t=Math.max(s.indexOf(o),0),r&&(n=Math.max(l(e.parentNode.querySelectorAll("section")).indexOf(e),0))}return{h:t,v:n}}function H(){if(document.querySelector(ut+".present")){var e=p(document.querySelectorAll(ut+".present .fragment:not(.visible)"));if(e.length)return e[0].classList.add("visible"),v("fragmentshown",{fragment:e[0]}),!0}else{var t=p(document.querySelectorAll(dt+".present .fragment:not(.visible)"));if(t.length)return t[0].classList.add("visible"),v("fragmentshown",{fragment:t[0]}),!0}return!1}function I(){if(document.querySelector(ut+".present")){var e=p(document.querySelectorAll(ut+".present .fragment.visible"));if(e.length)return e[e.length-1].classList.remove("visible"),v("fragmenthidden",{fragment:e[e.length-1]}),!0}else{var t=p(document.querySelectorAll(dt+".present .fragment.visible"));if(t.length)return t[t.length-1].classList.remove("visible"),v("fragmenthidden",{fragment:t[t.length-1]}),!0}return!1}function R(){clearTimeout(St),!mt||x()||E()||(St=setTimeout(K,mt))}function W(){clearTimeout(St)}function X(){(C().left&&E()||I()===!1)&&T(pt-1)}function Y(){(C().right&&E()||H()===!1)&&T(pt+1)}function F(){(C().up&&E()||I()===!1)&&T(pt,ht-1)}function U(){(C().down&&E()||H()===!1)&&T(pt,ht+1)}function j(){if(I()===!1)if(C().up)F();else{var e=document.querySelector(dt+".past:nth-child("+pt+")");e&&(ht=e.querySelectorAll("section").length+1||void 0,pt--,T())}}function K(){H()===!1&&(C().down?U():Y()),R()}function $(e){document.activeElement;var t=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&"inherit"===document.activeElement.contentEditable);if(!(t||e.shiftKey||e.altKey||e.ctrlKey||e.metaKey)){var n=!0;if(x()&&-1===[66,190,191].indexOf(e.keyCode))return!1;switch(e.keyCode){case 80:case 33:j();break;case 78:case 34:K();break;case 72:case 37:X();break;case 76:case 39:Y();break;case 75:case 38:F();break;case 74:case 40:U();break;case 36:T(0);break;case 35:T(Number.MAX_VALUE);break;case 32:E()?w():K();break;case 13:E()?w():n=!1;break;case 66:case 190:case 191:k();break;case 70:S();break;default:n=!1}n?e.preventDefault():27===e.keyCode&&wt&&(b(),e.preventDefault()),R()}}function Z(e){Tt.startX=e.touches[0].clientX,Tt.startY=e.touches[0].clientY,Tt.startCount=e.touches.length,2===e.touches.length&&ft.overview&&(Tt.startSpan=d({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:Tt.startX,y:Tt.startY}))}function _(e){if(Tt.handled)navigator.userAgent.match(/android/gi)&&e.preventDefault();else{var t=e.touches[0].clientX,n=e.touches[0].clientY;if(2===e.touches.length&&2===Tt.startCount&&ft.overview){var r=d({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:Tt.startX,y:Tt.startY});Math.abs(Tt.startSpan-r)>Tt.threshold&&(Tt.handled=!0,Tt.startSpan>r?L():w()),e.preventDefault()}else if(1===e.touches.length&&2!==Tt.startCount){var o=t-Tt.startX,s=n-Tt.startY;o>Tt.threshold&&Math.abs(o)>Math.abs(s)?(Tt.handled=!0,X()):-Tt.threshold>o&&Math.abs(o)>Math.abs(s)?(Tt.handled=!0,Y()):s>Tt.threshold?(Tt.handled=!0,F()):-Tt.threshold>s&&(Tt.handled=!0,U()),e.preventDefault()}}}function Q(){Tt.handled=!1}function V(e){clearTimeout(Et),Et=setTimeout(function(){var t=e.detail||-e.wheelDelta;t>0?K():j()},100)}function B(e){e.preventDefault();var t=l(document.querySelectorAll(dt)).length,n=Math.floor(e.clientX/Lt.wrapper.offsetWidth*t);T(n)}function G(e){e.preventDefault(),X()}function J(e){e.preventDefault(),Y()}function et(e){e.preventDefault(),F()}function tt(e){e.preventDefault(),U()}function nt(e){e.preventDefault(),j()}function rt(e){e.preventDefault(),K()}function ot(){P()}function st(){h()}function at(e){if(xt&&E()){e.preventDefault();for(var t=e.target;t&&!t.nodeName.match(/section/gi);)t=t.parentNode;if(t&&!t.classList.contains("disabled")&&(w(),t.nodeName.match(/section/gi))){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);T(n,r)}}}var it,ct,lt=".reveal .slides section",dt=".reveal .slides>section",ut=".reveal .slides>section.present>section",vt=".reveal .slides>section:first-child",ft={width:960,height:700,margin:.1,minScale:.2,maxScale:1,controls:!0,progress:!0,history:!1,keyboard:!0,overview:!0,center:!0,touch:!0,loop:!1,rtl:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!0,theme:null,transition:"default",dependencies:[]},mt=ft.autoSlide,pt=0,ht=0,gt=[],yt=1,Lt={},wt="WebkitPerspective"in document.body.style||"MozPerspective"in document.body.style||"msPerspective"in document.body.style||"OPerspective"in document.body.style||"perspective"in document.body.style,bt="WebkitTransform"in document.body.style||"MozTransform"in document.body.style||"msTransform"in document.body.style||"OTransform"in document.body.style||"transform"in document.body.style,Et=0,St=0,qt=0,At=0,kt=0,xt=!1,Tt={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:e,configure:s,slide:T,left:X,right:Y,up:F,down:U,prev:j,next:K,prevFragment:I,nextFragment:H,navigateTo:T,navigateLeft:X,navigateRight:Y,navigateUp:F,navigateDown:U,navigatePrev:j,navigateNext:K,layout:h,toggleOverview:b,togglePause:k,isOverview:E,isPaused:x,addEventListeners:a,removeEventListeners:i,getIndices:z,getSlide:function(e,t){var n=document.querySelectorAll(dt)[e],r=n&&n.querySelectorAll("section");return t!==void 0?r?r[t]:void 0:n},getPreviousSlide:function(){return it},getCurrentSlide:function(){return ct},getScale:function(){return yt},getQueryHash:function(){var e={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(t){e[t.split("=").shift()]=t.split("=").pop()}),e},isFirstSlide:function(){return null==document.querySelector(lt+".past")?!0:!1},isLastSlide:function(){return ct&&ct.classList.contains(".stack")?null==ct.querySelector(lt+".future")?!0:!1:null==document.querySelector(lt+".future")?!0:!1},addEventListener:function(e,t,n){"addEventListener"in window&&(Lt.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(Lt.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file From f9f17be01473bd80e8f1b6431c6070c4005e1164 Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Wed, 27 Feb 2013 15:01:30 -0500 Subject: [PATCH 14/22] merge external markdown support, move example to plugin (#329) --- demo.md | 29 --------- index-markdown.html | 116 ----------------------------------- plugin/markdown/example.html | 97 +++++++++++++++++++++++++++++ plugin/markdown/example.md | 29 +++++++++ 4 files changed, 126 insertions(+), 145 deletions(-) delete mode 100644 demo.md delete mode 100644 index-markdown.html create mode 100644 plugin/markdown/example.html create mode 100644 plugin/markdown/example.md diff --git a/demo.md b/demo.md deleted file mode 100644 index 1efe5f9..0000000 --- a/demo.md +++ /dev/null @@ -1,29 +0,0 @@ -# External markdown - - - -## Slide 1.1 - -Content 1.1 - - -## Slide 1.2 - -Content 1.2 - - - -## Slide 2 - -Content 2.1 - - - -## Slide 3.1 - -Content 3.1 - - -## Slide 3.2 - -Content 3.2 diff --git a/index-markdown.html b/index-markdown.html deleted file mode 100644 index 367c879..0000000 --- a/index-markdown.html +++ /dev/null @@ -1,116 +0,0 @@ - - - - - - - reveal.js - The HTML Presentation Framework - - - - - - - - - - - - - - - - - - - - - -
- - -
- - -
- - -
- -
- - -
- -
- - -
- -
- -
-
- - - - - - - - diff --git a/plugin/markdown/example.html b/plugin/markdown/example.html new file mode 100644 index 0000000..b4e7f91 --- /dev/null +++ b/plugin/markdown/example.html @@ -0,0 +1,97 @@ + + + + + + + reveal.js - Markdown Demo + + + + + + + +
+ +
+ + +
+ + +
+ +
+ + +
+ +
+ + +
+ +
+ +
+
+ + + + + + + + diff --git a/plugin/markdown/example.md b/plugin/markdown/example.md new file mode 100644 index 0000000..e988dd9 --- /dev/null +++ b/plugin/markdown/example.md @@ -0,0 +1,29 @@ +# Markdown Demo + + + +## External 1.1 + +Content 1.1 + + +## External 1.2 + +Content 1.2 + + + +## External 2 + +Content 2.1 + + + +## External 3.1 + +Content 3.1 + + +## External 3.2 + +Content 3.2 From 7cc0c8787d9f07efff0bc49ac655d19c6eebd8b6 Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Wed, 27 Feb 2013 15:05:56 -0500 Subject: [PATCH 15/22] add note about external markdown in readme (#329) --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 4375933..22216da 100644 --- a/README.md +++ b/README.md @@ -37,7 +37,7 @@ Markup heirarchy needs to be ``
``` elements and wrap the contents in a ```