Click to close
',{id:'extension__viewoptions'}).appendTo($extmgr.find('.panelHeader'));$displayOpts.append(LANG.plugins.extension.display_viewoptions);var displayOptionsHandler=function(){$extlist.toggleClass(this.name);DokuCookie.setValue('ext_'+this.name,$extlist.hasClass(this.name)?'1':'0');};jQuery(['enabled','disabled','updatable']).each(function(index,chkName){var $label=jQuery('').appendTo($displayOpts);var $input=jQuery('',{type:'checkbox',name:chkName}).change(displayOptionsHandler).appendTo($label);var previous=DokuCookie.getValue('ext_'+chkName);if(typeof previous==="undefined"||previous=='1'){$input.click();}jQuery('').append(' '+LANG.plugins.extension['display_'+chkName]).appendTo($label);});}});;(function(window,document,$,undefined){$.swipebox=function(elem,options){var ui,defaults={useCSS:true,useSVG:true,initialIndexOnArray:0,removeBarsOnMobile:true,hideCloseButtonOnMobile:false,hideBarsDelay:3000,videoMaxWidth:1140,vimeoColor:'cccccc',beforeOpen:null,afterOpen:null,afterClose:null,afterMedia:null,nextSlide:null,prevSlide:null,loopAtEnd:false,autoplayVideos:false,queryStringData:{},toggleClassOnLoad:'',titleAttribute:'title',captionAttribute:'data-caption',selector:null},plugin=this,elements=[],$elem,isMobile=navigator.userAgent.match(/(iPad)|(iPhone)|(iPod)|(Android)|(PlayBook)|(BB10)|(BlackBerry)|(Opera Mini)|(IEMobile)|(webOS)|(MeeGo)/i),isTouch=isMobile!==null||document.createTouch!==undefined||('ontouchstart'in window)||('onmsgesturechange'in window)||navigator.msMaxTouchPoints,supportSVG=!!document.createElementNS&&!!document.createElementNS('http://www.w3.org/2000/svg','svg').createSVGRect,winWidth=window.innerWidth?window.innerWidth:$(window).width(),winHeight=window.innerHeight?window.innerHeight:$(window).height(),currentX=0,html='
';plugin.settings={};$.swipebox.close=function(){ui.closeSlide();};$.swipebox.extend=function(){return ui;};plugin.init=function(){plugin.settings=$.extend({},defaults,options);if($.isArray(elem)){elements=elem;ui.target=$(window);ui.init(plugin.settings.initialIndexOnArray);}else{$(elem).on('click',plugin.settings.selector,function(event){if(event.target.parentNode.className==='slide current'){return false;}ui.destroy();if(plugin.settings.selector===null){$elem=$(elem);}else{$elem=$(elem).find(plugin.settings.selector);}elements=[];var index,relType,relVal;if(!relVal){relType='data-rel';relVal=$(this).attr(relType);}if(!relVal){relType='rel';relVal=$(this).attr(relType);}if(relVal&&relVal!==''&&relVal!=='nofollow'){$elem=$elem.filter('['+relType+'="'+relVal+'"]');}$elem.each(function(){var title=null,caption=null,href=null;if($(this).attr(plugin.settings.titleAttribute)){title=$(this).attr(plugin.settings.titleAttribute);}if($(this).attr(plugin.settings.captionAttribute)){caption=$(this).attr(plugin.settings.captionAttribute);}if($(this).attr('href')){href=$(this).attr('href');}elements.push({href:href,title:title,caption:caption});});index=$elem.index($(this));event.preventDefault();event.stopPropagation();ui.target=$(event.target);ui.init(index);});}};ui={init:function(index){if(plugin.settings.beforeOpen){plugin.settings.beforeOpen();}this.target.trigger('swipebox-start');$.swipebox.isOpen=true;this.build();this.openSlide(index);this.openMedia(index);this.preloadMedia(index+1);this.preloadMedia(index-1);if(plugin.settings.afterOpen){plugin.settings.afterOpen(index);}},build:function(){var $this=this,bg;$('body').append(html);if(supportSVG&&plugin.settings.useSVG===true){bg=$('#swipebox-close').css('background-image');bg=bg.replace('png','svg');$('#swipebox-prev, #swipebox-next, #swipebox-close').css({'background-image':bg});}if(isMobile&&plugin.settings.removeBarsOnMobile){$('#swipebox-bottom-bar, #swipebox-top-bar').remove();}$.each(elements,function(){$('#swipebox-slider').append('');});$this.setDim();$this.actions();if(isTouch){$this.gesture();}$this.keyboard();$this.animBars();$this.resize();},setDim:function(){var width,height,sliderCss={};if('onorientationchange'in window){window.addEventListener('orientationchange',function(){if(window.orientation===0){width=winWidth;height=winHeight;}else if(window.orientation===90||window.orientation===-90){width=winHeight;height=winWidth;}},false);}else{width=window.innerWidth?window.innerWidth:$(window).width();height=window.innerHeight?window.innerHeight:$(window).height();}sliderCss={width:width,height:height};$('#swipebox-overlay').css(sliderCss);},resize:function(){var $this=this;$(window).resize(function(){$this.setDim();}).resize();},supportTransition:function(){var prefixes='transition WebkitTransition MozTransition OTransition msTransition KhtmlTransition'.split(' '),i;for(i=0;i');var $link=$list.find('a');$link.wrapInner('