PageSourceSearch

https://www.laoliviakids.com/cdn/shop/t/14/assets/component-produc…?v=113257096557171887411742578152

js laoliviakids.com collected 2026-09-27 12:24:55 UTC 106,043 bytes, 8 lines download raw bytes

vendor: 14,357 bytes, lines 1-4
1(()=>{"use strict";/*!
2  * PhotoSwipe Lightbox 5.4.4 - https://photoswipe.com
3  * (c) 2024 Dmytro Semenov
4  */function createElement(className,tagName,appendToEl){const el=document.createElement(tagName);return className&&(el.className=className),appendToEl&&appendToEl.appendChild(el),el}function toTransformString(x,y,scale){let propValue=`translate3d(${x}px,${y||0}px,0)`;return scale!==void 0&&(propValue+=` scale3d(${scale},${scale},1)`),propValue}function setWidthHeight(el,w,h){el.style.width=typeof w=="number"?`${w}px`:w,el.style.height=typeof h=="number"?`${h}px`:h}const LOAD_STATE={IDLE:"idle",LOADING:"loading",LOADED:"loaded",ERROR:"error"};function specialKeyUsed(e){return"button"in e&&e.button===1||e.ctrlKey||e.metaKey||e.altKey||e.shiftKey}function getElementsFromOption(option,legacySelector,parent=document){let elements=[];if(option instanceof Element)elements=[option];else if(option instanceof NodeList||Array.isArray(option))elements=Array.from(option);else{const selector=typeof option=="string"?option:legacySelector;selector&&(elements=Array.from(parent.querySelectorAll(selector)))}return elements}function isPswpClass(fn){return typeof fn=="function"&&fn.prototype&&fn.prototype.goTo}function isSafari(){return!!(navigator.vendor&&navigator.vendor.match(/apple/i))}class PhotoSwipeEvent{constructor(type,details){this.type=type,this.defaultPrevented=!1,details&&Object.assign(this,details)}preventDefault(){this.defaultPrevented=!0}}class Eventable{constructor(){this._listeners={},this._filters={},this.pswp=void 0,this.options=void 0}addFilter(name,fn,priority=100){var _this$_filters$name,_this$_filters$name2,_this$pswp;this._filters[name]||(this._filters[name]=[]),(_this$_filters$name=this._filters[name])===null||_this$_filters$name===void 0||_this$_filters$name.push({fn,priority}),(_this$_filters$name2=this._filters[name])===null||_this$_filters$name2===void 0||_this$_filters$name2.sort((f1,f2)=>f1.priority-f2.priority),(_this$pswp=this.pswp)===null||_this$pswp===void 0||_this$pswp.addFilter(name,fn,priority)}removeFilter(name,fn){this._filters[name]&&(this._filters[name]=this._filters[name].filter(filter=>filter.fn!==fn)),this.pswp&&this.pswp.removeFilter(name,fn)}applyFilters(name,...args){var _this$_filters$name3;return(_this$_filters$name3=this._filters[name])===null||_this$_filters$name3===void 0||_this$_filters$name3.forEach(filter=>{args[0]=filter.fn.apply(this,args)}),args[0]}on(name,fn){var _this$_listeners$name,_this$pswp2;this._listeners[name]||(this._listeners[name]=[]),(_this$_listeners$name=this._listeners[name])===null||_this$_listeners$name===void 0||_this$_listeners$name.push(fn),(_this$pswp2=this.pswp)===null||_this$pswp2===void 0||_this$pswp2.on(name,fn)}off(name,fn){var _this$pswp3;this._listeners[name]&&(this._listeners[name]=this._listeners[name].filter(listener=>fn!==listener)),(_this$pswp3=this.pswp)===null||_this$pswp3===void 0||_this$pswp3.off(name,fn)}dispatch(name,details){var _this$_listeners$name2;if(this.pswp)return this.pswp.dispatch(name,details);const event=new PhotoSwipeEvent(name,details);return(_this$_listeners$name2=this._listeners[name])===null||_this$_listeners$name2===void 0||_this$_listeners$name2.forEach(listener=>{listener.call(this,event)}),event}}class Placeholder{constructor(imageSrc,container){if(this.element=createElement("pswp__img pswp__img--placeholder",imageSrc?"img":"div",container),imageSrc){const imgEl=this.element;imgEl.decoding="async",imgEl.alt="",imgEl.src=imageSrc,imgEl.setAttribute("role","presentation")}this.element.setAttribute("aria-hidden","true")}setDisplayedSize(width,height){this.element&&(this.element.tagName==="IMG"?(setWidthHeight(this.element,250,"auto"),this.element.style.transformOrigin="0 0",this.element.style.transform=toTransformString(0,0,width/250)):setWidthHeight(this.element,width,height))}destroy(){var _this$element;(_this$element=this.element)!==null&&_this$element!==void 0&&_this$element.parentNode&&this.element.remove(),this.element=null}}class Content{constructor(itemData,instance,index){this.instance=instance,this.data=itemData,this.index=index,this.element=void 0,this.placeholder=void 0,this.slide=void 0,this.displayedImageWidth=0,this.displayedImageHeight=0,this.width=Number(this.data.w)||Number(this.data.width)||0,this.height=Number(this.data.h)||Number(this.data.height)||0,this.isAttached=!1,this.hasSlide=!1,this.isDecoding=!1,this.state=LOAD_STATE.IDLE,this.data.type?this.type=this.data.type:this.data.src?this.type="image":this.type="html",this.instance.dispatch("contentInit",{content:this})}removePlaceholder(){this.placeholder&&!this.keepPlaceholder()&&setTimeout(()=>{this.placeholder&&(this.placeholder.destroy(),this.placeholder=void 0)},1e3)}load(isLazy,reload){if(this.slide&&this.usePlaceholder())if(this.placeholder){const placeholderEl=this.placeholder.element;placeholderEl&&!placeholderEl.parentElement&&this.slide.container.prepend(placeholderEl)}else{const placeholderSrc=this.instance.applyFilters("placeholderSrc",this.data.msrc&&this.slide.isFirstSlide?this.data.msrc:!1,this);this.placeholder=new Placeholder(placeholderSrc,this.slide.container)}this.element&&!reload||this.instance.dispatch("contentLoad",{content:this,isLazy}).defaultPrevented||(this.isImageContent()?(this.element=createElement("pswp__img","img"),this.displayedImageWidth&&this.loadImage(isLazy)):(this.element=createElement("pswp__content","div"),this.element.innerHTML=this.data.html||""),reload&&this.slide&&this.slide.updateContentSize(!0))}loadImage(isLazy){var _this$data$src,_this$data$alt;if(!this.isImageContent()||!this.element||this.instance.dispatch("contentLoadImage",{content:this,isLazy}).defaultPrevented)return;const imageElement=this.element;this.updateSrcsetSizes(),this.data.srcset&&(imageElement.srcset=this.data.srcset),imageElement.src=(_this$data$src=this.data.src)!==null&&_this$data$src!==void 0?_this$data$src:"",imageElement.alt=(_this$data$alt=this.data.alt)!==null&&_this$data$alt!==void 0?_this$data$alt:"",this.state=LOAD_STATE.LOADING,imageElement.complete?this.onLoaded():(imageElement.onload=()=>{this.onLoaded()},imageElement.onerror=()=>{this.onError()})}setSlide(slide){this.slide=slide,this.hasSlide=!0,this.instance=slide.pswp}onLoaded(){this.state=LOAD_STATE.LOADED,this.slide&&this.element&&(this.instance.dispatch("loadComplete",{slide:this.slide,content:this}),this.slide.isActive&&this.slide.heavyAppended&&!this.element.parentNode&&(this.append(),this.slide.updateContentSize(!0)),(this.state===LOAD_STATE.LOADED||this.state===LOAD_STATE.ERROR)&&this.removePlaceholder())}onError(){this.state=LOAD_STATE.ERROR,this.slide&&(this.displayError(),this.instance.dispatch("loadComplete",{slide:this.slide,isError:!0,content:this}),this.instance.dispatch("loadError",{slide:this.slide,content:this}))}isLoading(){return this.instance.applyFilters("isContentLoading",this.state===LOAD_STATE.LOADING,this)}isError(){return this.state===LOAD_STATE.ERROR}isImageContent(){return this.type==="image"}setDisplayedSize(width,height){if(this.element&&(this.placeholder&&this.placeholder.setDisplayedSize(width,height),!this.instance.dispatch("contentResize",{content:this,width,height}).defaultPrevented&&(setWidthHeight(this.element,width,height),this.isImageContent()&&!this.isError()))){const isInitialSizeUpdate=!this.displayedImageWidth&&width;this.displayedImageWidth=width,this.displayedImageHeight=height,isInitialSizeUpdate?this.loadImage(!1):this.updateSrcsetSizes(),this.slide&&this.instance.dispatch("imageSizeChange",{slide:this.slide,width,height,content:this})}}isZoomable(){return this.instance.applyFilters("isContentZoomable",this.isImageContent()&&this.state!==LOAD_STATE.ERROR,this)}updateSrcsetSizes(){if(!this.isImageContent()||!this.element||!this.data.srcset)return;const image=this.element,sizesWidth=this.instance.applyFilters("srcsetSizesWidth",this.displayedImageWidth,this);(!image.dataset.largestUsedSize||sizesWidth>parseInt(image.dataset.largestUsedSize,10))&&(image.sizes=sizesWidth+"px",image.dataset.largestUsedSize=String(sizesWidth))}usePlaceholder(){return this.instance.applyFilters("useContentPlaceholder",this.isImageContent(),this)}lazyLoad(){this.instance.dispatch("contentLazyLoad",{content:this}).defaultPrevented||this.load(!0)}keepPlaceholder(){return this.instance.applyFilters("isKeepingPlaceholder",this.isLoading(),this)}destroy(){this.hasSlide=!1,this.slide=void 0,!this.instance.dispatch("contentDestroy",{content:this}).defaultPrevented&&(this.remove(),this.placeholder&&(this.placeholder.destroy(),this.placeholder=void 0),this.isImageContent()&&this.element&&(this.element.onload=null,this.element.onerror=null,this.element=void 0))}displayError(){if(this.slide){var _this$instance$option,_this$instance$option2;let errorMsgEl=createElement("pswp__error-msg","div");errorMsgEl.innerText=(_this$instance$option=(_this$instance$option2=this.instance.options)===null||_this$instance$option2===void 0?void 0:_this$instance$option2.errorMsg)!==null&&_this$instance$option!==void 0?_this$instance$option:"",errorMsgEl=this.instance.applyFilters("contentErrorElement",errorMsgEl,this),this.element=createElement("pswp__content pswp__error-msg-container","div"),this.element.appendChild(errorMsgEl),this.slide.container.innerText="",this.slide.container.appendChild(this.element),this.slide.updateContentSize(!0),this.removePlaceholder()}}append(){if(this.isAttached||!this.element)return;if(this.isAttached=!0,this.state===LOAD_STATE.ERROR){this.displayError();return}if(this.instance.dispatch("contentAppend",{content:this}).defaultPrevented)return;const supportsDecode="decode"in this.element;this.isImageContent()?supportsDecode&&this.slide&&(!this.slide.isActive||isSafari())?(this.isDecoding=!0,this.element.decode().catch(()=>{}).finally(()=>{this.isDecoding=!1,this.appendImage()})):this.appendImage():this.slide&&!this.element.parentNode&&this.slide.container.appendChild(this.element)}activate(){this.instance.dispatch("contentActivate",{content:this}).defaultPrevented||!this.slide||(this.isImageContent()&&this.isDecoding&&!isSafari()?this.appendImage():this.isError()&&this.load(!1,!0),this.slide.holderElement&&this.slide.holderElement.setAttribute("aria-hidden","false"))}deactivate(){this.instance.dispatch("contentDeactivate",{content:this}),this.slide&&this.slide.holderElement&&this.slide.holderElement.setAttribute("aria-hidden","true")}remove(){this.isAttached=!1,!this.instance.dispatch("contentRemove",{content:this}).defaultPrevented&&(this.element&&this.element.parentNode&&this.element.remove(),this.placeholder&&this.placeholder.element&&this.placeholder.element.remove())}appendImage(){this.isAttached&&(this.instance.dispatch("contentAppendImage",{content:this}).defaultPrevented||(this.slide&&this.element&&!this.element.parentNode&&this.slide.container.appendChild(this.element),(this.state===LOAD_STATE.LOADED||this.state===LOAD_STATE.ERROR)&&this.removePlaceholder()))}}function getViewportSize(options,pswp){if(options.getViewportSizeFn){const newViewportSize=options.getViewportSizeFn(options,pswp);if(newViewportSize)return newViewportSize}return{x:document.documentElement.clientWidth,y:window.innerHeight}}function parsePaddingOption(prop,options,viewportSize,itemData,index){let paddingValue=0;if(options.paddingFn)paddingValue=options.paddingFn(viewportSize,itemData,index)[prop];else if(options.padding)paddingValue=options.padding[prop];else{const legacyPropName="padding"+prop[0].toUpperCase()+prop.slice(1);options[legacyPropName]&&(paddingValue=options[legacyPropName])}return Number(paddingValue)||0}function getPanAreaSize(options,viewportSize,itemData,index){return{x:viewportSize.x-parsePaddingOption("left",options,viewportSize,itemData,index)-parsePaddingOption("right",options,viewportSize,itemData,index),y:viewportSize.y-parsePaddingOption("top",options,viewportSize,itemData,index)-parsePaddingOption("bottom",options,viewportSize,itemData,index)}}const MAX_IMAGE_WIDTH=4e3;class ZoomLevel{constructor(options,itemData,index,pswp){this.pswp=pswp,this.options=options,this.itemData=itemData,this.index=index,this.panAreaSize=null,this.elementSize=null,this.fit=1,this.fill=1,this.vFill=1,this.initial=1,this.secondary=1,this.max=1,this.min=1}update(maxWidth,maxHeight,panAreaSize){const elementSize={x:maxWidth,y:maxHeight};this.elementSize=elementSize,this.panAreaSize=panAreaSize;const hRatio=panAreaSize.x/elementSize.x,vRatio=panAreaSize.y/elementSize.y;this.fit=Math.min(1,hRatio<vRatio?hRatio:vRatio),this.fill=Math.min(1,hRatio>vRatio?hRatio:vRatio),this.vFill=Math.min(1,vRatio),this.initial=this._getInitial(),this.secondary=this._getSecondary(),this.max=Math.max(this.initial,this.secondary,this._getMax()),this.min=Math.min(this.fit,this.initial,this.secondary),this.pswp&&this.pswp.dispatch("zoomLevelsUpdate",{zoomLevels:this,slideData:this.itemData})}_parseZoomLevelOption(optionPrefix){const optionName=optionPrefix+"ZoomLevel",optionValue=this.options[optionName];if(optionValue)return typeof optionValue=="function"?optionValue(this):optionValue==="fill"?this.fill:optionValue==="fit"?this.fit:Number(optionValue)}_getSecondary(){let currZoomLevel=this._parseZoomLevelOption("secondary");return currZoomLevel||(currZoomLevel=Math.min(1,this.fit*3),this.elementSize&&currZoomLevel*this.elementSize.x>MAX_IMAGE_WIDTH&&(currZoomLevel=MAX_IMAGE_WIDTH/this.elementSize.x),currZoomLevel)}_getInitial(){return this._parseZoomLevelOption("initial")||this.fit}_getMax(){return this._parseZoomLevelOption("max")||Math.max(1,this.fit*4)}}function lazyLoadData(itemData,instance,index){const content=instance.createContentFromData(itemData,index);let zoomLevel;const{options}=instance;if(options){zoomLevel=new ZoomLevel(options,itemData,-1);let viewportSize;instance.pswp?viewportSize=instance.pswp.viewportSize:viewportSize=getViewportSize(options,instance);const panAreaSize=getPanAreaSize(options,viewportSize,itemData,index);zoomLevel.update(content.width,content.height,panAreaSize)}return content.lazyLoad(),zoomLevel&&content.setDisplayedSize(Math.ceil(content.width*zoomLevel.initial),Math.ceil(content.height*zoomLevel.initial)),content}function lazyLoadSlide(index,instance){const itemData=instance.getItemData(index);if(!instance.dispatch("lazyLoadSlide",{index,itemData}).defaultPrevented)return lazyLoadData(itemData,instance,index)}
4class PhotoSwipeBase extends Eventable{getNumItems(){var _this$options;let numItems=0;const dataSource=(_this$options=this.options)===null||_this$options===void 0?void 0:_this$options.dataSource;dataSource&&"length"in dataSource?numItems=dataSource.length:dataSource&&"gallery"in dataSource&&(dataSource.items||(dataSource.items=this._getGalleryDOMElements(dataSource.gallery)),dataSource.items&&(numItems=dataSource.items.length));const event=this.dispatch("numItems",{dataSource,numItems});return this.applyFilters("numItems",event.numItems,dataSource)}createContentFromData(slideData,index){return new Content(slideData,this,index)}getItemData(index){var _this$options2;const dataSource=(_this$options2=this.options)===null||_this$options2===void 0?void 0:_this$options2.dataSource;let dataSourceItem={};Array.isArray(dataSource)?dataSourceItem=dataSource[index]:dataSource&&"gallery"in dataSource&&(dataSource.items||(dataSource.items=this._getGalleryDOMElements(dataSource.gallery)),dataSourceItem=dataSource.items[index]);let itemData=dataSourceItem;itemData instanceof Element&&(itemData=this._domElementToItemData(itemData));const event=this.dispatch("itemData",{itemData:itemData||{},index});return this.applyFilters("itemData",event.itemData,index)}_getGalleryDOMElements(galleryElement){var _this$options3,_this$options4;return(_this$options3=this.options)!==null&&_this$options3!==void 0&&_this$options3.children||(_this$options4=this.options)!==null&&_this$options4!==void 0&&_this$options4.childSelector?getElementsFromOption(this.options.children,this.options.childSelector,galleryElement)||[]:[galleryElement]}_domElementToItemData(element){const itemData={element},linkEl=element.tagName==="A"?element:element.querySelector("a");if(linkEl){itemData.src=linkEl.dataset.pswpSrc||linkEl.href,linkEl.dataset.pswpSrcset&&(itemData.srcset=linkEl.dataset.pswpSrcset),itemData.width=linkEl.dataset.pswpWidth?parseInt(linkEl.dataset.pswpWidth,10):0,itemData.height=linkEl.dataset.pswpHeight?parseInt(linkEl.dataset.pswpHeight,10):0,itemData.w=itemData.width,itemData.h=itemData.height,linkEl.dataset.pswpType&&(itemData.type=linkEl.dataset.pswpType);const thumbnailEl=element.querySelector("img");if(thumbnailEl){var _thumbnailEl$getAttri;
vendor: 15,605 bytes, lines 4-7
4itemData.msrc=thumbnailEl.currentSrc||thumbnailEl.src,itemData.alt=(_thumbnailEl$getAttri=thumbnailEl.getAttribute("alt"))!==null&&_thumbnailEl$getAttri!==void 0?_thumbnailEl$getAttri:""}(linkEl.dataset.pswpCropped||linkEl.dataset.cropped)&&(itemData.thumbCropped=!0)}return this.applyFilters("domItemData",itemData,element,linkEl)}lazyLoadData(itemData,index){return lazyLoadData(itemData,this,index)}}class PhotoSwipeLightbox extends PhotoSwipeBase{constructor(options){super(),this.options=options||{},this._uid=0,this.shouldOpen=!1,this._preloadedContent=void 0,this.onThumbnailsClick=this.onThumbnailsClick.bind(this)}init(){getElementsFromOption(this.options.gallery,this.options.gallerySelector).forEach(galleryElement=>{galleryElement.addEventListener("click",this.onThumbnailsClick,!1)})}onThumbnailsClick(e){if(specialKeyUsed(e)||window.pswp)return;let initialPoint={x:e.clientX,y:e.clientY};!initialPoint.x&&!initialPoint.y&&(initialPoint=null);let clickedIndex=this.getClickedIndex(e);clickedIndex=this.applyFilters("clickedIndex",clickedIndex,e,this);const dataSource={gallery:e.currentTarget};clickedIndex>=0&&(e.preventDefault(),this.loadAndOpen(clickedIndex,dataSource,initialPoint))}getClickedIndex(e){if(this.options.getClickedIndexFn)return this.options.getClickedIndexFn.call(this,e);const clickedTarget=e.target,clickedChildIndex=getElementsFromOption(this.options.children,this.options.childSelector,e.currentTarget).findIndex(child=>child===clickedTarget||child.contains(clickedTarget));return clickedChildIndex!==-1?clickedChildIndex:this.options.children||this.options.childSelector?-1:0}loadAndOpen(index,dataSource,initialPoint){if(window.pswp||!this.options)return!1;if(!dataSource&&this.options.gallery&&this.options.children){const galleryElements=getElementsFromOption(this.options.gallery);galleryElements[0]&&(dataSource={gallery:galleryElements[0]})}return this.options.index=index,this.options.initialPointerPos=initialPoint,this.shouldOpen=!0,this.preload(index,dataSource),!0}preload(index,dataSource){const{options}=this;dataSource&&(options.dataSource=dataSource);const promiseArray=[],pswpModuleType=typeof options.pswpModule;if(isPswpClass(options.pswpModule))promiseArray.push(Promise.resolve(options.pswpModule));else{if(pswpModuleType==="string")throw new Error("pswpModule as string is no longer supported");if(pswpModuleType==="function")promiseArray.push(options.pswpModule());else throw new Error("pswpModule is not valid")}typeof options.openPromise=="function"&&promiseArray.push(options.openPromise()),options.preloadFirstSlide!==!1&&index>=0&&(this._preloadedContent=lazyLoadSlide(index,this));const uid=++this._uid;Promise.all(promiseArray).then(iterableModules=>{if(this.shouldOpen){const mainModule=iterableModules[0];this._openPhotoswipe(mainModule,uid)}})}_openPhotoswipe(module,uid){if(uid!==this._uid&&this.shouldOpen||(this.shouldOpen=!1,window.pswp))return;const pswp=typeof module=="object"?new module.default(this.options):new module(this.options);this.pswp=pswp,window.pswp=pswp,Object.keys(this._listeners).forEach(name=>{var _this$_listeners$name;(_this$_listeners$name=this._listeners[name])===null||_this$_listeners$name===void 0||_this$_listeners$name.forEach(fn=>{pswp.on(name,fn)})}),Object.keys(this._filters).forEach(name=>{var _this$_filters$name;(_this$_filters$name=this._filters[name])===null||_this$_filters$name===void 0||_this$_filters$name.forEach(filter=>{pswp.addFilter(name,filter.fn,filter.priority)})}),this._preloadedContent&&(pswp.contentLoader.addToCache(this._preloadedContent),this._preloadedContent=void 0),pswp.on("destroy",()=>{this.pswp=void 0,delete window.pswp}),pswp.init()}destroy(){var _this$pswp;(_this$pswp=this.pswp)===null||_this$pswp===void 0||_this$pswp.destroy(),this.shouldOpen=!1,this._listeners={},getElementsFromOption(this.options.gallery,this.options.gallerySelector).forEach(galleryElement=>{galleryElement.removeEventListener("click",this.onThumbnailsClick,!1)})}}/*!
5  * PhotoSwipe 5.4.4 - https://photoswipe.com
6  * (c) 2024 Dmytro Semenov
7  */function photoswipe_esm_createElement(className,tagName,appendToEl){const el=document.createElement(tagName);return className&&(el.className=className),appendToEl&&appendToEl.appendChild(el),el}function equalizePoints(p1,p2){return p1.x=p2.x,p1.y=p2.y,p2.id!==void 0&&(p1.id=p2.id),p1}function roundPoint(p){p.x=Math.round(p.x),p.y=Math.round(p.y)}function getDistanceBetween(p1,p2){const x=Math.abs(p1.x-p2.x),y=Math.abs(p1.y-p2.y);return Math.sqrt(x*x+y*y)}function pointsEqual(p1,p2){return p1.x===p2.x&&p1.y===p2.y}function clamp(val,min,max){return Math.min(Math.max(val,min),max)}function photoswipe_esm_toTransformString(x,y,scale){let propValue=`translate3d(${x}px,${y||0}px,0)`;return scale!==void 0&&(propValue+=` scale3d(${scale},${scale},1)`),propValue}function setTransform(el,x,y,scale){el.style.transform=photoswipe_esm_toTransformString(x,y,scale)}const defaultCSSEasing="cubic-bezier(.4,0,.22,1)";function setTransitionStyle(el,prop,duration,ease){el.style.transition=prop?`${prop} ${duration}ms ${ease||defaultCSSEasing}`:"none"}function photoswipe_esm_setWidthHeight(el,w,h){el.style.width=typeof w=="number"?`${w}px`:w,el.style.height=typeof h=="number"?`${h}px`:h}function removeTransitionStyle(el){setTransitionStyle(el)}function decodeImage(img){return"decode"in img?img.decode().catch(()=>{}):img.complete?Promise.resolve(img):new Promise((resolve,reject)=>{img.onload=()=>resolve(img),img.onerror=reject})}const photoswipe_esm_LOAD_STATE={IDLE:"idle",LOADING:"loading",LOADED:"loaded",ERROR:"error"};function photoswipe_esm_specialKeyUsed(e){return"button"in e&&e.button===1||e.ctrlKey||e.metaKey||e.altKey||e.shiftKey}function photoswipe_esm_getElementsFromOption(option,legacySelector,parent=document){let elements=[];if(option instanceof Element)elements=[option];else if(option instanceof NodeList||Array.isArray(option))elements=Array.from(option);else{const selector=typeof option=="string"?option:legacySelector;selector&&(elements=Array.from(parent.querySelectorAll(selector)))}return elements}function photoswipe_esm_isSafari(){return!!(navigator.vendor&&navigator.vendor.match(/apple/i))}let supportsPassive=!1;try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>{supportsPassive=!0}}))}catch{}class DOMEvents{constructor(){this._pool=[]}add(target,type,listener,passive){this._toggleListener(target,type,listener,passive)}remove(target,type,listener,passive){this._toggleListener(target,type,listener,passive,!0)}removeAll(){this._pool.forEach(poolItem=>{this._toggleListener(poolItem.target,poolItem.type,poolItem.listener,poolItem.passive,!0,!0)}),this._pool=[]}_toggleListener(target,type,listener,passive,unbind,skipPool){if(!target)return;const methodName=unbind?"removeEventListener":"addEventListener";type.split(" ").forEach(eType=>{if(eType){skipPool||(unbind?this._pool=this._pool.filter(poolItem=>poolItem.type!==eType||poolItem.listener!==listener||poolItem.target!==target):this._pool.push({target,type:eType,listener,passive}));const eventOptions=supportsPassive?{passive:passive||!1}:!1;target[methodName](eType,listener,eventOptions)}})}}function photoswipe_esm_getViewportSize(options,pswp){if(options.getViewportSizeFn){const newViewportSize=options.getViewportSizeFn(options,pswp);if(newViewportSize)return newViewportSize}return{x:document.documentElement.clientWidth,y:window.innerHeight}}function photoswipe_esm_parsePaddingOption(prop,options,viewportSize,itemData,index){let paddingValue=0;if(options.paddingFn)paddingValue=options.paddingFn(viewportSize,itemData,index)[prop];else if(options.padding)paddingValue=options.padding[prop];else{const legacyPropName="padding"+prop[0].toUpperCase()+prop.slice(1);options[legacyPropName]&&(paddingValue=options[legacyPropName])}return Number(paddingValue)||0}function photoswipe_esm_getPanAreaSize(options,viewportSize,itemData,index){return{x:viewportSize.x-photoswipe_esm_parsePaddingOption("left",options,viewportSize,itemData,index)-photoswipe_esm_parsePaddingOption("right",options,viewportSize,itemData,index),y:viewportSize.y-photoswipe_esm_parsePaddingOption("top",options,viewportSize,itemData,index)-photoswipe_esm_parsePaddingOption("bottom",options,viewportSize,itemData,index)}}class PanBounds{constructor(slide){this.slide=slide,this.currZoomLevel=1,this.center={x:0,y:0},this.max={x:0,y:0},this.min={x:0,y:0}}update(currZoomLevel){this.currZoomLevel=currZoomLevel,this.slide.width?(this._updateAxis("x"),this._updateAxis("y"),this.slide.pswp.dispatch("calcBounds",{slide:this.slide})):this.reset()}_updateAxis(axis){const{pswp}=this.slide,elSize=this.slide[axis==="x"?"width":"height"]*this.currZoomLevel,padding=photoswipe_esm_parsePaddingOption(axis==="x"?"left":"top",pswp.options,pswp.viewportSize,this.slide.data,this.slide.index),panAreaSize=this.slide.panAreaSize[axis];this.center[axis]=Math.round((panAreaSize-elSize)/2)+padding,this.max[axis]=elSize>panAreaSize?Math.round(panAreaSize-elSize)+padding:this.center[axis],this.min[axis]=elSize>panAreaSize?padding:this.center[axis]}reset(){this.center.x=0,this.center.y=0,this.max.x=0,this.max.y=0,this.min.x=0,this.min.y=0}correctPan(axis,panOffset){return clamp(panOffset,this.max[axis],this.min[axis])}}const photoswipe_esm_MAX_IMAGE_WIDTH=4e3;class photoswipe_esm_ZoomLevel{constructor(options,itemData,index,pswp){this.pswp=pswp,this.options=options,this.itemData=itemData,this.index=index,this.panAreaSize=null,this.elementSize=null,this.fit=1,this.fill=1,this.vFill=1,this.initial=1,this.secondary=1,this.max=1,this.min=1}update(maxWidth,maxHeight,panAreaSize){const elementSize={x:maxWidth,y:maxHeight};this.elementSize=elementSize,this.panAreaSize=panAreaSize;const hRatio=panAreaSize.x/elementSize.x,vRatio=panAreaSize.y/elementSize.y;this.fit=Math.min(1,hRatio<vRatio?hRatio:vRatio),this.fill=Math.min(1,hRatio>vRatio?hRatio:vRatio),this.vFill=Math.min(1,vRatio),this.initial=this._getInitial(),this.secondary=this._getSecondary(),this.max=Math.max(this.initial,this.secondary,this._getMax()),this.min=Math.min(this.fit,this.initial,this.secondary),this.pswp&&this.pswp.dispatch("zoomLevelsUpdate",{zoomLevels:this,slideData:this.itemData})}_parseZoomLevelOption(optionPrefix){const optionName=optionPrefix+"ZoomLevel",optionValue=this.options[optionName];if(optionValue)return typeof optionValue=="function"?optionValue(this):optionValue==="fill"?this.fill:optionValue==="fit"?this.fit:Number(optionValue)}_getSecondary(){let currZoomLevel=this._parseZoomLevelOption("secondary");return currZoomLevel||(currZoomLevel=Math.min(1,this.fit*3),this.elementSize&&currZoomLevel*this.elementSize.x>photoswipe_esm_MAX_IMAGE_WIDTH&&(currZoomLevel=photoswipe_esm_MAX_IMAGE_WIDTH/this.elementSize.x),currZoomLevel)}_getInitial(){return this._parseZoomLevelOption("initial")||this.fit}_getMax(){return this._parseZoomLevelOption("max")||Math.max(1,this.fit*4)}}class Slide{constructor(data,index,pswp){this.data=data,this.index=index,this.pswp=pswp,this.isActive=index===pswp.currIndex,this.currentResolution=0,this.panAreaSize={x:0,y:0},this.pan={x:0,y:0},this.isFirstSlide=this.isActive&&!pswp.opener.isOpen,this.zoomLevels=new photoswipe_esm_ZoomLevel(pswp.options,data,index,pswp),this.pswp.dispatch("gettingData",{slide:this,data:this.data,index}),this.content=this.pswp.contentLoader.getContentBySlide(this),this.container=photoswipe_esm_createElement("pswp__zoom-wrap","div"),this.holderElement=null,this.currZoomLevel=1,this.width=this.content.width,this.height=this.content.height,this.heavyAppended=!1,this.bounds=new PanBounds(this),this.prevDisplayedWidth=-1,this.prevDisplayedHeight=-1,this.pswp.dispatch("slideInit",{slide:this})}setIsActive(isActive){isActive&&!this.isActive?this.activate():!isActive&&this.isActive&&this.deactivate()}append(holderElement){this.holderElement=holderElement,this.container.style.transformOrigin="0 0",this.data&&(this.calculateSize(),this.load(),this.updateContentSize(),this.appendHeavy(),this.holderElement.appendChild(this.container),this.zoomAndPanToInitial(),this.pswp.dispatch("firstZoomPan",{slide:this}),this.applyCurrentZoomPan(),this.pswp.dispatch("afterSetContent",{slide:this}),this.isActive&&this.activate())}load(){this.content.load(!1),this.pswp.dispatch("slideLoad",{slide:this})}appendHeavy(){const{pswp}=this;this.heavyAppended||!pswp.opener.isOpen||pswp.mainScroll.isShifted()||!this.isActive&&!!0||this.pswp.dispatch("appendHeavy",{slide:this}).defaultPrevented||(this.heavyAppended=!0,this.content.append(),this.pswp.dispatch("appendHeavyContent",{slide:this}))}activate(){this.isActive=!0,this.appendHeavy(),this.content.activate(),this.pswp.dispatch("slideActivate",{slide:this})}deactivate(){this.isActive=!1,this.content.deactivate(),this.currZoomLevel!==this.zoomLevels.initial&&this.calculateSize(),this.currentResolution=0,this.zoomAndPanToInitial(),this.applyCurrentZoomPan(),this.updateContentSize(),this.pswp.dispatch("slideDeactivate",{slide:this})}destroy(){this.content.hasSlide=!1,this.content.remove(),this.container.remove(),this.pswp.dispatch("slideDestroy",{slide:this})}resize(){this.currZoomLevel===this.zoomLevels.initial||!this.isActive?(this.calculateSize(),this.currentResolution=0,this.zoomAndPanToInitial(),this.applyCurrentZoomPan(),this.updateContentSize()):(this.calculateSize(),this.bounds.update(this.currZoomLevel),this.panTo(this.pan.x,this.pan.y))}updateContentSize(force){const scaleMultiplier=this.currentResolution||this.zoomLevels.initial;if(!scaleMultiplier)return;const width=Math.round(this.width*scaleMultiplier)||this.pswp.viewportSize.x,height=Math.round(this.height*scaleMultiplier)||this.pswp.viewportSize.y;!this.sizeChanged(width,height)&&!force||this.content.setDisplayedSize(width,height)}sizeChanged(width,height){return width!==this.prevDisplayedWidth||height!==this.prevDisplayedHeight?(this.prevDisplayedWidth=width,this.prevDisplayedHeight=height,!0):!1}getPlaceholderElement(){var _this$content$placeho;return(_this$content$placeho=this.content.placeholder)===null||_this$content$placeho===void 0?void 0:_this$content$placeho.element}zoomTo(destZoomLevel,centerPoint,transitionDuration,ignoreBounds){const{pswp}=this;if(!this.isZoomable()||pswp.mainScroll.isShifted())return;pswp.dispatch("beforeZoomTo",{destZoomLevel,centerPoint,transitionDuration}),pswp.animations.stopAllPan();const prevZoomLevel=this.currZoomLevel;ignoreBounds||(destZoomLevel=clamp(destZoomLevel,this.zoomLevels.min,this.zoomLevels.max)),this.setZoomLevel(destZoomLevel),this.pan.x=this.calculateZoomToPanOffset("x",centerPoint,prevZoomLevel),this.pan.y=this.calculateZoomToPanOffset("y",centerPoint,prevZoomLevel),roundPoint(this.pan);const finishTransition=()=>{this._setResolution(destZoomLevel),this.applyCurrentZoomPan()};transitionDuration?pswp.animations.startTransition({isPan:!0,name:"zoomTo",target:this.container,transform:this.getCurrentTransform(),onComplete:finishTransition,duration:transitionDuration,easing:pswp.options.easing}):finishTransition()}toggleZoom(centerPoint){this.zoomTo(this.currZoomLevel===this.zoomLevels.initial?this.zoomLevels.secondary:this.zoomLevels.initial,centerPoint,this.pswp.options.zoomAnimationDuration)}setZoomLevel(currZoomLevel){this.currZoomLevel=currZoomLevel,this.bounds.update(this.currZoomLevel)}calculateZoomToPanOffset(axis,point,prevZoomLevel){if(this.bounds.max[axis]-this.bounds.min[axis]===0)return this.bounds.center[axis];point||(point=this.pswp.getViewportCenterPoint()),prevZoomLevel||(prevZoomLevel=this.zoomLevels.initial);const zoomFactor=this.currZoomLevel/prevZoomLevel;
7return this.bounds.correctPan(axis,(this.pan[axis]-point[axis])*zoomFactor+point[axis])}panTo(panX,panY){this.pan.x=this.bounds.correctPan("x",panX),this.pan.y=this.bounds.correctPan("y",panY),this.applyCurrentZoomPan()}isPannable(){return!!this.width&&this.currZoomLevel>this.zoomLevels.fit}isZoomable(){return!!this.width&&this.content.isZoomable()}applyCurrentZoomPan(){this._applyZoomTransform(this.pan.x,this.pan.y,this.currZoomLevel),this===this.pswp.currSlide&&this.pswp.dispatch("zoomPanUpdate",{slide:this})}zoomAndPanToInitial(){this.currZoomLevel=this.zoomLevels.initial,this.bounds.update(this.currZoomLevel),equalizePoints(this.pan,this.bounds.center),this.pswp.dispatch("initialZoomPan",{slide:this})}_applyZoomTransform(x,y,zoom){zoom/=this.currentResolution||this.zoomLevels.initial,setTransform(this.container,x,y,zoom)}calculateSize(){const{pswp}=this;equalizePoints(this.panAreaSize,photoswipe_esm_getPanAreaSize(pswp.options,pswp.viewportSize,this.data,this.index)),this.zoomLevels.update(this.width,this.height,this.panAreaSize),pswp.dispatch("calcSlideSize",{slide:this})}getCurrentTransform(){const scale=this.currZoomLevel/(this.currentResolution||this.zoomLevels.initial);return photoswipe_esm_toTransformString(this.pan.x,this.pan.y,scale)}_setResolution(newResolution){newResolution!==this.currentResolution&&(this.currentResolution=newResolution,this.updateContentSize(),this.pswp.dispatch("resolutionChanged"))}}const PAN_END_FRICTION=.35,VERTICAL_DRAG_FRICTION=.6,MIN_RATIO_TO_CLOSE=.4,MIN_NEXT_SLIDE_SPEED=.5;function project(initialVelocity,decelerationRate){return initialVelocity*decelerationRate/(1-decelerationRate)}class DragHandler{constructor(gestures){this.gestures=gestures,this.pswp=gestures.pswp,this.startPan={x:0,y:0}}start(){this.pswp.currSlide&&equalizePoints(this.startPan,this.pswp.currSlide.pan),this.pswp.animations.stopAll()}change(){const{p1,prevP1,dragAxis}=this.gestures,{currSlide}=this.pswp;if(dragAxis==="y"&&this.pswp.options.closeOnVerticalDrag&&currSlide&&currSlide.currZoomLevel<=currSlide.zoomLevels.fit&&!this.gestures.isMultitouch){const panY=currSlide.pan.y+(p1.y-prevP1.y);if(!this.pswp.dispatch("verticalDrag",{panY}).defaultPrevented){this._setPanWithFriction("y",panY,VERTICAL_DRAG_FRICTION);const bgOpacity=1-Math.abs(this._getVerticalDragRatio(currSlide.pan.y));this.pswp.applyBgOpacity(bgOpacity),currSlide.applyCurrentZoomPan()}}else this._panOrMoveMainScroll("x")||(this._panOrMoveMainScroll("y"),currSlide&&(roundPoint(currSlide.pan),currSlide.applyCurrentZoomPan()))}end(){const{velocity}=this.gestures,{mainScroll,currSlide}=this.pswp;let indexDiff=0;if(this.pswp.animations.stopAll(),mainScroll.isShifted()){const currentSlideVisibilityRatio=(mainScroll.x-mainScroll.getCurrSlideX())/this.pswp.viewportSize.x;velocity.x<-MIN_NEXT_SLIDE_SPEED&&currentSlideVisibilityRatio<0||velocity.x<.1&&currentSlideVisibilityRatio<-.5?(indexDiff=1,velocity.x=Math.min(velocity.x,0)):(velocity.x>MIN_NEXT_SLIDE_SPEED&&currentSlideVisibilityRatio>0||velocity.x>-.1&&currentSlideVisibilityRatio>.5)&&(indexDiff=-1,velocity.x=Math.max(velocity.x,0)),mainScroll.moveIndexBy(indexDiff,!0,velocity.x)}currSlide&&currSlide.currZoomLevel>currSlide.zoomLevels.max||this.gestures.isMultitouch?this.gestures.zoomLevels.correctZoomPan(!0):(this._finishPanGestureForAxis("x"),this._finishPanGestureForAxis("y"))}_finishPanGestureForAxis(axis){const{velocity}=this.gestures,{currSlide}=this.pswp;if(!currSlide)return;const{pan,bounds}=currSlide,panPos=pan[axis],restoreBgOpacity=this.pswp.bgOpacity<1&&axis==="y",projectedPosition=panPos+project(velocity[axis],.995);if(restoreBgOpacity){const vDragRatio=this._getVerticalDragRatio(panPos),projectedVDragRatio=this._getVerticalDragRatio(projectedPosition);if(vDragRatio<0&&projectedVDragRatio<-MIN_RATIO_TO_CLOSE||vDragRatio>0&&projectedVDragRatio>MIN_RATIO_TO_CLOSE){this.pswp.close();return}}const correctedPanPosition=bounds.correctPan(axis,projectedPosition);if(panPos===correctedPanPosition)return;const dampingRatio=correctedPanPosition===projectedPosition?1:.82,initialBgOpacity=this.pswp.bgOpacity,totalPanDist=correctedPanPosition-panPos;this.pswp.animations.startSpring({name:"panGesture"+axis,isPan:!0,start:panPos,end:correctedPanPosition,velocity:velocity[axis],dampingRatio,onUp
7date:pos=>{if(restoreBgOpacity&&this.pswp.bgOpacity<1){const animationProgressRatio=1-(correctedPanPosition-pos)/totalPanDist;this.pswp.applyBgOpacity(clamp(initialBgOpacity+(1-initialBgOpacity)*animationProgressRatio,0,1))}pan[axis]=Math.floor(pos),currSlide.applyCurrentZoomPan()}})}_panOrMoveMainScroll(axis){const{p1,dragAxis,prevP1,isMultitouch}=this.gestures,{currSlide,mainScroll}=this.pswp,delta=p1[axis]-prevP1[axis],newMainScrollX=mainScroll.x+delta;if(!delta||!currSlide)return!1;if(axis==="x"&&!currSlide.isPannable()&&!isMultitouch)return mainScroll.moveTo(newMainScrollX,!0),!0;const{bounds}=currSlide,newPan=currSlide.pan[axis]+delta;if(this.pswp.options.allowPanToNext&&dragAxis==="x"&&axis==="x"&&!isMultitouch){const currSlideMainScrollX=mainScroll.getCurrSlideX(),mainScrollShiftDiff=mainScroll.x-currSlideMainScrollX,isLeftToRight=delta>0,isRightToLeft=!isLeftToRight;if(newPan>bounds.min[axis]&&isLeftToRight){if(bounds.min[axis]<=this.startPan[axis])return mainScroll.moveTo(newMainScrollX,!0),!0;this._setPanWithFriction(axis,newPan)}else if(newPan<bounds.max[axis]&&isRightToLeft){if(this.startPan[axis]<=bounds.max[axis])return mainScroll.moveTo(newMainScrollX,!0),!0;this._setPanWithFriction(axis,newPan)}else if(mainScrollShiftDiff!==0){if(mainScrollShiftDiff>0)return mainScroll.moveTo(Math.max(newMainScrollX,currSlideMainScrollX),!0),!0;if(mainScrollShiftDiff<0)return mainScroll.moveTo(Math.min(newMainScrollX,currSlideMainScrollX),!0),!0}else this._setPanWithFriction(axis,newPan)}else axis==="y"?!mainScroll.isShifted()&&bounds.min.y!==bounds.max.y&&this._setPanWithFriction(axis,newPan):this._setPanWithFriction(axis,newPan);return!1}_getVerticalDragRatio(panY){var _this$pswp$currSlide$,_this$pswp$currSlide;return(panY-((_this$pswp$currSlide$=(_this$pswp$currSlide=this.pswp.currSlide)===null||_this$pswp$currSlide===void 0?void 0:_this$pswp$currSlide.bounds.center.y)!==null&&_this$pswp$currSlide$!==void 0?_this$pswp$currSlide$:0))/(this.pswp.viewportSize.y/3)}_setPanWithFriction(axis,potentialPan,customFriction){const{currSlide}=this.pswp;if(!currSlide)return;const{pan,bounds}=currSlide;if(bounds.correctPan(axis,potentialPan)!==potentialPan||customFriction){const delta=Math.round(potentialPan-pan[axis]);pan[axis]+=delta*(customFriction||PAN_END_FRICTION)}else pan[axis]=potentialPan}}const UPPER_ZOOM_FRICTION=.05,LOWER_ZOOM_FRICTION=.15;function getZoomPointsCenter(p,p1,p2){return p.x=(p1.x+p2.x)/2,p.y=(p1.y+p2.y)/2,p}class ZoomHandler{constructor(gestures){this.gestures=gestures,this._startPan={x:0,y:0},this._startZoomPoint={x:0,y:0},this._zoomPoint={x:0,y:0},this._wasOverFitZoomLevel=!1,this._startZoomLevel=1}start(){const{currSlide}=this.gestures.pswp;currSlide&&(this._startZoomLevel=currSlide.currZoomLevel,equalizePoints(this._startPan,currSlide.pan)),this.gestures.pswp.animations.stopAllPan(),this._wasOverFitZoomLevel=!1}change(){const{p1,startP1,p2,startP2,pswp}=this.gestures,{currSlide}=pswp;if(!currSlide)return;const minZoomLevel=currSlide.zoomLevels.min,maxZoomLevel=currSlide.zoomLevels.max;if(!currSlide.isZoomable()||pswp.mainScroll.isShifted())return;getZoomPointsCenter(this._startZoomPoint,startP1,startP2),getZoomPointsCenter(this._zoomPoint,p1,p2);let currZoomLevel=1/getDistanceBetween(startP1,startP2)*getDistanceBetween(p1,p2)*this._startZoomLevel;if(currZoomLevel>currSlide.zoomLevels.initial+currSlide.zoomLevels.initial/15&&(this._wasOverFitZoomLevel=!0),currZoomLevel<minZoomLevel)if(pswp.options.pinchToClose&&!this._wasOverFitZoomLevel&&this._startZoomLevel<=currSlide.zoomLevels.initial){const bgOpacity=1-(minZoomLevel-currZoomLevel)/(minZoomLevel/1.2);pswp.dispatch("pinchClose",{bgOpacity}).defaultPrevented||pswp.applyBgOpacity(bgOpacity)}else currZoomLevel=minZoomLevel-(minZoomLevel-currZoomLevel)*LOWER_ZOOM_FRICTION;else currZoomLevel>maxZoomLevel&&(currZoomLevel=maxZoomLevel+(currZoomLevel-maxZoomLevel)*UPPER_ZOOM_FRICTION);currSlide.pan.x=this._calculatePanForZoomLevel("x",currZoomLevel),currSlide.pan.y=this._calculatePanForZoomLevel("y",currZoomLevel),currSlide.setZoomLevel(currZoomLevel),currSlide.applyCurrentZoomPan()}end(){const{pswp}=this.gestures,{currSlide}=pswp;(!currSlide||currSlide.currZoomLevel<currSlide.zoomLevels.initial)&&!this._wasOverFitZoomLevel&&pswp.options.pinchToClose?pswp.close():this.correctZoomPan()}_calculatePanForZoomLevel(axis,currZoomLevel){const zoomFactor=currZoomLevel/this._startZoomLevel;return this._zoomPoint[axis]-(this._startZoomPoint[axis]-this._startPan[axis])*zoomFactor}correctZoomPan(ignoreGesture){const{pswp}=this.gestures,{currSlide}=pswp;if(!(currSlide!=null&&currSlide.isZoomable()))return;this._zoomPoint.x===0&&(ignoreGesture=!0);const prevZoomLevel=currSlide.currZoomLevel;let destinationZoomLevel,currZoomLevelNeedsChange=!0;prevZoomLevel<currSlide.zoomLevels.initial?destinationZoomLevel=currSlide.zoomLevels.initial:prevZoomLevel>currSlide.zoomLevels.max?destinationZoomLevel=currSlide.zoomLevels.max:(currZoomLevelNeedsChange=!1,destinationZoomLevel=prevZoomLevel);const initialBgOpacity=pswp.bgOpacity,restoreBgOpacity=pswp.bgOpacity<1,initialPan=equalizePoints({x:0,y:0},currSlide.pan);let destinationPan=equalizePoints({x:0,y:0},initialPan);ignoreGesture&&(this._zoomPoint.x=0,this._zoomPoint.y=0,this._startZoomPoint.x=0,this._startZoomPoint.y=0,this._startZoomLevel=prevZoomLevel,equalizePoints(this._startPan,initialPan)),currZoomLevelNeedsChange&&(destinationPan={x:this._calculatePanForZoomLevel("x",destinationZoomLevel),y:this._calculatePanForZoomLevel("y",destinationZoomLevel)}),currSlide.setZoomLevel(destinationZoomLevel),destinationPan={x:currSlide.bounds.correctPan("x",destinationPan.x),y:curr
vendor: 18,002 bytes, line 7
7Slide.bounds.correctPan("y",destinationPan.y)},currSlide.setZoomLevel(prevZoomLevel);const panNeedsChange=!pointsEqual(destinationPan,initialPan);if(!panNeedsChange&&!currZoomLevelNeedsChange&&!restoreBgOpacity){currSlide._setResolution(destinationZoomLevel),currSlide.applyCurrentZoomPan();return}pswp.animations.stopAllPan(),pswp.animations.startSpring({isPan:!0,start:0,end:1e3,velocity:0,dampingRatio:1,naturalFrequency:40,onUpdate:now=>{if(now/=1e3,panNeedsChange||currZoomLevelNeedsChange){if(panNeedsChange&&(currSlide.pan.x=initialPan.x+(destinationPan.x-initialPan.x)*now,currSlide.pan.y=initialPan.y+(destinationPan.y-initialPan.y)*now),currZoomLevelNeedsChange){const newZoomLevel=prevZoomLevel+(destinationZoomLevel-prevZoomLevel)*now;currSlide.setZoomLevel(newZoomLevel)}currSlide.applyCurrentZoomPan()}restoreBgOpacity&&pswp.bgOpacity<1&&pswp.applyBgOpacity(clamp(initialBgOpacity+(1-initialBgOpacity)*now,0,1))},onComplete:()=>{currSlide._setResolution(destinationZoomLevel),currSlide.applyCurrentZoomPan()}})}}function didTapOnMainContent(event){return!!event.target.closest(".pswp__container")}class TapHandler{constructor(gestures){this.gestures=gestures}click(point,originalEvent){const targetClassList=originalEvent.target.classList,isImageClick=targetClassList.contains("pswp__img"),isBackgroundClick=targetClassList.contains("pswp__item")||targetClassList.contains("pswp__zoom-wrap");isImageClick?this._doClickOrTapAction("imageClick",point,originalEvent):isBackgroundClick&&this._doClickOrTapAction("bgClick",point,originalEvent)}tap(point,originalEvent){didTapOnMainContent(originalEvent)&&this._doClickOrTapAction("tap",point,originalEvent)}doubleTap(point,originalEvent){didTapOnMainContent(originalEvent)&&this._doClickOrTapAction("doubleTap",point,originalEvent)}_doClickOrTapAction(actionName,point,originalEvent){var _this$gestures$pswp$e;const{pswp}=this.gestures,{currSlide}=pswp,actionFullName=actionName+"Action",optionValue=pswp.options[actionFullName];if(!pswp.dispatch(actionFullName,{point,originalEvent}).defaultPrevented){if(typeof optionValue=="function"){optionValue.call(pswp,point,originalEvent);return}switch(optionValue){case"close":case"next":pswp[optionValue]();break;case"zoom":currSlide?.toggleZoom(point);break;case"zoom-or-close":currSlide!=null&&currSlide.isZoomable()&&currSlide.zoomLevels.secondary!==currSlide.zoomLevels.initial?currSlide.toggleZoom(point):pswp.options.clickToCloseNonZoomable&&pswp.close();break;case"toggle-controls":(_this$gestures$pswp$e=this.gestures.pswp.element)===null||_this$gestures$pswp$e===void 0||_this$gestures$pswp$e.classList.toggle("pswp--ui-visible");break}}}}const AXIS_SWIPE_HYSTERISIS=10,DOUBLE_TAP_DELAY=300,MIN_TAP_DISTANCE=25;class Gestures{constructor(pswp){this.pswp=pswp,this.dragAxis=null,this.p1={x:0,y:0},this.p2={x:0,y:0},this.prevP1={x:0,y:0},this.prevP2={x:0,y:0},this.startP1={x:0,y:0},this.startP2={x:0,y:0},this.velocity={x:0,y:0},this._lastStartP1={x:0,y:0},this._intervalP1={x:0,y:0},this._numActivePoints=0,this._ongoingPointers=[],this._touchEventEnabled="ontouchstart"in window,this._pointerEventEnabled=!!window.PointerEvent,this.supportsTouch=this._touchEventEnabled||this._pointerEventEnabled&&navigator.maxTouchPoints>1,this._numActivePoints=0,this._intervalTime=0,this._velocityCalculated=!1,this.isMultitouch=!1,this.isDragging=!1,this.isZooming=!1,this.raf=null,this._tapTimer=null,this.supportsTouch||(pswp.options.allowPanToNext=!1),this.drag=new DragHandler(this),this.zoomLevels=new ZoomHandler(this),this.tapHandler=new TapHandler(this),pswp.on("bindEvents",()=>{pswp.events.add(pswp.scrollWrap,"click",this._onClick.bind(this)),this._pointerEventEnabled?this._bindEvents("pointer","down","up","cancel"):this._touchEventEnabled?(this._bindEvents("touch","start","end","cancel"),pswp.scrollWrap&&(pswp.scrollWrap.ontouchmove=()=>{},pswp.scrollWrap.ontouchend=()=>{})):this._bindEvents("mouse","down","up")})}_bindEvents(pref,down,up,cancel){const{pswp}=this,{events}=pswp,cancelEvent=cancel?pref+cancel:"";events.add(pswp.scrollWrap,pref+down,this.onPointerDown.bind(this)),events.add(window,pref+"move",this.onPointerMove.bind(this)),events.add(window,pref+up,this.onPointerUp.bind(this)),cancelEvent&&events.add(pswp.scrollWrap,cancelEvent,this.onPointerUp.bind(this))}onPointerDown(e){const isMousePointer=e.type==="mousedown"||e.pointerType==="mouse";if(isMousePointer&&e.button>0)return;const{pswp}=this;if(!pswp.opener.isOpen){e.preventDefault();return}pswp.dispatch("pointerDown",{originalEvent:e}).defaultPrevented||(isMousePointer&&(pswp.mouseDetected(),this._preventPointerEventBehaviour(e,"down")),pswp.animations.stopAll(),this._updatePoints(e,"down"),this._numActivePoints===1&&(this.dragAxis=null,equalizePoints(this.startP1,this.p1)),this._numActivePoints>1?(this._clearTapTimer(),this.isMultitouch=!0):this.isMultitouch=!1)}onPointerMove(e){this._preventPointerEventBehaviour(e,"move"),this._numActivePoints&&(this._updatePoints(e,"move"),!this.pswp.dispatch("pointerMove",{originalEvent:e}).defaultPrevented&&(this._numActivePoints===1&&!this.isDragging?(this.dragAxis||this._calculateDragDirection(),this.dragAxis&&!this.isDragging&&(this.isZooming&&(this.isZooming=!1,this.zoomLevels.end()),this.isDragging=!0,this._clearTapTimer(),this._updateStartPoints(),this._intervalTime=Date.now(),this._velocityCalculated=!1,equalizePoints(this._intervalP1,this.p1),this.velocity.x=0,this.velocity.y=0,this.drag.start(),this._rafStopLoop(),this._rafRenderLoop())):this._numActivePoints>1&&!this.isZooming&&(this._finishDrag(),this.isZooming=!0,this._updateStartPoints(),this.zoomLevels.start(),this._rafStopLoop(),this._rafRenderLoop())))}_finishDrag(){this.isDragging&&(this.isDragging=!1,this._velocityCalculated||this._updateVelocity(!0),this.drag.end(),this.dragAxis=null)}onPointerUp(e){this._numActivePoints&&(this._updatePoints(e,"up"),!this.pswp.dispatch("pointerUp",{originalEvent:e}).defaultPrevented&&(this._numActivePoints===0&&(this._rafStopLoop(),this.isDragging?this._finishDrag():!this.isZooming&&!this.isMultitouch&&this._finishTap(e)),this._numActivePoints<2&&this.isZooming&&(this.isZooming=!1,this.zoomLevels.end(),this._numActivePoints===1&&(this.dragAxis=null,this._updateStartPoints()))))}_rafRenderLoop(){(this.isDragging||this.isZooming)&&(this._updateVelocity(),this.isDragging?pointsEqual(this.p1,this.prevP1)||this.drag.change():(!pointsEqual(this.p1,this.prevP1)||!pointsEqual(this.p2,this.prevP2))&&this.zoomLevels.change(),this._updatePrevPoints(),this.raf=requestAnimationFrame(this._rafRenderLoop.bind(this)))}_updateVelocity(force){const time=Date.now(),duration=time-this._intervalTime;duration<50&&!force||(this.velocity.x=this._getVelocity("x",duration),this.velocity.y=this._getVelocity("y",duration),this._intervalTime=time,equalizePoints(this._intervalP1,this.p1),this._velocityCalculated=!0)}_finishTap(e){const{mainScroll}=this.pswp;if(mainScroll.isShifted()){mainScroll.moveIndexBy(0,!0);return}if(e.type.indexOf("cancel")>0)return;if(e.type==="mouseup"||e.pointerType==="mouse"){this.tapHandler.click(this.startP1,e);return}const tapDelay=this.pswp.options.doubleTapAction?DOUBLE_TAP_DELAY:0;this._tapTimer?(this._clearTapTimer(),getDistanceBetween(this._lastStartP1,this.startP1)<MIN_TAP_DISTANCE&&this.tapHandler.doubleTap(this.startP1,e)):(equalizePoints(this._lastStartP1,this.startP1),this._tapTimer=setTimeout(()=>{this.tapHandler.tap(this.startP1,e),this._clearTapTimer()},tapDelay))}_clearTapTimer(){this._tapTimer&&(clearTimeout(this._tapTimer),this._tapTimer=null)}_getVelocity(axis,duration){const displacement=this.p1[axis]-this._intervalP1[axis];return Math.abs(displacement)>1&&duration>5?displacement/duration:0}_rafStopLoop(){this.raf&&(cancelAnimationFrame(this.raf),this.raf=null)}_preventPointerEventBehaviour(e,pointerType){this.pswp.applyFilters("preventPointerEvent",!0,e,pointerType)&&e.preventDefault()}_updatePoints(e,pointerType){if(this._pointerEventEnabled){const pointerEvent=e,pointerIndex=this._ongoingPointers.findIndex(ongoingPointer=>ongoingPointer.id===pointerEvent.pointerId);pointerType==="up"&&pointerIndex>-1?this._ongoingPointers.splice(pointerIndex,1):pointerType==="down"&&pointerIndex===-1?this._ongoingPointers.push(this._convertEventPosToPoint(pointerEvent,{x:0,y:0})):pointerIndex>-1&&this._convertEventPosToPoint(pointerEvent,this._ongoingPointers[pointerIndex]),this._numActivePoints=this._ongoingPointers.length,this._numActivePoints>0&&equalizePoints(this.p1,this._ongoingPointers[0]),this._numActivePoints>1&&equalizePoints(this.p2,this._ongoingPointers[1])}else{const touchEvent=e;this._numActivePoints=0,touchEvent.type.indexOf("touch")>-1?touchEvent.touches&&touchEvent.touches.length>0&&(this._convertEventPosToPoint(touchEvent.touches[0],this.p1),this._numActivePoints++,touchEvent.touches.length>1&&(this._convertEventPosToPoint(touchEvent.touches[1],this.p2),this._numActivePoints++)):(this._convertEventPosToPoint(e,this.p1),pointerType==="up"?this._numActivePoints=0:this._numActivePoints++)}}_updatePrevPoints(){equalizePoints(this.prevP1,this.p1),equalizePoints(this.prevP2,this.p2)}_updateStartPoints(){equalizePoints(this.startP1,this.p1),equalizePoints(this.startP2,this.p2),this._updatePrevPoints()}_calculateDragDirection(){if(this.pswp.mainScroll.isShifted())this.dragAxis="x";else{const diff=Math.abs(this.p1.x-this.startP1.x)-Math.abs(this.p1.y-this.startP1.y);if(diff!==0){const axisToCheck=diff>0?"x":"y";Math.abs(this.p1[axisToCheck]-this.startP1[axisToCheck])>=AXIS_SWIPE_HYSTERISIS&&(this.dragAxis=axisToCheck)}}}_convertEventPosToPoint(e,p){return p.x=e.pageX-this.pswp.offset.x,p.y=e.pageY-this.pswp.offset.y,"pointerId"in e?p.id=e.pointerId:e.identifier!==void 0&&(p.id=e.identifier),p}_onClick(e){this.pswp.mainScroll.isShifted()&&(e.preventDefault(),e.stopPropagation())}}const MAIN_SCROLL_END_FRICTION=.35;class MainScroll{constructor(pswp){this.pswp=pswp,this.x=0,this.slideWidth=0,this._currPositionIndex=0,this._prevPositionIndex=0,this._containerShiftIndex=-1,this.itemHolders=[]}resize(resizeSlides){const{pswp}=this,newSlideWidth=Math.round(pswp.viewportSize.x+pswp.viewportSize.x*pswp.options.spacing),slideWidthChanged=newSlideWidth!==this.slideWidth;slideWidthChanged&&(this.slideWidth=newSlideWidth,this.moveTo(this.getCurrSlideX())),this.itemHolders.forEach((itemHolder,index)=>{slideWidthChanged&&setTransform(itemHolder.el,(index+this._containerShiftIndex)*this.slideWidth),resizeSlides&&itemHolder.slide&&itemHolder.slide.resize()})}resetPosition(){this._currPositionIndex=0,this._prevPositionIndex=0,this.slideWidth=0,this._containerShiftIndex=-1}appendHolders(){this.itemHolders=[];for(let i=0;i<3;i++){const el=photoswipe_esm_createElement("pswp__item","div",this.pswp.container);el.setAttribute("role","group"),el.setAttribute("aria-roledescription","slide"),el.setAttribute("aria-hidden","true"),el.style.display=i===1?"block":"none",this.itemHolders.push({el})}}canBeSwiped(){return this.pswp.getNumItems()>1}moveIndexBy(diff,animate,velocityX){const{pswp}=this;let newIndex=pswp.potentialIndex+diff;const numSlides=pswp.getNumItems();if(pswp.canLoop()){newIndex=pswp.getLoopedIndex(newIndex);const distance=(diff+numSlides)%numSlides;distance<=numSlides/2?diff=distance:diff=distance-numSlides}else newIndex<0?newIndex=0:newIndex>=numSlides&&(newIndex=numSlides-1),diff=newIndex-pswp.potentialIndex;pswp.potentialIndex=newIndex,this._currPositionIndex-=diff,pswp.animations.stopMainScroll();const destinationX=this.getCurrSlideX();if(!animate)this.moveTo(destinationX),this.updateCurrItem();else{pswp.animations.startSpring({isMainScroll:!0,start:this.x,end:destinationX,velocity:velocityX||0,naturalFrequency:30,dampingRatio:1,onUpdate:x=>{this.moveTo(x)},onComplete:()=>{this.updateCurrItem(),pswp.appendHeavy()}});let currDiff=pswp.potentialIndex-pswp.currIndex;if(pswp.canLoop()){const currDistance=(currDiff+numSlides)%numSlides;currDistance<=numSlides/2?currDiff=currDistance:currDiff=currDistance-numSlides}Math.abs(currDiff)>1&&this.updateCurrItem()}return!!diff}getCurrSlideX(){return this.slideWidth*this._currPositionIndex}isShifted(){return this.x!==this.getCurrSlideX()}updateCurrItem(){var _this$itemHolders$;const{pswp}=this,positionDifference=this._prevPositionIndex-this._currPositionIndex;if(!positionDifference)return;this._prevPositionIndex=this._currPositionIndex,pswp.currIndex=pswp.potentialIndex;let diffAbs=Math.abs(positionDifference),tempHolder;diffAbs>=3&&(this._containerShiftIndex+=positionDifference+(positionDifference>0?-3:3),diffAbs=3,this.itemHolders.forEach(itemHolder=>{var _itemHolder$slide;(_itemHolder$slide=itemHolder.slide)===null||_itemHolder$slide===void 0||_itemHolder$slide.destroy(),itemHolder.slide=void 0}));for(let i=0;i<diffAbs;i++)positionDifference>0?(tempHolder=this.itemHolders.shift(),tempHolder&&(this.itemHolders[2]=tempHolder,this._containerShiftIndex++,setTransform(tempHolder.el,(this._containerShiftIndex+2)*this.slideWidth),pswp.setContent(tempHolder,pswp.currIndex-diffAbs+i+2))):(tempHolder=this.itemHolders.pop(),tempHolder&&(this.itemHolders.unshift(tempHolder),this._containerShiftIndex--,setTransform(tempHolder.el,this._containerShiftIndex*this.slideWidth),pswp.setContent(tempHolder,pswp.currIndex+diffAbs-i-2)));Math.abs(this._containerShiftIndex)>50&&!this.isShifted()&&(this.resetPosition(),this.resize()),pswp.animations.stopAllPan(),this.itemHolders.forEach((itemHolder,i)=>{itemHolder.slide&&itemHolder.slide.setIsActive(i===1)}),pswp.currSlide=(_this$itemHolders$=this.itemHolders[1])===null||_this$itemHolders$===void 0?void 0:_this$itemHolders$.slide,pswp.contentLoader.updateLazy(positionDifference),pswp.currSlide&&pswp.currSlide.applyCurrentZoomPan(),pswp.dispatch("change")}moveTo(x,dragging){if(!this.pswp.canLoop()&&dragging){let newSlideIndexOffset=(this.slideWidth*this._currPositionIndex-x)/this.slideWidth;newSlideIndexOffset+=this.pswp.currIndex;const delta=Math.round(x-this.x);(newSlideIndexOffset<0&&delta>0||newSlideIndexOffset>=this.pswp.getNumItems()-1&&delta<0)&&(x=this.x+delta*MAIN_SCROLL_END_FRICTION)}this.x=x,this.pswp.container&&setTransform(this.pswp.container,x),this.pswp.dispatch("moveMainScroll",{x,dragging:dragging??!1})}}const KeyboardKeyCodesMap={Escape:27,z:90,ArrowLeft:37,ArrowUp:38,ArrowRight:39,ArrowDown:40,Tab:9},getKeyboardEventKey=(key,isKeySupported)=>isKeySupported?key:KeyboardKeyCodesMap[key];class Keyboard{constructor(pswp){this.pswp=pswp,this._wasFocused=!1,pswp.on("bindEvents",()=>{pswp.options.trapFocus&&(pswp.options.initialPointerPos||this._focusRoot(),pswp.events.add(document,"focusin",this._onFocusIn.bind(this))),pswp.events.add(document,"keydown",this._onKeyDown.bind(this))});const lastActiveElement=document.activeElement;pswp.on("destroy",()=>{pswp.options.returnFocus&&lastActiveElement&&this._wasFocused&&lastActiveElement.focus()})}_focusRoot(){!this._wasFocused&&this.pswp.element&&(this.pswp.element.focus(),this._wasFocused=!0)}_onKeyDown(e){const{pswp}=this;if(pswp.dispatch("keydown",{originalEvent:e}).defaultPrevented||photoswipe_esm_specialKeyUsed(e))return;let keydownAction,axis,isForward=!1;const isKeySupported="key"in e;switch(isKeySupported?e.key:e.keyCode){case getKeyboardEventKey("Escape",isKeySupported):pswp.options.escKey&&(keydownAction="close");break;case getKeyboardEventKey("z",isKeySupported):keydownAction="toggleZoom";break;case getKeyboardEventKey("ArrowLeft",isKeySupported):axis="x";break;case getKeyboardEventKey("ArrowUp",isKeySupported):axis="y";break;case getKeyboardEventKey("ArrowRight",isKeySupported):axis="x",isForward=!0;break;case getKeyboardEventKey("ArrowDown",isKeySupported):isForward=!0,axis="y";break;case getKeyboardEventKey("Tab",isKeySupported):this._focusRoot();break}if(axis){e.preventDefault();const{currSlide}=pswp;pswp.options.arrowKeys&&axis==="x"&&pswp.getNumItems()>1?keydownAction=isForward?"next":"prev":currSlide&&currSlide.currZoomLevel>currSlide.zoomLevels.fit&&(currSlide.pan[axis]+=isForward?-80:80,currSlide.panTo(currSlide.pan.x,currSlide.pan.y))}keydownAction&&(e.preventDefault(),pswp[keydownAction]())}_onFocusIn(e){const{template}=this.pswp;template&&document!==e.target&&template!==e.target&&!template.contains(e.target)&&template.focus()}}const DEFAULT_EASING="cubic-bezier(.4,0,.22,1)";class CSSAnimation{constructor(props){var _props$prop;this.props=props;const{target,onComplete,transform,onFinish=()=>{},duration=333,easing=DEFAULT_EASING}=props;this.onFinish=onFinish;const prop=transform?"transform":"opacity",propValue=(_props$prop=props[prop])!==null&&_props$prop!==void 0?_props$prop:"";this._target=target,this._onComplete=onComplete,this._finished=!1,this._onTransitionEnd=this._onTransitionEnd.bind(this),this._helperTimeout=setTimeout(()=>{setTransitionStyle(target,prop,duration,easing),this._helperTimeout=setTimeout(()=>{target.addEventListener("transitionend",this._onTransitionEnd,!1),target.addEventListener("transitioncancel",this._onTransitionEnd,!1),this._helperTimeout=setTimeout(()=>{this._finalizeAnimation()},duration+500),target.style[prop]=propValue},30)},0)}_onTransitionEnd(e){e.target===this._target&&this._finalizeAnimation()}_finalizeAnimation(){this._finished||(this._finished=!0,this.onFinish(),this._onComplete&&this._onComplete())}destroy(){this._helperTimeout&&clearTimeout(this._helperTimeout),removeTransitionStyle(this._target),this._target.removeEventListener("transitionend",this._onTransitionEnd,!1),this._target.removeEventListener("transitioncancel",this._onTransitionEnd,!1),this._finished||this._finalizeAnimation()}}const DEFAULT_NATURAL_FREQUENCY=12,DEFAULT_DAMPING_RATIO=.75;class SpringEaser{constructor(initialVelocity,dampingRatio,naturalFrequency){this.velocity=initialVelocity*1e3,this._dampingRatio=dampingRatio||DEFAULT_DAMPING_RATIO,this._naturalFrequency=naturalFrequency||DEFAULT_NATURAL_FREQUENCY,this._dampedFrequency=this._naturalFrequency,this._dampingRatio<1&&(this._dampedFrequency*=Math.sqrt(1-this._dampingRatio*this._dampingRatio))}
7easeFrame(deltaPosition,deltaTime){let displacement=0,coeff;deltaTime/=1e3;const naturalDumpingPow=Math.E**(-this._dampingRatio*this._naturalFrequency*deltaTime);if(this._dampingRatio===1)coeff=this.velocity+this._naturalFrequency*deltaPosition,displacement=(deltaPosition+coeff*deltaTime)*naturalDumpingPow,this.velocity=displacement*-this._naturalFrequency+coeff*naturalDumpingPow;else if(this._dampingRatio<1){coeff=1/this._dampedFrequency*(this._dampingRatio*this._naturalFrequency*deltaPosition+this.velocity);const dumpedFCos=Math.cos(this._dampedFrequency*deltaTime),dumpedFSin=Math.sin(this._dampedFrequency*deltaTime);displacement=naturalDumpingPow*(deltaPosition*dumpedFCos+coeff*dumpedFSin),this.velocity=displacement*-this._naturalFrequency*this._dampingRatio+naturalDumpingPow*(-this._dampedFrequency*deltaPosition*dumpedFSin+this._dampedFrequency*coeff*dumpedFCos)}return displacement}}class SpringAnimation{constructor(props){this.props=props,this._raf=0;const{start,end,velocity,onUpdate,onComplete,onFinish=()=>{},dampingRatio,naturalFrequency}=props;this.onFinish=onFinish;const easer=new SpringEaser(velocity,dampingRatio,naturalFrequency);let prevTime=Date.now(),deltaPosition=start-end;const animationLoop=()=>{this._raf&&(deltaPosition=easer.easeFrame(deltaPosition,Date.now()-prevTime),Math.abs(deltaPosition)<1&&Math.abs(easer.velocity)<50?(onUpdate(end),onComplete&&onComplete(),this.onFinish()):(prevTime=Date.now(),onUpdate(deltaPosition+end),this._raf=requestAnimationFrame(animationLoop)))};this._raf=requestAnimationFrame(animationLoop)}destroy(){this._raf>=0&&cancelAnimationFrame(this._raf),this._raf=0}}class Animations{constructor(){this.activeAnimations=[]}startSpring(props){this._start(props,!0)}startTransition(props){this._start(props)}_start(props,isSpring){const animation=isSpring?new SpringAnimation(props):new CSSAnimation(props);return this.activeAnimations.push(animation),animation.onFinish=()=>this.stop(animation),animation}stop(animation){animation.destroy();const index=this.activeAnimations.indexOf(animation);index>-1&&this.activeAnimations.splice(index,1)}stopAll(){this.activeAnimations.forEach(animation=>{animation.destroy()}),this.activeAnimations=[]}stopAllPan(){this.activeAnimations=this.activeAnimations.filter(animation=>animation.props.isPan?(animation.destroy(),!1):!0)}stopMainScroll(){this.activeAnimations=this.activeAnimations.filter(animation=>animation.props.isMainScroll?(animation.destroy(),!1):!0)}isPanRunning(){return this.activeAnimations.some(animation=>animation.props.isPan)}}class ScrollWheel{constructor(pswp){this.pswp=pswp,pswp.events.add(pswp.element,"wheel",this._onWheel.bind(this))}_onWheel(e){e.preventDefault();const{currSlide}=this.pswp;let{deltaX,deltaY}=e;if(currSlide&&!this.pswp.dispatch("wheel",{originalEvent:e}).defaultPrevented)if(e.ctrlKey||this.pswp.options.wheelToZoom){if(currSlide.isZoomable()){let zoomFactor=-deltaY;e.deltaMode===1?zoomFactor*=.05:zoomFactor*=e.deltaMode?1:.002,zoomFactor=2**zoomFactor;const destZoomLevel=currSlide.currZoomLevel*zoomFactor;currSlide.zoomTo(destZoomLevel,{x:e.clientX,y:e.clientY})}}else currSlide.isPannable()&&(e.deltaMode===1&&(deltaX*=18,deltaY*=18),currSlide.panTo(currSlide.pan.x-deltaX,currSlide.pan.y-deltaY))}}function addElementHTML(htmlData){if(typeof htmlData=="string")return htmlData;if(!htmlData||!htmlData.isCustomSVG)return"";const svgData=htmlData;
vendor: 20,547 bytes, line 7
7let out='<svg aria-hidden="true" class="pswp__icn" viewBox="0 0 %d %d" width="%d" height="%d">';return out=out.split("%d").join(svgData.size||32),svgData.outlineID&&(out+='<use class="pswp__icn-shadow" xlink:href="#'+svgData.outlineID+'"/>'),out+=svgData.inner,out+="</svg>",out}class UIElement{constructor(pswp,data){var _container;const name=data.name||data.className;let elementHTML=data.html;if(pswp.options[name]===!1)return;typeof pswp.options[name+"SVG"]=="string"&&(elementHTML=pswp.options[name+"SVG"]),pswp.dispatch("uiElementCreate",{data});let className="";data.isButton?(className+="pswp__button ",className+=data.className||`pswp__button--${data.name}`):className+=data.className||`pswp__${data.name}`;let tagName=data.isButton?data.tagName||"button":data.tagName||"div";tagName=tagName.toLowerCase();const element=photoswipe_esm_createElement(className,tagName);if(data.isButton){tagName==="button"&&(element.type="button");let{title}=data;const{ariaLabel}=data;typeof pswp.options[name+"Title"]=="string"&&(title=pswp.options[name+"Title"]),title&&(element.title=title);const ariaText=ariaLabel||title;ariaText&&element.setAttribute("aria-label",ariaText)}element.innerHTML=addElementHTML(elementHTML),data.onInit&&data.onInit(element,pswp),data.onClick&&(element.onclick=e=>{typeof data.onClick=="string"?pswp[data.onClick]():typeof data.onClick=="function"&&data.onClick(e,element,pswp)});const appendTo=data.appendTo||"bar";let container=pswp.element;appendTo==="bar"?(pswp.topBar||(pswp.topBar=photoswipe_esm_createElement("pswp__top-bar pswp__hide-on-close","div",pswp.scrollWrap)),container=pswp.topBar):(element.classList.add("pswp__hide-on-close"),appendTo==="wrapper"&&(container=pswp.scrollWrap)),(_container=container)===null||_container===void 0||_container.appendChild(pswp.applyFilters("uiElement",element,data))}}function initArrowButton(element,pswp,isNextButton){element.classList.add("pswp__button--arrow"),element.setAttribute("aria-controls","pswp__items"),pswp.on("change",()=>{pswp.options.loop||(isNextButton?element.disabled=!(pswp.currIndex<pswp.getNumItems()-1):element.disabled=!(pswp.currIndex>0))})}const arrowPrev={name:"arrowPrev",className:"pswp__button--arrow--prev",title:"Previous",order:10,isButton:!0,appendTo:"wrapper",html:{isCustomSVG:!0,size:60,inner:'<path d="M29 43l-3 3-16-16 16-16 3 3-13 13 13 13z" id="pswp__icn-arrow"/>',outlineID:"pswp__icn-arrow"},onClick:"prev",onInit:initArrowButton},arrowNext={name:"arrowNext",className:"pswp__button--arrow--next",title:"Next",order:11,isButton:!0,appendTo:"wrapper",html:{isCustomSVG:!0,size:60,inner:'<use xlink:href="#pswp__icn-arrow"/>',outlineID:"pswp__icn-arrow"},onClick:"next",onInit:(el,pswp)=>{initArrowButton(el,pswp,!0)}},closeButton={name:"close",title:"Close",order:20,isButton:!0,html:{isCustomSVG:!0,inner:'<path d="M24 10l-2-2-6 6-6-6-2 2 6 6-6 6 2 2 6-6 6 6 2-2-6-6z" id="pswp__icn-close"/>',outlineID:"pswp__icn-close"},onClick:"close"},zoomButton={name:"zoom",title:"Zoom",order:10,isButton:!0,html:{isCustomSVG:!0,inner:'<path d="M17.426 19.926a6 6 0 1 1 1.5-1.5L23 22.5 21.5 24l-4.074-4.074z" id="pswp__icn-zoom"/><path fill="currentColor" class="pswp__zoom-icn-bar-h" d="M11 16v-2h6v2z"/><path fill="currentColor" class="pswp__zoom-icn-bar-v" d="M13 12h2v6h-2z"/>',outlineID:"pswp__icn-zoom"},onClick:"toggleZoom"},loadingIndicator={name:"preloader",appendTo:"bar",order:7,html:{isCustomSVG:!0,inner:'<path fill-rule="evenodd" clip-rule="evenodd" d="M21.2 16a5.2 5.2 0 1 1-5.2-5.2V8a8 8 0 1 0 8 8h-2.8Z" id="pswp__icn-loading"/>',outlineID:"pswp__icn-loading"},onInit:(indicatorElement,pswp)=>{let isVisible,delayTimeout=null;const toggleIndicatorClass=(className,add)=>{indicatorElement.classList.toggle("pswp__preloader--"+className,add)},setIndicatorVisibility=visible=>{isVisible!==visible&&(isVisible=visible,toggleIndicatorClass("active",visible))},updatePreloaderVisibility=()=>{var _pswp$currSlide;if(!((_pswp$currSlide=pswp.currSlide)!==null&&_pswp$currSlide!==void 0&&_pswp$currSlide.content.isLoading())){setIndicatorVisibility(!1),delayTimeout&&(clearTimeout(delayTimeout),delayTimeout=null);return}delayTimeout||(delayTimeout=setTimeout(()=>{var _pswp$currSlide2;setIndicatorVisibility(!!(!((_pswp$currSlide2=pswp.currSlide)===null||_pswp$currSlide2===void 0)&&_pswp$currSlide2.content.isLoading())),delayTimeout=null},pswp.options.preloaderDelay))};pswp.on("change",updatePreloaderVisibility),pswp.on("loadComplete",e=>{pswp.currSlide===e.slide&&updatePreloaderVisibility()}),pswp.ui&&(pswp.ui.updatePreloaderVisibility=updatePreloaderVisibility)}},counterIndicator={name:"counter",order:5,onInit:(counterElement,pswp)=>{pswp.on("change",()=>{counterElement.innerText=pswp.currIndex+1+pswp.options.indexIndicatorSep+pswp.getNumItems()})}};function setZoomedIn(el,isZoomedIn){el.classList.toggle("pswp--zoomed-in",isZoomedIn)}class UI{constructor(pswp){this.pswp=pswp,this.isRegistered=!1,this.uiElementsData=[],this.items=[],this.updatePreloaderVisibility=()=>{},this._lastUpdatedZoomLevel=void 0}init(){const{pswp}=this;this.isRegistered=!1,this.uiElementsData=[closeButton,arrowPrev,arrowNext,zoomButton,loadingIndicator,counterIndicator],pswp.dispatch("uiRegister"),this.uiElementsData.sort((a,b)=>(a.order||0)-(b.order||0)),this.items=[],this.isRegistered=!0,this.uiElementsData.forEach(uiElementData=>{this.registerElement(uiElementData)}),pswp.on("change",()=>{var _pswp$element;(_pswp$element=pswp.element)===null||_pswp$element===void 0||_pswp$element.classList.toggle("pswp--one-slide",pswp.getNumItems()===1)}),pswp.on("zoomPanUpdate",()=>this._onZoomPanUpdate())}registerElement(elementData){this.isRegistered?this.items.push(new UIElement(this.pswp,elementData)):this.uiElementsData.push(elementData)}_onZoomPanUpdate(){const{template,currSlide,options}=this.pswp;if(this.pswp.opener.isClosing||!template||!currSlide)return;let{currZoomLevel}=currSlide;if(this.pswp.opener.isOpen||(currZoomLevel=currSlide.zoomLevels.initial),currZoomLevel===this._lastUpdatedZoomLevel)return;this._lastUpdatedZoomLevel=currZoomLevel;const currZoomLevelDiff=currSlide.zoomLevels.initial-currSlide.zoomLevels.secondary;if(Math.abs(currZoomLevelDiff)<.01||!currSlide.isZoomable()){setZoomedIn(template,!1),template.classList.remove("pswp--zoom-allowed");return}template.classList.add("pswp--zoom-allowed");const potentialZoomLevel=currZoomLevel===currSlide.zoomLevels.initial?currSlide.zoomLevels.secondary:currSlide.zoomLevels.initial;setZoomedIn(template,potentialZoomLevel<=currZoomLevel),(options.imageClickAction==="zoom"||options.imageClickAction==="zoom-or-close")&&template.classList.add("pswp--click-to-zoom")}}function getBoundsByElement(el){const thumbAreaRect=el.getBoundingClientRect();return{x:thumbAreaRect.left,y:thumbAreaRect.top,w:thumbAreaRect.width}}function getCroppedBoundsByElement(el,imageWidth,imageHeight){const thumbAreaRect=el.getBoundingClientRect(),hRatio=thumbAreaRect.width/imageWidth,vRatio=thumbAreaRect.height/imageHeight,fillZoomLevel=hRatio>vRatio?hRatio:vRatio,offsetX=(thumbAreaRect.width-imageWidth*fillZoomLevel)/2,offsetY=(thumbAreaRect.height-imageHeight*fillZoomLevel)/2,bounds={x:thumbAreaRect.left+offsetX,y:thumbAreaRect.top+offsetY,w:imageWidth*fillZoomLevel};return bounds.innerRect={w:thumbAreaRect.width,h:thumbAreaRect.height,x:offsetX,y:offsetY},bounds}function getThumbBounds(index,itemData,instance){const event=instance.dispatch("thumbBounds",{index,itemData,instance});if(event.thumbBounds)return event.thumbBounds;const{element}=itemData;let thumbBounds,thumbnail;if(element&&instance.options.thumbSelector!==!1){const thumbSelector=instance.options.thumbSelector||"img";thumbnail=element.matches(thumbSelector)?element:element.querySelector(thumbSelector)}return thumbnail=instance.applyFilters("thumbEl",thumbnail,itemData,index),thumbnail&&(itemData.thumbCropped?thumbBounds=getCroppedBoundsByElement(thumbnail,itemData.width||itemData.w||0,itemData.height||itemData.h||0):thumbBounds=getBoundsByElement(thumbnail)),instance.applyFilters("thumbBounds",thumbBounds,itemData,index)}class photoswipe_esm_PhotoSwipeEvent{constructor(type,details){this.type=type,this.defaultPrevented=!1,details&&Object.assign(this,details)}preventDefault(){this.defaultPrevented=!0}}class photoswipe_esm_Eventable{constructor(){this._listeners={},this._filters={},this.pswp=void 0,this.options=void 0}addFilter(name,fn,priority=100){var _this$_filters$name,_this$_filters$name2,_this$pswp;this._filters[name]||(this._filters[name]=[]),(_this$_filters$name=this._filters[name])===null||_this$_filters$name===void 0||_this$_filters$name.push({fn,priority}),(_this$_filters$name2=this._filters[name])===null||_this$_filters$name2===void 0||_this$_filters$name2.sort((f1,f2)=>f1.priority-f2.priority),(_this$pswp=this.pswp)===null||_this$pswp===void 0||_this$pswp.addFilter(name,fn,priority)}removeFilter(name,fn){this._filters[name]&&(this._filters[name]=this._filters[name].filter(filter=>filter.fn!==fn)),this.pswp&&this.pswp.removeFilter(name,fn)}applyFilters(name,...args){var _this$_filters$name3;return(_this$_filters$name3=this._filters[name])===null||_this$_filters$name3===void 0||_this$_filters$name3.forEach(filter=>{args[0]=filter.fn.apply(this,args)}),args[0]}on(name,fn){var _this$_listeners$name,_this$pswp2;this._listeners[name]||(this._listeners[name]=[]),(_this$_listeners$name=this._listeners[name])===null||_this$_listeners$name===void 0||_this$_listeners$name.push(fn),(_this$pswp2=this.pswp)===null||_this$pswp2===void 0||_this$pswp2.on(name,fn)}off(name,fn){var _this$pswp3;this._listeners[name]&&(this._listeners[name]=this._listeners[name].filter(listener=>fn!==listener)),(_this$pswp3=this.pswp)===null||_this$pswp3===void 0||_this$pswp3.off(name,fn)}dispatch(name,details){var _this$_listeners$name2;if(this.pswp)return this.pswp.dispatch(name,details);const event=new photoswipe_esm_PhotoSwipeEvent(name,details);return(_this$_listeners$name2=this._listeners[name])===null||_this$_listeners$name2===void 0||_this$_listeners$name2.forEach(listener=>{listener.call(this,event)}),event}}class photoswipe_esm_Placeholder{constructor(imageSrc,container){if(this.element=photoswipe_esm_createElement("pswp__img pswp__img--placeholder",imageSrc?"img":"div",container),imageSrc){const imgEl=this.element;imgEl.decoding="async",imgEl.alt="",imgEl.src=imageSrc,imgEl.setAttribute("role","presentation")}this.element.setAttribute("aria-hidden","true")}setDisplayedSize(width,height){this.element&&(this.element.tagName==="IMG"?(photoswipe_esm_setWidthHeight(this.element,250,"auto"),this.element.style.transformOrigin="0 0",this.element.style.transform=photoswipe_esm_toTransformString(0,0,width/250)):photoswipe_esm_setWidthHeight(this.element,width,height))}destroy(){var _this$element;(_this$element=this.element)!==null&&_this$element!==void 0&&_this$element.parentNode&&this.element.remove(),this.element=null}}class photoswipe_esm_Content{constructor(itemData,instance,index){this.instance=instance,this.data=itemData,this.index=index,this.element=void 0,this.placeholder=void 0,this.slide=void 0,this.displayedImageWidth=0,this.displayedImageHeight=0,this.width=Number(this.data.w)||Number(this.data.width)||0,this.height=Number(this.data.h)||Number(this.data.height)||0,this.isAttached=!1,this.hasSlide=!1,this.isDecoding=!1,this.state=photoswipe_esm_LOAD_STATE.IDLE,this.data.type?this.type=this.data.type:this.data.src?this.type="image":this.type="html",this.instance.dispatch("contentInit",{content:this})}removePlaceholder(){this.placeholder&&!this.keepPlaceholder()&&setTimeout(()=>{this.placeholder&&(this.placeholder.destroy(),this.placeholder=void 0)},1e3)}load(isLazy,reload){if(this.slide&&this.usePlaceholder())if(this.placeholder){const placeholderEl=this.placeholder.element;placeholderEl&&!placeholderEl.parentElement&&this.slide.container.prepend(placeholderEl)}else{const placeholderSrc=this.instance.applyFilters("placeholderSrc",this.data.msrc&&this.slide.isFirstSlide?this.data.msrc:!1,this);this.placeholder=new photoswipe_esm_Placeholder(placeholderSrc,this.slide.container)}this.element&&!reload||this.instance.dispatch("contentLoad",{content:this,isLazy}).defaultPrevented||(this.isImageContent()?(this.element=photoswipe_esm_createElement("pswp__img","img"),this.displayedImageWidth&&this.loadImage(isLazy)):(this.element=photoswipe_esm_createElement("pswp__content","div"),this.element.innerHTML=this.data.html||""),reload&&this.slide&&this.slide.updateContentSize(!0))}loadImage(isLazy){var _this$data$src,_this$data$alt;if(!this.isImageContent()||!this.element||this.instance.dispatch("contentLoadImage",{content:this,isLazy}).defaultPrevented)return;const imageElement=this.element;this.updateSrcsetSizes(),this.data.srcset&&(imageElement.srcset=this.data.srcset),imageElement.src=(_this$data$src=this.data.src)!==null&&_this$data$src!==void 0?_this$data$src:"",imageElement.alt=(_this$data$alt=this.data.alt)!==null&&_this$data$alt!==void 0?_this$data$alt:"",this.state=photoswipe_esm_LOAD_STATE.LOADING,imageElement.complete?this.onLoaded():(imageElement.onload=()=>{this.onLoaded()},imageElement.onerror=()=>{this.onError()})}setSlide(slide){this.slide=slide,this.hasSlide=!0,this.instance=slide.pswp}onLoaded(){this.state=photoswipe_esm_LOAD_STATE.LOADED,this.slide&&this.element&&(this.instance.dispatch("loadComplete",{slide:this.slide,content:this}),this.slide.isActive&&this.slide.heavyAppended&&!this.element.parentNode&&(this.append(),this.slide.updateContentSize(!0)),(this.state===photoswipe_esm_LOAD_STATE.LOADED||this.state===photoswipe_esm_LOAD_STATE.ERROR)&&this.removePlaceholder())}onError(){this.state=photoswipe_esm_LOAD_STATE.ERROR,this.slide&&(this.displayError(),this.instance.dispatch("loadComplete",{slide:this.slide,isError:!0,content:this}),this.instance.dispatch("loadError",{slide:this.slide,content:this}))}isLoading(){return this.instance.applyFilters("isContentLoading",this.state===photoswipe_esm_LOAD_STATE.LOADING,this)}isError(){return this.state===photoswipe_esm_LOAD_STATE.ERROR}isImageContent(){return this.type==="image"}setDisplayedSize(width,height){if(this.element&&(this.placeholder&&this.placeholder.setDisplayedSize(width,height),!this.instance.dispatch("contentResize",{content:this,width,height}).defaultPrevented&&(photoswipe_esm_setWidthHeight(this.element,width,height),this.isImageContent()&&!this.isError()))){const isInitialSizeUpdate=!this.displayedImageWidth&&width;this.displayedImageWidth=width,this.displayedImageHeight=height,isInitialSizeUpdate?this.loadImage(!1):this.updateSrcsetSizes(),this.slide&&this.instance.dispatch("imageSizeChange",{slide:this.slide,width,height,content:this})}}isZoomable(){return this.instance.applyFilters("isContentZoomable",this.isImageContent()&&this.state!==photoswipe_esm_LOAD_STATE.ERROR,this)}updateSrcsetSizes(){if(!this.isImageContent()||!this.element||!this.data.srcset)return;const image=this.element,sizesWidth=this.instance.applyFilters("srcsetSizesWidth",this.displayedImageWidth,this);(!image.dataset.largestUsedSize||sizesWidth>parseInt(image.dataset.largestUsedSize,10))&&(image.sizes=sizesWidth+"px",image.dataset.largestUsedSize=String(sizesWidth))}usePlaceholder(){return this.instance.applyFilters("useContentPlaceholder",this.isImageContent(),this)}lazyLoad(){this.instance.dispatch("contentLazyLoad",{content:this}).defaultPrevented||this.load(!0)}keepPlaceholder(){return this.instance.applyFilters("isKeepingPlaceholder",this.isLoading(),this)}destroy(){this.hasSlide=!1,this.slide=void 0,!this.instance.dispatch("contentDestroy",{content:this}).defaultPrevented&&(this.remove(),this.placeholder&&(this.placeholder.destroy(),this.placeholder=void 0),this.isImageContent()&&this.element&&(this.element.onload=null,this.element.onerror=null,this.element=void 0))}displayError(){if(this.slide){var _this$instance$option,_this$instance$option2;let errorMsgEl=photoswipe_esm_createElement("pswp__error-msg","div");errorMsgEl.innerText=(_this$instance$option=(_this$instance$option2=this.instance.options)===null||_this$instance$option2===void 0?void 0:_this$instance$option2.errorMsg)!==null&&_this$instance$option!==void 0?_this$instance$option:"",errorMsgEl=this.instance.applyFilters("contentErrorElement",errorMsgEl,this),this.element=photoswipe_esm_createElement("pswp__content pswp__error-msg-container","div"),this.element.appendChild(errorMsgEl),this.slide.container.innerText="",this.slide.container.appendChild(this.element),this.slide.updateContentSize(!0),this.removePlaceholder()}}append(){if(this.isAttached||!this.element)return;if(this.isAttached=!0,this.state===photoswipe_esm_LOAD_STATE.ERROR){this.displayError();return}if(this.instance.dispatch("contentAppend",{content:this}).defaultPrevented)return;const supportsDecode="decode"in this.element;this.isImageContent()?supportsDecode&&this.slide&&(!this.slide.isActive||photoswipe_esm_isSafari())?(this.isDecoding=!0,this.element.decode().catch(()=>{}).finally(()=>{this.isDecoding=!1,this.appendImage()})):this.appendImage():this.slide&&!this.element.parentNode&&this.slide.container.appendChild(this.element)}activate(){this.instance.dispatch("contentActivate",{content:this}).defaultPrevented||!this.slide||(this.isImageContent()&&this.isDecoding&&!photoswipe_esm_isSafari()?this.appendImage():this.isError()&&this.load(!1,!0),this.slide.holderElement&&this.slide.holderElement.setAttribute("aria-hidden","false"))}deactivate(){this.instance.dispatch("contentDeactivate",{content:this}),this.slide&&this.slide.holderElement&&this.slide.holderElement.setAttribute("aria-hidden","true")}remove(){this.isAttached=!1,!this.instance.dispatch("contentRemove",{content:this}).defaultPrevented&&(this.element&&this.element.parentNode&&this.element.remove(),this.placeholder&&this.placeholder.element&&this.placeholder.element.remove())}appendImage(){this.isAttached&&(this.instance.dispatch("contentAppendImage",{content:this}).defaultPrevented||(this.slide&&this.element&&!this.element.parentNode&&this.slide.container.appendChild(this.element),(this.state===photoswipe_esm_LOAD_STATE.LOADED||this.state===photoswipe_esm_LOAD_STATE.ERROR)&&this.removePlaceholder()))}}const MIN_SLIDES_TO_CACHE=5;function photoswipe_esm_lazyLoadData(itemData,instance,index){const content=instance.createContentFromData(itemData,index);let zoomLevel;const{options}=instance;if(options){zoomLevel=new photoswipe_esm_ZoomLevel(options,itemData,-1);let viewportSize;instance.pswp?viewportSize=instance.pswp.viewportSize:viewportSize=photoswipe_esm_getViewportSize(options,instance);const panAreaSize=photoswipe_esm_getPanAreaSize(options,viewportSize,itemData,index);zoomLevel.update(content.width,content.height,panAreaSize)}return content.lazyLoad(),zoomLevel&&content.setDisplayedSize(Math.ceil(content.width*zoomLevel.initial),Math.ceil(content.height*zoomLevel.initial)),content}function photoswipe_esm_lazyLoadSlide(index,instance){const itemData=instance.getItemData(index);if(!instance.dispatch("lazyLoadSlide",{index,itemData}).defaultPrevented)return photoswipe_esm_lazyLoadData(itemData,instance,index)}class ContentLoader{constructor(pswp){this.pswp=pswp,this.limit=Math.max(pswp.options.preload[0]+pswp.options.preload[1]+1,MIN_SLIDES_TO_CACHE),this._cachedItems=[]}updateLazy(diff){const{pswp}=this;if(pswp.dispatch("lazyLoad").defaultPrevented)return;const{preload}=pswp.options,isForward=diff===void 0?!0:diff>=0;let i;for(i=0;i<=preload[1];i++)this.loadSlideByIndex(pswp.currIndex+(isForward?i:-i));for(i=1;i<=preload[0];i++)this.loadSlideByIndex(pswp.currIndex+(isForward?-i:i))}loadSlideByIndex(initialIndex){const index=this.pswp.getLoopedIndex(initialIndex);let content=this.getContentByIndex(index);content||(content=photoswipe_esm_lazyLoadSlide(index,this.pswp),content&&this.addToCache(content))}getContentBySlide(slide){let content=this.getContentByIndex(slide.index);return content||(content=this.pswp.createContentFromData(slide.data,slide.index),this.addToCache(content)),content.setSlide(slide),content}addToCache(content){if(this.removeByIndex(content.index),this._cachedItems.push(content),this._cachedItems.length>this.limit){const indexToRemove=this._cachedItems.findIndex(item=>!item.isAttached&&!item.hasSlide);indexToRemove!==-1&&this._cachedItems.splice(indexToRemove,1)[0].destroy()}}removeByIndex(index){const indexToRemove=this._cachedItems.findIndex(item=>item.index===index);indexToRemove!==-1&&this._cachedItems.splice(indexToRemove,1)}getContentByIndex(index){return this._cachedItems.find(content=>content.index===index)}
7destroy(){this._cachedItems.forEach(content=>content.destroy()),this._cachedItems=[]}}class photoswipe_esm_PhotoSwipeBase extends photoswipe_esm_Eventable{getNumItems(){var _this$options;let numItems=0;const dataSource=(_this$options=this.options)===null||_this$options===void 0?void 0:_this$options.dataSource;dataSource&&"length"in dataSource?numItems=dataSource.length:dataSource&&"gallery"in dataSource&&(dataSource.items||(dataSource.items=this._getGalleryDOMElements(dataSource.gallery)),dataSource.items&&(numItems=dataSource.items.length));const event=this.dispatch("numItems",{dataSource,numItems});return this.applyFilters("numItems",event.numItems,dataSource)}createContentFromData(slideData,index){return new photoswipe_esm_Content(slideData,this,index)}getItemData(index){var _this$options2;const dataSource=(_this$options2=this.options)===null||_this$options2===void 0?void 0:_this$options2.dataSource;let dataSourceItem={};Array.isArray(dataSource)?dataSourceItem=dataSource[index]:dataSource&&"gallery"in dataSource&&(dataSource.items||(dataSource.items=this._getGalleryDOMElements(dataSource.gallery)),dataSourceItem=dataSource.items[index]);let itemData=dataSourceItem;itemData instanceof Element&&(itemData=this._domElementToItemData(itemData));const event=this.dispatch("itemData",{itemData:itemData||{},index});return this.applyFilters("itemData",event.itemData,index)}_getGalleryDOMElements(galleryElement){var _this$options3,_this$options4;return(_this$options3=this.options)!==null&&_this$options3!==void 0&&_this$options3.children||(_this$options4=this.options)!==null&&_this$options4!==void 0&&_this$options4.childSelector?photoswipe_esm_getElementsFromOption(this.options.children,this.options.childSelector,galleryElement)||[]:[galleryElement]}_domElementToItemData(element){const itemData={element},linkEl=element.tagName==="A"?element:element.querySelector("a");if(linkEl){itemData.src=linkEl.dataset.pswpSrc||linkEl.href,linkEl.dataset.pswpSrcset&&(itemData.srcset=linkEl.dataset.pswpSrcset),itemData.width=linkEl.dataset.pswpWidth?parseInt(linkEl.dataset.pswpWidth,10):0,itemData.height=linkEl.dataset.pswpHeight?parseInt(linkEl.dataset.pswpHeight,10):0,itemData.w=itemData.width,itemData.h=itemData.height,linkEl.dataset.pswpType&&(itemData.type=linkEl.dataset.pswpType);const thumbnailEl=element.querySelector("img");if(thumbnailEl){var _thumbnailEl$getAttri;
vendor: 5,957 bytes, line 7
7itemData.msrc=thumbnailEl.currentSrc||thumbnailEl.src,itemData.alt=(_thumbnailEl$getAttri=thumbnailEl.getAttribute("alt"))!==null&&_thumbnailEl$getAttri!==void 0?_thumbnailEl$getAttri:""}(linkEl.dataset.pswpCropped||linkEl.dataset.cropped)&&(itemData.thumbCropped=!0)}return this.applyFilters("domItemData",itemData,element,linkEl)}lazyLoadData(itemData,index){return photoswipe_esm_lazyLoadData(itemData,this,index)}}const MIN_OPACITY=.003;class Opener{constructor(pswp){this.pswp=pswp,this.isClosed=!0,this.isOpen=!1,this.isClosing=!1,this.isOpening=!1,this._duration=void 0,this._useAnimation=!1,this._croppedZoom=!1,this._animateRootOpacity=!1,this._animateBgOpacity=!1,this._placeholder=void 0,this._opacityElement=void 0,this._cropContainer1=void 0,this._cropContainer2=void 0,this._thumbBounds=void 0,this._prepareOpen=this._prepareOpen.bind(this),pswp.on("firstZoomPan",this._prepareOpen)}open(){this._prepareOpen(),this._start()}close(){if(this.isClosed||this.isClosing||this.isOpening)return;const slide=this.pswp.currSlide;this.isOpen=!1,this.isOpening=!1,this.isClosing=!0,this._duration=this.pswp.options.hideAnimationDuration,slide&&slide.currZoomLevel*slide.width>=this.pswp.options.maxWidthToAnimate&&(this._duration=0),this._applyStartProps(),setTimeout(()=>{this._start()},this._croppedZoom?30:0)}_prepareOpen(){if(this.pswp.off("firstZoomPan",this._prepareOpen),!this.isOpening){const slide=this.pswp.currSlide;this.isOpening=!0,this.isClosing=!1,this._duration=this.pswp.options.showAnimationDuration,slide&&slide.zoomLevels.initial*slide.width>=this.pswp.options.maxWidthToAnimate&&(this._duration=0),this._applyStartProps()}}_applyStartProps(){const{pswp}=this,slide=this.pswp.currSlide,{options}=pswp;if(options.showHideAnimationType==="fade"?(options.showHideOpacity=!0,this._thumbBounds=void 0):options.showHideAnimationType==="none"?(options.showHideOpacity=!1,this._duration=0,this._thumbBounds=void 0):this.isOpening&&pswp._initialThumbBounds?this._thumbBounds=pswp._initialThumbBounds:this._thumbBounds=this.pswp.getThumbBounds(),this._placeholder=slide?.getPlaceholderElement(),pswp.animations.stopAll(),this._useAnimation=!!(this._duration&&this._duration>50),this._animateZoom=!!this._thumbBounds&&slide?.content.usePlaceholder()&&(!this.isClosing||!pswp.mainScroll.isShifted()),!this._animateZoom)this._animateRootOpacity=!0,this.isOpening&&slide&&(slide.zoomAndPanToInitial(),slide.applyCurrentZoomPan());else{var _options$showHideOpac;this._animateRootOpacity=(_options$showHideOpac=options.showHideOpacity)!==null&&_options$showHideOpac!==void 0?_options$showHideOpac:!1}if(this._animateBgOpacity=!this._animateRootOpacity&&this.pswp.options.bgOpacity>MIN_OPACITY,this._opacityElement=this._animateRootOpacity?pswp.element:pswp.bg,!this._useAnimation){this._duration=0,this._animateZoom=!1,this._animateBgOpacity=!1,this._animateRootOpacity=!0,this.isOpening&&(pswp.element&&(pswp.element.style.opacity=String(MIN_OPACITY)),pswp.applyBgOpacity(1));return}if(this._animateZoom&&this._thumbBounds&&this._thumbBounds.innerRect){var _this$pswp$currSlide;this._croppedZoom=!0,this._cropContainer1=this.pswp.container,this._cropContainer2=(_this$pswp$currSlide=this.pswp.currSlide)===null||_this$pswp$currSlide===void 0?void 0:_this$pswp$currSlide.holderElement,pswp.container&&(pswp.container.style.overflow="hidden",pswp.container.style.width=pswp.viewportSize.x+"px")}else this._croppedZoom=!1;this.isOpening?(this._animateRootOpacity?(pswp.element&&(pswp.element.style.opacity=String(MIN_OPACITY)),pswp.applyBgOpacity(1)):(this._animateBgOpacity&&pswp.bg&&(pswp.bg.style.opacity=String(MIN_OPACITY)),pswp.element&&(pswp.element.style.opacity="1")),this._animateZoom&&(this._setClosedStateZoomPan(),this._placeholder&&(this._placeholder.style.willChange="transform",this._placeholder.style.opacity=String(MIN_OPACITY)))):this.isClosing&&(pswp.mainScroll.itemHolders[0]&&(pswp.mainScroll.itemHolders[0].el.style.display="none"),pswp.mainScroll.itemHolders[2]&&(pswp.mainScroll.itemHolders[2].el.style.display="none"),this._croppedZoom&&pswp.mainScroll.x!==0&&(pswp.mainScroll.resetPosition(),pswp.mainScroll.resize()))}_start(){this.isOpening&&this._useAnimation&&this._placeholder&&this._placeholder.tagName==="IMG"?new Promise(resolve=>{let decoded=!1,isDelaying=!0;decodeImage(this._placeholder).finally(()=>{decoded=!0,isDelaying||resolve(!0)}),setTimeout(()=>{isDelaying=!1,decoded&&resolve(!0)},50),setTimeout(resolve,250)}).finally(()=>this._initiate()):this._initiate()}_initiate(){var _this$pswp$element,_this$pswp$element2;(_this$pswp$element=this.pswp.element)===null||_this$pswp$element===void 0||_this$pswp$element.style.setProperty("--pswp-transition-duration",this._duration+"ms"),this.pswp.dispatch(this.isOpening?"openingAnimationStart":"closingAnimationStart"),this.pswp.dispatch("initialZoom"+(this.isOpening?"In":"Out")),(_this$pswp$element2=this.pswp.element)===null||_this$pswp$element2===void 0||_this$pswp$element2.classList.toggle("pswp--ui-visible",this.isOpening),this.isOpening?(this._placeholder&&(this._placeholder.style.opacity="1"),this._animateToOpenState()):this.isClosing&&this._animateToClosedState(),this._useAnimation||this._onAnimationComplete()}_onAnimationComplete(){const{pswp}=this;if(this.isOpen=this.isOpening,this.isClosed=this.isClosing,this.isOpening=!1,this.isClosing=!1,pswp.dispatch(this.isOpen?"openingAnimationEnd":"closingAnimationEnd"),pswp.dispatch("initialZoom"+(this.isOpen?"InEnd":"OutEnd")),this.isClosed)pswp.destroy();else if(this.isOpen){var _pswp$currSlide;this._animateZoom&&pswp.container&&(pswp.container.style.overflow="visible",pswp.container.style.width="100%"),(_pswp$currSlide=pswp.currSlide)===null||_pswp$currSlide===void 0||_pswp$currSlide.applyCurrentZoomPan()}}_animateToOpenState(){const{pswp}=this;this._animateZoom&&(this._croppedZoom&&this._cropContainer1&&this._cropContainer2&&(this._animateTo(this._cropContainer1,"transform","translate3d(0,
70,0)"),this._animateTo(this._cropContainer2,"transform","none")),pswp.currSlide&&(pswp.currSlide.zoomAndPanToInitial(),this._animateTo(pswp.currSlide.container,"transform",pswp.currSlide.getCurrentTransform()))),this._animateBgOpacity&&pswp.bg&&this._animateTo(pswp.bg,"opacity",String(pswp.options.bgOpacity)),this._animateRootOpacity&&pswp.element&&this._animateTo(pswp.element,"opacity","1")}_animateToClosedState(){const{pswp}=this;this._animateZoom&&this._setClosedStateZoomPan(!0),this._animateBgOpacity&&pswp.bgOpacity>.01&&pswp.bg&&this._animateTo(pswp.bg,"opacity","0"),this._animateRootOpacity&&pswp.element&&this._animateTo(pswp.element,"opacity","0")}_setClosedStateZoomPan(animate){if(!this._thumbBounds)return;const{pswp}=this,{innerRect}=this._thumbBounds,{currSlide,viewportSize}=pswp;if(this._croppedZoom&&innerRect&&this._cropContainer1&&this._cropContainer2){const containerOnePanX=-viewportSize.x+(this._thumbBounds.x-innerRect.x)+innerRect.w,containerOnePanY=-viewportSize.y+(this._thumbBounds.y-innerRect.y)+innerRect.h,containerTwoPanX=viewportSize.x-innerRect.w,containerTwoPanY=viewportSize.y-innerRect.h;animate?(this._animateTo(this._cropContainer1,"transform",photoswipe_esm_toTransformString(containerOnePanX,containerOnePanY)),this._animateTo(this._cropContainer2,"transform",photoswipe_esm_toTransformString(containerTwoPanX,containerTwoPanY))):(setTransform(this._cropContainer1,containerOnePanX,containerOnePanY),setTransform(this._cropContainer2,containerTwoPanX,containerTwoPanY))}currSlide&&(equalizePoints(currSlide.pan,innerRect||this._thumbBounds),currSlide.currZoomLevel=this._thumbBounds.w/currSlide.width,animate?this._animateTo(currSlide.container,"transform",currSlide.getCurrentTransform()):currSlide.applyCurrentZoomPan())}_animateTo(target,prop,propValue){if(!this._duration){target.style[prop]=propValue;return}const{animations}=this.pswp,animProps={duration:this._duration,easing:this.pswp.options.easing,onComplete:()=>{animations.activeAnimations.length||this._onAnimationComplete()},target};animProps[prop]=propValue,animations.startTransition(animProps)}}const defaultOptions={allowPanToNext:!0,spacing:.1,loop:!0,pinchToClose:!0,closeOnVerticalDrag:!0,hideAnimationDuration:333,showAnimationDuration:333,zoomAnimationDuration:333,escKey:!0,arrowKeys:!0,trapFocus:!0,returnFocus:!0,maxWidthToAnimate:4e3,clickToCloseNonZoomable:!0,imageClickAction:"zoom-or-close",bgClickAction:"close",tapAction:"toggle-controls",doubleTapAction:"zoom",indexIndicatorSep:" / ",preloaderDelay:2e3,bgOpacity:.8,index:0,errorMsg:"The image cannot be loaded",preload:[1,2],easing:"cubic-bezier(.4,0,.22,1)"};class PhotoSwipe extends photoswipe_esm_PhotoSwipeBase{constructor(options){super(),this.options=this._prepareOptions(options||{}),this.offset={x:0,y:0},this._prevViewportSize={x:0,y:0},this.viewportSize={x:0,y:0},this.bgOpacity=1,this.currIndex=0,this.potentialIndex=0,this.isOpen=!1,this.isDestroying=!1,this.hasMouse=!1,this._initialItemData={},this._initialThumbBounds=void 0,this.topBar=void 0,this.element=void 0,this.template=void 0,this.container=void 0,this.scrollWrap=void 0,this.currSlide=void 0,this.events=new DOMEvents,this.animations=new Animations,this.mainScroll=new MainScroll(this),this.gestures=new Gestures(this),this.opener=new Opener(this),this.keyboard=new Keyboard(this),this.contentLoader=new ContentLoader(this)}init(){if(this.isOpen||this.isDestroying)return!1;this.isOpen=!0,this.dispatch("init"),this.dispatch("beforeOpen"),this._createMainStructure();let rootClasses="pswp--open";return this.gestures.supportsTouch&&(rootClasses+=" pswp--touch"),this.options.mainClass&&(rootClasses+=" "+this.options.mainClass),this.element&&(this.element.className+=" "+rootClasses),this.currIndex=this.options.index||0,this.potentialIndex=this.currIndex,this.dispatch("firstUpdate"),this.scrollWheel=new ScrollWheel(this),(Number.isNaN(this.currIndex)||this.currIndex<0||this.currIndex>=this.getNumItems())&&(this.currIndex=0),this.gestures.supportsTouch||this.mouseDetected(),this.updateSize(),this.offset.y=window.pageYOffset,this._initialItemData=this.getItemData(this.currIndex),this.dispatch("gettingData",{index:this.currIndex,data:this._initialItemData,slide:void 0}),this._initialThumbBounds=this.getThumbBounds(),this.dispatch("initialLayout"),this.on("openingAnimationEnd",()=>{const{itemHolders}=this.mainScroll;itemHolders[0]&&(itemHolders[0].el.style.display="block",this.setContent(itemHolders[0],this.currIndex-1)),itemHolders[2]&&(itemHolders[2].el.style.display="block",this.setContent(itemHolders[2],this.currIndex+1)),this.appendHeavy(),this.contentLoader.updateLazy(),this.events.add(window,"resize",this._handlePageResize.bind(this)),this.events.add(window,"scroll",this._updatePageScrollOffset.bind(this)),this.dispatch("bindEvents")}),this.mainScroll.itemHolders[1]&&this.setContent(this.mainScroll.itemHolders[1],this.currIndex),this.dispatch("change"),this.opener.open(),this.dispatch("afterInit"),!0}getLoopedIndex(index){const numSlides=this.getNumItems();return this.options.loop&&(index>numSlides-1&&(index-=numSlides),index<0&&(index+=numSlides)),clamp(index,0,numSlides-1)}
vendor: 4,100 bytes, line 7
7appendHeavy(){this.mainScroll.itemHolders.forEach(itemHolder=>{var _itemHolder$slide;(_itemHolder$slide=itemHolder.slide)===null||_itemHolder$slide===void 0||_itemHolder$slide.appendHeavy()})}goTo(index){this.mainScroll.moveIndexBy(this.getLoopedIndex(index)-this.potentialIndex)}next(){this.goTo(this.potentialIndex+1)}prev(){this.goTo(this.potentialIndex-1)}zoomTo(...args){var _this$currSlide;(_this$currSlide=this.currSlide)===null||_this$currSlide===void 0||_this$currSlide.zoomTo(...args)}toggleZoom(){var _this$currSlide2;(_this$currSlide2=this.currSlide)===null||_this$currSlide2===void 0||_this$currSlide2.toggleZoom()}close(){!this.opener.isOpen||this.isDestroying||(this.isDestroying=!0,this.dispatch("close"),this.events.removeAll(),this.opener.close())}destroy(){var _this$element;if(!this.isDestroying){this.options.showHideAnimationType="none",this.close();return}this.dispatch("destroy"),this._listeners={},this.scrollWrap&&(this.scrollWrap.ontouchmove=null,this.scrollWrap.ontouchend=null),(_this$element=this.element)===null||_this$element===void 0||_this$element.remove(),this.mainScroll.itemHolders.forEach(itemHolder=>{var _itemHolder$slide2;(_itemHolder$slide2=itemHolder.slide)===null||_itemHolder$slide2===void 0||_itemHolder$slide2.destroy()}),this.contentLoader.destroy(),this.events.removeAll()}refreshSlideContent(slideIndex){this.contentLoader.removeByIndex(slideIndex),this.mainScroll.itemHolders.forEach((itemHolder,i)=>{var _this$currSlide$index,_this$currSlide3;let potentialHolderIndex=((_this$currSlide$index=(_this$currSlide3=this.currSlide)===null||_this$currSlide3===void 0?void 0:_this$currSlide3.index)!==null&&_this$currSlide$index!==void 0?_this$currSlide$index:0)-1+i;if(this.canLoop()&&(potentialHolderIndex=this.getLoopedIndex(potentialHolderIndex)),potentialHolderIndex===slideIndex&&(this.setContent(itemHolder,slideIndex,!0),i===1)){var _itemHolder$slide3;this.currSlide=itemHolder.slide,(_itemHolder$slide3=itemHolder.slide)===null||_itemHolder$slide3===void 0||_itemHolder$slide3.setIsActive(!0)}}),this.dispatch("change")}setContent(holder,index,force){if(this.canLoop()&&(index=this.getLoopedIndex(index)),holder.slide){if(holder.slide.index===index&&!force)return;holder.slide.destroy(),holder.slide=void 0}if(!this.canLoop()&&(index<0||index>=this.getNumItems()))return;const itemData=this.getItemData(index);holder.slide=new Slide(itemData,index,this),index===this.currIndex&&(this.currSlide=holder.slide),holder.slide.append(holder.el)}getViewportCenterPoint(){return{x:this.viewportSize.x/2,y:this.viewportSize.y/2}}updateSize(force){if(this.isDestroying)return;const newViewportSize=photoswipe_esm_getViewportSize(this.options,this);!force&&pointsEqual(newViewportSize,this._prevViewportSize)||(equalizePoints(this._prevViewportSize,newViewportSize),this.dispatch("beforeResize"),equalizePoints(this.viewportSize,this._prevViewportSize),this._updatePageScrollOffset(),this.dispatch("viewportSize"),this.mainScroll.resize(this.opener.isOpen),!this.hasMouse&&window.matchMedia("(any-hover: hover)").matches&&this.mouseDetected(),this.dispatch("resize"))}applyBgOpacity(opacity){this.bgOpacity=Math.max(opacity,0),this.bg&&(this.bg.style.opacity=String(this.bgOpacity*this.options.bgOpacity))}mouseDetected(){if(!this.hasMouse){var _this$element2;this.hasMouse=!0,(_this$element2=this.element)===null||_this$element2===void 0||_this$element2.classList.add("pswp--has_mouse")}}_handlePageResize(){this.updateSize(),/iPhone|iPad|iPod/i.test(window.navigator.userAgent)&&setTimeout(()=>{this.updateSize()},500)}_updatePageScrollOffset(){this.setScrollOffset(0,window.pageYOffset)}setScrollOffset(x,y){this.offset.x=x,this.offset.y=y,this.dispatch("updateScrollOffset")}_createMainStructure(){this.element=photoswipe_esm_createElement("pswp","div"),this.element.setAttribute("tabindex","-1"),this.element.setAttribute("role","dialog"),this.template=this.element,this.bg=photoswipe_esm_createElement("pswp__bg","div",this.element),this.scrollWrap=photoswipe_esm_createElement("pswp__scroll-wrap","section",this.element),this.container=photoswipe_esm_
7createElement("pswp__container","div",this.scrollWrap),this.scrollWrap.setAttribute("aria-roledescription","carousel"),this.container.setAttribute("aria-live","off"),this.container.setAttribute("id","pswp__items"),this.mainScroll.appendHolders(),this.ui=new UI(this),this.ui.init(),(this.options.appendToEl||document.body).appendChild(this.element)}getThumbBounds(){return getThumbBounds(this.currIndex,this.currSlide?this.currSlide.data:this._initialItemData,this)}canLoop(){return this.options.loop&&this.getNumItems()>2}_prepareOptions(options){return window.matchMedia("(prefers-reduced-motion), (update: slow)").matches&&(options.showHideAnimationType="none",options.zoomAnimationDuration=0),{...defaultOptions,...options}}}if(!customElements.get("product-media-grid")){class ProductMediaGrid extends HTMLElement{constructor(){super(),this.mainMediaId=this.getAttribute("id")}connectedCallback(){this.initPhotoSwipe(),this.attachEventListeners()}attachEventListeners(){window.addEventListener("resize",this.handleResize)}initPhotoSwipe(){const leftArrowSVG='<svg viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg" width="20" height="20" class="pswp__icn"><path d="M13 5L8 10L13 15" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>',zoomSVGs='<svg viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg" width="20" height="20" class="pswp__icn" id="pswp__icn--zoom-in"><path d="M6.66667 9.16667H9.16667M9.16667 9.16667H11.6667M9.16667 9.16667V6.66667M9.16667 9.16667V11.6667M14.1667 14.1667L17.5 17.5M2.5 9.16667C2.5 10.9348 3.20238 12.6305 4.45262 13.8807C5.70286 15.131 7.39856 15.8333 9.16667 15.8333C10.9348 15.8333 12.6305 15.131 13.8807 13.8807C15.131 12.6305 15.8333 10.9348 15.8333 9.16667C15.8333 7.39856 15.131 5.70286 13.8807 4.45262C12.6305 3.20238 10.9348 2.5 9.16667 2.5C7.39856 2.5 5.70286 3.20238 4.45262 4.45262C3.20238 5.70286 2.5 7.39856 2.5 9.16667Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>'+'<svg viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg" width="20" height="20" class="pswp__icn" id="pswp__icn--zoom-out"><path d="M14.1667 14.1667L17.5 17.5M6.66667 9.16667H11.6667M2.5 9.16667C2.5 10.9348 3.20238 12.6305 4.45262 13.8807C5.70286 15.131 7.39856 15.8333 9.16667 15.8333C10.9348 15.8333 12.6305 15.131 13.8807 13.8807C15.131 12.6305 15.8333 10.9348 15.8333 9.16667C15.8333 7.39856 15.131 5.70286 13.8807 4.45262C12.6305 3.20238 10.9348 2.5 9.16667 2.5C7.39856 2.5 5.70286 3.20238 4.45262 4.45262C3.20238 5.70286 2.5 7.39856 2.5 9.16667Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>',closeSVG='<svg viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg" width="20" height="20" class="pswp__icn"><path d="M5.63086 14.3692L10 10L14.3692 14.3692M14.3692 5.63086L9.99919 10L5.63086 5.63086" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>',lightbox=new PhotoSwipeLightbox({mainClass:"pswp--custom-colors",gallery:`product-media-grid[id="${this.mainMediaId}"] [data-media-main]`,children:"a[data-main-media-link]",bgOpacity:1,showAnimationDuration:200,hideAnimationDuration:200,arrowPrevSVG:leftArrowSVG,arrowNextSVG:leftArrowSVG,zoomSVG:zoomSVGs,closeSVG,pswpModule:PhotoSwipe});lightbox.on("uiRegister",function(){lightbox.pswp.ui.registerElement({name:"bulletsIndicator",className:"pswp__bullets-indicator",appendTo:"wrapper",onInit:(el,pswp)=>{const bullets=[];let bullet,prevIndex=-1;for(let i=0;i<pswp.getNumItems();i++)bullet=document.createElement("div"),bullet.className="pswp__bullet",bullet.onclick=e=>{pswp.goTo(bullets.indexOf(e.target))},el.appendChild(bullet),bullets.push(bullet);pswp.on("change",a=>{prevIndex>=0&&bullets[prevIndex].classList.remove("pswp__bullet--active"),bullets[pswp.currIndex].classList.add("pswp__bullet--active"),prevIndex=pswp.currIndex})}})}),lightbox.on("beforeChange",function(){lightbox.template.classList.add("pswp--animated")}),lightbox.init()}handleResize(){window.eventBus.emit("pause:media")}
7}customElements.define("product-media-grid",ProductMediaGrid)}})();
8//# sourceMappingURL=/cdn/shop/t/14/assets/component-product-media-grid.js.map?v=113257096557171887411742578152

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.