/* @license Expanse by Archetype Themes (https://archetypethemes.co) Plugins: JavaScript Cookie 2.2.0 Flickity 2.3.0 with customizations by Archetype Flickity Fade 1.0.0 with customizations by Archetype Photoswipe 4.1.3 Photoswipe UI 4.1.2 with customizations by Archetype noUiSlider 15.2.0 Lazysizes for image loading: core 4.0.2 respimg 4.0.1 rias 4.0.1 */ /*! lazysizes respimg - v4.0.1 */ !function(t,e){var i=function(){e(t.lazySizes),t.removeEventListener("lazyunveilread",i,!0)};e=e.bind(null,t,t.document),"object"==typeof module&&module.exports?e(require("lazysizes"),require("../fix-ios-sizes/fix-ios-sizes")):t.lazySizes?i():t.addEventListener("lazyunveilread",i,!0)}(window,(function(t,e,i){"use strict";var n,o=i&&i.cfg||t.lazySizesConfig,r=e.createElement("img"),s="sizes"in r&&"srcset"in r,a=/\s+\d+h/g,l=function(){var t=/\s+(\d+)(w|h)\s+(\d+)(w|h)/,i=Array.prototype.forEach;return function(n){var o=e.createElement("img"),r=function(e){var i,n=e.getAttribute(lazySizesConfig.srcsetAttr);n&&(n.match(t)&&((i="w"==RegExp.$2?RegExp.$1/RegExp.$3:RegExp.$3/RegExp.$1)&&e.setAttribute("data-aspectratio",i)),e.setAttribute(lazySizesConfig.srcsetAttr,n.replace(a,"")))},s=function(t){var e=t.target.parentNode;e&&"PICTURE"==e.nodeName&&i.call(e.getElementsByTagName("source"),r),r(t.target)},l=function(){o.currentSrc&&e.removeEventListener("lazybeforeunveil",s)};n[1]&&(e.addEventListener("lazybeforeunveil",s),o.onload=l,o.onerror=l,o.srcset="data:,a 1w 1h",o.complete&&l())}}();if(o||(o={},t.lazySizesConfig=o),o.supportsType||(o.supportsType=function(t){return!t}),!t.picturefill&&!o.pf){if(t.HTMLPictureElement&&s)return e.msElementsFromPoint&&l(navigator.userAgent.match(/Edge\/(\d+)/)),void(o.pf=function(){});o.pf=function(e){var i,o;if(!t.picturefill)for(i=0,o=e.elements.length;o>i;i++)n(e.elements[i])},n=function(){var r=function(t,e){return t.w-e.w},l=/^\s*\d+\.*\d*px\s*$/,c=function(){var t,e=/(([^,\s].[^\s]+)\s+(\d+)w)/g,i=/\s/,n=function(e,i,n,o){t.push({c:i,u:n,w:1*o})};return function(o){return t=[],(o=o.trim()).replace(a,"").replace(e,n),t.length||!o||i.test(o)||t.push({c:o,u:o,w:99}),t}}(),u=function(){u.init||(u.init=!0,addEventListener("resize",function(){var t,i=e.getElementsByClassName("lazymatchmedia"),o=function(){var t,e;for(t=0,e=i.length;e>t;t++)n(i[t])};return function(){clearTimeout(t),t=setTimeout(o,66)}}()))},d=function(e,n){var r,s=e.getAttribute("srcset")||e.getAttribute(o.srcsetAttr);!s&&n&&(s=e._lazypolyfill?e._lazypolyfill._set:e.getAttribute(o.srcAttr)||e.getAttribute("src")),e._lazypolyfill&&e._lazypolyfill._set==s||(r=c(s||""),n&&e.parentNode&&(r.isPicture="PICTURE"==e.parentNode.nodeName.toUpperCase(),r.isPicture&&t.matchMedia&&(i.aC(e,"lazymatchmedia"),u())),r._set=s,Object.defineProperty(e,"_lazypolyfill",{value:r,writable:!0}))},h=function(e){var n=t.devicePixelRatio||1,o=i.getX&&i.getX(e);return Math.min(o||n,2.5,n)},p=function(e){return t.matchMedia?(p=function(t){return!t||(matchMedia(t)||{}).matches})(e):!e},f=function(t){var e,n,s,a,c,u,f;if(d(a=t,!0),(c=a._lazypolyfill).isPicture)for(n=0,s=(e=t.parentNode.getElementsByTagName("source")).length;s>n;n++)if(o.supportsType(e[n].getAttribute("type"),t)&&p(e[n].getAttribute("media"))){a=e[n],d(a),c=a._lazypolyfill;break}return c.length>1?(f=a.getAttribute("sizes")||"",f=l.test(f)&&parseInt(f,10)||i.gW(t,t.parentNode),c.d=h(t),!c.src||!c.w||c.wr;r++)if((o=t[r]).d=o.w/t.w,o.d>=t.d){!o.cached&&(e=t[r-1])&&e.d>t.d-.13*Math.pow(t.d,2.2)&&(i=Math.pow(e.d-.6,1.6),e.cached&&(e.d+=.15*i),e.d+(o.d-t.d)*i>t.d&&(o=e));break}return o}(c.sort(r)),c.src=u):u=c.src):u=c[0],u},m=function(t){if(!s||!t.parentNode||"PICTURE"==t.parentNode.nodeName.toUpperCase()){var e=f(t);e&&e.u&&t._lazypolyfill.cur!=e.u&&(t._lazypolyfill.cur=e.u,e.cached=!0,t.setAttribute(o.srcAttr,e.u),t.setAttribute("src",e.u))}};return m.parse=c,m}(),o.loadedClass&&o.loadingClass&&function(){var t=[];['img[sizes$="px"][srcset].',"picture > img:not([srcset])."].forEach((function(e){t.push(e+o.loadedClass),t.push(e+o.loadingClass)})),o.pf({elements:e.querySelectorAll(t.join(", "))})}()}})),function(t,e){var i=function(){e(t.lazySizes),t.removeEventListener("lazyunveilread",i,!0)};e=e.bind(null,t,t.document),"object"==typeof module&&module.exports?e(require("lazysizes")):t.lazySizes?i():t.addEventListener("lazyunveilread",i,!0)}(window,(function(t,e,i){"use strict";function n(e,i){var n,o,r,s,a=t.getComputedStyle(e);for(n in o=e.parentNode,s={isPicture:!(!o||!d.test(o.nodeName||""))},r=function(t,i){var n=e.getAttribute("data-"+t);if(!n){var o=a.getPropertyValue("--ls-"+t);o&&(n=o.trim())}if(n){if("true"==n)n=!0;else if("false"==n)n=!1;else if(u.test(n))n=parseFloat(n);else if("function"==typeof l[t])n=l[t](e,n);else if(m.test(n))try{n=JSON.parse(n)}catch(t){}s[t]=n}else t in l&&"function"!=typeof l[t]?s[t]=l[t]:i&&"function"==typeof l[t]&&(s[t]=l[t](e,n))},l)r(n);return i.replace(f,(function(t,e){e in s||r(e,!0)})),s}function o(t,i,n){var o=0,r=0,s=n;if(t){if("container"===i.ratio){for(o=s.scrollWidth,r=s.scrollHeight;!(o&&r||s===e);)o=(s=s.parentNode).scrollWidth,r=s.scrollHeight;o&&r&&(i.ratio=r/o)}(t=function(t,e){var i=[];return i.srcset=[],e.absUrl&&(v.setAttribute("href",t),t=v.href),t=((e.prefix||"")+t+(e.postfix||"")).replace(f,(function(t,i){return c[typeof e[i]]?e[i]:t})),e.widths.forEach((function(n){var o=e.widthmap[n]||n,r={u:t.replace(h,o).replace(p,e.ratio?Math.round(n*e.ratio):""),w:n};i.push(r),i.srcset.push(r.c=r.u+" "+n+"w")})),i}(t,i)).isPicture=i.isPicture,x&&"IMG"==n.nodeName.toUpperCase()?n.removeAttribute(a.srcsetAttr):n.setAttribute(a.srcsetAttr,t.srcset.join(", ")),Object.defineProperty(n,"_lazyrias",{value:t,writable:!0})}}function r(t,e){var o=n(t,e);return l.modifyOptions.call(t,{target:t,details:o,detail:o}),i.fire(t,"lazyriasmodifyoptions",o),o}function s(t){return t.getAttribute(t.getAttribute("data-srcattr")||l.srcAttr)||t.getAttribute(a.srcsetAttr)||t.getAttribute(a.srcAttr)||t.getAttribute("data-pfsrcset")||""}var a,l,c={string:1,number:1},u=/^\-*\+*\d+\.*\d*$/,d=/^picture$/i,h=/\s*\{\s*width\s*\}\s*/i,p=/\s*\{\s*height\s*\}\s*/i,f=/\s*\{\s*([a-z0-9]+)\s*\}\s*/gi,m=/^\[.*\]|\{.*\}$/,g=/^(?:auto|\d+(px)?)$/,v=e.createElement("a"),y=e.createElement("img"),x="srcset"in y&&!("sizes"in y),b=!!t.HTMLPictureElement&&!x;!function(){var e,n={prefix:"",postfix:"",srcAttr:"data-src",absUrl:!1,modifyOptions:function(){},widthmap:{},ratio:!1};for(e in(a=i&&i.cfg||t.lazySizesConfig)||(a={},t.lazySizesConfig=a),a.supportsType||(a.supportsType=function(t){return!t}),a.rias||(a.rias={}),"widths"in(l=a.rias)||(l.widths=[],function(t){for(var e,i=0;!e||3e3>e;)(i+=5)>30&&(i+=1),e=36*i,t.push(e)}(l.widths)),n)e in l||(l[e]=n[e])}(),addEventListener("lazybeforesizes",(function(t){var e,n,c,u,d,p,f,m,v,y,x,S,C;if(t.detail.instance==i&&(e=t.target,t.detail.dataAttr&&!t.defaultPrevented&&!l.disabled&&(v=e.getAttribute(a.sizesAttr)||e.getAttribute("sizes"))&&g.test(v))){if(c=r(e,n=s(e)),x=h.test(c.prefix)||h.test(c.postfix),c.isPicture&&(u=e.parentNode))for(p=0,f=(d=u.getElementsByTagName("source")).length;f>p;p++)(x||h.test(m=s(d[p])))&&(o(m,c,d[p]),S=!0);x||h.test(n)?(o(n,c,e),S=!0):S&&((C=[]).srcset=[],C.isPicture=!0,Object.defineProperty(e,"_lazyrias",{value:C,writable:!0})),S&&(b?e.removeAttribute(a.srcAttr):"auto"!=v&&(y={width:parseInt(v,10)},w({target:e,detail:y})))}}),!0);var w=function(){var n=function(t,e){return t.w-e.w},o=function(t,e){var n;return!t._lazyrias&&i.pWS&&(n=i.pWS(t.getAttribute(a.srcsetAttr||""))).length&&(Object.defineProperty(t,"_lazyrias",{value:n,writable:!0}),e&&t.parentNode&&(n.isPicture="PICTURE"==t.parentNode.nodeName.toUpperCase())),t._lazyrias},r=function(e){var n=t.devicePixelRatio||1,o=i.getX&&i.getX(e);return Math.min(o||n,2.4,n)},s=function(e,i){var s,a,l,c,u,d;if((u=e._lazyrias).isPicture&&t.matchMedia)for(a=0,l=(s=e.parentNode.getElementsByTagName("source")).length;l>a;a++)if(o(s[a])&&!s[a].getAttribute("type")&&(!(c=s[a].getAttribute("media"))||(matchMedia(c)||{}).matches)){u=s[a]._lazyrias;break}return(!u.w||u.wr;r++)if((o=t[r]).d=o.w/t.w,o.d>=t.d){!o.cached&&(e=t[r-1])&&e.d>t.d-.13*Math.pow(t.d,2.2)&&(i=Math.pow(e.d-.6,1.6),e.cached&&(e.d+=.15*i),e.d+(o.d-t.d)*i>t.d&&(o=e));break}return o}(u.sort(n))),d},l=function(n){if(n.detail.instance==i){var r,c=n.target;return!x&&(t.respimage||t.picturefill||lazySizesConfig.pf)?void e.removeEventListener("lazybeforesizes",l):void(("_lazyrias"in c||n.detail.dataAttr&&o(c,!0))&&(r=s(c,n.detail.width),r&&r.u&&c._lazyrias.cur!=r.u&&(c._lazyrias.cur=r.u,r.cached=!0,i.rAF((function(){c.setAttribute(a.srcAttr,r.u),c.setAttribute("src",r.u)})))))}};return b?l=function(){}:addEventListener("lazybeforesizes",l),l}()})),function(t,e){var i=function(t,e){"use strict";if(e.getElementsByClassName){var i,n,o=e.documentElement,r=t.Date,s=t.HTMLPictureElement,a="addEventListener",l="getAttribute",c=t[a],u=t.setTimeout,d=t.requestAnimationFrame||u,h=t.requestIdleCallback,p=/^picture$/i,f=["load","error","lazyincluded","_lazyloaded"],m={},g=Array.prototype.forEach,v=function(t,e){return m[e]||(m[e]=new RegExp("(\\s|^)"+e+"(\\s|$)")),m[e].test(t[l]("class")||"")&&m[e]},y=function(t,e){v(t,e)||t.setAttribute("class",(t[l]("class")||"").trim()+" "+e)},x=function(t,e){var i;(i=v(t,e))&&t.setAttribute("class",(t[l]("class")||"").replace(i," "))},b=function(t,e,i){var n=i?a:"removeEventListener";i&&b(t,e),f.forEach((function(i){t[n](i,e)}))},w=function(t,n,o,r,s){var a=e.createEvent("CustomEvent");return o||(o={}),o.instance=i,a.initCustomEvent(n,!r,!s,o),t.dispatchEvent(a),a},S=function(e,i){var o;!s&&(o=t.picturefill||n.pf)?o({reevaluate:!0,elements:[e]}):i&&i.src&&(e.src=i.src)},C=function(t,e){return(getComputedStyle(t,null)||{})[e]},E=function(t,e,i){for(i=i||t.offsetWidth;i49?function(){h(a,{timeout:s}),s!==n.ricTimeout&&(s=n.ricTimeout)}:P((function(){u(a)}),!0);return function(t){var n;(t=!0===t)&&(s=33),e||(e=!0,(n=o-(r.now()-i))<0&&(n=0),t||n<9?l():u(l,n))}},A=function(t){var e,i,n=function(){e=null,t()},o=function(){var t=r.now()-i;t<99?u(o,99-t):(h||n)(n)};return function(){i=r.now(),e||(e=u(o,99))}};!function(){var e,i={lazyClass:"lazyload",loadedClass:"lazyloaded",loadingClass:"lazyloading",preloadClass:"lazypreload",errorClass:"lazyerror",autosizesClass:"lazyautosizes",srcAttr:"data-src",srcsetAttr:"data-srcset",sizesAttr:"data-sizes",minSize:40,customMedia:{},init:!0,expFactor:1.5,hFac:.8,loadMode:2,loadHidden:!0,ricTimeout:0,throttleDelay:125};for(e in n=t.lazySizesConfig||t.lazysizesConfig||{},i)e in n||(n[e]=i[e]);t.lazySizesConfig=n,u((function(){n.init&&k()}))}();var _=function(){var s,d,h,f,m,E,_,k,T,M,L,F,N,O,U=/^img$/i,R=/^iframe$/i,W="onscroll"in t&&!/glebot/.test(navigator.userAgent),V=0,H=0,B=-1,j=function(t){H--,t&&t.target&&b(t.target,j),(!t||H<0||!t.target)&&(H=0)},q=function(t,i){var n,r=t,s="hidden"==C(e.body,"visibility")||"hidden"!=C(t,"visibility");for(k-=i,L+=i,T-=i,M+=i;s&&(r=r.offsetParent)&&r!=e.body&&r!=o;)(s=(C(r,"opacity")||1)>0)&&"visible"!=C(r,"overflow")&&(n=r.getBoundingClientRect(),s=M>n.left&&Tn.top-1&&k500&&o.clientWidth>500?500:370),F=n.expand,N=F*n.expFactor),V2&&f>2&&!e.hidden?(V=N,B=0):V=f>1&&B>1&&H<6?F:0;for(;r=p&&(k=a.top)<=_&&(M=a.right)>=p*O&&(T=a.left)<=E&&(L||M||T||k)&&(n.loadHidden||"hidden"!=C(v[r],"visibility"))&&(d&&H<3&&!m&&(f<3||B<4)||q(v[r],h))){if(Q(v[r]),u=!0,H>9)break}else!u&&d&&!c&&H<4&&B<4&&f>2&&(s[0]||n.preloadAfterLoad)&&(s[0]||!m&&(L||M||T||k||"auto"!=v[r][l](n.sizesAttr)))&&(c=s[0]||v[r]);else Q(v[r]);c&&!u&&Q(c)}},X=z(Z),G=function(t){y(t.target,n.loadedClass),x(t.target,n.loadingClass),b(t.target,K),w(t.target,"lazyloaded")},Y=P(G),K=function(t){Y({target:t.target})},$=function(t){var e,i=t[l](n.srcsetAttr);(e=n.customMedia[t[l]("data-media")||t[l]("media")])&&t.setAttribute("media",e),i&&t.setAttribute("srcset",i)},J=P((function(t,e,i,o,r){var s,a,c,d,f,m;(f=w(t,"lazybeforeunveil",e)).defaultPrevented||(o&&(i?y(t,n.autosizesClass):t.setAttribute("sizes",o)),a=t[l](n.srcsetAttr),s=t[l](n.srcAttr),r&&(d=(c=t.parentNode)&&p.test(c.nodeName||"")),m=e.firesLoad||"src"in t&&(a||s||d),f={target:t},m&&(b(t,j,!0),clearTimeout(h),h=u(j,2500),y(t,n.loadingClass),b(t,K,!0)),d&&g.call(c.getElementsByTagName("source"),$),a?t.setAttribute("srcset",a):s&&!d&&(R.test(t.nodeName)?function(t,e){try{t.contentWindow.location.replace(e)}catch(i){t.src=e}}(t,s):t.src=s),r&&(a||d)&&S(t,{src:s})),t._lazyRace&&delete t._lazyRace,x(t,n.lazyClass),D((function(){(!m||t.complete&&t.naturalWidth>1)&&(m?j(f):H--,G(f))}),!0)})),Q=function(t){var e,i=U.test(t.nodeName),o=i&&(t[l](n.sizesAttr)||t[l]("sizes")),r="auto"==o;(!r&&d||!i||!t[l]("src")&&!t.srcset||t.complete||v(t,n.errorClass)||!v(t,n.lazyClass))&&(e=w(t,"lazyunveilread").detail,r&&I.updateElem(t,!0,t.offsetWidth),t._lazyRace=!0,H++,J(t,e,r,o,i))},tt=function(){if(!d){if(r.now()-m<999)return void u(tt,999);var t=A((function(){n.loadMode=3,X()}));d=!0,n.loadMode=3,X(),c("scroll",(function(){3==n.loadMode&&(n.loadMode=2),t()}),!0)}};return{_:function(){m=r.now(),i.elements=e.getElementsByClassName(n.lazyClass),s=e.getElementsByClassName(n.lazyClass+" "+n.preloadClass),O=n.hFac,c("scroll",X,!0),c("resize",X,!0),t.MutationObserver?new MutationObserver(X).observe(o,{childList:!0,subtree:!0,attributes:!0}):(o[a]("DOMNodeInserted",X,!0),o[a]("DOMAttrModified",X,!0),setInterval(X,999)),c("hashchange",X,!0),["focus","mouseover","click","load","transitionend","animationend","webkitAnimationEnd"].forEach((function(t){e[a](t,X,!0)})),/d$|^c/.test(e.readyState)?tt():(c("load",tt),e[a]("DOMContentLoaded",X),u(tt,2e4)),i.elements.length?(Z(),D._lsFlush()):X()},checkElems:X,unveil:Q}}(),I=function(){var t,i=P((function(t,e,i,n){var o,r,s;if(t._lazysizesWidth=n,n+="px",t.setAttribute("sizes",n),p.test(e.nodeName||""))for(r=0,s=(o=e.getElementsByTagName("source")).length;r1){if("number"==typeof(r=t({path:"/"},n.defaults,r)).expires){var a=new Date;a.setMilliseconds(a.getMilliseconds()+864e5*r.expires),r.expires=a}r.expires=r.expires?r.expires.toUTCString():"";try{s=JSON.stringify(o),/^[\{\[]/.test(s)&&(o=s)}catch(t){}o=i.write?i.write(o,e):encodeURIComponent(String(o)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),e=(e=(e=encodeURIComponent(String(e))).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent)).replace(/[\(\)]/g,escape);var l="";for(var c in r)r[c]&&(l+="; "+c,!0!==r[c]&&(l+="="+r[c]));return document.cookie=e+"="+o+l}e||(s={});for(var u=document.cookie?document.cookie.split("; "):[],d=/(%[0-9A-Z]{2})+/g,h=0;h1&&(t=e.modulo(t,this.slideableWidth),t-=this.slideableWidth,this.shiftWrapCells(t)),this.setTranslateX(t,this.isAnimating),this.dispatchScrollEvent()},setTranslateX:function(t,e){t+=this.cursorPosition,t=this.options.rightToLeft?-t:t;var i=this.getPositionValue(t);this.slider.style.transform=e?"translate3d("+i+",0,0)":"translateX("+i+")"},dispatchScrollEvent:function(){var t=this.slides[0];if(t){var e=-this.x-t.target,i=e/this.slidesWidth;this.dispatchEvent("scroll",null,[i,e])}},positionSliderAtSelected:function(){this.cells.length&&(this.x=-this.selectedSlide.target,this.velocity=0,this.positionSlider())},getPositionValue:function(t){return this.options.percentPosition?.01*Math.round(t/this.size.innerWidth*1e4)+"%":Math.round(t)+"px"},settle:function(t){!this.isPointerDown&&Math.round(100*this.x)==Math.round(100*t)&&this.restingFrames++,this.restingFrames>2&&(this.isAnimating=!1,delete this.isFreeScrolling,this.positionSlider(),this.dispatchEvent("settle",null,[this.selectedIndex]))},shiftWrapCells:function(t){var e=this.cursorPosition+t;this._shiftCells(this.beforeShiftCells,e,-1);var i=this.size.innerWidth-(t+this.slideableWidth+this.cursorPosition);this._shiftCells(this.afterShiftCells,i,1)},_shiftCells:function(t,e,i){for(var n=0;n0?i:0;o.wrapShift(r),e-=o.size.outerWidth}},_unshiftCells:function(t){if(t&&t.length)for(var e=0;e0){var i=this.cells[t-1];e=i.x+i.size.outerWidth}for(var n=this.cells.length,o=t;o0;){var o=this.cells[e];if(!o)break;n.push(o),e+=i,t-=o.size.outerWidth}return n},d._containSlides=function(){if(this.options.contain&&!this.options.wrapAround&&this.cells.length){var t=this.options.rightToLeft,e=t?"marginRight":"marginLeft",i=t?"marginLeft":"marginRight",n=this.slideableWidth-this.getLastCell().size[i],o=n1))return t;var i=n.modulo(t,e),o=Math.abs(i-this.selectedIndex),r=Math.abs(i+e-this.selectedIndex),s=Math.abs(i-e-this.selectedIndex);!this.isDragSelect&&r=e&&(this.x+=this.slideableWidth)},d.previous=function(t,e){this.select(this.selectedIndex-1,t,e)},d.next=function(t,e){this.select(this.selectedIndex+1,t,e)},d.updateSelectedSlide=function(){var t=this.slides[this.selectedIndex];t&&(this.unselectSelectedSlide(),this.selectedSlide=t,t.select(),this.selectedCells=t.cells,this.selectedElements=t.getCellElements(),this.selectedCell=t.cells[0],this.selectedElement=this.selectedElements[0])},d.unselectSelectedSlide=function(){this.selectedSlide&&this.selectedSlide.unselect()},d.selectInitialIndex=function(){var t=this.options.initialIndex;if(this.isInitActivated)this.select(this.selectedIndex,!1,!0);else{if(t&&"string"==typeof t)if(this.queryCell(t))return void this.selectCell(t,!1,!0);var e=0;t&&this.slides[t]&&(e=t),this.select(e,!1,!0)}},d.selectCell=function(t,e,i){var n=this.queryCell(t);if(n){var o=this.getCellSlideIndex(n);this.select(o,e,i)}},d.getCellSlideIndex=function(t){for(var e=0;e *"),this.getCell(t))},d.getAdjacentCellElements=function(t,e){if(!t)return this.selectedSlide.getCellElements();e=void 0===e?this.selectedIndex:e;var i=this.slides.length;if(1+2*t>=i)return this.getCellElements();for(var o=[],r=e-t;r<=e+t;r++){var s=this.options.wrapAround?n.modulo(r,i):r,a=this.slides[s];a&&(o=o.concat(a.getCellElements()))}return o},d.queryCell=function(t){if("number"==typeof t)return this.cells[t];if("string"==typeof t){if(t.match(/^[#.]?[\d/]/))return;t=this.element.querySelector(t)}return this.getCell(t)},d.uiChange=function(){this.emitEvent("uiChange")},d.childUIPointerDown=function(t){"touchstart"!=t.type&&t.preventDefault(),this.focus()},d.onresize=function(){this.resize()},n.debounceMethod(u,"onresize",150),d.resize=function(){if(this.isActive&&!this.isAnimating&&!this.isDragging){this.getSize(),this.options.wrapAround&&(this.x=n.modulo(this.x,this.slideableWidth)),this.positionCells(),this._getWrapShiftCells(),this.setGallerySize(),this.emitEvent("resize");var t=this.selectedElements&&this.selectedElements[0];this.selectCell(t,!1,!0)}},d.onkeydown=function(t){var e=document.activeElement&&document.activeElement!=this.element;if(this.options.accessibility&&!e){var i=u.keyboardHandlers[t.keyCode];i&&i.call(this)}},u.keyboardHandlers={37:function(){var t=this.options.rightToLeft?"next":"previous";this.uiChange(),this[t]()},39:function(){var t=this.options.rightToLeft?"previous":"next";this.uiChange(),this[t]()}},d.focus=function(){var e=t.pageYOffset;this.element.focus({preventScroll:!0}),t.pageYOffset!=e&&t.scrollTo(t.pageXOffset,e)},d.deactivate=function(){this.isActive&&(this.element.classList.remove("flickity-enabled"),this.element.classList.remove("flickity-rtl"),this.unselectSelectedSlide(),this.cells.forEach((function(t){t.destroy()})),this.element.removeChild(this.viewport),a(this.slider.children,this.element),this.options.accessibility&&(this.element.removeAttribute("tabIndex"),this.element.removeEventListener("keydown",this)),this.isActive=!1,this.emitEvent("deactivate"))},d.destroy=function(){this.deactivate(),t.removeEventListener("resize",this),this.allOff(),this.emitEvent("destroy"),delete this.element.flickityGUID,delete c[this.guid]},n.extend(d,s),u.data=function(t){var e=(t=n.getQueryElement(t))&&t.flickityGUID;return e&&c[e]},n.htmlInit(u,"flickity"),u.Cell=o,u.Slide=r,u})), /*! * Unipointer v2.4.0 * base class for doing one thing with pointer event * MIT license */ function(t,e){"function"==typeof define&&define.amd?define("unipointer/unipointer",["ev-emitter/ev-emitter"],(function(i){return e(t,i)})):"object"==typeof module&&module.exports?module.exports=e(t,require("ev-emitter")):t.Unipointer=e(t,t.EvEmitter)}(window,(function(t,e){function i(){}var n=i.prototype=Object.create(e.prototype);n.bindStartEvent=function(t){this._bindStartEvent(t,!0)},n.unbindStartEvent=function(t){this._bindStartEvent(t,!1)},n._bindStartEvent=function(e,i){var n=(i=void 0===i||i)?"addEventListener":"removeEventListener",o="mousedown";"ontouchstart"in t?o="touchstart":t.PointerEvent&&(o="pointerdown"),e[n](o,this)},n.handleEvent=function(t){var e="on"+t.type;this[e]&&this[e](t)},n.getTouch=function(t){for(var e=0;e3||Math.abs(t.y)>3},n.pointerUp=function(t,e){this.emitEvent("pointerUp",[t,e]),this._dragPointerUp(t,e)},n._dragPointerUp=function(t,e){this.isDragging?this._dragEnd(t,e):this._staticClick(t,e)},n._dragStart=function(t,e){this.isDragging=!0,this.isPreventingClicks=!0,this.dragStart(t,e)},n.dragStart=function(t,e){this.emitEvent("dragStart",[t,e])},n._dragMove=function(t,e,i){this.isDragging&&this.dragMove(t,e,i)},n.dragMove=function(t,e,i){t.preventDefault(),this.emitEvent("dragMove",[t,e,i])},n._dragEnd=function(t,e){this.isDragging=!1,setTimeout(function(){delete this.isPreventingClicks}.bind(this)),this.dragEnd(t,e)},n.dragEnd=function(t,e){this.emitEvent("dragEnd",[t,e])},n.onclick=function(t){this.isPreventingClicks&&t.preventDefault()},n._staticClick=function(t,e){this.isIgnoringMouseUp&&"mouseup"==t.type||(this.staticClick(t,e),"mouseup"!=t.type&&(this.isIgnoringMouseUp=!0,setTimeout(function(){delete this.isIgnoringMouseUp}.bind(this),400)))},n.staticClick=function(t,e){this.emitEvent("staticClick",[t,e])},i.getPointerPoint=e.getPointerPoint,i})),function(t,e){"function"==typeof define&&define.amd?define("flickity/js/drag",["./flickity","unidragger/unidragger","fizzy-ui-utils/utils"],(function(i,n,o){return e(t,i,n,o)})):"object"==typeof module&&module.exports?module.exports=e(t,require("./flickity"),require("unidragger"),require("fizzy-ui-utils")):t.Flickity=e(t,t.Flickity,t.Unidragger,t.fizzyUIUtils)}(window,(function(t,e,i,n){n.extend(e.defaults,{draggable:">1",dragThreshold:3}),e.createMethods.push("_createDrag");var o=e.prototype;n.extend(o,i.prototype),o._touchActionValue="pan-y",o._createDrag=function(){this.on("activate",this.onActivateDrag),this.on("uiChange",this._uiChangeDrag),this.on("deactivate",this.onDeactivateDrag),this.on("cellChange",this.updateDraggable)},o.onActivateDrag=function(){this.handles=[this.viewport],this.bindHandles(),this.updateDraggable()},o.onDeactivateDrag=function(){this.unbindHandles(),this.element.classList.remove("is-draggable")},o.updateDraggable=function(){">1"==this.options.draggable?this.isDraggable=this.slides.length>1:this.isDraggable=this.options.draggable,this.isDraggable?this.element.classList.add("is-draggable"):this.element.classList.remove("is-draggable")},o.bindDrag=function(){this.options.draggable=!0,this.updateDraggable()},o.unbindDrag=function(){this.options.draggable=!1,this.updateDraggable()},o._uiChangeDrag=function(){delete this.isFreeScrolling},o.pointerDown=function(e,i){this.isDraggable?this.okayPointerDown(e)&&(this._pointerDownPreventDefault(e),this.pointerDownFocus(e),document.activeElement!=this.element&&this.pointerDownBlur(),this.dragX=this.x,this.viewport.classList.add("is-pointer-down"),this.pointerDownScroll=s(),t.addEventListener("scroll",this),this._pointerDownDefault(e,i)):this._pointerDownDefault(e,i)},o._pointerDownDefault=function(t,e){this.pointerDownPointer={pageX:e.pageX,pageY:e.pageY},this._bindPostStartEvents(t),this.dispatchEvent("pointerDown",t,[e])};var r={INPUT:!0,TEXTAREA:!0,SELECT:!0};function s(){return{x:t.pageXOffset,y:t.pageYOffset}}return o.pointerDownFocus=function(t){r[t.target.nodeName]||this.focus()},o._pointerDownPreventDefault=function(t){var e="touchstart"==t.type,i="touch"==t.pointerType,n=r[t.target.nodeName];e||i||n||t.preventDefault()},o.hasDragStarted=function(t){return Math.abs(t.x)>this.options.dragThreshold},o.pointerUp=function(t,e){delete this.isTouchScrolling,this.viewport.classList.remove("is-pointer-down"),this.dispatchEvent("pointerUp",t,[e]),this._dragPointerUp(t,e)},o.pointerDone=function(){t.removeEventListener("scroll",this),delete this.pointerDownScroll},o.dragStart=function(e,i){this.isDraggable&&(this.dragStartPosition=this.x,this.startAnimation(),t.removeEventListener("scroll",this),this.dispatchEvent("dragStart",e,[i]))},o.pointerMove=function(t,e){var i=this._dragPointerMove(t,e);this.dispatchEvent("pointerMove",t,[e,i]),this._dragMove(t,e,i)},o.dragMove=function(t,e,i){if(this.isDraggable){t.preventDefault(),this.previousDragX=this.dragX;var n=this.options.rightToLeft?-1:1;this.options.wrapAround&&(i.x%=this.slideableWidth);var o=this.dragStartPosition+i.x*n;if(!this.options.wrapAround&&this.slides.length){var r=Math.max(-this.slides[0].target,this.dragStartPosition);o=o>r?.5*(o+r):o;var s=Math.min(-this.getLastSlide().target,this.dragStartPosition);o=othis.slides[0].target&&-n1,r=o?n.modulo(e,i):e,s=this.slides[r];if(!s)return null;var a=o?this.slideableWidth*Math.floor(e/i):0;return t-(s.target+a)},o.dragEndBoostSelect=function(){if(void 0===this.previousDragX||!this.dragMoveTime||new Date-this.dragMoveTime>100)return 0;var t=this.getSlideDistance(-this.dragX,this.selectedIndex),e=this.previousDragX-this.dragX;return t>0&&e>0?1:t<0&&e<0?-1:0},o.staticClick=function(t,e){var i=this.getParentCell(t.target),n=i&&i.element,o=i&&this.cells.indexOf(i);this.dispatchEvent("staticClick",t,[e,n,o])},o.onscroll=function(){var t=s(),e=this.pointerDownScroll.x-t.x,i=this.pointerDownScroll.y-t.y;(Math.abs(e)>3||Math.abs(i)>3)&&this._pointerDone()},e})),function(t,e){"function"==typeof define&&define.amd?define("flickity/js/prev-next-button",["./flickity","unipointer/unipointer","fizzy-ui-utils/utils"],(function(i,n,o){return e(t,i,n,o)})):"object"==typeof module&&module.exports?module.exports=e(t,require("./flickity"),require("unipointer"),require("fizzy-ui-utils")):e(t,t.Flickity,t.Unipointer,t.fizzyUIUtils)}(window,(function(t,e,i,n){"use strict";var o="http://www.w3.org/2000/svg";function r(t,e){this.direction=t,this.parent=e,this._create()}r.prototype=Object.create(i.prototype),r.prototype._create=function(){this.isEnabled=!0,this.isPrevious=-1==this.direction;var t=this.parent.options.rightToLeft?1:-1;this.isLeft=this.direction==t;var e=this.element=document.createElement("button");e.className="flickity-button flickity-prev-next-button",e.className+=this.isPrevious?" flickity-previous":" flickity-next",e.setAttribute("type","button"),this.disable(),e.setAttribute("aria-label",this.isPrevious?"Previous":"Next");var i=this.createSVG();e.appendChild(i),this.parent.on("select",this.update.bind(this)),this.on("pointerDown",this.parent.childUIPointerDown.bind(this.parent))},r.prototype.activate=function(){this.bindStartEvent(this.element),this.element.addEventListener("click",this),this.parent.element.appendChild(this.element)},r.prototype.deactivate=function(){this.parent.element.removeChild(this.element),this.unbindStartEvent(this.element),this.element.removeEventListener("click",this)},r.prototype.createSVG=function(){var t=document.createElementNS(o,"svg");t.setAttribute("class","flickity-button-icon"),t.setAttribute("viewBox","0 0 100 100");var e=document.createElementNS(o,"path"),i=function(t){if("string"==typeof t)return t;return"M "+t.x0+",50 L "+t.x1+","+(t.y1+50)+" L "+t.x2+","+(t.y2+50)+" L "+t.x3+",50 L "+t.x2+","+(50-t.y2)+" L "+t.x1+","+(50-t.y1)+" Z"}(this.parent.options.arrowShape);return e.setAttribute("d",i),e.setAttribute("class","arrow"),this.isLeft||e.setAttribute("transform","translate(100, 100) rotate(180) "),t.appendChild(e),t},r.prototype.handleEvent=n.handleEvent,r.prototype.onclick=function(){if(this.isEnabled){this.parent.uiChange();var t=this.isPrevious?"previous":"next";this.parent[t]()}},r.prototype.enable=function(){this.isEnabled||(this.element.disabled=!1,this.isEnabled=!0)},r.prototype.disable=function(){this.isEnabled&&(this.element.disabled=!0,this.isEnabled=!1)},r.prototype.update=function(){var t=this.parent.slides;if(this.parent.options.wrapAround&&t.length>1)this.enable();else{var e=t.length?t.length-1:0,i=this.isPrevious?0:e;this[this.parent.selectedIndex==i?"disable":"enable"]()}},r.prototype.destroy=function(){this.deactivate(),this.allOff()},n.extend(e.defaults,{prevNextButtons:!0,arrowShape:{x0:10,x1:60,y1:50,x2:70,y2:40,x3:30}}),e.createMethods.push("_createPrevNextButtons");var s=e.prototype;return s._createPrevNextButtons=function(){this.options.prevNextButtons&&(this.prevButton=new r(-1,this),this.nextButton=new r(1,this),this.on("activate",this.activatePrevNextButtons))},s.activatePrevNextButtons=function(){this.prevButton.activate(),this.nextButton.activate(),this.on("deactivate",this.deactivatePrevNextButtons)},s.deactivatePrevNextButtons=function(){this.prevButton.deactivate(),this.nextButton.deactivate(),this.off("deactivate",this.deactivatePrevNextButtons)},e.PrevNextButton=r,e})),function(t,e){"function"==typeof define&&define.amd?define("flickity/js/page-dots",["./flickity","unipointer/unipointer","fizzy-ui-utils/utils"],(function(i,n,o){return e(t,i,n,o)})):"object"==typeof module&&module.exports?module.exports=e(t,require("./flickity"),require("unipointer"),require("fizzy-ui-utils")):e(t,t.Flickity,t.Unipointer,t.fizzyUIUtils)}(window,(function(t,e,i,n){function o(t){this.parent=t,this._create()}o.prototype=Object.create(i.prototype),o.prototype._create=function(){this.holder=document.createElement("ol"),this.holder.className="flickity-page-dots",this.dots=[],this.handleClick=this.onClick.bind(this),this.on("pointerDown",this.parent.childUIPointerDown.bind(this.parent))},o.prototype.activate=function(){this.setDots(),this.holder.addEventListener("click",this.handleClick),this.bindStartEvent(this.holder),this.parent.element.appendChild(this.holder)},o.prototype.deactivate=function(){this.holder.removeEventListener("click",this.handleClick),this.unbindStartEvent(this.holder),this.parent.element.removeChild(this.holder)},o.prototype.setDots=function(){var t=this.parent.slides.length-this.dots.length;t>0?this.addDots(t):t<0&&this.removeDots(-t)},o.prototype.addDots=function(t){for(var e=document.createDocumentFragment(),i=[],n=this.dots.length,o=n+t,r=n;r.5?t.a:t.b);null!=this.fadeHideIndex&&this.fadeHideIndex!=r&&this.fadeHideIndex!=t.a&&(this.fadeHideIndex,t.b);this.fadeHideIndex=r}},o.getFadeIndexes=function(){return this.isDragging||this.didDragEnd?this.options.wrapAround?this.getFadeDragWrapIndexes():this.getFadeDragLimitIndexes():{a:this.fadeIndex,b:this.selectedIndex}},o.getFadeDragWrapIndexes=function(){var t=this.slides.map((function(t,e){return this.getSlideDistance(-this.x,e)}),this),i=t.map((function(t){return Math.abs(t)})),n=Math.min.apply(Math,i),o=i.indexOf(n),r=t[o],s=this.slides.length,a=r>=0?1:-1;return{a:o,b:e.modulo(o+a,s)}},o.getFadeDragLimitIndexes=function(){for(var t=0,e=0;e0&&(r=parseInt(r[1],10))>=1&&r<8&&(i.isOldIOSPhone=!0)}var s=n.match(/Android\s([0-9\.]*)/),a=s?s[1]:0;(a=parseFloat(a))>=1&&(a<4.4&&(i.isOldAndroid=!0),i.androidVersion=a),i.isMobileOpera=/opera mini|opera mobi/i.test(n)}for(var l,c,u=["transform","perspective","animationName"],d=["","webkit","Moz","ms","O"],h=0;h<4;h++){e=d[h];for(var p=0;p<3;p++)l=u[p],c=e+(e?l.charAt(0).toUpperCase()+l.slice(1):l),!i[l]&&c in t&&(i[l]=c);e&&!i.raf&&(e=e.toLowerCase(),i.raf=window[e+"RequestAnimationFrame"],i.raf&&(i.caf=window[e+"CancelAnimationFrame"]||window[e+"CancelRequestAnimationFrame"]))}if(!i.raf){var f=0;i.raf=function(t){var e=(new Date).getTime(),i=Math.max(0,16-(e-f)),n=window.setTimeout((function(){t(e+i)}),i);return f=e+i,n},i.caf=function(t){clearTimeout(t)}}return i.svg=!!document.createElementNS&&!!document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect,o.features=i,i}};o.detectFeatures(),o.features.oldIE&&(o.bind=function(t,e,i,n){e=e.split(" ");for(var o,r=(n?"detach":"attach")+"Event",s=function(){i.handleEvent.call(i)},a=0;ae-1?t-e:t<0?e+t:t},Ct={},Et=function(t,e){return Ct[t]||(Ct[t]=[]),Ct[t].push(e)},Dt=function(t){var e=Ct[t];if(e){var i=Array.prototype.slice.call(arguments);i.shift();for(var n=0;nr.currItem.fitRatio?bt||(Ke(r.currItem,!1,!0),bt=!0):bt&&(Ke(r.currItem),bt=!1)),At(et,dt.x,dt.y,g))},It=function(t){t.container&&At(t.container.style,t.initialPosition.x,t.initialPosition.y,t.initialZoomLevel,t)},kt=function(t,e){e[A]=y+t+"px, 0px"+x},Tt=function(t,e){if(!s.loop&&e){var i=u+(mt.x*pt-t)/mt.x,n=Math.round(t-ue.x);(i<0&&n>0||i>=Ve()-1&&n<0)&&(t=ue.x+n*s.mainScrollEndFriction)}ue.x=t,kt(t,d)},Mt=function(t,e){var i=de[t]-ft[t];return ut[t]+ct[t]+i-i*(e/v)},Lt=function(t,e){t.x=e.x,t.y=e.y,e.id&&(t.id=e.id)},Ft=function(t){t.x=Math.round(t.x),t.y=Math.round(t.y)},Nt=null,Ot=function(){Nt&&(o.unbind(document,"mousemove",Ot),o.addClass(t,"pswp--has_mouse"),s.mouseUsed=!0,Dt("mouseUsed")),Nt=setTimeout((function(){Nt=null}),100)},Ut=function(t,e){var i=Ze(r.currItem,ht,t);return e&&(tt=i),i},Rt=function(t){return t||(t=r.currItem),t.initialZoomLevel},Wt=function(t){return t||(t=r.currItem),t.w>0?s.maxSpreadZoom:1},Vt=function(t,e,i,n){return n===r.currItem.initialZoomLevel?(i[t]=r.currItem.initialPosition[t],!0):(i[t]=Mt(t,n),i[t]>e.min[t]?(i[t]=e.min[t],!0):i[t]=n)return Xt(t),r(i),void(s&&s());r((i-e)*o(a/n)+e),qt[t].raf=k(c)}};c()},$t={shout:Dt,listen:Et,viewportSize:ht,options:s,isMainScrollAnimating:function(){return it},getZoomLevel:function(){return g},getCurrentIndex:function(){return u},isDragging:function(){return q},isZooming:function(){return J},setScrollOffset:function(t,e){ft.x=t,N=ft.y=e,Dt("updateScrollOffset",ft)},applyZoomPan:function(t,e,i,n){dt.x=e,dt.y=i,g=t,_t(n)},init:function(){if(!a&&!l){var i;r.framework=o,r.template=t,r.bg=o.getChildByClass(t,"pswp__bg"),M=t.className,a=!0,O=o.detectFeatures(),k=O.raf,T=O.caf,A=O.transform,F=O.oldIE,r.scrollWrap=o.getChildByClass(t,"pswp__scroll-wrap"),r.container=o.getChildByClass(r.scrollWrap,"pswp__container"),d=r.container.style,r.itemHolders=S=[{el:r.container.children[0],wrap:0,index:-1},{el:r.container.children[1],wrap:0,index:-1},{el:r.container.children[2],wrap:0,index:-1}],S[0].el.style.display=S[2].el.style.display="none",function(){if(A){var e=O.perspective&&!I;return y="translate"+(e?"3d(":"("),void(x=O.perspective?", 0px)":")")}A="left",o.addClass(t,"pswp--ie"),kt=function(t,e){e.left=t+"px"},It=function(t){var e=t.fitRatio>1?1:t.fitRatio,i=t.container.style,n=e*t.w,o=e*t.h;i.width=n+"px",i.height=o+"px",i.left=t.initialPosition.x+"px",i.top=t.initialPosition.y+"px"},_t=function(){if(et){var t=et,e=r.currItem,i=e.fitRatio>1?1:e.fitRatio,n=i*e.w,o=i*e.h;t.width=n+"px",t.height=o+"px",t.left=dt.x+"px",t.top=dt.y+"px"}}}(),m={resize:r.updateSize,orientationchange:function(){clearTimeout(U),U=setTimeout((function(){ht.x!==r.scrollWrap.clientWidth&&r.updateSize()}),500)},scroll:jt,keydown:Ht,click:Bt};var n=O.isOldIOSPhone||O.isOldAndroid||O.isMobileOpera;for(O.animationName&&O.transform&&!n||(s.showAnimationDuration=s.hideAnimationDuration=0),i=0;i=Ve())&&(u=0),r.currItem=We(u),(O.isOldIOSPhone||O.isOldAndroid)&&(vt=!1),t.setAttribute("aria-hidden","false"),s.modal&&(vt?t.style.position="fixed":(t.style.position="absolute",t.style.top=o.getScrollY()+"px")),void 0===N&&(Dt("initialLayout"),N=L=o.getScrollY());var c="pswp--open ";for(s.mainClass&&(c+=s.mainClass+" "),s.showHideOpacity&&(c+="pswp--animate_opacity "),c+=I?"pswp--touch":"pswp--notouch",c+=O.animationName?" pswp--css_animation":"",c+=O.svg?" pswp--svg":"",o.addClass(t,c),r.updateSize(),h=-1,gt=null,i=0;i<3;i++)kt((i+h)*mt.x,S[i].el.style);F||o.bind(r.scrollWrap,f,r),Et("initialZoomInEnd",(function(){r.setContent(S[0],u-1),r.setContent(S[2],u+1),S[0].el.style.display=S[2].el.style.display="block",s.focus&&t.focus(),o.bind(document,"keydown",r),O.transform&&o.bind(r.scrollWrap,"click",r),s.mouseUsed||o.bind(document,"mousemove",Ot),o.bind(window,"resize scroll orientationchange",r),Dt("bindEvents")})),r.setContent(S[1],u),r.updateCurrItem(),Dt("afterInit"),vt||(b=setInterval((function(){Zt||q||J||g!==r.currItem.initialZoomLevel||r.updateSize()}),1e3)),o.addClass(t,"pswp--visible")}},close:function(){a&&(a=!1,l=!0,Dt("close"),o.unbind(window,"resize scroll orientationchange",r),o.unbind(window,"scroll",m.scroll),o.unbind(document,"keydown",r),o.unbind(document,"mousemove",Ot),O.transform&&o.unbind(r.scrollWrap,"click",r),q&&o.unbind(window,p,r),clearTimeout(U),Dt("unbindEvents"),He(r.currItem,null,!0,r.destroy))},destroy:function(){Dt("destroy"),Ne&&clearTimeout(Ne),t.setAttribute("aria-hidden","true"),t.className=M,b&&clearInterval(b),o.unbind(r.scrollWrap,f,r),o.unbind(window,"scroll",r),fe(),Yt(),Ct=null},panTo:function(t,e,i){i||(t>tt.min.x?t=tt.min.x:ttt.min.y?e=tt.min.y:e=3&&(h+=gt+(gt>0?-3:3),i=3);for(var n=0;n0?(e=S.shift(),S[2]=e,h++,kt((h+2)*mt.x,e.el.style),r.setContent(e,u-i+n+1+1)):(e=S.pop(),S.unshift(e),h--,kt(h*mt.x,e.el.style),r.setContent(e,u+i-n-1-1));if(et&&1===Math.abs(gt)){var o=We(C);o.initialZoomLevel!==g&&(Ze(o,ht),Ke(o),It(o))}gt=0,r.updateCurrZoomItem(),C=u,Dt("afterChange")}}},updateSize:function(e){if(!vt&&s.modal){var i=o.getScrollY();if(N!==i&&(t.style.top=i+"px",N=i),!e&&xt.x===window.innerWidth&&xt.y===window.innerHeight)return;xt.x=window.innerWidth,xt.y=window.innerHeight,t.style.height=xt.y+"px"}if(ht.x=r.scrollWrap.clientWidth,ht.y=r.scrollWrap.clientHeight,jt(),mt.x=ht.x+Math.round(ht.x*s.spacing),mt.y=ht.y,Tt(mt.x*pt),Dt("beforeResize"),void 0!==h){for(var n,a,l,c=0;c<3;c++)n=S[c],kt((c+h)*mt.x,n.el.style),l=u+c-1,s.loop&&Ve()>2&&(l=St(l)),(a=We(l))&&(w||a.needsUpdate||!a.bounds)?(r.cleanSlide(a),r.setContent(n,l),1===c&&(r.currItem=a,r.updateCurrZoomItem(!0)),a.needsUpdate=!1):-1===n.index&&l>=0&&r.setContent(n,l),a&&a.container&&(Ze(a,ht),Ke(a),It(a));w=!1}v=g=r.currItem.initialZoomLevel,(tt=r.currItem.bounds)&&(dt.x=tt.center.x,dt.y=tt.center.y,_t(!0)),Dt("resize")},zoomTo:function(t,e,i,n,r){e&&(v=g,de.x=Math.abs(e.x)-dt.x,de.y=Math.abs(e.y)-dt.y,Lt(ut,dt));var s=Ut(t,!1),a={};Vt("x",s,a,t),Vt("y",s,a,t);var l=g,c=dt.x,u=dt.y;Ft(a);var d=function(e){1===e?(g=t,dt.x=a.x,dt.y=a.y):(g=(t-l)*e+l,dt.x=(a.x-c)*e+c,dt.y=(a.y-u)*e+u),r&&r(e),_t(1===e)};i?Kt("customZoomTo",0,1,i,n||o.easing.sine.inOut,d):d(1)}},Jt={},Qt={},te={},ee={},ie={},ne=[],oe={},re=[],se={},ae=0,le={x:0,y:0},ce=0,ue={x:0,y:0},de={x:0,y:0},he={x:0,y:0},pe=function(t,e){return se.x=Math.abs(t.x-e.x),se.y=Math.abs(t.y-e.y),Math.sqrt(se.x*se.x+se.y*se.y)},fe=function(){Y&&(T(Y),Y=null)},me=function(){q&&(Y=k(me),_e())},ge=function(t,e){return!(!t||t===document)&&(!(t.getAttribute("class")&&t.getAttribute("class").indexOf("pswp__scroll-wrap")>-1)&&(e(t)?t:ge(t.parentNode,e)))},ve={},ye=function(t,e){return ve.prevent=!ge(t.target,s.isClickableElement),Dt("preventDragEvent",t,e,ve),ve.prevent},xe=function(t,e){return e.x=t.pageX,e.y=t.pageY,e.id=t.identifier,e},be=function(t,e,i){i.x=.5*(t.x+e.x),i.y=.5*(t.y+e.y)},we=function(){var t=dt.y-r.currItem.initialPosition.y;return 1-Math.abs(t/(ht.y/2))},Se={},Ce={},Ee=[],De=function(t){for(;Ee.length>0;)Ee.pop();return _?(lt=0,ne.forEach((function(t){0===lt?Ee[0]=t:1===lt&&(Ee[1]=t),lt++}))):t.type.indexOf("touch")>-1?t.touches&&t.touches.length>0&&(Ee[0]=xe(t.touches[0],Se),t.touches.length>1&&(Ee[1]=xe(t.touches[1],Ce))):(Se.x=t.pageX,Se.y=t.pageY,Se.id="",Ee[0]=Se),Ee},Pe=function(t,e){var i,n,o,a,l=dt[t]+e[t],c=e[t]>0,u=ue.x+e.x,d=ue.x-oe.x;if(i=l>tt.min[t]||ltt.min[t]&&(i=s.panEndFriction,tt.min[t]-l,n=tt.min[t]-ut[t]),(n<=0||d<0)&&Ve()>1?(a=u,d<0&&u>oe.x&&(a=oe.x)):tt.min.x!==tt.max.x&&(o=l)):(l0)&&Ve()>1?(a=u,d>0&&ur.currItem.fitRatio&&(dt[t]+=e[t]*i)},ze=function(t){if(!("mousedown"===t.type&&t.button>0))if(Re)t.preventDefault();else if(!j||"mousedown"!==t.type){if(ye(t,!0)&&t.preventDefault(),Dt("pointerDown"),_){var e=o.arraySearch(ne,t.pointerId,"id");e<0&&(e=ne.length),ne[e]={x:t.pageX,y:t.pageY,id:t.pointerId}}var i=De(t),n=i.length;$=null,Yt(),q&&1!==n||(q=ot=!0,o.bind(window,p,r),H=at=rt=B=K=G=Z=X=!1,nt=null,Dt("firstTouchStart",i),Lt(ut,dt),ct.x=ct.y=0,Lt(ee,i[0]),Lt(ie,ee),oe.x=mt.x*pt,re=[{x:ee.x,y:ee.y}],W=R=Pt(),Ut(g,!0),fe(),me()),!J&&n>1&&!it&&!K&&(v=g,X=!1,J=Z=!0,ct.y=ct.x=0,Lt(ut,dt),Lt(Jt,i[0]),Lt(Qt,i[1]),be(Jt,Qt,he),de.x=Math.abs(he.x)-dt.x,de.y=Math.abs(he.y)-dt.y,Q=pe(Jt,Qt))}},Ae=function(t){if(t.preventDefault(),_){var e=o.arraySearch(ne,t.pointerId,"id");if(e>-1){var i=ne[e];i.x=t.pageX,i.y=t.pageY}}if(q){var n=De(t);if(nt||G||J)$=n;else if(ue.x!==mt.x*pt)nt="h";else{var r=Math.abs(n[0].x-ee.x)-Math.abs(n[0].y-ee.y);Math.abs(r)>=10&&(nt=r>0?"h":"v",$=n)}}},_e=function(){if($){var t=$.length;if(0!==t)if(Lt(Jt,$[0]),te.x=Jt.x-ee.x,te.y=Jt.y-ee.y,J&&t>1){if(ee.x=Jt.x,ee.y=Jt.y,!te.x&&!te.y&&function(t,e){return t.x===e.x&&t.y===e.y}($[1],Qt))return;Lt(Qt,$[1]),X||(X=!0,Dt("zoomGestureStarted"));var e=pe(Jt,Qt),i=Le(e);i>r.currItem.initialZoomLevel+r.currItem.initialZoomLevel/15&&(at=!0);var n=1,o=Rt(),a=Wt();if(i1&&(n=1),i=o-n*(o/3);else i>a&&((n=(i-a)/(6*o))>1&&(n=1),i=a+n*o);n<0&&(n=0),e,be(Jt,Qt,le),ct.x+=le.x-he.x,ct.y+=le.y-he.y,Lt(he,le),dt.x=Mt("x",i),dt.y=Mt("y",i),H=i>g,g=i,_t()}else{if(!nt)return;if(ot&&(ot=!1,Math.abs(te.x)>=10&&(te.x-=$[0].x-ie.x),Math.abs(te.y)>=10&&(te.y-=$[0].y-ie.y)),ee.x=Jt.x,ee.y=Jt.y,0===te.x&&0===te.y)return;if("v"===nt&&s.closeOnVerticalDrag&&"fit"===s.scaleMode&&g===r.currItem.initialZoomLevel){ct.y+=te.y,dt.y+=te.y;var c=we();return B=!0,Dt("onVerticalDrag",c),zt(c),void _t()}!function(t,e,i){if(t-W>50){var n=re.length>2?re.shift():{};n.x=e,n.y=i,re.push(n),W=t}}(Pt(),Jt.x,Jt.y),G=!0,tt=r.currItem.bounds,Pe("x",te)||(Pe("y",te),Ft(dt),_t())}}},Ie=function(t){if(O.isOldAndroid){if(j&&"mouseup"===t.type)return;t.type.indexOf("touch")>-1&&(clearTimeout(j),j=setTimeout((function(){j=0}),600))}var e;if(Dt("pointerUp"),ye(t,!1)&&t.preventDefault(),_){var i=o.arraySearch(ne,t.pointerId,"id");if(i>-1)if(e=ne.splice(i,1)[0],navigator.msPointerEnabled){e.type={4:"mouse",2:"touch",3:"pen"}[t.pointerType],e.type||(e.type=t.pointerType||"mouse")}else e.type=t.pointerType||"mouse"}var n,a=De(t),l=a.length;if("mouseup"===t.type&&(l=0),2===l)return $=null,!0;1===l&&Lt(ie,a[0]),0!==l||nt||it||(e||("mouseup"===t.type?e={x:t.pageX,y:t.pageY,type:"mouse"}:t.changedTouches&&t.changedTouches[0]&&(e={x:t.changedTouches[0].pageX,y:t.changedTouches[0].pageY,type:"touch"})),Dt("touchRelease",t,e));var c=-1;if(0===l&&(q=!1,o.unbind(window,p,r),fe(),J?c=0:-1!==ce&&(c=Pt()-ce)),ce=1===l?Pt():-1,n=-1!==c&&c<150?"zoom":"swipe",J&&l<2&&(J=!1,1===l&&(n="zoomPointerUp"),Dt("zoomGestureEnded")),$=null,G||X||it||B)if(Yt(),V||(V=ke()),V.calculateSwipeSpeed("x"),B){if(we()r.currItem.fitRatio&&Te(V):Fe())}},ke=function(){var t,e,i={lastFlickOffset:{},lastFlickDist:{},lastFlickSpeed:{},slowDownRatio:{},slowDownRatioReverse:{},speedDecelerationRatio:{},speedDecelerationRatioAbs:{},distanceOffset:{},backAnimDestination:{},backAnimStarted:{},calculateSwipeSpeed:function(n){re.length>1?(t=Pt()-W+50,e=re[re.length-2][n]):(t=Pt()-R,e=ie[n]),i.lastFlickOffset[n]=ee[n]-e,i.lastFlickDist[n]=Math.abs(i.lastFlickOffset[n]),i.lastFlickDist[n]>20?i.lastFlickSpeed[n]=i.lastFlickOffset[n]/t:i.lastFlickSpeed[n]=0,Math.abs(i.lastFlickSpeed[n])<.1&&(i.lastFlickSpeed[n]=0),i.slowDownRatio[n]=.95,i.slowDownRatioReverse[n]=1-i.slowDownRatio[n],i.speedDecelerationRatio[n]=1},calculateOverBoundsAnimOffset:function(t,e){i.backAnimStarted[t]||(dt[t]>tt.min[t]?i.backAnimDestination[t]=tt.min[t]:dt[t]30&&(c||e.lastFlickOffset.x>20)?n=-1:l<-30&&(c||e.lastFlickOffset.x<-20)&&(n=1)}n&&((u+=n)<0?(u=s.loop?Ve()-1:0,a=!0):u>=Ve()&&(u=s.loop?0:Ve()-1,a=!0),a&&!s.loop||(gt+=n,pt-=n,i=!0));var d,h=mt.x*pt,p=Math.abs(h-ue.x);return i||h>ue.x==e.lastFlickSpeed.x>0?(d=Math.abs(e.lastFlickSpeed.x)>0?p/Math.abs(e.lastFlickSpeed.x):333,d=Math.min(d,400),d=Math.max(d,250)):d=333,ae===u&&(i=!1),it=!0,Dt("mainScrollAnimStart"),Kt("mainScroll",ue.x,h,d,o.easing.cubic.out,Tt,(function(){Yt(),it=!1,ae=-1,(i||ae!==u)&&r.updateCurrItem(),Dt("mainScrollAnimComplete")})),i&&r.updateCurrItem(!0),i},Le=function(t){return 1/Q*t*v},Fe=function(){var t=g,e=Rt(),i=Wt();gi&&(t=i);var n,s=st;return rt&&!H&&!at&&g1||navigator.msMaxTouchPoints>1),r.likelyTouchDevice=I,m[E]=ze,m[D]=Ae,m[P]=Ie,z&&(m[z]=m[P]),O.touch&&(f+=" mousedown",p+=" mousemove mouseup",m.mousedown=m[E],m.mousemove=m[D],m.mouseup=m[P]),I||(s.allowPanToNext=!1)}}});var Ne,Oe,Ue,Re,We,Ve,He=function(e,i,n,a){var l;Ne&&clearTimeout(Ne),Re=!0,Ue=!0,e.initialLayout?(l=e.initialLayout,e.initialLayout=null):l=s.getThumbBoundsFn&&s.getThumbBoundsFn(u);var d=n?s.hideAnimationDuration:s.showAnimationDuration,h=function(){Xt("initialZoom"),n?(r.template.removeAttribute("style"),r.bg.removeAttribute("style")):(zt(1),i&&(i.style.display="block"),o.addClass(t,"pswp--animated-in"),Dt("initialZoom"+(n?"OutEnd":"InEnd"))),a&&a(),Re=!1};if(!d||!l||void 0===l.x)return Dt("initialZoom"+(n?"Out":"In")),g=e.initialZoomLevel,Lt(dt,e.initialPosition),_t(),t.style.opacity=n?0:1,zt(1),void(d?setTimeout((function(){h()}),d):h());var p,f;p=c,f=!r.currItem.src||r.currItem.loadError||s.showHideOpacity,e.miniImg&&(e.miniImg.style.webkitBackfaceVisibility="hidden"),n||(g=l.w/e.w,dt.x=l.x,dt.y=l.y-L,r[f?"template":"bg"].style.opacity=.001,_t()),Gt("initialZoom"),n&&!p&&o.removeClass(t,"pswp--animated-in"),f&&(n?o[(p?"remove":"add")+"Class"](t,"pswp--animate_opacity"):setTimeout((function(){o.addClass(t,"pswp--animate_opacity")}),30)),Ne=setTimeout((function(){if(Dt("initialZoom"+(n?"Out":"In")),n){var i=l.w/e.w,r={x:dt.x,y:dt.y},s=g,a=st,c=function(e){1===e?(g=i,dt.x=l.x,dt.y=l.y-N):(g=(i-s)*e+s,dt.x=(l.x-r.x)*e+r.x,dt.y=(l.y-N-r.y)*e+r.y),_t(),f?t.style.opacity=1-e:zt(a-e*a)};p?Kt("initialZoom",0,1,d,o.easing.cubic.out,c,h):(c(1),Ne=setTimeout(h,d+20))}else g=e.initialZoomLevel,Lt(dt,e.initialPosition),_t(),zt(1),f?t.style.opacity=1:zt(1),Ne=setTimeout(h,d+20)}),n?25:90)},Be={},je=[],qe={index:0,errorMsg:'
The image could not be loaded.
',forceProgressiveLoading:!1,preload:[1,1],getNumItemsFn:function(){return Oe.length}},Ze=function(t,e,i){if(t.src&&!t.loadError){var n=!i;if(n&&(t.vGap||(t.vGap={top:0,bottom:0}),Dt("parseVerticalMargin",t)),Be.x=e.x,Be.y=e.y-t.vGap.top-t.vGap.bottom,n){var o=Be.x/t.w,r=Be.y/t.h;t.fitRatio=o1&&(i=1),t.initialZoomLevel=i,t.bounds||(t.bounds={center:{x:0,y:0},max:{x:0,y:0},min:{x:0,y:0}})}if(!i)return;return function(t,e,i){var n=t.bounds;n.center.x=Math.round((Be.x-e)/2),n.center.y=Math.round((Be.y-i)/2)+t.vGap.top,n.max.x=e>Be.x?Math.round(Be.x-e):n.center.x,n.max.y=i>Be.y?Math.round(Be.y-i)+t.vGap.top:n.center.y,n.min.x=e>Be.x?0:n.center.x,n.min.y=i>Be.y?t.vGap.top:n.center.y}(t,t.w*i,t.h*i),n&&i===t.initialZoomLevel&&(t.initialPosition=t.bounds.center),t.bounds}return t.w=t.h=0,t.initialZoomLevel=t.fitRatio=1,t.bounds={center:{x:0,y:0},max:{x:0,y:0},min:{x:0,y:0}},t.initialPosition=t.bounds.center,t.bounds},Xe=function(t,e,i,n,o,s){e.loadError||n&&(e.imageAppended=!0,Ke(e,n,e===r.currItem&&bt),i.appendChild(n),s&&setTimeout((function(){e&&e.loaded&&e.placeholder&&(e.placeholder.style.display="none",e.placeholder=null)}),500))},Ge=function(t){t.loading=!0,t.loaded=!1;var e=t.img=o.createEl("pswp__img","img"),i=function(){t.loading=!1,t.loaded=!0,t.loadComplete?t.loadComplete(t):t.img=null,e.onload=e.onerror=null,e=null};return e.onload=i,e.onerror=function(){t.loadError=!0,i()},e.src=t.src,e},Ye=function(t,e){if(t.src&&t.loadError&&t.container)return e&&(t.container.innerHTML=""),t.container.innerHTML=s.errorMsg.replace("%url%",t.src),!0},Ke=function(t,e,i){if(t.src){e||(e=t.container.lastChild);var n=i?t.w:Math.round(t.w*t.fitRatio),o=i?t.h:Math.round(t.h*t.fitRatio);t.placeholder&&!t.loaded&&(t.placeholder.style.width=n+"px",t.placeholder.style.height=o+"px"),e.style.width=n+"px",e.style.height=o+"px"}},$e=function(){if(je.length){for(var t,e=0;e=0,o=Math.min(i[0],Ve()),a=Math.min(i[1],Ve());for(e=1;e<=(n?a:o);e++)r.lazyLoadItem(u+e);for(e=1;e<=(n?o:a);e++)r.lazyLoadItem(u-e)})),Et("initialLayout",(function(){r.currItem.initialLayout=s.getThumbBoundsFn&&s.getThumbBoundsFn(u)})),Et("mainScrollAnimComplete",$e),Et("initialZoomInEnd",$e),Et("destroy",(function(){for(var t,e=0;e=0&&(void 0!==Oe[t]&&Oe[t])},allowProgressiveImg:function(){return s.forceProgressiveLoading||!I||s.mouseUsed||screen.width>1200},setContent:function(t,e){s.loop&&(e=St(e));var i=r.getItemAt(t.index);i&&(i.container=null);var n,l=r.getItemAt(e);if(l){Dt("gettingData",e,l),t.index=e,t.item=l;var c=l.container=o.createEl("pswp__zoom-wrap");if(!l.src&&l.html&&(l.html.tagName?c.appendChild(l.html):c.innerHTML=l.html),Ye(l),Ze(l,ht),!l.src||l.loadError||l.loaded)l.src&&!l.loadError&&((n=o.createEl("pswp__img","img")).style.opacity=1,n.src=l.src,Ke(l,n),Xe(0,l,c,n));else{if(l.loadComplete=function(i){if(a){if(t&&t.index===e){if(Ye(i,!0))return i.loadComplete=i.img=null,Ze(i,ht),It(i),void(t.index===u&&r.updateCurrZoomItem());i.imageAppended?!Re&&i.placeholder&&(i.placeholder.style.display="none",i.placeholder=null):O.transform&&(it||Re)?je.push({item:i,baseDiv:c,img:i.img,index:e,holder:t,clearPlaceholder:!0}):Xe(0,i,c,i.img,0,!0)}i.loadComplete=null,i.img=null,Dt("imageLoadComplete",e,i)}},o.features.transform){var d="pswp__img pswp__img--placeholder";d+=l.msrc?"":" pswp__img--placeholder--blank";var h=o.createEl(d,l.msrc?"img":"");l.msrc&&(h.src=l.msrc),Ke(l,h),c.appendChild(h),l.placeholder=h}l.loading||Ge(l),r.allowProgressiveImg()&&(!Ue&&O.transform?je.push({item:l,baseDiv:c,img:l.img,index:e,holder:t}):Xe(0,l,c,l.img,0,!0))}Ue||e!==u?It(l):(et=c.style,He(l,n||l.img)),t.el.innerHTML="",t.el.appendChild(c)}else t.el.innerHTML=""},cleanSlide:function(t){t.img&&(t.img.onload=t.img.onerror=null),t.loaded=t.loading=t.img=t.imageAppended=!1}}});var Je,Qe,ti={},ei=function(t,e,i){var n=document.createEvent("CustomEvent"),o={origEvent:t,target:t.target,releasePoint:e,pointerType:i||"touch"};n.initCustomEvent("pswpTap",!0,!0,o),t.target.dispatchEvent(n)};wt("Tap",{publicMethods:{initTap:function(){Et("firstTouchStart",r.onTapStart),Et("touchRelease",r.onTapRelease),Et("destroy",(function(){ti={},Je=null}))},onTapStart:function(t){t.length>1&&(clearTimeout(Je),Je=null)},onTapRelease:function(t,e){var i,n;if(e&&(!G&&!Z&&!Zt)){var r=e;if(Je&&(clearTimeout(Je),Je=null,i=r,n=ti,Math.abs(i.x-n.x)<25&&Math.abs(i.y-n.y)<25))return void Dt("doubleTap",r);if("mouse"===e.type)return void ei(t,e,"mouse");if("BUTTON"===t.target.tagName.toUpperCase()||o.hasClass(t.target,"pswp__single-tap"))return void ei(t,e);Lt(ti,r),Je=setTimeout((function(){ei(t,e),Je=null}),300)}}}}),wt("DesktopZoom",{publicMethods:{initDesktopZoom:function(){F||(I?Et("mouseUsed",(function(){r.setupDesktopZoom()})):r.setupDesktopZoom(!0))},setupDesktopZoom:function(e){Qe={};var i="wheel mousewheel DOMMouseScroll";Et("bindEvents",(function(){o.bind(t,i,r.handleMouseWheel)})),Et("unbindEvents",(function(){Qe&&o.unbind(t,i,r.handleMouseWheel)})),r.mouseZoomedIn=!1;var n,s=function(){r.mouseZoomedIn&&(o.removeClass(t,"pswp--zoomed-in"),r.mouseZoomedIn=!1),g<1?o.addClass(t,"pswp--zoom-allowed"):o.removeClass(t,"pswp--zoom-allowed"),a()},a=function(){n&&(o.removeClass(t,"pswp--dragging"),n=!1)};Et("resize",s),Et("afterChange",s),Et("pointerDown",(function(){r.mouseZoomedIn&&(n=!0,o.addClass(t,"pswp--dragging"))})),Et("pointerUp",a),e||s()},handleMouseWheel:function(t){if(g<=r.currItem.fitRatio)return s.modal&&(!s.closeOnScroll||Zt||q?t.preventDefault():A&&Math.abs(t.deltaY)>2&&(c=!0,r.close())),!0;if(t.stopPropagation(),Qe.x=0,"deltaX"in t)1===t.deltaMode?(Qe.x=18*t.deltaX,Qe.y=18*t.deltaY):(Qe.x=t.deltaX,Qe.y=t.deltaY);else if("wheelDelta"in t)t.wheelDeltaX&&(Qe.x=-.16*t.wheelDeltaX),t.wheelDeltaY?Qe.y=-.16*t.wheelDeltaY:Qe.y=-.16*t.wheelDelta;else{if(!("detail"in t))return;Qe.y=t.detail}Ut(g,!0);var e=dt.x-Qe.x,i=dt.y-Qe.y;(s.modal||e<=tt.min.x&&e>=tt.max.x&&i<=tt.min.y&&i>=tt.max.y)&&t.preventDefault(),r.panTo(e,i)},toggleDesktopZoom:function(e){e=e||{x:ht.x/2+ft.x,y:ht.y/2+ft.y};var i=s.getDoubleTapZoom(!0,r.currItem),n=g===i;r.mouseZoomedIn=!n,r.zoomTo(n?r.currItem.initialZoomLevel:i,e,333),o[(n?"remove":"add")+"Class"](t,"pswp--zoomed-in")}}}),o.extend(r,$t)}})),function(t,e){"function"==typeof define&&define.amd?define(e):"object"==typeof exports?module.exports=e():t.PhotoSwipeUI_Default=e()}(this,(function(){"use strict";return function(t,e){var i,n,o,r,s,a,l,c,u,d,h,p,f,m,g,v,y,x,b=this,w=!1,S=!0,C=!0,E={barsSize:{top:44,bottom:"auto"},closeElClasses:["item","caption","zoom-wrap","ui","top-bar"],timeToIdle:4e3,timeToIdleOutside:1e3,loadingIndicatorDelay:1e3,addCaptionHTMLFn:function(t,e){return t.title?(e.children[0].innerHTML=t.title,!0):(e.children[0].innerHTML="",!1)},closeEl:!0,captionEl:!0,fullscreenEl:!0,zoomEl:!0,shareEl:!0,counterEl:!0,arrowEl:!0,preloaderEl:!0,tapToClose:!1,tapToToggleControls:!0,clickToCloseNonZoomable:!0,shareButtons:[{id:"facebook",label:"Share on Facebook",url:"https://www.facebook.com/sharer/sharer.php?u={{url}}"},{id:"twitter",label:"Tweet",url:"https://twitter.com/intent/tweet?text={{text}}&url={{url}}"},{id:"pinterest",label:"Pin it",url:"http://www.pinterest.com/pin/create/button/?url={{url}}&media={{image_url}}&description={{text}}"},{id:"download",label:"Download image",url:"{{raw_image_url}}",download:!0}],getImageURLForShare:function(){return t.currItem.src||""},getPageURLForShare:function(){return window.location.href},getTextForShare:function(){return t.currItem.title||""},indexIndicatorSep:" / ",fitControlsWidth:1200},D=function(t){if(v)return!0;t=t||window.event,g.timeToIdle&&g.mouseUsed&&!u&&F();for(var i,n,o=(t.target||t.srcElement).getAttribute("class")||"",r=0;r-1&&(i.onTap(),n=!0);if(n){t.stopPropagation&&t.stopPropagation(),v=!0;var s=e.features.isOldAndroid?600:30;setTimeout((function(){v=!1}),s)}},P=function(){return!t.likelyTouchDevice||g.mouseUsed||screen.width>g.fitControlsWidth},z=function(t,i,n){e[(n?"add":"remove")+"Class"](t,"pswp__"+i)},A=function(){var t=1===g.getNumItemsFn();t!==m&&(z(n,"ui--one-slide",t),m=t)},_=function(){z(l,"share-modal--hidden",C)},I=function(){return(C=!C)?(e.removeClass(l,"pswp__share-modal--fade-in"),setTimeout((function(){C&&_()}),300)):(_(),setTimeout((function(){C||e.addClass(l,"pswp__share-modal--fade-in")}),30)),C||T(),!1},k=function(e){var i=(e=e||window.event).target||e.srcElement;return t.shout("shareLinkClick",e,i),!(!i.href||!i.hasAttribute("download")&&(window.open(i.href,"pswp_share","scrollbars=yes,resizable=yes,toolbar=no,location=yes,width=550,height=420,top=100,left="+(window.screen?Math.round(screen.width/2-275):100)),C||I(),1))},T=function(){for(var t,e,i,n,o="",r=0;r