From 271bae6b563ef1a625cf582934d589759cec7db7 Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Sun, 18 Aug 2013 00:01:28 -0400 Subject: [PATCH] allow hiding of vertical slide stacks --- js/reveal.js | 12 +++--------- js/reveal.min.js | 4 ++-- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/js/reveal.js b/js/reveal.js index 4ce8f3b..9c8b4b0 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -1688,11 +1688,10 @@ var Reveal = (function(){ // Loops so that it measures 1 between the first and last slides distanceX = Math.abs( ( indexh - x ) % ( horizontalSlidesLength - viewDistance ) ) || 0; - if( verticalSlidesLength ) { + // Show the horizontal slide if it's within the view distance + horizontalSlide.style.display = distanceX > viewDistance ? 'none' : 'block'; - // Always show the vertical stack itself, even if its child - // slides are invisible - horizontalSlide.style.display = 'block'; + if( verticalSlidesLength ) { var oy = getPreviousVerticalIndex( horizontalSlide ); @@ -1705,11 +1704,6 @@ var Reveal = (function(){ } } - else { - - horizontalSlide.style.display = distanceX > viewDistance ? 'none' : 'block'; - - } } } diff --git a/js/reveal.min.js b/js/reveal.min.js index edc5cca..6efd513 100644 --- a/js/reveal.min.js +++ b/js/reveal.min.js @@ -1,8 +1,8 @@ /*! - * reveal.js 2.5.0 (2013-08-17, 12:17) + * reveal.js 2.5.0 (2013-08-18, 00:00) * 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 t(),Rt||It?(window.addEventListener("load",T,!1),d(Ut,e),y(),n(),void 0):(document.body.setAttribute("class","no-transforms"),void 0)}function t(){It="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,Rt="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,Ht=navigator.userAgent.match(/(iphone|ipod|android)/gi)}function n(){function e(){n.length&&head.js.apply(null,n),r()}for(var t=[],n=[],o=0,a=Ut.dependencies.length;a>o;o++){var i=Ut.dependencies[o];(!i.condition||i.condition())&&(i.async?n.push(i.src):t.push(i.src),"function"==typeof i.callback&&head.ready(i.src.match(/([\w\d_\-]*)\.?js$|[^\\\/]*$/i)[0],i.callback))}t.length?(head.ready(e),head.js.apply(null,t)):e()}function r(){a(),o(),c(),G(),setTimeout(function(){Kt.slides.classList.remove("no-transition"),Wt=!0,w("ready",{indexh:Nt,indexv:Pt,currentSlide:Ct})},1)}function o(){var e=f(document.querySelectorAll(Xt));e.forEach(function(e){var t=f(e.querySelectorAll("section"));t.forEach(function(e,t){t>0&&e.classList.add("future")})})}function a(){Kt.theme=document.querySelector("#theme"),Kt.wrapper=document.querySelector(".reveal"),Kt.slides=document.querySelector(".reveal .slides"),Kt.slides.classList.add("no-transition"),Kt.background=i(Kt.wrapper,"div","backgrounds",null),Kt.progress=i(Kt.wrapper,"div","progress",""),Kt.progressbar=Kt.progress.querySelector("span"),i(Kt.wrapper,"aside","controls",''),i(Kt.wrapper,"div","state-background",null),i(Kt.wrapper,"div","pause-overlay",null),Ut.controls&&(Kt.controls=document.querySelector(".reveal .controls"),Kt.controlsLeft=f(document.querySelectorAll(".navigate-left")),Kt.controlsRight=f(document.querySelectorAll(".navigate-right")),Kt.controlsUp=f(document.querySelectorAll(".navigate-up")),Kt.controlsDown=f(document.querySelectorAll(".navigate-down")),Kt.controlsPrev=f(document.querySelectorAll(".navigate-prev")),Kt.controlsNext=f(document.querySelectorAll(".navigate-next")))}function i(e,t,n,r){var o=e.querySelector("."+n);return o||(o=document.createElement(t),o.classList.add(n),null!==r&&(o.innerHTML=r),e.appendChild(o)),o}function s(){function e(e,t){var n={background:e.getAttribute("data-background"),backgroundSize:e.getAttribute("data-background-size"),backgroundImage:e.getAttribute("data-background-image"),backgroundColor:e.getAttribute("data-background-color"),backgroundRepeat:e.getAttribute("data-background-repeat"),backgroundPosition:e.getAttribute("data-background-position"),backgroundTransition:e.getAttribute("data-background-transition")},r=document.createElement("div");return r.className="slide-background",n.background&&(/^(http|file|\/\/)/gi.test(n.background)||/\.(png|jpg|jpeg|gif|bmp)$/gi.test(n.background)?r.style.backgroundImage="url("+n.background+")":r.style.background=n.background),n.backgroundSize&&(r.style.backgroundSize=n.backgroundSize),n.backgroundImage&&(r.style.backgroundImage='url("'+n.backgroundImage+'")'),n.backgroundColor&&(r.style.backgroundColor=n.backgroundColor),n.backgroundRepeat&&(r.style.backgroundRepeat=n.backgroundRepeat),n.backgroundPosition&&(r.style.backgroundPosition=n.backgroundPosition),n.backgroundTransition&&r.setAttribute("data-background-transition",n.backgroundTransition),t.appendChild(r),r}h()&&document.body.classList.add("print-pdf"),Kt.background.innerHTML="",Kt.background.classList.add("no-transition"),f(document.querySelectorAll(Xt)).forEach(function(t){var n;n=h()?e(t,t):e(t,Kt.background),f(t.querySelectorAll("section")).forEach(function(t){h()?e(t,t):e(t,n)})})}function c(e){if(Kt.wrapper.classList.remove(Ut.transition),"object"==typeof e&&d(Ut,e),It===!1&&(Ut.transition="linear"),Kt.wrapper.classList.add(Ut.transition),Kt.wrapper.setAttribute("data-transition-speed",Ut.transitionSpeed),Kt.wrapper.setAttribute("data-background-transition",Ut.backgroundTransition),Kt.controls&&(Kt.controls.style.display=Ut.controls&&Kt.controls?"block":"none"),Kt.progress&&(Kt.progress.style.display=Ut.progress&&Kt.progress?"block":"none"),Ut.rtl?Kt.wrapper.classList.add("rtl"):Kt.wrapper.classList.remove("rtl"),Ut.center?Kt.wrapper.classList.add("center"):Kt.wrapper.classList.remove("center"),Ut.mouseWheel?(document.addEventListener("DOMMouseScroll",yt,!1),document.addEventListener("mousewheel",yt,!1)):(document.removeEventListener("DOMMouseScroll",yt,!1),document.removeEventListener("mousewheel",yt,!1)),Ut.rollingLinks?L():E(),Ut.previewLinks?k():(S(),k("[data-preview-link]")),Ut.theme&&Kt.theme){var t=Kt.theme.getAttribute("href"),n=/[^\/]*?(?=\.css)/,r=t.match(n)[0];Ut.theme!==r&&(t=t.replace(n,Ut.theme),Kt.theme.setAttribute("href",t))}W()}function l(){Gt=!0,window.addEventListener("hashchange",qt,!1),window.addEventListener("resize",xt,!1),Ut.touch&&(Kt.wrapper.addEventListener("touchstart",ft,!1),Kt.wrapper.addEventListener("touchmove",vt,!1),Kt.wrapper.addEventListener("touchend",pt,!1),window.navigator.msPointerEnabled&&(Kt.wrapper.addEventListener("MSPointerDown",gt,!1),Kt.wrapper.addEventListener("MSPointerMove",mt,!1),Kt.wrapper.addEventListener("MSPointerUp",ht,!1))),Ut.keyboard&&document.addEventListener("keydown",dt,!1),Ut.progress&&Kt.progress&&Kt.progress.addEventListener("click",bt,!1),Ut.controls&&Kt.controls&&["touchstart","click"].forEach(function(e){Kt.controlsLeft.forEach(function(t){t.addEventListener(e,wt,!1)}),Kt.controlsRight.forEach(function(t){t.addEventListener(e,Lt,!1)}),Kt.controlsUp.forEach(function(t){t.addEventListener(e,Et,!1)}),Kt.controlsDown.forEach(function(t){t.addEventListener(e,kt,!1)}),Kt.controlsPrev.forEach(function(t){t.addEventListener(e,St,!1)}),Kt.controlsNext.forEach(function(t){t.addEventListener(e,At,!1)})})}function u(){Gt=!1,document.removeEventListener("keydown",dt,!1),window.removeEventListener("hashchange",qt,!1),window.removeEventListener("resize",xt,!1),Kt.wrapper.removeEventListener("touchstart",ft,!1),Kt.wrapper.removeEventListener("touchmove",vt,!1),Kt.wrapper.removeEventListener("touchend",pt,!1),window.navigator.msPointerEnabled&&(Kt.wrapper.removeEventListener("MSPointerDown",gt,!1),Kt.wrapper.removeEventListener("MSPointerMove",mt,!1),Kt.wrapper.removeEventListener("MSPointerUp",ht,!1)),Ut.progress&&Kt.progress&&Kt.progress.removeEventListener("click",bt,!1),Ut.controls&&Kt.controls&&["touchstart","click"].forEach(function(e){Kt.controlsLeft.forEach(function(t){t.removeEventListener(e,wt,!1)}),Kt.controlsRight.forEach(function(t){t.removeEventListener(e,Lt,!1)}),Kt.controlsUp.forEach(function(t){t.removeEventListener(e,Et,!1)}),Kt.controlsDown.forEach(function(t){t.removeEventListener(e,kt,!1)}),Kt.controlsPrev.forEach(function(t){t.removeEventListener(e,St,!1)}),Kt.controlsNext.forEach(function(t){t.removeEventListener(e,At,!1)})})}function d(e,t){for(var n in t)e[n]=t[n]}function f(e){return Array.prototype.slice.call(e)}function v(e,t){var n=e.x-t.x,r=e.y-t.y;return Math.sqrt(n*n+r*r)}function p(e,t){e.style.WebkitTransform=t,e.style.MozTransform=t,e.style.msTransform=t,e.style.OTransform=t,e.style.transform=t}function g(e){var t=0;if(e){var n=0;f(e.childNodes).forEach(function(e){"number"==typeof e.offsetTop&&e.style&&("absolute"===e.style.position&&(n+=1),t=Math.max(t,e.offsetTop+e.offsetHeight))}),0===n&&(t=e.offsetHeight)}return t}function m(e,t){if(t=t||0,e){var n=e.parentNode,r=n.childNodes;f(r).forEach(function(n){if("number"==typeof n.offsetHeight&&n!==e){var r=window.getComputedStyle(n),o=parseInt(r.marginTop,10),a=parseInt(r.marginBottom,10);t-=n.offsetHeight+o+a}});var o=window.getComputedStyle(e);t-=parseInt(o.marginTop,10)+parseInt(o.marginBottom,10)}return t}function h(){return/print-pdf/gi.test(window.location.search)}function y(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",b,!1),window.addEventListener("orientationchange",b,!1))}function b(){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 w(e,t){var n=document.createEvent("HTMLEvents",1,2);n.initEvent(e,!0,!0),d(n,t),Kt.wrapper.dispatchEvent(n)}function L(){if(It&&!("msPerspective"in document.body.style))for(var e=document.querySelectorAll(Yt+" 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 E(){for(var e=document.querySelectorAll(Yt+" 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 k(e){var t=f(document.querySelectorAll(e?e:"a"));t.forEach(function(e){/^(http|www)/gi.test(e.getAttribute("href"))&&e.addEventListener("click",Mt,!1)})}function S(){var e=f(document.querySelectorAll("a"));e.forEach(function(e){/^(http|www)/gi.test(e.getAttribute("href"))&&e.removeEventListener("click",Mt,!1)})}function A(e){q(),Kt.preview=document.createElement("div"),Kt.preview.classList.add("preview-link-overlay"),Kt.wrapper.appendChild(Kt.preview),Kt.preview.innerHTML=["
",'','',"
",'
','
','',"
"].join(""),Kt.preview.querySelector("iframe").addEventListener("load",function(){Kt.preview.classList.add("loaded")},!1),Kt.preview.querySelector(".close").addEventListener("click",function(e){q(),e.preventDefault()},!1),Kt.preview.querySelector(".external").addEventListener("click",function(){q()},!1),setTimeout(function(){Kt.preview.classList.add("visible")},1)}function q(){Kt.preview&&(Kt.preview.setAttribute("src",""),Kt.preview.parentNode.removeChild(Kt.preview),Kt.preview=null)}function x(e){var t=f(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 T(){if(Kt.wrapper&&!h()){var e=Kt.wrapper.offsetWidth,t=Kt.wrapper.offsetHeight;e-=t*Ut.margin,t-=t*Ut.margin;var n=Ut.width,r=Ut.height,o=20;"string"==typeof n&&/%$/.test(n)&&(n=parseInt(n,10)/100*e),"string"==typeof r&&/%$/.test(r)&&(r=parseInt(r,10)/100*t),Kt.slides.style.width=n+"px",Kt.slides.style.height=r+"px",f(Kt.slides.querySelectorAll("section > .remaining-height")).forEach(function(e){e.style.height=m(e,r-2*o)+"px"}),_t=Math.min(e/n,t/r),_t=Math.max(_t,Ut.minScale),_t=Math.min(_t,Ut.maxScale),void 0===Kt.slides.style.zoom||navigator.userAgent.match(/(iphone|ipod|ipad|android)/gi)?p(Kt.slides,"translate(-50%, -50%) scale("+_t+") translate(50%, 50%)"):Kt.slides.style.zoom=_t;for(var a=f(document.querySelectorAll(Yt)),i=0,s=a.length;s>i;i++){var c=a[i];"none"!==c.style.display&&(c.style.top=Ut.center?c.classList.contains("stack")?0:Math.max(-(g(c)/2)-o,-r/2)+"px":"")}_()}}function M(e,t){"object"==typeof e&&"function"==typeof e.setAttribute&&e.setAttribute("data-previous-indexv",t||0)}function N(e){if("object"==typeof e&&"function"==typeof e.setAttribute&&e.classList.contains("stack")){var t=e.hasAttribute("data-start-indexv")?"data-start-indexv":"data-previous-indexv";return parseInt(e.getAttribute(t)||0,10)}return 0}function P(){if(Ut.overview){ot();var e=Kt.wrapper.classList.contains("overview"),t=400>window.innerWidth?1e3:2500;Kt.wrapper.classList.add("overview"),Kt.wrapper.classList.remove("exit-overview"),clearTimeout(Zt),clearTimeout(Qt),Zt=setTimeout(function(){for(var n=document.querySelectorAll(Xt),r=0,o=n.length;o>r;r++){var a=n[r],i=Ut.rtl?-105:105;if(a.setAttribute("data-index-h",r),p(a,"translateZ(-"+t+"px) translate("+(r-Nt)*i+"%, 0%)"),a.classList.contains("stack"))for(var s=a.querySelectorAll("section"),c=0,l=s.length;l>c;c++){var u=r===Nt?Pt:N(a),d=s[c];d.setAttribute("data-index-h",r),d.setAttribute("data-index-v",c),p(d,"translate(0%, "+105*(c-u)+"%)"),d.addEventListener("click",Tt,!0)}else a.addEventListener("click",Tt,!0)}F(),T(),e||w("overviewshown",{indexh:Nt,indexv:Pt,currentSlide:Ct})},10)}}function D(){if(Ut.overview){clearTimeout(Zt),clearTimeout(Qt),Kt.wrapper.classList.remove("overview"),Kt.wrapper.classList.add("exit-overview"),Qt=setTimeout(function(){Kt.wrapper.classList.remove("exit-overview")},10);for(var e=f(document.querySelectorAll(Yt)),t=0,n=e.length;n>t;t++){var r=e[t];r.style.display="",p(r,""),r.removeEventListener("click",Tt,!0)}U(Nt,Pt),rt(),w("overviewhidden",{indexh:Nt,indexv:Pt,currentSlide:Ct})}}function C(e){"boolean"==typeof e?e?P():D():I()?D():P()}function I(){return Kt.wrapper.classList.contains("overview")}function R(e){return e=e?e:Ct,e&&!!e.parentNode.nodeName.match(/section/i)}function H(){var e=document.body,t=e.requestFullScreen||e.webkitRequestFullscreen||e.webkitRequestFullScreen||e.mozRequestFullScreen||e.msRequestFullScreen;t&&t.apply(e)}function Y(){var e=Kt.wrapper.classList.contains("paused");ot(),Kt.wrapper.classList.add("paused"),e===!1&&w("paused")}function X(){var e=Kt.wrapper.classList.contains("paused");Kt.wrapper.classList.remove("paused"),rt(),e&&w("resumed")}function O(){z()?X():Y()}function z(){return Kt.wrapper.classList.contains("paused")}function U(e,t,n,r){Dt=Ct;var o=document.querySelectorAll(Xt);void 0===t&&(t=N(o[e])),Dt&&Dt.parentNode&&Dt.parentNode.classList.contains("stack")&&M(Dt.parentNode,Pt);var a=Ft.concat();Ft.length=0;var i=Nt||0,s=Pt||0;Nt=j(Xt,void 0===e?Nt:e),Pt=j(Ot,void 0===t?Pt:t),F(),T();e:for(var c=0,l=Ft.length;l>c;c++){for(var u=0;a.length>u;u++)if(a[u]===Ft[c]){a.splice(u,1);continue e}document.documentElement.classList.add(Ft[c]),w(Ft[c])}for(;a.length;)document.documentElement.classList.remove(a.pop());I()&&P();var d=o[Nt],v=d.querySelectorAll("section");if(Ct=v[Pt]||d,n!==void 0){var p=x(Ct.querySelectorAll(".fragment"));f(p).forEach(function(e,t){n>t?e.classList.add("visible"):e.classList.remove("visible")})}var g=Nt!==i||Pt!==s;g?w("slidechanged",{indexh:Nt,indexv:Pt,previousSlide:Dt,currentSlide:Ct,origin:r}):Dt=null,Dt&&(Dt.classList.remove("present"),document.querySelector(zt).classList.contains("present")&&setTimeout(function(){var e,t=f(document.querySelectorAll(Xt+".stack"));for(e in t)t[e]&&M(t[e],0)},0)),g&&(Q(Dt),Z(Ct)),K(),_(),$(),J()}function W(){u(),l(),T(),jt=Ut.autoSlide,rt(),s(),K(),_(),$()}function j(e,t){var n=f(document.querySelectorAll(e)),r=n.length;if(r){Ut.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 a=n[o],i=Ut.rtl&&!R(a);if(a.classList.remove("past"),a.classList.remove("present"),a.classList.remove("future"),a.setAttribute("hidden",""),t>o)a.classList.add(i?"future":"past");else if(o>t){a.classList.add(i?"past":"future");for(var s=f(a.querySelectorAll(".fragment.visible"));s.length;)s.pop().classList.remove("visible")}a.querySelector("section")&&a.classList.add("stack")}n[t].classList.add("present"),n[t].removeAttribute("hidden");var c=n[t].getAttribute("data-state");c&&(Ft=Ft.concat(c.split(" ")));var l=n[t].getAttribute("data-autoslide");jt=l?parseInt(l,10):Ut.autoSlide,rt()}else t=0;return t}function F(){var e,t,n=f(document.querySelectorAll(Xt)),r=n.length;if(r){var o=I()?10:Ut.viewDistance;Ht&&(o=I()?6:1);for(var a=0;r>a;a++){var i=n[a],s=f(i.querySelectorAll("section")),c=s.length;if(e=Math.abs((Nt-a)%(r-o))||0,c){i.style.display="block";for(var l=N(i),u=0;c>u;u++){var d=s[u];t=a===Nt?Math.abs(Pt-u):Math.abs(u-l),d.style.display=e+t>o?"none":"block"}}else i.style.display=e>o?"none":"block"}}}function _(){if(Ut.progress&&Kt.progress){var e=f(document.querySelectorAll(Xt)),t=document.querySelectorAll(Yt+":not(.stack)").length,n=0;e:for(var r=0;e.length>r;r++){for(var o=e[r],a=f(o.querySelectorAll("section")),i=0;a.length>i;i++){if(a[i].classList.contains("present"))break e;n++}if(o.classList.contains("present"))break;o.classList.contains("stack")===!1&&n++}Kt.progressbar.style.width=n/(t-1)*window.innerWidth+"px"}}function K(){if(Ut.controls&&Kt.controls){var e=V(),t=B();Kt.controlsLeft.concat(Kt.controlsRight).concat(Kt.controlsUp).concat(Kt.controlsDown).concat(Kt.controlsPrev).concat(Kt.controlsNext).forEach(function(e){e.classList.remove("enabled"),e.classList.remove("fragmented")}),e.left&&Kt.controlsLeft.forEach(function(e){e.classList.add("enabled")}),e.right&&Kt.controlsRight.forEach(function(e){e.classList.add("enabled")}),e.up&&Kt.controlsUp.forEach(function(e){e.classList.add("enabled")}),e.down&&Kt.controlsDown.forEach(function(e){e.classList.add("enabled")}),(e.left||e.up)&&Kt.controlsPrev.forEach(function(e){e.classList.add("enabled")}),(e.right||e.down)&&Kt.controlsNext.forEach(function(e){e.classList.add("enabled")}),Ct&&(t.prev&&Kt.controlsPrev.forEach(function(e){e.classList.add("fragmented","enabled")}),t.next&&Kt.controlsNext.forEach(function(e){e.classList.add("fragmented","enabled")}),R(Ct)?(t.prev&&Kt.controlsUp.forEach(function(e){e.classList.add("fragmented","enabled")}),t.next&&Kt.controlsDown.forEach(function(e){e.classList.add("fragmented","enabled")})):(t.prev&&Kt.controlsLeft.forEach(function(e){e.classList.add("fragmented","enabled")}),t.next&&Kt.controlsRight.forEach(function(e){e.classList.add("fragmented","enabled")})))}}function $(){f(Kt.background.childNodes).forEach(function(e,t){var n=Ut.rtl?"future":"past",r=Ut.rtl?"past":"future";e.className="slide-background "+(Nt>t?n:t>Nt?r:"present"),f(e.childNodes).forEach(function(e,t){e.className="slide-background "+(Pt>t?"past":t>Pt?"future":"present")})}),setTimeout(function(){Kt.background.classList.remove("no-transition")},1)}function V(){var e=document.querySelectorAll(Xt),t=document.querySelectorAll(Ot),n={left:Nt>0||Ut.loop,right:e.length-1>Nt||Ut.loop,up:Pt>0,down:t.length-1>Pt};if(Ut.rtl){var r=n.left;n.left=n.right,n.right=r}return n}function B(){if(Ct&&Ut.fragments){var e=Ct.querySelectorAll(".fragment"),t=Ct.querySelectorAll(".fragment:not(.visible)");return{prev:e.length-t.length>0,next:!!t.length}}return{prev:!1,next:!1}}function Z(e){e&&(f(e.querySelectorAll("video, audio")).forEach(function(e){e.hasAttribute("data-autoplay")&&e.play()}),f(e.querySelectorAll('iframe[src*="youtube.com/embed/"]')).forEach(function(e){e.hasAttribute("data-autoplay")&&e.contentWindow.postMessage('{"event":"command","func":"playVideo","args":""}',"*")}))}function Q(e){e&&(f(e.querySelectorAll("video, audio")).forEach(function(e){e.hasAttribute("data-ignore")||e.pause()}),f(e.querySelectorAll('iframe[src*="youtube.com/embed/"]')).forEach(function(e){e.hasAttribute("data-ignore")||"function"!=typeof e.contentWindow.postMessage||e.contentWindow.postMessage('{"event":"command","func":"pauseVideo","args":""}',"*")}))}function G(){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);U(o.h,o.v)}else U(Nt||0,Pt||0)}else{var a=parseInt(t[0],10)||0,i=parseInt(t[1],10)||0;(a!==Nt||i!==Pt)&&U(a,i)}}function J(e){if(Ut.history)if(clearTimeout(Bt),"number"==typeof e)Bt=setTimeout(J,e);else{var t="/";Ct&&"string"==typeof Ct.getAttribute("id")?t="/"+Ct.getAttribute("id"):((Nt>0||Pt>0)&&(t+=Nt),Pt>0&&(t+="/"+Pt)),window.location.hash=t}}function et(e){var t,n=Nt,r=Pt;if(e){var o=R(e),a=o?e.parentNode:e,i=f(document.querySelectorAll(Xt));n=Math.max(i.indexOf(a),0),o&&(r=Math.max(f(e.parentNode.querySelectorAll("section")).indexOf(e),0))}if(!e&&Ct){var s=Ct.querySelectorAll(".fragment").length>0;if(s){var c=Ct.querySelectorAll(".fragment.visible");t=c.length}}return{h:n,v:r,f:t}}function tt(){if(Ct&&Ut.fragments){var e=x(Ct.querySelectorAll(".fragment:not(.visible)"));if(e.length){var t=e[0].getAttribute("data-fragment-index");return e=Ct.querySelectorAll('.fragment[data-fragment-index="'+t+'"]'),f(e).forEach(function(e){e.classList.add("visible")}),w("fragmentshown",{fragment:e[0],fragments:e}),K(),!0}}return!1}function nt(){if(Ct&&Ut.fragments){var e=x(Ct.querySelectorAll(".fragment.visible"));if(e.length){var t=e[e.length-1].getAttribute("data-fragment-index");return e=Ct.querySelectorAll('.fragment[data-fragment-index="'+t+'"]'),f(e).forEach(function(e){e.classList.remove("visible")}),w("fragmenthidden",{fragment:e[0],fragments:e}),K(),!0}}return!1}function rt(){clearTimeout(Vt),!jt||z()||I()||(Vt=setTimeout(ut,jt))}function ot(){clearTimeout(Vt)}function at(){Ut.rtl?(I()||tt()===!1)&&V().left&&U(Nt+1):(I()||nt()===!1)&&V().left&&U(Nt-1)}function it(){Ut.rtl?(I()||nt()===!1)&&V().right&&U(Nt-1):(I()||tt()===!1)&&V().right&&U(Nt+1)}function st(){(I()||nt()===!1)&&V().up&&U(Nt,Pt-1)}function ct(){(I()||tt()===!1)&&V().down&&U(Nt,Pt+1)}function lt(){if(nt()===!1)if(V().up)st();else{var e=document.querySelector(Xt+".past:nth-child("+Nt+")");if(e){var t=e.querySelectorAll("section").length-1||void 0,n=Nt-1;U(n,t)}}}function ut(){tt()===!1&&(V().down?ct():it()),rt()}function dt(e){document.activeElement;var t=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&"inherit"===document.activeElement.contentEditable);if(!(t||e.shiftKey&&32!==e.keyCode||e.altKey||e.ctrlKey||e.metaKey)){if(z()&&-1===[66,190,191].indexOf(e.keyCode))return!1;var n=!1;if("object"==typeof Ut.keyboard)for(var r in Ut.keyboard)if(parseInt(r,10)===e.keyCode){var o=Ut.keyboard[r];"function"==typeof o?o.apply(null,[e]):"string"==typeof o&&"function"==typeof Reveal[o]&&Reveal[o].call(),n=!0}if(n===!1)switch(n=!0,e.keyCode){case 80:case 33:lt();break;case 78:case 34:ut();break;case 72:case 37:at();break;case 76:case 39:it();break;case 75:case 38:st();break;case 74:case 40:ct();break;case 36:U(0);break;case 35:U(Number.MAX_VALUE);break;case 32:I()?D():e.shiftKey?lt():ut();break;case 13:I()?D():n=!1;break;case 66:case 190:case 191:O();break;case 70:H();break;default:n=!1}n?e.preventDefault():27!==e.keyCode&&79!==e.keyCode||!It||(C(),e.preventDefault()),rt()}}function ft(e){Jt.startX=e.touches[0].clientX,Jt.startY=e.touches[0].clientY,Jt.startCount=e.touches.length,2===e.touches.length&&Ut.overview&&(Jt.startSpan=v({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:Jt.startX,y:Jt.startY}))}function vt(e){if(Jt.captured)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===Jt.startCount&&Ut.overview){var r=v({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:Jt.startX,y:Jt.startY});Math.abs(Jt.startSpan-r)>Jt.threshold&&(Jt.captured=!0,Jt.startSpan>r?P():D()),e.preventDefault()}else if(1===e.touches.length&&2!==Jt.startCount){var o=t-Jt.startX,a=n-Jt.startY;o>Jt.threshold&&Math.abs(o)>Math.abs(a)?(Jt.captured=!0,at()):-Jt.threshold>o&&Math.abs(o)>Math.abs(a)?(Jt.captured=!0,it()):a>Jt.threshold?(Jt.captured=!0,st()):-Jt.threshold>a&&(Jt.captured=!0,ct()),Ut.embedded?(Jt.captured||R(Ct))&&e.preventDefault():e.preventDefault()}}}function pt(){Jt.captured=!1}function gt(e){e.pointerType===e.MSPOINTER_TYPE_TOUCH&&(e.touches=[{clientX:e.clientX,clientY:e.clientY}],ft(e))}function mt(e){e.pointerType===e.MSPOINTER_TYPE_TOUCH&&(e.touches=[{clientX:e.clientX,clientY:e.clientY}],vt(e))}function ht(e){e.pointerType===e.MSPOINTER_TYPE_TOUCH&&(e.touches=[{clientX:e.clientX,clientY:e.clientY}],pt(e))}function yt(e){if(Date.now()-$t>600){$t=Date.now();var t=e.detail||-e.wheelDelta;t>0?ut():lt()}}function bt(e){e.preventDefault();var t=f(document.querySelectorAll(Xt)).length,n=Math.floor(e.clientX/Kt.wrapper.offsetWidth*t);U(n)}function wt(e){e.preventDefault(),at()}function Lt(e){e.preventDefault(),it()}function Et(e){e.preventDefault(),st()}function kt(e){e.preventDefault(),ct()}function St(e){e.preventDefault(),lt()}function At(e){e.preventDefault(),ut()}function qt(){G()}function xt(){T()}function Tt(e){if(Gt&&I()){e.preventDefault();for(var t=e.target;t&&!t.nodeName.match(/section/gi);)t=t.parentNode;if(t&&!t.classList.contains("disabled")&&(D(),t.nodeName.match(/section/gi))){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);U(n,r)}}}function Mt(e){var t=e.target.getAttribute("href");t&&(A(t),e.preventDefault())}var Nt,Pt,Dt,Ct,It,Rt,Ht,Yt=".reveal .slides section",Xt=".reveal .slides>section",Ot=".reveal .slides>section.present>section",zt=".reveal .slides>section:first-child",Ut={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,fragments:!0,embedded:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!1,previewLinks:!1,theme:null,transition:"default",transitionSpeed:"default",backgroundTransition:"default",viewDistance:3,dependencies:[]},Wt=!1,jt=0,Ft=[],_t=1,Kt={},$t=0,Vt=0,Bt=0,Zt=0,Qt=0,Gt=!1,Jt={startX:0,startY:0,startSpan:0,startCount:0,captured:!1,threshold:40};return{initialize:e,configure:c,sync:W,slide:U,left:at,right:it,up:st,down:ct,prev:lt,next:ut,prevFragment:nt,nextFragment:tt,navigateTo:U,navigateLeft:at,navigateRight:it,navigateUp:st,navigateDown:ct,navigatePrev:lt,navigateNext:ut,layout:T,availableRoutes:V,availableFragments:B,toggleOverview:C,togglePause:O,isOverview:I,isPaused:z,addEventListeners:l,removeEventListeners:u,getIndices:et,getSlide:function(e,t){var n=document.querySelectorAll(Xt)[e],r=n&&n.querySelectorAll("section");return t!==void 0?r?r[t]:void 0:n},getPreviousSlide:function(){return Dt},getCurrentSlide:function(){return Ct},getScale:function(){return _t},getConfig:function(){return Ut},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(Yt+".past")?!0:!1},isLastSlide:function(){return Ct&&Ct.classList.contains(".stack")?null==Ct.querySelector(Yt+".future")?!0:!1:null==document.querySelector(Yt+".future")?!0:!1},isReady:function(){return Wt},addEventListener:function(e,t,n){"addEventListener"in window&&(Kt.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(Kt.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file +var Reveal=function(){"use strict";function e(e){return t(),Rt||It?(window.addEventListener("load",T,!1),d(Ut,e),y(),n(),void 0):(document.body.setAttribute("class","no-transforms"),void 0)}function t(){It="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,Rt="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,Ht=navigator.userAgent.match(/(iphone|ipod|android)/gi)}function n(){function e(){n.length&&head.js.apply(null,n),r()}for(var t=[],n=[],o=0,a=Ut.dependencies.length;a>o;o++){var i=Ut.dependencies[o];(!i.condition||i.condition())&&(i.async?n.push(i.src):t.push(i.src),"function"==typeof i.callback&&head.ready(i.src.match(/([\w\d_\-]*)\.?js$|[^\\\/]*$/i)[0],i.callback))}t.length?(head.ready(e),head.js.apply(null,t)):e()}function r(){a(),o(),c(),G(),setTimeout(function(){Kt.slides.classList.remove("no-transition"),Wt=!0,w("ready",{indexh:Nt,indexv:Pt,currentSlide:Ct})},1)}function o(){var e=f(document.querySelectorAll(Xt));e.forEach(function(e){var t=f(e.querySelectorAll("section"));t.forEach(function(e,t){t>0&&e.classList.add("future")})})}function a(){Kt.theme=document.querySelector("#theme"),Kt.wrapper=document.querySelector(".reveal"),Kt.slides=document.querySelector(".reveal .slides"),Kt.slides.classList.add("no-transition"),Kt.background=i(Kt.wrapper,"div","backgrounds",null),Kt.progress=i(Kt.wrapper,"div","progress",""),Kt.progressbar=Kt.progress.querySelector("span"),i(Kt.wrapper,"aside","controls",''),i(Kt.wrapper,"div","state-background",null),i(Kt.wrapper,"div","pause-overlay",null),Ut.controls&&(Kt.controls=document.querySelector(".reveal .controls"),Kt.controlsLeft=f(document.querySelectorAll(".navigate-left")),Kt.controlsRight=f(document.querySelectorAll(".navigate-right")),Kt.controlsUp=f(document.querySelectorAll(".navigate-up")),Kt.controlsDown=f(document.querySelectorAll(".navigate-down")),Kt.controlsPrev=f(document.querySelectorAll(".navigate-prev")),Kt.controlsNext=f(document.querySelectorAll(".navigate-next")))}function i(e,t,n,r){var o=e.querySelector("."+n);return o||(o=document.createElement(t),o.classList.add(n),null!==r&&(o.innerHTML=r),e.appendChild(o)),o}function s(){function e(e,t){var n={background:e.getAttribute("data-background"),backgroundSize:e.getAttribute("data-background-size"),backgroundImage:e.getAttribute("data-background-image"),backgroundColor:e.getAttribute("data-background-color"),backgroundRepeat:e.getAttribute("data-background-repeat"),backgroundPosition:e.getAttribute("data-background-position"),backgroundTransition:e.getAttribute("data-background-transition")},r=document.createElement("div");return r.className="slide-background",n.background&&(/^(http|file|\/\/)/gi.test(n.background)||/\.(png|jpg|jpeg|gif|bmp)$/gi.test(n.background)?r.style.backgroundImage="url("+n.background+")":r.style.background=n.background),n.backgroundSize&&(r.style.backgroundSize=n.backgroundSize),n.backgroundImage&&(r.style.backgroundImage='url("'+n.backgroundImage+'")'),n.backgroundColor&&(r.style.backgroundColor=n.backgroundColor),n.backgroundRepeat&&(r.style.backgroundRepeat=n.backgroundRepeat),n.backgroundPosition&&(r.style.backgroundPosition=n.backgroundPosition),n.backgroundTransition&&r.setAttribute("data-background-transition",n.backgroundTransition),t.appendChild(r),r}h()&&document.body.classList.add("print-pdf"),Kt.background.innerHTML="",Kt.background.classList.add("no-transition"),f(document.querySelectorAll(Xt)).forEach(function(t){var n;n=h()?e(t,t):e(t,Kt.background),f(t.querySelectorAll("section")).forEach(function(t){h()?e(t,t):e(t,n)})})}function c(e){if(Kt.wrapper.classList.remove(Ut.transition),"object"==typeof e&&d(Ut,e),It===!1&&(Ut.transition="linear"),Kt.wrapper.classList.add(Ut.transition),Kt.wrapper.setAttribute("data-transition-speed",Ut.transitionSpeed),Kt.wrapper.setAttribute("data-background-transition",Ut.backgroundTransition),Kt.controls&&(Kt.controls.style.display=Ut.controls&&Kt.controls?"block":"none"),Kt.progress&&(Kt.progress.style.display=Ut.progress&&Kt.progress?"block":"none"),Ut.rtl?Kt.wrapper.classList.add("rtl"):Kt.wrapper.classList.remove("rtl"),Ut.center?Kt.wrapper.classList.add("center"):Kt.wrapper.classList.remove("center"),Ut.mouseWheel?(document.addEventListener("DOMMouseScroll",yt,!1),document.addEventListener("mousewheel",yt,!1)):(document.removeEventListener("DOMMouseScroll",yt,!1),document.removeEventListener("mousewheel",yt,!1)),Ut.rollingLinks?L():E(),Ut.previewLinks?k():(S(),k("[data-preview-link]")),Ut.theme&&Kt.theme){var t=Kt.theme.getAttribute("href"),n=/[^\/]*?(?=\.css)/,r=t.match(n)[0];Ut.theme!==r&&(t=t.replace(n,Ut.theme),Kt.theme.setAttribute("href",t))}W()}function l(){Gt=!0,window.addEventListener("hashchange",qt,!1),window.addEventListener("resize",xt,!1),Ut.touch&&(Kt.wrapper.addEventListener("touchstart",ft,!1),Kt.wrapper.addEventListener("touchmove",vt,!1),Kt.wrapper.addEventListener("touchend",pt,!1),window.navigator.msPointerEnabled&&(Kt.wrapper.addEventListener("MSPointerDown",gt,!1),Kt.wrapper.addEventListener("MSPointerMove",mt,!1),Kt.wrapper.addEventListener("MSPointerUp",ht,!1))),Ut.keyboard&&document.addEventListener("keydown",dt,!1),Ut.progress&&Kt.progress&&Kt.progress.addEventListener("click",bt,!1),Ut.controls&&Kt.controls&&["touchstart","click"].forEach(function(e){Kt.controlsLeft.forEach(function(t){t.addEventListener(e,wt,!1)}),Kt.controlsRight.forEach(function(t){t.addEventListener(e,Lt,!1)}),Kt.controlsUp.forEach(function(t){t.addEventListener(e,Et,!1)}),Kt.controlsDown.forEach(function(t){t.addEventListener(e,kt,!1)}),Kt.controlsPrev.forEach(function(t){t.addEventListener(e,St,!1)}),Kt.controlsNext.forEach(function(t){t.addEventListener(e,At,!1)})})}function u(){Gt=!1,document.removeEventListener("keydown",dt,!1),window.removeEventListener("hashchange",qt,!1),window.removeEventListener("resize",xt,!1),Kt.wrapper.removeEventListener("touchstart",ft,!1),Kt.wrapper.removeEventListener("touchmove",vt,!1),Kt.wrapper.removeEventListener("touchend",pt,!1),window.navigator.msPointerEnabled&&(Kt.wrapper.removeEventListener("MSPointerDown",gt,!1),Kt.wrapper.removeEventListener("MSPointerMove",mt,!1),Kt.wrapper.removeEventListener("MSPointerUp",ht,!1)),Ut.progress&&Kt.progress&&Kt.progress.removeEventListener("click",bt,!1),Ut.controls&&Kt.controls&&["touchstart","click"].forEach(function(e){Kt.controlsLeft.forEach(function(t){t.removeEventListener(e,wt,!1)}),Kt.controlsRight.forEach(function(t){t.removeEventListener(e,Lt,!1)}),Kt.controlsUp.forEach(function(t){t.removeEventListener(e,Et,!1)}),Kt.controlsDown.forEach(function(t){t.removeEventListener(e,kt,!1)}),Kt.controlsPrev.forEach(function(t){t.removeEventListener(e,St,!1)}),Kt.controlsNext.forEach(function(t){t.removeEventListener(e,At,!1)})})}function d(e,t){for(var n in t)e[n]=t[n]}function f(e){return Array.prototype.slice.call(e)}function v(e,t){var n=e.x-t.x,r=e.y-t.y;return Math.sqrt(n*n+r*r)}function p(e,t){e.style.WebkitTransform=t,e.style.MozTransform=t,e.style.msTransform=t,e.style.OTransform=t,e.style.transform=t}function g(e){var t=0;if(e){var n=0;f(e.childNodes).forEach(function(e){"number"==typeof e.offsetTop&&e.style&&("absolute"===e.style.position&&(n+=1),t=Math.max(t,e.offsetTop+e.offsetHeight))}),0===n&&(t=e.offsetHeight)}return t}function m(e,t){if(t=t||0,e){var n=e.parentNode,r=n.childNodes;f(r).forEach(function(n){if("number"==typeof n.offsetHeight&&n!==e){var r=window.getComputedStyle(n),o=parseInt(r.marginTop,10),a=parseInt(r.marginBottom,10);t-=n.offsetHeight+o+a}});var o=window.getComputedStyle(e);t-=parseInt(o.marginTop,10)+parseInt(o.marginBottom,10)}return t}function h(){return/print-pdf/gi.test(window.location.search)}function y(){/iphone|ipod|android/gi.test(navigator.userAgent)&&!/crios/gi.test(navigator.userAgent)&&(window.addEventListener("load",b,!1),window.addEventListener("orientationchange",b,!1))}function b(){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 w(e,t){var n=document.createEvent("HTMLEvents",1,2);n.initEvent(e,!0,!0),d(n,t),Kt.wrapper.dispatchEvent(n)}function L(){if(It&&!("msPerspective"in document.body.style))for(var e=document.querySelectorAll(Yt+" 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 E(){for(var e=document.querySelectorAll(Yt+" 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 k(e){var t=f(document.querySelectorAll(e?e:"a"));t.forEach(function(e){/^(http|www)/gi.test(e.getAttribute("href"))&&e.addEventListener("click",Mt,!1)})}function S(){var e=f(document.querySelectorAll("a"));e.forEach(function(e){/^(http|www)/gi.test(e.getAttribute("href"))&&e.removeEventListener("click",Mt,!1)})}function A(e){q(),Kt.preview=document.createElement("div"),Kt.preview.classList.add("preview-link-overlay"),Kt.wrapper.appendChild(Kt.preview),Kt.preview.innerHTML=["
",'','',"
",'
','
','',"
"].join(""),Kt.preview.querySelector("iframe").addEventListener("load",function(){Kt.preview.classList.add("loaded")},!1),Kt.preview.querySelector(".close").addEventListener("click",function(e){q(),e.preventDefault()},!1),Kt.preview.querySelector(".external").addEventListener("click",function(){q()},!1),setTimeout(function(){Kt.preview.classList.add("visible")},1)}function q(){Kt.preview&&(Kt.preview.setAttribute("src",""),Kt.preview.parentNode.removeChild(Kt.preview),Kt.preview=null)}function x(e){var t=f(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 T(){if(Kt.wrapper&&!h()){var e=Kt.wrapper.offsetWidth,t=Kt.wrapper.offsetHeight;e-=t*Ut.margin,t-=t*Ut.margin;var n=Ut.width,r=Ut.height,o=20;"string"==typeof n&&/%$/.test(n)&&(n=parseInt(n,10)/100*e),"string"==typeof r&&/%$/.test(r)&&(r=parseInt(r,10)/100*t),Kt.slides.style.width=n+"px",Kt.slides.style.height=r+"px",f(Kt.slides.querySelectorAll("section > .remaining-height")).forEach(function(e){e.style.height=m(e,r-2*o)+"px"}),_t=Math.min(e/n,t/r),_t=Math.max(_t,Ut.minScale),_t=Math.min(_t,Ut.maxScale),void 0===Kt.slides.style.zoom||navigator.userAgent.match(/(iphone|ipod|ipad|android)/gi)?p(Kt.slides,"translate(-50%, -50%) scale("+_t+") translate(50%, 50%)"):Kt.slides.style.zoom=_t;for(var a=f(document.querySelectorAll(Yt)),i=0,s=a.length;s>i;i++){var c=a[i];"none"!==c.style.display&&(c.style.top=Ut.center?c.classList.contains("stack")?0:Math.max(-(g(c)/2)-o,-r/2)+"px":"")}_()}}function M(e,t){"object"==typeof e&&"function"==typeof e.setAttribute&&e.setAttribute("data-previous-indexv",t||0)}function N(e){if("object"==typeof e&&"function"==typeof e.setAttribute&&e.classList.contains("stack")){var t=e.hasAttribute("data-start-indexv")?"data-start-indexv":"data-previous-indexv";return parseInt(e.getAttribute(t)||0,10)}return 0}function P(){if(Ut.overview){ot();var e=Kt.wrapper.classList.contains("overview"),t=400>window.innerWidth?1e3:2500;Kt.wrapper.classList.add("overview"),Kt.wrapper.classList.remove("exit-overview"),clearTimeout(Zt),clearTimeout(Qt),Zt=setTimeout(function(){for(var n=document.querySelectorAll(Xt),r=0,o=n.length;o>r;r++){var a=n[r],i=Ut.rtl?-105:105;if(a.setAttribute("data-index-h",r),p(a,"translateZ(-"+t+"px) translate("+(r-Nt)*i+"%, 0%)"),a.classList.contains("stack"))for(var s=a.querySelectorAll("section"),c=0,l=s.length;l>c;c++){var u=r===Nt?Pt:N(a),d=s[c];d.setAttribute("data-index-h",r),d.setAttribute("data-index-v",c),p(d,"translate(0%, "+105*(c-u)+"%)"),d.addEventListener("click",Tt,!0)}else a.addEventListener("click",Tt,!0)}F(),T(),e||w("overviewshown",{indexh:Nt,indexv:Pt,currentSlide:Ct})},10)}}function D(){if(Ut.overview){clearTimeout(Zt),clearTimeout(Qt),Kt.wrapper.classList.remove("overview"),Kt.wrapper.classList.add("exit-overview"),Qt=setTimeout(function(){Kt.wrapper.classList.remove("exit-overview")},10);for(var e=f(document.querySelectorAll(Yt)),t=0,n=e.length;n>t;t++){var r=e[t];r.style.display="",p(r,""),r.removeEventListener("click",Tt,!0)}U(Nt,Pt),rt(),w("overviewhidden",{indexh:Nt,indexv:Pt,currentSlide:Ct})}}function C(e){"boolean"==typeof e?e?P():D():I()?D():P()}function I(){return Kt.wrapper.classList.contains("overview")}function R(e){return e=e?e:Ct,e&&!!e.parentNode.nodeName.match(/section/i)}function H(){var e=document.body,t=e.requestFullScreen||e.webkitRequestFullscreen||e.webkitRequestFullScreen||e.mozRequestFullScreen||e.msRequestFullScreen;t&&t.apply(e)}function Y(){var e=Kt.wrapper.classList.contains("paused");ot(),Kt.wrapper.classList.add("paused"),e===!1&&w("paused")}function X(){var e=Kt.wrapper.classList.contains("paused");Kt.wrapper.classList.remove("paused"),rt(),e&&w("resumed")}function O(){z()?X():Y()}function z(){return Kt.wrapper.classList.contains("paused")}function U(e,t,n,r){Dt=Ct;var o=document.querySelectorAll(Xt);void 0===t&&(t=N(o[e])),Dt&&Dt.parentNode&&Dt.parentNode.classList.contains("stack")&&M(Dt.parentNode,Pt);var a=Ft.concat();Ft.length=0;var i=Nt||0,s=Pt||0;Nt=j(Xt,void 0===e?Nt:e),Pt=j(Ot,void 0===t?Pt:t),F(),T();e:for(var c=0,l=Ft.length;l>c;c++){for(var u=0;a.length>u;u++)if(a[u]===Ft[c]){a.splice(u,1);continue e}document.documentElement.classList.add(Ft[c]),w(Ft[c])}for(;a.length;)document.documentElement.classList.remove(a.pop());I()&&P();var d=o[Nt],v=d.querySelectorAll("section");if(Ct=v[Pt]||d,n!==void 0){var p=x(Ct.querySelectorAll(".fragment"));f(p).forEach(function(e,t){n>t?e.classList.add("visible"):e.classList.remove("visible")})}var g=Nt!==i||Pt!==s;g?w("slidechanged",{indexh:Nt,indexv:Pt,previousSlide:Dt,currentSlide:Ct,origin:r}):Dt=null,Dt&&(Dt.classList.remove("present"),document.querySelector(zt).classList.contains("present")&&setTimeout(function(){var e,t=f(document.querySelectorAll(Xt+".stack"));for(e in t)t[e]&&M(t[e],0)},0)),g&&(Q(Dt),Z(Ct)),K(),_(),$(),J()}function W(){u(),l(),T(),jt=Ut.autoSlide,rt(),s(),K(),_(),$()}function j(e,t){var n=f(document.querySelectorAll(e)),r=n.length;if(r){Ut.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 a=n[o],i=Ut.rtl&&!R(a);if(a.classList.remove("past"),a.classList.remove("present"),a.classList.remove("future"),a.setAttribute("hidden",""),t>o)a.classList.add(i?"future":"past");else if(o>t){a.classList.add(i?"past":"future");for(var s=f(a.querySelectorAll(".fragment.visible"));s.length;)s.pop().classList.remove("visible")}a.querySelector("section")&&a.classList.add("stack")}n[t].classList.add("present"),n[t].removeAttribute("hidden");var c=n[t].getAttribute("data-state");c&&(Ft=Ft.concat(c.split(" ")));var l=n[t].getAttribute("data-autoslide");jt=l?parseInt(l,10):Ut.autoSlide,rt()}else t=0;return t}function F(){var e,t,n=f(document.querySelectorAll(Xt)),r=n.length;if(r){var o=I()?10:Ut.viewDistance;Ht&&(o=I()?6:1);for(var a=0;r>a;a++){var i=n[a],s=f(i.querySelectorAll("section")),c=s.length;if(e=Math.abs((Nt-a)%(r-o))||0,i.style.display=e>o?"none":"block",c)for(var l=N(i),u=0;c>u;u++){var d=s[u];t=a===Nt?Math.abs(Pt-u):Math.abs(u-l),d.style.display=e+t>o?"none":"block"}}}}function _(){if(Ut.progress&&Kt.progress){var e=f(document.querySelectorAll(Xt)),t=document.querySelectorAll(Yt+":not(.stack)").length,n=0;e:for(var r=0;e.length>r;r++){for(var o=e[r],a=f(o.querySelectorAll("section")),i=0;a.length>i;i++){if(a[i].classList.contains("present"))break e;n++}if(o.classList.contains("present"))break;o.classList.contains("stack")===!1&&n++}Kt.progressbar.style.width=n/(t-1)*window.innerWidth+"px"}}function K(){if(Ut.controls&&Kt.controls){var e=V(),t=B();Kt.controlsLeft.concat(Kt.controlsRight).concat(Kt.controlsUp).concat(Kt.controlsDown).concat(Kt.controlsPrev).concat(Kt.controlsNext).forEach(function(e){e.classList.remove("enabled"),e.classList.remove("fragmented")}),e.left&&Kt.controlsLeft.forEach(function(e){e.classList.add("enabled")}),e.right&&Kt.controlsRight.forEach(function(e){e.classList.add("enabled")}),e.up&&Kt.controlsUp.forEach(function(e){e.classList.add("enabled")}),e.down&&Kt.controlsDown.forEach(function(e){e.classList.add("enabled")}),(e.left||e.up)&&Kt.controlsPrev.forEach(function(e){e.classList.add("enabled")}),(e.right||e.down)&&Kt.controlsNext.forEach(function(e){e.classList.add("enabled")}),Ct&&(t.prev&&Kt.controlsPrev.forEach(function(e){e.classList.add("fragmented","enabled")}),t.next&&Kt.controlsNext.forEach(function(e){e.classList.add("fragmented","enabled")}),R(Ct)?(t.prev&&Kt.controlsUp.forEach(function(e){e.classList.add("fragmented","enabled")}),t.next&&Kt.controlsDown.forEach(function(e){e.classList.add("fragmented","enabled")})):(t.prev&&Kt.controlsLeft.forEach(function(e){e.classList.add("fragmented","enabled")}),t.next&&Kt.controlsRight.forEach(function(e){e.classList.add("fragmented","enabled")})))}}function $(){f(Kt.background.childNodes).forEach(function(e,t){var n=Ut.rtl?"future":"past",r=Ut.rtl?"past":"future";e.className="slide-background "+(Nt>t?n:t>Nt?r:"present"),f(e.childNodes).forEach(function(e,t){e.className="slide-background "+(Pt>t?"past":t>Pt?"future":"present")})}),setTimeout(function(){Kt.background.classList.remove("no-transition")},1)}function V(){var e=document.querySelectorAll(Xt),t=document.querySelectorAll(Ot),n={left:Nt>0||Ut.loop,right:e.length-1>Nt||Ut.loop,up:Pt>0,down:t.length-1>Pt};if(Ut.rtl){var r=n.left;n.left=n.right,n.right=r}return n}function B(){if(Ct&&Ut.fragments){var e=Ct.querySelectorAll(".fragment"),t=Ct.querySelectorAll(".fragment:not(.visible)");return{prev:e.length-t.length>0,next:!!t.length}}return{prev:!1,next:!1}}function Z(e){e&&(f(e.querySelectorAll("video, audio")).forEach(function(e){e.hasAttribute("data-autoplay")&&e.play()}),f(e.querySelectorAll('iframe[src*="youtube.com/embed/"]')).forEach(function(e){e.hasAttribute("data-autoplay")&&e.contentWindow.postMessage('{"event":"command","func":"playVideo","args":""}',"*")}))}function Q(e){e&&(f(e.querySelectorAll("video, audio")).forEach(function(e){e.hasAttribute("data-ignore")||e.pause()}),f(e.querySelectorAll('iframe[src*="youtube.com/embed/"]')).forEach(function(e){e.hasAttribute("data-ignore")||"function"!=typeof e.contentWindow.postMessage||e.contentWindow.postMessage('{"event":"command","func":"pauseVideo","args":""}',"*")}))}function G(){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);U(o.h,o.v)}else U(Nt||0,Pt||0)}else{var a=parseInt(t[0],10)||0,i=parseInt(t[1],10)||0;(a!==Nt||i!==Pt)&&U(a,i)}}function J(e){if(Ut.history)if(clearTimeout(Bt),"number"==typeof e)Bt=setTimeout(J,e);else{var t="/";Ct&&"string"==typeof Ct.getAttribute("id")?t="/"+Ct.getAttribute("id"):((Nt>0||Pt>0)&&(t+=Nt),Pt>0&&(t+="/"+Pt)),window.location.hash=t}}function et(e){var t,n=Nt,r=Pt;if(e){var o=R(e),a=o?e.parentNode:e,i=f(document.querySelectorAll(Xt));n=Math.max(i.indexOf(a),0),o&&(r=Math.max(f(e.parentNode.querySelectorAll("section")).indexOf(e),0))}if(!e&&Ct){var s=Ct.querySelectorAll(".fragment").length>0;if(s){var c=Ct.querySelectorAll(".fragment.visible");t=c.length}}return{h:n,v:r,f:t}}function tt(){if(Ct&&Ut.fragments){var e=x(Ct.querySelectorAll(".fragment:not(.visible)"));if(e.length){var t=e[0].getAttribute("data-fragment-index");return e=Ct.querySelectorAll('.fragment[data-fragment-index="'+t+'"]'),f(e).forEach(function(e){e.classList.add("visible")}),w("fragmentshown",{fragment:e[0],fragments:e}),K(),!0}}return!1}function nt(){if(Ct&&Ut.fragments){var e=x(Ct.querySelectorAll(".fragment.visible"));if(e.length){var t=e[e.length-1].getAttribute("data-fragment-index");return e=Ct.querySelectorAll('.fragment[data-fragment-index="'+t+'"]'),f(e).forEach(function(e){e.classList.remove("visible")}),w("fragmenthidden",{fragment:e[0],fragments:e}),K(),!0}}return!1}function rt(){clearTimeout(Vt),!jt||z()||I()||(Vt=setTimeout(ut,jt))}function ot(){clearTimeout(Vt)}function at(){Ut.rtl?(I()||tt()===!1)&&V().left&&U(Nt+1):(I()||nt()===!1)&&V().left&&U(Nt-1)}function it(){Ut.rtl?(I()||nt()===!1)&&V().right&&U(Nt-1):(I()||tt()===!1)&&V().right&&U(Nt+1)}function st(){(I()||nt()===!1)&&V().up&&U(Nt,Pt-1)}function ct(){(I()||tt()===!1)&&V().down&&U(Nt,Pt+1)}function lt(){if(nt()===!1)if(V().up)st();else{var e=document.querySelector(Xt+".past:nth-child("+Nt+")");if(e){var t=e.querySelectorAll("section").length-1||void 0,n=Nt-1;U(n,t)}}}function ut(){tt()===!1&&(V().down?ct():it()),rt()}function dt(e){document.activeElement;var t=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&"inherit"===document.activeElement.contentEditable);if(!(t||e.shiftKey&&32!==e.keyCode||e.altKey||e.ctrlKey||e.metaKey)){if(z()&&-1===[66,190,191].indexOf(e.keyCode))return!1;var n=!1;if("object"==typeof Ut.keyboard)for(var r in Ut.keyboard)if(parseInt(r,10)===e.keyCode){var o=Ut.keyboard[r];"function"==typeof o?o.apply(null,[e]):"string"==typeof o&&"function"==typeof Reveal[o]&&Reveal[o].call(),n=!0}if(n===!1)switch(n=!0,e.keyCode){case 80:case 33:lt();break;case 78:case 34:ut();break;case 72:case 37:at();break;case 76:case 39:it();break;case 75:case 38:st();break;case 74:case 40:ct();break;case 36:U(0);break;case 35:U(Number.MAX_VALUE);break;case 32:I()?D():e.shiftKey?lt():ut();break;case 13:I()?D():n=!1;break;case 66:case 190:case 191:O();break;case 70:H();break;default:n=!1}n?e.preventDefault():27!==e.keyCode&&79!==e.keyCode||!It||(C(),e.preventDefault()),rt()}}function ft(e){Jt.startX=e.touches[0].clientX,Jt.startY=e.touches[0].clientY,Jt.startCount=e.touches.length,2===e.touches.length&&Ut.overview&&(Jt.startSpan=v({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:Jt.startX,y:Jt.startY}))}function vt(e){if(Jt.captured)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===Jt.startCount&&Ut.overview){var r=v({x:e.touches[1].clientX,y:e.touches[1].clientY},{x:Jt.startX,y:Jt.startY});Math.abs(Jt.startSpan-r)>Jt.threshold&&(Jt.captured=!0,Jt.startSpan>r?P():D()),e.preventDefault()}else if(1===e.touches.length&&2!==Jt.startCount){var o=t-Jt.startX,a=n-Jt.startY;o>Jt.threshold&&Math.abs(o)>Math.abs(a)?(Jt.captured=!0,at()):-Jt.threshold>o&&Math.abs(o)>Math.abs(a)?(Jt.captured=!0,it()):a>Jt.threshold?(Jt.captured=!0,st()):-Jt.threshold>a&&(Jt.captured=!0,ct()),Ut.embedded?(Jt.captured||R(Ct))&&e.preventDefault():e.preventDefault()}}}function pt(){Jt.captured=!1}function gt(e){e.pointerType===e.MSPOINTER_TYPE_TOUCH&&(e.touches=[{clientX:e.clientX,clientY:e.clientY}],ft(e))}function mt(e){e.pointerType===e.MSPOINTER_TYPE_TOUCH&&(e.touches=[{clientX:e.clientX,clientY:e.clientY}],vt(e))}function ht(e){e.pointerType===e.MSPOINTER_TYPE_TOUCH&&(e.touches=[{clientX:e.clientX,clientY:e.clientY}],pt(e))}function yt(e){if(Date.now()-$t>600){$t=Date.now();var t=e.detail||-e.wheelDelta;t>0?ut():lt()}}function bt(e){e.preventDefault();var t=f(document.querySelectorAll(Xt)).length,n=Math.floor(e.clientX/Kt.wrapper.offsetWidth*t);U(n)}function wt(e){e.preventDefault(),at()}function Lt(e){e.preventDefault(),it()}function Et(e){e.preventDefault(),st()}function kt(e){e.preventDefault(),ct()}function St(e){e.preventDefault(),lt()}function At(e){e.preventDefault(),ut()}function qt(){G()}function xt(){T()}function Tt(e){if(Gt&&I()){e.preventDefault();for(var t=e.target;t&&!t.nodeName.match(/section/gi);)t=t.parentNode;if(t&&!t.classList.contains("disabled")&&(D(),t.nodeName.match(/section/gi))){var n=parseInt(t.getAttribute("data-index-h"),10),r=parseInt(t.getAttribute("data-index-v"),10);U(n,r)}}}function Mt(e){var t=e.target.getAttribute("href");t&&(A(t),e.preventDefault())}var Nt,Pt,Dt,Ct,It,Rt,Ht,Yt=".reveal .slides section",Xt=".reveal .slides>section",Ot=".reveal .slides>section.present>section",zt=".reveal .slides>section:first-child",Ut={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,fragments:!0,embedded:!1,autoSlide:0,mouseWheel:!1,rollingLinks:!1,previewLinks:!1,theme:null,transition:"default",transitionSpeed:"default",backgroundTransition:"default",viewDistance:3,dependencies:[]},Wt=!1,jt=0,Ft=[],_t=1,Kt={},$t=0,Vt=0,Bt=0,Zt=0,Qt=0,Gt=!1,Jt={startX:0,startY:0,startSpan:0,startCount:0,captured:!1,threshold:40};return{initialize:e,configure:c,sync:W,slide:U,left:at,right:it,up:st,down:ct,prev:lt,next:ut,prevFragment:nt,nextFragment:tt,navigateTo:U,navigateLeft:at,navigateRight:it,navigateUp:st,navigateDown:ct,navigatePrev:lt,navigateNext:ut,layout:T,availableRoutes:V,availableFragments:B,toggleOverview:C,togglePause:O,isOverview:I,isPaused:z,addEventListeners:l,removeEventListeners:u,getIndices:et,getSlide:function(e,t){var n=document.querySelectorAll(Xt)[e],r=n&&n.querySelectorAll("section");return t!==void 0?r?r[t]:void 0:n},getPreviousSlide:function(){return Dt},getCurrentSlide:function(){return Ct},getScale:function(){return _t},getConfig:function(){return Ut},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(Yt+".past")?!0:!1},isLastSlide:function(){return Ct&&Ct.classList.contains(".stack")?null==Ct.querySelector(Yt+".future")?!0:!1:null==document.querySelector(Yt+".future")?!0:!1},isReady:function(){return Wt},addEventListener:function(e,t,n){"addEventListener"in window&&(Kt.wrapper||document.querySelector(".reveal")).addEventListener(e,t,n)},removeEventListener:function(e,t,n){"addEventListener"in window&&(Kt.wrapper||document.querySelector(".reveal")).removeEventListener(e,t,n)}}}(); \ No newline at end of file