aboutsummaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
Diffstat (limited to 'js')
-rw-r--r--js/reveal.js90
-rw-r--r--js/reveal.min.js4
2 files changed, 84 insertions, 10 deletions
diff --git a/js/reveal.js b/js/reveal.js
index fd8a9f0..ccb009f 100644
--- a/js/reveal.js
+++ b/js/reveal.js
@@ -3,7 +3,7 @@
* http://lab.hakim.se/reveal-js
* MIT licensed
*
- * Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se
+ * Copyright (C) 2011-2013 Hakim El Hattab, http://hakim.se
*/
var Reveal = (function(){
@@ -16,6 +16,19 @@ var Reveal = (function(){
// Configurations defaults, can be overridden at initialization time
config = {
+
+ // The "normal" size of the presentation, aspect ratio will be preserved
+ // when the presentation is scaled to fit different resolutions
+ width: 960,
+ height: 700,
+
+ // Factor of the display size that should remain empty around the content
+ margin: 0.1,
+
+ // Bounds for smallest/largest possible scale to apply to content
+ minScale: 0.2,
+ maxScale: 1.0,
+
// Display controls in the bottom right corner
controls: true,
@@ -81,6 +94,9 @@ var Reveal = (function(){
// all current slides.
state = [],
+ // The current scale of the presentation (see width/height config)
+ scale = 1,
+
// Cached references to DOM elements
dom = {},
@@ -128,7 +144,7 @@ var Reveal = (function(){
*/
function initialize( options ) {
- if( ( !supports2DTransforms && !supports3DTransforms ) ) {
+ if( !supports2DTransforms && !supports3DTransforms ) {
document.body.setAttribute( 'class', 'no-transforms' );
// If the browser doesn't support core features we won't be
@@ -219,10 +235,6 @@ var Reveal = (function(){
function hideAddressBar() {
if( navigator.userAgent.match( /(iphone|ipod)/i ) ) {
- // Give the page some scrollable overflow
- document.documentElement.style.overflow = 'scroll';
- document.body.style.height = '120%';
-
// Events that should trigger the address bar to hide
window.addEventListener( 'load', removeAddressBar, false );
window.addEventListener( 'orientationchange', removeAddressBar, false );
@@ -497,9 +509,18 @@ var Reveal = (function(){
*/
function removeAddressBar() {
+ if( window.orientation === 0 ) {
+ document.documentElement.style.overflow = 'scroll';
+ document.body.style.height = '120%';
+ }
+ else {
+ document.documentElement.style.overflow = '';
+ document.body.style.height = '100%';
+ }
+
setTimeout( function() {
window.scrollTo( 0, 1 );
- }, 0 );
+ }, 10 );
}
@@ -547,13 +568,61 @@ var Reveal = (function(){
*/
function layout() {
+ // Available space to scale within
+ var availableWidth = dom.wrapper.offsetWidth,
+ availableHeight = dom.wrapper.offsetHeight;
+
+ // Reduce availabe space by margin
+ availableWidth -= ( availableHeight * config.margin );
+ availableHeight -= ( availableHeight * config.margin );
+
+ // Dimensions of the content
+ var slideWidth = config.width,
+ slideHeight = config.height;
+
+ // Slide width may be a percentage of available width
+ if( typeof slideWidth === 'string' && /%$/.test( slideWidth ) ) {
+ slideWidth = parseInt( slideWidth, 10 ) / 100 * availableWidth;
+ }
+
+ // Slide height may be a percentage of available height
+ if( typeof slideHeight === 'string' && /%$/.test( slideHeight ) ) {
+ slideHeight = parseInt( slideHeight, 10 ) / 100 * availableHeight;
+ }
+
+ dom.slides.style.width = slideWidth + 'px';
+ dom.slides.style.height = slideHeight + 'px';
+
+ // Determine scale of content to fit within available space
+ scale = Math.min( availableWidth / slideWidth, availableHeight / slideHeight );
+
+ // Respect max/min scale settings
+ scale = Math.max( scale, config.minScale );
+ scale = Math.min( scale, config.maxScale );
+
+ // Prefer applying scale via zoom since Chrome blurs scaled content
+ // with nested transforms
+ if( typeof dom.slides.style.zoom !== 'undefined' && !navigator.userAgent.match( /(iphone|ipod|android)/gi ) ) {
+ dom.slides.style.zoom = scale;
+ }
+ // Apply scale transform as a fallback
+ else {
+ var transform = 'translate(-50%, -50%) scale('+ scale +') translate(50%, 50%)';
+
+ dom.slides.style.WebkitTransform = transform;
+ dom.slides.style.MozTransform = transform;
+ dom.slides.style.msTransform = transform;
+ dom.slides.style.OTransform = transform;
+ dom.slides.style.transform = transform;
+ }
+
if( config.center ) {
// Select all slides, vertical and horizontal
var slides = toArray( document.querySelectorAll( SLIDES_SELECTOR ) );
// Determine the minimum top offset for slides
- var minTop = -dom.wrapper.offsetHeight / 2;
+ var minTop = -slideHeight / 2;
for( var i = 0, len = slides.length; i < len; i++ ) {
var slide = slides[ i ];
@@ -1774,6 +1843,11 @@ var Reveal = (function(){
return currentSlide;
},
+ // Returns the current scale of the presentation content
+ getScale: function() {
+ return scale;
+ },
+
// Helper method, retrieves query string as a key/value hash
getQueryHash: function() {
var query = {};
diff --git a/js/reveal.min.js b/js/reveal.min.js
index 46a765e..1cec6ce 100644
--- a/js/reveal.min.js
+++ b/js/reveal.min.js
@@ -1,8 +1,8 @@
/*!
- * reveal.js 2.2 (2013-01-21, 14:54)
+ * reveal.js 2.3 (2013-02-02, 19:46)
* http://lab.hakim.se/reveal-js
* MIT licensed
*
* Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se
*/
-var Reveal=function(){"use strict";function u(a){return n||m?(window.addEventListener("load",J,!1),C(e,a),w(),x(),void 0):(document.body.setAttribute("class","no-transforms"),void 0)}function v(){if(l.theme=document.querySelector("#theme"),l.wrapper=document.querySelector(".reveal"),l.slides=document.querySelector(".reveal .slides"),!l.wrapper.querySelector(".progress")&&e.progress){var a=document.createElement("div");a.classList.add("progress"),a.innerHTML="<span></span>",l.wrapper.appendChild(a)}if(!l.wrapper.querySelector(".controls")&&e.controls){var b=document.createElement("aside");b.classList.add("controls"),b.innerHTML='<div class="navigate-left"></div><div class="navigate-right"></div><div class="navigate-up"></div><div class="navigate-down"></div>',l.wrapper.appendChild(b)}if(!l.wrapper.querySelector(".state-background")){var c=document.createElement("div");c.classList.add("state-background"),l.wrapper.appendChild(c)}if(!l.wrapper.querySelector(".pause-overlay")){var d=document.createElement("div");d.classList.add("pause-overlay"),l.wrapper.appendChild(d)}l.progress=document.querySelector(".reveal .progress"),l.progressbar=document.querySelector(".reveal .progress span"),e.controls&&(l.controls=document.querySelector(".reveal .controls"),l.controlsLeft=D(document.querySelectorAll(".navigate-left")),l.controlsRight=D(document.querySelectorAll(".navigate-right")),l.controlsUp=D(document.querySelectorAll(".navigate-up")),l.controlsDown=D(document.querySelectorAll(".navigate-down")),l.controlsPrev=D(document.querySelectorAll(".navigate-prev")),l.controlsNext=D(document.querySelectorAll(".navigate-next")))}function w(){navigator.userAgent.match(/(iphone|ipod)/i)&&(document.documentElement.style.overflow="scroll",document.body.style.height="120%",window.addEventListener("load",G,!1),window.addEventListener("orientationchange",G,!1))}function x(){function g(){b.length&&head.js.apply(null,b),y()}for(var a=[],b=[],c=0,d=e.dependencies.length;d>c;c++){var f=e.dependencies[c];(!f.condition||f.condition())&&(f.async?b.push(f.src):a.push(f.src),"function"==typeof f.callback&&head.ready(f.src.match(/([\w\d_\-]*)\.?js$|[^\\\/]*$/i)[0],f.callback))}a.length?(head.ready(g),head.js.apply(null,a)):g()}function y(){v(),A(),z(),J(),$(),db(),setTimeout(function(){H("ready",{indexh:g,indexv:h,currentSlide:j})},1)}function z(){if(m===!1&&(e.transition="linear"),e.controls&&l.controls&&(l.controls.style.display="block"),e.progress&&l.progress&&(l.progress.style.display="block"),"default"!==e.transition&&l.wrapper.classList.add(e.transition),e.rtl&&l.wrapper.classList.add("rtl"),e.center&&l.wrapper.classList.add("center"),e.mouseWheel&&(document.addEventListener("DOMMouseScroll",ob,!1),document.addEventListener("mousewheel",ob,!1)),e.rollingLinks&&I(),e.theme&&l.theme){var a=l.theme.getAttribute("href"),b=/[^\/]*?(?=\.css)/,c=a.match(b)[0];e.theme!==c&&(a=a.replace(b,e.theme),l.theme.setAttribute("href",a))}}function A(){if(window.addEventListener("hashchange",qb,!1),window.addEventListener("resize",rb,!1),e.touch&&(document.addEventListener("touchstart",lb,!1),document.addEventListener("touchmove",mb,!1),document.addEventListener("touchend",nb,!1)),e.keyboard&&document.addEventListener("keydown",kb,!1),e.progress&&l.progress&&l.progress.addEventListener("click",F(pb),!1),e.controls&&l.controls){var a="ontouchstart"in window?"touchstart":"click";l.controlsLeft.forEach(function(b){b.addEventListener(a,F(eb),!1)}),l.controlsRight.forEach(function(b){b.addEventListener(a,F(fb),!1)}),l.controlsUp.forEach(function(b){b.addEventListener(a,F(gb),!1)}),l.controlsDown.forEach(function(b){b.addEventListener(a,F(hb),!1)}),l.controlsPrev.forEach(function(b){b.addEventListener(a,F(ib),!1)}),l.controlsNext.forEach(function(b){b.addEventListener(a,F(jb),!1)})}}function B(){if(document.removeEventListener("keydown",kb,!1),window.removeEventListener("hashchange",qb,!1),window.removeEventListener("resize",rb,!1),e.touch&&(document.removeEventListener("touchstart",lb,!1),document.removeEventListener("touchmove",mb,!1),document.removeEventListener("touchend",nb,!1)),e.progress&&l.progress&&l.progress.removeEventListener("click",F(pb),!1),e.controls&&l.controls){var a="ontouchstart"in window?"touchstart":"click";l.controlsLeft.forEach(function(b){b.removeEventListener(a,F(eb),!1)}),l.controlsRight.forEach(function(b){b.removeEventListener(a,F(fb),!1)}),l.controlsUp.forEach(function(b){b.removeEventListener(a,F(gb),!1)}),l.controlsDown.forEach(function(b){b.removeEventListener(a,F(hb),!1)}),l.controlsPrev.forEach(function(b){b.removeEventListener(a,F(ib),!1)}),l.controlsNext.forEach(function(b){b.removeEventListener(a,F(jb),!1)})}}function C(a,b){for(var c in b)a[c]=b[c]}function D(a){return Array.prototype.slice.call(a)}function E(a,b){var c=a.x-b.x,d=a.y-b.y;return Math.sqrt(c*c+d*d)}function F(a){return function(b){b.preventDefault(),a.call(null,b)}}function G(){setTimeout(function(){window.scrollTo(0,1)},0)}function H(a,b){var c=document.createEvent("HTMLEvents",1,2);c.initEvent(a,!0,!0),C(c,b),l.wrapper.dispatchEvent(c)}function I(){if(m&&!("msPerspective"in document.body.style))for(var b=document.querySelectorAll(a+" a:not(.image)"),c=0,d=b.length;d>c;c++){var e=b[c];if(!(!e.textContent||e.querySelector("*")||e.className&&e.classList.contains(e,"roll"))){var f=document.createElement("span");f.setAttribute("data-title",e.text),f.innerHTML=e.innerHTML,e.classList.add("roll"),e.innerHTML="",e.appendChild(f)}}}function J(){if(e.center)for(var b=D(document.querySelectorAll(a)),c=-l.wrapper.offsetHeight/2,d=0,f=b.length;f>d;d++){var g=b[d];"none"!==g.style.display&&(g.style.top=g.classList.contains("stack")?0:Math.max(-(g.offsetHeight/2)-20,c)+"px")}}function K(a,b){a&&a.setAttribute("data-previous-indexv",b||0)}function L(a){return a&&a.classList.contains("stack")?parseInt(a.getAttribute("data-previous-indexv")||0,10):0}function M(){if(e.overview){var a=l.wrapper.classList.contains("overview");l.wrapper.classList.add("overview"),l.wrapper.classList.remove("exit-overview"),clearTimeout(r),clearTimeout(s),r=setTimeout(function(){for(var c=document.querySelectorAll(b),d=0,e=c.length;e>d;d++){var f=c[d],i="translateZ(-2500px) translate("+105*(d-g)+"%, 0%)";if(f.setAttribute("data-index-h",d),f.style.display="block",f.style.WebkitTransform=i,f.style.MozTransform=i,f.style.msTransform=i,f.style.OTransform=i,f.style.transform=i,f.classList.contains("stack"))for(var k=f.querySelectorAll("section"),l=0,m=k.length;m>l;l++){var n=d===g?h:L(f),o=k[l],p="translate(0%, "+105*(l-n)+"%)";o.setAttribute("data-index-h",d),o.setAttribute("data-index-v",l),o.style.display="block",o.style.WebkitTransform=p,o.style.MozTransform=p,o.style.msTransform=p,o.style.OTransform=p,o.style.transform=p,o.addEventListener("click",sb,!0)}else f.addEventListener("click",sb,!0)}J(),a||H("overviewshown",{indexh:g,indexv:h,currentSlide:j})},10)}}function N(){if(e.overview){clearTimeout(r),clearTimeout(s),l.wrapper.classList.remove("overview"),l.wrapper.classList.add("exit-overview"),s=setTimeout(function(){l.wrapper.classList.remove("exit-overview")},10);for(var b=D(document.querySelectorAll(a)),c=0,d=b.length;d>c;c++){var f=b[c];f.style.display="",f.style.WebkitTransform="",f.style.MozTransform="",f.style.msTransform="",f.style.OTransform="",f.style.transform="",f.removeEventListener("click",sb,!0)}V(g,h),H("overviewhidden",{indexh:g,indexv:h,currentSlide:j})}}function O(a){"boolean"==typeof a?a?M():N():P()?N():M()}function P(){return l.wrapper.classList.contains("overview")}function Q(){var a=document.body,b=a.requestFullScreen||a.webkitRequestFullScreen||a.mozRequestFullScreen||a.msRequestFullScreen;b&&b.apply(a)}function R(){l.wrapper.classList.add("paused")}function S(){l.wrapper.classList.remove("paused")}function T(){U()?S():R()}function U(){return l.wrapper.classList.contains("paused")}function V(a,e,f){i=j;var l=document.querySelectorAll(b);void 0===e&&(e=L(l[a])),i&&i.parentNode&&i.parentNode.classList.contains("stack")&&K(i.parentNode,h);var m=k.concat();k.length=0;var n=g,o=h;g=W(b,void 0===a?g:a),h=W(c,void 0===e?h:e),J();a:for(var p=0,q=k.length;q>p;p++){for(var r=0;m.length>r;r++)if(m[r]===k[p]){m.splice(r,1);continue a}document.documentElement.classList.add(k[p]),H(k[p])}for(;m.length;)document.documentElement.classList.remove(m.pop());P()&&M(),_(1500);var s=l[g],t=s.querySelectorAll("section");if(j=t[h]||s,f!==void 0){var u=j.querySelectorAll(".fragment");D(u).forEach(function(a,b){f>b?a.classList.add("visible"):a.classList.remove("visible")})}g!==n||h!==o?H("slidechanged",{indexh:g,indexv:h,previousSlide:i,currentSlide:j}):i=null,i&&(i.classList.remove("present"),document.querySelector(d).classList.contains("present")&&setTimeout(function(){var c,a=D(document.querySelectorAll(b+".stack"));for(c in a)a[c]&&K(a[c],0)},0)),Y(),X()}function W(a,b){var c=D(document.querySelectorAll(a)),d=c.length;if(d){e.loop&&(b%=d,0>b&&(b=d+b)),b=Math.max(Math.min(b,d-1),0);for(var g=0;d>g;g++){var h=c[g];if(P()===!1){var i=Math.abs((b-g)%(d-3))||0;h.style.display=i>3?"none":"block"}c[g].classList.remove("past"),c[g].classList.remove("present"),c[g].classList.remove("future"),b>g?c[g].classList.add("past"):g>b&&c[g].classList.add("future"),h.querySelector("section")&&c[g].classList.add("stack")}c[b].classList.add("present");var j=c[b].getAttribute("data-state");j&&(k=k.concat(j.split(" ")));var l=c[b].getAttribute("data-autoslide");f=l?parseInt(l,10):e.autoSlide}else b=0;return b}function X(){if(e.progress&&l.progress){var c=D(document.querySelectorAll(b)),d=document.querySelectorAll(a+":not(.stack)").length,f=0;a:for(var g=0;c.length>g;g++){for(var h=c[g],i=D(h.querySelectorAll("section")),j=0;i.length>j;j++){if(i[j].classList.contains("present"))break a;f++}if(h.classList.contains("present"))break;h.classList.contains("stack")===!1&&f++}l.progressbar.style.width=f/(d-1)*window.innerWidth+"px"}}function Y(){if(e.controls&&l.controls){var a=Z();l.controlsLeft.concat(l.controlsRight).concat(l.controlsUp).concat(l.controlsDown).concat(l.controlsPrev).concat(l.controlsNext).forEach(function(a){a.classList.remove("enabled")}),a.left&&l.controlsLeft.forEach(function(a){a.classList.add("enabled")}),a.right&&l.controlsRight.forEach(function(a){a.classList.add("enabled")}),a.up&&l.controlsUp.forEach(function(a){a.classList.add("enabled")}),a.down&&l.controlsDown.forEach(function(a){a.classList.add("enabled")}),(a.left||a.up)&&l.controlsPrev.forEach(function(a){a.classList.add("enabled")}),(a.right||a.down)&&l.controlsNext.forEach(function(a){a.classList.add("enabled")})}}function Z(){var a=document.querySelectorAll(b),d=document.querySelectorAll(c);return{left:g>0,right:a.length-1>g,up:h>0,down:d.length-1>h}}function $(){var a=window.location.hash,b=a.slice(2).split("/"),c=a.replace(/#|\//gi,"");if(isNaN(parseInt(b[0],10))&&c.length){var d=document.querySelector("#"+c);if(d){var e=Reveal.getIndices(d);V(e.h,e.v)}else V(g,h)}else{var f=parseInt(b[0],10)||0,i=parseInt(b[1],10)||0;V(f,i)}}function _(a){if(e.history)if(clearTimeout(q),"number"==typeof a)q=setTimeout(_,a);else{var b="/";j&&"string"==typeof j.getAttribute("id")?b="/"+j.getAttribute("id"):((g>0||h>0)&&(b+=g),h>0&&(b+="/"+h)),window.location.hash=b}}function ab(a){var c=g,d=h;if(a){var e=!!a.parentNode.nodeName.match(/section/gi),f=e?a.parentNode:a,i=D(document.querySelectorAll(b));c=Math.max(i.indexOf(f),0),e&&(d=Math.max(D(a.parentNode.querySelectorAll("section")).indexOf(a),0))}return{h:c,v:d}}function bb(){if(document.querySelector(c+".present")){var a=document.querySelectorAll(c+".present .fragment:not(.visible)");if(a.length)return a[0].classList.add("visible"),H("fragmentshown",{fragment:a[0]}),!0}else{var d=document.querySelectorAll(b+".present .fragment:not(.visible)");if(d.length)return d[0].classList.add("visible"),H("fragmentshown",{fragment:d[0]}),!0}return!1}function cb(){if(document.querySelector(c+".present")){var a=document.querySelectorAll(c+".present .fragment.visible");if(a.length)return a[a.length-1].classList.remove("visible"),H("fragmenthidden",{fragment:a[a.length-1]}),!0}else{var d=document.querySelectorAll(b+".present .fragment.visible");if(d.length)return d[d.length-1].classList.remove("visible"),H("fragmenthidden",{fragment:d[d.length-1]}),!0}return!1}function db(){clearTimeout(p),f&&(p=setTimeout(jb,f))}function eb(){(Z().left&&P()||cb()===!1)&&V(g-1)}function fb(){(Z().right&&P()||bb()===!1)&&V(g+1)}function gb(){(Z().up&&P()||cb()===!1)&&V(g,h-1)}function hb(){(Z().down&&P()||bb()===!1)&&V(g,h+1)}function ib(){if(cb()===!1)if(Z().up)gb();else{var a=document.querySelector(b+".past:nth-child("+g+")");a&&(h=a.querySelectorAll("section").length+1||void 0,g--,V())}}function jb(){bb()===!1&&(Z().down?hb():fb()),db()}function kb(a){document.activeElement;var c=!(!document.activeElement||!document.activeElement.type&&!document.activeElement.href&&"inherit"===document.activeElement.contentEditable);if(!(c||a.shiftKey||a.altKey||a.ctrlKey||a.metaKey)){var d=!0;switch(a.keyCode){case 80:case 33:ib();break;case 78:case 34:jb();break;case 72:case 37:eb();break;case 76:case 39:fb();break;case 75:case 38:gb();break;case 74:case 40:hb();break;case 36:V(0);break;case 35:V(Number.MAX_VALUE);break;case 32:P()?N():jb();break;case 13:P()?N():d=!1;break;case 66:case 190:case 191:T();break;case 70:Q();break;default:d=!1}d?a.preventDefault():27===a.keyCode&&m&&(O(),a.preventDefault()),db()}}function lb(a){t.startX=a.touches[0].clientX,t.startY=a.touches[0].clientY,t.startCount=a.touches.length,2===a.touches.length&&e.overview&&(t.startSpan=E({x:a.touches[1].clientX,y:a.touches[1].clientY},{x:t.startX,y:t.startY}))}function mb(a){if(t.handled)navigator.userAgent.match(/android/gi)&&a.preventDefault();else{var b=a.touches[0].clientX,c=a.touches[0].clientY;if(2===a.touches.length&&2===t.startCount&&e.overview){var d=E({x:a.touches[1].clientX,y:a.touches[1].clientY},{x:t.startX,y:t.startY});Math.abs(t.startSpan-d)>t.threshold&&(t.handled=!0,t.startSpan>d?M():N()),a.preventDefault()}else if(1===a.touches.length&&2!==t.startCount){var f=b-t.startX,g=c-t.startY;f>t.threshold&&Math.abs(f)>Math.abs(g)?(t.handled=!0,eb()):-t.threshold>f&&Math.abs(f)>Math.abs(g)?(t.handled=!0,fb()):g>t.threshold?(t.handled=!0,gb()):-t.threshold>g&&(t.handled=!0,hb()),a.preventDefault()}}}function nb(){t.handled=!1}function ob(a){clearTimeout(o),o=setTimeout(function(){var b=a.detail||-a.wheelDelta;b>0?jb():ib()},100)}function pb(a){var c=D(document.querySelectorAll(b)).length,d=Math.floor(a.clientX/l.wrapper.offsetWidth*c);V(d)}function qb(){$()}function rb(){J()}function sb(a){if(P()){a.preventDefault(),N();for(var b=a.target;b&&!b.nodeName.match(/section/gi);)b=b.parentNode;if(b.nodeName.match(/section/gi)){var c=parseInt(b.getAttribute("data-index-h"),10),d=parseInt(b.getAttribute("data-index-v"),10);V(c,d)}}}var i,j,a=".reveal .slides section",b=".reveal .slides>section",c=".reveal .slides>section.present>section",d=".reveal .slides>section:first-child",e={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:[]},f=e.autoSlide,g=0,h=0,k=[],l={},m="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,n="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,o=0,p=0,q=0,r=0,s=0,t={startX:0,startY:0,startSpan:0,startCount:0,handled:!1,threshold:80};return{initialize:u,slide:V,left:eb,right:fb,up:gb,down:hb,prev:ib,next:jb,prevFragment:cb,nextFragment:bb,navigateTo:V,navigateLeft:eb,navigateRight:fb,navigateUp:gb,navigateDown:hb,navigatePrev:ib,navigateNext:jb,layout:J,toggleOverview:O,togglePause:T,addEventListeners:A,removeEventListeners:B,getIndices:ab,getPreviousSlide:function(){return i},getCurrentSlide:function(){return j},getQueryHash:function(){var a={};return location.search.replace(/[A-Z0-9]+?=(\w*)/gi,function(b){a[b.split("=").shift()]=b.split("=").pop()}),a},addEventListener:function(a,b,c){"addEventListener"in window&&(l.wrapper||document.querySelector(".reveal")).addEventListener(a,b,c)},removeEventListener:function(a,b,c){"addEventListener"in window&&(l.wrapper||document.querySelector(".reveal")).removeEventListener(a,b,c)}}}(); \ 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="<span></span>",h.wrapper.appendChild(e)}if(!h.wrapper.querySelector(".controls")&&i.controls){var t=document.createElement("aside");t.classList.add("controls"),t.innerHTML='<div class="navigate-left"></div><div class="navigate-right"></div><div class="navigate-up"></div><div class="navigate-down"></div>',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(){navigator.userAgent.match(/(iphone|ipod)/i)&&(window.addEventListener("load",D,!1),window.addEventListener("orientationchange",D,!1))}function T(){function o(){t.length&&head.js.apply(null,t),N()}var e=[],t=[];for(var n=0,r=i.dependencies.length;n<r;n++){var s=i.dependencies[n];if(!s.condition||s.condition())s.async?t.push(s.src):e.push(s.src),typeof s.callback=="function"&&head.ready(s.src.match(/([\w\d_\-]*)\.?js$|[^\\\/]*$/i)[0],s.callback)}e.length?(head.ready(o),head.js.apply(null,e)):o()}function N(){S(),k(),C(),B(),Z(),it(),setTimeout(function(){P("ready",{indexh:o,indexv:u,currentSlide:f})},1)}function C(){p===!1&&(i.transition="linear"),i.controls&&h.controls&&(h.controls.style.display="block"),i.progress&&h.progress&&(h.progress.style.display="block"),i.transition!=="default"&&h.wrapper.classList.add(i.transition),i.rtl&&h.wrapper.classList.add("rtl"),i.center&&h.wrapper.classList.add("center"),i.mouseWheel&&(document.addEventListener("DOMMouseScroll",vt,!1),document.addEventListener("mousewheel",vt,!1)),i.rollingLinks&&H();if(i.theme&&h.theme){var e=h.theme.getAttribute("href"),t=/[^\/]*?(?=\.css)/,n=e.match(t)[0];i.theme!==n&&(e=e.replace(t,i.theme),h.theme.setAttribute("href",e))}}function k(){window.addEventListener("hashchange",gt,!1),window.addEventListener("resize",yt,!1),i.touch&&(document.addEventListener("touchstart",ht,!1),document.addEventListener("touchmove",pt,!1),document.addEventListener("touchend",dt,!1)),i.keyboard&&document.addEventListener("keydown",ct,!1),i.progress&&h.progress&&h.progress.addEventListener("click",_(mt),!1);if(i.controls&&h.controls){var e="ontouchstart"in window?"touchstart":"click";h.controlsLeft.forEach(function(t){t.addEventListener(e,_(st),!1)}),h.controlsRight.forEach(function(t){t.addEventListener(e,_(ot),!1)}),h.controlsUp.forEach(function(t){t.addEventListener(e,_(ut),!1)}),h.controlsDown.forEach(function(t){t.addEventListener(e,_(at),!1)}),h.controlsPrev.forEach(function(t){t.addEventListener(e,_(ft),!1)}),h.controlsNext.forEach(function(t){t.addEventListener(e,_(lt),!1)})}}function L(){document.removeEventListener("keydown",ct,!1),window.removeEventListener("hashchange",gt,!1),window.removeEventListener("resize",yt,!1),i.touch&&(document.removeEventListener("touchstart",ht,!1),document.removeEventListener("touchmove",pt,!1),document.removeEventListener("touchend",dt,!1)),i.progress&&h.progress&&h.progress.removeEventListener("click",_(mt),!1);if(i.controls&&h.controls){var e="ontouchstart"in window?"touchstart":"click";h.controlsLeft.forEach(function(t){t.removeEventListener(e,_(st),!1)}),h.controlsRight.forEach(function(t){t.removeEventListener(e,_(ot),!1)}),h.controlsUp.forEach(function(t){t.removeEventListener(e,_(ut),!1)}),h.controlsDown.forEach(function(t){t.removeEventListener(e,_(at),!1)}),h.controlsPrev.forEach(function(t){t.removeEventListener(e,_(ft),!1)}),h.controlsNext.forEach(function(t){t.removeEventListener(e,_(lt),!1)})}}function A(e,t){for(var n in t)e[n]=t[n]}function O(e){return Array.prototype.slice.call(e)}function M(e,t){var n=e.x-t.x,r=e.y-t.y;return Math.sqrt(n*n+r*r)}function _(e){return function(t){t.preventDefault(),e.call(null,t)}}function D(){window.orientation===0?(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 P(e,t){var n=document.createEvent("HTMLEvents",1,2);n.initEvent(e,!0,!0),A(n,t),h.wrapper.dispatchEvent(n)}function H(){if(p&&!("msPerspective"in document.body.style)){var t=document.querySelectorAll(e+" a:not(.image)");for(var n=0,r=t.length;n<r;n++){var i=t[n];if(i.textContent&&!i.querySelector("*")&&(!i.className||!i.classList.contains(i,"roll"))){var s=document.createElement("span");s.setAttribute("data-title",i.text),s.innerHTML=i.innerHTML,i.classList.add("roll"),i.innerHTML="",i.appendChild(s)}}}}function B(){var t=h.wrapper.offsetWidth,n=h.wrapper.offsetHeight;t-=n*i.margin,n-=n*i.margin;var r=i.width,s=i.height;typeof r=="string"&&/%$/.test(r)&&(r=parseInt(r,10)/100*t),typeof s=="string"&&/%$/.test(s)&&(s=parseInt(s,10)/100*n),h.slides.style.width=r+"px",h.slides.style.height=s+"px",c=Math.min(t/r,n/s),c=Math.max(c,i.minScale),c=Math.min(c,i.maxScale);if(typeof h.slides.style.zoom!="undefined"&&!navigator.userAgent.match(/(iphone|ipod|android)/gi))h.slides.style.zoom=c;else{var o="translate(-50%, -50%) scale("+c+") translate(50%, 50%)";h.slides.style.WebkitTransform=o,h.slides.style.MozTransform=o,h.slides.style.msTransform=o,h.slides.style.OTransform=o,h.slides.style.transform=o}if(i.center){var u=O(document.querySelectorAll(e)),a=-s/2;for(var f=0,l=u.length;f<l;f++){var p=u[f];if(p.style.display==="none")continue;p.classList.contains("stack")?p.style.top=0:p.style.top=Math.max(-(p.offsetHeight/2)-20,a)+"px"}}}function j(e,t){e&&e.setAttribute("data-previous-indexv",t||0)}function F(e){return e&&e.classList.contains("stack")?parseInt(e.getAttribute("data-previous-indexv")||0,10):0}function I(){if(i.overview){var e=h.wrapper.classList.contains("overview");h.wrapper.classList.add("overview"),h.wrapper.classList.remove("exit-overview"),clearTimeout(y),clearTimeout(b),y=setTimeout(function(){var n=document.querySelectorAll(t);for(var r=0,i=n.length;r<i;r++){var s=n[r],a="translateZ(-2500px) translate("+(r-o)*105+"%, 0%)";s.setAttribute("data-index-h",r),s.style.display="block",s.style.WebkitTransform=a,s.style.MozTransform=a,s.style.msTransform=a,s.style.OTransform=a,s.style.transform=a;if(s.classList.contains("stack")){var l=s.querySelectorAll("section");for(var c=0,h=l.length;c<h;c++){var p=r===o?u:F(s),d=l[c],v="translate(0%, "+(c-p)*105+"%)";d.setAttribute("data-index-h",r),d.setAttribute("data-index-v",c),d.style.display="block",d.style.WebkitTransform=v,d.style.MozTransform=v,d.style.msTransform=v,d.style.OTransform=v,d.style.transform=v,d.addEventListener("click",bt,!0)}}else s.addEventListener("click",bt,!0)}B(),e||P("overviewshown",{indexh:o,indexv:u,currentSlide:f})},10)}}function q(){if(i.overview){clearTimeout(y),clearTimeout(b),h.wrapper.classList.remove("overview"),h.wrapper.classList.add("exit-overview"),b=setTimeout(function(){h.wrapper.classList.remove("exit-overview")},10);var t=O(document.querySelectorAll(e));for(var n=0,r=t.length;n<r;n++){var s=t[n];s.style.display="",s.style.WebkitTransform="",s.style.MozTransform="",s.style.msTransform="",s.style.OTransform="",s.style.transform="",s.removeEventListener("click",bt,!0)}J(o,u),P("overviewhidden",{indexh:o,indexv:u,currentSlide:f})}}function R(e){typeof e=="boolean"?e?I():q():U()?q():I()}function U(){return h.wrapper.classList.contains("overview")}function z(){var e=document.body,t=e.requestFullScreen||e.webkitRequestFullScreen||e.mozRequestFullScreen||e.msRequestFullScreen;t&&t.apply(e)}function W(){h.wrapper.classList.add("paused")}function X(){h.wrapper.classList.remove("paused")}function V(){$()?X():W()}function $(){return h.wrapper.classList.contains("paused")}function J(e,i,s){a=f;var c=document.querySelectorAll(t);i===undefined&&(i=F(c[e])),a&&a.parentNode&&a.parentNode.classList.contains("stack")&&j(a.parentNode,u);var h=l.concat();l.length=0;var p=o,d=u;o=K(t,e===undefined?o:e),u=K(n,i===undefined?u:i),B();e:for(var v=0,m=l.length;v<m;v++){for(var g=0;g<h.length;g++)if(h[g]===l[v]){h.splice(g,1);continue e}document.documentElement.classList.add(l[v]),P(l[v])}while(h.length)document.documentElement.classList.remove(h.pop());U()&&I(),et(1500);var y=c[o],b=y.querySelectorAll("section");f=b[u]||y;if(typeof s!="undefined"){var w=f.querySelectorAll(".fragment");O(w).forEach(function(e,t){t<s?e.classList.add("visible"):e.classList.remove("visible")})}o!==p||u!==d?P("slidechanged",{indexh:o,indexv:u,previousSlide:a,currentSlide:f}):a=null,a&&(a.classList.remove("present"),document.querySelector(r).classList.contains("present")&&setTimeout(function(){var e=O(document.querySelectorAll(t+".stack")),n;for(n in e)e[n]&&j(e[n],0)},0)),G(),Q()}function K(e,t){var n=O(document.querySelectorAll(e)),r=n.length;if(r){i.loop&&(t%=r,t<0&&(t=r+t)),t=Math.max(Math.min(t,r-1),0);for(var o=0;o<r;o++){var u=n[o];if(U()===!1){var a=Math.abs((t-o)%(r-3))||0;u.style.display=a>3?"none":"block"}n[o].classList.remove("past"),n[o].classList.remove("present"),n[o].classList.remove("future"),o<t?n[o].classList.add("past"):o>t&&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;o<n.length;o++){var u=n[o],a=O(u.querySelectorAll("section"));for(var f=0;f<a.length;f++){if(a[f].classList.contains("present"))break e;s++}if(u.classList.contains("present"))break;u.classList.contains("stack")===!1&&s++}h.progressbar.style.width=s/(r-1)*window.innerWidth+"px"}}function G(){if(i.controls&&h.controls){var e=Y();h.controlsLeft.concat(h.controlsRight).concat(h.controlsUp).concat(h.controlsDown).concat(h.controlsPrev).concat(h.controlsNext).forEach(function(e){e.classList.remove("enabled")}),e.left&&h.controlsLeft.forEach(function(e){e.classList.add("enabled")}),e.right&&h.controlsRight.forEach(function(e){e.classList.add("enabled")}),e.up&&h.controlsUp.forEach(function(e){e.classList.add("enabled")}),e.down&&h.controlsDown.forEach(function(e){e.classList.add("enabled")}),(e.left||e.up)&&h.controlsPrev.forEach(function(e){e.classList.add("enabled")}),(e.right||e.down)&&h.controlsNext.forEach(function(e){e.classList.add("enabled")})}}function Y(){var e=document.querySelectorAll(t),r=document.querySelectorAll(n);return{left:o>0,right:o<e.length-1,up:u>0,down:u<r.length-1}}function Z(){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 i=Reveal.getIndices(r);J(i.h,i.v)}else J(o,u)}else{var s=parseInt(t[0],10)||0,a=parseInt(t[1],10)||0;J(s,a)}}function et(e){if(i.history){clearTimeout(g);if(typeof e=="number")g=setTimeout(et,e);else{var t="/";if(f&&typeof f.getAttribute("id")=="string")t="/"+f.getAttribute("id");else{if(o>0||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"),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 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"),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 it(){clearTimeout(m),s&&(m=setTimeout(lt,s))}function st(){(Y().left&&U()||rt()===!1)&&J(o-1)}function ot(){(Y().right&&U()||nt()===!1)&&J(o+1)}function ut(){(Y().up&&U()||rt()===!1)&&J(o,u-1)}function at(){(Y().down&&U()||nt()===!1)&&J(o,u+1)}function ft(){if(rt()===!1)if(Y().up)ut();else{var e=document.querySelector(t+".past:nth-child("+o+")");e&&(u=e.querySelectorAll("section").length+1||undefined,o--,J())}}function lt(){nt()===!1&&(Y().down?at():ot()),it()}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;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:J(0);break;case 35:J(Number.MAX_VALUE);break;case 32:U()?q():lt();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 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,r<w.startSpan?I():q()),e.preventDefault()}else if(e.touches.length===1&&w.startCount!==2){var s=t-w.startX,o=n-w.startY;s>w.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){var n=O(document.querySelectorAll(t)).length,r=Math.floor(e.clientX/h.wrapper.offsetWidth*n);J(r)}function gt(e){Z()}function yt(e){B()}function bt(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,slide:J,left:st,right:ot,up:ut,down:at,prev:ft,next:lt,prevFragment:rt,nextFragment:nt,navigateTo:J,navigateLeft:st,navigateRight:ot,navigateUp:ut,navigateDown:at,navigatePrev:ft,navigateNext:lt,layout:B,toggleOverview:R,togglePause:V,addEventListeners:k,removeEventListeners:L,getIndices:tt,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},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