1/* 2 * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development"). 3 * This devtool is neither made for production nor for readable output files. 4 * It uses "eval()" calls to create a separate source file in the browser devtools. 5 * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/) 6 * or disable the default devtool with "devtool: false". 7 * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/). 8 */ 9/******/ (() => { // webpackBootstrap 10/******/ var __webpack_modules__ = ({ 11 12/***/ "./node_modules/@fancyapps/ui/dist/index.esm.js" 13/*!******************************************************!*\ 14 !*** ./node_modules/@fancyapps/ui/dist/index.esm.js ***! 15 \******************************************************/ 16(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 17 18"use strict"; 19eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Carousel: () => (/* binding */ Q),\n/* harmony export */ Fancybox: () => (/* binding */ Oe),\n/* harmony export */ Panzoom: () => (/* binding */ I)\n/* harmony export */ });\nconst t=(t,e=1e4)=>(t=parseFloat(t+\"\")||0,Math.round((t+Number.EPSILON)*e)/e),e=function(t){if(!(t&&t instanceof Element&&t.offsetParent))return!1;const e=t.scrollHeight>t.clientHeight,i=window.getComputedStyle(t).overflowY,n=-1!==i.indexOf(\"hidden\"),s=-1!==i.indexOf(\"visible\");return e&&!n&&!s},i=function(t,n=void 0){return!(!t||t===document.body||n&&t===n)&&(e(t)?t:i(t.parentElement,n))},n=function(t){var e=(new DOMParser).parseFromString(t,\"text/html\").body;if(e.childElementCount>1){for(var i=document.createElement(\"div\");e.firstChild;)i.appendChild(e.firstChild);return i}return e.firstChild},s=t=>`${t||\"\"}`.split(\" \").filter((t=>!!t)),o=(t,e,i)=>{t&&s(e).forEach((e=>{t.classList.toggle(e,i||!1)}))};class a{constructor(t){Object.defineProperty(this,\"pageX\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"pageY\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"clientX\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"clientY\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"id\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"time\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"nativePointer\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.nativePointer=t,this.pageX=t.pageX,this.pageY=t.pageY,this.clientX=t.clientX,this.clientY=t.clientY,this.id=self.Touch&&t instanceof Touch?t.identifier:-1,this.time=Date.now()}}const r={passive:!1};class l{constructor(t,{start:e=(()=>!0),move:i=(()=>{}),end:n=(()=>{})}){Object.defineProperty(this,\"element\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"startCallback\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"moveCallback\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"endCallback\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"currentPointers\",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,\"startPointers\",{enumerable:!0,configurable:!0,writable:!0,value:[]}),this.element=t,this.startCallback=e,this.moveCallback=i,this.endCallback=n;for(const t of[\"onPointerStart\",\"onTouchStart\",\"onMove\",\"onTouchEnd\",\"onPointerEnd\",\"onWindowBlur\"])this[t]=this[t].bind(this);this.element.addEventListener(\"mousedown\",this.onPointerStart,r),this.element.addEventListener(\"touchstart\",this.onTouchStart,r),this.element.addEventListener(\"touchmove\",this.onMove,r),this.element.addEventListener(\"touchend\",this.onTouchEnd),this.element.addEventListener(\"touchcancel\",this.onTouchEnd)}onPointerStart(t){if(!t.buttons||0!==t.button)return;const e=new a(t);this.currentPointers.some((t=>
19t.id===e.id))||this.triggerPointerStart(e,t)&&(window.addEventListener(\"mousemove\",this.onMove),window.addEventListener(\"mouseup\",this.onPointerEnd),window.addEventListener(\"blur\",this.onWindowBlur))}onTouchStart(t){for(const e of Array.from(t.changedTouches||[]))this.triggerPointerStart(new a(e),t);window.addEventListener(\"blur\",this.onWindowBlur)}onMove(t){const e=this.currentPointers.slice(),i=\"changedTouches\"in t?Array.from(t.changedTouches||[]).map((t=>new a(t))):[new a(t)],n=[];for(const t of i){const e=this.currentPointers.findIndex((e=>e.id===t.id));e<0||(n.push(t),this.currentPointers[e]=t)}n.length&&this.moveCallback(t,this.currentPointers.slice(),e)}onPointerEnd(t){t.buttons>0&&0!==t.button||(this.triggerPointerEnd(t,new a(t)),window.removeEventListener(\"mousemove\",this.onMove),window.removeEventListener(\"mouseup\",this.onPointerEnd),window.removeEventListener(\"blur\",this.onWindowBlur))}onTouchEnd(t){for(const e of Array.from(t.changedTouches||[]))this.triggerPointerEnd(t,new a(e))}triggerPointerStart(t,e){return!!this.startCallback(e,t,this.currentPointers.slice())&&(this.currentPointers.push(t),this.startPointers.push(t),!0)}triggerPointerEnd(t,e){const i=this.currentPointers.findIndex((t=>t.id===e.id));i<0||(this.currentPointers.splice(i,1),this.startPointers.splice(i,1),this.endCallback(t,e,this.currentPointers.slice()))}onWindowBlur(){this.clear()}clear(){for(;this.currentPointers.length;){const t=this.currentPointers[this.currentPointers.length-1];this.currentPointers.splice(this.currentPointers.length-1,1),this.startPointers.splice(this.currentPointers.length-1,1),this.endCallback(new Event(\"touchend\",{bubbles:!0,cancelable:!0,clientX:t.clientX,clientY:t.clientY}),t,this.currentPointers.slice())}}stop(){this.element.removeEventListener(\"mousedown\",this.onPointerStart,r),this.element.removeEventListener(\"touchstart\",this.onTouchStart,r),this.element.removeEventListener(\"touchmove\",this.onMove,r),this.element.removeEventListener(\"touchend\",this.onTouchEnd),this.element.removeEventListener(\"touchcancel\",this.onTouchEnd),window.removeEventListener(\"mousemove\",this.onMove),window.removeEventListener(\"mouseup\",this.onPointerEnd),window.removeEventListener(\"blur\",this.onWindowBlur)}}function c(t,e){return e?Math.sqrt(Math.pow(e.clientX-t.clientX,2)+Math.pow(e.clientY-t.clientY,2)):0}function h(t,e){return e?{clientX:(t.clientX+e.clientX)/2,clientY:(t.clientY+e.clientY)/2}:t}const d=t=>\"object\"==typeof t&&null!==t&&t.constructor===Object&&\"[object Object]\"===Object.prototype.toString.call(t),u=(t,...e)=>{const i=e.length;for(let n=0;n<i;n++){const i=e[n]||{};Object.entries(i).forEach((([e,i])=>{const n=Array.isArray(i)?[]:{};t[e]||Object.assign(t,{[e]:n}),d(i)?Object.assign(t[e],u(n,i)):Array.isArray(i)?Object.assign(t,{[e]:[...i]}):Object.assign(t,{[e]:i})}))}return t},p=function(t,e){return t.split(\".\").reduce(((t,e)=>\"object\"==typeof t?t[e]:void 0),e)};class f{constructor(t={}){Object.defineProperty(this,\"options\",{enumerable:!0,configurable:!0,writable:!0,value:t}),Object.defineProperty(this,\"events\",{enumerable:!0,configurable:!0,writable:!0,value:new Map}),this.setOptions(t);for(const t of Object.getOwnPropertyNames(Object.getPrototypeOf(this)))t.startsWith(\"on\")&&\"function\"==typeof this[t]&&(this[t]=this[t].bind(this))}setOptions(t){this.options=t?u({},this.constructor.defaults,t):{};for(const[t,e]of Object.entries(this.option(\"on\")||{}))this.on(t,e)}option(t,...e){let i=p(t,this.options);return i&&\"function\"==typeof i&&(i=i.call(this,this,...e)),i}optionFor(t,e,i,...n){let s=p(e,t);var o;\"string\"!=typeof(o=s)||isNaN(o)||isNaN(parseFloat(o))||(s=parseFloat(s)),\"true\"===s&&(s=!0),\"false\"===s&&(s=!1),s&&\"function\"==typeof s&&(s=s.call(this,this,t,...n));let a=p(e,this.options);return a&&\"function\"==typeof a?s=a.call(this,this,t,...n,s):void 0===s&&(s=a),void 0===s?i:s}cn(t){const e=this.options.classes;return e&&e[t]||\"\"}localize(t,e=[]){t=String(t).replace(/\\{\\{(\\w+).?(\\w+)?\\}\\}/g,((t,e,i)=>{let n=\"\";return i?n=this.option(`${e[0]+e.toLowerCase().substring(1)}.l10n.${i}`):e&&(n=this.option(`l10n.${e}`)),n||(n=t),n}));for(let i=0;i<e.length;i++)t=t.split(e[i][0]).join(e[i][1]);return t=t.replace(/\\{\\{(.*?)\\}\\}/g,((t,e)=>e))}on(t,e){let i=[];
19\"string\"==typeof t?i=t.split(\" \"):Array.isArray(t)&&(i=t),this.events||(this.events=new Map),i.forEach((t=>{let i=this.events.get(t);i||(this.events.set(t,[]),i=[]),i.includes(e)||i.push(e),this.events.set(t,i)}))}off(t,e){let i=[];\"string\"==typeof t?i=t.split(\" \"):Array.isArray(t)&&(i=t),i.forEach((t=>{const i=this.events.get(t);if(Array.isArray(i)){const t=i.indexOf(e);t>-1&&i.splice(t,1)}}))}emit(t,...e){[...this.events.get(t)||[]].forEach((t=>t(this,...e))),\"*\"!==t&&this.emit(\"*\",t,...e)}}Object.defineProperty(f,\"version\",{enumerable:!0,configurable:!0,writable:!0,value:\"5.0.36\"}),Object.defineProperty(f,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:{}});class g extends f{constructor(t={}){super(t),Object.defineProperty(this,\"plugins\",{enumerable:!0,configurable:!0,writable:!0,value:{}})}attachPlugins(t={}){const e=new Map;for(const[i,n]of Object.entries(t)){const t=this.option(i),s=this.plugins[i];s||!1===t?s&&!1===t&&(s.detach(),delete this.plugins[i]):e.set(i,new n(this,t||{}))}for(const[t,i]of e)this.plugins[t]=i,i.attach()}detachPlugins(t){t=t||Object.keys(this.plugins);for(const e of t){const t=this.plugins[e];t&&t.detach(),delete this.plugins[e]}return this.emit(\"detachPlugins\"),this}}var m;!function(t){t[t.Init=0]=\"Init\",t[t.Error=1]=\"Error\",t[t.Ready=2]=\"Ready\",t[t.Panning=3]=\"Panning\",t[t.Mousemove=4]=\"Mousemove\",t[t.Destroy=5]=\"Destroy\"}(m||(m={}));const v=[\"a\",\"b\",\"c\",\"d\",\"e\",\"f\"],b={PANUP:\"Move up\",PANDOWN:\"Move down\",PANLEFT:\"Move left\",PANRIGHT:\"Move right\",ZOOMIN:\"Zoom in\",ZOOMOUT:\"Zoom out\",TOGGLEZOOM:\"Toggle zoom level\",TOGGLE1TO1:\"Toggle zoom level\",ITERATEZOOM:\"Toggle zoom level\",ROTATECCW:\"Rotate counterclockwise\",ROTATECW:\"Rotate clockwise\",FLIPX:\"Flip horizontally\",FLIPY:\"Flip vertically\",FITX:\"Fit horizontally\",FITY:\"Fit vertically\",RESET:\"Reset\",TOGGLEFS:\"Toggle fullscreen\"},y={content:null,width:\"auto\",height:\"auto\",panMode:\"drag\",touch:!0,dragMinThreshold:3,lockAxis:!1,mouseMoveFactor:1,mouseMoveFriction:.12,zoom:!0,pinchToZoom:!0,panOnlyZoomed:\"auto\",minScale:1,maxScale:2,friction:.25,dragFriction:.35,decelFriction:.05,click:\"toggleZoom\",dblClick:!1,wheel:\"zoom\",wheelLimit:7,spinner:!0,bounds:\"auto\",infinite:!1,rubberband:!0,bounce:!0,maxVelocity:75,transformParent:!1,classes:{content:\"f-panzoom__content\",isLoading:\"is-loading\",canZoomIn:\"can-zoom_in\",canZoomOut:\"can-zoom_out\",isDraggable:\"is-draggable\",isDragging:\"is-dragging\",inFullscreen:\"in-fullscreen\",htmlHasFullscreen:\"with-panzoom-in-fullscreen\"},l10n:b},w='<circle cx=\"25\" cy=\"25\" r=\"20\"></circle>',x='<div class=\"f-spinner\"><svg viewBox=\"0 0 50 50\">'+w+w+\"</svg></div>\",E=t=>t&&null!==t&&t instanceof Element&&\"nodeType\"in t,S=(t,e)=>{t&&s(e).forEach((e=>{t.classList.remove(e)}))},P=(t,e)=>{t&&s(e).forEach((e=>{t.classList.add(e)}))},C={a:1,b:0,c:0,d:1,e:0,f:0},T=1e5,M=1e4,O=\"mousemove\",A=\"drag\",L=\"content\",z=\"auto\";let R=null,k=null;class I extends g{get fits(){return this.contentRect.width-this.contentRect.fitWidth<1&&this.contentRect.height-this.contentRect.fitHeight<1}get isTouchDevice(){return null===k&&(k=window.matchMedia(\"(hover: none)\").matches),k}get isMobile(){return null===R&&(R=/iPhone|iPad|iPod|Android/i.test(navigator.userAgent)),R}get panMode(){return this.options.panMode!==O||this.isTouchDevice?A:O}get panOnlyZoomed(){const t=this.options.panOnlyZoomed;return t===z?this.isTouchDevice:t}get isInfinite(){return this.option(\"infinite\")}get angle(){return 180*Math.atan2(this.current.b,this.current.a)/Math.PI||0}get targetAngle(){return 180*Math.atan2(this.target.b,this.target.a)/Math.PI||0}get scale(){const{a:t,b:e}=this.current;return Math.sqrt(t*t+e*e)||1}get targetScale(){const{a:t,b:e}=this.target;return Math.sqrt(t*t+e*e)||1}get minScale(){return this.option(\"minScale\")||1}get fullScale(){const{contentRect:t}=this;return t.fullWidth/t.fitWidth||1}get maxScale(){return this.fullScale*(this.option(\"maxScale\")||1)||1}get coverScale(){const{containerRect:t,contentRect:e}=this,i=Math.max(t.height/e.fitHeight,t.width/e.fitWidth)||1;return Math.min(this.fullScale,i)}get isScaling(){return Math.abs(this.targetScale-this.scale)>1e-5&&!this.isResting}get isContentLoading(){const t=this.content;return!!(t&&t instanceof HTMLImageElement)&&!t.complete}get isResting(){if(this.isBouncingX||this.isBouncingY)return!1;for(const t of v){const e=\"e\"==t||\"f\"===t?1e-4:1e-5;
19if(Math.abs(this.target[t]-this.current[t])>e)return!1}return!(!this.ignoreBounds&&!this.checkBounds().inBounds)}constructor(t,e={},i={}){var s;if(super(e),Object.defineProperty(this,\"pointerTracker\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"resizeObserver\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"updateTimer\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"clickTimer\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"rAF\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"isTicking\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,\"ignoreBounds\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,\"isBouncingX\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,\"isBouncingY\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,\"clicks\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"trackingPoints\",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,\"pwt\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"cwd\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"pmme\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"friction\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"state\",{enumerable:!0,configurable:!0,writable:!0,value:m.Init}),Object.defineProperty(this,\"isDragging\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,\"container\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"content\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"spinner\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"containerRect\",{enumerable:!0,configurable:!0,writable:!0,value:{width:0,height:0,innerWidth:0,innerHeight:0}}),Object.defineProperty(this,\"contentRect\",{enumerable:!0,configurable:!0,writable:!0,value:{top:0,right:0,bottom:0,left:0,fullWidth:0,fullHeight:0,fitWidth:0,fitHeight:0,width:0,height:0}}),Object.defineProperty(this,\"dragStart\",{enumerable:!0,configurable:!0,writable:!0,value:{x:0,y:0,top:0,left:0,time:0}}),Object.defineProperty(this,\"dragOffset\",{enumerable:!0,configurable:!0,writable:!0,value:{x:0,y:0,time:0}}),Object.defineProperty(this,\"current\",{enumerable:!0,configurable:!0,writable:!0,value:Object.assign({},C)}),Object.defineProperty(this,\"target\",{enumerable:!0,configurable:!0,writable:!0,value:Object.assign({},C)}),Object.defineProperty(this,\"velocity\",{enumerable:!0,configurable:!0,writable:!0,value:{a:0,b:0,c:0,d:0,e:0,f:0}}),Object.defineProperty(this,\"lockedAxis\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),!t)throw new Error(\"Container Element Not Found\");this.container=t,this.initContent(),this.attachPlugins(Object.assign(Object.assign({},I.Plugins),i)),this.emit(\"attachPlugins\"),this.emit(\"init\");const o=this.content;if(o.addEventListener(\"load\",this.onLoad),o.addEventListener(\"error\",this.onError),this.isContentLoading){if(this.option(\"spinner\")){t.classList.add(this.cn(\"isLoading\"));const e=n(x);!t.contains(o)||o.parentElement instanceof HTMLPictureElement?this.spinner=t.appendChild(e):this.spinner=(null===(s=o.parentElement)||void 0===s?void 0:s.insertBefore(e,o))||null}this.emit(\"beforeLoad\")}else queueMicrotask((()=>{this.enable()}))}initContent(){const{container:t}=this,e=this.cn(L);let i=this.option(L)||t.querySelector(`.${e}`);if(i||(i=t.querySelector(\"img,picture\")||t.firstElementChild,i&&P(i,e)),i instanceof HTMLPictureElement&&(i=i.querySelector(\"img\")),!i)throw new Error(\"No content found\");this.content=i}onLoad(){const{spinner:t,container:e,state:i}=this;t&&(t.remove(),this.spinner=null),this.option(\"spinner\")&&e.classList.remove(this.cn(\"isLoading\")),this.emit
19(\"afterLoad\"),i===m.Init?this.enable():this.updateMetrics()}onError(){this.state!==m.Destroy&&(this.spinner&&(this.spinner.remove(),this.spinner=null),this.stop(),this.detachEvents(),this.state=m.Error,this.emit(\"error\"))}getNextScale(t){const{fullScale:e,targetScale:i,coverScale:n,maxScale:s,minScale:o}=this;let a=o;switch(t){case\"toggleMax\":a=i-o<.5*(s-o)?s:o;break;case\"toggleCover\":a=i-o<.5*(n-o)?n:o;break;case\"toggleZoom\":a=i-o<.5*(e-o)?e:o;break;case\"iterateZoom\":let t=[1,e,s].sort(((t,e)=>t-e)),r=t.findIndex((t=>t>i+1e-5));a=t[r]||1}return a}attachObserver(){var t;const e=()=>{const{container:t,containerRect:e}=this;return Math.abs(e.width-t.getBoundingClientRect().width)>.1||Math.abs(e.height-t.getBoundingClientRect().height)>.1};this.resizeObserver||void 0===window.ResizeObserver||(this.resizeObserver=new ResizeObserver((()=>{this.updateTimer||(e()?(this.onResize(),this.isMobile&&(this.updateTimer=setTimeout((()=>{e()&&this.onResize(),this.updateTimer=null}),500))):this.updateTimer&&(clearTimeout(this.updateTimer),this.updateTimer=null))}))),null===(t=this.resizeObserver)||void 0===t||t.observe(this.container)}detachObserver(){var t;null===(t=this.resizeObserver)||void 0===t||t.disconnect()}attachEvents(){const{container:t}=this;t.addEventListener(\"click\",this.onClick,{passive:!1,capture:!1}),t.addEventListener(\"wheel\",this.onWheel,{passive:!1}),this.pointerTracker=new l(t,{start:this.onPointerDown,move:this.onPointerMove,end:this.onPointerUp}),document.addEventListener(O,this.onMouseMove)}detachEvents(){var t;const{container:e}=this;e.removeEventListener(\"click\",this.onClick,{passive:!1,capture:!1}),e.removeEventListener(\"wheel\",this.onWheel,{passive:!1}),null===(t=this.pointerTracker)||void 0===t||t.stop(),this.pointerTracker=null,document.removeEventListener(O,this.onMouseMove),document.removeEventListener(\"keydown\",this.onKeydown,!0),this.clickTimer&&(clearTimeout(this.clickTimer),this.clickTimer=null),this.updateTimer&&(clearTimeout(this.updateTimer),this.updateTimer=null)}animate(){this.setTargetForce();const t=this.friction,e=this.option(\"maxVelocity\");for(const i of v)t?(this.velocity[i]*=1-t,e&&!this.isScaling&&(this.velocity[i]=Math.max(Math.min(this.velocity[i],e),-1*e)),this.current[i]+=this.velocity[i]):this.current[i]=this.target[i];this.setTransform(),this.setEdgeForce(),!this.isResting||this.isDragging?this.rAF=requestAnimationFrame((()=>this.animate())):this.stop(\"current\")}setTargetForce(){for(const t of v)\"e\"===t&&this.isBouncingX||\"f\"===t&&this.isBouncingY||(this.velocity[t]=(1/(1-this.friction)-1)*(this.target[t]-this.current[t]))}checkBounds(t=0,e=0){const{current:i}=this,n=i.e+t,s=i.f+e,o=this.getBounds(),{x:a,y:r}=o,l=a.min,c=a.max,h=r.min,d=r.max;let u=0,p=0;return l!==1/0&&n<l?u=l-n:c!==1/0&&n>c&&(u=c-n),h!==1/0&&s<h?p=h-s:d!==1/0&&s>d&&(p=d-s),Math.abs(u)<1e-4&&(u=0),Math.abs(p)<1e-4&&(p=0),Object.assign(Object.assign({},o),{xDiff:u,yDiff:p,inBounds:!u&&!p})}clampTargetBounds(){const{target:t}=this,{x:e,y:i}=this.getBounds();e.min!==1/0&&(t.e=Math.max(t.e,e.min)),e.max!==1/0&&(t.e=Math.min(t.e,e.max)),i.min!==1/0&&(t.f=Math.max(t.f,i.min)),i.max!==1/0&&(t.f=Math.min(t.f,i.max))}calculateContentDim(t=this.current){const{content:e,contentRect:i}=this,{fitWidth:n,fitHeight:s,fullWidth:o,fullHeight:a}=i;let r=o,l=a;if(this.option(\"zoom\")||0!==this.angle){const i=!(e instanceof HTMLImageElement)&&(\"none\"===window.getComputedStyle(e).maxWidth||\"none\"===window.getComputedStyle(e).maxHeight),c=i?o:n,h=i?a:s,d=this.getMatrix(t),u=new DOMPoint(0,0).matrixTransform(d),p=new DOMPoint(0+c,0).matrixTransform(d),f=new DOMPoint(0+c,0+h).matrixTransform(d),g=new DOMPoint(0,0+h).matrixTransform(d),m=Math.abs(f.x-u.x),v=Math.abs(f.y-u.y),b=Math.abs(g.x-p.x),y=Math.abs(g.y-p.y);r=Math.max(m,b),l=Math.max(v,y)}return{contentWidth:r,contentHeight:l}}setEdgeForce(){if(this.ignoreBounds||this.isDragging||this.panMode===O||this.targetScale<this.scale)return this.isBouncingX=!1,void(this.isBouncingY=!1);const{target:t}=this,{x:e,y:i,xDiff:n,yDiff:s}=this.checkBounds();const o=this.option(\"maxVelocity\");let a=this.velocity.e,r=this.velocity.f;0!==n?(this.isBouncingX=!0,n*a<=0?a+=.14*n:(a=.14*n,e.min!==1/0&&(this.target.e=Math.max(t.e,e.min)),e.max!==1/0&&(this.target.e=Math.min(t.e,e.max))),o&&(a=Math.max(Math.min(a,o),-1*o))):this.isBouncingX=!1,0!==s?(this.isBouncingY=!0,s*r<=0?r+=.14*s:(r=.14*s,i.min!==1/0&&(this.target.f=Math.max(t.f,i.min)),i.max!==1/0&&(this.target.f=Math.min(t.f,i.max))),o&&(r=Math.max(Math.min(r,o),-1*o))):this.isBouncingY=!1,this.isBouncingX&&(this.velocity.e=a
19),this.isBouncingY&&(this.velocity.f=r)}enable(){const{content:t}=this,e=new DOMMatrixReadOnly(window.getComputedStyle(t).transform);for(const t of v)this.current[t]=this.target[t]=e[t];this.updateMetrics(),this.attachObserver(),this.attachEvents(),this.state=m.Ready,this.emit(\"ready\")}onClick(t){var e;\"click\"===t.type&&0===t.detail&&(this.dragOffset.x=0,this.dragOffset.y=0),this.isDragging&&(null===(e=this.pointerTracker)||void 0===e||e.clear(),this.trackingPoints=[],this.startDecelAnim());const i=t.target;if(!i||t.defaultPrevented)return;if(i.hasAttribute(\"disabled\"))return t.preventDefault(),void t.stopPropagation();if((()=>{const t=window.getSelection();return t&&\"Range\"===t.type})()&&!i.closest(\"button\"))return;const n=i.closest(\"[data-panzoom-action]\"),s=i.closest(\"[data-panzoom-change]\"),o=n||s,a=o&&E(o)?o.dataset:null;if(a){const e=a.panzoomChange,i=a.panzoomAction;if((e||i)&&t.preventDefault(),e){let t={};try{t=JSON.parse(e)}catch(t){console&&console.warn(\"The given data was not valid JSON\")}return void this.applyChange(t)}if(i)return void(this[i]&&this[i]())}if(Math.abs(this.dragOffset.x)>3||Math.abs(this.dragOffset.y)>3)return t.preventDefault(),void t.stopPropagation();if(i.closest(\"[data-fancybox]\"))return;const r=this.content.getBoundingClientRect(),l=this.dragStart;if(l.time&&!this.canZoomOut()&&(Math.abs(r.x-l.x)>2||Math.abs(r.y-l.y)>2))return;this.dragStart.time=0;const c=e=>{this.option(\"zoom\",t)&&e&&\"string\"==typeof e&&/(iterateZoom)|(toggle(Zoom|Full|Cover|Max)|(zoomTo(Fit|Cover|Max)))/.test(e)&&\"function\"==typeof this[e]&&(t.preventDefault(),this[e]({event:t}))},h=this.option(\"click\",t),d=this.option(\"dblClick\",t);d?(this.clicks++,1==this.clicks&&(this.clickTimer=setTimeout((()=>{1===this.clicks?(this.emit(\"click\",t),!t.defaultPrevented&&h&&c(h)):(this.emit(\"dblClick\",t),t.defaultPrevented||c(d)),this.clicks=0,this.clickTimer=null}),350))):(this.emit(\"click\",t),!t.defaultPrevented&&h&&c(h))}addTrackingPoint(t){const e=this.trackingPoints.filter((t=>t.time>Date.now()-100));e.push(t),this.trackingPoints=e}onPointerDown(t,e,i){var n;if(!1===this.option(\"touch\",t))return!1;this.pwt=0,this.dragOffset={x:0,y:0,time:0},this.trackingPoints=[];const s=this.content.getBoundingClientRect();if(this.dragStart={x:s.x,y:s.y,top:s.top,left:s.left,time:Date.now()},this.clickTimer)return!1;if(this.panMode===O&&this.targetScale>1)return t.preventDefault(),t.stopPropagation(),!1;const o=t.composedPath()[0];if(!i.length){if([\"TEXTAREA\",\"OPTION\",\"INPUT\",\"SELECT\",\"VIDEO\",\"IFRAME\"].includes(o.nodeName)||o.closest(\"[contenteditable],[data-selectable],[data-draggable],[data-clickable],[data-panzoom-change],[data-panzoom-action]\"))return!1;null===(n=window.getSelection())||void 0===n||n.removeAllRanges()}if(\"mousedown\"===t.type)[\"A\",\"BUTTON\"].includes(o.nodeName)||t.preventDefault();else if(Math.abs(this.velocity.a)>.3)return!1;return this.target.e=this.current.e,this.target.f=this.current.f,this.stop(),this.isDragging||(this.isDragging=!0,this.addTrackingPoint(e),this.emit(\"touchStart\",t)),!0}onPointerMove(e,n,s){if(!1===this.option(\"touch\",e))return;if(!this.isDragging)return;if(n.length<2&&this.panOnlyZoomed&&t(this.targetScale)<=t(this.minScale))return;if(this.emit(\"touchMove\",e),e.defaultPrevented)return;this.addTrackingPoint(n[0]);const{content:o}=this,a=h(s[0],s[1]),r=h(n[0],n[1]);let l=0,d=0;if(n.length>1){const t=o.getBoundingClientRect();l=a.clientX-t.left-.5*t.width,d=a.clientY-t.top-.5*t.height}const u=c(s[0],s[1]),p=c(n[0],n[1]);let f=u?p/u:1,g=r.clientX-a.clientX,m=r.clientY-a.clientY;this.dragOffset.x+=g,this.dragOffset.y+=m,this.dragOffset.time=Date.now()-this.dragStart.time;let v=t(this.targetScale)===t(this.minScale)&&this.option(\"lockAxis\");if(v&&!this.lockedAxis)if(\"xy\"===v||\"y\"===v||\"touchmove\"===e.type){if(Math.abs(this.dragOffset.x)<6&&Math.abs(this.dragOffset.y)<6)return void e.preventDefault();const t=Math.abs(180*Math.atan2(this.dragOffset.y,this.dragOffset.x)/Math.PI);this.lockedAxis=t>45&&t<135?\"y\":\"x\",this.dragOffset.x=0,this.dragOffset.y=0,g=0,m=0}else this.lockedAxis=v;if(i(e.target,this.content)&&(v=\"x\",this.dragOffset.y=0),v&&\"xy\"!==v&&this.lockedAxis!==v&&t(this.targetScale)===t(this.minScale))return;e.cancelable&&e.preventDefault(),this.container.classList.add(this.cn(\"isDragging\"));const b=this.checkBounds(g,m);this.option(\"rubberband\")?(\"x\"!==this.isInfinite&&(b.xDiff>0&&g<0||b.xDiff<0&&g>0)&&(g*=Math.max(0,.5-Math.abs(.75/this.contentRect.fitWidth*b.xDiff))),\"y\"!==this.isInfinite&&(b.yDiff>0&&m<0||b.yDiff<0&&m>0)&&(m*=Math.max(0,.5-Math.abs(.75/this.contentRect.fitHeight*b.yDiff)))):(b.xDiff&&(g=0),b.yDiff&&(m=0));const y=this.targetScale,w=this.minScale,x=this.maxScale;y<.5*w&&(f=Math.max(f,w)),y>
191.5*x&&(f=Math.min(f,x)),\"y\"===this.lockedAxis&&t(y)===t(w)&&(g=0),\"x\"===this.lockedAxis&&t(y)===t(w)&&(m=0),this.applyChange({originX:l,originY:d,panX:g,panY:m,scale:f,friction:this.option(\"dragFriction\"),ignoreBounds:!0})}onPointerUp(t,e,n){if(n.length)return this.dragOffset.x=0,this.dragOffset.y=0,void(this.trackingPoints=[]);this.container.classList.remove(this.cn(\"isDragging\")),this.isDragging&&(this.addTrackingPoint(e),this.panOnlyZoomed&&this.contentRect.width-this.contentRect.fitWidth<1&&this.contentRect.height-this.contentRect.fitHeight<1&&(this.trackingPoints=[]),i(t.target,this.content)&&\"y\"===this.lockedAxis&&(this.trackingPoints=[]),this.emit(\"touchEnd\",t),this.isDragging=!1,this.lockedAxis=!1,this.state!==m.Destroy&&(t.defaultPrevented||this.startDecelAnim()))}startDecelAnim(){var e;const i=this.isScaling;this.rAF&&(cancelAnimationFrame(this.rAF),this.rAF=null),this.isBouncingX=!1,this.isBouncingY=!1;for(const t of v)this.velocity[t]=0;this.target.e=this.current.e,this.target.f=this.current.f,S(this.container,\"is-scaling\"),S(this.container,\"is-animating\"),this.isTicking=!1;const{trackingPoints:n}=this,s=n[0],o=n[n.length-1];let a=0,r=0,l=0;o&&s&&(a=o.clientX-s.clientX,r=o.clientY-s.clientY,l=o.time-s.time);const c=(null===(e=window.visualViewport)||void 0===e?void 0:e.scale)||1;1!==c&&(a*=c,r*=c);let h=0,d=0,u=0,p=0,f=this.option(\"decelFriction\");const g=this.targetScale;if(l>0){u=Math.abs(a)>3?a/(l/30):0,p=Math.abs(r)>3?r/(l/30):0;const t=this.option(\"maxVelocity\");t&&(u=Math.max(Math.min(u,t),-1*t),p=Math.max(Math.min(p,t),-1*t))}u&&(h=u/(1/(1-f)-1)),p&&(d=p/(1/(1-f)-1)),(\"y\"===this.option(\"lockAxis\")||\"xy\"===this.option(\"lockAxis\")&&\"y\"===this.lockedAxis&&t(g)===this.minScale)&&(h=u=0),(\"x\"===this.option(\"lockAxis\")||\"xy\"===this.option(\"lockAxis\")&&\"x\"===this.lockedAxis&&t(g)===this.minScale)&&(d=p=0);const m=this.dragOffset.x,b=this.dragOffset.y,y=this.option(\"dragMinThreshold\")||0;Math.abs(m)<y&&Math.abs(b)<y&&(h=d=0,u=p=0),(this.option(\"zoom\")&&(g<this.minScale-1e-5||g>this.maxScale+1e-5)||i&&!h&&!d)&&(f=.35),this.applyChange({panX:h,panY:d,friction:f}),this.emit(\"decel\",u,p,m,b)}onWheel(t){var e=[-t.deltaX||0,-t.deltaY||0,-t.detail||0].reduce((function(t,e){return Math.abs(e)>Math.abs(t)?e:t}));const i=Math.max(-1,Math.min(1,e));if(this.emit(\"wheel\",t,i),this.panMode===O)return;if(t.defaultPrevented)return;const n=this.option(\"wheel\");\"pan\"===n?(t.preventDefault(),this.panOnlyZoomed&&!this.canZoomOut()||this.applyChange({panX:2*-t.deltaX,panY:2*-t.deltaY,bounce:!1})):\"zoom\"===n&&!1!==this.option(\"zoom\")&&this.zoomWithWheel(t)}onMouseMove(t){this.panWithMouse(t)}onKeydown(t){\"Escape\"===t.key&&this.toggleFS()}onResize(){this.updateMetrics(),this.checkBounds().inBounds||this.requestTick()}setTransform(){this.emit(\"beforeTransform\");const{current:e,target:i,content:n,contentRect:s}=this,o=Object.assign({},C);for(const n of v){const s=\"e\"==n||\"f\"===n?M:T;o[n]=t(e[n],s),Math.abs(i[n]-e[n])<(\"e\"==n||\"f\"===n?.51:.001)&&(e[n]=i[n])}let{a:a,b:r,c:l,d:c,e:h,f:d}=o,u=`matrix(${a}, ${r}, ${l}, ${c}, ${h}, ${d})`,p=n.parentElement instanceof HTMLPictureElement?n.parentElement:n;if(this.option(\"transformParent\")&&(p=p.parentElement||p),p.style.transform===u)return;p.style.transform=u;const{contentWidth:f,contentHeight:g}=this.calculateContentDim();s.width=f,s.height=g,this.emit(\"afterTransform\")}updateMetrics(e=!1){var i;if(!this||this.state===m.Destroy)return;if(this.isContentLoading)return;const n=Math.max(1,(null===(i=window.visualViewport)||void 0===i?void 0:i.scale)||1),{container:s,content:o}=this,a=o instanceof HTMLImageElement,r=s.getBoundingClientRect(),l=getComputedStyle(this.container);let c=r.width*n,h=r.height*n;const d=parseFloat(l.paddingTop)+parseFloat(l.paddingBottom),u=c-(parseFloat(l.paddingLeft)+parseFloat(l.paddingRight)),p=h-d;this.containerRect={width:c,height:h,innerWidth:u,innerHeight:p};const f=parseFloat(o.dataset.width||\"\")||(t=>{let e=0;return e=t instanceof HTMLImageElement?t.naturalWidth:t instanceof SVGElement?t.width.baseVal.value:Math.max(t.offsetWidth,t.scrollWidth),e||0})(o),g=parseFloat(o.dataset.height||\"\")||(t=>{let e=0;return e=t instanceof HTMLImageElement?t.naturalHeight:t instanceof SVGElement?t.height.baseVal.value:Math.max(t.offsetHeight,t.scrollHeight),e||0})(o);let v=this.option(\"width\",f)||z,b=this.option(\"height\",g)||z;const y=v===z,w=b===z;
19\"number\"!=typeof v&&(v=f),\"number\"!=typeof b&&(b=g),y&&(v=f*(b/g)),w&&(b=g/(f/v));let x=o.parentElement instanceof HTMLPictureElement?o.parentElement:o;this.option(\"transformParent\")&&(x=x.parentElement||x);const E=x.getAttribute(\"style\")||\"\";x.style.setProperty(\"transform\",\"none\",\"important\"),a&&(x.style.width=\"\",x.style.height=\"\"),x.offsetHeight;const S=o.getBoundingClientRect();let P=S.width*n,C=S.height*n,T=P,M=C;P=Math.min(P,v),C=Math.min(C,b),a?({width:P,height:C}=((t,e,i,n)=>{const s=i/t,o=n/e,a=Math.min(s,o);return{width:t*=a,height:e*=a}})(v,b,P,C)):(P=Math.min(P,v),C=Math.min(C,b));let O=.5*(M-C),A=.5*(T-P);this.contentRect=Object.assign(Object.assign({},this.contentRect),{top:S.top-r.top+O,bottom:r.bottom-S.bottom+O,left:S.left-r.left+A,right:r.right-S.right+A,fitWidth:P,fitHeight:C,width:P,height:C,fullWidth:v,fullHeight:b}),x.style.cssText=E,a&&(x.style.width=`${P}px`,x.style.height=`${C}px`),this.setTransform(),!0!==e&&this.emit(\"refresh\"),this.ignoreBounds||(t(this.targetScale)<t(this.minScale)?this.zoomTo(this.minScale,{friction:0}):this.targetScale>this.maxScale?this.zoomTo(this.maxScale,{friction:0}):this.state===m.Init||this.checkBounds().inBounds||this.requestTick()),this.updateControls()}calculateBounds(){const{contentWidth:e,contentHeight:i}=this.calculateContentDim(this.target),{targetScale:n,lockedAxis:s}=this,{fitWidth:o,fitHeight:a}=this.contentRect;let r=0,l=0,c=0,h=0;const d=this.option(\"infinite\");if(!0===d||s&&d===s)r=-1/0,c=1/0,l=-1/0,h=1/0;else{let{containerRect:s,contentRect:d}=this,u=t(o*n,M),p=t(a*n,M),{innerWidth:f,innerHeight:g}=s;if(s.width===u&&(f=s.width),s.width===p&&(g=s.height),e>f){c=.5*(e-f),r=-1*c;let t=.5*(d.right-d.left);r+=t,c+=t}if(o>f&&e<f&&(r-=.5*(o-f),c-=.5*(o-f)),i>g){h=.5*(i-g),l=-1*h;let t=.5*(d.bottom-d.top);l+=t,h+=t}a>g&&i<g&&(r-=.5*(a-g),c-=.5*(a-g))}return{x:{min:r,max:c},y:{min:l,max:h}}}getBounds(){const t=this.option(\"bounds\");return t!==z?t:this.calculateBounds()}updateControls(){const e=this,i=e.container,{panMode:n,contentRect:s,targetScale:a,minScale:r}=e;let l=r,c=e.option(\"click\")||!1;c&&(l=e.getNextScale(c));let h=e.canZoomIn(),d=e.canZoomOut(),u=n===A&&!!this.option(\"touch\"),p=d&&u;if(u&&(t(a)<t(r)&&!this.panOnlyZoomed&&(p=!0),(t(s.width,1)>t(s.fitWidth,1)||t(s.height,1)>t(s.fitHeight,1))&&(p=!0)),t(s.width*a,1)<t(s.fitWidth,1)&&(p=!1),n===O&&(p=!1),o(i,this.cn(\"isDraggable\"),p),!this.option(\"zoom\"))return;let f=h&&t(l)>t(a),g=!f&&!p&&d&&t(l)<t(a);o(i,this.cn(\"canZoomIn\"),f),o(i,this.cn(\"canZoomOut\"),g);for(const t of i.querySelectorAll(\"[data-panzoom-action]\")){let e=!1,i=!1;switch(t.dataset.panzoomAction){case\"zoomIn\":h?e=!0:i=!0;break;case\"zoomOut\":d?e=!0:i=!0;break;case\"toggleZoom\":case\"iterateZoom\":h||d?e=!0:i=!0;const n=t.querySelector(\"g\");n&&(n.style.display=h?\"\":\"none\")}e?(t.removeAttribute(\"disabled\"),t.removeAttribute(\"tabindex\")):i&&(t.setAttribute(\"disabled\",\"\"),t.setAttribute(\"tabindex\",\"-1\"))}}panTo({x:t=this.target.e,y:e=this.target.f,scale:i=this.targetScale,friction:n=this.option(\"friction\"),angle:s=0,originX:o=0,originY:a=0,flipX:r=!1,flipY:l=!1,ignoreBounds:c=!1}){this.state!==m.Destroy&&this.applyChange({panX:t-this.target.e,panY:e-this.target.f,scale:i/this.targetScale,angle:s,originX:o,originY:a,friction:n,flipX:r,flipY:l,ignoreBounds:c})}applyChange({panX:e=0,panY:i=0,scale:n=1,angle:s=0,originX:o=-this.current.e,originY:a=-this.current.f,friction:r=this.option(\"friction\"),flipX:l=!1,flipY:c=!1,ignoreBounds:h=!1,bounce:d=this.option(\"bounce\")}){const u=this.state;if(u===m.Destroy)return;this.rAF&&(cancelAnimationFrame(this.rAF),this.rAF=null),this.friction=r||0,this.ignoreBounds=h;const{current:p}=this,f=p.e,g=p.f,b=this.getMatrix(this.target);let y=(new DOMMatrix).translate(f,g).translate(o,a).translate(e,i);if(this.option(\"zoom\")){if(!h){const t=this.targetScale,e=this.minScale,i=this.maxScale;t*n<e&&(n=e/t),t*n>i&&(n=i/t)}y=y.scale(n)}y=y.translate(-o,-a).translate(-f,-g).multiply(b),s&&(y=y.rotate(s)),l&&(y=y.scale(-1,1)),c&&(y=y.scale(1,-1));for(const e of v)\"e\"!==e&&\"f\"!==e&&(y[e]>this.minScale+1e-5||y[e]<this.minScale-1e-5)?this.target[e]=y[e]:this.target[e]=t(y[e],M);(this.targetScale<this.scale||Math.abs(n-1)>.1||this.panMode===O||!1===d)&&!h&&this.clampTargetBounds(),u===m.Init?this.animate():this.isResting||(this.state=m.Panning,this.requestTick())}stop(t=!1){if(this.state===m.Init||this.state===m.Destroy)return;const e=this.isTicking;this.rAF&&(cancelAnimationFrame(this.rAF),this.rAF=null),this.isBouncingX=!1,this.isBouncingY=!1;for(const e of v)this.velocity[e]=0,\"current\"===t?this.current[e]=this.target[e]:\"target\"===t&&(this.target[e]=this.current[e]);this.setTransform(),S(this.container,\"is-scaling\"),S(this.container,\"is-animating\"),this.isTicking=!1,this.state=m.Ready,e&&(this.emit
19(\"endAnimation\"),this.updateControls())}requestTick(){this.isTicking||(this.emit(\"startAnimation\"),this.updateControls(),P(this.container,\"is-animating\"),this.isScaling&&P(this.container,\"is-scaling\")),this.isTicking=!0,this.rAF||(this.rAF=requestAnimationFrame((()=>this.animate())))}panWithMouse(e,i=this.option(\"mouseMoveFriction\")){if(this.pmme=e,this.panMode!==O||!e)return;if(t(this.targetScale)<=t(this.minScale))return;this.emit(\"mouseMove\",e);const{container:n,containerRect:s,contentRect:o}=this,a=s.width,r=s.height,l=n.getBoundingClientRect(),c=(e.clientX||0)-l.left,h=(e.clientY||0)-l.top;let{contentWidth:d,contentHeight:u}=this.calculateContentDim(this.target);const p=this.option(\"mouseMoveFactor\");p>1&&(d!==a&&(d*=p),u!==r&&(u*=p));let f=.5*(d-a)-c/a*100/100*(d-a);f+=.5*(o.right-o.left);let g=.5*(u-r)-h/r*100/100*(u-r);g+=.5*(o.bottom-o.top),this.applyChange({panX:f-this.target.e,panY:g-this.target.f,friction:i})}zoomWithWheel(e){if(this.state===m.Destroy||this.state===m.Init)return;const i=Date.now();if(i-this.pwt<45)return void e.preventDefault();this.pwt=i;var n=[-e.deltaX||0,-e.deltaY||0,-e.detail||0].reduce((function(t,e){return Math.abs(e)>Math.abs(t)?e:t}));const s=Math.max(-1,Math.min(1,n)),{targetScale:o,maxScale:a,minScale:r}=this;let l=o*(100+45*s)/100;t(l)<t(r)&&t(o)<=t(r)?(this.cwd+=Math.abs(s),l=r):t(l)>t(a)&&t(o)>=t(a)?(this.cwd+=Math.abs(s),l=a):(this.cwd=0,l=Math.max(Math.min(l,a),r)),this.cwd>this.option(\"wheelLimit\")||(e.preventDefault(),t(l)!==t(o)&&this.zoomTo(l,{event:e}))}canZoomIn(){return this.option(\"zoom\")&&(t(this.contentRect.width,1)<t(this.contentRect.fitWidth,1)||t(this.targetScale)<t(this.maxScale))}canZoomOut(){return this.option(\"zoom\")&&t(this.targetScale)>t(this.minScale)}zoomIn(t=1.25,e){this.zoomTo(this.targetScale*t,e)}zoomOut(t=.8,e){this.zoomTo(this.targetScale*t,e)}zoomToFit(t){this.zoomTo(\"fit\",t)}zoomToCover(t){this.zoomTo(\"cover\",t)}zoomToFull(t){this.zoomTo(\"full\",t)}zoomToMax(t){this.zoomTo(\"max\",t)}toggleZoom(t){this.zoomTo(this.getNextScale(\"toggleZoom\"),t)}toggleMax(t){this.zoomTo(this.getNextScale(\"toggleMax\"),t)}toggleCover(t){this.zoomTo(this.getNextScale(\"toggleCover\"),t)}iterateZoom(t){this.zoomTo(\"next\",t)}zoomTo(t=1,{friction:e=z,originX:i=z,originY:n=z,event:s}={}){if(this.isContentLoading||this.state===m.Destroy)return;const{targetScale:o,fullScale:a,maxScale:r,coverScale:l}=this;if(this.stop(),this.panMode===O&&(s=this.pmme||s),s||i===z||n===z){const t=this.content.getBoundingClientRect(),e=this.container.getBoundingClientRect(),o=s?s.clientX:e.left+.5*e.width,a=s?s.clientY:e.top+.5*e.height;i=o-t.left-.5*t.width,n=a-t.top-.5*t.height}let c=1;\"number\"==typeof t?c=t:\"full\"===t?c=a:\"cover\"===t?c=l:\"max\"===t?c=r:\"fit\"===t?c=1:\"next\"===t&&(c=this.getNextScale(\"iterateZoom\")),c=c/o||1,e=e===z?c>1?.15:.25:e,this.applyChange({scale:c,originX:i,originY:n,friction:e}),s&&this.panMode===O&&this.panWithMouse(s,e)}rotateCCW(){this.applyChange({angle:-90})}rotateCW(){this.applyChange({angle:90})}flipX(){this.applyChange({flipX:!0})}flipY(){this.applyChange({flipY:!0})}fitX(){this.stop(\"target\");const{containerRect:t,contentRect:e,target:i}=this;this.applyChange({panX:.5*t.width-(e.left+.5*e.fitWidth)-i.e,panY:.5*t.height-(e.top+.5*e.fitHeight)-i.f,scale:t.width/e.fitWidth/this.targetScale,originX:0,originY:0,ignoreBounds:!0})}fitY(){this.stop(\"target\");const{containerRect:t,contentRect:e,target:i}=this;this.applyChange({panX:.5*t.width-(e.left+.5*e.fitWidth)-i.e,panY:.5*t.innerHeight-(e.top+.5*e.fitHeight)-i.f,scale:t.height/e.fitHeight/this.targetScale,originX:0,originY:0,ignoreBounds:!0})}toggleFS(){const{container:t}=this,e=this.cn(\"inFullscreen\"),i=this.cn(\"htmlHasFullscreen\");t.classList.toggle(e);const n=t.classList.contains(e);n?(document.documentElement.classList.add(i),document.addEventListener(\"keydown\",this.onKeydown,!0)):(document.documentElement.classList.remove(i),document.removeEventListener(\"keydown\",this.onKeydown,!0)),this.updateMetrics(),this.emit(n?\"enterFS\":\"exitFS\")}getMatrix(t=this.current){const{a:e,b:i,c:n,d:s,e:o,f:a}=t;return new DOMMatrix([e,i,n,s,o,a])}reset(t){if(this.state!==m.Init&&this.state!==m.Destroy){this.stop(\"current\");for(const t of v)this.target[t]=C[t];this.target.a=this.minScale,this.target.d=this.minScale,this.clampTargetBounds(),this.isResting||(this.friction=void 0===t?this.option(\"friction\"):t,this.state=m.Panning,this.requestTick())}}destroy(){this.stop(),this.state=m.Destroy,this.detachEvents(),this.detachObserver();const{container:t,content:e}=this,i=this.option(\"classes\")||{};for(const e of Object.values(i))t.classList.remove(e+\"\");e&&(e.removeEventListener(\"load\",this.onLoad),e.removeEventListener(\"error\",this.onError)),this.detachPlugins()}}Object.defineProperty(I,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:y}),Object.defineProperty(I,\"Plugins\",{enumerable:!0,configurable:!0,writable:!0,value:{}});const D=function(t,e){let i=!0;return(...n)=>{i&&(i=!1,t(...n),setTimeout((()=>{i=!0}),e))}},F=(t,e)=>{let i=[];
19return t.childNodes.forEach((t=>{t.nodeType!==Node.ELEMENT_NODE||e&&!t.matches(e)||i.push(t)})),i},j={viewport:null,track:null,enabled:!0,slides:[],axis:\"x\",transition:\"fade\",preload:1,slidesPerPage:\"auto\",initialPage:0,friction:.12,Panzoom:{decelFriction:.12},center:!0,infinite:!0,fill:!0,dragFree:!1,adaptiveHeight:!1,direction:\"ltr\",classes:{container:\"f-carousel\",viewport:\"f-carousel__viewport\",track:\"f-carousel__track\",slide:\"f-carousel__slide\",isLTR:\"is-ltr\",isRTL:\"is-rtl\",isHorizontal:\"is-horizontal\",isVertical:\"is-vertical\",inTransition:\"in-transition\",isSelected:\"is-selected\"},l10n:{NEXT:\"Next slide\",PREV:\"Previous slide\",GOTO:\"Go to slide #%d\"}};var B;!function(t){t[t.Init=0]=\"Init\",t[t.Ready=1]=\"Ready\",t[t.Destroy=2]=\"Destroy\"}(B||(B={}));const H=t=>{if(\"string\"==typeof t||t instanceof HTMLElement)t={html:t};else{const e=t.thumb;void 0!==e&&(\"string\"==typeof e&&(t.thumbSrc=e),e instanceof HTMLImageElement&&(t.thumbEl=e,t.thumbElSrc=e.src,t.thumbSrc=e.src),delete t.thumb)}return Object.assign({html:\"\",el:null,isDom:!1,class:\"\",customClass:\"\",index:-1,dim:0,gap:0,pos:0,transition:!1},t)},N=(t={})=>Object.assign({index:-1,slides:[],dim:0,pos:-1},t);class _ extends f{constructor(t,e){super(e),Object.defineProperty(this,\"instance\",{enumerable:!0,configurable:!0,writable:!0,value:t})}attach(){}detach(){}}const $={classes:{list:\"f-carousel__dots\",isDynamic:\"is-dynamic\",hasDots:\"has-dots\",dot:\"f-carousel__dot\",isBeforePrev:\"is-before-prev\",isPrev:\"is-prev\",isCurrent:\"is-current\",isNext:\"is-next\",isAfterNext:\"is-after-next\"},dotTpl:'<button type=\"button\" data-carousel-page=\"%i\" aria-label=\"{{GOTO}}\"><span class=\"f-carousel__dot\" aria-hidden=\"true\"></span></button>',dynamicFrom:11,maxCount:1/0,minCount:2};class W extends _{constructor(){super(...arguments),Object.defineProperty(this,\"isDynamic\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,\"list\",{enumerable:!0,configurable:!0,writable:!0,value:null})}onRefresh(){this.refresh()}build(){let t=this.list;if(!t){t=document.createElement(\"ul\"),P(t,this.cn(\"list\")),t.setAttribute(\"role\",\"tablist\");const e=this.instance.container;e.appendChild(t),P(e,this.cn(\"hasDots\")),this.list=t}return t}refresh(){var t;const e=this.instance.pages.length,i=Math.min(2,this.option(\"minCount\")),n=Math.max(2e3,this.option(\"maxCount\")),s=this.option(\"dynamicFrom\");if(e<i||e>n)return void this.cleanup();const a=\"number\"==typeof s&&e>5&&e>=s,r=!this.list||this.isDynamic!==a||this.list.children.length!==e;r&&this.cleanup();const l=this.build();if(o(l,this.cn(\"isDynamic\"),!!a),r)for(let t=0;t<e;t++)l.append(this.createItem(t));let c,h=0;for(const e of[...l.children]){const i=h===this.instance.page;i&&(c=e),o(e,this.cn(\"isCurrent\"),i),null===(t=e.children[0])||void 0===t||t.setAttribute(\"aria-selected\",i?\"true\":\"false\");for(const t of[\"isBeforePrev\",\"isPrev\",\"isNext\",\"isAfterNext\"])S(e,this.cn(t));h++}if(c=c||l.firstChild,a&&c){const t=c.previousElementSibling,e=t&&t.previousElementSibling;P(t,this.cn(\"isPrev\")),P(e,this.cn(\"isBeforePrev\"));const i=c.nextElementSibling,n=i&&i.nextElementSibling;P(i,this.cn(\"isNext\")),P(n,this.cn(\"isAfterNext\"))}this.isDynamic=a}createItem(t=0){var e;const i=document.createElement(\"li\");i.setAttribute(\"role\",\"presentation\");const s=n(this.instance.localize(this.option(\"dotTpl\"),[[\"%d\",t+1]]).replace(/\\%i/g,t+\"\"));return i.appendChild(s),null===(e=i.children[0])||void 0===e||e.setAttribute(\"role\",\"tab\"),i}cleanup(){this.list&&(this.list.remove(),this.list=null),this.isDynamic=!1,S(this.instance.container,this.cn(\"hasDots\"))}attach(){this.instance.on([\"refresh\",\"change\"],this.onRefresh)}detach(){this.instance.off([\"refresh\",\"change\"],this.onRefresh),this.cleanup()}}Object.defineProperty(W,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:$});const X=\"disabled\",q=\"next\",Y=\"prev\";class V extends _{constructor(){super(...arguments),Object.defineProperty(this,\"container\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"prev\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"next\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"isDom\",{enumerable:!0,configurable:!0,writable:!0,value:!1})}onRefresh(){const t=this.instance,e=t.pages.length,i=t.page;if(e<2)return void this.cleanup();this.build();let n=this.prev,s=this.next;n&&s&&(n.removeAttribute(X),s.removeAttribute(X),t.isInfinite||(i<=0&&n.setAttribute(X,\"\"),i>=e-1&&s.setAttribute(X,\"\")))}addBtn(t){var e;const i=this.instance,n=document.createElement(\"button\");n.setAttribute(\"tabindex\",\"0\"),n.setAttribute(\"title\",i.localize(`{{${t.toUpperCase()}}}
19`)),P(n,this.cn(\"button\")+\" \"+this.cn(t===q?\"isNext\":\"isPrev\"));const s=i.isRTL?t===q?Y:q:t;var o;return n.innerHTML=i.localize(this.option(`${s}Tpl`)),n.dataset[`carousel${o=t,o?o.match(\"^[a-z]\")?o.charAt(0).toUpperCase()+o.substring(1):o:\"\"}`]=\"true\",null===(e=this.container)||void 0===e||e.appendChild(n),n}build(){const t=this.instance.container,e=this.cn(\"container\");let{container:i,prev:n,next:s}=this;i||(i=t.querySelector(\".\"+e),this.isDom=!!i),i||(i=document.createElement(\"div\"),P(i,e),t.appendChild(i)),this.container=i,s||(s=i.querySelector(\"[data-carousel-next]\")),s||(s=this.addBtn(q)),this.next=s,n||(n=i.querySelector(\"[data-carousel-prev]\")),n||(n=this.addBtn(Y)),this.prev=n}cleanup(){this.isDom||(this.prev&&this.prev.remove(),this.next&&this.next.remove(),this.container&&this.container.remove()),this.prev=null,this.next=null,this.container=null,this.isDom=!1}attach(){this.instance.on([\"refresh\",\"change\"],this.onRefresh)}detach(){this.instance.off([\"refresh\",\"change\"],this.onRefresh),this.cleanup()}}Object.defineProperty(V,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:{classes:{container:\"f-carousel__nav\",button:\"f-button\",isNext:\"is-next\",isPrev:\"is-prev\"},nextTpl:'<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" tabindex=\"-1\"><path d=\"M9 3l9 9-9 9\"/></svg>',prevTpl:'<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" tabindex=\"-1\"><path d=\"M15 3l-9 9 9 9\"/></svg>'}});class Z extends _{constructor(){super(...arguments),Object.defineProperty(this,\"selectedIndex\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"target\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"nav\",{enumerable:!0,configurable:!0,writable:!0,value:null})}addAsTargetFor(t){this.target=this.instance,this.nav=t,this.attachEvents()}addAsNavFor(t){this.nav=this.instance,this.target=t,this.attachEvents()}attachEvents(){const{nav:t,target:e}=this;t&&e&&(t.options.initialSlide=e.options.initialPage,t.state===B.Ready?this.onNavReady(t):t.on(\"ready\",this.onNavReady),e.state===B.Ready?this.onTargetReady(e):e.on(\"ready\",this.onTargetReady))}onNavReady(t){t.on(\"createSlide\",this.onNavCreateSlide),t.on(\"Panzoom.click\",this.onNavClick),t.on(\"Panzoom.touchEnd\",this.onNavTouch),this.onTargetChange()}onTargetReady(t){t.on(\"change\",this.onTargetChange),t.on(\"Panzoom.refresh\",this.onTargetChange),this.onTargetChange()}onNavClick(t,e,i){this.onNavTouch(t,t.panzoom,i)}onNavTouch(t,e,i){var n,s;if(Math.abs(e.dragOffset.x)>3||Math.abs(e.dragOffset.y)>3)return;const o=i.target,{nav:a,target:r}=this;if(!a||!r||!o)return;const l=o.closest(\"[data-index]\");if(i.stopPropagation(),i.preventDefault(),!l)return;const c=parseInt(l.dataset.index||\"\",10)||0,h=r.getPageForSlide(c),d=a.getPageForSlide(c);a.slideTo(d),r.slideTo(h,{friction:(null===(s=null===(n=this.nav)||void 0===n?void 0:n.plugins)||void 0===s?void 0:s.Sync.option(\"friction\"))||0}),this.markSelectedSlide(c)}onNavCreateSlide(t,e){e.index===this.selectedIndex&&this.markSelectedSlide(e.index)}onTargetChange(){var t,e;const{target:i,nav:n}=this;if(!i||!n)return;if(n.state!==B.Ready||i.state!==B.Ready)return;const s=null===(e=null===(t=i.pages[i.page])||void 0===t?void 0:t.slides[0])||void 0===e?void 0:e.index,o=n.getPageForSlide(s);this.markSelectedSlide(s),n.slideTo(o,null===n.prevPage&&null===i.prevPage?{friction:0}:void 0)}markSelectedSlide(t){const e=this.nav;e&&e.state===B.Ready&&(this.selectedIndex=t,[...e.slides].map((e=>{e.el&&e.el.classList[e.index===t?\"add\":\"remove\"](\"is-nav-selected\")})))}attach(){const t=this;let e=t.options.target,i=t.options.nav;e?t.addAsNavFor(e):i&&t.addAsTargetFor(i)}detach(){const t=this,e=t.nav,i=t.target;e&&(e.off(\"ready\",t.onNavReady),e.off(\"createSlide\",t.onNavCreateSlide),e.off(\"Panzoom.click\",t.onNavClick),e.off(\"Panzoom.touchEnd\",t.onNavTouch)),t.nav=null,i&&(i.off(\"ready\",t.onTargetReady),i.off(\"refresh\",t.onTargetChange),i.off(\"change\",t.onTargetChange)),t.target=null}}Object.defineProperty(Z,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:{friction:.35}});const U={Navigation:V,Dots:W,Sync:Z},G=\"animationend\",K=\"isSelected\",J=\"slide\";class Q extends g{get axis(){return this.isHorizontal?\"e\":\"f\"}get isEnabled(){return this.state===B.Ready}get isInfinite(){let t=!1;const{contentDim:e,viewportDim:i,pages:n,slides:s}=this,o=s[0];return n.length>=2&&o&&e+o.dim>=i&&(t=this.option(\"infinite\")),t}get isRTL(){return\"rtl\"===this.option(\"direction\")}get isHorizontal(){return\"x\"===this.option(\"axis\")}constructor(t,e={},i={}){if(super(),Object.defineProperty(this,\"bp\",{enumerable:!0,configurable:!0,writable:!0,value:\"\"}),Object.defineProperty(this,\"lp\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"userOptions\",{enumerable:!0,configurable:!0,writable:!0,value:{}}),Object.defineProperty(this,\"userPlugins\",{enumerable:!0,configurable:!0,writable:!0,value:{}}),Object.defineProperty(this,\"state\",{enumerable:!0,configurable:!0,writable:!0,value:B.Init}),Object.defineProperty(this,\"page\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"prevPage\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"container\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,\"viewport\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"track\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"slides\",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,\"pages\",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,\"panzoom\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"inTransition\",{enumerable:!0,configurable:!0,writable:!0,value:new Set}),Object.defineProperty(this,\"contentDim\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"viewportDim\",{enumerable:!0,configurable:!0,writable:!0,value:0}
19),\"string\"==typeof t&&(t=document.querySelector(t)),!t||!E(t))throw new Error(\"No Element found\");this.container=t,this.slideNext=D(this.slideNext.bind(this),150),this.slidePrev=D(this.slidePrev.bind(this),150),this.userOptions=e,this.userPlugins=i,queueMicrotask((()=>{this.processOptions()}))}processOptions(){var t,e;const i=u({},Q.defaults,this.userOptions);let n=\"\";const s=i.breakpoints;if(s&&d(s))for(const[t,e]of Object.entries(s))window.matchMedia(t).matches&&d(e)&&(n+=t,u(i,e));n===this.bp&&this.state!==B.Init||(this.bp=n,this.state===B.Ready&&(i.initialSlide=(null===(e=null===(t=this.pages[this.page])||void 0===t?void 0:t.slides[0])||void 0===e?void 0:e.index)||0),this.state!==B.Init&&this.destroy(),super.setOptions(i),!1===this.option(\"enabled\")?this.attachEvents():setTimeout((()=>{this.init()}),0))}init(){this.state=B.Init,this.emit(\"init\"),this.attachPlugins(Object.assign(Object.assign({},Q.Plugins),this.userPlugins)),this.emit(\"attachPlugins\"),this.initLayout(),this.initSlides(),this.updateMetrics(),this.setInitialPosition(),this.initPanzoom(),this.attachEvents(),this.state=B.Ready,this.emit(\"ready\")}initLayout(){const{container:t}=this,e=this.option(\"classes\");P(t,this.cn(\"container\")),o(t,e.isLTR,!this.isRTL),o(t,e.isRTL,this.isRTL),o(t,e.isVertical,!this.isHorizontal),o(t,e.isHorizontal,this.isHorizontal);let i=this.option(\"viewport\")||t.querySelector(`.${e.viewport}`);i||(i=document.createElement(\"div\"),P(i,e.viewport),i.append(...F(t,`.${e.slide}`)),t.prepend(i)),i.addEventListener(\"scroll\",this.onScroll);let n=this.option(\"track\")||t.querySelector(`.${e.track}`);n||(n=document.createElement(\"div\"),P(n,e.track),n.append(...Array.from(i.childNodes))),n.setAttribute(\"aria-live\",\"polite\"),i.contains(n)||i.prepend(n),this.viewport=i,this.track=n,this.emit(\"initLayout\")}initSlides(){const{track:t}=this;if(!t)return;const e=[...this.slides],i=[];[...F(t,`.${this.cn(J)}`)].forEach((t=>{if(E(t)){const e=H({el:t,isDom:!0,index:this.slides.length});i.push(e)}}));for(let t of[...this.option(\"slides\",[])||[],...e])i.push(H(t));this.slides=i;for(let t=0;t<this.slides.length;t++)this.slides[t].index=t;
19for(const t of i)this.emit(\"beforeInitSlide\",t,t.index),this.emit(\"initSlide\",t,t.index);this.emit(\"initSlides\")}setInitialPage(){const t=this.option(\"initialSlide\");this.page=\"number\"==typeof t?this.getPageForSlide(t):parseInt(this.option(\"initialPage\",0)+\"\",10)||0}setInitialPosition(){const{track:t,pages:e,isHorizontal:i}=this;if(!t||!e.length)return;let n=this.page;e[n]||(this.page=n=0);const s=(e[n].pos||0)*(this.isRTL&&i?1:-1),o=i?`${s}px`:\"0\",a=i?\"0\":`${s}px`;t.style.transform=`translate3d(${o}, ${a}, 0) scale(1)`,this.option(\"adaptiveHeight\")&&this.setViewportHeight()}initPanzoom(){this.panzoom&&(this.panzoom.destroy(),this.panzoom=null);const t=this.option(\"Panzoom\")||{};this.panzoom=new I(this.viewport,u({},{content:this.track,zoom:!1,panOnlyZoomed:!1,lockAxis:this.isHorizontal?\"x\":\"y\",infinite:this.isInfinite,click:!1,dblClick:!1,touch:t=>!(this.pages.length<2&&!t.options.infinite),bounds:()=>this.getBounds(),maxVelocity:t=>Math.abs(t.target[this.axis]-t.current[this.axis])<2*this.viewportDim?100:0},t)),this.panzoom.on(\"*\",((t,e,...i)=>{this.emit(`Panzoom.${e}`,t,...i)})),this.panzoom.on(\"decel\",this.onDecel),this.panzoom.on(\"refresh\",this.onRefresh),this.panzoom.on(\"beforeTransform\",this.onBeforeTransform),this.panzoom.on(\"endAnimation\",this.onEndAnimation)}attachEvents(){const t=this.container;t&&(t.addEventListener(\"click\",this.onClick,{passive:!1,capture:!1}),t.addEventListener(\"slideTo\",this.onSlideTo)),window.addEventListener(\"resize\",this.onResize)}createPages(){let t=[];const{contentDim:e,viewportDim:i}=this;let n=this.option(\"slidesPerPage\");n=(\"auto\"===n||e<=i)&&!1!==this.option(\"fill\")?1/0:parseFloat(n+\"\");let s=0,o=0,a=0;for(const e of this.slides)(!t.length||o+e.dim-i>.05||a>=n)&&(t.push(N()),s=t.length-1,o=0,a=0),t[s].slides.push(e),o+=e.dim+e.gap,a++;return t}processPages(){const e=this.pages,{contentDim:i,viewportDim:n,isInfinite:s}=this,o=this.option(\"center\"),a=this.option(\"fill\"),r=a&&o&&i>n&&!s;if(e.forEach(((t,e)=>{var s;t.index=e,t.pos=(null===(s=t.slides[0])||void 0===s?void 0:s.pos)||0,t.dim=0;for(const[e,i]of t.slides.entries())t.dim+=i.dim,e<t.slides.length-1&&(t.dim+=i.gap);r&&t.pos+.5*t.dim<.5*n?t.pos=0:r&&t.pos+.5*t.dim>=i-.5*n?t.pos=i-n:o&&(t.pos+=-.5*(n-t.dim))})),e.forEach((e=>{a&&!s&&i>n&&(e.pos=Math.max(e.pos,0),e.pos=Math.min(e.pos,i-n)),e.pos=t(e.pos,1e3),e.dim=t(e.dim,1e3),Math.abs(e.pos)<=.1&&(e.pos=0)})),s)return e;const l=[];let c;return e.forEach((t=>{const e=Object.assign({},t);c&&e.pos===c.pos?(c.dim+=e.dim,c.slides=[...c.slides,...e.slides]):(e.index=l.length,c=e,l.push(e))})),l}getPageFromIndex(t=0){const e=this.pages.length;let i;return t=parseInt((t||0).toString())||0,i=this.isInfinite?(t%e+e)%e:Math.max(Math.min(t,e-1),0),i}getSlideMetrics(e){var i,n;const s=this.isHorizontal?\"width\":\"height\";let o=0,a=0,r=e.el;const l=!(!r||r.parentNode);if(r?o=parseFloat(r.dataset[s]||\"\")||0:(r=document.createElement(\"div\"),r.style.visibility=\"hidden\",(this.track||document.body).prepend(r)),P(r,this.cn(J)+\" \"+e.class+\" \"+e.customClass),o)r.style[s]=`${o}px`,r.style[\"width\"===s?\"height\":\"width\"]=\"\";else{l&&(this.track||document.body).prepend(r),o=r.getBoundingClientRect()[s]*Math.max(1,(null===(i=window.visualViewport)||void 0===i?void 0:i.scale)||1);let t=r[this.isHorizontal?\"offsetWidth\":\"offsetHeight\"];t-1>o&&(o=t)}const c=getComputedStyle(r);return\"content-box\"===c.boxSizing&&(this.isHorizontal?(o+=parseFloat(c.paddingLeft)||0,o+=parseFloat(c.paddingRight)||0):(o+=parseFloat(c.paddingTop)||0,o+=parseFloat(c.paddingBottom)||0)),a=parseFloat(c[this.isHorizontal?\"marginRight\":\"marginBottom\"])||0,l?null===(n=r.parentElement)||void 0===n||n.removeChild(r):e.el||r.remove(),{dim:t(o,1e3),gap:t(a,1e3)}}getBounds(){const{isInfinite:t,isRTL:e,isHorizontal:i,pages:n}=this;let s={min:0,max:0};if(t)s={min:-1/0,max:1/0};else if(n.length){const t=n[0].pos,o=n[n.length-1].pos;s=e&&i?{min:t,max:o}:{min:-1*o,max:-1*t}}return{x:i?s:{min:0,max:0},y:i?{min:0,max:0}:s}}repositionSlides(){let e,{isHorizontal:i,isRTL:n,isInfinite:s,viewport:o,viewportDim:a,contentDim:r,page:l,pages:c,slides:h,panzoom:d}=this,u=0,p=0,f=0,g=0;d?g=-1*d.current[this.axis]:c[l]&&(g=c[l].pos||0),e=i?n?\"right\":\"left\":\"top\",n&&i&&(g*=-1);for(const i of h){const n=i.el;n?(\"top\"===e?(n.style.right=\"\",n.style.left=\"\"):n.style.top=\"\",i.index!==u?n.style[e]=0===p?\"\":`${t(p,1e3)}px`:n.style[e]=\"\",f+=i.dim+i.gap,u++):p+=i.dim+i.gap}if(s&&f&&o){let n=getComputedStyle(o),s=\"padding\",l=i?\"Right\":\"Bottom\",c=parseFloat(n[s+(i?\"Left\":\"Top\")]);g-=c,a+=c,a+=parseFloat(n[s+l]);for(const i of h)i.el&&(t(i.pos)<t(a)&&t(i.pos+i.dim+i.gap)<t(g)&&t(g)>t(r-a)&&(i.el.style[e]=`${t(p+f,1e3)}px`),t(i.pos+i.gap)>=t(r-a)&&t(i.pos)>t(g+a)&&t(g)<t(a)&&(i.el.style[e]=`-${t(f,1e3)}px`))}let m,v,b=[...this.inTransition];if(b.length>1&&(m=c[b[0]],v=c[b[1]]),m&&v){let i=0;for(const n of h)n.el?this.inTransition.has(n.index)&&m.slides.indexOf(n)<0&&(n.el.style[e]=`${t(i+(m.pos-v.pos),1e3)}px`):i+=n.dim+n.gap}}createSlideEl(t){const{track:e,slides:i}=this;if(!e||!t)return;if(t.el&&t.el.parentNode)return;const n=t.el||document.createElement(\"div\");P(n,this.cn(J)),P(n,t.class),P(n,t.customClass);const s=t.html;s&&(s instanceof HTMLElement?n.appendChild(s):n.innerHTML=t.html+\"\");const o=[];
19i.forEach(((t,e)=>{t.el&&o.push(e)}));const a=t.index;let r=null;if(o.length){r=i[o.reduce(((t,e)=>Math.abs(e-a)<Math.abs(t-a)?e:t))]}const l=r&&r.el&&r.el.parentNode?r.index<t.index?r.el.nextSibling:r.el:null;e.insertBefore(n,e.contains(l)?l:null),t.el=n,this.emit(\"createSlide\",t)}removeSlideEl(t,e=!1){const i=null==t?void 0:t.el;if(!i||!i.parentNode)return;const n=this.cn(K);if(i.classList.contains(n)&&(S(i,n),this.emit(\"unselectSlide\",t)),t.isDom&&!e)return i.removeAttribute(\"aria-hidden\"),i.removeAttribute(\"data-index\"),void(i.style.left=\"\");this.emit(\"removeSlide\",t);const s=new CustomEvent(G);i.dispatchEvent(s),t.el&&(t.el.remove(),t.el=null)}transitionTo(t=0,e=this.option(\"transition\")){var i,n,s,o;if(!e)return!1;const a=this.page,{pages:r,panzoom:l}=this;t=parseInt((t||0).toString())||0;const c=this.getPageFromIndex(t);if(!l||!r[c]||r.length<2||Math.abs(((null===(n=null===(i=r[a])||void 0===i?void 0:i.slides[0])||void 0===n?void 0:n.dim)||0)-this.viewportDim)>1)return!1;let h=t>a?1:-1;this.isInfinite&&(0===a&&t===r.length-1&&(h=-1),a===r.length-1&&0===t&&(h=1));const d=r[c].pos*(this.isRTL?1:-1);if(a===c&&Math.abs(d-l.target[this.axis])<1)return!1;this.clearTransitions();const u=l.isResting;P(this.container,this.cn(\"inTransition\"));const p=(null===(s=r[a])||void 0===s?void 0:s.slides[0])||null,f=(null===(o=r[c])||void 0===o?void 0:o.slides[0])||null;this.inTransition.add(f.index),this.createSlideEl(f);let g=p.el,m=f.el;u||e===J||(e=\"fadeFast\",g=null);const v=this.isRTL?\"next\":\"prev\",b=this.isRTL?\"prev\":\"next\";return g&&(this.inTransition.add(p.index),p.transition=e,g.addEventListener(G,this.onAnimationEnd),g.classList.add(`f-${e}Out`,`to-${h>0?b:v}`)),m&&(f.transition=e,m.addEventListener(G,this.onAnimationEnd),m.classList.add(`f-${e}In`,`from-${h>0?v:b}`)),l.current[this.axis]=d,l.target[this.axis]=d,l.requestTick(),this.onChange(c),!0}manageSlideVisiblity(){const t=new Set,e=new Set,i=this.getVisibleSlides(parseFloat(this.option(\"preload\",0)+\"\")||0);for(const n of this.slides)i.has(n)?t.add(n):e.add(n);for(const e of this.inTransition)t.add(this.slides[e]);for(const e of t)this.createSlideEl(e),this.lazyLoadSlide(e);for(const i of e)t.has(i)||this.removeSlideEl(i);this.markSelectedSlides(),this.repositionSlides()}markSelectedSlides(){if(!this.pages[this.page]||!this.pages[this.page].slides)return;const t=\"aria-hidden\";let e=this.cn(K);if(e)for(const i of this.slides){const n=i.el;n&&(n.dataset.index=`${i.index}`,n.classList.contains(\"f-thumbs__slide\")?this.getVisibleSlides(0).has(i)?n.removeAttribute(t):n.setAttribute(t,\"true\"):this.pages[this.page].slides.includes(i)?(n.classList.contains(e)||(P(n,e),this.emit(\"selectSlide\",i)),n.removeAttribute(t)):(n.classList.contains(e)&&(S(n,e),this.emit(\"unselectSlide\",i)),n.setAttribute(t,\"true\")))}}flipInfiniteTrack(){const{axis:t,isHorizontal:e,isInfinite:i,isRTL:n,viewportDim:s,contentDim:o}=this,a=this.panzoom;if(!a||!i)return;let r=a.current[t],l=a.target[t]-r,c=0,h=.5*s;n&&e?(r<-h&&(c=-1,r+=o),r>o-h&&(c=1,r-=o)):(r>h&&(c=1,r-=o),r<-o+h&&(c=-1,r+=o)),c&&(a.current[t]=r,a.target[t]=r+l)}lazyLoadImg(t,e){const i=this,s=\"f-fadeIn\",o=\"is-preloading\";let a=!1,r=null;const l=()=>{a||(a=!0,r&&(r.remove(),r=null),S(e,o),e.complete&&(P(e,s),setTimeout((()=>{S(e,s)}),350)),this.option(\"adaptiveHeight\")&&t.el&&this.pages[this.page].slides.indexOf(t)>-1&&(i.updateMetrics(),i.setViewportHeight()),this.emit(\"load\",t))};P(e,o),e.src=e.dataset.lazySrcset||e.dataset.lazySrc||\"\",delete e.dataset.lazySrc,delete e.dataset.lazySrcset,e.addEventListener(\"error\",(()=>{l()})),e.addEventListener(\"load\",(()=>{l()})),setTimeout((()=>{const i=e.parentNode;i&&t.el&&(e.complete?l():a||(r=n(x),i.insertBefore(r,e)))}),300)}lazyLoadSlide(t){const e=t&&t.el;if(!e)return;const i=new Set;let n=Array.from(e.querySelectorAll(\"[data-lazy-src],[data-lazy-srcset]\"));e.dataset.lazySrc&&n.push(e),n.map((t=>{t instanceof HTMLImageElement?i.add(t):t instanceof HTMLElement&&t.dataset.lazySrc&&(t.style.backgroundImage=`url('${t.dataset.lazySrc}')`,delete t.dataset.lazySrc)}));for(const e of i)this.lazyLoadImg(t,e)}onAnimationEnd(t){var e;const i=t.target,n=i?parseInt(i.dataset.index||\"\",10)||0:-1,s=this.slides[n],o=t.animationName;if(!i||!s||!o)return;const a=!!this.inTransition.has(n)&&s.transition;a&&o.substring(0,a.length+2)===`f-${a}`&&this.inTransition.delete(n),this.inTransition.size||this.clearTransitions(),n===this.page&&(null===(e=this.panzoom)||void 0===e?void 0:e.isResting)&&this.emit
19(\"settle\")}onDecel(t,e=0,i=0,n=0,s=0){if(this.option(\"dragFree\"))return void this.setPageFromPosition();const{isRTL:o,isHorizontal:a,axis:r,pages:l}=this,c=l.length,h=Math.abs(Math.atan2(i,e)/(Math.PI/180));let d=0;if(d=h>45&&h<135?a?0:i:a?e:0,!c)return;let u=this.page,p=o&&a?1:-1;const f=t.current[r]*p;let{pageIndex:g}=this.getPageFromPosition(f);Math.abs(d)>5?(l[u].dim<document.documentElement[\"client\"+(this.isHorizontal?\"Width\":\"Height\")]-1&&(u=g),u=o&&a?d<0?u-1:u+1:d<0?u+1:u-1):u=0===n&&0===s?u:g,this.slideTo(u,{transition:!1,friction:t.option(\"decelFriction\")})}onClick(t){const e=t.target,i=e&&E(e)?e.dataset:null;let n,s;i&&(void 0!==i.carouselPage?(s=\"slideTo\",n=i.carouselPage):void 0!==i.carouselNext?s=\"slideNext\":void 0!==i.carouselPrev&&(s=\"slidePrev\")),s?(t.preventDefault(),t.stopPropagation(),e&&!e.hasAttribute(\"disabled\")&&this[s](n)):this.emit(\"click\",t)}onSlideTo(t){const e=t.detail||0;this.slideTo(this.getPageForSlide(e),{friction:0})}onChange(t,e=0){const i=this.page;this.prevPage=i,this.page=t,this.option(\"adaptiveHeight\")&&this.setViewportHeight(),t!==i&&(this.markSelectedSlides(),this.emit(\"change\",t,i,e))}onRefresh(){let t=this.contentDim,e=this.viewportDim;this.updateMetrics(),this.contentDim===t&&this.viewportDim===e||this.slideTo(this.page,{friction:0,transition:!1})}onScroll(){var t;null===(t=this.viewport)||void 0===t||t.scroll(0,0)}onResize(){this.option(\"breakpoints\")&&this.processOptions()}onBeforeTransform(t){this.lp!==t.current[this.axis]&&(this.flipInfiniteTrack(),this.manageSlideVisiblity()),this.lp=t.current.e}onEndAnimation(){this.inTransition.size||this.emit(\"settle\")}reInit(t=null,e=null){this.destroy(),this.state=B.Init,this.prevPage=null,this.userOptions=t||this.userOptions,this.userPlugins=e||this.userPlugins,this.processOptions()}slideTo(t=0,{friction:e=this.option(\"friction\"),transition:i=this.option(\"transition\")}={}){if(this.state===B.Destroy)return;t=parseInt((t||0).toString())||0;const n=this.getPageFromIndex(t),{axis:s,isHorizontal:o,isRTL:a,pages:r,panzoom:l}=this,c=r.length,h=a&&o?1:-1;if(!l||!c)return;if(this.page!==n){const e=new Event(\"beforeChange\",{bubbles:!0,cancelable:!0});if(this.emit(\"beforeChange\",e,t),e.defaultPrevented)return}if(this.transitionTo(t,i))return;let d=r[n].pos;if(this.isInfinite){const e=this.contentDim,i=l.target[s]*h;if(2===c)d+=e*Math.floor(parseFloat(t+\"\")/2);else{d=[d,d-e,d+e].reduce((function(t,e){return Math.abs(e-i)<Math.abs(t-i)?e:t}))}}d*=h,Math.abs(l.target[s]-d)<1||(l.panTo({x:o?d:0,y:o?0:d,friction:e}),this.onChange(n))}slideToClosest(t){if(this.panzoom){const{pageIndex:e}=this.getPageFromPosition();this.slideTo(e,t)}}slideNext(){this.slideTo(this.page+1)}slidePrev(){this.slideTo(this.page-1)}clearTransitions(){this.inTransition.clear(),S(this.container,this.cn(\"inTransition\"));const t=[\"to-prev\",\"to-next\",\"from-prev\",\"from-next\"];for(const e of this.slides){const i=e.el;if(i){i.removeEventListener(G,this.onAnimationEnd),i.classList.remove(...t);const n=e.transition;n&&i.classList.remove(`f-${n}Out`,`f-${n}In`)}}this.manageSlideVisiblity()}addSlide(t,e){var i,n,s,o;const a=this.panzoom,r=(null===(i=this.pages[this.page])||void 0===i?void 0:i.pos)||0,l=(null===(n=this.pages[this.page])||void 0===n?void 0:n.dim)||0,c=this.contentDim<this.viewportDim;let h=Array.isArray(e)?e:[e];const d=[];for(const t of h)d.push(H(t));this.slides.splice(t,0,...d);for(let t=0;t<this.slides.length;t++)this.slides[t].index=t;for(const t of d)this.emit(\"beforeInitSlide\",t,t.index);if(this.page>=t&&(this.page+=d.length),this.updateMetrics(),a){const e=(null===(s=this.pages[this.page])||void 0===s?void 0:s.pos)||0,i=(null===(o=this.pages[this.page])||void 0===o?void 0:o.dim)||0,n=this.pages.length||1,h=this.isRTL?l-i:i-l,d=this.isRTL?r-e:e-r;c&&1===n?(t<=this.page&&(a.current[this.axis]-=h,a.target[this.axis]-=h),a.panTo({[this.isHorizontal?\"x\":\"y\"]:-1*e})):d&&t<=this.page&&(a.target[this.axis]-=d,a.current[this.axis]-=d,a.requestTick())}for(const t of d)this.emit(\"initSlide\",t,t.index)}prependSlide(t){this.addSlide(0,t)}appendSlide(t){this.addSlide(this.slides.length,t)}removeSlide(t){const e=this.slides.length;t=(t%e+e)%e;const i=this.slides[t];
19if(i){this.removeSlideEl(i,!0),this.slides.splice(t,1);for(let t=0;t<this.slides.length;t++)this.slides[t].index=t;this.updateMetrics(),this.slideTo(this.page,{friction:0,transition:!1}),this.emit(\"destroySlide\",i)}}updateMetrics(){const{panzoom:e,viewport:i,track:n,slides:s,isHorizontal:o,isInfinite:a}=this;if(!n)return;const r=o?\"width\":\"height\",l=o?\"offsetWidth\":\"offsetHeight\";if(i){let e=Math.max(i[l],t(i.getBoundingClientRect()[r],1e3)),n=getComputedStyle(i),s=\"padding\",a=o?\"Right\":\"Bottom\";e-=parseFloat(n[s+(o?\"Left\":\"Top\")])+parseFloat(n[s+a]),this.viewportDim=e}let c,h=0;for(const[e,i]of s.entries()){let n=0,o=0;!i.el&&c?(n=c.dim,o=c.gap):(({dim:n,gap:o}=this.getSlideMetrics(i)),c=i),n=t(n,1e3),o=t(o,1e3),i.dim=n,i.gap=o,i.pos=h,h+=n,(a||e<s.length-1)&&(h+=o)}h=t(h,1e3),this.contentDim=h,e&&(e.contentRect[r]=h,e.contentRect[o?\"fullWidth\":\"fullHeight\"]=h),this.pages=this.createPages(),this.pages=this.processPages(),this.state===B.Init&&this.setInitialPage(),this.page=Math.max(0,Math.min(this.page,this.pages.length-1)),this.manageSlideVisiblity(),this.emit(\"refresh\")}getProgress(e,i=!1,n=!1){void 0===e&&(e=this.page);const s=this,o=s.panzoom,a=s.contentDim,r=s.pages[e]||0;if(!r||!o)return e>this.page?-1:1;let l=-1*o.current.e,c=t((l-r.pos)/(1*r.dim),1e3),h=c,d=c;this.isInfinite&&!0!==n&&(h=t((l-r.pos+a)/(1*r.dim),1e3),d=t((l-r.pos-a)/(1*r.dim),1e3));let u=[c,h,d].reduce((function(t,e){return Math.abs(e)<Math.abs(t)?e:t}));return i?u:u>1?1:u<-1?-1:u}setViewportHeight(){const{page:t,pages:e,viewport:i,isHorizontal:n}=this;if(!i||!e[t])return;let s=0;n&&this.track&&(this.track.style.height=\"auto\",e[t].slides.forEach((t=>{t.el&&(s=Math.max(s,t.el.offsetHeight))}))),i.style.height=s?`${s}px`:\"\"}getPageForSlide(t){for(const e of this.pages)for(const i of e.slides)if(i.index===t)return e.index;return-1}getVisibleSlides(t=0){var e;const i=new Set;let{panzoom:n,contentDim:s,viewportDim:o,pages:a,page:r}=this;if(o){s=s+(null===(e=this.slides[this.slides.length-1])||void 0===e?void 0:e.gap)||0;let l=0;l=n&&n.state!==m.Init&&n.state!==m.Destroy?-1*n.current[this.axis]:a[r]&&a[r].pos||0,this.isInfinite&&(l-=Math.floor(l/s)*s),this.isRTL&&this.isHorizontal&&(l*=-1);const c=l-o*t,h=l+o*(t+1),d=this.isInfinite?[-1,0,1]:[0];for(const t of this.slides)for(const e of d){const n=t.pos+e*s,o=n+t.dim+t.gap;n<h&&o>c&&i.add(t)}}return i}getPageFromPosition(t){const{viewportDim:e,contentDim:i,slides:n,pages:s,panzoom:o}=this,a=s.length,r=n.length,l=n[0],c=n[r-1],h=this.option(\"center\");let d=0,u=0,p=0,f=void 0===t?-1*((null==o?void 0:o.target[this.axis])||0):t;h&&(f+=.5*e),this.isInfinite?(f<l.pos-.5*c.gap&&(f-=i,p=-1),f>c.pos+c.dim+.5*c.gap&&(f-=i,p=1)):f=Math.max(l.pos||0,Math.min(f,c.pos));let g=c,m=n.find((t=>{const e=t.pos-.5*g.gap,i=t.pos+t.dim+.5*t.gap;return g=t,f>=e&&f<i}));return m||(m=c),u=this.getPageForSlide(m.index),d=u+p*a,{page:d,pageIndex:u}}setPageFromPosition(){const{pageIndex:t}=this.getPageFromPosition();this.onChange(t)}destroy(){if([B.Destroy].includes(this.state))return;this.state=B.Destroy;const{container:t,viewport:e,track:i,slides:n,panzoom:s}=this,o=this.option(\"classes\");t.removeEventListener(\"click\",this.onClick,{passive:!1,capture:!1}),t.removeEventListener(\"slideTo\",this.onSlideTo),window.removeEventListener(\"resize\",this.onResize),s&&(s.destroy(),this.panzoom=null),n&&n.forEach((t=>{this.removeSlideEl(t)})),this.detachPlugins(),e&&(e.removeEventListener(\"scroll\",this.onScroll),e.offsetParent&&i&&i.offsetParent&&e.replaceWith(...i.childNodes));for(const[e,i]of Object.entries(o))\"container\"!==e&&i&&t.classList.remove(i);this.track=null,this.viewport=null,this.page=0,this.slides=[];const a=this.events.get(\"ready\");this.events=new Map,a&&this.events.set(\"ready\",a)}}Object.defineProperty(Q,\"Panzoom\",{enumerable:!0,configurable:!0,writable:!0,value:I}),Object.defineProperty(Q,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:j}),Object.defineProperty(Q,\"Plugins\",{enumerable:!0,configurable:!0,writable:!0,value:U});const tt=function(t){if(!E(t))return 0;const e=window.scrollY,i=window.innerHeight,n=e+i,s=t.getBoundingClientRect(),o=s.y+e,a=s.height,r=o+a;if(e>r||n<o)return 0;if(e<o&&n>r)return 100;if(o<e&&r>n)return 100;let l=a;o<e&&(l-=e-o),r>n&&(l-=r-n);const c=l/i*100;return Math.round(c)},et=!(\"undefined\"==typeof window||!window.document||!window.document.createElement);let it;const nt=[\"a[href]\",\"area[href]\",'input:not([disabled]):not([type=\"hidden\"]):not([aria-hidden])',\"select:not([disabled]):not([aria-hidden])\",\"textarea:not([disabled]):not([aria-hidden])\",\"button:not([disabled]):not([aria-hidden]):not(.fancybox-focus-guard)\",\"iframe\",\"object\",\"embed\",\"video\",\"audio\",\"[contenteditable]\",'[tabindex]:not
19([tabindex^=\"-\"]):not([disabled]):not([aria-hidden])'].join(\",\"),st=t=>{if(t&&et){void 0===it&&document.createElement(\"div\").focus({get preventScroll(){return it=!0,!1}});try{if(it)t.focus({preventScroll:!0});else{const e=window.scrollY||document.body.scrollTop,i=window.scrollX||document.body.scrollLeft;t.focus(),document.body.scrollTo({top:e,left:i,behavior:\"auto\"})}}catch(t){}}},ot=()=>{const t=document;let e,i=\"\",n=\"\",s=\"\";return t.fullscreenEnabled?(i=\"requestFullscreen\",n=\"exitFullscreen\",s=\"fullscreenElement\"):t.webkitFullscreenEnabled&&(i=\"webkitRequestFullscreen\",n=\"webkitExitFullscreen\",s=\"webkitFullscreenElement\"),i&&(e={request:function(e=t.documentElement){return\"webkitRequestFullscreen\"===i?e[i](Element.ALLOW_KEYBOARD_INPUT):e[i]()},exit:function(){return t[s]&&t[n]()},isFullscreen:function(){return t[s]}}),e},at={animated:!0,autoFocus:!0,backdropClick:\"close\",Carousel:{classes:{container:\"fancybox__carousel\",viewport:\"fancybox__viewport\",track:\"fancybox__track\",slide:\"fancybox__slide\"}},closeButton:\"auto\",closeExisting:!1,commonCaption:!1,compact:()=>window.matchMedia(\"(max-width: 578px), (max-height: 578px)\").matches,contentClick:\"toggleZoom\",contentDblClick:!1,defaultType:\"image\",defaultDisplay:\"flex\",dragToClose:!0,Fullscreen:{autoStart:!1},groupAll:!1,groupAttr:\"data-fancybox\",hideClass:\"f-fadeOut\",hideScrollbar:!0,idle:3500,keyboard:{Escape:\"close\",Delete:\"close\",Backspace:\"close\",PageUp:\"next\",PageDown:\"prev\",ArrowUp:\"prev\",ArrowDown:\"next\",ArrowRight:\"next\",ArrowLeft:\"prev\"},l10n:Object.assign(Object.assign({},b),{CLOSE:\"Close\",NEXT:\"Next\",PREV:\"Previous\",MODAL:\"You can close this modal content with the ESC key\",ERROR:\"Something Went Wrong, Please Try Again Later\",IMAGE_ERROR:\"Image Not Found\",ELEMENT_NOT_FOUND:\"HTML Element Not Found\",AJAX_NOT_FOUND:\"Error Loading AJAX : Not Found\",AJAX_FORBIDDEN:\"Error Loading AJAX : Forbidden\",IFRAME_ERROR:\"Error Loading Page\",TOGGLE_ZOOM:\"Toggle zoom level\",TOGGLE_THUMBS:\"Toggle thumbnails\",TOGGLE_SLIDESHOW:\"Toggle slideshow\",TOGGLE_FULLSCREEN:\"Toggle full-screen mode\",DOWNLOAD:\"Download\"}),parentEl:null,placeFocusBack:!0,showClass:\"f-zoomInUp\",startIndex:0,tpl:{closeButton:'<button data-fancybox-close class=\"f-button is-close-btn\" title=\"{{CLOSE}}\"><svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" tabindex=\"-1\"><path d=\"M20 20L4 4m16 0L4 20\"/></svg></button>',main:'<div class=\"fancybox__container\" role=\"dialog\" aria-modal=\"true\" aria-label=\"{{MODAL}}\" tabindex=\"-1\">\\n <div class=\"fancybox__backdrop\"></div>\\n <div class=\"fancybox__carousel\"></div>\\n <div class=\"fancybox__footer\"></div>\\n </div>'},trapFocus:!0,wheel:\"zoom\"};var rt,lt;!function(t){t[t.Init=0]=\"Init\",t[t.Ready=1]=\"Ready\",t[t.Closing=2]=\"Closing\",t[t.CustomClosing=3]=\"CustomClosing\",t[t.Destroy=4]=\"Destroy\"}(rt||(rt={})),function(t){t[t.Loading=0]=\"Loading\",t[t.Opening=1]=\"Opening\",t[t.Ready=2]=\"Ready\",t[t.Closing=3]=\"Closing\"}(lt||(lt={}));let ct=\"\",ht=!1,dt=!1,ut=null;const pt=()=>{let t=\"\",e=\"\";const i=Oe.getInstance();if(i){const n=i.carousel,s=i.getSlide();if(n&&s){let o=s.slug||void 0,a=s.triggerEl||void 0;e=o||(i.option(\"slug\")||\"\"),!e&&a&&a.dataset&&(e=a.dataset.fancybox||\"\"),e&&\"true\"!==e&&(t=\"#\"+e+(!o&&n.slides.length>1?\"-\"+(s.index+1):\"\"))}}return{hash:t,slug:e,index:1}},ft=()=>{const t=new URL(document.URL).hash,e=t.slice(1).split(\"-\"),i=e[e.length-1],n=i&&/^\\+?\\d+$/.test(i)&&parseInt(e.pop()||\"1\",10)||1;return{hash:t,slug:e.join(\"-\"),index:n}},gt=()=>{const{slug:t,index:e}=ft();if(!t)return;let i=document.querySelector(`[data-slug=\"${t}\"]`);if(i&&i.dispatchEvent(new CustomEvent(\"click\",{bubbles:!0,cancelable:!0})),Oe.getInstance())return;const n=document.querySelectorAll(`[data-fancybox=\"${t}\"]`);n.length&&(i=n[e-1],i&&i.dispatchEvent(new CustomEvent(\"click\",{bubbles:!0,cancelable:!0})))},mt=()=>{if(!1===Oe.defaults.Hash)return;const t=Oe.getInstance();if(!1===(null==t?void 0:t.options.Hash))return;const{slug:e,index:i}=ft(),{slug:n}=pt();t&&(e===n?t.jumpTo(i-1):(ht=!0,t.close())),gt()},vt=()=>{ut&&clearTimeout(ut),queueMicrotask((()=>{mt()}))},bt=()=>{window.addEventListener(\"hashchange\",vt,!1),setTimeout((()=>{mt()}),500)};et&&(/complete|interactive|loaded/.test(document.readyState)?bt():document.addEventListener(\"DOMContentLoaded\",bt));const yt=\"is-zooming-in\";class wt extends _{onCreateSlide(t,e,i){const n=this.instance.optionFor(i,\"src\")||\"\";
19i.el&&\"image\"===i.type&&\"string\"==typeof n&&this.setImage(i,n)}onRemoveSlide(t,e,i){i.panzoom&&i.panzoom.destroy(),i.panzoom=void 0,i.imageEl=void 0}onChange(t,e,i,n){S(this.instance.container,yt);for(const t of e.slides){const e=t.panzoom;e&&t.index!==i&&e.reset(.35)}}onClose(){var t;const e=this.instance,i=e.container,n=e.getSlide();if(!i||!i.parentElement||!n)return;const{el:s,contentEl:o,panzoom:a,thumbElSrc:r}=n;if(!s||!r||!o||!a||a.isContentLoading||a.state===m.Init||a.state===m.Destroy)return;a.updateMetrics();let l=this.getZoomInfo(n);if(!l)return;this.instance.state=rt.CustomClosing,i.classList.remove(yt),i.classList.add(\"is-zooming-out\"),o.style.backgroundImage=`url('${r}')`;const c=i.getBoundingClientRect();1===((null===(t=window.visualViewport)||void 0===t?void 0:t.scale)||1)&&Object.assign(i.style,{position:\"absolute\",top:`${i.offsetTop+window.scrollY}px`,left:`${i.offsetLeft+window.scrollX}px`,bottom:\"auto\",right:\"auto\",width:`${c.width}px`,height:`${c.height}px`,overflow:\"hidden\"});const{x:h,y:d,scale:u,opacity:p}=l;if(p){const t=((t,e,i,n)=>{const s=e-t,o=n-i;return e=>i+((e-t)/s*o||0)})(a.scale,u,1,0);a.on(\"afterTransform\",(()=>{o.style.opacity=t(a.scale)+\"\"}))}a.on(\"endAnimation\",(()=>{e.destroy()})),a.target.a=u,a.target.b=0,a.target.c=0,a.target.d=u,a.panTo({x:h,y:d,scale:u,friction:p?.2:.33,ignoreBounds:!0}),a.isResting&&e.destroy()}setImage(t,e){const i=this.instance;t.src=e,this.process(t,e).then((e=>{const{contentEl:n,imageEl:s,thumbElSrc:o,el:a}=t;if(i.isClosing()||!n||!s)return;n.offsetHeight;const r=!!i.isOpeningSlide(t)&&this.getZoomInfo(t);if(this.option(\"protected\")&&a){a.addEventListener(\"contextmenu\",(t=>{t.preventDefault()}));const t=document.createElement(\"div\");P(t,\"fancybox-protected\"),n.appendChild(t)}if(o&&r){const s=e.contentRect,a=Math.max(s.fullWidth,s.fullHeight);let c=null;!r.opacity&&a>1200&&(c=document.createElement(\"img\"),P(c,\"fancybox-ghost\"),c.src=o,n.appendChild(c));const h=()=>{c&&(P(c,\"f-fadeFastOut\"),setTimeout((()=>{c&&(c.remove(),c=null)}),200))};(l=o,new Promise(((t,e)=>{const i=new Image;i.onload=t,i.onerror=e,i.src=l}))).then((()=>{i.hideLoading(t),t.state=lt.Opening,this.instance.emit(\"reveal\",t),this.zoomIn(t).then((()=>{h(),this.instance.done(t)}),(()=>{})),c&&setTimeout((()=>{h()}),a>2500?800:200)}),(()=>{i.hideLoading(t),i.revealContent(t)}))}else{const n=this.optionFor(t,\"initialSize\"),s=this.optionFor(t,\"zoom\"),o={event:i.prevMouseMoveEvent||i.options.event,friction:s?.12:0};let a=i.optionFor(t,\"showClass\")||void 0,r=!0;i.isOpeningSlide(t)&&(\"full\"===n?e.zoomToFull(o):\"cover\"===n?e.zoomToCover(o):\"max\"===n?e.zoomToMax(o):r=!1,e.stop(\"current\")),r&&a&&(a=e.isDragging?\"f-fadeIn\":\"\"),i.hideLoading(t),i.revealContent(t,a)}var l}),(()=>{i.setError(t,\"{{IMAGE_ERROR}}\")}))}process(t,e){return new Promise(((i,s)=>{var o;const a=this.instance,r=t.el;a.clearContent(t),a.showLoading(t);let l=this.optionFor(t,\"content\");if(\"string\"==typeof l&&(l=n(l)),!l||!E(l)){if(l=document.createElement(\"img\"),l instanceof HTMLImageElement){let i=\"\",n=t.caption;i=\"string\"==typeof n&&n?n.replace(/<[^>]+>/gi,\"\").substring(0,1e3):`Image ${t.index+1} of ${(null===(o=a.carousel)||void 0===o?void 0:o.pages.length)||1}`,l.src=e||\"\",l.alt=i,l.draggable=!1,t.srcset&&l.setAttribute(\"srcset\",t.srcset),this.instance.isOpeningSlide(t)&&(l.fetchPriority=\"high\")}t.sizes&&l.setAttribute(\"sizes\",t.sizes)}P(l,\"fancybox-image\"),t.imageEl=l,a.setContent(t,l,!1);t.panzoom=new I(r,u({transformParent:!0},this.option(\"Panzoom\")||{},{content:l,width:(e,i)=>a.optionFor(t,\"width\",\"auto\",i)||\"auto\",height:(e,i)=>a.optionFor(t,\"height\",\"auto\",i)||\"auto\",wheel:()=>{const t=a.option(\"wheel\");return(\"zoom\"===t||\"pan\"==t)&&t},click:(e,i)=>{var n,s;if(a.isCompact||a.isClosing())return!1;if(t.index!==(null===(n=a.getSlide())||void 0===n?void 0:n.index))return!1;if(i){const t=i.composedPath()[0];if([\"A\",\"BUTTON\",\"TEXTAREA\",\"OPTION\",\"INPUT\",\"SELECT\",\"VIDEO\"].includes(t.nodeName))return!1}let o=!i||i.target&&(null===(s=t.contentEl)||void 0===s?void 0:s.contains(i.target));return a.option(o?\"contentClick\":\"backdropClick\")||!1},dblClick:()=>a.isCompact?\"toggleZoom\":a.option(\"contentDblClick\")||!1,spinner:!1,panOnlyZoomed:!0,wheelLimit:1/0,on:{ready:t=>{i(t)},error:()=>{s()},destroy:()=>{s()}}}))}))}zoomIn(t){return new Promise(((e,i)=>{const n=this.instance,s=n.container,{panzoom:o,contentEl:a,el:r}=t;o&&o.updateMetrics();const l=this.getZoomInfo(t);if(!(l&&r&&a&&o&&s))return void i();const{x:c,y:h,scale:d,opacity:u}=l,p=()=>{t.state!==lt.Closing&&(u&&(a.style.opacity=Math.max(Math.min(1,1-(1-o.scale)/(1-d)),0)+\"\"),o.scale>=1&&o.scale>o.targetScale-.1&&e(o))},f=t=>{(t.scale<.99||t.scale>1.01)&&!t.isDragging||(S(s,yt),a.style.opacity=\"\",t.off(\"endAnimation\",f),t.off(\"touchStart\",f),t.off(\"afterTransform\",p),e(t))};o.on(\"endAnimation\",f),o.on(\"touchStart\",f),o.on(\"afterTransform\",p),o.on([\"error\",\"destroy\"],(()=>{i()})),o.panTo({x:c,y:h,scale:d,friction:0,ignoreBounds:!0}),o.stop(\"current\");const g={event:\"mousemove\"===o.panMode?n.prevMouseMoveEvent||n.options.event:void 0},m=this.optionFor(t,\"initialSize\");P(s,yt),n.hideLoading(t),\"full\"===m?o.zoomToFull(g):\"cover\"===m?o.zoomToCover(g):\"max\"===m?o.zoomToMax(g):o.reset(.172)}))}getZoomInfo(t){const{el:e,imageEl:i,thumbEl:n,panzoom:s}=t,o=this.instance,a=o.container;if(!e||!i||!n||!s||tt(n)<3||!this.optionFor(t,\"zoom\")||!a||o.state===rt.Destroy)return!1;if(\"0\"===getComputedStyle(a).getPropertyValue(\"--f-images-zoom\"))return!1;
vendor: 4,479 bytes, line 19
19const r=window.visualViewport||null;if(1!==(r?r.scale:1))return!1;let{top:l,left:c,width:h,height:d}=n.getBoundingClientRect(),{top:u,left:p,fitWidth:f,fitHeight:g}=s.contentRect;if(!(h&&d&&f&&g))return!1;const m=s.container.getBoundingClientRect();p+=m.left,u+=m.top;const v=-1*(p+.5*f-(c+.5*h)),b=-1*(u+.5*g-(l+.5*d)),y=h/f;let w=this.option(\"zoomOpacity\")||!1;return\"auto\"===w&&(w=Math.abs(h/d-f/g)>.1),{x:v,y:b,scale:y,opacity:w}}attach(){const t=this,e=t.instance;e.on(\"Carousel.change\",t.onChange),e.on(\"Carousel.createSlide\",t.onCreateSlide),e.on(\"Carousel.removeSlide\",t.onRemoveSlide),e.on(\"close\",t.onClose)}detach(){const t=this,e=t.instance;e.off(\"Carousel.change\",t.onChange),e.off(\"Carousel.createSlide\",t.onCreateSlide),e.off(\"Carousel.removeSlide\",t.onRemoveSlide),e.off(\"close\",t.onClose)}}Object.defineProperty(wt,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:{initialSize:\"fit\",Panzoom:{maxScale:1},protected:!1,zoom:!0,zoomOpacity:\"auto\"}}),\"function\"==typeof SuppressedError&&SuppressedError;const xt=\"html\",Et=\"image\",St=\"map\",Pt=\"youtube\",Ct=\"vimeo\",Tt=\"html5video\",Mt=(t,e={})=>{const i=new URL(t),n=new URLSearchParams(i.search),s=new URLSearchParams;for(const[t,i]of[...n,...Object.entries(e)]){let e=i+\"\";if(\"t\"===t){let t=e.match(/((\\d*)m)?(\\d*)s?/);t&&s.set(\"start\",60*parseInt(t[2]||\"0\")+parseInt(t[3]||\"0\")+\"\")}else s.set(t,e)}let o=s+\"\",a=t.match(/#t=((.*)?\\d+s)/);return a&&(o+=`#t=${a[1]}`),o},Ot={ajax:null,autoSize:!0,iframeAttr:{allow:\"autoplay; fullscreen\",scrolling:\"auto\"},preload:!0,videoAutoplay:!0,videoRatio:16/9,videoTpl:'<video class=\"fancybox__html5video\" playsinline controls controlsList=\"nodownload\" poster=\"{{poster}}\">\\n <source src=\"{{src}}\" type=\"{{format}}\" />Sorry, your browser doesn\\'t support embedded videos.</video>',videoFormat:\"\",vimeo:{byline:1,color:\"00adef\",controls:1,dnt:1,muted:0},youtube:{controls:1,enablejsapi:1,nocookie:1,rel:0,fs:1}},At=[\"image\",\"html\",\"ajax\",\"inline\",\"clone\",\"iframe\",\"map\",\"pdf\",\"html5video\",\"youtube\",\"vimeo\"];class Lt extends _{onBeforeInitSlide(t,e,i){this.processType(i)}onCreateSlide(t,e,i){this.setContent(i)}onClearContent(t,e){e.xhr&&(e.xhr.abort(),e.xhr=null);const i=e.iframeEl;i&&(i.onload=i.onerror=null,i.src=\"//about:blank\",e.iframeEl=null);const n=e.contentEl,s=e.placeholderEl;if(\"inline\"===e.type&&n&&s)n.classList.remove(\"fancybox__content\"),\"none\"!==getComputedStyle(n).getPropertyValue(\"display\")&&(n.style.display=\"none\"),setTimeout((()=>{s&&(n&&s.parentNode&&s.parentNode.insertBefore(n,s),s.remove())}),0),e.contentEl=void 0,e.placeholderEl=void 0;else for(;e.el&&e.el.firstChild;)e.el.removeChild(e.el.firstChild)}onSelectSlide(t,e,i){i.state===lt.Ready&&this.playVideo()}onUnselectSlide(t,e,i){var n,s;if(i.type===Tt){try{null===(s=null===(n=i.el)||void 0===n?void 0:n.querySelector(\"video\"))||void 0===s||s.pause()}catch(t){}return}let o;i.type===Ct?o={method:\"pause\",value:\"true\"}:i.type===Pt&&(o={event:\"command\",func:\"pauseVideo\"}),o&&i.iframeEl&&i.iframeEl.contentWindow&&i.iframeEl.contentWindow.postMessage(JSON.stringify(o),\"*\"),i.poller&&clearTimeout(i.poller)}onDone(t,e){t.isCurrentSlide(e)&&!t.isClosing()&&this.playVideo()}onRefresh(t,e){e.slides.forEach((t=>{t.el&&(this.resizeIframe(t),this.setAspectRatio(t))}))}onMessage(t){try{let e=JSON.parse(t.data);if(\"https://player.vimeo.com\"===t.origin){if(\"ready\"===e.event)for(let e of Array.from(document.getElementsByClassName(\"fancybox__iframe\")))e instanceof HTMLIFrameElement&&e.contentWindow===t.source&&(e.dataset.ready=\"true\")}else if(t.origin.match(/^https:\\/\\/(www.)?youtube(-nocookie)?.com$/)&&\"onReady\"===e.event){const t=document.getElementById(e.id);t&&(t.dataset.ready=\"true\")}}catch(t){}}loadAjaxContent(t){const e=this.instance.optionFor(t,\"src\")||\"\";this.instance.showLoading(t);const i=this.instance,n=new XMLHttpRequest;i.showLoading(t),n.onreadystatechange=function(){n.readyState===XMLHttpRequest.DONE&&i.state===rt.Ready&&(i.hideLoading(t),200===n.status?i.setContent(t,n.responseText):i.setError(t,404===n.status?\"{{AJAX_NOT_FOUND}}\":\"{{AJAX_FORBIDDEN}}\"))};const s=t.ajax||null;n.open(s?\"POST\":\"GET\",e+\"\"),n.setRequestHeader(\"Content-Type\",\"application/x-www-form-urlencoded\"),n.setRequestHeader(\"X-Requested-With\",\"XMLHttpRequest\"),n.send(s),t.xhr=n}setInlineContent(t){let e=null;if(E(t.src))e=t.src;
19else if(\"string\"==typeof t.src){const i=t.src.split(\"#\",2).pop();e=i?document.getElementById(i):null}if(e){if(\"clone\"===t.type||e.closest(\".fancybox__slide\")){e=e.cloneNode(!0);const i=e.dataset.animationName;i&&(e.classList.remove(i),delete e.dataset.animationName);let n=e.getAttribute(\"id\");n=n?`${n}--clone`:`clone-${this.instance.id}-${t.index}`,e.setAttribute(\"id\",n)}else if(e.parentNode){const i=document.createElement(\"div\");i.classList.add(\"fancybox-placeholder\"),e.parentNode.insertBefore(i,e),t.placeholderEl=i}this.instance.setContent(t,e)}else this.instance.setError(t,\"{{ELEMENT_NOT_FOUND}}\")}setIframeContent(t){const{src:e,el:i}=t;if(!e||\"string\"!=typeof e||!i)return;i.classList.add(\"is-loading\");const n=this.instance,s=document.createElement(\"iframe\");s.className=\"fancybox__iframe\",s.setAttribute(\"id\",`fancybox__iframe_${n.id}_${t.index}`);for(const[e,i]of Object.entries(this.optionFor(t,\"iframeAttr\")||{}))s.setAttribute(e,i);s.onerror=()=>{n.setError(t,\"{{IFRAME_ERROR}}\")},t.iframeEl=s;const o=this.optionFor(t,\"preload\");if(\"iframe\"!==t.type||!1===o)return s.setAttribute(\"src\",t.src+\"\"),n.setContent(t,s,!1),this.resizeIframe(t),void n.revealContent(t);n.showLoading(t),s.onload=()=>{if(!s.src.length)return;const e=\"true\"!==s.dataset.ready;s.dataset.ready=\"true\",this.resizeIframe(t),e?n.revealContent(t):n.hideLoading(t)},s.setAttribute(\"src\",e),n.setContent(t,s,!1)}resizeIframe(t){const{type:e,iframeEl:i}=t;if(e===Pt||e===Ct)return;const n=null==i?void 0:i.parentElement;if(!i||!n)return;let s=t.autoSize;void 0===s&&(s=this.optionFor(t,\"autoSize\"));let o=t.width||0,a=t.height||0;o&&a&&(s=!1);const r=n&&n.style;if(!1!==t.preload&&!1!==s&&r)try{const t=window.getComputedStyle(n),e=parseFloat(t.paddingLeft)+parseFloat(t.paddingRight),s=parseFloat(t.paddingTop)+parseFloat(t.paddingBottom),l=i.contentWindow;if(l){const t=l.document,i=t.getElementsByTagName(xt)[0],n=t.body;r.width=\"\",n.style.overflow=\"hidden\",o=o||i.scrollWidth+e,r.width=`${o}px`,n.style.overflow=\"\",r.flex=\"0 0 auto\",r.height=`${n.scrollHeight}px`,a=i.scrollHeight+s}}catch(t){}if(o||a){const t={flex:\"0 1 auto\",width:\"\",height:\"\"};o&&\"auto\"!==o&&(t.width=`${o}px`),a&&\"auto\"!==a&&(t.height=`${a}px`),Object.assign(r,t)}}playVideo(){const t=this.instance.getSlide();if(!t)return;const{el:e}=t;if(!e||!e.offsetParent)return;if(!this.optionFor(t,\"videoAutoplay\"))return;if(t.type===Tt)try{const t=e.querySelector(\"video\");if(t){const e=t.play();void 0!==e&&e.then((()=>{})).catch((e=>{t.muted=!0,t.play()}))}}catch(t){}if(t.type!==Pt&&t.type!==Ct)return;const i=()=>{if(t.iframeEl&&t.iframeEl.contentWindow){let e;if(\"true\"===t.iframeEl.dataset.ready)return e=t.type===Pt?{event:\"command\",func:\"playVideo\"}:{method:\"play\",value:\"true\"},e&&t.iframeEl.contentWindow.postMessage(JSON.stringify(e),\"*\"),void(t.poller=void 0);t.type===Pt&&(e={event:\"listening\",id:t.iframeEl.getAttribute(\"id\")},t.iframeEl.contentWindow.postMessage(JSON.stringify(e),\"*\"))}t.poller=setTimeout(i,250)};i()}processType(t){if(t.html)return t.type=xt,t.src=t.html,void(t.html=\"\");const e=this.instance.optionFor(t,\"src\",\"\");if(!e||\"string\"!=typeof e)return;let i=t.type,n=null;if(n=e.match(/(youtube\\.com|youtu\\.be|youtube\\-nocookie\\.com)\\/(?:watch\\?(?:.*&)?v=|v\\/|u\\/|shorts\\/|embed\\/?)?(videoseries\\?list=(?:.*)|[\\w-]{11}|\\?listType=(?:.*)&list=(?:.*))(?:.*)/i)){const s=this.optionFor(t,Pt),{nocookie:o}=s,a=function(t,e){var i={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(i[n]=t[n]);if(null!=t&&\"function\"==typeof Object.getOwnPropertySymbols){var s=0;for(n=Object.getOwnPropertySymbols(t);s<n.length;s++)e.indexOf(n[s])<0&&Object.prototype.propertyIsEnumerable.call(t,n[s])&&(i[n[s]]=t[n[s]])}return i}(s,[\"nocookie\"]),r=`www.youtube${o?\"-nocookie\":\"\"}.com`,l=Mt(e,a),c=encodeURIComponent(n[2]);t.videoId=c,t.src=`https://${r}/embed/${c}?${l}`,t.thumbSrc=t.thumbSrc||`https://i.ytimg.com/vi/${c}/mqdefault.jpg`,i=Pt}else if(n=e.match(/^.+vimeo.com\\/(?:\\/)?([\\d]+)((\\/|\\?h=)([a-z0-9]+))?(.*)?/)){const s=Mt(e,this.optionFor(t,Ct)),o=encodeURIComponent(n[1]),a=n[4]||\"\";t.videoId=o,t.src=`https://player.vimeo.com/video/${o}?${a?`h=${a}${s?\"&\":\"\"}`:\"\"}${s}`,i=Ct}if(!i&&t.triggerEl){const e=t.triggerEl.dataset.type;At.includes(e)&&(i=e)}
19i||\"string\"==typeof e&&(\"#\"===e.charAt(0)?i=\"inline\":(n=e.match(/\\.(mp4|mov|ogv|webm)((\\?|#).*)?$/i))?(i=Tt,t.videoFormat=t.videoFormat||\"video/\"+(\"ogv\"===n[1]?\"ogg\":n[1])):e.match(/(^data:image\\/[a-z0-9+\\/=]*,)|(\\.(jp(e|g|eg)|gif|png|bmp|webp|svg|ico)((\\?|#).*)?$)/i)?i=Et:e.match(/\\.(pdf)((\\?|#).*)?$/i)&&(i=\"pdf\")),(n=e.match(/(?:maps\\.)?google\\.([a-z]{2,3}(?:\\.[a-z]{2})?)\\/(?:(?:(?:maps\\/(?:place\\/(?:.*)\\/)?\\@(.*),(\\d+.?\\d+?)z))|(?:\\?ll=))(.*)?/i))?(t.src=`https://maps.google.${n[1]}/?ll=${(n[2]?n[2]+\"&z=\"+Math.floor(parseFloat(n[3]))+(n[4]?n[4].replace(/^\\//,\"&\"):\"\"):n[4]+\"\").replace(/\\?/,\"&\")}&output=${n[4]&&n[4].indexOf(\"layer=c\")>0?\"svembed\":\"embed\"}`,i=St):(n=e.match(/(?:maps\\.)?google\\.([a-z]{2,3}(?:\\.[a-z]{2})?)\\/(?:maps\\/search\\/)(.*)/i))&&(t.src=`https://maps.google.${n[1]}/maps?q=${n[2].replace(\"query=\",\"q=\").replace(\"api=1\",\"\")}&output=embed`,i=St),i=i||this.instance.option(\"defaultType\"),t.type=i,i===Et&&(t.thumbSrc=t.thumbSrc||t.src)}setContent(t){const e=this.instance.optionFor(t,\"src\")||\"\";if(t&&t.type&&e){switch(t.type){case xt:this.instance.setContent(t,e);break;case Tt:const i=this.option(\"videoTpl\");i&&this.instance.setContent(t,i.replace(/\\{\\{src\\}\\}/gi,e+\"\").replace(/\\{\\{format\\}\\}/gi,this.optionFor(t,\"videoFormat\")||\"\").replace(/\\{\\{poster\\}\\}/gi,t.poster||t.thumbSrc||\"\"));break;case\"inline\":case\"clone\":this.setInlineContent(t);break;case\"ajax\":this.loadAjaxContent(t);break;case\"pdf\":case St:case Pt:case Ct:t.preload=!1;case\"iframe\":this.setIframeContent(t)}this.setAspectRatio(t)}}setAspectRatio(t){const e=t.contentEl;if(!(t.el&&e&&t.type&&[Pt,Ct,Tt].includes(t.type)))return;let i,n=t.width||\"auto\",s=t.height||\"auto\";if(\"auto\"===n||\"auto\"===s){i=this.optionFor(t,\"videoRatio\");const e=(i+\"\").match(/(\\d+)\\s*\\/\\s?(\\d+)/);i=e&&e.length>2?parseFloat(e[1])/parseFloat(e[2]):parseFloat(i+\"\")}else n&&s&&(i=n/s);if(!i)return;e.style.aspectRatio=\"\",e.style.width=\"\",e.style.height=\"\",e.offsetHeight;const o=e.getBoundingClientRect(),a=o.width||1,r=o.height||1;e.style.aspectRatio=i+\"\",i<a/r?(s=\"auto\"===s?r:Math.min(r,s),e.style.width=\"auto\",e.style.height=`${s}px`):(n=\"auto\"===n?a:Math.min(a,n),e.style.width=`${n}px`,e.style.height=\"auto\")}attach(){const t=this,e=t.instance;e.on(\"Carousel.beforeInitSlide\",t.onBeforeInitSlide),e.on(\"Carousel.createSlide\",t.onCreateSlide),e.on(\"Carousel.selectSlide\",t.onSelectSlide),e.on(\"Carousel.unselectSlide\",t.onUnselectSlide),e.on(\"Carousel.Panzoom.refresh\",t.onRefresh),e.on(\"done\",t.onDone),e.on(\"clearContent\",t.onClearContent),window.addEventListener(\"message\",t.onMessage)}detach(){const t=this,e=t.instance;e.off(\"Carousel.beforeInitSlide\",t.onBeforeInitSlide),e.off(\"Carousel.createSlide\",t.onCreateSlide),e.off(\"Carousel.selectSlide\",t.onSelectSlide),e.off(\"Carousel.unselectSlide\",t.onUnselectSlide),e.off(\"Carousel.Panzoom.refresh\",t.onRefresh),e.off(\"done\",t.onDone),e.off(\"clearContent\",t.onClearContent),window.removeEventListener(\"message\",t.onMessage)}}Object.defineProperty(Lt,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:Ot});const zt=\"play\",Rt=\"pause\",kt=\"ready\";class It extends _{constructor(){super(...arguments),Object.defineProperty(this,\"state\",{enumerable:!0,configurable:!0,writable:!0,value:kt}),Object.defineProperty(this,\"inHover\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,\"timer\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"progressBar\",{enumerable:!0,configurable:!0,writable:!0,value:null})}get isActive(){return this.state!==kt}onReady(t){this.option(\"autoStart\")&&(t.isInfinite||t.page<t.pages.length-1)&&this.start()}onChange(){this.removeProgressBar(),this.pause()}onSettle(){this.resume()}onVisibilityChange(){\"visible\"===document.visibilityState?this.resume():this.pause()}onMouseEnter(){this.inHover=!0,this.pause()}onMouseLeave(){var t;this.inHover=!1,(null===(t=this.instance.panzoom)||void 0===t?void 0:t.isResting)&&this.resume()}onTimerEnd(){const t=this.instance;\"play\"===this.state&&(t.isInfinite||t.page!==t.pages.length-1?t.slideNext():t.slideTo(0))}removeProgressBar(){this.progressBar&&(this.progressBar.remove(),this.progressBar=null)}createProgressBar(){var t;if(!this.option(\"showProgress\"))return null;this.removeProgressBar();const e=this.instance,i=(null===(t=e.pages[e.page])||void 0===t?void 0:t.slides)||[];let n=this.option(\"progressParentEl\");if(n||(n=(1===i.length?i[0].el:null)||e.viewport),!n)return null;const s=document.createElement(\"div\");return P(s,\"f-progress\"),n.prepend(s),this.progressBar=s,s.offsetHeight,s}set(){const t=this,e=t.instance;if(e.pages.length<2)return;if(t.timer)return;const i=t.option(\"timeout\");t.state=zt,P(e.container,\"has-autoplay\");let n=t.createProgressBar();n&&(n.style.transitionDuration=`${i}ms`,n.style.transform=\"scaleX(1)\"),t.timer=setTimeout((()=>{t.timer=null,t.inHover||t.onTimerEnd()}),i),t.emit(\"set\")}clear(){const t=this;t.timer&&(clearTimeout(t.timer),t.timer=null),t.removeProgressBar()}start(){const t=this;if(t.set(),t.state!==kt){if(t.option(\"pauseOnHover\")){const e=t.instance.container;e.addEventListener(\"mouseenter\",t.onMouseEnter,!1),e.addEventListener(\"mouseleave\",t.onMouseLeave,!1)}document.addEventListener(\"visibilitychange\",t.onVisibilityChange,!1),t.emit(\"start\")}}stop(){const t=this,e=t.state,i=t.instance.container;t.clear(),t.state=kt,i.removeEventListener(\"mouseenter\",t.onMouseEnter,!1),i.removeEventListener(\"mouseleave\",t.onMouseLeave,!1),document.removeEventListener(\"visibilitychange\",t.onVisibilityChange,!1),S(i,\"has-autoplay\"),e!==kt&&t.emit(\"stop\")}pause(){const t=this;t.state===zt&&(t.state=Rt,t.clear(),t.emit(Rt))}resume(){const t=this,e=t.instance;if(e.isInfinite||e.page!==e.pages.length-1)if(t.state!==zt){if(t.state===Rt&&!t.inHover){const e=new Event(\"resume\",{bubbles:!0,cancelable:!0});t.emit(\"resume\",e),e.defaultPrevented||t.set()}}else t.set();else t.stop()}toggle(){this.state===zt||this.state===Rt?this.stop():this.start()}attach(){const t=this,e=t.instance;e.on(\"ready\",t.onReady),e.on(\"Panzoom.startAnimation\",t.onChange),e.on(\"Panzoom.endAnimation\",t.onSettle),e.on(\"Panzoom.touchMove\",t.onChange)}detach(){const t=this,e=t.instance;e.off(\"ready\",t.onReady),e.off(\"Panzoom.startAnimation\",t.onChange),e.off(\"Panzoom.endAnimation\",t.onSettle),e.off(\"Panzoom.touchMove\",t.onChange),t.stop()}}Object.defineProperty(It,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:{autoStart:!0,pauseOnHover:!0,progressParentEl:null,showProgress:!0,timeout:3e3}});class Dt extends _{constructor(){super(...arguments),Object.defineProperty(this,\"ref\",{enumerable:!0,configurable:!0,writable:!0,value:null})}onPrepare(t){const e=t.carousel;if(!e)return;const i=t.container;i&&(e.options.Autoplay=u({autoStart:!1},this.option(\"Autoplay\")||{},{pauseOnHover:!1,timeout:this.option(\"timeout\"),progressParentEl:()=>this.option(\"progressParentEl\")||null,on:{start:()=>{t.emit(\"startSlideshow\")}
19,set:e=>{var n;i.classList.add(\"has-slideshow\"),(null===(n=t.getSlide())||void 0===n?void 0:n.state)!==lt.Ready&&e.pause()},stop:()=>{i.classList.remove(\"has-slideshow\"),t.isCompact||t.endIdle(),t.emit(\"endSlideshow\")},resume:(e,i)=>{var n,s,o;!i||!i.cancelable||(null===(n=t.getSlide())||void 0===n?void 0:n.state)===lt.Ready&&(null===(o=null===(s=t.carousel)||void 0===s?void 0:s.panzoom)||void 0===o?void 0:o.isResting)||i.preventDefault()}}}),e.attachPlugins({Autoplay:It}),this.ref=e.plugins.Autoplay)}onReady(t){const e=t.carousel,i=this.ref;i&&e&&this.option(\"playOnStart\")&&(e.isInfinite||e.page<e.pages.length-1)&&i.start()}onDone(t,e){const i=this.ref,n=t.carousel;if(!i||!n)return;const s=e.panzoom;s&&s.on(\"startAnimation\",(()=>{t.isCurrentSlide(e)&&i.stop()})),t.isCurrentSlide(e)&&i.resume()}onKeydown(t,e){var i;const n=this.ref;n&&e===this.option(\"key\")&&\"BUTTON\"!==(null===(i=document.activeElement)||void 0===i?void 0:i.nodeName)&&n.toggle()}attach(){const t=this,e=t.instance;e.on(\"Carousel.init\",t.onPrepare),e.on(\"Carousel.ready\",t.onReady),e.on(\"done\",t.onDone),e.on(\"keydown\",t.onKeydown)}detach(){const t=this,e=t.instance;e.off(\"Carousel.init\",t.onPrepare),e.off(\"Carousel.ready\",t.onReady),e.off(\"done\",t.onDone),e.off(\"keydown\",t.onKeydown)}}Object.defineProperty(Dt,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:{key:\" \",playOnStart:!1,progressParentEl:t=>{var e;return(null===(e=t.instance.container)||void 0===e?void 0:e.querySelector(\".fancybox__toolbar [data-fancybox-toggle-slideshow]\"))||t.instance.container},timeout:3e3}});const Ft={classes:{container:\"f-thumbs f-carousel__thumbs\",viewport:\"f-thumbs__viewport\",track:\"f-thumbs__track\",slide:\"f-thumbs__slide\",isResting:\"is-resting\",isSelected:\"is-selected\",isLoading:\"is-loading\",hasThumbs:\"has-thumbs\"},minCount:2,parentEl:null,thumbTpl:'<button class=\"f-thumbs__slide__button\" tabindex=\"0\" type=\"button\" aria-label=\"{{GOTO}}\" data-carousel-index=\"%i\"><img class=\"f-thumbs__slide__img\" data-lazy-src=\"{{%s}}\" alt=\"\" /></button>',type:\"modern\"};var jt;!function(t){t[t.Init=0]=\"Init\",t[t.Ready=1]=\"Ready\",t[t.Hidden=2]=\"Hidden\"}(jt||(jt={}));const Bt=\"isResting\",Ht=\"thumbWidth\",Nt=\"thumbHeight\",_t=\"thumbClipWidth\";let $t=class extends _{constructor(){super(...arguments),Object.defineProperty(this,\"type\",{enumerable:!0,configurable:!0,writable:!0,value:\"modern\"}),Object.defineProperty(this,\"container\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"track\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"carousel\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"thumbWidth\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"thumbClipWidth\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"thumbHeight\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"thumbGap\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"thumbExtraGap\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"state\",{enumerable:!0,configurable:!0,writable:!0,value:jt.Init})}get isModern(){return\"modern\"===this.type}onInitSlide(t,e){const i=e.el?e.el.dataset:void 0;i&&(e.thumbSrc=i.thumbSrc||e.thumbSrc||\"\",e[_t]=parseFloat(i[_t]||\"\")||e[_t]||0,e[Nt]=parseFloat(i.thumbHeight||\"\")||e[Nt]||0),this.addSlide(e)}onInitSlides(){this.build()}onChange(){var t;if(!this.isModern)return;const e=this.container,i=this.instance,n=i.panzoom,s=this.carousel,a=s?s.panzoom:null,r=i.page;if(n&&s&&a){if(n.isDragging){S(e,this.cn(Bt));let n=(null===(t=s.pages[r])||void 0===t?void 0:t.pos)||0;n+=i.getProgress(r)*(this[_t]+this.thumbGap);let o=a.getBounds();-1*n>o.x.min&&-1*n<o.x.max&&a.panTo({x:-1*n,friction:.12})}else o(e,this.cn(Bt),n.isResting);this.shiftModern()}}onRefresh(){this.updateProps();for(const t of this.instance.slides||[])this.resizeModernSlide(t);this.shiftModern()}isDisabled(){const t=this.option(\"minCount\")||0;if(t){const e=this.instance;let i=0;for(const t of e.slides||[])t.thumbSrc&&i++;if(i<t)return!0}const e=this.option(\"type\");return[\"modern\",\"classic\"].indexOf(e)<0}getThumb(t){const e=this.option(\"thumbTpl\")||\"\";return{html:this.instance.localize(e,[[\"%i\",t.index],[\"%d\",t.index+1],[\"%s\",t.thumbSrc||\"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7\"]])}}addSlide(t){const e=this.carousel;e&&e.addSlide(t.index,this.getThumb(t))}getSlides(){const t=[];for(const e of this.instance.slides||[])t.push(this.getThumb(e));return t}resizeModernSlide(t){this.isModern&&(t[Ht]=t[_t]&&t[Nt]?Math.round(this[Nt]*(t[_t]/t[Nt])):this[Ht])}updateProps(){const t=this.container;if(!t)return;const e=e=>parseFloat(getComputedStyle(t).getPropertyValue(\"--f-thumb-\"+e))||0;this.thumbGap=e(\"gap\"),this.thumbExtraGap=e(\"extra-gap\"),this[Ht]=e(\"width\")||40,this[_t]=e(\"clip-width\")||40,this[Nt]=e(\"height\")||40}build(){const t=this;if(t.state!==jt.Init)return;if(t.isDisabled())return void t.emit(\"disabled\");
19const e=t.instance,i=e.container,n=t.getSlides(),s=t.option(\"type\");t.type=s;const o=t.option(\"parentEl\"),a=t.cn(\"container\"),r=t.cn(\"track\");let l=null==o?void 0:o.querySelector(\".\"+a);l||(l=document.createElement(\"div\"),P(l,a),o?o.appendChild(l):i.after(l)),P(l,`is-${s}`),P(i,t.cn(\"hasThumbs\")),t.container=l,t.updateProps();let c=l.querySelector(\".\"+r);c||(c=document.createElement(\"div\"),P(c,t.cn(\"track\")),l.appendChild(c)),t.track=c;const h=u({},{track:c,infinite:!1,center:!0,fill:\"classic\"===s,dragFree:!0,slidesPerPage:1,transition:!1,preload:.25,friction:.12,Panzoom:{maxVelocity:0},Dots:!1,Navigation:!1,classes:{container:\"f-thumbs\",viewport:\"f-thumbs__viewport\",track:\"f-thumbs__track\",slide:\"f-thumbs__slide\"}},t.option(\"Carousel\")||{},{Sync:{target:e},slides:n}),d=new e.constructor(l,h);d.on(\"createSlide\",((e,i)=>{t.setProps(i.index),t.emit(\"createSlide\",i,i.el)})),d.on(\"ready\",(()=>{t.shiftModern(),t.emit(\"ready\")})),d.on(\"refresh\",(()=>{t.shiftModern()})),d.on(\"Panzoom.click\",((e,i,n)=>{t.onClick(n)})),t.carousel=d,t.state=jt.Ready}onClick(t){t.preventDefault(),t.stopPropagation();const e=this.instance,{pages:i,page:n}=e,s=t=>{if(t){const e=t.closest(\"[data-carousel-index]\");if(e)return[parseInt(e.dataset.carouselIndex||\"\",10)||0,e]}return[-1,void 0]},o=(t,e)=>{const i=document.elementFromPoint(t,e);return i?s(i):[-1,void 0]};let[a,r]=s(t.target);if(a>-1)return;const l=this[_t],c=t.clientX,h=t.clientY;let[d,u]=o(c-l,h),[p,f]=o(c+l,h);u&&f?(a=Math.abs(c-u.getBoundingClientRect().right)<Math.abs(c-f.getBoundingClientRect().left)?d:p,a===n&&(a=a===d?p:d)):u?a=d:f&&(a=p),a>-1&&i[a]&&e.slideTo(a)}getShift(t){var e;const i=this,{instance:n}=i,s=i.carousel;if(!n||!s)return 0;const o=i[Ht],a=i[_t],r=i.thumbGap,l=i.thumbExtraGap;if(!(null===(e=s.slides[t])||void 0===e?void 0:e.el))return 0;const c=.5*(o-a),h=n.pages.length-1;let d=n.getProgress(0),u=n.getProgress(h),p=n.getProgress(t,!1,!0),f=0,g=c+l+r;const m=d<0&&d>-1,v=u>0&&u<1;return 0===t?(f=g*Math.abs(d),v&&1===d&&(f-=g*Math.abs(u))):t===h?(f=g*Math.abs(u)*-1,m&&-1===u&&(f+=g*Math.abs(d))):m||v?(f=-1*g,f+=g*Math.abs(d),f+=g*(1-Math.abs(u))):f=g*p,f}setProps(e){var i;const n=this;if(!n.isModern)return;const{instance:s}=n,o=n.carousel;if(s&&o){const a=null===(i=o.slides[e])||void 0===i?void 0:i.el;if(a&&a.childNodes.length){let i=t(1-Math.abs(s.getProgress(e))),o=t(n.getShift(e));a.style.setProperty(\"--progress\",i?i+\"\":\"\"),a.style.setProperty(\"--shift\",o+\"\")}}}shiftModern(){const t=this;if(!t.isModern)return;const{instance:e,track:i}=t,n=e.panzoom,s=t.carousel;if(!(e&&i&&n&&s))return;if(n.state===m.Init||n.state===m.Destroy)return;for(const i of e.slides)t.setProps(i.index);let o=(t[_t]+t.thumbGap)*(s.slides.length||0);i.style.setProperty(\"--width\",o+\"\")}cleanup(){const t=this;t.carousel&&t.carousel.destroy(),t.carousel=null,t.container&&t.container.remove(),t.container=null,t.track&&t.track.remove(),t.track=null,t.state=jt.Init,S(t.instance.container,t.cn(\"hasThumbs\"))}attach(){const t=this,e=t.instance;e.on(\"initSlide\",t.onInitSlide),e.state===B.Init?e.on(\"initSlides\",t.onInitSlides):t.onInitSlides(),e.on([\"change\",\"Panzoom.afterTransform\"],t.onChange),e.on(\"Panzoom.refresh\",t.onRefresh)}detach(){const t=this,e=t.instance;e.off(\"initSlide\",t.onInitSlide),e.off(\"initSlides\",t.onInitSlides),e.off([\"change\",\"Panzoom.afterTransform\"],t.onChange),e.off(\"Panzoom.refresh\",t.onRefresh),t.cleanup()}};Object.defineProperty($t,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:Ft});const Wt=Object.assign(Object.assign({},Ft),{key:\"t\",showOnStart:!0,parentEl:null}),Xt=\"is-masked\",qt=\"aria-hidden\";class Yt extends _{constructor(){super(...arguments),Object.defineProperty(this,\"ref\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"hidden\",{enumerable:!0,configurable:!0,writable:!0,value:!1})}get isEnabled(){const t=this.ref;return t&&!t.isDisabled()}get isHidden(){return this.hidden}onClick(t,e){e.stopPropagation()}onCreateSlide(t,e){var i,n,s;const o=(null===(s=null===(n=null===(i=this.instance)||void 0===i?void 0:i.carousel)||void 0===n?void 0:n.slides[e.index])||void 0===s?void 0:s.type)||\"\",a=e.el;if(a&&o){let t=`for-${o}`;
19[\"video\",\"youtube\",\"vimeo\",\"html5video\"].includes(o)&&(t+=\" for-video\"),P(a,t)}}onInit(){var t;const e=this,i=e.instance,n=i.carousel;if(e.ref||!n)return;const s=e.option(\"parentEl\")||i.footer||i.container;if(!s)return;const o=u({},e.options,{parentEl:s,classes:{container:\"f-thumbs fancybox__thumbs\"},Carousel:{Sync:{friction:i.option(\"Carousel.friction\")||0}},on:{ready:t=>{const i=t.container;i&&this.hidden&&(e.refresh(),i.style.transition=\"none\",e.hide(),i.offsetHeight,queueMicrotask((()=>{i.style.transition=\"\",e.show()})))}}});o.Carousel=o.Carousel||{},o.Carousel.on=u((null===(t=e.options.Carousel)||void 0===t?void 0:t.on)||{},{click:this.onClick,createSlide:this.onCreateSlide}),n.options.Thumbs=o,n.attachPlugins({Thumbs:$t}),e.ref=n.plugins.Thumbs,e.option(\"showOnStart\")||(e.ref.state=jt.Hidden,e.hidden=!0)}onResize(){var t;const e=null===(t=this.ref)||void 0===t?void 0:t.container;e&&(e.style.maxHeight=\"\")}onKeydown(t,e){const i=this.option(\"key\");i&&i===e&&this.toggle()}toggle(){const t=this.ref;if(t&&!t.isDisabled())return t.state===jt.Hidden?(t.state=jt.Init,void t.build()):void(this.hidden?this.show():this.hide())}show(){const t=this.ref;if(!t||t.isDisabled())return;const e=t.container;e&&(this.refresh(),e.offsetHeight,e.removeAttribute(qt),e.classList.remove(Xt),this.hidden=!1)}hide(){const t=this.ref,e=t&&t.container;e&&(this.refresh(),e.offsetHeight,e.classList.add(Xt),e.setAttribute(qt,\"true\")),this.hidden=!0}refresh(){const t=this.ref;if(!t||!t.state)return;const e=t.container,i=(null==e?void 0:e.firstChild)||null;e&&i&&i.childNodes.length&&(e.style.maxHeight=`${i.getBoundingClientRect().height}px`)}attach(){const t=this,e=t.instance;e.state===rt.Init?e.on(\"Carousel.init\",t.onInit):t.onInit(),e.on(\"resize\",t.onResize),e.on(\"keydown\",t.onKeydown)}detach(){var t;const e=this,i=e.instance;i.off(\"Carousel.init\",e.onInit),i.off(\"resize\",e.onResize),i.off(\"keydown\",e.onKeydown),null===(t=i.carousel)||void 0===t||t.detachPlugins([\"Thumbs\"]),e.ref=null}}Object.defineProperty(Yt,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:Wt});const Vt={panLeft:{icon:'<svg><path d=\"M5 12h14M5 12l6 6M5 12l6-6\"/></svg>',change:{panX:-100}},panRight:{icon:'<svg><path d=\"M5 12h14M13 18l6-6M13 6l6 6\"/></svg>',change:{panX:100}},panUp:{icon:'<svg><path d=\"M12 5v14M18 11l-6-6M6 11l6-6\"/></svg>',change:{panY:-100}},panDown:{icon:'<svg><path d=\"M12 5v14M18 13l-6 6M6 13l6 6\"/></svg>',change:{panY:100}},zoomIn:{icon:'<svg><circle cx=\"11\" cy=\"11\" r=\"7.5\"/><path d=\"m21 21-4.35-4.35M11 8v6M8 11h6\"/></svg>',action:\"zoomIn\"},zoomOut:{icon:'<svg><circle cx=\"11\" cy=\"11\" r=\"7.5\"/><path d=\"m21 21-4.35-4.35M8 11h6\"/></svg>',action:\"zoomOut\"},toggle1to1:{icon:'<svg><path d=\"M3.51 3.07c5.74.02 11.48-.02 17.22.02 1.37.1 2.34 1.64 2.18 3.13 0 4.08.02 8.16 0 12.23-.1 1.54-1.47 2.64-2.79 2.46-5.61-.01-11.24.02-16.86-.01-1.36-.12-2.33-1.65-2.17-3.14 0-4.07-.02-8.16 0-12.23.1-1.36 1.22-2.48 2.42-2.46Z\"/><path d=\"M5.65 8.54h1.49v6.92m8.94-6.92h1.49v6.92M11.5 9.4v.02m0 5.18v0\"/></svg>',action:\"toggleZoom\"},toggleZoom:{icon:'<svg><g><line x1=\"11\" y1=\"8\" x2=\"11\" y2=\"14\"></line></g><circle cx=\"11\" cy=\"11\" r=\"7.5\"/><path d=\"m21 21-4.35-4.35M8 11h6\"/></svg>',action:\"toggleZoom\"},iterateZoom:{icon:'<svg><g><line x1=\"11\" y1=\"8\" x2=\"11\" y2=\"14\"></line></g><circle cx=\"11\" cy=\"11\" r=\"7.5\"/><path d=\"m21 21-4.35-4.35M8 11h6\"/></svg>',action:\"iterateZoom\"},rotateCCW:{icon:'<svg><path d=\"M15 4.55a8 8 0 0 0-6 14.9M9 15v5H4M18.37 7.16v.01M13 19.94v.01M16.84 18.37v.01M19.37 15.1v.01M19.94 11v.01\"/></svg>',action:\"rotateCCW\"},rotateCW:{icon:'<svg><path d=\"M9 4.55a8 8 0 0 1 6 14.9M15 15v5h5M5.63 7.16v.01M4.06 11v.01M4.63 15.1v.01M7.16 18.37v.01M11 19.94v.01\"/></svg>',action:\"rotateCW\"},flipX:{icon:'<svg style=\"stroke-width: 1.3\"><path d=\"M12 3v18M16 7v10h5L16 7M8 7v10H3L8 7\"/></svg>',action:\"flipX\"},flipY:{icon:'<svg style=\"stroke-width: 1.3\"><path d=\"M3 12h18M7 16h10L7 21v-5M7 8h10L7 3v5\"/></svg>',action:\"flipY\"},fitX:{icon:'<svg><path d=\"M4 12V6a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v6M10 18H3M21 18h-7M6 15l-3 3 3 3M18 15l3 3-3 3\"/></svg>',action:\"fitX\"},fitY:{icon:'<svg><path d=\"M12 20H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h6M18 14v7M18 3v7M15 18l3 3 3-3M15 6l3-3 3 3\"/></svg>',action:\"fitY\"},reset:{icon:'<svg><path d=\"M20 11A8.1 8.1 0 0 0 4.5 9M4 5v4h4M4 13a8.1 8.1 0 0 0 15.5 2m.5 4v-4h-4\"/>
19</svg>',action:\"reset\"},toggleFS:{icon:'<svg><g><path d=\"M14.5 9.5 21 3m0 0h-6m6 0v6M3 21l6.5-6.5M3 21v-6m0 6h6\"/></g><g><path d=\"m14 10 7-7m-7 7h6m-6 0V4M3 21l7-7m0 0v6m0-6H4\"/></g></svg>',action:\"toggleFS\"}};var Zt;!function(t){t[t.Init=0]=\"Init\",t[t.Ready=1]=\"Ready\",t[t.Disabled=2]=\"Disabled\"}(Zt||(Zt={}));const Ut={absolute:\"auto\",display:{left:[\"infobar\"],middle:[],right:[\"iterateZoom\",\"slideshow\",\"fullscreen\",\"thumbs\",\"close\"]},enabled:\"auto\",items:{infobar:{tpl:'<div class=\"fancybox__infobar\" tabindex=\"-1\"><span data-fancybox-current-index></span>/<span data-fancybox-count></span></div>'},download:{tpl:'<a class=\"f-button\" title=\"{{DOWNLOAD}}\" data-fancybox-download href=\"javasript:;\"><svg><path d=\"M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-2M7 11l5 5 5-5M12 4v12\"/></svg></a>'},prev:{tpl:'<button class=\"f-button\" title=\"{{PREV}}\" data-fancybox-prev><svg><path d=\"m15 6-6 6 6 6\"/></svg></button>'},next:{tpl:'<button class=\"f-button\" title=\"{{NEXT}}\" data-fancybox-next><svg><path d=\"m9 6 6 6-6 6\"/></svg></button>'},slideshow:{tpl:'<button class=\"f-button\" title=\"{{TOGGLE_SLIDESHOW}}\" data-fancybox-toggle-slideshow><svg><g><path d=\"M8 4v16l13 -8z\"></path></g><g><path d=\"M8 4v15M17 4v15\"/></g></svg></button>'},fullscreen:{tpl:'<button class=\"f-button\" title=\"{{TOGGLE_FULLSCREEN}}\" data-fancybox-toggle-fullscreen><svg><g><path d=\"M4 8V6a2 2 0 0 1 2-2h2M4 16v2a2 2 0 0 0 2 2h2M16 4h2a2 2 0 0 1 2 2v2M16 20h2a2 2 0 0 0 2-2v-2\"/></g><g><path d=\"M15 19v-2a2 2 0 0 1 2-2h2M15 5v2a2 2 0 0 0 2 2h2M5 15h2a2 2 0 0 1 2 2v2M5 9h2a2 2 0 0 0 2-2V5\"/></g></svg></button>'},thumbs:{tpl:'<button class=\"f-button\" title=\"{{TOGGLE_THUMBS}}\" data-fancybox-toggle-thumbs><svg><circle cx=\"5.5\" cy=\"5.5\" r=\"1\"/><circle cx=\"12\" cy=\"5.5\" r=\"1\"/><circle cx=\"18.5\" cy=\"5.5\" r=\"1\"/><circle cx=\"5.5\" cy=\"12\" r=\"1\"/><circle cx=\"12\" cy=\"12\" r=\"1\"/><circle cx=\"18.5\" cy=\"12\" r=\"1\"/><circle cx=\"5.5\" cy=\"18.5\" r=\"1\"/><circle cx=\"12\" cy=\"18.5\" r=\"1\"/><circle cx=\"18.5\" cy=\"18.5\" r=\"1\"/></svg></button>'},close:{tpl:'<button class=\"f-button\" title=\"{{CLOSE}}\" data-fancybox-close><svg><path d=\"m19.5 4.5-15 15M4.5 4.5l15 15\"/></svg></button>'}},parentEl:null},Gt={tabindex:\"-1\",width:\"24\",height:\"24\",viewBox:\"0 0 24 24\",xmlns:\"http://www.w3.org/2000/svg\"},Kt=\"has-toolbar\",Jt=\"fancybox__toolbar\";class Qt extends _{constructor(){super(...arguments),Object.defineProperty(this,\"state\",{enumerable:!0,configurable:!0,writable:!0,value:Zt.Init}),Object.defineProperty(this,\"container\",{enumerable:!0,configurable:!0,writable:!0,value:null})}onReady(t){var e;if(!t.carousel)return;let i=this.option(\"display\"),n=this.option(\"absolute\"),s=this.option(\"enabled\");if(\"auto\"===s){const t=this.instance.carousel;let e=0;if(t)for(const i of t.slides)(i.panzoom||\"image\"===i.type)&&e++;e||(s=!1)}s||(i=void 0);let o=0;const a={left:[],middle:[],right:[]};if(i)for(const t of[\"left\",\"middle\",\"right\"])for(const n of i[t]){const i=this.createEl(n);i&&(null===(e=a[t])||void 0===e||e.push(i),o++)}let r=null;if(o&&(r=this.createContainer()),r){for(const[t,e]of Object.entries(a)){const i=document.createElement(\"div\");P(i,Jt+\"__column is-\"+t);for(const t of e)i.appendChild(t);\"auto\"!==n||\"middle\"!==t||e.length||(n=!0),r.appendChild(i)}!0===n&&P(r,\"is-absolute\"),this.state=Zt.Ready,this.onRefresh()}else this.state=Zt.Disabled}onClick(t){var e,i;const n=this.instance,s=n.getSlide(),o=null==s?void 0:s.panzoom,a=t.target,r=a&&E(a)?a.dataset:null;if(!r)return;if(void 0!==r.fancyboxToggleThumbs)return t.preventDefault(),t.stopPropagation(),void(null===(e=n.plugins.Thumbs)||void 0===e||e.toggle());if(void 0!==r.fancyboxToggleFullscreen)return t.preventDefault(),t.stopPropagation(),void this.instance.toggleFullscreen();if(void 0!==r.fancyboxToggleSlideshow){t.preventDefault(),t.stopPropagation();const e=null===(i=n.carousel)||void 0===i?void 0:i.plugins.Autoplay;let s=e.isActive;return o&&\"mousemove\"===o.panMode&&!s&&o.reset(),void(s?e.stop():e.start())}const l=r.panzoomAction,c=r.panzoomChange;if((c||l)&&(t.preventDefault(),t.stopPropagation()),c){let t={};try{t=JSON.parse(c)}catch(t){}o&&o.applyChange(t)}
19else l&&o&&o[l]&&o[l]()}onChange(){this.onRefresh()}onRefresh(){if(this.instance.isClosing())return;const t=this.container;if(!t)return;const e=this.instance.getSlide();if(!e||e.state!==lt.Ready)return;const i=e&&!e.error&&e.panzoom;for(const e of t.querySelectorAll(\"[data-panzoom-action]\"))i?(e.removeAttribute(\"disabled\"),e.removeAttribute(\"tabindex\")):(e.setAttribute(\"disabled\",\"\"),e.setAttribute(\"tabindex\",\"-1\"));let n=i&&i.canZoomIn(),s=i&&i.canZoomOut();for(const e of t.querySelectorAll('[data-panzoom-action=\"zoomIn\"]'))n?(e.removeAttribute(\"disabled\"),e.removeAttribute(\"tabindex\")):(e.setAttribute(\"disabled\",\"\"),e.setAttribute(\"tabindex\",\"-1\"));for(const e of t.querySelectorAll('[data-panzoom-action=\"zoomOut\"]'))s?(e.removeAttribute(\"disabled\"),e.removeAttribute(\"tabindex\")):(e.setAttribute(\"disabled\",\"\"),e.setAttribute(\"tabindex\",\"-1\"));for(const e of t.querySelectorAll('[data-panzoom-action=\"toggleZoom\"],[data-panzoom-action=\"iterateZoom\"]')){s||n?(e.removeAttribute(\"disabled\"),e.removeAttribute(\"tabindex\")):(e.setAttribute(\"disabled\",\"\"),e.setAttribute(\"tabindex\",\"-1\"));const t=e.querySelector(\"g\");t&&(t.style.display=n?\"\":\"none\")}}onDone(t,e){var i;null===(i=e.panzoom)||void 0===i||i.on(\"afterTransform\",(()=>{this.instance.isCurrentSlide(e)&&this.onRefresh()})),this.instance.isCurrentSlide(e)&&this.onRefresh()}createContainer(){const t=this.instance.container;if(!t)return null;const e=this.option(\"parentEl\")||t;let i=e.querySelector(\".\"+Jt);return i||(i=document.createElement(\"div\"),P(i,Jt),e.prepend(i)),i.addEventListener(\"click\",this.onClick,{passive:!1,capture:!0}),t&&P(t,Kt),this.container=i,i}createEl(t){const e=this.instance,i=e.carousel;if(!i)return null;if(\"toggleFS\"===t)return null;if(\"fullscreen\"===t&&!ot())return null;let s=null;const o=i.slides.length||0;let a=0,r=0;for(const t of i.slides)(t.panzoom||\"image\"===t.type)&&a++,(\"image\"===t.type||t.downloadSrc)&&r++;if(o<2&&[\"infobar\",\"prev\",\"next\"].includes(t))return s;if(void 0!==Vt[t]&&!a)return null;if(\"download\"===t&&!r)return null;if(\"thumbs\"===t){const t=e.plugins.Thumbs;if(!t||!t.isEnabled)return null}if(\"slideshow\"===t){if(!i.plugins.Autoplay||o<2)return null}if(void 0!==Vt[t]){const e=Vt[t];s=document.createElement(\"button\"),s.setAttribute(\"title\",this.instance.localize(`{{${t.toUpperCase()}}}`)),P(s,\"f-button\"),e.action&&(s.dataset.panzoomAction=e.action),e.change&&(s.dataset.panzoomChange=JSON.stringify(e.change)),s.appendChild(n(this.instance.localize(e.icon)))}else{const e=(this.option(\"items\")||[])[t];e&&(s=n(this.instance.localize(e.tpl)),\"function\"==typeof e.click&&s.addEventListener(\"click\",(t=>{t.preventDefault(),t.stopPropagation(),\"function\"==typeof e.click&&e.click.call(this,this,t)})))}const l=null==s?void 0:s.querySelector(\"svg\");if(l)for(const[t,e]of Object.entries(Gt))l.getAttribute(t)||l.setAttribute(t,String(e));return s}removeContainer(){const t=this.container;t&&t.remove(),this.container=null,this.state=Zt.Disabled;const e=this.instance.container;e&&S(e,Kt)}attach(){const t=this,e=t.instance;e.on(\"Carousel.initSlides\",t.onReady),e.on(\"done\",t.onDone),e.on([\"reveal\",\"Carousel.change\"],t.onChange),t.onReady(t.instance)}detach(){const t=this,e=t.instance;e.off(\"Carousel.initSlides\",t.onReady),e.off(\"done\",t.onDone),e.off([\"reveal\",\"Carousel.change\"],t.onChange),t.removeContainer()}}Object.defineProperty(Qt,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:Ut});const te={Hash:class extends _{onReady(){ht=!1}onChange(t){ut&&clearTimeout(ut);const{hash:e}=pt(),{hash:i}=ft(),n=t.isOpeningSlide(t.getSlide());n&&(ct=i===e?\"\":i),e&&e!==i&&(ut=setTimeout((()=>{try{if(t.state===rt.Ready){let t=\"replaceState\";n&&!dt&&(t=\"pushState\",dt=!0),window.history[t]({},document.title,window.location.pathname+window.location.search+e)}}catch(t){}}),300))}onClose(t){if(ut&&clearTimeout(ut),!ht&&dt)return dt=!1,ht=!1,void window.history.back();if(!ht)try{window.history.replaceState({},document.title,window.location.pathname+window.location.search+(ct||\"\"))}catch(t){}}attach(){const t=this.instance;t.on(\"ready\",this.onReady),t.on([\"Carousel.ready\",\"Carousel.change\"],this.onChange),t.on(\"close\",this.onClose)}detach(){const t=this.instance;t.off(\"ready\",this.onReady),t.off([\"Carousel.ready\",\"Carousel.change\"],this.onChange),t.off(\"close\",this.onClose)}static parseURL(){return ft()}static startFromUrl(){gt()}static destroy(){window.removeEventListener(\"hashchange\",vt,!1)}},Html:Lt,Images:wt,Slideshow:Dt,Thumbs:Yt,Toolbar:Qt},ee=\"with-fancybox\",ie=\"hide-scrollbar\",ne=\"--fancybox-scrollbar-compensate\",se=\"--fancybox-body-margin\",oe=\"aria-hidden\",ae=\"is-using-tab\",re=\"is-animated\",le=\"is-compact\",ce=\"is-loading\",he=\"is-opening\",de=\"has-caption\",ue=\"disabled\",pe=\"tabindex\",fe=\"download\",ge=\"href\",me=\"src\",ve=t=>
19\"string\"==typeof t,be=function(){var t=window.getSelection();return!!t&&\"Range\"===t.type};let ye,we=null,xe=null,Ee=0,Se=0,Pe=0,Ce=0;const Te=new Map;let Me=0;class Oe extends g{get isIdle(){return this.idle}get isCompact(){return this.option(\"compact\")}constructor(t=[],e={},i={}){super(e),Object.defineProperty(this,\"userSlides\",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,\"userPlugins\",{enumerable:!0,configurable:!0,writable:!0,value:{}}),Object.defineProperty(this,\"idle\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,\"idleTimer\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"clickTimer\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"pwt\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"ignoreFocusChange\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,\"startedFs\",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,\"state\",{enumerable:!0,configurable:!0,writable:!0,value:rt.Init}),Object.defineProperty(this,\"id\",{enumerable:!0,configurable:!0,writable:!0,value:0}),Object.defineProperty(this,\"container\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"caption\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"footer\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"carousel\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"lastFocus\",{enumerable:!0,configurable:!0,writable:!0,value:null}),Object.defineProperty(this,\"prevMouseMoveEvent\",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),ye||(ye=ot()),this.id=e.id||++Me,Te.set(this.id,this),this.userSlides=t,this.userPlugins=i,queueMicrotask((()=>{this.init()}))}init(){if(this.state===rt.Destroy)return;this.state=rt.Init,this.attachPlugins(Object.assign(Object.assign({},Oe.Plugins),this.userPlugins)),this.emit(\"init\"),this.emit(\"attachPlugins\"),!0===this.option(\"hideScrollbar\")&&(()=>{if(!et)return;const t=document,e=t.body,i=t.documentElement;if(e.classList.contains(ie))return;let n=window.innerWidth-i.getBoundingClientRect().width;const s=parseFloat(window.getComputedStyle(e).marginRight);n<0&&(n=0),i.style.setProperty(ne,`${n}px`),s&&e.style.setProperty(se,`${s}px`),e.classList.add(ie)})(),this.initLayout(),this.scale();const t=()=>{this.initCarousel(this.userSlides),this.state=rt.Ready,this.attachEvents(),this.emit(\"ready\"),setTimeout((()=>{this.container&&this.container.setAttribute(oe,\"false\")}),16)};this.option(\"Fullscreen.autoStart\")&&ye&&!ye.isFullscreen()?ye.request().then((()=>{this.startedFs=!0,t()})).catch((()=>t())):t()}initLayout(){var t,e;const i=this.option(\"parentEl\")||document.body,s=n(this.localize(this.option(\"tpl.main\")||\"\"));if(s){if(s.setAttribute(\"id\",`fancybox-${this.id}`),s.setAttribute(\"aria-label\",this.localize(\"{{MODAL}}\")),s.classList.toggle(le,this.isCompact),P(s,this.option(\"mainClass\")||\"\"),P(s,he),this.container=s,this.footer=s.querySelector(\".fancybox__footer\"),i.appendChild(s),P(document.documentElement,ee),we&&xe||(we=document.createElement(\"span\"),P(we,\"fancybox-focus-guard\"),we.setAttribute(pe,\"0\"),we.setAttribute(oe,\"true\"),we.setAttribute(\"aria-label\",\"Focus guard\"),xe=we.cloneNode(),null===(t=s.parentElement)||void 0===t||t.insertBefore(we,s),null===(e=s.parentElement)||void 0===e||e.append(xe)),s.addEventListener(\"mousedown\",(t=>{Ee=t.pageX,Se=t.pageY,S(s,ae)})),this.option(\"closeExisting\"))for(const t of Te.values())t.id!==this.id&&t.close();else this.option(\"animated\")&&(P(s,re),setTimeout((()=>{this.isClosing()||S(s,re)}),350));this.emit(\"initLayout\")}}initCarousel(t){const i=this.container;if(!i)return;const n=i.querySelector(\".fancybox__carousel\");if(!n)return;const s=this.carousel=new Q(n,u({},{slides:t,transition:\"fade\",Panzoom:{lockAxis:this.option(\"dragToClose\")?\"xy\":\"x\",infinite:!!this.option(\"dragToClose\")&&\"y\"},Dots:!1,Navigation:{classes:{container:\"fancybox__nav\",button:\"f-button\",isNext:\"is-next\",isPrev:\"is-prev\"}},initialPage:this.option(\"startIndex\"),l10n:this.option(\"l10n\")},this.option(\"Carousel\")||{}));s.on(\"*\",((t,e,...i)=>
19{this.emit(`Carousel.${e}`,t,...i)})),s.on([\"ready\",\"change\"],(()=>{this.manageCaption()})),this.on(\"Carousel.removeSlide\",((t,e,i)=>{this.clearContent(i),i.state=void 0})),s.on(\"Panzoom.touchStart\",(()=>{var t,e;this.isCompact||this.endIdle(),(null===(t=document.activeElement)||void 0===t?void 0:t.closest(\".f-thumbs\"))&&(null===(e=this.container)||void 0===e||e.focus())})),s.on(\"settle\",(()=>{this.idleTimer||this.isCompact||!this.option(\"idle\")||this.setIdle(),this.option(\"autoFocus\")&&!this.isClosing&&this.checkFocus()})),this.option(\"dragToClose\")&&(s.on(\"Panzoom.afterTransform\",((t,i)=>{const n=this.getSlide();if(n&&e(n.el))return;const s=this.container;if(s){const t=Math.abs(i.current.f),e=t<1?\"\":Math.max(.5,Math.min(1,1-t/i.contentRect.fitHeight*1.5));s.style.setProperty(\"--fancybox-ts\",e?\"0s\":\"\"),s.style.setProperty(\"--fancybox-opacity\",e+\"\")}})),s.on(\"Panzoom.touchEnd\",((t,i,n)=>{var s;const o=this.getSlide();if(o&&e(o.el))return;if(i.isMobile&&document.activeElement&&-1!==[\"TEXTAREA\",\"INPUT\"].indexOf(null===(s=document.activeElement)||void 0===s?void 0:s.nodeName))return;const a=Math.abs(i.dragOffset.y);\"y\"===i.lockedAxis&&(a>=200||a>=50&&i.dragOffset.time<300)&&(n&&n.cancelable&&n.preventDefault(),this.close(n,\"f-throwOut\"+(i.current.f<0?\"Up\":\"Down\")))}))),s.on(\"change\",(t=>{var e;let i=null===(e=this.getSlide())||void 0===e?void 0:e.triggerEl;if(i){const e=new CustomEvent(\"slideTo\",{bubbles:!0,cancelable:!0,detail:t.page});i.dispatchEvent(e)}})),s.on([\"refresh\",\"change\"],(t=>{const e=this.container;if(!e)return;for(const i of e.querySelectorAll(\"[data-fancybox-current-index]\"))i.innerHTML=t.page+1;for(const i of e.querySelectorAll(\"[data-fancybox-count]\"))i.innerHTML=t.pages.length;if(!t.isInfinite){for(const i of e.querySelectorAll(\"[data-fancybox-next]\"))t.page<t.pages.length-1?(i.removeAttribute(ue),i.removeAttribute(pe)):(i.setAttribute(ue,\"\"),i.setAttribute(pe,\"-1\"));for(const i of e.querySelectorAll(\"[data-fancybox-prev]\"))t.page>0?(i.removeAttribute(ue),i.removeAttribute(pe)):(i.setAttribute(ue,\"\"),i.setAttribute(pe,\"-1\"))}const i=this.getSlide();if(!i)return;let n=i.downloadSrc||\"\";n||\"image\"!==i.type||i.error||!ve(i[me])||(n=i[me]);for(const t of e.querySelectorAll(\"[data-fancybox-download]\")){const e=i.downloadFilename;n?(t.removeAttribute(ue),t.removeAttribute(pe),t.setAttribute(ge,n),t.setAttribute(fe,e||n),t.setAttribute(\"target\",\"_blank\")):(t.setAttribute(ue,\"\"),t.setAttribute(pe,\"-1\"),t.removeAttribute(ge),t.removeAttribute(fe))}})),this.emit(\"initCarousel\")}attachEvents(){const t=this,e=t.container;if(!e)return;e.addEventListener(\"click\",t.onClick,{passive:!1,capture:!1}),e.addEventListener(\"wheel\",t.onWheel,{passive:!1,capture:!1}),document.addEventListener(\"keydown\",t.onKeydown,{passive:!1,capture:!0}),document.addEventListener(\"visibilitychange\",t.onVisibilityChange,!1),document.addEventListener(\"mousemove\",t.onMousemove),t.option(\"trapFocus\")&&document.addEventListener(\"focus\",t.onFocus,!0),window.addEventListener(\"resize\",t.onResize);const i=window.visualViewport;i&&(i.addEventListener(\"scroll\",t.onResize),i.addEventListener(\"resize\",t.onResize))}detachEvents(){const t=this,e=t.container;if(!e)return;document.removeEventListener(\"keydown\",t.onKeydown,{passive:!1,capture:!0}),e.removeEventListener(\"wheel\",t.onWheel,{passive:!1,capture:!1}),e.removeEventListener(\"click\",t.onClick,{passive:!1,capture:!1}),document.removeEventListener(\"mousemove\",t.onMousemove),window.removeEventListener(\"resize\",t.onResize);const i=window.visualViewport;i&&(i.removeEventListener(\"resize\",t.onResize),i.removeEventListener(\"scroll\",t.onResize)),document.removeEventListener(\"visibilitychange\",t.onVisibilityChange,!1),document.removeEventListener(\"focus\",t.onFocus,!0)}scale(){const t=this.container;if(!t)return;const e=window.visualViewport,i=Math.max(1,(null==e?void 0:e.scale)||1);let n=\"\",s=\"\",o=\"\";if(e&&i>1){let t=`${e.offsetLeft}px`,a=`${e.offsetTop}px`;n=e.width*i+\"px\",s=e.height*i+\"px\",o=`translate3d(${t}, ${a}, 0) scale(${1/i})`}t.style.transform=o,t.style.width=n,t.style.height=s}onClick(t){var e;const{container:i,isCompact:n}=this;if(!i||this.isClosing())return;!n&&this.option(\"idle\")&&this.resetIdle();const s=t.composedPath()[0];if(s.closest(\".fancybox-spinner\")||s.closest(\"[data-fancybox-close]\"))return t.preventDefault(),void this.close(t);if(s.closest(\"[data-fancybox-prev]\"))return t.preventDefault(),void this.prev();if(s.closest(\"[data-fancybox-next]\"))return t.preventDefault(),void this.next();if(\"click\"===t.type&&0===t.detail)return;if(Math.abs(t.pageX-Ee)>30||Math.abs(t.pageY-Se)>30)return;const o=document.activeElement;if(be()&&o&&i.contains(o))return;if(n&&\"image\"===(null===(e=this.getSlide())||void 0===e?void 0:e.type))return void(this.clickTimer?(clearTimeout(this.clickTimer),this.clickTimer=null):this.clickTimer=setTimeout((()=>{this.toggleIdle(),this.clickTimer=null}),350));
19if(this.emit(\"click\",t),t.defaultPrevented)return;let a=!1;if(s.closest(\".fancybox__content\")){if(o){if(o.closest(\"[contenteditable]\"))return;s.matches(nt)||o.blur()}if(be())return;a=this.option(\"contentClick\")}else s.closest(\".fancybox__carousel\")&&!s.matches(nt)&&(a=this.option(\"backdropClick\"));\"close\"===a?(t.preventDefault(),this.close(t)):\"next\"===a?(t.preventDefault(),this.next()):\"prev\"===a&&(t.preventDefault(),this.prev())}onWheel(t){const e=t.target;let n=this.option(\"wheel\",t);e.closest(\".fancybox__thumbs\")&&(n=\"slide\");const s=\"slide\"===n,o=[-t.deltaX||0,-t.deltaY||0,-t.detail||0].reduce((function(t,e){return Math.abs(e)>Math.abs(t)?e:t})),a=Math.max(-1,Math.min(1,o)),r=Date.now();this.pwt&&r-this.pwt<300?s&&t.preventDefault():(this.pwt=r,this.emit(\"wheel\",t,a),t.defaultPrevented||(\"close\"===n?(t.preventDefault(),this.close(t)):\"slide\"===n&&(i(e)||(t.preventDefault(),this[a>0?\"prev\":\"next\"]()))))}onScroll(){window.scrollTo(Pe,Ce)}onKeydown(t){if(!this.isTopmost())return;this.isCompact||!this.option(\"idle\")||this.isClosing()||this.resetIdle();const e=t.key,i=this.option(\"keyboard\");if(!i)return;const n=t.composedPath()[0],s=document.activeElement&&document.activeElement.classList,o=s&&s.contains(\"f-button\")||n.dataset.carouselPage||n.dataset.carouselIndex;if(\"Escape\"!==e&&!o&&E(n)){if(n.isContentEditable||-1!==[\"TEXTAREA\",\"OPTION\",\"INPUT\",\"SELECT\",\"VIDEO\"].indexOf(n.nodeName))return}if(\"Tab\"===t.key?P(this.container,ae):S(this.container,ae),t.ctrlKey||t.altKey||t.shiftKey)return;this.emit(\"keydown\",e,t);const a=i[e];a&&\"function\"==typeof this[a]&&(t.preventDefault(),this[a]())}onResize(){const t=this.container;if(!t)return;const e=this.isCompact;t.classList.toggle(le,e),this.manageCaption(this.getSlide()),this.isCompact?this.clearIdle():this.endIdle(),this.scale(),this.emit(\"resize\")}onFocus(t){this.isTopmost()&&this.checkFocus(t)}onMousemove(t){this.prevMouseMoveEvent=t,!this.isCompact&&this.option(\"idle\")&&this.resetIdle()}onVisibilityChange(){\"visible\"===document.visibilityState?this.checkFocus():this.endIdle()}manageCloseBtn(t){const e=this.optionFor(t,\"closeButton\")||!1;if(\"auto\"===e){const t=this.plugins.Toolbar;if(t&&t.state===Zt.Ready)return}if(!e)return;if(!t.contentEl||t.closeBtnEl)return;const i=this.option(\"tpl.closeButton\");if(i){const e=n(this.localize(i));t.closeBtnEl=t.contentEl.appendChild(e),t.el&&P(t.el,\"has-close-btn\")}}manageCaption(t=void 0){var e,i;const n=\"fancybox__caption\",s=this.container;if(!s)return;S(s,de);const o=this.isCompact||this.option(\"commonCaption\"),a=!o;if(this.caption&&this.stop(this.caption),a&&this.caption&&(this.caption.remove(),this.caption=null),o&&!this.caption)for(const t of(null===(e=this.carousel)||void 0===e?void 0:e.slides)||[])t.captionEl&&(t.captionEl.remove(),t.captionEl=void 0,S(t.el,de),null===(i=t.el)||void 0===i||i.removeAttribute(\"aria-labelledby\"));if(t||(t=this.getSlide()),!t||o&&!this.isCurrentSlide(t))return;const r=t.el;let l=this.optionFor(t,\"caption\",\"\");if(!l)return void(o&&this.caption&&this.animate(this.caption,\"f-fadeOut\",(()=>{this.caption&&(this.caption.innerHTML=\"\")})));let c=null;if(a){if(c=t.captionEl||null,r&&!c){const e=n+`_${this.id}_${t.index}`;c=document.createElement(\"div\"),P(c,n),c.setAttribute(\"id\",e),t.captionEl=r.appendChild(c),P(r,de),r.setAttribute(\"aria-labelledby\",e)}}else{if(c=this.caption,c||(c=s.querySelector(\".\"+n)),!c){c=document.createElement(\"div\"),c.dataset.fancyboxCaption=\"\",P(c,n);(this.footer||s).prepend(c)}P(s,de),this.caption=c}c&&(c.innerHTML=\"\",ve(l)||\"number\"==typeof l?c.innerHTML=l+\"\":l instanceof HTMLElement&&c.appendChild(l))}checkFocus(t){this.focus(t)}focus(t){var e;if(this.ignoreFocusChange)return;const i=document.activeElement||null,n=(null==t?void 0:t.target)||null,s=this.container,o=null===(e=this.carousel)||void 0===e?void 0:e.viewport;if(!s||!o)return;if(!t&&i&&s.contains(i))return;const a=this.getSlide(),r=a&&a.state===lt.Ready?a.el:null;if(!r||r.contains(i)||s===i)return;t&&t.cancelable&&t.preventDefault(),this.ignoreFocusChange=!0;const l=Array.from(s.querySelectorAll(nt));let c=[],h=null;for(let t of l){const e=!t.offsetParent||!!t.closest('[aria-hidden=\"true\"]'),i=r&&r.contains(t),n=!o.contains(t);if(t===s||(i||n)&&!e){c.push(t);const e=t.dataset.origTabindex;void 0!==e&&e&&(t.tabIndex=parseFloat(e)),t.removeAttribute(\"data-orig-tabindex\"),!t.hasAttribute(\"autoFocus\")&&h||(h=t)}else{const e=void 0===t.dataset.origTabindex?t.getAttribute(\"tabindex\")||\"\":t.dataset.origTabindex;e&&(t.dataset.origTabindex=e),t.tabIndex=-1}}let d=null;t?(!n||c.indexOf(n)<0)&&(d=h||s,c.length&&(i===xe?d=c[0]:this.lastFocus!==s&&i!==we||(d=c[c.length-1]))):d=a&&\"image\"===a.type?s:h||s,d&&st(d),this.lastFocus=document.activeElement,this.ignoreFocusChange=!1}
19next(){const t=this.carousel;t&&t.pages.length>1&&t.slideNext()}prev(){const t=this.carousel;t&&t.pages.length>1&&t.slidePrev()}jumpTo(...t){this.carousel&&this.carousel.slideTo(...t)}isTopmost(){var t;return(null===(t=Oe.getInstance())||void 0===t?void 0:t.id)==this.id}animate(t=null,e=\"\",i){if(!t||!e)return void(i&&i());this.stop(t);const n=s=>{s.target===t&&t.dataset.animationName&&(t.removeEventListener(\"animationend\",n),delete t.dataset.animationName,i&&i(),S(t,e))};t.dataset.animationName=e,t.addEventListener(\"animationend\",n),P(t,e)}stop(t){t&&t.dispatchEvent(new CustomEvent(\"animationend\",{bubbles:!1,cancelable:!0,currentTarget:t}))}setContent(t,e=\"\",i=!0){if(this.isClosing())return;const s=t.el;if(!s)return;let o=null;if(E(e)?o=e:(o=n(e+\"\"),E(o)||(o=document.createElement(\"div\"),o.innerHTML=e+\"\")),[\"img\",\"picture\",\"iframe\",\"video\",\"audio\"].includes(o.nodeName.toLowerCase())){const t=document.createElement(\"div\");t.appendChild(o),o=t}E(o)&&t.filter&&!t.error&&(o=o.querySelector(t.filter)),o&&E(o)?(P(o,\"fancybox__content\"),t.id&&o.setAttribute(\"id\",t.id),s.classList.add(`has-${t.error?\"error\":t.type||\"unknown\"}`),s.prepend(o),\"none\"===o.style.display&&(o.style.display=\"\"),\"none\"===getComputedStyle(o).getPropertyValue(\"display\")&&(o.style.display=t.display||this.option(\"defaultDisplay\")||\"flex\"),t.contentEl=o,i&&this.revealContent(t),this.manageCloseBtn(t),this.manageCaption(t)):this.setError(t,\"{{ELEMENT_NOT_FOUND}}\")}revealContent(t,e){const i=t.el,n=t.contentEl;i&&n&&(this.emit(\"reveal\",t),this.hideLoading(t),t.state=lt.Opening,(e=this.isOpeningSlide(t)?void 0===e?this.optionFor(t,\"showClass\"):e:\"f-fadeIn\")?this.animate(n,e,(()=>{this.done(t)})):this.done(t))}done(t){this.isClosing()||(t.state=lt.Ready,this.emit(\"done\",t),P(t.el,\"is-done\"),this.isCurrentSlide(t)&&this.option(\"autoFocus\")&&queueMicrotask((()=>{var e;null===(e=t.panzoom)||void 0===e||e.updateControls(),this.option(\"autoFocus\")&&this.focus()})),this.isOpeningSlide(t)&&(S(this.container,he),!this.isCompact&&this.option(\"idle\")&&this.setIdle()))}isCurrentSlide(t){const e=this.getSlide();return!(!t||!e)&&e.index===t.index}isOpeningSlide(t){var e,i;return null===(null===(e=this.carousel)||void 0===e?void 0:e.prevPage)&&t&&t.index===(null===(i=this.getSlide())||void 0===i?void 0:i.index)}showLoading(t){t.state=lt.Loading;const e=t.el;if(!e)return;P(e,ce),this.emit(\"loading\",t),t.spinnerEl||setTimeout((()=>{if(!this.isClosing()&&!t.spinnerEl&&t.state===lt.Loading){let i=n(x);P(i,\"fancybox-spinner\"),t.spinnerEl=i,e.prepend(i),this.animate(i,\"f-fadeIn\")}}),250)}hideLoading(t){const e=t.el;if(!e)return;const i=t.spinnerEl;this.isClosing()?null==i||i.remove():(S(e,ce),i&&this.animate(i,\"f-fadeOut\",(()=>{i.remove()}
19)),t.state===lt.Loading&&(this.emit(\"loaded\",t),t.state=lt.Ready))}setError(t,e){if(this.isClosing())return;const i=new Event(\"error\",{bubbles:!0,cancelable:!0});if(this.emit(\"error\",i,t),i.defaultPrevented)return;t.error=e,this.hideLoading(t),this.clearContent(t);const n=document.createElement(\"div\");n.classList.add(\"fancybox-error\"),n.innerHTML=this.localize(e||\"<p>{{ERROR}}</p>\"),this.setContent(t,n)}clearContent(t){if(void 0===t.state)return;this.emit(\"clearContent\",t),t.contentEl&&(t.contentEl.remove(),t.contentEl=void 0);const e=t.el;e&&(S(e,\"has-error\"),S(e,\"has-unknown\"),S(e,`has-${t.type||\"unknown\"}`)),t.closeBtnEl&&t.closeBtnEl.remove(),t.closeBtnEl=void 0,t.captionEl&&t.captionEl.remove(),t.captionEl=void 0,t.spinnerEl&&t.spinnerEl.remove(),t.spinnerEl=void 0}getSlide(){var t;const e=this.carousel;return(null===(t=null==e?void 0:e.pages[null==e?void 0:e.page])||void 0===t?void 0:t.slides[0])||void 0}close(t,e){if(this.isClosing())return;const i=new Event(\"shouldClose\",{bubbles:!0,cancelable:!0});if(this.emit(\"shouldClose\",i,t),i.defaultPrevented)return;t&&t.cancelable&&(t.preventDefault(),t.stopPropagation());const n=()=>{this.proceedClose(t,e)};this.startedFs&&ye&&ye.isFullscreen()?Promise.resolve(ye.exit()).then((()=>n())):n()}clearIdle(){this.idleTimer&&clearTimeout(this.idleTimer),this.idleTimer=null}setIdle(t=!1){const e=()=>{this.clearIdle(),this.idle=!0,P(this.container,\"is-idle\"),this.emit(\"setIdle\")};if(this.clearIdle(),!this.isClosing())if(t)e();else{const t=this.option(\"idle\");t&&(this.idleTimer=setTimeout(e,t))}}endIdle(){this.clearIdle(),this.idle&&!this.isClosing()&&(this.idle=!1,S(this.container,\"is-idle\"),this.emit(\"endIdle\"))}resetIdle(){this.endIdle(),this.setIdle()}toggleIdle(){this.idle?this.endIdle():this.setIdle(!0)}toggleFullscreen(){ye&&(ye.isFullscreen()?ye.exit():ye.request().then((()=>{this.startedFs=!0})))}isClosing(){return[rt.Closing,rt.CustomClosing,rt.Destroy].includes(this.state)}proceedClose(t,e){var i,n;this.state=rt.Closing,this.clearIdle(),this.detachEvents();const s=this.container,o=this.carousel,a=this.getSlide(),r=a&&this.option(\"placeFocusBack\")?a.triggerEl||this.option(\"triggerEl\"):null;if(r&&(tt(r)?st(r):r.focus()),s&&(S(s,he),P(s,\"is-closing\"),s.setAttribute(oe,\"true\"),this.option(\"animated\")&&P(s,re),s.style.pointerEvents=\"none\"),o){o.clearTransitions(),null===(i=o.panzoom)||void 0===i||i.destroy(),null===(n=o.plugins.Navigation)||void 0===n||n.detach();for(const t of o.slides){t.state=lt.Closing,this.hideLoading(t);const e=t.contentEl;e&&this.stop(e);const i=null==t?void 0:t.panzoom;i&&(i.stop(),i.detachEvents(),i.detachObserver()),this.isCurrentSlide(t)||o.emit(\"removeSlide\",t)}}Pe=window.scrollX,Ce=window.scrollY,window.addEventListener(\"scroll\",this.onScroll),this.emit(\"close\",t),this.state!==rt.CustomClosing?(void 0===e&&a&&(e=this.optionFor(a,\"hideClass\")),e&&a?(this.animate(a.contentEl,e,(()=>{o&&o.emit(\"removeSlide\",a)})),setTimeout((()=>{this.destroy()}),500)):this.destroy()):setTimeout((()=>{this.destroy()}),500)}destroy(){var t;if(this.state===rt.Destroy)return;window.removeEventListener(\"scroll\",this.onScroll),this.state=rt.Destroy,null===(t=this.carousel)||void 0===t||t.destroy();const e=this.container;e&&e.remove(),Te.delete(this.id);const i=Oe.getInstance();i?i.focus():(we&&(we.remove(),we=null),xe&&(xe.remove(),xe=null),S(document.documentElement,ee),(()=>{if(!et)return;const t=document,e=t.body;e.classList.remove(ie),e.style.setProperty(se,\"\"),t.documentElement.style.setProperty(ne,\"\")})(),this.emit(\"destroy\"))}static bind(t,e,i){if(!et)return;let n,s=\"\",o={};if(void 0===t?n=document.body:ve(t)?(n=document.body,s=t,\"object\"==typeof e&&(o=e||{})):(n=t,ve(e)&&(s=e),\"object\"==typeof i&&(o=i||{})),!n||!E(n))return;s=s||\"[data-fancybox]\";const a=Oe.openers.get(n)||new Map;a.set(s,o),Oe.openers.set(n,a),1===a.size&&n.addEventListener(\"click\",Oe.fromEvent)}static unbind(t,e){let i,n=\"\";if(ve(t)?(i=document.body,n=t):(i=t,ve(e)&&(n=e)),!i)return;const s=Oe.openers.get(i);s&&n&&s.delete(n),n&&s||(Oe.openers.delete(i),i.removeEventListener(\"click\",Oe.fromEvent))}static destroy(){let t;for(;t=Oe.getInstance();)t.destroy();for(const t of Oe.openers.keys())t.removeEventListener(\"click\",Oe.fromEvent);Oe.openers=new Map}static fromEvent(t){if(t.defaultPrevented)return;if(t.button&&0!==t.button)return;if(t.ctrlKey||t.metaKey||t.shiftKey)return;let e=t.composedPath()[0];const i=e.closest(\"[data-fancybox-trigger]\");if(i){const t=i.dataset.fancyboxTrigger||\"\",n=document.querySelectorAll(`[data-fancybox=\"${t}\"]`),s=parseInt(i.dataset.fancyboxIndex||\"\",10)||0;e=n[s]||e}if(!(e&&e instanceof Element))return;let n,s,o,a;if([...Oe.openers].reverse().find((([t,i])=>!(!t.contains(e)||![...i].reverse().find((([i,r])=>{let l=e.closest(i);return!!l&&(n=t,s=i,o=l,a=r,!0)}))))),!n||!s||!o)return;a=a||{},t.preventDefault(),e=o;let r=[],l=u({},at,a);l.event=t,l.triggerEl=e,l.delegate=i;const c=l.groupAll,h=l.groupAttr,d=h&&e?e.getAttribute(`${h}`):\"\";
vendor: 5,376 bytes, lines 19-30
19if((!e||d||c)&&(r=[].slice.call(n.querySelectorAll(s))),e&&!c&&(r=d?r.filter((t=>t.getAttribute(`${h}`)===d)):[e]),!r.length)return;const p=Oe.getInstance();return p&&p.options.triggerEl&&r.indexOf(p.options.triggerEl)>-1?void 0:(e&&(l.startIndex=r.indexOf(e)),Oe.fromNodes(r,l))}static fromSelector(t,e,i){let n=null,s=\"\",o={};if(ve(t)?(n=document.body,s=t,\"object\"==typeof e&&(o=e||{})):t instanceof HTMLElement&&ve(e)&&(n=t,s=e,\"object\"==typeof i&&(o=i||{})),!n||!s)return!1;const a=Oe.openers.get(n);return!!a&&(o=u({},a.get(s)||{},o),!!o&&Oe.fromNodes(Array.from(n.querySelectorAll(s)),o))}static fromNodes(t,e){e=u({},at,e||{});const i=[];for(const n of t){const t=n.dataset||{},s=t[me]||n.getAttribute(ge)||n.getAttribute(\"currentSrc\")||n.getAttribute(me)||void 0;let o;const a=e.delegate;let r;a&&i.length===e.startIndex&&(o=a instanceof HTMLImageElement?a:a.querySelector(\"img:not([aria-hidden])\")),o||(o=n instanceof HTMLImageElement?n:n.querySelector(\"img:not([aria-hidden])\")),o&&(r=o.currentSrc||o[me]||void 0,!r&&o.dataset&&(r=o.dataset.lazySrc||o.dataset[me]||void 0));const l={src:s,triggerEl:n,thumbEl:o,thumbElSrc:r,thumbSrc:r};for(const e in t){let i=t[e]+\"\";i=\"false\"!==i&&(\"true\"===i||i),l[e]=i}i.push(l)}return new Oe(i,e)}static getInstance(t){if(t)return Te.get(t);return Array.from(Te.values()).reverse().find((t=>!t.isClosing()&&t))||null}static getSlide(){var t;return(null===(t=Oe.getInstance())||void 0===t?void 0:t.getSlide())||null}static show(t=[],e={}){return new Oe(t,e)}static next(){const t=Oe.getInstance();t&&t.next()}static prev(){const t=Oe.getInstance();t&&t.prev()}static close(t=!0,...e){if(t)for(const t of Te.values())t.close(...e);else{const t=Oe.getInstance();t&&t.close(...e)}}}Object.defineProperty(Oe,\"version\",{enumerable:!0,configurable:!0,writable:!0,value:\"5.0.36\"}),Object.defineProperty(Oe,\"defaults\",{enumerable:!0,configurable:!0,writable:!0,value:at}),Object.defineProperty(Oe,\"Plugins\",{enumerable:!0,configurable:!0,writable:!0,value:te}),Object.defineProperty(Oe,\"openers\",{enumerable:!0,configurable:!0,writable:!0,value:new Map});\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/@fancyapps/ui/dist/index.esm.js?\n}"); 20 21/***/ }, 22 23/***/ "./dev/js/Application.js" 24/*!*******************************!*\ 25 !*** ./dev/js/Application.js ***! 26 \*******************************/ 27(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 28 29"use strict"; 30eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _components_actionBar__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./components/actionBar */ \"./dev/js/components/actionBar.js\");\n/* harmony import */ var _components_productComparison__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./components/productComparison */ \"./dev/js/components/productComparison.js\");\n/* harmony import */ var _components_countdown__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./components/countdown */ \"./dev/js/components/countdown.js\");\n/* harmony import */ var _components_countdown__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_components_countdown__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _components_filterNav__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./components/filterNav */ \"./dev/js/components/filterNav.js\");\n/* harmony import */ var _components_filterNav__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_components_filterNav__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var _components_cookieBanner__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./components/cookieBanner */ \"./dev/js/components/cookieBanner.js\");\n/* harmony import */ var _components_cookieBanner__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_components_cookieBanner__WEBPACK_IMPORTED_MODULE_4__);\n/* harmony import */ var _components_discountNotification__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./components/discountNotification */ \"./dev/js/components/discountNotification.js\");\n/* harmony import */ var _components_discountNotification__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_components_discountNotification__WEBPACK_IMPORTED_MODULE_5__);\n/* harmony import */ var _components_plasticCounter__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./components/plasticCounter */ \"./dev/js/components/plasticCounter.js\");\n/* harmony import */ var _components_contentMaxheight__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./components/contentMaxheight */ \"./dev/js/components/contentMaxheight.js\");\n/* harmony import */ var _components_contentMaxheight__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_components_contentMaxheight__WEBPACK_IMPORTED_MODULE_7__);\n/* harmony import */ var _components_bundle__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./components/bundle */ \"./dev/js/components/bundle.js\");\n/* harmony import */ var _components_saleButton__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./components/saleButton */ \"./dev/js/components/saleButton.js\");\n/* harmony import */ var _components_saleButton__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(_components_saleButton__WEBPACK_IMPORTED_MODULE_9__);
30\n/* harmony import */ var _components_addonCheckbox__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./components/addonCheckbox */ \"./dev/js/components/addonCheckbox.js\");\n/* harmony import */ var _components_nudge__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./components/nudge */ \"./dev/js/components/nudge.js\");\n/* harmony import */ var _components_nudge__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(_components_nudge__WEBPACK_IMPORTED_MODULE_11__);\n/* harmony import */ var _components_richText__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./components/richText */ \"./dev/js/components/richText.js\");\n/* harmony import */ var _components_interestCalculator__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./components/interestCalculator */ \"./dev/js/components/interestCalculator.js\");\n/* harmony import */ var _components_interestCalculator__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(_components_interestCalculator__WEBPACK_IMPORTED_MODULE_13__);\n/* harmony import */ var _components_clipboardCode__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./components/clipboardCode */ \"./dev/js/components/clipboardCode.js\");\n/* harmony import */ var _components_clipboardCode__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(_components_clipboardCode__WEBPACK_IMPORTED_MODULE_14__);\n/* harmony import */ var _components_multiOption__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./components/multiOption */ \"./dev/js/components/multiOption.js\");\n/* harmony import */ var _components_multiOption__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(_components_multiOption__WEBPACK_IMPORTED_MODULE_15__);\n/* harmony import */ var _components_locksmithForm__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./components/locksmithForm */ \"./dev/js/components/locksmithForm.js\");\n/* harmony import */ var _components_locksmithForm__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(_components_locksmithForm__WEBPACK_IMPORTED_MODULE_16__);\n/* harmony import */ var _components_quickAtc__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./components/quickAtc */ \"./dev/js/components/quickAtc.js\");\n/* harmony import */ var _components_productTreasure__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./components/productTreasure */ \"./dev/js/components/productTreasure.js\");\n/* harmony import */ var _components_logoSlider__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./components/logoSlider */ \"./dev/js/components/logoSlider.js\");\n/* harmony import */ var _components_productSlider__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./components/productSlider */ \"./dev/js/components/productSlider.js\");\n/* harmony import */ var _components_textScroll__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! ./components/textScroll */ \"./dev/js/components/textScroll.js\");\n/* harmony import */ var _components_animationScrolltext__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ./components/animationScrolltext */ \"./dev/js/components/animationScrolltext.js\");\n/* harmony import */ var _components_animationBottles__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ./components/animationBottles */ \"./dev/js/components/animationBottles.js\");\n/* harmony import */ var _components_animationColleagues__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ./components/animationColleagues */ \"./dev/js/components/animationColleagues.js\");\n/* harmony import */ var _components_animationBoldText__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ./components/animationBoldText */ \"./dev/js/components/animationBoldText.js\");\n/* harmony import */ var _components_animationAccordion__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ./components/animationAccordion */ \"./dev/js/components/animationAccordion.js\");\n/* harmony import */ var _components_animationScrollSection__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ./components/
30animationScrollSection */ \"./dev/js/components/animationScrollSection.js\");\n/* harmony import */ var _components_animationSplitImage__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ./components/animationSplitImage */ \"./dev/js/components/animationSplitImage.js\");\n/* harmony import */ var _components_animationFixedtext__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! ./components/animationFixedtext */ \"./dev/js/components/animationFixedtext.js\");\n/* harmony import */ var _components_animationVideo__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! ./components/animationVideo */ \"./dev/js/components/animationVideo.js\");\n/* harmony import */ var _components_animationLoader__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! ./components/animationLoader */ \"./dev/js/components/animationLoader.js\");\n/* harmony import */ var _components_animationLoader__WEBPACK_IMPORTED_MODULE_31___default = /*#__PURE__*/__webpack_require__.n(_components_animationLoader__WEBPACK_IMPORTED_MODULE_31__);\n/* harmony import */ var _components_animationReveal__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(/*! ./components/animationReveal */ \"./dev/js/components/animationReveal.js\");\n/* harmony import */ var _components_reviewsIoSection__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(/*! ./components/reviewsIoSection */ \"./dev/js/components/reviewsIoSection.js\");\n/* harmony import */ var _components_reviewsIoSection__WEBPACK_IMPORTED_MODULE_33___default = /*#__PURE__*/__webpack_require__.n(_components_reviewsIoSection__WEBPACK_IMPORTED_MODULE_33__);\n/* harmony import */ var _components_searchResults__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(/*! ./components/searchResults */ \"./dev/js/components/searchResults.js\");\n/* harmony import */ var _components_videoSlider__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(/*! ./components/videoSlider */ \"./dev/js/components/videoSlider.js\");\n/* harmony import */ var _components_langModal__WEBPACK_IMPORTED_MODULE_36__ = __webpack_require__(/*! ./components/langModal */ \"./dev/js/components/langModal.js\");\n/* harmony import */ var _components_langModal__WEBPACK_IMPORTED_MODULE_36___default = /*#__PURE__*/__webpack_require__.n(_components_langModal__WEBPACK_IMPORTED_MODULE_36__);\n/* harmony import */ var _components_shopTheLookAnimation__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(/*! ./components/shopTheLookAnimation */ \"./dev/js/components/shopTheLookAnimation.js\");\n/* harmony import */ var _components_horizontalScroll__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(/*! ./components/horizontalScroll */ \"./dev/js/components/horizontalScroll.js\");\n/* harmony import */ var _components_rotatingImage__WEBPACK_IMPORTED_MODULE_39__ = __webpack_require__(/*! ./components/rotatingImage */ \"./dev/js/components/rotatingImage.js\");\n/* harmony import */ var _components_klaviyoBirthday__WEBPACK_IMPORTED_MODULE_40__ = __webpack_require__(/*! ./components/klaviyoBirthday */ \"./dev/js/components/klaviyoBirthday.js\");\n/* harmony import */ var _components_klaviyoBirthday__WEBPACK_IMPORTED_MODULE_40___default = /*#__PURE__*/__webpack_require__.n(_components_klaviyoBirthday__WEBPACK_IMPORTED_MODULE_40__);\n/* harmony import */ var _components_reviewsSlider__WEBPACK_IMPORTED_MODULE_41__ = __webpack_require__(/*! ./components/reviewsSlider */ \"./dev/js/components/reviewsSlider.js\");\n/* harmony import */ var _components_imageSlider__WEBPACK_IMPORTED_MODULE_42__ = __webpack_require__(/*! ./components/imageSlider */ \"./dev/js/components/imageSlider.js\");\n/* harmony import */ var _components_swiperProgress__WEBPACK_IMPORTED_MODULE_43__ = __webpack_require__(/*! ./components/swiperProgress */ \"./dev/js/components/swiperProgress.js\");\n/* harmony import */ var _components_swiperProgress__WEBPACK_IMPORTED_MODULE_43___default = /*#__PURE__*/__webpack_require__.n(_components_swiperProgress__WEBPACK_IMPORTED_MODULE_43__);\n/* harmony import */ var _components_contentSlider__WEBPACK_IMPORTED_MODULE_44__ = __webpack_require__(/*! ./components/contentSlider */ \"./dev/js/components/contentSlider.js\");\n/* harmony import */ var _components_showMoreButton__WEBPACK_IMPORTED_MODULE_45__ = __webpack_require__(/*! ./components/showMoreButton */ \"./dev/js/components/showMoreButton.js\");\n/* harmony import */ var _components_showMoreButton__WEBPACK_IMPORTED_MODULE_45___default = /*#__PURE__*/__webpack_require__.n(_components_showMoreButton__WEBPACK_IMPORTED_MODULE_45__);\n/* harmony import */ var _components_pauseButton__WEBPACK_IMPORTED_MODULE_46__ = __webpack_require__(/*! ./components/pauseButton */ \"./dev/js/components/pauseButton.js\");\n/* harmony import */ var _components_pauseButton__WEBPACK_IMPORTED_MODULE_46___default = /*#__PURE__*/__webpack_require__.n(_components_pauseButton__WEBPACK_IMPORTED_MODULE_46__);\n/* harmony import */ var _components_freeGiftModal__WEBPACK_IMPORTED_MODULE_47__ = __webpack_require__(/*! ./components/freeGiftModal */ \"./dev/js/components/freeGiftModal.js\");\n/* harmony import */ var _components_announcementBar__WEBPACK_IMPORTED_MODULE_48__ = __webpack_require__(/*! ./components/
30announcementBar */ \"./dev/js/components/announcementBar.js\");\n/* harmony import */ var _components_announcementBar__WEBPACK_IMPORTED_MODULE_48___default = /*#__PURE__*/__webpack_require__.n(_components_announcementBar__WEBPACK_IMPORTED_MODULE_48__);\n/* harmony import */ var _components_announcementBarV2__WEBPACK_IMPORTED_MODULE_49__ = __webpack_require__(/*! ./components/announcementBarV2 */ \"./dev/js/components/announcementBarV2.js\");\n/* harmony import */ var _components_announcementBarV2__WEBPACK_IMPORTED_MODULE_49___default = /*#__PURE__*/__webpack_require__.n(_components_announcementBarV2__WEBPACK_IMPORTED_MODULE_49__);\n/* harmony import */ var _components_featuredProductSlider__WEBPACK_IMPORTED_MODULE_50__ = __webpack_require__(/*! ./components/featuredProductSlider */ \"./dev/js/components/featuredProductSlider.js\");\n/* harmony import */ var _components_outlet__WEBPACK_IMPORTED_MODULE_51__ = __webpack_require__(/*! ./components/outlet */ \"./dev/js/components/outlet.js\");\n/* harmony import */ var _components_outlet__WEBPACK_IMPORTED_MODULE_51___default = /*#__PURE__*/__webpack_require__.n(_components_outlet__WEBPACK_IMPORTED_MODULE_51__);\n/* harmony import */ var _components_readMore__WEBPACK_IMPORTED_MODULE_52__ = __webpack_require__(/*! ./components/readMore */ \"./dev/js/components/readMore.js\");\n/* harmony import */ var _components_readMore__WEBPACK_IMPORTED_MODULE_52___default = /*#__PURE__*/__webpack_require__.n(_components_readMore__WEBPACK_IMPORTED_MODULE_52__);\n/* harmony import */ var _components_recommendedProducts__WEBPACK_IMPORTED_MODULE_53__ = __webpack_require__(/*! ./components/recommendedProducts */ \"./dev/js/components/recommendedProducts.js\");\n/* harmony import */ var _components_swatch__WEBPACK_IMPORTED_MODULE_54__ = __webpack_require__(/*! ./components/swatch */ \"./dev/js/components/swatch.js\");\n/* harmony import */ var _components_swatch__WEBPACK_IMPORTED_MODULE_54___default = /*#__PURE__*/__webpack_require__.n(_components_swatch__WEBPACK_IMPORTED_MODULE_54__);\n/* harmony import */ var _components_saleHeaderBanner__WEBPACK_IMPORTED_MODULE_55__ = __webpack_require__(/*! ./components/saleHeaderBanner */ \"./dev/js/components/saleHeaderBanner.js\");\n/* harmony import */ var _components_giftCard__WEBPACK_IMPORTED_MODULE_56__ = __webpack_require__(/*! ./components/giftCard */ \"./dev/js/components/giftCard.js\");\n/* harmony import */ var _components_productCardSlider__WEBPACK_IMPORTED_MODULE_57__ = __webpack_require__(/*! ./components/productCardSlider */ \"./dev/js/components/productCardSlider.js\");\n/* harmony import */ var _components_videoBanner__WEBPACK_IMPORTED_MODULE_58__ = __webpack_require__(/*! ./components/videoBanner */ \"./dev/js/components/videoBanner.js\");\n/* harmony import */ var _components_videoBanner__WEBPACK_IMPORTED_MODULE_58___default = /*#__PURE__*/__webpack_require__.n(_components_videoBanner__WEBPACK_IMPORTED_MODULE_58__);\n/* harmony import */ var _components_productVariantSlider__WEBPACK_IMPORTED_MODULE_59__ = __webpack_require__(/*! ./components/productVariantSlider */ \"./dev/js/components/productVariantSlider.js\");\n/* harmony import */ var _components_addToCart__WEBPACK_IMPORTED_MODULE_60__ = __webpack_require__(/*! ./components/addToCart */ \"./dev/js/components/addToCart.js\");\n/* harmony import */ var _components_return__WEBPACK_IMPORTED_MODULE_61__ = __webpack_require__(/*! ./components/return */ \"./dev/js/components/return.js\");\n/* harmony import */ var _components_return__WEBPACK_IMPORTED_MODULE_61___default = /*#__PURE__*/__webpack_require__.n(_components_return__WEBPACK_IMPORTED_MODULE_61__);\n/* harmony import */ var _components_revocation__WEBPACK_IMPORTED_MODULE_62__ = __webpack_require__(/*! ./components/revocation */ \"./dev/js/components/revocation.js\");\n/* harmony import */ var _components_revocation__WEBPACK_IMPORTED_MODULE_62___default = /*#__PURE__*/__webpack_require__.n(_components_revocation__WEBPACK_IMPORTED_MODULE_62__);\n/* harmony import */ var _components_address_change__WEBPACK_IMPORTED_MODULE_63__ = __webpack_require__(/*! ./components/
30address-change */ \"./dev/js/components/address-change.js\");\n/* harmony import */ var _components_address_change__WEBPACK_IMPORTED_MODULE_63___default = /*#__PURE__*/__webpack_require__.n(_components_address_change__WEBPACK_IMPORTED_MODULE_63__);\n/* harmony import */ var _components_collection_collection__WEBPACK_IMPORTED_MODULE_64__ = __webpack_require__(/*! ./components/collection/collection */ \"./dev/js/components/collection/collection.js\");\n/* harmony import */ var _components_collection_collection__WEBPACK_IMPORTED_MODULE_64___default = /*#__PURE__*/__webpack_require__.n(_components_collection_collection__WEBPACK_IMPORTED_MODULE_64__);\n/* harmony import */ var _components_collection_bubbles__WEBPACK_IMPORTED_MODULE_65__ = __webpack_require__(/*! ./components/collection/bubbles */ \"./dev/js/components/collection/bubbles.js\");\n/* harmony import */ var _components_collection_tiles__WEBPACK_IMPORTED_MODULE_66__ = __webpack_require__(/*! ./components/collection/tiles */ \"./dev/js/components/collection/tiles.js\");\n/* harmony import */ var _components_collection_sort__WEBPACK_IMPORTED_MODULE_67__ = __webpack_require__(/*! ./components/collection/sort */ \"./dev/js/components/collection/sort.js\");\n/* harmony import */ var _components_collection_sort__WEBPACK_IMPORTED_MODULE_67___default = /*#__PURE__*/__webpack_require__.n(_components_collection_sort__WEBPACK_IMPORTED_MODULE_67__);\n/* harmony import */ var _components_product_page__WEBPACK_IMPORTED_MODULE_68__ = __webpack_require__(/*! ./components/product/page */ \"./dev/js/components/product/page.js\");\n/* harmony import */ var _components_product_images__WEBPACK_IMPORTED_MODULE_69__ = __webpack_require__(/*! ./components/product/images */ \"./dev/js/components/product/images.js\");\n/* harmony import */ var _components_product_giftCardOptions__WEBPACK_IMPORTED_MODULE_70__ = __webpack_require__(/*! ./components/product/giftCardOptions */ \"./dev/js/components/product/giftCardOptions.js\");\n/* harmony import */ var _components_productAddons__WEBPACK_IMPORTED_MODULE_71__ = __webpack_require__(/*! ./components/productAddons */ \"./dev/js/components/productAddons.js\");\n/* harmony import */ var _functions_variantSwitch__WEBPACK_IMPORTED_MODULE_72__ = __webpack_require__(/*! ./functions/variantSwitch */ \"./dev/js/functions/variantSwitch.js\");\n/* harmony import */ var _functions_variantSwitch__WEBPACK_IMPORTED_MODULE_72___default = /*#__PURE__*/__webpack_require__.n(_functions_variantSwitch__WEBPACK_IMPORTED_MODULE_72__);\n/* harmony import */ var _functions_cartNotification__WEBPACK_IMPORTED_MODULE_73__ = __webpack_require__(/*! ./functions/cartNotification */ \"./dev/js/functions/cartNotification.js\");\n/* harmony import */ var _functions_cartNotification__WEBPACK_IMPORTED_MODULE_73___default = /*#__PURE__*/__webpack_require__.n(_functions_cartNotification__WEBPACK_IMPORTED_MODULE_73__);\n/* harmony import */ var _functions_variantAdded__WEBPACK_IMPORTED_MODULE_74__ = __webpack_require__(/*! ./functions/variantAdded */ \"./dev/js/functions/variantAdded.js\");\n/* harmony import */ var _functions_cartUpdated__WEBPACK_IMPORTED_MODULE_75__ = __webpack_require__(/*! ./functions/cart
30Updated */ \"./dev/js/functions/cartUpdated.js\");\n/* harmony import */ var _functions_productTabSwitch__WEBPACK_IMPORTED_MODULE_76__ = __webpack_require__(/*! ./functions/productTabSwitch */ \"./dev/js/functions/productTabSwitch.js\");\n/* harmony import */ var _functions_productTabSwitch__WEBPACK_IMPORTED_MODULE_76___default = /*#__PURE__*/__webpack_require__.n(_functions_productTabSwitch__WEBPACK_IMPORTED_MODULE_76__);\n/* harmony import */ var _functions_reShadeButton__WEBPACK_IMPORTED_MODULE_77__ = __webpack_require__(/*! ./functions/reShadeButton */ \"./dev/js/functions/reShadeButton.js\");\n/* harmony import */ var _functions_reShadeButton__WEBPACK_IMPORTED_MODULE_77___default = /*#__PURE__*/__webpack_require__.n(_functions_reShadeButton__WEBPACK_IMPORTED_MODULE_77__);\n/* harmony import */ var _functions_influenceIO__WEBPACK_IMPORTED_MODULE_78__ = __webpack_require__(/*! ./functions/influenceIO */ \"./dev/js/functions/influenceIO.js\");\n/* harmony import */ var _functions_influenceIO__WEBPACK_IMPORTED_MODULE_78___default = /*#__PURE__*/__webpack_require__.n(_functions_influenceIO__WEBPACK_IMPORTED_MODULE_78__);\n/* harmony import */ var _functions_predictiveSearchButton__WEBPACK_IMPORTED_MODULE_79__ = __webpack_require__(/*! ./functions/predictiveSearchButton */ \"./dev/js/functions/predictiveSearchButton.js\");\n/* harmony import */ var _functions_predictiveSearchButton__WEBPACK_IMPORTED_MODULE_79___default = /*#__PURE__*/__webpack_require__.n(_functions_predictiveSearchButton__WEBPACK_IMPORTED_MODULE_79__);\n/* harmony import */ var _functions_chatbotCta__WEBPACK_IMPORTED_MODULE_80__ = __webpack_require__(/*! ./functions/chatbotCta */ \"./dev/js/functions/chatbotCta.js\");\n/* harmony import */ var _functions_chatbotCta__WEBPACK_IMPORTED_MODULE_80___default = /*#__PURE__*/__webpack_require__.n(_functions_chatbotCta__WEBPACK_IMPORTED_MODULE_80__);\n/* harmony import */ var _functions_jdgmCarousel__WEBPACK_IMPORTED_MODULE_81__ = __webpack_require__(/*! ./functions/jdgmCarousel */ \"./dev/js/functions/jdgmCarousel.js\");\n/* harmony import */ var _functions_jdgmCarousel__WEBPACK_IMPORTED_MODULE_81___default = /*#__PURE__*/__webpack_require__.n(_functions_jdgmCarousel__WEBPACK_IMPORTED_MODULE_81__);\n/* harmony import */ var _functions_bundleUpdate__WEBPACK_IMPORTED_MODULE_82__ = __webpack_require__(/*! ./functions/bundleUpdate */ \"./dev/js/functions/bundleUpdate.js\");\n/* harmony import */ var _functions_freeGiftUpdate__WEBPACK_IMPORTED_MODULE_83__ = __webpack_require__(/*! ./functions/freeGiftUpdate */ \"./dev/js/functions/freeGiftUpdate.js\");\n/* harmony import */ var _functions_checkOverflow__WEBPACK_IMPORTED_MODULE_84__ = __webpack_require__(/*! ./functions/checkOverflow */ \"./dev/js/functions/checkOverflow.js\");\n/* harmony import */ var _functions_checkOverflow__WEBPACK_IMPORTED_MODULE_84___default = /*#__PURE__*/__webpack_require__.n(_functions_checkOverflow__WEBPACK_IMPORTED_MODULE_84__);\n/* harmony import */ var _functions_coralGardenersUpdate__WEBPACK_IMPORTED_MODULE_85__ = __webpack_require__(/*! ./functions/coralGardenersUpdate */ \"./dev/js/functions/coralGardenersUpdate.js\");\n/* harmony import */ var _functions_openCartFromUrl__WEBPACK_IMPORTED_MODULE_86__ = __webpack_require__(/*! ./functions/openCartFromUrl */ \"./dev/js/functions/openCartFromUrl.js\");\n/* harmony import */ var _functions_openCartFromUrl__WEBPACK_IMPORTED_MODULE_86___default = /*#__PURE__*/__webpack_require__.n(_functions_openCartFromUrl__WEBPACK_IMPORTED_MODULE_86__);\n/* harmony import */ var _lib_fancybox__WEBPACK_IMPORTED_MODULE_87__ = __webpack_require__(/*! ./lib/fancybox */ \"./dev/js/lib/fancybox.js\");\n/* harmony import */ var _components_atomic_tabs__WEBPACK_IMPORTED_MODULE_88__ = __webpack_require__(/*! ./components/atomic/tabs */ \"./dev/js/components/atomic/tabs.js\");\n/* harmony import */ var _components_atomic_tabs__WEBPACK_IMPORTED_MODULE_88___default = /*#__PURE__*/__webpack_require__.n(_components_atomic_tabs__WEBPACK_IMPORTED_MODULE_88__);\n/* harmony import */ var _components_atomic_dropdown__WEBPACK_IMPORTED_MODULE_89__ = __webpack_require__(/*! ./components/
30atomic/dropdown */ \"./dev/js/components/atomic/dropdown.js\");\n/* harmony import */ var _components_atomic_dropdown__WEBPACK_IMPORTED_MODULE_89___default = /*#__PURE__*/__webpack_require__.n(_components_atomic_dropdown__WEBPACK_IMPORTED_MODULE_89__);\n/* harmony import */ var _ablyft_345__WEBPACK_IMPORTED_MODULE_90__ = __webpack_require__(/*! ./ablyft/345 */ \"./dev/js/ablyft/345.js\");\n/* harmony import */ var _ablyft_345__WEBPACK_IMPORTED_MODULE_90___default = /*#__PURE__*/__webpack_require__.n(_ablyft_345__WEBPACK_IMPORTED_MODULE_90__);\n/* harmony import */ var _components_navbar__WEBPACK_IMPORTED_MODULE_91__ = __webpack_require__(/*! ./components/navbar */ \"./dev/js/components/navbar.js\");\n/* harmony import */ var _components_navbar__WEBPACK_IMPORTED_MODULE_91___default = /*#__PURE__*/__webpack_require__.n(_components_navbar__WEBPACK_IMPORTED_MODULE_91__);\n/* harmony import */ var _components_subnavDesktop__WEBPACK_IMPORTED_MODULE_92__ = __webpack_require__(/*! ./components/subnavDesktop */ \"./dev/js/components/subnavDesktop.js\");\n/* harmony import */ var _components_subnavDesktop__WEBPACK_IMPORTED_MODULE_92___default = /*#__PURE__*/__webpack_require__.n(_components_subnavDesktop__WEBPACK_IMPORTED_MODULE_92__);\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n//import './atomic/stickyProduct'\n//import './atomic/klaviyoContainer'\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n//COLLECTION\n\n\n\n\n\n//PRODUCT PAGE\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n//import './functions/klaviyoDropForm'\n\n\n\n//ATOMIC\n\n\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/Application.js?\n}"); 31 32/***/ }, 33 34/***/ "./dev/js/ablyft/345.js" 35/*!******************************!*\ 36 !*** ./dev/js/ablyft/345.js ***! 37 \******************************/ 38() { 39 40eval("{document.addEventListener('cart:updated', function (event) {\n if (document.querySelector('body.test-060')) {\n document.getElementById('mini-cart').open = true;\n }\n});\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/ablyft/345.js?\n}"); 41 42/***/ }, 43 44/***/ "./dev/js/app.js" 45/*!***********************!*\ 46 !*** ./dev/js/app.js ***! 47 \***********************/ 48(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 49 50"use strict"; 51eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _scss_app_scss__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../scss/app.scss */ \"./dev/scss/app.scss\");\n/* harmony import */ var _Application__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Application */ \"./dev/js/Application.js\");\n\n\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/app.js?\n}"); 52 53/***/ }, 54 55/***/ "./dev/js/components/actionBar.js" 56/*!****************************************!*\ 57 !*** ./dev/js/components/actionBar.js ***! 58 \****************************************/ 59(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 60 61"use strict"; 62eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_isShopifyThemeEditor__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/isShopifyThemeEditor */ \"./dev/js/helper/isShopifyThemeEditor.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
62\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\nvar ActionBarComponent = /*#__PURE__*/function (_HTMLElement) {\n function ActionBarComponent() {\n _classCallCheck(this, ActionBarComponent);\n return _callSuper(this, ActionBarComponent);\n }\n _inherits(ActionBarComponent, _HTMLElement);\n return _createClass(ActionBarComponent, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n // RELOAD REMOVED: \n // We no longer set timeouts to refresh the page here.\n var endTsStr = this.getAttribute('data-end-ts');\n if (!endTsStr) return;\n var endTs = Number(endTsStr);\n if (Number.isNaN(endTs)) return;\n var nowTs = Math.floor(Date.now() / 1000);\n if (endTs <= nowTs) {\n this.renderZeroState();\n }\n }\n }, {\n key: \"renderZeroState\",\n value: function renderZeroState() {\n // If the count-down component doesn't handle the zero state itself,\n // this helper ensures the text is overwritten.\n var countdownEl = this.querySelector('count-down');\n if (countdownEl) {\n var format = countdownEl.getAttribute('data-format');\n countdownEl.innerHTML = format.includes('%d') ? \"00:00:00:00\" : \"00:00:00\";\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('action-bar-component', ActionBarComponent);\n\n// RELOAD REMOVED: \n// Global listener for next block start stripped of window.location.reload()\ndocument.addEventListener('DOMContentLoaded', function () {\n var nextEl = document.getElementById('action-bar-next');\n if (!nextEl) return;\n});
62\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/actionBar.js?\n}"); 63 64/***/ }, 65 66/***/ "./dev/js/components/addToCart.js" 67/*!****************************************!*\ 68 !*** ./dev/js/components/addToCart.js ***! 69 \****************************************/ 70(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 71 72"use strict"; 73eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_addProduct__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/addProduct */ \"./dev/js/helper/addProduct.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread(); }\nfunction _nonIterableSpread() { throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _iterableToArray(r) { if (\"undefined\" != typeof Symbol && null != r[Symbol.iterator] || null != r[\"@@iterator\"]) return Array.from(r); }\nfunction _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(r); }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\");
73 t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\nvar AddToCart = /*#__PURE__*/function (_HTMLElement) {\n function AddToCart() {\n _classCallCheck(this, AddToCart);\n return _callSuper(this, AddToCart);\n }\n _inherits(AddToCart, _HTMLElement);\n return _createClass(AddToCart, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this = this;\n this.addEventListener('click', function (e) {\n return _this.handleClick(e);\n });\n document.addEventListener('change', function (e) {\n var _e$target$classList;\n if ((_e$target$classList = e.target.classList) !== null && _e$target$classList !== void 0 && _e$target$classList.contains('product-addon-checkbox')) {\n _this.updateLabel();\n }\n });\n this.updateLabel();\n }\n }, {\n key: \"getAddonsComponent\",\n value: function getAddonsComponent() {\n var _this$closest;\n return (_this$closest = this.closest('product-page-component')) === null || _this$closest === void 0 ? void 0 : _this$closest.querySelector('product-addons-component:not([hidden])');\n }\n }, {\n key: \"updateLabel\",\n value: function updateLabel() {\n var addonsComponent = this.getAddonsComponent();\n var selectedCount = addonsComponent && typeof addonsComponent.getSelectedItems === 'function' ? addonsComponent.getSelectedItems().length : 0;\n this.classList.toggle('has-addon-selected', selectedCount === 1);\n this.classList.toggle('has-multiple-addons-selected', selectedCount > 1);\n }\n }, {\n key: \"handleClick\",\n value: function handleClick(e) {\n var _this2 = this;\n e.preventDefault();\n if (this.classList.contains('success') || this.hasAttribute('disabled')) return;\n var currentVariantId = parseInt(this.getAttribute('variant-id'), 10);\n var gift = this.getAttribute('data-target-free_gift') || '';\n var timestamp = Date.now();\n var items = [_objectSpread({\n id: currentVariantId,\n quantity: 1\n }, gift && {\n properties: {\n _gift_added_at: timestamp\n }\n })];\n var addonsComponent = this.getAddonsComponent();\n if (addonsComponent && typeof addonsComponent.getSelectedItems === 'function') {\n items.push.apply(items, _toConsumableArray(addonsComponent.getSelectedItems()));\n }\n var mainPayload = {\n items: items\n };\n (0,_helper_addProduct__WEBPACK_IMPORTED_MODULE_0__.addProduct)(mainPayload, false, false).then(function () {\n _this2.classList.add('success');\n setTimeout(function () {\n return _this2.classList.remove('success');\n }, 3000);\n if (addonsComponent && typeof addonsComponent.uncheckAll === 'function') {\n addonsComponent.uncheckAll();\n }\n _this2.updateLabel();\n if (gift) {\n (0,_helper_addProduct__WEBPACK_IMPORTED_MODULE_0__.addProduct)({\n items: [{\n id: gift,\n quantity: 1,\n properties: {\n _free_gift: 'true',\n _gift_added_at: timestamp\n }\n }]\n }, true, false, true)[\"catch\"](function (err) {\n return console.warn('Gift could not be added:', err);\n });\n }\n })[\"catch\"](function (error) {\n console.error('Error:', error);\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"add-to-cart\", AddToCart);
73\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/addToCart.js?\n}"); 74 75/***/ }, 76 77/***/ "./dev/js/components/addonCheckbox.js" 78/*!********************************************!*\ 79 !*** ./dev/js/components/addonCheckbox.js ***! 80 \********************************************/ 81(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 82 83"use strict"; 84eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_addProduct__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/addProduct */ \"./dev/js/helper/addProduct.js\");\n/* harmony import */ var _helper_removeProduct__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../helper/removeProduct */ \"./dev/js/helper/removeProduct.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\nvar AddonCheckbox = /*#__PURE__*/function (_HTMLElement) {\n function AddonCheckbox() {\n var _this;\n _classCallCheck(this, AddonCheckbox);\n _this = _callSuper(this, AddonCheckbox);\n _this.container = _this.querySelector('.checkbox-container');\n _this.input = _this.querySelector('input[type=\"checkbox\"]');\n\n // Initialize the component\n _this.init();\n return _this;\n }\n _inherits(AddonCheckbox, _HTMLElement);\n return _createClass(AddonCheckbox, [{\n key: \"init\",\n value: function init(
84) {\n var _this2 = this;\n if (this.input && this.container) {\n this.input.addEventListener('change', function () {\n return _this2.handleCheckboxChange();\n });\n }\n }\n }, {\n key: \"handleCheckboxChange\",\n value: function handleCheckboxChange() {\n var productId = this.input.getAttribute('data-addon');\n\n // Toggle the active class\n if (this.input.checked) {\n this.input.classList.add('active');\n this.addProductToCart(productId);\n } else {\n this.input.classList.remove('active');\n this.removeProductFromCart(productId);\n }\n }\n }, {\n key: \"addProductToCart\",\n value: function addProductToCart(productId) {\n // Construct the data object for adding the product\n var data = {\n id: productId,\n quantity: 1\n };\n\n // Call the addProduct function (assuming it's defined globally)\n (0,_helper_addProduct__WEBPACK_IMPORTED_MODULE_0__.addProduct)(data, false, false);\n }\n }, {\n key: \"removeProductFromCart\",\n value: function removeProductFromCart(productId) {\n // Construct the data object for removing the product\n var data = {\n id: productId,\n quantity: 0\n };\n (0,_helper_removeProduct__WEBPACK_IMPORTED_MODULE_1__.removeProduct)(data);\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"addon-checkbox\", AddonCheckbox);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/addonCheckbox.js?\n}"); 85 86/***/ }, 87 88/***/ "./dev/js/components/address-change.js" 89/*!*********************************************!*\ 90 !*** ./dev/js/components/address-change.js ***! 91 \*********************************************/ 92() { 93 94eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
94 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
94 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar AddressChangeComponent = /*#__PURE__*/function (_HTMLElement) {\n function AddressChangeComponent() {\n var _this;\n _classCallCheck(this, AddressChangeComponent);\n _this = _callSuper(this, AddressChangeComponent);\n _this.formState = _this.querySelector('.state--form');\n _this.addressState = _this.querySelector('.state--address');\n _this.shippedState = _this.querySelector('.state--shipped');\n _this.errorState = _this.querySelector('.state--error');\n _this.successState = _this.querySelector('.state--success');\n _this.orderInput = _this.querySelector('.order-input');\n _this.emailInput = _this.querySelector('.email-input');\n _this.submitBtn = _this.querySelector('.submit-btn');\n _this.addressSubmitBtn = _this.querySelector('.address-submit-btn');\n _this.resetBtns = _this.querySelectorAll('.reset-btn');\n _this.countryInput = _this.querySelector('.country-input');\n _this.firstNameInput = _this.querySelector('.first-name-input');\n _this.lastNameInput = _this.querySelector('.last-name-input');\n _this.companyInput = _this.querySelector('.company-input');\n _this.address1Input = _this.querySelector('.address1-input');\n _this.address2Input = _this.querySelector('.address2-input');\n _this.zipInput = _this.querySelector('.zip-input');\n _this.cityInput = _this.querySelector('.city-input');\n _this.provinceInput = _this.querySelector('.province-input');\n _this.phoneInput = _this.querySelector('.phone-input');\n _this.orderId = null;\n return _this;\n }\n _inherits(AddressChangeComponent, _HTMLElement);\n return _createClass(AddressChangeComponent, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n if (this.submitBtn) {\n this.submitBtn.addEventListener('click', function () {\n return _this2.checkOrder();\n });\n }\n if (this.addressSubmitBtn) {\n this.addressSubmitBtn.addEventListener('click', function () {\n return _this2.submitAddress();\n });\n }\n this.resetBtns.forEach(function (btn) {\n btn.addEventListener('click', function () {\n return _this2.reset();\n });\n });\n [this.orderInput, this.emailInput].forEach(function (input) {\n if (input) input.addEventListener('keypress', function (e) {\n if (e.key === 'Enter') _this2.checkOrder();\n });\n });\n }\n }, {\n key: \"hideAllStates\",\n value: function hideAllStates() {\n [this.formState, this.addressState, this.shippedState, this.errorState, this.successState].forEach(function (s) {\n if (s) s.hidden = true;\n });\n }\n }, {\n key: \"reset\",\n value: function reset() {\n this.hideAllStates();\n if (this.formState) this.formState.hidden = false;\n if (this.orderInput) this.orderInput.value = '';\n if (this.emailInput) this.emailInput.value = '';\n this.orderId = null;\n }\n }, {\n key: \"checkOrder\",\n value: function () {\n var _checkOrder = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var order, email, originalText, response, data, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n order = this.orderInput.value.trim();\n email = this.emailInput.value.trim();\n if (!(!order || !email)) {\n _context.n = 1;\n break;\n }\n alert(this.submitBtn.dataset.errorText || 'Bitte fülle alle Felder aus.');\n return _context.a(2);\n case 1:\n originalText = this.submitBtn.textContent;\n this.submitBtn.disabled = true;\n this.submitBtn.textContent = this.submitBtn.dataset.loadingText || 'Wird geprüft...';\n _context.p = 2;\n _context.n = 3;\n return fetch('https://gotbag.app.n8n.cloud/webhook/3720c604-2cf6-4030-b9a8-8c03582715de', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n orderName: order,\n email: email\n })\n });\n case 3:\n response = _context.v;\n _context.n = 4;\n return response.json();\n case 4:\n data = _context.v;\n this.hideAllStates();\n if (data.status === 'error' && data.code === 'already_shipped') {\n if (this.shippedState) this.shippedState.hidden = false;\n } else if (data.status === 'error' && data.code === 'not_found') {\n if (this.errorState) this.errorState.hidden = false;\n } else if (response.status === 200 && data.address) {\n this.orderId = data.address.id;\n this.prefillAddress(data.address);\n if (this.addressState) this.addressState.hidden = false;\n } else {\n if (this.errorState) this.errorState.hidden = false;\n }\n _context.n = 6;\n break;\n case 5:\n _context.p = 5;\n _t = _context.v;\n console.error('Fetch error:', _t);\n this.hideAllStates();\n if (this.errorState) this.errorState.hidden = false;\n case 6:\n _context.p = 6;\n this.submitBtn.disabled = false;\n this.submitBtn.textContent = originalText;\n return _context.f(6);\n case 7:\n return _context.a(2);\n }\n }, _callee, this, [[2, 5, 6, 7]]);\n }));\n function checkOrder() {\n return _checkOrder.apply(this, arguments);\n }\n return checkOrder;\n }()\n }, {\n key: \"prefillAddress\",\n value: function prefillAddress(address) {\n if (this.countryInput) this.countryInput.value = address.country || '';\n if (this.firstNameInput) this.firstNameInput.value = address.first_name || '';\n if (this.lastNameInput) this.lastNameInput.value = address.last_name || '';\n if (this.address1Input) this.address1Input.value = address.address1 || '';\n if (this.zipInput) this.zipInput.value = address.zip || '';\n if (this.cityInput) this.cityInput.value = address.city || '';\n if (this.provinceInput) this.provinceInput.value = address.province || '';\n }\n }, {\n key: \"submitAddress\",\n value: function () {\n var _submitAddress = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee2() {\n var order, email, firstName, lastName, address1, zip, city, originalText, response, data, _t2;\n return _regenerator().w(function (_context2) {\n while (1) switch (_context2.p = _context2.n) {\n case 0:\n order = this.orderInput.value.trim();\n email = this.emailInput.value.trim();\n firstName = this.firstNameInput.value.trim();\n lastName = this.lastNameInput.value.trim();\n address1 = this.address1Input.value.trim();\n zip = this.zipInput.value.trim();\n city = this.cityInput.value.trim();\n if (!(!firstName || !lastName || !address1 || !zip || !city)) {\n _context2.n = 1;\n break;\n }\n alert(this.addressSubmitBtn.dataset.errorText || 'Bitte fülle alle Pflichtfelder aus.');\n return _context2.a(2);\n case 1:\n originalText = this.addressSubmitBtn.textContent;\n this.addressSubmitBtn.disabled = true;\n this.addressSubmitBtn.textContent = this.addressSubmitBtn.dataset.loadingText || 'Wird gespeichert...';\n _context2.p = 2;\n _context2.n = 3;\n return fetch('https://gotbag.app.n8n.cloud/webhook/d1d23f47-8d33-4974-947c-5ba3d7f4bac9', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n orderName: order,\n email: email,\n orderId: this.orderId,\n first_name: firstName,\n last_name: lastName,\n company: this.companyInput ? this.companyInput.value.trim() : '',\n address1: address1,\n address2: this.address2Input ? this.address2Input.value.trim() : '',\n zip: zip,\n city: city,\n province: this.provinceInput ? this.provinceInput.value.trim() : '',\n phone: this.phoneInput ? this.phoneInput.value.trim() : ''\n })\n });\n case 3:\n response = _context2.v;
94\n _context2.n = 4;\n return response.json();\n case 4:\n data = _context2.v;\n this.hideAllStates();\n if (response.status === 200 && data.status !== 'error') {\n if (this.successState) this.successState.hidden = false;\n } else {\n if (this.errorState) this.errorState.hidden = false;\n }\n _context2.n = 6;\n break;\n case 5:\n _context2.p = 5;\n _t2 = _context2.v;\n console.error('Fetch error:', _t2);\n this.hideAllStates();\n if (this.errorState) this.errorState.hidden = false;\n case 6:\n _context2.p = 6;\n this.addressSubmitBtn.disabled = false;\n this.addressSubmitBtn.textContent = originalText;\n return _context2.f(6);\n case 7:\n return _context2.a(2);\n }\n }, _callee2, this, [[2, 5, 6, 7]]);\n }));\n function submitAddress() {\n return _submitAddress.apply(this, arguments);\n }\n return submitAddress;\n }()\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nif (!customElements.get('address-change-component')) {\n customElements.define('address-change-component', AddressChangeComponent);\n}\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/address-change.js?\n}"); 95 96/***/ }, 97 98/***/ "./dev/js/components/animationAccordion.js" 99/*!*************************************************!*\ 100 !*** ./dev/js/components/animationAccordion.js ***! 101 \*************************************************/ 102(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 103 104"use strict"; 105eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\");
105 t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\n\n// Register GSAP ScrollTrigger plugin\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar AnimationAccordion = /*#__PURE__*/function (_HTMLElement) {\n function AnimationAccordion() {\n var _this;\n _classCallCheck(this, AnimationAccordion);\n _this = _callSuper(this, AnimationAccordion);\n _this.items = Array.from(_this.querySelectorAll('.stack')); // Collect all stack sections\n _this.wrapper = _this.querySelector('.wrapper');\n return _this;\n }\n _inherits(AnimationAccordion, _HTMLElement);\n return _createClass(AnimationAccordion, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initAnimation();\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n var _this2 = this;\n var top = 0;\n this.items.forEach(function (section, index) {\n var height = section.querySelector('.heading').getBoundingClientRect().height;\n gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.create({\n trigger: section,\n start: \"top top+=\".concat(top),\n pin: true,\n pinSpacing: false,\n scrub: true,\n endTrigger: _this2.wrapper,\n end: \"bottom bottom\"\n });\n top = top + height + 15;\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement)); // Define the custom element\nwindow.customElements.define(\"animation-accordion\", AnimationAccordion);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationAccordion.js?\n}"); 106 107/***/ }, 108 109/***/ "./dev/js/components/animationBoldText.js" 110/*!************************************************!*\ 111 !*** ./dev/js/components/animationBoldText.js ***! 112 \************************************************/ 113(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 114 115"use strict"; 116eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
116\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar AnimationBoldText = /*#__PURE__*/function (_HTMLElement) {\n function AnimationBoldText() {\n var _this;\n _classCallCheck(this, AnimationBoldText);\n _this = _callSuper(this, AnimationBoldText);\n _this.textElements = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.utils.toArray('.text');\n return _this;\n }\n _inherits(AnimationBoldText, _HTMLElement);\n return _createClass(AnimationBoldText, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initAnimation();\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n this.textElements.forEach(function (text) {\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(text, {\n backgroundSize: '100%',\n ease: 'none',\n scrollTrigger: {\n trigger: text,\n start: 'center 80%',\n end: 'center 20%',\n scrub: true\n }\n });\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"animation-bold-text\", AnimationBoldText);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationBoldText.js?\n}"); 117 118/***/ }, 119 120/***/ "./dev/js/components/animationBottles.js" 121/*!***********************************************!*\
122 !*** ./dev/js/components/animationBottles.js ***! 123 \***********************************************/ 124(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 125 126"use strict"; 127eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar AnimationBottles = /*#__PURE__*/function (_HTMLElement) {\n function AnimationBottles() {\n var _this;\n _classCallCheck(this, AnimationBottles);\n _this = _callSuper(this, AnimationBottles);\n _this.img = _this.querySelectorAll('img:not(.background-image)');\n _this.content1 = _this.querySelector('.content:first-of-type');\n _this.content2 = _this.querySelector('.content:last-of-type');\n _this.target = document.querySelector(\".target\");\n _this.section = document.querySelector('.animation-bottles');\n return _this;\n }\n _inherits(AnimationBottles, _HTMLElement);\n return _createClass(AnimationBottles, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initAnimation();\n this.initBottleClick();
127\n this.initCursor();\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n var _this2 = this;\n this.img.forEach(function (img, index) {\n // Apply initial random rotation between 0 and 360 degrees\n var initialRotation = Math.random() * 360;\n var rotateDirection = Math.random() < 0.5 ? -1 : 1; // Randomly choose rotate direction\n var rotateSpeed = Math.random() * 10; // Limit rotation speed to 10 degrees\n\n // Calculate parallax speed based on index\n var parallaxFactor = parseInt(img.dataset.scrub);\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.set(img, {\n rotation: initialRotation\n }); // Set initial rotation\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(img, {\n scrollTrigger: {\n trigger: _this2,\n start: 'top bottom',\n end: 'bottom top',\n scrub: parallaxFactor\n },\n y: \"+=\".concat(window.innerHeight * 0.5 * parallaxFactor / 3),\n rotation: \"+=\".concat(rotateSpeed * rotateDirection),\n ease: 'none'\n });\n });\n }\n }, {\n key: \"initBottleClick\",\n value: function initBottleClick() {\n this.img.forEach(function (image) {\n image.addEventListener('click', function (e) {\n console.log('clicked');\n e.currentTarget.classList.add('clicked');\n });\n });\n }\n }, {\n key: \"initCursor\",\n value: function initCursor() {\n var _this3 = this;\n this.section = document.querySelector('.animation-bottles');\n var lastKnownMouseX = 0;\n var lastKnownMouseY = 0;\n var isHovering = false;\n var updatePosition = function updatePosition() {\n var rect = _this3.section.getBoundingClientRect();\n var relativeX = lastKnownMouseX - rect.left;\n var relativeY = lastKnownMouseY - rect.top;\n\n // Check if the mouse is inside the parent element\n if (relativeX >= 0 && relativeX <= rect.width && relativeY >= 0 && relativeY <= rect.height) {\n if (!isHovering) {\n isHovering = true;\n _this3.section.classList.add('hovered');\n }\n } else {\n if (isHovering) {\n isHovering = false;\n _this3.section.classList.remove('hovered');\n }\n }\n\n // Smoothly move the target to the new position\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(_this3.target, {\n x: relativeX,\n y: relativeY,\n ease: \"power3.out\",\n // Smooth easing\n duration: 1 // Adjust the duration to control the lag\n });\n };\n\n // Track mouse position relative to the parent element on mousemove\n this.section.addEventListener(\"mousemove\", function (event) {\n lastKnownMouseX = event.clientX;\n lastKnownMouseY = event.clientY;\n updatePosition();\n });\n\n // Ensure the hover class is removed when the mouse leaves the section\n this.section.addEventListener(\"mouseleave\", function () {\n isHovering = false;\n _this3.section.classList.remove('hovered');\n });\n\n // Continuously check and update mouse position relative to the parent element during scroll\n window.addEventListener(\"scroll\", function () {\n var rect = _this3.section.getBoundingClientRect();\n\n // Check if the section is in the viewport\n if (rect.top < window.innerHeight && rect.bottom > 0) {\n // If the mouse is within the viewport but the hover state isn't active, activate it\n if (lastKnownMouseX >= rect.left && lastKnownMouseX <= rect.right && lastKnownMouseY >= rect.top && lastKnownMouseY <= rect.bottom) {\n if (!isHovering) {\n isHovering = true;\n _this3.section.classList.add('hovered');\n }\n updatePosition();\n } else if (isHovering) {\n isHovering = false;\n _this3.section.classList.remove('hovered');\n }\n }\n });\n\n // Continuously update position even if re-entering the section\n this.section.addEventListener(\"mouseenter\", function () {\n updatePosition();\n });\n }\n }, {\n key: \"fadeOutContent1\",\n value: function fadeOutContent1() {\n var _this4 = this;\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(this.content1, {\n opacity: 0,\n duration: 1,\n onComplete: function onComplete() {\n _this4.fadeInContent2();\n }\n });\n }\n }, {\n key: \"fadeInContent2\",\n value: function fadeInContent2() {\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(this.content2, {\n opacity: 1,\n duration: 1\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"animation-bottles\", AnimationBottles);
127\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationBottles.js?\n}"); 128 129/***/ }, 130 131/***/ "./dev/js/components/animationColleagues.js" 132/*!**************************************************!*\ 133 !*** ./dev/js/components/animationColleagues.js ***! 134 \**************************************************/ 135(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 136 137"use strict"; 138eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar AnimationColleagues = /*#__PURE__*/function (_HTMLElement) {\n function AnimationColleagues() {\n var _this;\n _classCallCheck(this, AnimationColleagues);\n _this = _callSuper(this, AnimationColleagues);\n _this.colleague = _this.querySelectorAll('.colleague');\n _this.headline = _this.querySelectorAll('.headline-container ');\n _this.wrapper = _this.querySelector('.wrapper');\n return _this;\n }\n _inherits(AnimationColleagues, _HTMLElement);\n return _createClass(AnimationColleagues, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initAnimation();\n }\n }, {\n key: \"getRandomNumberBetween\",\n value: function getRandomNumberBetween(min, max) {\n return Math.random() * (max - min) + min;\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\
138n var _this2 = this;\n var timeline = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this,\n start: \"top top\",\n end: \"bottom bottom\",\n pin: this.headline,\n pinSpacing: true,\n onEnter: function onEnter() {\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(_this2.headline, {\n opacity: 1,\n duration: .8,\n ease: \"power1.inOut\"\n });\n },\n onLeave: function onLeave() {\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(_this2.headline, {\n opacity: 0,\n duration: .8,\n ease: \"power1.inOut\"\n });\n },\n onEnterBack: function onEnterBack() {\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(_this2.headline, {\n opacity: 1,\n duration: .8,\n ease: \"power1.inOut\"\n });\n },\n onLeaveBack: function onLeaveBack() {\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(_this2.headline, {\n opacity: 0,\n duration: .8,\n ease: \"power1.inOut\"\n });\n }\n }\n });\n this.colleague.forEach(function (colleague, index) {\n // Randomize the parallax values\n var parallaxFactor = _this2.getRandomNumberBetween(1, 3);\n\n // Parallax animation\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(colleague.querySelector(\".inner-container\"), {\n y: \"+=\".concat(window.innerHeight * 0.5 * parallaxFactor / 3),\n ease: \"none\",\n scrollTrigger: {\n scrub: _this2.getRandomNumberBetween(0.1, 2),\n trigger: colleague,\n start: \"top bottom\",\n end: \"bottom top\"\n }\n });\n\n // Scale and blur animation for the image when hitting the center of the screen\n var image = colleague.querySelector('img');\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.fromTo(image, {\n scale: 1.2,\n filter: \"blur(20px)\"\n },\n // Initial state\n {\n scale: 1,\n filter: \"blur(0px)\",\n duration: 0.2,\n ease: \"power2.out\",\n scrollTrigger: {\n trigger: colleague,\n start: \"center 80%\",\n // Trigger when the element hits the center of the screen\n once: true // Ensure the animation only happens once\n }\n });\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"animation-colleagues\", AnimationColleagues);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationColleagues.js?\n}"); 139 140/***/ }, 141 142/***/ "./dev/js/components/animationFixedtext.js" 143/*!*************************************************!*\ 144 !*** ./dev/js/components/animationFixedtext.js ***! 145 \*************************************************/ 146(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 147 148"use strict"; 149eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
149\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar AnimationFixedtext = /*#__PURE__*/function (_HTMLElement) {\n function AnimationFixedtext() {\n var _this;\n _classCallCheck(this, AnimationFixedtext);\n _this = _callSuper(this, AnimationFixedtext);\n _this.textElement = _this.querySelector('.heading');\n _this.wrapper = _this.querySelector('.wrapper');\n return _this;\n }\n _inherits(AnimationFixedtext, _HTMLElement);\n return _createClass(AnimationFixedtext, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initAnimation();\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n // Pin the section with no animations for now\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this.wrapper,\n // The wrapper element as the trigger\n start: \"top top\",\n // When the top of the wrapper hits the top of the viewport\n end: \"bottom top\",\n // Pin for a duration equal to the viewport height\n scrub: true,\n // Smooth scrubbing\n pin: true // Pin the text in place\n //markers: true, // Disable markers for cleaner output\n }\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"animation-fixedtext\", AnimationFixedtext);
149\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationFixedtext.js?\n}"); 150 151/***/ }, 152 153/***/ "./dev/js/components/animationLoader.js" 154/*!**********************************************!*\ 155 !*** ./dev/js/components/animationLoader.js ***! 156 \**********************************************/ 157() { 158 159eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar AnimationLoading = /*#__PURE__*/function (_HTMLElement) {\n function AnimationLoading() {\n _classCallCheck(this, AnimationLoading);\n return _callSuper(this, AnimationLoading);\n }\n _inherits(AnimationLoading, _HTMLElement);\n return _createClass(AnimationLoading, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this = this;\n window.addEventListener('load', function () {\n _this.style.display = 'none';\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"animation-loading\", AnimationLoading);
159\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationLoader.js?\n}"); 160 161/***/ }, 162 163/***/ "./dev/js/components/animationReveal.js" 164/*!**********************************************!*\ 165 !*** ./dev/js/components/animationReveal.js ***! 166 \**********************************************/ 167(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 168 169"use strict"; 170eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar AnimationReveal = /*#__PURE__*/function (_HTMLElement) {\n function AnimationReveal() {\n var _this;\n _classCallCheck(this, AnimationReveal);\n _this = _callSuper(this, AnimationReveal);\n _this.target = _this.firstElementChild;\n _this.delay = 0;\n return _this;\n }\n _inherits(AnimationReveal, _HTMLElement);
170\n return _createClass(AnimationReveal, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initAnimation();\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n var _this2 = this;\n if (this.hasAttribute('data-delay')) {\n this.delay = parseFloat(this.getAttribute('data-delay'));\n }\n gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.create({\n trigger: this,\n start: 'top 80%',\n onEnter: function onEnter() {\n setTimeout(function () {\n _this2.classList.add('active');\n }, _this2.delay);\n }\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('animation-reveal', AnimationReveal);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationReveal.js?\n}"); 171 172/***/ }, 173 174/***/ "./dev/js/components/animationScrollSection.js" 175/*!*****************************************************!*\ 176 !*** ./dev/js/components/animationScrollSection.js ***! 177 \*****************************************************/ 178(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 179 180"use strict"; 181eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
181 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar AnimationScrollSection = /*#__PURE__*/function (_HTMLElement) {\n function AnimationScrollSection() {\n var _this;\n _classCallCheck(this, AnimationScrollSection);\n _this = _callSuper(this, AnimationScrollSection);\n _this.left = document.querySelector(\".column-left\");\n _this.right = document.querySelector(\".column-right\");\n return _this;\n }\n _inherits(AnimationScrollSection, _HTMLElement);\n return _createClass(AnimationScrollSection, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initAnimation();\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n var _this2 = this;\n var totalRows = document.querySelectorAll('.column-left .column-items').length;\n var tl = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n pin: \".columns\",\n trigger: \".columns\",\n start: \"top top\",\n end: function end() {\n return \"+=\".concat(window.innerHeight * totalRows);\n },\n // End based on the total number of rows\n scrub: 0.5,\n pinSpacing: true\n }\n });\n tl.to(this.left, {\n y: function y() {\n return -1 * (_this2.left.scrollHeight - window.innerHeight);\n }\n }, 0).from(this.right, {\n y: function y() {\n return -1 * (_this2.right.scrollHeight - window.innerHeight);\n }\n }, 0);\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"animation-scrollsection\", AnimationScrollSection);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationScrollSection.js?\n}"); 182 183/***/ }, 184 185/***/ "./dev/js/components/animationScrolltext.js" 186/*!**************************************************!*\ 187 !*** ./dev/js/components/animationScrolltext.js ***! 188 \**************************************************/ 189(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 190 191"use strict"; 192eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
192\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar AnimationScrolltext = /*#__PURE__*/function (_HTMLElement) {\n function AnimationScrolltext() {\n var _this;\n _classCallCheck(this, AnimationScrolltext);\n _this = _callSuper(this, AnimationScrolltext);\n _this.wrapper = _this.querySelector('.wrapper');\n _this.image = _this.wrapper.querySelectorAll('img');\n _this.contentAfter = _this.wrapper.querySelector('.content-after');\n _this.content = _this.wrapper.querySelector('.content');\n _this.split = _this.content.querySelector('.split');\n return _this;\n }\n _inherits(AnimationScrolltext, _HTMLElement);\n return _createClass(AnimationScrolltext, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n this.initAnimation();\n window.addEventListener('load', function () {\n _this2.splitAnimation();\n });\n }\n }, {\n key: \"splitAnimation\",\n value: function splitAnimation() {\n // Animate each character with a staggered y value change\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(this.split.querySelectorAll('span'), {\n y: 0,\n duration: 1,\n ease: \"power2.out\",\n stagger: 0.05\n });\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n var timeline = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this.wrapper,\n start: \"top top\",\n end: \"center top\",\n pin: true,\n scrub: true\n }\n });\n timeline.to(this.content, {\n opacity: 0,\n duration: 1\n }).to(this.image, {\n filter: 'grayscale(100%)',\n webkitFilter: 'grayscale(100%)',\n scale: 1.2,\n duration: 1\n }, 0).to(this.contentAfter, {\n opacity: 1,\n duration: 1\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"animation-scrolltext\", AnimationScrolltext);
192\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationScrolltext.js?\n}"); 193 194/***/ }, 195 196/***/ "./dev/js/components/animationSplitImage.js" 197/*!**************************************************!*\ 198 !*** ./dev/js/components/animationSplitImage.js ***! 199 \**************************************************/ 200(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 201 202"use strict"; 203eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar AnimationSplitImage = /*#__PURE__*/function (_HTMLElement) {\n function AnimationSplitImage() {\n var _this;\n _classCallCheck(this, AnimationSplitImage);\n _this = _callSuper(this, AnimationSplitImage);\n _this.columns = _this.querySelectorAll('.column');\n _this.img = _this.querySelectorAll('.column img');\n _this.container = _this.querySelector('.container');\n _this.content = _this.querySelector('.content');\n _this.wrapper = _this.querySelector('.wrapper');\n return _this;\n }\n _inherits(AnimationSplitImage, _HTMLElement);\n return _createClass(AnimationSplitImage, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n if (window.innerWidth > 1024) {\n this.initAnimation();\n this.moveAnimation();\n this.textAnimation();\n } else {\n //this.initMobileAnimation();\n this.moveMobileAnimation();\n }\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\
203n var _this2 = this;\n // Set initial staggered Y positions for the images\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.set(this.img[0], {\n y: 600\n });\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.set(this.img[1], {\n y: 1200\n });\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.set(this.img[2], {\n y: 1800\n });\n\n // Animate the Y position of each image on scroll\n this.img.forEach(function (column, index) {\n var initialY = 600 * index;\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.fromTo(column, {\n y: initialY\n }, {\n y: 0,\n scrollTrigger: {\n trigger: _this2.img[0],\n // Use a specific child element as the trigger\n start: \"top 100%\",\n end: \"top top\",\n scrub: true\n }\n });\n });\n }\n }, {\n key: \"moveAnimation\",\n value: function moveAnimation() {\n // Use a child element as the trigger to avoid infinite loop\n var timeline = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this.columns[0],\n start: \"top top\",\n end: \"bottom\",\n pin: true,\n scrub: true\n //markers: {startColor: \"red\", endColor: \"blue\", fontSize: \"18px\", fontWeight: \"bold\", indent: 20}\n }\n });\n\n // Move the columns to the right and overlap them\n timeline.to(this.columns[0], {\n xPercent: 200,\n duration: 1\n }, 0); // Move the first column to the right\n\n var timeline1 = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this.columns[1],\n start: \"top top\",\n end: \"bottom\",\n pin: true,\n scrub: true\n }\n });\n\n // Move the columns to the right and overlap them\n timeline1.to(this.columns[1], {\n xPercent: 100,\n duration: 1\n }, 0); // Move the first column to the right\n\n var timeline2 = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this.columns[2],\n start: \"top top\",\n end: \"bottom\",\n pin: true,\n scrub: true\n }\n });\n }\n }, {\n key: \"textAnimation\",\n value: function textAnimation() {\n var timeline = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this.content,\n start: \"top top\",\n end: \"bottom\",\n pin: true,\n scrub: true\n }\n });\n timeline.to(this.content.querySelectorAll('.split span'), {\n y: 0,\n duration: 1,\n ease: \"power2.out\",\n stagger: 0.05\n });\n timeline.from(this.content.querySelectorAll('p'), {\n opacity: 0,\n duration: 1\n });\n }\n }, {\n key: \"moveMobileAnimation\",\n value: function moveMobileAnimation() {\n // Replicate desktop movement: pin and move each image to the right sequentially\n var timeline = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this.wrapper,\n start: 'top top',\n end: function end() {\n return \"bottom+=\".concat(window.innerHeight * 3, \"px\");\n },\n pin: true,\n scrub: true\n //markers: true,\n }\n });\n timeline.to(this.columns[0], {\n xPercent: 100,\n duration: 1\n }, 0).to(this.columns[1], {\n xPercent: 100,\n duration: 1\n }, '+=1').to(this.columns[2], {\n xPercent: 100,\n duration: 1\n }, '+=1');\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('animation-splitimage', AnimationSplitImage);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationSplitImage.js?\n}"); 204 205/***/ }, 206 207/***/ "./dev/js/components/animationVideo.js" 208/*!*********************************************!*\
209 !*** ./dev/js/components/animationVideo.js ***! 210 \*********************************************/ 211(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 212 213"use strict"; 214eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar AnimationVideo = /*#__PURE__*/function (_HTMLElement) {\n function AnimationVideo() {\n var _this;\n _classCallCheck(this, AnimationVideo);\n _this = _callSuper(this, AnimationVideo);\n _this.wrapper = _this.querySelector('.wrapper');\n _this.content = _this.querySelector('.content');\n _this.veil = _this.querySelector('.veil');\n return _this;\n }\n _inherits(AnimationVideo, _HTMLElement);\n return _createClass(AnimationVideo, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initAnimation();\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\
214n var timeline = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this.wrapper,\n // The wrapper element as the trigger\n start: \"top top\",\n // Start pinning when the top of the wrapper hits the top of the viewport\n end: \"bottom top\",\n // Pin for a duration equal to the viewport height\n scrub: true,\n // Smooth scrubbing\n pin: true,\n // Pin the entire section\n pinSpacing: true\n //markers: true, // Enable markers for debugging (optional)\n }\n });\n\n // Fade in the content and the veil when half of the section is scrolled\n timeline.fromTo([this.content, this.veil], {\n opacity: 0\n },\n // Initial state: fully transparent\n {\n opacity: 0.8,\n duration: 1\n },\n // Fade to fully visible\n \"50%\" // Trigger at the halfway point of the scroll\n );\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"animation-video\", AnimationVideo);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/animationVideo.js?\n}"); 215 216/***/ }, 217 218/***/ "./dev/js/components/announcementBar.js" 219/*!**********************************************!*\ 220 !*** ./dev/js/components/announcementBar.js ***! 221 \**********************************************/ 222() { 223 224eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
224 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar AnnouncementBar = /*#__PURE__*/function (_HTMLElement) {\n function AnnouncementBar() {\n var _this$navbar, _this$navbar2, _this$navbar3, _this$navbar4;\n var _this;\n _classCallCheck(this, AnnouncementBar);\n _this = _callSuper(this, AnnouncementBar);\n _this.root = document.documentElement;\n _this.initialHeight = 0;\n _this.onScroll = _this.onScroll.bind(_this);\n _this.navbar = document.querySelector('navbar-component');\n\n // merken, ob die Navbar beim Laden transparent war\n _this.wasInitiallyTransparent = ((_this$navbar = _this.navbar) === null || _this$navbar === void 0 ? void 0 : _this$navbar.classList.contains('transparent')) || false;\n _this.wasInitiallyTransparentMobile = ((_this$navbar2 = _this.navbar) === null || _this$navbar2 === void 0 ? void 0 : _this$navbar2.classList.contains('transparent_mobile')) || false;\n _this.wasInitiallyLight = ((_this$navbar3 = _this.navbar) === null || _this$navbar3 === void 0 ? void 0 : _this$navbar3.classList.contains('light')) || false;\n _this.wasInitiallyLightMobile = ((_this$navbar4 = _this.navbar) === null || _this$navbar4 === void 0 ? void 0 : _this$navbar4.classList.contains('light_mobile')) || false;\n return _this;\n }\n _inherits(AnnouncementBar, _HTMLElement);\n return _createClass(AnnouncementBar, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initialHeight = this.offsetHeight;\n this.setHeight(this.initialHeight);\n window.addEventListener('scroll', this.onScroll);\n }\n }, {\n key: \"disconnectedCallback\",\n value: function disconnectedCallback() {\n window.removeEventListener('scroll', this.onScroll);\n }\n }, {\n key: \"onScroll\",\n value: function onScroll() {\n var scrolled = window.scrollY > 0;\n this.setHeight(scrolled ? 0 : this.initialHeight);\n if (this.wasInitiallyTransparent) {\n if (scrolled) {\n this.navbar.classList.remove('transparent');\n } else {\n this.navbar.classList.add('transparent');\n }\n }\n if (this.wasInitiallyLight) {\n if (scrolled) {\n this.navbar.classList.remove('light');\n } else {\n this.navbar.classList.add('light');\n }\n }\n if (this.wasInitiallyTransparentMobile) {\n if (scrolled) {\n this.navbar.classList.remove('transparent_mobile');\n } else {\n this.navbar.classList.add('transparent_mobile');\n }\n }\n if (this.wasInitiallyLightMobile) {\n if (scrolled) {\n this.navbar.classList.remove(\"light_mobile\");\n } else {\n this.navbar.classList.add(\"light_mobile\");\n }\n }\n }\n }, {\n key: \"setHeight\",\n value: function setHeight(value) {\n this.root.style.setProperty('--announcement-bar-height', \"\".concat(value, \"px\"));\n this.root.style.setProperty('--announcement-bar-height-inverted', \"\".concat(value - this.initialHeight, \"px\"));\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\ncustomElements.define('announcement-bar-component', AnnouncementBar);
224\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/announcementBar.js?\n}"); 225 226/***/ }, 227 228/***/ "./dev/js/components/announcementBarV2.js" 229/*!************************************************!*\ 230 !*** ./dev/js/components/announcementBarV2.js ***! 231 \************************************************/ 232() { 233 234eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread(); }\nfunction _nonIterableSpread() { throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _iterableToArray(r) { if (\"undefined\" != typeof Symbol && null != r[Symbol.iterator] || null != r[\"@@iterator\"]) return Array.from(r); }\nfunction _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(r); }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
234 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar AnnouncementBarV2 = /*#__PURE__*/function (_HTMLElement) {\n function AnnouncementBarV2() {\n var _this$navbar, _this$navbar2, _this$navbar3, _this$navbar4;\n var _this;\n _classCallCheck(this, AnnouncementBarV2);\n _this = _callSuper(this, AnnouncementBarV2);\n _this.root = document.documentElement;\n _this.initialHeight = 0;\n _this.onScroll = _this.onScroll.bind(_this);\n _this.navbar = document.querySelector('navbar-component');\n _this.wasInitiallyTransparent = ((_this$navbar = _this.navbar) === null || _this$navbar === void 0 ? void 0 : _this$navbar.classList.contains('transparent')) || false;\n _this.wasInitiallyTransparentMobile = ((_this$navbar2 = _this.navbar) === null || _this$navbar2 === void 0 ? void 0 : _this$navbar2.classList.contains('transparent_mobile')) || false;\n _this.wasInitiallyLight = ((_this$navbar3 = _this.navbar) === null || _this$navbar3 === void 0 ? void 0 : _this$navbar3.classList.contains('light')) || false;\n _this.wasInitiallyLightMobile = ((_this$navbar4 = _this.navbar) === null || _this$navbar4 === void 0 ? void 0 : _this$navbar4.classList.contains('light_mobile')) || false;\n return _this;\n }\n _inherits(AnnouncementBarV2, _HTMLElement);\n return _createClass(AnnouncementBarV2, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n if (getComputedStyle(this).display === 'none') return;\n this.initialHeight = this.offsetHeight;\n this.setHeight(this.initialHeight);\n window.addEventListener('scroll', this.onScroll);\n this._initSlider();\n }\n }, {\n key: \"_initSlider\",\n value: function _initSlider() {\n var _this2 = this;\n var slides = _toConsumableArray(this.querySelectorAll('.announcement-bar-v2__slide'));\n var sliderEl = this.querySelector('.announcement-bar-v2__slider');\n if (!sliderEl || slides.length === 0) return;\n var getWidth = function getWidth(i) {\n var _slides$i$querySelect, _slides$i;\n return (_slides$i$querySelect = (_slides$i = slides[i]) === null || _slides$i === void 0 || (_slides$i = _slides$i.querySelector('.announcement-bar-v2__slide-inner')) === null || _slides$i === void 0 ? void 0 : _slides$i.offsetWidth) !== null && _slides$i$querySelect !== void 0 ? _slides$i$querySelect : null;\n };\n var current = 0;\n var fadeRafId = null;\n var advanceTimeoutId = null;\n var showTimeoutId = null;\n var show = function show(i) {\n var animate = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;\n // data-active erlaubt CSS auf Mobile: aktive Slide in den Dokumentfluss\n slides.forEach(function (s) {\n return s.removeAttribute('data-active');\n });\n slides[i].setAttribute('data-active', '');\n var w = getWidth(i);\n if (w) sliderEl.style.width = \"\".concat(w, \"px\");\n if (fadeRafId) {\n cancelAnimationFrame(fadeRafId);\n fadeRafId = null;\n }\n if (!animate) {\n slides[i].style.transition = '
234none';\n slides[i].style.transform = 'translateY(0)';\n slides[i].style.opacity = '1';\n return;\n }\n slides[i].style.transition = 'none';\n slides[i].style.transform = 'translateY(-100%)';\n slides[i].style.opacity = '0';\n fadeRafId = requestAnimationFrame(function () {\n fadeRafId = requestAnimationFrame(function () {\n fadeRafId = null;\n // Guard: rAF kann sich im Hintergrund-Tab aufgestaut haben â\n // nur die noch aktuelle Slide einblenden\n if (current !== i) return;\n slides[i].style.transition = 'opacity 0.3s ease, transform 0.3s ease';\n slides[i].style.opacity = '1';\n slides[i].style.transform = 'translateY(0)';\n });\n });\n };\n\n // double rAF so countdown has time to render before measuring\n requestAnimationFrame(function () {\n return requestAnimationFrame(function () {\n show(0, false);\n // Nach dem ersten Render Höhe neu messen â auf Mobile kann auto-height\n // von der CSS-Höhe abweichen (z.B. wenn Text umbricht)\n var h = _this2.offsetHeight;\n if (h !== _this2.initialHeight) {\n _this2.initialHeight = h;\n _this2.setHeight(h);\n }\n });\n });\n if (slides.length < 2) return;\n var _next = function next() {\n var delay = parseInt(slides[current].dataset.delay, 10) || 3800;\n advanceTimeoutId = setTimeout(function () {\n var outgoing = slides[current];\n current = (current + 1) % slides.length;\n outgoing.style.transition = 'opacity 0.3s ease, transform 0.3s ease';\n outgoing.style.opacity = '0';\n outgoing.style.transform = 'translateY(100%)';\n showTimeoutId = setTimeout(function () {\n show(current);\n _next();\n }, 400);\n }, delay);\n };\n var pause = function pause() {\n clearTimeout(advanceTimeoutId);\n clearTimeout(showTimeoutId);\n if (fadeRafId) {\n cancelAnimationFrame(fadeRafId);\n fadeRafId = null;\n }\n };\n\n // Im Hintergrund-Tab läuft setTimeout gedrosselt weiter, während\n // requestAnimationFrame komplett pausiert wird â das führt zu aufgestauten\n // Slide-Wechseln, die beim Zurückkehren alle auf einmal feuern. Deshalb die\n // Rotation beim Verstecken anhalten und sauber neu starten.\n var onVisibilityChange = function onVisibilityChange() {\n if (document.hidden) {\n pause();\n } else {\n show(current, false);\n _next();\n }\n };\n document.addEventListener('visibilitychange', onVisibilityChange);\n this._cleanupSlider = function () {\n pause();\n document.removeEventListener('visibilitychange', onVisibilityChange);\n };\n _next();\n }\n }, {\n key: \"disconnectedCallback\",\n value: function disconnectedCallback() {\n window.removeEventListener('scroll', this.onScroll);\n if (this._cleanupSlider) this._cleanupSlider();\n }\n }, {\n key: \"onScroll\",\n value: function onScroll() {\n var scrolled = window.scrollY > 0;\n this.setHeight(scrolled ? 0 : this.initialHeight);\n if (this.wasInitiallyTransparent) {\n this.navbar.classList.toggle('transparent', !scrolled);\n }\n if (this.wasInitiallyLight) {\n this.navbar.classList.toggle('light', !scrolled);\n }\n if (this.wasInitiallyTransparentMobile) {\n this.navbar.classList.toggle('transparent_mobile', !scrolled);\n }\n if (this.wasInitiallyLightMobile) {\n this.navbar.classList.toggle('light_mobile', !scrolled);\n }\n }\n }, {\n key: \"setHeight\",\n value: function setHeight(value) {\n this.root.style.setProperty('--announcement-bar-height', \"\".concat(value, \"px\"));\n this.root.style.setProperty('--announcement-bar-height-inverted', \"\".concat(value - this.initialHeight, \"px\"));\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\ncustomElements.define('announcement-bar-v2', AnnouncementBarV2);
234\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/announcementBarV2.js?\n}"); 235 236/***/ }, 237 238/***/ "./dev/js/components/atomic/dropdown.js" 239/*!**********************************************!*\ 240 !*** ./dev/js/components/atomic/dropdown.js ***! 241 \**********************************************/ 242() { 243 244eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar Dropdown = /*#__PURE__*/function (_HTMLElement) {\n function Dropdown() {\n var _this;\n _classCallCheck(this, Dropdown);\n _this = _callSuper(this, Dropdown);\n _this.opener = _this.querySelector('.selected');\n _this.selectedText = _this.querySelector('.selected>span');\n _this.items = _this.querySelectorAll('ul li');\n return _this;\n }\n _inherits(Dropdown, _HTMLElement);\n return _createClass(Dropdown, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.openModal();\n this.toggleItems();\n }\n }, {\n key: \"openModal\",\n value: function openModal() {\n var _this2 = this;\n this.opener.addEventListener('click', function () {\n _this2.classList.toggle('active');\n });\n }\n }, {\n key: \"toggleItems\",\n value: function toggleItems() {\n var _this3 = this;
244\n this.items.forEach(function (item) {\n item.addEventListener('click', function () {\n // Aktiven Zustand setzen\n _this3.items.forEach(function (i) {\n return i.classList.remove('active');\n });\n item.classList.add('active');\n _this3.selectedText.innerHTML = Array.from(item.querySelectorAll('span')).map(function (s) {\n return s.outerHTML;\n }).join('');\n _this3.classList.remove('active');\n });\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('dropdown-component', Dropdown);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/atomic/dropdown.js?\n}"); 245 246/***/ }, 247 248/***/ "./dev/js/components/atomic/tabs.js" 249/*!******************************************!*\ 250 !*** ./dev/js/components/atomic/tabs.js ***! 251 \******************************************/ 252() { 253 254eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar Tabs = /*#__PURE__*/function (_HTMLElement) {\n function Tabs() {\n var _this;\n _classCallCheck(this, Tabs);\n _this = _callSuper(this, Tabs);\n _this.indicator = _this.querySelector('indicator-component');\n _this.tabs = _this.querySelectorAll('[data-tab]');\n return _this;\n }\n _inherits(Tabs, _HTMLElement);\n return _createClass(Tabs, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n this.setDimensions();
254\n this.tabs.forEach(function (element) {\n element.addEventListener('click', function () {\n _this2.tabs.forEach(function (i) {\n return i.classList.remove('active');\n });\n element.classList.add('active');\n _this2.setDimensions();\n });\n });\n }\n }, {\n key: \"setDimensions\",\n value: function setDimensions() {\n var _this3 = this;\n this.tabs.forEach(function (element) {\n if (element.classList.contains('active')) {\n var width = element.getBoundingClientRect().width;\n var left = element.offsetLeft;\n _this3.style.setProperty('--indicator-width', \"\".concat(width, \"px\"));\n _this3.style.setProperty('--indicator-position', \"\".concat(left, \"px\"));\n }\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('tabs-component', Tabs);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/atomic/tabs.js?\n}"); 255 256/***/ }, 257 258/***/ "./dev/js/components/bundle.js" 259/*!*************************************!*\ 260 !*** ./dev/js/components/bundle.js ***! 261 \*************************************/ 262(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 263 264"use strict"; 265eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_addProduct__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/addProduct */ \"./dev/js/helper/addProduct.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
265 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\nvar Bundle = /*#__PURE__*/function (_HTMLElement) {\n function Bundle() {\n var _this;\n _classCallCheck(this, Bundle);\n _this = _callSuper(this, Bundle);\n _this.initializeElements();\n _this.addEventListeners();\n return _this;\n }\n _inherits(Bundle, _HTMLElement);\n return _createClass(Bundle, [{\n key: \"initializeElements\",\n value: function initializeElements() {\n this.id = this.getAttribute('id');\n this.bundleContainers = [document.querySelector('#bundle-1'), document.querySelector('#bundle-2'), document.querySelector('#bundle-3')];\n this.stepButtons = [document.querySelector('.bundle-step-1'), document.querySelector('.bundle-step-2')];\n this.bundleOptions = document.querySelector('.bundles__options');\n this.spinner = document.querySelector('.loader-button__loader');\n this.statusText = document.querySelector('.text');\n }\n }, {\n key: \"addEventListeners\",\n value: function addEventListeners() {\n var _this2 = this;\n this.stepButtons.forEach(function (button, index) {\n button.addEventListener('click', function (event) {\n event.preventDefault();\n _this2.handleBundleStep(index);\n });\n });\n\n // Add event listeners for dropdown and swatch changes\n this.bundleContainers.forEach(function (container) {\n var selectElement = container.querySelector('select');\n if (selectElement) {\n selectElement.addEventListener('change', _this2.updateSelectedValueDisplay.bind(_this2, container));\n }\n var comboBoxOptions = container.querySelectorAll('.combo-box__option-item');\n comboBoxOptions.forEach(function (option) {\n option.addEventListener('click', function () {\n if (selectElement) {\n selectElement.value = option.value;\n var event = new Event('change');\n selectElement.dispatchEvent(event);\n }\n });\n });\n });\n }\n }, {\n key: \"updateSelectedValueDisplay\",\n value: function updateSelectedValueDisplay(container) {\n if (container) {\n var selectElement = container.querySelector('select');\n var selectedValueSpan = container.querySelector('.select__selected-value');\n if (selectElement && selectedValueSpan) {\n var selectedOption = selectElement.options[selectElement.selectedIndex];\n selectedValueSpan.textContent = selectedOption.textContent;\n }\n }\n }\n }, {\n key: \"handleBundleStep\",\n value: function handleBundleStep(stepIndex) {\n var selectedVariantId = this.getSelectedVariantId(this.bundleContainers[stepIndex]);\n var currentBundle = this.bundleOptions.getAttribute('products') || '';\n this.bundleOptions.setAttribute('products', currentBundle ? \"\".concat(currentBundle, \",\").concat(selectedVariantId) : selectedVariantId);\n switch (stepIndex) {\n case 0:\n this.transitionBetweenSteps(0, 1);\n break;\n case 1:\n //this.transitionBetweenSteps(1, 2);\n this.prepareForAddingToCart();\n this.addBundleToCart();\n break;\n case 2:\n break;\n }\n }\n }, {\n key: \"transitionBetweenSteps\",\n value: function transitionBetweenSteps(first, second) {\n var _this3 = this;\n this.bundleContainers[first].classList.add('fadeOut');\n this.bundleOptions.classList.remove(\"step-\".concat(first + 1));\n this.bundleOptions.classList.add(\"step-\".concat(first + 2));\n setTimeout(function () {\n _this3.bundleContainers[first].classList.remove('active');\n _this3.bundleContainers[second].classList.add('active');\n _this3.bundleContainers[second].classList.add('fadeIn');\n window.scrollTo(0, 0);\n }, 500);\n }\n }, {\n key: \"getSelectedVariantId\",\n value: function getSelectedVariantId(container) {\n var swatchElement = container.querySelector('.color-swatch__radio:checked');\n var swatch = swatchElement ? swatchElement.getAttribute('variant-id') : null;\n var dropdownElement = container.querySelector('select option[selected]');\n var dropdown = dropdownElement ? dropdownElement.getAttribute('variant-id') : null;\n if (swatch) {\n return swatch;\n } else {\n return dropdown;\n }\n }\n }, {\n key: \"prepareForAddingToCart\",\n value: function prepareForAddingToCart() {\n this.statusText.classList.add('hidden');\n this.spinner.classList.add('active');\n this.bundleOptions.classList.add('step-3');\n this.stepButtons[1].setAttribute('disabled', 'disabled');\n }\n }, {\n key: \"addBundleToCart\",\n value: function addBundleToCart() {\n var _this4 = this;\n var productIds = this.bundleOptions.getAttribute('products').split(',');\n var timestamp = new Date().getTime();\n var discount = this.getAttribute('data-discount') / 2;\n var name = this.id;\n var items = productIds.map(function (id) {\n return {\n id: id,\n quantity: 1,\n properties: {\n _bundle_discount: discount,\n _bundle_added_at: timestamp,\n _bundle_name: name\n }\n };\n });\n (0,_helper_addProduct__WEBPACK_IMPORTED_MODULE_0__.addProduct)({\n items: items\n }, true).then(function () {\n _this4.onAddToCartSuccess();\n });\n }\n }, {\n key: \"onAddToCartSuccess\",\n value: function onAddToCartSuccess() {\
265n this.spinner.classList.remove('active');\n this.statusText.classList.remove('hidden');\n this.stepButtons[1].setAttribute('disabled');\n this.stepButtons[1].classList.add('disabled');\n this.bundleOptions.classList.add('step-4');\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"bundle-builder\", Bundle);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/bundle.js?\n}"); 266 267/***/ }, 268 269/***/ "./dev/js/components/clipboardCode.js" 270/*!********************************************!*\ 271 !*** ./dev/js/components/clipboardCode.js ***! 272 \********************************************/ 273() { 274 275eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
275\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar clipboardCode = /*#__PURE__*/function (_HTMLElement) {\n function clipboardCode() {\n _classCallCheck(this, clipboardCode);\n return _callSuper(this, clipboardCode);\n }\n _inherits(clipboardCode, _HTMLElement);\n return _createClass(clipboardCode, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this = this;\n document.getElementById('copyButton').addEventListener('click', /*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var textToCopy, info, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n textToCopy = _this.getAttribute('data-code'); // Assuming you set the code via attribute\n _context.p = 1;\n _context.n = 2;\n return navigator.clipboard.writeText(textToCopy);\n case 2:\n info = document.querySelector('.copy_info');\n info.classList.add('active');\n setTimeout(function () {\n return info.classList.remove('active');\n }, 2000); // Hide info after 2 seconds\n _context.n = 4;\n break;\n case 3:\n _context.p = 3;\n _t = _context.v;\n console.error('Failed to copy: ', _t);\n case 4:\n return _context.a(2);\n }\n }, _callee, null, [[1, 3]]);\n })));\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('clipboard-code', clipboardCode);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/clipboardCode.js?\n}"); 276 277/***/ }, 278 279/***/ "./dev/js/components/collection/bubbles.js" 280/*!*************************************************!*\ 281 !*** ./dev/js/components/collection/bubbles.js ***! 282 \*************************************************/ 283(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 284 285"use strict"; 286eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
286\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\nvar CollectionBubbles = /*#__PURE__*/function (_HTMLElement) {\n function CollectionBubbles() {\n var _this;\n _classCallCheck(this, CollectionBubbles);\n _this = _callSuper(this, CollectionBubbles);\n _this.swiperContainer = _this.querySelector('.swiper');\n _this.imageSelector = '.swiper-slide img';\n _this.activeSlide = _this.querySelector('.swiper-slide.active');\n _this.text = _this.querySelector('.text');\n\n // Nav-Buttons merken\n _this.nextBtn = _this.querySelector('next-button-component');\n _this.prevBtn = _this.querySelector('prev-button-component');\n return _this;\n }\n _inherits(CollectionBubbles, _HTMLElement);\n return _createClass(CollectionBubbles, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"].use([swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Navigation]);\n var allSlides = this.querySelectorAll('.swiper-slide');\n var totalSlides = allSlides.length;\n\n // Standardwert\n var initialIndex = 0;\n if (this.activeSlide) {\n var visibleSlides = this.getVisibleSlides();\n if (totalSlides > visibleSlides) {\n initialIndex = Array.from(allSlides).indexOf(this.activeSlide);\n }\n }\n this.swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.swiperContainer, {\n slidesPerView: 2.7,\n spaceBetween: 20,\n cssMode: false,\n mousewheel: true,\n initialSlide: initialIndex,\n slidesOffsetAfter: 50,\n watchOverflow: true,\n observer: true,\n observeParents: true,\n navigation: {\n nextEl: this.nextBtn,\n prevEl: this.prevBtn\n },\n breakpoints: {\n 720: {\n spaceBetween: 40,\n slidesPerView: 4\n },\n 1600: {\n slidesPerView: 6\n }\n }
286,\n on: {\n init: function init() {\n return _this2.updateNavigation();\n },\n resize: function resize() {\n return _this2.updateNavigation();\n },\n update: function update() {\n return _this2.updateNavigation();\n },\n slideChangeTransitionStart: function slideChangeTransitionStart() {\n return _this2.swiperContainer.classList.add('is-moving');\n },\n slideChangeTransitionEnd: function slideChangeTransitionEnd() {\n return _this2.swiperContainer.classList.remove('is-moving');\n },\n touchStart: function touchStart() {\n return _this2.swiperContainer.classList.add('is-moving');\n },\n touchEnd: function touchEnd() {\n return _this2.swiperContainer.classList.remove('is-moving');\n }\n }\n });\n\n // CSS Variable für Pfeilhöhe setzen\n this.setCSSVariable();\n window.addEventListener('resize', function () {\n return _this2.setCSSVariable();\n });\n }\n }, {\n key: \"getVisibleSlides\",\n value: function getVisibleSlides() {\n // Breakp
286oints checken, da Swiper erst beim Init die Werte setzt\n var width = window.innerWidth;\n if (width >= 1600) return 6;\n if (width >= 720) return 4;\n return 2.7; // Default\n }\n }, {\n key: \"updateNavigation\",\n value: function updateNavigation() {\n if (!this.nextBtn || !this.prevBtn || !this.swiper) return;\n var visibleSlides = this.swiper.params.slidesPerView;\n var totalSlides = this.swiper.slides.length;\n var notSwipable = totalSlides <= visibleSlides;\n this.nextBtn.toggleAttribute('hidden', notSwipable);\n this.prevBtn.toggleAttribute('hidden', notSwipable);\n }\n }, {\n key: \"setCSSVariable\",\n value: function setCSSVariable() {\n var firstImage = this.querySelector(this.imageSelector);\n if (!firstImage) return;\n var imageHeight = firstImage.offsetHeight;\n var variableValue = imageHeight * 0.5 + 'px';\n this.style.setProperty('--prev-next-height', variableValue);\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('collection-bubbles-component', CollectionBubbles);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/collection/bubbles.js?\n}"); 287 288/***/ }, 289 290/***/ "./dev/js/components/collection/collection.js" 291/*!****************************************************!*\ 292 !*** ./dev/js/components/collection/collection.js ***! 293 \****************************************************/ 294() { 295 296eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
296 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar Collection = /*#__PURE__*/function (_HTMLElement) {\n function Collection() {\n var _this;\n _classCallCheck(this, Collection);\n _this = _callSuper(this, Collection);\n _this.grid = _this.querySelector('.bottom');\n _this.items = Array.from(_this.querySelectorAll('product-card-component'));\n _this.tabs = document.querySelectorAll('tabs-component .tab');\n _this.count = _this.querySelector('.count');\n if (_this.items.some(function (item) {\n return item.parentElement.hasAttribute('data-animation');\n })) {\n _this.items = _this.items.map(function (item) {\n return item.parentElement;\n });\n }\n return _this;\n }\n _inherits(Collection, _HTMLElement);\n return _createClass(Collection, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;
296\n this.tabs.forEach(function (tab) {\n tab.addEventListener('click', function () {\n return _this2.filter(tab.dataset.tab);\n });\n });\n }\n }, {\n key: \"filter\",\n value: function filter(selected) {\n var visibleCount = 0;\n this.items.forEach(function (element) {\n element.classList.add('active');\n var productItem = element.tagName.toLowerCase() === 'product-card-component' ? element : element.querySelector('product-card-component');\n var filters = JSON.parse(productItem.dataset.filters || '[]');\n var match = selected === 'all' || filters.includes(selected);\n if (match) {\n element.removeAttribute(\"hidden\");\n visibleCount++;\n } else {\n element.setAttribute(\"hidden\", true);\n }\n });\n\n // Text in .count komplett neu setzen\n if (this.count) {\n this.count.textContent = \"\".concat(visibleCount, \" Varianten\");\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('collection-component', Collection);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/collection/collection.js?\n}"); 297 298/***/ }, 299 300/***/ "./dev/js/components/collection/sort.js" 301/*!**********************************************!*\ 302 !*** ./dev/js/components/collection/sort.js ***! 303 \**********************************************/ 304() { 305 306eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread(); }\nfunction _nonIterableSpread() { throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _iterableToArray(r) { if (\"undefined\" != typeof Symbol && null != r[Symbol.iterator] || null != r[\"@@iterator\"]) return Array.from(r); }\nfunction _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(r); }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\");
306 t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar CollectionSort = /*#__PURE__*/function (_HTMLElement) {\n function CollectionSort() {\n var _this;\n _classCallCheck(this, CollectionSort);\n _this = _callSuper(this, CollectionSort);\n _this.dropdown = _this.querySelector('dropdown-component');\n // Alle Produkt-Wrapper (animation-reveal) innerhalb der Collection holen\n _this.items = Array.from(document.querySelectorAll('.product-grid animation-reveal'));\n _this.dropdownItems = _this.dropdown.querySelectorAll('ul li');\n return _this;\n }\n _inherits(CollectionSort, _HTMLElement);\n return _createClass(CollectionSort, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n this.dropdownItems.forEach(function (item) {\n item.addEventListener('click', function () {\n var selection = item.dataset.selection;\n _this2.sortItems(selection);\n });\n });\n }\n }, {\n key: \"sortItems\",\n value: function sortItems(selection) {\n var sorted = _toConsumableArray(this.items);\n switch (selection) {\n case 'manual':\n sorted = _toConsumableArray(this.items);\n break;\n case 'price_up':\n sorted.sort(function (a, b) {\n var _a$querySelector, _b$querySelector;\n var aPrice = parseFloat(((_a$querySelector = a.querySelector('product-card-component')) === null || _a$querySelector === void 0 ? void 0 : _a$querySelector.dataset.filterPrice) || 0);\n var bPrice = parseFloat(((_b$querySelector = b.querySelector('product-card-component')) === null || _b$querySelector === void 0 ? void 0 : _b$querySelector.dataset.filterPrice) || 0);\n return aPrice - bPrice;\n });\n break;\n case 'price_down':\n sorted.sort(function (a, b) {\n var _a$querySelector2, _b$querySelector2;\n var aPrice = parseFloat(((_a$querySelector2 = a.querySelector('product-card-component')) === null || _a$querySelector2 === void 0 ? void 0 : _a$querySelector2.dataset.filterPrice) || 0);\n var bPrice = parseFloat(((_b$querySelector2 = b.querySelector('product-card-component')) === null || _b$querySelector2 === void 0 ? void 0 : _b$querySelector2.dataset.f
306ilterPrice) || 0);\n return bPrice - aPrice;\n });\n break;\n case 'new':\n sorted.sort(function (a, b) {\n var _a$querySelector3, _b$querySelector3;\n var aNew = (_a$querySelector3 = a.querySelector('product-card-component')) !== null && _a$querySelector3 !== void 0 && _a$querySelector3.hasAttribute('data-filter-new') ? 1 : 0;\n var bNew = (_b$querySelector3 = b.querySelector('product-card-component')) !== null && _b$querySelector3 !== void 0 && _b$querySelector3.hasAttribute('data-filter-new') ? 1 : 0;\n return bNew - aNew;\n });\n break;\n case 'reduced':\n sorted.sort(function (a, b) {\n var _a$querySelector4, _b$querySelector4;\n var aReduced = (_a$querySelector4 = a.querySelector('product-card-component')) !== null && _a$querySelector4 !== void 0 && _a$querySelector4.hasAttribute('data-filter-reduced') ? 1 : 0;\n var bReduced = (_b$querySelector4 = b.querySelector('product-card-component')) !== null && _b$querySelector4 !== void 0 && _b$querySelector4.hasAttribute('data-filter-reduced') ? 1 : 0;\n return bReduced - aReduced;\n });\n break;\n }\n\n // Reihenfolge setzen\n sorted.forEach(function (wrapper, index) {\n wrapper.style.order = index;\n wrapper.classList.add('active');\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('collection-sort-component', CollectionSort);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/collection/sort.js?\n}"); 307 308/***/ }, 309 310/***/ "./dev/js/components/collection/tiles.js" 311/*!***********************************************!*\ 312 !*** ./dev/js/components/collection/tiles.js ***! 313 \***********************************************/ 314(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 315 316"use strict"; 317eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\");
317 t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\nvar CollectionTiles = /*#__PURE__*/function (_HTMLElement) {\n function CollectionTiles() {\n var _this;\n _classCallCheck(this, CollectionTiles);\n _this = _callSuper(this, CollectionTiles);\n _this.swiperContainer = _this.querySelector('.swiper');\n _this.imageSelector = '.swiper-slide img';\n _this.resizeObserver = null;\n return _this;\n }\n _inherits(CollectionTiles, _HTMLElement);\n return _createClass(CollectionTiles, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"].use([swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Navigation]);\n this.swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.swiperContainer, {\n slidesPerView: 1.5,\n spaceBetween: 10,\n cssMode: false,\n slidesOffsetAfter: 25,\n mousewheel: true,\n navigation: {\n nextEl: 'next-button-component',\n prevEl: 'prev-button-component'\n },\n breakpoints: {\n 720: {\n slidesPerView: 1.8,\n spaceBetween: 20,\n cssMode: true\n }\n }\n });\n this.setCSSVariable();\n window.addEventListener('resize', function () {\n return _this2.setCSSVariable();\n });\n }\n }, {\n key: \"setCSSVariable\",\n value: function setCSSVariable() {\n var firstImage = this.querySelector(this.imageSelector);\n if (!firstImage) return;\n var imageHeight = firstImage.offsetHeight;\n var variableValue = imageHeight * 0.5 + 'px';\n this.style.setProperty('--prev-next-height', variableValue);\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('collection-tiles-component', CollectionTiles);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/collection/tiles.js?\n}"); 318 319/***/ }, 320 321/***/ "./dev/js/components/contentMaxheight.js" 322/*!***********************************************!*\ 323 !*** ./dev/js/components/contentMaxheight.js ***! 324 \***********************************************/ 325() { 326 327eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
327\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar ContentMaxheight = /*#__PURE__*/function (_HTMLElement) {\n function ContentMaxheight() {\n var _this;\n _classCallCheck(this, ContentMaxheight);\n _this = _callSuper(this, ContentMaxheight);\n _this.isOpen = false;\n _this.content = _this.querySelector('.text');\n _this.button = _this.querySelector('.readMore');\n return _this;\n }\n _inherits(ContentMaxheight, _HTMLElement);\n return _createClass(ContentMaxheight, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n if (!this.content || !this.button) return;\n this.content.classList.add('collapsed');\n this.button.addEventListener('click', function () {\n if (_this2.isOpen) return;\n _this2.isOpen = true;\n _this2.content.classList.remove('collapsed');\n _this2.button.style.display = 'none';\n });\n if (window.innerWidth > 768) {\n this.button.style.display = 'none';\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('content-maxheight', ContentMaxheight);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/contentMaxheight.js?\n}"); 328 329/***/ }, 330 331/***/ "./dev/js/components/contentSlider.js" 332/*!********************************************!*\ 333 !*** ./dev/js/components/contentSlider.js ***! 334 \********************************************/ 335(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 336 337"use strict"; 338eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
338 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\n\n\nvar ContentSlider = /*#__PURE__*/function (_HTMLElement) {\n function ContentSlider() {\n var _this;\n _classCallCheck(this, ContentSlider);\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n _this = _callSuper(this, ContentSlider, [].concat(args));\n _defineProperty(_this, \"loadRecommendations\", /*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var loader, _loader$dataset, sectionId, productId, intent, recommendationsCount, url, response, html, responseDoc, slides;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.n) {\n case 0:\n loader = _this.querySelector('[data-recommendations-loader]');\n if (loader) {\n _context.n = 1;\n break;\n }\n return _context.a(2);\n case 1:\n _loader$dataset = loader.dataset, sectionId = _loader$dataset.sectionId, productId = _loader$dataset.productId, intent = _loader$dataset.intent, recommendationsCount = _loader$dataset.recommendationsCount;\n url = \"\".concat(window.themeVariables.routes.productRecommendationsUrl, \"?section_id=\").concat(sectionId, \"&product_id=\").concat(productId, \"&intent=\").concat(intent, \"&limit=\").concat(recommendationsCount);\n _context.n = 2;\n return fetch(url);\n case 2:\n response = _context.v;\n _context.n = 3;\n return response.text();\n case 3:\n html = _context.v;\n responseDoc = document.createElement('div');\n responseDoc.innerHTML = html;\n slides = responseDoc.querySelectorAll('[data-recommendations-loader] .swiper-slide');\n if (slides.length) {\n _this.swiper.appendSlide(Array.from(slides));
338\n _this.swiper.update();\n }\n loader.remove();\n case 4:\n return _context.a(2);\n }\n }, _callee);\n })));\n return _this;\n }\n _inherits(ContentSlider, _HTMLElement);\n return _createClass(ContentSlider, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var paginationEl = this.querySelector('swiper-pagination');\n var fill = document.createElement('span');\n if (paginationEl) paginationEl.appendChild(fill);\n var updateProgress = function updateProgress(swiper) {\n var locked = swiper.isBeginning && swiper.isEnd;\n if (paginationEl) paginationEl.hidden = locked;\n if (!fill || locked) return;\n var adjusted = (1 + swiper.progress * swiper.slides.length) / (swiper.slides.length + 1);\n fill.style.transform = \"scaleX(\".concat(adjusted, \")\");\n };\n var _this$dataset = this.dataset,\n slidesPerViewMobile = _this$dataset.slidesPerViewMobile,\n slidesPerViewTablet = _this$dataset.slidesPerViewTablet,\n slidesPerViewDesktop = _this$dataset.slidesPerViewDesktop,\n gap = _this$dataset.gap,\n gridTablet = _this$dataset.gridTablet;\n var parsedGap = parseFloat(gap);\n var isGridTablet = gridTablet === 'true';\n this.swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.querySelector('.swiper'), {\n modules: [swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Grid, swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Manipulation, swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Mousewheel],\n slidesPerView: parseFloat(slidesPerViewMobile) || 1.2,\n spaceBetween: Number.isNaN(parsedGap) ? 10 : parsedGap,\n loop: false,\n centerInsufficientSlides: true,\n mousewheel: {\n forceToAxis: true\n },\n breakpoints: {\n 640: isGridTablet ? {\n slidesPerView: 2,\n grid: {\n rows: 2,\n fill: 'row'\n }\n } : {\n slidesPerView: parseFloat(slidesPerViewTablet) || 2.2\n },\n 960: {\n slidesPerView: parseFloat(slidesPerViewDesktop) || 3.5,\n grid: {\n rows: 1\n }\n }\n },\n on: {\n init: updateProgress,\n progress: updateProgress,\n breakpoint: updateProgress\n }\n });\n this.loadRecommendations();\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('content-slider', ContentSlider);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/contentSlider.js?\n}"); 339 340/***/ }, 341 342/***/ "./dev/js/components/cookieBanner.js" 343/*!*******************************************!*\ 344 !*** ./dev/js/components/cookieBanner.js ***! 345 \*******************************************/ 346() { 347 348eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
348\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar CookieBanner = /*#__PURE__*/function (_HTMLElement) {\n function CookieBanner() {\n var _this;\n _classCallCheck(this, CookieBanner);\n _this = _callSuper(this, CookieBanner);\n _this.storageKey = \"cookieBannerAccepted\";\n _this.acceptButton = null;\n return _this;\n }\n _inherits(CookieBanner, _HTMLElement);\n return _createClass(CookieBanner, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.acceptButton = this.querySelector(\".accept-button\");\n this.acceptButton.addEventListener(\"click\", this.accept.bind(this));\n if (!this.isAccepted()) {\n this.showBanner();\n }\n }\n }, {\n key: \"accept\",\n value: function accept() {\n localStorage.setItem(this.storageKey, \"true\");\n this.hideBanner();\n }\n }, {\n key: \"isAccepted\",\n value: function isAccepted() {\n return localStorage.getItem(this.storageKey) === \"true\";\n }\n }, {\n key: \"hideBanner\",\n value: function hideBanner() {\n this.style.display = \"none\";\n }\n }, {\n key: \"showBanner\",\n value: function showBanner() {\n this.style.display = \"block\";\n setTimeout(function () {\n document.querySelector('.cookie-banner').classList.add('transform');\n }, 500);\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"cookie-banner\", CookieBanner);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/cookieBanner.js?\n}"); 349 350/***/ }, 351 352/***/ "./dev/js/components/countdown.js" 353/*!****************************************!*\ 354 !*** ./dev/js/components/countdown.js ***! 355 \****************************************/ 356() { 357 358eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to de
358structure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar Countdown = /*#__PURE__*/function (_HTMLElement) {\n function Countdown() {\n var _this;\n _classCallCheck(this, Countdown);\n _this = _callSuper(this, Countdown);\n _this.timerTimeout = null; // Track timeout for cleanup\n return _this;\n }\n _inherits(Countdown, _HTMLElement);\n return _createClass(Countdown, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n var countdownDate = this.getAttribute('data-datetime');\n var format = this.getAttribute('data-format');\n var includeUnits = this.getAttribute('data-unit') === 'true';\n var includeColons = this.getAttribute('data-colons') === 'true';\n var language = document.documentElement.lang || 'en';\n var units;\n switch (language) {\n case 'de':\n units = {\n days: 'Tage',\n hrs: 'Stunden',\n mins: 'Minuten',\n secs: 'Sekunden'\n };\n break;\n case 'fr':\n units = {\n days: 'jours',\n hrs: 'heures',\n mins: 'min',\n secs: 'sec'\n };\n break;\n case 'it':\n units = {\n days: 'giorni',\n hrs: 'ore',\n mins: 'minuti',\n secs: 'secondi'\n };\n break;\n case 'nl':\n units = {\n days: 'dagen',\n hrs: 'uren',\n mins: 'minuten',\n secs: 'seconden'\n };\n break;\n case 'cs':\n units = {\n days: 'dny',\n hrs: 'hodiny',\n mins: 'minut',\n secs: 'sekund'\n };\n break;\n default:\n units = {\n days: 'days',\n hrs: 'hours',\n mins: 'minutes',\n secs: 'seconds'\n };\n }\n\n // Parse date\n var _countdownDate$split = countdownDate.split(/\\.|:|\\s/),\n _countdownDate$split2 = _slicedToArray(_countdownDate$split, 6),\n day = _countdownDate$split2[0],\n month
358= _countdownDate$split2[1],\n year = _countdownDate$split2[2],\n hour = _countdownDate$split2[3],\n minute = _countdownDate$split2[4],\n second = _countdownDate$split2[5];\n month--;\n var targetDateTime = new Date(year, month, day, hour, minute, second).getTime();\n var countdownContainer = document.createElement('div');\n this.appendChild(countdownContainer);\n var _updateCountdown = function updateCountdown() {\n var currentTime = new Date().getTime();\n var timeRemaining = targetDateTime - currentTime;\n\n // CHANGE: If time is up, force it to 0 and don't recalculate a new target\n if (timeRemaining <= 0) {\n timeRemaining = 0;\n }\n var days = Math.floor(timeRemaining / (1000 * 60 * 60 * 24));\n var hours = Math.floor(timeRemaining % (1000 * 60 * 60 * 24) / (1000 * 60 * 60));\n var minutes = Math.floor(timeRemaining % (1000 * 60 * 60) / (1000 * 60));\n var seconds = Math.floor(timeRemaining % (1000 * 60) / 1000);\n var formattedDays = days.toString().padStart(2, '0');\n var formattedHours = hours.toString().padStart(2, '0');\n var formattedMinutes = minutes.toString().padStart(2, '0');\n var formattedSeconds = seconds.toString().padStart(2, '0');\n var countdownString = '';\n if (includeColons) {\n if (includeUnits) {\n countdownString = \"<span class=\\\"countdown-number\\\">\".concat(formattedDays, \"<span class=\\\"unit\\\"> \").concat(units.days, \"</span></span><span class=\\\"colon\\\">:</span>\") + \"<span class=\\\"countdown-number\\\">\".concat(formattedHours, \"<span class=\\\"unit\\\"> \").concat(units.hrs, \"</span></span><span class=\\\"colon\\\">:</span>\") + \"<span class=\\\"countdown-number\\\">\".concat(formattedMinutes, \"<span class=\\\"unit\\\"> \").concat(units.mins, \"</span></span><span class=\\\"colon\\\">:</span>\") + \"<span class=\\\"countdown-number\\\">\".concat(formattedSeconds, \"<span class=\\\"unit\\\"> \").concat(units.secs, \"</span></span>\");\n } else {\n countdownString = \"\".concat(formattedDays, \":\").concat(formattedHours, \":\").concat(formattedMinutes, \":\").concat(formattedSeconds);\n }\n } else {\n if (includeUnits) {\n countdownString = \"<span class=\\\"countdown-number\\\">\".concat(formattedDays, \"<span class=\\\"unit\\\"> \").concat(units.days, \"</span></span> \") + \"<span class=\\\"countdown-number\\\">\".concat(formattedHours, \"<span class=\\\"unit\\\"> \").concat(units.hrs, \"</span></span> \") + \"<span class=\\\"countdown-number\\\">\".concat(formattedMinutes, \"<span class=\\\"unit\\\"> \").concat(units.mins, \"</span></span> \") + \"<span class=\\\"countdown-number\\\">\".concat(formattedSeconds, \"<span class=\\\"unit\\\"> \").concat(units.secs, \"</span></span>\");\n } else {\n countdownString = format.replace('%d', formattedDays).replace('%H', formattedHours).replace('%M', formattedMinutes).replace('%S', formattedSeconds);\n }\n }\n countdownContainer.innerHTML = countdownString;\n\n // Only continue the loop if we haven't reached zero yet\n if (timeRemaining > 0) {\n _this2.timerTimeout = setTimeout(_updateCountdown, 1000);\n }\n };\n _updateCountdown();\n }\n }, {\n key: \"disconnectedCallback\",\n value: function disconnectedCallback() {\n if (this.timerTimeout) {\n clearTimeout(this.timerTimeout);\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('count-down', Countdown);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/countdown.js?\n}"); 359 360/***/ }, 361 362/***/ "./dev/js/components/discountNotification.js" 363/*!***************************************************!*\ 364 !*** ./dev/js/components/discountNotification.js ***! 365 \***************************************************/ 366() { 367 368eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
368\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar DiscountNotification = /*#__PURE__*/function (_HTMLElement) {\n function DiscountNotification() {\n _classCallCheck(this, DiscountNotification);\n return _callSuper(this, DiscountNotification, arguments);\n }\n _inherits(DiscountNotification, _HTMLElement);\n return _createClass(DiscountNotification, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this = this;\n // Check if any discount code should trigger the notification\n var discountCookie = this.getCookie(\"discount_code\");\n var showNotification = this.isValidDiscountCookie(discountCookie);\n\n // Check if any discount code has been shown before using localStorage\n var storedDiscounts = JSON.parse(localStorage.getItem(\"discountBanners\")) || {};\n if (showNotification && !this.hasDiscountBeenShownWithin24Hours(storedDiscounts, discountCookie)) {\n this._onShow();\n this.addEventListener(\"mouseenter\", this.stopTimer.bind(this));\n this.addEventListener(\"mouseleave\", this.startTimer.bind(this));\n window.addEventListener(\"pagehide\", function () {\n return _this.hidden = true;\n });\n\n // Store the discount code with the current timestamp in localStorage\n this.updateDiscountShown(storedDiscounts, discountCookie);\n localStorage.setItem(\"discountBanners\", JSON.stringify(storedDiscounts));\n } else {\n this.hidden = true; // Hide the notification if the cookie doesn't meet the criteria or if a banner was already shown\n }\n }\n }, {\n key: \"hidden\",\n set: function set(value) {\n if (!value) {\n this.startTimer();\n } else {\n this.stopTimer();\n }\n this.toggleAttribute(\"hidden\", value);\n }\n }, {\n key: \"isInsideDrawer\",\n get: function get() {\n return this.classList.contains(\"cart-notification--drawer\");\n }\n }, {\n key: \"stopTimer\",\n value: function stopTimer() {\n clearTimeout(this._timeout);\n }\n }, {\n key: \"startTimer\",\n value: function startTimer() {\n var _this2 = this;\n this._timeout = setTimeout(function () {\n return _this2.hidden = true;\n }, 3e3);\n }\n }, {\n key: \"_onShow\",\n value: function _onShow(event) {\n if (this.isInsideDrawer && !this.closest(\".drawer\").open) {\n return;\n }\n //event.stopPropagation();\n var closeButtonHtml = \"\";\n if (!this.isInsideDrawer) {\n closeButtonHtml = \"\\n <button class=\\\"cart
368-notification__close tap-area hidden-phone\\\" data-action=\\\"close\\\">\\n <span class=\\\"visually-hidden\\\">\".concat(window.themeVariables.strings.accessibilityClose, \"</span>\\n <svg focusable=\\\"false\\\" width=\\\"14\\\" height=\\\"14\\\" class=\\\"icon icon--close icon--inline\\\" viewBox=\\\"0 0 14 14\\\">\\n <path d=\\\"M13 13L1 1M13 1L1 13\\\" stroke=\\\"currentColor\\\" stroke-width=\\\"2\\\" fill=\\\"none\\\"></path>\\n </svg>\\n </button>\\n \");\n }\n this.innerHTML = \"\\n <div class=\\\"cart-notification__overflow\\\">\\n <div class=\\\"container\\\">\\n <div class=\\\"cart-notification__wrapper\\\">\\n <svg focusable=\\\"false\\\" width=\\\"20\\\" height=\\\"20\\\" class=\\\"icon icon--cart-notification\\\" viewBox=\\\"0 0 20 20\\\">\\n <rect width=\\\"20\\\" height=\\\"20\\\" rx=\\\"10\\\" fill=\\\"currentColor\\\"></rect>\\n <path d=\\\"M6 10L9 13L14 7\\\" fill=\\\"none\\\" stroke=\\\"rgb(var(--success-color))\\\" stroke-width=\\\"2\\\"></path>\\n </svg>\\n \\n <div class=\\\"cart-notification__text-wrapper\\\">\\n <span class=\\\"cart-notification__heading heading\\\">\".concat(window.themeVariables.strings.discountActive, \"</span>\\n </div>\\n \\n \").concat(closeButtonHtml, \"\\n </div>\\n </div>\\n </div>\\n \");\n this.clientHeight;\n this.hidden = false;\n }\n }, {\n key: \"isValidDiscountCookie\",\n value: function isValidDiscountCookie(discountCookie) {\n if (!discountCookie) {\n return false; // Cookie doesn't exist, don't show the notification\n }\n\n // Check if the cookie value matches the format \"<word>-<number>\"\n var discountCodeRegex = /^\\w+-\\d+$/;\n return discountCodeRegex.test(discountCookie);\n }\n }, {\n key: \"hasDiscountBeenShownWithin24Hours\",\n value: function hasDiscountBeenShownWithin24Hours(storedDiscounts, discountCode) {\n var oneDayInMilliseconds = 24 * 60 * 60 * 1000; // 24 hours in milliseconds\n var discountInfo = storedDiscounts[discountCode];\n return discountInfo && Date.now() - discountInfo.timestamp <= oneDayInMilliseconds;\n }\n }, {\n key: \"updateDiscountShown\",\n value: function updateDiscountShown(storedDiscounts, discountCode) {\n storedDiscounts[discountCode] = {\n timestamp: Date.now()\n };\n }\n }, {\n key: \"getCookie\",\n value: function getCookie(name) {\n var value = \"; \".concat(document.cookie);\n var parts = value.split(\"; \".concat(name, \"=\"));\n if (parts.length === 2) return parts.pop().split(';').shift();\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"discount-notification\", DiscountNotification);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/discountNotification.js?\n}"); 369 370/***/ }, 371 372/***/ "./dev/js/components/featuredProductSlider.js" 373/*!****************************************************!*\ 374 !*** ./dev/js/components/featuredProductSlider.js ***! 375 \****************************************************/ 376(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 377 378"use strict"; 379eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
379\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\nvar FeaturedProductSliderComponent = /*#__PURE__*/function (_HTMLElement) {\n function FeaturedProductSliderComponent() {\n var _this;\n _classCallCheck(this, FeaturedProductSliderComponent);\n _this = _callSuper(this, FeaturedProductSliderComponent);\n\n // DOM Elements\n _this.swatchSliderEl = _this.querySelector('.swatch-slider');\n _this.productSliderEl = _this.querySelector('.featured-product-slider');\n _this.swatches = _this.querySelectorAll('.swatch-slide');\n _this.productBtnPrev = _this.querySelector('.product-button-prev');\n _this.productBtnNext = _this.querySelector('.product-button-next');\n _this.swatchBtnPrev = _this.querySelector('.swatch-slider-wrapper .swiper-button-prev');\n _this.swatchBtnNext = _this.querySelector('.swatch-slider-wrapper .swiper-button-next');\n if (!_this.productSliderEl) return _possibleConstructorReturn(_this);\n\n // New State Variables\n _this.currentVariantIndex = 0;\n _this.totalVariants = _this.swatches.length;\n _this.initSwipers();\n _this.bindEvents();\n return _this;\n }\n _inherits(FeaturedProductSliderComponent, _HTMLElement);\n return _createClass(FeaturedProductSliderComponent, [{\n key: \"initSwipers\",\n value: function initSwipers() {\n var _this2 = this;\n // 1. Initialize Swatch Slider\n if (this.swatchSliderEl) {\n this.swatchSwiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.swatchSliderEl, {\n slidesPerView: 'auto',\n spaceBetween: 4,\n observer: true,\n observeParents: true,\n on: {\n init: function init(swiper) {\n return _this2.updateFadeClasses(swiper);\n },\n progress: function progress(swiper) {\n return _this2.updateFadeClasses(swiper);\n }\n }\n });\n }\n\n // 2. Initialize Product Slider\n this.productSwiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.productSliderEl, {\n modules: [swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Navigation],\n slidesPerView: 1.5,\n spaceBetween: 16,\n observer: true,\n observeParents: true,\n breakpoints: {\n 768: {\n slidesPerView: 4.2\n }\n },\n navigation: {\n nextEl: this.productBtnNext,\n prevEl: this.productBtnPrev\n },\n on: {\n init: function init(swiper) {\n _this2.updateProductNavVisibility(swiper);\n _this2.updateSwatchNavVisibility(); // Set initial swatch arrow state\n },\n slideChange: function slideChange(swiper) {\n _this2.updateProductNavVisibility(swiper);\n\n // If the product slider is at the end, and we are actively selecting \n // a swatch that is already visible in this final view, DO NOT snap back.\n if (swiper.isEnd && _this2.currentVariantIndex >= swiper.activeIndex) {\n return;\n }\n\n // Otherwise (e.g., user swiped the product slider manually), sync the swatch\n _this2.goToVariant(swiper.activeIndex, false);\n }\n }\n });\n }\n }, {\n key: \"bindEvents\",\n value: function bindEvents() {\n var _this3 = this;
379\n // Swatch Clicks\n this.swatches.forEach(function (swatch, index) {\n swatch.addEventListener('click', function () {\n _this3.goToVariant(index);\n });\n });\n\n // Swatch Arrows -> Now control our internal state\n if (this.swatchBtnPrev) {\n this.swatchBtnPrev.addEventListener('click', function () {\n _this3.goToVariant(_this3.currentVariantIndex - 1);\n });\n }\n if (this.swatchBtnNext) {\n this.swatchBtnNext.addEventListener('click', function () {\n _this3.goToVariant(_this3.currentVariantIndex + 1);\n });\n }\n }\n\n // --- THE BRAIN ---\n // Controls the active state independently of the product slider's physical limits\n }, {\n key: \"goToVariant\",\n value: function goToVariant(index) {\n var moveProductSlider = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;\n if (index < 0 || index >= this.totalVariants) return;\n this.currentVariantIndex = index;\n\n // 1. Move product slider (Swiper will safely ignore this if it's already at the max position)\n if (moveProductSlider && this.productSwiper) {\n this.productSwiper.slideTo(index);\n }\n\n // 2. Sync visual swatch states\n this.syncActiveSwatch(index);\n\n // 3. Update the swatch arrows based on our total variant count\n this.updateSwatchNavVisibility();\n }\n }, {\n key: \"syncActiveSwatch\",\n value: function syncActiveSwatch(activeIndex) {\n var _this4 = this;\n if (!this.swatches.length) return;\n this.swatches.forEach(function (swatch, index) {\n var isActive = index === activeIndex;\n swatch.classList.toggle('is-active', isActive);\n swatch.setAttribute('aria-selected', isActive ? 'true' : 'false');\n\n // Slides the swatch track itself so the active dot stays in view\n if (isActive && _this4.swatchSwiper) {\n _this4.swatchSwiper.slideTo(index);\n }\n });\n }\n }, {\n key: \"updateFadeClasses\",\n value: function updateFadeClasses(swiper) {\n if (!swiper.el) return;\n swiper.el.classList.toggle('is-at-start', swiper.isBeginning);\n swiper.el.classList.toggle('is-at-end', swiper.isEnd);\n }\n }, {\n key: \"updateProductNavVisibility\",\n value: function updateProductNavVisibility(swiper) {\n // These only hide when the physical product slider reaches its ends\n if (this.productBtnPrev) this.productBtnPrev.classList.toggle('is-hidden', swiper.isBeginning);\n if (this.productBtnNext) this.productBtnNext.classList.toggle('is-hidden', swiper.isEnd);\n }\n }, {\n key: \"updateSwatchNavVisibility\",\n value: function updateSwatchNavVisibility() {\n // These now only disable when you hit the absolute first or last variant\n if (this.swatchBtnPrev) {\n this.swatchBtnPrev.classList.toggle('swiper-button-disabled', this.currentVariantIndex === 0);\n }\n if (this.swatchBtnNext) {\n this.swatchBtnNext.classList.toggle('swiper-button-disabled', this.currentVariantIndex === this.totalVariants - 1);\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nif (!customElements.get('featured-product-slider-component')) {\n customElements.define('featured-product-slider-component', FeaturedProductSliderComponent);\n}\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/featuredProductSlider.js?\n}"); 380 381/***/ }, 382 383/***/ "./dev/js/components/filterNav.js" 384/*!****************************************!*\ 385 !*** ./dev/js/components/filterNav.js ***! 386 \****************************************/ 387() { 388 389eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
389\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar FilterNav = /*#__PURE__*/function (_HTMLElement) {\n function FilterNav() {\n _classCallCheck(this, FilterNav);\n return _callSuper(this, FilterNav);\n }\n _inherits(FilterNav, _HTMLElement);\n return _createClass(FilterNav, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this = this;\n var buttons = this.querySelectorAll('button');\n var productItems = document.querySelectorAll('.product-card');\n var countElement = document.querySelector('.product-facet__meta-bar-item--count');\n var facetInfos = document.querySelectorAll('.product-facet__info');\n\n // Create and append position indicator\n this.positionIndicator = this.createPositionIndicator();\n this.appendChild(this.positionIndicator);\n\n // Set initial state\n var allButton = this.querySelector('button[data-controls=\"all\"]');\n if (allButton) {\n this.updateButtonState(buttons, allButton);\n this.showAllProductItems(productItems);\n if (countElement) {\n this.updateItemCount(countElement, productItems);\n }\n requestAnimationFrame(function () {\n if (allButton) {\n _this.updatePositionIndicator(allButton);\n }\n });\n } else {\n requestAnimationFrame(function () {\n if (allButton) {\n _this.updatePositionIndicator(buttons[0]);\n }\n });\n }\n buttons.forEach(function (button, index) {\n button.addEventListener('click', function () {\n _this.updateButtonState(buttons, button);\n if (button.getAttribute('data-controls') === 'all') {\n _this.showAllProductItems(productItems);\n } else {\n _this.updateProductItems(productItems, button);\n }\n if (countElement) {\n _this.updateItemCount(countElement, productItems);\n }\n _this.updateFacetInfoActiveState(facetInfos, index);\n requestAnimationFrame(function () {\n _this.updatePositionIndicator(button);\n });\n });\n });\n }\n }, {\n key: \"createPositionIndicator\",\n value: function createPositionIndicator() {\n var positionIndicator = document.createElement('span');\n positionIndicator.classList.add('tabs-nav__position');\n positionIndicator.classList.add('is-initialized');\n return positionIndicator;\n }\n }, {\n key: \"updatePositionIndicator\",\n value: function updatePositionIndicator(activeButton) {\n var _this2 = this;\n var attempts = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 10;\n if (attempts <= 0) {\n console.error('Failed to position indicator â layout might not be stable.');\n return;\n }\n var buttonRect = activeButton.getBoundingClientRect();\n var parentRect = this.getBoundingClientRect(); // Nimm explizit den FilterNav-Container als Bezug\n\n if (buttonRect.width === 0 || parentRect.width === 0) {\n requestAnimationFrame(function () {\n _this2.updatePositionIndicator(activeButton, attempts - 1);\n });\n return;\n }\n var offsetLeft = buttonRect.left - parentRect.left;\n var width = buttonRect.width;\n this.positionIndicator.style.left = \"\".concat(offsetLeft, \"px\");\n this.positionIndicator.style.width = \"\".concat(width, \"px\");\n }\n }, {\n key: \"updateButtonState\",\n value: function updateButtonState(buttons, activeButton) {\n buttons.forEach(function (btn) {\n return btn.classList.remove('active');\n });\n activeButton.classList.add('active');\n }\n }, {\n key: \"showAllProductItems\",\n value: function showAllProductItems(productItems) {\n productItems.forEac
389h(function (item) {\n item.hidden = false;\n });\n }\n }, {\n key: \"updateProductItems\",\n value: function updateProductItems(productItems, button) {\n var dataControlsValue = button.getAttribute('data-controls');\n productItems.forEach(function (item) {\n var dataFilterValue = item.getAttribute('data-filter');\n item.hidden = dataFilterValue !== dataControlsValue;\n });\n }\n }, {\n key: \"updateItemCount\",\n value: function updateItemCount(countElement, productItems) {\n var visibleItemCount = Array.from(productItems).filter(function (item) {\n return !item.hidden;\n }).length;\n var splitText = countElement.textContent.split(' ');\n countElement.textContent = \"\".concat(visibleItemCount, \" \").concat(splitText[1]);\n }\n }, {\n key: \"updateFacetInfoActiveState\",\n value: function updateFacetInfoActiveState(facetInfos, activeIndex) {\n facetInfos.forEach(function (info, index) {\n info.classList.toggle('active', index === activeIndex);\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('filter-nav', FilterNav);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/filterNav.js?\n}"); 390 391/***/ }, 392 393/***/ "./dev/js/components/freeGiftModal.js" 394/*!********************************************!*\ 395 !*** ./dev/js/components/freeGiftModal.js ***! 396 \********************************************/ 397(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 398 399"use strict"; 400eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ useProducts: () => (/* binding */ useProducts)\n/* harmony export */ });\n/* harmony import */ var _helper_addProduct__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/addProduct */ \"./dev/js/helper/addProduct.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\n\nvar button = document.querySelector('[data-freegift]');\nvar modal = document.querySelector('#freegift-modal');\nvar modalATC = document.querySelector('#freegift-add-btn');\nvar skipButton = document.querySelector('#freegift-skip-btn');\nvar select = document.querySelector('#freegift-select');\nvar selectValue = document.querySelector('#freegift-select-value');\nfunction updateAddToCartFreeGiftFromSelectedSwatch() {\n if (!button) return;\n var selectedSwatch = document.querySelector('.color-swatch__radio:checked');\n if (!selectedSwatch) {\n button.dataset.freegift = '';\n return;\n }\n var isFreeGiftDisabled = selectedSwatch.dataset.freegiftDisabled === 'true';\n if (isFreeGiftDisabled) {\n button.dataset.freegift = '';\n return;\n }\n var firstGiftVariantId = selectedSwatch.dataset.freegiftFirst || '';\n button.dataset.freegift = firstGiftVariantId;\n}\ndocument.addEventListener('DOMContentLoaded', updateAddToCartFreeGiftFromSelectedSwatch);\ndocument.addEventListener('change', function (event) {\n if (event.target.matches('.color-swatch__radio')) {\n updateAddToCartFreeGiftFromSelectedSwatch();\n }\n});\nif (select) {\n select.addEventListener('change', function () {\n setTimeout(function () {\n selectValue.textContent = select.options[select.selectedIndex].dataset.title;\n }, 1);\n });\n}\nif (button) {\n button.addEventListener('click', function (e) {\n var _document$querySelect;\n e.preventDefault();\n updateAddToCartFreeGiftFromSelectedSwatch();\n var timestamp = Date.now();\n var mainId = (_document$querySelect = document.querySelector('.color-swatch__radio:checked')) === null || _document$querySelect === void 0 ? void 0 : _document$querySelect.getAttribute('product-id');\n var gift = button.dataset.freegift || '';\n if (gift && gift.includes(',')) {\n var firstGiftFromQueue = gift.split(',')[0].trim();\n useProducts(mainId, firstGiftFromQueue || null, timestamp);\n return;\n }\n useProducts(mainId, gift || null, timestamp);\n\n // OLD behavior (kept for future re-enable) would have been:\n //\n // if (gift && gift.includes(',')) {\n // modal.setAttribute('open', true);\n // modalATC.addEventListener('click', () => {\n // const modalSelection = document.querySelector('#freegift-select option[selected]').value;\n // useProducts(mainId, modalSelection, timestamp);\n // modal.removeAttribute('open');\n // });\n // skipButton.addEventListener('click', () => {\n // useProducts(mainId, null, timestamp);\n // modal.removeAttribute('open');\n // });\n // } else {\n // useProducts(mainId, gift, timestamp);\n // }\n });\n}\nvar useProducts = function useProducts(mainId, gift) {\n var timestamp = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Date.now();\n var disableTracking = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;\n var mainItem = _objectSpread({\n id: mainId,\n quantity: 1\n }, gift && {\n properties: {\n _gift_added_at: timestamp\n }\n });\n (0,_helper_addProduct__WEBPACK_IMPORTED_MODULE_0__.addProduct)({\n items: [mainItem]\n }, true, true, disableTracking).then(function (r) {\n console.log('Main product added: ', r);\n if (gift) {\n var giftItem = {\n id: gift,\n quantity: 1,\n properties: {\n _free_gift: 'true',\n _gift_added_at: timestamp\n }\n };\n (0,_helper_addProduct__WEBPACK_IMPORTED_MODULE_0__.addProduct)({\n items: [giftItem]\n }, true, true, true).then(function (r2) {\n console.log('Gift added: ', r2);\n })[\"catch\"](function (err) {\n console.warn('Gift could not be added (probably sold out): ', err);\n });\n }\n });\n};\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/freeGiftModal.js?\n}"); 401 402/***/ }, 403 404/***/ "./dev/js/components/giftCard.js" 405/*!***************************************!*\ 406 !*** ./dev/js/components/giftCard.js ***! 407 \***************************************/ 408(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 409 410"use strict"; 411eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_isMobile__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/isMobile */ \"./dev/js/helper/isMobile.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
411 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
411 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\nvar GiftCard = /*#__PURE__*/function (_HTMLElement) {\n function GiftCard() {\n var _this;\n _classCallCheck(this, GiftCard);\n _this = _callSuper(this, GiftCard);\n _this.input = _this.querySelector('.input');\n _this.printButton = _this.querySelector('.js-print-giftcard');\n return _this;\n }\n _inherits(GiftCard, _HTMLElement);\n return _createClass(GiftCard, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n var cardWrapper = this.querySelector('.cardWrapper');\n if (!cardWrapper) return;\n var card = cardWrapper.querySelector('.tilt-card');\n var highlight = cardWrapper.querySelector('.highlight');\n if (!card || !highlight) return;\n var mostX = 10;\n var mostY = 10;\n cardWrapper.addEventListener('mousemove', function (e) {\n card.style.transition = 'none';\n highlight.style.transition = 'none';\n var rect = cardWrapper.getBoundingClientRect();\n var x = e.clientX - rect.left;\n var y = e.clientY - rect.top;\n var halfWidth = rect.width / 2;\n var halfHeight = rect.height / 2;\n var rotationY = (x - halfWidth) / halfWidth * mostX;\n var rotationX = (y - halfHeight) / halfHeight * mostY;\n card.style.transform = \"rotateY(\".concat(rotationY, \"deg) rotateX(\").concat(rotationX, \"deg)\");\n highlight.style.left = \"\".concat(rotationY / mostX * 30 * -1, \"%\");\n highlight.style.top = \"\".concat(rotationX / mostY * 30 * -1, \"%\");\n });\n cardWrapper.addEventListener('mouseleave', function () {\n card.style.transition = 'transform 0.5s ease-in-out';\n card.style.transform = \"rotateY(0) rotateX(0)\";\n highlight.style.transition = 'left 0.5s ease-in-out, top 0.5s ease-in-out';\n highlight.style.left = \"-20%\";\n highlight.style.top = \"-13%\";\n });\n if ((0,_helper_isMobile__WEBPACK_IMPORTED_MODULE_0__.isMobile)()) {\n setTimeout(function () {\n // erste Tilt-Bewegung nach links\n card.style.transition = \"transform 0.4s ease-out\";\n card.style.transform = \"rotateY(-8deg) rotateX(10deg)\";\n setTimeout(function () {\n // zweite Tilt-Bewegung nach rechts\n card.style.transform = \"rotateY(8deg) rotateX(-10deg)\";\n setTimeout(function () {\n // zurück zur Mitte\n card.style.transform = \"rotateY(0deg) rotateX(0deg)\";\n }, 1000);\n }, 1000);\n }, 1000);\n }\n this.input.addEventListener('click', /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(e) {\n var _codeInput$value;\n var codeInput, code, _navigator$clipboard, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n e.preventDefault();\n codeInput = _this2.input.querySelector('input[name=\"gift_card_code\"]');\n code = codeInput === null || codeInput === void 0 || (_codeInput$value = codeInput.value) === null || _codeInput$value === void 0 ? void 0 : _codeInput$value.trim();\n if (code) {\n _context.n = 1;\n break;\n }\n return _context.a(2);\n case 1:\n _context.p = 1;\n if (!((_navigator$clipboard = navigator.clipboard) !== null && _navigator$clipboard !== void 0 && _navigator$clipboard.writeText)) {\n _context.n = 3;\n break;\n }\n _context.n = 2;\n return navigator.clipboard.writeText(code);\n case 2:\n _context.n = 4;\n break;\n case 3:\n // Fallback (älter / restrictive browser)\n codeInput.removeAttribute('readonly'); // falls du es irgendwann readonly machst\n codeInput.focus();\n codeInput.select();\n codeInput.setSelectionRange(0, code.length);\n document.execCommand('copy');\n codeInput.blur();\n codeInput.setAttribute('readonly', 'readonly');\n case 4:\n _this2.input.classList.add('active');\n setTimeout(function () {\n return _this2.input.classList.remove('active');\n }, 2000);\n _context.n = 6;\n break;\n case 5:\n _context.p = 5;\n _t = _context.v;\n console.error('ð Copy failed:', _t);\n case 6:\n return _context.a(2);\n }\n }, _callee, null, [[1, 5]]);\n }));\n return function (_x) {\n return _ref.apply(this, arguments);\n };\n }());\n if (this.printButton) {\n this.printButton.addEventListener('click', function () {\n window.print();\n });\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('gift-card-section', GiftCard);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/giftCard.js?\n}"); 412 413/***/ }, 414 415/***/ "./dev/js/components/horizontalScroll.js" 416/*!***********************************************!*\ 417 !*** ./dev/js/components/horizontalScroll.js ***! 418 \***********************************************/ 419(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 420 421"use strict"; 422eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\n/* harmony import */ var _helper_isMobile__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../helper/isMobile */ \"./dev/js/helper/isMobile.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _createForOfIteratorHelper(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t[\"return\"] || t[\"return\"](); } finally { if (u) throw o; } } }; }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
422\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar HorizontalScroll = /*#__PURE__*/function (_HTMLElement) {\n function HorizontalScroll() {\n var _this;\n _classCallCheck(this, HorizontalScroll);\n _this = _callSuper(this, HorizontalScroll);\n _this._initialized = false;\n _this.initAnimation = _this.initAnimation.bind(_this);\n _this.onResize = _this.onResize.bind(_this);\n return _this;\n }\n _inherits(HorizontalScroll, _HTMLElement);\n return _createClass(HorizontalScroll, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.cacheElements();\n if (this._initialized) return;\n if (document.readyState === 'complete' || document.readyState === 'interactive') {\n this.initAnimation();\n } else {\n document.addEventListener('DOMContentLoaded', this.initAnimation, {\n once: true\n });\n }\n window.addEventListener('resize', this.onResize);\n }\n }, {\n key: \"disconnectedCallback\",\n value: function disconnectedCallback() {\n var _this2 = this;\n window.removeEventListener('resize', this.onResize);\n gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.getAll().forEach(function (trigger) {\n if (trigger.trigger === _this2.container || trigger.trigger === _this2.content) {\n trigger.kill();\n }\n });\n }\n }, {\n key: \"onResize\",\n value: function onResize() {\n gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.refresh();\n }\n }, {\n key: \"cacheElements\",\n value: function cacheElements() {\n this.container = this.querySelector('.horizontal-scroll__wrapper');\n this.content = this.querySelector('.horizontal-scroll__content');\n this.items = this.querySelectorAll('.horizontal-scroll__item');\n this.header = document.querySelector('navbar-component');\n this.headline = this.querySelector('.headline');\n this.button = this.querySelector('.button');\n }\n }, {\n key: \"getScroller\",\n value: function getScroller() {\n // If another section configured a custom scroller, reuse it\n var triggers = gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.getAll();\n var _iterator = _createForOfIteratorHelper(triggers),\n _step;
422\n try {\n for (_iterator.s(); !(_step = _iterator.n()).done;) {\n var t = _step.value;\n if (t.vars && t.vars.scroller) {\n return t.vars.scroller;\n }\n }\n } catch (err) {\n _iterator.e(err);\n } finally {\n _iterator.f();\n }\n return undefined; // default -> window\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n var _this$header,\n _this3 = this;\n if (this._initialized) return;\n if (!this.container || this.items.length === 0 || !this.content) return;\n this._initialized = true;\n var scroller = this.getScroller();\n var navHeight = (_this$header = this.header) !== null && _this$header !== void 0 && _this$header.offsetHeight ? this.header.offsetHeight + 1 : 0;\n var sectionWidth = this.content.scrollWidth;\n var viewportWidth = window.innerWidth;\n var leftOffset = this.getBoundingClientRect().left;\n var rawScrollDistance = sectionWidth - viewportWidth + leftOffset;\n var scrollDistance = Math.max(rawScrollDistance, 0);\n var endMultiplier = (0,_helper_isMobile__WEBPACK_IMPORTED_MODULE_2__.isMobile)() ? 2 : 1.5;\n var endMultiplierContainer = (0,_helper_isMobile__WEBPACK_IMPORTED_MODULE_2__.isMobile)() ? 0 : 400;\n var scrubValue = (0,_helper_isMobile__WEBPACK_IMPORTED_MODULE_2__.isMobile)() ? 1 : 2;\n var topHeight = (0,_helper_isMobile__WEBPACK_IMPORTED_MODULE_2__.isMobile)() ? 0 : 50;\n\n // â start offset: mobile fixed 150, desktop keeps old logic\n var startOffset = (0,_helper_isMobile__WEBPACK_IMPORTED_MODULE_2__.isMobile)() ? navHeight + topHeight - 250 : navHeight + topHeight - 250;\n\n // Pin wrapper\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(this.container, {\n scrollTrigger: {\n id: 'horizontal-wrapper',\n trigger: this.container,\n scroller: scroller,\n start: \"top+=\".concat(startOffset, \" top\"),\n end: \"+=\".concat(scrollDistance * endMultiplier + endMultiplierContainer),\n pin: true,\n invalidateOnRefresh: true\n //markers: true, // uncomment for debugging\n }\n });\n\n // Horizontal scroll\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(this.content, {\n x: -scrollDistance - leftOffset,\n ease: 'none',\n scrollTrigger: {\n id: 'horizontal-content',\n trigger: this.content,\n scroller: scroller,\n start: \"top center\",\n end: \"+=\".concat(scrollDistance * endMultiplier),\n scrub: scrubValue,\n invalidateOnRefresh: true\n //markers: true,\n }\n });\n\n // Reveal button near the end\n if (this.button) {\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.set(this.button, {\n opacity: 0,\n y: 40\n });\n gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.create({\n id: 'horizontal-button',\n trigger: this.content,\n scroller: scroller,\n start: function start() {\n return \"+=\".concat(scrollDistance * 0.8, \" top\");\n },\n end: \"+=100\",\n toggleActions: \"play none none reverse\",\n onEnter: function onEnter() {\n return gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(_this3.button, {\n opacity: 1,\n y: 0,\n duration: 0.5\n });\n },\n onLeaveBack: function onLeaveBack() {\n return gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(_this3.button, {\n opacity: 0,\n y: -20,\n duration: 0.5\n });\n },\n invalidateOnRefresh: true\n // markers: true,\n });\n }\n\n // Make sure ScrollTrigger recalculates everything once *all* triggers are present\n gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.refresh();\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('horizontal-scroll', HorizontalScroll);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/horizontalScroll.js?\n}"); 423 424/***/ }, 425 426/***/ "./dev/js/components/imageSlider.js" 427/*!******************************************!*\ 428 !*** ./dev/js/components/imageSlider.js ***! 429 \******************************************/ 430(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 431 432"use strict"; 433eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
433\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\n\nvar ImageSlider = /*#__PURE__*/function (_HTMLElement) {\n function ImageSlider() {\n var _this;\n _classCallCheck(this, ImageSlider);\n _this = _callSuper(this, ImageSlider);\n _this.carousel = null;\n return _this;\n }\n _inherits(ImageSlider, _HTMLElement);\n return _createClass(ImageSlider, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"].use([swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Navigation, swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Autoplay]);\n var desktopPerView = parseInt(this.dataset.desktopPerView || '4', 10);\n var swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this, {\n slidesPerView: 1,\n spaceBetween: 0,\n loop: false,\n navigation: {\n nextEl: 'next-button-component',\n prevEl: 'prev-button-component'\n },\n autoplay: {\n delay: 999999\n },\n breakpoints: {\n 720: {\n slidesPerView: desktopPerView\n }\n }\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('image-slider', ImageSlider);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/imageSlider.js?\n}"); 434 435/***/ }, 436 437/***/ "./dev/js/components/interestCalculator.js" 438/*!*************************************************!*\ 439 !*** ./dev/js/components/interestCalculator.js ***! 440 \*************************************************/ 441() { 442 443eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
443\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar InterestCalculator = /*#__PURE__*/function (_HTMLElement) {\n function InterestCalculator() {\n var _this;\n _classCallCheck(this, InterestCalculator);\n _this = _callSuper(this, InterestCalculator);\n _this.calculateInterest = _this.calculateInterest.bind(_this);\n _this.handleInputChange = _this.handleInputChange.bind(_this);\n return _this;\n }\n _inherits(InterestCalculator, _HTMLElement);\n return _createClass(InterestCalculator, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.addEventListeners();\n }\n }, {\n key: \"addEventListeners\",\n value: function addEventListeners() {\n var input = this.querySelector('input[type=\"text\"]'); // Ensure this matches your input type\n input.addEventListener('input', this.handleInputChange);\n }\n }, {\n key: \"handleInputChange\",\n value: function handleInputChange(event) {\n var value = parseFloat(event.target.value);\n // Update the principal based on input value and recalculate\n this.setAttribute('data-principal', value.toString());\n this.renderResults();\n // Display min investment notice if applicable\n var minInvestmentNotice = this.querySelector('.min-investment-notice');\n var maxInvestmentNotice = this.querySelector('.max-investment-notice');\n if (value < 250) {\n minInvestmentNotice.style.display = 'block';\n maxInvestmentNotice.style.display = 'none';\n } else if (value > 25000) {\n maxInvestmentNotice.style.display = 'block';\n minInvestmentNotice.style.display = 'none';\n } else {\n minInvestmentNotice.style.display = 'none';\n maxInvestmentNotice.style.display = 'none';\n }\n }\n }, {\n key: \"calculateInterest\",\n value: function calculateInterest(principal) {\n var interestRate = parseFloat(this.getAttribute('data-interest')) / 100;\n var additionalInterest = parseFloat(this.getAttribute('data-additional')) / 100;\n var discountRate = parseFloat(this.getAttribute('data-discount'));\n\n // Adjusting the calculation to add the \"discount\" as a bonus to the principal\n var effectivePrincipal = principal - principal * discountRate / 100;\n var totalInterestEarned = 0;\n var interestPerYear = [];\n for (var year = 1; year <= 5; year++) {\n // Interest is calculated on the effective principal each year, without compounding\n var interestForYear = principal * (year === 1 ? interestRate + additionalInterest : interestRate);\n totalInterestEarned += interestForYear;
443\n interestPerYear[year - 1] = interestForYear;\n }\n // The total amount after 5 years includes the effective principal plus the total interest earned\n var totalAmount = principal + totalInterestEarned;\n return {\n interestPerYear: interestPerYear,\n actualPayment: effectivePrincipal.toFixed(2),\n // Reflects the initial amount after applying the discount\n totalInterestEarned: totalInterestEarned.toFixed(2),\n totalAmount: totalAmount.toFixed(2)\n };\n }\n }, {\n key: \"renderResults\",\n value: function renderResults() {\n var principal = parseFloat(this.getAttribute('data-principal')) || 0;\n var _this$calculateIntere = this.calculateInterest(principal),\n interestPerYear = _this$calculateIntere.interestPerYear,\n actualPayment = _this$calculateIntere.actualPayment,\n totalInterestEarned = _this$calculateIntere.totalInterestEarned,\n totalAmount = _this$calculateIntere.totalAmount;\n var discount = actualPayment - principal;\n discount = discount.toFixed();\n this.querySelector('.old-payment').textContent = \"\\u20AC\".concat(principal);\n this.querySelector('.new-payment').textContent = \"\\u20AC\".concat(actualPayment);\n //this.querySelector('.total-interest').textContent = `â¬${totalInterestEarned}`;\n this.querySelector('.total-amount').textContent = \"\\u20AC\".concat(totalAmount);\n //this.querySelector('.discount').textContent = `â¬${discount}`;\n //this.querySelectorAll('.start-payment').textContent = `${principal}`;\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('interest-calculator', InterestCalculator);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/interestCalculator.js?\n}"); 444 445/***/ }, 446 447/***/ "./dev/js/components/klaviyoBirthday.js" 448/*!**********************************************!*\ 449 !*** ./dev/js/components/klaviyoBirthday.js ***! 450 \**********************************************/ 451() { 452 453eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
453\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar klaviyoBirthday = /*#__PURE__*/function (_HTMLElement) {\n function klaviyoBirthday() {\n var _this;\n _classCallCheck(this, klaviyoBirthday);\n _this = _callSuper(this, klaviyoBirthday);\n _this.init();\n return _this;\n }\n _inherits(klaviyoBirthday, _HTMLElement);\n return _createClass(klaviyoBirthday, [{\n key: \"init\",\n value: function init() {\n var _this2 = this;\n var button = this.querySelector('.button');\n var dateInput = this.querySelector('input[type=\"date\"]');\n if (button && dateInput) {\n button.addEventListener('click', function () {\n return _this2.saveBirthday(button, dateInput);\n });\n }\n }\n\n /**\n * Speichert das Geburtsdatum in Klaviyo\n */\n }, {\n key: \"saveBirthday\",\n value: function saveBirthday(button, dateInput) {\n if (!dateInput) return;\n var rawDate = dateInput.value; // YYYY-MM-DD Format\n if (!rawDate) {\n alert(\"Bitte ein Datum eingeben.\");\n return;\n }\n\n // Datum umformatieren zu MM/DD/YYYY\n var formattedDate = this.formatDate(rawDate);\n\n // E-Mail aus Dataset holen (muss vorher gesetzt sein)\n var userEmail = this.dataset.user;\n if (!userEmail) {\n console.error(\"Keine E-Mail-Adresse im Dataset gefunden!\");\n return;\n }\n console.log(\"Speichere Geburtstag für:\", userEmail);\n fetch('https://a.klaviyo.com/api/identify', {\n method: 'POST',\n headers: {\n accept: 'text/html',\n 'content-type': 'application/x-www-form-urlencoded'\n },\n body: new URLSearchParams({\n data: JSON.stringify({\n token: \"S88kdy\",\n // Dein Klaviyo Token\n properties: {\n \"$email\": userEmail,\n \"birthday\": formattedDate // Speichert Geburtstag in Klaviyo\n }\n })\n })\n }).then(function (res) {\n return res.json();\n }).then(function (res) {\n console.log(\"Geburtstag gespeichert:\", res);\n document.querySelector('.klaviyo-birthday__info').classList.add('active');\n button.setAttribute('disabled', true);\n dateInput.setAttribute('disabled', true);\n })[\"catch\"](function (err) {\n return console.error(\"Fehler beim Speichern:\", err);\n });\n }\n\n /**\n * Formatiert ein Datum von YYYY-MM-DD zu MM/DD/YYYY\n */\n }, {\n key: \"formatDate\",\n value: function formatDate(date) {\n var _date$split = date.split('-'),\n _date$split2 = _slicedToArray(_date$split, 3),\n year = _date$split2[0],\n month
453= _date$split2[1],\n day = _date$split2[2];\n return \"\".concat(month, \"/\").concat(day, \"/\").concat(year); // MM/DD/YYYY\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('klaviyo-birthday', klaviyoBirthday);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/klaviyoBirthday.js?\n}"); 454 455/***/ }, 456 457/***/ "./dev/js/components/langModal.js" 458/*!****************************************!*\ 459 !*** ./dev/js/components/langModal.js ***! 460 \****************************************/ 461() { 462 463eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar LangModal = /*#__PURE__*/function (_HTMLElement) {\n function LangModal() {\n var _this;\n _classCallCheck(this, LangModal);\n _this = _callSuper(this, LangModal);\n _this.countrySelect = _this.querySelector('.modal__content-left select');\n _this.langSelects = _this.querySelectorAll('.modal__content-right .select-wrapper');\n _this.langButtons = _this.querySelectorAll('.change-lang');\n _this.marketValueSpan = _this.querySelector('#market-value');\n _this.modal = document.getElementById('lang-modal');\n return _this;\n }\n _inherits(LangModal, _HTMLElement);\n return _createClass(LangModal, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n // Modal öffnet sich nicht mehr automatisch für neue Kunden.\n // Zum Reaktivieren einfach den Block wieder einkommentieren:\n //\n // const isThemePreview = window.location.search.includes('preview');\n // const isUsStore = window.location.hostname === 'us.got-bag.com';\n // if (!isUsStore && !this.getCookie('langModalSeen') && !Sh
463opify.designMode) {\n // this.openModal();\n // this.setCookie('langModalSeen', 'true', 365);\n // }\n\n this.setInitialSelection();\n this.setupCountryChangeListener();\n this.setupLanguageChangeListener();\n this.setupChangeLangButton();\n }\n\n // ----------------------------\n // Helpers\n // ----------------------------\n }, {\n key: \"getCookie\",\n value: function getCookie(name) {\n var match = document.cookie.match(new RegExp(\"(^| )\".concat(name, \"=([^;]+)\")));\n return match ? decodeURIComponent(match[2]) : null;\n }\n }, {\n key: \"setCookie\",\n value: function setCookie(name, value, days) {\n var expires = new Date(Date.now() + days * 864e5).toUTCString();\n document.cookie = \"\".concat(name, \"=\").concat(encodeURIComponent(value), \"; expires=\").concat(expires, \"; path=/\");\n }\n }, {\n key: \"openModal\",\n value: function openModal() {\n if (this.modal) this.modal.setAttribute('open', true);\n }\n }, {\n key: \"getPathSegments\",\n value: function getPathSegments() {\n return window.location.pathname.split('/').filter(Boolean);\n }\n }, {\n key: \"isLocaleSegment\",\n value: function isLocaleSegment(segment) {\n // erlaubt: \"fr\" oder \"fr-ch\" (case-insensitive)\n return /^([a-z]{2})(-[a-z]{2})?$/i.test(segment || '');\n }\n }, {\n key: \"parseLocaleFromPath\",\n value: function parseLocaleFromPath() {\n var segments = this.getPathSegments();\n\n // defaults\n var langCode = 'de';\n var countryCode = 'de';\n if (!segments.length) return {\n langCode: langCode,\n countryCode: countryCode\n };\n var first = segments[0];\n\n // \"fr\" oder \"fr-ch\"\n if (this.isLocaleSegment(first)) {\n var m = first.match(/^([a-z]{2})(?:-([a-z]{2}))?$/i);\n if (m) {\n langCode = (m[1] || 'de').toLowerCase();\n countryCode = (m[2] || 'de').toLowerCase();\n }\n }\n\n // Wenn nur Sprache ohne Land (z.B. \"/fr/...\"), interpretieren wir das als DE-Markt\n if (first && !first.includes('-') && first.length === 2) {\n countryCode = 'de';\n }\n return {\n langCode: langCode,\n countryCode: countryCode\n };\n }\n }, {\n key: \"getCountryOptionByCode\",\n value: function getCountryOptionByCode(code) {\n var _this$countrySelect;\n return ((_this$countrySelect = this.countrySelect) === null || _this$countrySelect === void 0 ? void 0 : _this$countrySelect.querySelector(\"option[data-code=\\\"\".concat(code, \"\\\"]\"))) || null;\n }\n }, {\n key: \"getVisibleLangSelect\",\n value: function getVisibleLangSelect() {\n // hidden kann bei euch als attribute hidden=\"true\" gesetzt sein\n // deshalb checken wir explizit auf [hidden=\"true\"]\n return this.querySelector(\".modal__content-right .select-wrapper:not([hidden='true']) select\");\n }\n }, {\n key: \"selectOptionByDataCode\",\n value: function selectOptionByDataCode(selectEl, dataCode) {\n if (!selectEl || !dataCode) return null;\n var option = selectEl.querySelector(\"option[data-code=\\\"\".concat(dataCode, \"\\\"]\"));\n if (!option) return null;\n selectEl.value = option.value;\n\n // Optional: Selected-Attribute für UI (auch wenn value reicht)\n selectEl.querySelectorAll('option').forEach(function (opt) {\n return opt.removeAttribute('selected');\n });\n option.setAttribute('selected', 'true');\n\n // Change triggern\n selectEl.dispatchEvent(new Event('change', {\n bubbles: true\n }));\n return option;\n }\n }, {\n key: \"showOnlyLangSelectForCountry\",\n value: function showOnlyLangSelectForCountry(countryValue) {\n this.langSelects.forEach(function (wrapper) {\n if (wrapper.getAttribute('data-lang') === countryValue) {\n wrapper.removeAttribute('hidden');\n } else {\n wrapper.setAttribute('hidden', true);\n }\n });\n }\n }, {\n key: \"updateLanguageButtons\",\n value: function updateLanguageButtons(selectedLang) {\n this.langButtons.forEach(function (btn) {\n btn.hidden = btn.dataset.buttonkey !== selectedLang;\n });\n }\n }, {\n key: \"removeLocalePrefixFromSegments\",\n value: function removeLocalePrefixFromSegments(segments) {\n if (!segments.length) return segments;\n if (this.isLocaleSegment(segments[0])) return segments.slice(1);\n return segments;\n }\n }, {\n key: \"buildNewUrl\",\n value: function buildNewUrl(_ref) {\n var selectedCountry = _ref.selectedCountry,\n selectedLang = _ref.selectedLang,\n newPath = _ref.newPath;\n var hasPath = typeof newPath === 'string' && newPath.length > 0;\n\n // US -> eigene Domain\n if (selectedCountry === 'us') {\n var base = 'https://us.got-bag.com';\n return hasPath ? \"\".concat(base, \"/\").concat(newPath) : \"\".concat(base, \"/\");\n }\n\n // DE + DE -> Root ohne Prefix\n if (selectedCountry === 'de' && selectedLang === 'de') {\n return hasPath ? \"/\".concat(newPath) : \"/\";\n }\n\n // DE + andere Sprache -> /fr oder /it (ohne trailing slash auf root)\n if (selectedCountry === 'de') {\n return hasPath ? \"/\".concat(selectedLang, \"/\").concat(newPath) : \"/\".concat(selectedLang);\n }\n\n // alle anderen Märkte -> /fr-ch (ohne trailing slash auf root)\n var prefix = \"\".concat(selectedLang, \"-\").concat(selectedCountry);\n return hasPath ? \"/\".concat(prefix, \"/\").concat(newPath) : \"/\".concat(prefix);\n }\n\n // ----------------------------\n // Initial selection\n // ----------------------------\n }, {\n key: \"setInitialSelection\",\n value: function setInitialSelection() {\
463n if (!this.countrySelect) return;\n var _this$parseLocaleFrom = this.parseLocaleFromPath(),\n langCode = _this$parseLocaleFrom.langCode,\n countryCode = _this$parseLocaleFrom.countryCode;\n var countryOption = this.getCountryOptionByCode(countryCode);\n\n // Land setzen (Select value nutzt bei euch den \"value\" Text, nicht data-code)\n if (countryOption) {\n this.countrySelect.value = countryOption.value;\n if (this.marketValueSpan) {\n this.marketValueSpan.textContent = countryOption.textContent.trim();\n }\n }\n\n // Passenden Sprach-Select sichtbar machen\n var selectedCountryValue = (countryOption === null || countryOption === void 0 ? void 0 : countryOption.value) || this.countrySelect.value;\n this.showOnlyLangSelectForCountry(selectedCountryValue);\n\n // Sprache im sichtbaren Dropdown wählen\n var visibleSelect = this.getVisibleLangSelect();\n if (visibleSelect) {\n var chosen = this.selectOptionByDataCode(visibleSelect, langCode);\n var selectedLang = (chosen === null || chosen === void 0 ? void 0 : chosen.getAttribute('data-code')) || langCode;\n this.updateLanguageButtons(selectedLang);\n } else {\n // Fallback: Buttons nach langCode\n this.updateLanguageButtons(langCode);\n }\n }\n\n // ----------------------------\n // Listeners\n // ----------------------------\n }, {\n key: \"setupCountryChangeListener\",\n value: function setupCountryChangeListener() {\n var _this2 = this;\n if (!this.countrySelect) return;\n this.countrySelect.addEventListener('change', function (event) {\n var selectedCountryValue = event.target.value;\n if (_this2.marketValueSpan) {\n _this2.marketValueSpan.textContent = event.target.selectedOptions[0].textContent.trim();\n }\n\n // passenden Wrapper zeigen\n _this2.showOnlyLangSelectForCountry(selectedCountryValue);\n\n // erste Sprache im jetzt sichtbaren Select auswählen\n var visibleSelect = _this2.getVisibleLangSelect();\n if (visibleSelect) {\n var firstOption = visibleSelect.querySelector('option:first-child');\n if (firstOption) {\n visibleSelect.value = firstOption.value;\n visibleSelect.querySelectorAll('option').forEach(function (opt) {\n return opt.removeAttribute('selected');\n });\n firstOption.setAttribute('selected', 'true');\n visibleSelect.dispatchEvent(new Event('change', {\n bubbles: true\n }));\n var firstLangCode = firstOption.getAttribute('data-code');\n if (firstLangCode) _this2.updateLanguageButtons(firstLangCode);\n }\n }\n });\n }\n }, {\n key: \"setupLanguageChangeListener\",\n value: function setupLanguageChangeListener() {\n var _this3 = this;\n this.langSelects.forEach(function (wrapper) {\n var selectEl = wrapper.querySelector('select');\n if (!selectEl) return;\n selectEl.addEventListener('change', function () {\n var _selectEl$options$sel;\n var selectedLangCode = (_selectEl$options$sel = selectEl.options[selectEl.selectedIndex]) === null || _selectEl$options$sel === void 0 ? void 0 : _selectEl$options$sel.getAttribute('data-code');\n if (selectedLangCode) _this3.updateLanguageButtons(selectedLangCode);\n });\n });\n }\n }, {\n key: \"setupChangeLangButton\",\n value: function setupChangeLangButton() {\n var _this4 = this;\n this.langButtons.forEach(function (button) {\n button.addEventListener('click', function () {\n var _this4$countrySelect;\n var selectedCountryOption = (_this4$countrySelect = _this4.countrySelect) === null || _this4$countrySelect === void 0 ? void 0 : _this4$countrySelect.querySelector('option:checked');\n var selectedCountry = selectedCountryOption === null || selectedCountryOption === void 0 ? void 0 : selectedCountryOption.getAttribute('data-code');\n var visibleSelect = _this4.getVisibleLangSelect();\n var selectedLangOption = visibleSelect === null || visibleSelect === void 0 ? void 0 : visibleSelect.querySelector('option:checked');\n var selectedLang = selectedLangOption === null || selectedLangOption === void 0 ? void 0 : selectedLangOption.getAttribute('data-code');\n if (!selectedCountry || !selectedLang) {\n console.error('Kein gültiges Land oder Sprache gewählt.');\n return;\n }\n var segments = _this4.getPathSegments();\n segments = _this4.removeLocalePrefixFromSegments(segments);\n var newPath = segments.join('/');\n var newUrl = _this4.buildNewUrl({\n selectedCountry: selectedCountry,\n selectedLang: selectedLang,\n newPath: newPath\n });\n newUrl += window.location.search + window.location.hash;\n window.location.href = newUrl;\n });\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('lang-modal', LangModal);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/langModal.js?\n}"); 464 465/***/ }, 466 467/***/ "./dev/js/components/locksmithForm.js" 468/*!********************************************!*\ 469 !*** ./dev/js/components/locksmithForm.js ***! 470 \********************************************/ 471() { 472 473eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
473\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar LocksmithForm = /*#__PURE__*/function (_HTMLElement) {\n function LocksmithForm() {\n _classCallCheck(this, LocksmithForm);\n return _callSuper(this, LocksmithForm);\n }\n _inherits(LocksmithForm, _HTMLElement);\n return _createClass(LocksmithForm, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var form = document.getElementById('locksmith-passcode-form');\n if (!form) {\n console.warn('#locksmith-passcode-form nicht gefunden');\n return;\n }\n this.appendChild(form);\n var htmlLang = document.documentElement.lang;\n var langCode = (htmlLang || navigator.language || 'en').slice(0, 2).toLowerCase();\n var buttonTexts = {\n de: 'Fortfahren',\n fr: 'Continuer',\n it: 'Continua',\n en: 'Continue'\n };\n var placeholderTexts = {\n de: 'Passwort',\n fr: 'Mot de passe',\n it: 'Password',\n en: 'Password'\n };\n var btn = this.querySelector('.default');\n if (btn) {\n btn.textContent = buttonTexts[langCode] || buttonTexts.en;\n } else {\n console.warn('Kein Element mit .default gefunden');\n }\n var input = this.querySelector('input');\n if (input) {\n input.setAttribute('placeholder', placeholderTexts[langCode] || placeholderTexts.en);\n } else {\n console.warn('Kein <input> im Formular gefunden');\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('locksmith-form', LocksmithForm);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/locksmithForm.js?\n}"); 474 475/***/ }, 476 477/***/ "./dev/js/components/logoSlider.js" 478/*!*****************************************!*\ 479 !*** ./dev/js/components/logoSlider.js ***! 480 \*****************************************/ 481(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 482 483"use strict"; 484eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
484\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\n\nvar LogoSlider = /*#__PURE__*/function (_HTMLElement) {\n function LogoSlider() {\n var _this;\n _classCallCheck(this, LogoSlider);\n _this = _callSuper(this, LogoSlider);\n _this.carousel = null;\n return _this;\n }\n _inherits(LogoSlider, _HTMLElement);\n return _createClass(LogoSlider, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"].use([swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Navigation, swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Autoplay]);\n var swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this, {\n slidesPerView: 2,\n spaceBetween: 20,\n loop: true,\n cssMode: true,\n rewind: true,\n navigation: {\n nextEl: '.swiper-button-next',\n prevEl: '.swiper-button-prev'\n },\n autoplay: {\n delay: 2000\n },\n breakpoints: {\n 720: {\n slidesPerView: 3\n },\n 1000: {\n slidesPerView: 6\n }\n }\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('logo-slider', LogoSlider);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/logoSlider.js?\n}"); 485 486/***/ }, 487 488/***/ "./dev/js/components/multiOption.js" 489/*!******************************************!*\ 490 !*** ./dev/js/components/multiOption.js ***! 491 \******************************************/ 492() { 493 494eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
494\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar MultiOption = /*#__PURE__*/function (_HTMLElement) {\n function MultiOption() {\n var _this;\n _classCallCheck(this, MultiOption);\n _this = _callSuper(this, MultiOption);\n _this.inputs = _this.querySelectorAll('input[data-bind-value]');\n return _this;\n }\n _inherits(MultiOption, _HTMLElement);\n return _createClass(MultiOption, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n this.inputs.forEach(function (input) {\n input.addEventListener('change', _this2.updateSelectWrappers.bind(_this2));\n });\n this.updateSelectWrappers(); // Initial call to set the correct state on page load\n }\n }, {\n key: \"updateSelectWrappers\",\n value: function updateSelectWrappers() {\n var selectedIds = Array.from(this.inputs).filter(function (input) {\n return input.checked;\n }).map(function (input) {\n return input.getAttribute('data-bind-value');\n });\n var selectWrappers = document.querySelectorAll('.select-wrapper.multi--option');\n selectWrappers.forEach(function (wrapper) {\n if (selectedIds.includes(wrapper.getAttribute('data-multioption'))) {\n wrapper.classList.add('active');\n } else {\n wrapper.classList.remove('active');\n }\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('multi-option', MultiOption);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/multiOption.js?\n}"); 495 496/***/ }, 497 498/***/ "./dev/js/components/navbar.js" 499/*!*************************************!*\ 500 !*** ./dev/js/components/navbar.js ***! 501 \*************************************/ 502() { 503 504eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
504\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar Navbar = /*#__PURE__*/function (_HTMLElement) {\n function Navbar() {\n var _this;\n _classCallCheck(this, Navbar);\n _this = _callSuper(this, Navbar);\n _this.component = _this;\n _this.height = _this.offsetHeight;\n _this.root = document.documentElement;\n _this.toggles = _this.querySelectorAll('[data-toggle]');\n _this.navMobile = document.querySelector('subnav-mobile-component');\n _this.navMobileSecondLvl = document.querySelectorAll('subnav-secondlvl-component');\n _this.subNavDesktop = document.querySelectorAll('subnav-desktop-component');\n _this.burger = _this.querySelector('.nav-icon');\n _this.navClose = _this.querySelector('.close');\n _this.openSecondlvl = _this.navMobile.querySelectorAll('[data-toggle]');\n _this.closeSecondlvl = _this.navMobile.querySelectorAll('subnav-secondlvl-component .top');\n _this.headerVeil = document.querySelector('header-veil-component');\n _this.navMobileAnimate = _this.navMobile.querySelector('.animate');\n _this.announcementBar = document.querySelector('announcement-bar-v2');\n _this.actionBar = document.querySelector('action-bar-component');\n _this.subNavVeil = document.querySelector('subnav-veil-component');\n return _this;\n }\n _inherits(Navbar, _HTMLElement);\n return _createClass(Navbar, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.setNavHeight();
504\n this.openSubnavDesktop();\n this.toggleNavMobile();\n this.openNavMobileSecondlvl();\n this.closeNavMobileSecondlvl();\n this.transparentTheme();\n }\n }, {\n key: \"setNavHeight\",\n value: function setNavHeight() {\n this.root.style.setProperty('--navbar-height', this.height + 'px');\n var actionBarHeight = 0;\n var bg = getComputedStyle(this).backgroundColor;\n var isActuallyTransparent = bg === 'rgba(0, 0, 0, 0)';\n if (this.actionBar) {\n actionBarHeight = this.actionBar.offsetHeight - 1;\n }\n if (!isActuallyTransparent) {\n this.root.style.setProperty('--content-margin', this.height + actionBarHeight + this.announcementBar.offsetHeight + 'px');\n } else {\n this.root.style.setProperty('--content-margin', \"0px\");\n }\n }\n }, {\n key: \"toggleNavMobile\",\n value: function toggleNavMobile() {\n var _this2 = this;\n this.burger.addEventListener('click', function () {\n _this2.root.style.overflow = 'hidden';\n _this2.component.setAttribute('open-mobile', '');\n _this2.navMobile.setAttribute('open', '');\n _this2.root.style.setProperty('--announcement-bar-height', '0px');\n });\n this.navClose.addEventListener('click', function () {\n var hasScrolled = false;\n window.addEventListener('scroll', function () {\n if (window.scrollY > 0) hasScrolled = true;\n });\n if (!hasScrolled && window.scrollY === 0) {\n _this2.root.style.setProperty('--announcement-bar-height', \"\".concat(_this2.announcementBar.offsetHeight, \"px\"));\n }\n _this2.component.removeAttribute('open-mobile');\n _this2.navMobile.removeAttribute('open');\n _this2.navMobileAnimate.removeAttribute('hide');\n _this2.navMobileSecondLvl.forEach(function (nav) {\n nav.removeAttribute('open');\n });\n _this2.root.style.overflow = '';\n });\n }\n }, {\n key: \"openNavMobileSecondlvl\",\n value: function openNavMobileSecondlvl() {\n this.openSecondlvl.forEach(function (toggleEl) {\n toggleEl.addEventListener('click', function (event) {\n var key = toggleEl.getAttribute('data-toggle');\n var target = document.querySelector(\"subnav-secondlvl-component[data-open=\\\"\".concat(key, \"\\\"]\"));\n if (target.hasAttribute('open')) {\n event.target.closest('.animate').removeAttribute('hide');\n target.removeAttribute('open');\n } else {\n event.target.closest('.animate').setAttribute('hide', '');\n target.setAttribute('open', '');\n }\n });\n });\n }\n }, {\n key: \"closeNavMobileSecondlvl\",\n value: function closeNavMobileSecondlvl() {\n var _this3 = this;\n this.closeSecondlvl.forEach(function (toggleEl) {\n toggleEl.addEventListener('click', function (event) {\n _this3.navMobileSecondLvl.forEach(function (element) {\n element.removeAttribute('open');\n });\n _this3.navMobileAnimate.removeAttribute('hide');\n });\n });\n }\n }, {\n key: \"openSubnavDesktop\",\n value: function openSubnavDesktop() {\n var _this4 = this;\n this.toggles.forEach(function (toggleEl) {\n var key = toggleEl.getAttribute('data-toggle');\n var target = document.querySelector(\"[data-open=\\\"\".concat(key, \"\\\"]\"));\n if (!target) return;\n toggleEl.addEventListener('mouseenter', function () {\n target.setAttribute('open', '');\n _this4.headerVeil.setAttribute('open', '');\n _this4.subNavVeil.setAttribute('open', '');\n _this4.component.setAttribute('open', '');\n });\n toggleEl.addEventListener('mouseleave', function () {\n target.removeAttribute('open');\n _this4.headerVeil.removeAttribute('open');\n _this4.subNavVeil.removeAttribute('open');\n _this4.component.removeAttribute('open');\n });\n target.addEventListener('mouseenter', function () {\n target.setAttribute('open', '');\n _this4.headerVeil.setAttribute('open', '');\n _this4.subNavVeil.setAttribute('open', '');\n _this4.component.setAttribute('open', '');\n });\n target.addEventListener('mouseleave', function () {\n target.removeAttribute('open');\n _this4.headerVeil.removeAttribute('open');\n _this4.subNavVeil.removeAttribute('open');\n _this4.component.removeAttribute('open');\n });\n });\n }\n }, {\n key: \"transparentTheme\",\n value: function transparentTheme(
504) {\n var _this5 = this;\n this.subNavDesktop.forEach(function (el) {\n el.addEventListener('mouseenter', function () {\n _this5.setAttribute('open', '');\n });\n el.addEventListener('mouseleave', function () {\n _this5.removeAttribute('open');\n });\n });\n\n // das Header-Veil\n if (this.headerVeil) {\n this.headerVeil.addEventListener('mouseenter', function () {\n _this5.setAttribute('open', '');\n });\n this.headerVeil.addEventListener('mouseleave', function () {\n _this5.removeAttribute('open');\n });\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('navbar-component', Navbar);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/navbar.js?\n}"); 505 506/***/ }, 507 508/***/ "./dev/js/components/nudge.js" 509/*!************************************!*\ 510 !*** ./dev/js/components/nudge.js ***! 511 \************************************/ 512() { 513 514eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar Nudge = /*#__PURE__*/function (_HTMLElement) {\n function Nudge() {\n var _this;\n _classCallCheck(this, Nudge);\n _this = _callSuper(this, Nudge);\n _this.close = _this.close.bind(_this);\n _this.startAnimation = _this.startAnimation.bind(_this);\n _this.observer = null;\n return _this;\n }\n _inherits(Nudge, _HTMLElement);\n return _createClass(Nudge, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n // Set an initial style with display none\n this.classList.add('product-nudge-enter');\n\n // Initialize Intersection Observer\n this.observer = new IntersectionObserver(function (entries) {\n // The callback will execute when the element is observed to enter or exit the viewport\n entr
514ies.forEach(function (entry) {\n if (entry.isIntersecting) {\n // Start the animation only when the element is visible in the viewport\n _this2.startAnimation();\n // Stop observing the element after the animation has started\n _this2.observer.unobserve(_this2);\n }\n });\n }, {\n threshold: 0.1 // This means the callback will execute when at least 10% of the target is visible\n });\n\n // Start observing this element\n this.observer.observe(this);\n\n // Add event listener for the close button\n this.querySelector('.close').addEventListener('click', this.close);\n }\n }, {\n key: \"disconnectedCallback\",\n value: function disconnectedCallback() {\n var _this$querySelector, _this$observer;\n // Clean up the event listener when the element is removed\n (_this$querySelector = this.querySelector('.close')) === null || _this$querySelector === void 0 || _this$querySelector.removeEventListener('click', this.close);\n // Disconnect the observer if it's still observing\n (_this$observer = this.observer) === null || _this$observer === void 0 || _this$observer.disconnect();\n }\n }, {\n key: \"startAnimation\",\n value: function startAnimation() {\n var _this3 = this;\n setTimeout(function () {\n _this3.classList.add('show');\n }, 2000);\n }\n }, {\n key: \"close\",\n value: function close() {\n // You can also add an animation for fading out if you like\n this.remove();\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('product-nudge', Nudge);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/nudge.js?\n}"); 515 516/***/ }, 517 518/***/ "./dev/js/components/outlet.js" 519/*!*************************************!*\ 520 !*** ./dev/js/components/outlet.js ***! 521 \*************************************/ 522() { 523 524eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
524 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar Outlet = /*#__PURE__*/function (_HTMLElement) {\n function Outlet() {\n var _this;\n _classCallCheck(this, Outlet);\n _this = _callSuper(this, Outlet);\n\n // alle relevanten Elemente sammeln\n _this.buttons = _this.querySelectorAll('button[data-outlet]');\n _this.infoTexts = _this.querySelectorAll('[data-text]');\n _this.items = _this.querySelectorAll('product-card-component');\n _this.noResult = _this.querySelector('.no-result');\n _this.grid = _this.querySelector('.product-grid');\n _this.activeFilter = '*';\n return _this;\n }\n _inherits(Outlet, _HTMLElement);\n return _createClass(Outlet, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n // Button Events\n this.buttons.forEach(function (button) {\n button.addEventListener('click', function () {\n _this2.activeFilter = button.getAttribute('data-outlet');\n _this2.updateActiveButton(button);\n _this2.updateInfoText();\n _this2.applyFilters();\n });\n });\n\n // Standard: erster Button aktiv\n if (this.buttons.length > 0) {\n var firstButton = this.buttons[0];\n this.activeFilter = firstButton.getAttribute('data-outlet');\n this.updateActiveButton(firstButton);\n this.updateInfoText();\n this.applyFilters();\n }\n }\n }, {\n key: \"updateActiveButton\",\n value: function updateActiveButton(activeBtn) {\n this.buttons.forEach(function (btn) {\n btn.classList.toggle('active', btn === activeBtn);\n // Optional: If you want to follow accessibility standards used in your other tabs:\n btn.setAttribute('aria-expanded', btn === activeBtn ? 'true' : 'false');\n });\n }\n }, {\n key: \"updateInfoText\",\n value: function updateInfoText() {\n this.infoTexts.forEach(function (el) {\n return el.hidden = true;\n });\n if (this.activeFilter !== '*') {\n var infoEl = this.querySelector(\"[data-text=\\\"\".concat(this.activeFilter, \"\\\"]\"));\n if (infoEl) infoEl.hidden = false;\n }\n }\n }, {\n key: \"applyFilters\",\n value: function applyFilters() {\n var _this3 = this;\n var visibleCount = 0;\n this.items.forEach(function (item) {\n var parent = item.closest('animation-reveal') || item.parentElement;\n var filters = [];\n try {\n var raw = item.getAttribute('data-filters') || '[]';\n filters = raw.replace(/^\\[|\\]$/g, '').replace(/['\"]+/g, '').split(',').map(function (f) {\n return f.trim();\n }).filter(function (f) {\n return f.length > 0;\n });\n } catch (e) {\n console.error('Filter parsing error', e);\n }\n var matches = _this3.activeFilter === '*' || filters.includes(_this3.activeFilter);\n if (matches) {\n item.parentElement.removeAttribute('hidden');\n if (parent) parent.classList.add('active');\n visibleCount++;\n } else {\n item.parentElement.setAttribute('hidden', '');\n if (parent) parent.classList.remove('active');\n }\n });\n if (this.noResult) this.noResult.hidden = visibleCount > 0;\n if (this.grid) this.grid.hidden = visibleCount === 0;\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('outlet-section', Outlet);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/outlet.js?\n}"); 525 526/***/ }, 527 528/***/ "./dev/js/components/pauseButton.js" 529/*!******************************************!*\ 530 !*** ./dev/js/components/pauseButton.js ***! 531 \******************************************/ 532() { 533 534eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
534\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar PauseButton = /*#__PURE__*/function (_HTMLElement) {\n function PauseButton() {\n _classCallCheck(this, PauseButton);\n return _callSuper(this, PauseButton);\n }\n _inherits(PauseButton, _HTMLElement);\n return _createClass(PauseButton, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this = this;\n var btn = this.querySelector('.pause-button, .pause-button__fancybox-slider');\n var playicon = this.querySelector('.icon-play');\n var pauseicon = this.querySelector('.icon-pause');\n if (!btn) return;\n btn.addEventListener('click', function () {\n var video = _this.parentElement.querySelector('video');\n if (!video) return;\n if (video.paused) {\n video.play();\n playicon.classList.add(\"hidden\");\n pauseicon.classList.remove(\"hidden\");\n } else {\n video.pause();\n playicon.classList.remove(\"hidden\");\n pauseicon.classList.add(\"hidden\");\n }\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"pause-button\", PauseButton);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/pauseButton.js?\n}"); 535 536/***/ }, 537 538/***/ "./dev/js/components/plasticCounter.js" 539/*!*********************************************!*\ 540 !*** ./dev/js/components/plasticCounter.js ***! 541 \*********************************************/ 542(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 543 544"use strict"; 545eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\n/* harmony import */ var odometer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! odometer */ \"./node_modules/odometer/odometer.js\");\n/* harmony import */ var odometer__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(odometer__WEBPACK_IMPORTED_MODULE_2__);\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
545 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
545 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n// Import GSAP and ScrollTrigger\n\n\n\n// Import Odometer library\n\n\n// Register the ScrollTrigger plugin with GSAP\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar PlasticCounter = /*#__PURE__*/function (_HTMLElement) {\n function PlasticCounter() {\n _classCallCheck(this, PlasticCounter);\n return _callSuper(this, PlasticCounter);\n }\n _inherits(PlasticCounter, _HTMLElement);\n return _createClass(PlasticCounter, [{\n key: \"connectedCallback\",\n value: function () {\n var _connectedCallback = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var weight, response, data, odometerElement, odometer, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n _context.p = 0;\n _context.n = 1;\n return fetch('https://gotbag-intern.got-bag.com/plastictracker/tracker.json');\n case 1:\n response = _context.v;\n _context.n = 2;\n return response.json();\n case 2:\n data = _context.v;\n // Use the fetched value\n weight = Math.floor(data.now);\n _context.n = 4;\n break;\n case 3:\n _context.p = 3;\n _t = _context.v;\n console.error('Fetch failed, using fallback value:', _t);\n\n // Fallback static value for testing\n weight = 1200000; // Set any fallback value here\n case 4:\n // Convert to lbs if the attribute specifies it\n if (this.getAttribute('data-format') === 'lbs') {\n weight = weight * 2.20462; // Convert kg to lbs if needed\n }\n\n // Set initial HTML with Odometer element\n this.innerHTML = \"\\n <div class=\\\"h1 heading\\\">\\n <div id=\\\"odometer\\\" class=\\\"odometer\\\">0</div> <!-- Odometer starts at 0 -->\\n \".concat(this.getAttribute('data-format') === 'lbs' ? 'lbs' : 'kg', \"\\n </div>\\n \");\n\n // Initialize Odometer on the element\n odometerElement = this.querySelector('#odometer');\n odometer = new (odometer__WEBPACK_IMPORTED_MODULE_2___default())({\n el: odometerElement,\n duration: 100,\n value: 0,\n // Set initial value to 0 for the animation start point\n format: '(.ddd)',\n // Format number with dot\n theme: 'train-station' // Use the default theme (you can change this if you imported a different theme)\n }); // Use GSAP ScrollTrigger to update the Odometer when in view\n gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.create({\n trigger: this,\n // Trigger when this element is in view\n start: 'top 80%',\n // Adjust start based on when you want the trigger to activate\n once: true,\n // Trigger only once\n onEnter: function onEnter() {\n // Update the odometer value when the element enters the viewport\n odometer.update(Math.floor(weight));\n }\n });\n case 5:\n return _context.a(2);\n }\n }, _callee, this, [[0, 3]]);\n }));\n function connectedCallback() {\n return _connectedCallback.apply(this, arguments);\n }\n return connectedCallback;\n }()\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\ncustomElements.define('plastic-counter', PlasticCounter);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/plasticCounter.js?\n}"); 546 547/***/ }, 548 549/***/ "./dev/js/components/product/giftCardOptions.js" 550/*!******************************************************!*\ 551 !*** ./dev/js/components/product/giftCardOptions.js ***! 552 \******************************************************/ 553(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 554 555"use strict"; 556eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_formatPrice__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../helper/formatPrice */ \"./dev/js/helper/formatPrice.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
556\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\nvar GiftCardOptions = /*#__PURE__*/function (_HTMLElement) {\n function GiftCardOptions() {\n _classCallCheck(this, GiftCardOptions);\n return _callSuper(this, GiftCardOptions, arguments);\n }\n _inherits(GiftCardOptions, _HTMLElement);\n return _createClass(GiftCardOptions, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this = this;\n this.variants = JSON.parse(this.getAttribute('data-variants') || '[]');\n this.currentOption1 = this.getAttribute('data-option1');\n this.currentOption2 = this.getAttribute('data-option2');\n this.querySelectorAll('.gift-card-price-option').forEach(function (item) {\n item.addEventListener('click', function () {\n _this.querySelectorAll('.gift-card-price-option').forEach(function (i) {\n return i.classList.remove('active');\n });\n item.classList.add('active');\n _this.currentOption1 = item.getAttribute('data-value');\n var selectedSpan = _this.querySelector('dropdown-component .selected > span');\n if (selectedSpan) selectedSpan.textContent = item.querySelector('span').textContent;\n _this.selectVariant();\n });\n });\n this.querySelectorAll('.image-swatch').forEach(function (swatch) {\n swatch.addEventListener('click', function () {\n _this.querySelectorAll('.image-swatch').forEach(function (s) {\n return s.classList.remove('active');\n });\n swatch.classList.add('active');\n _this.currentOption2 = swatch.getAttribute('data-value');\n _this.selectVariant();\n });\n });\n }\n }, {\n key: \"selectVariant\",\n value: function selectVariant() {\n var _this2 = this;\n var variant = this.variants.find(function (v) {\n var option1Match = String(v.option1) === _this2.currentOption1;\n if (!_this2.currentOption2) return option1Match;\n return option1Match && String(v.option2) === _this2.currentOption2;\n });\n if (!variant) return;\n var variantId = String(variant.id);\n var productPage = this.closest('product-page-component');\n if (!productPage) return;\n var atc = productPage.querySelector('add-to-cart[data-target-variant-id]');\n if (atc) {\n atc.setAttribute('variant-id', variantId);\n atc.value = variantId;\n atc.toggleAttribute('disabled', !variant.available);\n }\n var bis = productPage.querySelector('#back-in-stock-container');\n if (bis) {\n bis.setAttribute('variant-id', variantId);\n bis.value = variantId;\n bis.toggleAttribute('hidden', variant.available);\n }\n var currency = document.documentElement.getAttribute('currency') || '';\n var priceEl = productPage.querySelector('[data-target-price]');\n if (priceEl) priceEl.textContent = (0,_helper_formatPrice__WEBPACK_IMPORTED_MODULE_0__.formatPrice)(variant.price) + ' ' + currency;\n var comparePriceEl = productPage.querySelector('[data-target-compare_at_price]');\n if (comparePriceEl) {\n if (variant.compare_at_price && variant.compare_at_price > variant.price) {\n comparePriceEl.textContent = (0,_helper_formatPrice__WEBPACK_IMPORTED_MODULE_0__.formatPrice)(variant.compare_at_price) + ' ' + currency;\n comparePriceEl.removeAttribute('hidden');\n } else {\n comparePriceEl.setAttribute('hidden', true);\n }\n }\n productPage.querySelectorAll('[data-variant]').forEach(function (el) {\n el.toggleAttribute('hidden', el.getAttribute('data-variant') !== variantId);\n });\n var images = productPage.querySelector('product-page-images');\n if (images && typeof images.resetToFirstVisibleSlide === 'function') {\n images.resetToFirstVisibleSlide(variantId);\n }\n var url = new URL(window.location.href);\n url.searchParams.set('variant', variantId);\n window.history.replaceState({}, '', url.toString());\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\ncustomElements.define('gift-card-options', GiftCardOptions);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/product/giftCardOptions.js?\n}"); 557 558/***/ }, 559 560/***/ "./dev/js/components/product/images.js" 561/*!*********************************************!*\ 562 !*** ./dev/js/components/product/images.js ***! 563 \*********************************************/ 564(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 565 566"use strict"; 567eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var _helper_isMobile__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../helper/isMobile */ \"./dev/js/helper/isMobile.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
567\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n// WICHTIG: Falls du Swiper über NPM nutzt, musst du zwingend das Core-CSS importieren!\n// import 'swiper/css';\n\nvar ProductPageImages = /*#__PURE__*/function (_HTMLElement) {\n function ProductPageImages() {\n var _this;\n _classCallCheck(this, ProductPageImages);\n _this = _callSuper(this, ProductPageImages);\n _this.swiperContainer = null;\n _this.swiperWrapper = null;\n _this.swiper = null;\n _this.currentMobileState = null;\n _this.resizeTimer = null;\n _this.minCounter = null;\n _this.maxCounter = null;\n\n // NEU: Speichert ALLE Slides einmalig sicher im Arbeitsspeicher ab\n _this.allSlides = [];\n _this.handleResize = _this.handleResize.bind(_this);\n return _this;\n }\n _inherits(ProductPageImages, _HTMLElement);\n return _createClass(ProductPageImages, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.swiperContainer = this.querySelector('.swiper');\n this.swiperWrapper = this.querySelector('.swiper-wrapper');\n this.minCounter = this.querySelector('.counter .min');\n this.maxCounter = this.querySelector('.counter .max');\n if (!this.swiperContainer || !this.swiperWrapper) return;\n\n // 1. Alle Slides beim Laden als Array sichern (inkl. der unsichtbaren)\n this.allSlides = Array.from(this.querySelectorAll('.swiper-slide'));\n\n // 2. DOM initial aufräumen: Versteckte Slides rauswerfen\n this.filterDOM();\n this.updateSlider((0,_helper_isMobile__WEBPACK_IMPORTED_MODULE_1__.isMobile)());\n this.initVideos();\n window.addEventListener('resize', this.handleResize, {\n passive: true\n });\n }\n\n // Deaktiviert die nativen Video-Controls im pausierten Zustand, da die
567se sonst\n // Touch-Events \"schlucken\" und das Swipen im Slider blockieren (siehe videoSlider.js)\n }, {\n key: \"initVideos\",\n value: function initVideos() {\n this.allSlides.forEach(function (slide) {\n var video = slide.querySelector('video');\n if (!video) return;\n var playButton = slide.querySelector('.play-button');\n video.addEventListener('play', function () {\n video.controls = true;\n if (playButton) playButton.setAttribute('hidden', true);\n });\n video.addEventListener('pause', function () {\n video.controls = false;\n if (playButton) playButton.removeAttribute('hidden');\n });\n if (playButton) {\n playButton.addEventListener('click', function () {\n return video.play();\n });\n }\n });\n }\n }, {\n key: \"disconnectedCallback\",\n value: function disconnectedCallback() {\n window.removeEventListener('resize', this.handleResize);\n if (this.swiper) this.swiper.destroy(true, true);\n }\n }, {\n key: \"handleResize\",\n value: function handleResize() {\n var _this2 = this;\n clearTimeout(this.resizeTimer);\n this.resizeTimer = setTimeout(function () {\n var mobile = (0,_helper_isMobile__WEBPACK_IMPORTED_MODULE_1__.isMobile)();\n if (mobile !== _this2.currentMobileState) {\n _this2.updateSlider(mobile);\n }\n }, 150);\n }\n }, {\n key: \"updateSlider\",\n value: function updateSlider(mobile) {\n this.currentMobileState = mobile;\n if (mobile && !this.swiper) {\n this.initSwiper();\n } else if (!mobile && this.swiper) {\n this.swiper.destroy(true, true);\n this.swiper = null;\n }\n }\n }, {\n key: \"initSwiper\",\n value: function initSwiper() {\n var _this3 = this;\n this.swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.swiperContainer, {\n slidesPerView: 'auto',\n spaceBetween: 0,\n observer: true,\n observeParents: true,\n on: {\n init: function init(swiper) {\n return _this3.updateCounter(swiper);\n },\n slideChange: function slideChange(swiper) {\n _this3.updateCounter(swiper);\n _this3.preloadNextSlide(swiper);\n }\n }\n });\n }\n }, {\n key: \"preloadNextSlide\",\n value: function preloadNextSlide(swiper) {\n if (!swiper || swiper.destroyed) return;\n var slides = this.swiperWrapper.querySelectorAll('.swiper-slide');\n var nextSlide = slides[swiper.activeIndex + 1];\n if (!nextSlide) return;\n nextSlide.querySelectorAll('img[loading=\"lazy\"]').forEach(function (img) {\n img.loading = 'eager';\n });\n }\n\n // NEU: Filtert die Slides sauber, indem sie physisch hinzugefügt/entfernt werden\n }, {\n key: \"filterDOM\",\n value: function filterDOM() {\n var _this4 = this;\n var activeVariantId = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;\n if (!this.swiperWrapper) return;\n\n // Den Slider-Container im HTML komplett leeren\n this.swiperWrapper.innerHTML = '';\n\n // Nur die Slides einfügen, die zur aktiven Variante gehören\n this.allSlides.forEach(function (slide) {\n // Wenn eine ID übergeben wurde, steuern wir das 'hidden' Attribut direkt hier\n if (activeVariantId) {\n if (slide.getAttribute('data-variant') === activeVariantId) {\n slide.removeAttribute('hidden');\n } else {\n slide.setAttribute('hidden', true);\n }\n }\n\n // Alles was KEIN hidden hat, darf zurück ins sichtbare HTML\n if (!slide.hasAttribute('hidden')) {\n _this4.swiperWrapper.appendChild(slide);\n }\n });\n }\n }, {\n key: \"updateCounter\",\n value: function updateCounter(swiper) {\n if (!this.minCounter || !swiper || swiper.destroyed) return;\n\n // Da keine unsichtbaren Slides mehr im HTML existieren,\n // ist der interne Swiper-Index zu 100 % deckungsgleich mit der Bildnummer!\n this.minCounter.innerHTML = swiper.activeIndex + 1;\n }\n }, {\n key: \"resetToFirstVisibleSlide\",\n value: function resetToFirstVisibleSlide(variantId) {\n if (!this.swiperContainer) return;\n\n // 1. Physisch nur die neuen Bilder der angeklickten Variante ins HTML laden\n this.filterDOM(variantId);\n var visibleSlides = this.swiperWrapper.querySelectorAll('.swiper-slide').length;\n this.maxCounter.innerHTML = visibleSlides;\n\n // 2. Swiper updaten\n if (this.swiper) {\n this.swiper.update(
567);\n // Da alle unpassenden Bilder rausgeworfen wurden, ist Index 0 garantiert das erste Bild der Variante!\n this.swiper.slideTo(0, 0, false);\n }\n\n // 3. Counter aktualisieren\n this.updateCounter(this.swiper);\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('product-page-images', ProductPageImages);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/product/images.js?\n}"); 568 569/***/ }, 570 571/***/ "./dev/js/components/product/page.js" 572/*!*******************************************!*\ 573 !*** ./dev/js/components/product/page.js ***! 574 \*******************************************/ 575(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 576 577"use strict"; 578eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\n/* harmony import */ var _helper_isMobile__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../helper/isMobile */ \"./dev/js/helper/isMobile.js\");\n/* harmony import */ var _helper_formatPrice__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../helper/formatPrice */ \"./dev/js/helper/formatPrice.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
578\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar ProductPage = /*#__PURE__*/function (_HTMLElement) {\n function ProductPage() {\n var _this;\n _classCallCheck(this, ProductPage);\n _this = _callSuper(this, ProductPage);\n _this.images = _this.querySelector('product-page-images');\n _this.info = _this.querySelector('product-page-info');\n _this.addons = _this.querySelector('product-addons-component');\n _this.swatches = _this.querySelectorAll('swatch-item');\n _this.dataVariant = _this.querySelectorAll('[data-variant]');\n _this.targetCategories = _this.querySelectorAll('[data-target-category]');\n _this.productData = null;\n _this.currentActiveSwatch = null;\n _this.dropdownItems = [];\n _this.scrollTriggerInstance = null;\n _this.currentMobileState = null;\n\n // Timeout für den ResizeObserver\n _this.resizeTimeout = null;\n _this.handleResize = _this.handleResize.bind(_this);\n return _this;\n }\n _inherits(ProductPage, _HTMLElement);\n return _createClass(ProductPage, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n // --- Observer mit Debounce (Verhindert Ruckeln beim Aufklappen von Elementen) ---\n this.resizeObserver = new ResizeObserver(function () {\n if (_this2.scrollTriggerInstance) {\n clearTimeout(_this2.resizeTimeout);\n _this2.resizeTimeout = setTimeout(function () {\n gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.refresh();\n }, 50);\n }\n });\n this.resizeObserver.observe(this.images);\n this.resizeObserver.observe(this.info);
578\n this.swatches.forEach(function (swatch) {\n if (swatch.classList.contains('active')) {\n _this2.currentActiveSwatch = swatch;\n }\n swatch.addEventListener('click', function () {\n return _this2.handleVariantClick(swatch);\n });\n swatch.addEventListener('mouseenter', function () {\n return _this2.handleVariantHoverIn(swatch);\n });\n swatch.addEventListener('mouseleave', function () {\n return _this2.handleVariantHoverOut(swatch);\n });\n });\n\n // Fallback, falls beim Laden kein Swatch aktiv ist\n if (!this.currentActiveSwatch && this.swatches.length > 0) {\n this.currentActiveSwatch = this.swatches[0];\n }\n if (this.currentActiveSwatch) {\n this.updateTextsAndCategories(this.currentActiveSwatch);\n }\n this.dropdownItems = Array.from(this.querySelectorAll('dropdown-component li[data-variant-id]'));\n if (this.dropdownItems.length > 0) {\n this.dropdownItems.forEach(function (item) {\n item.addEventListener('click', function () {\n return _this2.handleDropdownClick(item);\n });\n });\n var activeItem = this.dropdownItems.find(function (i) {\n return i.classList.contains('active');\n });\n if (activeItem) this.updateTextsAndCategories(activeItem);\n }\n this.initOrDestroySticky((0,_helper_isMobile__WEBPACK_IMPORTED_MODULE_2__.isMobile)());\n window.addEventListener('resize', this.handleResize, {\n passive: true\n });\n this.fetchProductData();\n }\n }, {\n key: \"fetchProductData\",\n value: function () {\n var _fetchProductData = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var response, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n _context.p = 0;\n _context.n = 1;\n return fetch(window.location.pathname + '.js');\n case 1:\n response = _context.v;\n _context.n = 2;\n return response.json();\n case 2:\n this.productData = _context.v;\n _context.n = 4;\n break;\n case 3:\n _context.p = 3;\n _t = _context.v;\n console.error('Fehler beim Laden der Produktdaten:', _t);\n case 4:\n return _context.a(2);\n }\n }, _callee, this, [[0, 3]]);\n }));\n function fetchProductData() {\n return _fetchProductData.apply(this, arguments);\n }\n return fetchProductData;\n }()\n }, {\n key: \"handleResize\",\n value: function handleResize() {\n var mobile = (0,_helper_isMobile__WEBPACK_IMPORTED_MODULE_2__.isMobile)();\n if (mobile !== this.currentMobileState) {\n this.initOrDestroySticky(mobile);\n }\n }\n }, {\n key: \"updateTextsAndCategories\",\n value: function updateTextsAndCategories(swatch) {\n var _this3 = this;\n var variantCategory = swatch.getAttribute('data-category');\n this.targetCategories.forEach(function (category) {\n if (category.getAttribute('data-target-category') === variantCategory) {\n category.removeAttribute('hidden');\n } else {\n category.setAttribute('hidden', true);\n }\n });\n var atc = this.querySelector('add-to-cart[data-target-variant-id]');\n var bis = this.querySelector('#back-in-stock-container');\n var isSoldOut = swatch.classList.contains('sold_out');\n if (atc) atc.toggleAttribute('disabled', isSoldOut);\n if (bis) bis.toggleAttribute('hidden', !isSoldOut);\n\n // NEU: Spezialfall für die Variant-ID, damit das Button-Text nicht überschrieben wird\n var variantId = swatch.getAttribute('data-variant-id');\n if (variantId) {\n var variantTargets = this.querySelectorAll('[data-target-variant-id]');
578\n variantTargets.forEach(function (target) {\n // Schreibt die ID als Attribut und Value, nicht als Textinhalt!\n target.setAttribute('variant-id', variantId);\n target.value = variantId;\n });\n }\n Array.from(swatch.attributes).forEach(function (attr) {\n if (attr.name.startsWith('data-value-')) {\n var fieldName = attr.name.replace('data-value-', '');\n\n // Sicherheitsabfrage: Falls data-value-variant-id noch im HTML existiert, wird es hier ignoriert\n if (fieldName === 'variant-id' || fieldName === 'variant_id') return;\n\n // category-info drives its own collab-info collapse animation below,\n // so it doesn't go through the generic hidden-attribute toggle here.\n if (fieldName === 'category-info') return;\n\n // Exclude the product-addons slider: it renders its own price/target\n // markup per add-on product, which must not be overwritten with the\n // main product's variant values.\n var targetElements = _this3.querySelectorAll(\"[data-target-\".concat(fieldName, \"]:not(product-addons-component, product-addons-component *)\"));\n targetElements.forEach(function (target) {\n if (fieldName === 'free_gift') {\n target.setAttribute('data-target-free_gift', attr.value || '');\n return;\n }\n if (attr.value && attr.value.trim() !== '') {\n if (!target.hasAttribute('data-target-category')) {\n target.removeAttribute('hidden');\n }\n var displayValue = attr.value;\n if (fieldName.includes('price')) {\n var currency = document.documentElement.getAttribute('currency') || '';\n var market = document.documentElement.getAttribute('market') || '';\n var formatted = (0,_helper_formatPrice__WEBPACK_IMPORTED_MODULE_3__.formatPrice)(parseInt(displayValue, 10));\n displayValue = market === 'us' ? \"\".concat(currency).concat(formatted) : \"\".concat(formatted, \" \").concat(currency);\n }\n if (!fieldName.includes('max-images')) {\n target.innerHTML = displayValue;\n }\n var defaultValue = target.getAttribute('data-default');\n if (defaultValue !== null) {\n if (displayValue !== defaultValue) {\n target.classList.add('is-modified');\n } else {\n target.classList.remove('is-modified');\n }\n }\n } else {\n if (!target.hasAttribute('data-target-category')) {\n target.setAttribute('hidden', true);\n }\n target.classList.remove('is-modified');\n }\n });\n }\n });\n var categoryInfoTarget = this.querySelector('[data-target-category-info]');\n if (categoryInfoTarget) {\n var categoryInfoValue = swatch.getAttribute('data-value-category-info') || '';\n var categoryInfoWrapper = categoryInfoTarget.closest('collab-info');\n // Deliberately not using the `hidden` attribute here: collab-info's CSS\n // also collapses via `:has(.inner[hidden])`, and browsers recompute :has()\n // matches synchronously on the attribute mutation, which can apply the\n // collapsed layout before the transition engine records a starting frame â\n // i.e. it animates in but snaps shut. aria-hidden keeps this accessible\n // without touching that selector, so only the .is-hidden class (a normal,\n // reliably-transitioning class toggle) drives the animation either way.\n if (categoryInfoValue.trim() !== '') {\n categoryInfoTarget.innerHTML = categoryInfoValue;\n categoryInfoTarget.removeAttribute('aria-hidden');\n if (categoryInfoWrapper) categoryInfoWrapper.classList.remove('is-hidden');\n } else {\n categoryInfoTarget.setAttribute('aria-hidden', 'true');\n if (categoryInfoWrapper) categoryInfoWrapper.classList.add('is-hidden');\n }\n }\n var maxImages = swatch.getAttribute('data-value-max-images');\n if (maxImages !== null) {\n this.toggleAttribute('data-single-image', parseInt(maxImages, 10) === 1);\n }\n var compareAtPriceRaw = parseInt(swatch.getAttribute('data-value-compare_at_price') || '0', 10);\n var priceRaw = parseInt(swatch.getAttribute('data-value-price') || '0', 10);\n var saleBadge = this.querySelector('[data-sale-badge]');\n if (saleBadge) {\n if (compareAtPriceRaw > priceRaw) {\n var discount = Math.round((compareAtPriceRaw - priceRaw) * 100 / compareAtPriceRaw);\n saleBadge.querySelector('span').textContent = \"-\".concat(discount, \"%\");\n saleBadge.removeAttribute('hidden');\n } else {\n saleBadge.setAttribute('hidden', true);\n }\n }\n }\n }, {\n key: \"handleVariantClick\",\n value: function handleVariantClick(swatch) {\n this.currentActiveSwatch = swatch;\n var variantId = swatch.getAttribute('data-variant-id');
578\n this.swatches.forEach(function (s) {\n return s.classList.remove('active');\n });\n swatch.classList.add('active');\n this.dataVariant.forEach(function (data) {\n // data-variant can hold a single id (image slides) or a space-separated\n // list (addon slides shared by several variants) â token match covers both.\n var variants = data.getAttribute('data-variant').split(/\\s+/).filter(Boolean);\n if (variants.includes(variantId)) {\n data.removeAttribute('hidden');\n } else {\n data.setAttribute('hidden', true);\n }\n });\n\n // NEU: Wir übergeben die Variante direkt an den Slider, damit dieser das HTML sauber filtern kann!\n if (this.images && typeof this.images.resetToFirstVisibleSlide === 'function') {\n this.images.resetToFirstVisibleSlide(variantId);\n }\n\n // The generic dataVariant loop above already set `hidden` on each addon slide;\n // this just re-syncs the swiper's internal slide list/index to match, same as\n // resetToFirstVisibleSlide does for the image gallery.\n if (this.addons && typeof this.addons.syncSwiper === 'function') {\n this.addons.syncSwiper();\n }\n if (variantId) {\n var url = new URL(window.location.href);\n url.searchParams.set('variant', variantId);\n window.history.replaceState({}, '', url.toString());\n }\n this.updateTextsAndCategories(swatch);\n }\n }, {\n key: \"handleDropdownClick\",\n value: function handleDropdownClick(item) {\n var variantId = item.getAttribute('data-variant-id');
578\n this.dataVariant.forEach(function (data) {\n // data-variant can hold a single id (image slides) or a space-separated\n // list (addon slides shared by several variants) â token match covers both.\n var variants = data.getAttribute('data-variant').split(/\\s+/).filter(Boolean);\n if (variants.includes(variantId)) {\n data.removeAttribute('hidden');\n } else {\n data.setAttribute('hidden', true);\n }\n });\n if (this.images && typeof this.images.resetToFirstVisibleSlide === 'function') {\n this.images.resetToFirstVisibleSlide(variantId);\n }\n\n // The generic dataVariant loop above already set `hidden` on each addon slide;\n // this just re-syncs the swiper's internal slide list/index to match, same as\n // resetToFirstVisibleSlide does for the image gallery.\n if (this.addons && typeof this.addons.syncSwiper === 'function') {\n this.addons.syncSwiper();\n }\n if (variantId) {\n var url = new URL(window.location.href);\n url.searchParams.set('variant', variantId);\n window.history.replaceState({}, '', url.toString());\n }\n this.updateTextsAndCategories(item);\n }\n }, {\n key: \"handleVariantHoverIn\",\n value: function handleVariantHoverIn(swatch) {\n if (!window.matchMedia('(hover: hover)').matches) return; // Touch-Geräte ignorieren\n swatch.classList.add('active');\n this.updateTextsAndCategories(swatch);\n }\n }, {\n key: \"handleVariantHoverOut\",\n value: function handleVariantHoverOut(swatch) {\n if (!window.matchMedia('(hover: hover)').matches) return;\n if (!this.currentActiveSwatch) return;\n if (swatch !== this.currentActiveSwatch) {\n swatch.classList.remove('active');\n }\n this.updateTextsAndCategories(this.currentActiveSwatch);\n }\n }, {\n key: \"initOrDestroySticky\",\n value: function initOrDestroySticky(mobile) {\n var _this4 = this;\n this.currentMobileState = mobile;\n if (!mobile && !this.scrollTriggerInstance) {\n this.info.style.position = 'sticky';\n this.info.style.alignSelf = 'start';\n var lastScroll = 0;\n var topOffset = 0;\n this.scrollTriggerInstance = gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.create({\n trigger: this.images,\n start: 'top bottom',\n end: 'bottom top',\n onRefresh: function onRefresh(self) {\n var navHStr = getComputedStyle(document.documentElement).getPropertyValue('--content-margin').trim();\n _this4.navH = parseInt(navHStr) || 0;\n var winH = window.innerHeight;\n var infoH = _this4.info.offsetHeight;\n\n // Lies den aktuellen top-Wert aus, anstatt ihn sofort auf 0 (bzw. navH) zu setzen\n var currentTop = parseFloat(_this4.info.style.top);\n if (isNaN(currentTop)) currentTop = _this4.navH;\n\n // Wenn das Element in den Bildschirm passt, an der Top-Navigation anpinnen\n if (infoH + _this4.navH <=
578winH) {\n topOffset = _this4.navH;\n } else {\n // Ansonsten: Berechne neue Grenzen basierend auf der neuen Höhe\n var minTop = winH - infoH;\n var maxTop = _this4.navH;\n\n // Klemme die AKTUELLE Position einfach in die neuen Grenzen ein.\n // Dadurch springt das Element nicht nach oben, wenn z.B. ein Akkordeon öffnet!\n topOffset = Math.max(minTop, Math.min(maxTop, currentTop));\n }\n _this4.info.style.top = \"\".concat(topOffset, \"px\");\n lastScroll = self.scroll();\n },\n onUpdate: function onUpdate(self) {\n var winH = window.innerHeight;\n var infoH = _this4.info.offsetHeight;\n if (infoH + _this4.navH <= winH) {\n _this4.info.style.top = \"\".concat(_this4.navH, \"px\");\n return;\n }\n var currentScroll = self.scroll();\n var scrollDelta = currentScroll - lastScroll;\n lastScroll = currentScroll;\n topOffset -= scrollDelta;\n var minTop = winH - infoH;\n var maxTop = _this4.navH;\n topOffset = Math.max(minTop, Math.min(maxTop, topOffset));\n _this4.info.style.top = \"\".concat(topOffset, \"px\");\n }\n });\n } else if (mobile && this.scrollTriggerInstance) {\n this.scrollTriggerInstance.kill();\n this.scrollTriggerInstance = null;\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.set(this.info, {\n clearProps: 'all'\n });\n }\n }\n }, {\n key: \"disconnectedCallback\",\n value: function disconnectedCallback() {\n if (this.resizeObserver) this.resizeObserver.disconnect();\n window.removeEventListener('resize', this.handleResize);\n if (this.scrollTriggerInstance) {\n this.scrollTriggerInstance.kill();\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('product-page-component', ProductPage);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/product/page.js?\n}"); 579 580/***/ }, 581 582/***/ "./dev/js/components/productAddons.js" 583/*!********************************************!*\ 584 !*** ./dev/js/components/productAddons.js ***! 585 \********************************************/ 586(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 587 588"use strict"; 589eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\n/* harmony import */ var _helper_formatPrice__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../helper/formatPrice */ \"./dev/js/helper/formatPrice.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }
589\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\n\n\n\nvar ProductAddonsComponent = /*#__PURE__*/function (_HTMLElement) {\n function ProductAddonsComponent() {\n var _this;\n _classCallCheck(this, ProductAddonsComponent);\n _this = _callSuper(this, ProductAddonsComponent);\n // Swiper measures actual DOM children, so a merely `[hidden]` slide would\n // still count as a zero-width slide â physically move only the visible\n // ones into the wrapper, then re-sync Swiper to match.\n _defineProperty(_this, \"syncSwiper\", function () {\n _this.swiperWrapper.innerHTML = '';\n _this.allSlides.forEach(function (slide) {\n if (!slide.hasAttribute('hidden')) _this.swiperWrapper.appendChild(slide);\n });\n _this.toggleAttribute('hidden', _this.swiperWrapper.children.length === 0);\n if (_this.hasAttribute('hidden')) return;
589\n if (_this.swiper) {\n _this.swiper.update();\n _this.swiper.slideTo(0, 0, false);\n } else {\n _this.initSwiper();\n }\n });\n _defineProperty(_this, \"bindSlideInteractions\", function () {\n _this.allSlides.forEach(function (slide) {\n slide.querySelectorAll('.swatch').forEach(function (swatch) {\n swatch.addEventListener('click', function () {\n return _this.selectSwatch(swatch);\n });\n });\n slide.addEventListener('click', function (e) {\n // Let the image/title links navigate and the swatches do their own thing;\n // everywhere else on the slide (including on top of the checkbox, which\n // has a transparent cover layer â see productAddons/_index.scss) toggles\n // here. The native checkbox is just visual feedback, not the click target.\n if (e.target.closest('a') || e.target.closest('.swatch')) return;\n var checkbox = slide.querySelector('.product-addon-checkbox');\n if (!checkbox) return;\n checkbox.checked = !checkbox.checked;\n checkbox.dispatchEvent(new Event('change', {\n bubbles: true\n }));\n });\n });\n });\n _defineProperty(_this, \"selectSwatch\", function (swatch) {\n var _swatch$dataset$swatc = swatch.dataset.swatchVariant.split('||'),\n _swatch$dataset$swatc2 = _slicedToArray(_swatch$dataset$swatc, 5),\n id = _swatch$dataset$swatc2[0],\n title = _swatch$dataset$swatc2[1],\n price = _swatch$dataset$swatc2[2],\n comparePrice = _swatch$dataset$swatc2[3],\n image = _swatch$dataset$swatc2[4];\n var slide = swatch.closest('.swiper-slide');\n if (!slide) return;\n var currency = document.documentElement.getAttribute('currency') || '';\n var titleEl = slide.querySelector('.title');\n var priceEl = slide.querySelector('[data-target-price]');\n var compareEl = slide.querySelector('[data-target-compare_at_price]');\n var imageEl = slide.querySelector('.image img');\n var checkbox = slide.querySelector('.product-addon-checkbox');\n if (titleEl) {\n titleEl.textContent = title.trim();\n if (titleEl.tagName === 'A') {\n var url = new URL(titleEl.href, window.location.origin);\n url.searchParams.set('variant', id.trim());\n titleEl.href = url.toString();\n }\n }\n if (imageEl) imageEl.srcset = image.trim();
589\n if (checkbox) checkbox.dataset.addonVariantId = id.trim();\n if (priceEl) priceEl.textContent = (0,_helper_formatPrice__WEBPACK_IMPORTED_MODULE_2__.formatPrice)(parseInt(price, 10)) + ' ' + currency;\n if (compareEl) {\n var cmp = parseInt(comparePrice, 10);\n if (cmp > 0) {\n compareEl.textContent = (0,_helper_formatPrice__WEBPACK_IMPORTED_MODULE_2__.formatPrice)(cmp) + ' ' + currency;\n compareEl.removeAttribute('hidden');\n } else {\n compareEl.textContent = '';\n compareEl.setAttribute('hidden', '');\n }\n }\n var swatchGroup = swatch.closest('swatch-component');\n if (swatchGroup) {\n swatchGroup.querySelectorAll('.swatch').forEach(function (s) {\n return s.classList.remove('active');\n });\n swatch.classList.add('active');\n }\n });\n _defineProperty(_this, \"getSelectedItems\", function () {\n var checkboxes = _this.querySelectorAll('.product-addon-checkbox:checked');\n return Array.from(checkboxes).map(function (checkbox) {\n return parseInt(checkbox.dataset.add
589onVariantId, 10);\n }).filter(function (id) {\n return !Number.isNaN(id);\n }).map(function (id) {\n return {\n id: id,\n quantity: 1\n };\n });\n });\n _defineProperty(_this, \"uncheckAll\", function () {\n _this.querySelectorAll('.product-addon-checkbox:checked').forEach(function (checkbox) {\n checkbox.checked = false;\n });\n });\n _this.swiperContainer = _this.querySelector('.swiper');\n _this.swiperWrapper = _this.querySelector('.swiper-wrapper');\n _this.nextBtn = _this.querySelector('next-button-component');\n _this.prevBtn = _this.querySelector('prev-button-component');\n\n // There's a single instance of this component for the whole product â one\n // slide per unique addon product, tagged data-variant=\"id1 id2 ...\" with\n // the main-product variants it applies to (see product-addon-slide.liquid).\n // Visibility (the `hidden` attribute) is driven generically by page.js â\n // same [data-variant] mechanism the image gallery slides use â this\n // component only has to keep Swiper's slide list/index in sync with\n // whatever is currently visible. Slides are never duplicated or recreated,\n // so checkbox/swatch state on one survives a variant switch for free.\n _this.allSlides = [];\n return _this;\n }\n _inherits(ProductAddonsComponent, _HTMLElement);\n return _createClass(ProductAddonsComponent, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n if (!this.swiperContainer || !this.swiperWrapper) return;\n this.allSlides = Array.from(this.querySelectorAll('.swiper-slide'));\n this.bindSlideInteractions();\n this.syncSwiper();\n }\n }, {\n key: \"disconnectedCallback\",\n value: function disconnectedCallback() {\n if (this.swiper) {\n this.swiper.destroy();\n this.swiper = null;\n }\n }\n }, {\n key: \"initSwiper\",\n value: function initSwiper() {\n if (this.swiper) return;\n this.swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.swiperContainer, {\n modules: [swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Navigation],\n spaceBetween: 20,\n slidesPerView: 1,\n resizeObserver: false,\n navigation: {\n nextEl: this.nextBtn,\n prevEl: this.prevBtn,\n disabledClass: 'opacity'\n }\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nif (!customElements.get('product-addons-component')) {\n window.customElements.define('product-addons-component', ProductAddonsComponent);\n}\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/productAddons.js?\n}"); 590 591/***/ }, 592 593/***/ "./dev/js/components/productCardSlider.js" 594/*!************************************************!*\ 595 !*** ./dev/js/components/productCardSlider.js ***! 596 \************************************************/ 597(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 598 599"use strict"; 600eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
600\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\nvar ProductCardSlider = /*#__PURE__*/function (_HTMLElement) {\n function ProductCardSlider() {\n var _this;\n _classCallCheck(this, ProductCardSlider);\n _this = _callSuper(this, ProductCardSlider);\n _this.swiper = _this.querySelector('.swiper');\n _this.observer = null;\n _this.hintArmed = false;\n return _this;\n }\n _inherits(ProductCardSlider, _HTMLElement);\n return _createClass(ProductCardSlider, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n console.log(this.swiper.classList.contains('disable'));\n if (this.swiper.classList.contains('disable')) return;\n var container = this.querySelector('.swiper');\n this.swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](container, {\n slidesPerView: 1,\n spaceBetween: 0,\n loop: false\n });\n this.maybeActivateSwipeHint();\n this.attachUserSwipeListener();\n }\n }, {\n key: \"disconnectedCallback\",\n value: function disconnectedCallback() {\n if (this.observer) this.observer.disconnect();\n }\n }, {\n key: \"maybeActivateSwipeHint\",\n value: function maybeActivateSwipeHint() {\n var _this2 = this;\n if (this.getCookie('product_card_swipe_hint_seen')) return;\n var all = document.querySelectorAll('product-card-slider');\n if (all[0] !== this) return;\n this.observer = new IntersectionObserver(function (_ref) {\n var _ref2 = _slicedToArray(_ref, 1),\n entry = _ref2[0];\n if (!entry.isIntersecting) return;\n _this2.observer.disconnect();\n _this2.classList.add('first');\n _this2.hintArmed = true;\n }, {\n threshold: 0.6\n });\n this.observer.observe(this);\n }\n }, {\n key: \"attachUserSwipeListener\",\n value: function attachUserSwipeListener() {\n var _this3 = this;\n if (this.getCookie('product_card_swipe_hint_seen')) return;\n var startIndex = null;\n this.swiper.on('touchStart', function () {\n startIndex = _this3.swiper.activeIndex;\n });\n this.swiper.on('touchEnd', function () {\n if (!_this3.hintArmed) return;\n if (startIndex === _this3.swiper.activeIndex) return;\n _this3.setCookie('product_card_swipe_hint_seen', '1', 365);\n _this3.hintArmed = false;\n _this3.classList.remove('first');\n });\n this.swiper.on('sliderFirstMove', function () {\n if (!_this3.hintArmed) return;\n _this3.setCookie('product_card_swipe_hint_seen', '1', 365);\n _this3.hintArmed = false;\n _this3.classList.remove('first');\n });\n }\n }, {\n key: \"getCookie\",\n value: function getCookie(name) {\n var match = document.cookie.match(new RegExp('(?:^|; )' + name.replace(/([.$?*|{}()[\\]\\\\/+^])/g, '\\\\$1') + '=([^;]*)'));\n return match ? decodeURIComponent(match[1]) : null;\n }\n }, {\n key: \"setCookie\",\n value: function setCookie(name, value, days) {\n var d = new Date();\n d.setTime(d.getTime() + days * 864e5);
600\n document.cookie = \"\".concat(name, \"=\").concat(value, \"; expires=\").concat(d.toUTCString(), \"; path=/; SameSite=Lax\");\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\ncustomElements.define('product-card-slider', ProductCardSlider);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/productCardSlider.js?\n}"); 601 602/***/ }, 603 604/***/ "./dev/js/components/productComparison.js" 605/*!************************************************!*\ 606 !*** ./dev/js/components/productComparison.js ***! 607 \************************************************/ 608(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 609 610"use strict"; 611eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread(); }\nfunction _nonIterableSpread() { throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _iterableToArray(r) { if (\"undefined\" != typeof Symbol && null != r[Symbol.iterator] || null != r[\"@@iterator\"]) return Array.from(r); }\nfunction _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(r); }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\");
611 t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar ProductComparison = /*#__PURE__*/function (_HTMLElement) {\n function ProductComparison() {\n var _this;\n _classCallCheck(this, ProductComparison);\n _this = _callSuper(this, ProductComparison);\n _this.selectElements = [];\n _this.options = [];\n _this.selectedOptions = []; // Now populated dynamically on load\n _this.comparisonItems = [];\n _this.comparisonTop = null;\n _this.comparisonBottom = null;\n _this.comboBox = null;\n return _this;\n }\n _inherits(ProductComparison, _HTMLElement);\n return _createClass(ProductComparison, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n this.comparisonBottom = this.querySelector('.comparison__bottom');\n this.selectElements = Array.from(this.querySelectorAll('select'));\n this.comparisonItems = Array.from(this.querySelectorAll('.comparison__item'));\n this.comparisonItemsInfo = Array.from(this.comparisonBottom.querySelectorAll('.comparison__item-info'));\n this.comparisonTop = this.querySelector('.comparison__top');\n this.comboBox = this.querySelectorAll('.combo-box');\n\n // Sync initial state from Liquid's pre-selection\n this.selectElements.forEach(function (select, index) {\n var _this2$options;\n var options = Array.from(select.options).map(function (option) {\n return {\n id: option.getAttribute('data-id'),\n value: option.value\n };\n });\n (_this2$options = _this2.options).push.apply(_this2$options, _toConsumableArray(options));\n var selectedOpt = select.options[select.selectedIndex];\n _this2.selectedOptions[index] = {\n id: selectedOpt.getAttribute('data-id'),\n value: selectedOpt.value\n };\n });\n this.updateSelection();\n this.changeComboBox();\n this.moveComboBoxes();\n document.fonts.ready.then(function () {\n _this2.calculateHeight();\n setTimeout(function () {\n _this2.classList.add('is-ready');\n }, \"2000\");\n });\n this.forceRecalculationAfterTransition();
611\n this.selectElements.forEach(function (selectElement, index) {\n selectElement.addEventListener('change', function (event) {\n var selectedOptionId = event.target.selectedOptions[0].getAttribute('data-id');\n var selectedOption = _this2.options.find(function (option) {\n return option.id === selectedOptionId;\n });\n _this2.selectedOptions[index] = selectedOption;\n _this2.updateSelection();\n _this2.calculateHeight();\n _this2.dispatchEvent(new CustomEvent('selectionChange', {\n detail: _this2.selectedOptions\n }));\n });\n });\n var header = document.querySelector('.shopify-section--header');\n var comparisonCenter = this.querySelector('.comparison.comparison__center');\n if (header && comparisonCenter) {\n gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger.create({\n trigger: comparisonCenter,\n start: \"top top+=\".concat(header.offsetHeight),\n end: \"bottom-=\".concat(comparisonCenter.offsetHeight + header.offsetHeight),\n endTrigger: this.comparisonBottom,\n pin: true,\n pinSpacing: false,\n toggleClass: \"pinned\"\n });\n }\n window.addEventListener('resize', this.moveComboBoxes.bind(this));\n }\n }, {\n key: \"updateSelection\",\n value: function updateSelection() {\n var _this3 = this;\n // Clear current visibility\n this.comparisonItems.forEach(function (el) {\n return el.setAttribute('hidden', 'true');\n });\n this.comparisonItemsInfo.forEach(function (el) {\n return el.setAttribute('hidden', 'true');\n });\n\n // Apply new visibility based on selectedOptions\n this.selectedOptions.forEach(function (selectedOption) {\n var itemIndex = parseInt(selectedOption.id) - 1;\n if (_this3.comparisonItems[itemIndex]) {\n _this3.comparisonItems[itemIndex].removeAttribute('hidden');\n _this3.comparisonTop.appendChild(_this3.comparisonItems[itemIndex]);\n }\n if (_this3.comparisonItemsInfo[itemIndex]) {\n _this3.comparisonItemsInfo[itemIndex].removeAttribute('hidden');\n _this3.comparisonBottom.appendChild(_this3.comparisonItemsInfo[itemIndex]);\n }\n });\n this.changeComboBox();\n }\n }, {\n key: \"calculateHeight\",\n value: function calculateHeight() {\n var attributeColumn = this.comparisonBottom.querySelector('.comparison__attributes');\n var comparableElements = Array.from(this.comparisonBottom.querySelectorAll('.comparison__item-info:not([hidden])'));\n if (!attributeColumn) return;\n comparableElements.unshift(attributeColumn);\n var compareAndAdjustHeights = function compareAndAdjustHeights(nodeElements) {\n if (!nodeElements.length) return;\n var maxRows = Array.from(nodeElements).reduce(function (max, el) {\n return Math.max(max, el.querySelectorAll(':scope > div').length);\n }, 0);\n var _loop = function _loop(rowIndex) {\n var maxHeight = 0;\n var rowDivs = [];\n nodeElements.forEach(function (col) {\n var div = col.querySelectorAll(':scope > div')[rowIndex];\n if (div) {\n div.style.height = 'auto';\n rowDivs.push(div);\n maxHeight = Math.max(maxHeight, div.getBoundingClientRect().height);\n }\n });\n rowDivs.forEach(function (div) {\n div.style.height = \"\".concat(maxHeight, \"px\");\n });\n };\n for (var rowIndex = 0; rowIndex < maxRows; rowIndex++) {\n _loop(rowIndex);\n }\n };\n compareAndAdjustHeights(comparableElements);\n }\n }, {\n key: \"forceRecalculationAfterTransition\",\n value: function forceRecalculationAfterTransition() {\n var _this4 = this;\n this.comparisonBottom.addEventListener('transitionend', function () {\n _this4.calculateHeight();\n });\n }\n }, {\n key: \"changeComboBox\",\n value: function changeComboBox() {\n var _this5 = this;
611\n this.comboBox.forEach(function (element) {\n element.querySelectorAll('button').forEach(function (button, index) {\n button.removeAttribute('disabled');\n var isSelected = _this5.selectedOptions.some(function (opt) {\n return parseInt(opt.id) === index + 1;\n });\n if (isSelected) button.setAttribute('disabled', true);\n });\n });\n }\n }, {\n key: \"moveComboBoxes\",\n value: function moveComboBoxes() {\n var _this6 = this;\n var isMobile = window.innerWidth <= 768;\n if (isMobile && this.comboBox) {\n this.comboBox.forEach(function (combo) {\n _this6.appendChild(combo);\n });\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"product-comparison\", ProductComparison);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/productComparison.js?\n}"); 612 613/***/ }, 614 615/***/ "./dev/js/components/productSlider.js" 616/*!********************************************!*\ 617 !*** ./dev/js/components/productSlider.js ***! 618 \********************************************/ 619(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 620 621"use strict"; 622eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
622 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\n\n\n\nvar ProductSlider = /*#__PURE__*/function (_HTMLElement) {\n function ProductSlider() {\n var _this;\n _classCallCheck(this, ProductSlider);\n _this = _callSuper(this, ProductSlider);\n _this.el = _this;\n _this.mainEl = _this.el.querySelector('.swiper-main');\n _this.thumbsEl = _this.el.querySelector('.swiper-thumbs');\n return _this;\n }\n _inherits(ProductSlider, _HTMLElement);\n return _createClass(ProductSlider, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"].use([swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Navigation, swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Autoplay, swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Thumbs, swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Controller]);\n var thumbsSwiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.thumbsEl, {\n spaceBetween: 3,\n slidesPerView: 5,\n watchSlidesProgress: true,\n slidesOffsetBefore: 20,\n centeredSlides: true,\n centeredSlidesBounds: true,\n breakpoints: {\n 640: {\n slidesPerView: 6\n },\n 1024: {\n slidesPerView: 8\n }\n }\n });\n var mainEl = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.mainEl, {\n slidesPerView: 1,\n loop: false,\n navigation: {\n nextEl: '.swiper-button-next',\n prevEl: '.swiper-button-prev'\n },\n thumbs: {\n swiper: thumbsSwiper\n },\n controller: {\n control: thumbsSwiper\n },\n on: {\n slideChange: function slideChange() {\n _this2.trackSlideChange(mainEl);\n }\n }\n });\n }\n }, {\n key: \"trackSlideChange\",\n value: function trackSlideChange(mainEl) {\n var currentIndex = mainEl.realIndex;\n window.dataLayer = window.dataLayer || [];\n window.dataLayer.push({\n event: 'swiperSlideChange',\n slideIndex: currentIndex\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('product-slider', ProductSlider);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/productSlider.js?\n}"); 623 624/***/ }, 625 626/***/ "./dev/js/components/productTreasure.js" 627/*!**********************************************!*\ 628 !*** ./dev/js/components/productTreasure.js ***! 629 \**********************************************/ 630(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 631 632"use strict"; 633eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_addProduct__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/addProduct */ \"./dev/js/helper/addProduct.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
633\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\nvar ProductTreasure = /*#__PURE__*/function (_HTMLElement) {\n function ProductTreasure() {\n var _this;\n _classCallCheck(this, ProductTreasure);\n _this = _callSuper(this, ProductTreasure);\n _this.button = _this.querySelector('button');\n return _this;\n }\n _inherits(ProductTreasure, _HTMLElement);\n return _createClass(ProductTreasure, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n if (!this.button) {\n console.error('Button nicht gefunden!');\n return;\n }\n this.button.addEventListener('click', function () {\n return _this2.addTreasure();\n });\n }\n }, {\n key: \"addTreasure\",\n value: function addTreasure() {\n var timestamp = Date.now();\n var id = this.button.dataset.id;\n var manta = this.button.dataset.manta;\n if (!id) {\n console.error('Keine Produkt-ID am Button gefunden!');\n return;\n }\n\n // Basis-Item (ohne properties)\n var item = {\n id: id,\n quantity: 1\n };\n\n // Nur, wenn data-manta existiert, properties hinzufügen\n if (manta) {\n item.properties = {\n _treasure_chest: \"true\",\n _unique_id: timestamp\n };\n }\n (0,_helper_addProduct__WEBPACK_IMPORTED_MODULE_0__.addProduct)({\n items: [item]\n }, true).then(function () {\n return console.log('Produkt erfolgreich zum Warenkorb hinzugefügt!');\n })[\"catch\"](function (err) {\n return console.error('Fehler beim Hinzufügen zum Warenkorb:', err);\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('product-treasure', ProductTreasure);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/productTreasure.js?\n}"); 634 635/***/ }, 636 637/***/ "./dev/js/components/productVariantSlider.js" 638/*!***************************************************!*\ 639 !*** ./dev/js/components/productVariantSlider.js ***! 640 \***************************************************/ 641(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 642 643"use strict"; 644eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
644\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\nvar ProductVariantSliderComponent = /*#__PURE__*/function (_HTMLElement) {\n function ProductVariantSliderComponent() {\n var _this;\n _classCallCheck(this, ProductVariantSliderComponent);\n _this = _callSuper(this, ProductVariantSliderComponent);\n _this.productSliderEl = _this.querySelector('.variant-slider');\n\n /* --- SWATCH LOGIC DISABLED ---\n this.swatchSliderEl = this.querySelector('.variant-indicator');\n this.isThumbnailClick = false;\n ------------------------------ */\n\n _this.prevButtonEl = _this.querySelector('prev-button-component');\n _this.nextButtonEl = _this.querySelector('next-button-component');\n _this.isNavigating = false;\n return _this;\n }\n _inherits(ProductVariantSliderComponent, _HTMLElement);\n return _createClass(ProductVariantSliderComponent, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n if (!this.productSliderEl || this.productSwiper) return;\n this.initSwipers();\n }\n }, {\n key: \"disconnectedCallback\",\n value: function disconnectedCallback() {\n if (this.productSwiper) {\n this.productSwiper.destroy();\n this.productSwiper = null;\n }\n /* --- SWATCH DESTROY DISABLED ---\n if (this.swatchSwiper) {\n this.swatchSwiper.destroy();\n this.swatchSwiper = null;\n }\n ------------------------------- */\n }\n\n /* --- SWATCH UPDATE METHOD DISABLED ---\n updateActiveSwatch(index) {\n if (!this.swatchSliderEl) return;\n const swatches = this.swatchSliderEl.querySelectorAll('.swiper-slide');
644\n swatches.forEach(swatch => swatch.classList.remove('swiper-slide-thumb-active'));\n if (swatches[index]) {\n swatches[index].classList.add('swiper-slide-thumb-active');\n }\n }\n -------------------------------------- */\n }, {\n key: \"initSwipers\",\n value: function initSwipers() {\n var _this2 = this;\n // Reorder Product Slides (Move sold out to end)\n var productWrapper = this.productSliderEl.querySelector('.swiper-wrapper');\n if (productWrapper) {\n var productSoldOut = productWrapper.querySelectorAll('.swiper-slide.sold_out');\n productSoldOut.forEach(function (slide) {\n return productWrapper.appendChild(slide);\n });\n }\n\n /* --- SWATCH INITIALIZATION DISABLED ---\n if (this.swatchSliderEl) {\n // ... Swatch Swiper logic removed for brevity ...\n }\n --------------------------------------- */\n\n // Main Product Swiper\n this.productSwiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.productSliderEl, {\n modules: [swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Mousewheel],\n slidesPerView: 1.5,\n spaceBetween: 16,\n mousewheel: {\n forceToAxis: true,\n releaseOnEdges: true\n },\n breakpoints: {\n 420: {\n slidesPerView: 3.2\n },\n 800: {\n slidesPerView: 4.2\n }\n },\n on: {\n init: function init(swiper) {\n _this2.updateNavigationButtons(swiper);\n },\n slideChange: function slideChange(swiper) {\n /* --- SWATCH SYNC DISABLED ---\n if (this.swatchSwiper && !this.swatchSwiper.destroyed && !this.isThumbnailClick) {\n this.swatchSwiper.slideTo(swiper.activeIndex);\n }\n this.updateActiveSwatch(swiper.activeIndex);\n ---------------------------- */\n _this2.updateNavigationButtons(swiper);\n },\n resize: function resize(swiper) {\n _this2.updateNavigationButtons(swiper);\n }\n }\n });\n this.initManualNavigation();\n }\n }, {\n key: \"initManualNavigation\",\n value: function initManualNavigation() {\n var _this3 = this;\n var handleNavClick = function handleNavClick(direction, e) {\n e.preventDefault();\n e.stopPropagation();\n if (_this3.isNavigating || !_this3.productSwiper) return;\n _this3.isNavigating = true;\n direction === 'next' ? _this3.productSwiper.slideNext() : _this3.productSwiper.slidePrev();\n setTimeout(function () {\n _this3.isNavigating = false;\n }, 300);\n };\n if (this.prevButtonEl) this.prevButtonEl.addEventListener('click', function (e) {\n return handleNavClick('prev', e);\n });\n if (this.nextButtonEl) this.nextButtonEl.addEventListener('click', function (e) {\n return handleNavClick('next', e);\n });\n }\n }, {\n key: \"updateNavigationButtons\",\n value: function updateNavigationButtons(swiper) {\n if (this.prevButtonEl) this.prevButtonEl.classList.toggle('swiper-button-disabled', swiper.isBeginning);\n if (this.nextButtonEl) this.nextButtonEl.classList.toggle('swiper-button-disabled', swiper.isEnd);\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nif (!customElements.get('product-variant-slider-component')) {\n window.customElements.define('product-variant-slider-component', ProductVariantSliderComponent);\n}\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/productVariantSlider.js?\n}"); 645 646/***/ }, 647 648/***/ "./dev/js/components/quickAtc.js" 649/*!***************************************!*\ 650 !*** ./dev/js/components/quickAtc.js ***! 651 \***************************************/ 652(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 653 654"use strict"; 655eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _freeGiftModal__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./freeGiftModal */ \"./dev/js/components/freeGiftModal.js\");\n/* harmony import */ var _helper_formatPrice__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../helper/formatPrice */ \"./dev/js/helper/formatPrice.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
655 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
655 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\nvar QuickAtc = /*#__PURE__*/function (_HTMLElement) {\n function QuickAtc() {\n var _this$btn;\n var _this;\n _classCallCheck(this, QuickAtc);\n _this = _callSuper(this, QuickAtc);\n _this.btn = _this.querySelector('button[data-handle]');\n _this.modal = document.getElementById('quick-atc');\n _this.variants = [];\n if ((_this$btn = _this.btn) !== null && _this$btn !== void 0 && _this$btn.dataset.variantCategories) {\n var stripedText = _this.btn.dataset.variantCategories.replace(/\\s\\s/g, '');\n if (stripedText.endsWith(',]')) {\n stripedText = stripedText.slice(0, -2) + ']';\n }\n try {\n _this.variants = JSON.parse(stripedText);\n } catch (e) {\n console.error('Konnte variant-categories nicht parsen:', e);\n }\n }\n _this._dispatchAddEvent = _this._dispatchAddEvent.bind(_this);\n _this._onClick = _this._onClick.bind(_this);\n return _this;\n }\n _inherits(QuickAtc, _HTMLElement);\n return _createClass(QuickAtc, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this$modal;\n if (!this.btn) {\n console.warn('Kein ATC-Button mit data-handle gefunden');\n return;\n }\n this.btn.addEventListener('click', this._onClick);\n this.addToCartButton = (_this$modal = this.modal) === null || _this$modal === void 0 ? void 0 : _this$modal.querySelector('#AddToCart');\n if (this.addToCartButton) {\n this.addToCartButton.onclick = this._dispatchAddEvent;\n }\n }\n }, {\n key: \"_onClick\",\n value: function () {\n var _onClick2 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(e) {\n var _this$btn2;\n var _this$variants, vid, ent, gift, handle, res, productData, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n e.preventDefault();\n if (!(((_this$btn2 = this.btn) === null || _this$btn2 === void 0 ? void 0 : _this$btn2.dataset.variant) === 'true')) {\n _context.n = 3;\n break;\n }\n vid = this.btn.dataset.variantId;\n if (vid) {\n _context.n = 1;\n break;\n }\n return _context.a(2, console.warn('Kein Variant-ID im data-variant-id Attribut'));\n case 1:\n ent = (_this$variants = this.variants) !== null && _this$variants !== void 0 && _this$variants.length ? this.variants.find(function (x) {\n return String(x.id) === String(vid);\n }) : null;\n if (!(ent && ent.freegiftDisabled)) {\n _context.n = 2;\n break;\n }\n (0,_freeGiftModal__WEBPACK_IMPORTED_MODULE_0__.useProducts)(vid, null, Date.now(), true);\n return _context.a(2);\n case 2:\n gift = this.btn.getAttribute('data-quick-freegift') || '';\n if (!gift && ent && !ent.freegiftDisabled && ent.freegiftFirst) {\n gift = ent.freegiftFirst;\n }\n (0,_freeGiftModal__WEBPACK_IMPORTED_MODULE_0__.useProducts)(vid, gift || null, Date.now(), true);\n return _context.a(2);\n case 3:\n if (this.addToCartButton) {\n if (this.btn.hasAttribute('data-quick-freegift')) {\n this.addToCartButton.setAttribute('data-freegift', this.btn.getAttribute('data-quick-freegift'));\n } else {\n this.addToCartButton.removeAttribute('data-freegift');\n }\n }\n handle = this.btn.dataset.handle;\n if (handle) {\n _context.n = 4;\n break;\n }\n return _context.a(2, console.warn('Kein Produkt-Handle im data-handle-Attribut'));\n case 4:\n _context.p = 4;\n _context.n = 5;\n return fetch(\"/products/\".concat(handle, \".js\"));\n case 5:\n res = _context.v;\n if (res.ok) {\n _context.n = 6;\n break;\n }\n throw new Error(\"Fetch-Fehler: \".concat(res.status));\n case 6:\n _context.n = 7;\n return res.json();\n case 7:\n productData = _context.v;\n this.productData = productData;\n this._openModal();\n this._renderVariants(productData);\n this._bindVariantEvents();\n this._applyFreeGiftFromSelectedVariant();\n _context.n = 9;\n break;\n case 8:\n _context.p = 8;\n _t = _context.v;\n console.error('Fehler beim Laden der Produkt-Daten:', _t);\n case 9:\n return _context.a(2);\n }\n }, _callee, this, [[4, 8]]);\n }));\n function _onClick(_x) {\n return _onClick2.apply(this, arguments);\n }\n return _onClick;\n }()\n }
655, {\n key: \"_openModal\",\n value: function _openModal() {\n var _this$modal2;\n (_this$modal2 = this.modal) === null || _this$modal2 === void 0 || _this$modal2.setAttribute('open', '');\n }\n }, {\n key: \"_getTabKey\",\n value: function _getTabKey(category) {\n return category !== null && category !== void 0 && category.startsWith('collab') ? 'collab' : category;\n }\n }, {\n key: \"_getAvailableCategories\",\n value: function _getAvailableCategories(productData) {\n var _this2 = this;\n var s = new Set();\n productData.variants.forEach(function (v) {\n if (!v.available) return;\n var ent = _this2.variants.find(function (x) {\n return Number(x.id) === v.id;\n });\n if (!ent || !ent.category) return;\n s.add(_this2._getTabKey(ent.category));\n });\n return Array.from(s);\n }\n }, {\n key: \"_renderVariants\",\n value: function _renderVariants(productData) {\n var _this$modal3,\n _this$modal4,\n _this3 = this;\n var container = (_this$modal3 = this.modal) === null || _this$modal3 === void 0 ? void 0 : _this$modal3.querySelector('#variants-container');\n if (!container) return console.warn('#variants-container nicht gefunden');\n container.innerHTML = '';\n var titleEl = (_this$modal4 = this.modal) === null || _this$modal4 === void 0 ? void 0 : _this$modal4.querySelector('.quick-atc-header__title');\n if (titleEl) titleEl.textContent = productData.title;\n var cats = this._getAvailableCategories(productData);\n if (cats.length === 0) return;\n var assetsBase = this.modal.dataset.assetsBase || '';\n var NO_FLAG_CATS = ['collab', 'print', 'imperfect'];\n var wrapper = document.createElement('product-variants');\n wrapper.setAttribute('handle', productData.handle);\n wrapper.className = 'product-form__variants';\n cats.forEach(function (cat, catIndex) {\n var section = document.createElement('div');\n section.className = 'quick-atc-category';\n var titleDiv = document.createElement('div');\n titleDiv.className = 'quick-atc-category__title';\n if (assetsBase && catIndex < 2 && !NO_FLAG_CATS.includes(cat)) {\n var flagImg = document.createElement('img');\n flagImg.src = assetsBase + 'flag-' + cat + '.svg';\n flagImg.alt = '';\n flagImg.className = 'quick-atc-category__flag';\n titleDiv.appendChild(flagImg);\n }\n var strong = document.createElement('strong');\n strong.textContent = cat.charAt(0).toUpperCase() + cat.slice(1) + ':';\n var nameSpan = document.createElement('span');\n nameSpan.dataset.categoryKey = cat;\n titleDiv.appendChild(strong);\n titleDiv.appendChild(document.createTextNode(' '));\n titleDiv.appendChild(nameSpan);\n section.appendChild(titleDiv);\n var swatchList = document.createElement('div');\n swatchList.className = 'quick-atc-category__swatches color-swatch-list';\n productData.variants.filter(function (v) {\n if (!v.available) return false;\n var ent = _this3.variants.find(function (x) {\n return Number(x.id) === v.id;\n });\n return ent && _this3._getTabKey(ent.category) === cat;\n }
655).forEach(function (v) {\n var _v$featured_image;\n var ent = _this3.variants.find(function (x) {\n return Number(x.id) === v.id;\n });\n var sw = document.createElement('div');\n sw.className = 'color-swatch';\n if (ent !== null && ent !== void 0 && ent.swatchStyle) sw.setAttribute('style', ent.swatchStyle);\n var inp = document.createElement('input');\n inp.className = 'color-swatch__radio visually-hidden';\n inp.type = 'radio';\n inp.name = 'option1';\n inp.id = \"option-\".concat(productData.handle, \"-\").concat(v.id);\n inp.value = v.option1;\n inp.dataset.variantId = v.id;\n inp.dataset.categoryKey = cat;\n if (ent) {\n inp.dataset.freegiftDisabled = ent.freegiftDisabled ? 'true' : 'false';\n inp.dataset.freegiftFirst = ent.freegiftFirst || '';\n }\n var lab = document.createElement('label');\n lab.className = 'color-swatch__item';\n lab.htmlFor = inp.id;\n var img = document.createElement('img');\n img.className = 'variant-swatch__image abtest-hidden';\n img.src = ((_v$featured_image = v.featured_image) === null || _v$featured_image === void 0 ? void 0 : _v$featured_image.src) || '';\n img.alt = productData.title;\n lab.appendChild(img);\n sw.appendChild(inp);\n sw.appendChild(lab);\n swatchList.appendChild(sw);\n });\n section.appendChild(swatchList);\n wrapper.appendChild(section);\n });\n container.appendChild(wrapper);\n }\n }, {\n key: \"_bindVariantEvents\",\n value: function _bindVariantEvents() {\n var _this$modal5,\n _this$modal6,\n _this$modal7,\n _this4 = this;\n this.infoSpan = (_this$modal5 = this.modal) === null || _this$modal5 === void 0 ? void 0 : _this$modal5.querySelector('#variant-info span');\n this.descContainer = (_this$modal6 = this.modal) === null || _this$modal6 === void 0 ? void 0 : _this$modal6.querySelector('.info_description');\n var radios = ((_this$modal7 = this.modal) === null || _this$modal7 === void 0 ? void 0 : _this$modal7.querySelectorAll('input[name=\"option1\"]')) || [];\n radios.forEach(function (radio, idx) {\n radio.onchange = function () {\n return _this4._updateInfo();\n };\n if (idx === 0) radio.checked = true;\n });\n this._updateInfo();\n }\n }, {\n key: \"_updateInfo\",\n value: function _updateInfo() {\n var _this$modal8, _this$modal9;\n var sel = (_this$modal8 = this.modal) === null || _this$modal8 === void 0 ? void 0 : _this$modal8.querySelector('input[name=\"option1\"]:checked');\n var color = ((sel === null || sel === void 0 ? void 0 : sel.value) || '').replace(/monochrome/i, '').trim();\n if (this.infoSpan) this.infoSpan.textContent = color;\n var selCat = (sel === null || sel === void 0 ? void 0 : sel.dataset.categoryKey) || '';\n (_this$modal9 = this.modal) === null || _this$modal9 === void 0 || _this$modal9.querySelectorAll('.quick-atc-category__title span[data-category-key]').forEach(function (span) {\n span.textContent = span.dataset.categoryKey === selCat ? color : '';\n });\n var vid = sel === null || sel === void 0 ? void 0 : sel.dataset.variantId;\n var meta = this.variants.find(function (v) {\n return String(v.id) === String(vid);\n });\n if (meta && this.descContainer) {\n var old = this.descContainer.querySelector('.desc-text');\n if (old) old.remove();\n var d = document.createElement('div');\n d.className = 'desc-text';\n d.textContent = meta.description || '';\n this.descContainer.appendChild(d);\n }\n if (sel !== null && sel !== void 0 && sel.dataset.variantId) this._updatePrice(sel.dataset.variantId);\n this._applyFreeGiftFromSelectedVariant();\n }\n }, {\n key: \"_updatePrice\",\n value: function _updatePrice(variantId) {\n var _this$modal0;\n var priceEl = (_this$modal0 = this.modal) === null || _this$modal0 === void 0 ? void 0 : _this$modal0.querySelector('price-component');\n if (!priceEl || !this.productData) return;\n var variant = this.productData.variants.find(function (v) {\n return String(v.id) === String(variantId);\n });\n if (!variant) return;\n var currency = this.modal.dataset.currency || '';\n var suffix = currency ? ' ' + currency : '';\n var priceSpan = priceEl.querySelector('[data-target-price]');\n var compareSpan = priceEl.querySelector('[data-target-compare_at_price]');\n if (priceSpan) priceSpan.textContent = this._formatPrice(variant.price) + suffix;\n if (compareSpan) {\n if (variant.compare_at_price && variant.compare_at_price > variant.price) {\n compareSpan.textContent = this._formatPrice(variant.compare_at_price) + suffix;\n compareSpan.removeAttribute('hidden');\n } else {\n compareSpan.textContent = '';\n compareSpan.setAttribute('hidden', '');\n }\n }\n }\n }, {\n key: \"_formatPrice\",\n value: function _formatPrice(cents) {\n return (0,_helper_formatPrice__WEBPACK_IMPORTED_MODULE_1__.formatPrice)(cents);\n }\n }, {\n key: \"_applyFreeGiftFromSelectedVariant\",\n value: function _applyFreeGiftFromSelectedVariant() {\n var _this$modal1;\n if (!this.addToCartButton) return;\n var sel = (_this$modal1 = this.modal) === null || _this$modal1 === void 0 ? void 0 : _this$modal1.querySelector('input[name=\"option1\"]:checked');\n if (!sel) {\n this.addToCartButton.removeAttribute('data-freegift');\n return;\n }\n var isDisabled = sel.dataset.freegiftDisabled === 'true';\n if (isDisabled) {\n this.addToCartButton.removeAttribute('data-freegift');\n return;\n }\n var firstGift = sel.dataset.freegiftFirst || '';\n if (firstGift) {\n this.addToCartButton.setAttribute('data-freegift', firstGift);\n } else {\n this.addToCartButton.removeAttribute('data-freegift');\n }\n }\n }, {\n key: \"_dispatchAddEvent\",\n value: function _dispatchAddEvent(e) {\n var _this$modal10, _this$addToCartButton;\n e.preventDefault();\n var sel = (_this$modal10 = this.modal) === null || _this$modal10 === void 0 ? void 0 : _this$modal10.querySelector('input[name=\"option1\"]:checked');\n var vid = sel === null || sel === void 0 ? void 0 : sel.dataset.variantId;\n if (!vid) return console.warn('Keine Variante ausgewählt');\n var timestamp = Date.now();\n var gift = ((_this$addToCartButton = this.addToCartButton) === null || _this$addToCartButton === void 0 ? void 0 : _this$addToCartButton.getAttribute('data-freegift')) || '';\n (0,_freeGiftModal__WEBPACK_IMPORTED_MODULE_0__.useProducts)(vid, gift || null, timestamp, true);\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('quick-atc', QuickAtc);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/quickAtc.js?\n}"); 656 657/***/ }, 658 659/***/ "./dev/js/components/readMore.js" 660/*!***************************************!*\ 661 !*** ./dev/js/components/readMore.js ***! 662 \***************************************/ 663() { 664 665eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
665\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar ReadMore = /*#__PURE__*/function (_HTMLElement) {\n function ReadMore() {\n var _this;\n _classCallCheck(this, ReadMore);\n _this = _callSuper(this, ReadMore);\n _this.content = _this.querySelector('.content');\n _this.innerContent = _this.content.querySelector('div');\n _this.button = _this.querySelector('button');\n return _this;\n }\n _inherits(ReadMore, _HTMLElement);\n return _createClass(ReadMore, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n this.style.setProperty('--height', \"\".concat(this.innerContent.offsetHeight, \"px\"));\n this.button.addEventListener('click', function () {\n _this2.content.classList.toggle('active');\n _this2.button.classList.toggle('active');\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"read-more-component\", ReadMore);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/readMore.js?\n}"); 666 667/***/ }, 668 669/***/ "./dev/js/components/recommendedProducts.js" 670/*!**************************************************!*\ 671 !*** ./dev/js/components/recommendedProducts.js ***! 672 \**************************************************/ 673(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 674 675"use strict"; 676eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\n/* harmony import */ var _helper_addProduct__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../helper/addProduct */ \"./dev/js/helper/addProduct.js\");\n/* harmony import */ var _helper_formatPrice__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../helper/formatPrice */ \"./dev/js/helper/formatPrice.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to de
676structure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\n\n\n\n\nvar RecommendedProducts = /*#__PURE__*/function (_HTMLElement) {\n function RecommendedProducts() {\n var _this;\n _classCallCheck(this, RecommendedProducts);\n _this = _callSuper(this, RecommendedProducts);\n _defineProperty(_this, \"hideIfEmpty\", function () {\n if (_this.swiper && _this.swiper.slides.length === 0) {\n _this.hidden = true;\n }\n });\n _defineProperty(_this, \"changeVariant\", function () {\n _this.swatches.forEac
676h(function (swatch) {\n swatch.addEventListener('click', function () {\n var _swatch$dataset$varia = swatch.dataset.variant.split('||'),\n _swatch$dataset$varia2 = _slicedToArray(_swatch$dataset$varia, 5),\n id = _swatch$dataset$varia2[0],\n title = _swatch$dataset$varia2[1],\n price = _swatch$dataset$varia2[2],\n comparePrice = _swatch$dataset$varia2[3],\n image = _swatch$dataset$varia2[4];\n var slide = swatch.closest('.swiper-slide');\n if (!slide) return;\n var currency = document.documentElement.getAttribute('currency') || '';\n var titleEl = slide.querySelector('.title');\n var priceEl = slide.querySelector('[data-target-price]');\n var compareEl = slide.querySelector('[data-target-compare_at_price]');\n var imageEl = slide.querySelector('.image img');\n var buttonEl = slide.querySelector('.button');\n if (titleEl) titleEl.textContent = title.trim();\n if (imageEl) imageEl.srcset = image.trim();\n if (buttonEl) buttonEl.dataset.variant = id.trim();\n if (priceEl) priceEl.textContent = (0,_helper_formatPrice__WEBPACK_IMPORTED_MODULE_3__.formatPrice)(parseInt(price, 10)) + ' ' + currency;\n if (compareEl) {\n var cmp = parseInt(comparePrice, 10);\n if (cmp > 0) {\n compareEl.textContent = (0,_helper_formatPrice__WEBPACK_IMPORTED_MODULE_3__.formatPrice)(cmp) + ' ' + currency;\n compareEl.removeAttribute('hidden');\n } else {\n compareEl.textContent = '';\n compareEl.setAttribute('hidden', '');\n }\n }\n });\n });\n });\n _defineProperty(_this, \"addVariant\", function () {\n var buttons = _this.querySelectorAll('.button');\n buttons.forEach(function (button) {\n button.addEventListener('click', function () {\n button.classList.add('animate');\n var variant = button.dataset.variant;\n if (!variant) return;\n var data = {\n id: variant,\n quantity: 1\n };\n var slide = button.closest('.swiper-slide');\n setTimeout(function () {\n if (_this.drawerContent) {\n _this.drawerContent.scrollTo({\n top: 0,\n behavior: 'smooth'\n });\n }\n (0,_helper_addProduct__WEBPACK_IMPORTED_MODULE_2__.addProduct)(data, false, true).then(function () {\n button.classList.remove('animate');\n\n // Remove the slide for this product from the swiper\n if (slide && _this.swiper) {\n // Find the index of this slide in Swiper's slides array-like\n var slideIndex = Array.prototype.indexOf.call(_this.swiper.slides, slide);\n if (slideIndex !== -1) {\n _this.swiper.removeSlide(slideIndex);\n _this.swiper.update();\n } else {\n // Fallback: just remove from DOM and update\n slide.remove();\n _this.swiper.update();\n }\n _this.hideIfEmpty();\n }\n });\n }, 2000);\n });\n });\n });\n _this.swiperContainer = _this.querySelector('.swiper');\n _this.nextBtn = _this.querySelector('next-button-component');\n _this.prevBtn = _this.querySelector('prev-button-component');\n _this.swatches = _this.querySelectorAll('.swatch');\n _this.drawerContent = document.querySelector('.drawer__content');\n return _this;\n }\n _inherits(RecommendedProducts, _HTMLElement);\n return _createClass(RecommendedProducts, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this$swiperContainer;\n if (!((_this$swiperContainer = this.swiperContainer) !== null && _this$swiperContainer !== void 0 && _this$swiperContainer.querySelector('.swiper-slide'))) {\n this.hidden = true;\n return;\n }\n this.swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.swiperContainer, {\n modules: [swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Navigation, swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Mousewheel],\n spaceBetween: 20,\n slidesOffsetBefore: 24,\n slidesOffsetAfter: 24,\n slidesPerView: 1.25,\n mousewheel: {\n forceToAxis: true,\n thresholdDelta: 10,\n thresholdTime: 600\n },\n navigation: {\n nextEl: this.nextBtn,\n prevEl: this.prevBtn,\n disabledClass: 'o
676pacity'\n },\n breakpoints: {\n 720: {\n slidesOffsetBefore: 40,\n slidesOffsetAfter: 40\n }\n }\n });\n this.changeVariant();\n this.addVariant();\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('recommended-products-component', RecommendedProducts);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/recommendedProducts.js?\n}"); 677 678/***/ }, 679 680/***/ "./dev/js/components/return.js" 681/*!*************************************!*\ 682 !*** ./dev/js/components/return.js ***! 683 \*************************************/ 684() { 685 686eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
686\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar ReturnComponent = /*#__PURE__*/function (_HTMLElement) {\n function ReturnComponent() {\n var _this;\n _classCallCheck(this, ReturnComponent);\n _this = _callSuper(this, ReturnComponent);\n // Dom-Elemente referenzieren\n _this.formState = _this.querySelector('.state--form');\n _this.successState = _this.querySelector('.state--success');\n _this.shippedState = _this.querySelector('.state--shipped');\n _this.errorState = _this.querySelector('.state--error');\n _this.returnLinkBtn = _this.querySelector('.state--shipped a.button');\n _this.orderInput = _this.querySelector('.order-input');\n _this.emailInput = _this.querySelector('.email-input');\n _this.submitBtn = _this.querySelector('.submit-btn');\n _this.resetBtns = _this.querySelectorAll('.reset-btn');\n return _this;\n }\n _inherits(ReturnComponent, _HTMLElement);\n return _createClass(ReturnComponent, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n if (this.submitBtn) {\n this.submitBtn.addEventListener('click', function () {\n return _this2.submit();\n });\n }\n this.resetBtns.forEach(function (btn) {\n btn.addEventListener('click', function () {\n return _this2.reset();\n });\n });\n\n // Enter-Key Support für bessere UX\n [this.orderInput, this.emailInput].forEach(function (input) {\n if (input) {\n input.addEventListener('keypress', function (e) {\n if (e.key === 'Enter') _this2.submit();\n });\n }\n });\n }\n }, {\n key: \"hideAllStates\",\n value: function hideAllStates() {\n if (this.formState) this.formState.hidden = true;\n if (this.successState) this.successState.hidden = true;\n if (this.shippedState) this.shippedState.hidden = true;\n if (this.errorState) this.errorState.hidden = true;\n }\n }, {\n key: \"reset\",\n value: function reset() {\n this.hideAllStates();\n if (this.formState) this.formState.hidden = false;\n if (this.orderInput) this.orderInput.value = '';\n if (this.emailInput) this.emailInput.value = '';\n }\n }, {\n key: \"submit\",\n value: function () {\n var _submit = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var order, email, originalText, response, data, encodedOrder, encodedEmail, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n order = this.orderInput.value.trim();\n email = this.emailInput.value.trim(); // Felder prüfen\n if (!(!order || !email)) {\n _context.n = 1;\n break;\n }\n alert(this.submitBtn.dataset.errorText || 'Bitte fülle alle Felder aus.');\n return _context.a(2);\n case 1:\n originalText = this.submitBtn.textContent;\n this.submitBtn.disabled = true;\n this.submitBtn.textContent = this.submitBtn.dataset.loadingText || 'Wird geprüft...';\n _context.p = 2;\n _context.n = 3;\n return fetch('https://gotbag.app.n8n.cloud/webhook/7148f6b1-8f6e-40ce-9c27-493e7c113f7f', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n orderName: order,\n email: email\n })\n });\n case 3:\n response = _context.v;\n _context.n = 4;\n return response.json();\n case 4:\n data = _context.v;\n // --- DEBUGGING AUSGABE ---\n console.log(\"=== Webhook Response ===\");\n console.log(\"HTTP Status:\", response.status);\n console.log(\"Return Data:\", data);\n console.log(\"========================\");\n this.hideAllStates();\n\n // Webhook Status Logic\n if (data.status === 'error' && data.message === 'bc') {\n // Paket bereits unterwegs (Code: bc) -> \"shipped_info_text\" Screen\n if (this.returnLinkBtn) {\n encodedOrder = encodeURIComponent(order);\n encodedEmail = encodeURIComponent(email);\n this.returnLinkBtn.href = \"https://got-bag.returnsportal.online/orders?filter[invoice_number]=\".concat(encodedOrder, \"&filter[customer][email]=\").concat(encodedEmail);\n }\n if (this.shippedState) this.shippedState.hidden = false;\n } else if (data.status === 'error' && data.message === 'e-mail') {\n // Falsc
686he E-Mail / Bestellung nicht gefunden -> \"order_not_found_text\" Screen\n if (this.errorState) this.errorState.hidden = false;\n } else if (response.status === 200 && data.status !== 'error') {\n // Erfolgreich storniert (Kein Fehler gemeldet)\n if (this.successState) this.successState.hidden = false;\n } else {\n // Genereller Fallback für alle anderen unbekannten Fehler\n if (this.errorState) this.errorState.hidden = false;\n }\n _context.n = 6;\n break;\n case 5:\n _context.p = 5;\n _t = _context.v;\n // Netzwerkfehler oder andere Probleme\n console.error(\"Fetch Error:\", _t);\n this.hideAllStates();\n if (this.errorState) this.errorState.hidden = false;\n case 6:\n _context.p = 6;\n this.submitBtn.disabled = false;\n this.submitBtn.textContent = originalText;\n return _context.f(6);\n case 7:\n return _context.a(2);\n }\n }, _callee, this, [[2, 5, 6, 7]]);\n }));\n function submit() {\n return _submit.apply(this, arguments);\n }\n return submit;\n }()\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nif (!customElements.get('return-component')) {\n customElements.define('return-component', ReturnComponent);\n}\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/return.js?\n}"); 687 688/***/ }, 689 690/***/ "./dev/js/components/reviewsIoSection.js" 691/*!***********************************************!*\ 692 !*** ./dev/js/components/reviewsIoSection.js ***! 693 \***********************************************/ 694() { 695 696eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
696 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
696 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar ReviewsIoSection = /*#__PURE__*/function (_HTMLElement) {\n function ReviewsIoSection() {\n var _this;\n _classCallCheck(this, ReviewsIoSection);\n _this = _callSuper(this, ReviewsIoSection);\n _this.customerData = null;\n _this.pointsHistory = null;\n\n // API-Daten\n _this.apiData = {\n customerId: _this.dataset.customerId,\n customerEmail: _this.dataset.customerEmail,\n shop: _this.dataset.shop,\n digest: _this.dataset.customerDigest\n };\n\n // Ãbersetzungen\n _this.texts = {\n maxLevel: _this.dataset.textMaxLevel,\n pointsToNext: _this.dataset.textPointsToNext,\n congrats: _this.dataset.textCongrats,\n calendarBtn: _this.dataset.textCalendarBtn,\n treasureBtn: _this.dataset.textTreasureBtn\n };\n return _this;\n }\n _inherits(ReviewsIoSection, _HTMLElement);\n return _createClass(ReviewsIoSection, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.renderBlocks();\n }\n }, {\n key: \"fetchData\",\n value: function () {\n var _fetchData = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var response, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n _context.p = 0;\n _context.n = 1;\n return fetch(\"https://launcher.api.influence.io/launcher/v1/customer?\" + new URLSearchParams({\n customer_id: this.apiData.customerId,\n customer_email: this.apiData.customerEmail,\n shop: 'gotbag.myshopify.com',\n digest: this.apiData.digest\n }), {\n headers: {\n \"content-type\": \"application/json\"\n }\n });\n case 1:\n response = _context.v;\n if (response.ok) {\n _context.n = 2;\n break;\n }\n throw new Error(\"Failed to fetch data from API\");\n case 2:\n _context.n = 3;\n return response.json();\n case 3:\n return _context.a(2, _context.v);\n case 4:\n _context.p = 4;\n _t = _context.v;\n console.error(\"Error fetching customer data:\", _t);\n return _context.a(2, null);\n }\n }, _callee, this, [[0, 4]]);\n }));\n function fetchData() {\n return _fetchData.apply(this, arguments);\n }\n return fetchData;\n }()\n }, {\n key: \"renderBlocks\",\n value: function renderBlocks() {\n var _this2 = this;\n var blocks = this.querySelectorAll('[data-type]');\n blocks.forEach(function (block) {\n var blockType = block.dataset.type;\n switch (blockType) {\n case 'tier_list':\n _this2.renderTierList(block);\n break;\n case 'points_history':\n _this2.renderPointsHistory(block);\n break;\n }\n });\n }\n }, {\n key: \"renderTierList\",\n value: function () {\n var _renderTierList = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee2(block) {\n var _this3 = this;\n var data, currentLoyaltyTierProgress, tierItems, secondTier, secondTierPoints, hasReachedSecondTier, existingButton, maxLevelButton;\n return _regenerator().w(function (_context2) {\n while (1) switch (_context2.n) {\n case 0:\n _context2.n = 1;\n return this.fetchData();\n case 1:\n data = _context2.v;
696\n if (data) {\n _context2.n = 2;\n break;\n }\n return _context2.a(2);\n case 2:\n currentLoyaltyTierProgress = data.currentLoyaltyTierProgress;\n tierItems = block.querySelectorAll('.tier_list__item');\n secondTier = tierItems[1];\n secondTierPoints = parseInt(secondTier.dataset.points, 10);\n hasReachedSecondTier = currentLoyaltyTierProgress >= secondTierPoints;\n if (hasReachedSecondTier) {\n existingButton = secondTier.querySelector('.button--primary');\n if (!existingButton) {\n maxLevelButton = document.createElement(\"a\");\n maxLevelButton.className = 'button button--primary';\n maxLevelButton.target = '_blank';\n maxLevelButton.href = 'https://www.addevent.com/calendar/Lu524675';\n maxLevelButton.textContent = this.texts.calendarBtn;\n secondTier.appendChild(maxLevelButton);\n }\n }\n tierItems.forEach(function (tierItem, index) {\n var pointsRequired = parseInt(tierItem.dataset.points, 10);\n var nextTier = tierItems[index + 1];\n var nextTierPoints = nextTier ? parseInt(nextTier.dataset.points, 10) : null;\n var progressPercentage = nextTier ? (currentLoyaltyTierProgress - pointsRequired) / (nextTierPoints - pointsRequired) * 100 : 100;\n var isCurrentTier = currentLoyaltyTierProgress >= pointsRequired && (!nextTier || currentLoyaltyTierProgress < nextTierPoints);\n tierItem.classList.toggle('active', isCurrentTier);\n if (isCurrentTier) {\n if (nextTier) {\n // Fortschrittsanzeige\n var progressContainer = document.createElement('div');\n progressContainer.className = 'progress-container';\n var progressBar = document.createElement('div');\n progressBar.className = 'progress-bar';\n progressBar.style.width = \"\".concat(progressPercentage, \"%\");\n progressContainer.appendChild(progressBar);\n var nextTierText = document.createElement('p');\n nextTierText.className = 'next-tier';\n nextTierText.textContent = _this3.texts.pointsToNext.replace('{{count}}', nextTierPoints - currentLoyaltyTierProgress).replace('{{tier}}', nextTier.querySelector('.heading').textContent);\n tierItem.appendChild(progressContainer);\n tierItem.appendChild(nextTierText);\n\n // Button in der 2. Stufe\n // if (index === 1) {\n // console.log('index -----' + index)\n // const calendarButton = document.createElement(\"a\");\n // calendarButton.className = 'button button--primary';\n // calendarButton.target = '_blank';\n // calendarButton.href = 'https://www.addevent.com/calendar/Lu524675';\n // calendarButton.textContent = this.texts.calendarBtn;\n // tierItem.appendChild(calendarButton);\n // }\n } else {\n // Letzte Stufe: Glückwunsch + Schatzkisten-Button\n var locale = document.documentElement.lang || \"de\"; // falls kein lang-Attribut gesetzt ist\n\n var treasureUrl = \"/pages/treasure-chest\";\n if (locale !== \"de\") {\n treasureUrl = \"/\".concat(locale, \"/pages/treasure-chest\");\n }\n var maxLevelText = document.createElement('p');\n maxLevelText.className = 'max-tier';\n maxLevelText.textContent = _this3.texts.congrats.replace('{{tier}}', tierItem.querySelector('.heading').textContent);\n tierItem.appendChild(maxLevelText);\n var treasureButton = document.createElement(\"a\");\n treasureButton.className = \"button button--primary\";\n treasureButton.href = treasureUrl;\n treasureButton.target = \"_blank\";\n treasureButton.textContent = _this3.texts.treasureBtn;\n tierItem.appendChild(treasureButton);\n }\n }\n });\n case 3:\n return _context2.a(2);\n }\n }, _callee2, this);\n }));\n function renderTierList(_x) {\n return _renderTierList.apply(this, arguments);\n }\n return renderTierList;\n }()\n }, {\n key: \"renderPointsHistory\",\n value: function renderPointsHistory(block) {\n var _this$pointsHistory;\n var tableBody = block.querySelector('table tbody');\n if (!((_this$pointsHistory = this.pointsHistory) !== null && _this$pointsHistory !== void 0 && _this$pointsHistory.items)) return;
696\n this.pointsHistory.items.forEach(function (entry) {\n var row = document.createElement('tr');\n row.innerHTML = \"\\n <td>\".concat(new Date(entry.createdAt).toLocaleDateString(), \"</td>\\n <td>\").concat(entry.action || 'Keine Aktion angegeben', \"</td>\\n <td>\").concat(entry.points > 0 ? \"+\".concat(entry.points) : entry.points, \"</td>\\n <td>\").concat(entry.type, \"</td>\\n \");\n tableBody.appendChild(row);\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('reviews-section', ReviewsIoSection);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/reviewsIoSection.js?\n}"); 697 698/***/ }, 699 700/***/ "./dev/js/components/reviewsSlider.js" 701/*!********************************************!*\ 702 !*** ./dev/js/components/reviewsSlider.js ***! 703 \********************************************/ 704(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 705 706"use strict"; 707eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
707 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\n\nvar ReviewsSlider = /*#__PURE__*/function (_HTMLElement) {\n function ReviewsSlider() {\n var _this;\n _classCallCheck(this, ReviewsSlider);\n _this = _callSuper(this, ReviewsSlider);\n _this.carousel = null;\n return _this;\n }\n _inherits(ReviewsSlider, _HTMLElement);\n return _createClass(ReviewsSlider, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"].use([swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Navigation, swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Autoplay]);\n var swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this, {\n slidesPerView: 1,\n spaceBetween: 20,\n loop: true,\n navigation: {\n nextEl: '.swiper-button-next',\n prevEl: '.swiper-button-prev'\n },\n autoplay: {\n delay: 5000\n },\n breakpoints: {\n 720: {\n slidesPerView: 2\n },\n 1000: {\n slidesPerView: 3\n }\n }\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('reviews-slider', ReviewsSlider);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/reviewsSlider.js?\n}"); 708 709/***/ }, 710 711/***/ "./dev/js/components/revocation.js" 712/*!*****************************************!*\ 713 !*** ./dev/js/components/revocation.js ***! 714 \*****************************************/ 715() { 716 717eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
717 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); }
717 return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar RevocationComponent = /*#__PURE__*/function (_HTMLElement) {\n function RevocationComponent() {\n var _this;\n _classCallCheck(this, RevocationComponent);\n _this = _callSuper(this, RevocationComponent);\n _this.formState = _this.querySelector('.state--form');\n _this.successState = _this.querySelector('.state--success');\n _this.errorState = _this.querySelector('.state--error');\n _this.orderInput = _this.querySelector('.order-input');\n _this.emailInput = _this.querySelector('.email-input');\n _this.submitBtn = _this.querySelector('.submit-btn');\n _this.resetBtns = _this.querySelectorAll('.reset-btn');\n return _this;\n }\n _inherits(RevocationComponent, _HTMLElement);\n return _createClass(RevocationComponent, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n if (this.submitBtn) {\n this.submitBtn.addEventListener('click', function () {\n return _this2.submit();\n });\n }\n this.resetBtns.forEach(function (btn) {\n btn.addEventListener('click', function () {\n return _this2.reset();\n });\n });\n [this.orderInput, this.emailInput].forEach(function (input) {\n if (input) {\n input.addEventListener('keypress', function (e) {\n if (e.key === 'Enter') _this2.submit();\n });\n }\n });\n }\n }, {\n key: \"hideAllStates\",\n value: function hideAllStates() {\n if (this.formState) this.formState.hidden = true;\n if (this.successState) this.successState.hidden = true;\n if (this.errorState) this.errorState.hidden = true;\n }\n }, {\n key: \"reset\",\n value: function reset() {\n this.hideAllStates();\n if (this.formState) this.formState.hidden = false;\n if (this.orderInput) this.orderInput.value = '';\n if (this.emailInput) this.emailInput.value = '';\n }\n }, {\n key: \"submit\",\n value: function () {\n var _submit = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var order, email, originalText, response, data, text, _t, _t2;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n order = this.orderInput.value.trim();\n email = this.emailInput.value.trim();\n if (!(!order || !email)) {\n _context.n = 1;\n break;\n }\n alert(this.submitBtn.dataset.errorText || 'Bitte fülle alle Felder aus.');\n return _context.a(2);\n case 1:\n originalText = this.submitBtn.textContent;\n this.submitBtn.disabled = true;\n this.submitBtn.textContent = this.submitBtn.dataset.loadingText || 'Wird bearbeitet...';\n _context.p = 2;\n _context.n = 3;\n return fetch('https://gotbag.app.n8n.cloud/webhook/7148f6b1-8f6e-40ce-9c27-493e7c113f7f', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n orderName: order,\n email: email,\n language: document.documentElement.lang || 'de',\n revocation: true\n })\n });\n case 3:\n response = _context.v;\n data = {};\n _context.p = 4;\n _context.n = 5;\n return response.text();\n case 5:\n text = _context.v;\n if (text) data = JSON.parse(text);\n _context.n = 7;\n break;\n case 6:\n _context.p = 6;\n _t = _context.v;\n case 7:\n console.log('=== Revocation Webhook Response ===');\n console.log('HTTP Status:', response.status);\n console.log('Response Data:', data);\n console.log('===================================');\n this.hideAllStates();\n if (response.status === 200 && data.status !== 'error') {\n if (this.successState) this.successState.hidden = false;\n } else if (data.status === 'error' && data.message === 'e-mail') {\n if (this.errorState) this.errorState.hidden = false;\n } else {\n if (this.errorState) this.errorState.hidden = false;\n }\n _context.n = 9;\n break;\n case 8:\n _context.p = 8;\n _t2 = _context.v;\n console.error('Revocation Fetch Error:', _t2);\n this.hideAllStates();\n if (this.errorState) this.errorState.hidden = false;\n case 9:\n _context.p = 9;\n this.submitBtn.disabled = false;\n this.submitBtn.textContent = originalText;\n return _context.f(9);\n case 10:\n return _context.a(2);\n }\n }, _callee, this, [[4, 6], [2, 8, 9, 10]]);\n }));\n function submit() {\n return _submit.apply(this, arguments);\n }\n return submit;\n }()\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nif (!customElements.get('revocation-component')) {\n customElements.define('revocation-component', RevocationComponent);\n}\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/revocation.js?\n}"); 718 719/***/ }, 720 721/***/ "./dev/js/components/richText.js" 722/*!***************************************!*\ 723 !*** ./dev/js/components/richText.js ***! 724 \***************************************/ 725(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 726 727"use strict"; 728eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
728\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar RichText = /*#__PURE__*/function (_HTMLElement) {\n function RichText() {\n var _this;\n _classCallCheck(this, RichText);\n _this = _callSuper(this, RichText);\n _this.headline = _this.querySelector('.headline');\n _this.heading = _this.querySelector('.heading');\n _this.wrapper = _this.querySelector('.wrapper');\n _this.text = _this.querySelector('.text');\n _this.button = _this.querySelector('.button-wrapper');\n return _this;\n }\n _inherits(RichText, _HTMLElement);\n return _createClass(RichText, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n // Check if the RichText element has the class 'animate'\n if (this.classList.contains('animate')) {\n this.initAnimation();\n }\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n var timeline = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this.wrapper,\n start: 'top center',\n end: 'bottom 20%',\n toggleActions: 'play none none none',\n //markers: true,\n pinSpacing: true\n }\n });\n\n // Animate the headline if it exists\n if (this.heading) {\n timeline.from(this.heading, {\n opacity: 0,\n y: 20,\n // Move up from 50px\n duration: 1,\n ease: 'power2.out'\n });\n }\n\n // Animate the heading if it exists\n if (this.headline) {\n timeline.from(this.headline, {\n opacity: 0,\n y: 20,\n // Move up from 50px\n duration: 1,\n ease: 'power2.out'\n }, this.heading ? '-=0.2' : ''); // Only offset if headline exists\n }\n\n // Animate the text paragraphs if they exist\n if (this.text) {\n timeline.from(this.text, {\n opacity: 0,\n y: 20,\n duration: 1,\n stagger: 0.2,\n // Stagger the animation for each paragraph\n ease: 'power2.out'\n }, this.headline || this.heading ? '-=0.2' : ''); // Offset if thereâs a prior animation\n }\n\n // Animate the button if it exists\n if (this.button) {\n timeline.from(this.button, {\n opacity: 0,\n y: 10,\n duration: 1,\n ease: 'power2.out'\n }, this.headline || this.heading || this.text.length > 0 ? '-=0.3' : ''); // Offset if thereâs a prior animation\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"rich-text\", RichText);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/richText.js?\n}"); 729 730/***/ }, 731 732/***/ "./dev/js/components/rotatingImage.js" 733/*!********************************************!*\ 734 !*** ./dev/js/components/rotatingImage.js ***! 735 \********************************************/ 736(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 737 738"use strict"; 739eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
739\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar RotatingImage = /*#__PURE__*/function (_HTMLElement) {\n function RotatingImage() {\n var _this;\n _classCallCheck(this, RotatingImage);\n _this = _callSuper(this, RotatingImage);\n _this.wrapper = _this.querySelector(\".rotating-image__image-container\"); // ÃuÃere Ebene für Scrollsteuerung\n _this.image = _this.querySelector(\"img\"); // Innere Ebene für konstante Drehung\n _this.lastScrollY = window.scrollY; // Speichert letzte Scroll-Position\n return _this;\n }\n _inherits(RotatingImage, _HTMLElement);\n return _createClass(RotatingImage, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n window.onload = function () {\n _this2.initAnimation();\n };\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n var _this3 = this;\n if (!this.image || !this.wrapper) return;\n var tl = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n repeat: -1,\n paused: false\n });\n tl.to(this.image, {\n rotation: \"+=1440\",\n duration: 320,\n ease: \"linear\"\n });\n tl.progress(0.5);\n window.addEventListener(\"scroll\", function () {\n var scrollSpeed = window.scrollY > _this3.lastScrollY ? 1 : -1;\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(tl, {\n timeScale: scrollSpeed,\n duration: 1,\n ease: \"power1.out\"\n });\n _this3.lastScrollY = window.scrollY;\n });\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(this.wrapper, {\n scrollTrigger: {\n trigger: this.wrapper,\n start: \"top bottom\",\n end: \"bottom top\",\n scrub: 2\n },\n rotation: \"+=180\",\n ease: \"power1.out\"\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('rotating-image', RotatingImage);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/rotatingImage.js?\n}"); 740 741/***/ }, 742 743/***/ "./dev/js/components/saleButton.js" 744/*!*****************************************!*\ 745 !*** ./dev/js/components/saleButton.js ***! 746 \*****************************************/ 747() { 748 749eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
749\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar SaleButton = /*#__PURE__*/function (_HTMLElement) {\n function SaleButton() {\n var _this;\n _classCallCheck(this, SaleButton);\n _this = _callSuper(this, SaleButton);\n _this.activeSaleFilter = '*';\n return _this;\n }\n _inherits(SaleButton, _HTMLElement);\n return _createClass(SaleButton, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n this.addEventListener('click', function (event) {\n var button = event.target.closest('[data-sale]');\n if (!button) return;\n var id = button.dataset.info;\n _this2.querySelectorAll('span.sale-button__infotext').forEach(function (el) {\n return el.style.display = 'none';\n });\n if (id) {\n var infoEl = _this2.querySelector(\".sale-button__infotext[data-info=\\\"\".concat(id, \"\\\"]\"));\n if (infoEl) infoEl.style.display = 'block';\n }\n _this2.setSaleFilter(button.getAttribute('data-sale'));\n });\n var saleValueFromURL = this.getSaleValueFromURL();\n if (saleValueFromURL) {\n var matchingButton = Array.from(this.querySelectorAll('[data-sale]')).find(function (btn) {\n return btn.getAttribute('data-sale').toLowerCase() === saleValueFromURL.toLowerCase();\n });\n var filterValue = matchingButton ? matchingButton.getAttribute('data-sale') : saleValueFromURL;\n this.setSaleFilter(filterValue, true);\n } else {\n var firstSaleButton = this.querySelector('[data-sale]');\n if (firstSaleButton) this.setSaleFilter(firstSaleButton.getAttribute('data-sale'), true);\n }\n this.applyFilters();\n }\n }, {\n key: \"getSaleValueFromURL\",\n value: function getSaleValueFromURL() {\
749n var urlParams = new URLSearchParams(window.location.search);\n return urlParams.get('filter') || urlParams.get('sale');\n }\n }, {\n key: \"updateURL\",\n value: function updateURL(value) {\n var url = new URL(window.location.href);\n if (value === '*') {\n url.searchParams[\"delete\"]('filter');\n } else {\n url.searchParams.set('filter', value.toLowerCase());\n }\n window.history.replaceState({}, '', url.toString());\n }\n }, {\n key: \"setSaleFilter\",\n value: function setSaleFilter(value) {\n var isInitial = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n this.activeSaleFilter = value;\n this.querySelectorAll('[data-sale]').forEach(function (btn) {\n btn.classList.toggle('active', btn.getAttribute('data-sale') === value);\n });\n if (!isInitial) {\n this.updateURL(value);\n this.applyFilters();\n }\n }\n }, {\n key: \"parseFiltersAttr\",\n value: function parseFiltersAttr(attr) {\n if (!attr) return [];\n var txt = attr.trim().replace(/"/g, '\"');\n try {\n var parsed = JSON.parse(txt);\n if (Array.isArray(parsed)) {\n if (parsed.length === 1 && typeof parsed[0] === 'string' && parsed[0].includes(',')) {\n return parsed[0].split(',').map(function (s) {\n return s.trim();\n }).filter(Boolean);\n }\n return parsed.map(function (s) {\n return typeof s === 'string' ? s : String(s);\n });\n }\n } catch (e) {\n if (txt.startsWith('[') && txt.endsWith(']')) txt = txt.slice(1, -1);\n return txt.split(',').map(function (s) {\n return s.replace(/^\"+|\"+$/g, '').trim();\n }).filter(Boolean);\n }\n return [];\n }\n }, {\n key: \"getNumericSaleThresholds\",\n value: function getNumericSaleThresholds() {\n var vals = Array.from(this.querySelectorAll('[data-sale]')).map(function (btn) {\n return parseInt(btn.getAttribute('data-sale'), 10);\n }).filter(function (n) {\n return !Number.isNaN(n);\n });\n return Array.from(new Set(vals)).sort(function (a, b) {\n return a - b;\n });\n }\n }, {\n key: \"applyFilters\",\n value: function applyFilters() {\n var _this3 = this;\n var saleFilter = this.activeSaleFilter;\n var isNumeric = !Number.isNaN(parseInt(saleFilter, 10));\n var minSale = 0;\n var maxSale = Infinity;\n if (isNumeric) {\n var sel = parseInt(saleFilter, 10);\n var thresholds = this.getNumericSaleThresholds();\n var idx = thresholds.indexOf(sel);\n minSale = idx > 0 ? thresholds[idx - 1] + 1 : 0;\n maxSale = sel;\n }\n var products = document.querySelectorAll('product-card-component');\n var visibleProductCount = 0;\n products.forEach(function (item) {\n var wrapper = item.closest('animation-reveal') || item.parentElement;\n var matches = false;\n if (saleFilter === '*') {\n matches = true;\n } else if (isNumeric) {\n var itemSaleNum = parseInt(item.getAttribute('data-filter-price-percentage'), 10);\n matches = !Number.isNaN(itemSaleNum) && itemSaleNum >= minSale && itemSaleNum <= maxSale;\n } else {\n // Text-Filter â gegen data-filters der product-card prüfen\n var itemFilters = _this3.parseFiltersAttr(item.getAttribute('data-filters'));\n matches = itemFilters.some(function (f) {\n return f.toLowerCase() === saleFilter.toLowerCase();\n });\n }\n if (matches) {\n wrapper.removeAttribute('hidden');\n wrapper.classList.add('active');\n visibleProductCount++;\n } else {\n wrapper.setAttribute('hidden', '');\n wrapper.classList.remove('active');\n }\n });\n var emptyDiv = document.querySelector('.empty');\n if (emptyDiv) emptyDiv.classList.toggle('active', visibleProductCount === 0);\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\ncustomElements.define('sale-button', SaleButton);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/saleButton.js?\n}"); 750 751/***/ }, 752 753/***/ "./dev/js/components/saleHeaderBanner.js" 754/*!***********************************************!*\ 755 !*** ./dev/js/components/saleHeaderBanner.js ***! 756 \***********************************************/ 757(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 758 759"use strict"; 760eval("{__webpack_require__.r(__webpack_exports__);\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
760\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\nvar SaleHeaderBanner = /*#__PURE__*/function (_HTMLElement) {\n function SaleHeaderBanner() {\n _classCallCheck(this, SaleHeaderBanner);\n return _callSuper(this, SaleHeaderBanner);\n }\n _inherits(SaleHeaderBanner, _HTMLElement);\n return _createClass(SaleHeaderBanner, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {}\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\ncustomElements.define('sale-header-banner', SaleHeaderBanner);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/saleHeaderBanner.js?\n}"); 761 762/***/ }, 763 764/***/ "./dev/js/components/searchResults.js" 765/*!********************************************!*\ 766 !*** ./dev/js/components/searchResults.js ***! 767 \********************************************/ 768(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 769 770"use strict"; 771eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_isUs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/isUs */ \"./dev/js/helper/isUs.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
771\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\nvar SearchResults = /*#__PURE__*/function (_HTMLElement) {\n function SearchResults() {\n var _this;\n _classCallCheck(this, SearchResults);\n _this = _callSuper(this, SearchResults);\n _this.searchInput = document.querySelector(\"#predictive-search-form-input\");\n _this.productResultsContainer = document.querySelector(\"#main-product .predictive-search__results\");\n _this.searchResultsContainer = document.querySelector(\".predictive-search__results\");\n _this.pageResultsContainer = document.querySelector(\"#main-page\");\n _this.articleResultsContainer = document.querySelector(\"#main-article\");\n _this.loadingState = document.querySelector(\".predictive-search__loading-state\");\n _this.noResultsContainers = document.querySelectorAll(\".no_result\");\n\n // Tab buttons for displaying result counts\n _this.productTabButton = document.querySelector(\"[data-type='product'] span\");\n _this.pageTabButton = document.querySelector(\"[data-type='page'] span\");\n _this.articleTabButton = document.querySelector(\"[data-type='article'] span\");\n return _this;\n }\n _inherits(SearchResults, _HTMLElement);\n return _createClass(SearchResults, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n // Set the search input value from URL parameter if available\n var urlParams = new URLSearchParams(window.location.search);
771\n var query = urlParams.get('q');\n if (query) {\n this.searchInput.value = query;\n this.onSearchInput(); // Trigger search based on URL query\n }\n if (this.searchInput) {\n this.searchInput.addEventListener(\"input\", function () {\n _this2.resetSearch(); // Reset on each new input\n _this2.onSearchInput();\n });\n }\n }\n }, {\n key: \"resetSearch\",\n value: function resetSearch() {\n // Clear previous search results\n this.searchResultsContainer.innerHTML = \"\";\n\n // Reset tab counters to empty\n this.productTabButton.textContent = '';\n this.pageTabButton.textContent = '';\n this.articleTabButton.textContent = '';\n\n // Hide \"No Results\" messages initially\n this.noResultsContainers.forEach(function (container) {\n return container.hidden = true;\n });\n }\n }, {\n key: \"onSearchInput\",\n value: function onSearchInput() {\n var _this3 = this;\n var query = this.searchInput.value.trim();\n if (query.length < 2) {\n this.hideResults();\n return;\n }\n this.showLoadingState();\n fetch(\"/search/suggest.json?q=\".concat(query, \"&resources[type]=product,page,article\")).then(function (response) {\n return response.json();\n }
771).then(function (data) {\n var _data$resources;\n _this3.hideLoadingState();\n var results = ((_data$resources = data.resources) === null || _data$resources === void 0 ? void 0 : _data$resources.results) || {\n products: [],\n pages: [],\n articles: []\n };\n _this3.displaySearchResults(data.resources.results);\n })[\"catch\"](function (error) {\n console.error(\"Error fetching predictive search results:\", error);\n });\n }\n }, {\n key: \"hideResults\",\n value: function hideResults() {\n this.productResultsContainer.innerHTML = \"\";\n this.pageResultsContainer.innerHTML = \"\";\n this.articleResultsContainer.innerHTML = \"\";\n this.productResultsContainer.hidden = true;\n this.pageResultsContainer.hidden = true;\n this.articleResultsContainer.hidden = true;\n this.loadingState.hidden = true;\n }\n }, {\n key: \"showLoadingState\",\n value: function showLoadingState() {\n this.loadingState.hidden = false;\n }\n }, {\n key: \"hideLoadingState\",\n value: function hideLoadingState() {\n this.loadingState.hidden = true;\n }\n }, {\n key: \"displaySearchResults\",\n value: function displaySearchResults(results) {\n var _this4 = this;\n var _results$products = results.products,\n products = _results$products === void 0 ? [] : _results$products,\n _results$pages = results.pages,\n pages = _results$pages === void 0 ? [] : _results$pages,\n _results$articles = results.articles,\n articles = _results$articles === void 0 ? [] : _results$articles;\n\n // Clear previous results\n this.productResultsContainer.innerHTML = \"\";\n this.pageResultsContainer.innerHTML = \"\";\n this.articleResultsContainer.innerHTML = \"\";\n\n // Display products\n products.forEach(function (product) {\n if (product.variants.length > 0) {\n product.variants.filter(function (variant) {\n return variant.available;\n }) // Only include available variants\n .forEach(function (variant) {\n var productItem = _this4.createProductItem(product, variant);\n _this4.productResultsContainer.appendChild(productItem);\n });\n } else if (product.available) {\n var productItem = _this4.createProductItem(product);\n _this4.productResultsContainer.appendChild(productItem);\n }\n });\n\n // Display pages\n pages.forEach(function (page) {\n var pageItem = _this4.createPageItem(page);\n _this4.pageResultsContainer.appendChild(pageItem);\n });\n\n // Display articles\n articles.forEach(function (article) {\n var articleItem = _this4.createArticleItem(article);\n _this4.articleResultsContainer.appendChild(articleItem);\n });\n var displayedProductCount = 0;\n products.forEach(function (product) {\n if (product.variants.length > 0) {\n displayedProductCount += product.variants.filter(function (variant) {\n return variant.available;\n }).length;\n } else if (product.available) {\n displayedProductCount += 1;\n }\n });\n this.productTabButton.textContent = displayedProductCount > 0 ? displayedProductCount : '';\n this.pageTabButton.textContent = pages.length > 0 ? pages.length : '';\n this.articleTabButton.textContent = articles.length > 0 ? articles.length : '';\n this.productResultsContainer.hidden = products.length === 0;\n this.pageResultsContainer.hidden = pages.length === 0;\n this.articleResultsContainer.hidden = articles.length === 0;\n }\n }, {\n key: \"createProductItem\",\n value: function createProductItem(product) {\n var variant = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n var productItem = document.createElement(\"product-item\");\n productItem.className = \"product-item\";\n\n // Determine whether to use product or variant details\n var item = variant || product;\n var itemUrl = variant ? \"\".concat(product.url, \"?variant=\").concat(variant.id) : product.url;\n var itemTitle = variant ? \"\".concat(product.title, \" - \").concat(variant.title) : product.title;\n var price = parseFloat(item.price) || 0;\n // variant.compare_at_price is often null in the Predictive Search API; fall back to product-level max\n var compareAtPrice = parseFloat(item.compare_at_price || product.compare_at_price_max) || 0;\n var symbol = (0,_helper_isUs__WEBPACK_IMPORTED_MODULE_0__.getCurrencySymbol)();\n var formatPrice = function formatPrice(n) {\n return n.toFixed(2).replace(/\\.00$/, '');\n };\n\n // Calculate discount percentage if compare_at_price is greater than price\n var discountPercentage = compareAtPrice > price ? Math.round((compareAtPrice - price) / compareAtPrice * 100) : null;\n productItem.innerHTML = \"\\n <div class=\\\"product-item__image-wrapper\\\">\\n <a href=\\\"\".concat(itemUrl, \"\\\" class=\\\"product-item__link\\\">\\n \").concat(discountPercentage ? \"\\n <div class=\\\"product-item__tags\\\">
771\\n <span class=\\\"label label--highlight\\\">-\".concat(discountPercentage, \"%</span>\\n </div>\\n \") : \"\", \"\\n <img src=\\\"\").concat(product.featured_image.url, \"\\\" alt=\\\"\").concat(product.featured_image.alt, \"\\\" width=\\\"420\\\" height=\\\"420\\\" class=\\\"product-item__primary-image\\\">\\n </a>\\n </div>\\n <div class=\\\"product-item__info text--left\\\">\\n <a href=\\\"\").concat(itemUrl, \"\\\" class=\\\"product-item__title\\\">\").concat(itemTitle, \"</a>\\n \\n <div class=\\\"product-item__price\\\">\\n \").concat(compareAtPrice > price ? \"\\n <span class=\\\"price price--compare strike-through\\\">\".concat(symbol).concat(formatPrice(compareAtPrice), \"</span>\\n <span class=\\\"price price--highlight\\\">\").concat(symbol).concat(formatPrice(price), \"</span>\\n \") : \"\\n <span class=\\\"price\\\">\".concat(symbol).concat(formatPrice(price), \"</span>\\n \"), \"\\n </div>\\n </div>\\n \");\n return productItem;\n }\n }, {\n key: \"createPageItem\",\n value: function createPageItem(page) {\n var pageItem = document.createElement(\"div\");\n pageItem.className = \"page-item\";\n pageItem.innerHTML = \"\\n <a href=\\\"\".concat(page.url, \"\\\" class=\\\"page-item__link\\\">\\n <h3 class=\\\"page-item__title\\\">\").concat(page.title, \"</h3>\\n <p class=\\\"page-item__snippet\\\">\").concat(page.body.substring(0, 100), \"...</p>\\n </a>\\n \");\n return pageItem;\n }\n }, {\n key: \"createArticleItem\",\n value: function createArticleItem(article) {\n var articleItem = document.createElement(\"div\");\n articleItem.className = \"article-item\";\n console.log(article);\n articleItem.innerHTML = \"\\n <a href=\\\"\".concat(article.url, \"\\\" class=\\\"article-item__link\\\">\\n <h3 class=\\\"article-item__title\\\">\").concat(article.title, \"</h3>\\n <p class=\\\"article-item__snippet\\\">\").concat(article.body.substring(0, 300), \"...</p>\\n </a>\\n \");\n return articleItem;\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('search-results', SearchResults);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/searchResults.js?\n}"); 772 773/***/ }, 774 775/***/ "./dev/js/components/shopTheLookAnimation.js" 776/*!***************************************************!*\ 777 !*** ./dev/js/components/shopTheLookAnimation.js ***! 778 \***************************************************/ 779(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 780 781"use strict"; 782eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\n/* harmony import */ var _helper_isMobile__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../helper/isMobile */ \"./dev/js/helper/isMobile.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
782\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar ShopTheLookAnimation = /*#__PURE__*/function (_HTMLElement) {\n function ShopTheLookAnimation() {\n var _this;\n _classCallCheck(this, ShopTheLookAnimation);\n _this = _callSuper(this, ShopTheLookAnimation);\n // New selectors based on your provided Liquid\n _this.container = _this.querySelector('.container');\n _this.headline = _this.querySelector('.headline');\n _this.points = _this.querySelectorAll('.point');\n return _this;\n }\n _inherits(ShopTheLookAnimation, _HTMLElement);\n return _createClass(ShopTheLookAnimation, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n // Wait for fonts/layout to be ready\n document.fonts.ready.then(function () {\n _this2.initAnimation();\n });\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n if (!this.container) return;\n var tl = gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.timeline({\n scrollTrigger: {\n trigger: this,\n // Triggers when the section enters view\n start: _helper_isMobile__WEBPACK_IMPORTED_MODULE_2__.isMobile ? \"top center+=20%\" : \"top center\",\n end: \"bottom center\",\n toggleActions: \"play none none none\"\n // markers: true, // Uncomment to debug\n }\n });\n\n // 1. Animate Headline in\n if (this.headline) {\n tl.from(this.headline, {\n y: 30,\n opacity: 0,\n duration: 0.8,\n ease: \"power2.out\"\n });\n }\n\n // 2. Animate List Points (Staggered)\n if (this.points.length > 0) {\n tl.from(this.points, {\n y: 20,\n opacity: 0,\n duration: 0.5,\n stagger: 0.15,\n // One after another\n ease: \"power2.out\"\n }, \"-=0.4\"); // Starts slightly before headline finishes\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement)); // Ensure the name matches the tag in your Liquid file\nif (!customElements.get('shop-the-look-animation')) {\n window.customElements.define('shop-the-look-animation', ShopTheLookAnimation);\n}\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/shopTheLookAnimation.js?\n}"); 783 784/***/ }, 785 786/***/ "./dev/js/components/showMoreButton.js" 787/*!*********************************************!*\ 788 !*** ./dev/js/components/showMoreButton.js ***! 789 \*********************************************/ 790() { 791 792eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
792\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar showMoreButton = /*#__PURE__*/function (_HTMLElement) {\n function showMoreButton() {\n _classCallCheck(this, showMoreButton);\n return _callSuper(this, showMoreButton);\n }\n _inherits(showMoreButton, _HTMLElement);\n return _createClass(showMoreButton, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var btn = this.querySelector('.unhide-all');\n var hideBtn = this.querySelector('.hide-all');\n if (!btn || !hideBtn) return;\n btn.addEventListener('click', function () {\n // un-hide everything\n document.querySelectorAll('.extra-media.hidden').forEach(function (el) {\n return el.classList.remove('hidden');\n });\n // swap the buttons\n btn.classList.add('hidden');\n hideBtn.classList.remove('hidden');\n });\n hideBtn.addEventListener('click', function () {\n // scroll up a bit\n window.scrollTo({\n top: 600,\n behavior: 'smooth'\n });\n // hide the extra-media items again\n document.querySelectorAll('.extra-media').forEach(function (el) {\n return el.classList.add('hidden');\n });\n // swap the buttons back\n hideBtn.classList.add('hidden');\n btn.classList.remove('hidden');\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('show-more-button', showMoreButton);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/showMoreButton.js?\n}"); 793 794/***/ }, 795 796/***/ "./dev/js/components/subnavDesktop.js" 797/*!********************************************!*\ 798 !*** ./dev/js/components/subnavDesktop.js ***! 799 \********************************************/ 800() { 801 802eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
802\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar SubnavDesktop = /*#__PURE__*/function (_HTMLElement) {\n function SubnavDesktop() {\n _classCallCheck(this, SubnavDesktop);\n return _callSuper(this, SubnavDesktop);\n }\n _inherits(SubnavDesktop, _HTMLElement);\n return _createClass(SubnavDesktop, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {}\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('subnav-desktop-component', SubnavDesktop);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/subnavDesktop.js?\n}"); 803 804/***/ }, 805 806/***/ "./dev/js/components/swatch.js" 807/*!*************************************!*\ 808 !*** ./dev/js/components/swatch.js ***! 809 \*************************************/ 810() { 811 812eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
812\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar SwatchComponent = /*#__PURE__*/function (_HTMLElement) {\n function SwatchComponent() {\n var _this;\n _classCallCheck(this, SwatchComponent);\n _this = _callSuper(this, SwatchComponent);\n _this.clickable = _this.getAttribute(\"data-clickable\");\n _this.swatches = _this.querySelectorAll('.swatch');\n return _this;\n }\n _inherits(SwatchComponent, _HTMLElement);\n return _createClass(SwatchComponent, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n var _this2 = this;\n if (this.clickable != null) {\n this.swatches.forEach(function (swatch) {\n swatch.addEventListener('click', function () {\n _this2.swatches.forEach(function (s) {\n return s.classList.remove('active');\n });\n swatch.classList.add('active');\n });\n });\n }\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"swatch-component\", SwatchComponent);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/swatch.js?\n}"); 813 814/***/ }, 815 816/***/ "./dev/js/components/swiperProgress.js" 817/*!*********************************************!*\ 818 !*** ./dev/js/components/swiperProgress.js ***! 819 \*********************************************/ 820() { 821 822eval("{function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }
822\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\nvar SwiperProgress = /*#__PURE__*/function (_HTMLElement) {\n function SwiperProgress() {\n _classCallCheck(this, SwiperProgress);\n return _callSuper(this, SwiperProgress, arguments);\n }\n _inherits(SwiperProgress, _HTMLElement);\n return _createClass(SwiperProgress);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('swiper-pagination', SwiperProgress);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/swiperProgress.js?\n}"); 823 824/***/ }, 825 826/***/ "./dev/js/components/textScroll.js" 827/*!*****************************************!*\ 828 !*** ./dev/js/components/textScroll.js ***! 829 \*****************************************/ 830(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 831 832"use strict"; 833eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var gsap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! gsap */ \"./node_modules/gsap/index.js\");\n/* harmony import */ var gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! gsap/ScrollTrigger */ \"./node_modules/gsap/ScrollTrigger.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }
833\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\ngsap__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(gsap_ScrollTrigger__WEBPACK_IMPORTED_MODULE_1__.ScrollTrigger);\nvar TextScroll = /*#__PURE__*/function (_HTMLElement) {\n function TextScroll() {\n var _this;\n _classCallCheck(this, TextScroll);\n _this = _callSuper(this, TextScroll);\n _this.content = _this.querySelector('.text-scroll__content');\n _this.image = _this.querySelector('.text-scroll__image');\n _this.headline = _this.querySelector('.text-scroll__container-headline');\n return _this;\n }\n _inherits(TextScroll, _HTMLElement);\n return _createClass(TextScroll, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initAnimation();\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(this.image, {\n scale: 1.2,\n '-webkit-filter': 'grayscale(100%)',\n filter: 'grayscale(100%)',\n scrollTrigger: {\n start: \"top top\",\n end: \"bottom top\",\n trigger: this.image,\n pin: true,\n scrub: true\n //markers: true\n }\n });\n gsap__WEBPACK_IMPORTED_MODULE_0__.gsap.to(this.headline, {\n scrollTrigger: {\n start: \"top top\",\n end: \"bottom top\",\n trigger: this.content,\n pin: true,\n scrub: true\n //markers: true\n }\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define('text-scroll', TextScroll);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/textScroll.js?\n}"); 834 835/***/ }, 836 837/***/ "./dev/js/components/videoBanner.js" 838/*!******************************************!*\ 839 !*** ./dev/js/components/videoBanner.js ***! 840 \******************************************/ 841() { 842 843eval("{function _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
843 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\ndocument.addEventListener(\"DOMContentLoaded\", function () {\n document.querySelectorAll(\"video-with-text-overlay\").forEach(function (root) {\n var desktopVideo = root.querySelector(\".video-overlay__video--desktop\");\n var desktopBtn = root.querySelector(\".video-overlay__toggle--desktop\");\n var mobileVideo = root.querySelector(\".video-overlay__video--mobile\");\n var mobileBtn = root.querySelector(\".video-overlay__toggle--mobile\");\n var sync = function sync() {\n return desktopBtn.setAttribute(\"aria-pressed\", desktopVideo.paused ? \"true\" : \"false\");\n };\n sync();\n desktopVideo.addEventListener(\"play\", sync);\n desktopVideo.addEventListener(\"pause\", sync);\n desktopVideo.addEventListener(\"canplay\", sync);\n if (desktopBtn && desktopVideo) {\n desktopBtn.setAttribute(\"aria-pressed\", desktopVideo.paused ? \"true\" : \"false\");\n desktopBtn.addEventListener(\"click\", /*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n if (!desktopVideo.paused) {\n _context.n = 5;\n break;\n }\n _context.p = 1;\n _context.n = 2;\n return desktopVideo.play();\n case 2:\n _context.n = 4;\n break;\n case 3:\n _context.p = 3;\n _t = _context.v;\n case 4:\n _context.n = 6;\n break;\n case 5:\n desktopVideo.pause();\n case 6:\n desktopBtn.setAttribute(\"aria-pressed\", desktopVideo.paused ? \"true\" : \"false\");\n case 7:\n return _context.a(2);\n }\n }, _callee, null, [[1, 3]]);\n })));\n }\n if (mobileBtn && mobileVideo) {\n mobileBtn.setAttribute(\"aria-pressed\", mobileVideo.paused ? \"true\" : \"false\");\n mobileBtn.addEventListener(\"click\", /*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee2() {\n var _t2;\n return _regenerator().w(function (_context2) {\n while (1) switch (_context2.p = _context2.n) {\n case 0:\n if (!mobileVideo.paused) {\n _context2.n = 5;\n break;\n }\n _context2.p = 1;\n _context2.n = 2;\n return mobileVideo.play();\n case 2:\n _context2.n = 4;\n break;\n case 3:\n _context2.p = 3;\n _t2 = _context2.v;
843\n case 4:\n _context2.n = 6;\n break;\n case 5:\n mobileVideo.pause();\n case 6:\n mobileBtn.setAttribute(\"aria-pressed\", mobileVideo.paused ? \"true\" : \"false\");\n case 7:\n return _context2.a(2);\n }\n }, _callee2, null, [[1, 3]]);\n })));\n }\n });\n});\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/videoBanner.js?\n}"); 844 845/***/ }, 846 847/***/ "./dev/js/components/videoSlider.js" 848/*!******************************************!*\ 849 !*** ./dev/js/components/videoSlider.js ***! 850 \******************************************/ 851(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 852 853"use strict"; 854eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var swiper__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! swiper */ \"./node_modules/swiper/swiper.mjs\");\n/* harmony import */ var swiper_modules__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! swiper/modules */ \"./node_modules/swiper/modules/index.mjs\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n\n\nvar videoSlider = /*#__PURE__*/function (_HTMLElement) {\n function videoSlider() {\n var _this;\n _classCallCheck(this, videoSlider);\n _this = _callSuper(this, videoSlider);\n _this.swiper = _this.querySelector('.swiper');\n _this.wrapper = _this.querySelector('.swiper-wrapper');\n _this.actionBar = document.querySelector('action-bar');\n _this.header = document.querySelector('store-header');\n _this.container = _this.querySelectorAll('.video-container');\n _this.playButton = _this.querySelectorAll('.play-button');
854\n _this.navHeight = (_this.actionBar ? _this.actionBar.offsetHeight : 0) + (_this.header ? _this.header.offsetHeight : 0);\n return _this;\n }\n _inherits(videoSlider, _HTMLElement);\n return _createClass(videoSlider, [{\n key: \"connectedCallback\",\n value: function connectedCallback() {\n this.initAnimation();\n }\n }, {\n key: \"initAnimation\",\n value: function initAnimation() {\n var _this2 = this;\n swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"].use([swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Pagination, swiper_modules__WEBPACK_IMPORTED_MODULE_1__.Autoplay]);\n var slidesCount = this.querySelectorAll('.swiper-slide').length;\n var isSingleSlide = slidesCount <= 1;\n var swiper = new swiper__WEBPACK_IMPORTED_MODULE_0__[\"default\"](this.swiper, {\n slidesPerView: 1,\n loop: false,\n watchOverflow: true,\n cssMode: false,\n spaceBetween: isSingleSlide ? 0 : 10,\n navigation: {\n nextEl: this.querySelector('next-button-component'),\n prevEl: this.querySelector('prev-button-component')\n },\n pagination: {\n el: \"swiper-pagination-component\"\n },\n breakpoints: {\n 720: {\n slidesPerView: 2\n },\n 1200: {\n spaceBetween: isSingleSlide ? 0 : 40,\n slidesPerView: 4,\n cssMode: true\n }\n },\n on: {\n slideChange: function slideChange() {\n _this2.trackSlideChange(_this2.container);\n }\n }\n });\n\n // Add or remove justify-center class based on slides count vs. slidesPerView\n var updateCenterClass = function updateCenterClass() {\n var width = window.innerWidth;\n var perView = 1;\n if (width >= 1200) {\n perView = 4;\n } else if (width >= 720) {\n perView = 2;\n } else {\n perView = 1;\n }\n var slidesCountNow = _this2.querySelectorAll('.swiper-slide').length;\n if (_this2.wrapper) {\n if (slidesCountNow < perView) {\n _this2.wrapper.classList.add('justify-center');\n } else {\n _this2.wrapper.classList.remove('justify-center');\n }\n }\n // Show prev/next only when there are more slides than slidesPerView\n var nextBtn = _this2.querySelector('next-button-component');\n var prevBtn = _this2.querySelector('prev-button-component');\n var shouldShowNav = slidesCountNow > perView;\n [nextBtn, prevBtn].forEach(function (btn) {\n if (!btn) return;\n if (shouldShowNav) {\n btn.removeAttribute('hidden');\n } else {\n btn.setAttribute('hidden', '');\n }\n });\n };\n updateCenterClass();\n window.addEventListener('resize', updateCenterClass);\n if (swiper && swiper.on) {\n swiper.on('breakpoint', updateCenterClass);\n }\n if (window.innerWidth <= 720) {\n this.querySelectorAll('video').forEach(function (video) {\n video.style.height = \"calc(100vh - \".concat(_this2.navHeight * 2.5, \"px)\");\n });\n }\n this.videoPlay();\n }\n }, {\n key: \"trackSlideChange\",\n value: function trackSlideChange(container) {\n container.forEach(function (element) {\n element.querySelector('video').pause();\n });\n }\n }, {\n key: \"videoPlay\",\n value: function videoPlay() {\n this.playButton.forEach(function (button) {\n var container = button.closest('.video-container');\n var video = container.querySelector('video');\n button.addEventListener('click', function () {\n video.controls = true;\n video.play();\n button.setAttribute('hidden', true);\n });\n video.addEventListener('play', function () {\n button.setAttribute('hidden', true);\n video.controls = true;\n });\n video.addEventListener('pause', function () {\n button.removeAttribute('hidden');\n video.controls = false;\n });\n video.addEventListener('ended', function () {\n button.removeAttribute('hidden');\n video.controls = false;\n });\n });\n }\n }]);\n}(/*#__PURE__*/_wrapNativeSuper(HTMLElement));\nwindow.customElements.define(\"video-slider-component\", videoSlider);\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/components/videoSlider.js?\n}"); 855 856/***/ }, 857 858/***/ "./dev/js/functions/bundleUpdate.js" 859/*!******************************************!*\ 860 !*** ./dev/js/functions/bundleUpdate.js ***! 861 \******************************************/ 862(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 863 864"use strict"; 865eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_fetchCart_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/fetchCart.js */ \"./dev/js/helper/fetchCart.js\");\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
865 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction _createForOfIteratorHelper(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t[\"return\"] || t[\"return\"](); } finally { if (u) throw o; } } }; }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\n\nvar initBundleRemoveListener = function initBundleRemoveListener() {\n var buttons = document.querySelectorAll('[data-timestamp]');\n if (buttons.length > 0) {\n buttons.forEach(function (button) {\n // Doppelte Listener vermeiden\n if (button.dataset.listenerAttached === 'true') return;\n button.dataset.listenerAttached = 'true';\n button.addEventListener('click', /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(e) {\n var timestamp, cart, bundleItems, updates, _iterator, _step, item;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.n) {\n case 0:\n timestamp = button.getAttribute('data-timestamp');
865\n if (timestamp) {\n _context.n = 1;\n break;\n }\n return _context.a(2);\n case 1:\n _context.n = 2;\n return (0,_helper_fetchCart_js__WEBPACK_IMPORTED_MODULE_0__.fetchCart)();\n case 2:\n cart = _context.v;\n console.log(cart);\n bundleItems = cart.items.filter(function (item) {\n var _item$properties;\n return String((_item$properties = item.properties) === null || _item$properties === void 0 ? void 0 : _item$properties._bundle_added_at) === String(timestamp);\n });\n console.log(bundleItems);\n if (bundleItems.length) {\n _context.n = 3;\n break;\n }\n return _context.a(2);\n case 3:\n updates = {};\n _iterator = _createForOfIteratorHelper(bundleItems);\n try {\n for (_iterator.s(); !(_step = _iterator.n()).done;) {\n item = _step.value;\n updates[item.key] = 0;\n }\n } catch (err) {\n _iterator.e(err);\n } finally {\n _iterator.f();\n }\n console.log('[ð§¹ Entferne Bundle mit Timestamp]', timestamp, bundleItems);\n _context.n = 4;\n return fetch('/cart/update.js', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n updates: updates\n })\n });\n case 4:\n document.documentElement.dispatchEvent(new CustomEvent('cart:refresh', {\n bubbles: true\n }));\n case 5:\n return _context.a(2);\n }\n }, _callee);\n }));\n return function (_x) {\n return _ref.apply(this, arguments);\n };\n }());\n });\n }\n};\ndocument.addEventListener('cart:refresh', function () {\n // falls Buttons bei neuem Cart DOM erneut ins HTML gerendert wurden\n initBundleRemoveListener();\n});\ndocument.querySelectorAll('[aria-controls=\"mini-cart\"], [aria-controls=\"slide-out-cart\"]').forEach(function (trigger) {\n trigger.addEventListener('click', function () {\n initBundleRemoveListener();\n });\n});\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/bundleUpdate.js?\n}"); 866 867/***/ }, 868 869/***/ "./dev/js/functions/cartNotification.js" 870/*!**********************************************!*\ 871 !*** ./dev/js/functions/cartNotification.js ***! 872 \**********************************************/ 873() { 874 875eval("{var init = function init() {\n // const parentElement = document.querySelector('.cart-notification');\n //\n // parentElement.addEventListener('click', function(event) {\n // if (event.target.classList.contains('cart-notification__view-cart')) {\n // event.preventDefault();\n // document.getElementById('mini-cart').open = true;\n // }\n // });\n};\ninit();\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/cartNotification.js?\n}"); 876 877/***/ }, 878
879/***/ "./dev/js/functions/cartUpdated.js" 880/*!*****************************************!*\ 881 !*** ./dev/js/functions/cartUpdated.js ***! 882 \*****************************************/ 883(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 884 885"use strict"; 886eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_fetchCart_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/fetchCart.js */ \"./dev/js/helper/fetchCart.js\");\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\n\nvar setMiniCartStateClass = function setMiniCartStateClass(itemCount) {\n var miniCart = document.getElementById('mini-cart');\n if (!miniCart) return;\n miniCart.classList.toggle('mini-cart--empty', itemCount === 0);\n miniCart.classList.toggle('mini-cart--full', itemCount > 0);\n};
886\nvar init = function init() {\n var handleCartChange = /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(event) {\n var _event$detail;\n var itemCount, cart;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.n) {\n case 0:\n itemCount = event === null || event === void 0 || (_event$detail = event.detail) === null || _event$detail === void 0 || (_event$detail = _event$detail.cart) === null || _event$detail === void 0 ? void 0 : _event$detail.item_count;\n if (!(typeof itemCount !== 'undefined')) {\n _context.n = 1;\n break;\n }\n setMiniCartStateClass(itemCount);\n return _context.a(2);\n case 1:\n _context.n = 2;\n return (0,_helper_fetchCart_js__WEBPACK_IMPORTED_MODULE_0__.fetchCart)();\n case 2:\n cart = _context.v;\n if (cart) {\n setMiniCartStateClass(cart.item_count);\n }\n case 3:\n return _context.a(2);\n }\n }, _callee);\n }));\n return function handleCartChange(_x) {\n return _ref.apply(this, arguments);\n };\n }();\n document.addEventListener(\"cart:updated\", handleCartChange);\n document.addEventListener(\"cart:refresh\", handleCartChange);\n};\ninit();
886\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/cartUpdated.js?\n}"); 887 888/***/ }, 889 890/***/ "./dev/js/functions/chatbotCta.js" 891/*!****************************************!*\ 892 !*** ./dev/js/functions/chatbotCta.js ***! 893 \****************************************/ 894() { 895 896eval("{var init = function init() {\n var chatbot = document.querySelector('.tile-grid__item.chatbot');\n if (chatbot) {\n chatbot.addEventListener('click', function (e) {\n e.preventDefault();\n\n // Das iframe auswählen\n var iframe = document.getElementById('launcher');\n if (iframe) {\n try {\n // Zugriff auf den Inhalt des iframes\n var iframeDocument = iframe.contentDocument || iframe.contentWindow.document;\n\n // Den Button im iframe finden und klicken\n var button = iframeDocument.querySelector('[data-garden-id=\"buttons.icon_button\"]');\n if (button) {\n button.click();\n } else {\n console.error('Button nicht gefunden im iframe');\n }\n } catch (error) {\n console.error('Zugriff auf iframe-Inhalt fehlgeschlagen:', error);\n }\n } else {\n console.error('iframe nicht gefunden');\n }\n });\n }\n};\ninit();\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/chatbotCta.js?\n}"); 897 898/***/ }, 899 900/***/ "./dev/js/functions/checkOverflow.js" 901/*!*******************************************!*\ 902 !*** ./dev/js/functions/checkOverflow.js ***! 903 \*******************************************/ 904() { 905 906eval("{function checkTextOverflow() {\n // Find all the text elements in your dropdowns\n var selectedValues = document.querySelectorAll('.select__selected-value');\n selectedValues.forEach(function (element) {\n // Compare the full width of the text to the visible width of the element\n var isOverflowing = element.scrollWidth > element.clientWidth;\n\n // Add or remove the class based on the result\n if (isOverflowing) {\n element.classList.add('is-overflowing');\n } else {\n element.classList.remove('is-overflowing');\n }\n });\n}\n\n// Run the check when the page first loads\ndocument.addEventListener('DOMContentLoaded', checkTextOverflow);\n\n// Run the check whenever the window is resized\nwindow.addEventListener('resize', checkTextOverflow);\n\n// --- IMPORTANT ---\n// You also need to run this check whenever a new dropdown option is selected.\n// You will need to find where your combo-box component updates the text\n// and call the checkTextOverflow() function right after.\n// For example, if your component dispatches a 'change' event:\n\ndocument.querySelectorAll('combo-box').forEach(function (comboBox) {\n comboBox.addEventListener('change', function () {\n // Use a small delay to allow the DOM to update with the new text\n setTimeout(checkTextOverflow, 0);\n });\n});\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/checkOverflow.js?\n}"); 907 908/***/ }, 909 910/***/ "./dev/js/functions/coralGardenersUpdate.js" 911/*!**************************************************!*\ 912 !*** ./dev/js/functions/coralGardenersUpdate.js ***! 913 \**************************************************/ 914(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 915 916"use strict"; 917eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_fetchCart_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/fetchCart.js */ \"./dev/js/helper/fetchCart.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
917 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }
917\n\nvar CORAL_CARD_VARIANT_ID = 44528612245769;\nfunction isCoralGardenersItem(item) {\n if ((item === null || item === void 0 ? void 0 : item.variant_id) === CORAL_CARD_VARIANT_ID) return false;\n var title = ((item === null || item === void 0 ? void 0 : item.title) || '').toLowerCase();\n var variantTitle = ((item === null || item === void 0 ? void 0 : item.variant_title) || '').toLowerCase();\n return title.includes('coral gardeners') || variantTitle.includes('coral gardeners');\n}\nfunction isCoralCard(item) {\n return (item === null || item === void 0 ? void 0 : item.variant_id) === CORAL_CARD_VARIANT_ID;\n}\nvar SUPPRESSED_KEY = '_coral_card_suppressed';\nvar _syncInFlight = false;\nvar _syncTimer = null;\nvar _prevCoralCardQty = null;\nfunction syncCoralCard() {\n return _syncCoralCard.apply(this, arguments);\n}\nfunction _syncCoralCard() {\n _syncCoralCard = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var cart, coralGardenersQty, coralCardLines, totalCoralCardQty, updates, primary, _updates, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n if (!_syncInFlight) {\n _context.n = 1;\n break;\n }\n return _context.a(2);\n case 1:\n _syncInFlight = true;\n _context.p = 2;\n _context.n = 3;\n return (0,_helper_fetchCart_js__WEBPACK_IMPORTED_MODULE_0__.fetchCart)();\n case 3:\n cart = _context.v;\n coralGardenersQty = cart.items.filter(isCoralGardenersItem).reduce(function (sum, item) {\n return sum + Number(item.quantity || 0);\n }, 0);\n coralCardLines = cart.items.filter(isCoralCard);\n totalCoralCardQty = coralCardLines.reduce(function (sum, item) {\n return sum + Number(item.quantity || 0);\n }, 0); // Reset suppression when no coral gardeners items remain in cart\n if (coralGardenersQty === 0) {\n sessionStorage.removeItem(SUPPRESSED_KEY);\n }\n\n // Detect user manually removing the coral card:\n // coral card was present last run, now gone, but coral gardeners items still in cart\n if (_prevCoralCardQty !== null && _prevCoralCardQty > 0 && totalCoralCardQty === 0 && coralGardenersQty > 0) {\n sessionStorage.setItem(SUPPRESSED_KEY, 'true');\n }\n _prevCoralCardQty = totalCoralCardQty;\n if (!(coralGardenersQty === totalCoralCardQty)) {\n _context.n = 4;\n break;\n }\n return _context.a(2);\n case 4:\n if (!(sessionStorage.getItem(SUPPRESSED_KEY) === 'true')) {\n _context.n = 5;\n break;\n }\n return _context.a(2);\n case 5:\n if (!(coralGardenersQty === 0)) {\n _context.n = 8;\n break;\n }\n if (!(coralCardLines.length === 0)) {\n _context.n = 6;\n break;\n }\n return _context.a(2);\n case 6:\n updates = coralCardLines.reduce(function (acc, item) {\n acc[item.key] = 0;\n return acc;\n }, {});\n _context.n = 7;\n return fetch('/cart/update.js', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n updates: updates\n })\n });\n case 7:\n _context.n = 12;\n break;\n case 8:\n if (!(coralCardLines.length === 0)) {\n _context.n = 10;\n break;\n }\n _context.n = 9;\n return fetch('/cart/add.js', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n items: [{\n id: CORAL_CARD_VARIANT_ID,\n quantity: coralGardenersQty,\n properties: {\n _coral_card: 'true'\n }\n }]\n })\n });\n case 9:\n _prevCoralCardQty = coralGardenersQty;\n _context.n = 12;\n break;\n case 10:\n primary = coralCardLines[0];\n _updates = _defineProperty({}, primary.key, coralGardenersQty);
917\n coralCardLines.slice(1).forEach(function (item) {\n _updates[item.key] = 0;\n });\n _context.n = 11;\n return fetch('/cart/update.js', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n updates: _updates\n })\n });\n case 11:\n _prevCoralCardQty = coralGardenersQty;\n case 12:\n document.documentElement.dispatchEvent(new CustomEvent('cart:refresh', {\n bubbles: true\n }));\n _context.n = 14;\n break;\n case 13:\n _context.p = 13;\n _t = _context.v;\n console.error('syncCoralCard failed', _t);\n case 14:\n _context.p = 14;\n _syncInFlight = false;\n return _context.f(14);\n case 15:\n return _context.a(2);\n }\n }, _callee, null, [[2, 13, 14, 15]]);\n }));\n return _syncCoralCard.apply(this, arguments);\n}\nfunction scheduleSync() {\n if (_syncTimer) clearTimeout(_syncTimer);\n _syncTimer = setTimeout(syncCoralCard, 250);\n}\ndocument.addEventListener('DOMContentLoaded', scheduleSync);\ndocument.addEventListener('cart:refresh', scheduleSync);\nvar miniToggle = document.querySelector('[aria-controls=\"mini-cart\"]');\nif (miniToggle) {\n miniToggle.addEventListener('click', scheduleSync);\n}\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/coralGardenersUpdate.js?\n}"); 918 919/***/ }, 920 921/***/ "./dev/js/functions/freeGiftUpdate.js" 922/*!********************************************!*\ 923 !*** ./dev/js/functions/freeGiftUpdate.js ***! 924 \********************************************/ 925(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 926 927"use strict"; 928eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_fetchCart_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/fetchCart.js */ \"./dev/js/helper/fetchCart.js\");\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\n// assets/freeGiftUpdate.js\n\n\n// ---- Helpers ---------------------------------------------------------------\n\nfunction isGiftLine(item) {\n var _item$properties;\n var fg = item === null || item === void 0 || (_item$properties = item.properties) === null || _item$properties === void 0 ? void 0 : _item$properties._free_gift;\n return fg === true || fg === 'true';\n}\nfunction safeGiftTsFrom(item) {\n // Only accept a timestamp if the property actually exists\n if (!(item !== null && item !== void 0 && item.properties) || !Object.prototype.hasOwnProperty.call(item.properties, '_gift_added_at')) {\n return '';\n }\n var raw = String(item.properties._gift_added_at);\n // Guard against sloppy values becoming truthy strings\n if (!raw || raw === 'undefined' || raw === 'null') return '';\n return raw;\n}\n\n// Inline-Gifts aus dem Slide-out-Cart verknüpfen sich nicht über einen\n// gemeinsamen Timestamp, sondern direkt über den Line-Key der Hauptposition\n// (Property _gift_for_line, siehe snippets/slide-out-cart-line-item.liquid).\nfunction safeGiftLineRefFrom(item) {\n if (!(item !== null && item !== void 0 && item.properties) || !Object.prototype.hasOwnProperty.call(item.properties, '_gift_for_line')) {\n return '';\n }\n var raw = String(item.properties._gift_for_line);\n if (!raw || raw === 'undefined' || raw === 'null') return '';\n return raw;\n}\n\n// ---- 1) Standalone âÃâ on the gift line -----------------------------------\n\nfunction initFreeGiftRemoveListener() {\n document.querySelectorAll('.line-item__remove-gift').forEach(function (btn) {\n if (btn.dataset.bound === 'true') return;\n btn.dataset.bound = 'true';\n btn.addEventListener('click', /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(e) {\n var ts, cart, toRemove, updates, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n e.preventDefault();\n ts = btn.dataset.giftTimestamp;\n if (ts) {\n _context.n = 1;\n break;\n }\n return _context.a(2);\n case 1:\n _context.p = 1;\n _context.n = 2;\n return (0,_helper_fetchCart_js__WEBPACK_IMPORTED_MODULE_0__.fetchCart)();\n case 2:\n cart = _context.v;\n // remove ONLY gifts that share this exact timestamp\n toRemove = cart.items.filter(function (item) {\n return isGiftLine(item) && safeGiftTsFrom(item) === ts;\n }).map(function (item) {\n return item.key;\n });\n if (toRemove.length) {\n _context.n = 3;\n break;\n }\n return _context.a(2);\n case 3:\n updates = toRemove.reduce(function (acc, key) {\n acc[key] = 0;\n return acc;\n }, {});\n _context.n = 4;\n return fetch('/cart/update.js', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n updates: updates\n })\n });\n case 4:\n document.documentElement.dispatchEvent(new CustomEvent('cart:refresh', {\n bubbles: true\n }));\n _context.n = 6;\n break;\n case 5:\n _context.p = 5;\n _t = _context.v;\n console.error('Gift remove failed', _t);\n case 6:\n return _context.a(2);\n }\n }, _callee, null, [[1, 5]]);\n }));\n return function (_x) {\n return _ref.apply(this, arguments);\n };\n }());\n });\n}\n\n// ---- 2) Orphan-gift cleanup when *main* gets removed -----------------------\nfunction cleanupOrphanGifts() {\n return _cleanupOrphanGifts.apply(this, arguments);\n} // ---- 3) Keep gift qty in sync with main qty for each timestamp -------------\nfunction _cleanupOrphanGifts() {\n _cleanupOrphanGifts = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee2() {\n var cart, nonGiftItems, validTs, validLineKeys, orphanKeys, updates, _t2;\n return _regenerator().w(function (_context2) {\n while (1) switch (_context2.p = _context2.n) {\n case 0:\n _context2.p = 0;\n _context2.n = 1;\n return (0,_helper_fetchCart_js__WEBPACK_IMPORTED_MODULE_0__.fetchCart)();\n case 1:\n cart = _context2.v;
928\n nonGiftItems = cart.items.filter(function (item) {\n return !isGiftLine(item);\n }); // Collect valid timestamps ONLY from non-gift lines that actually have the property\n validTs = new Set(nonGiftItems.map(safeGiftTsFrom).filter(function (ts) {\n return !!ts;\n })); // Valid line keys for the inline-gift scheme (_gift_for_line -> main line's key)\n validLineKeys = new Set(nonGiftItems.map(function (item) {\n return item.key;\n })); // Any gift whose link (timestamp OR referenced line) no longer resolves\n orphanKeys = cart.items.filter(function (item) {\n if (!isGiftLine(item)) return false;\n var ts = safeGiftTsFrom(item);\n if (ts) return !validTs.has(ts);\n var lineRef = safeGiftLineRefFrom(item);\n if (lineRef) return !validLineKeys.has(lineRef);\n return true; // neither link present -> orphan\n }).map(function (item) {\n return item.key;\n });\n if (orphanKeys.length) {\n _context2.n = 2;\n break;\n }\n return _context2.a(2);\n case 2:\n updates = orphanKeys.reduce(function (acc, key) {\n acc[key] = 0;\n return acc;\n }, {});\n _context2.n = 3;\n return fetch('/cart/update.js', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n updates: updates\n })\n });\n case 3:\n document.documentElement.dispatchEvent(new CustomEvent('cart:refresh', {\n bubbles: true\n }));\n _context2.n = 5;\n break;\n case 4:\n _context2.p = 4;\n _t2 = _context2.v;\n console.error('cleanupOrphanGifts failed', _t2);\n case 5:\n return _context2.a(2);\n }\n }, _callee2, null, [[0, 4]]);\n }));\n return _cleanupOrphanGifts.apply(this, arguments);\n}\nfunction ensureGiftQuantityMatchesMain() {\n return _ensureGiftQuantityMatchesMain.apply(this, arguments);\n} // ---- 4) Bind +/- to resync after clicks -----------------------------------\nfunction _ensureGiftQuantityMatchesMain() {\n _ensureGiftQuantityMatchesMain = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee3() {\n var cart, mainQtyByLineKey, groups, updates, _t3;\n return _regenerator().w(function (_context3) {\n while (1) switch (_context3.p = _context3.n) {\n case 0:\n _context3.p = 0;\n _context3.n = 1;\n return (0,_helper_fetchCart_js__WEBPACK_IMPORTED_MODULE_0__.fetchCart)();\n case 1:\n cart = _context3.v;\n // Main line quantities, keyed by their own line key (for the _gift_for_line scheme)\n mainQtyByLineKey = new Map(cart.items.filter(function (item) {\n return !isGiftLine(item);\n }).map(function (item) {\n return [item.key, Number(item.quantity || 0)];\n })); // Group -> { mainQty, gifts: [{ key, qty, variant_id, index }] }\n groups = new Map();\n cart.items.forEach(function (item, index) {\n var ts = safeGiftTsFrom(item);\n var lineRef = ts ? '' : safeGiftLineRefFrom(item);\n var groupKey = ts ? \"ts:\".concat(ts) : lineRef ? \"line:\".concat(lineRef) : '';\n if (!groupKey) return; // ignore lines without a valid link\n\n var entry = groups.get(groupKey) || {\n mainQty: ts ? 0 : mainQtyByLineKey.get(lineRef) || 0,\n gifts: []\n };\n if (isGiftLine(item)) {\n entry.gifts.push({\n key: item.key,\n qty: Number(item.quantity || 0),\n variant_id: item.variant_id,\n index: index\n });\n } else if (ts) {\n entry.mainQty += Number(item.quantity || 0);\n }\n groups.set(groupKey, entry);\n });\n updates = {};\n groups.forEach(function (entry) {\n if (!entry.gifts.length) return; // nothing to sync\n\n var targetQty = entry.mainQty; // 1:1 gift per main\n var totalGiftQty = entry.gifts.reduce(function (s, g) {\n return s + g.qty;\n }, 0);\n if (totalGiftQty === targetQty) return; // already in sync\n\n // Keep the earliest-appearing gift line to preserve the original variant\n var primary = entry.gifts.slice().sort(function (a, b) {\n return a.index - b.index;\n })[0];\n updates[primary.key] = targetQty;\n\n // Remove extra gift lines for the same group\n entry.gifts.filter(function (g) {\n return g.key !== primary.key;\n }
928).forEach(function (g) {\n updates[g.key] = 0;\n });\n });\n if (!(Object.keys(updates).length === 0)) {\n _context3.n = 2;\n break;\n }\n return _context3.a(2);\n case 2:\n _context3.n = 3;\n return fetch('/cart/update.js', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n updates: updates\n })\n });\n case 3:\n document.documentElement.dispatchEvent(new CustomEvent('cart:refresh', {\n bubbles: true\n }));\n _context3.n = 5;\n break;\n case 4:\n _context3.p = 4;\n _t3 = _context3.v;\n console.error('ensureGiftQuantityMatchesMain failed', _t3);\n case 5:\n return _context3.a(2);\n }\n }, _callee3, null, [[0, 4]]);\n }));\n return _ensureGiftQuantityMatchesMain.apply(this, arguments);\n}\nfunction bindQtyButtonsForGiftSync() {\n var selectorsPlus = ['[data-quantity-increment]', '.quantity__button--plus', '[data-action=\"increment\"]', 'button[aria-label=\"Increase quantity\"]', '.js-qty__adjust--plus'];\n var selectorsMinus = ['[data-quantity-decrement]', '.quantity__button--minus', '[data-action=\"decrement\"]', 'button[aria-label=\"Decrease quantity\"]', '.js-qty__adjust--minus'];\n var bind = function bind(el, flag) {\n if (el.dataset[flag] === 'true') return;\n el.dataset[flag] = 'true';\n el.addEventListener('click', function () {\n setTimeout(function () {\n scheduleBootstrap();\n }, 600);\n });\n };\n selectorsPlus.forEach(function (sel) {\n document.querySelectorAll(sel).forEach(function (el) {\n return bind(el, 'boundGiftPlus');\n });\n });\n selectorsMinus.forEach(function (sel) {\n document.querySelectorAll(sel).forEach(function (el) {\n return bind(el, 'boundGiftMinus');\n });\n });\n}\n\n// ---- 5) Bootstrap (serialized + debounced) ---------------------------------\n\nvar _giftBootstrapTimer = null;\nvar _bootstrapInFlight = false;\nfunction bootstrapGiftLogic() {\n return _bootstrapGiftLogic.apply(this, arguments);\n}\nfunction _bootstrapGiftLogic() {\n _bootstrapGiftLogic = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee4() {\n return _regenerator().w(function (_context4) {\n while (1) switch (_context4.p = _context4.n) {\n case 0:\n if (!_bootstrapInFlight) {\n _context4.n = 1;\n break;\n }\n return _context4.a(2);\n case 1:\n _bootstrapInFlight = true;\n _context4.p = 2;\n initFreeGiftRemoveListener();\n // Run in a deterministic order on the SAME cart snapshot sequence\n _context4.n = 3;\n return cleanupOrphanGifts();\n case 3:\n _context4.n = 4;\n return ensureGiftQuantityMatchesMain();\n case 4:\n bindQtyButtonsForGiftSync();\n case 5:\n _context4.p = 5;\n _bootstrapInFlight = false;\n return _context4.f(5);\n case 6:\n return _context4.a(2);\n }\n }, _callee4, null, [[2,, 5, 6]]);\n }));\n return _bootstrapGiftLogic.apply(this, arguments);\n}\nfunction scheduleBootstrap() {\n if (_giftBootstrapTimer) clearTimeout(_giftBootstrapTimer);\n _giftBootstrapTimer = setTimeout(function () {\n bootstrapGiftLogic();\n }, 250);\n}\n\n// Initial + reactive hooks\ndocument.addEventListener('DOMContentLoaded', scheduleBootstrap);\ndocument.addEventListener('cart:refresh', scheduleBootstrap);\n\n// If a cart toggle doesnât fire `cart:refresh`:\ndocument.querySelectorAll('[aria-controls=\"mini-cart\"], [aria-controls=\"slide-out-cart\"]').forEach(function (toggle) {\n toggle.addEventListener('click', scheduleBootstrap);\n});\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/freeGiftUpdate.js?\n}"); 929 930/***/ }, 931 932/***/ "./dev/js/functions/influenceIO.js" 933/*!*****************************************!*\ 934 !*** ./dev/js/functions/influenceIO.js ***! 935 \*****************************************/ 936() { 937
938eval("{var init = function init() {\n var maxAttempts = 10; // Maximum number of polling attempts\n var attempts = 0;\n var pollInterval = 500; // Poll every 500ms\n\n function moveElementIfConditionsMet() {\n var container = document.querySelector('.LoyaltyPage__inner');\n var accountApps = document.querySelector('.account__apps');\n var pointsActivity = document.getElementById('influence-io-points-activity');\n\n // Check if all necessary elements exist\n if (container && accountApps && pointsActivity) {\n // Move #influence-io-points-activity to the end of the container\n container.appendChild(pointsActivity);\n }\n }\n function checkAndApplyNegativeClass() {\n var rows = document.querySelectorAll('.LoyaltyPage__PointsActivity div:nth-child(3) .R-TextBody');\n rows.forEach(function (row) {\n var content = row.textContent.trim();\n if (content.includes('-')) {\n row.closest('.R-flex-row').classList.add('negative');\n } else {\n row.closest('.R-flex-row').classList.add('positive');\n }\n });\n }\n function tierList() {\n var indicator = document.querySelector('.R-SliderIndicator');\n indicator.closest('.R-ContentCard').classList.add('active');\n var heading = indicator.closest('.R-ContentCard').querySelector('.R-TextHeading');\n heading.innerHTML = heading.innerHTML.replace(/(Shore Guardian|Marine Protector|Sea Ambassador)/g, '<span class=\"title\">$1</span>');\n var text1 = '<strong>Deine Vorteile:</strong><ul>' + '<li>1 OCEAN CARE CREDIT pro 1 ⬠Umsatz sammeln</li>' + '<li>OCEAN CARE CREDITS gegen Prämien einlösen</li>' + '<li>Vorzeitiger Zugang zu Sales</li>' + '<li>Teilnahme an exklusiven Gewinnspielen</li>' + '</ul>';\n var text2 = '<strong>Deine Vorteile:</strong><ul>' + '<li>Alle Vorteile der \"Shore Guardian\" Stufe</li>' + '<li>Kostenloses T-Shirt oder Sonnenbrille</li>' + '</ul>';\n var text3 = '<strong>Deine Vorteile:</strong><ul>' + '<li>Alle Vorteile der \"Marine Protector\" Stufe</li>' + '<li>Zugang zu exklusiven Produktlaunches</li>' + '<li>Einblicke in zukünftige Produktentwicklungen</li>' + '</ul>';\n var texts = [text1, text2, text3];\n var elements = document.querySelectorAll('#influence-io-tiers .R-ContentSection__inner .R-flex-row.R-flex-center-xxs>div');\n elements.forEach(function (element, index) {\n // Check if the index exists in the texts array\n if (index < texts.length) {\n element.querySelector('.R-TextBody').innerHTML = texts[index];\n }\n });\n }\n function pollForElements() {\n attempts++;\n var containerExists = document.querySelector('.LoyaltyPage__inner') !== null;\n var AppExists = document.querySelector('.LoyaltyFullpage') !== null;\n var loyalityExists = document.querySelector('.LoyaltyPage__PointsActivity') !== null;\n var tiersExists = document.querySelector('#influence-io-tiers .R-SliderIndicator') !== null;\n if (AppExists) {\n if (containerExists && tiersExists) {\n moveElementIfConditionsMet();\n checkAndApplyNegativeClass();\n tierList();\n } else if (attempts < maxAttempts) {\n setTimeout(pollForElements, pollInterval);\n }\n }\n }\n pollForElements();\n};\ninit();\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/influenceIO.js?\n}"); 939 940/***/ }, 941 942/***/ "./dev/js/functions/jdgmCarousel.js" 943/*!******************************************!*\ 944 !*** ./dev/js/functions/jdgmCarousel.js ***! 945 \******************************************/ 946() { 947 948eval("{var init = function init() {\n var adjustHeights = function adjustHeights() {\n var reviewContents = document.querySelectorAll('.jdgm-carousel-item__review-content');\n var productImages = document.querySelectorAll('.jdgm-carousel-item__product-image');\n if (!reviewContents.length || !productImages.length) return;\n\n // Bestimme die maximale Höhe\n var maxReviewHeight = 0;\n reviewContents.forEach(function (content) {\n maxReviewHeight = Math.max(maxReviewHeight, content.offsetHeight);\n });\n\n // Setze margin-top basierend auf der Differenz\n reviewContents.forEac
948h(function (content, index) {\n var difference = maxReviewHeight - content.offsetHeight;\n var productImage = productImages[index];\n if (productImage) {\n productImage.style.marginTop = \"\".concat(difference + 9, \"px\");\n }\n });\n };\n\n // Rufe die Funktion auf\n adjustHeights();\n\n // Optional: Neuberechnung bei FenstergröÃenänderung\n window.addEventListener('resize', adjustHeights);\n};\nwindow.addEventListener('load', function () {\n setTimeout(function () {\n init();\n }, 100);\n});\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/jdgmCarousel.js?\n}"); 949 950/***/ }, 951 952/***/ "./dev/js/functions/openCartFromUrl.js" 953/*!*********************************************!*\ 954 !*** ./dev/js/functions/openCartFromUrl.js ***! 955 \*********************************************/ 956() { 957 958eval("{var init = function init() {\n var params = new URLSearchParams(window.location.search);\n if (params.get('open_cart') !== '1') return;\n var miniCart = document.getElementById('mini-cart');\n if (miniCart) {\n miniCart.open = true;\n }\n var url = new URL(window.location.href);\n url.searchParams[\"delete\"]('open_cart');\n window.history.replaceState({}, '', url);\n};\ninit();\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/openCartFromUrl.js?\n}"); 959 960/***/ }, 961 962/***/ "./dev/js/functions/predictiveSearchButton.js" 963/*!****************************************************!*\ 964 !*** ./dev/js/functions/predictiveSearchButton.js ***! 965 \****************************************************/ 966() { 967 968eval("{var init = function init() {\n document.addEventListener(\"DOMContentLoaded\", function () {\n var searchInput = document.querySelector(\".predictive-search__input\");\n var viewAllLink = document.querySelector(\".view-all-link\");\n if (searchInput && viewAllLink) {\n searchInput.addEventListener(\"input\", function () {\n var query = searchInput.value.trim();\n viewAllLink.href = \"\".concat(window.themeVariables.routes.searchUrl, \"?q=\").concat(encodeURIComponent(query), \"&type=product\");\n });\n }\n });\n};\ninit();\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/predictiveSearchButton.js?\n}"); 969 970/***/ }, 971 972/***/ "./dev/js/functions/productTabSwitch.js" 973/*!**********************************************!*\ 974 !*** ./dev/js/functions/productTabSwitch.js ***! 975 \**********************************************/ 976() { 977 978eval("{function init() {\n var tabButton = document.querySelectorAll('.tabs-nav__item');\n tabButton.forEach(function (element) {\n element.addEventListener('click', function (button) {\n var attr = button.target.getAttribute('aria-controls').split(\"-\")[1];\n var eligibleElements = document.querySelectorAll(\"[data-type=\\\"\".concat(attr, \"\\\"]:not(.disabled) input\"));\n if (eligibleElements.length > 0) {\n eligibleElements[0].click();\n } else {\n var allElements = document.querySelectorAll(\"[data-type=\\\"\".concat(attr, \"\\\"] input\"));\n if (allElements.length > 0) {\n allElements[0].click();\n }\n }\n });\n });\n}\ninit();\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/productTabSwitch.js?\n}"); 979 980/***/ }, 981 982/***/ "./dev/js/functions/reShadeButton.js" 983/*!*******************************************!*\ 984 !*** ./dev/js/functions/reShadeButton.js ***! 985 \*******************************************/ 986() { 987 988eval("{var init = function init() {\n var geeneeButton = document.getElementById('geenee-vto-btn');\n var reshadeButton = document.querySelectorAll('.reshade--button');\n if (geeneeButton && reshadeButton) {\n geeneeButton.closest('.shopify-section--apps').classList.add('display--none');\n reshadeButton.forEach(function (button) {\n button.addEventListener('click', function () {\n geeneeButton.click();\n });\n });\n }\n};\ninit();\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/reShadeButton.js?\n}"); 989 990/***/ }, 991 992/***/ "./dev/js/functions/variantAdded.js" 993/*!******************************************!*\ 994 !*** ./dev/js/functions/variantAdded.js ***! 995 \******************************************/ 996(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 997 998"use strict"; 999eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _helper_addProduct__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../helper/addProduct */ \"./dev/js/helper/addProduct.js\");\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf;
999 var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction _createForOfIteratorHelper(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t[\"return\"] || t[\"return\"](); } finally { if (u) throw o; } } }; }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\n\nvar init = function init() {\n document.addEventListener(\"variant:added\", /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(event) {\n var variant, checkboxes, _iterator, _step, checkbox, productId, data;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.n) {\n case 0:\n variant = event.detail.variant;\n checkboxes = document.querySelectorAll('.addon-checkbox');\n _iterator = _createForOfIteratorHelper(checkboxes);\n try {\n for (_iterator.s(); !(_step = _iterator.n()).done;) {\n checkbox = _step.value;\n if (checkbox.checked) {\n productId = checkbox.getAttribute('data-addon');\n data = {\n id: productId,\n quantity: 1\n };\n (0,_helper_addProduct__WEBPACK_IMPORTED_MODULE_0__.addProduct)(data);\n }\n }\n } catch (err) {\n _iterator.e(err);\n } finally {\n _iterator.f();\n }\n window['ablyft'] = window['ablyft'] || [];\n window['ablyft'].push({\n eventType: 'custom',\n eventName: 'add-to-cart-api',\n eventValue: 0 //optional\n });\n case 1:\n return _context.a(2);\n }\n }, _callee);\n }));\n return function (_x) {\n return _ref.apply(this, arguments);\n };\n }());\n};\ninit();\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/variantAdded.js?\n}"); 1000 1001/***/ }, 1002 1003/***/ "./dev/js/functions/variantSwitch.js" 1004/*!*******************************************!*\ 1005 !*** ./dev/js/functions/variantSwitch.js ***! 1006 \*******************************************/ 1007() { 1008
1009eval("{var init = function init() {\n // let thumbnail = document.querySelectorAll('.product__thumbnail-item');\n // let activeThumbnail = document.querySelector('.product__thumbnail-item[aria-current]');\n var stickyAtc = document.querySelector('.product-sticky-form');\n document.addEventListener('variant:changed', function (event) {\n console.log('variant changed');\n var bis = document.querySelector('#back-in-stock-container');\n var atc = document.querySelector('#AddToCart');\n var variant = event.detail.variant;\n var parent = event.target.parentNode.parentNode.parentNode.parentNode;\n var activeGalleries = parent.querySelectorAll('[data-id].active');\n var activeInfoDescription = parent.querySelectorAll('[data-desc].active');\n //let scrollerGalleries = document.querySelectorAll('[scroller-id].active');\n var mobileActiveGalleries = parent.querySelectorAll('[mobile-id].active');\n //let activeButtons = document.querySelectorAll('[button-id].active');\n var deliveryText = parent.querySelectorAll('[delivery-id].active');\n var shippingText = parent.querySelectorAll('[shipping-id].active');\n var active_item = document.querySelector('.variant-swatch__item.active');\n if (active_item) {\n active_item.classList.remove('active');\n }\n var option2 = event.detail.variant.option2;\n if (option2) {\n document.querySelector(\".variant-swatch__item[title=\\\"\".concat(option2, \"\\\"]\")).classList.add('active');\n }\n var nudge = document.querySelector('product-nudge');\n var lastChance = document.querySelectorAll('[data-lastchance].active');\n displayCountdown(variant);\n activeGalleries.forEach(function (gallery) {\n gallery.classList.remove('active');\n });\n mobileActiveGalleries.forEach(function (gallery) {\n gallery.classList.remove('active');\n });\n deliveryText.forEach(function (button) {\n button.classList.remove('active');\n });\n shippingText.forEach(function (item) {\n item.classList.remove('active');\n });\n activeInfoDescription.forEach(function (desc) {\n desc.classList.remove('active');\n });\n lastChance.forEach(function (item) {\n item.classList.remove('active');\n });\n if (nudge) {\n if (variant.price < variant.compare_at_price) {\n nudge.classList.remove('hidden');\n } else {\n nudge.classList.add('hidden');\n }\n }\n if (variant.available) {\n if (atc) {\n atc.classList.add('active');\n }\n bis.classList.remove('active');\n if (stickyAtc) {\n stickyAtc.style.display = 'block';\n }\n } else {\n if (atc) {\n atc.classList.remove('active');\n }\n bis.classList.add('active');\n if (stickyAtc) {\n stickyAtc.style.display = 'none';\n }\n }\n var activeBundleNumber;\n if (document.querySelector('#bundle-1.active')) {\n activeBundleNumber = '-1';\n } else if (document.querySelector('#bundle-2.active')) {\n activeBundleNumber = '-2';\n } else {\n activeBundleNumber = '';\n }\n document.querySelector(\"[data-id=\\\"\".concat(variant.id).concat(activeBundleNumber, \"\\\"]\")).classList.add('active');\n document.querySelector(\"[mobile-id=\\\"\".concat(variant.id).concat(activeBundleNumber, \"\\\"]\")).classList.add('active');\n //document.querySelector(`[scroller-id=\"${variant.id}\"]`).classList.add('active');\n if (document.querySelector(\"[delivery-id=\\\"\".concat(variant.id, \"\\\"]\"))) {\n document.querySelector(\"[delivery-id=\\\"\".concat(variant.id, \"\\\"]\")).classList.add('active');\n }\n if (document.querySelector(\"[data-desc=\\\"\".concat(variant.id, \"\\\"]\"))) {\n document.querySelector(\"[data-desc=\\\"\".concat(variant.id, \"\\\"]\")).classList.add('active');\n }\n if (document.querySelector(\"[shipping-id=\\\"\".concat(variant.id, \"\\\"]\"))) {\n document.querySelector(\"[shipping-id=\\\"\".concat(variant.id, \"\\\"]\")).classList.add('active');\n }\n if (document.querySelector(\"[data-lastchanceid=\\\"\".concat(variant.id, \"\\\"]\"))) {\n document.querySelector(\"[data-lastchanceid=\\\"\".concat(variant.id, \"\\\"]\")).classList.add('active');\n }\n collabVariant(variant);\n });\n};\ndisplayCountdown = function displayCountdown(variant) {\n if (document.querySelector('.count-down')) {\n if (variant.compare_at_price) {\n document.querySelector('.count-down').classList.add('active');\n } else {\n document.querySelector('.count-down').classList.remove('active');\n }\n }\n};\ncollabVariant = function collabVariant(variant) {\n var coralCard = document.querySelector('.coral_card');\n if (!variant) return;\n var variantTitle = variant.title.toLowerCase();\n var elements = document.querySelectorAll(\"[data-collab]\");\n\n // 1. CLEAR EVERYTHING FIRST (The most important step)\n elements.forEac
1009h(function (el) {\n return el.classList.remove('active');\n });\n\n // 2. LOGIC ORDER MATTERS (Priority Logic)\n var matched = false;\n\n // PRIORITY 1: Special Collabs\n if (variantTitle.includes('coral gardeners')) {\n var _document$querySelect;\n (_document$querySelect = document.querySelector('[data-collab=\"coralgardeners\"]')) === null || _document$querySelect === void 0 || _document$querySelect.classList.add('active');\n coralCard === null || coralCard === void 0 || coralCard.classList.add('active');\n matched = true;\n } else {\n coralCard === null || coralCard === void 0 || coralCard.classList.remove('active');\n }\n if (variantTitle.includes('dolphin project')) {\n var _document$querySelect2;\n (_document$querySelect2 = document.querySelector('[data-collab=\"dolphinproject\"]')) === null || _document$querySelect2 === void 0 || _document$querySelect2.classList.add('active');\n matched = true;\n }\n if (variantTitle.includes('sea shepherd')) {\n var _document$querySelect3;\n (_document$querySelect3 = document.querySelector('[data-collab=\"seashepherd\"]')) === null || _document$querySelect3 === void 0 || _document$querySelect3.classList.add('active');\n matched = true;\n }\n\n // PRIORITY 2: Prints / Vichy (Checking this BEFORE Monochrome)\n if (!matched && (variantTitle.includes('vichy') || variantTitle.includes('print'))) {\n var _document$querySelect4;\n (_document$querySelect4 = document.querySelector('[data-collab=\"print\"]')) === null || _document$querySelect4 === void 0 || _document$querySelect4.classList.add('active');\n matched = true;\n }\n\n // PRIORITY 3: Monochrome (Only if not already matched by Vichy/Print)\n if (!matched && variantTitle.includes('monochrome')) {\n var _document$querySelect5;\n (_document$querySelect5 = document.querySelector('[data-collab=\"monochrome\"]')) === null || _document$querySelect5 === void 0 || _document$querySelect5.classList.add('active');\n matched = true;\n }\n\n // PRIORITY 4: Imperfect / Last Chance (Check by data-type attribute)\n if (!matched) {\n var _swatchRadio$parentNo;\n var swatchRadio = document.querySelector(\".color-swatch__radio[value=\\\"\".concat(variant.title, \"\\\"]\"));\n var type = (swatchRadio === null || swatchRadio === void 0 || (_swatchRadio$parentNo = swatchRadio.parentNode) === null || _swatchRadio$parentNo === void 0 || (_swatchRadio$parentNo = _swatchRadio$parentNo.getAttribute('data-type')) === null || _swatchRadio$parentNo === void 0 ? void 0 : _swatchRadio$parentNo.toLowerCase()) || \"\";\n if (type.includes('imperfect')) {\n var _document$querySelect6;\n (_document$querySelect6 = document.querySelector('[data-collab=\"imperfect\"]')) === null || _document$querySelect6 === void 0 || _document$querySelect6.classList.add('active');\n matched = true;\n } else if (type.includes('last chance')) {\n var _document$querySelect7;\n (_document$querySelect7 = document.querySelector('[data-collab=\"lastchance\"]')) === null || _document$querySelect7 === void 0 || _document$querySelect7.classList.add('active');\n matched = true;\n }\n }\n\n // PRIORITY 5: Fallback to Classic\n if (!matched) {\n var _document$querySelect8;\n (_document$querySelect8 = document.querySelector('[data-collab=\"classic\"]')) === null || _document$querySelect8 === void 0 || _document$querySelect8.classList.add('active');\n }\n};\ninit();\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/functions/variantSwitch.js?\n}"); 1010 1011/***/ }, 1012 1013/***/ "./dev/js/helper/addProduct.js" 1014/*!*************************************!*\ 1015 !*** ./dev/js/helper/addProduct.js ***! 1016 \*************************************/ 1017(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1018 1019"use strict"; 1020eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ addProduct: () => (/* binding */ addProduct)\n/* harmony export */ });\nvar addProduct = function addProduct(payload, disableEg) {\n var disableNotification = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;\n var disableTracking = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;\n //The easygift reference disables the easy gift functionality\n var addToCartString = '/cart/add.js';\n if (disableEg) {\n addToCartString = '/cart/add.js?_easygift_internal=true';\n }\n return fetch(addToCartString, {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify(payload)\n }).then(function (response) {\n return response.json();\n }
1020).then(function (data) {\n console.log('Item added:', data);\n if (!disableTracking) {\n window['ablyft'] = window['ablyft'] || [];\n window['ablyft'].push({\n eventType: 'custom',\n eventName: 'add-to-cart-api',\n eventValue: 0\n });\n }\n document.documentElement.dispatchEvent(new CustomEvent('cart:refresh', {\n bubbles: true\n }));\n if (document.querySelector('body.test-060')) {\n document.getElementById('mini-cart').open = true;\n }\n if (disableNotification) {\n document.documentElement.dispatchEvent(new CustomEvent('cart-notification:show', {\n bubbles: true,\n cancelable: true,\n detail: {\n status: \"success\"\n }\n }));\n }\n })[\"catch\"](function (error) {\n console.error('Error:', error);\n // Handle errors, maybe show a notification to the user\n });\n};\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/helper/addProduct.js?\n}"); 1021 1022/***/ }, 1023 1024/***/ "./dev/js/helper/fetchCart.js" 1025/*!************************************!*\ 1026 !*** ./dev/js/helper/fetchCart.js ***! 1027 \************************************/ 1028(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1029 1030"use strict"; 1031eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ fetchCart: () => (/* binding */ fetchCart)\n/* harmony export */ });\nfunction _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nvar fetchCart = /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {\n var response, data, _t;\n return _regenerator().w(function (_context) {\n while (1) switch (_context.p = _context.n) {\n case 0:\n _context.p = 0;\n _context.n = 1;\n return fetch(\"/cart.js\");\n case 1:\n response = _context.v;\n _context.n = 2;\n return response.json();\n case 2:\n data = _context.v;\n return _context.a(2, data);\n case 3:\n _context.p = 3;\n _t = _context.v;\n console.error(\"[â Fehler beim Laden des Warenkorbs]\", _t);\n return _context.a(2, null);\n }\n }, _callee, null, [[0, 3]]);\n }));\n return function fetchCart() {\n return _ref.apply(this, arguments);\n };\n}();\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/helper/fetchCart.js?\n}"); 1032 1033/***/ }, 1034 1035/***/ "./dev/js/helper/formatPrice.js" 1036/*!**************************************!*\ 1037 !*** ./dev/js/helper/formatPrice.js ***! 1038 \**************************************/ 1039(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1040 1041"use strict"; 1042eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ formatPrice: () => (/* binding */ formatPrice)\n/* harmony export */ });\nvar MARKET_LOCALE_MAP = {\n cz: 'cs',\n ch: 'de-CH'\n};\nvar getFormatLocale = function getFormatLocale() {\n var market = document.documentElement.getAttribute('market') || '';\n return MARKET_LOCALE_MAP[market] || document.documentElement.lang || 'de';\n};\nvar formatPrice = function formatPrice(cents) {\n var locale = getFormatLocale();
1042\n return (cents / 100).toLocaleString(locale, {\n minimumFractionDigits: 0,\n maximumFractionDigits: 0\n });\n};\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/helper/formatPrice.js?\n}"); 1043 1044/***/ }, 1045 1046/***/ "./dev/js/helper/isMobile.js" 1047/*!***********************************!*\ 1048 !*** ./dev/js/helper/isMobile.js ***! 1049 \***********************************/ 1050(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1051 1052"use strict"; 1053eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ isMobile: () => (/* binding */ isMobile)\n/* harmony export */ });\nvar isMobile = function isMobile() {\n return window.matchMedia(\"(max-width: 768px)\").matches;\n};\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/helper/isMobile.js?\n}"); 1054 1055/***/ }, 1056 1057/***/ "./dev/js/helper/isShopifyThemeEditor.js" 1058/*!***********************************************!*\ 1059 !*** ./dev/js/helper/isShopifyThemeEditor.js ***! 1060 \***********************************************/ 1061(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1062 1063"use strict"; 1064eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ isShopifyThemeEditor: () => (/* binding */ isShopifyThemeEditor)\n/* harmony export */ });\nvar isShopifyThemeEditor = function isShopifyThemeEditor() {\n var _window$Shopify;\n if (typeof window === 'undefined') {\n return false;\n }\n return Boolean((_window$Shopify = window.Shopify) === null || _window$Shopify === void 0 ? void 0 : _window$Shopify.designMode);\n};\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/helper/isShopifyThemeEditor.js?\n}"); 1065 1066/***/ }, 1067 1068/***/ "./dev/js/helper/isUs.js" 1069/*!*******************************!*\ 1070 !*** ./dev/js/helper/isUs.js ***! 1071 \*******************************/ 1072(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1073 1074"use strict"; 1075eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ getCurrencySymbol: () => (/* binding */ getCurrencySymbol),\n/* harmony export */ isUs: () => (/* binding */ isUs)\n/* harmony export */ });\nvar isUs = function isUs() {\n return window.location.hostname.split(\".\")[0] === \"us\";\n};\nvar getCurrencySymbol = function getCurrencySymbol() {\n return isUs() ? \"$\" : \"â¬\";\n};\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/helper/isUs.js?\n}"); 1076 1077/***/ }, 1078 1079/***/ "./dev/js/helper/removeProduct.js" 1080/*!****************************************!*\ 1081 !*** ./dev/js/helper/removeProduct.js ***! 1082 \****************************************/ 1083(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1084 1085"use strict"; 1086eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ removeProduct: () => (/* binding */ removeProduct)\n/* harmony export */ });\nvar removeProduct = function removeProduct(payload) {\n return fetch('/cart/change.js', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n id: payload.id,\n quantity: 0\n })\n }).then(function (response) {\n return response.json();\n }
1086).then(function (data) {\n console.log('Item removed:', data);\n document.documentElement.dispatchEvent(new CustomEvent('cart:refresh', {\n bubbles: true\n }));\n })[\"catch\"](function (error) {\n console.error('Error:', error);\n // Handle errors, maybe show a notification to the user\n });\n};\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/helper/removeProduct.js?\n}"); 1087 1088/***/ }, 1089 1090/***/ "./dev/js/lib/fancybox.js" 1091/*!********************************!*\ 1092 !*** ./dev/js/lib/fancybox.js ***! 1093 \********************************/ 1094(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1095 1096"use strict"; 1097eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _fancyapps_ui__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @fancyapps/ui */ \"./node_modules/@fancyapps/ui/dist/index.esm.js\");\n\ndocument.querySelectorAll(\".gallery, product-slider\").forEach(function (containerEl) {\n var figures = Array.from(containerEl.querySelectorAll(\".gallery__figure\")).filter(function (figure) {\n return figure.dataset.src;\n });\n if (figures.length === 0) return;\n var mediaItems = figures.map(function (figure) {\n var _figure$querySelector;\n var caption = figure.dataset.caption || \"\";
1097\n var videoSource = (_figure$querySelector = figure.querySelector(\"video source\")) === null || _figure$querySelector === void 0 ? void 0 : _figure$querySelector.src;\n var isVideo = Boolean(videoSource);\n if (isVideo) {\n return {\n type: \"html\",\n caption: caption,\n html: \"\\n <div class=\\\"fancybox__video-content\\\">\\n <video autoplay muted loop style=\\\"width: 100%; height: auto; max-height: 100%;\\\">\\n <source src=\\\"\".concat(videoSource, \"\\\" type=\\\"video/mp4\\\" />\\n Your browser does not support the video tag.\\n </video>\\n <pause-button> \\n <button class=\\\"pause-button__fancybox-slider\\\"><svg class=\\\"icon-play hidden\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\" fill=\\\"none\\\" viewBox=\\\"0 0 48 48\\\">\\n <circle cx=\\\"24\\\" cy=\\\"24\\\" r=\\\"24\\\" fill=\\\"#3C3C43\\\"/>\\n <path fill=\\\"#fff\\\" d=\\\"m30.24 24-9.36 5.404V18.596z\\\"/>\\n <circle cx=\\\"24\\\" cy=\\\"24\\\" r=\\\"10.08\\\" stroke=\\\"#fff\\\" stroke-width=\\\".96\\\"/>\\n </svg>\\n <svg class=\\\"icon-pause\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\" fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\">\\n <circle cx=\\\"12\\\" cy=\\\"12\\\" r=\\\"12\\\" fill=\\\"#3C3C43\\\"/>\\n <circle cx=\\\"12\\\" cy=\\\"12\\\" r=\\\"5.04\\\" stroke=\\\"#fff\\\" stroke-width=\\\".48\\\"/>\\n <path fill=\\\"#fff\\\" d=\\\"M10.56 9.6h.72v4.8h-.72zM12.72 9.6h.72v4.8h-.72z\\\"/>\\n </svg>\\n </button> \\n </pause-button>\\n </div>\\n \"),\n thumb: figure.dataset.src\n };\n }\n\n // fallback to image from data-src\n return {\n type: \"image\",\n src: figure.dataset.src,\n caption: caption\n };\n });\n figures.forEach(function (figure, index) {\n // if (figure.classList.contains(\"video\")) return;\n figure.addEventListener(\"click\", function (e) {\n e.preventDefault();\n _fancyapps_ui__WEBPACK_IMPORTED_MODULE_0__.Fancybox.show(mediaItems, {\n startIndex: index,\n on: {\n done: function done() {\n document.querySelectorAll(\".fancybox__content img\").forEach(function (el) {\n el.classList.add(\"cursor-magnifiying-glass\");\n });\n }\n }\n });\n });\n });\n});\n\n//# sourceURL=webpack://gotbagtheme/./dev/js/lib/fancybox.js?\n}"); 1098 1099/***/ }, 1100 1101/***/ "./node_modules/gsap/CSSPlugin.js" 1102/*!****************************************!*\ 1103 !*** ./node_modules/gsap/CSSPlugin.js ***! 1104 \****************************************/ 1105(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1106 1107"use strict"; 1108eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ CSSPlugin: () => (/* binding */ CSSPlugin),\n/* harmony export */ _createElement: () => (/* binding */ _createElement),\n/* harmony export */ _getBBox: () => (/* binding */ _getBBox),\n/* harmony export */ checkPrefix: () => (/* binding */ _checkPropPrefix),\n/* harmony export */ \"default\": () => (/* binding */ CSSPlugin)\n/* harmony export */ });\n/* harmony import */ var _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./gsap-core.js */ \"./node_modules/gsap/gsap-core.js\");\n/*!\n * CSSPlugin 3.15.0\n * https://gsap.com\n *\n * Copyright 2008-2026, GreenSock. All rights reserved.\n * Subject to the terms at https://gsap.com/standard-license\n * @author: Jack Doyle, [email protected]\n*/\n\n/* eslint-disable */\n\n\nvar _win,\n _doc,\n _docElement,\n _pluginInitted,\n _tempDiv,\n _tempDivStyler,\n _recentSetterPlugin,\n _reverting,\n _windowExists = function _windowExists() {\n return typeof window !== \"undefined\";\n},\n _transformProps = {},\n _RAD2DEG = 180 / Math.PI,\n _DEG2RAD = Math.PI / 180,\n _atan2 = Math.atan2,\n _bigNum = 1e8,\n _capsExp = /([A-Z])/g,\n _horizontalExp = /(left|right|width|margin|padding|x)/i,\n _complexExp = /[\\s,\\(]\\S/,\n _propertyAliases = {\n autoAlpha: \"opacity,visibility\",\n scale: \"scaleX,scaleY\",\n alpha: \"opacity\"\n},\n _renderCSSProp = function _renderCSSProp(ratio, data) {\n return data.set(data.t, data.p, Math.round((data.s + data.c * ratio) * 10000) / 10000 + data.u, data);\n},\n _renderPropWithEnd = function _renderPropWithEnd(ratio, data) {\n return data.set(data.t, data.p, ratio === 1 ? data.e : Math.round((data.s + data.c * ratio) * 10000) / 10000 + data.u, data);\n},\n _renderCSSPropWithBeginning = function _renderCSSPropWithBeginning(ratio, data) {\n return data.set(data.t, data.p, ratio ? Math.round((data.s + data.c * ratio) * 10000) / 10000 + data.u : data.b, data);\n},\n //if units change, we need a way to render the original unit/value when the tween goes all the way back to the beginning (ratio:0)\n_renderCSSPropWithBeginningAndEnd = function _renderCSSPropWithBeginningAndEnd(ratio, data) {\n return data.set(data.t, data.p, ratio === 1 ? data.e : ratio ? Math.round((data.s + data.c * ratio) * 10000) / 10000 + data.u : data.b, data);\n},\n //if units change, we need a way to render the original unit/value when the tween goes all the way back to the beginning (ratio:0)\n_renderRoundedCSSProp = function _renderRoundedCSSProp(ratio, data) {\n var value = data.s + data.c * ratio;\n data.set(data.t, data.p, ~~(value + (value < 0 ? -.5 : .5)) + data.u, data);\n},\n _renderNonTweeningValue = function _renderNonTweeningValue(ratio, data) {\n return data.set(data.t, data.p, ratio ? data.e : data.b, data);\n},\n _renderNonTweeningValueOnlyAtEnd = function _renderNonTweeningValueOnlyAtEnd(ratio, data) {\n return data.set(data.t, data.p, ratio !== 1 ? data.b : data.e, data);\n},\n _setterCSSStyle = function _setterCSSStyle(target, property, value) {\n return target.style[property] = value;\n},\n _setterCSSProp = function _setterCSSProp(target, property, value) {\n return target.style.setProperty(property, value);\n},\n _setterTransform = function _setterTransform(target, property, value) {\n return target._gsap[property] = value;\n},\n _setterScale = function _setterScale(target, property, value) {\n return target._gsap.scaleX = target._gsap.scaleY = value;\n},\n _setterScaleWithRender = function _setterScaleWithRender(target, property, value, data, ratio) {\n var cache = target._gsap;\n cache.scaleX = cache.scaleY = value;\n cache.renderTransform(ratio, cache);\n},\n _setterTransformWithRender = function _setterTransformWithRender(target, property, value, data, ratio) {\n var cache = target._gsap;\n cache[property] = value;\n cache.renderTransform(ratio, cache);\n},\n _transformProp = \"transform\",\n _transformOriginProp = _transformProp + \"Origin\",\n _saveStyle = function _saveStyle(property, isNotCSS) {\n var _this = this;\n\n var target = this.target,\n style = target.style,\n cache = target._gsap;\n\n if (property in _transformProps && style) {\n this.tfm = this.tfm || {};\n\n if (property !== \"transform\") {\n property = _propertyAliases[property] || property;\n ~property.indexOf(\",\") ? property.split(\",\").forEach(function (a) {\n return _this.tfm[a] = _get(target, a);\n }) : this.tfm[property] = cache.x ? cache[property] : _get(target, property); // note: scale would map to \"scaleX,scaleY\", thus we loop and apply them both.\n\n property === _transformOriginProp && (this.tfm.zOrigin = cache.zOrigin);\n } else {\n return _propertyAliases.transform.split(\",\").forEach(function (p) {\n return _saveStyle.call(_this, p, isNotCSS);\n });\n }\n\n if (this.props.indexOf(_transformProp) >= 0) {\n return;\n }\n\n if (cache.svg) {\n this.svgo = target.getAttribute(\"data-svg-origin\");\n this.props.push(_transformOriginProp, isNotCSS, \"\");\n }\n\n property = _transformProp;\n }\n\n (style || isNotCSS) && this.props.push(property, isNotCSS, style[property]);\n},\n _removeIndependentTransforms = function _removeIndependentTransforms(style) {\n if (style.translate) {\n style.removeProperty(\"translate\");\n style.removeProperty(\"scale\");\n style.removeProperty(\"rotate\");\n }\n},\n _revertStyle = function _revertStyle() {\n var props = this.props,\n target = this.target,\n style = target.style,\n cache = target._gsap,\n i,\n p;\n\n for (i = 0; i < props.length; i += 3) {\n // stored like this: property, isNotCSS, value\n if (!props[i + 1]) {\n props[i + 2] ? style[props[i]] = props[i + 2] : style.removeProperty(props[i].substr(0, 2) === \"--\" ? props[i] : props[i].replace(_capsExp, \"-$1\").toLowerCase());\n } else if (props[i + 1] === 2) {\n // non-CSS value (function-based)\n target[props[i]](props[i + 2]);\n } else {\n // non-CSS value (not function-based)\n target[props[i]] = props[i + 2];\n }\n }\n\n if (this.tfm) {\n for (p in this.tfm) {\n cache[p] = this.tfm[p];\n }\n\n if (cache.svg) {\n cache.renderTransform();\n target.setAttribute(\"data-svg-origin\", this.svgo || \"\");\n }\n\n i = _reverting();\n\n if ((!i || !i.isStart) && !style[_transformProp]) {\n _removeIndependentTransforms(style);\n\n if (cache.zOrigin && style[_transformOriginProp]) {\n style[_transformOriginProp] += \" \" + cache.zOrigin + \"px\"; // since we're uncaching, we must put the zOrigin back into the transformOrigin so that we can pull it out accurately when we parse again. Otherwise, we'd lose the z portion of the origin since we extract it to protect from Safari bugs.\n\n cache.zOrigin = 0;\n cache.renderTransform();\n }\n\n cache.uncache = 1; // if it's a startAt that's being reverted in the _initTween() of the core, we don't need to uncache transforms. This is purely a performance optimization.\n }\n }\n},\n _getStyleSaver = function _getStyleSaver(target, properties) {\n var saver = {\n target: target,\n props: [],\n revert: _revertStyle,\n save: _saveStyle\n };\n target._gsap || _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.gsap.core.getCache(target); // just make sure there's a _gsap cache defined because we read from it in _saveStyle() and it's more efficient to just check it here once.\n\n properties && target.style && target.nodeType && properties.split(\",\").forEach(function (p) {\n return saver.save(p);\n }); // make sure it's a DOM node too.\n\n return saver;\n},\n _supports3D,\n _createElement = function _createElement(type, ns) {\n var e = _doc.createElementNS ? _doc.createElementNS((ns || \"http://www.w3.org/1999/xhtml\").replace(/^https/, \"http\"), type) : _doc.createElement(type); //some servers swap in https for http in the namespace which can break things, making \"style\" inaccessible.\n\n return e && e.style ? e : _doc.createElement(type); //some environments won't allow access to the element's style when created with a namespace in which case we default to the standard createElement() to work around the issue. Also note that when GSAP is embedded directly inside an SVG file, createElement() won't allow access to the style object in Firefox (see https://gsap.com/forums/topic/20215-problem-using-tweenmax-in-standalone-self-containing-svg-file-err-cannot-set-property-csstext-of-undefined/).\n},\n _getComputedProperty = function _getComputedProperty(target, property, skipPrefixFallback) {\n var cs = getComputedStyle(target);\n return cs[property] || cs.getPropertyValue(property.replace(_capsExp, \"-$1\").toLowerCase()) || cs.getPropertyValue(property) || !skipPrefixFallback && _getComputedProperty(target, _checkPropPrefix(property) || property, 1) || \"\"; //css variables may not need caps swapped out for dashes and lowercase.\n},\n _prefixes = \"O,Moz,ms,Ms,Webkit\".split(\",\"),\n _checkPropPrefix = function _checkPropPrefix(property, element, preferPrefix) {\n var e = element || _tempDiv,\n s = e.style,\n i = 5;\n\n if (property in s && !preferPrefix) {\n return property;\n }\n\n property = property.charAt(0).toUpperCase() + property.substr(1);\n\n while (i-- && !(_prefixes[i] + property in s)) {}\n\n return i < 0 ? null : (i === 3 ? \"ms\" : i >= 0 ? _prefixes[i] : \"\") + property;\n},\n _initCore = function _initCore() {\n if (_windowExists() && window.document) {\n _win = window;\n _doc = _win.document;\n _docElement = _doc.documentElement;\n _tempDiv = _createElement(\"div\") || {\n style: {}\n };\n _tempDivStyler = _createElement(\"div\");\n _transformProp = _checkPropPrefix(_transformProp);\n _transformOriginProp = _transformProp + \"Origin\";\n _tempDiv.style.cssText = \"border-width:0;line-height:0;position:absolute;padding:0\"; //make sure to override certain properties that may contaminate measurements, in case the user has overreaching style sheets.\n\n _supports3D = !!_checkPropPrefix(\"perspective\");\n _reverting = _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.gsap.core.reverting;\n _pluginInitted = 1;\n }\n},\n _getReparentedCloneBBox = function _getReparentedCloneBBox(target) {\n //works around issues in some browsers (like Firefox) that don't correctly report getBBox() on SVG elements inside a <defs> element and/or <mask>. We try creating an SVG, adding it to the documentElement and toss the element in there so that it's definitely part of the rendering tree, then grab the bbox and if it works, we actually swap out the original getBBox() method for our own that does these extra steps whenever getBBox is needed. This helps ensure that performance is optimal (only do all these extra steps when absolutely necessary...most elements don't need it).\n var owner = target.ownerSVGElement,\n svg = _createElement(\"svg\", owner && owner.getAttribute(\"xmlns\") || \"http://www.w3.org/2000/svg\"),\n clone = target.cloneNode(true),\n bbox;\n\n clone.style.display = \"block\";\n svg.appendChild(clone);\n\n _docElement.appendChild(svg);\n\n try {\n bbox = clone.getBBox();\n } catch (e) {}\n\n svg.removeChild(clone);\n\n _docElement.removeChild(svg);\n\n return bbox;\n},\n _getAttributeFallbacks = function _getAttributeFallbacks(target, attributesArray) {\n var i = attributesArray.length;\n\n while (i--) {\n if (target.hasAttribute(attributesArray[i])) {\n return target.getAttribute(attributesArray[i]);\n }\n }\n},\n _getBBox = function _getBBox(target) {\n var bounds, cloned;\n\n try {\n bounds = target.getBBox(); //Firefox throws errors if you try calling getBBox() on an SVG element that's not rendered (like in a <symbol> or <defs>). https://bugzilla.mozilla.org/show_bug.cgi?id=612118\n } catch (error) {\n bounds = _getReparentedCloneBBox(target);\n cloned = 1;\n }\n\n bounds && (bounds.width || bounds.height) || cloned || (bounds = _getReparentedCloneBBox(target)); //some browsers (like Firefox) misreport the bounds if the element has zero width and height (it just assumes it's at x:0, y:0), thus we need to manually grab the position in that case.\n\n return bounds && !bounds.width && !bounds.x && !bounds.y ? {\n x: +_getAttributeFallbacks(target, [\"x\", \"cx\", \"x1\"]) || 0,\n y: +_getAttributeFallbacks(target, [\"y\", \"cy\", \"y1\"]) || 0,\n width: 0,\n height: 0\n } : bounds;\n},\n _isSVG = function _isSVG(e) {\n return !!(e.getCTM && (!e.parentNode || e.ownerSVGElement) && _getBBox(e));\n},\n //reports if the element is an SVG on which getBBox() actually works\n_removeProperty = function _removeProperty(target, property) {\n if
1108(property) {\n var style = target.style,\n first2Chars;\n\n if (property in _transformProps && property !== _transformOriginProp) {\n property = _transformProp;\n }\n\n if (style.removeProperty) {\n first2Chars = property.substr(0, 2);\n\n if (first2Chars === \"ms\" || property.substr(0, 6) === \"webkit\") {\n //Microsoft and some Webkit browsers don't conform to the standard of capitalizing the first prefix character, so we adjust so that when we prefix the caps with a dash, it's correct (otherwise it'd be \"ms-transform\" instead of \"-ms-transform\" for IE9, for example)\n property = \"-\" + property;\n }\n\n style.removeProperty(first2Chars === \"--\" ? property : property.replace(_capsExp, \"-$1\").toLowerCase());\n } else {\n //note: old versions of IE use \"removeAttribute()\" instead of \"removeProperty()\"\n style.removeAttribute(property);\n }\n }\n},\n _addNonTweeningPT = function _addNonTweeningPT(plugin, target, property, beginning, end, onlySetAtEnd) {\n var pt = new _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.PropTween(plugin._pt, target, property, 0, 1, onlySetAtEnd ? _renderNonTweeningValueOnlyAtEnd : _renderNonTweeningValue);\n plugin._pt = pt;\n pt.b = beginning;\n pt.e = end;\n\n plugin._props.push(property);\n\n return pt;\n},\n _nonConvertibleUnits = {\n deg: 1,\n rad: 1,\n turn: 1\n},\n _nonStandardLayouts = {\n grid: 1,\n flex: 1\n},\n //takes a single value like 20px and converts it to the unit specified, like \"%\", returning only the numeric amount.\n_convertToUnit = function _convertToUnit(target, property, value, unit) {\n var curValue = parseFloat(value) || 0,\n curUnit = (value + \"\").trim().substr((curValue + \"\").length) || \"px\",\n // some browsers leave extra whitespace at the beginning of CSS variables, hence the need to trim()\n style = _tempDiv.style,\n horizontal = _horizontalExp.test(property),\n isRootSVG = target.tagName.toLowerCase() === \"svg\",\n measureProperty = (isRootSVG ? \"client\" : \"offset\") + (horizontal ? \"Width\" : \"Height\"),\n amount = 100,\n toPixels = unit === \"px\",\n toPercent = unit === \"%\",\n px,\n parent,\n cache,\n isSVG;\n\n if (unit === curUnit || !curValue || _nonConvertibleUnits[unit] || _nonConvertibleUnits[curUnit]) {\n return curValue;\n }\n\n curUnit !== \"px\" && !toPixels && (curValue = _convertToUnit(target, property, value, \"px\"));\n isSVG = target.getCTM && _isSVG(target);\n\n if ((toPercent || curUnit === \"%\") && (_transformProps[property] || ~property.indexOf(\"adius\"))) {\n px = isSVG ? target.getBBox()[horizontal ? \"width\" : \"height\"] : target[measureProperty];\n return (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(toPercent ? curValue / px * amount : curValue / 100 * px);\n }\n\n style[horizontal ? \"width\" : \"height\"] = amount + (toPixels ? curUnit : unit);\n parent = unit !== \"rem\" && ~property.indexOf(\"adius\") || unit === \"em\" && target.appendChild && !isRootSVG ? target : target.parentNode;\n\n if (isSVG) {\n parent = (target.ownerSVGElement || {}).parentNode;\n }\n\n if (!parent || parent === _doc || !parent.appendChild) {\n parent = _doc.body;\n }\n\n cache = parent._gsap;\n\n if (cache && toPercent && cache.width && horizontal && cache.time === _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._ticker.time && !cache.uncache) {\n return (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(curValue / cache.width * amount);\n } else {\n if (toPercent && (property === \"height\" || property === \"width\")) {\n // if we're dealing with width/height that's inside a container with padding and/or it's a flexbox/grid container, we must apply it to the target itself rather than the _tempDiv in order to ensure complete accuracy, factoring in the parent's padding.\n var v = target.style[property];\n target.style[property] = amount + unit;\n px = target[measureProperty];\n v ? target.style[property] = v : _removeProperty(target, property);\n } else {\n (toPercent || curUnit === \"%\") && !_nonStandardLayouts[_getComputedProperty(parent, \"display\")
1108] && (style.position = _getComputedProperty(target, \"position\"));\n parent === target && (style.position = \"static\"); // like for borderRadius, if it's a % we must have it relative to the target itself but that may not have position: relative or position: absolute in which case it'd go up the chain until it finds its offsetParent (bad). position: static protects against that.\n\n parent.appendChild(_tempDiv);\n px = _tempDiv[measureProperty];\n parent.removeChild(_tempDiv);\n style.position = \"absolute\";\n }\n\n if (horizontal && toPercent) {\n cache = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._getCache)(parent);\n cache.time = _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._ticker.time;\n cache.width = parent[measureProperty];\n }\n }\n\n return (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(toPixels ? px * curValue / amount : px && curValue ? amount / px * curValue : 0);\n},\n _get = function _get(target, property, unit, uncache) {\n var value;\n _pluginInitted || _initCore();\n\n if (property in _propertyAliases && property !== \"transform\") {\n property = _propertyAliases[property];\n\n if (~property.indexOf(\",\")) {\n property = property.split(\",\")[0];\n }\n }\n\n if (_transformProps[property] && property !== \"transform\") {\n value = _parseTransform(target, uncache);\n value = property !== \"transformOrigin\" ? value[property] : value.svg ? value.origin : _firstTwoOnly(_getComputedProperty(target, _transformOriginProp)) + \" \" + value.zOrigin + \"px\";\n } else {\n value = target.style[property];\n\n if (!value || value === \"auto\" || uncache || ~(value + \"\").indexOf(\"calc(\")) {\n value = _specialProps[property] && _specialProps[property](target, property, unit) || _getComputedProperty(target, property) || (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._getProperty)(target, property) || (property === \"opacity\" ? 1 : 0); // note: some browsers, like Firefox, don't report borderRadius correctly! Instead, it only reports every corner like borderTopLeftRadius\n }\n }\n\n return unit && !~(value + \"\").trim().indexOf(\" \") ? _convertToUnit(target, property, value, unit) + unit : value;\n},\n _tweenComplexCSSString = function _tweenComplexCSSString(target, prop, start, end) {\n // note: we call _tweenComplexCSSString.call(pluginInstance...) to ensure that it's scoped properly. We may call it from within a plugin too, thus \"this\" would refer to the plugin.\n if (!start || start === \"none\") {\n // some browsers like Safari actually PREFER the prefixed property and mis-report the unprefixed value like clipPath (BUG). In other words, even though clipPath exists in the style (\"clipPath\" in target.style) and it's set in the CSS properly (along with -webkit-clip-path), Safari reports clipPath as \"none\" whereas WebkitClipPath reports accurately like \"ellipse(100% 0% at 50% 0%)\", so in this case we must SWITCH to using the prefixed property instead. See https://gsap.com/forums/topic/18310-clippath-doesnt-work-on-ios/\n var p = _checkPropPrefix(prop, target, 1),\n s = p && _getComputedProperty(target, p, 1);\n\n if (s && s !== start) {\n prop = p;\n start = s;\n } else if (prop === \"borderColor\") {\n start = _getComputedProperty(target, \"borderTopColor\"); // Firefox bug: always reports \"borderColor\" as \"\", so we must fall back to borderTopColor. See https://gsap.com/forums/topic/24583-how-to-return-colors-that-i-had-after-reverse/\n }\n }\n\n var pt = new _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.PropTween(this._pt, target.style, prop, 0, 1, _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._renderComplexString),\n index = 0,\n matchIndex = 0,\n a,\n result,\n startValues,\n startNum,\n color,\n startValue,\n endValue,\n endNum,\n chunk,\n endUnit,\n startUnit,\n endValues;\n pt.b = start;\n pt.e = end;\n start += \"\"; // ensure values are strings\n\n end += \"\";\n\n if (end.substring(0, 6) === \"var(--\") {\n end = _getComputedProperty(target, end.substring(4, end.indexOf(\")\")));\n }\n\n if (end === \"auto\") {\n startValue = target.style[prop];\n target.style[prop] = end;\n end = _getComputedProperty(target, prop) || end;\n startValue ? target.style[prop] = startValue : _removeProperty(target, prop);\n }\n\n a = [start, end];\n\n (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._colorStringFilter)(a); // pass an array with the starting and ending values and let the filter do whatever it needs to the values. If colors are found, it returns true and then we must match where the color shows up order-wise because for things like boxShadow, sometimes the browser provides the computed values with the color FIRST, but the user provides it with the color LAST, so flip them if necessary. Same for drop-shadow().\n\n\n start = a[0];\n end = a[1];\n startValues = start.match(_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._numWithUnitExp) || [];\n endValues = end.match(_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._numWithUnitExp) || [];\n\n if (endValues.length) {\n while (result = _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._numWithUnitExp.exec(end)) {\n endValue = result[0];\n chunk = end.substring(index, result.index);\n\n if (color) {\n color = (color + 1) % 5;\n } else if (chunk.substr(-5) === \"rgba(\" || chunk.substr(-5) === \"hsla(\") {\n color = 1;\n }\n\n if (endValue !== (startValue = startValues[matchIndex++] || \"\")) {\n startNum = parseFloat(startValue) || 0;\n startUnit = startValue.substr((startNum + \"\").length);\n endValue.charAt(1) === \"=\" && (endValue = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._parseRelative)(startNum, endValue) + startUnit);\n endNum = parseFloat(endValue);\n endUnit = endValue.substr((endNum + \"\").length);\n index = _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._numWithUnitExp.lastIndex - endUnit.length;\n\n if (!endUnit) {\n //if something like \"perspective:300\" is passed in and we must add a unit to the end\n endUnit = endUnit || _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._config.units[prop] || startUnit;\n\n if (index === end.length) {\n end += endUnit;\n pt.e += endUnit;\n }\n }\n\n if (startUnit !== endUnit) {\n startNum = _convertToUnit(target, prop, startValue, endUnit) || 0;\n } // these nested PropTweens are handled in a special way - we'll never actually call a render or setter method on them. We'll just loop through them in the parent complex string PropTween's render method.\n\n\n pt._pt = {\n _next: pt._pt,\n p: chunk || matchIndex === 1 ? chunk : \",\",\n //note: SVG spec allows om
1108ission of comma/space when a negative sign is wedged between two numbers, like 2.5-5.3 instead of 2.5,-5.3 but when tweening, the negative value may switch to positive, so we insert the comma just in case.\n s: startNum,\n c: endNum - startNum,\n m: color && color < 4 || prop === \"zIndex\" ? Math.round : 0\n };\n }\n }\n\n pt.c = index < end.length ? end.substring(index, end.length) : \"\"; //we use the \"c\" of the PropTween to store the final part of the string (after the last number)\n } else {\n pt.r = prop === \"display\" && end === \"none\" ? _renderNonTweeningValueOnlyAtEnd : _renderNonTweeningValue;\n }\n\n _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._relExp.test(end) && (pt.e = 0); //if the end string contains relative values or dynamic random(...) values, delete the end it so that on the final render we don't actually set it to the string with += or -= characters (forces it to use the calculated value).\n\n this._pt = pt; //start the linked list with this new PropTween. Remember, we call _tweenComplexCSSString.call(pluginInstance...) to ensure that it's scoped properly. We may call it from within another plugin too, thus \"this\" would refer to the plugin.\n\n return pt;\n},\n _keywordToPercent = {\n top: \"0%\",\n bottom: \"100%\",\n left: \"0%\",\n right: \"100%\",\n center: \"50%\"\n},\n _convertKeywordsToPercentages = function _convertKeywordsToPercentages(value) {\n var split = value.split(\" \"),\n x = split[0],\n y = split[1] || \"50%\";\n\n if (x === \"top\" || x === \"bottom\" || y === \"left\" || y === \"right\") {\n //the user provided them in the wrong order, so flip them\n value = x;\n x = y;\n y = value;\n }\n\n split[0] = _keywordToPercent[x] || x;\n split[1] = _keywordToPercent[y] || y;\n return split.join(\" \");\n},\n _renderClearProps = function _renderClearProps(ratio, data) {\n if (data.tween && data.tween._time === data.tween._dur) {\n var target = data.t,\n style = target.style,\n props = data.u,\n cache = target._gsap,\n prop,\n clearTransforms,\n i;\n\n if (props === \"all\" || props === true) {\n style.cssText = \"\";\n clearTransforms = 1;\n } else {\n props = props.split(\",\");\n i = props.length;\n\n while (--i > -1) {\n prop = props[i];\n\n if (_transformProps[prop]) {\n clearTransforms = 1;\n prop = prop === \"transformOrigin\" ? _transformOriginProp : _transformProp;\n }\n\n _removeProperty(target, prop);\n }\n }\n\n if (clearTransforms) {\n _removeProperty(target, _transformProp);\n\n if (cache) {\n cache.svg && target.removeAttribute(\"transform\");\n style.scale = style.rotate = style.translate = \"none\";\n\n _parseTransform(target, 1); // force all the cached values back to \"normal\"/identity, otherwise if there's another tween that's already set to render transforms on this element, it could display the wrong values.\n\n\n cache.uncache = 1;\n\n _removeIndependentTransforms(style);\n }\n }\n }\n},\n // note: specialProps should return 1 if (and only if) they have a non-zero priority. It indicates we need to sort the linked list.\n_specialProps = {\n clearProps: function clearProps(plugin, target, property, endValue, tween) {\n if (tween.data !== \"isFromStart\") {\n var pt = plugin._pt = new _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.PropTween(plugin._pt, target, property, 0, 0, _renderClearProps);\n pt.u = endValue;\n pt.pr = -10;\n pt.tween = tween;\n\n plugin._props.push(property);\n\n return 1;\n }\n }\n /* className feature (about 0.4kb gzipped).\n , className(plugin, target, property, endValue, tween) {\n \tlet _renderClassName = (ratio, data) => {\n \t\t\tdata.css.render(ratio, data.css);\n \t\t\tif (!ratio || ratio === 1) {\n \t\t\t\tlet inline = data.rmv,\n \t\t\t\t\ttarget = data.t,\n \t\t\t\t\tp;\n \t\t\t\ttarget.setAttribute(\"class\", ratio ? data.e : data.b);\n \t\t\t\tfor (p in inline) {\n \t\t\t\t\t_removeProperty(target, p);\n \t\t\t\t}\n \t\t\t}\n \t\t},\n \t\t_getAllStyles = (target) => {\n \t\t\tlet styles = {},\n \t\t\t\tcomputed = getComputedStyle(target),\n \t\t\t\tp;
1108\n \t\t\tfor (p in computed) {\n \t\t\t\tif (isNaN(p) && p !== \"cssText\" && p !== \"length\") {\n \t\t\t\t\tstyles[p] = computed[p];\n \t\t\t\t}\n \t\t\t}\n \t\t\t_setDefaults(styles, _parseTransform(target, 1));\n \t\t\treturn styles;\n \t\t},\n \t\tstartClassList = target.getAttribute(\"class\"),\n \t\tstyle = target.style,\n \t\tcssText = style.cssText,\n \t\tcache = target._gsap,\n \t\tclassPT = cache.classPT,\n \t\tinlineToRemoveAtEnd = {},\n \t\tdata = {t:target, plugin:plugin, rmv:inlineToRemoveAtEnd, b:startClassList, e:(endValue.charAt(1) !== \"=\") ? endValue : startClassList.replace(new RegExp(\"(?:\\\\s|^)\" + endValue.substr(2) + \"(?![\\\\w-])\"), \"\") + ((endValue.charAt(0) === \"+\") ? \" \" + endValue.substr(2) : \"\")},\n \t\tchangingVars = {},\n \t\tstartVars = _getAllStyles(target),\n \t\ttransformRelated = /(transform|perspective)/i,\n \t\tendVars, p;\n \tif (classPT) {\n \t\tclassPT.r(1, classPT.d);\n \t\t_removeLinkedListItem(classPT.d.plugin, classPT, \"_pt\");\n \t}\n \ttarget.setAttribute(\"class\", data.e);\n \tendVars = _getAllStyles(target, true);\n \ttarget.setAttribute(\"class\", startClassList);\n \tfor (p in endVars) {\n \t\tif (endVars[p] !== startVars[p] && !transformRelated.test(p)) {\n \t\t\tchangingVars[p] = endVars[p];\n \t\t\tif (!style[p] && style[p] !== \"0\") {\n \t\t\t\tinlineToRemoveAtEnd[p] = 1;\n \t\t\t}\n \t\t}\n \t}\n \tcache.classPT = plugin._pt = new PropTween(plugin._pt, target, \"className\", 0, 0, _renderClassName, data, 0, -11);\n \tif (style.cssText !== cssText) { //only apply if things change. Otherwise, in cases like a background-image that's pulled dynamically, it could cause a refresh. See https://gsap.com/forums/topic/20368-possible-gsap-bug-switching-classnames-in-chrome/.\n \t\tstyle.cssText = cssText; //we recorded cssText before we swapped classes and ran _getAllStyles() because in cases when a className tween is overwritten, we remove all the related tweening properties from that class change (otherwise class-specific stuff can't override properties we've directly set on the target's style object due to specificity).\n \t}\n \t_parseTransform(target, true); //to clear the caching of transforms\n \tdata.css = new gsap.plugins.css();
1108\n \tdata.css.init(target, changingVars, tween);\n \tplugin._props.push(...data.css._props);\n \treturn 1;\n }\n */\n\n},\n\n/*\n * --------------------------------------------------------------------------------------\n * TRANSFORMS\n * --------------------------------------------------------------------------------------\n */\n_identity2DMatrix = [1, 0, 0, 1, 0, 0],\n _rotationalProperties = {},\n _isNullTransform = function _isNullTransform(value) {\n return value === \"matrix(1, 0, 0, 1, 0, 0)\" || value === \"none\" || !value;\n},\n _getComputedTransformMatrixAsArray = function _getComputedTransformMatrixAsArray(target) {\n var matrixString = _getComputedProperty(target, _transformProp);\n\n return _isNullTransform(matrixString) ? _identity2DMatrix : matrixString.substr(7).match(_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._numExp).map(_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round);\n},\n _getMatrix = function _getMatrix(target, force2D) {\n var cache = target._gsap || (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._getCache)(target),\n style = target.style,\n matrix = _getComputedTransformMatrixAsArray(target),\n parent,\n nextSibling,\n temp,\n addedToDOM;\n\n if (cache.svg && target.getAttribute(\"transform\")) {\n temp = target.transform.baseVal.consolidate().matrix; //ensures that even complex values like \"translate(50,60) rotate(135,0,0)\" are parsed because it mashes it into a matrix.\n\n matrix = [temp.a, temp.b, temp.c, temp.d, temp.e, temp.f];\n return matrix.join(\",\") === \"1,0,0,1,0,0\" ? _identity2DMatrix : matrix;\n } else if (matrix === _identity2DMatrix && !target.offsetParent && target !== _docElement && !cache.svg) {\n //note: if offsetParent is null, that means the element isn't in the normal document flow, like if it has display:none or one of its ancestors has display:none). Firefox returns null for getComputedStyle() if the element is in an iframe that has display:none. https://bugzilla.mozilla.org/show_bug.cgi?id=548397\n //browsers don't report transforms accurately unless the element is in the DOM and has a display value that's not \"none\". Firefox and Microsoft browsers have a partial bug where they'll report transforms even if display:none BUT not any percentage-based values like translate(-50%, 8px) will be reported as if it's translate(0, 8px).\n temp = style.display;\n style.display = \"block\";\n parent = target.parentNode;\n\n if (!parent || !target.offsetParent && !target.getBoundingClientRect().width) {\n // note: in 3.3.0 we switched target.offsetParent to _doc.body.contains(target) to avoid [sometimes unnecessary] MutationObserver calls but that wasn't adequate because there are edge cases where nested position: fixed elements need to get reparented to accurately sense transforms. See https://github.com/greensock/GSAP/issues/388 and https://github.com/greensock/GSAP/issues/375. Note: position: fixed elements report a null offsetParent but they could also be invisible because they're in an ancestor with display: none, so we check getBoundingClientRect(). We only want to alter the DOM if we absolutely have to because it can cause iframe content to reload, like a Vimeo video.\n addedToDOM = 1; //flag\n\n nextSibling = target.nextElementSibling;\n\n _docElement.appendChild(target); //we must add it to the DOM in order to get values properly\n\n }\n\n matrix = _getComputedTransformMatrixAsArray(target);\n temp ? style.display = temp : _removeProperty(target, \"display\");
1108\n\n if (addedToDOM) {\n nextSibling ? parent.insertBefore(target, nextSibling) : parent ? parent.appendChild(target) : _docElement.removeChild(target);\n }\n }\n\n return force2D && matrix.length > 6 ? [matrix[0], matrix[1], matrix[4], matrix[5], matrix[12], matrix[13]] : matrix;\n},\n _applySVGOrigin = function _applySVGOrigin(target, origin, originIsAbsolute, smooth, matrixArray, pluginToAddPropTweensTo) {\n var cache = target._gsap,\n matrix = matrixArray || _getMatrix(target, true),\n xOriginOld = cache.xOrigin || 0,\n yOriginOld = cache.yOrigin || 0,\n xOffsetOld = cache.xOffset || 0,\n yOffsetOld = cache.yOffset || 0,\n a = matrix[0],\n b = matrix[1],\n c = matrix[2],\n d = matrix[3],\n tx = matrix[4],\n ty = matrix[5],\n originSplit = origin.split(\" \"),\n xOrigin = parseFloat(originSplit[0]) || 0,\n yOrigin = parseFloat(originSplit[1]) || 0,\n bounds,\n determinant,\n x,\n y;\n\n if (!originIsAbsolute) {\n bounds = _getBBox(target);\n xOrigin = bounds.x + (~originSplit[0].indexOf(\"%\") ? xOrigin / 100 * boun
1108ds.width : xOrigin);\n yOrigin = bounds.y + (~(originSplit[1] || originSplit[0]).indexOf(\"%\") ? yOrigin / 100 * bounds.height : yOrigin); // if (!(\"xOrigin\" in cache) && (xOrigin || yOrigin)) { // added in 3.12.3, reverted in 3.12.4; requires more exploration\n // \txOrigin -= bounds.x;\n // \tyOrigin -= bounds.y;\n // }\n } else if (matrix !== _identity2DMatrix && (determinant = a * d - b * c)) {\n //if it's zero (like if scaleX and scaleY are zero), skip it to avoid errors with dividing by zero.\n x = xOrigin * (d / determinant) + yOrigin * (-c / determinant) + (c * ty - d * tx) / determinant;\n y = xOrigin * (-b / determinant) + yOrigin * (a / determinant) - (a * ty - b * tx) / determinant;\n xOrigin = x;\n yOrigin = y; // theory: we only had to do this for smoothing and it assumes that the previous one was not originIsAbsolute.\n }\n\n if (smooth || smooth !== false && cache.smooth) {\n tx = xOrigin - xOriginOld;\n ty = yOrigin - yOriginOld;\n cache.xOffset = xOffsetOld + (tx * a + ty * c) - tx;\n cache.yOffset = yOffsetOld + (tx * b + ty * d) - ty;\n } else {\n cache.xOffset = cache.yOffset = 0;\n }\n\n cache.xOrigin = xOrigin;\n cache.yOrigin = yOrigin;\n cache.smooth = !!smooth;\n cache.origin = origin;\n cache.originIsAbsolute = !!originIsAbsolute;\n target.style[_transformOriginProp] = \"0px 0px\"; //otherwise, if someone sets an origin via CSS, it will likely interfere with the SVG transform attribute ones (because remember, we're baking the origin into the matrix() value).\n\n if (pluginToAddPropTweensTo) {\n _addNonTweeningPT(pluginToAddPropTweensTo, cache, \"xOrigin\", xOriginOld, xOrigin);\n\n _addNonTweeningPT(pluginToAddPropTweensTo, cache, \"yOrigin\", yOriginOld, yOrigin);\n\n _addNonTweeningPT(pluginToAddPropTweensTo, cache, \"xOffset\", xOffsetOld, cache.xOffset);\n\n _addNonTweeningPT(pluginToAddPropTweensTo, cache, \"yOffset\", yOffsetOld, cache.yOffset);\n }\n\n target.setAttribute(\"data-svg-origin\", xOrigin + \" \" + yOrigin);\n},\n _parseTransform = function _parseTransform(target, uncache) {\n var cache = target._gsap || new _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.GSCache(target);\n\n if (\"x\" in cache && !uncache && !cache.uncache) {\n return cache;\n }\n\n var style = target.style,\n invertedScaleX = cache.scaleX < 0,\n px = \"px\",\n deg = \"deg\",\n cs = getComputedStyle(target),\n origin = _getComputedProperty(target, _transformOriginProp) || \"0\",\n x,\n y,\n z,\n scaleX,\n scaleY,\n rotation,\n rotationX,\n rotationY,\n skewX,\n skewY,\n perspective,\n xOrigin,\n yOrigin,\n matrix,\n angle,\n cos,\n sin,\n a,\n b,\n c,\n d,\n a12,\n a22,\n t1,\n t2,\n t3,\n a13,\n a23,\n a33,\n a42,\n a43,\n a32;\n x = y = z = rotation = rotationX = rotationY = skewX = skewY = perspective = 0;\n scaleX = scaleY = 1;\n cache.svg = !!(target.getCTM && _isSVG(target));\n\n if (cs.translate) {\n // accommodate independent transforms by combining them into normal ones.\n if (cs.translate !== \"none\" || cs.scale !== \"none\" || cs.rotate !== \"none\") {\n style[_transformProp] = (cs.translate !== \"none\" ? \"translate3d(\" + (cs.translate + \" 0 0\").split(\" \").slice(0, 3).join(\", \") + \") \" : \"\") + (cs.rotate !== \"none\" ? \"rotate(\" + cs.rotate + \") \" : \"\") + (cs.scale !== \"none\" ? \"scale(\" + cs.scale.split(\" \").join(\",\") + \") \" : \"\") + (cs[_transformProp] !== \"none\" ? cs[_transformProp] : \"\");\n }\n\n style.scale = style.rotate = style.translate = \"none\";\n }\n\n matrix = _getMatrix(target, cache.svg);\n\n if (cache.svg) {\n if (cache.uncache) {\n // if cache.uncache is true (and maybe if origin is 0,0), we need to set element.style.transformOrigin = (cache.xOrigin - bbox.x) + \"px \" + (cache.yOrigin - bbox.y) + \"px\". Previously we let the data-svg-origin stay instead, but when introducing revert(), it complicated things.\n t2 = target.getBBox();\n origin = cache.xOrigin - t2.x + \"px \" + (cache.yOrigin - t2.y) + \"px\";\n t1 = \"\";\n } else {\n t1 = !uncache && target.getAttribute(\"data-svg-origin\"); // Remember, to work around browser inconsistencies we always force SVG elements' transformOrigin to 0,0 and offset the translation accordingly.\n }\n\n _applySVGOrigin(target, t1 || origin, !!t1 || cache.originIsAbsolute, cache.smooth !== false, matrix
1108);\n }\n\n xOrigin = cache.xOrigin || 0;\n yOrigin = cache.yOrigin || 0;\n\n if (matrix !== _identity2DMatrix) {\n a = matrix[0]; //a11\n\n b = matrix[1]; //a21\n\n c = matrix[2]; //a31\n\n d = matrix[3]; //a41\n\n x = a12 = matrix[4];\n y = a22 = matrix[5]; //2D matrix\n\n if (matrix.length === 6) {\n scaleX = Math.sqrt(a * a + b * b);\n scaleY = Math.sqrt(d * d + c * c);\n rotation = a || b ? _atan2(b, a) * _RAD2DEG : 0; //note: if scaleX is 0, we cannot accurately measure rotation. Same for skewX with a scaleY of 0. Therefore, we default to the previously recorded value (or zero if that doesn't exist).\n\n skewX = c || d ? _atan2(c, d) * _RAD2DEG + rotation : 0;\n skewX && (scaleY *= Math.abs(Math.cos(skewX * _DEG2RAD)));\n\n if (cache.svg) {\n x -= xOrigin - (xOrigin * a + yOrigin * c);\n y -= yOrigin - (xOrigin * b + yOrigin * d);\n } //3D matrix\n\n } else {\n a32 = matrix[6];\n a42 = matrix[7];\n a13 = matrix[8];\n a23 = matrix[9];\n a33 = matrix[10];\n a43 = matrix[11];\n x = matrix[12];\n y = matrix[13];\n z = matrix[14];\n angle = _atan2(a32, a33);\n rotationX = angle * _RAD2DEG; //rotationX\n\n if (angle) {\n cos = Math.cos(-angle);\n sin = Math.sin(-angle);\n t1 = a12 * cos + a13 * sin;\n t2 = a22 * cos + a23 * sin;\n t3 = a32 * cos + a33 * sin;\n a13 = a12 * -sin + a13 * cos;\n a23 = a22 * -sin + a23 * cos;\n a33 = a32 * -sin + a33 * cos;\n a43 = a42 * -sin + a43 * cos;\n a12 = t1;\n a22 = t2;\n a32 = t3;\n } //rotationY\n\n\n angle = _atan2(-c, a33);\n rotationY = angle * _RAD2DEG;\n\n if (angle) {\n cos = Math.cos(-angle);\n sin = Math.sin(-angle);\n t1 = a * cos - a13 * sin;\n t2 = b * cos - a23 * sin;\n t3 = c * cos - a33 * sin;\n a43 = d * sin + a43 * cos;\n a = t1;\n b = t2;\n c = t3;\n } //rotationZ\n\n\n angle = _atan2(b, a);\n rotation = angle * _RAD2DEG;\n\n if (angle) {\n cos = Math.cos(angle);\n sin = Math.sin(angle);\n t1 = a * cos + b * sin;\n t2 = a12 * cos + a22 * sin;\n b = b * cos - a * sin;\n a22 = a22 * cos - a12 * sin;\n a = t1;\n a12 = t2;\n }\n\n if (rotationX && Math.abs(rotationX) + Math.abs(rotation) > 359.9) {\n //when rotationY is set, it will often be parsed as 180 degrees different than it should be, and rotationX and rotation both being 180 (it looks the same), so we adjust for that here.\n rotationX = rotation = 0;\n rotationY = 180 - rotationY;\n }\n\n scaleX = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(Math.sqrt(a * a + b * b + c * c));\n scaleY = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(Math.sqrt(a22 * a22 + a32 * a32));\n angle = _atan2(a12, a22);\n skewX = Math.abs(angle) > 0.0002 ? angle * _RAD2DEG : 0;\n perspective = a43 ? 1 / (a43 < 0 ? -a43 : a43) : 0;\n }\n\n if (cache.svg) {\n //sense if there are CSS transforms applied on an SVG element in which case we must overwrite them when rendering. The transform attribute is more reliable cross-browser, but we can't just remove the CSS ones because they may be applied in a CSS rule somewhere (not just inline).\n t1 = target.getAttribute(\"transform\");\n cache.forceCSS = target.setAttribute(\"transform\", \"\") || !_isNullTransform(_getComputedProperty(target, _transformProp));\n t1 && target.setAttribute(\"transform\", t1);\n }\n }\n\n if (Math.abs(skewX) > 90 && Math.abs(skewX) < 270) {\n if (invertedScaleX) {\n scaleX *= -1;\n skewX += rotation <= 0 ? 180 : -180;\n rotation += rotation <= 0 ? 180 : -180;\n } else {\n scaleY *= -1;\n skewX += skewX <= 0 ? 180 : -180;\n }\n }\n\n uncache = uncache || cache.uncache;\n cache.x = x - ((cache.xPercent = x && (!uncache && cache.xPercent || (Math.round(target.offsetWidth / 2) === Math.round(-x) ? -50 : 0))) ? target.offsetWidth * cache.xPercent / 100 : 0) + px;\n cache.y = y - ((cache.yPercent = y && (!uncache && cache.yPercent || (Math.round(target.offsetHeight / 2) === Math.round(-y) ? -50 : 0))) ? target.offsetHeight * cache.yPercent / 100 : 0) + px;\n cache.z = z + px;\n cache.scaleX = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(scaleX);\n cache.scaleY = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(scaleY);\n cache.rotation = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(rotation) + deg;
1108\n cache.rotationX = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(rotationX) + deg;\n cache.rotationY = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(rotationY) + deg;\n cache.skewX = skewX + deg;\n cache.skewY = skewY + deg;\n cache.transformPerspective = perspective + px;\n\n if (cache.zOrigin = parseFloat(origin.split(\" \")[2]) || !uncache && cache.zOrigin || 0) {\n style[_transformOriginProp] = _firstTwoOnly(origin);\n }\n\n cache.xOffset = cache.yOffset = 0;\n cache.force3D = _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._config.force3D;\n cache.renderTransform = cache.svg ? _renderSVGTransforms : _supports3D ? _renderCSSTransforms : _renderNon3DTransforms;\n cache.uncache = 0;\n return cache;\n},\n _firstTwoOnly = function _firstTwoOnly(value) {\n return (value = value.split(\" \"))[0] + \" \" + value[1];\n},\n //for handling transformOrigin values, stripping out the 3rd dimension\n_addPxTranslate = function _addPxTranslate(target, start, value) {\n var unit = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.getUnit)(start);\n return (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(parseFloat(start) + parseFloat(_convertToUnit(target, \"x\", value + \"px\", unit))) + unit;\n},\n _renderNon3DTransforms = function _renderNon3DTransforms(ratio, cache) {\n cache.z = \"0px\";\n cache.rotationY = cache.rotationX = \"0deg\";\n cache.force3D = 0;\n\n _renderCSSTransforms(ratio, cache);\n},\n _zeroDeg = \"0deg\",\n _zeroPx = \"0px\",\n _endParenthesis = \") \",\n _renderCSSTransforms = function _renderCSSTransforms(ratio, cache) {\n var _ref = cache || this,\n xPercent = _ref.xPercent,\n yPercent = _ref.yPercent,\n x = _ref.x,\n y = _ref.y,\n z = _ref.z,\n rotation = _ref.rotation,\n rotationY = _ref.rotationY,\n rotationX = _ref.rotationX,\n skewX = _ref.skewX,\n skewY = _ref.skewY,\n scaleX = _ref.scaleX,\n scaleY = _ref.scaleY,\n transformPerspective = _ref.transformPerspective,\n force3D = _ref.force3D,\n target = _ref.target,\n zOrigin = _ref.zOrigin,\n transforms = \"\",\n use3D = force3D === \"auto\" && ratio && ratio !== 1 || force3D === true; // Safari has a bug that causes it not to render 3D transform-origin values properly, so we force the z origin to 0, record it in the cache, and then do the math here to offset the translate values accordingly (basically do the 3D transform-origin part manually)\n\n\n if (zOrigin && (rotationX !== _zeroDeg || rotationY !== _zeroDeg)) {\n var angle = parseFloat(rotationY) * _DEG2RAD,\n a13 = Math.sin(angle),\n a33 = Math.cos(angle),\n cos;\n\n angle = parseFloat(rotationX) * _DEG2RAD;\n cos = Math.cos(angle);\n x = _addPxTranslate(target, x, a13 * cos * -zOrigin);\n y = _addPxTranslate(target, y, -Math.sin(angle) * -zOrigin);\n z = _addPxTranslate(target, z, a33 * cos * -zOrigin + zOrigin);\n }\n\n if (transformPerspective !== _zeroPx) {\n transforms += \"perspective(\" + transformPerspective + _endParenthesis;\n }\n\n if (xPercent || yPercent) {\n transforms += \"translate(\" + xPercent + \"%, \" + yPercent + \"%) \";\n }\n\n if (use3D || x !== _zeroPx || y !== _zeroPx || z !== _zeroPx) {\n transforms += z !== _zeroPx || use3D ? \"translate3d(\" + x + \", \" + y + \", \" + z + \") \" : \"translate(\" + x + \", \" + y + _endParenthesis;\n }\n\n if (rotation !== _zeroDeg) {\n transforms += \"rotate(\" + rotation + _endParenthesis;\n }\n\n if (rotationY !== _zeroDeg) {\n transforms += \"rotateY(\" + rotationY + _endParenthesis;\n }\n\n if (rotationX !== _zeroDeg) {\n transforms += \"rotateX(\" + rotationX + _endParenthesis;\n }\n\n if (skewX !== _zeroDeg || skewY !== _zeroDeg) {\n transforms += \"skew(\" + skewX + \", \" + skewY + _endParenthesis;\n }\n\n if (scaleX !== 1 || scaleY !== 1) {\n transforms += \"scale(\" + scaleX + \", \" + scaleY + _endParenthesis;\n }\n\n target.style[_transformProp] = transforms || \"translate(0, 0)\";\n},\n _renderSVGTransforms = function _renderSVGTransforms(ratio, cache) {\n var _ref2 = cache || this,\n xPercent = _ref2.xPercent,\n yPercent = _ref2.yPercent,\n x = _ref2.x,\n y = _ref2.y,\n rotation = _ref2.rotation,\n skewX = _ref2.skewX,\n skewY = _ref2.skewY,\n scaleX = _ref2.scaleX,\n scaleY = _ref2.scaleY,\n target = _ref2.target,\n xOrigin = _ref2.xOrigin,\n yOrigin = _ref2.yOrigin,\n xOffset = _ref2.xOffset,\n yOffset = _ref2.yOffset,\n forceCSS = _ref2.forceCSS,\n tx = parseFloat(x),\n ty = parseFloat(y),\n a11,\n a21,\n a12,\n a22,\n temp;\n\n rotation = parseFloat(rotation);\n skewX = parseFloat(skewX);\n skewY = parseFloat(skewY);
1108\n\n if (skewY) {\n //for performance reasons, we combine all skewing into the skewX and rotation values. Remember, a skewY of 10 degrees looks the same as a rotation of 10 degrees plus a skewX of 10 degrees.\n skewY = parseFloat(skewY);\n skewX += skewY;\n rotation += skewY;\n }\n\n if (rotation || skewX) {\n rotation *= _DEG2RAD;\n skewX *= _DEG2RAD;\n a11 = Math.cos(rotation) * scaleX;\n a21 = Math.sin(rotation) * scaleX;\n a12 = Math.sin(rotation - skewX) * -scaleY;\n a22 = Math.cos(rotation - skewX) * scaleY;\n\n if (skewX) {\n skewY *= _DEG2RAD;\n temp = Math.tan(skewX - skewY);\n temp = Math.sqrt(1 + temp * temp);\n a12 *= temp;\n a22 *= temp;\n\n if (skewY) {\n temp = Math.tan(skewY);\n temp = Math.sqrt(1 + temp * temp);\n a11 *= temp;\n a21 *= temp;\n }\n }\n\n a11 = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(a11);\n a21 = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(a21);\n a12 = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(a12);\n a22 = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(a22);\n } else {\n a11 = scaleX;\n a22 = scaleY;\n a21 = a12 = 0;\n }\n\n if (tx && !~(x + \"\").indexOf(\"px\") || ty && !~(y + \"\").indexOf(\"px\")) {\n tx = _convertToUnit(target, \"x\", x, \"px\");\n ty = _convertToUnit(target, \"y\", y, \"px\");\n }\n\n if (xOrigin || yOrigin || xOffset || yOffset) {\n tx = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(tx + xOrigin - (xOrigin * a11 + yOrigin * a12) + xOffset);\n ty = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(ty + yOrigin - (xOrigin * a21 + yOrigin * a22) + yOffset);\n }\n\n if (xPercent || yPercent) {\n //The SVG spec doesn't support percentage-based translation in the \"transform\" attribute, so we merge it into the translation to simulate it.\n temp = target.getBBox();\n tx = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(tx + xPercent / 100 * temp.width);\n ty = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._round)(ty + yPercent / 100 * temp.height);\n }\n\n temp = \"matrix(\" + a11 + \",\" + a21 + \",\" + a12 + \",\" + a22 + \",\" + tx + \",\" + ty + \")\";\n target.setAttribute(\"transform\", temp);\n forceCSS && (target.style[_transformProp] = temp); //some browsers prioritize CSS transforms over the transform attribute. When we sense that the user has CSS transforms applied, we must overwrite them this way (otherwise some browser simply won't render the transform attribute changes!)\n},\n _addRotationalPropTween = function _addRotationalPropTween(plugin, target, property, startNum, endValue) {\n var cap = 360,\n isString = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._isString)(endValue),\n endNum = parseFloat(endValue) * (isString && ~endValue.indexOf(\"rad\") ? _RAD2DEG : 1),\n change = endNum - startNum,\n finalValue = startNum + change + \"deg\",\n direction,\n pt;\n\n if (isString) {\n direction = endValue.split(\"_\")[1];\n\n if (direction === \"short\") {\n change %= cap;\n\n if (change !== change % (cap / 2)) {\n change += change < 0 ? cap : -cap;\n }\n }\n\n if (direction === \"cw\" && change < 0) {\n change = (change + cap * _bigNum) % cap - ~~(change / cap) * cap;\n } else if (direction === \"ccw\" && change > 0) {\n change = (change - cap * _bigNum) % cap - ~~(change / cap) * cap;\n }\n }\n\n plugin._pt = pt = new _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.PropTween(plugin._pt, target, property, startNum, change, _renderPropWithEnd);\n pt.e = finalValue;\n pt.u = \"deg\";\n\n plugin._props.push(property);\n\n return pt;\n},\n _assign = function _assign(target, source) {\n // Internet Explorer doesn't have Object.assign(), so we recreate it here.\n for (var p in source) {\n target[p] = source[p];\n }\n\n return target;\n},\n _addRawTransformPTs = function _addRawTransformPTs(plugin, transforms, target) {\n //for handling cases where someone passes in a whole transform string, like transform: \"scale(2, 3) rotate(20deg) translateY(30em)\"\n var startCache = _assign({}, target._gsap),\n exclude = \"perspective,force3D,transformOrigin,svgOrigin\",\n style = target.style,\n endCache,\n p,\n startValue,\n endValue,\n startNum,\n endNum,\n startUnit,\n endUnit;\n\n if (startCache.svg) {\n startValue = target.getAttribute(\"transform\");\n target.setAttribute(\"transform\", \"\");\n style[_transformProp] = transforms;\n endCache = _parseTransform(target, 1);\n\n _removeProperty(target, _transformProp);\n\n target.setAttribute(\"transform\", startValue);\n } else {\n startValue = getComputedStyle(target)[_transformProp];\n style[_transformProp] = transforms;\n endCache = _parseTransform(target, 1);\n style[_transformProp] = startValue;\n }
1108\n\n for (p in _transformProps) {\n startValue = startCache[p];\n endValue = endCache[p];\n\n if (startValue !== endValue && exclude.indexOf(p) < 0) {\n //tweening to no perspective gives very unintuitive results - just keep the same perspective in that case.\n startUnit = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.getUnit)(startValue);\n endUnit = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.getUnit)(endValue);\n startNum = startUnit !== endUnit ? _convertToUnit(target, p, startValue, endUnit) : parseFloat(startValue);\n endNum = parseFloat(endValue);\n plugin._pt = new _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.PropTween(plugin._pt, endCache, p, startNum, endNum - startNum, _renderCSSProp);\n plugin._pt.u = endUnit || 0;\n\n plugin._props.push(p);\n }\n }\n\n _assign(endCache, startCache);\n}; // handle splitting apart padding, margin, borderWidth, and borderRadius into their 4 components. Firefox, for example, won't report borderRadius correctly - it will only do borderTopLeftRadius and the other corners. We also want to handle paddingTop, marginLeft, borderRightWidth, etc.\n\n\n(0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._forEachName)(\"padding,margin,Width,Radius\", function (name, index) {\n var t = \"Top\",\n r = \"Right\",\n b = \"Bottom\",\n l = \"Left\",\n props = (index < 3 ? [t, r, b, l] : [t + l, t + r, b + r, b + l]).map(function (side) {\n return index < 2 ? name + side : \"border\" + side + name;\n });\n\n _specialProps[index > 1 ? \"border\" + name : name] = function (plugin, target, property, endValue, tween) {\n var a, vars;\n\n if (arguments.length < 4) {\n // getter, passed target, property, and unit (from _get())\n a = props.map(function (prop) {\n return _get(plugin, prop, property);\n });\n vars = a.join(\" \");\n return vars.split(a[0]).length === 5 ? a[0] : vars;\n }\n\n a = (endValue + \"\").split(\" \");\n vars = {};\n props.forEach(function (prop, i) {\n return vars[prop] = a[i] = a[i] || a[(i - 1) / 2 | 0];\n });\n plugin.init(target, vars, tween);\n };\n});\n\nvar CSSPlugin = {\n name: \"css\",\n register: _initCore,\n targetTest: function targetTest(target) {\n return target.style && target.nodeType;\n },\n init: function init(target, vars, tween, index, targets) {\n var props = this._props,\n style = target.style,\n startAt = tween.vars.startAt,\n startValue,\n endValue,\n endNum,\n startNum,\n type,\n specialProp,\n p,\n startUnit,\n endUnit,\n relative,\n isTransformRelated,\n transformPropTween,\n cache,\n smooth,\n hasPriority,\n inlineProps,\n finalTransformValue;\n _pluginInitted || _initCore(); // we may call init() multiple times on the same plugin instance, like when adding special properties, so make sure we don't overwrite the revert data or inlineProps\n\n this.styles = this.styles || _getStyleSaver(target);\n inlineProps = this.styles.props;\n this.tween = tween;\n\n for (p in vars) {\n if (p === \"autoRound\") {\n continue;\n }\n\n endValue = vars[p];\n\n if (_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._plugins[p] && (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._checkPlugin)(p, vars, tween, index, target, targets)) {\n // plugins\n continue;\n }\n\n type = typeof endValue;\n specialProp = _specialProps[p];\n\n if (type === \"function\") {\n endValue = endValue.call(tween, index, target, targets);\n type = typeof endValue;\n }\n\n if (type === \"string\" && ~endValue.indexOf(\"random(\")) {\n endValue = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._replaceRandom)(endValue);\n }\n\n if (specialProp) {\n specialProp(this, target, p, endValue, tween) && (hasPriority = 1);\n } else if (p.substr(0, 2) === \"--\") {\n //CSS variable\n startValue = (getComputedStyle(target).getPropertyValue(p) + \"\").trim();\n endValue += \"\";\n _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._colorExp.lastIndex = 0;\n\n if (!_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._colorExp.test(startValue)) {\n // colors don't have units\n startUnit = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.getUnit)(startValue);\n endUnit = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.getUnit)(endValue);\n endUnit ? startUnit !== endUnit && (startValue = _convertToUnit(target, p, startValue, endUnit) + endUnit) : startUnit && (endValue += startUnit);\n }\n\n this.add(style, \"setProperty\", startValue, endValue, index, targets, 0, 0, p);\n props.push(p);\n inlineProps.push(p, 0, style[p]);\n } else if (type !== \"undefined\") {\n if (startAt && p in startAt) {\n // in case someone hard-codes a complex value as the start, like top: \"calc(2vh / 2)\". Without this, it'd use the computed value (always in px)\n startValue = typeof startAt[p] === \"function\" ? startAt[p].call(tween, index, target, targets) : startAt[p];\n (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._isString)(startValue) && ~startValue.indexOf(\"random(\") && (startValue = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._replaceRandom)(startValue));\n (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.getUnit)(startValue + \"\") || startValue === \"auto\" || (startValue += _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._config.units[p] || (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.getUnit)(_get(target, p)) || \"\"); // for cases when someone passes in a unitless value like {x: 100}; if we try setting translate(100, 0px) it won't work.\n\n (startValue + \"\").charAt(1) === \"=\" && (startValue = _get(target, p)); // can't work with relative values\n } else {\n startValue = _get(target, p);\n }\n\n startNum = parseFloat(startValue);\n relative = type === \"string\" && endValue.charAt(1) === \"=\" && endValue.substr(0, 2);\n relative && (endValue = endValue.substr(2));\n endNum = parseFloat(endValue);\n\n if (p in _propertyAliases) {\n if (p === \"autoAlpha\") {\n //special case where we control the visibility along with opacity. We still allow the opacity value to pass through and get tweened.\n if (startNum === 1 && _get(target, \"visibility\") === \"hidden\" && endNum) {\n //if visibility is initially set to \"hidden\", we should interpret that as intent to make opacity 0 (a convenience)\n startNum = 0;\n }\n\n inlineProps.push(\"visibility\", 0, style.visibility);\n\n _addNonTweeningPT(this, style, \"visibility\", startNum ? \"inherit\" : \"hidden\", endNum ? \"inherit\" : \"hidden\", !endNum);\n }\n\n if (p !== \"scale\" && p !== \"transform\") {\n p = _propertyAliases[p];\n ~p.indexOf(\",\") && (p = p.split(\",\")[0]);\n }\n }
1108\n\n isTransformRelated = p in _transformProps; //--- TRANSFORM-RELATED ---\n\n if (isTransformRelated) {\n this.styles.save(p);\n finalTransformValue = endValue; // this is always the same as endValue except when it's a var(--) value, in which case we need to calculate the end value.\n\n if (type === \"string\" && endValue.substring(0, 6) === \"var(--\") {\n endValue = _getComputedProperty(target, endValue.substring(4, endValue.indexOf(\")\")));\n\n if (endValue.substring(0, 5) === \"calc(\") {\n var origPerspective = target.style.perspective;\n target.style.perspective = endValue;\n endValue = _getComputedProperty(target, \"perspective\");\n origPerspective ? target.style.perspective = origPerspective : _removeProperty(target, \"perspective\");\n }\n\n endNum = parseFloat(endValue);\n }\n\n if (!transformPropTween) {\n cache = target._gsap;\n cache.renderTransform && !vars.parseTransform || _parseTransform(target, vars.parseTransform); // if, for example, gsap.set(... {transform:\"translateX(50vw)\"}), the _get() call doesn't parse the transform, thus cache.renderTransform won't be set yet so force the parsing of the transform here.\n\n smooth = vars.smoothOrigin !== false && cache.smooth;\n transformPropTween = this._pt = new _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.PropTween(this._pt, style, _transformProp, 0, 1, cache.renderTransform, cache, 0, -1); //the first time through, create the rendering PropTween so that it runs LAST (in the linked list, we keep adding to the beginning)\n\n transformPropTween.dep = 1; //flag it as dependent so that if things get killed/overwritten and this is the only PropTween left, we can safely kill the whole tween.\n }\n\n if (p === \"scale\") {\n this._pt = new _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.PropTween(this._pt, cache, \"scaleY\", cache.scaleY, (relative ? (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._parseRelative)(cache.scaleY, relative + endNum) : endNum) - cache.scaleY || 0, _renderCSSProp);\n this._pt.u = 0;\n props.push(\"scaleY\", p);\n p += \"X\";\n } else if (p === \"transformOrigin\") {\n inlineProps.push(_transformOriginProp, 0, style[_transformOriginProp]);\n endValue = _convertKeywordsToPercentages(endValue); //in case something like \"left top\" or \"bottom right\" is passed in. Convert to percentages.\n\n if (cache.svg) {\n _applySVGOrigin(target, endValue, 0, smooth, 0, this);\n } else {\n endUnit = parseFloat(endValue.split(\" \")[2]) || 0; //handle the zOrigin separately!\n\n endUnit !== cache.zOrigin && _addNonTweeningPT(this, cache, \"zOrigin\", cache.zOrigin, endUnit);\n\n _addNonTweeningPT(this, style, p, _firstTwoOnly(startValue), _firstTwoOnly(endValue));\n }\n\n continue;\n } else if (p === \"svgOrigin\") {\n _applySVGOrigin(target, endValue, 1, smooth, 0, this);\n\n continue;\n } else if (p in _rotationalProperties) {\n _addRotationalPropTween(this, cache, p, startNum, relative ? (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._parseRelative)(startNum, relative + endValue) : endValue);\n\n continue;\n } else if (p === \"smoothOrigin\") {\n _addNonTweeningPT(this, cache, \"smooth\", cache.smooth, endValue);\n\n continue;\n } else if (p === \"force3D\") {\n cache[p] = endValue;\n continue;\n } else if (p === \"transform\") {\n _addRawTransformPTs(this, endValue, target);\n\n continue;\n }\n } else if (!(p in style)) {\n p = _checkPropPrefix(p) || p;\n }\n\n if (isTransformRelated || (endNum || endNum === 0) && (startNum || startNum === 0) && !_complexExp.test(endValue) && p in style) {\n startUnit = (startValue + \"\").substr((startNum + \"\").length);\n endNum || (endNum = 0); // protect against NaN\n\n endUnit = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.getUnit)(endValue) || (p in _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._config.units ? _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._config.units[p] : startUnit);\n startUnit !== endUnit && (startNum = _convertToUnit(target, p, startValue, endUnit));\n this._pt = new _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.PropTween(this._pt, isTransformRelated ? cache : style, p, startNum, (relative ? (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._parseRelative)(startNum, relative + endNum) : endNum) - startNum,
1108!isTransformRelated && (endUnit === \"px\" || p === \"zIndex\") && vars.autoRound !== false ? _renderRoundedCSSProp : _renderCSSProp);\n this._pt.u = endUnit || 0;\n\n if (isTransformRelated && finalTransformValue !== endValue) {\n this._pt.b = startValue;\n this._pt.e = finalTransformValue;\n this._pt.r = _renderCSSPropWithBeginningAndEnd;\n } else if (startUnit !== endUnit && endUnit !== \"%\") {\n //when the tween goes all the way back to the beginning, we need to revert it to the OLD/ORIGINAL value (with those units). We record that as a \"b\" (beginning) property and point to a render method that handles that. (performance optimization)\n this._pt.b = startValue;\n this._pt.r = _renderCSSPropWithBeginning;\n }\n } else if (!(p in style)) {\n if (p in target) {\n //maybe it's not a style - it could be a property added directly to an element in which case we'll try to animate that.\n this.add(target, p, startValue || target[p], relative ? relative + endValue : endValue, index, targets);\n } else if (p !== \"parseTransform\") {\n (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._missingPlugin)(p, endValue);\n\n continue;\n }\n } else {\n _tweenComplexCSSString.call(this, target, p, startValue, relative ? relative + endValue : endValue);\n }\n\n isTransformRelated || (p in style ? inlineProps.push(p, 0, style[p]) : typeof target[p] === \"function\" ? inlineProps.push(p, 2, target[p]()) : inlineProps.push(p, 1, startValue || target[p]));\n props.push(p);\n }\n }\n\n hasPriority && (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._sortPropTweensByPriority)(this);\n },\n render: function render(ratio, data) {\n if (data.tween._time || !_reverting()) {\n var pt = data._pt;\n\n while (pt) {\n pt.r(ratio, pt.d);\n pt = pt._next;\n }\n } else {\n data.styles.revert();\n }\n },\n get: _get,\n aliases: _propertyAliases,\n getSetter: function getSetter(target, property, plugin) {\n //returns a setter function that accepts target, property, value and applies it accordingly. Remember, properties like \"x\" aren't as simple as target.style.property = value because they've got to be applied to a proxy object and then merged into a transform string in a renderer.\n var p = _propertyAliases[property];\n p && p.indexOf(\",\") < 0 && (property = p);\n return property in _transformProps && property !== _transformOriginProp && (target._gsap.x || _get(target, \"x\")) ? plugin && _recentSetterPlugin === plugin ? property === \"scale\" ? _setterScale : _setterTransform : (_recentSetterPlugin = plugin || {}) && (property === \"scale\" ? _setterScaleWithRender : _setterTransformWithRender) : target.style && !(0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._isUndefined)(target.style[property]) ? _setterCSSStyle : ~property.indexOf(\"-\") ? _setterCSSProp : (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._getSetter)(target, property);\n },\n core: {\n _removeProperty: _removeProperty,\n _getMatrix: _getMatrix\n }\n};\n_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.gsap.utils.checkPrefix = _checkPropPrefix;\n_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.gsap.core.getStyleSaver = _getStyleSaver;\n\n(function (positionAndScale, rotation, others, aliases) {\n var all = (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._forEachName)(positionAndScale + \",\" + rotation + \",\" + others, function (name) {\n _transformProps[name] = 1;\n });\n\n (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._forEachName)(rotation, function (name) {\n _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._config.units[name] = \"deg\";\n _rotationalProperties[name] = 1;\n });\n\n _propertyAliases[all[13]] = positionAndScale + \",\" + rotation;\n\n (0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._forEachName)(aliases, function (name) {\n var split = name.split(\":\");\n _propertyAliases[split[1]] = all[split[0]];\n });\n})(\"x,y,z,scale,scaleX,scaleY,xPercent,yPercent\", \"rotation,rotationX,rotationY,skewX,skewY\", \"transform,transformOrigin,svgOrigin,force3D,smoothOrigin,transformPerspective\", \"0:translateX,1:translateY,2:translateZ,8:rotate,8:rotationZ,8:rotateZ,9:rotateX,10:rotateY\");\n\n(0,_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._forEachName)(\"x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective\", function (name) {\n _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__._config.units[name] = \"px\";\n});\n\n_gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(CSSPlugin);\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/gsap/CSSPlugin.js?\n}"); 1109 1110/***/ }, 1111 1112/***/ "./node_modules/gsap/Observer.js" 1113/*!***************************************!*\ 1114 !*** ./node_modules/gsap/Observer.js ***! 1115 \***************************************/ 1116(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1117 1118"use strict"; 1119eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Ob
1119server: () => (/* binding */ Observer),\n/* harmony export */ _getProxyProp: () => (/* binding */ _getProxyProp),\n/* harmony export */ _getScrollFunc: () => (/* binding */ _getScrollFunc),\n/* harmony export */ _getTarget: () => (/* binding */ _getTarget),\n/* harmony export */ _getVelocityProp: () => (/* binding */ _getVelocityProp),\n/* harmony export */ _horizontal: () => (/* binding */ _horizontal),\n/* harmony export */ _isViewport: () => (/* binding */ _isViewport),\n/* harmony export */ _proxies: () => (/* binding */ _proxies),\n/* harmony export */ _scrollers: () => (/* binding */ _scrollers),\n/* harmony export */ _vertical: () => (/* binding */ _vertical),\n/* harmony export */ \"default\": () => (/* binding */ Observer)\n/* harmony export */ });\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n/*!\n * Observer 3.15.0\n * https://gsap.com\n *\n * @license Copyright 2008-2026, GreenSock. All rights reserved.\n * Subject to the terms at https://gsap.com/standard-license\n * @author: Jack Doyle, [email protected]\n*/\n\n/* eslint-disable */\nvar gsap,\n _coreInitted,\n _clamp,\n _win,\n _doc,\n _docEl,\n _body,\n _isTouch,\n _pointerType,\n ScrollTrigger,\n _root,\n _normalizer,\n _eventTypes,\n _context,\n _getGSAP = function _getGSAP() {\n return gsap || typeof window !== \"undefined\" && (gsap = window.gsap) && gsap.registerPlugin && gsap;\n},\n _startup = 1,\n _observers = [],\n _scrollers = [],\n _proxies = [],\n _getTime = Date.now,\n _bridge = function _bridge(name, value) {\n return value;\n},\n _integrate = function _integrate() {\n var core = ScrollTrigger.core,\n data = core.bridge || {},\n scrollers = core._scrollers,\n proxies = core._proxies;\n scrollers.push.apply(scrollers, _scrollers);\n proxies.push.apply(proxies, _proxies);\n _scrollers = scrollers;\n _proxies = proxies;\n\n _bridge = function _bridge(name, value) {\n return data[name](value);\n };\n},\n _getProxyProp = function _getProxyProp(element, property) {\n return ~_proxies.indexOf(element) && _proxies[_proxies.indexOf(element) + 1][property];\n},\n _isViewport = function _isViewport(el) {\n return !!~_root.indexOf(el);\n},\n _addListener = function _addListener(element, type, func, passive, capture) {\n return element.addEventListener(type, func, {\n passive: passive !== false,\n capture: !!capture\n });\n},\n _removeListener = function _removeListener(element, type, func, capture) {\n return element.removeEventListener(type, func, !!capture);\n},\n _scrollLeft = \"scrollLeft\",\n _scrollTop = \"scrollTop\",\n _onScroll = function _onScroll() {\n return _normalizer && _normalizer.isPressed || _scrollers.cache++;\n},\n _scrollCacheFunc = function _scrollCacheFunc(f, doNotCache) {\n var cachingFunc = function cachingFunc(value) {\n // since reading the scrollTop/scrollLeft/pageOffsetY/pageOffsetX can trigger a layout, this function allows us to cache the value so it only gets read fresh after a \"scroll\" event fires (or while we're refreshing because that can lengthen the page and alter the scroll position). when \"soft\" is true, that means don't actually set the scroll, but cache the new value instead (useful in ScrollSmoother)\n if (value || value === 0) {\n _startup && (_win.history.scrollRestoration = \"manual\"); // otherwise the new position will get overwritten by the browser onload.\n\n var isNormalizing = _normalizer && _normalizer.isPressed;\n value = cachingFunc.v = Math.round(value) || (_normalizer && _normalizer.iOS ? 1 : 0); //TODO: iOS Bug: if you allow it to go to 0, Safari can start to report super strange (wildly inaccurate) touch positions!\n\n f(value);\n cachingFunc.cacheID = _scrollers.cache;\n isNormalizing && _bridge(\"ss\", value);
1119 // set scroll (notify ScrollTrigger so it can dispatch a \"scrollStart\" event if necessary\n } else if (doNotCache || _scrollers.cache !== cachingFunc.cacheID || _bridge(\"ref\")) {\n cachingFunc.cacheID = _scrollers.cache;\n cachingFunc.v = f();\n }\n\n return cachingFunc.v + cachingFunc.offset;\n };\n\n cachingFunc.offset = 0;\n return f && cachingFunc;\n},\n _horizontal = {\n s: _scrollLeft,\n p: \"left\",\n p2: \"Left\",\n os: \"right\",\n os2: \"Right\",\n d: \"width\",\n d2: \"Width\",\n a: \"x\",\n sc: _scrollCacheFunc(function (value) {\n return arguments.length ? _win.scrollTo(value, _vertical.sc()) : _win.pageXOffset || _doc[_scrollLeft] || _docEl[_scrollLeft] || _body[_scrollLeft] || 0;\n })\n},\n _vertical = {\n s: _scrollTop,\n p: \"top\",\n p2: \"Top\",\n os: \"bottom\",\n os2: \"Bottom\",\n d: \"height\",\n d2: \"Height\",\n a: \"y\",\n op: _horizontal,\n sc: _scrollCacheFunc(function (value) {\n return arguments.length ? _win.scrollTo(_horizontal.sc(), value) : _win.pageYOffset || _doc[_scrollTop] || _docEl[_scrollTop] || _body[_scrollTop] || 0;\n })\n},\n _getTarget = function _getTarget(t, self) {\n return (self && self._ctx && self._ctx.selector || gsap.utils.toArray)(t)[0] || (typeof t === \"string\" && gsap.config().nullTargetWarn !== false ? console.warn(\"Element not found:\", t) : null);\n},\n _isWithin = function _isWithin(element, list) {\n // check if the element is in the list or is a descendant of an element in the list.\n var i = list.length;\n\n while (i--) {\n if (list[i] === element || list[i].contains(element)) {\n return true;\n }\n }\n\n return false;\n},\n _getScrollFunc = function _getScrollFunc(element, _ref) {\n var s = _ref.s,\n sc = _ref.sc;\n // we store the scroller functions in an alternating sequenced Array like [element, verticalScrollFunc, horizontalScrollFunc, ...] so that we can minimize memory, maximize performance, and we also record the last position as a \".rec\" property in order to revert to that after refreshing to ensure things don't shift around.\n _isViewport(element) && (element = _doc.scrollingElement || _docEl);\n\n var i = _scrollers.indexOf(element),\n offset = sc === _vertical.sc ? 1 : 2;\n\n !~i && (i = _scrollers.push(element) - 1);\n _scrollers[i + offset] || _addListener(element, \"scroll\", _onScroll); // clear the cache when a scroll occurs\n\n var prev = _scrollers[i + offset],\n func = prev || (_scrollers[i + offset] = _scrollCacheFunc(_getProxyProp(element, s), true) || (_isViewport(element) ? sc : _scrollCacheFunc(function (value) {\n return arguments.length ? element[s] = value : element[s];\n })));\n func.target = element;\n prev || (func.smooth = gsap.getProperty(element, \"scrollBehavior\") === \"smooth\"); // only set it the first time (don't reset every time a scrollFunc is requested because perhaps it happens during a refresh() when it's disabled in ScrollTrigger.\n\n return func;\n},\n _getVelocityProp = function _getVelocityProp(value, minTimeRefresh, useDelta) {\n var v1 = value,\n v2 = value,\n t1 = _getTime(),\n t2 = t1,\n min = minTimeRefresh || 50,\n dropToZeroTime = Math.max(500, min * 3),\n update = function update(value, force) {\n var t = _getTime();\n\n if (force || t - t1 > min) {\n v2 = v1;\n v1 = value;\n t2 = t1;\n t1 = t;\n } else if (useDelta) {\n v1 += value;\n } else {\n // not totally necessary, but makes it a bit more accurate by adjusting the v1 value according to the new slope. This way we're not just ignoring the incoming data. Removing for now because it doesn't seem to make much practical difference and it's probably not worth the kb.\n v1 = v2 + (value - v2) / (t - t2) * (t1 - t2);\n }\n },\n reset = function reset() {\n v2 = v1 = useDelta ? 0 : v1;\n t2 = t1 = 0;\n },\n getVelocity = function getVelocity(latestValue) {\n var tOld = t2,\n vOld = v2,\n t = _getTime();\n\n (latestValue || latestValue === 0) && latestValue !== v1 && update(latestValue);\n return t1 === t2 || t - t2 > dropToZeroTime ? 0 : (v1 + (useDelta ? vOld : -vOld)) / ((useDelta ? t : t1) - tOld) * 1000;\n };\n\n return {\n update: update,\n reset: reset,\n getVelocity: getVelocity\n };\n},\n _getEvent = function _getEvent(e, preventDefault) {\n preventDefault && !e._gsapAllow && e.cancelable !== false && e.preventDefault();\n return e.changedTouches ? e.changedTouches[0] : e;
1119\n},\n _getAbsoluteMax = function _getAbsoluteMax(a) {\n var max = Math.max.apply(Math, a),\n min = Math.min.apply(Math, a);\n return Math.abs(max) >= Math.abs(min) ? max : min;\n},\n _setScrollTrigger = function _setScrollTrigger() {\n ScrollTrigger = gsap.core.globals().ScrollTrigger;\n ScrollTrigger && ScrollTrigger.core && _integrate();\n},\n _initCore = function _initCore(core) {\n gsap = core || _getGSAP();\n\n if (!_coreInitted && gsap && typeof document !== \"undefined\" && document.body) {\n _win = window;\n _doc = document;\n _docEl = _doc.documentElement;\n _body = _doc.body;\n _root = [_win, _doc, _docEl, _body];\n _clamp = gsap.utils.clamp;\n\n _context = gsap.core.context || function () {};\n\n _pointerType = \"onpointerenter\" in _body ? \"pointer\" : \"mouse\"; // isTouch is 0 if no touch, 1 if ONLY touch, and 2 if it can accommodate touch but also other types like mouse/pointer.\n\n _isTouch = Observer.isTouch = _win.matchMedia && _win.matchMedia(\"(hover: none), (pointer: coarse)\").matches ? 1 : \"ontouchstart\" in _win || navigator.maxTouchPoints > 0 || navigator.msMaxTouchPoints > 0 ? 2 : 0;\n _eventTypes = Observer.eventTypes = (\"ontouchstart\" in _docEl ? \"touchstart,touchmove,touchcancel,touchend\" : !(\"onpointerdown\" in _docEl) ? \"mousedown,mousemove,mouseup,mouseup\" : \"pointerdown,pointermove,pointercancel,pointerup\").split(\",\");\n setTimeout(function () {\n return _startup = 0;\n }, 500);\n _coreInitted = 1;\n }\n\n ScrollTrigger || _setScrollTrigger(); // Observer might be initted BEFORE ScrollTrigger, so don't put this with the initting code. ScrollTrigger will call Observer.register() when it inits.\n\n return _coreInitted;\n};\n\n_horizontal.op = _vertical;\n_scrollers.cache = 0;\nvar Observer = /*#__PURE__*/function () {\n function Observer(vars) {\n this.init(vars);\n }\n\n var _proto = Observer.prototype;\n\n _proto.init = function init(vars) {\n _coreInitted || _initCore(gsap) || console.warn(\"Please gsap.registerPlugin(Observer)\");\n ScrollTrigger || _setScrollTrigger();\n var tolerance = vars.tolerance,\n dragMinimum = vars.dragMinimum,\n type = vars.type,\n target = vars.target,\n lineHeight = vars.lineHeight,\n debounce = vars.debounce,\n preventDefault = vars.preventDefault,\n onStop = vars.onStop,\n onStopDelay = vars.onStopDelay,\n ignore = vars.ignore,\n wheelSpeed = vars.wheelSpeed,\n event = vars.event,\n onDragStart = vars.onDragStart,\n onDragEnd = vars.onDragEnd,\n onDrag = vars.onDrag,\n onPress = vars.onPress,\n onRelease = vars.onRelease,\n onRight = vars.onRight,\n onLeft = vars.onLeft,\n onUp = vars.onUp,\n onDown = vars.onDown,\n onChangeX = vars.onChangeX,\n onChangeY = vars.onChangeY,\n onChange = vars.onChange,\n onToggleX = vars.onToggleX,\n onToggleY = vars.onToggleY,\n onHover = vars.onHover,\n onHoverEnd = vars.onHoverEnd,\n onMove = vars.onMove,\n ignoreCheck = vars.ignoreCheck,\n isNormalizer = vars.isNormalizer,\n onGestureStart = vars.onGestureStart,\n onGestureEnd = vars.onGestureEnd,\n onWheel = vars.onWheel,\n onEnable = vars.onEnable,\n onDisable = vars.onDisable,\n onClick = vars.onClick,\n scrollSpeed = vars.scrollSpeed,\n capture = vars.capture,\n allowClicks = vars.allowClicks,\n lockAxis = vars.lockAxis,\n onLockAxis = vars.onLockAxis;\n this.target = target = _getTarget(target) || _docEl;\n this.vars = vars;\n ignore && (ignore = gsap.utils.toArray(ignore));\n tolerance = tolerance || 1e-9;\n dragMinimum = dragMinimum || 0;\n wheelSpeed = wheelSpeed || 1;\n scrollSpeed = scrollSpeed || 1;\n type = type || \"wheel,touch,pointer\";\n debounce = debounce !== false;\n lineHeight || (lineHeight = parseFloat(_win.getComputedStyle(_body).lineHeight) || 22); // note: browser may report \"normal\", so default to 22.\n\n var id,\n onStopDelayedCall,\n dragged,\n moved,\n wheeled,\n locked,\n axis,\n self = this,\n prevDeltaX = 0,\n prevDeltaY = 0,\n passive = vars.passive || !preventDefault && vars.passive !== false,\n scrollFuncX = _getScrollFunc(target, _horizontal),\n scrollFuncY = _getScrollFunc(target, _vertical),\n scrollX = scrollFuncX(),\n scrollY = scrollFuncY(),\n limitToTouch = ~type.indexOf(\"touch\") && !~type.indexOf(\"pointer\") && _eventTypes[0] === \"pointerdown\",\n // for devices that accommodate mouse events and touch events, we need to distinguish.\n isViewport = _isViewport(target),\n ownerDoc = target.ownerDocument || _doc,\n deltaX = [0, 0, 0],\n // wheel, scroll, pointer/touch\n deltaY = [0, 0, 0],\n onClickTime = 0,\n clickCapture = function clickCapture() {\n return onClickTime = _getTime();\n },\n _ignoreCheck = function _ignoreCheck(e, isPointerOrTouch) {\n return (self.event = e) && ignore && _isWithin(e.target, ignore) || isPointerOrTouch && limitToTouch && e.pointerType !== \"touch\" || ignoreCheck && ignoreCheck(e, isPointerOrTouch);\n },\n onStopFunc = function onStopFunc() {\n self._vx.reset();\n\n self._vy.reset();\n\n onStopDelayedCall.pause();\n onStop && onStop(self);\n }
1119,\n update = function update() {\n var dx = self.deltaX = _getAbsoluteMax(deltaX),\n dy = self.deltaY = _getAbsoluteMax(deltaY),\n changedX = Math.abs(dx) >= tolerance,\n changedY = Math.abs(dy) >= tolerance;\n\n onChange && (changedX || changedY) && onChange(self, dx, dy, deltaX, deltaY); // in ScrollTrigger.normalizeScroll(), we need to know if it was touch/pointer so we need access to the deltaX/deltaY Arrays before we clear them out.\n\n if (changedX) {\n onRight && self.deltaX > 0 && onRight(self);\n onLeft && self.deltaX < 0 && onLeft(self);\n onChangeX && onChangeX(self);\n onToggleX && self.deltaX < 0 !== prevDeltaX < 0 && onToggleX(self);\n prevDeltaX = self.deltaX;\n deltaX[0] = deltaX[1] = deltaX[2] = 0;\n }\n\n if (changedY) {\n onDown && self.deltaY > 0 && onDown(self);\n onUp && self.deltaY < 0 && onUp(self);\n onChangeY && onChangeY(self);\n onToggleY && self.deltaY < 0 !== prevDeltaY < 0 && onToggleY(self);\n prevDeltaY = self.deltaY;\n deltaY[0] = deltaY[1] = deltaY[2] = 0;\n }\n\n if (moved || dragged) {\n onMove && onMove(self);\n\n if (dragged) {\n onDragStart && dragged === 1 && onDragStart(self);\n onDrag && onDrag(self);\n dragged = 0;\n }\n\n moved = false;\n }\n\n locked && !(locked = false) && onLockAxis && onLockAxis(self);\n\n if (wheeled) {\n onWheel(self);\n wheeled = false;\n }\n\n id = 0;\n },\n onDelta = function onDelta(x, y, index) {\n deltaX[index] += x;\n deltaY[index] += y;\n\n self._vx.update(x);\n\n self._vy.update(y);\n\n debounce ? id || (id = requestAnimationFrame(update)) : update();\n },\n onTouchOrPointerDelta = function onTouchOrPointerDelta(x, y) {\n if (lockAxis && !axis) {\n self.axis = axis = Math.abs(x) > Math.abs(y) ? \"x\" : \"y\";\n locked = true;\n }\n\n if (axis !== \"y\") {\n deltaX[2] += x;\n\n self._vx.update(x, true); // update the velocity as frequently as possible instead of in the debounced function so that very quick touch-scrolls (flicks) feel natural. If it's the mouse/touch/pointer, force it so that we get snappy/accurate momentum scroll.\n\n }\n\n if (axis !== \"x\") {\n deltaY[2] += y;\n\n self._vy.update(y, true);\n }\n\n debounce ? id || (id = requestAnimationFrame(update)) : update();\n },\n _onDrag = function _onDrag(e) {\n if (_ignoreCheck(e, 1)) {\n return;\n }\n\n e = _getEvent(e, preventDefault);\n var x = e.clientX,\n y = e.clientY,\n dx = x - self.x,\n dy = y - self.y,\n isDragging = self.isDragging;\n self.x = x;\n self.y = y;\n\n if (isDragging || (dx || dy) && (Math.abs(self.startX - x) >= dragMinimum || Math.abs(self.startY - y) >= dragMinimum)) {\n dragged || (dragged = isDragging ? 2 : 1); // dragged: 0 = not dragging, 1 = first drag, 2 = normal drag\n\n isDragging || (self.isDragging = true);\n onTouchOrPointerDelta(dx, dy);\n }\n },\n _onPress = self.onPress = function (e) {\n if (_ignoreCheck(e, 1) || e && e.button) {\n return;\n }\n\n self.axis = axis = null;\n onStopDelayedCall.pause();\n self.isPressed = true;\n e = _getEvent(e); // note: may need to preventDefault(?) Won't side-scroll on iOS Safari if we do, though.\n\n prevDeltaX = prevDeltaY = 0;\n self.startX = self.x = e.clientX;\n self.startY = self.y = e.clientY;\n\n self._vx.reset(); // otherwise the t2 may be stale if the user touches and flicks super fast and releases in less than 2 requestAnimationFrame ticks, causing velocity to be 0.\n\n\n self._vy.reset();\n\n _addListener(isNormalizer ? target : ownerDoc, _eventTypes[1], _onDrag, passive, true);\n\n self.deltaX = self.deltaY = 0;\n onPress && onPress(self);\n },\n _onRelease = self.onRelease = function (e) {\n if (_ignoreCheck(e, 1)) {\n return;\n }\n\n _removeListener(isNormalizer ? target : ownerDoc, _eventTypes[1], _onDrag, true);\n\n var isTrackingDrag = !isNaN(self.y - self.startY),\n wasDragging = self.isDragging,\n isDragNotClick = wasDragging && (Math.abs(self.x - self.startX) > 3 || Math.abs(self.y - self.startY) > 3),\n // some touch devices need some wiggle room in terms of sensing clicks - the finger may move a few pixels.\n eventData = _getEvent(e);\n\n if (!isDragNotClick && isTrackingDrag) {\n self._vx.reset();\n\n self._vy.reset(); //if (preventDefault && allowClicks && self.isPressed) { // check isPressed because in a rare edge case, the inputObserver in ScrollTrigger may stopPropagation() on the press/drag, so the onRelease may get fired without the onPress/onDrag ever getting called, thus it could trigger a click to occur on a link after scroll-dragging it.\n\n\n if (preventDefault && allowClicks) {\n gsap.delayedCall(0.08, function () {\n // some browsers (like Firefox) won't trust script-generated clicks, so if the user tries to click on a video to play it, for example, it simply won't work. Since a regular \"click\" event will most likely be generated anyway (one that has its isTrusted flag set to true), we must slightly delay our script-generated click so that the \"real\"/trusted one is prioritized. Remember, when there are duplicate events in quick succession, we suppress all but the first one. Some browsers don't even trigger the \"real\" one at all, so our synthetic one is a safety valve that ensures that no matter what, a click event does get dispatched.\n if (_getTime() - onClickTime > 300 && !e.defaultPrevented) {\n if (e.target.click) {\
1119n //some browsers (like mobile Safari) don't properly trigger the click event\n e.target.click();\n } else if (ownerDoc.createEvent) {\n var syntheticEvent = ownerDoc.createEvent(\"MouseEvents\");\n syntheticEvent.initMouseEvent(\"click\", true, true, _win, 1, eventData.screenX, eventData.screenY, eventData.clientX, eventData.clientY, false, false, false, false, 0, null);\n e.target.dispatchEvent(syntheticEvent);\n }\n }\n });\n }\n }\n\n self.isDragging = self.isGesturing = self.isPressed = false;\n onStop && wasDragging && !isNormalizer && onStopDelayedCall.restart(true);\n dragged && update(); // in case debouncing, we don't want onDrag to fire AFTER onDragEnd().\n\n onDragEnd && wasDragging && onDragEnd(self);\n onRelease && onRelease(self, isDragNotClick);\n },\n _onGestureStart = function _onGestureStart(e) {\n return e.touches && e.touches.length > 1 && (self.isGesturing = true) && onGestureStart(e, self.isDragging);\n },\n _onGestureEnd = function _onGestureEnd() {\n return (self.isGesturing = false) || onGestureEnd(self);\n },\n onScroll = function onScroll(e) {\n if (_ignoreCheck(e)) {\n return;\n }\n\n var x = scrollFuncX(),\n y = scrollFuncY();\n onDelta((x - scrollX) * scrollSpeed, (y - scrollY) * scrollSpeed, 1);\n scrollX = x;\n scrollY = y;\n onStop && onStopDelayedCall.restart(true);\n },\n _onWheel = function _onWheel(e) {\n if (_ignoreCheck(e)) {\n return;\n }\n\n e = _getEvent(e, preventDefault);\n onWheel && (wheeled = true);\n var multiplier = (e.deltaMode === 1 ? lineHeight : e.deltaMode === 2 ? _win.innerHeight : 1) * wheelSpeed;\n onDelta(e.deltaX * multiplier, e.deltaY * multiplier, 0);\n onStop && !isNormalizer && onStopDelayedCall.restart(true);\n },\n _onMove = function _onMove(e) {\n if (_ignoreCheck(e)) {\n return;\n }\n\n var x = e.clientX,\n y = e.clientY,\n dx = x - self.x,\n dy = y - self.y;\n self.x = x;\n self.y = y;\n moved = true;\n onStop && onStopDelayedCall.restart(true);\n (dx || dy) && onTouchOrPointerDelta(dx, dy);\n },\n _onHover = function _onHover(e) {\n self.event = e;\n onHover(self);\n },\n _onHoverEnd = function _onHoverEnd(e) {\n self.event = e;\n onHoverEnd(self);\n },\n _onClick = function _onClick(e) {\n return _ignoreCheck(e) || _getEvent(e, preventDefault) && onClick(self);\n };\n\n onStopDelayedCall = self._dc = gsap.delayedCall(onStopDelay || 0.25, onStopFunc).pause();\n self.deltaX = self.deltaY = 0;\n self._vx = _getVelocityProp(0, 50, true);\n self._vy = _getVelocityProp(0, 50, true);\n self.scrollX = scrollFuncX;\n self.scrollY = scrollFuncY;\n self.isDragging = self.isGesturing = self.isPressed = false;\n\n _context(this);\n\n self.enable = function (e) {\n if (!self.isEnabled) {\n _addListener(isViewport ? ownerDoc : target, \"scroll\", _onScroll);\n\n type.indexOf(\"scroll\") >= 0 && _addListener(isViewport ? ownerDoc : target, \"scroll\", onScroll, passive, capture);\n type.indexOf(\"wheel\") >= 0 && _addListener(target, \"wheel\", _onWheel, passive, capture);\n\n if (type.indexOf(\"touch\") >= 0 && _isTouch || type.indexOf(\"pointer\") >= 0) {\n _addListener(target, _eventTypes[0], _onPress, passive, capture);\n\n _addListener(ownerDoc, _eventTypes[2], _onRelease);\n\n _addListener(ownerDoc, _eventTypes[3], _onRelease);\n\n allowClicks && _addListener(target, \"click\", clickCapture, true, true);\n onClick && _addListener(target, \"click\", _onClick);\n onGestureStart && _addListener(ownerDoc, \"gesturestart\", _onGestureStart);\n onGestureEnd && _addListener(ownerDoc, \"gestureend\", _onGestureEnd);\n onHover && _addListener(target, _pointerType + \"enter\", _onHover);\n onHoverEnd && _addListener(target, _pointerType + \"leave\", _onHoverEnd);\n onMove && _addListener(target, _pointerType + \"move\", _onMove);\n }\n\n self.isEnabled = true;\n self.isDragging = self.isGesturing = self.isPressed = moved = dragged = false;\n\n self._vx.reset();\n\n self._vy.reset();\n\n scrollX = scrollFuncX();\n scrollY = scrollFuncY();\n e && e.type && _onPress(e);\n onEnable && onEnable(self);\n }\n\n return self;\n };\n\n self.disable = function () {\n if (self.isEnabled) {\n // only remove the _onScroll listener if there aren't any others that rely on the functionality.\n _observers.filter(function (o) {\n return o !== self && _isViewport(o.target);\n }).length || _removeListener(isViewport ? ownerDoc : target, \"scroll\", _onScroll);\n\n if (self.isPressed) {\n self._vx.reset();\n\n self._vy.reset();\n\n _removeListener(isNormalizer ? target : ownerDoc, _eventTypes[1], _onDrag, true);\n }\n\n _removeListener(isViewport ? ownerDoc : target, \"scroll\", onScroll, capture);\n\n _removeListener(target, \"wheel\", _onWheel, capture);\n\n _removeListener(target, _eventTypes[0], _onPress, capture);\n\n _removeListener(ownerDoc, _eventTypes[2], _onRelease);\n\n _removeListener(ownerDoc, _eventTypes[3], _onRelease);\n\n _removeListener(target, \"click\", clickCapture, true);\n\n _removeListener(target, \"click\", _onClick);\n\n _removeListener(ownerDoc, \"gesturestart\", _onGestureStart);\n\n _removeListener(ownerDoc, \"gestureend\", _onGestureEnd);\n\n _removeListener(target, _pointerType + \"enter\", _onHover);\n\n _removeListener(target, _pointerType + \"leave\", _onHoverEnd);\n\n _removeListener(target, _pointerType + \"move\", _onMove);\n\n self.isEnabled = self.isPressed = self.isDragging = false;\n onDisable && onDisable(self);\n }\n };\n\n self.kill = self.revert = function () {\n self.disable();\n\n var i = _observers.indexOf(self);\n\n i >= 0 && _observers.splice(i, 1);\n _normalizer === self && (_normalizer = 0);\n };\n\n _observers.push(self);\n\n isNormalizer && _isViewport(target) && (_normalizer = self);\n self.enable(event);\n };\n\n _createClass(Observer, [{\n key: \"velocityX\",\n get: function get() {\n return this._vx.getVelocity();\n }\n }, {\n key: \"velocityY\",\n get: function get() {\n return this._vy.getVelocity();\n }\n }]);\n\n return Observer;\n}();\nObserver.version = \"3.15.0\";\n\nObserver.create = function (vars) {\n return new Observer(vars);\n};\n\nObserver.register = _initCore;\n\nObserver.getAll = function () {\n return _observers.slice();\n};\n\nObserver.getById = function (id) {\n return _observers.filter(function (o) {\n return o.vars.id === id;\n })[0];\n};\n\n_getGSAP() && gsap.registerPlugin(Observer);\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/gsap/Observer.js?\n}"); 1120 1121/***/ }, 1122 1123/***/ "./node_modules/gsap/ScrollTrigger.js" 1124/*!********************************************!*\ 1125 !*** ./node_modules/gsap/ScrollTrigger.js ***! 1126 \********************************************/ 1127(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1128 1129"use strict"; 1130eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ ScrollTrigger: () => (/* binding */ ScrollTrigger),\n/* harmony export */ \"default\": () => (/* binding */ ScrollTrigger)\n/* harmony export */ });\n/* harmony import */ var _Observer_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Observer.js */ \"./node_modules/gsap/Observer.js\");\n/*!\n * ScrollTrigger 3.15.0\n * https://gsap.com\n *\n * @license Copyright 2008-2026, GreenSock. All rights reserved.\n * Subject to the terms at https://gsap.com/standard-license\n * @author: Jack Doyle, [email protected]\n*/\n\n/* eslint-disable */\n\n\nvar gsap,\n _coreInitted,\n _win,\n _doc,\n _docEl,\n _body,\n _root,\n _resizeDelay,\n _toArray,\n _clamp,\n _time2,\n _syncInterval,\n _refreshing,\n _pointerIsDown,\n _transformProp,\n _i,\n _prevWidth,\n _prevHeight,\n _autoRefresh,\n _sort,\n _suppressOverwrites,\n _ignoreResize,\n _normalizer,\n _ignoreMobileResize,\n _baseScreenHeight,\n _baseScreenWidth,\n _fixIOSBug,\n _context,\n _scrollRestoration,\n _div100vh,\n _100vh,\n _isReverted,\n _clampingMax,\n _limitCallbacks,\n // if true, we'll only trigger callbacks if the active state toggles, so if you scroll immediately past both the start and end positions of a ScrollTrigger (thus inactive to inactive), neither its onEnter nor onLeave will be called. This is useful during startup.\n_startup = 1,\n _getTime = Date.now,\n _time1 = _getTime(),\n _lastScrollTime = 0,\n _enabled = 0,\n _parseClamp = function _parseClamp(value, type, self) {\n var clamp = _isString(value) && (value.substr(0, 6) === \"clamp(\" || value.indexOf(\"max\") > -1);\n self[\"_\" + type + \"Clamp\"] = clamp;\n return clamp ? value.substr(6, value.length - 7) : value;\n},\n _keepClamp = function _keepClamp(value, clamp) {\n return clamp && (!_isString(value) || value.substr(0, 6) !== \"clamp(\") ? \"clamp(\" + value + \")\" : value;\n},\n _rafBugFix = function _rafBugFix() {\n return _enabled && requestAnimationFrame(_rafBugFix);\n},\n // in some browsers (like Firefox), screen repaints weren't consistent unless we had SOMETHING queued up in requestAnimationFrame()! So this just creates a super simple loop to keep it alive and smooth out repaints.\
1130n_pointerDownHandler = function _pointerDownHandler() {\n return _pointerIsDown = 1;\n},\n _pointerUpHandler = function _pointerUpHandler() {\n return _pointerIsDown = 0;\n},\n _passThrough = function _passThrough(v) {\n return v;\n},\n _round = function _round(value) {\n return Math.round(value * 100000) / 100000 || 0;\n},\n _windowExists = function _windowExists() {\n return typeof window !== \"undefined\";\n},\n _getGSAP = function _getGSAP() {\n return gsap || _windowExists() && (gsap = window.gsap) && gsap.registerPlugin && gsap;\n},\n _isViewport = function _isViewport(e) {\n return !!~_root.indexOf(e);\n},\n _getViewportDimension = function _getViewportDimension(dimensionProperty) {\n return (dimensionProperty === \"Height\" ? _100vh : _win[\"inner\" + dimensionProperty]) || _docEl[\"client\" + dimensionProperty] || _body[\"client\" + dimensionProperty];\n},\n _getBoundsFunc = function _getBoundsFunc(element) {\n return (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getProxyProp)(element, \"getBoundingClientRect\") || (_isViewport(element) ? function () {\n _winOffsets.width = _win.innerWidth;\n _winOffsets.height = _100vh;\n return _winOffsets;\n } : function () {\n return _getBounds(element);\n });\n},\n _getSizeFunc = function _getSizeFunc(scroller, isViewport, _ref) {\n var d = _ref.d,\n d2 = _ref.d2,\n a = _ref.a;\n return (a = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getProxyProp)(scroller, \"getBoundingClientRect\")) ? function () {\n return a()[d];\n } : function () {\n return (isViewport ? _getViewportDimension(d2) : scroller[\"client\" + d2]) || 0;\n };\n},\n _getOffsetsFunc = function _getOffsetsFunc(element, isViewport) {\n return !isViewport || ~_Observer_js__WEBPACK_IMPORTED_MODULE_0__._proxies.indexOf(element) ? _getBoundsFunc(element) : function () {\n return _winOffsets;\n };\n},\n _maxScroll = function _maxScroll(element, _ref2) {\n var s = _ref2.s,\n d2 = _ref2.d2,\n d = _ref2.d,\n a = _ref2.a;\n return Math.max(0, (s = \"scroll\" + d2) && (a = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getProxyProp)(element, s)) ? a() - _getBoundsFunc(element)()[d] : _isViewport(element) ? (_docEl[s] || _body[s]) - _getViewportDimension(d2) : element[s] - element[\"offset\" + d2]);\n},\n _iterateAutoRefresh = function _iterateAutoRefresh(func, events) {\n for (var i = 0; i < _autoRefresh.length; i += 3) {\n (!events || ~events.indexOf(_autoRefresh[i + 1])) && func(_autoRefresh[i], _autoRefresh[i + 1], _autoRefresh[i + 2]);\n }\n},\n _isString = function _isString(value) {\n return typeof value === \"string\";\n},\n _isFunction = function _isFunction(value) {\n return typeof value === \"function\";\n},\n _isNumber = function _isNumber(value) {\n return typeof value === \"number\";\n},\n _isObject = function _isObject(value) {\n return typeof value === \"object\";\n},\n _endAnimation = function _endAnimation(animation, reversed, pause) {\n return animation && animation.progress(reversed ? 0 : 1) && pause && animation.pause();\n},\n _callback = function _callback(self, func, extraParam) {\n if (self.enabled) {\n var result = self._ctx ? self._ctx.add(function () {\n return func(self, extraParam);\n }) : func(self, extraParam);\n result && result.totalTime && (self.callbackAnimation = result);\n }\n},\n _abs = Math.abs,\n _left = \"left\",\n _top = \"top\",\n _right = \"right\",\n _bottom = \"bottom\",\n _width = \"width\",\n _height = \"height\",\n _Right = \"Right\",\n _Left = \"Left\",\n _Top = \"Top\",\n _Bottom = \"Bottom\",\n _padding = \"padding\",\n _margin = \"margin\",\n _Width = \"Width\",\n _Height = \"Height\",\n _px = \"px\",\n _getComputedStyle = function _getComputedStyle(element) {\n return _win.getComputedStyle(element.nodeType === Node.DOCUMENT_NODE ? element.scrollingElement : element);\n},\n _makePositionable = function _makePositionable(element) {\n // if the element already has position: absolute or fixed, leave that, otherwise make it position: relative\n var position = _getComputedStyle(element).position;\n\n element.style.position = position === \"absolute\" || position === \"fixed\" ? position : \"relative\";\n},\n _setDefaults = function _setDefaults(obj, defaults) {\n for (var p in defaults) {\n p in obj || (obj[p] = defaults[p]);\n }\n\n return obj;\n},\n _getBounds = function _getBounds(element, withoutTransforms) {\n var tween = withoutTransforms && _getComputedStyle(element)[_transformProp] !== \"matrix(1, 0, 0, 1, 0, 0)\" && gsap.to(element, {\n x: 0,\n y: 0,\n xPercent: 0,\n yPercent: 0,\n rotation: 0,\n rotationX: 0,\n rotationY: 0,\n scale: 1,\n skewX: 0,\n skewY: 0\n }).progress(1),\n bounds = element.getBoundingClientRect ? element.getBoundingClientRect() : element.scrollingElement.getBoundingClientRect();\n tween && tween.progress(0).kill();\n return bounds;\n},\n _getSize = function _getSize(element, _ref3) {\n var d2 = _ref3.d2;\n return element[\"offset\" + d2] || element[\"client\" + d2] || 0;\n},\n _getLabelRatioArray = function _getLabelRatioArray(timeline) {\n var a = [],\n labels = timeline.labels,\n duration = timeline.duration(),\n p;\n\n for (p in labels) {\n a.push(labels[p] / duration);\n }\n\n return a;\n},\n _getClosestLabel = function _getClosestLabel(animation) {\n return function (value) {\n return gsap.utils.snap(_getLabelRatioArray(animation), value);\n };\n},\n _snapDirectional = function _snapDirectional(snapIncrementOrArray) {\n var snap = gsap.utils.snap(snapIncrementOrArray),\n a = Array.isArray(snapIncrementOrArray) && snapIncrementOrArray.slice(0).sort(function (a, b) {\n return a - b;\n });\n return a ? function (value, direction, threshold) {\n if (threshold === void 0) {\n threshold = 1e-3;\n }\n\n var i;\n\n if (!direction) {\n return snap(value);\n }\n\n if (direction > 0) {\n value -= threshold; // to avoid rounding errors. If we're too strict, it might snap forward, then immediately again, and again.\n\n for (i = 0; i < a.length;
1130 i++) {\n if (a[i] >= value) {\n return a[i];\n }\n }\n\n return a[i - 1];\n } else {\n i = a.length;\n value += threshold;\n\n while (i--) {\n if (a[i] <= value) {\n return a[i];\n }\n }\n }\n\n return a[0];\n } : function (value, direction, threshold) {\n if (threshold === void 0) {\n threshold = 1e-3;\n }\n\n var snapped = snap(value);\n return !direction || Math.abs(snapped - value) < threshold || snapped - value < 0 === direction < 0 ? snapped : snap(direction < 0 ? value - snapIncrementOrArray : value + snapIncrementOrArray);\n };\n},\n _getLabelAtDirection = function _getLabelAtDirection(timeline) {\n return function (value, st) {\n return _snapDirectional(_getLabelRatioArray(timeline))(value, st.direction);\n };\n},\n _multiListener = function _multiListener(func, element, types, callback) {\n return types.split(\",\").forEach(function (type) {\n return func(element, type, callback);\n });\n},\n _addListener = function _addListener(element, type, func, nonPassive, capture) {\n return element.addEventListener(type, func, {\n passive: !nonPassive,\n capture: !!capture\n });\n},\n _removeListener = function _removeListener(element, type, func, capture) {\n return element.removeEventListener(type, func, !!capture);\n},\n _wheelListener = function _wheelListener(func, el, scrollFunc) {\n scrollFunc = scrollFunc && scrollFunc.wheelHandler;\n\n if (scrollFunc) {\n func(el, \"wheel\", scrollFunc);\n func(el, \"touchmove\", scrollFunc);\n }\n},\n _markerDefaults = {\n startColor: \"green\",\n endColor: \"red\",\n indent: 0,\n fontSize: \"16px\",\n fontWeight: \"normal\"\n},\n _defaults = {\n toggleActions: \"play\",\n anticipatePin: 0\n},\n _keywords = {\n top: 0,\n left: 0,\n center: 0.5,\n bottom: 1,\n right: 1\n},\n _offsetToPx = function _offsetToPx(value, size) {\n if (_isString(value)) {\n var eqIndex = value.indexOf(\"=\"),\n relative = ~eqIndex ? +(value.charAt(eqIndex - 1) + 1) * parseFloat(value.substr(eqIndex + 1)) : 0;\n\n if (~eqIndex) {\n value.indexOf(\"%\") > eqIndex && (relative *= size / 100);\n value = value.substr(0, eqIndex - 1);\n }\n\n value = relative + (value in _keywords ? _keywords[value] * size : ~value.indexOf(\"%\") ? parseFloat(value) * size / 100 : parseFloat(value) || 0);\n }\n\n return value;\n},\n _createMarker = function _createMarker(type, name, container, direction, _ref4, offset, matchWidthEl, containerAnimation) {\n var startColor = _ref4.startColor,\n endColor = _ref4.endColor,\n fontSize = _ref4.fontSize,\n indent = _ref4.indent,\n fontWeight = _ref4.fontWeight;\n\n var e = _doc.createElement(\"div\"),\n useFixedPosition = _isViewport(container) || (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getProxyProp)(container, \"pinType\") === \"fixed\",\n isScroller = type.indexOf(\"scroller\") !== -1,\n parent = useFixedPosition ? _body : container.tagName === \"IFRAME\" ? container.contentDocument.body : container,\n isStart = type.indexOf(\"start\") !== -1,\n color = isStart ? startColor : endColor,\n css = \"border-color:\" + color + \";font-size:\" + fontSize + \";color:\" + color + \";font-weight:\" + fontWeight + \";pointer-events:none;white-space:nowrap;font-family:sans-serif,Arial;z-index:1000;padding:4px 8px;border-width:0;border-style:solid;\";\n\n css += \"position:\" + ((isScroller || containerAnimation) && useFixedPosition ? \"fixed;\" : \"absolute;\");\n (isScroller || containerAnimation || !useFixedPosition) && (css += (direction === _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical ? _right : _bottom) + \":\" + (offset + parseFloat(indent)) + \"px;\");\n matchWidthEl && (css += \"box-sizing:border-box;text-align:left;width:\" + matchWidthEl.offsetWidth + \"px;\");\n e._isStart = isStart;\n e.setAttribute(\"class\", \"gsap-marker-\" + type + (name ? \" marker-\" + name : \"\"));\n e.style.cssText = css;\n e.innerText = name || name === 0 ? type + \"-\" + name : type;\n parent.children[0] ? parent.insertBefore(e, parent.children[0]) : parent.appendChild(e);\n e._offset = e[\"offset\" + direction.op.d2];\n\n _positionMarker(e, 0, direction, isStart);\n\n return e;\n},\n _positionMarker = function _positionMarker(marker, start, direction, flipped) {\n var vars = {\n display: \"block\"\n },\n side = direction[flipped ? \"os2\" : \"p2\"],\n oppositeSide = direction[flipped ? \"p2\" : \"os2\"];\n marker._isFlipped = flipped;\n vars[direction.a + \"Percent\"] = flipped ? -100 : 0;\n vars[direction.a] = flipped ? \"1px\" : 0;\n vars[\"border\" + side + _Width] = 1;\n vars[\"border\" + oppositeSide + _Width] = 0;\n vars[direction.p] = start + \"px\";
1130\n gsap.set(marker, vars);\n},\n _triggers = [],\n _ids = {},\n _rafID,\n _sync = function _sync() {\n return _getTime() - _lastScrollTime > 34 && (_rafID || (_rafID = requestAnimationFrame(_updateAll)));\n},\n _onScroll = function _onScroll() {\n // previously, we tried to optimize performance by batching/deferring to the next requestAnimationFrame(), but discovered that Safari has a few bugs that make this unworkable (especially on iOS). See https://codepen.io/GreenSock/pen/16c435b12ef09c38125204818e7b45fc?editors=0010 and https://codepen.io/GreenSock/pen/JjOxYpQ/3dd65ccec5a60f1d862c355d84d14562?editors=0010 and https://codepen.io/GreenSock/pen/ExbrPNa/087cef197dc35445a0951e8935c41503?editors=0010\n if (!_normalizer || !_normalizer.isPressed || _normalizer.startX > _body.clientWidth) {\n // if the user is dragging the scrollbar, allow it.\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.cache++;\n\n if (_normalizer) {\n _rafID || (_rafID = requestAnimationFrame(_updateAll));\n } else {\n _updateAll(); // Safari in particular (on desktop) NEEDS the immediate update rather than waiting for a requestAnimationFrame() whereas iOS seems to benefit from waiting for the requestAnimationFrame() tick, at least when normalizing. See https://codepen.io/GreenSock/pen/qBYozqO?editors=0110\n\n }\n\n _lastScrollTime || _dispatch(\"scrollStart\");\n _lastScrollTime = _getTime();\n }\n},\n _setBaseDimensions = function _setBaseDimensions() {\n _baseScreenWidth = _win.innerWidth;\n _baseScreenHeight = _win.innerHeight;\n},\n _onResize = function _onResize(force) {\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.cache++;\n (force === true || !_refreshing && !_ignoreResize && !_doc.fullscreenElement && !_doc.webkitFullscreenElement && (!_ignoreMobileResize || _baseScreenWidth !== _win.innerWidth || Math.abs(_win.innerHeight - _baseScreenHeight) > _win.innerHeight * 0.25)) && _resizeDelay.restart(true);\n},\n // ignore resizes triggered by refresh()\n_listeners = {},\n _emptyArray = [],\n _softRefresh = function _softRefresh() {\n return _removeListener(ScrollTrigger, \"scrollEnd\", _softRefresh) || _refreshAll(true);\n},\n _dispatch = function _dispatch(type) {\n return _listeners[type] && _listeners[type].map(function (f) {\n return f();\n }) || _emptyArray;\n},\n _savedStyles = [],\n // when ScrollTrigger.saveStyles() is called, the inline styles are recorded in this Array in a sequential format like [element, cssText, gsCache, media]. This keeps it very memory-efficient and fast to iterate through.\n_revertRecorded = function _revertRecorded(media) {\n for (var i = 0; i < _savedStyles.length; i += 5) {\n if (!media || _savedStyles[i + 4] && _savedStyles[i + 4].query === media) {\n _savedStyles[i].style.cssText = _savedStyles[i + 1];\n _savedStyles[i].getBBox && _savedStyles[i].setAttribute(\"transform\", _savedStyles[i + 2] || \"\");\n _savedStyles[i + 3].uncache = 1;\n }\n }\n},\n _recordScrollPositions = function _recordScrollPositions() {\n return _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.forEach(function (obj) {\n return _isFunction(obj) && ++obj.cacheID && (obj.rec = obj());\n });\n},\n // record the current scroll position. Also force the clearing of the cache because some browsers take a little while to dispatch the \"scroll\" event and the user may have changed the scroll position and then called ScrollTrigger.refresh() right away\n_revertAll = function _revertAll(kill, media) {\n var trigger;\n\n for (_i = 0; _i < _triggers.length;
1130 _i++) {\n trigger = _triggers[_i];\n\n if (trigger && (!media || trigger._ctx === media)) {\n if (kill) {\n trigger.kill(1);\n } else {\n trigger.revert(true, true);\n }\n }\n }\n\n _isReverted = true;\n media && _revertRecorded(media);\n media || _dispatch(\"revert\");\n},\n _clearScrollMemory = function _clearScrollMemory(scrollRestoration, force) {\n // zero-out all the recorded scroll positions. Don't use _triggers because if, for example, .matchMedia() is used to create some ScrollTriggers and then the user resizes and it removes ALL ScrollTriggers, and then go back to a size where there are ScrollTriggers, it would have kept the position(s) saved from the initial state.\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.cache++;\n (force || !_refreshingAll) && _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.forEach(function (obj) {\n return _isFunction(obj) && obj.cacheID++ && (obj.rec = 0);\n });\n _isString(scrollRestoration) && (_win.history.scrollRestoration = _scrollRestoration = scrollRestoration);\n},\n _refreshingAll,\n _refreshID = 0,\n _queueRefreshID,\n _queueRefreshAll = function _queueRefreshAll() {\n // we don't want to call _refreshAll() every time we create a new ScrollTrigger (for performance reasons) - it's better to batch them. Some frameworks dynamically load content and we can't rely on the window's \"load\" or \"DOMContentLoaded\" events to trigger it.\n if (_queueRefreshID !== _refreshID) {\n var id = _queueRefreshID = _refreshID;\n requestAnimationFrame(function () {\n return id === _refreshID && _refreshAll(true);\n });\n }\n},\n _refresh100vh = function _refresh100vh() {\n _body.appendChild(_div100vh);\n\n _100vh = !_normalizer && _div100vh.offsetHeight || _win.innerHeight;\n\n _body.removeChild(_div100vh);\n},\n _hideAllMarkers = function _hideAllMarkers(hide) {\n return _toArray(\".gsap-marker-start, .gsap-marker-end, .gsap-marker-scroller-start, .gsap-marker-scroller-end\").forEach(function (el) {\n return el.style.display = hide ? \"none\" : \"block\";\n });\n},\n _refreshAll = function _refreshAll(force, skipRevert) {\n _docEl = _doc.documentElement; // some frameworks like Astro may cache the <body> and replace it during routing, so we'll just re-record the _docEl and _body for safety (otherwise, the markers may not get added properly).\n\n _body = _doc.body;\n _root = [_win, _doc, _docEl, _body];\n\n if (_lastScrollTime && !force && !_isReverted) {\n _addListener(ScrollTrigger, \"scrollEnd\", _softRefresh);\n\n return;\n }\n\n _refresh100vh();\n\n _refreshingAll = ScrollTrigger.isRefreshing = true;\n _isReverted || _recordScrollPositions();\n\n var refreshInits = _dispatch(\"refreshInit\");\n\n _sort && ScrollTrigger.sort();\n skipRevert || _revertAll();\n\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.forEach(function (obj) {\n if (_isFunction(obj)) {\n obj.smooth && (obj.target.style.scrollBehavior = \"auto\"); // smooth scrolling interferes\n\n obj(0);\n }\n });\n\n _triggers.slice(0).forEach(function (t) {\n return t.refresh();\n }); // don't loop with _i because during a refresh() someone could call ScrollTrigger.update(
1130) which would iterate through _i resulting in a skip.\n\n\n _isReverted = false;\n\n _triggers.forEach(function (t) {\n // nested pins (pinnedContainer) with pinSpacing may expand the container, so we must accommodate that here.\n if (t._subPinOffset && t.pin) {\n var prop = t.vars.horizontal ? \"offsetWidth\" : \"offsetHeight\",\n original = t.pin[prop];\n t.revert(true, 1);\n t.adjustPinSpacing(t.pin[prop] - original);\n t.refresh();\n }\n });\n\n _clampingMax = 1; // pinSpacing might be propping a page open, thus when we .setPositions() to clamp a ScrollTrigger's end we should leave the pinSpacing alone. That's what this flag is for.\n\n _hideAllMarkers(true);\n\n _triggers.forEach(function (t) {\n // the scroller's max scroll position may change after all the ScrollTriggers refreshed (like pinning could push it down), so we need to loop back and correct any with end: \"max\". Same for anything with a clamped end\n var max = _maxScroll(t.scroller, t._dir),\n endClamp = t.vars.end === \"max\" || t._endClamp && t.end > max,\n startClamp = t._startClamp && t.start >= max;\n\n (endClamp || startClamp) && t.setPositions(startClamp ? max - 1 : t.start, endClamp ? Math.max(startClamp ? max : t.start + 1, max) : t.end, true);\n });\n\n _hideAllMarkers(false);\n\n _clampingMax = 0;\n refreshInits.forEach(function (result) {\n return result && result.render && result.render(-1);\n }); // if the onRefreshInit() returns an animation (typically a gsap.set()), revert it. This makes it easy to put things in a certain spot before refreshing for measurement purposes, and then put things back.\n\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.forEach(function (obj) {\n if (_isFunction(obj)) {\n obj.smooth && requestAnimationFrame(function () {\n return obj.target.style.scrollBehavior = \"smooth\";\n });\n obj.rec && obj(obj.rec);\n }\n });\n\n _clearScrollMemory(_scrollRestoration, 1);\n\n _resizeDelay.pause();\n\n _refreshID++;\n _refreshingAll = 2;\n\n _updateAll(2);\n\n _triggers.forEach(function (t) {\n return _isFunction(t.vars.onRefresh) && t.vars.onRefresh(t);\n });\n\n _refreshingAll = ScrollTrigger.isRefreshing = false;\n\n _dispatch(\"refresh\");\n},\n _lastScroll = 0,\n _direction = 1,\n _primary,\n _updateAll = function _updateAll(force) {\n if (force === 2 || !_refreshingAll && !_isReverted) {\n // _isReverted could be true if, for example, a matchMedia() is in the process of executing. We don't want to update during the time everything is reverted.\n ScrollTrigger.isUpdating = true;\n _primary && _primary.update(0); // ScrollSmoother uses refreshPriority -9999 to become the primary that gets updated before all others because it affects the scroll position.\n\n var l = _triggers.length,\n time = _getTime(),\n recordVelocity = time - _time1 >= 50,\n scroll = l && _triggers[0].scroll();\n\n _direction = _lastScroll > scroll ? -1 : 1;\n _refreshingAll || (_lastScroll = scroll);\n\n if (recordVelocity) {\n if (_lastScrollTime && !_pointerIsDown && time - _lastScrollTime > 200) {\n _lastScrollTime = 0;\n\n _dispatch(\"scrollEnd\");\n }\n\n _time2 = _time1;\n _time1 = time;\n }\n\n if (_direction < 0) {\n _i = l;\n\n while (_i-- > 0) {\n _triggers[_i] && _triggers[_i].update(0, recordVelocity);\n }\n\n _direction = 1;\n } else {\n for (_i = 0; _i < l; _i++) {\n _triggers[_i] && _triggers[_i].update(0, recordVelocity);\n }\n }\n\n ScrollTrigger.isUpdating = false;\n }\n\n _rafID = 0;\n},\n _propNamesToCopy = [_left, _top, _bottom, _right, _margin + _Bottom, _margin + _Right, _margin + _Top, _margin + _Left, \"display\", \"flexShrink\", \"float\", \"zIndex\", \"gridColumnStart\", \"gridColumnEnd\", \"gridRowStart\", \"gridRowEnd\", \"gridArea\", \"justifySelf\", \"alignSelf\", \"placeSelf\", \"order\"],\n _stateProps = _propNamesToCopy.concat([_width, _height, \"boxSizing\", \"max\" + _Width, \"max\" + _Height, \"position\", _margin, _padding, _padding + _Top, _padding + _Right, _padding + _Bottom, _padding + _Left]),\n _swapPinOut = function _swapPinOut(pin, spacer, state) {\n _setState(state);\n\n var cache = pin._gsap;\n\n if (cache.spacerIsNative) {\n _setState(cache.spacerState);\n } else if (pin._gsap.swappedIn) {\n var parent = spacer.parentNode;\n\n if (parent) {\n parent.insertBefore(pin, spacer);\n parent.removeChild(spacer);\n }\n }\n\n pin._gsap.swappedIn = false;\n},\n _swapPinIn = function _swapPinIn(pin, spacer, cs, spacerState) {\n if (!pin._gsap.swappedIn) {\n var i = _propNamesToCopy.length,\n spacerStyle = spacer.style,\n pinStyle = pin.style,\n p;\n\n while (i--) {\n p = _propNamesToCopy[i];\n spacerStyle[p] = cs[p];\n }\n\n spacerStyle.position = cs.position === \"absolute\" ? \"absolute\" : \"relative\";\n cs.display === \"inline\" && (spacerStyle.display = \"inline-block\");\n pinStyle[_bottom] = pinStyle[_right] = \"auto\";\n spacerStyle.flexBasis = cs.flexBasis || \"auto\";\n spacerStyle.overflow = \"visible\";\n spacerStyle.boxSizing = \"border-box\";\n spacerStyle[_width] = _getSize(pin, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal) + _px;\n spacerStyle[_height] = _getSize(pin, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical) + _px;\n spacerStyle[_padding] = pinStyle[_margin] = pinStyle[_top] = pinStyle[_left] = \"0\";\n\n _setState(spacerState);\n\n pinStyle[_width] = pinStyle[\"max\" + _Width] = cs[_width];\n pinStyle[_height] = pinStyle[\"max\" + _Height] = cs[_height];\n pinStyle[_padding] = cs[_padding];\n\n if (pin.parentNode !== spacer) {\n pin.parentNode.insertBefore(spacer, pin);\n spacer.appendChild(pin);\n }\n\n pin._gsap.swappedIn = true;\n }\n},\n _capsExp = /([A-Z])/g,\n _setState = function _setState(state) {\n if (state) {\n var style = state.t.style,\n l = state.length,\n i = 0,\n p,\n value;\n (state.t._gsap || gsap.core.getCache(state.t)).uncache = 1; // otherwise transforms may be off\n\n for (; i < l; i += 2) {\n value = state[i + 1];\n p = state[i];\n\n if (value) {\n style[p] = value;\n } else if (style[p]) {\n style.removeProperty(p.replace(_capsExp, \"-$1\").toLowerCase());\n }\n }\n }\n},\n _getState = function _getState(element) {\n // returns an Array with alternating values like [property, value, property, value] and a \"t\" property pointing to the target (element). Makes it fast and cheap.\n var l = _stateProps.length,\n style = element.style,\n state = [],\n i = 0;\n\n for (; i < l;
1130 i++) {\n state.push(_stateProps[i], style[_stateProps[i]]);\n }\n\n state.t = element;\n return state;\n},\n _copyState = function _copyState(state, override, omitOffsets) {\n var result = [],\n l = state.length,\n i = omitOffsets ? 8 : 0,\n // skip top, left, right, bottom if omitOffsets is true\n p;\n\n for (; i < l; i += 2) {\n p = state[i];\n result.push(p, p in override ? override[p] : state[i + 1]);\n }\n\n result.t = state.t;\n return result;\n},\n _winOffsets = {\n left: 0,\n top: 0\n},\n // // potential future feature (?) Allow users to calculate where a trigger hits (scroll position) like getScrollPosition(\"#id\", \"top bottom\")\n// _getScrollPosition = (trigger, position, {scroller, containerAnimation, horizontal}) => {\n// \tscroller = _getTarget(scroller || _win);\n// \tlet direction = horizontal ? _horizontal : _vertical,\n// \t\tisViewport = _isViewport(scroller);\n// \t_getSizeFunc(scroller, isViewport, direction);\n// \treturn _parsePosition(position, _getTarget(trigger), _getSizeFunc(scroller, isViewport, direction)(), direction, _getScrollFunc(scroller, direction)(), 0, 0, 0, _getOffsetsFunc(scroller, isViewport)(), isViewport ? 0 : parseFloat(_getComputedStyle(scroller)[\"border\" + direction.p2 + _Width]) || 0, 0, containerAnimation ? containerAnimation.duration() : _maxScroll(scroller), containerAnimation);\n// },\n_parsePosition = function _parsePosition(value, trigger, scrollerSize, direction, scroll, marker, markerScroller, self, scrollerBounds, borderWidth, useFixedPosition, scrollerMax, containerAnimation, clampZeroProp) {\n _isFunction(value) && (value = value(self));\n\n if (_isString(value) && value.substr(0, 3) === \"max\") {\n value = scrollerMax + (value.charAt(4) === \"=\" ? _offsetToPx(\"0\" + value.substr(3), scrollerSize) : 0);\n }\n\n var time = containerAnimation ? containerAnimation.time() : 0,\n p1,\n p2,\n element;\n containerAnimation && containerAnimation.seek(0);\n isNaN(value) || (value = +value); // convert a string number like \"45\" to an actual number\n\n if (!_isNumber(value)) {\n _isFunction(trigger) && (trigger = trigger(self));\n var offsets = (value || \"0\").split(\" \"),\n bounds,\n localOffset,\n globalOffset,\n display;\n element = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(trigger, self) || _body;\n bounds = _getBounds(element) || {};\n\n if ((!bounds || !bounds.left && !bounds.top) && _getComputedStyle(element).display === \"none\") {\n // if display is \"none\", it won't report getBoundingClientRect() properly\n display = element.style.display;\n element.style.display = \"block\";\n bounds = _getBounds(element);\n display ? element.style.display = display : element.style.removeProperty(\"display\");\n }\n\n localOffset = _offsetToPx(offsets[0], bounds[direction.d]);\n globalOffset = _offsetToPx(offsets[1] || \"0\", scrollerSize);\n value = bounds[direction.p] - scrollerBounds[direction.p] - borderWidth + localOffset + scroll - globalOffset;\n markerScroller && _positionMarker(markerScroller, globalOffset, direction, scrollerSize - globalOffset < 20 || markerScroller._isStart && globalOffset > 20);\n scrollerSize -= scrollerSize - globalOffset; // adjust for the marker\n } else {\n containerAnimation && (value = gsap.utils.mapRange(containerAnimation.scrollTrigger.start, containerAnimation.scrollTrigger.end, 0, scrollerMax, value));\n markerScroller && _positionMarker(markerScroller, scrollerSize, direction, true);\n }\n\n if (clampZeroProp) {\n self[clampZeroProp] = value || -0.001;\n value < 0 && (value = 0);\n }\n\n if (marker) {\n var position = value + scrollerSize,\n isStart = marker._isStart;\n p1 = \"scroll\" + direction.d2;\n\n _positionMarker(marker, position, direction, isStart && position > 20 || !isStart && (useFixedPosition ? Math.max(_body[p1], _docEl[p1]) : marker.parentNode[p1]) <= position + 1);\n\n if (useFixedPosition) {\n scrollerBounds = _getBounds(marker
1130Scroller);\n useFixedPosition && (marker.style[direction.op.p] = scrollerBounds[direction.op.p] - direction.op.m - marker._offset + _px);\n }\n }\n\n if (containerAnimation && element) {\n p1 = _getBounds(element);\n containerAnimation.seek(scrollerMax);\n p2 = _getBounds(element);\n containerAnimation._caScrollDist = p1[direction.p] - p2[direction.p];\n value = value / containerAnimation._caScrollDist * scrollerMax;\n }\n\n containerAnimation && containerAnimation.seek(time);\n return containerAnimation ? value : Math.round(value);\n},\n _prefixExp = /(webkit|moz|length|cssText|inset)/i,\n _reparent = function _reparent(element, parent, top, left) {\n if (element.parentNode !== parent) {\n var style = element.style,\n p,\n cs;\n\n if (parent === _body) {\n element._stOrig = style.cssText; // record original inline styles so we can revert them later\n\n cs = _getComputedStyle(element);\n\n for (p in cs) {\n // must copy all relevant styles to ensure that nothing changes visually when we reparent to the <body>. Skip the vendor prefixed ones.\n if (!+p && !_prefixExp.test(p) && cs[p] && typeof style[p] === \"string\" && p !== \"0\") {\n style[p] = cs[p];\n }\n }\n\n style.top = top;\n style.left = left;\n } else {\n style.cssText = element._stOrig;\n }\n\n gsap.core.getCache(element).uncache = 1;\n parent.appendChild(element);\n }\n},\n _interruptionTracker = function _interruptionTracker(getValueFunc, initialValue, onInterrupt) {\n var last1 = initialValue,\n last2 = last1;\n return function (value) {\n var current = Math.round(getValueFunc()); // round because in some [very uncommon] Windows environments, scroll can get reported with decimals even though it was set without.\n\n if (current !== last1 && current !== last2 && Math.abs(current - last1) > 3 && Math.abs(current - last2) > 3) {\n // if the user scrolls, kill the tween. iOS Safari intermittently misreports the scroll position, it may be the most recently-set one or the one before that! When Safari is zoomed (CMD-+), it often misreports as 1 pixel off too! So if we set the scroll position to 125, for example, it'll actually report it as 124.\n value = current;\n onInterrupt && onInterrupt();\n }\n\n last2 = last1;\n last1 = Math.round(value);\n return last1;\n };\n},\n _shiftMarker = function _shiftMarker(marker, direction, value) {\n var vars = {};\n vars[direction.p] = \"+=\" + value;\n gsap.set(marker, vars);\n},\n // _mergeAnimations = animations => {\n// \tlet tl = gsap.timeline({smoothChildTiming: true}).startTime(Math.min(...animations.map(a => a.globalTime(0))));\n// \tanimations.forEach(a => {let time = a.totalTime(); tl.add(a); a.totalTime(time); });\n// \ttl.smoothChildTiming = false;\n// \treturn tl;\n// },\n// returns a function that can be used to tween the scroll position in the direction provided, and when doing so it'll add a .tween property to the FUNCTION itself, and remove it when the tween completes or gets killed. This gives us a way to have multiple ScrollTriggers use a central function for any given scroller and see if there's a scroll tween running (which would affect if/how things get updated)\n_getTweenCreator = function _getTweenCreator(scroller, direction) {\n var getScroll = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getScrollFunc)(scroller, direction),\n prop = \"_scroll\" + direction.p2,\n // add a tweenable property to the scroller that's a getter/setter function, like _scrollTop or _scrollLeft. This way, if someone does gsap.killTweensOf(scroller) it'll
1130kill the scroll tween.\n getTween = function getTween(scrollTo, vars, initialValue, change1, change2) {\n var tween = getTween.tween,\n onComplete = vars.onComplete,\n modifiers = {};\n initialValue = initialValue || getScroll();\n\n var checkForInterruption = _interruptionTracker(getScroll, initialValue, function () {\n tween.kill();\n getTween.tween = 0;\n });\n\n change2 = change1 && change2 || 0; // if change1 is 0, we set that to the difference and ignore change2. Otherwise, there would be a compound effect.\n\n change1 = change1 || scrollTo - initialValue;\n tween && tween.kill();\n vars[prop] = scrollTo;\n vars.inherit = false;\n vars.modifiers = modifiers;\n\n modifiers[prop] = function () {\n return checkForInterruption(initialValue + change1 * tween.ratio + change2 * tween.ratio * tween.ratio);\n };\n\n vars.onUpdate = function () {\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.cache++;\n getTween.tween && _updateAll(); // if it was interrupted/killed, like in a context.revert(), don't force an updateAll()\n };\n\n vars.onComplete = function () {\n getTween.tween = 0;\n onComplete && onComplete.call(tween);\n };\n\n tween = getTween.tween = gsap.to(scroller, vars);\n return tween;\n };\n\n scroller[prop] = getScroll;\n\n getScroll.wheelHandler = function () {\n return getTween.tween && getTween.tween.kill() && (getTween.tween = 0);\n };\n\n _addListener(scroller, \"wheel\", getScroll.wheelHandler); // Windows machines handle mousewheel scrolling in chunks (like \"3 lines per scroll\") meaning the typical strategy for cancelling the scroll isn't as sensitive. It's much more likely to match one of the previous 2 scroll event positions. So we kill any snapping as soon as there's a wheel event.\n\n\n ScrollTrigger.isTouch && _addListener(scroller, \"touchmove\", getScroll.wheelHandler);\n return getTween;\n};\n\nvar ScrollTrigger = /*#__PURE__*/function () {\n function ScrollTrigger(vars, animation) {\n _coreInitted || ScrollTrigger.register(gsap) || console.warn(\"Please gsap.registerPlugin(ScrollTrigger)\");\n\n _context(this);\n\n this.init(vars, animation);\n }\n\n var _proto = ScrollTrigger.prototype;\n\n _proto.init = function init(vars, animation) {\n this.progress = this.start = 0;\n this.vars && this.kill(true, true); // in case it's being initted again\n\n if (!_enabled) {\n this.update = this.refresh = this.kill = _passThrough;\n return;\n }\n\n vars = _setDefaults(_isString(vars) || _isNumber(vars) || vars.nodeType ? {\n trigger: vars\n } : vars, _defaults);\n\n var _vars = vars,\n onUpdate = _vars.onUpdate,\n toggleClass = _vars.toggleClass,\n id = _vars.id,\n onToggle = _vars.onToggle,\n onRefresh = _vars.onRefresh,\n scrub = _vars.scrub,\n trigger = _vars.trigger,\n pin = _vars.pin,\n pinSpacing = _vars.pinSpacing,\n invalidateOnRefresh = _vars.invalidateOnRefresh,\n anticipatePin = _vars.anticipatePin,\n onScrubComplete = _vars.onScrubComplete,\n onSnapComplete = _vars.onSnapComplete,\n once = _vars.once,\n snap = _vars.snap,\n pinReparent = _vars.pinReparent,\n pinSpacer = _vars.pinSpacer,\n containerAnimation = _vars.containerAnimation,\n fastScrollEnd = _vars.fastScrollEnd,\n preventOverlaps = _vars.preventOverlaps,\n direction = vars.horizontal || vars.containerAnimation && vars.horizontal !== false ? _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal : _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical,\n isToggle = !scrub && scrub !== 0,\n scroller = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(vars.scroller || _win),\n scrollerCache = gsap.core.getCache(scroller),\n isViewport = _isViewport(scroller),\n useFixedPosition = (\"pinType\" in vars ? vars.pinType : (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getProxyProp)(scroller, \"pinType\") || isViewport && \"fixed\") === \"fixed\",\n callbacks = [vars.onEnter, vars.onLeave, vars.onEnterBack, vars.onLeaveBack],\n toggleActions = isToggle && vars.toggleActions.split(\" \"),\n markers = \"markers\" in vars ? vars.markers : _defaults.markers,\n borderWidth = isViewport ? 0 : parseFloat(_getComputedStyle(scroller)[\"border\" + direction.p2 + _Width]) || 0,\n self = this,\n onRefreshInit = vars.onRefreshInit && function () {\n return vars.onRefreshInit(self);\n }
1130,\n getScrollerSize = _getSizeFunc(scroller, isViewport, direction),\n getScrollerOffsets = _getOffsetsFunc(scroller, isViewport),\n lastSnap = 0,\n lastRefresh = 0,\n prevProgress = 0,\n scrollFunc = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getScrollFunc)(scroller, direction),\n tweenTo,\n pinCache,\n snapFunc,\n scroll1,\n scroll2,\n start,\n end,\n markerStart,\n markerEnd,\n markerStartTrigger,\n markerEndTrigger,\n markerVars,\n executingOnRefresh,\n change,\n pinOriginalState,\n pinActiveState,\n pinState,\n spacer,\n offset,\n pinGetter,\n pinSetter,\n pinStart,\n pinChange,\n spacingStart,\n spacerState,\n markerStartSetter,\n pinMoves,\n markerEndSetter,\n cs,\n snap1,\n snap2,\n scrubTween,\n scrubSmooth,\n snapDurClamp,\
1130n snapDelayedCall,\n prevScroll,\n prevAnimProgress,\n caMarkerSetter,\n customRevertReturn; // for the sake of efficiency, _startClamp/_endClamp serve like a truthy value indicating that clamping was enabled on the start/end, and ALSO store the actual pre-clamped numeric value. We tap into that in ScrollSmoother for speed effects. So for example, if start=\"clamp(top bottom)\" results in a start of -100 naturally, it would get clamped to 0 but -100 would be stored in _startClamp.\n\n\n self._startClamp = self._endClamp = false;\n self._dir = direction;\n anticipatePin *= 45;\n self.scroller = scroller;\n self.scroll = containerAnimation ? containerAnimation.time.bind(containerAnimation) : scrollFunc;\n scroll1 = scrollFunc();\n self.vars = vars;\n animation = animation || vars.animation;\n\n if (\"refreshPriority\" in vars) {\n _sort = 1;\n vars.refreshPriority === -9999 && (_primary = self); // used by ScrollSmoother\n }\n\n scrollerCache.tweenScroll = scrollerCache.tweenScroll || {\n top: _getTweenCreator(scroller, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical),\n left: _getTweenCreator(scroller, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal)\n };\n self.tweenTo = tweenTo = scrollerCache.tweenScroll[direction.p];\n\n self.scrubDuration = function (value) {\n scrubSmooth = _isNumber(value) && value;\n\n if (!scrubSmooth) {\n scrubTween && scrubTween.progress(1).kill();\n scrubTween = 0;\n } else {\n scrubTween ? scrubTween.duration(value) : scrubTween = gsap.to(animation, {\n ease: \"expo\",\n totalProgress: \"+=0\",\n inherit: false,\n duration: scrubSmooth,\n paused: true,\n onComplete: function onComplete() {\n return onScrubComplete && onScrubComplete(self);\n }\n });\n }\n };\n\n if (animation) {\n animation.vars.lazy = false;\n animation._initted && !self.isReverted || animation.vars.immediateRender !== false && vars.immediateRender !== false && animation.duration() && animation.render(0, true, true); // special case: if this ScrollTrigger gets re-initted, a from() tween with a stagger could get initted initially and then reverted on the re-init which means it'll need to get rendered again here to properly display things. Otherwise, See https://gsap.com/forums/topic/36777-scrollsmoother-splittext-nextjs/ and https://codepen.io/GreenSock/pen/eYPyPpd?editors=0010\n\n self.animation = animation.pause();\n animation.scrollTrigger = self;\n self.scrubDuration(scrub);\n snap1 = 0;\n id || (id = animation.vars.id);\n }\n\n if (snap) {\n // TODO: potential idea: use legitimate CSS scroll snapping by pushing invisible elements into the DOM that serve as snap positions, and toggle the document.scrollingElement.style.scrollSnapType onToggle. See https://codepen.io/GreenSock/pen/JjLrgWM for a quick proof of concept.\n if (!_isObject(snap) || snap.push) {\n snap = {\n snapTo: snap\n };\n }\n\n \"scrollBehavior\" in _body.style && gsap.set(isViewport ? [_body, _docEl] : scroller, {\n scrollBehavior: \"auto\"\n }); // smooth scrolling doesn't work with snap.\n\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.forEach(function (o) {\n return _isFunction(o) && o.target === (isViewport ? _doc.scrollingElement || _docEl : scroller) && (o.smooth = false);\n }); // note: set smooth to false on both the vertical and horizontal scroll getters/setters\n\n\n snapFunc = _isFunction(snap.snapTo) ? snap.snapTo : snap.snapTo === \"labels\" ? _getClosestLabel(animation) : snap.snapTo === \"labelsDirectional\" ? _getLabelAtDirection(animation) : snap.directional !== false ? function (value, st) {\n return _snapDirectional(snap.snapTo)(value, _getTime() - lastRefresh < 500 ? 0 : st.direction);\n } : gsap.utils.snap(snap.snapTo);\n snapDurClamp = snap.duration || {\n min: 0.1,\n max: 2\n };\n snapDurClamp = _isObject(snapDurClamp) ? _clamp(snapDurClamp.min, snapDurClamp.max) : _clamp(snapDurClamp, snapDurClamp);\n snapDelayedCall = gsap.delayedCall(snap.delay || scrubSmooth / 2 || 0.1, function () {\n var scroll = scrollFunc(),\n refreshedRecently = _getTime() - lastRefresh < 500,\n tween = tweenTo.tween;\n\n if ((refreshedRecently || Math.abs(self.getVelocity()) < 10) && !tween && !_pointerIsDown && lastSnap !== scroll) {\n var progress = (scroll - start) / change,\n totalProgress = animation && !isToggle ? animation.totalProgress() : progress,\n velocity = refreshedRecently ? 0 : (totalProgress - snap2) / (_getTime() - _time2) * 1000 || 0,\n change1 = gsap.utils.clamp(-progress, 1 - progress, _abs(velocity / 2) * velocity / 0.185),\n naturalEnd = progress + (snap.inertia === false ? 0 : change1),\n endValue,\n endScroll,\n _snap = snap,\n onStart = _snap.onStart,\n _onInterrupt = _snap.onInterrupt,\n _onComplete = _snap.onComplete;\n endValue = snapFunc(naturalEnd, self);\n _isNumber(endValue) || (endValue = naturalEnd); // in case the function didn't return a number, fall back to using the naturalEnd\n\n endScroll = Math.max(0, Math.round(start + endValue * change));\n\n if (scroll <= end && scroll >= start && endScroll !== scroll) {\n if (tween && !tween._initted && tween.data <= _abs(endScroll - scroll)) {\n // there's an overlapping snap! So we must figure out which one is closer and let that tween live.\n return;\n }\n\n if (snap.inertia === false) {\n change1 = endValue - progress;\n }\n\n tweenTo(endScroll, {\n duration: snapDurClamp(_abs(Math.max(_abs(naturalEnd - totalProgress), _abs(endValue - totalProgress)) * 0.185 / velocity / 0.05 || 0)),\n ease: snap.ease || \"power3\",\n data: _abs(endScroll - scroll),\n // record the distance so that if another snap tween occurs (conflict) we
1130can prioritize the closest snap.\n onInterrupt: function onInterrupt() {\n return snapDelayedCall.restart(true) && _onInterrupt && _callback(self, _onInterrupt);\n },\n onComplete: function onComplete() {\n self.update();\n lastSnap = scrollFunc();\n\n if (animation && !isToggle) {\n // the resolution of the scrollbar is limited, so we should correct the scrubbed animation's playhead at the end to match EXACTLY where it was supposed to snap\n scrubTween ? scrubTween.resetTo(\"totalProgress\", endValue, animation._tTime / animation._tDur) : animation.progress(endValue);\n }\n\n snap1 = snap2 = animation && !isToggle ? animation.totalProgress() : self.progress;\n onSnapComplete && onSnapComplete(self);\n _onComplete && _callback(self, _onComplete);\n }\n }, scroll, change1 * change, endScroll - scroll - change1 * change);\n onStart && _callback(self, onStart, tweenTo.tween);\n }\n } else if (self.isActive && lastSnap !== scroll) {\n snapDelayedCall.restart(true);\n }\n }).pause();\n }\n\n id && (_ids[id] = self);\n trigger = self.trigger = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(trigger || pin !== true && pin); // if a trigger has some kind of scroll-related effect applied that could contaminate the \"y\" or \"x\" position (like a ScrollSmoother effect), we needed a way to temporarily revert it, so we use the stRevert property of the gsCache. It can return another function that we'll call at the end so it can return to its normal state.\n\n customRevertReturn = trigger && trigger._gsap && trigger._gsap.stRevert;\n customRevertReturn && (customRevertReturn = customRevertReturn(self));\n pin = pin === true ? trigger : (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(pin);\n _isString(toggleClass) && (toggleClass = {\n targets: trigger,\n className: toggleClass\n });\n\n if (pin) {\n pinSpacing === false || pinSpacing === _margin || (pinSpacing = !pinSpacing && pin.parentNode && pin.parentNode.style && _getComputedStyle(pin.parentNode).display === \"flex\" ? false : _padding); // if the parent is display: flex, don't apply pinSpacing by default. We should check that pin.parentNode is an element (not shadow dom window)\n\n self.pin = pin;\n pinCache = gsap.core.getCache(pin);\n\n if (!pinCache.spacer) {\n // record the spacer and pinOriginalState on the cache in case someone tries pinning the same element with MULTIPLE ScrollTriggers - we don't want to have multiple spacers or record the \"original\" pin state after it has already been affected by another ScrollTrigger.\n if (pinSpacer) {\n pinSpacer = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(pinSpacer);\n pinSpacer && !pinSpacer.nodeType && (pinSpacer = pinSpacer.current || pinSpacer.nativeElement); // for React & Angular\n\n pinCache.spacerIsNative = !!pinSpacer;\n pinSpacer && (pinCache.spacerState = _getState(pinSpacer));\n }\n\n pinCache.spacer = spacer = pinSpacer || _doc.createElement(\"div\");\n spacer.classList.add(\"pin-spacer\");\n id && spacer.classList.add(\"pin-spacer-\" + id);\n pinCache.pinState = pinOriginalState = _getState(pin);\n } else {\n pinOriginalState = pinCache.pinState;\n }\n\n vars.force3D !== false && gsap.set(pin, {\n force3D: true\n });\n self.spacer = spacer = pinCache.spacer;\n cs = _getComputedStyle(pin);\n spacingStart = cs[pinSpacing + direction.os2];\n pinGetter = gsap.getProperty(pin);\n pinSetter = gsap.quickSetter(pin, direction.a, _px); // pin.firstChild && !_maxScroll(pin, direction) && (pin.style.overflow = \"hidden\"); // protects from collapsing margins, but can have unintended consequences as demonstrated here: https://codepen.io/GreenSock/pen/1e42c7a73bfa409d2cf1e184e7a4248d so it was removed in favor of just telling people to set up their CSS to avoid the collapsing margins (overflow: hidden | auto is just one option. Another is border-top: 1px solid transparent).\n\n _swapPinIn(pin, spacer, cs);
1130\n\n pinState = _getState(pin);\n }\n\n if (markers) {\n markerVars = _isObject(markers) ? _setDefaults(markers, _markerDefaults) : _markerDefaults;\n markerStartTrigger = _createMarker(\"scroller-start\", id, scroller, direction, markerVars, 0);\n markerEndTrigger = _createMarker(\"scroller-end\", id, scroller, direction, markerVars, 0, markerStartTrigger);\n offset = markerStartTrigger[\"offset\" + direction.op.d2];\n\n var content = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)((0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getProxyProp)(scroller, \"content\") || scroller);\n\n markerStart = this.markerStart = _createMarker(\"start\", id, content, direction, markerVars, offset, 0, containerAnimation);\n markerEnd = this.markerEnd = _createMarker(\"end\", id, content, direction, markerVars, offset, 0, containerAnimation);\n containerAnimation && (caMarkerSetter = gsap.quickSetter([markerStart, markerEnd], direction.a, _px));\n\n if (!useFixedPosition && !(_Observer_js__WEBPACK_IMPORTED_MODULE_0__._proxies.length && (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getProxyProp)(scroller, \"fixedMarkers\") === true)) {\n _makePositionable(isViewport ? _body : scroller);\n\n gsap.set([markerStartTrigger, markerEndTrigger], {\n force3D: true\n });\n markerStartSetter = gsap.quickSetter(markerStartTrigger, direction.a, _px);\n markerEndSetter = gsap.quickSetter(markerEndTrigger, direction.a, _px);\n }\n }\n\n if (containerAnimation) {\n var oldOnUpdate = containerAnimation.vars.onUpdate,\n oldParams = containerAnimation.vars.onUpdateParams;\n containerAnimation.eventCallback(\"onUpdate\", function () {\n self.update(0, 0, 1);\n oldOnUpdate && oldOnUpdate.apply(containerAnimation, oldParams || []);\n });\n }\n\n self.previous = function () {\n return _triggers[_triggers.indexOf(self) - 1];\n };\n\n self.next = function () {\n return _triggers[_triggers.indexOf(self) + 1];\n };\n\n self.revert = function (revert, temp) {\n if (!temp) {\n return self.kill(true);\n } // for compatibility with gsap.context() and gsap.matchMedia() which call revert()\n\n\n var r = revert !== false || !self.enabled,\n prevRefreshing = _refreshing;\n\n if (r !== self.isReverted) {\n if (r) {\n prevScroll = Math.max(scrollFunc(), self.scroll.rec || 0); // record the scroll so we can revert later (repositioning/pinning things can affect scroll position). In the static refresh() method, we first record all the scroll positions as a reference.\n\n prevProgress = self.progress;\n prevAnimProgress = animation && animation.progress();\n }\n\n markerStart && [markerStart, markerEnd, markerStartTrigger, markerEndTrigger].forEach(function (m) {\n return m.style.display = r ? \"none\" : \"block\";\n });\n\n if (r) {\n _refreshing = self;\n self.update(r); // make sure the pin is back in its original position so that all the measurements are correct. do this BEFORE swapping the pin out\n }\n\n if (pin && (!pinReparent || !self.isActive)) {\n if (r) {\n _swapPinOut(pin, spacer, pinOriginalState);\n } else {\n _swapPinIn(pin, spacer, _getComputedStyle(pin), spacerState);\n }\n }\n\n r || self.update(r); // when we're restoring, the update should run AFTER swapping the pin into its pin-spacer.\n\n _refreshing = prevRefreshing; // restore. We set it to true during the update() so that things fire properly in there.\n\n self.isReverted = r;\n }\n };\n\n self.refresh = function (soft, force, position, pinOffset) {\n // position is typically only defined if it's coming from setPositions() - it's a way to skip the normal parsing. pinOffset is also only from setPositions() and is mostly related to fancy stuff we need to do in ScrollSmoother with effects\n if ((_refreshing || !self.enabled) && !force) {\n return;\n }\n\n if (pin && soft && _lastScrollTime) {\n _addListener(ScrollTrigger, \"scrollEnd\", _softRefresh);\n\n return;\n }\n\n !_refreshingAll && onRefreshInit && onRefreshInit(self);\n _refreshing = self;\n\n if (tweenTo.tween && !position) {\n // we skip this if a position is passed in because typically that's from .setPositions() and it's best to allow in-progress snapping to continue.\n tweenTo.tween.kill();\n tweenTo.tween = 0;\n }\n\n scrubTween && scrubTween.pause();\n\n if (invalidateOnRefresh && animation) {\n animation.revert({\n kill: false\n }).invalidate();\n animation.getChildren ? animation.getChildren(true, true, false).forEach(function (t) {\n return t.vars.immediateRender && t.render(0, true, true);\n }) : animation.vars.immediateRender && animation.render(0, true, true); // any from() or fromTo() tweens should render immediately (well, unless they have immediateRender: false)\n }\n\n self.isReverted || self.revert(true, true);\n self._subPinOffset = false; // we'll set this to true in the sub-pins if we find any\n\n var size = getScrollerSize(),\n scrollerBounds = getScrollerOffsets(),\n max = containerAnimation ? c
1130ontainerAnimation.duration() : _maxScroll(scroller, direction),\n isFirstRefresh = change <= 0.01 || !change,\n offset = 0,\n otherPinOffset = pinOffset || 0,\n parsedEnd = _isObject(position) ? position.end : vars.end,\n parsedEndTrigger = vars.endTrigger || trigger,\n parsedStart = _isObject(position) ? position.start : vars.start || (vars.start === 0 || !trigger ? 0 : pin ? \"0 0\" : \"0 100%\"),\n pinnedContainer = self.pinnedContainer = vars.pinnedContainer && (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(vars.pinnedContainer, self),\n triggerIndex = trigger && Math.max(0, _triggers.indexOf(self)) || 0,\n i = triggerIndex,\n cs,\n bounds,\n scroll,\n isVertical,\n override,\n curTrigger,\n curPin,\n oppositeScroll,\n initted,\n revertedPins,\n forcedOverflow,\n markerStartOffset,\n markerEndOffset;\n\n if (markers && _isObject(position)) {\n // if we alter the start/end positions with .setPositions(), it generally feeds in absolute NUMBERS which don't convey information about where to line up the markers, so to keep it intuitive, we record how far the trigger positions shift after applying the new numbers and then offset by that much in the opposite direction. We do the same to the associated trigger markers too of course.\n markerStartOffset = gsap.getProperty(markerStartTrigger, direction.p);\n markerEndOffset = gsap.getProperty(markerEndTrigger, direction.p);\n }\n\n while (i-- > 0) {\n // user might try to pin the same element more than once, so we must find any prior triggers with the same pin, revert them, and determine how long they're pinning so that we can offset things appropriately. Make sure we revert from last to first so that things \"rewind\" properly.\n curTrigger = _triggers[i];\n curTrigger.end || curTrigger.refresh(0, 1) || (_refreshing = self); // if it's a timeline-based trigger that hasn't been fully initialized yet because it's waiting for 1 tick, just force the refresh() here, otherwise if it contains a pin that's supposed to affect other ScrollTriggers further down the page, they won't be adjusted properly.\n\n curPin = curTrigger.pin;\n\n if (curPin && (curPin === trigger || curPin === pin || curPin === pinnedContainer) && !curTrigger.isReverted) {\n revertedPins || (revertedPins = []);\n revertedPins.unshift(curTrigger); // we'll revert from first to last to make sure things reach their end state properly\n\n curTrigger.revert(true, true);\n }\n\n if (curTrigger !== _triggers[i]) {\n // in case it got removed.\n triggerIndex--;\n i--;\n }\n }\n\n _isFunction(parsedStart) && (parsedStart = parsedStart(self));\n parsedStart = _parseClamp(parsedStart, \"start\", self);\n start = _parsePosition(parsedStart, trigger, size, direction, scrollFunc(), markerStart, markerStartTrigger, self, scrollerBounds, borderWidth, useFixedPosition, max, containerAnimation, self._startClamp && \"_startClamp\") || (pin ? -0.001 : 0);\n _isFunction(parsedEnd) && (parsedEnd = parsedEnd(self));\n\n if (_isString(parsedEnd) && !parsedEnd.indexOf(\"+=\")) {\n if (~parsedEnd.indexOf(\" \")) {\n parsedEnd = (_isString(parsedStart) ? parsedStart.split(\" \")[0] : \"\") + parsedEnd;\n } else {\n offset = _offsetToPx(parsedEnd.substr(2), size);\n parsedEnd = _isString(parsedStart) ? parsedStart : (containerAnimation ? gsap.utils.mapRange(0, containerAnimation.duration(), containerAnimation.scrollTrigger.start, containerAnimation.scrollTrigger.end, start) : start) + offset; // _parsePosition won't factor in the offset if the start is a number, so do it here.\n\n parsedEndTrigger = trigger;\n }\n }\n\n parsedEnd = _parseClamp(parsedEnd, \"end\", self);\n end = Math.max(start, _parsePosition(parsedEnd || (parsedEndTrigger ? \"100% 0\" : max), parsedEndTrigger, size, direction, scrollFunc() + offset, markerEnd, markerEndTrigger, self, scrollerBounds, borderWidth, useFixedPosition, max, containerAnimation, self._endClamp && \"_endClamp\")) || -0.001;\n offset = 0;\n i = triggerIndex;\n\n while (i--) {\n curTrigger = _triggers[i] || {};\n curPin = curTrigger.pin;\n\n if (curPin && curTrigger.start - curTrigger._pinPush <= start && !containerAnimation && curTrigger.end > 0) {\n cs = curTrigger.end - (self._startClamp ? Math.max(0, curTr
1130igger.start) : curTrigger.start);\n\n if ((curPin === trigger && curTrigger.start - curTrigger._pinPush < start || curPin === pinnedContainer) && isNaN(parsedStart)) {\n // numeric start values shouldn't be offset at all - treat them as absolute\n offset += cs * (1 - curTrigger.progress);\n }\n\n curPin === pin && (otherPinOffset += cs);\n }\n }\n\n start += offset;\n end += offset;\n self._startClamp && (self._startClamp += offset);\n\n if (self._endClamp && !_refreshingAll) {\n self._endClamp = end || -0.001;\n end = Math.min(end, _maxScroll(scroller, direction));\n }\n\n change = end - start || (start -= 0.01) && 0.001;\n\n if (isFirstRefresh) {\n // on the very first refresh(), the prevProgress couldn't have been accurate yet because the start/end were never calculated, so we set it here. Before 3.11.5, it could lead to an inaccurate scroll position restoration with snapping.\n prevProgress = gsap.utils.clamp(0, 1, gsap.utils.normalize(start, end, prevScroll));\n }\n\n self._pinPush = otherPinOffset;\n\n if (markerStart && offset) {\n // offset the markers if necessary\n cs = {};\n cs[direction.a] = \"+=\" + offset;\n pinnedContainer && (cs[direction.p] = \"-=\" + scrollFunc());\n gsap.set([markerStart, markerEnd], cs);\n }\n\n if (pin && !(_clampingMax && self.end >= _maxScroll(scroller, direction))) {\n cs = _getComputedStyle(pin);\n isVertical = direction === _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical;\n scroll = scrollFunc(); // recalculate because the triggers can affect the scroll\n\n pinStart = parseFloat(pinGetter(direction.a)) + otherPinOffset;\n\n if (!max && end > 1) {\n // makes sure the scroller has a scrollbar, otherwise if something has width: 100%, for example, it would be too big (exclude the scrollbar). See https://gsap.com/forums/topic/25182-scrolltrigger-width-of-page-increase-where-markers-are-set-to-false/\n forcedOverflow = (isViewport ? _doc.scrollingElement || _docEl : scroller).style;\n forcedOverflow = {\n style: forcedOverflow,\n value: forcedOverflow[\"overflow\" + direction.a.toUpperCase()]\n };\n\n if (isViewport && _getComputedStyle(_body)[\"overflow\" + direction.a.toUpperCase()] !== \"scroll\") {\n // avoid an extra scrollbar if BOTH <html> and <body> have overflow set to \"scroll\"\n forcedOverflow.style[\"overflow\" + direction.a.toUpperCase()] = \"scroll\";\n }\n }\n\n _swapPinIn(pin, spacer, cs);\n\n pinState = _getState(pin); // transforms will interfere with the top/left/right/bottom placement, so remove them temporarily. getBoundingClientRect() factors in transforms.\n\n bounds = _getBounds(pin, true);\n oppositeScroll = useFixedPosition && (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getScrollFunc)(scroller, isVertical ? _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal : _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical)();\n\n if (pinSpacing) {\n spacerState = [pinSpacing + direction.os2, change + otherPinOffset + _px];\n spacerState.t = spacer;\n i = pinSpacing === _padding ? _getSize(pin, direction) + change + otherPinOffset : 0;\n\n if (i) {\n spacerState.push(direction.d, i + _px); // for box-sizing: border-box (must include padding).\n\n spacer.style.flexBasis !== \"auto\" && (spacer.style.flexBasis = i + _px);\n }\n\n _setState(spacerState);\n\n if (pinnedContainer) {\n // in ScrollTrigger.refresh(), we need to re-evaluate the pinContainer's size because this pinSpacing may stretch it out, but we can't just add the exact distance because depending on layout, it may not push things down or it may only do so partially.\n _triggers.forEach(function (t) {\n if (t.pin === pinnedContainer && t.vars.pinSpacing !== false) {\n t._subPinOffset = true;\n }\n });\n }\n\n useFixedPosition && scrollFunc(prevScroll);\n } else {\n i = _getSize(pin, direction);\n i && spacer.style.flexBasis !== \"auto\" && (spacer.style.flexBasis = i + _px);\n }\n\n if (useFixedPosition) {\n override = {\n top: bounds.top + (isVertical ? scroll - start : oppositeScroll) + _px,\n left: bounds.left + (isVertical ? oppositeScroll : scroll - start) + _px,\n boxSizing: \"border-box\",\n position: \"fixed\"\n };\n override[_width] = override[\"max\" + _Width] = Math.ceil(bounds.width) + _px;\n override[_height] = override[\"max\" + _Height] = Math.ceil(bounds.height) + _px;\n override[_margin] = override[_margin + _Top] = override[_margin + _Right] = override[_margin + _Bottom] = override[_margin + _Left] = \"0\";\n override[_padding] = cs[_padding];\n override[_padding + _Top] = cs[_padding + _Top];\n override[_padding + _Right] = cs[_padding + _Right];\n override[_padding + _Bottom] = cs[_padding + _Bottom];\n override[_padding + _Left] = cs[_padding + _Left];\n pinActiveState = _copyState(pinOriginalState, override, pinReparent);\n _refreshingAll && scrollFunc(0);\n }\n\n if (animation) {\n // the animation might be affecting the transform, so we must jump to the end, check the value, and compensate accordingly. Otherwise, when it becomes unpinned, the pinSetter() will get set to a value that doesn't include whatever the animation did.\n initted = animation._initted; // if not, we must invalidate() after this step, otherwise it could lock
1130in starting values prematurely.\n\n _suppressOverwrites(1);\n\n animation.render(animation.duration(), true, true);\n pinChange = pinGetter(direction.a) - pinStart + change + otherPinOffset;\n pinMoves = Math.abs(change - pinChange) > 1;\n useFixedPosition && pinMoves && pinActiveState.splice(pinActiveState.length - 2, 2); // transform is the last property/value set in the state Array. Since the animation is controlling that, we should omit it.\n\n animation.render(0, true, true);\n initted || animation.invalidate(true);\n animation.parent || animation.totalTime(animation.totalTime()); // if, for example, a toggleAction called play() and then refresh() happens and when we render(1) above, it would cause the animation to complete and get removed from its parent, so this makes sure it gets put back in.\n\n _suppressOverwrites(0);\n } else {\n pinChange = change;\n }\n\n forcedOverflow && (forcedOverflow.value ? forcedOverflow.style[\"overflow\" + direction.a.toUpperCase()] = forcedOverflow.value : forcedOverflow.style.removeProperty(\"overflow-\" + direction.a));\n } else if (trigger && scrollFunc() && !containerAnimation) {\n // it may be INSIDE a pinned element, so walk up the tree and look for any elements with _pinOffset to compensate because anything with pinSpacing that's already scrolled would throw off the measurements in getBoundingClientRect()\n bounds = trigger.parentNode;\n\n while (bounds && bounds !== _body) {\n if (bounds._pinOffset) {\n start -= bounds._pinOffset;\n end -= bounds._pinOffset;\n }\n\n bounds = bounds.parentNode;\n }\n }\n\n revertedPins && revertedPins.forEach(function (t) {\n return t.revert(false, true);\n });\n self.start = start;\n self.end = end;\n scroll1 = scroll2 = _refreshingAll ? prevScroll : scrollFunc(); // reset velocity\n\n if (!containerAnimation && !_refreshingAll) {\n scroll1 < prevScroll && scrollFunc(prevScroll);\n self.scroll.rec = 0;\n }\n\n self.revert(false, true);\n lastRefresh = _getTime();\n\n if (snapDelayedCall) {\n lastSnap = -1; // just so snapping gets re-enabled, clear out any recorded last value\n // self.isActive && scrollFunc(start + change * prevProgress); // previously this line was here to ensure that when snapping kicks in, it's from the previous progress but in some cases that's not desirable, like an all-page ScrollTrigger when new content gets added to the page, that'd totally change the progress.\n\n snapDelayedCall.restart(true);\n }\n\n _refreshing = 0;\n animation && isToggle && (animation._initted || prevAnimProgress) && animation.progress() !== prevAnimProgress && animation.progress(prevAnimProgress || 0, true).render(animation.time(), true, true); // must force a re-render because if saveStyles() was used on the target(s), the styles could have been wiped out during the refresh().\n\n if (isFirstRefresh || prevProgress !== self.progress || containerAnimation || invalidateOnRefresh || animation && !animation._initted) {\n // ensures that the direction is set properly (when refreshing, progress is set back to 0 initially, then back again to wherever it needs to be) and that callbacks are triggered.\n animation && !isToggle && (animation._initted || prevProgress || animation.vars.immediateRender !== false) && animation.totalProgress(containerAnimation && start < -0.001 && !prevProgress ? gsap.utils.normalize(start, end, 0) : prevProgress, true); // to avoid issues where animation callbacks like onStart aren't triggered.\n\n self.progress = isFirstRefresh || (scroll1 - start) / change === prevProgress ? 0 : prevProgress;\n }\n\n pin && pinSpacing && (spacer._pinOffset = Math.round(self.progress * pinChange));\n scrubTween && scrubTween.invalidate();\n\n if (!isNaN(markerStartOffset)) {\n // numbers were passed in for the position which are absolute, so instead of just putting the markers at the very bottom of the viewport, we figure out how far they shifted down (it's safe to assume they were originally positioned in closer relation to the trigger element with values like \"top\", \"center\", a percentage or whatever, so we offset that much in the opposite direction to basically revert them to the relative position thy were at previously.\n markerStartOffset -= gsap.getProperty(markerStartTrigger, direction.p);\n markerEndOffset -= gsap.getProperty(markerEndTrigger, direction.p);\n\n _shiftMarker(markerStartTrigger, direction, markerStartOffset);\n\n _shiftMarker(markerStart, direction, markerStartOffset - (pinOffset || 0));\n\n _shiftMarker(markerEndTrigger, direction, markerEndOffset);\n\n _shiftMarker(markerEnd, direction, markerEndOffset - (pinOffset || 0));\n }
1130\n\n isFirstRefresh && !_refreshingAll && self.update(); // edge case - when you reload a page when it's already scrolled down, some browsers fire a \"scroll\" event before DOMContentLoaded, triggering an updateAll(). If we don't update the self.progress as part of refresh(), then when it happens next, it may record prevProgress as 0 when it really shouldn't, potentially causing a callback in an animation to fire again.\n\n if (onRefresh && !_refreshingAll && !executingOnRefresh) {\n // when refreshing all, we do extra work to correct pinnedContainer sizes and ensure things don't exceed the maxScroll, so we should do all the refreshes at the end after all that work so that the start/end values are corrected.\n executingOnRefresh = true;\n onRefresh(self);\n executingOnRefresh = false;\n }\n };\n\n self.getVelocity = function () {\n return (scrollFunc() - scroll2) / (_getTime() - _time2) * 1000 || 0;\n };\n\n self.endAnimation = function () {\n _endAnimation(self.callbackAnimation);\n\n if (animation) {\n scrubTween ? scrubTween.progress(1) : !animation.paused() ? _endAnimation(animation, animation.reversed()) : isToggle || _endAnimation(animation, self.direction < 0, 1);\n }\n };\n\n self.labelToScroll = function (label) {\n return animation && animation.labels && (start || self.refresh() || start) + animation.labels[label] / animation.duration() * change || 0;\n };\n\n self.getTrailing = function (name) {\n var i = _triggers.indexOf(self),\n a = self.direction > 0 ? _triggers.slice(0, i).reverse() : _triggers.slice(i + 1);\n\n return (_isString(name) ? a.filter(function (t) {\n return t.vars.preventOverlaps === name;\n }) : a).filter(function (t) {\n return self.direction > 0 ? t.end <= start : t.start >= end;\n });\n };\n\n self.update = function (reset, recordVelocity, forceFake) {\n if (containerAnimation && !forceFake && !reset) {\n return;\n }\n\n var scroll = _refreshingAll === true ? prevScroll : self.scroll(),\n p = reset ? 0 : (scroll - start) / change,\n clipped = p < 0 ? 0 : p > 1 ? 1 : p || 0,\n prevProgress = self.progress,\n isActive,\n wasActive,\n toggleState,\n action,\n stateChanged,\n toggled,\n isAtMax,\n isTakingAction;\n\n if (recordVelocity) {\n scroll2 = scroll1;\n scroll1 = containerAnimation ? scrollFunc() : scroll;\n\n if (snap) {\n snap2 = snap1;\n snap1 = animation && !isToggle ? animation.totalProgress() : clipped;\n }\n } // anticipate the pinning a few ticks ahead of time based on velocity to avoid a visual glitch due to the fact that most browsers do scrolling on a separate thread (not synced with requestAnimationFrame).\n\n\n if (anticipatePin && pin && !_refreshing && !_startup && _lastScrollTime) {\n if (!clipped && start < scroll + (scroll - scroll2) / (_getTime() - _time2) * anticipatePin) {\n clipped = 0.0001;\n } else if (clipped === 1 && end > scroll + (scroll - scroll2) / (_getTime() - _time2) * anticipatePin) {\n clipped = 0.9999;\n }\n }\n\n if (clipped !== prevProgress && self.enabled) {\n isActive = self.isActive = !!clipped && clipped < 1;\n wasActive = !!prevProgress && prevProgress < 1;\n toggled = isActive !== wasActive;\n stateChanged = toggled || !!clipped !== !!prevProgress; // could go from start all the way to end, thus it didn't toggle but it did change state in a sense (may need to fire a callback)\n\n self.direction = clipped > prevProgress ? 1 : -1;\n self.progress = clipped;\n\n if (stateChanged && !_refreshing) {\n toggleState = clipped && !prevProgress ? 0 : clipped === 1 ? 1 : prevProgress === 1 ? 2 : 3; // 0 = enter, 1 = leave, 2 = enterBack, 3 = leaveBack (we prioritize the FIRST encounter, thus if you scroll really fast past the onEnter and onLeave in one tick, it'd prioritize onEnter.\n\n if (isToggle) {\n action = !toggled && toggleActions[toggleState + 1] !== \"none\" && toggleActions[toggleState + 1] || toggleActions[toggleState]; // if it didn't toggle, that means it shot right past and since we prioritize the \"enter\" action, we should switch to the \"leave\" in this case (but only if one is defined)\n\n isTakingAction = animation && (action === \"complete\" || action === \"reset\" || action in animation);\n }\n }\n\n preventOverlaps && (toggled || isTakingAction) && (isTakingAction || scrub || !animation) && (_isFunction(preventOverlaps) ? preventOverlaps(self) : self.getTrailing(preventOverlaps).forEac
1130h(function (t) {\n return t.endAnimation();\n }));\n\n if (!isToggle) {\n if (scrubTween && !_refreshing && !_startup) {\n scrubTween._dp._time - scrubTween._start !== scrubTween._time && scrubTween.render(scrubTween._dp._time - scrubTween._start); // if there's a scrub on both the container animation and this one (or a ScrollSmoother), the update order would cause this one not to have rendered yet, so it wouldn't make any progress before we .restart() it heading toward the new progress so it'd appear stuck thus we force a render here.\n\n if (scrubTween.resetTo) {\n scrubTween.resetTo(\"totalProgress\", clipped, animation._tTime / animation._tDur);\n } else {\n // legacy support (courtesy), before 3.10.0\n scrubTween.vars.totalProgress = clipped;\n scrubTween.invalidate().restart();\n }\n } else if (animation) {\n animation.totalProgress(clipped, !!(_refreshing && (lastRefresh || reset)));\n }\n }\n\n if (pin) {\n reset && pinSpacing && (spacer.style[pinSpacing + direction.os2] = spacingStart);\n\n if (!useFixedPosition) {\n pinSetter(_round(pinStart + pinChange * clipped));\n } else if (stateChanged) {\n isAtMax = !reset && clipped > prevProgress && end + 1 > scroll && scroll + 1 >= _maxScroll(scroller, direction); // if it's at the VERY end of the page, don't switch away from position: fixed because it's pointless and it could cause a brief flash when the user scrolls back up (when it gets pinned again)\n\n if (pinReparent) {\n if (!reset && (isActive || isAtMax)) {\n var bounds = _getBounds(pin, true),\n _offset = scroll - start;\n\n _reparent(pin, _body, bounds.top + (direction === _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical ? _offset : 0) + _px, bounds.left + (direction === _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical ? 0 : _offset) + _px);\n } else {\n _reparent(pin, spacer);\n }\n }\n\n _setState(isActive || isAtMax ? pinActiveState : pinState);\n\n pinMoves && clipped < 1 && isActive || pinSetter(pinStart + (clipped === 1 && !isAtMax ? pinChange : 0));\n }\n }\n\n snap && !tweenTo.tween && !_refreshing && !_startup && snapDelayedCall.restart(true);\n toggleClass && (toggled || once && clipped && (clipped < 1 || !_limitCallbacks)) && _toArray(toggleClass.targets).forEach(function (el) {\n return el.classList[isActive || once ? \"add\" : \"remove\"](toggleClass.className);\n }); // classes could affect positioning, so do it even if reset or refreshing is true.\n\n onUpdate && !isToggle && !reset && onUpdate(self);\n\n if (stateChanged && !_refreshing) {\n if (isToggle) {\n if (isTakingAction) {\n if (action === \"complete\") {\n animation.pause().totalProgress(1);\n } else if (action === \"reset\") {\n animation.restart(true).pause();\n } else if (action === \"restart\") {\n animation.restart(true);\n } else {\n animation[action]();\n }\n }\n\n onUpdate && onUpdate(self);\n }\n\n if (toggled || !_limitCallbacks) {\n // on startup, the page could be scrolled and we don't want to fire callbacks that didn't toggle. For example onEnter shouldn't fire if the ScrollTrigger isn't actually entered.\n onToggle && toggled && _callback(self, onToggle);\n callbacks[toggleState] && _callback(self, callbacks[toggleState]);\n once && (clipped === 1 ? self.kill(false, 1) : callbacks[toggleState] = 0); // a callback shouldn't be called again if once is true.\n\n if (!toggled) {\n // it's possible to go completely past, like from before the start to after the end (or vice-versa) in which case BOTH callbacks should be fired in that order\n toggleState = clipped === 1 ? 1 : 3;\n callbacks[toggleState] && _callback(self, callbacks[toggleState]);\n }\n }\n\n if (fastScrollEnd && !isActive && Math.abs(self.getVelocity()) > (_isNumber(fastScrollEnd) ? fastScrollEnd : 2500)) {\n _endAnimation(self.callbackA
1130nimation);\n\n scrubTween ? scrubTween.progress(1) : _endAnimation(animation, action === \"reverse\" ? 1 : !clipped, 1);\n }\n } else if (isToggle && onUpdate && !_refreshing) {\n onUpdate(self);\n }\n } // update absolutely-positioned markers (only if the scroller isn't the viewport)\n\n\n if (markerEndSetter) {\n var n = containerAnimation ? scroll / containerAnimation.duration() * (containerAnimation._caScrollDist || 0) : scroll;\n markerStartSetter(n + (markerStartTrigger._isFlipped ? 1 : 0));\n markerEndSetter(n);\n }\n\n caMarkerSetter && caMarkerSetter(-scroll / containerAnimation.duration() * (containerAnimation._caScrollDist || 0));\n };\n\n self.enable = function (reset, refresh) {\n if (!self.enabled) {\n self.enabled = true;\n\n _addListener(scroller, \"resize\", _onResize);\n\n isViewport || _addListener(scroller, \"scroll\", _onScroll);\n onRefreshInit && _addListener(ScrollTrigger, \"refreshInit\", onRefreshInit);\n\n if (reset !== false) {\n self.progress = prevProgress = 0;\n scroll1 = scroll2 = lastSnap = scrollFunc();\n }\n\n refresh !== false && self.refresh();\n }\n };\n\n self.getTween = function (snap) {\n return snap && tweenTo ? tweenTo.tween : scrubTween;\n };\n\n self.setPositions = function (newStart, newEnd, keepClamp, pinOffset) {\n // doesn't persist after refresh()! Intended to be a way to override values that were set during refresh(), like you could set it in onRefresh()\n if (containerAnimation) {\n // convert ratios into scroll positions. Remember, start/end values on ScrollTriggers that have a containerAnimation refer to the time (in seconds), NOT scroll positions.\n var st = containerAnimation.scrollTrigger,\n duration = containerAnimation.duration(),\n _change = st.end - st.start;\n\n newStart = st.start + _change * newStart / duration;\n newEnd = st.start + _change * newEnd / duration;\n }\n\n self.refresh(false, false, {\n start: _keepClamp(newStart, keepClamp && !!self._startClamp),\n end: _keepClamp(newEnd, keepClamp && !!self._endClamp)\n }, pinOffset);\n self.update();\n };\n\n self.adjustPinSpacing = function (amount) {\n if (spacerState && amount) {\n var i = spacerState.indexOf(direction.d) + 1;\n spacerState[i] = parseFloat(spacerState[i]) + amount + _px;\n spacerState[1] = parseFloat(spacerState[1]) + amount + _px;\n\n _setState(spacerState);\n }\n };\n\n self.disable = function (reset, allowAnimation) {\n reset !== false && self.revert(true, true);\n\n if (self.enabled) {\n self.enabled = self.isActive = false;\n allowAnimation || scrubTween && scrubTween.pause();\n prevScroll = 0;\n pinCache && (pinCache.uncache = 1);\n onRefreshInit && _removeListener(ScrollTrigger, \"refreshInit\", onRefreshInit);\n\n if (snapDelayedCall) {\n snapDelayedCall.pause();\n tweenTo.tween && tweenTo.tween.kill() && (tweenTo.tween = 0);\n }\n\n if (!isViewport) {\n var i = _triggers.length;\n\n while (i--) {\n if (_triggers[i].scroller === scroller && _triggers[i] !== self) {\n return; //don't remove the listeners if there are still other triggers referencing it.\n }\n }\n\n _removeListener(scroller, \"resize\", _onResize);\n\n isViewport || _removeListener(scroller, \"scroll\", _onScroll);\n }\n }\n };\n\n self.kill = function (revert, allowAnimation) {\n self.disable(revert, allowAnimation);\n scrubTween && !allowAnimation && scrubTween.kill();\n id && delete _ids[id];\n\n var i = _triggers.indexOf(self);\n\n i >= 0 && _triggers.splice(i, 1);\n i === _i && _direction > 0 && _i--; // if we're in the middle of a refresh() or update(), splicing would cause skips in the index, so adjust...\n // if no other ScrollTrigger instances of the same scroller are found, wipe out any re
1130corded scroll position. Otherwise, in a single page application, for example, it could maintain scroll position when it really shouldn't.\n\n i = 0;\n\n _triggers.forEach(function (t) {\n return t.scroller === self.scroller && (i = 1);\n });\n\n i || _refreshingAll || (self.scroll.rec = 0);\n\n if (animation) {\n animation.scrollTrigger = null;\n revert && animation.revert({\n kill: false\n });\n allowAnimation || animation.kill();\n }\n\n markerStart && [markerStart, markerEnd, markerStartTrigger, markerEndTrigger].forEach(function (m) {\n return m.parentNode && m.parentNode.removeChild(m);\n });\n _primary === self && (_primary = 0);\n\n if (pin) {\n pinCache && (pinCache.uncache = 1);\n i = 0;\n\n _triggers.forEach(function (t) {\n return t.pin === pin && i++;\n });\n\n i || (pinCache.spacer = 0); // if there aren't any more ScrollTriggers with the same pin, remove the spacer, otherwise it could be contaminated with old/stale values if the user re-creates a ScrollTrigger for the same element.\n }\n\n vars.onKill && vars.onKill(self);\n };\n\n _triggers.push(self);\n\n self.enable(false, false);\n customRevertReturn && customRevertReturn(self);\n\n if (animation && animation.add && !change) {\n // if the animation is a timeline, it may not have been populated yet, so it wouldn't render at the proper place on the first refresh(), thus we should schedule one for the next tick. If \"change\" is defined, we know it must be re-enabling, thus we can refresh() right away.\n var updateFunc = self.update; // some browsers may fire a scroll event BEFORE a tick elapses and/or the DOMContentLoaded fires. So there's a chance update() will be called BEFORE a refresh() has happened on a Timeline-attached ScrollTrigger which means the start/end won't be calculated yet. We don't want to add conditional logic inside the update() method (like check to see if end is defined and if not, force a refresh()) because that's a function that gets hit a LOT (performance). So we swap out the real update() method for this one that'll re-attach it the first time it gets called and of course forces a refresh().\n\n self.update = function () {\n self.update = updateFunc;\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.cache++; // otherwise a cached scroll position may get used in the refresh() in a very rare scenario, like if ScrollTriggers are created inside a DOMContentLoaded event and the queued requestAnimationFrame() fires beforehand. See https://gsap.com/community/forums/topic/41267-scrolltrigger-breaks-on-refresh-when-using-domcontentloaded/\n\n start || end || self.refresh();\n };\n\n gsap.delayedCall(0.01, self.update);\n change = 0.01;\n start = end = 0;\n } else {\n self.refresh();\n }\n\n pin && _queueRefreshAll(); // pinning could affect the positions of other things, so make sure we queue a full refresh()\n };\n\n ScrollTrigger.register = function register(core) {\n if (!_coreInitted) {\n gsap = core || _getGSAP();\n _windowExists() && window.document && ScrollTrigger.enable();\n _coreInitted = _enabled;\n }\n\n return _coreInitted;\n };\n\n ScrollTrigger.defaults = function defaults(config) {\n if (config) {\n for (var p in config) {\n _defaults[p] = config[p];\n }\n }\n\n return _defaults;\n };\n\n ScrollTrigger.disable = function disable(reset, kill) {\n _enabled = 0;\n\n _triggers.forEach(function (trigger) {\n return trigger[kill ? \"kill\" : \"disable\"](reset);\n });\n\n _removeListener(_win, \"wheel\", _onScroll);\n\n _removeListener(_doc, \"scroll\", _onScroll);\n\n clearInterval(_syncInterval);\n\n _removeListener(_doc, \"touchcancel\", _passThrough);\n\n _removeListener(_body, \"touchstart\", _passThrough);\n\n _multiListener(_removeListener, _doc, \"pointerdown,touchstart,mousedown\", _pointerDownHandler);\n\n _multiListener(_removeListener, _doc, \"pointerup,touchend,mouseup\", _pointerUpHandler);\n\n _resizeDelay.kill();\n\n _iterateAutoRefresh(_removeListener);\n\n for (var i = 0; i < _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.length; i += 3) {\n _wheelListener(_removeListener, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers[i], _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers[i + 1]);\n\n _wheelListener(_removeListener, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers[i], _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers[i + 2]);\n }\n };\n\n ScrollTrigger.enable = function enable() {\n _win = window;\n _doc = document;\n _docEl = _doc.documentElement;\n _body = _doc.body;\n\n if (gsap) {\n _toArray = gsap.utils.toArray;\n _clamp = gsap.utils.clamp;\n _context = gsap.core.context || _passThrough;\n _suppressOverwrites = gsap.core.suppressOverwrites || _passThrough;\n _scrollRestoration = _win.history.scrollRestoration || \"auto\";\n _lastScroll = _win.pageYOffset || 0;\n gsap.core.globals(\"ScrollTrigger\", ScrollTrigger); // must register the global manually because in Internet Explorer, functions (classes) don't have a \"name\" property.\n\n if (_body) {\
1130n _enabled = 1;\n _div100vh = document.createElement(\"div\"); // to solve mobile browser address bar show/hide resizing, we shouldn't rely on window.innerHeight. Instead, use a <div> with its height set to 100vh and measure that since that's what the scrolling is based on anyway and it's not affected by address bar showing/hiding.\n\n _div100vh.style.height = \"100vh\";\n _div100vh.style.position = \"absolute\";\n\n _refresh100vh();\n\n _rafBugFix();\n\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer.register(gsap); // isTouch is 0 if no touch, 1 if ONLY touch, and 2 if it can accommodate touch but also other types like mouse/pointer.\n\n ScrollTrigger.isTouch = _Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer.isTouch;\n _fixIOSBug = _Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer.isTouch && /(iPad|iPhone|iPod|Mac)/g.test(navigator.userAgent); // since 2017, iOS has had a bug that causes event.clientX/Y to be inaccurate when a scroll occurs, thus we must alternate ignoring every other touchmove event to work around it. See https://bugs.webkit.org/show_bug.cgi?id=181954 and https://codepen.io/GreenSock/pen/ExbrPNa/087cef197dc35445a0951e8935c41503\n\n _ignoreMobileResize = _Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer.isTouch === 1;\n\n _addListener(_win, \"wheel\", _onScroll); // mostly for 3rd party smooth scrolling libraries.\n\n\n _root = [_win, _doc, _docEl, _body];\n\n if (gsap.matchMedia) {\n ScrollTrigger.matchMedia = function (vars) {\n var mm = gsap.matchMedia(),\n p;\n\n for (p in vars) {\n mm.add(p, vars[p]);\n }\n\n return mm;\n };\n\n gsap.addEventListener(\"matchMediaInit\", function () {\n _recordScrollPositions();\n\n _revertAll();\n });\n gsap.addEventListener(\"matchMediaRevert\", function () {\n return _revertRecorded();\n });\n gsap.addEventListener(\"matchMedia\", function () {\n _refreshAll(0, 1);\n\n _dispatch(\"matchMedia\");\n });\n gsap.matchMedia().add(\"(orientation: portrait)\", function () {\n // when orientation changes, we should take new base measurements for the ignoreMobileResize feature.\n _setBaseDimensions();\n\n return _setBaseDimensions;\n });\n } else {\n console.warn(\"Requires GSAP 3.11.0 or later\");\n }\n\n _setBaseDimensions();\n\n _addListener(_doc, \"scroll\", _onScroll); // some browsers (like Chrome), the window stops dispatching scroll events on the window if you scroll really fast, but it's consistent on the document!\n\n\n var bodyHasStyle = _body.hasAttribute(\"style\"),\n bodyStyle = _body.style,\n border = bodyStyle.borderTopStyle,\n AnimationProto = gsap.core.Animation.prototype,\n bounds,\n i;\n\n AnimationProto.revert || Object.defineProperty(AnimationProto, \"revert\", {\n value: function value() {\n return this.time(-0.01, true);\n }\n }); // only for backwards compatibility (Animation.revert() was added after 3.10.4)\n\n bodyStyle.borderTopStyle = \"solid\"; // works around an issue where a margin of a child element could throw off the bounds of the _body, making it seem like there's a margin when there actually isn't. The border ensures that the bounds are accurate.\n\n bounds = _getBounds(_body);\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical.m = Math.round(bounds.top + _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical.sc()) || 0; // accommodate the offset of the <body> caused by margins and/or padding\n\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal.m = Math.round(bounds.left + _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal.sc()) || 0;\n border ? bodyStyle.borderTopStyle = border : bodyStyle.removeProperty(\"border-top-style\");\n\n if (!bodyHasStyle) {\n // SSR frameworks like Next.js complain if this attribute gets added.\n _body.setAttribute(\"style\", \"\"); // it's not enough to just removeAttribute() - we must first set it to empty, otherwise Next.js complains.\n\n\n _body.removeAttribute(\"style\");\n } // TODO: (?) maybe move to leveraging the velocity mechanism in Observer and skip intervals.\n\n\n _syncInterval = setInterval(_sync, 250);\n gsap.delayedCall(0.5, function () {\n return _startup = 0;\n });\n\n _addListener(_doc, \"touchcancel\", _passThrough); // some older Android devices intermittently stop dispatching \"touchmove\" events if we don't listen for \"touchcancel\" on the document.\n\n\n _addListener(_body, \"touchstart\", _passThrough); //works around Safari bug: https://gsap.com/forums/topic/21450-draggable-in-iframe-on-mobile-is-buggy/\n\n\n _multiListener(_addListener, _doc, \"pointerdown,touchstart,mousedown\", _pointerDownHandler);\n\n _multiListener(_addListener, _doc, \"pointerup,touchend,mouseup\", _pointerUpHandler);\n\n _transformProp = gsap.utils.checkPrefix(\"transform\");\n\n _stateProps.push(_transformProp);\n\n _coreInitted = _getTime();\n _resizeDelay = gsap.delayedCall(0.2, _refreshAll).pause();\n _autoRefresh = [_doc, \"visibilitychange\", function () {\n var w = _win.innerWidth,\n h = _win.innerHeight;\n\n if (_doc.hidden) {\n _prevWidth = w;\n _prevHeight = h;\n }
1130 else if (_prevWidth !== w || _prevHeight !== h) {\n _onResize();\n }\n }, _doc, \"DOMContentLoaded\", _refreshAll, _win, \"load\", _refreshAll, _win, \"resize\", _onResize];\n\n _iterateAutoRefresh(_addListener);\n\n _triggers.forEach(function (trigger) {\n return trigger.enable(0, 1);\n });\n\n for (i = 0; i < _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.length; i += 3) {\n _wheelListener(_removeListener, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers[i], _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers[i + 1]);\n\n _wheelListener(_removeListener, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers[i], _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers[i + 2]);\n }\n } else if (_doc) {\n var onLoad = function onLoad() {\n ScrollTrigger.enable();\n\n _doc.removeEventListener(\"DOMContentLoaded\", onLoad);\n };\n\n _doc.addEventListener(\"DOMContentLoaded\", onLoad);\n }\n }\n };\n\n ScrollTrigger.config = function config(vars) {\n \"limitCallbacks\" in vars && (_limitCallbacks = !!vars.limitCallbacks);\n var ms = vars.syncInterval;\n ms && clearInterval(_syncInterval) || (_syncInterval = ms) && setInterval(_sync, ms);\n \"ignoreMobileResize\" in vars && (_ignoreMobileResize = ScrollTrigger.isTouch === 1 && vars.ignoreMobileResize);\n\n if (\"autoRefreshEvents\" in vars) {\n _iterateAutoRefresh(_removeListener) || _iterateAutoRefresh(_addListener, vars.autoRefreshEvents || \"none\");\n _ignoreResize = (vars.autoRefreshEvents + \"\").indexOf(\"resize\") === -1;\n }\n };\n\n ScrollTrigger.scrollerProxy = function scrollerProxy(target, vars) {\n var t = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(target),\n i = _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.indexOf(t),\n isViewport = _isViewport(t);\n\n if (~i) {\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.splice(i, isViewport ? 6 : 2);\n }\n\n if (vars) {\n isViewport ? _Observer_js__WEBPACK_IMPORTED_MODULE_0__._proxies.unshift(_win, vars, _body, vars, _docEl, vars) : _Observer_js__WEBPACK_IMPORTED_MODULE_0__._proxies.unshift(t, vars);\n }\n };\n\n ScrollTrigger.clearMatchMedia = function clearMatchMedia(query) {\n _triggers.forEach(function (t) {\n return t._ctx && t._ctx.query === query && t._ctx.kill(true, true);\n });\n };\n\n ScrollTrigger.isInViewport = function isInViewport(element, ratio, horizontal) {\n var bounds = (_isString(element) ? (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(element) : element).getBoundingClientRect(),\n offset = bounds[horizontal ? _width : _height] * ratio || 0;\n return horizontal ? bounds.right - offset > 0 && bounds.left + offset < _win.innerWidth : bounds.bottom - offset > 0 && bounds.top + offset < _win.innerHeight;\n };\n\n ScrollTrigger.positionInViewport = function positionInViewport(element, referencePoint, horizontal) {\n _isString(element) && (element = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(element));\n var bounds = element.getBoundingClientRect(),\n size = bounds[horizontal ? _width : _height],\n offset = referencePoint == null ? size / 2 : referencePoint in _keywords ? _keywords[referencePoint] * size : ~referencePoint.indexOf(\"%\") ? parseFloat(referencePoint) * size / 100 : parseFloat(referencePoint) || 0;\n return horizontal ? (bounds.left + offset) / _win.innerWidth : (bounds.top + offset) / _win.innerHeight;\n };\n\n ScrollTrigger.killAll = function killAll(allowListeners) {\n _triggers.slice(0).forEach(function (t) {\n return t.vars.id !== \"ScrollSmoother\" && t.kill();\n });\n\n if (allowListeners !== true) {\n var listeners = _listeners.killAll || [];\n _listeners = {};\n listeners.forEach(function (f) {\n return f();\n });\n }\n };\n\n return ScrollTrigger;\n}();\nScrollTrigger.version = \"3.15.0\";\n\nScrollTrigger.saveStyles = function (targets) {\n return targets ? _toArray(targets).forEac
1130h(function (target) {\n // saved styles are recorded in a consecutive alternating Array, like [element, cssText, transform attribute, cache, matchMedia, ...]\n if (target && target.style) {\n var i = _savedStyles.indexOf(target);\n\n i >= 0 && _savedStyles.splice(i, 5);\n\n _savedStyles.push(target, target.style.cssText, target.getBBox && target.getAttribute(\"transform\"), gsap.core.getCache(target), _context());\n }\n }) : _savedStyles;\n};\n\nScrollTrigger.revert = function (soft, media) {\n return _revertAll(!soft, media);\n};\n\nScrollTrigger.create = function (vars, animation) {\n return new ScrollTrigger(vars, animation);\n};\n\nScrollTrigger.refresh = function (safe) {\n return safe ? _onResize(true) : (_coreInitted || ScrollTrigger.register()) && _refreshAll(true);\n};\n\nScrollTrigger.update = function (force) {\n return ++_Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.cache && _updateAll(force === true ? 2 : 0);\n};\n\nScrollTrigger.clearScrollMemory = _clearScrollMemory;\n\nScrollTrigger.maxScroll = function (element, horizontal) {\n return _maxScroll(element, horizontal ? _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal : _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical);\n};\n\nScrollTrigger.getScrollFunc = function (element, horizontal) {\n return (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getScrollFunc)((0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(element), horizontal ? _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal : _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical);\n};\n\nScrollTrigger.getById = function (id) {\n return _ids[id];\n};\n\nScrollTrigger.getAll = function () {\n return _triggers.filter(function (t) {\n return t.vars.id !== \"ScrollSmoother\";\n });\n}; // it's common for people to ScrollTrigger.getAll(t => t.kill()) on page routes, for example, and we don't want it to ruin smooth scrolling by killing the main ScrollSmoother one.\n\n\nScrollTrigger.isScrolling = function () {\n return !!_lastScrollTime;\n};\n\nScrollTrigger.snapDirectional = _snapDirectional;\n\nScrollTrigger.addEventListener = function (type, callback) {\n var a = _listeners[type] || (_listeners[type] = []);\n ~a.indexOf(callback) || a.push(callback);\n};\n\nScrollTrigger.removeEventListener = function (type, callback) {\n var a = _listeners[type],\n i = a && a.indexOf(callback);\n i >= 0 && a.splice(i, 1);\n};\n\nScrollTrigger.batch = function (targets, vars) {\n var result = [],\n varsCopy = {},\n interval = vars.interval || 0.016,\n batchMax = vars.batchMax || 1e9,\n proxyCallback = function proxyCallback(type, callback) {\n var elements = [],\n triggers = [],\n delay = gsap.delayedCall(interval, function () {\n callback(elements, triggers);\n elements = [];\n triggers = [];\n }).pause();\n return function (self) {\n elements.length || delay.restart(true);\n elements.push(self.trigger);\n triggers.push(self);\n batchMax <= elements.length && delay.progress(1);\n };\n },\n p;\n\n for (p in vars) {\n varsCopy[p] = p.substr(0, 2) === \"on\" && _isFunction(vars[p]) && p !== \"onRefreshInit\" ? proxyCallback(p, vars[p]) : vars[p];\n }\n\n if (_isFunction(batchMax)) {\n batchMax = batchMax();\n\n _addListener(ScrollTrigger, \"refresh\", function () {\n return batchMax = vars.batchMax();\n });\n }\n\n _toArray(targets).forEach(function (target) {\n var config = {};\n\n for (p in varsCopy) {\n config[p] = varsCopy[p];\n }\n\n config.trigger = target;\n result.push(ScrollTrigger.create(config));\n });\n\n return result;\n}; // to reduce file size. clamps the scroll and also returns a duration multiplier so that if the scroll gets chopped shorter, the duration gets curtailed as well (otherwise if you're very close to the top of the page, for example, and swipe up really fast, it'll suddenly slow down and take a long time to reach the top).\n\n\nvar _clampScrollAndGetDurationMultiplier = function _clampScrollAndGetDurationMultiplier(scrollFunc, current, end, max) {\n current > max ? scrollFunc(max) : current < 0 && scrollFunc(0);\n return end > max ? (max - current) / (end - current) : end < 0 ? current / (current - end) : 1;\n},\n _allowNativePanning = function _allowNativePanning(target, direction) {\n if (direction === true) {\n target.style.removeProperty(\"touch-action\");\n } else {\n target.style.touchAction = direction === true ? \"auto\" : direction ? \"pan-\" + direction + (_Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer.isTouch ? \" pinch-zoom\" : \"\") : \"none\"; // note: Firefox doesn't support it pinch-zoom properly, at least in addition to a pan-x or pan-y.\n }\n\n target === _docEl && _allowNativePanning(_body, direction);\n},\n _overflow = {\n auto: 1,\n scroll: 1\n},\n _nestedScroll = function _nestedScroll(_ref5) {\n var event = _ref5.event,\n target = _ref5.target,\n axis = _ref5.axis;\n\n var node = (event.changedTouches ? event.changedTouches[0] : event).target,\n cache = node._gsap || gsap.core.getCache(node),\n time = _getTime(),\n cs;\n\n if (!cache._isScrollT || time - cache._isScrollT > 2000) {\n // cache for 2 seconds to improve performance.\n while (node && node !== _body && (node.scrollHeight <= node.clientHeight && node.scrollWidth <= node.clientWidth || !(_overflow[(cs = _getComputedStyle(node)).overflowY] || _overflow[cs.overflowX]))) {\n node = node.parentNode;\n }\n\n cache._isScroll = node && node !== target && !_isViewport(node) && (_overflow[(cs = _getComputedStyle(node)).overflowY] || _overflow[cs.overflowX]);\n cache._isScrollT = time;\n }\n\n if (cache._isScroll || axis === \"x\") {\n event.stopPropagation();\n event._gsapAllow = true;\n }\n},\n // capture events on scrollable elements INSIDE the <body> and allow those by calling stopPropagation() when we find a scrollable ancestor\n_inputObserver = function _inputObserver(target, type, inputs, nested) {\n return _Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer.create({\n target: target,\n capture: true,\n debounce: false,\n lockAxis: true,\n type: type,\n onWheel: nested = nested && _nestedScroll,\n onPress: nested,\n onDrag: nested,\n onScroll: nested,\n onEnable: function onEnable() {\n return input
1130s && _addListener(_doc, _Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer.eventTypes[0], _captureInputs, false, true);\n },\n onDisable: function onDisable() {\n return _removeListener(_doc, _Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer.eventTypes[0], _captureInputs, true);\n }\n });\n},\n _inputExp = /(input|label|select|textarea)/i,\n _inputIsFocused,\n _captureInputs = function _captureInputs(e) {\n var isInput = _inputExp.test(e.target.tagName);\n\n if (isInput || _inputIsFocused) {\n e._gsapAllow = true;\n _inputIsFocused = isInput;\n }\n},\n _getScrollNormalizer = function _getScrollNormalizer(vars) {\n _isObject(vars) || (vars = {});\n vars.preventDefault = vars.isNormalizer = vars.allowClicks = true;\n vars.type || (vars.type = \"wheel,touch\");\n vars.debounce = !!vars.debounce;\n vars.id = vars.id || \"normalizer\";\n\n var _vars2 = vars,\n normalizeScrollX = _vars2.normalizeScrollX,\n momentum = _vars2.momentum,\n allowNestedScroll = _vars2.allowNestedScroll,\n onRelease = _vars2.onRelease,\n self,\n maxY,\n target = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(vars.target) || _docEl,\n smoother = gsap.core.globals().ScrollSmoother,\n smootherInstance = smoother && smoother.get(),\n content = _fixIOSBug && (vars.content && (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getTarget)(vars.content) || smootherInstance && vars.content !== false && !smootherInstance.smooth() && smootherInstance.content()),\n scrollFuncY = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getScrollFunc)(target, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical),\n scrollFuncX = (0,_Observer_js__WEBPACK_IMPORTED_MODULE_0__._getScrollFunc)(target, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal),\n scale = 1,\n initialScale = (_Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer.isTouch && _win.visualViewport ? _win.visualViewport.scale * _win.visualViewport.width : _win.outerWidth) / _win.innerWidth,\n wheelRefresh = 0,\n resolveMomentumDuration = _isFunction(momentum) ? function () {\n return momentum(self);\n } : function () {\n return momentum || 2.8;\n },\n lastRefreshID,\n skipTouchMove,\n inputObserver = _inputObserver(target, vars.type, true, allowNestedScroll),\n resumeTouchMove = function resumeTouchMove() {\n return skipTouchMove = false;\n },\n scrollClampX = _passThrough,\n scrollClampY = _passThrough,\n updateClamps = function updateClamps() {\n maxY = _maxScroll(target, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical);\n scrollClampY = _clamp(_fixIOSBug ? 1 : 0, maxY);\n normalizeScrollX && (scrollClampX = _clamp(0, _maxScroll(target, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal)));\n lastRefreshID = _refreshID;\n },\n removeContentOffset = function removeContentOffset() {\n content._gsap.y = _round(parseFloat(content._gsap.y) + scrollFuncY.offset) + \"px\";\n content.style.transform = \"matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, \" + parseFloat(content._gsap.y) + \", 0, 1)\";\n scrollFuncY.offset = scrollFuncY.cacheID = 0;\n },\n ignoreDrag = function ignoreDrag() {\n if (skipTouchMove) {\n requestAnimationFrame(resumeTouchMove);\n\n var offset = _round(self.deltaY / 2),\n scroll = scrollClampY(scrollFuncY.v - offset);\n\n if (content && scroll !== scrollFuncY.v + scrollFuncY.offset) {\n scrollFuncY.offset = scroll - scrollFuncY.v;\n\n var y = _round((parseFloat(content && content._gsap.y) || 0) - scrollFuncY.offset);\n\n content.style.transform = \"matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, \" + y + \", 0, 1)\";\n content._gsap.y = y + \"px\";\n scrollFuncY.cacheID = _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.cache;\n\n _updateAll();\n }\n\n return true;\n }\n\n scrollFuncY.offset && removeContentOffset();\n skipTouchMove = true;\n },\n tween,\n startScrollX,\n startScrollY,\n onStopDelayedCall,\n onResize = function onResize() {\n // if the window resizes, like on an iPhone which Apple FORCES the address bar to show/hide even if we event.preventDefault(), it may be scrolling too far now that the address bar is showing, so we must dynamically adjust the momentum tween.\n updateClamps();\n\n if (tween.isActive() && tween.vars.scrollY > maxY) {\n scrollFuncY() > maxY ? tween.progress(1) && scrollFuncY(maxY) : tween.resetTo(\"scrollY\", maxY);\n }\n };\n\n content && gsap.set(content, {\n y: \"+=0\"\n }); // to ensure there's a cache (element._gsap)\n\n vars.ignoreCheck = function (e) {\n return _fixIOSBug && e.type === \"touchmove\" && ignoreDrag(e) || scale > 1.05 && e.type !== \"touchstart\" || self.isGesturing || e.touches && e.touches.length > 1;\n };\n\n vars.onPress = function () {\n skipTouchMove = false;\n var prevScale = scale;
1130\n scale = _round((_win.visualViewport && _win.visualViewport.scale || 1) / initialScale);\n tween.pause();\n prevScale !== scale && _allowNativePanning(target, scale > 1.01 ? true : normalizeScrollX ? false : \"x\");\n startScrollX = scrollFuncX();\n startScrollY = scrollFuncY();\n updateClamps();\n lastRefreshID = _refreshID;\n };\n\n vars.onRelease = vars.onGestureStart = function (self, wasDragging) {\n scrollFuncY.offset && removeContentOffset();\n\n if (!wasDragging) {\n onStopDelayedCall.restart(true);\n } else {\n _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers.cache++; // make sure we're pulling the non-cached value\n // alternate algorithm: durX = Math.min(6, Math.abs(self.velocityX / 800)),\tdur = Math.max(durX, Math.min(6, Math.abs(self.velocityY / 800))); dur = dur * (0.4 + (1 - _power4In(dur / 6)) * 0.6)) * (momentumSpeed || 1)\n\n var dur = resolveMomentumDuration(),\n currentScroll,\n endScroll;\n\n if (normalizeScrollX) {\n currentScroll = scrollFuncX();\n endScroll = currentScroll + dur * 0.05 * -self.velocityX / 0.227; // the constant .227 is from power4(0.05). velocity is inverted because scrolling goes in the opposite direction.\n\n dur *= _clampScrollAndGetDurationMultiplier(scrollFuncX, currentScroll, endScroll, _maxScroll(target, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._horizontal));\n tween.vars.scrollX = scrollClampX(endScroll);\n }\n\n currentScroll = scrollFuncY();\n endScroll = currentScroll + dur * 0.05 * -self.velocityY / 0.227; // the constant .227 is from power4(0.05)\n\n dur *= _clampScrollAndGetDurationMultiplier(scrollFuncY, currentScroll, endScroll, _maxScroll(target, _Observer_js__WEBPACK_IMPORTED_MODULE_0__._vertical));\n tween.vars.scrollY = scrollClampY(endScroll);\n tween.invalidate().duration(dur).play(0.01);\n\n if (_fixIOSBug && tween.vars.scrollY >= maxY || currentScroll >= maxY - 1) {\n // iOS bug: it'll show the address bar but NOT fire the window \"resize\" event until the animation is done but we must protect against overshoot so we leverage an onUpdate to do so.\n gsap.to({}, {\n onUpdate: onResize,\n duration: dur\n });\n }\n }\n\n onRelease && onRelease(self);\n };\n\n vars.onWheel = function () {\n tween._ts && tween.pause();\n\n if (_getTime() - wheelRefresh > 1000) {\n // after 1 second, refresh the clamps otherwise that'll only happen when ScrollTrigger.refresh() is called or for touch-scrolling.\n lastRefreshID = 0;\n wheelRefresh = _getTime();\n }\n };\n\n vars.onChange = function (self, dx, dy, xArray, yArray) {\n _refreshID !== lastRefreshID && updateClamps();\n dx && normalizeScrollX && scrollFuncX(scrollClampX(xArray[2] === dx ? startScrollX + (self.startX - self.x) : scrollFuncX() + dx - xArray[1])); // for more precision, we track pointer/touch movement from the start, otherwise it'll drift.\n\n if (dy) {\n scrollFuncY.offset && removeContentOffset();\n var isTouch = yArray[2] === dy,\n y = isTouch ? startScrollY + self.startY - self.y : scrollFuncY() + dy - yArray[1],\n yClamped = scrollClampY(y);\n isTouch && y !== yClamped && (startScrollY += yClamped - y);\n scrollFuncY(yClamped);\n }\n\n (dy || dx) && _updateAll();\n };\n\n vars.onEnable = function () {\n _allowNativePanning(target, normalizeScrollX ? false : \"x\");\n\n ScrollTrigger.addEventListener(\"refresh\", onResize);\n\n _addListener(_win, \"resize\", onResize);\n\n if (scrollFuncY.smooth) {\n scrollFuncY.target.style.scrollBehavior = \"auto\";\n scrollFuncY.smooth = scrollFuncX.smooth = false;\n }\n\n inputObserver.enable();\n };\n\n vars.onDisable = function () {\n _allowNativePanning(target, true);\n\n _removeListener(_win, \"resize\", onResize);\n\n ScrollTrigger.removeEventListener(\"refresh\", onResize);\n inputObserver.kill();\n };\n\n vars.lockAxis = vars.lockAxis !== false;\n self = new _Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer(vars);\n self.iOS = _fixIOSBug; // used in the Observer getCachedScroll() function to work around an iOS bug that wreaks havoc with TouchEvent.clientY if we allow scroll to go all the way back to 0.\n\n _fixIOSBug && !scrollFuncY() && scrollFuncY(1); // iOS bug causes event.clientY values to freak out (wildly inaccurate) if the scroll position is exactly 0.\n\n _fixIOSBug && gsap.ticker.add(_passThrough); // prevent the ticker from sleeping\n\n onStopDelayedCall = self._dc;\n tween = gsap.to(self, {\n ease: \"power4\",\n paused: true,\n inherit: false,\n scrollX: normalizeScrollX ? \"+=0.1\" : \"+=0\",\n scrollY: \"+=0.1\",\n modifiers: {\n scrollY: _interruptionTracker(scrollFuncY, scrollFuncY(), function () {\n return tween.pause();\n })\n },\n onUpdate: _updateAll,\n onComplete: onStopDelayedCall.vars.onComplete\n }); // we need the modifier to sense if the scroll position is altered outside of the momentum tween (like with a scrollTo tween) so we can pause() it to prevent conflicts.\n\n return self;\n};\n\nScrollTrigger.sort = function (func) {\n if (_isFunction(func)) {\n return _triggers.sort(func);\n }\n\n var scroll = _win.pageYOffset || 0;
1130\n ScrollTrigger.getAll().forEach(function (t) {\n return t._sortY = t.trigger ? scroll + t.trigger.getBoundingClientRect().top : t.start + _win.innerHeight;\n });\n return _triggers.sort(func || function (a, b) {\n return (a.vars.refreshPriority || 0) * -1e6 + (a.vars.containerAnimation ? 1e6 : a._sortY) - ((b.vars.containerAnimation ? 1e6 : b._sortY) + (b.vars.refreshPriority || 0) * -1e6);\n }); // anything with a containerAnimation should refresh last.\n};\n\nScrollTrigger.observe = function (vars) {\n return new _Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer(vars);\n};\n\nScrollTrigger.normalizeScroll = function (vars) {\n if (typeof vars === \"undefined\") {\n return _normalizer;\n }\n\n if (vars === true && _normalizer) {\n return _normalizer.enable();\n }\n\n if (vars === false) {\n _normalizer && _normalizer.kill();\n _normalizer = vars;\n return;\n }\n\n var normalizer = vars instanceof _Observer_js__WEBPACK_IMPORTED_MODULE_0__.Observer ? vars : _getScrollNormalizer(vars);\n _normalizer && _normalizer.target === normalizer.target && _normalizer.kill();\n _isViewport(normalizer.target) && (_normalizer = normalizer);\n return normalizer;\n};\n\nScrollTrigger.core = {\n // smaller file size way to leverage in ScrollSmoother and Observer\n _getVelocityProp: _Observer_js__WEBPACK_IMPORTED_MODULE_0__._getVelocityProp,\n _inputObserver: _inputObserver,\n _scrollers: _Observer_js__WEBPACK_IMPORTED_MODULE_0__._scrollers,\n _proxies: _Observer_js__WEBPACK_IMPORTED_MODULE_0__._proxies,\n bridge: {\n // when normalizeScroll sets the scroll position (ss = setScroll)\n ss: function ss() {\n _lastScrollTime || _dispatch(\"scrollStart\");\n _lastScrollTime = _getTime();\n },\n // a way to get the _refreshing value in Observer\n ref: function ref() {\n return _refreshing;\n }\n }\n};\n_getGSAP() && gsap.registerPlugin(ScrollTrigger);\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/gsap/ScrollTrigger.js?\n}"); 1131 1132/***/ }, 1133 1134/***/ "./node_modules/gsap/gsap-core.js" 1135/*!****************************************!*\ 1136 !*** ./node_modules/gsap/gsap-core.js ***! 1137 \****************************************/ 1138(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1139 1140"use strict"; 1141eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Animation: () => (/* binding */ Animation),\n/* harmony export */ Back: () => (/* binding */ Back),\n/* harmony export */ Bounce: () => (/* binding */ Bounce),\n/* harmony export */ Circ: () => (/* binding */ Circ),\n/* harmony export */ Cubic: () => (/* binding */ Cubic),\n/* harmony export */ Elastic: () => (/* binding */ Elastic),\n/* harmony export */ Expo: () => (/* binding */ Expo),\n/* harmony export */ GSCache: () => (/* binding */ GSCache),\n/* harmony export */ Linear: () => (/* binding */ Linear),\n/* harmony export */ Power0: () => (/* binding */ Power0),\n/* harmony export */ Power1: () => (/* binding */ Power1),\n/* harmony export */ Power2: () => (/* binding */ Power2),\n/* harmony export */ Power3: () => (/* binding */ Power3),\n/* harmony export */ Power4: () => (/* binding */ Power4),\n/* harmony export */ PropTween: () => (/* binding */ PropTween),\n/* harmony export */ Quad: () => (/* binding */ Quad),\n/* harmony export */ Quart: () => (/* binding */ Quart),\n/* harmony export */ Quint: () => (/* binding */ Quint),\n/* harmony export */ Sine: () => (/* binding */ Sine),\n/* harmony export */ SteppedEase: () => (/* binding */ SteppedEase),\n/* harmony export */ Strong: () => (/* binding */ Strong),\n/* harmony export */ Timeline: () => (/* binding */ Timeline),\n/* harmony export */ TimelineLite: () => (/* binding */ Timeline),\n/* harmony export */ TimelineMax: () => (/* binding */ Timeline),\n/* harmony export */ Tween: () => (/* binding */ Tween),\n/* harmony export */ TweenLite: () => (/* binding */ Tween),\n/* harmony export */ TweenMax: () =>
1141 (/* binding */ Tween),\n/* harmony export */ _checkPlugin: () => (/* binding */ _checkPlugin),\n/* harmony export */ _colorExp: () => (/* binding */ _colorExp),\n/* harmony export */ _colorStringFilter: () => (/* binding */ _colorStringFilter),\n/* harmony export */ _config: () => (/* binding */ _config),\n/* harmony export */ _forEachName: () => (/* binding */ _forEachName),\n/* harmony export */ _getCache: () => (/* binding */ _getCache),\n/* harmony export */ _getProperty: () => (/* binding */ _getProperty),\n/* harmony export */ _getSetter: () => (/* binding */ _getSetter),\n/* harmony export */ _isString: () => (/* binding */ _isString),\n/* harmony export */ _isUndefined: () => (/* binding */ _isUndefined),\n/* harmony export */ _missingPlugin: () => (/* binding */ _missingPlugin),\n/* harmony export */ _numExp: () => (/* binding */ _numExp),\n/* harmony export */ _numWithUnitExp: () => (/* binding */ _numWithUnitExp),\n/* harmony export */ _parseRelative: () => (/* binding */ _parseRelative),\n/* harmony export */ _plugins: () => (/* binding */ _plugins),\n/* harmony export */ _relExp: () => (/* binding */ _relExp),\n/* harmony export */ _removeLinkedListItem: () => (/* binding */ _removeLinkedListItem),\n/* harmony export */ _renderComplexString: () => (/* binding */ _renderComplexString),\n/* harmony export */ _replaceRandom: () => (/* binding */ _replaceRandom),\n/* harmony export */ _round: () => (/* binding */ _round),\n/* harmony export */ _roundModifier: () => (/* binding */ _roundModifier),\n/* harmony export */ _setDefaults: () => (/* binding */ _setDefaults),\n/* harmony export */ _sortPropTweensByPriority: () => (/* binding */ _sortPropTweensByPriority),\n/* harmony export */ _ticker: () => (/* binding */ _ticker),\n/* harmony export */ clamp: () => (/* binding */ clamp),\n/* harmony export */ \"default\": () => (/* binding */ gsap),\n/* harmony export */ distribute: () => (/* binding */ distribute),\n/* harmony export */ getUnit: () => (/* binding */ getUnit),\n/* harmony export */ gsap: () => (/* binding */ gsap),\n/* harmony export */ interpolate: () => (/* binding */ interpolate),\n/* harmony export */ mapRange: () => (/* binding */ mapRange),\n/* harmony export */ normalize: () => (/* binding */ normalize),\n/* harmony export */ pipe: () => (/* binding */ pipe),\n/* harmony export */ random: () => (/* binding */ random),\n/* harmony export */ selector: () => (/* binding */ selector),\n/* harmony export */ shuffle: () => (/* binding */ shuffle),\n/* harmony export */ snap: () => (/* binding */ snap),\n/* harmony export */ splitColor: () => (/* binding */ splitColor),\n/* harmony export */ toArray: () => (/* binding */ toArray),\n/* harmony export */ unitize: () => (/* binding */ unitize),\n/* harmony export */ wrap: () => (/* binding */ wrap),\n/* harmony export */ wrapYoyo: () => (/* binding */ wrapYoyo)\n/* harmony export */ });\nfunction _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return self; }\n\nfunction _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }\n\n/*!\n * GSAP 3.15.0\n * https://gsap.com\n *\n * @license Copyright 2008-2026, GreenSock. All rights reserved.\n * Subject to the terms at https://gsap.com/standard-license\n * @author: Jack Doyle, [email protected]\n*/\n\n/* eslint-disable */\nvar _config = {\n autoSleep: 120,\n force3D: \"auto\",\n nullTargetWarn: 1,\n units: {\n lineHeight: \"\"\n }\n},\n _defaults = {\n duration: .5,\n overwrite: false,\n delay: 0\n},\n _suppressOverwrites,\n _reverting,\n _context,\n _bigNum = 1e8,\n _tinyNum = 1 / _bigNum,\n _2PI = Math.PI * 2,\n _HALF_PI = _2PI / 4,\n _gsID = 0,\n _sqrt = Math.sqrt,\n _cos = Math.cos,\n _sin = Math.sin,\n _isString = function _isString(value) {\n return typeof value === \"string\";\n},\n _isFunction = function _isFunction(value) {\n return typeof value === \"function\";\n},\n _isNumber = function _isNumber(value) {\n return typeof value === \"number\";\n},\n _isUndefined = function _isUndefined(value) {\n return typeof value === \"undefined\";\n},\n _isObject = function _isObject(value) {\n return typeof value === \"object\";\n},\n _isNotFalse = function _isNotFalse(value) {\n return value !== false;\n},\n _windowExists = function _windowExists() {\n return typeof window !== \"undefined\";\n},\n _isFuncOrString = function _isFuncOrString(value) {\n return _isFunction(value) || _isString(value);\n},\n _isTypedArray = typeof ArrayBuffer === \"function\" && ArrayBuffer.isView || function () {},\n // note: IE10 has ArrayBuffer, but NOT ArrayBuffer.isView().\
1141n_isArray = Array.isArray,\n _randomExp = /random\\([^)]+\\)/g,\n _commaDelimExp = /,\\s*/g,\n _strictNumExp = /(?:-?\\.?\\d|\\.)+/gi,\n //only numbers (including negatives and decimals) but NOT relative values.\n_numExp = /[-+=.]*\\d+[.e\\-+]*\\d*[e\\-+]*\\d*/g,\n //finds any numbers, including ones that start with += or -=, negative numbers, and ones in scientific notation like 1e-8.\n_numWithUnitExp = /[-+=.]*\\d+[.e-]*\\d*[a-z%]*/g,\n _complexStringNumExp = /[-+=.]*\\d+\\.?\\d*(?:e-|e\\+)?\\d*/gi,\n //duplicate so that while we're looping through matches from exec(), it doesn't contaminate the lastIndex of _numExp which we use to search for colors too.\n_relExp = /[+-]=-?[.\\d]+/,\n _delimitedValueExp = /[^,'\"\\[\\]\\s]+/gi,\n // previously /[#\\-+.]*\\b[a-z\\d\\-=+%.]+/gi but didn't catch special characters.\n_unitExp = /^[+\\-=e\\s\\d]*\\d+[.\\d]*([a-z]*|%)\\s*$/i,\n _globalTimeline,\n _win,\n _coreInitted,\n _doc,\n _globals = {},\n _installScope = {},\n _coreReady,\n _install = function _install(scope) {\n return (_installScope = _merge(scope, _globals)) && gsap;\n},\n _missingPlugin = function _missingPlugin(property, value) {\n return console.warn(\"Invalid property\", property, \"set to\", value, \"Missing plugin? gsap.registerPlugin()\");\n},\n _warn = function _warn(message, suppress) {\n return !suppress && console.warn(message);\n},\n _addGlobal = function _addGlobal(name, obj) {\n return name && (_globals[name] = obj) && _installScope && (_installScope[name] = obj) || _globals;\n},\n _emptyFunc = function _emptyFunc() {\n return 0;\n},\n _startAtRevertConfig = {\n suppressEvents: true,\n isStart: true,\n kill: false\n},\n _revertConfigNoKill = {\n suppressEvents: true,\n kill: false\n},\n _revertConfig = {\n suppressEvents: true\n},\n _reservedProps = {},\n _lazyTweens = [],\n _lazyLookup = {},\n _lastRenderedFrame,\n _plugins = {},\n _effects = {},\n _nextGCFrame = 30,\n _harnessPlugins = [],\n _callbackNames = \"\",\n _harness = function _harness(targets) {\n var target = targets[0],\n harnessPlugin,\n i;\n _isObject(target) || _isFunction(target) || (targets = [targets]);\n\n if (!(harnessPlugin = (target._gsap || {}).harness)) {\n // find the first target with a harness. We assume targets passed into an animation will be of similar type, meaning the same kind of harness can be used for them all (performance optimization)\n i = _harnessPlugins.length;\n\n while (i-- && !_harnessPlugins[i].targetTest(target)) {}\n\n harnessPlugin = _harnessPlugins[i];\n }\n\n i = targets.length;\n\n while (i--) {\n targets[i] && (targets[i]._gsap || (targets[i]._gsap = new GSCache(targets[i], harnessPlugin))) || targets.splice(i, 1);\n }\n\n return targets;\n},\n _getCache = function _getCache(target) {\n return target._gsap || _harness(toArray(target))[0]._gsap;\n},\n _getProperty = function _getProperty(target, property, v) {\n return (v = target[property]) && _isFunction(v) ? target[property]() : _isUndefined(v) && target.getAttribute && target.getAttribute(property) || v;\n},\n _forEachName = function _forEachName(names, func) {\n return (names = names.split(\",\")).forEach(func) || names;\n},\n //split a comma-delimited list of names into an array, then run a forEach() function and return the split array (this is just a way to consolidate/shorten some code).\n_round = function _round(value) {\n return Math.round(value * 100000) / 100000 || 0;\n},\n _roundPrecise = function _roundPrecise(value) {\n return Math.round(value * 10000000) / 10000000 || 0;\n}
1141,\n // increased precision mostly for timing values.\n_parseRelative = function _parseRelative(start, value) {\n var operator = value.charAt(0),\n end = parseFloat(value.substr(2));\n start = parseFloat(start);\n return operator === \"+\" ? start + end : operator === \"-\" ? start - end : operator === \"*\" ? start * end : start / end;\n},\n _arrayContainsAny = function _arrayContainsAny(toSearch, toFind) {\n //searches one array to find matches for any of the items in the toFind array. As soon as one is found, it returns true. It does NOT return all the matches; it's simply a boolean search.\n var l = toFind.length,\n i = 0;\n\n for (; toSearch.indexOf(toFind[i]) < 0 && ++i < l;) {}\n\n return i < l;\n},\n _lazyRender = function _lazyRender() {\n var l = _lazyTweens.length,\n a = _lazyTweens.slice(0),\n i,\n tween;\n\n _lazyLookup = {};\n _lazyTweens.length = 0;\n\n for (i = 0; i < l; i++) {\n tween = a[i];\n tween && tween._lazy && (tween.render(tween._lazy[0], tween._lazy[1], true)._lazy = 0);\n }\n},\n _isRevertWorthy = function _isRevertWorthy(animation) {\n return !!(animation._initted || animation._startAt || animation.add);\n},\n _lazySafeRender = function _lazySafeRender(animation, time, suppressEvents, force) {\n _lazyTweens.length && !_reverting && _lazyRender();\n animation.render(time, suppressEvents, force || !!(_reverting && time < 0 && _isRevertWorthy(animation)));\n _lazyTweens.length && !_reverting && _lazyRender(); //in case rendering caused any tweens to lazy-init, we should render them because typically when someone calls seek() or time() or progress(), they expect an immediate render.\n},\n _numericIfPossible = function _numericIfPossible(value) {\n var n = parseFloat(value);\n return (n || n === 0) && (value + \"\").match(_delimitedValueExp).length < 2 ? n : _isString(value) ? value.trim() : value;\n},\n _passThrough = function _passThrough(p) {\n return p;\n},\n _setDefaults = function _setDefaults(obj, defaults) {\n for (var p in defaults) {\n p in obj || (obj[p] = defaults[p]);\n }\n\n return obj;\n},\n _setKeyframeDefaults = function _setKeyframeDefaults(excludeDuration) {\n return function (obj, defaults) {\n for (var p in defaults) {\n p in obj || p === \"duration\" && excludeDuration || p === \"ease\" || (obj[p] = defaults[p]);\n }\n };\n},\n _merge = function _merge(base, toMerge) {\n for (var p in toMerge) {\n base[p] = toMerge[p];\n }\n\n return base;\n},\n _mergeDeep = function _mergeDeep(base, toMerge) {\n for (var p in toMerge) {\n p !== \"__proto__\" && p !== \"constructor\" && p !== \"prototype\" && (base[p] = _isObject(toMerge[p]) ? _mergeDeep(base[p] || (base[p] = {}), toMerge[p]) : toMerge[p]);\n }\n\n return base;\n},\n _copyExcluding = function _copyExcluding(obj, excluding) {\n var copy = {},\n p;\n\n for (p in obj) {\n p in excluding || (copy[p] = obj[p]);\n }\n\n return copy;\n},\n _inheritDefaults = function _inheritDefaults(vars) {\n var parent = vars.parent || _globalTimeline,\n func = vars.keyframes ? _setKeyframeDefaults(_isArray(vars.keyframes)) : _setDefaults;\n\n if (_isNotFalse(vars.inherit)) {\n while (parent) {\n func(vars, parent.vars.defaults);\n parent = parent.parent || parent._dp;\n }\n }\n\n return vars;\n},\n _arraysMatch = function _arraysMatch(a1, a2) {\n var i = a1.length,\n match = i === a2.length;\n\n while (match && i-- && a1[i] === a2[i]) {}\n\n return i < 0;\n},\n _addLinkedListItem = function _addLinkedListItem(parent, child, firstProp, lastProp, sortBy) {\n if (firstProp === void 0) {\n firstProp = \"_first\";\n }\n\n if (lastProp === void 0) {\n lastProp = \"_last\";\n }\n\n var prev = parent[lastProp],\n t;\n\n if (sortBy) {\n t = child[sortBy];\n\n while (prev && prev[sortBy] > t) {\n prev = prev._prev;\n }\n }\n\n if (prev) {\n child._next = prev._next;\n prev._next = child;\n } else {\n child._next = parent[firstProp];\n parent[firstProp] = child;\n }\n\n if (child._next) {\n child._next._prev = child;\n } else {\n parent[lastProp] = child;\n }\n\n child._prev = prev;\n child.parent = child._dp = parent;\n return child;\n},\n _removeLinkedListItem = function _removeLinkedListItem(parent, child, firstProp, lastProp) {\n if (firstProp === void 0) {\n firstProp = \"_first\";\n }\n\n if (lastProp === void 0) {\n lastProp = \"_last\";\n }\n\n var prev = child._prev,\n next = child._next;\n\n if (prev) {\n prev._next = next;\n } else if (parent[firstProp] === child) {\n parent[firstProp] = next;\n }\n\n if (next) {\n next._prev = prev;\n } else if (parent[lastProp] === child) {\n parent[lastProp] = prev;\n }\n\n child._next = child._prev = child.parent = null; // don't delete the _dp just so we can revert if necessary. But parent should be null to indicate the item isn't in a linked list.\n},\n _removeFromParent = function _removeFromParent(child, onlyIfParentHasAutoRemove) {\n child.parent && (!onlyIfParentHasAutoRemove || child.parent.autoRemoveChildren) && child.parent.remove && child.parent.remove(child);\n child._act = 0;\n},\n _uncache = function _uncache(animation, child) {\n if (animation && (!child || child._end > animation._dur || child._start < 0)) {\n // performance optimization: if a child animation is passed in we should only uncache if that child EXTENDS the animation (its end time is beyond the end)\n var a = animation;\n\n while (a) {\n a._dirty = 1;\n a = a.parent;\n }\n }\n\n return animation;\n},\n _recacheAncestors = function _recacheAncestors(animation) {\n var parent = animation.parent;\n\n while (parent && parent.parent) {\n //sometimes we must force a re-sort of all children and update the duration/totalDuration of all ancestor timelines immediately in case, for example, in the middle of a render loop, one tween alters another tween's timeScale which shoves its startTime before 0, forcing the parent timeline to shift around and shiftChildren() which could affect that next tween's render (startTime). Doesn't matter for the root timeline though.\n parent._dirty = 1;\n parent.totalDuration();\n parent = parent.parent;\n }\n\n return animation;\n},\n _rewindStartAt = function _rewindStartAt(tween, totalTime, suppressEvents, force) {\n return tween._startAt && (_reverting ? tween._startAt.revert(_revertConfigNoKill) : tween.vars.immediateRender && !tween.vars.autoRevert || tween._startAt.render(totalTime, true, force));\n},\n _hasNoPausedAncestors = function _hasNoPausedAncestors(animation) {\n return !animation || animation._ts && _hasNoPausedAncestors(animation.parent);\n},\n _elapsedCycleDuration = function _elapsedCycleDuration(animation) {\n return animation._repeat ? _animationCycle(animation._tTime, animation = animation.duration() + animation._rDelay) * animation : 0;\n},\n // feed in the totalTime and cycleDuration and it'll return the cycle (iteration minus 1) and if the playhead is exactly at the very END, it will NOT bump up to the next cycle.\n_animationCycle = function _animationCycle(tTime, cycleDuration) {\n var whole = Math.floor(tTime = _roundPrecise(tTime / cycleDuration));\n return tTime && whole === tTime ? whole - 1 : whole;
1141\n},\n _parentToChildTotalTime = function _parentToChildTotalTime(parentTime, child) {\n return (parentTime - child._start) * child._ts + (child._ts >= 0 ? 0 : child._dirty ? child.totalDuration() : child._tDur);\n},\n _setEnd = function _setEnd(animation) {\n return animation._end = _roundPrecise(animation._start + (animation._tDur / Math.abs(animation._ts || animation._rts || _tinyNum) || 0));\n},\n _alignPlayhead = function _alignPlayhead(animation, totalTime) {\n // adjusts the animation's _start and _end according to the provided totalTime (only if the parent's smoothChildTiming is true and the animation isn't paused). It doesn't do any rendering or forcing things back into parent timelines, etc. - that's what totalTime() is for.\n var parent = animation._dp;\n\n if (parent && parent.smoothChildTiming && animation._ts) {\n animation._start = _roundPrecise(parent._time - (animation._ts > 0 ? totalTime / animation._ts : ((animation._dirty ? animation.totalDuration() : animation._tDur) - totalTime) / -animation._ts));\n\n _setEnd(animation);\n\n parent._dirty || _uncache(parent, animation); //for performance improvement. If the parent's cache is already dirty, it already took care of marking the ancestors as dirty too, so skip the function call here.\n }\n\n return animation;\n},\n\n/*\n_totalTimeToTime = (clampedTotalTime, duration, repeat, repeatDelay, yoyo) => {\n\tlet cycleDuration = duration + repeatDelay,\n\t\ttime = _round(clampedTotalTime % cycleDuration);\n\tif (time > duration) {\n\t\ttime = duration;\n\t}\n\treturn (yoyo && (~~(clampedTotalTime / cycleDuration) & 1)) ? duration - time : time;\n},\n*/\n_postAddChecks = function _postAddChecks(timeline, child) {\n var t;\n\n if (child._time || !child._dur && child._initted || child._start < timeline._time && (child._dur || !child.add)) {\n // in case, for example, the _start is moved on a tween that has already rendered, or if it's being inserted into a timeline BEFORE where the playhead is currently. Imagine it's at its end state, then the startTime is moved WAY later (after the end of this timeline), it should render at its beginning. Special case: if it's a timeline (has .add() method) and no duration, we can skip rendering because the user may be populating it AFTER adding it to a parent timeline (unconventional, but possible, and we wouldn't want it to get removed if the parent's autoRemoveChildren is true).\n t = _parentToChildTotalTime(timeline.rawTime(), child);\n\n if (!child._dur || _clamp(0, child.totalDuration(), t) - child._tTime > _tinyNum) {\n child.render(t, true);\n }\n } //if the timeline has already ended but the inserted tween/timeline extends the duration, we should enable this timeline again so that it renders properly. We should also align the playhead with the parent timeline's when appropriate.\n\n\n if (_uncache(timeline, child)._dp && timeline._initted && timeline._time >= timeline._dur && timeline._ts) {\n //in case any of the ancestors had completed but should now be enabled...\n if (timeline._dur < timeline.duration()) {\n t = timeline;\n\n while (t._dp) {\n t.rawTime() >= 0 && t.totalTime(t._tTime); //moves the timeline (shifts its startTime) if necessary, and also enables it. If it's currently zero, though, it may not be scheduled to render until later so there's no need to force it to align with the current playhead position. Only move to catch up with the playhead.\n\n t = t._dp;\n }\n }\n\n timeline._zTime = -_tinyNum; // helps ensure that the next render() will be forced (crossingStart = true in render()), even if the duration hasn't changed (we're adding a child which w
1141ould need to get rendered). Definitely an edge case. Note: we MUST do this AFTER the loop above where the totalTime() might trigger a render() because this _addToTimeline() method gets called from the Animation constructor, BEFORE tweens even record their targets, etc. so we wouldn't want things to get triggered in the wrong order.\n }\n},\n _addToTimeline = function _addToTimeline(timeline, child, position, skipChecks) {\n child.parent && _removeFromParent(child);\n child._start = _roundPrecise((_isNumber(position) ? position : position || timeline !== _globalTimeline ? _parsePosition(timeline, position, child) : timeline._time) + child._delay);\n child._end = _roundPrecise(child._start + (child.totalDuration() / Math.abs(child.timeScale()) || 0));\n\n _addLinkedListItem(timeline, child, \"_first\", \"_last\", timeline._sort ? \"_start\" : 0);\n\n _isFromOrFromStart(child) || (timeline._recent = child);\n skipChecks || _postAddChecks(timeline, child);\n timeline._ts < 0 && _alignPlayhead(timeline, timeline._tTime); // if the timeline is reversed and the new child makes it longer, we may need to adjust the parent's _start (push it back)\n\n return timeline;\n},\n _scrollTrigger = function _scrollTrigger(animation, trigger) {\n return (_globals.ScrollTrigger || _missingPlugin(\"scrollTrigger\", trigger)) && _globals.ScrollTrigger.create(trigger, animation);\n},\n _attemptInitTween = function _attemptInitTween(tween, time, force, suppressEvents, tTime) {\n _initTween(tween, time, tTime);\n\n if (!tween._initted) {\n return 1;\n }\n\n if (!force && tween._pt && !_reverting && (tween._dur && tween.vars.lazy !== false || !tween._dur && tween.vars.lazy) && _lastRenderedFrame !== _ticker.frame) {\n _lazyTweens.push(tween);\n\n tween._lazy = [tTime, suppressEvents];\n return 1;\n }\n},\n _parentPlayheadIsBeforeStart = function _parentPlayheadIsBeforeStart(_ref) {\n var parent = _ref.parent;\n return parent && parent._ts && parent._initted && !parent._lock && (parent.rawTime() < 0 || _parentPlayheadIsBeforeStart(parent));\n},\n // check parent's _lock because when a timeline repeats/yoyos and does its artificial wrapping, we shouldn't force the ratio back to 0\n_isFromOrFromStart = function _isFromOrFromStart(_ref2) {\n var data = _ref2.data;\n return data === \"isFromStart\" || data === \"isStart\";\n},\n _renderZeroDurationTween = function _renderZeroDurationTween(tween, totalTime, suppressEvents, force) {\n var prevRatio = tween.ratio,\n ratio = totalTime < 0 || !totalTime && (!tween._start && _parentPlayheadIsBeforeStart(tween) && !(!tween._initted && _isFromOrFromStart(tween)) || (tween._ts < 0 || tween._dp._ts < 0) && !_isFromOrFromStart(tween)) ? 0 : 1,\n // if the tween or its parent is reversed and the totalTime is 0, we should go to a ratio of 0. Edge case: if a from() or fromTo() stagger tween is placed later in a timeline, the \"startAt\" zero-duration tween could initially render at a time when the parent timeline's playhead is technically BEFORE where this tween is, so make sure that any \"from\" and \"fromTo\" startAt tweens are rendered the first time at a ratio of 1.\n repeatDelay = tween._rDelay,\n tTime = 0,\n pt,\n iteration,\n prevIteration;\n\n if (repeatDelay && tween._repeat) {\n // in case there's a zero-duration tween that has a repeat with a repeatDelay\n tTime = _clamp(0, tween._tDur, totalTime);\n iteration = _animationCycle(tTime, repeatDelay);\n tween._yoyo && iteration & 1 && (ratio = 1 - ratio);\n\n if (iteration !== _animationCycle(tween._tTime, repeatDelay)) {\n // if iteration changed\n prevRatio = 1 - ratio;\n tween.vars.repeatRefresh && tween._initted && tween.invalidate();\n }\n }\n\n if (ratio !== prevRatio || _reverting || force || tween._zTime === _tinyNum || !totalTime && tween._zTime) {\n if (!tween._initted && _attemptInitTween(tween, totalTime, force, suppressEvents, tTime)) {\
1141n // if we render the very beginning (time == 0) of a fromTo(), we must force the render (normal tweens wouldn't need to render at a time of 0 when the prevTime was also 0). This is also mandatory to make sure overwriting kicks in immediately.\n return;\n }\n\n prevIteration = tween._zTime;\n tween._zTime = totalTime || (suppressEvents ? _tinyNum : 0); // when the playhead arrives at EXACTLY time 0 (right on top) of a zero-duration tween, we need to discern if events are suppressed so that when the playhead moves again (next time), it'll trigger the callback. If events are NOT suppressed, obviously the callback would be triggered in this render. Basically, the callback should fire either when the playhead ARRIVES or LEAVES this exact spot, not both. Imagine doing a timeline.seek(0) and there's a callback that sits at 0. Since events are suppressed on that seek() by default, nothing will fire, but when the playhead moves off of that position, the callback should fire. This behavior is what people intuitively expect.\n\n suppressEvents || (suppressEvents = totalTime && !prevIteration); // if it was rendered previously at exactly 0 (_zTime) and now the playhead is moving away, DON'T fire callbacks otherwise they'll seem like duplicates.\n\n tween.ratio = ratio;\n tween._from && (ratio = 1 - ratio);\n tween._time = 0;\n tween._tTime = tTime;\n pt = tween._pt;\n\n while (pt) {\n pt.r(ratio, pt.d);\n pt = pt._next;\n }\n\n totalTime < 0 && _rewindStartAt(tween, totalTime, suppressEvents, true);
1141\n tween._onUpdate && !suppressEvents && _callback(tween, \"onUpdate\");\n tTime && tween._repeat && !suppressEvents && tween.parent && _callback(tween, \"onRepeat\");\n\n if ((totalTime >= tween._tDur || totalTime < 0) && tween.ratio === ratio) {\n ratio && _removeFromParent(tween, 1);\n\n if (!suppressEvents && !_reverting) {\n _callback(tween, ratio ? \"onComplete\" : \"onReverseComplete\", true);\n\n tween._prom && tween._prom();\n }\n }\n } else if (!tween._zTime) {\n tween._zTime = totalTime;\n }\n},\n _findNextPauseTween = function _findNextPauseTween(animation, prevTime, time) {\n var child;\n\n if (time > prevTime) {\n child = animation._first;\n\n while (child && child._start <= time) {\n if (child.data === \"isPause\" && child._start > prevTime) {\n return child;\n }\n\n child = child._next;\n }\n } else {\n child = animation._last;\n\n while (child && child._start >= time) {\n if (child.data === \"isPause\" && child._start < prevTime) {\n return child;\n }\n\n child = child._prev;\n }\n }\n},\n _setDuration = function _setDuration(animation, duration, skipUncache, leavePlayhead) {\n var repeat = animation._repeat,\n dur = _roundPrecise(duration) || 0,\n totalProgress = animation._tTime / animation._tDur;\n totalProgress && !leavePlayhead && (animation._time *= dur / animation._dur);\n animation._dur = dur;\n animation._tDur = !repeat ? dur : repeat < 0 ? 1e10 : _roundPrecise(dur * (repeat + 1) + animation._rDelay * repeat);\n totalProgress > 0 && !leavePlayhead && _alignPlayhead(animation, animation._tTime = animation._tDur * totalProgress);\n animation.parent && _setEnd(animation);\n skipUncache || _uncache(animation.parent, animation);\n return animation;\n},\n _onUpdateTotalDuration = function _onUpdateTotalDuration(animation) {\n return animation instanceof Timeline ? _uncache(animation) : _setDuration(animation, animation._dur);\n},\n _zeroPosition = {\n _start: 0,\n endTime: _emptyFunc,\n totalDuration: _emptyFunc\n},\n _parsePosition = function _parsePosition(animation, position, percentAnimation) {\n var labels = animation.labels,\n recent = animation._recent || _zeroPosition,\n clippedDuration = animation.duration() >= _bigNum ? recent.endTime(false) : animation._dur,\n //in case there's a child that infinitely repeats, users almost never intend for the insertion point of a new child to be based on a SUPER long value like that so we clip it and assume the most recently-added child's endTime should be used instead.\n i,\n offset,\n isPercent;\n\n if (_isString(position) && (isNaN(position) || position in labels)) {\n //if the string is a number like \"1\", check to see if there's a label with that name, otherwise interpret it as a number (absolute value).\n offset = position.charAt(0);\n isPercent = position.substr(-1) === \"%\";\n i = position.indexOf(\"=\");\n\n if (offset === \"<\" || offset === \">\") {\n i >= 0 && (position = position.replace(/=/, \"\"));\n return (offset === \"<\" ? recent._start : recent.endTime(recent._repeat >= 0)) + (parseFloat(position.substr(1)) || 0) * (isPercent ? (i < 0 ? recent : percentAnimation).totalDuration() / 100 : 1);\n }\n\n if (i < 0) {\n position in labels || (labels[position] = clippedDuration);\n return labels[position];\n }\n\n offset = parseFloat(position.charAt(i - 1) + position.substr(i + 1));\n\n if (isPercent && percentAnimation) {\n offset = offset / 100 * (_isArray(percentAnimation) ? percentAnimation[0] : percentAnimation).totalDuration();\n }\n\n return i > 1 ? _parsePosition(animation, position.substr(0, i - 1), percentAnimation) + offset : clippedDuration + offset;\n }\n\n return position == null ? clippedDuration : +position;\n},\n _createTweenType = function _createTweenType(type, params, timeline) {\n var isLegacy = _isNumber(params[1]),\n varsIndex = (isLegacy ? 2 : 1) + (type < 2 ? 0 : 1),\n vars = params[varsIndex],\n irVars,\n parent;\n\n isLegacy && (vars.duration = params[1]);\n vars.parent = timeline;\n\n if (type) {\n irVars = vars;\n parent = timeline;
1141\n\n while (parent && !(\"immediateRender\" in irVars)) {\n // inheritance hasn't happened yet, but someone may have set a default in an ancestor timeline. We could do vars.immediateRender = _isNotFalse(_inheritDefaults(vars).immediateRender) but that'd exact a slight performance penalty because _inheritDefaults() also runs in the Tween constructor. We're paying a small kb price here to gain speed.\n irVars = parent.vars.defaults || {};\n parent = _isNotFalse(parent.vars.inherit) && parent.parent;\n }\n\n vars.immediateRender = _isNotFalse(irVars.immediateRender);\n type < 2 ? vars.runBackwards = 1 : vars.startAt = params[varsIndex - 1]; // \"from\" vars\n }\n\n return new Tween(params[0], vars, params[varsIndex + 1]);\n},\n _conditionalReturn = function _conditionalReturn(value, func) {\n return value || value === 0 ? func(value) : func;\n},\n _clamp = function _clamp(min, max, value) {\n return value < min ? min : value > max ? max : value;\n},\n getUnit = function getUnit(value, v) {\n return !_isString(value) || !(v = _unitExp.exec(value)) ? \"\" : v[1];\n},\n // note: protect against padded numbers as strings, like \"100.100\". That shouldn't return \"00\" as the unit. If it's numeric, return no unit.\nclamp = function clamp(min, max, value) {\n return _conditionalReturn(value, function (v) {\n return _clamp(min, max, v);\n });\n},\n _slice = [].slice,\n _isArrayLike = function _isArrayLike(value, nonEmpty) {\n return value && _isObject(value) && \"length\" in value && (!nonEmpty && !value.length || value.length - 1 in value && _isObject(value[0])) && !value.nodeType && value !== _win;\n},\n _flatten = function _flatten(ar, leaveStrings, accumulator) {\n if (accumulator === void 0) {\n accumulator = [];\n }\n\n return ar.forEach(function (value) {\n var _accumulator;\n\n return _isString(value) && !leaveStrings || _isArrayLike(value, 1) ? (_accumulator = accumulator).push.apply(_accumulator, toArray(value)) : accumulator.push(value);\n }) || accumulator;\n},\n // takes any value and returns an Array. If it's a string (and leaveStrings isn't true), it'll use document.querySelectorAll() and convert that to an array. It'll also accept iterables like jQuery objects.\ntoArray = function toArray(value, scope, leaveStrings) {\n return _context && !scope && _context.selector ? _context.selector(value) : _isString(value) && !leaveStrings && (_coreInitted || !_wake()) ? _slice.call((scope || _doc).querySelectorAll(value), 0) : _isArray(value) ? _flatten(value, leaveStrings) : _isArrayLike(value) ? _slice.call(value, 0) : value ? [value] : [];\n},\n selector = function selector(value) {\n value = toArray(value)[0] || _warn(\"Invalid scope\") || {};\n return function (v) {\n var el = value.current || value.nativeElement || value;\n return toArray(v, el.querySelectorAll ? el : el === value ? _warn(\"Invalid scope\") || _doc.createElement(\"div\") : value);\n };\n},\n shuffle = function shuffle(a) {\n return a.sort(function () {\n return .5 - Math.random();\n });\n},\n // alternative that's a bit faster and more reliably diverse but bigger: for (let j, v, i = a.length; i; j = (Math.random() * i) | 0, v = a[--i], a[i] = a[j], a[j] = v); return a;\n// for distributing values across an Array. Can accept a number, a function or (most commonly) an object which can contain the following properties: {base, amount, from, ease, grid, axis, length, each}. Returns a function that expects the following parameters: index, target, array.\n
1141distribute = function distribute(v) {\n if (_isFunction(v)) {\n return v;\n }\n\n var vars = _isObject(v) ? v : {\n each: v\n },\n //n:1 is just to indicate v was a number; we leverage that later to set v according to the length we get. If a number is passed in, we treat it like the old stagger value where 0.1, for example, would mean that things would be distributed with 0.1 between each element in the array rather than a total \"amount\" that's chunked out among them all.\n ease = _parseEase(vars.ease),\n from = vars.from || 0,\n base = parseFloat(vars.base) || 0,\n cache = {},\n isDecimal = from > 0 && from < 1,\n ratios = isNaN(from) || isDecimal,\n axis = vars.axis,\n ratioX = from,\n ratioY = from;\n\n if (_isString(from)) {\n ratioX = ratioY = {\n center: .5,\n edges: .5,\n end: 1\n }[from] || 0;\n } else if (!isDecimal && ratios) {\n ratioX = from[0];\n ratioY = from[1];\n }\n\n return function (i, target, a) {\n var l = (a || vars).length,\n distances = cache[l],\n originX,\n originY,\n x,\n y,\n d,\n j,\n max,\n min,\n wrapAt;\n\n if (!distances) {\n wrapAt = vars.grid === \"auto\" ? 0 : (vars.grid || [1, _bigNum])[1];\n\n if (!wrapAt) {\n max = -_bigNum;\n\n while (max < (max = a[wrapAt++].getBoundingClientRect().left) && wrapAt < l) {}\n\n wrapAt < l && wrapAt--;\n }\n\n distances = cache[l] = [];\n originX = ratios ? Math.min(wrapAt, l) * ratioX - .5 : from % wrapAt;\n originY = wrapAt === _bigNum ? 0 : ratios ? l * ratioY / wrapAt - .5 : from / wrapAt | 0;\n max = 0;\n min = _bigNum;\n\n for (j = 0; j < l;
1141 j++) {\n x = j % wrapAt - originX;\n y = originY - (j / wrapAt | 0);\n distances[j] = d = !axis ? _sqrt(x * x + y * y) : Math.abs(axis === \"y\" ? y : x);\n d > max && (max = d);\n d < min && (min = d);\n }\n\n from === \"random\" && shuffle(distances);\n distances.max = max - min;\n distances.min = min;\n distances.v = l = (parseFloat(vars.amount) || parseFloat(vars.each) * (wrapAt > l ? l - 1 : !axis ? Math.max(wrapAt, l / wrapAt) : axis === \"y\" ? l / wrapAt : wrapAt) || 0) * (from === \"edges\" ? -1 : 1);\n distances.b = l < 0 ? base - l : base;\n distances.u = getUnit(vars.amount || vars.each) || 0; //unit\n\n ease = ease && l < 0 ? _invertEase(ease) : ease;\n }\n\n l = (distances[i] - distances.min) / distances.max || 0;\n return _roundPrecise(distances.b + (ease ? ease(l) : l) * distances.v) + distances.u; //round in order to work around floating point errors\n };\n},\n _roundModifier = function _roundModifier(v) {\n //pass in 0.1 get a function that'll round to the nearest tenth, or 5 to round to the closest 5, or 0.001 to the closest 1000th, etc.\n var p = Math.pow(10, ((v + \"\").split(\".\")[1] || \"\").length); //to avoid floating point math errors (like 24 * 0.1 == 2.4000000000000004), we chop off at a specific number of decimal places (much faster than toFixed())\n\n return function (raw) {\n var n = _roundPrecise(Math.round(parseFloat(raw) / v) * v * p);\n\n return (n - n % 1) / p + (_isNumber(raw) ? 0 : getUnit(raw)); // n - n % 1 replaces Math.floor() in order to handle negative values properly. For example, Math.floor(-150.00000000000003) is 151!\n };\n},\n snap = function snap(snapTo, value) {\n var isArray = _isArray(snapTo),\n radius,\n is2D;\n\n if (!isArray && _isObject(snapTo)) {\n radius = isArray = snapTo.radius || _bigNum;\n\n if (snapTo.values) {\n snapTo = toArray(snapTo.values);\n\n if (is2D = !_isNumber(snapTo[0])) {\n radius *= radius; //performance optimization so we don't have to Math.sqrt() in the loop.\n }\n } else {\n snapTo = _roundModifier(snapTo.increment);\n }\n }\n\n return _conditionalReturn(value, !isArray ? _roundModifier(snapTo) : _isFunction(snapTo) ? function (raw) {\n is2D = snapTo(raw);\n return Math.abs(is2D - raw) <= radius ? is2D : raw;\n } : function (raw) {\n var x = parseFloat(is2D ? raw.x : raw),\n y = parseFloat(is2D ? raw.y : 0),\n min = _bigNum,\n closest = 0,\n i = snapTo.length,\n dx,\n dy;\n\n while (i--) {\n if (is2D) {\n dx = snapTo[i].x - x;\n dy = snapTo[i].y - y;\n dx = dx * dx + dy * dy;\n } else {\n dx = Math.abs(snapTo[i] - x);\n }\n\n if (dx < min) {\n min = dx;\n closest = i;\n }\n }\n\n closest = !radius || min <= radius ? snapTo[closest] : raw;\n return is2D || closest === raw || _isNumber(raw) ? closest : closest + getUnit(raw);\n });\n},\n random = function random(min, max, roundingIncrement, returnFunction) {\n return _conditionalReturn(_isArray(min) ? !max : roundingIncrement === true ? !!(roundingIncrement = 0) : !returnFunction, function () {\n return _isArray(min) ? min[~~(Math.random() * min.length)] : (roundingIncrement = roundingIncrement || 1e-5) && (returnFunction = roundingIncrement < 1 ? Math.pow(10, (roundingIncrement + \"\").length - 2) : 1) && Math.floor(Math.round((min - roundingIncrement / 2 + Math.random() * (max - min + roundingIncrement * .99)) / roundingIncrement) * roundingIncrement * returnFunction) / returnFunction;\n });\n},\n pipe = function pipe() {\n for (var _len = arguments.length, functions = new Array(_len), _key = 0; _key < _len; _key++) {\n functions[_key] = arguments[_key];\n }\n\n return function (value) {\n return functions.reduce(function (v, f) {\n return f(v);\n }, value);\n };\n},\n unitize = function unitize(func, unit) {\n return function (value) {\n return func(parseFloat(value)) + (unit || getUnit(value));\n };\n},\n normalize = function normalize(min, max, value) {\n return mapRange(min, max, 0, 1, value);\n},\n _wrapArray = function _wrapArray(a, wrapper, value) {\n return _conditionalReturn(value, function (index) {\n return a[~~wrapper(index)];\n });\n},\n wrap = function wrap(min, max, value) {\n // NOTE: wrap() CANNOT be an arrow function! A very odd compiling bug
1141causes problems (unrelated to GSAP).\n var range = max - min;\n return _isArray(min) ? _wrapArray(min, wrap(0, min.length), max) : _conditionalReturn(value, function (value) {\n return (range + (value - min) % range) % range + min;\n });\n},\n wrapYoyo = function wrapYoyo(min, max, value) {\n var range = max - min,\n total = range * 2;\n return _isArray(min) ? _wrapArray(min, wrapYoyo(0, min.length - 1), max) : _conditionalReturn(value, function (value) {\n value = (total + (value - min) % total) % total || 0;\n return min + (value > range ? total - value : value);\n });\n},\n _replaceRandom = function _replaceRandom(s) {\n return s.replace(_randomExp, function (match) {\n //replaces all occurrences of random(...) in a string with the calculated random value. can be a range like random(-100, 100, 5) or an array like random([0, 100, 500])\n var arIndex = match.indexOf(\"[\") + 1,\n values = match.substring(arIndex || 7, arIndex ? match.indexOf(\"]\") : match.length - 1).split(_commaDelimExp);\n return random(arIndex ? values : +values[0], arIndex ? 0 : +values[1], +values[2] || 1e-5);\n });\n},\n mapRange = function mapRange(inMin, inMax, outMin, outMax, value) {\n var inRange = inMax - inMin,\n outRange = outMax - outMin;\n return _conditionalReturn(value, function (value) {\n return outMin + ((value - inMin) / inRange * outRange || 0);\n });\n},\n interpolate = function interpolate(start, end, progress, mutate) {\n var func = isNaN(start + end) ? 0 : function (p) {\n return (1 - p) * start + p * end;\n };\n\n if (!func) {\n var isString = _isString(start),\n master = {},\n p,\n i,\n interpolators,\n l,\n il;\n\n progress === true && (mutate = 1) && (progress = null);\n\n if (isString) {\n start = {\n p: start\n };\n end = {\n p: end\n };\n } else if (_isArray(start) && !_isArray(end)) {\n interpolators = [];\n l = start.length;\n il = l - 2;\n\n for (i = 1; i < l; i++) {\n interpolators.push(interpolate(start[i - 1], start[i])); //build the interpolators up front as a performance optimization so that when the function is called many times, it can just reuse them.\n }\n\n l--;\n\n func = function func(p) {\n p *= l;\n var i = Math.min(il, ~~p);\n return interpolators[i](p - i);\n };\n\n progress = end;\n } else if (!mutate) {\n start = _merge(_isArray(start) ? [] : {}, start);\n }\n\n if (!interpolators) {\n for (p in end) {\n _addPropTween.call(master, start, p, \"get\", end[p]);\n }\n\n func = function func(p) {\n return _renderPropTweens(p, master) || (isString ? start.p : start);\n };\n }\n }\n\n return _conditionalReturn(progress, func);\n},\n _getLabelInDirection = function _getLabelInDirection(timeline, fromTime, backward) {\n //used for nextLabel() and previousLabel()\n var labels = timeline.labels,\n min = _bigNum,\n p,\n distance,\n label;\n\n for (p in labels) {\n distance = labels[p] - fromTime;\n\n if (distance < 0 === !!backward && distance && min > (distance = Math.abs(distance))) {\n label = p;\n min = distance;\n }\n }\n\n return label;\n},\n _callback = function _callback(animation, type, executeLazyFirst) {\n var v = animation.vars,\n callback = v[type],\n prevContext = _context,\n context = animation._ctx,\n params,\n scope,\n result;\n\n if (!callback) {\n return;\n }\n\n params = v[type + \"Params\"];\n scope = v.callbackScope || animation;\n executeLazyFirst && _lazyTweens.length && _lazyRender(); //in case rendering caused any tweens to lazy-init, we should render them because typically when a timeline finishes, users expect things to have rendered fully. Imagine an onUpdate on a timeline that reports/checks tweened values.\n\n context && (_context = context);\n result = params ? callback.apply(scope, params) : callback.call(scope);\n _context = prevContext;\n return result;\n}
1141,\n _interrupt = function _interrupt(animation) {\n _removeFromParent(animation);\n\n animation.scrollTrigger && animation.scrollTrigger.kill(!!_reverting);\n animation.progress() < 1 && _callback(animation, \"onInterrupt\");\n return animation;\n},\n _quickTween,\n _registerPluginQueue = [],\n _createPlugin = function _createPlugin(config) {\n if (!config) return;\n config = !config.name && config[\"default\"] || config; // UMD packaging wraps things oddly, so for example MotionPathHelper becomes {MotionPathHelper:MotionPathHelper, default:MotionPathHelper}.\n\n if (_windowExists() || config.headless) {\n // edge case: some build tools may pass in a null/undefined value\n var name = config.name,\n isFunc = _isFunction(config),\n Plugin = name && !isFunc && config.init ? function () {\n this._props = [];\n } : config,\n //in case someone passes in an object that's not a plugin, like CustomEase\n instanceDefaults = {\n init: _emptyFunc,\n render: _renderPropTweens,\n add: _addPropTween,\n kill: _killPropTweensOf,\n modifier: _addPluginModifier,\n rawVars: 0\n },\n statics = {\n targetTest: 0,\n get: 0,\n getSetter: _getSetter,\n aliases: {},\n register: 0\n };\n\n _wake();\n\n if (config !== Plugin) {\n if (_plugins[name]) {\n return;\n }\n\n _setDefaults(Plugin, _setDefaults(_copyExcluding(config, instanceDefaults), statics)); //static methods\n\n\n _merge(Plugin.prototype, _merge(instanceDefaults, _copyExcluding(config, statics))); //instance methods\n\n\n _plugins[Plugin.prop = name] = Plugin;\n\n if (config.targetTest) {\n _harnessPlugins.push(Plugin);\n\n _reservedProps[name] = 1;\n }\n\n name = (name === \"css\" ? \"CSS\" : name.charAt(0).toUpperCase() + name.substr(1)) + \"Plugin\"; //for the global name. \"motionPath\" should become MotionPathPlugin\n }\n\n _addGlobal(name, Plugin);\n\n config.register && config.register(gsap, Plugin, PropTween);\n } else {\n _registerPluginQueue.push(config);\n }\n},\n\n/*\n * --------------------------------------------------------------------------------------\n * COLORS\n * --------------------------------------------------------------------------------------\n */\n_255 = 255,\n _colorLookup = {\n aqua: [0, _255, _255],\n lime: [0, _255, 0],\n silver: [192, 192, 192],\n black: [0, 0, 0],\n maroon: [128, 0, 0],\n teal: [0, 128, 128],\n blue: [0, 0, _255],\n navy: [0, 0, 128],\n white: [_255, _255, _255],\n olive: [128, 128, 0],\n yellow: [_255, _255, 0],\n orange: [_255, 165, 0],\n gray: [128, 128, 128],\n purple: [128, 0, 128],\n green: [0, 128, 0],\n red: [_255, 0, 0],\n pink: [_255, 192, 203],\n cyan: [0, _255, _255],\n transparent: [_255, _255, _255, 0]\n},\n // possible future idea to replace the hard-coded color name values - put this in the ticker.wake() where we set the _doc:\n// let ctx = _doc.createElement(\"canvas\").getContext(\"2d\");\n// _forEachName(\"aqua,lime,silver,black,maroon,teal,blue,navy,white,olive,yellow,orange,gray,purple,green,red,pink,cyan\", color => {ctx.fillStyle = color; _colorLookup[color] = splitColor(ctx.fillStyle)});\n_hue = function _hue(h, m1, m2) {\n h += h < 0 ? 1 : h > 1 ? -1 : 0;\n return (h * 6 < 1 ? m1 + (m2 - m1) * h * 6 : h < .5 ? m2 : h * 3 < 2 ? m1 + (m2 - m1) * (2 / 3 - h) * 6 : m1) * _255 + .5 | 0;\n},\n splitColor = function splitColor(v, toHSL, forceAlpha) {\n var a = !v ? _colorLookup.black : _isNumber(v) ? [v >> 16, v >> 8 & _255, v & _255] : 0,\n r,\n g,\n b,\n h,\n s,\n l,\n max,\n min,\n d,\n wasHSL;\n\n if (!a) {\n if (v.substr(-1) === \",\") {\n //sometimes a trailing comma is included and we should chop it off (typically from a comma-delimited list of values like a textShadow:\"2px 2px 2px blue, 5px 5px 5px rgb(255,0,0)\" - in this example \"blue,\" has a trailing comma. We could strip it out inside parseComplex() but we'd need to do it to the beginning and ending values plus it wouldn't provide protection from other potential scenarios like if the user passes in a similar value.\n v = v.substr(0, v.length - 1);\n }\n\n if (_colorLookup[v]) {\n a = _colorLookup[v];\n } else if (v.charAt(0) === \"#\") {\n if (v.length < 6) {\n //for shorthand like #9F0 or #9F0F (could have alpha)\n r = v.charAt(1);\n g = v.charAt(2);\n b = v.charAt(3);\n v = \"#\" + r + r + g + g + b + b + (v.length === 5 ? v.charAt(4) + v.charAt(4) : \"\");\n }\n\n if (v.length === 9) {\n // hex with alpha, like #fd5e53ff\n a = parseInt(v.substr(1, 6), 16);\n return [a >> 16, a >>
1141 8 & _255, a & _255, parseInt(v.substr(7), 16) / 255];\n }\n\n v = parseInt(v.substr(1), 16);\n a = [v >> 16, v >> 8 & _255, v & _255];\n } else if (v.substr(0, 3) === \"hsl\") {\n a = wasHSL = v.match(_strictNumExp);\n\n if (!toHSL) {\n h = +a[0] % 360 / 360;\n s = +a[1] / 100;\n l = +a[2] / 100;\n g = l <= .5 ? l * (s + 1) : l + s - l * s;\n r = l * 2 - g;\n a.length > 3 && (a[3] *= 1); //cast as number\n\n a[0] = _hue(h + 1 / 3, r, g);\n a[1] = _hue(h, r, g);\n a[2] = _hue(h - 1 / 3, r, g);\n } else if (~v.indexOf(\"=\")) {\n //if relative values are found, just return the raw strings with the relative prefixes in place.\n a = v.match(_numExp);\n forceAlpha && a.length < 4 && (a[3] = 1);\n return a;\n }\n } else {\n a = v.match(_strictNumExp) || _colorLookup.transparent;\n }\n\n a = a.map(Number);\n }\n\n if (toHSL && !wasHSL) {\n r = a[0] / _255;\n g = a[1] / _255;\n b = a[2] / _255;\n max = Math.max(r, g, b);\n min = Math.min(r, g, b);\n l = (max + min) / 2;\n\n if (max === min) {\n h = s = 0;\n } else {\n d = max - min;\n s = l > 0.5 ? d / (2 - max - min) : d / (max + min);\n h = max === r ? (g - b) / d + (g < b ? 6 : 0) : max === g ? (b - r) / d + 2 : (r - g) / d + 4;\n h *= 60;\n }\n\n a[0] = ~~(h + .5);\n a[1] = ~~(s * 100 + .5);\n a[2] = ~~(l * 100 + .5);\n }\n\n forceAlpha && a.length < 4 && (a[3] = 1);\n return a;\n},\n _colorOrderData = function _colorOrderData(v) {\n // strips out the colors from the string, finds all the numeric slots (with units) and returns an array of those. The Array also has a \"c\" property which is an Array of the index values where the colors belong. This is to help work around issues where there's a mis-matched order of color/numeric data like drop-shadow(#f00 0px 1px 2px) and drop-shadow(0x 1px 2px #f00). This is basically a helper function used in _formatColors()\n var values = [],\n c = [],\n i = -1;\n v.split(_colorExp).forEach(function (v) {\n var a = v.match(_numWithUnitExp) || [];\n values.push.apply(values, a);\n c.push(i += a.length + 1);\n });\n values.c = c;\n return values;\n},\n _formatColors = function _formatColors(s, toHSL, orderMatchData) {\n var result = \"\",\n colors = (s + result).match(_colorExp),\n type = toHSL ? \"hsla(\" : \"rgba(\",\n i = 0,\n c,\n shell,\n d,\n l;\n\n if (!colors) {\n return s;\n }\n\n colors = colors.map(function (color) {\n return (color = splitColor(color, toHSL, 1)) && type + (toHSL ? color[0] + \",\" + color[1] + \"%,\" + color[2] + \"%,\" + color[3] : color.join(\",\")) + \")\";\n });\n\n if (orderMatchData) {\n d = _colorOrderData(s);\n c = orderMatchData.c;\n\n if (c.join(result) !== d.c.join(result)) {\n shell = s.replace(_colorExp, \"1\").split(_numWithUnitExp);\n l = shell.length - 1;\n\n for (; i < l; i++) {\n result += shell[i] + (~c.indexOf(i) ? colors.shift() || type + \"0,0,0,0)\" : (d.length ? d : colors.length ? colors : orderMatchData).shift());\n }\n }\n }\n\n if (!shell) {\n shell = s.split(_colorExp);\n l = shell.length - 1;\n\n for (; i < l; i++) {\n result += shell[i] + colors[i];\n }\n }\n\n return result + shell[l];\n},\n _colorExp = function () {\n var s = \"(?:\\\\b(?:(?:rgb|rgba|hsl|hsla)\\\\(.+?\\\\))|\\\\B#(?:[0-9a-f]{3,4}){1,2}\\\\b\",\n //we'll dynamically build this Regular Expression to conserve file size. After building it, it will be able to find rgb(), rgba(), # (hexadecimal), and named color values like red, blue, purple, etc.,\n p;\n\n for (p in _colorLookup) {\n s += \"|\" + p + \"\\\\b\";\n }\n\n return new RegExp(s + \")\", \"gi\");\n}(),\n _hslExp = /hsl[a]?\\(/,\n _colorStringFilter = function _colorStringFilter(a) {\n var combined = a.join(\" \"),\n toHSL;\n _colorExp.lastIndex = 0;\n\n if (_colorExp.test(combined)) {\n toHSL = _hslExp.test(combined);\n a[1] = _formatColors(a[1], toHSL);\n a[0] = _formatColors(a[0], toHSL, _colorOrderData(a[1])); // make sure the order of numbers/colors match with the END value.\n\n return true;\n }\n},\n\n/*\n * --------------------------------------------------------------------------------------\n * TICKER\n * --------------------------------------------------------------------------------------\n */\n_tickerActive,\n _ticker = function () {\n var _getTime = Date.now,\n _lagThreshold = 500,\n _adjustedLag = 33,\n _startTime = _getTime(),\n _lastUpdate = _startTime,\n _gap = 1000 / 240,\n _nextTime = _gap,\n _listeners = [],\n _id,\n _req,\n _raf,\n _self,\n _delta,\n _i,\n _tick = function _tick(v) {\n var elapsed
1141= _getTime() - _lastUpdate,\n manual = v === true,\n overlap,\n dispatch,\n time,\n frame;\n\n (elapsed > _lagThreshold || elapsed < 0) && (_startTime += elapsed - _adjustedLag);\n _lastUpdate += elapsed;\n time = _lastUpdate - _startTime;\n overlap = time - _nextTime;\n\n if (overlap > 0 || manual) {\n frame = ++_self.frame;\n _delta = time - _self.time * 1000;\n _self.time = time = time / 1000;\n _nextTime += overlap + (overlap >= _gap ? 4 : _gap - overlap);\n dispatch = 1;\n }\n\n manual || (_id = _req(_tick)); //make sure the request is made before we dispatch the \"tick\" event so that timing is maintained. Otherwise, if processing the \"tick\" requires a bunch of time (like 15ms) and we're using a setTimeout() that's based on 16.7ms, it'd technically take 31.7ms between frames otherwise.\n\n if (dispatch) {\n for (_i = 0; _i < _listeners.length; _i++) {\n // use _i and check _listeners.length instead of a variable because a listener could get removed during the loop, and if that happens to an element less than the current index, it'd throw things off in the loop.\n _listeners[_i](time, _delta, frame, v);\n }\n }\n };\n\n _self = {\n time: 0,\n frame: 0,\n tick: function tick() {\n _tick(true);\n },\n deltaRatio: function deltaRatio(fps) {\n return _delta / (1000 / (fps || 60));\n },\n wake: function wake() {\n if (_coreReady) {\n if (!_coreInitted && _windowExists()) {\n _win = _coreInitted = window;\n _doc = _win.document || {};\n _globals.gsap = gsap;\n (_win.gsapVersions || (_win.gsapVersions = [])).push(gsap.version);\n\n _install(_installScope || _win.GreenSockGlobals || !_win.gsap && _win || {});\n\n _registerPluginQueue.forEach(_createPlugin);\n }\n\n _raf = typeof requestAnimationFrame !== \"undefined\" && requestAnimationFrame;\n _id && _self.sleep();\n\n _req = _raf || function (f) {\n return setTimeout(f, _nextTime - _self.time * 1000 + 1 | 0);\n };\n\n _tickerActive = 1;\n\n _tick(2);\n }\n },\n sleep: function sleep() {\n (_raf ? cancelAnimationFrame : clearTimeout)(_id);\n _tickerActive = 0;\n _req = _emptyFunc;\n },\n lagSmoothing: function lagSmoothing(threshold, adjustedLag) {\n _lagThreshold = threshold || Infinity; // zero should be interpreted as basically unlimited\n\n _adjustedLag = Math.min(adjustedLag || 33, _lagThreshold);\n },\n fps: function fps(_fps) {\n _gap = 1000 / (_fps || 240);\n _nextTime = _self.time * 1000 + _gap;\n },\n add: function add(callback, once, prioritize) {\n var func = once ? function (t, d, f, v) {\n callback(t, d, f, v);\n\n _self.remove(func);\n } : callback;\n\n _self.remove(callback);\n\n _listeners[prioritize ? \"unshift\" : \"push\"](func);\n\n _wake();\n\n return func;\n },\n remove: function remove(callback, i) {\n ~(i = _listeners.indexOf(callback)) && _listeners.splice(i, 1) && _i >= i && _i--;\n },\n _listeners: _listeners\n };\n return _self;\n}(),\n _wake = function _wake() {\n return !_tickerActive && _ticker.wake();\n},\n //also ensures the core classes are initialized.\n\n/*\n* -------------------------------------------------\n* EASING\n* -------------------------------------------------\n*/\n_easeMap = {},\n _customEaseExp = /^[\\d.\\-M][\\d.\\-,\\s]/,\n _quotesExp = /[\"']/g,\n _parseObjectInString = function _parseObjectInString(value) {\n //takes a string like \"{wiggles:10, type:anticipate})\" and turns it into a real object. Notice it ends in \")\" and includes the {} wrappers. This is because we only use this function for parsing ease configs and prioritized optimization rather than reusability.\n var obj = {},\n split = value.substr(1, value.length - 3).split(\":\"),\n key = split[0],\n i = 1,\n l = split.length,\n index,\n val,\n parsedVal;\n\n for (; i < l;
1141 i++) {\n val = split[i];\n index = i !== l - 1 ? val.lastIndexOf(\",\") : val.length;\n parsedVal = val.substr(0, index);\n obj[key] = isNaN(parsedVal) ? parsedVal.replace(_quotesExp, \"\").trim() : +parsedVal;\n key = val.substr(index + 1).trim();\n }\n\n return obj;\n},\n _valueInParentheses = function _valueInParentheses(value) {\n var open = value.indexOf(\"(\") + 1,\n close = value.indexOf(\")\"),\n nested = value.indexOf(\"(\", open);\n return value.substring(open, ~nested && nested < close ? value.indexOf(\")\", close + 1) : close);\n},\n _configEaseFromString = function _configEaseFromString(name) {\n //name can be a string like \"elastic.out(1,0.5)\", and pass in _easeMap as obj and it'll parse it out and call the actual function like _easeMap.Elastic.easeOut.config(1,0.5). It will also parse custom ease strings as long as CustomEase is loaded and registered (internally as _easeMap._CE).\n var split = (name + \"\").split(\"(\"),\n ease = _easeMap[split[0]];\n return ease && split.length > 1 && ease.config ? ease.config.apply(null, ~name.indexOf(\"{\") ? [_parseObjectInString(split[1])] : _valueInParentheses(name).split(\",\").map(_numericIfPossible)) : _easeMap._CE && _customEaseExp.test(name) ? _easeMap._CE(\"\", name) : ease;\n},\n _invertEase = function _invertEase(ease) {\n return function (p) {\n return 1 - ease(1 - p);\n };\n},\n _parseEase = function _parseEase(ease, defaultEase) {\n return !ease ? defaultEase : (_isFunction(ease) ? ease : _easeMap[ease] || _configEaseFromString(ease)) || defaultEase;\n},\n _insertEase = function _insertEase(names, easeIn, easeOut, easeInOut) {\n if (easeOut === void 0) {\n easeOut = function easeOut(p) {\n return 1 - easeIn(1 - p);\n };\n }\n\n if (easeInOut === void 0) {\n easeInOut = function easeInOut(p) {\n return p < .5 ? easeIn(p * 2) / 2 : 1 - easeIn((1 - p) * 2) / 2;\n };\n }\n\n var ease = {\n easeIn: easeIn,\n easeOut: easeOut,\n easeInOut: easeInOut\n },\n lowercaseName;\n\n _forEachName(names, function (name) {\n _easeMap[name] = _globals[name] = ease;\n _easeMap[lowercaseName = name.toLowerCase()] = easeOut;\n\n for (var p in ease) {\n _easeMap[lowercaseName + (p === \"easeIn\" ? \".in\" : p === \"easeOut\" ? \".out\" : \".inOut\")] = _easeMap[name + \".\" + p] = ease[p];\n }\n });\n\n return ease;\n},\n _easeInOutFromOut = function _easeInOutFromOut(easeOut) {\n return function (p) {\n return p < .5 ? (1 - easeOut(1 - p * 2)) / 2 : .5 + easeOut((p - .5) * 2) / 2;\n };\n},\n _configElastic = function _configElastic(type, amplitude, period) {\n var p1 = amplitude >= 1 ? amplitude : 1,\n //note: if amplitude is < 1, we simply adjust the period for a more natural feel. Otherwise the math doesn't work right and the curve starts at 1.\n p2 = (period || (type ? .3 : .45)) / (amplitude < 1 ? amplitude : 1),\n p3 = p2 / _2PI * (Math.asin(1 / p1) || 0),\n easeOut = function easeOut(p) {\n return p === 1 ? 1 : p1 * Math.pow(2, -10 * p) * _sin((p - p3) * p2) + 1;\n },\n ease = type === \"out\" ? easeOut : type === \"in\" ? function (p) {\n return 1 - easeOut(1 - p);\n } : _easeInOutFromOut(easeOut);\n\n p2 = _2PI / p2; //precalculate to optimize\n\n ease.config = function (amplitude, period) {\n return _configElastic(type, amplitude, period);\n };\n\n return ease;\n},\n _configBack = function _configBack(type, overshoot) {\n if (overshoot === void 0) {\n overshoot = 1.70158;\n }\n\n var easeOut = function easeOut(p) {\n return p ? --p * p * ((overshoot + 1) * p + overshoot) + 1 : 0;\n },\n ease = type === \"out\" ? easeOut : type === \"in\" ? function (p) {\n return 1 - easeOut(1 - p);\n } : _easeInOutFromOut(easeOut);\n\n ease.config = function (overshoot) {\n return _configBack(type, overshoot);\n };\n\n return ease;\n}; // a cheaper (kb and cpu) but more mild way to get a parameterized weighted ease by feeding in a value between -1 (easeIn) and 1 (easeOut) where 0 is linear.\n// _weightedEase = ratio => {\n// \tlet y = 0.5 + ratio / 2;\n// \treturn p => (2 * (1 - p) * p * y + p * p);\n// },\n// a stronger (but more expensive kb/cpu) parameterized weighted ease that lets you feed in a value between -1 (easeIn) and 1 (easeOut) where 0 is linear.\n// _weightedEaseStrong = ratio => {\n// \tratio = .5 + ratio / 2;\n// \tlet o = 1 / 3 * (ratio < .5 ? ratio : 1 - ratio),\n// \t\tb = ratio - o,\n// \t\tc = ratio + o;\n// \treturn p => p === 1 ? p : 3 * b * (1 - p) * (1 - p) * p + 3 * c * (1 - p) * p * p + p * p * p;\n// };\n\n\n_forEachName(\"Linear,Quad,Cubic,Quart,Quint,Strong\", function (name, i) {\n var power = i < 5 ? i + 1 : i;\n\n _insertEase(name + \",Power\" + (power - 1), i ? function (p) {\n return Math.pow(p, power);\n }
1141 : function (p) {\n return p;\n }, function (p) {\n return 1 - Math.pow(1 - p, power);\n }, function (p) {\n return p < .5 ? Math.pow(p * 2, power) / 2 : 1 - Math.pow((1 - p) * 2, power) / 2;\n });\n});\n\n_easeMap.Linear.easeNone = _easeMap.none = _easeMap.Linear.easeIn;\n\n_insertEase(\"Elastic\", _configElastic(\"in\"), _configElastic(\"out\"), _configElastic());\n\n(function (n, c) {\n var n1 = 1 / c,\n n2 = 2 * n1,\n n3 = 2.5 * n1,\n easeOut = function easeOut(p) {\n return p < n1 ? n * p * p : p < n2 ? n * Math.pow(p - 1.5 / c, 2) + .75 : p < n3 ? n * (p -= 2.25 / c) * p + .9375 : n * Math.pow(p - 2.625 / c, 2) + .984375;\n };\n\n _insertEase(\"Bounce\", function (p) {\n return 1 - easeOut(1 - p);\n }, easeOut);\n})(7.5625, 2.75);\n\n_insertEase(\"Expo\", function (p) {\n return Math.pow(2, 10 * (p - 1)) * p + p * p * p * p * p * p * (1 - p);\n}); // previously 2 ** (10 * (p - 1)) but that doesn't end up with the value quite at the right spot so we do a blended ease to ensure it lands where it should perfectly.\n\n\n_insertEase(\"Circ\", function (p) {\n return -(_sqrt(1 - p * p) - 1);\n});\n\n_insertEase(\"Sine\", function (p) {\n return p === 1 ? 1 : -_cos(p * _HALF_PI) + 1;\n});\n\n_insertEase(\"Back\", _configBack(\"in\"), _configBack(\"out\"), _configBack());\n\n_easeMap.SteppedEase = _easeMap.steps = _globals.SteppedEase = {\n config: function config(steps, immediateStart) {\n if (steps === void 0) {\n steps = 1;\n }\n\n var p1 = 1 / steps,\n p2 = steps + (immediateStart ? 0 : 1),\n p3 = immediateStart ? 1 : 0,\n max = 1 - _tinyNum;\n return function (p) {\n return ((p2 * _clamp(0, max, p) | 0) + p3) * p1;\n };\n }\n};\n_defaults.ease = _easeMap[\"quad.out\"];\n\n_forEachName(\"onComplete,onUpdate,onStart,onRepeat,onReverseComplete,onInterrupt\", function (name) {\n return _callbackNames += name + \",\" + name + \"Params,\";\n});\n/*\n * --------------------------------------------------------------------------------------\n * CACHE\n * --------------------------------------------------------------------------------------\n */\n\n\nvar GSCache = function GSCache(target, harness) {\n this.id = _gsID++;\n target._gsap = this;\n this.target = target;\n this.harness = harness;\n this.get = harness ? harness.get : _getProperty;\n this.set = harness ? harness.getSetter : _getSetter;\n};\n/*\n * --------------------------------------------------------------------------------------\n * ANIMATION\n * --------------------------------------------------------------------------------------\n */\n\nvar Animation = /*#__PURE__*/function () {\n function Animation(vars) {\n this.vars = vars;\n this._delay = +vars.delay || 0;\n\n if (this._repeat = vars.repeat === Infinity ? -2 : vars.repeat || 0) {\n // TODO: repeat: Infinity on a timeline's children must flag that timeline internally and affect its totalDuration, otherwise it'll stop in the negative direction when reaching the start.\n this._rDelay = vars.repeatDelay || 0;\n this._yoyo = !!vars.yoyo || !!vars.yoyoEase;\n }\n\n this._ts = 1;\n\n _setDuration(this, +vars.duration, 1, 1);\n\n this.data = vars.data;\n\n if (_context) {\n this._ctx = _context;\n\n _context.data.push(this);\n }\n\n _tickerActive || _ticker.wake();\n }\n\n var _proto = Animation.prototype;\n\n _proto.delay = function delay(value) {\n if (value || value === 0) {\n this.parent && this.parent.smoothChildTiming && this.startTime(this._start + value - this._delay);\n this._delay = value;\n return this;\n }\n\n return this._delay;\n };\n\n _proto.duration = function duration(value) {\n return arguments.length ? this.totalDuration(this._repeat > 0 ? value + (value + this._rDelay) * this._repeat : value) : this.totalDuration() && this._dur;\n };\n\n _proto.totalDuration = function totalDuration(value) {\n if (!arguments.length) {\n return this._tDur;\n }\n\n this._dirty = 0;\n return _setDuration(this, this._repeat < 0 ? value : (value - this._repeat * this._rDelay) / (this._repeat + 1));\n };\n\n _proto.totalTime = function totalTime(_totalTime, suppressEvents) {\n _wake();\n\n if (!arguments.length) {\n return this._tTime;\n }\n\n var parent = this._dp;\n\n if (parent && parent.smoothChildTiming && this._ts) {\n _alignPlayhead(this, _totalTime);\n\n !parent._dp || parent.parent || _postAddChecks(parent, this); // edge case: if this is a child of a timeline that already completed, for example, we must re-activate the parent.\n //in case any of the ancestor timelines had completed but should now be enabled, we should reset the
1141ir totalTime() which will also ensure that they're lined up properly and enabled. Skip for animations that are on the root (wasteful). Example: a TimelineLite.exportRoot() is performed when there's a paused tween on the root, the export will not complete until that tween is unpaused, but imagine a child gets restarted later, after all [unpaused] tweens have completed. The start of that child would get pushed out, but one of the ancestors may have completed.\n\n while (parent && parent.parent) {\n if (parent.parent._time !== parent._start + (parent._ts >= 0 ? parent._tTime / parent._ts : (parent.totalDuration() - parent._tTime) / -parent._ts)) {\n parent.totalTime(parent._tTime, true);\n }\n\n parent = parent.parent;\n }\n\n if (!this.parent && this._dp.autoRemoveChildren && (this._ts > 0 && _totalTime < this._tDur || this._ts < 0 && _totalTime > 0 || !this._tDur && !_totalTime)) {\n //if the animation doesn't have a parent, put it back into its last parent (recorded as _dp for exactly cases like this). Limit to parents with autoRemoveChildren (like globalTimeline) so that if the user manually removes an animation from a timeline and then alters its playhead, it doesn't get added back in.\n _addToTimeline(this._dp, this, this._start - this._delay);\n }\n }\n\n if (this._tTime !== _totalTime || !this._dur && !suppressEvents || this._initted && Math.abs(this._zTime) === _tinyNum || !this._initted && this._dur && _totalTime || !_totalTime && !this._initted && (this.add || this._ptLookup)) {\n // check for _ptLookup on a Tween instance to ensure it has actually finished being instantiated, otherwise if this.reverse() gets called in the Animation constructor, it could trigger a render() here even though the _targets weren't populated, thus when _init() is called there won't be any PropTweens (it'll act like the tween is non-functional)\n this._ts || (this._pTime = _totalTime); // otherwise, if an animation is paused, then the playhead is moved back to zero, then resumed, it'd revert back to the original time at the pause\n //if (!this._lock) { // avoid endless recursion (not sure we need this yet or if it's worth the performance hit)\n // this._lock = 1;\n\n _lazySafeRender(this, _totalTime, suppressEvents); // this._lock = 0;\n //}\n\n }\n\n return this;\n };\n\n _proto.time = function time(value, suppressEvents) {\n return arguments.length ? this.totalTime(Math.min(this.totalDuration(), value + _elapsedCycleDuration(this)) % (this._dur + this._rDelay) || (value ? this._dur : 0), suppressEvents) : this._time; // note: if the modulus results in 0, the playhead could be exactly at the end or the beginning, and we always defer to the END with a non-zero value, otherwise if you set the time() to the very end (duration()), it would render at the START!\n };\n\n _proto.totalProgress = function totalProgress(value, suppressEvents) {\n return arguments.length ? this.totalTime(this.totalDuration() * value, suppressEvents) : this.totalDuration() ? Math.min(1, this._tTime / this._tDur) : this.rawTime() >= 0 && this._initted ? 1 : 0;\n };\n\n _proto.progress = function progress(value, suppressEvents) {\n return arguments.length ? this.totalTime(this.duration() * (this._yoyo && !(this.iteration() & 1) ? 1 - value : value) + _elapsedCycleDuration(this), suppressEvents) : this.duration() ? Math.min(1, this._time / this._dur) : this.rawTime() > 0 ? 1 : 0;\n };\n\n _proto.iteration = function iteration(value, suppressEvents) {\n var cycleDuration = this.duration() + this._rDelay;\n\n return arguments.length ? this.totalTime(this._time + (value - 1) * cycleDuration, suppressEvents) : this._repeat ? _animationCycle(this._tTime, cycleDuration) + 1 : 1;\n } // potential future addition:\n // isPlayingBackwards() {\n // \tlet animation = this,\n // \t\torientation = 1; // 1 = forward, -1 = backward\n // \twhile (animation) {\n // \t\torientation *= animation.reversed() || (animation.repeat() && !(animation.iteration() & 1)) ? -1 : 1;\n // \t\tanimation = animation.parent;\n // \t}\n // \treturn orientation < 0;\n // }\n ;\n\n _proto.timeScale = function timeScale(value, suppressEvents) {\n if (!arguments.length) {\n return this._rts === -_tinyNum ? 0 : this._rts; // recorded timeScale. Special case: if someone calls reverse() on an animation with timeScale of 0, we assign it -_tinyNum to remember it's reversed.\n }\n\n if (this._rts === value) {\n return this;\n }\n\n var tTime = this.parent && this._ts ? _parentToChildTotalTime(this.parent._time, this) : this._tTime; // make sure to do the parentToChildTotalTime() BEFORE setting the new _ts because the old one must be used in that calculation.\n // future addition? Up side: fast and minimal file size. Down side: only w
1141orks on this animation; if a timeline is reversed, for example, its childrens' onReverse wouldn't get called.\n //(+value < 0 && this._rts >= 0) && _callback(this, \"onReverse\", true);\n // prioritize rendering where the parent's playhead lines up instead of this._tTime because there could be a tween that's animating another tween's timeScale in the same rendering loop (same parent), thus if the timeScale tween renders first, it would alter _start BEFORE _tTime was set on that tick (in the rendering loop), effectively freezing it until the timeScale tween finishes.\n\n this._rts = +value || 0;\n this._ts = this._ps || value === -_tinyNum ? 0 : this._rts; // _ts is the functional timeScale which would be 0 if the animation is paused.\n\n this.totalTime(_clamp(-Math.abs(this._delay), this.totalDuration(), tTime), suppressEvents !== false);\n\n _setEnd(this); // if parent.smoothChildTiming was false, the end time didn't get updated in the _alignPlayhead() method, so do it here.\n\n\n return _recacheAncestors(this);\n };\n\n _proto.paused = function paused(value) {\n if (!arguments.length) {\n return this._ps;\n } // possible future addition - if an animation is removed from its parent and then .restart() or .play() or .resume() is called, perhaps we should force it back into the globalTimeline but be careful because what if it's already at its end? We don't want it to just persist forever and not get released for GC.\n // !this.parent && !value && this._tTime < this._tDur && this !== _globalTimeline && _globalTimeline.add(this);\n\n\n if (this._ps !== value) {\n this._ps = value;\n\n if (value) {\n this._pTime = this._tTime || Math.max(-this._delay, this.rawTime()); // if the pause occurs during the delay phase, make sure that's factored in when resuming.\n\n this._ts = this._act = 0; // _ts is the functional timeScale, so a paused tween would effectively have a timeScale of 0. We record the \"real\" timeScale as _rts (recorded time scale)\n } else {\n _wake();\n\n this._ts = this._rts; //only defer to _pTime (pauseTime) if tTime is zero. Remember, someone could pause() an animation, then scrub the playhead and resume(). If the parent doesn't have smoothChildTiming, we render at the rawTime() because the startTime won't get updated.\n\n this.totalTime(this.parent && !this.parent.smoothChildTiming ? this.rawTime() : this._tTime || this._pTime, this.progress() === 1 && Math.abs(this._zTime) !== _tinyNum && (this._tTime -= _tinyNum)); // edge case: animation.progress(1).pause().play() wouldn't render again because the playhead is already at the end, but the call to totalTime() below will add it back to its parent...and not remove it again (since removing only happens upon rendering at a new time). Offsetting the _tTime slightly is done simply to cause the final render in totalTime() that'll pop it off its timeline (if autoRemoveChildren is true, of course). Check to make sure _zTime isn't -_tinyNum to avoid an edge case where the playhead is pushed to the end but INSIDE a tween/callback, the timeline itself is paused thus halting rendering and leaving a few unrendered. When resuming, it wouldn't render those otherwise.\n }\n }\n\n return this;\n };\n\n _proto.startTime = function startTime(value) {\n if (arguments.length) {\n this._start = _roundPrecise(value);\n var parent = this.parent || this._dp;\n parent && (parent._sort || !this.parent) && _addToTimeline(parent, this, this._start - this._delay);\n return this;\n }\n\n return this._start;\n };\n\n _proto.endTime = function endTime(includeRepeats) {\n return this._start + (_isNotFalse(includeRepeats) ? this.totalDuration() : this.duration()) / Math.abs(this._ts || 1);\n };\n\n _proto.rawTime = function rawTime(wrapRepeats) {\n var parent = this.parent || this._dp; // _dp = detached parent\n\n return !parent ? this._tTime : wrapRepeats && (!this._ts || this._repeat && this._time && this.totalProgress() < 1) ? this._tTime % (this._dur + this._rDelay) : !this._ts ? this._tTime : _parentToChildTotalTime(parent.rawTime(wrapRepeats), this);\n };\n\n _proto.revert = function revert(config) {\n if (config === void 0) {\n config = _revertConfig;\n }\n\n var prevIsReverting = _reverting;\n _reverting = config;\n\n if (_isRevertWorthy(this)) {\n this.timeline && this.timeline.revert(config);\n this.totalTime(-0.01, config.suppressEvents);\n }\n\n this.data !== \"nested\" && config.kill !== false && this.kill();\n _reverting = prevIsReverting;\n return this;\n };\n\n _proto.globalTime = function globalTime(rawTime) {\n var animation = this,\n time = arguments.length ? rawTime : animation.rawTime();\n\n while (animation) {\n time = animation._start + time / (Math.abs(animation._ts) || 1
1141);\n animation = animation._dp;\n }\n\n return !this.parent && this._sat ? this._sat.globalTime(rawTime) : time; // the _startAt tweens for .fromTo() and .from() that have immediateRender should always be FIRST in the timeline (important for context.revert()). \"_sat\" stands for _startAtTween, referring to the parent tween that created the _startAt. We must discern if that tween had immediateRender so that we can know whether or not to prioritize it in revert().\n };\n\n _proto.repeat = function repeat(value) {\n if (arguments.length) {\n this._repeat = value === Infinity ? -2 : value;\n return _onUpdateTotalDuration(this);\n }\n\n return this._repeat === -2 ? Infinity : this._repeat;\n };\n\n _proto.repeatDelay = function repeatDelay(value) {\n if (arguments.length) {\n var time = this._time;\n this._rDelay = value;\n\n _onUpdateTotalDuration(this);\n\n return time ? this.time(time) : this;\n }\n\n return this._rDelay;\n };\n\n _proto.yoyo = function yoyo(value) {\n if (arguments.length) {\n this._yoyo = value;\n return this;\n }\n\n return this._yoyo;\n };\n\n _proto.seek = function seek(position, suppressEvents) {\n return this.totalTime(_parsePosition(this, position), _isNotFalse(suppressEvents));\n };\n\n _proto.restart = function restart(includeDelay, suppressEvents) {\n this.play().totalTime(includeDelay ? -this._delay : 0, _isNotFalse(suppressEvents));\n this._dur || (this._zTime = -_tinyNum); // ensures onComplete fires on a zero-duration animation that gets restarted.\n\n return this;\n };\n\n _proto.play = function play(from, suppressEvents) {\n from != null && this.seek(from, suppressEvents);\n return this.reversed(false).paused(false);\n };\n\n _proto.reverse = function reverse(from, suppressEvents) {\n from != null && this.seek(from || this.totalDuration(), suppressEvents);\n return this.reversed(true).paused(false);\n };\n\n _proto.pause = function pause(atTime, suppressEvents) {\n atTime != null && this.seek(atTime, suppressEvents);\n return this.paused(true);\n };\n\n _proto.resume = function resume() {\n return this.paused(false);\n };\n\n _proto.reversed = function reversed(value) {\n if (arguments.length) {\n !!value !== this.reversed() && this.timeScale(-this._rts || (value ? -_tinyNum : 0)); // in case timeScale is zero, reversing would have no effect so we use _tinyNum.\n\n return this;\n }\n\n return this._rts < 0;\n };
1141\n\n _proto.invalidate = function invalidate() {\n this._initted = this._act = 0;\n this._zTime = -_tinyNum;\n return this;\n };\n\n _proto.isActive = function isActive() {\n var parent = this.parent || this._dp,\n start = this._start,\n rawTime;\n return !!(!parent || this._ts && this._initted && parent.isActive() && (rawTime = parent.rawTime(true)) >= start && rawTime < this.endTime(true) - _tinyNum);\n };\n\n _proto.eventCallback = function eventCallback(type, callback, params) {\n var vars = this.vars;\n\n if (arguments.length > 1) {\n if (!callback) {\n delete vars[type];\n } else {\n vars[type] = callback;\n params && (vars[type + \"Params\"] = params);\n type === \"onUpdate\" && (this._onUpdate = callback);\n }\n\n return this;\n }\n\n return vars[type];\n };\n\n _proto.then = function then(onFulfilled) {\n var self = this,\n prevProm = self._prom;\n return new Promise(function (resolve) {\n var f = _isFunction(onFulfilled) ? onFulfilled : _passThrough,\n _resolve = function _resolve() {\n var _then = self.then;\n self.then = null; // temporarily null the then() method to avoid an infinite loop (see https://github.com/greensock/GSAP/issues/322)\n\n prevProm && prevProm();\n _isFunction(f) && (f = f(self)) && (f.then || f === self) && (self.then = _then);\n resolve(f);\n self.then = _then;\n };\n\n if (self._initted && self.totalProgress() === 1 && self._ts >= 0 || !self._tTime && self._ts < 0) {\n _resolve();\n } else {\n self._prom = _resolve;\n }\n });\n };\n\n _proto.kill = function kill() {\n _interrupt(this);\n };\n\n return Animation;\n}();\n\n_setDefaults(Animation.prototype, {\n _time: 0,\n _start: 0,\n _end: 0,\n _tTime: 0,\n _tDur: 0,\n _dirty: 0,\n _repeat: 0,\n _yoyo: false,\n parent: null,\n _initted: false,\n _rDelay: 0,\n _ts: 1,\n _dp: 0,\n ratio: 0,\n _zTime: -_tinyNum,\n _prom: 0,\n _ps: false,\n _rts: 1\n});\n/*\n * -------------------------------------------------\n * TIMELINE\n * -------------------------------------------------\n */\n\n\nvar Timeline = /*#__PURE__*/function (_Animation) {\n _inheritsLoose(Timeline, _Animation);\n\n function Timeline(vars, position) {\n var _this;\n\n if (vars === void 0) {\n vars = {};\n }\n\n _this = _Animation.call(this, vars) || this;\n _this.labels = {};\n _this.smoothChildTiming = !!vars.smoothChildTiming;\n _this.autoRemoveChildren = !!vars.autoRemoveChildren;\n _this._sort = _isNotFalse(vars.sortChildren);\n _globalTimeline && _addToTimeline(vars.parent || _globalTimeline, _assertThisInitialized(_this), position);\n vars.reversed && _this.reverse();\n vars.paused && _this.paused(true);\n vars.scrollTrigger && _scrollTrigger(_assertThisInitialized(_this), vars.scrollTrigger);\n return _this;\n }\n\n var _proto2 = Timeline.prototype;\n\n _proto2.to = function to(targets, vars, position) {\n _createTweenType(0, arguments, this);\n\n return this;\n };\n\n _proto2.from = function from(targets, vars, position) {\n _createTweenType(1, arguments, this);\n\n return this;\n };\n\n _proto2.fromTo = function fromTo(targets, fromVars, toVars, position) {\n _createTweenType(2, arguments, this);\n\n return this;\n };\n\n _proto2.set = function set(targets, vars, position) {\n vars.duration = 0;\n vars.parent = this;\n _inheritDefaults(vars).repeatDelay || (vars.repeat = 0);\n vars.immediateRender = !!vars.immediateRender;\n new Tween(targets, vars, _parsePosition(this, position), 1);\n return this;\n };\n\n _proto2.call = function call(callback, params, position) {\n return _addToTimeline(this, Tween.delayedCall(0, callback, params), position);\n } //ONLY for backward compatibility! Maybe delete?\n ;\n\n _proto2.staggerTo = function staggerTo(targets, duration, vars, stagger, position, onCompleteAll, onCompleteAllParams) {\n vars.duration = duration;\n vars.stagger = vars.stagger || stagger;\n vars.onComplete = onCompleteAll;\n vars.onCompleteParams = onCompleteAllParams;\n vars.parent = this;\n new Tween(targets, vars, _parsePosition(this, position));\n return this;\n };\n\n _proto2.staggerFrom = function staggerFrom(targets, duration, vars, stagger, position, onCompleteAll, onCompleteAllParams) {\n vars.runBackwards = 1;\n _inheritDefaults(vars).immediateRender = _isNotFalse(vars.immediateRender);\n return this.staggerTo(targets, duration, vars, stagger, position, onCompleteAll, onCompleteAllParams);\n };\n\n _proto2.staggerFromTo = function staggerFromTo(targets, duration, fromVars, toVars, stagger, position, onCompleteAll, onCompleteAllParams) {\n toVars.startAt = fromVars;\n _inheritDefaults(toVars).immediateRender = _isNotFalse(toVars.immediateRender);\n return this.staggerTo(targets, duration, toVars, stagger, position, onCompleteAll, onCompleteAllParams);\n };\n\n _proto2.render = function render(totalTime, suppressEvents, force) {\n var prevTime = this._time,\n tDur = this._dirty ? this.totalDuration() : this._tDur,\n dur = this._dur,\n tTime = totalTime <= 0 ? 0 : _roundPrecise(totalTime),\n // if a paused timeline is resumed (or its _start is updated for another reason...which rounds it), that could result in the playhead shifting a **tiny** amount and a zero-duration child at that spot may get rendered at a different ratio, like its totalTime in render() may be 1e-17 instead of 0, for example.\n crossingStart = this._zTime < 0 !== totalTime < 0 && (this._initted || !dur),\n time,\n child,\n next,\n iteration,\n cycleDuration,\n prevPaused,\n pauseTween,\n timeScale,\n prevStart,\n prevIteration,\n yoyo,\n isYoyo;\n this !== _globalTimeline && tTime > tDur && totalTime >= 0 && (tTime = tDur);\n\n if (tTime !== this._tTime || force || crossingStart) {\n if (prevTime !== this._time && dur) {\n //if totalDuration() finds a child with a negative startTime and smoothChildTiming is true, things get shifted around internally so we need to adjust the time accordingly. For example, if a tween starts at -30 we must shift EVERYTHING forward 30 seconds and move this timeline's startTime backward by 30 seconds so that things align with the playhead (no jump).\n tTime += this._time - prevTime;
1141\n totalTime += this._time - prevTime;\n }\n\n time = tTime;\n prevStart = this._start;\n timeScale = this._ts;\n prevPaused = !timeScale;\n\n if (crossingStart) {\n dur || (prevTime = this._zTime); //when the playhead arrives at EXACTLY time 0 (right on top) of a zero-duration timeline, we need to discern if events are suppressed so that when the playhead moves again (next time), it'll trigger the callback. If events are NOT suppressed, obviously the callback would be triggered in this render. Basically, the callback should fire either when the playhead ARRIVES or LEAVES this exact spot, not both. Imagine doing a timeline.seek(0) and there's a callback that sits at 0. Since events are suppressed on that seek() by default, nothing will fire, but when the playhead moves off of that position, the callback should fire. This behavior is what people intuitively expect.\n\n (totalTime || !suppressEvents) && (this._zTime = totalTime);\n }\n\n if (this._repeat) {\n //adjust the time for repeats and yoyos\n yoyo = this._yoyo;\n cycleDuration = dur + this._rDelay;\n\n if (this._repeat < -1 && totalTime < 0) {\n return this.totalTime(cycleDuration * 100 + totalTime, suppressEvents, force);\n }\n\n time = _roundPrecise(tTime % cycleDuration); //round to avoid floating point errors. (4 % 0.8 should be 0 but some browsers report it as 0.79999999!)\n\n if (tTime === tDur) {\n // the tDur === tTime is for edge cases where there's a lengthy decimal on the duration and it may reach the very end but the time is rendered as not-quite-there (remember, tDur is rounded to 4 decimals whereas dur isn't)\n iteration = this._repeat;\n time = dur;\n } else {\n prevIteration = _roundPrecise(tTime / cycleDuration); // full decimal version of iterations, not the previous iteration (we're reusing prevIteration variable for efficiency)\n\n iteration = ~~prevIteration;\n\n if (iteration && iteration === prevIteration) {\n time = dur;\n iteration--;\n }\n\n time > dur && (time = dur);\n }\n\n prevIteration = _animationCycle(this._tTime, cycleDuration);\n !prevTime && this._tTime && prevIteration !== iteration && this._tTime - prevIteration * cycleDuration - this._dur <= 0 && (prevIteration = iteration); // edge case - if someone does addPause() at the very beginning of a repeating timeline, that pause is technically at the same spot as the end which causes this._time to get set to 0 when the totalTime would normally place the playhead at the end. See https://gsap.com/forums/topic/23823-closing-nav-animation-not-working-on-ie-and-iphone-6-maybe-other-older-browser/?tab=comments#comment-113005 also, this._tTime - prevIteration * cycleDuration - this._dur <= 0 just checks to make sure it wasn't previously in the \"repeatDelay\" portion\n\n if (yoyo && iteration & 1) {\n time = dur - time;\n isYoyo = 1;\n }\n /*\n make sure children at the end/beginning of the timeline are rendered properly. If, for example,\n a 3-second long timeline rendered at 2.9 seconds previously, and now renders at 3.2 seconds (which\n would get translated to 2.8 seconds if the timeline yoyos or 0.2 seconds if it just repeats), there\n could be a callback or a short tween that's at 2.95 or 3 seconds in which wouldn't render. So\n we need to push the timeline to the end (and/or beginning depending on its yoyo value). Also we must\n ensure that zero-duration tweens at the very beginning or end of the Timeline work.\n */\n\n\n if (iteration !== prevIteration && !this._lock) {\n var rewinding = yoyo && prevIteration & 1,\n doesWrap = rewinding === (yoyo && iteration & 1);\n iteration < prevIteration && (rewinding = !rewinding);\n prevTime = rewinding ? 0 : tTime % dur ? dur : tTime; // if the playhead is landing exactly at the end of an iteration, use that totalTime rather than only the duration, otherwise it'll skip the 2nd render since it's effectively at the same time.\n\n this._lock = 1;\n this.render(prevTime || (isYoyo ? 0 : _roundPrecise(iteration * cycleDuration)), suppressEvents, !dur)._lock = 0;\n this._tTime = tTime; // if a user gets the iteration() inside the onRepeat, for example, it should be accurate.\n\n !suppressEvents && this.parent && _callback(this, \"onRepeat\");\n\n if (this.vars.repeatRefresh && !isYoyo) {\n this.invalidate()._lock = 1;\n prevIteration = iteration; // otherwise, the onStart() may fire on the 2nd iteration.\n }\n\n if (prevTime && prevTime !== this._time || prevPaused !== !this._ts || this.vars.onRepeat && !this.parent && !this._act) {\n // if prevTime is 0 and we render at the very end, _time will be the end, thus won't match. So in this edge c
1141ase, prevTime won't match _time but that's okay. If it gets killed in the onRepeat, eject as well.\n return this;\n }\n\n dur = this._dur; // in case the duration changed in the onRepeat\n\n tDur = this._tDur;\n\n if (doesWrap) {\n this._lock = 2;\n prevTime = rewinding ? dur : -0.0001;\n this.render(prevTime, true);\n this.vars.repeatRefresh && !isYoyo && this.invalidate();\n }\n\n this._lock = 0;\n\n if (!this._ts && !prevPaused) {\n return this;\n }\n }\n }\n\n if (this._hasPause && !this._forcing && this._lock < 2) {\n pauseTween = _findNextPauseTween(this, _roundPrecise(prevTime), _roundPrecise(time));\n\n if (pauseTween) {\n tTime -= time - (time = pauseTween._start);\n }\n }\n\n this._tTime = tTime;\n this._time = time;\n this._act = !!timeScale; // as long as it's not paused, force it to be active so that if the user renders independent of the parent timeline, it'll be forced to re-render on the next tick.\n\n if (!this._initted) {\n this._onUpdate = this.vars.onUpdate;\n this._initted = 1;\n this._zTime = totalTime;\n prevTime = 0; // upon init, the playhead should always go forward;
1141 someone could invalidate() a completed timeline and then if they restart(), that would make child tweens render in reverse order which could lock in the wrong starting values if they build on each other, like tl.to(obj, {x: 100}).to(obj, {x: 0}).\n }\n\n if (!prevTime && tTime && dur && !suppressEvents && !prevIteration) {\n _callback(this, \"onStart\");\n\n if (this._tTime !== tTime) {\n // in case the onStart triggered a render at a different spot, eject. Like if someone did animation.pause(0.5) or something inside the onStart.\n return this;\n }\n }\n\n if (time >= prevTime && totalTime >= 0) {\n child = this._first;\n\n while (child) {\n next = child._next;\n\n if ((child._act || time >= child._start) && child._ts && pauseTween !== child) {\n if (child.parent !== this) {\n // an extreme edge case - the child's render could do something like kill() the \"next\" one in the linked list, or reparent it. In that case we must re-initiate the whole render to be safe.\n return this.render(totalTime, suppressEvents, force);\n }\n\n child.render(child._ts > 0 ? (time - child._start) * child._ts : (child._dirty ? child.totalDuration() : child._tDur) + (time - child._start) * child._ts, suppressEvents, force);\n\n if (time !== this._time || !this._ts && !prevPaused) {\n //in case a tween pauses or seeks the timeline when rendering, like inside of an onUpdate/onComplete\n pauseTween = 0;\n next && (tTime += this._zTime = -_tinyNum); // it didn't finish rendering, so flag zTime as negative so that the next time render() is called it'll be forced (to render any remaining children)\n\n break;\n }\n }\n\n child = next;\n }\n } else {\n child = this._last;\n var adjustedTime = totalTime < 0 ? totalTime : time; //when the playhead goes backward beyond the start of this timeline, we must pass that information down to the child animations so that zero-duration tweens know whether to render their starting or ending values.\n\n while (child) {\n next = child._prev;\n\n if ((child._act || adjustedTime <= child._end) && child._ts && pauseTween !== child) {\n if (child.parent !== this) {\n // an extreme edge case - the child's render could do something like kill() the \"next\" one in the linked list, or reparent it. In that case we must re-initiate the whole render to be safe.\n return this.render(totalTime, suppressEvents, force);\n }\n\n child.render(child._ts > 0 ? (adjustedTime - child._start) * child._ts : (child._dirty ? child.totalDuration() : child._tDur) + (adjustedTime - child._start) * child._ts, suppressEvents, force || _reverting && _isRevertWorthy(child)); // if reverting, we should always force renders of initted tweens (but remember that .fromTo() or .from() may have a _startAt but not _initted yet). If, for example, a .fromTo() tween with a stagger (which creates an internal timeline) gets reverted BEFORE some of its child tweens render for the first time, it may not properly trigger them to revert.\n\n if (time !== this._time || !this._ts && !prevPaused) {\n //in case a tween pauses or seeks the timeline when rendering, like inside of an onUpdate/onComplete\n pauseTween = 0;\n next && (tTime += this._zTime = adjustedTime ? -_tinyNum : _tinyNum); // it didn't finish rendering, so adjust zTime so that so that the next time render() is called it'll be forced (to render any remaining children)\n\n break;\n }\n }\n\n child = next;\n }\n }\n\n if (pauseTween && !suppressEvents) {\n this.pause();\n pauseTween.render(time >= prevTime ? 0 : -_tinyNum)._zTime = time >= prevTime ? 1 : -1;\n\n if (this._ts) {\n //the callback resumed playback! So since we may have held back the playhead due to where the pause is positioned, go ahead and jump to where it's SUPPOSED to be (if no pause happened).\n this._start = prevStart; //if the pause was at an earlier time and the user resumed in the callback, it could reposition the timeline (changing its startTime), throwing things off slightly, so we make sure the _start doesn't shift.\n\n _setEnd(this);\n\n return this.render(totalTime, suppressEvents, force);\n }\n }
1141\n\n this._onUpdate && !suppressEvents && _callback(this, \"onUpdate\", true);\n if (tTime === tDur && this._tTime >= this.totalDuration() || !tTime && prevTime) if (prevStart === this._start || Math.abs(timeScale) !== Math.abs(this._ts)) if (!this._lock) {\n // remember, a child's callback may alter this timeline's playhead or timeScale which is why we need to add some of these checks.\n (totalTime || !dur) && (tTime === tDur && this._ts > 0 || !tTime && this._ts < 0) && _removeFromParent(this, 1); // don't remove if the timeline is reversed and the playhead isn't at 0, otherwise tl.progress(1).reverse() won't work. Only remove if the playhead is at the end and timeScale is positive, or if the playhead is at 0 and the timeScale is negative.\n\n if (!suppressEvents && !(totalTime < 0 && !prevTime) && (tTime || prevTime || !tDur)) {\n _callback(this, tTime === tDur && totalTime >= 0 ? \"onComplete\" : \"onReverseComplete\", true);\n\n this._prom && !(tTime < tDur && this.timeScale() > 0) && this._prom();\n }\n }\n }\n\n return this;\n };\n\n _proto2.add = function add(child, position) {\n var _this2 = this;\n\n _isNumber(position) || (position = _parsePosition(this, position, child));\n\n if (!(child instanceof Animation)) {\n if (_isArray(child)) {\n child.forEach(function (obj) {\n return _this2.add(obj, position);\n });\n return this;\n }\n\n if (_isString(child)) {\n return this.addLabel(child, position);\n }\n\n if (_isFunction(child)) {\n child = Tween.delayedCall(0, child);\n } else {\n return this;\n }\n }\n\n return this !== child ? _addToTimeline(this, child, position) : this; //don't allow a timeline to be added to itself as a child!\n };\n\n _proto2.getChildren = function getChildren(nested, tweens, timelines, ignoreBeforeTime) {\n if (nested === void 0) {\n nested = true;\n }\n\n if (tweens === void 0) {\n tweens = true;\n }\n\n if (timelines === void 0) {\n timelines = true;\n }\n\n if (ignoreBeforeTime === void 0) {\n ignoreBeforeTime = -_bigNum;\n }\n\n var a = [],\n child = this._first;\n\n while (child) {\n if (child._start >= ignoreBeforeTime) {\n if (child instanceof Tween) {\n tweens && a.push(child);\n } else {\n timelines && a.push(child);\n nested && a.push.apply(a, child.getChildren(true, tweens, timelines));\n }\n }\n\n child = child._next;\n }\n\n return a;\n };\n\n _proto2.getById = function getById(id) {\n var animations = this.getChildren(1, 1, 1),\n i = animations.length;\n\n while (i--) {\n if (animations[i].vars.id === id) {\n return animations[i];\n }\n }\n };\n\n _proto2.remove = function remove(child) {\n if (_isString(child)) {\n return this.removeLabel(child);\n }\n\n if (_isFunction(child)) {\n return this.killTweensOf(child);\n }\n\n child.parent === this && _removeLinkedListItem(this, child);\n\n if (child === this._recent) {\n this._recent = this._last;\n }\n\n return _uncache(this);\n };\n\n _proto2.totalTime = function totalTime(_totalTime2, suppressEvents) {\n if (!arguments.length) {\n return this._tTime;\n }\n\n this._forcing = 1;\n\n if (!this._dp && this._ts) {\n //special case for the global timeline (or any other that has no parent or detached parent).\n this._start = _roundPrecise(_ticker.time - (this._ts > 0 ? _totalTime2 / this._ts : (this.totalDuration() - _totalTime2) / -this._ts));\n }\n\n _Animation.prototype.totalTime.call(this, _totalTime2, suppressEvents);\n\n this._forcing = 0;\n return this;\n };\n\n _proto2.addLabel = function addLabel(label, position) {\n this.labels[label] = _parsePosition(this, position);\n return this;\n };\n\n _proto2.removeLabel = function removeLabel(label) {\n delete this.labels[label];\n return this;\n };\n\n _proto2.addPause = function addPause(position, callback, params) {\n var t = Tween.delayedCall(0, callback || _emptyFunc, params);
1141\n t.data = \"isPause\";\n this._hasPause = 1;\n return _addToTimeline(this, t, _parsePosition(this, position));\n };\n\n _proto2.removePause = function removePause(position) {\n var child = this._first;\n position = _parsePosition(this, position);\n\n while (child) {\n if (child._start === position && child.data === \"isPause\") {\n _removeFromParent(child);\n }\n\n child = child._next;\n }\n };\n\n _proto2.killTweensOf = function killTweensOf(targets, props, onlyActive) {\n var tweens = this.getTweensOf(targets, onlyActive),\n i = tweens.length;\n\n while (i--) {\n _overwritingTween !== tweens[i] && tweens[i].kill(targets, props);\n }\n\n return this;\n };\n\n _proto2.getTweensOf = function getTweensOf(targets, onlyActive) {\n var a = [],\n parsedTargets = toArray(targets),\n child = this._first,\n isGlobalTime = _isNumber(onlyActive),\n // a number is interpreted as a global time. If the animation spans\n children;\n\n while (child) {\n if (child instanceof Tween) {\n if (_arrayContainsAny(child._targets, parsedTargets) && (isGlobalTime ? (!_overwritingTween || child._initted && child._ts) && child.globalTime(0) <= onlyActive && child.globalTime(child.totalDuration()) > onlyActive : !onlyActive || child.isActive())) {\n // note: if this is for overwriting, it should only be for tweens that aren't paused and are initted.\n a.push(child);\n }\n } else if ((children = child.getTweensOf(parsedTargets, onlyActive)).length) {\n a.push.apply(a, children);\n }\n\n child = child._next;\n }\n\n return a;\n } // potential future feature - targets() on timelines\n // targets() {\n // \tlet result = [];\n // \tthis.getChildren(true, true, false).forEach(t => result.push(...t.targets()));\n // \treturn result.filter((v, i) => result.indexOf(v) === i);\n // }\n ;\n\n _proto2.tweenTo = function tweenTo(position, vars) {\n vars = vars || {};\n\n var tl = this,\n endTime = _parsePosition(tl, position),\n _vars = vars,\n startAt = _vars.startAt,\n _onStart = _vars.onStart,\n onStartParams = _vars.onStartParams,\n immediateRender = _vars.immediateRender,\n initted,\n tween = Tween.to(tl, _setDefaults({\n ease: vars.ease || \"none\",\n lazy: false,\n immediateRender: false,\n time: endTime,\n overwrite: \"auto\",\n duration: vars.duration || Math.abs((endTime - (startAt && \"time\" in startAt ? startAt.time : tl._time)) / tl.timeScale()) || _tinyNum,\n onStart: function onStart() {\n tl.pause();\n\n if (!initted) {\n var duration = vars.duration || Math.abs((endTime - (startAt && \"time\" in startAt ? startAt.time : tl._time)) / tl.timeScale());\n tween._dur !== duration && _setDuration(tween, duration, 0, 1).render(tween._time, true, true);\n initted = 1;\n }\n\n _onStart && _onStart.apply(tween, onStartParams || []); //in case the user had an onStart in the vars - we don't want to overwrite it.\n }\n }, vars));\n\n return immediateRender ? tween.render(0) : tween;\n };\n\n _proto2.tweenFromTo = function tweenFromTo(fromPosition, toPosition, vars) {\n return this.tweenTo(toPosition, _setDefaults({\n startAt: {\n time: _parsePosition(this, fromPosition)\n }\n }, vars));\n };\n\n _proto2.recent = function recent() {\n return this._recent;\n };\n\n _proto2.nextLabel = function nextLabel(afterTime) {\n if (afterTime === void 0) {\n afterTime = this._time;\n }\n\n return _getLabelInDirection(this, _parsePosition(this, afterTime));\n };\n\n _proto2.previousLabel = function previousLabel(beforeTime) {\n if (beforeTime === void 0) {\n beforeTime = this._time;\n }\n\n return _getLabelInDirection(this, _parsePosition(this, beforeTime), 1);\n };\n\n _proto2.currentLabel = function currentLabel(value) {\n return arguments.length ? this.seek(value, true) : this.previousLabel(this._time + _tinyNum);\n };\n\n _proto2.shiftChildren = function shiftChildren(amount, adjustLabels, ignoreBeforeTime) {\n if (ignoreBeforeTime === void 0) {\n ignoreBeforeTime = 0;\n }\n\n var child = this._first,\n labels = this.labels,\n p;\n amount = _roundPrecise(amount);\n\n while (child) {\n if (child._start >= ignoreBeforeTime) {\n child._start += amount;
1141\n child._end += amount;\n }\n\n child = child._next;\n }\n\n if (adjustLabels) {\n for (p in labels) {\n if (labels[p] >= ignoreBeforeTime) {\n labels[p] += amount;\n }\n }\n }\n\n return _uncache(this);\n };\n\n _proto2.invalidate = function invalidate(soft) {\n var child = this._first;\n this._lock = 0;\n\n while (child) {\n child.invalidate(soft);\n child = child._next;\n }\n\n return _Animation.prototype.invalidate.call(this, soft);\n };\n\n _proto2.clear = function clear(includeLabels) {\n if (includeLabels === void 0) {\n includeLabels = true;\n }\n\n var child = this._first,\n next;\n\n while (child) {\n next = child._next;\n this.remove(child);\n child = next;\n }\n\n this._dp && (this._time = this._tTime = this._pTime = 0);\n includeLabels && (this.labels = {});\n return _uncache(this);\n };\n\n _proto2.totalDuration = function totalDuration(value) {\n var max = 0,\n self = this,\n child = self._last,\n prevStart = _bigNum,\n prev,\n start,\n parent;\n\n if (arguments.length) {\n return self.timeScale((self._repeat < 0 ? self.duration() : self.totalDuration()) / (self.reversed() ? -value : value));\n }\n\n if (self._dirty) {\n parent = self.parent;\n\n while (child) {\n prev = child._prev; //record it here in case the tween changes position in the sequence...\n\n child._dirty && child.totalDuration(); //could change the tween._startTime, so make sure the animation's cache is clean before analyzing it.\n\n start = child._start;\n\n if (start > prevStart && self._sort && child._ts && !self._lock) {\n //in case one of the tweens shifted out of order, it needs to be re-inserted into the correct position in the sequence\n self._lock = 1; //prevent endless recursive calls - there are methods that get triggered that check duration/totalDuration when we add().\n\n _addToTimeline(self, child, start - child._delay, 1)._lock = 0;\n } else {\n prevStart = start;\n }\n\n if (start < 0 && child._ts) {\n //children aren't allowed to have negative startTimes unless smoothChildTiming is true, so adjust here if one is found.\n max -= start;\n\n if (!parent && !self._dp || parent && parent.smoothChildTiming) {\n self._start += _roundPrecise(start / self._ts);\n self._time -= start;\n self._tTime -= start;\n }\n\n self.shiftChildren(-start, false, -1e999);\n prevStart = 0;\n }\n\n child._end > max && child._ts && (max = child._end);\n child = prev;\n }\n\n _setDuration(self, self === _globalTimeline && self._time > max ? self._time : max, 1, 1);\n\n self._dirty = 0;\n }\n\n return self._tDur;\n };\n\n Timeline.updateRoot = function updateRoot(time) {\n if (_globalTimeline._ts) {\n _lazySafeRender(_globalTimeline, _parentToChildTotalTime(time, _globalTimeline));\n\n _lastRenderedFrame = _ticker.frame;\n }\n\n if (_ticker.frame >= _nextGCFrame) {\n _nextGCFrame += _config.autoSleep || 120;\n var child = _globalTimeline._first;\n if (!child || !child._ts) if (_config.autoSleep && _ticker._listeners.length < 2) {\n while (child && !child._ts) {\n child = child._next;\n }\n\n child || _ticker.sleep();\n }\n }\n };\n\n return Timeline;\n}(Animation);\n\n_setDefaults(Timeline.prototype, {\n _lock: 0,\n _hasPause: 0,\n _forcing: 0\n});\n\nvar _addComplexStringPropTween = function _addComplexStringPropTween(target, prop, start, end, setter, stringFilter, funcParam) {\n //note: we call _addComplexStringPropTween.call(tweenInstance...) to ensure that it's scoped properly. We may call it from within a plugin too, thus \"this\" would refer to the plugin.\n var pt = new PropTween(this._pt, target, prop, 0, 1, _renderComplexString, null, setter),\n index = 0,\n matchIndex = 0,\n result,\n startNums,\n color,\n endNum,\n chunk,\n startNum,\n hasRandom,\n a;\n pt.b = start;\n pt.e = end;\n start += \"\"; //ensure values are strings\n\n end += \"\";\n\n if (hasRandom = ~end.indexOf(\"random(\")) {\n end = _replaceRandom(end);\n }\n\n if (stringFilter) {\n a = [start, end];\n stringFilter(a, target, prop); //pass an array with the starting and ending values and let the filter do whatever it needs to the values.\
1141n\n start = a[0];\n end = a[1];\n }\n\n startNums = start.match(_complexStringNumExp) || [];\n\n while (result = _complexStringNumExp.exec(end)) {\n endNum = result[0];\n chunk = end.substring(index, result.index);\n\n if (color) {\n color = (color + 1) % 5;\n } else if (chunk.substr(-5) === \"rgba(\") {\n color = 1;\n }\n\n if (endNum !== startNums[matchIndex++]) {\n startNum = parseFloat(startNums[matchIndex - 1]) || 0; //these nested PropTweens are handled in a special way - we'll never actually call a render or setter method on them. We'll just loop through them in the parent complex string PropTween's render method.\n\n pt._pt = {\n _next: pt._pt,\n p: chunk || matchIndex === 1 ? chunk : \",\",\n //note: SVG spec allows omission of comma/space when a negative sign is wedged between two numbers, like 2.5-5.3 instead of 2.5,-5.3 but when tweening, the negative value may switch to positive, so we insert the comma just in case.\n s: startNum,\n c: endNum.charAt(1) === \"=\" ? _parseRelative(startNum, endNum) - startNum : parseFloat(endNum) - startNum,\n m: color && color < 4 ? Math.round : 0\n };\n index = _complexStringNumExp.lastIndex;\n }\n }\n\n pt.c = index < end.length ? end.substring(index, end.length) : \"\"; //we use the \"c\" of the PropTween to store the final part of the string (after the last number)\n\n pt.fp = funcParam;\n\n if (_relExp.test(end) || hasRandom) {\n pt.e = 0; //if the end string contains relative values or dynamic random(...) values, delete the end it so that on the final render we don't actually set it to the string with += or -= characters (forces it to use the calculated value).\n }\n\n this._pt = pt; //start the linked list with this new PropTween. Remember, we call _addComplexStringPropTween.call(tweenInstance...) to ensure that it's scoped properly. We may call it from within a plugin too, thus \"this\" would refer to the plugin.\n\n return pt;\n},\n _addPropTween = function _addPropTween(target, prop, start, end, index, targets, modifier, stringFilter, funcParam, optional) {\n _isFunction(end) && (end = end(index || 0, target, targets));\n var currentValue = target[prop],\n parsedStart = start !== \"get\" ? start : !_isFunction(currentValue) ? currentValue : funcParam ? target[prop.indexOf(\"set\") || !_isFunction(target[\"get\" + prop.substr(3)]) ? prop : \"get\" + prop.substr(3)](funcParam) : target[prop](),\n setter = !_isFunction(currentValue) ? _setterPlain : funcParam ? _setterFuncWithParam : _setterFunc,\n pt;\n\n if (_isString(end)) {\n if (~end.indexOf(\"random(\")) {\n end = _replaceRandom(end);\n }\n\n if (end.charAt(1) === \"=\") {\n pt = _parseRelative(parsedStart, end) + (getUnit(parsedStart) || 0);\n\n if (pt || pt === 0) {\n // to avoid isNaN, like if someone passes in a value like \"!= whatever\"\n end = pt;\n }\n }\n }\n\n if (!optional || parsedStart !== end || _forceAllPropTweens) {\n if (!isNaN(parsedStart * end) && end !== \"\") {\n // fun fact: any number multiplied by \"\" is evaluated as the number 0!\n pt = new PropTween(this._pt, target, prop, +parsedStart || 0, end - (parsedStart || 0), typeof currentValue === \"boolean\" ? _renderBoolean : _renderPlain, 0, setter);\n funcParam && (pt.fp = funcParam);\n modifier && pt.modifier(modifier, this, target);\n return this._pt = pt;\n }\n\n !currentValue && !(prop in target) && _missingPlugin(prop, end);\n return _addComplexStringPropTween.call(this, target, prop, parsedStart, end, setter, stringFilter || _config.stringFilter, funcParam);\n }\n},\n //creates a copy of the vars object and processes any function-based values (putting the resulting values directly into the copy) as well as strings with \"random()\" in them. It does NOT process relative values.\n_processVars = function _processVars(vars, index, target, targets, tween) {\n _isFunction(vars) && (vars = _parseFuncOrString(vars, tween, index, target, targets));\n\n if (!_isObject(vars) || vars.style && vars.nodeType || _isArray(vars) || _isTypedArray(vars)) {\n return _isString(vars) ? _parseFuncOrString(vars, tween, index, target, targets) : vars;\n }\n\n var copy = {},\n p;\n\n for (p in vars) {\n copy[p] = _parseFuncOrString(vars[p], tween, index, target, targets);\n }\n\n return copy;\n},\n _checkPlugin = function _checkPlugin(property, vars, tween, index, target, targets) {\n var plugin, pt, ptLookup, i;\n\n if (_plugins[property] && (plugin = new _plugins[property]()).init(target, plugin.rawVars ? vars[property] : _processVars(vars[property], index, target, targets, tween), tween, index, targets) !== false) {\n tween._pt = pt = new PropTween(tween._pt, target, property, 0, 1, plugin.render, plugin, 0, plugin.priority);\n\n if (tween !== _quickTween) {\n ptLookup = tween._ptLookup[tween._targets.indexOf(target)]; //note: we can't use tween._ptLookup[index] because for staggered tweens, the index from the fullTargets array won't match what it is in each individual tween that spawns from the stagger.\n\n i = plugin._props.length;\n\n while (i--) {\n ptLookup[plugin._props[i]] = pt;\n }\n }\n }\n\n return plugin;\n},\n _overwritingTween,\n //store a reference temporarily so we can avoid overwriting itself.\n_forceAllPropTweens,\n _initTween = function _initTween(tween, time, tTime) {\n var vars = tween.vars,\n ease = vars.ease,\n startAt = vars.startAt,\n immediateRender = vars.immediateRender,\n lazy = vars.lazy,\n onUpdate = vars.onUp
1141date,\n runBackwards = vars.runBackwards,\n yoyoEase = vars.yoyoEase,\n keyframes = vars.keyframes,\n autoRevert = vars.autoRevert,\n dur = tween._dur,\n prevStartAt = tween._startAt,\n targets = tween._targets,\n parent = tween.parent,\n fullTargets = parent && parent.data === \"nested\" ? parent.vars.targets : targets,\n autoOverwrite = tween._overwrite === \"auto\" && !_suppressOverwrites,\n tl = tween.timeline,\n reverseEase = vars.easeReverse || yoyoEase,\n cleanVars,\n i,\n p,\n pt,\n target,\n hasPriority,\n gsData,\n harness,\n plugin,\n ptLookup,\n index,\n harnessVars,\n overwritten;\n tl && (!keyframes || !ease) && (ease = \"none\");\n tween._ease = _parseEase(ease, _defaults.ease);\n tween._rEase = reverseEase && (_parseEase(reverseEase) || tween._ease);\n tween._from = !tl && !!vars.runBackwards; //nested timelines should never run backwards - the backwards-ness is in the child tweens.\n\n if (tween._from) tween.ratio = 1;\n\n if (!tl || keyframes && !vars.stagger) {\n //if there's an internal timeline, skip all the parsing because we passed that task down the chain.\n harness = targets[0] ? _getCache(targets[0]).harness : 0;\n harnessVars = harness && vars[harness.prop]; //someone may need to specify CSS-specific values AND non-CSS values, like if the element has an \"x\" property plus it's a standard DOM element. We allow people to distinguish by wrapping plugin-specific stuff in a css:{} object for example.\n\n cleanVars = _copyExcluding(vars, _reservedProps);\n\n if (prevStartAt) {\n prevStartAt._zTime < 0 && prevStartAt.progress(1); // in case it's a lazy startAt that hasn't rendered yet.\n\n time < 0 && runBackwards && immediateRender && !autoRevert ? prevStartAt.render(-1, true) : prevStartAt.revert(runBackwards && dur ? _revertConfigNoKill : _startAtRevertConfig); // if it's a \"startAt\" (not \"from()\" or runBackwards: true), we only need to do a shallow revert (keep transforms cached in CSSPlugin)\n // don't just _removeFromParent(prevStartAt.render(-1, true)) because that'll leave inline styles. We're creating a new _startAt for \"startAt\" tweens that re-capture things to ensure that if the pre-tween values changed since the tween was created, they're recorded.\n\n prevStartAt._lazy = 0;\n }\n\n if (startAt) {\n _removeFromParent(tween._startAt = Tween.set(targets, _setDefaults({\n data: \"isStart\",\n overwrite: false,\n parent: parent,\n immediateRender: true,\n lazy: !prevStartAt && _isNotFalse(lazy),\n startAt: null,\n delay: 0,\n onUpdate: onUpdate && function () {\n return _callback(tween, \"onUpdate\");\n },\n stagger: 0\n }, startAt))); //copy the properties/values into a new object to avoid collisions, like var to = {x:0}, from = {x:500}; timeline.fromTo(e, from, to).fromTo(e, to, from);\n\n\n tween._startAt._dp = 0; // don't allow it to get put back into root timeline! Like when revert() is called and totalTime() gets set.\n\n tween._startAt._sat = tween; // used in globalTime(). _sat stands for _startAtTween\n\n time < 0 && (_reverting || !immediateRender && !autoRevert) && tween._startAt.revert(_revertConfigNoKill); // rare edge case, like if a render is forced in the negative direction of a non-initted tween.\n\n if (immediateRender) {\n if (dur && time <= 0 && tTime <= 0) {\n // check tTime here because in the case of a yoyo tween whose playhead gets pushed to the end like tween.progress(1), we should allow it through so that the onComplete gets fired properly.\n time && (tween._zTime = time);\n return; //we skip initialization here so that overwriting doesn't occur until the tween actually begins. Otherwise, if you create several immediateRender:true tweens of the same target/properties to drop into a Timeline, the last one created would overwrite the first ones because they didn't get placed into the timeline yet before the first render occurs and kicks in overwriting.\n }\n }\n } else if (runBackwards && dur) {\n // from() tweens must be handled uniquely: their beginning values must be rendered but we don't want overwriting to occur yet (when time is still 0). Wait until the tween actually begins before doing all the routines like overwriting. At that time, we should render at the END of the tween to ensure that things initialize correctly (remember, from() tweens go backwards)\n if (!prevStartAt) {\n time && (immediateRender = false); //in rare cases (like if a from() tween runs and then is invali
1141date()-ed), immediateRender could be true but the initial forced-render gets skipped, so there's no need to force the render in this context when the _time is greater than 0\n\n p = _setDefaults({\n overwrite: false,\n data: \"isFromStart\",\n //we tag the tween with as \"isFromStart\" so that if [inside a plugin] we need to only do something at the very END of a tween, we have a way of identifying this tween as merely the one that's setting the beginning values for a \"from()\" tween. For example, clearProps in CSSPlugin should only get applied at the very END of a tween and without this tag, from(...{height:100, clearProps:\"height\", delay:1}) would wipe the height at the beginning of the tween and after 1 second, it'd kick back in.\n lazy: immediateRender && !prevStartAt && _isNotFalse(lazy),\n immediateRender: immediateRender,\n //zero-duration tweens render immediately by default, but if we're not specifically instructed to render this tween immediately, we should skip this and merely _init() to record the starting values (rendering them immediately would push them to completion which is wasteful in that case - we'd have to render(-1) immediately after)\n stagger: 0,\n parent: parent //ensures that nested tweens that had a stagger are handled properly, like gsap.from(\".class\", {y: gsap.utils.wrap([-100,100]), stagger: 0.5})\n\n }, cleanVars);\n harnessVars && (p[harness.prop] = harnessVars); // in case someone does something like .from(..., {css:{}})\n\n _removeFromParent(tween._startAt = Tween.set(targets, p));\n\n tween._startAt._dp = 0; // don't allow it to get put back into root timeline!\n\n tween._startAt._sat = tween; // used in globalTime()\n\n time < 0 && (_reverting ? tween._startAt.revert(_revertConfigNoKill) : tween._startAt.render(-1, true));\n tween._zTime = time;\n\n if (!immediateRender) {\n _initTween(tween._startAt, _tinyNum, _tinyNum); //ensures that the initial values are recorded\n\n } else if (!time) {\n return;\n }\n }\n }\n\n tween._pt = tween._ptCache = 0;\n lazy = dur && _isNotFalse(lazy) || lazy && !dur;\n\n for (i = 0; i < targets.length; i++) {\n target = targets[i];\n gsData = target._gsap || _harness(targets)[i]._gsap;\n tween._ptLookup[i] = ptLookup = {};\n _lazyLookup[gsData.id] && _lazyTweens.length && _lazyRender(); //if other tweens of the same target have recently initted but haven't rendered yet, we've got to force the render so that the starting values are correct (imagine populating a timeline with a bunch of sequential tweens and then jumping to the end)\n\n index = fullTargets === targets ? i : fullTargets.indexOf(target);\n\n if (harness && (plugin = new harness()).init(target, harnessVars || cleanVars, tween, index, fullTargets) !== false) {\n tween._pt = pt = new PropTween(tween._pt, target, plugin.name, 0, 1, plugin.render, plugin, 0, plugin.priority);\n\n plugin._props.forEach(function (name) {\n ptLookup[name] = pt;\n });\n\n plugin.priority && (hasPriority = 1);\n }\n\n if (!harness || harnessVars) {\n for (p in cleanVars) {\n if (_plugins[p] && (plugin = _checkPlugin(p, cleanVars, tween, index, target, fullTargets))) {\n plugin.priority && (hasPriority = 1);\n } else {\n ptLookup[p] = pt = _addPropTween.call(tween, target, p, \"get\", cleanVars[p], index, fullTargets, 0, vars.stringFilter);\n }\n }\n }\n\n tween._op && tween._op[i] && tween.kill(target, tween._op[i]);\n\n if (autoOverwrite && tween._pt) {\n _overwritingTween = tween;\n\n _globalTimeline.killTweensOf(target, ptLookup, tween.globalTime(time)); // make sure the overwriting doesn't overwrite THIS tween!!!\n\n\n overwritten = !tween.parent;\n _overwritingTween = 0;\n }\n\n tween._pt && lazy && (_lazyLookup[gsData.id] = 1);\n }\n\n hasPriority && _sortPropTweensByPriority(tween);\n tween._onInit && tween._onInit(tween); //plugins like RoundProps must wait until ALL of the PropTweens are instantiated. In the plugin's init() function, it sets the _onInit on the tween instance. May not be pretty/intuitive, but it's fast and keeps file size down.\n }\n\n tween._onUpdate = onUpdate;\n tween._initted = (!tween._op || tween._pt) && !overwritten;
1141 // if overwrittenProps resulted in the entire tween being killed, do NOT flag it as initted or else it may render for one tick.\n\n keyframes && time <= 0 && tl.render(_bigNum, true, true); // if there's a 0% keyframe, it'll render in the \"before\" state for any staggered/delayed animations thus when the following tween initializes, it'll use the \"before\" state instead of the \"after\" state as the initial values.\n},\n _updatePropTweens = function _updatePropTweens(tween, property, value, start, startIsRelative, ratio, time, skipRecursion) {\n var ptCache = (tween._pt && tween._ptCache || (tween._ptCache = {}))[property],\n pt,\n rootPT,\n lookup,\n i;\n\n if (!ptCache) {\n ptCache = tween._ptCache[property] = [];\n lookup = tween._ptLookup;\n i = tween._targets.length;\n\n while (i--) {\n pt = lookup[i][property];\n\n if (pt && pt.d && pt.d._pt) {\n // it's a plugin, so find the nested PropTween\n pt = pt.d._pt;\n\n while (pt && pt.p !== property && pt.fp !== property) {\n // \"fp\" is functionParam for things like setting CSS variables which require .setProperty(\"--var-name\", value)\n pt = pt._next;\n }\n }\n\n if (!pt) {\n // there is no PropTween associated with that property, so we must FORCE one to be created and ditch out of this\n // if the tween has other properties that already rendered at new positions, we'd normally have to rewind to put them back like tween.render(0, true) before forcing an _initTween(), but that can create another edge case like tweening a timeline's progress would trigger onUpdates to fire which could move other things around. It's better to just inform users that .resetTo() should ONLY be used for tweens that already have that property. For example, you can't gsap.to(...{ y: 0 }) and then tween.restTo(\"x\", 200) for example.\n _forceAllPropTweens = 1; // otherwise, when we _addPropTween() and it finds no change between the start and end values, it skips creating a PropTween (for efficiency...why tween when there's no difference?) but in this case we NEED that PropTween created so we can edit it.\n\n tween.vars[property] = \"+=0\";\n\n _initTween(tween, time);\n\n _forceAllPropTweens = 0;\n return skipRecursion ? _warn(property + \" not eligible for reset. Try splitting into individual properties\") : 1; // if someone tries to do a quickTo() on a special property like borderRadius which must get split into 4 different properties, that's not eligible for .resetTo().\n }\n\n ptCache.push(pt);\n }\n }\n\n i = ptCache.length;\n\n while (i--) {\n rootPT = ptCache[i];\n pt = rootPT._pt || rootPT; // complex values may have nested PropTweens. We only accommodate the FIRST value.\n\n pt.s = (start || start === 0) && !startIsRelative ? start : pt.s + (start || 0) + ratio * pt.c;\n pt.c = value - pt.s;\n rootPT.e && (rootPT.e = _round(value) + getUnit(rootPT.e)); // mainly for CSSPlugin (end value)\n\n rootPT.b && (rootPT.b = pt.s + getUnit(rootPT.b)); // (beginning value)\n }\n},\n _addAliasesToVars = function _addAliasesToVars(targets, vars) {\n var harness = targets[0] ? _getCache(targets[0]).harness : 0,\n propertyAliases = harness && harness.aliases,\n copy,\n p,\n i,\n aliases;\n\n if (!propertyAliases) {\n return vars;\n }\n\n copy = _merge({}, vars);\n\n for (p in propertyAliases) {\n if (p in copy) {\n aliases = propertyAliases[p].split(\",\");\n i = aliases.length;\n\n while (i--) {\n copy[aliases[i]] = copy[p];\n }\n }\n }\n\n return copy;\n},\n // parses multiple formats, like {\"0%\": {x: 100}, {\"50%\": {x: -20}} and { x: {\"0%\": 100, \"50%\": -20} }, and an \"ease\" can be set on any object. We populate an \"allProps\" object with an Array for each property, like {x: [{}, {}], y:[{}, {}]} with data for each property tween. The objects have a \"t\" (time), \"v\", (value), and \"e\" (ease) property. This allows us to piece together a timeline later.\n_parseKeyframe = function _parseKeyframe(prop, obj, allProps, easeEach) {\n var ease = obj.ease || easeEach || \"power1.inOut\",\n p,\n a;\n\n if (_isArray(obj)) {\n a = allProps[prop] || (allProps[prop] = []); // t = time (out of 100), v = value, e = ease\n\n obj.forEac
1141h(function (value, i) {\n return a.push({\n t: i / (obj.length - 1) * 100,\n v: value,\n e: ease\n });\n });\n } else {\n for (p in obj) {\n a = allProps[p] || (allProps[p] = []);\n p === \"ease\" || a.push({\n t: parseFloat(prop),\n v: obj[p],\n e: ease\n });\n }\n }\n},\n _parseFuncOrString = function _parseFuncOrString(value, tween, i, target, targets) {\n return _isFunction(value) ? value.call(tween, i, target, targets) : _isString(value) && ~value.indexOf(\"random(\") ? _replaceRandom(value) : value;\n},\n _staggerTweenProps = _callbackNames + \"repeat,repeatDelay,yoyo,repeatRefresh,yoyoEase,easeReverse,autoRevert\",\n _staggerPropsToSkip = {};\n\n_forEachName(_staggerTweenProps + \",id,stagger,delay,duration,paused,scrollTrigger\", function (name) {\n return _staggerPropsToSkip[name] = 1;\n});\n/*\n * --------------------------------------------------------------------------------------\n * TWEEN\n * --------------------------------------------------------------------------------------\n */\n\n\nvar Tween = /*#__PURE__*/function (_Animation2) {\n _inheritsLoose(Tween, _Animation2);\n\n function Tween(targets, vars, position, skipInherit) {\n var _this3;\n\n if (typeof vars === \"number\") {\n position.duration = vars;\n vars = position;\n position = null;\n }\n\n _this3 = _Animation2.call(this, skipInherit ? vars : _inheritDefaults(vars)) || this;\n var _this3$vars = _this3.vars,\n duration = _this3$vars.duration,\n delay = _this3$vars.delay,\n immediateRender = _this3$vars.immediateRender,\n stagger = _this3$vars.stagger,\n overwrite = _this3$vars.overwrite,\n keyframes = _this3$vars.keyframes,\n defaults = _this3$vars.defaults,\n scrollTrigger = _this3$vars.scrollTrigger,\n parent = vars.parent || _globalTimeline,\n parsedTargets = (_isArray(targets) || _isTypedArray(targets) ? _isNumber(targets[0]) : \"length\" in vars) ? [targets] : toArray(targets),\n tl,\n i,\n copy,\n l,\n p,\n curTarget,\n staggerFunc,\n staggerVarsToMerge;\n _this3._targets = parsedTargets.length ? _harness(parsedTargets) : _warn(\"GSAP target \" + targets + \" not found. https://gsap.com\", !_config.nullTargetWarn) || [];\n _this3._ptLookup = []; //PropTween lookup. An array containing an object for each target, having keys for each tweening property\n\n _this3._overwrite = overwrite;\n\n if (keyframes || stagger || _isFuncOrString(duration) || _isFuncOrString(delay)) {\n vars = _this3.vars;\n var easeReverse = vars.easeReverse || vars.yoyoEase;\n tl = _this3.timeline = new Timeline({\n data: \"nested\",\n defaults: defaults || {},\n targets: parent && parent.data === \"nested\" ? parent.vars.targets : parsedTargets\n }); // we need to store the targets because for staggers and keyframes, we end up creating an individual tween for each but function-based values need to know the index and the whole Array of targets.\n\n tl.kill();\n tl.parent = tl._dp = _assertThisInitialized(_this3);\n tl._start = 0;\n\n if (stagger || _isFuncOrString(duration) || _isFuncOrString(delay)) {\n l = parsedTargets.length;\n staggerFunc = stagger && distribute(stagger);\n\n if (_isObject(stagger)) {\n //users can pass in callbacks like onStart/onComplete in the stagger object. These should fire with each individual tween.\n for (p in stagger) {\n if (~_staggerTweenProps.indexOf(p)) {\n staggerVarsToMerge || (staggerVarsToMerge = {});\n staggerVarsToMerge[p] = stagger[p];\n }\n }\n }\n\n for (i = 0; i < l; i++) {\n copy = _copyExcluding(vars, _staggerPropsToSkip);\n copy.stagger = 0;\n easeReverse && (copy.easeReverse = easeReverse);\n staggerVarsToMerge && _merge(copy, staggerVarsToMerge);\n curTarget = parsedTargets[i]; //don't just copy duration or delay because if they're a string or function, we'd end up in an infinite loop because _isFuncOrString() would evaluate as true in the child tweens, entering this loop, etc. So we parse the value straight from vars and default to 0.\n\n copy.duration = +_parseFuncOrString(duration, _assertThisInitialized(_this3), i, curTarget, parsedTargets);\n copy.delay = (+_parseFuncOrString(delay, _assertThisInitialized(_this3), i, curTarget, parsedTargets) || 0) - _this3._delay;\n\n if (!stagger && l === 1 && copy.delay) {\n // if someone does delay:\"random(1, 5)\", repeat:-1, for example, the delay
1141shouldn't be inside the repeat.\n _this3._delay = delay = copy.delay;\n _this3._start += delay;\n copy.delay = 0;\n }\n\n tl.to(curTarget, copy, staggerFunc ? staggerFunc(i, curTarget, parsedTargets) : 0);\n tl._ease = _easeMap.none;\n }\n\n tl.duration() ? duration = delay = 0 : _this3.timeline = 0; // if the timeline's duration is 0, we don't need a timeline internally!\n } else if (keyframes) {\n _inheritDefaults(_setDefaults(tl.vars.defaults, {\n ease: \"none\"\n }));\n\n tl._ease = _parseEase(keyframes.ease || vars.ease || \"none\");\n var time = 0,\n a,\n kf,\n v;\n\n if (_isArray(keyframes)) {\n keyframes.forEach(function (frame) {\n return tl.to(parsedTargets, frame, \">\");\n });\n tl.duration(); // to ensure tl._dur is cached because we tap into it for performance purposes in the render() method.\n } else {\n copy = {};\n\n for (p in keyframes) {\n p === \"ease\" || p === \"easeEach\" || _parseKeyframe(p, keyframes[p], copy, keyframes.easeEach);\n }\n\n for (p in copy) {\n a = copy[p].sort(function (a, b) {\n return a.t - b.t;\n });\n time = 0;\n\n for (i = 0; i < a.length; i++) {\n kf = a[i];\n v = {\n ease: kf.e,\n duration: (kf.t - (i ? a[i - 1].t : 0)) / 100 * duration\n };\n v[p] = kf.v;\n tl.to(parsedTargets, v, time);\n time += v.duration;\n }\n }\n\n tl.duration() < duration && tl.to({}, {\n duration: duration - tl.duration()\n }); // in case keyframes didn't go to 100%\n }\n }\n\n duration || _this3.duration(duration = tl.duration());\n } else {\n _this3.timeline = 0; //speed optimization, faster lookups (no going up the prototype chain)\n }\n\n if (overwrite === true && !_suppressOverwrites) {\n _overwritingTween = _assertThisInitialized(_this3);\n\n _globalTimeline.killTweensOf(parsedTargets);\n\n _overwritingTween = 0;\n }\n\n _addToTimeline(parent, _assertThisInitialized(_this3), position);\n\n vars.reversed && _this3.reverse();\n vars.paused && _this3.paused(true);\n\n if (immediateRender || !duration && !keyframes && _this3._start === _roundPrecise(parent._time) && _isNotFalse(immediateRender) && _hasNoPausedAncestors(_assertThisInitialized(_this3)) && parent.data !== \"nested\") {\n _this3._tTime = -_tinyNum; //forces a render without having to set the render() \"force\" parameter to true because we want to allow lazying by default (using the \"force\" parameter always forces an immediate full render)\n\n _this3.render(Math.max(0, -delay) || 0); //in case delay is negative\n\n }\n\n scrollTrigger && _scrollTrigger(_assertThisInitialized(_this3), scrollTrigger);\n return _this3;\n }\n\n var _proto3 = Tween.prototype;\n\n _proto3.render = function render(totalTime, suppressEvents, force) {\n var prevTime = this._time,\n tDur = this._tDur,\n dur = this._dur,\n isNegative = totalTime < 0,\n tTime = totalTime > tDur - _tinyNum && !isNegative ? tDur : totalTime < _tinyNum ? 0 : totalTime,\n time,\n pt,\n iteration,\n cycleDuration,\n prevIteration,\n isYoyo,\n ratio,\n timeline;\n\n if (!dur) {\n _renderZeroDurationTween(this, totalTime, suppressEvents, force);\n } else if (tTime !== this._tTime || !totalTime || force || !this._initted && this._tTime || this._startAt && this._zTime < 0 !== isNegative || this._lazy) {\n // this senses if we're crossing over the start time, in which case we must record _zTime and force the render, but we do it in this lengthy conditional way for performance reasons (usually we can skip the calculations): this._initted && (this._zTime < 0) !== (totalTime < 0)\n time = tTime;\n timeline = this.timeline;\n\n if (this._repeat) {\n //adjust the time for repeats and yoyos\n cycleDuration = dur + this._rDelay;\n\n if (this._repeat < -1 && isNegative) {\n return this.totalTime(cycleDuration * 100 + totalTime, suppressEvents, force);\n }\n\n time = _roundPrecise(tTime % cycleDuration); //round to avoid floating point errors. (4 % 0.8 should be 0 but some browsers report it as 0.79999999!)\n\n if (tTime === tDur) {\n // the tDur === tTime is for edge cases where there's a lengthy decimal on the duration and it may reach the very end but the time is rendered as not-quite-there (remember, tDur is rounded to 4 decimals whereas dur isn't)\n iteration = this._repeat;\n time = dur;\n } else {\n prevIteration = _roundPrecise(tTime / cycleDuration); // full decimal version of iterations, not the previous iteration (we're reusing prevIteration variable for efficiency)\n\n iteration = ~~prevIteration;\n\n if (iteration && iteration === prevIteration) {\n time = dur;\n iteration--;\n } else if (time > dur) {\n time = dur;\n }\n }\n\n isYoyo = this._yoyo && iteration & 1;\n if (isYoyo) time = dur - time;\n prevIteration = _animationCycle(this._tTime, cycleDuration);\n\n if (time === prevTime && !force && this._initted && iteration === prevIteration) {\n //could be during the repeatDelay part. No need to render and fire callbacks.\n this._tTime = tTime;\n return this;\n }\n\n if (iteration !== prevIteration) {\n //repeatRefresh functionality\n if (this.vars.repeatRefresh && !isYoyo && !this._lock && time !== cycleDuration && this._initted) {\n // this._time will === cycleDuration when we render at EXACTLY the end of an iteration. Without this condition, it'd often do the repeatRefresh render TWICE (again on the very next tick).\n this._lock = force = 1; //force, otherwise if lazy is true, the _attemptInitTween() will return and we'll jump out and get caught bouncing on each tick.\n\n this.render(_roundPrecise(cycleDuration * iteration), true).invalidate()._lock = 0;\n }\n }\n }\n\n if (!this._initted) {\n if (_attemptInitTween(this, isNegative ? totalTime : time, force, suppressEvents, tTime)) {\
1141n this._tTime = 0; // in constructor if immediateRender is true, we set _tTime to -_tinyNum to have the playhead cross the starting point but we can't leave _tTime as a negative number.\n\n return this;\n }\n\n if (prevTime !== this._time && !(force && this.vars.repeatRefresh && iteration !== prevIteration)) {\n // rare edge case - during initialization, an onUpdate in the _startAt (.fromTo()) might force this tween to render at a different spot in which case we should ditch this render() call so that it doesn't revert the values. But we also don't want to dump if we're doing a repeatRefresh render!\n return this;\n }\n\n if (dur !== this._dur) {\n // while initting, a plugin like InertiaPlugin might alter the duration, so rerun from the start to ensure everything renders as it should.\n return this.render(totalTime, suppressEvents, force);\n }\n }\n\n if (this._rEase) {\n var inv = time < prevTime;\n\n if (inv !== this._inv) {\n var segDur = inv ? prevTime : dur - prevTime;\n this._inv = inv;\n if (this._from) this.ratio = 1 - this.ratio;\n this._invRatio = this.ratio;\n this._invTime = prevTime;\n this._invRecip = segDur ? (inv ? -1 : 1) / segDur : 0;\n this._invScale = inv ? -this.ratio : 1 - this.ratio;\n this._invEase = inv ? this._rEase : this._ease;\n }\n\n this.ratio = ratio = this._invRatio + this._invScale * this._invEase((time - this._invTime) * this._invRecip);\n } else {\n this.ratio = ratio = this._ease(time / dur);\n }\n\n if (this._from) this.ratio = ratio = 1 - ratio;\n this._tTime = tTime;\n this._time = time;\n\n if (!this._act && this._ts) {\n this._act = 1; //as long as it's not paused, force it to be active so that if the user renders independent of the parent timeline, it'll be forced to re-render on the next tick.\n\n this._lazy = 0;\n }\n\n if (!prevTime && tTime && !suppressEvents && !prevIteration) {\n _callback(this, \"onStart\");\n\n if (this._tTime !== tTime) {\n // in case the onStart triggered a render at a different spot, eject. Like if someone did animation.pause(0.5) or something inside the onStart.\n return this;\n }\n }\n\n pt = this._pt;\n\n while (pt) {\n pt.r(ratio, pt.d);\n pt = pt._next;\n }\n\n timeline && timeline.render(totalTime < 0 ? totalTime : timeline._dur * timeline._ease(time / this._dur), suppressEvents, force) || this._startAt && (this._zTime = totalTime);\n\n if (this._onUpdate && !suppressEvents) {\n isNegative && _rewindStartAt(this, totalTime, suppressEvents, force); //note: for performance reasons, we tuck this conditional logic inside less traveled areas (most tweens don't have an onUpdate). We'd just have it at the end before the onComplete, but the values should be updated before any onUpdate is called, so we ALSO put it here and then if it's not called, we do so later near the onComplete.\n\n _callback(this, \"onUpdate\");\n }\n\n this._repeat && iteration !== prevIteration && this.vars.onRepeat && !suppressEvents && this.parent && _callback(this, \"onRepeat\");\n\n if ((tTime === this._tDur || !tTime) && this._tTime === tTime) {\n isNegative && !this._onUpdate && _rewindStartAt(this, totalTime, true, true);\n (totalTime || !dur) && (tTime === this._tDur && this._ts > 0 || !tTime && this._ts < 0) && _removeFromParent(this, 1); // don't remove if we're rendering at exactly a time of 0, as there could be autoRevert values that should get set on the next tick (if the playhead goes backward beyond the startTime, negative totalTime). Don't remove if the timeline is reversed and the playhead isn't at 0, otherwise tl.progress(1).reverse() won't work. Only remove if the playhead is at the end and timeScale is positive, or if the playhead is at 0 and the timeScale is negative.\n\n if (!suppressEvents && !(isNegative && !prevTime) && (tTime || prevTime || isYoyo)) {\n // if prevTime and tTime are zero, we shouldn't fire the onReverseComplete. This could happen if you gsap.to(... {paused:true}).play();\n _callback(this, tTime === tDur ? \"onComplete\" : \"onReverseComplete\", true);\n\n this._prom && !(tTime < tDur && this.timeScale() > 0) && this._prom();\n }\n }\n }\n\n return this;\n };\n\n _proto3.targets = function targets() {\n return this._targets;\n };
1141\n\n _proto3.invalidate = function invalidate(soft) {\n // \"soft\" gives us a way to clear out everything EXCEPT the recorded pre-\"from\" portion of from() tweens. Otherwise, for example, if you tween.progress(1).render(0, true true).invalidate(), the \"from\" values would persist and then on the next render, the from() tweens would initialize and the current value would match the \"from\" values, thus animate from the same value to the same value (no animation). We tap into this in ScrollTrigger's refresh() where we must push a tween to completion and then back again but honor its init state in case the tween is dependent on another tween further up on the page.\n (!soft || !this.vars.runBackwards) && (this._startAt = 0);\n this._pt = this._op = this._onUpdate = this._lazy = this.ratio = 0;\n this._ptLookup = [];\n this.timeline && this.timeline.invalidate(soft);\n return _Animation2.prototype.invalidate.call(this, soft);\n };\n\n _proto3.resetTo = function resetTo(property, value, start, startIsRelative, skipRecursion) {\n _tickerActive || _ticker.wake();\n this._ts || this.play();\n var time = Math.min(this._dur, (this._dp._time - this._start) * this._ts),\n ratio;\n this._initted || _initTween(this, time);\n ratio = this._ease(time / this._dur); // don't just get tween.ratio because it may not have rendered yet.\n // possible future addition to allow an object with multiple values to update, like tween.resetTo({x: 100, y: 200}); At this point, it doesn't seem worth the added kb given the fact that most users will likely opt for the convenient gsap.quickTo() way of interacting with this method.\n // if (_isObject(property)) { // performance optimization\n // \tfor (p in property) {\n // \t\tif (_updatePropTweens(this, p, property[p], value ? value[p] : null, start, ratio, time)) {\n // \t\t\treturn this.resetTo(property, value, start, startIsRelative); // if a PropTween wasn't found for the property, it'll get forced with a re-initialization so we need to jump out and start over again.\n // \t\t}\n // \t}\n // } else {\n\n if (_updatePropTweens(this, property, value, start, startIsRelative, ratio, time, skipRecursion)) {\n return this.resetTo(property, value, start, startIsRelative, 1); // if a PropTween wasn't found for the property, it'll get forced with a re-initialization so we need to jump out and start over again.\n } //}\n\n\n _alignPlayhead(this, 0);\n\n this.parent || _addLinkedListItem(this._dp, this, \"_first\", \"_last\", this._dp._sort ? \"_start\" : 0);\n return this.render(0);\n };\n\n _proto3.kill = function kill(targets, vars) {\n if (vars === void 0) {\n vars = \"all\";\n }\n\n if (!targets && (!vars || vars === \"all\")) {\n this._lazy = this._pt = 0;\n this.parent ? _interrupt(this) : this.scrollTrigger && this.scrollTrigger.kill(!!_reverting);\n return this;\n }\n\n if (this.timeline) {\n var tDur = this.timeline.totalDuration();\n this.timeline.killTweensOf(targets, vars, _overwritingTween && _overwritingTween.vars.overwrite !== true)._first || _interrupt(this); // if nothing is left tweening, interrupt.\n\n this.parent && tDur !== this.timeline.totalDuration() && _setDuration(this, this._dur * this.timeline._tDur / tDur, 0, 1); // if a nested tween is killed that changes the duration, it should affect this tween's duration. We must use the ratio, though, because sometimes the internal timeline is stretched like for keyframes where they don't all add up to whatever the parent tween's duration was set to.\n\n return this;\n }\n\n var parsedTargets = this._targets,\n killingTargets = targets ? toArray(targets) : parsedTargets,\n propTweenLookup = this._ptLookup,\n firstPT = this._pt,\n overwrittenProps,\n curLookup,\n curOverwriteProps,\n props,\n p,\n pt,\n i;\n\n if ((!vars || vars === \"all\") && _arraysMatch(parsedTargets, killingTargets)) {\n vars === \"all\" && (this._pt = 0);\n return _interrupt(this);\n }\n\n overwrittenProps = this._op = this._op || [];\n\n if (vars !== \"all\") {\n //so people can pass in a comma-delimited list of property names\n if (_isString(vars)) {\n p = {};
1141\n\n _forEachName(vars, function (name) {\n return p[name] = 1;\n });\n\n vars = p;\n }\n\n vars = _addAliasesToVars(parsedTargets, vars);\n }\n\n i = parsedTargets.length;\n\n while (i--) {\n if (~killingTargets.indexOf(parsedTargets[i])) {\n curLookup = propTweenLookup[i];\n\n if (vars === \"all\") {\n overwrittenProps[i] = vars;\n props = curLookup;\n curOverwriteProps = {};\n } else {\n curOverwriteProps = overwrittenProps[i] = overwrittenProps[i] || {};\n props = vars;\n }\n\n for (p in props) {\n pt = curLookup && curLookup[p];\n\n if (pt) {\n if (!(\"kill\" in pt.d) || pt.d.kill(p) === true) {\n _removeLinkedListItem(this, pt, \"_pt\");\n }\n\n delete curLookup[p];\n }\n\n if (curOverwriteProps !== \"all\") {\n curOverwriteProps[p] = 1;\n }\n }\n }\n }\n\n this._initted && !this._pt && firstPT && _interrupt(this); //if all tweening properties are killed, kill the tween. Without this line, if there's a tween with multiple targets and then you killTweensOf() each target individually, the tween would technically still remain active and fire its onComplete even though there aren't any more properties tweening.\n\n return this;\n };\n\n Tween.to = function to(targets, vars) {\n return new Tween(targets, vars, arguments[2]);\n };\n\n Tween.from = function from(targets, vars) {\n return _createTweenType(1, arguments);\n };\n\n Tween.delayedCall = function delayedCall(delay, callback, params, scope) {\n return new Tween(callback, 0, {\n immediateRender: false,\n lazy: false,\n overwrite: false,\n delay: delay,\n onComplete: callback,\n onReverseComplete: callback,\n onCompleteParams: params,\n onReverseCompleteParams: params,\n callbackScope: scope\n }); // we must use onReverseComplete too for things like timeline.add(() => {...}) which should be triggered in BOTH directions (forward and reverse)\n };\n\n Tween.fromTo = function fromTo(targets, fromVars, toVars) {\n return _createTweenType(2, arguments);\n };\n\n Tween.set = function set(targets, vars) {\n vars.duration = 0;\n vars.repeatDelay || (vars.repeat = 0);\n return new Tween(targets, vars);\n };\n\n Tween.killTweensOf = function killTweensOf(targets, props, onlyActive) {\n return _globalTimeline.killTweensOf(targets, props, onlyActive);\n };\n\n return Tween;\n}(Animation);\n\n_setDefaults(Tween.prototype, {\n _targets: [],\n _lazy: 0,\n _startAt: 0,\n _op: 0,\n _onInit: 0\n}); //add the pertinent timeline methods to Tween instances so that users can chain conveniently and create a timeline automatically. (removed due to concerns that it'd ultimately add to more confusion especially for beginners)\n// _forEachName(\"to,from,fromTo,set,call,add,addLabel,addPause\", name => {\n// \tTween.prototype[name] = function() {\n// \t\tlet tl = new Timeline();\n// \t\treturn _addToTimeline(tl, this)[name].apply(tl, toArray(arguments));\n// \t}\n// });\n//for backward compatibility. Leverage the timeline calls.\n\n\n_forEachName(\"staggerTo,staggerFrom,staggerFromTo\", function (name) {\n Tween[name] = function () {\n var tl = new Timeline(),\n params = _slice.call(arguments, 0);\n\n params.splice(name === \"staggerFromTo\" ? 5 : 4, 0, 0);\n return tl[name].apply(tl, params);\n };\n});\n/*\n * --------------------------------------------------------------------------------------\n * PROPTWEEN\n * --------------------------------------------------------------------------------------\n */\n\n\nvar _setterPlain = function _setterPlain(target, property, value) {\n return target[property] = value;\n},\n _setterFunc = function _setterFunc(target, property, value) {\n return target[property](value);\n},\n _setterFuncWithParam = function _setterFuncWithParam(target, property, value, data) {\n return target[property](data.fp, value);\n},\n _setterAttribute = function _setterAttribute(target, property, value) {\n return target.setAttribute(property, value);\n},\n _getSetter = function _getSetter(target, property) {\n return _isFunction(target[property]) ? _setterFunc : _isUndefined(target[property]) && target.setAttribute ? _setterAttribute : _setterPlain;\n}
1141,\n _renderPlain = function _renderPlain(ratio, data) {\n return data.set(data.t, data.p, Math.round((data.s + data.c * ratio) * 1000000) / 1000000, data);\n},\n _renderBoolean = function _renderBoolean(ratio, data) {\n return data.set(data.t, data.p, !!(data.s + data.c * ratio), data);\n},\n _renderComplexString = function _renderComplexString(ratio, data) {\n var pt = data._pt,\n s = \"\";\n\n if (!ratio && data.b) {\n //b = beginning string\n s = data.b;\n } else if (ratio === 1 && data.e) {\n //e = ending string\n s = data.e;\n } else {\n while (pt) {\n s = pt.p + (pt.m ? pt.m(pt.s + pt.c * ratio) : Math.round((pt.s + pt.c * ratio) * 10000) / 10000) + s; //we use the \"p\" property for the text inbetween (like a suffix). And in the context of a complex string, the modifier (m) is typically just Math.round(), like for RGB colors.\n\n pt = pt._next;\n }\n\n s += data.c; //we use the \"c\" of the PropTween to store the final chunk of non-numeric text.\n }\n\n data.set(data.t, data.p, s, data);\n},\n _renderPropTweens = function _renderPropTweens(ratio, data) {\n var pt = data._pt;\n\n while (pt) {\n pt.r(ratio, pt.d);\n pt = pt._next;\n }\n},\n _addPluginModifier = function _addPluginModifier(modifier, tween, target, property) {\n var pt = this._pt,\n next;\n\n while (pt) {\n next = pt._next;\n pt.p === property && pt.modifier(modifier, tween, target);\n pt = next;\n }\n},\n _killPropTweensOf = function _killPropTweensOf(property) {\n var pt = this._pt,\n hasNonDependentRemaining,\n next;\n\n while (pt) {\n next = pt._next;\n\n if (pt.p === property && !pt.op || pt.op === property) {\n _removeLinkedListItem(this, pt, \"_pt\");\n } else if (!pt.dep) {\n hasNonDependentRemaining = 1;\n }\n\n pt = next;\n }\n\n return !hasNonDependentRemaining;\n},\n _setterWithModifier = function _setterWithModifier(target, property, value, data) {\n data.mSet(target, property, data.m.call(data.tween, value, data.mt), data);\n},\n _sortPropTweensByPriority = function _sortPropTweensByPriority(parent) {\n var pt = parent._pt,\n next,\n pt2,\n first,\n last; //sorts the PropTween linked list in order of priority because some plugins need to do their work after ALL of the PropTweens were created (like RoundPropsPlugin and ModifiersPlugin)\n\n while (pt) {\n next = pt._next;\n pt2 = first;\n\n while (pt2 && pt2.pr > pt.pr) {\n pt2 = pt2._next;\n }\n\n if (pt._prev = pt2 ? pt2._prev : last) {\n pt._prev._next = pt;\n } else {\n first = pt;\n }\n\n if (pt._next = pt2) {\n pt2._prev = pt;\n } else {\n last = pt;\n }\n\n pt = next;\n }\n\n parent._pt = first;\n}; //PropTween key: t = target, p = prop, r = renderer, d = data, s = start, c = change, op = overwriteProperty (ONLY populated when it's different than p), pr = priority, _next/_prev for the linked list siblings, set = setter, m = modifier, mSet = modifierSetter (the original setter, before a modifier was added)\n\n\nvar PropTween = /*#__PURE__*/function () {\n function PropTween(next, target, prop, start, change, renderer, data, setter, priority) {\n this.t = target;\n this.s = start;\n this.c = change;\n this.p = prop;\n this.r = renderer || _renderPlain;\n this.d = data || this;\n this.set = setter || _setterPlain;\n this.pr = priority || 0;\n this._next = next;\n\n if (next) {\n next._prev = this;\n }\n }\n\n var _proto4 = PropTween.prototype;\n\n _proto4.modifier = function modifier(func, tween, target) {\n this.mSet = this.mSet || this.set; //in case it was already set (a PropTween can only have one modifier)\n\n this.set = _setterWithModifier;\n this.m = func;\n this.mt = target; //modifier target\n\n this.tween = tween;\n };\n\n return PropTween;\n}(); //Initialization tasks\n\n_forEachName(_callbackNames + \"parent,duration,ease,delay,overwrite,runBackwards,startAt,yoyo,immediateRender,repeat,repeatDelay,data,paused,reversed,lazy,callbackScope,stringFilter,id,yoyoEase,stagger,inherit,repeatRefresh,keyframes,autoRevert,scrollTrigger,easeReverse\", function (name) {\n return _reservedProps[name] = 1;\n});\n\n_globals.TweenMax = _globals.TweenLite = Tween;\n_globals.TimelineLite = _globals.TimelineMax = Timeline;\n_globalTimeline = new Timeline({\n sortChildren: false,\n defaults: _defaults,\n autoRemoveChildren: true,\n id: \"root\",\n smoothChildTiming: true\n});\n_config.stringFilter = _colorStringFilter;\n\nvar _media = [],\n _listeners = {},\n _emptyArray = [],\n _lastMediaTime = 0,\n _contextID = 0,\n _dispatch = function _dispatch(type) {\n return (_listeners[type] || _emptyArray).map(function (f) {\n return f();\n });\n},\n _onMediaChange = function _onMediaChange() {\n var time = Date.now(),\n matches = [];\n\n if (time - _lastMediaTime > 2) {\n _dispatch(\"matchMediaInit\");
1141\n\n _media.forEach(function (c) {\n var queries = c.queries,\n conditions = c.conditions,\n match,\n p,\n anyMatch,\n toggled;\n\n for (p in queries) {\n match = _win.matchMedia(queries[p]).matches; // Firefox doesn't update the \"matches\" property of the MediaQueryList object correctly - it only does so as it calls its change handler - so we must re-create a media query here to ensure it's accurate.\n\n match && (anyMatch = 1);\n\n if (match !== conditions[p]) {\n conditions[p] = match;\n toggled = 1;\n }\n }\n\n if (toggled) {\n c.revert();\n anyMatch && matches.push(c);\n }\n });\n\n _dispatch(\"matchMediaRevert\");\n\n matches.forEach(function (c) {\n return c.onMatch(c, function (func) {\n return c.add(null, func);\n });\n });\n _lastMediaTime = time;\n\n _dispatch(\"matchMedia\");\n }\n};\n\nvar Context = /*#__PURE__*/function () {\n function Context(func, scope) {\n this.selector = scope && selector(scope);\n this.data = [];\n this._r = []; // returned/cleanup functions\n\n this.isReverted = false;\n this.id = _contextID++; // to work around issues that frameworks like Vue cause by making things into Proxies which make it impossible to do something like _media.indexOf(this) because \"this\" would no longer refer to the Context instance itself - it'd refer to a Proxy! We needed a way to identify the context uniquely\n\n func && this.add(func);\n }\n\n var _proto5 = Context.prototype;\n\n _proto5.add = function add(name, func, scope) {\n // possible future addition if we need the ability to add() an animation to a context and for whatever reason cannot create that animation inside of a context.add(() => {...}) function.\n // if (name && _isFunction(name.revert)) {\n // \tthis.data.push(name);\n // \treturn (name._ctx = this);\n // }\n if (_isFunction(name)) {\n scope = func;\n func = name;\n name = _isFunction;\n }\n\n var self = this,\n f = function f() {\n var prev = _context,\n prevSelector = self.selector,\n result;\n prev && prev !== self && prev.data.push(self);\n scope && (self.selector = selector(scope));\n _context = self;\n result = func.apply(self, arguments);\n _isFunction(result) && self._r.push(result);\n _context = prev;\n self.selector = prevSelector;\n self.isReverted = false;\n return result;\n };\n\n self.last = f;\n return name === _isFunction ? f(self, function (func) {\n return self.add(null, func);\n }) : name ? self[name] = f : f;\n };\n\n _proto5.ignore = function ignore(func) {\n var prev = _context;\n _context = null;\n func(this);\n _context = prev;\n };\n\n _proto5.getTweens = function getTweens() {\n var a = [];\n this.data.forEach(function (e) {\n return e instanceof Context ? a.push.apply(a, e.getTweens()) : e instanceof Tween && !(e.parent && e.parent.data === \"nested\") && a.push(e);\n });\n return a;\n };\n\n _proto5.clear = function clear() {\n this._r.length = this.data.length = 0;\n };\n\n _proto5.kill = function kill(revert, matchMedia) {\n var _this4 = this;\n\n if (revert) {\n (function () {\n var tweens = _this4.getTweens(),\n i = _this4.data.length,\n t;\n\n while (i--) {\n // Flip plugin tweens are very different in that they should actually be pushed to their end. The plugin replaces the timeline's .revert() method to do exactly that. But we also need to remove any of those nested tweens inside the flip timeline so that they don't get individually reverted.\n t = _this4.data[i];\n\n if (t.data === \"isFlip\") {\n t.revert();\n t.getChildren(true, true, false).forEach(function (tween) {\n return tweens.splice(tweens.indexOf(tween), 1);\n });\n }\n } // save as an object so that we can cache the globalTime for each tween to optimize performance during the sort\n\n\n tweens.map(function (t) {\n return {\n g: t._dur || t._delay || t._sat && !t._sat.vars.immediateRender ? t.globalTime(0) : -Infinity,\n t: t\n };\n }).sort(function (a, b) {\n return b.g - a.g || -Infinity;\n }
1141).forEach(function (o) {\n return o.t.revert(revert);\n }); // note: all of the _startAt tweens should be reverted in reverse order that they were created, and they'll all have the same globalTime (-1) so the \" || -1\" in the sort keeps the order properly.\n\n i = _this4.data.length;\n\n while (i--) {\n // make sure we loop backwards so that, for example, SplitTexts that were created later on the same element get reverted first\n t = _this4.data[i];\n\n if (t instanceof Timeline) {\n if (t.data !== \"nested\") {\n t.scrollTrigger && t.scrollTrigger.revert();\n t.kill(); // don't revert() the timeline because that's duplicating efforts since we already reverted all the tweens\n }\n } else {\n !(t instanceof Tween) && t.revert && t.revert(revert);\n }\n }\n\n _this4._r.forEach(function (f) {\n return f(revert, _this4);\n });\n\n _this4.isReverted = true;\n })();\n } else {\n this.data.forEach(function (e) {\n return e.kill && e.kill();\n });\n }\n\n this.clear();\n\n if (matchMedia) {\n var i = _media.length;\n\n while (i--) {\n // previously, we checked _media.indexOf(this), but some frameworks like Vue enforce Proxy objects that make it impossible to get the proper result that way, so we must use a unique ID number instead.\n _media[i].id === this.id && _media.splice(i, 1);\n }\n }\n } // killWithCleanup() {\n // \tthis.kill();\n // \tthis._r.forEach(f => f(false, this));\n // }\n ;\n\n _proto5.revert = function revert(config) {\n this.kill(config || {});\n };\n\n return Context;\n}();\n\nvar MatchMedia = /*#__PURE__*/function () {\n function MatchMedia(scope) {\n this.contexts = [];\n this.scope = scope;\n _context && _context.data.push(this);\n }\n\n var _proto6 = MatchMedia.prototype;\n\n _proto6.add = function add(conditions, func, scope) {\n _isObject(conditions) || (conditions = {\n matches: conditions\n });\n var context = new Context(0, scope || this.scope),\n cond = context.conditions = {},\n mq,\n p,\n active;\n _context && !context.selector && (context.selector = _context.selector); // in case a context is created inside a context. Like a gsap.matchMedia() that's inside a scoped gsap.context()\n\n this.contexts.push(context);\n func = context.add(\"onMatch\", func);\n context.queries = conditions;\n\n for (p in conditions) {\n if (p === \"all\") {\n active = 1;\n } else {\n mq = _win.matchMedia(conditions[p]);\n\n if (mq) {\n _media.indexOf(context) < 0 && _media.push(context);\n (cond[p] = mq.matches) && (active = 1);\n mq.addListener ? mq.addListener(_onMediaChange) : mq.addEventListener(\"change\", _onMediaChange);\n }\n }\n }\n\n active && func(context, function (f) {\n return context.add(null, f);\n });\n return this;\n } // refresh() {\n // \tlet time = _lastMediaTime,\n // \t\tmedia = _media;\n // \t_lastMediaTime = -1;\n // \t_media = this.contexts;\n // \t_onMediaChange();\n // \t_lastMediaTime = time;\n // \t_media = media;\n // }\n ;\n\n _proto6.revert = function revert(config) {\n this.kill(config || {});\n };\n\n _proto6.kill = function kill(revert) {\n this.contexts.forEac
1141h(function (c) {\n return c.kill(revert, true);\n });\n };\n\n return MatchMedia;\n}();\n/*\n * --------------------------------------------------------------------------------------\n * GSAP\n * --------------------------------------------------------------------------------------\n */\n\n\nvar _gsap = {\n registerPlugin: function registerPlugin() {\n for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n args[_key2] = arguments[_key2];\n }\n\n args.forEach(function (config) {\n return _createPlugin(config);\n });\n },\n timeline: function timeline(vars) {\n return new Timeline(vars);\n },\n getTweensOf: function getTweensOf(targets, onlyActive) {\n return _globalTimeline.getTweensOf(targets, onlyActive);\n },\n getProperty: function getProperty(target, property, unit, uncache) {\n _isString(target) && (target = toArray(target)[0]); //in case selector text or an array is passed in\n\n var getter = _getCache(target || {}).get,\n format = unit ? _passThrough : _numericIfPossible;\n\n unit === \"native\" && (unit = \"\");\n return !target ? target : !property ? function (property, unit, uncache) {\n return format((_plugins[property] && _plugins[property].get || getter)(target, property, unit, uncache));\n } : format((_plugins[property] && _plugins[property].get || getter)(target, property, unit, uncache));\n },\n quickSetter: function quickSetter(target, property, unit) {\n target = toArray(target);\n\n if (target.length > 1) {\n var setters = target.map(function (t) {\n return gsap.quickSetter(t, property, unit);\n }),\n l = setters.length;\n return function (value) {\n var i = l;\n\n while (i--) {\n setters[i](value);\n }\n };\n }\n\n target = target[0] || {};\n\n var Plugin = _plugins[property],\n cache = _getCache(target),\n p = cache.harness && (cache.harness.aliases || {})[property] || property,\n // in case it's an alias, like \"rotate\" for \"rotation\".\n setter = Plugin ? function (value) {\n var p = new Plugin();\n _quickTween._pt = 0;\n p.init(target, unit ? value + unit : value, _quickTween, 0, [target]);\n p.render(1, p);\n _quickTween._pt && _renderPropTweens(1, _quickTween);\n } : cache.set(target, p);\n\n return Plugin ? setter : function (value) {\n return setter(target, p, unit ? value + unit : value, cache, 1);\n };\n },\n quickTo: function quickTo(target, property, vars) {\n var _setDefaults2;\n\n var tween = gsap.to(target, _setDefaults((_setDefaults2 = {}, _setDefaults2[property] = \"+=0.1\", _setDefaults2.paused = true, _setDefaults2.stagger = 0, _setDefaults2), vars || {})),\n func = function func(value, start, startIsRelative) {\n return tween.resetTo(property, value, start, startIsRelative);\n };\n\n func.tween = tween;\n return func;\n },\n isTweening: function isTweening(targets) {\n return _globalTimeline.getTweensOf(targets, true).length > 0;\n },\n defaults: function defaults(value) {\n value && value.ease && (value.ease = _parseEase(value.ease, _defaults.ease));\n return _mergeDeep(_defaults, value || {});\n },\n config: function config(value) {\n return _mergeDeep(_config, value || {});\n },\n registerEffect: function registerEffect(_ref3) {\n var name = _ref3.name,\n effect = _ref3.effect,\n plugins = _ref3.plugins,\n defaults = _ref3.defaults,\n extendTimeline = _ref3.extendTimeline;\n (plugins || \"\").split(\",\").forEach(function (pluginName) {\n return pluginName && !_plugins[pluginName] && !_globals[pluginName] && _warn(name + \" effect requires \" + pluginName + \" plugin.\");\n });\n\n _effects[name] = function (targets, vars, tl) {\n return effect(toArray(targets), _setDefaults(vars || {}, defaults), tl);\n };\n\n if (extendTimeline) {\n Timeline.prototype[name] = function (targets, vars, position) {\n return this.add(_effects[name](targets, _isObject(vars) ? vars : (position = vars) && {}, this), position);\n };\n }\n },\n registerEase: function registerEase(name, ease) {\n _easeMap[name] = _parseEase(ease);\n },\n parseEase: function parseEase(ease, defaultEase) {\n return arguments.length ? _parseEase(ease, defaultEase) : _easeMap;\n },\n getById: function getById(id) {\n return _globalTimeline.getById(id);\n },\n exportRoot: function exportRoot(vars, includeDelayedCalls) {\n if (vars === void 0) {\n vars = {};\n }\n\n var tl = new Timeline(vars),\n child,\n next;\n tl.smoothChildTiming = _isNotFalse(vars.smoothChildTiming);\n\n _globalTimeline.remove(tl);\n\n tl._dp = 0;
1141 //otherwise it'll get re-activated when adding children and be re-introduced into _globalTimeline's linked list (then added to itself).\n\n tl._time = tl._tTime = _globalTimeline._time;\n child = _globalTimeline._first;\n\n while (child) {\n next = child._next;\n\n if (includeDelayedCalls || !(!child._dur && child instanceof Tween && child.vars.onComplete === child._targets[0])) {\n _addToTimeline(tl, child, child._start - child._delay);\n }\n\n child = next;\n }\n\n _addToTimeline(_globalTimeline, tl, 0);\n\n return tl;\n },\n context: function context(func, scope) {\n return func ? new Context(func, scope) : _context;\n },\n matchMedia: function matchMedia(scope) {\n return new MatchMedia(scope);\n },\n matchMediaRefresh: function matchMediaRefresh() {\n return _media.forEach(function (c) {\n var cond = c.conditions,\n found,\n p;\n\n for (p in cond) {\n if (cond[p]) {\n cond[p] = false;\n found = 1;\n }\n }\n\n found && c.revert();\n }) || _onMediaChange();\n },\n addEventListener: function addEventListener(type, callback) {\n var a = _listeners[type] || (_listeners[type] = []);\n ~a.indexOf(callback) || a.push(callback);\n },\n removeEventListener: function removeEventListener(type, callback) {\n var a = _listeners[type],\n i = a && a.indexOf(callback);\n i >= 0 && a.splice(i, 1);\n },\n utils: {\n wrap: wrap,\n wrapYoyo: wrapYoyo,\n distribute: distribute,\n random: random,\n snap: snap,\n normalize: normalize,\n getUnit: getUnit,\n clamp: clamp,\n splitColor: splitColor,\n toArray: toArray,\n selector: selector,\n mapRange: mapRange,\n pipe: pipe,\n unitize: unitize,\n interpolate: interpolate,\n shuffle: shuffle\n },\n install: _install,\n effects: _effects,\n ticker: _ticker,\n updateRoot: Timeline.updateRoot,\n plugins: _plugins,\n globalTimeline: _globalTimeline,\n core: {\n PropTween: PropTween,\n globals: _addGlobal,\n Tween: Tween,\n Timeline: Timeline,\n Animation: Animation,\n getCache: _getCache,\n _removeLinkedListItem: _removeLinkedListItem,\n reverting: function reverting() {\n return _reverting;\n },\n context: function context(toAdd) {\n if (toAdd && _context) {\n _context.data.push(toAdd);\n\n toAdd._ctx = _context;\n }\n\n return _context;\n },\n suppressOverwrites: function suppressOverwrites(value) {\n return _suppressOverwrites = value;\n }\n }\n};\n\n_forEachName(\"to,from,fromTo,delayedCall,set,killTweensOf\", function (name) {\n return _gsap[name] = Tween[name];\n});\n\n_ticker.add(Timeline.updateRoot);\n\n_quickTween = _gsap.to({}, {\n duration: 0\n}); // ---- EXTRA PLUGINS --------------------------------------------------------\n\nvar _getPluginPropTween = function _getPluginPropTween(plugin, prop
1141) {\n var pt = plugin._pt;\n\n while (pt && pt.p !== prop && pt.op !== prop && pt.fp !== prop) {\n pt = pt._next;\n }\n\n return pt;\n},\n _addModifiers = function _addModifiers(tween, modifiers) {\n var targets = tween._targets,\n p,\n i,\n pt;\n\n for (p in modifiers) {\n i = targets.length;\n\n while (i--) {\n pt = tween._ptLookup[i][p];\n\n if (pt && (pt = pt.d)) {\n if (pt._pt) {\n // is a plugin\n pt = _getPluginPropTween(pt, p);\n }\n\n pt && pt.modifier && pt.modifier(modifiers[p], tween, targets[i], p);\n }\n }\n }\n},\n _buildModifierPlugin = function _buildModifierPlugin(name, modifier) {\n return {\n name: name,\n headless: 1,\n rawVars: 1,\n //don't pre-process function-based values or \"random()\" strings.\n init: function init(target, vars, tween) {\n tween._onInit = function (tween) {\n var temp, p;\n\n if (_isString(vars)) {\n temp = {};\n\n _forEachName(vars, function (name) {\n return temp[name] = 1;\n }); //if the user passes in a comma-delimited list of property names to roundProps, like \"x,y\", we round to whole numbers.\n\n\n vars = temp;\n }\n\n if (modifier) {\n temp = {};\n\n for (p in vars) {\n temp[p] = modifier(vars[p]);\n }\n\n vars = temp;\n }\n\n _addModifiers(tween, vars);\n };\n }\n };\n}; //register core plugins\n\n\nvar gsap = _gsap.registerPlugin({\n name: \"attr\",\n init: function init(target, vars, tween, index, targets) {\n var p, pt, v;\n this.tween = tween;\n\n for (p in vars) {\n v = target.getAttribute(p) || \"\";\n pt = this.add(target, \"setAttribute\", (v || 0) + \"\", vars[p], index, targets, 0, 0, p);\n pt.op = p;\n pt.b = v; // record the beginning value so we can revert()\n\n this._props.push(p);\n }\n },\n render: function render(ratio, data) {\n var pt = data._pt;\n\n while (pt) {\n _reverting ? pt.set(pt.t, pt.p, pt.b, pt) : pt.r(ratio, pt.d); // if reverting, go back to the original (pt.b)\n\n pt = pt._next;\n }\n }\n}, {\n name: \"endArray\",\n headless: 1,\n init: function init(target, value) {\n var i = value.length;\n\n while (i--) {\n this.add(target, i, target[i] || 0, value[i], 0, 0, 0, 0, 0, 1);\n }\n }\n}, _buildModifierPlugin(\"roundProps\", _roundModifier), _buildModifierPlugin(\"modifiers\"), _buildModifierPlugin(\"snap\", snap)) || _gsap; //to prevent the core plugins from being dropped via aggressive tree shaking, we must include them in the variable declaration in this way.\n\nTween.version = Timeline.version = gsap.version = \"3.15.0\";\n_coreReady = 1;\n_windowExists() && _wake();\nvar Power0 = _easeMap.Power0,\n Power1 = _easeMap.Power1,\n Power2 = _easeMap.Power2,\n Power3 = _easeMap.Power3,\n Power4 = _easeMap.Power4,\n Linear = _easeMap.Linear,\n Quad = _easeMap.Quad,\n Cubic = _easeMap.Cubic,\n Quart = _easeMap.Quart,\n Quint = _easeMap.Quint,\n Strong = _easeMap.Strong,\n Elastic = _easeMap.Elastic,\n Back = _easeMap.Back,\n SteppedEase = _easeMap.SteppedEase,\n Bounce = _easeMap.Bounce,\n Sine = _easeMap.Sine,\n Expo = _easeMap.Expo,\n Circ = _easeMap.Circ;\n\n //export some internal methods/orojects for use in CSSPlugin so that we can externalize that file and allow custom builds that exclude it.\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/gsap/gsap-core.js?\n}"); 1142 1143/***/ }, 1144 1145/***/ "./node_modules/gsap/index.js" 1146/*!************************************!*\ 1147 !*** ./node_modules/gsap/index.js ***! 1148 \************************************/ 1149(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1150 1151"use strict"; 1152eval("{__webpack_require__.r(__webpack_exports__);\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ TweenMax: () => (/* binding */ TweenMaxWithCSS),\n/* harmony export */ \"default\": () => (/* binding */ gsapWithCSS),\n/* harmony export */ gsap: () => (/* binding */ gsapWithCSS)\n/* harmony export */ });\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* empty/unused harmony star reexport */\n/* harmony import */ var _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./gsap-core.js */ \"./node_modules/gsap/gsap-core.js\");\n/* harmony import */ var _CSSPlugin_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./CSSPlugin.js */ \"./node_modules/gsap/CSSPlugin.js\");\n\n\nvar gsapWithCSS = _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.gsap.registerPlugin(_CSSPlugin_js__WEBPACK_IMPORTED_MODULE_2__.CSSPlugin) || _gsap_core_js__WEBPACK_IMPORTED_MODULE_0__.gsap,\n // to protect from tree shaking\nTweenMaxWithCSS = gsapWithCSS.core.Tween;\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/gsap/index.js?\n}"); 1153 1154/***/ }, 1155 1156/***/ "./dev/scss/app.scss" 1157/*!***************************!*\ 1158 !*** ./dev/scss/app.scss ***! 1159 \***************************/ 1160(__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1161 1162"use strict"; 1163eval("{__webpack_require__.r(__webpack_exports__);\n// extracted by mini-css-extract-plugin\n\n\n//# sourceURL=webpack://gotbagtheme/./dev/scss/app.scss?\n}"); 1164 1165/***/ }, 1166 1167/***/ "./node_modules/odometer/odometer.js" 1168/*!*******************************************!*\ 1169 !*** ./node_modules/odometer/odometer.js ***! 1170 \*******************************************/
1171(module, exports) { 1172 1173eval("{var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function() {\n var COUNT_FRAMERATE, COUNT_MS_PER_FRAME, DIGIT_FORMAT, DIGIT_HTML, DIGIT_SPEEDBOOST, DURATION, FORMAT_MARK_HTML, FORMAT_PARSER, FRAMERATE, FRAMES_PER_VALUE, MS_PER_FRAME, MutationObserver, Odometer, RIBBON_HTML, TRANSITION_END_EVENTS, TRANSITION_SUPPORT, VALUE_HTML, addClass, createFromHTML, fractionalPart, now, removeClass, requestAnimationFrame, round, transitionCheckStyles, trigger, truncate, wrapJQuery, _jQueryWrapped, _old, _ref, _ref1,\n __slice = [].slice;\n\n VALUE_HTML = '<span class=\"odometer-value\"></span>';\n\n RIBBON_HTML = '<span class=\"odometer-ribbon\"><span class=\"odometer-ribbon-inner\">' + VALUE_HTML + '</span></span>';\n\n DIGIT_HTML = '<span class=\"odometer-digit\"><span class=\"odometer-digit-spacer\">8</span><span class=\"odometer-digit-inner\">' + RIBBON_HTML + '</span></span>';\n\n FORMAT_MARK_HTML = '<span class=\"odometer-formatting-mark\"></span>';\n\n DIGIT_FORMAT = '(,ddd).dd';\n\n FORMAT_PARSER = /^\\(?([^)]*)\\)?(?:(.)(d+))?$/;\n\n FRAMERATE = 30;\n\n DURATION = 2000;\n\n COUNT_FRAMERATE = 20;\n\n FRAMES_PER_VALUE = 2;\n\n DIGIT_SPEEDBOOST = .5;\n\n MS_PER_FRAME = 1000 / FRAMERATE;\n\n COUNT_MS_PER_FRAME = 1000 / COUNT_FRAMERATE;\n\n TRANSITION_END_EVENTS = 'transitionend webkitTransitionEnd oTransitionEnd otransitionend MSTransitionEnd';\n\n transitionCheckStyles = document.createElement('div').style;\n\n TRANSITION_SUPPORT = (transitionCheckStyles.transition != null) || (transitionCheckStyles.webkitTransition != null) || (transitionCheckStyles.mozTransition != null) || (transitionCheckStyles.oTransition != null);\n\n requestAnimationFrame = window.requestAnimationFrame || window.mozRequestAnimationFrame || window.webkitRequestAnimationFrame || window.msRequestAnimationFrame;\n\n MutationObserver = window.MutationObserver || window.WebKitMutationObserver || window.MozMutationObserver;\n\n createFromHTML = function(html) {\n var el;\n el = document.createElement('div');\n el.innerHTML = html;\n return el.children[0];\n };\n\n removeClass = function(el, name) {\n return el.className = el.className.replace(new RegExp(\"(^| )\" + (name.split(' ').join('|')) + \"( |$)\", 'gi'), ' ');\n };\n\n addClass = function(el, name) {\n removeClass(el, name);\n return el.className += \" \" + name;\n };\n\n trigger = function(el, name) {\n var evt;\n if (document.createEvent != null) {\n evt = document.createEvent('HTMLEvents');\n evt.initEvent(name, true, true);\n return el.dispatchEvent(evt);\n }\n };\n\n now = function() {\n var _ref, _ref1;\n return (_ref = (_ref1 = window.performance) != null ? typeof _ref1.now === \"function\" ? _ref1.now() : void 0 : void 0) != null ? _ref : +(new Date);\n };\n\n round = function(val, precision) {\n if (precision == null) {\n precision = 0;\n }\n if (!precision) {\n return Math.round(val);\n }\n val *= Math.pow(10, precision);\n val += 0.5;\n val = Math.floor(val);\n return val /= Math.pow(10, precision);\n };\n\n truncate = function(val) {\n if (val < 0) {\n return Math.ceil(val);\n } else {\n return Math.floor(val);\n }\n };\n\n fractionalPart = function(val) {\n return val - round(val);\n };\n\n _jQueryWrapped = false;\n\n (wrapJQuery = function() {\n var property, _i, _len, _ref, _results;\n if (_jQueryWrapped) {\n return;\n }\n if (window.jQuery != null) {\n _jQueryWrapped = true;\n _ref = ['html', 'text'];\n _results = [];\n for (_i = 0, _len = _ref.length; _i < _len; _i++) {\n property = _ref[_i];\n _results.push((function(property) {\n var old;\n old = window.jQuery.fn[property];\n return window.jQuery.fn[property] = function(val) {\n var _ref1;\n if ((val == null) || (((_ref1 = this[0]) != null ? _ref1.odometer : void 0) == null)) {\n return old.apply(this, arguments);\n }\n return this[0].odometer.update(val);\n };\n })(property));\n }\n return _results;\n }\n })();\n\n setTimeout(wrapJQuery, 0);
1173\n\n Odometer = (function() {\n function Odometer(options) {\n var e, k, property, v, _base, _i, _len, _ref, _ref1, _ref2,\n _this = this;\n this.options = options;\n this.el = this.options.el;\n if (this.el.odometer != null) {\n return this.el.odometer;\n }\n this.el.odometer = this;\n _ref = Odometer.options;\n for (k in _ref) {\n v = _ref[k];\n if (this.options[k] == null) {\n this.options[k] = v;\n }\n }\n if ((_base = this.options).duration == null) {\n _base.duration = DURATION;\n }\n this.MAX_VALUES = ((this.options.duration / MS_PER_FRAME) / FRAMES_PER_VALUE) | 0;\n this.resetFormat();\n this.value = this.cleanValue((_ref1 = this.options.value) != null ? _ref1 : '');\n this.renderInside();\n this.render();\n try {\n _ref2 = ['innerHTML', 'innerText', 'textContent'];\n for (_i = 0, _len = _ref2.length; _i < _len; _i++) {\n property = _ref2[_i];\n if (this.el[property] != null) {\n (function(property) {\n return Object.defineProperty(_this.el, property, {\n get: function() {\n var _ref3;\n if (property === 'innerHTML') {\n return _this.inside.outerHTML;\n } else {\n return (_ref3 = _this.inside.innerText) != null ? _ref3 : _this.inside.textContent;\n }\n },\n set: function(val) {\n return _this.update(val);\n }\n });\n })(property);\n }\n }\n } catch (_error) {\n e = _error;\n this.watchForMutations();\n }\n this;\n }\n\n Odometer.prototype.renderInside = function() {\n this.inside = document.createElement('div');\n this.inside.className = 'odometer-inside';\n this.el.innerHTML = '';\n return this.el.appendChild(this.inside);\n };\n\n Odometer.prototype.watchForMutations = function() {\n var e,\n _this = this;\n if (MutationObserver == null) {\n return;\n }\n try {\n if (this.observer == null) {\n this.observer = new MutationObserver(function(mutations) {\n var newVal;\n newVal = _this.el.innerText;\n _this.renderInside();\n _this.render(_this.value);\n return _this.update(newVal);\n });\n }\n this.watchMutations = true;\n return this.startWatchingMutations();\n } catch (_error) {\n e = _error;\n }\n };\n\n Odometer.prototype.startWatchingMutations = function() {\n if (this.watchMutations) {\n return this.observer.observe(this.el, {\n childList: true\n });\n }\n };\n\n Odometer.prototype.stopWatchingMutations = function() {\n var _ref;\n return (_ref = this.observer) != null ? _ref.disconnect() : void 0;\n };\n\n Odometer.prototype.cleanValue = function(val) {\n var _ref;\n if (typeof val === 'string') {\n val = val.replace((_ref = this.format.radix) != null ? _ref : '.', '<radix>');\n val = val.replace(/[.,]/g, '');\n val = val.replace('<radix>', '.');\n val = parseFloat(val, 10) || 0;\n }\n return round(val, this.format.precision);\n };\n\n Odometer.prototype.bindTransitionEnd = function() {\n var event, renderEnqueued, _i, _len, _ref, _results,\n _this = this;\n if (this.transitionEndBound) {\n return;\n }\n this.transitionEndBound = true;\n renderEnqueued = false;\n _ref = TRANSITION_END_EVENTS.split(' ');\n _results = [];\n for (_i = 0, _len = _ref.length; _i < _len; _i++) {\n event = _ref[_i];\n _results.push(this.el.addEventListener(event, function() {\n if (renderEnqueued) {\n return true;\n }\n renderEnqueued = true;\n setTimeout(function() {\n _this.render();\n renderEnqueued = false;\n return trigger(_this.el, 'odometerdone');\n }, 0);\n return true;\n }, false));\n }\n return _results;\n };
1173\n\n Odometer.prototype.resetFormat = function() {\n var format, fractional, parsed, precision, radix, repeating, _ref, _ref1;\n format = (_ref = this.options.format) != null ? _ref : DIGIT_FORMAT;\n format || (format = 'd');\n parsed = FORMAT_PARSER.exec(format);\n if (!parsed) {\n throw new Error(\"Odometer: Unparsable digit format\");\n }\n _ref1 = parsed.slice(1, 4), repeating = _ref1[0], radix = _ref1[1], fractional = _ref1[2];\n precision = (fractional != null ? fractional.length : void 0) || 0;\n return this.format = {\n repeating: repeating,\n radix: radix,\n precision: precision\n };\n };\n\n Odometer.prototype.render = function(value) {\n var classes, cls, match, newClasses, theme, _i, _len;\n if (value == null) {\n value = this.value;\n }\n this.stopWatchingMutations();\n this.resetFormat();\n this.inside.innerHTML = '';\n theme = this.options.theme;\n classes = this.el.className.split(' ');\n newClasses = [];\n for (_i = 0, _len = classes.length; _i < _len; _i++) {\n cls = classes[_i];\n if (!cls.length) {\n continue;\n }\n if (match = /^odometer-theme-(.+)$/.exec(cls)) {\n theme = match[1];\n continue;\n }\n if (/^odometer(-|$)/.test(cls)) {\n continue;\n }\n newClasses.push(cls);\n }\n newClasses.push('odometer');\n if (!TRANSITION_SUPPORT) {\n newClasses.push('odometer-no-transitions');\n }\n if (theme) {\n newClasses.push(\"odometer-theme-\" + theme);\n } else {\n newClasses.push(\"odometer-auto-theme\");\n }\n this.el.className = newClasses.join(' ');\n this.ribbons = {};\n this.formatDigits(value);\n return this.startWatchingMutations();\n };\n\n Odometer.prototype.formatDigits = function(value) {\n var digit, valueDigit, valueString, wholePart, _i, _j, _len, _len1, _ref, _ref1;\n this.digits = [];\n if (this.options.formatFunction) {\n valueString = this.options.formatFunction(value);\n _ref = valueString.split('').reverse();\n for (_i = 0, _len = _ref.length; _i < _len; _i++) {\n valueDigit = _ref[_i];\n if (valueDigit.match(/0-9/)) {\n digit = this.renderDigit();\n digit.querySelector('.odometer-value').innerHTML = valueDigit;\n this.digits.push(digit);\n this.insertDigit(digit);\n } else {\n this.addSpacer(valueDigit);\n }\n }\n } else {\n wholePart = !this.format.precision || !fractionalPart(value) || false;\n _ref1 = value.toString().split('').reverse();\n for (_j = 0, _len1 = _ref1.length; _j < _len1; _j++) {\n digit = _ref1[_j];\n if (digit === '.') {\n wholePart = true;\n }\n this.addDigit(digit, wholePart);\n }\n }\n };\n\n Odometer.prototype.update = function(newValue) {\n var diff,\n _this = this;\n newValue = this.cleanValue(newValue);\n if (!(diff = newValue - this.value)) {\n return;\n }\n removeClass(this.el, 'odometer-animating-up odometer-animating-down odometer-animating');\n if (diff > 0) {\n addClass(this.el, 'odometer-animating-up');\n } else {\n addClass(this.el, 'odometer-animating-down');\n }\n this.stopWatchingMutations();\n this.animate(newValue);\n this.startWatchingMutations();\n setTimeout(function() {\n _this.el.offsetHeight;\n return addClass(_this.el, 'odometer-animating');\n }, 0);\n return this.value = newValue;\n };\n\n Odometer.prototype.renderDigit = function() {\n return createFromHTML(DIGIT_HTML);\n };\n\n Odometer.prototype.insertDigit = function(digit, before) {\n if (before != null) {\n return this.inside.insertBefore(digit, before);\n } else if (!this.inside.children.length) {\n return this.inside.appendChild(digit);\n } else {\n return this.inside.insertBefore(digit, this.inside.children[0]);\n }\n };\n\n Odometer.prototype.addSpacer = function(chr, before, extraClasse
1173s) {\n var spacer;\n spacer = createFromHTML(FORMAT_MARK_HTML);\n spacer.innerHTML = chr;\n if (extraClasses) {\n addClass(spacer, extraClasses);\n }\n return this.insertDigit(spacer, before);\n };\n\n Odometer.prototype.addDigit = function(value, repeating) {\n var chr, digit, resetted, _ref;\n if (repeating == null) {\n repeating = true;\n }\n if (value === '-') {\n return this.addSpacer(value, null, 'odometer-negation-mark');\n }\n if (value === '.') {\n return this.addSpacer((_ref = this.format.radix) != null ? _ref : '.', null, 'odometer-radix-mark');\n }\n if (repeating) {\n resetted = false;\n while (true) {\n if (!this.format.repeating.length) {\n if (resetted) {\n throw new Error(\"Bad odometer format without digits\");\n }\n this.resetFormat();\n resetted = true;\n }\n chr = this.format.repeating[this.format.repeating.length - 1];\n this.format.repeating = this.format.repeating.substring(0, this.format.repeating.length - 1);\n if (chr === 'd') {\n break;\n }\n this.addSpacer(chr);\n }\n }\n digit = this.renderDigit();\n digit.querySelector('.odometer-value').innerHTML = value;\n this.digits.push(digit);\n return this.insertDigit(digit);\n };\n\n Odometer.prototype.animate = function(newValue) {\n if (!TRANSITION_SUPPORT || this.options.animation === 'count') {\n return this.animateCount(newValue);\n } else {\n return this.animateSlide(newValue);\n }\n };\n\n Odometer.prototype.animateCount = function(newValue) {\n var cur, diff, last, start, tick,\n _this = this;\n if (!(diff = +newValue - this.value)) {\n return;\n }\n start = last = now();\n cur = this.value;\n return (tick = function() {\n var delta, dist, fraction;\n if ((now() - start) > _this.options.duration) {\n _this.value = newValue;\n _this.render();\n trigger(_this.el, 'odometerdone');\n return;\n }\n delta = now() - last;\n if (delta > COUNT_MS_PER_FRAME) {\n last = now();\n fraction = delta / _this.options.duration;\n dist = diff * fraction;\n cur += dist;\n _this.render(Math.round(cur));\n }\n if (requestAnimationFrame != null) {\n return requestAnimationFrame(tick);\n } else {\n return setTimeout(tick, COUNT_MS_PER_FRAME);\n }\n })();\n };\n\n Odometer.prototype.getDigitCount = function() {\n var i, max, value, values, _i, _len;\n values = 1 <= arguments.length ? __slice.call(arguments, 0) : [];\n for (i = _i = 0, _len = values.length; _i < _len; i = ++_i) {\n value = values[i];\n values[i] = Math.abs(value);\n }\n max = Math.max.apply(Math, values);\n return Math.ceil(Math.log(max + 1) / Math.log(10));\n };\n\n Odometer.prototype.getFractionalDigitCount = function() {\n var i, parser, parts, value, values, _i, _len;\n values = 1 <= arguments.length ? __slice.call(arguments, 0) : [];\n parser = /^\\-?\\d*\\.(\\d*?)0*$/;\n for (i = _i = 0, _len = values.length; _i < _len; i = ++_i) {\n value = values[i];\n values[i] = value.toString();\n parts = parser.exec(values[i]);\n if (parts == null) {\n values[i] = 0;\n } else {\n values[i] = parts[1].length;\n }\n }\n return Math.max.apply(Math, values);\n };\n\n Odometer.prototype.resetDigits = function() {\n this.digits = [];\n this.ribbons = [];\n this.inside.innerHTML = '';\n return this.resetFormat();\n };\n\n Odometer.prototype.animateSlide = function(newValue) {\n var boosted, cur, diff, digitCount, digits, dist, end, fractionalCount, frame, frames, i, incr, j, mark, numEl, oldValue, start, _base, _i, _j, _k, _l, _len, _len1, _len2, _m, _ref, _results;\n oldValue = this.value;\n fractionalCount = this.getFractionalDigitCount(oldValue, newValue);\n if (fractionalCount) {\n newValue = newValue * Math.pow(10, fractionalCount);\n oldValue = oldValue * Math.pow(10, fractionalCount);\n }\n if (!(diff = newValue - oldValue)) {\n return;\n }\n this.bindTransitionEnd();\n digitCount = this.getDigitCount(oldValue, newValue);\n digits = [];\n boosted = 0;\n for (i = _i = 0; 0 <= digitCount ? _i < digitCount : _i > digitCount; i = 0 <= digitCount ? ++_i : --_i) {\n start = truncate(oldValue / Math.pow(10, digitCount - i - 1));\n end = truncate(newValue / Math.pow(10, digitCount - i - 1));\n dist = end - start;\n if (Math.abs(dist) > this.MAX_VALUES) {\n frames = [];\n incr = dist / (this.MAX_VALUES + this.MAX_VALUES * boosted * DIGIT_SPEEDBOOST);\n cur = start;\n while ((dist > 0 && cur < end) || (dist < 0 && cur > end)) {\n frames.push(Math.round(cur));\n cur += incr;\n }\n if (frames[frames.length - 1] !== end) {\n frames.push(end);\n }\n boosted++;\n }
1173 else {\n frames = (function() {\n _results = [];\n for (var _j = start; start <= end ? _j <= end : _j >= end; start <= end ? _j++ : _j--){ _results.push(_j); }\n return _results;\n }).apply(this);\n }\n for (i = _k = 0, _len = frames.length; _k < _len; i = ++_k) {\n frame = frames[i];\n frames[i] = Math.abs(frame % 10);\n }\n digits.push(frames);\n }\n this.resetDigits();\n _ref = digits.reverse();\n for (i = _l = 0, _len1 = _ref.length; _l < _len1; i = ++_l) {\n frames = _ref[i];\n if (!this.digits[i]) {\n this.addDigit(' ', i >= fractionalCount);\n }\n if ((_base = this.ribbons)[i] == null) {\n _base[i] = this.digits[i].querySelector('.odometer-ribbon-inner');\n }\n this.ribbons[i].innerHTML = '';\n if (diff < 0) {\n frames = frames.reverse();\n }\n for (j = _m = 0, _len2 = frames.length; _m < _len2; j = ++_m) {\n frame = frames[j];\n numEl = document.createElement('div');\n numEl.className = 'odometer-value';\n numEl.innerHTML = frame;\n this.ribbons[i].appendChild(numEl);\n if (j === frames.length - 1) {\n addClass(numEl, 'odometer-last-value');\n }\n if (j === 0) {\n addClass(numEl, 'odometer-first-value');\n }\n }\n }\n if (start < 0) {\n this.addDigit('-');\n }\n mark = this.inside.querySelector('.odometer-radix-mark');\n if (mark != null) {\n mark.parent.removeChild(mark);\n }\n if (fractionalCount) {\n return this.addSpacer(this.format.radix, this.digits[fractionalCount - 1], 'odometer-radix-mark');\n }\n };\n\n return Odometer;\n\n })();\n\n Odometer.options = (_ref = window.odometerOptions) != null ? _ref : {};\n\n setTimeout(function() {\n var k, v, _base, _ref1, _results;\n if (window.odometerOptions) {\n _ref1 = window.odometerOptions;\n _results = [];\n for (k in _ref1) {\n v = _ref1[k];\n _results.push((_base = Odometer.options)[k] != null ? (_base = Odometer.options)[k] : _base[k] = v);\n }\n return _results;\n }\n }, 0);\n\n Odometer.init = function() {\n var el, elements, _i, _len, _ref1, _results;\n if (document.querySelectorAll == null) {\n return;\n }\n elements = document.querySelectorAll(Odometer.options.selector || '.odometer');\n _results = [];\n for (_i = 0, _len = elements.length; _i < _len; _i++) {\n el = elements[_i];\n _results.push(el.odometer = new Odometer({\n el: el,\n value: (_ref1 = el.innerText) != null ? _ref1 : el.textContent\n }));\n }\n return _results;\n };\n\n if ((((_ref1 = document.documentElement) != null ? _ref1.doScroll : void 0) != null) && (document.createEventObject != null)) {\n _old = document.onreadystatechange;\n document.onreadystatechange = function() {\n if (document.readyState === 'complete' && Odometer.options.auto !== false) {\n Odometer.init();\n }\n return _old != null ? _old.apply(this, arguments) : void 0;\n };\n } else {\n document.addEventListener('DOMContentLoaded', function() {\n if (Odometer.options.auto !== false) {\n return Odometer.init();\n }\n }, false);\n }\n\n if (true) {\n !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = (function() {\n return Odometer;\n }).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),\n\t\t__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));\n } else // removed by dead control flow\n{}\n\n}).call(this);\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/odometer/odometer.js?\n}"); 1174 1175/***/ }, 1176 1177/***/ "./node_modules/swiper/modules/a11y.mjs" 1178/*!**********************************************!*\ 1179 !*** ./node_modules/swiper/modules/a11y.mjs ***! 1180 \**********************************************/ 1181(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1182 1183"use strict"; 1184eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ A11y)\n/* harmony export */ });\n/* harmony import */ var _shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/classes-to-selector.mjs */ \"./node_modules/swiper/shared/classes-to-selector.mjs\");\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\n\nconst isVirtualEnabled = (swiper) => !!swiper.virtual && !!swiper.params.virtual?.enabled;\nconst A11y = ({ swiper, extendParams, on }) =>
1184 {\n extendParams({\n a11y: {\n enabled: true,\n notificationClass: 'swiper-notification',\n prevSlideMessage: 'Previous slide',\n nextSlideMessage: 'Next slide',\n firstSlideMessage: 'This is the first slide',\n lastSlideMessage: 'This is the last slide',\n paginationBulletMessage: 'Go to slide {{index}}',\n slideLabelMessage: '{{index}} / {{slidesLength}}',\n containerMessage: null,\n containerRoleDescriptionMessage: null,\n containerRole: null,\n itemRoleDescriptionMessage: null,\n slideRole: 'group',\n id: null,\n scrollOnFocus: true,\n wrapperLiveRegion: true,\n },\n });\n swiper.a11y = {\n clicked: false,\n };\n let liveRegion = null;\n let preventFocusHandler = false;\n let focusTargetSlideEl;\n let visibilityChangedTimestamp = new Date().getTime();\n function getParams() {\n return swiper.params.a11y;\n }\n function notify(message) {\n const notification = liveRegion;\n if (!notification || !message)\n return;\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.w)(notification, message);\n }\n function getRandomNumber(size = 16) {\n const randomChar = () => Math.round(16 * Math.random()).toString(16);\n return 'x'.repeat(size).replace(/x/g, randomChar);\n }\n function makeElFocusable(el) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(el);\n els.forEach((subEl) => {\n subEl.setAttribute('tabIndex', '0');\n });\n }\n function makeElNotFocusable(el) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(el);\n els.forEach((subEl) => {\n subEl.setAttribute('tabIndex', '-1');\n });\n }\n function addElRole(el, role) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(el);\n els.forEach((subEl) => {\n subEl.setAttribute('role', role);\n });\n }\n function addElRoleDescription(el, description) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(el);\n els.forEach((subEl) => {\n subEl.setAttribute('aria-roledescription', description);\n });\n }\n function addElLabel(el, label) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(el);\n els.forEach((subEl) => {\n subEl.setAttribute('aria-label', label);\n });\n }\n function addElId(el, id) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(el);\n els.forEach((subEl) => {\n subEl.setAttribute('id', id);\n });\n }\n function addElLive(el, live) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(el);\n els.forEach((subEl) => {\n subEl.setAttribute('aria-live', live);\n });\n }\n function disableEl(el) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(el);\n els.forEach((subEl) => {\n subEl.setAttribute('aria-disabled', 'true');\n });\n }\n function enableEl(el) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(el);\n els.forEach((subEl) => {\n subEl.removeAttribute('aria-disabled');\n });\n }\n function onEnterOrSpaceKey(e) {\n if (e.keyCode !== 13 && e.keyCode !== 32)\n return;\n const params = getParams();\n const paginationParams = swiper.params.pagination;\n const targetEl = e.target;\n if (swiper.pagination &&\n swiper.pagination.el &&\n (targetEl === swiper.pagination.el || swiper.pagination.el.contains(targetEl))) {\n if (!targetEl.matches((0,_shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__.c)(paginationParams?.bulletClass)))\n return;\n }\n if (swiper.navigation && swiper.navigation.prevEl && swiper.navigation.nextEl) {\n const prevEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(swiper.navigation.prevEl);\n const nextEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(swiper.navigation.nextEl);\n if (nextEls.includes(targetEl)) {\n if (!(swiper.isEnd && !swiper.params.loop)) {\n swiper.slideNext();\n }\n if (swiper.isEnd) {\n notify(params.lastSlideMessage);\n }\n else {\n notify(params.nextSlideMessage);\n }\n }\n if (prevEls.includes(targetEl)) {\n if (!(swiper.isBeginning && !swiper.params.loop)) {\n swiper.slidePrev();\n }\n if (swiper.isBeginning) {\n notify(params.firstSlideMessage);\n }\n else {\n notify(params.prevSlideMessage);\n }\n }\n }\n if (swiper.pagination && targetEl.matches((0,_shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__.c)(paginationParams?.bulletClass))) {\n targetEl.click();\n }\n }
1184\n function updateNavigation() {\n if (swiper.params.loop || swiper.params.rewind || !swiper.navigation)\n return;\n const { nextEl, prevEl } = swiper.navigation;\n if (prevEl) {\n if (swiper.isBeginning) {\n disableEl(prevEl);\n makeElNotFocusable(prevEl);\n }\n else {\n enableEl(prevEl);\n makeElFocusable(prevEl);\n }\n }\n if (nextEl) {\n if (swiper.isEnd) {\n disableEl(nextEl);\n makeElNotFocusable(nextEl);\n }\n else {\n enableEl(nextEl);\n makeElFocusable(nextEl);\n }\n }\n }\n function hasPagination() {\n return !!(swiper.pagination && swiper.pagination.bullets && swiper.pagination.bullets.length);\n }\n function hasClickablePagination() {\n const paginationParams = swiper.params.pagination;\n return hasPagination() && !!paginationParams?.clickable;\n }\n function updatePagination() {\n const params = getParams();\n if (!hasPagination())\n return;\n const paginationParams = swiper.params.pagination;\n swiper.pagination.bullets.forEach((bulletEl) => {\n if (paginationParams.clickable) {\n makeElFocusable(bulletEl);\n if (!paginationParams.renderBullet) {\n addElRole(bulletEl, 'button');\n addElLabel(bulletEl, params.paginationBulletMessage.replace(/\\{\\{index\\}\\}/, String(((0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.b)(bulletEl) ?? 0) + 1)));\n }\n }\n if (bulletEl.matches((0,_shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__.c)(paginationParams.bulletActiveClass))) {\n bulletEl.setAttribute('aria-current', 'true');\n }\n else {\n bulletEl.removeAttribute('aria-current');\n }\n });\n }\n const initNavEl = (el, _wrapperId, message) => {\n makeElFocusable(el);\n if (el.tagName !== 'BUTTON') {\n addElRole(el, 'button');\n el.addEventListener('keydown', onEnterOrSpaceKey);\n }\n addElLabel(el, message);\n };\n const handlePointerDown = (e) => {\n if (focusTargetSlideEl &&\n focusTargetSlideEl !== e.target &&\n !focusTargetSlideEl.contains(e.target)) {\n preventFocusHandler = true;\n }\n swiper.a11y.clicked = true;\n };\n const handlePointerUp = () => {\n preventFocusHandler = false;\n requestAnimationFrame(() => {\n requestAnimationFrame(() => {\n if (!swiper.destroyed) {\n swiper.a11y.clicked = false;\n }\n });\n });\n };\n const onVisibilityChange = (_e) => {\n visibilityChangedTimestamp = new Date().getTime();\n };\n const handleFocus = (e) => {\n const params = getParams();\n if (swiper.a11y.clicked || !params.scrollOnFocus)\n return;\n if (new Date().getTime() - visibilityChangedTimestamp < 100)\n return;\n const target = e.target;\n const slideEl = target.closest(`.${swiper.params.slideClass}, swiper-slide`);\n if (!slideEl || !swiper.slides.includes(slideEl))\n return;\n focusTargetSlideEl = slideEl;\n const isVirtual = isVirtualEnabled(swiper);\n const isActive = (isVirtual\n ? parseInt(slideEl.getAttribute('data-swiper-slide-index') || '0', 10)\n : swiper.slides.indexOf(slideEl)) === swiper.activeIndex;\n const isVisible = swiper.params.watchSlidesProgress &&\n swiper.visibleSlides &&\n swiper.visibleSlides.includes(slideEl);\n if (isActive || isVisible)\n return;\n const sourceCapabilities = e.sourceCapabilities;\n if (sourceCapabilities && sourceCapabilities.firesTouchEvents)\n return;\n if (swiper.isHorizontal()) {\n swiper.el.scrollLeft = 0;\n }\n else {\n swiper.el.scrollTop = 0;\n }\n requestAnimationFrame(() =>
1184 {\n if (preventFocusHandler)\n return;\n if (swiper.params.loop) {\n swiper.slideToLoop(swiper.getSlideIndexWhenGrid(parseInt(slideEl.getAttribute('data-swiper-slide-index') || '0', 10)), 0);\n }\n else if (isVirtual) {\n swiper.slideTo(swiper.getSlideIndexWhenGrid(parseInt(slideEl.getAttribute('data-swiper-slide-index') || '0', 10)), 0);\n }\n else {\n swiper.slideTo(swiper.getSlideIndexWhenGrid(swiper.slides.indexOf(slideEl)), 0);\n }\n preventFocusHandler = false;\n });\n };\n const initSlides = () => {\n const params = getParams();\n if (params.itemRoleDescriptionMessage) {\n addElRoleDescription(swiper.slides, params.itemRoleDescriptionMessage);\n }\n if (params.slideRole) {\n addElRole(swiper.slides, params.slideRole);\n }\n const slidesLength = swiper.slides.length;\n const slideLabelMessage = params.slideLabelMessage;\n if (slideLabelMessage) {\n swiper.slides.forEach((slideEl, index) => {\n const slideIndex = swiper.params.loop\n ? parseInt(slideEl.getAttribute('data-swiper-slide-index') || '0', 10)\n : index;\n const ariaLabelMessage = slideLabelMessage\n .replace(/\\{\\{index\\}\\}/, String(slideIndex + 1))\n .replace(/\\{\\{slidesLength\\}\\}/, String(slidesLength));\n addElLabel(slideEl, ariaLabelMessage);\n });\n }\n };\n const init = () => {\n const params = getParams();\n if (liveRegion)\n swiper.el.append(liveRegion);\n // Container\n const containerEl = swiper.el;\n if (params.containerRoleDescriptionMessage) {\n addElRoleDescription(containerEl, params.containerRoleDescriptionMessage);\n }\n if (params.containerMessage) {\n addElLabel(containerEl, params.containerMessage);\n }\n if (params.containerRole) {\n addElRole(containerEl, params.containerRole);\n }\n // Wrapper\n const wrapperEl = swiper.wrapperEl;\n const wrapperId = String(params.id || wrapperEl.getAttribute('id') || `swiper-wrapper-${getRandomNumber(16)}`);\n addElId(wrapperEl, wrapperId);\n if (params.wrapperLiveRegion) {\n const autoplayParams = swiper.params.autoplay;\n const live = swiper.params.autoplay && autoplayParams?.enabled ? 'off' : 'polite';\n addElLive(wrapperEl, live);\n }\n // Slide\n initSlides();\n // Navigation\n const nav = swiper.navigation\n ? swiper.navigation\n : { nextEl: undefined, prevEl: undefined };\n const nextEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(nav.nextEl);\n const prevEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(nav.prevEl);\n if (nextEls) {\n nextEls.forEach((el) => initNavEl(el, wrapperId, params.nextSlideMessage));\n }\n if (prevEls) {\n prevEls.forEach((el) => initNavEl(el, wrapperId, params.prevSlideMessage));\n }\n // Pagination\n if (hasClickablePagination()) {\n const paginationEl = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(swiper.pagination.el);\n paginationEl.forEach((el) => {\n el.addEventListener('keydown', onEnterOrSpaceKey);\n });\n }\n // Tab focus\n document.addEventListener('visibilitychange', onVisibilityChange);\n swiper.el.addEventListener('focus', handleFocus, true);\n swiper.el.addEventListener('pointerdown', handlePointerDown, true);\n swiper.el.addEventListener('pointerup', handlePointerUp, true);\n };\n function destroy() {\n if (liveRegion)\n liveRegion.remove();\n const nav = swiper.navigation\n ? swiper.navigation\n : { nextEl: undefined, prevEl: undefined };\n const nextEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(nav.nextEl);\n const prevEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(nav.prevEl);
1184\n if (nextEls) {\n nextEls.forEach((el) => el.removeEventListener('keydown', onEnterOrSpaceKey));\n }\n if (prevEls) {\n prevEls.forEach((el) => el.removeEventListener('keydown', onEnterOrSpaceKey));\n }\n // Pagination\n if (hasClickablePagination()) {\n const paginationEl = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(swiper.pagination.el);\n paginationEl.forEach((el) => {\n el.removeEventListener('keydown', onEnterOrSpaceKey);\n });\n }\n document.removeEventListener('visibilitychange', onVisibilityChange);\n // Tab focus\n if (swiper.el && typeof swiper.el !== 'string') {\n swiper.el.removeEventListener('focus', handleFocus, true);\n swiper.el.removeEventListener('pointerdown', handlePointerDown, true);\n swiper.el.removeEventListener('pointerup', handlePointerUp, true);\n }\n }\n on('beforeInit', () => {\n liveRegion = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.a)('span', getParams().notificationClass);\n liveRegion.setAttribute('aria-live', 'assertive');\n liveRegion.setAttribute('aria-atomic', 'true');\n });\n on('afterInit', () => {\n if (!getParams().enabled)\n return;\n init();\n });\n on('slidesLengthChange snapGridLengthChange slidesGridLengthChange', () => {\n if (!getParams().enabled)\n return;\n initSlides();\n });\n on('fromEdge toEdge afterInit lock unlock', () => {\n if (!getParams().enabled)\n return;\n updateNavigation();\n });\n on('paginationUpdate', () => {\n if (!getParams().enabled)\n return;\n updatePagination();\n });\n on('destroy', () => {\n if (!getParams().enabled)\n return;\n destroy();\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/a11y.mjs?\n}"); 1185 1186/***/ }, 1187 1188/***/ "./node_modules/swiper/modules/autoplay.mjs" 1189/*!**************************************************!*\ 1190 !*** ./node_modules/swiper/modules/autoplay.mjs ***! 1191 \**************************************************/ 1192(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1193 1194"use strict"; 1195eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Autoplay)\n/* harmony export */ });\nconst Autoplay = ({ swiper, extendParams, on, emit, params }) => {\n swiper.autoplay = {\n running: false,\n paused: false,\n timeLeft: 0,\n };\n extendParams({\n autoplay: {\n enabled: false,\n delay: 3000,\n waitForTransition: true,\n disableOnInteraction: false,\n stopOnLastSlide: false,\n reverseDirection: false,\n pauseOnMouseEnter: false,\n },\n });\n function getParams() {\n return swiper.params.autoplay;\n }\n // params here is the user-supplied passedParams; extendParams hasn't yet\n // merged the defaults into swiper.params.autoplay at this point.\n const initialAutoplayDelay = typeof params.autoplay === 'object' &&\n params.autoplay &&\n typeof params.autoplay.delay === 'number'\n ? params.autoplay.delay\n : 3000;\n let timeout;\n let raf;\n let autoplayDelayTotal = initialAutoplayDelay;\n let autoplayDelayCurrent = initialAutoplayDelay;\n let autoplayTimeLeft = 0;\n let autoplayStartTime = new Date().getTime();\n let wasPaused = false;\n let isTouched = false;\n let pausedByTouch = false;\n let touchStartTimeout;\n let pausedByInteraction = false;\n let pausedByPointerEnter = false;\n function onTransitionEnd(e) {\n if (!swiper || swiper.destroyed || !swiper.wrapperEl)\n return;\n if (e.target !== swiper.wrapperEl)\n return;\n swiper.wrapperEl.removeEventListener('transitionend', onTransitionEnd);\n const detail = e.detail;\n if (pausedByPointerEnter || (detail && detail.bySwiperTouchMove)) {\
1195n return;\n }\n resume();\n }\n const calcTimeLeft = () => {\n if (swiper.destroyed || !swiper.autoplay.running)\n return;\n if (swiper.autoplay.paused) {\n wasPaused = true;\n }\n else if (wasPaused) {\n autoplayDelayCurrent = autoplayTimeLeft;\n wasPaused = false;\n }\n const timeLeft = swiper.autoplay.paused\n ? autoplayTimeLeft\n : autoplayStartTime + autoplayDelayCurrent - new Date().getTime();\n swiper.autoplay.timeLeft = timeLeft;\n emit('autoplayTimeLeft', timeLeft, timeLeft / autoplayDelayTotal);\n raf = requestAnimationFrame(() => {\n calcTimeLeft();\n });\n };\n const getSlideDelay = () => {\n let activeSlideEl;\n const virtualEnabled = !!swiper.params.virtual?.enabled;\n if (swiper.virtual && virtualEnabled) {\n activeSlideEl = swiper.slides.find((slideEl) => slideEl.classList.contains('swiper-slide-active'));\n }\n else {\n activeSlideEl = swiper.slides[swiper.activeIndex];\n }\n if (!activeSlideEl)\n return undefined;\n const attr = activeSlideEl.getAttribute('data-swiper-autoplay');\n if (attr == null)\n return undefined;\n return parseInt(attr, 10);\n };\n const getTotalDelay = () => {\n let totalDelay = getParams().delay;\n const currentSlideDelay = getSlideDelay();\n if (typeof currentSlideDelay === 'number' &&\n !Number.isNaN(currentSlideDelay) &&\n currentSlideDelay > 0) {\n totalDelay = currentSlideDelay;\n }\n return totalDelay;\n };\n const run = (delayForce) => {\n if (swiper.destroyed || !swiper.autoplay.running)\n return 0;\n if (raf !== undefined)\n cancelAnimationFrame(raf);\n calcTimeLeft();\n let delay = delayForce;\n if (typeof delay === 'undefined') {\n delay = getTotalDelay();\n autoplayDelayTotal = delay;\n autoplayDelayCurrent = delay;\n }\n autoplayTimeLeft = delay;\n const speed = swiper.params.speed;\n const proceed = () => {\n if (!swiper || swiper.destroyed)\n return;\n const autoplayParams = getParams();\n if (autoplayParams.reverseDirection) {\n if (!swiper.isBeginning || swiper.params.loop || swiper.params.rewind) {\n swiper.slidePrev(speed, true, true);\n emit('autoplay');\n }\n else if (!autoplayParams.stopOnLastSlide) {\n swiper.slideTo(swiper.slides.length - 1, speed, true, true);\n emit('autoplay');\n }\n }\n else {\n if (!swiper.isEnd || swiper.params.loop || swiper.params.rewind) {\n swiper.slideNext(speed, true, true);\n emit('autoplay');\n }\n else if (!autoplayParams.stopOnLastSlide) {\n swiper.slideTo(0, speed, true, true);\n emit('autoplay');\n }\n }\n if (swiper.params.cssMode) {\n autoplayStartTime = new Date().getTime();\n requestAnimationFrame(() => {\n run();\n });\n }\n };\n if (delay > 0) {\n if (timeout !== undefined)\n clearTimeout(timeout);\n timeout = setTimeout(() => {\n proceed();\n }, delay);\n }\n else {\n requestAnimationFrame(() => {\n proceed();\n });\n }\n return delay;\n };\n const start = () => {\n autoplayStartTime = new Date().getTime();\n swiper.autoplay.running = true;\n run();\n emit('autoplayStart');\n return true;\n };\n const stop = () => {\n swiper.autoplay.running = false;\n if (timeout !== undefined)\n clearTimeout(timeout);\n if (raf !== undefined)\n cancelAnimationFrame(raf);\n emit('autoplayStop');\n return true;\n };\n const pause = (internal, reset) => {\n if (swiper.destroyed || !swiper.autoplay.running)\n return;\n if (timeout !== undefined)\n clearTimeout(timeout);\n if (!internal) {\n pausedByInteraction = true;\n }\n const proceed = () => {\n emit('autoplayPause');\n if (getParams().waitForTransition) {\n swiper.wrapperEl.addEventListener('transitionend', onTransitionEnd);\n }\n else {\n resume();\n }\n };\n swiper.autoplay.paused = true;\n if (reset) {\n proceed();\n return;\n }
1195\n const delay = autoplayTimeLeft || getParams().delay;\n autoplayTimeLeft = delay - (new Date().getTime() - autoplayStartTime);\n if (swiper.isEnd && autoplayTimeLeft < 0 && !swiper.params.loop)\n return;\n if (autoplayTimeLeft < 0)\n autoplayTimeLeft = 0;\n proceed();\n };\n const resume = () => {\n if ((swiper.isEnd && autoplayTimeLeft < 0 && !swiper.params.loop) ||\n swiper.destroyed ||\n !swiper.autoplay.running)\n return;\n autoplayStartTime = new Date().getTime();\n if (pausedByInteraction) {\n pausedByInteraction = false;\n run(autoplayTimeLeft);\n }\n else {\n run();\n }\n swiper.autoplay.paused = false;\n emit('autoplayResume');\n };\n const onVisibilityChange = () => {\n if (swiper.destroyed || !swiper.autoplay.running)\n return;\n if (document.visibilityState === 'hidden') {\n pausedByInteraction = true;\n pause(true);\n }\n if (document.visibilityState === 'visible') {\n resume();\n }\n };\n const onPointerEnter = (e) => {\n if (e.pointerType !== 'mouse')\n return;\n pausedByInteraction = true;\n pausedByPointerEnter = true;\n if (swiper.animating || swiper.autoplay.paused)\n return;\n pause(true);\n };\n const onPointerLeave = (e) => {\n if (e.pointerType !== 'mouse')\n return;\n pausedByPointerEnter = false;\n if (swiper.autoplay.paused) {\n resume();\n }\n };\n const attachMouseEvents = () => {\n if (getParams().pauseOnMouseEnter) {\n swiper.el.addEventListener('pointerenter', onPointerEnter);\n swiper.el.addEventListener('pointerleave', onPointerLeave);\n }\n };\n const detachMouseEvents = () => {\n if (swiper.el && typeof swiper.el !== 'string') {\n swiper.el.removeEventListener('pointerenter', onPointerEnter);\n swiper.el.removeEventListener('pointerleave', onPointerLeave);\n }\n };\n const attachDocumentEvents = () => {\n document.addEventListener('visibilitychange', onVisibilityChange);\n };\n const detachDocumentEvents = () => {\n document.removeEventListener('visibilitychange', onVisibilityChange);\n };\n on('init', () => {\n if (getParams().enabled) {\n attachMouseEvents();\n attachDocumentEvents();\n start();\n }\n });\n on('destroy', () => {\n detachMouseEvents();\n detachDocumentEvents();\n if (swiper.autoplay.running) {\n stop();\n }\n });\n on('_freeModeStaticRelease', () => {\n if (pausedByTouch || pausedByInteraction) {\n resume();\n }\n });\n on('_freeModeNoMomentumRelease', () => {\n if (!getParams().disableOnInteraction) {\n pause(true, true);\n }\n else {\n stop();\n }\n });\n on('beforeTransitionStart', (_s, _speed, internal) => {\n if (swiper.destroyed || !swiper.autoplay.running)\n return;\n if (internal || !getParams().disableOnInteraction) {\n pause(true, true);\n }\n else {\n stop();\n }\n });\n on('sliderFirstMove', () => {\n if (swiper.destroyed || !swiper.autoplay.running)\n return;\n if (getParams().disableOnInteraction) {\n stop();\n return;\n }\n isTouched = true;\n pausedByTouch = false;\n pausedByInteraction = false;\n touchStartTimeout = setTimeout(() => {\n pausedByInteraction = true;\n pausedByTouch = true;\n pause(true);\n }, 200);\n });\n on('touchEnd', () => {\n if (swiper.destroyed || !swiper.autoplay.running || !isTouched)\n return;\n if (touchStartTimeout !== undefined)\n clearTimeout(touchStartTimeout);\n if (timeout !== undefined)\n clearTimeout(timeout);\n if (getParams().disableOnInteraction) {\n pausedByTouch = false;\n isTouched = false;\n return;\n }\n if (pausedByTouch && swiper.params.cssMode)\n resume();\n pausedByTouch = false;\n isTouched = false;\n });\n on('slideChange', () => {\n if (swiper.destroyed || !swiper.autoplay.running)\n return;\n if (swiper.autoplay.paused) {\n autoplayTimeLeft = getTotalDelay();\n autoplayDelayTotal = getTotalDelay();\n }\n });\n Object.assign(swiper.autoplay, {\n start,\n stop,\n pause,\n resume,\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/autoplay.mjs?\n}"); 1196 1197/***/ }, 1198 1199/***/ "./node_modules/swiper/modules/controller.mjs" 1200/*!****************************************************!*\ 1201 !*** ./node_modules/swiper/modules/controller.mjs ***! 1202 \****************************************************/ 1203(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1204 1205"use strict"; 1206eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Controller)\n/* harmony export */ });\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nclass LinearSpline {\n x;\n y;\n lastIndex;\n binarySearch;\n constructor(x, y) {\n let maxIndex;\n let minIndex;\n let guess;\n this.binarySearch = (array, val) => {\n minIndex = -1;\n maxIndex = array.length;\n while (maxIndex - minIndex > 1) {\n guess = (maxIndex + minIndex) >> 1;\n if (array[guess] <= val) {\n minIndex = guess;\n }\n else {\n maxIndex = guess;\n }\n }
1206\n return maxIndex;\n };\n this.x = x;\n this.y = y;\n this.lastIndex = x.length - 1;\n }\n interpolate(x2) {\n if (!x2)\n return 0;\n const i3 = this.binarySearch(this.x, x2);\n const i1 = i3 - 1;\n // Given an x value (x2), return the expected y2 value:\n // (x1,y1) is the known point before given value,\n // (x3,y3) is the known point after given value.\n // y2 := ((x2âx1) à (y3ây1)) ÷ (x3âx1) + y1\n return (((x2 - this.x[i1]) * (this.y[i3] - this.y[i1])) / (this.x[i3] - this.x[i1]) + this.y[i1]);\n }\n}\nconst Controller = ({ swiper, extendParams, on }) => {\n extendParams({\n controller: {\n control: undefined,\n inverse: false,\n by: 'slide', // or 'container'\n },\n });\n swiper.controller = {\n control: undefined,\n };\n function getParams() {\n return swiper.params.controller;\n }\n function getInterpolateFunction(c) {\n swiper.controller.spline = swiper.params.loop\n ? new LinearSpline(swiper.slidesGrid, c.slidesGrid)\n : new LinearSpline(swiper.snapGrid, c.snapGrid);\n }\n function setTranslate(_t, byController) {\n const controlled = swiper.controller.control;\n let multiplier;\n let controlledTranslate;\n const SwiperCtor = swiper.constructor;\n function setControlledTranslate(c) {\n if (c.destroyed)\n return;\n // this will create an Interpolate function based on the snapGrids\n // x is the Grid of the scrolled scroller and y will be the controlled scroller\n // it makes sense to create this only once and recall it for the interpolation\n // the function does a lot of value caching for performance\n const translate = swiper.rtlTranslate ? -swiper.translate : swiper.translate;\n const controllerParams = getParams();\n if (controllerParams.by === 'slide') {\n getInterpolateFunction(c);\n // i am not sure why the values have to be multiplicated this way, tried to invert the snapGrid\n // but it did not work out\n controlledTranslate = -swiper.controller.spline.interpolate(-translate);\n }\n else {\n controlledTranslate = 0;\n }\n if (!controlledTranslate || controllerParams.by === 'container') {\n multiplier =\n (c.maxTranslate() - c.minTranslate()) / (swiper.maxTranslate() - swiper.minTranslate());\n if (Number.isNaN(multiplier) || !Number.isFinite(multiplier)) {\n multiplier = 1;\n }\n controlledTranslate = (translate - swiper.minTranslate()) * multiplier + c.minTranslate();\n }\n if (controllerParams.inverse) {\n controlledTranslate = c.maxTranslate() - controlledTranslate;\n }\n c.updateProgress(controlledTranslate);\n c.setTranslate(controlledTranslate, swiper);\n c.updateActiveIndex();\n c.updateSlidesClasses();\n }\n if (Array.isArray(controlled)) {\n for (let i = 0; i < controlled.length; i += 1) {\n const target = controlled[i];\n if (target && target !== byController && target instanceof SwiperCtor) {\n setControlledTranslate(target);\n }\n }\n }\n else if (controlled instanceof SwiperCtor && byController !== controlled) {\n setControlledTranslate(controlled);\n }\n }\n function setTransition(duration, byController) {\n const SwiperCtor = swiper.constructor;\n const controlled = swiper.controller.control;\n function setControlledTransition(c) {\n if (c.destroyed)\n return;\n c.setTransition(duration, swiper);\n if (duration !== 0) {\n c.transitionStart();\n if (c.params.autoHeight) {\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.t)(() =>
1206 {\n c.updateAutoHeight();\n });\n }\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.m)(c.wrapperEl, () => {\n if (!controlled)\n return;\n c.transitionEnd();\n });\n }\n }\n if (Array.isArray(controlled)) {\n for (let i = 0; i < controlled.length; i += 1) {\n const target = controlled[i];\n if (target && target !== byController && target instanceof SwiperCtor) {\n setControlledTransition(target);\n }\n }\n }\n else if (controlled instanceof SwiperCtor && byController !== controlled) {\n setControlledTransition(controlled);\n }\n }\n function removeSpline() {\n if (!swiper.controller.control)\n return;\n if (swiper.controller.spline) {\n swiper.controller.spline = undefined;\n delete swiper.controller.spline;\n }\n }\n on('beforeInit', () => {\n const controllerParam = getParams().control;\n if (typeof window !== 'undefined' &&\n (typeof controllerParam === 'string' || controllerParam instanceof HTMLElement)) {\n const controlElements = typeof controllerParam === 'string'\n ? [...document.querySelectorAll(controllerParam)]\n : [controllerParam];\n controlElements.forEach((controlElement) => {\n if (!swiper.controller.control)\n swiper.controller.control = [];\n const list = swiper.controller.control;\n if (controlElement && controlElement.swiper) {\n list.push(controlElement.swiper);\n }\n else if (controlElement) {\n const eventName = `${swiper.params.eventsPrefix}init`;\n const onControllerSwiper = (e) => {\n const detail = e.detail;\n if (detail && detail[0])\n list.push(detail[0]);\n swiper.update();\n controlElement.removeEventListener(eventName, onControllerSwiper);\n };\n controlElement.addEventListener(eventName, onControllerSwiper);\n }\n });\n return;\n }\n // After this point control is either Swiper or Swiper[] (or null/undefined),\n // never the string/HTMLElement forms that the public option accepts.\n swiper.controller.control = controllerParam;\n });\n on('update', () => {\n removeSpline();\n });\n on('resize', () => {\n removeSpline();\n });\n on('observerUpdate', () => {\n removeSpline();\n });\n // Event payloads come typed against the legacy public Swiper class\n // (src/types/swiper-class.d.ts) until Phase 5 deletes src/types/; cast the\n // forwarded byController back to the core Swiper so it lines up with the\n // controller-internal signatures.\n on('setTranslate', (_s, translate, byController) => {\n if (!swiper.controller.control)\n return;\n if (!Array.isArray(swiper.controller.control) && swiper.controller.control.destroyed)\n return;\n swiper.controller.setTranslate(translate, byController);\n });\n on('setTransition', (_s, duration, byController) => {\n if (!swiper.controller.control)\n return;\n if (!Array.isArray(swiper.controller.control) && swiper.controller.control.destroyed)\n return;\n swiper.controller.setTransition(duration, byController);\n });\n Object.assign(swiper.controller, {\n setTranslate,\n setTransition,\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/controller.mjs?\n}"); 1207 1208/***/ }, 1209 1210/***/ "./node_modules/swiper/modules/effect-cards.mjs" 1211/*!******************************************************!*\ 1212 !*** ./node_modules/swiper/modules/effect-cards.mjs ***! 1213 \******************************************************/ 1214(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1215 1216"use strict"; 1217eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ EffectCards)\n/* harmony export */ });\n/* harmony import */ var _shared_create_shadow_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/create-shadow.mjs */ \"./node_modules/swiper/shared/create-shadow.mjs\");\n/* harmony import */ var _shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../shared/effect-init.mjs */ \"./node_modules/swiper/shared/effect-init.mjs\");\n/* harmony import */ var _shared_effect_target_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../shared/effect-target.mjs */ \"./node_modules/swiper/shared/effect-target.mjs\");\n/* harmony import */ var _shared_effect_virtual_transition_end_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../shared/effect-virtual-transition-end.mjs */ \"./node_modules/swiper/shared/effect-virtual-transition-end.mjs\");\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\n\n\n\n\nconst EffectCards = ({ swiper, extendParams, on }) =>
1217 {\n extendParams({\n cardsEffect: {\n slideShadows: true,\n rotate: true,\n perSlideRotate: 2,\n perSlideOffset: 8,\n },\n });\n function getParams() {\n return swiper.params.cardsEffect;\n }\n const setTranslate = () => {\n const { slides, activeIndex, rtlTranslate: rtl } = swiper;\n const params = getParams();\n const { startTranslate, isTouched } = swiper.touchEventsData;\n const currentTranslate = rtl ? -swiper.translate : swiper.translate;\n for (let i = 0; i < slides.length; i += 1) {\n const slideEl = slides[i];\n const slideProgress = slideEl.progress ?? 0;\n const progress = Math.min(Math.max(slideProgress, -4), 4);\n let offset = slideEl.swiperSlideOffset ?? 0;\n if (swiper.params.centeredSlides && !swiper.params.cssMode) {\n swiper.wrapperEl.style.transform = `translateX(${swiper.minTranslate()}px)`;\n }\n if (swiper.params.centeredSlides && swiper.params.cssMode) {\n offset -= slides[0].swiperSlideOffset ?? 0;\n }\n let tX = swiper.params.cssMode ? -offset - swiper.translate : -offset;\n let tY = 0;\n const tZ = -100 * Math.abs(progress);\n let scale = 1;\n let rotate = -params.perSlideRotate * progress;\n let tXAdd = params.perSlideOffset - Math.abs(progress) * 0.75;\n const slideIndex = swiper.virtual && swiper.params.virtual?.enabled ? swiper.virtual.from + i : i;\n const isSwipeToNext = (slideIndex === activeIndex || slideIndex === activeIndex - 1) &&\n progress > 0 &&\n progress < 1 &&\n (isTouched || swiper.params.cssMode) &&\n (currentTranslate ?? 0) < (startTranslate ?? 0);\n const isSwipeToPrev = (slideIndex === activeIndex || slideIndex === activeIndex + 1) &&\n progress < 0 &&\n progress > -1 &&\n (isTouched || swiper.params.cssMode) &&\n (currentTranslate ?? 0) > (startTranslate ?? 0);\n if (isSwipeToNext || isSwipeToPrev) {\n const subProgress = (1 - Math.abs((Math.abs(progress) - 0.5) / 0.5)) ** 0.5;\n rotate += -28 * progress * subProgress;\n scale += -0.5 * subProgress;\n tXAdd += 96 * subProgress;\n tY = `${(params.rotate || swiper.isHorizontal() ? -25 : 0) * subProgress * Math.abs(progress)}%`;\n }\n if (progress < 0) {\n // next\n tX = `calc(${tX}px ${rtl ? '-' : '+'} (${tXAdd * Math.abs(progress)}%))`;\n }\n else if (progress > 0) {\n // prev\n tX = `calc(${tX}px ${rtl ? '-' : '+'} (-${tXAdd * Math.abs(progress)}%))`;\n }\n else {\n tX = `${tX}px`;\n }\n if (!swiper.isHorizontal()) {\n const prevY = tY;\n tY = tX;\n tX = prevY;\n }\n const scaleString = progress < 0 ? `${1 + (1 - scale) * progress}` : `${1 - (1 - scale) * progress}`;\n const transform = `\n translate3d(${tX}, ${tY}, ${tZ}px)\n rotateZ(${params.rotate ? (rtl ? -rotate : rotate) : 0}deg)\n scale(${scaleString})\n `;\n if (params.slideShadows) {\n // Set shadows\n let shadowEl = slideEl.querySelector('.swiper-slide-shadow');\n if (!shadowEl) {\n shadowEl = (0,_shared_create_shadow_mjs__WEBPACK_IMPORTED_MODULE_0__.c)('cards', slideEl);\n }\n if (shadowEl)\n shadowEl.style.opacity = String(Math.min(Math.max((Math.abs(progress) - 0.5) / 0.5, 0), 1));\n }\n slideEl.style.zIndex = String(-Math.abs(Math.round(slideProgress)) + slides.length);\n const targetEl = (0,_shared_effect_target_mjs__WEBPACK_IMPORTED_MODULE_2__.e)(params, slideEl);\n targetEl.style.transform = transform;\n }\n };\n const setTransition = (duration) =>
1217 {\n const transformElements = swiper.slides.map((slideEl) => (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_4__.p)(slideEl));\n transformElements.forEach((el) => {\n el.style.transitionDuration = `${duration}ms`;\n el.querySelectorAll('.swiper-slide-shadow').forEach((shadowEl) => {\n shadowEl.style.transitionDuration = `${duration}ms`;\n });\n });\n (0,_shared_effect_virtual_transition_end_mjs__WEBPACK_IMPORTED_MODULE_3__.e)({ swiper, duration, transformElements });\n };\n (0,_shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_1__.e)({\n effect: 'cards',\n swiper,\n on,\n setTranslate,\n setTransition,\n perspective: () => true,\n overwriteParams: () => ({\n _loopSwapReset: false,\n watchSlidesProgress: true,\n loopAdditionalSlides: getParams().rotate ? 3 : 2,\n centeredSlides: true,\n virtualTranslate: !swiper.params.cssMode,\n }),\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/effect-cards.mjs?\n}"); 1218 1219/***/ }, 1220 1221/***/ "./node_modules/swiper/modules/effect-coverflow.mjs" 1222/*!**********************************************************!*\ 1223 !*** ./node_modules/swiper/modules/effect-coverflow.mjs ***! 1224 \**********************************************************/ 1225(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1226 1227"use strict"; 1228eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ EffectCoverflow)\n/* harmony export */ });\n/* harmony import */ var _shared_create_shadow_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/create-shadow.mjs */ \"./node_modules/swiper/shared/create-shadow.mjs\");\n/* harmony import */ var _shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../shared/effect-init.mjs */ \"./node_modules/swiper/shared/effect-init.mjs\");\n/* harmony import */ var _shared_effect_target_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../shared/effect-target.mjs */ \"./node_modules/swiper/shared/effect-target.mjs\");\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\n\n\n\nconst EffectCoverflow = ({ swiper, extendParams, on }) => {\n extendParams({\n coverflowEffect: {\n rotate: 50,\n stretch: 0,\n depth: 100,\n scale: 1,\n modifier: 1,\n slideShadows: true,\n },\n });\n function getParams() {\n return swiper.params.coverflowEffect;\n }\n const setTranslate = () => {\n const { width: swiperWidth, height: swiperHeight, slides, slidesSizesGrid } = swiper;\n const params = getParams();\n const isHorizontal = swiper.isHorizontal();\n const transform = swiper.translate;\n const center = isHorizontal ? -transform + swiperWidth / 2 : -transform + swiperHeight / 2;\n const rotate = isHorizontal ? params.rotate : -params.rotate;\n const translate = params.depth;\n const r = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_3__.o)(swiper);\n // Each slide offset from center\n for (let i = 0, length = slides.length; i < length; i += 1) {\n const slideEl = slides[i];\n const slideSize = slidesSizesGrid[i];\n const slideOffset = slideEl.swiperSlideOffset ?? 0;\n const centerOffset = (center - slideOffset - slideSize / 2) / slideSize;\n const offsetMultiplier = typeof params.modifier === 'function'\n ? params.modifier(centerOffset)\n : centerOffset * params.modifier;\n let rotateY = isHorizontal ? rotate * offsetMultiplier : 0;\n let rotateX = isHorizontal ? 0 : rotate * offsetMultiplier;\n // var rotateZ = 0\n let translateZ = -translate * Math.abs(offsetMultiplier);\n let stretch = typeof params.stretch === 'string' && params.stretch.indexOf('%') !== -1\n ? (parseFloat(params.stretch) / 100) * slideSize\n : params.stretch;\n let translateY = isHorizontal ? 0 : stretch * offsetMultiplier;\n let translateX = isHorizontal ? stretch * offsetMultiplier : 0;\n let scale = 1 - (1 - params.scale) * Math.abs(offsetMultiplier);\n // Fix for ultra small values\n if (Math.abs(translateX) < 0.001)\n translateX = 0;\n if (Math.abs(translateY) < 0.001)\n translateY = 0;\n if (Math.abs(translateZ) < 0.001)\n translateZ = 0;\n if (Math.abs(rotateY) < 0.001)\n rotateY = 0;\n if (Math.abs(rotateX) < 0.001)\n rotateX = 0;\n if (Math.abs(scale) < 0.001)\n scale = 0;\n const slideTransform = `translate3d(${translateX}px,${translateY}px,${translateZ}px) rotateX(${r(rotateX)}deg) rotateY(${r(rotateY)}deg) scale(${scale})`;\n const targetEl = (0,_shared_effect_target_mjs__WEBPACK_IMPORTED_MODULE_2__.e)(params, slideEl);\n targetEl.style.transform = slideTransform;\n slideEl.style.zIndex = String(-Math.abs(Math.round(offsetMultiplier)) + 1);\n if (params.slideShadows) {\n // Set shadows\n let shadowBeforeEl = isHorizontal\n ? slideEl.querySelector('.swiper-slide-shadow-left')\n : slideEl.querySelector('.swiper-slide-shadow-top');\n let shadowAfterEl = isHorizontal\n ? slideEl.querySelector('.swiper-slide-shadow-right')\n : slideEl.querySelector('.swiper-slide-shadow-bottom');\n if (!shadowBeforeEl) {\n shadowBeforeEl = (0,_shared_create_shadow_mjs__WEBPACK_IMPORTED_MODULE_0__.c)('coverflow', slideEl, isHorizontal ? 'left' : 'top');\n }\n if (!shadowAfterEl) {\n shadowAfterEl = (0,_shared_create_shadow_mjs__WEBPACK_IMPORTED_MODULE_0__.c)('coverflow', slideEl, isHorizontal ? 'right' : 'bottom');\n }\n if (shadowBeforeEl)\n shadowBeforeEl.style.opacity = String(offsetMultiplier > 0 ? offsetMultiplier : 0);\n if (shadowAfterEl)\n shadowAfterEl.style.opacity = String(-offsetMultiplier > 0 ? -offsetMultiplier : 0);\n }\n }\n };\n const setTransition = (duration) =>
1228 {\n const transformElements = swiper.slides.map((slideEl) => (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_3__.p)(slideEl));\n transformElements.forEach((el) => {\n el.style.transitionDuration = `${duration}ms`;\n el.querySelectorAll('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left').forEach((shadowEl) => {\n shadowEl.style.transitionDuration = `${duration}ms`;\n });\n });\n };\n (0,_shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_1__.e)({\n effect: 'coverflow',\n swiper,\n on,\n setTranslate,\n setTransition,\n perspective: () => true,\n overwriteParams: () => ({\n watchSlidesProgress: true,\n }),\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/effect-coverflow.mjs?\n}"); 1229 1230/***/ }, 1231 1232/***/ "./node_modules/swiper/modules/effect-creative.mjs" 1233/*!*********************************************************!*\ 1234 !*** ./node_modules/swiper/modules/effect-creative.mjs ***! 1235 \*********************************************************/ 1236(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1237 1238"use strict"; 1239eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ EffectCreative)\n/* harmony export */ });\n/* harmony import */ var _shared_create_shadow_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/create-shadow.mjs */ \"./node_modules/swiper/shared/create-shadow.mjs\");\n/* harmony import */ var _shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../shared/effect-init.mjs */ \"./node_modules/swiper/shared/effect-init.mjs\");\n/* harmony import */ var _shared_effect_target_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../shared/effect-target.mjs */ \"./node_modules/swiper/shared/effect-target.mjs\");\n/* harmony import */ var _shared_effect_virtual_transition_end_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../shared/effect-virtual-transition-end.mjs */ \"./node_modules/swiper/shared/effect-virtual-transition-end.mjs\");\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\n\n\n\n\nconst EffectCreative = ({ swiper, extendParams, on }) => {\n extendParams({\n creativeEffect: {\n limitProgress: 1,\n shadowPerProgress: false,\n progressMultiplier: 1,\n perspective: true,\n prev: {\n translate: [0, 0, 0],\n rotate: [0, 0, 0],\n opacity: 1,\n scale: 1,\n },\n next: {\n translate: [0, 0, 0],\n rotate: [0, 0, 0],\n opacity: 1,\n scale: 1,\n },\n },\n });\n function getParams() {\n return swiper.params.creativeEffect;\n }\n const getTranslateValue = (value) => {\n if (typeof value === 'string')\n return value;\n return `${value}px`;\n };\n const setTranslate = () => {\n const { slides, wrapperEl, slidesSizesGrid } = swiper;\n const params = getParams();\n const { progressMultiplier: multiplier } = params;\n const isCenteredSlides = swiper.params.centeredSlides;\n const rotateFix = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_4__.o)(swiper);\n if (isCenteredSlides) {\n const margin = slidesSizesGrid[0] / 2 - (swiper.params.slidesOffsetBefore ?? 0);\n wrapperEl.style.transform = `translateX(calc(50% - ${margin}px))`;\n }\n for (let i = 0; i < slides.length; i += 1) {\n const slideEl = slides[i];\n const slideProgress = slideEl.progress ?? 0;\n const progress = Math.min(Math.max(slideProgress, -params.limitProgress), params.limitProgress);\n let originalProgress = progress;\n if (!isCenteredSlides) {\n originalProgress = Math.min(Math.max(slideEl.originalProgress ?? 0, -params.limitProgress), params.limitProgress);\n }\n const offset = slideEl.swiperSlideOffset ?? 0;\n const t = [\n swiper.params.cssMode ? -offset - swiper.translate : -offset,\n 0,\n 0,\n ];\n const r = [0, 0, 0];\n let custom = false;\n if (!swiper.isHorizontal()) {\n t[1] = t[0];\n t[0] = 0;\n }\n let data = {\n translate: [0, 0, 0],\n rotate: [0, 0, 0],\n scale: 1,\n opacity: 1,\n };\n if (progress < 0) {\n data = params.next;\n custom = true;\n }\n else if (progress > 0) {\n data = params.prev;\n custom = true;\n }\n // set translate\n t.forEach((value, index) =>
1239 {\n t[index] = `calc(${value}px + (${getTranslateValue(data.translate[index])} * ${Math.abs(progress * multiplier)}))`;\n });\n // set rotates\n r.forEach((_value, index) => {\n r[index] = data.rotate[index] * Math.abs(progress * multiplier);\n });\n slideEl.style.zIndex = String(-Math.abs(Math.round(slideProgress)) + slides.length);\n const translateString = t.join(', ');\n const rotateString = `rotateX(${rotateFix(r[0])}deg) rotateY(${rotateFix(r[1])}deg) rotateZ(${rotateFix(r[2])}deg)`;\n const scaleString = originalProgress < 0\n ? `scale(${1 + (1 - data.scale) * originalProgress * multiplier})`\n : `scale(${1 - (1 - data.scale) * originalProgress * multiplier})`;\n const opacityString = originalProgress < 0\n ? 1 + (1 - data.opacity) * originalProgress * multiplier\n : 1 - (1 - data.opacity) * originalProgress * multiplier;\n const transform = `translate3d(${translateString}) ${rotateString} ${scaleString}`;\n // Set shadows\n if ((custom && data.shadow) || !custom) {\n let shadowEl = slideEl.querySelector('.swiper-slide-shadow');\n if (!shadowEl && data.shadow) {\n shadowEl = (0,_shared_create_shadow_mjs__WEBPACK_IMPORTED_MODULE_0__.c)('creative', slideEl);\n }\n if (shadowEl) {\n const shadowOpacity = params.shadowPerProgress\n ? progress * (1 / params.limitProgress)\n : progress;\n shadowEl.style.opacity = String(Math.min(Math.max(Math.abs(shadowOpacity), 0), 1));\n }\n }\n const targetEl = (0,_shared_effect_target_mjs__WEBPACK_IMPORTED_MODULE_2__.e)(params, slideEl);\n targetEl.style.transform = transform;\n targetEl.style.opacity = String(opacityString);\n if (data.origin) {\n targetEl.style.transformOrigin = data.origin;\n }\n }\n };\n const setTransition = (duration) => {\n const transformElements = swiper.slides.map((slideEl) => (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_4__.p)(slideEl));\n transformElements.forEach((el) => {\n el.style.transitionDuration = `${duration}ms`;\n el.querySelectorAll('.swiper-slide-shadow').forEach((shadowEl) => {\n shadowEl.style.transitionDuration = `${duration}ms`;\n });\n });\n (0,_shared_effect_virtual_transition_end_mjs__WEBPACK_IMPORTED_MODULE_3__.e)({ swiper, duration, transformElements, allSlides: true });\n };\n (0,_shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_1__.e)({\n effect: 'creative',\n swiper,\n on,\n setTranslate,\n setTransition,\n perspective: () => getParams().perspective,\n overwriteParams: () => ({\n watchSlidesProgress: true,\n virtualTranslate: !swiper.params.cssMode,\n }),\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/effect-creative.mjs?\n}"); 1240 1241/***/ }, 1242 1243/***/ "./node_modules/swiper/modules/effect-cube.mjs" 1244/*!*****************************************************!*\ 1245 !*** ./node_modules/swiper/modules/effect-cube.mjs ***! 1246 \*****************************************************/ 1247(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1248 1249"use strict"; 1250eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ EffectCube)\n/* harmony export */ });\n/* harmony import */ var _shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/effect-init.mjs */ \"./node_modules/swiper/shared/effect-init.mjs\");\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\n\nconst EffectCube = ({ swiper, extendParams, on }) =>
1250 {\n extendParams({\n cubeEffect: {\n slideShadows: true,\n shadow: true,\n shadowOffset: 20,\n shadowScale: 0.94,\n },\n });\n function getParams() {\n return swiper.params.cubeEffect;\n }\n const createSlideShadows = (slideEl, progress, isHorizontal) => {\n let shadowBefore = isHorizontal\n ? slideEl.querySelector('.swiper-slide-shadow-left')\n : slideEl.querySelector('.swiper-slide-shadow-top');\n let shadowAfter = isHorizontal\n ? slideEl.querySelector('.swiper-slide-shadow-right')\n : slideEl.querySelector('.swiper-slide-shadow-bottom');\n if (!shadowBefore) {\n shadowBefore = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.a)('div', `swiper-slide-shadow-cube swiper-slide-shadow-${isHorizontal ? 'left' : 'top'}`.split(' '));\n slideEl.append(shadowBefore);\n }\n if (!shadowAfter) {\n shadowAfter = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.a)('div', `swiper-slide-shadow-cube swiper-slide-shadow-${isHorizontal ? 'right' : 'bottom'}`.split(' '));\n slideEl.append(shadowAfter);\n }\n if (shadowBefore)\n shadowBefore.style.opacity = String(Math.max(-progress, 0));\n if (shadowAfter)\n shadowAfter.style.opacity = String(Math.max(progress, 0));\n };\n const recreateShadows = () => {\n // create new ones\n const isHorizontal = swiper.isHorizontal();\n swiper.slides.forEach((slideEl) => {\n const progress = Math.max(Math.min(slideEl.progress ?? 0, 1), -1);\n createSlideShadows(slideEl, progress, isHorizontal);\n });\n };\n const setTranslate = () => {\n const { el, wrapperEl, slides, width: swiperWidth, height: swiperHeight, rtlTranslate: rtl, size: swiperSize, } = swiper;\n const r = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.o)(swiper);\n const params = getParams();\n const isHorizontal = swiper.isHorizontal();\n const isVirtual = !!(swiper.virtual && swiper.params.virtual?.enabled);\n let wrapperRotate = 0;\n let cubeShadowEl = null;\n if (params.shadow) {\n if (isHorizontal) {\n cubeShadowEl = swiper.wrapperEl.querySelector('.swiper-cube-shadow');\n if (!cubeShadowEl) {\n cubeShadowEl = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.a)('div', 'swiper-cube-shadow');\n swiper.wrapperEl.append(cubeShadowEl);\n }\n cubeShadowEl.style.height = `${swiperWidth}px`;\n }\n else {\n cubeShadowEl = el.querySelector('.swiper-cube-shadow');\n if (!cubeShadowEl) {\n cubeShadowEl = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.a)('div', 'swiper-cube-shadow');\n el.append(cubeShadowEl);\n }\n }\n }\n for (let i = 0; i < slides.length; i += 1) {\n const slideEl = slides[i];\n let slideIndex = i;\n if (isVirtual) {\n slideIndex = parseInt(slideEl.getAttribute('data-swiper-slide-index') ?? '0', 10);\n }\n let slideAngle = slideIndex * 90;\n let round = Math.floor(slideAngle / 360);\n if (rtl) {\n slideAngle = -slideAngle;\n round = Math.floor(-slideAngle / 360);\n }\n const progress = Math.max(Math.min(slideEl.progress ?? 0, 1), -1);\n let tx = 0;\n let ty = 0;\n let tz = 0;\n if (slideIndex % 4 === 0) {\n tx = -round * 4 * swiperSize;\n tz = 0;\n }\n else if ((slideIndex - 1) % 4 === 0) {\n tx = 0;\n tz = -round * 4 * swiperSize;\n }\n else if ((slideIndex - 2) % 4 === 0) {\n tx = swiperSize + round * 4 * swiperSize;\n tz = swiperSize;\n }\n else if ((slideIndex - 3) % 4 === 0) {\n tx = -swiperSize;\n tz = 3 * swiperSize + swiperSize * 4 * round;\n }\n if (rtl) {\n tx = -tx;\n }\n if (!isHorizontal) {\n ty = tx;\n tx = 0;\n }\n const transform = `rotateX(${r(isHorizontal ? 0 : -slideAngle)}
1250deg) rotateY(${r(isHorizontal ? slideAngle : 0)}deg) translate3d(${tx}px, ${ty}px, ${tz}px)`;\n if (progress <= 1 && progress > -1) {\n wrapperRotate = slideIndex * 90 + progress * 90;\n if (rtl)\n wrapperRotate = -slideIndex * 90 - progress * 90;\n }\n slideEl.style.transform = transform;\n if (params.slideShadows) {\n createSlideShadows(slideEl, progress, isHorizontal);\n }\n }\n wrapperEl.style.transformOrigin = `50% 50% -${swiperSize / 2}px`;\n wrapperEl.style.setProperty('-webkit-transform-origin', `50% 50% -${swiperSize / 2}px`);\n if (params.shadow && cubeShadowEl) {\n if (isHorizontal) {\n cubeShadowEl.style.transform = `translate3d(0px, ${swiperWidth / 2 + params.shadowOffset}px, ${-swiperWidth / 2}px) rotateX(89.99deg) rotateZ(0deg) scale(${params.shadowScale})`;\n }\n else {\n const shadowAngle = Math.abs(wrapperRotate) - Math.floor(Math.abs(wrapperRotate) / 90) * 90;\n const multiplier = 1.5 -\n (Math.sin((shadowAngle * 2 * Math.PI) / 360) / 2 +\n Math.cos((shadowAngle * 2 * Math.PI) / 360) / 2);\n const scale1 = params.shadowScale;\n const scale2 = params.shadowScale / multiplier;\n const offset = params.shadowOffset;\n cubeShadowEl.style.transform = `scale3d(${scale1}, 1, ${scale2}) translate3d(0px, ${swiperHeight / 2 + offset}px, ${-swiperHeight / 2 / scale2}px) rotateX(-89.99deg)`;\n }\n }\n wrapperEl.style.transform = `translate3d(0px,0,0px) rotateX(${r(swiper.isHorizontal() ? 0 : wrapperRotate)}deg) rotateY(${r(swiper.isHorizontal() ? -wrapperRotate : 0)}deg)`;\n wrapperEl.style.setProperty('--swiper-cube-translate-z', '0px');\n };\n const setTransition = (duration) => {\n const { el, slides } = swiper;\n slides.forEach((slideEl) => {\n slideEl.style.transitionDuration = `${duration}ms`;\n slideEl\n .querySelectorAll('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left')\n .forEach((subEl) => {\n subEl.style.transitionDuration = `${duration}ms`;\n });\n });\n if (swiper.params.cubeEffect?.shadow && !swiper.isHorizontal()) {\n const shadowEl = el.querySelector('.swiper-cube-shadow');\n if (shadowEl)\n shadowEl.style.transitionDuration = `${duration}ms`;\n }\n };\n (0,_shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_0__.e)({\n effect: 'cube',\n swiper,\n on,\n setTranslate,\n setTransition,\n recreateShadows,\n getEffectParams: () => swiper.params.cubeEffect,\n perspective: () => true,\n overwriteParams: () => ({\n slidesPerView: 1,\n slidesPerGroup: 1,\n watchSlidesProgress: true,\n resistanceRatio: 0,\n spaceBetween: 0,\n centeredSlides: false,\n virtualTranslate: true,\n }),\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/effect-cube.mjs?\n}"); 1251 1252/***/ }, 1253 1254/***/ "./node_modules/swiper/modules/effect-fade.mjs" 1255/*!*****************************************************!*\ 1256 !*** ./node_modules/swiper/modules/effect-fade.mjs ***! 1257 \*****************************************************/ 1258(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1259 1260"use strict"; 1261eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ EffectFade)\n/* harmony export */ });\n/* harmony import */ var _shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/effect-init.mjs */ \"./node_modules/swiper/shared/effect-init.mjs\");\n/* harmony import */ var _shared_effect_target_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../shared/effect-target.mjs */ \"./node_modules/swiper/shared/effect-target.mjs\");\n/* harmony import */ var _shared_effect_virtual_transition_end_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../shared/effect-virtual-transition-end.mjs */ \"./node_modules/swiper/shared/effect-virtual-transition-end.mjs\");\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\n\n\n\nconst EffectFade = ({ swiper, extendParams, on }) =>
1261 {\n extendParams({\n fadeEffect: {\n crossFade: false,\n },\n });\n function getParams() {\n return swiper.params.fadeEffect;\n }\n const setTranslate = () => {\n const { slides } = swiper;\n const params = getParams();\n for (let i = 0; i < slides.length; i += 1) {\n const slideEl = slides[i];\n const offset = slideEl.swiperSlideOffset ?? 0;\n let tx = -offset;\n if (!swiper.params.virtualTranslate)\n tx -= swiper.translate;\n let ty = 0;\n if (!swiper.isHorizontal()) {\n ty = tx;\n tx = 0;\n }\n const slideProgress = slideEl.progress ?? 0;\n const slideOpacity = params.crossFade\n ? Math.max(1 - Math.abs(slideProgress), 0)\n : 1 + Math.min(Math.max(slideProgress, -1), 0);\n const targetEl = (0,_shared_effect_target_mjs__WEBPACK_IMPORTED_MODULE_1__.e)(params, slideEl);\n targetEl.style.opacity = String(slideOpacity);\n targetEl.style.transform = `translate3d(${tx}px, ${ty}px, 0px)`;\n }\n };\n const setTransition = (duration) => {\n const transformElements = swiper.slides.map((slideEl) => (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_3__.p)(slideEl));\n transformElements.forEach((el) => {\n el.style.transitionDuration = `${duration}ms`;\n });\n (0,_shared_effect_virtual_transition_end_mjs__WEBPACK_IMPORTED_MODULE_2__.e)({ swiper, duration, transformElements, allSlides: true });\n };\n (0,_shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_0__.e)({\n effect: 'fade',\n swiper,\n on,\n setTranslate,\n setTransition,\n overwriteParams: () => ({\n slidesPerView: 1,\n slidesPerGroup: 1,\n watchSlidesProgress: true,\n spaceBetween: 0,\n virtualTranslate: !swiper.params.cssMode,\n }),\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/effect-fade.mjs?\n}"); 1262 1263/***/ }, 1264 1265/***/ "./node_modules/swiper/modules/effect-flip.mjs" 1266/*!*****************************************************!*\ 1267 !*** ./node_modules/swiper/modules/effect-flip.mjs ***! 1268 \*****************************************************/ 1269(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1270 1271"use strict"; 1272eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ EffectFlip)\n/* harmony export */ });\n/* harmony import */ var _shared_create_shadow_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/create-shadow.mjs */ \"./node_modules/swiper/shared/create-shadow.mjs\");\n/* harmony import */ var _shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../shared/effect-init.mjs */ \"./node_modules/swiper/shared/effect-init.mjs\");\n/* harmony import */ var _shared_effect_target_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../shared/effect-target.mjs */ \"./node_modules/swiper/shared/effect-target.mjs\");\n/* harmony import */ var _shared_effect_virtual_transition_end_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../shared/effect-virtual-transition-end.mjs */ \"./node_modules/swiper/shared/effect-virtual-transition-end.mjs\");\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\n\n\n\n\nconst EffectFlip = ({ swiper, extendParams, on }) => {\n extendParams({\n flipEffect: {\n slideShadows: true,\n limitRotation: true,\n },\n });\n function getParams() {\n return swiper.params.flipEffect;\n }\n const createSlideShadows = (slideEl, progress) => {\n let shadowBefore = swiper.isHorizontal()\n ? slideEl.querySelector('.swiper-slide-shadow-left')\n : slideEl.querySelector('.swiper-slide-shadow-top');\n let shadowAfter = swiper.isHorizontal()\n ? slideEl.querySelector('.swiper-slide-shadow-right')\n : slideEl.querySelector('.swiper-slide-shadow-bottom');\n if (!shadowBefore) {\n shadowBefore = (0,_shared_create_shadow_mjs__WEBPACK_IMPORTED_MODULE_0__.c)('flip', slideEl, swiper.isHorizontal() ? 'left' : 'top');\n }\n if (!shadowAfter) {\n shadowAfter = (0,_shared_create_shadow_mjs__WEBPACK_IMPORTED_MODULE_0__.c)('flip', slideEl, swiper.isHorizontal() ? 'right' : 'bottom');\n }\n if (shadowBefore)\n shadowBefore.style.opacity = String(Math.max(-progress, 0));\n if (shadowAfter)\n shadowAfter.style.opacity = String(Math.max(progress, 0));\n };\n const recreateShadows = () => {\n // Set shadows\n const params = getParams();
1272\n swiper.slides.forEach((slideEl) => {\n let progress = slideEl.progress ?? 0;\n if (params.limitRotation) {\n progress = Math.max(Math.min(progress, 1), -1);\n }\n createSlideShadows(slideEl, progress);\n });\n };\n const setTranslate = () => {\n const { slides, rtlTranslate: rtl } = swiper;\n const params = getParams();\n const rotateFix = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_4__.o)(swiper);\n for (let i = 0; i < slides.length; i += 1) {\n const slideEl = slides[i];\n let progress = slideEl.progress ?? 0;\n if (params.limitRotation) {\n progress = Math.max(Math.min(progress, 1), -1);\n }\n const offset = slideEl.swiperSlideOffset ?? 0;\n const rotate = -180 * progress;\n let rotateY = rotate;\n let rotateX = 0;\n let tx = swiper.params.cssMode ? -offset - swiper.translate : -offset;\n let ty = 0;\n if (!swiper.isHorizontal()) {\n ty = tx;\n tx = 0;\n rotateX = -rotateY;\n rotateY = 0;\n }\n else if (rtl) {\n rotateY = -rotateY;\n }\n slideEl.style.zIndex = String(-Math.abs(Math.round(progress)) + slides.length);\n if (params.slideShadows) {\n createSlideShadows(slideEl, progress);\n }\n const transform = `translate3d(${tx}px, ${ty}px, 0px) rotateX(${rotateFix(rotateX)}deg) rotateY(${rotateFix(rotateY)}deg)`;\n const targetEl = (0,_shared_effect_target_mjs__WEBPACK_IMPORTED_MODULE_2__.e)(params, slideEl);\n targetEl.style.transform = transform;\n }\n };\n const setTransition = (duration) => {\n const transformElements = swiper.slides.map((slideEl) => (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_4__.p)(slideEl));\n transformElements.forEach((el) => {\n el.style.transitionDuration = `${duration}ms`;\n el.querySelectorAll('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left').forEach((shadowEl) => {\n shadowEl.style.transitionDuration = `${duration}ms`;\n });\n });\n (0,_shared_effect_virtual_transition_end_mjs__WEBPACK_IMPORTED_MODULE_3__.e)({ swiper, duration, transformElements });\n };\n (0,_shared_effect_init_mjs__WEBPACK_IMPORTED_MODULE_1__.e)({\n effect: 'flip',\n swiper,\n on,\n setTranslate,\n setTransition,\n recreateShadows,\n getEffectParams: () => swiper.params.flipEffect,\n perspective: () => true,\n overwriteParams: () => ({\n slidesPerView: 1,\n slidesPerGroup: 1,\n watchSlidesProgress: true,\n spaceBetween: 0,\n virtualTranslate: !swiper.params.cssMode,\n }),\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/effect-flip.mjs?\n}"); 1273 1274/***/ }, 1275 1276/***/ "./node_modules/swiper/modules/free-mode.mjs" 1277/*!***************************************************!*\ 1278 !*** ./node_modules/swiper/modules/free-mode.mjs ***! 1279 \***************************************************/ 1280(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1281 1282"use strict"; 1283eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ FreeMode)\n/* harmony export */ });\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nconst FreeMode = ({ swiper, extendParams, emit, once }) => {\n extendParams({\n freeMode: {\n enabled: false,\n momentum: true,\n momentumRatio: 1,\n momentumBounce: true,\n momentumBounceRatio: 1,\n momentumVelocityRatio: 1,\n sticky: fal
1283se,\n minimumVelocity: 0.02,\n },\n });\n function getParams() {\n return swiper.params.freeMode;\n }\n function onTouchStart() {\n if (swiper.params.cssMode)\n return;\n const translate = swiper.getTranslate();\n swiper.setTranslate(translate);\n swiper.setTransition(0);\n swiper.touchEventsData.velocities.length = 0;\n swiper.freeMode.onTouchEnd({ currentPos: swiper.rtl ? swiper.translate : -swiper.translate });\n }\n function onTouchMove() {\n if (swiper.params.cssMode)\n return;\n const { touchEventsData: data, touches } = swiper;\n // Velocity\n if (data.velocities.length === 0) {\n data.velocities.push({\n position: touches[swiper.isHorizontal() ? 'startX' : 'startY'],\n time: data.touchStartTime ?? (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)(),\n });\n }\n data.velocities.push({\n position: touches[swiper.isHorizontal() ? 'currentX' : 'currentY'],\n time: (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)(),\n });\n }\n function onTouchEnd({ currentPos }) {\n if (swiper.params.cssMode)\n return;\n const { wrapperEl, rtlTranslate: rtl, snapGrid, touchEventsData: data } = swiper;\n const params = swiper.params;\n const freeModeParams = getParams();\n // Time diff\n const touchEndTime = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)();\n const timeDiff = touchEndTime - (data.touchStartTime ?? touchEndTime);
1283\n if (currentPos < -swiper.minTranslate()) {\n swiper.slideTo(swiper.activeIndex);\n return;\n }\n if (currentPos > -swiper.maxTranslate()) {\n if (swiper.slides.length < snapGrid.length) {\n swiper.slideTo(snapGrid.length - 1);\n }\n else {\n swiper.slideTo(swiper.slides.length - 1);\n }\n return;\n }\n if (freeModeParams.momentum) {\n if (data.velocities.length > 1) {\n const lastMoveEvent = data.velocities.pop();\n const velocityEvent = data.velocities.pop();\n const distance = lastMoveEvent.position - velocityEvent.position;\n const time = lastMoveEvent.time - velocityEvent.time;\n swiper.velocity = distance / time;\n swiper.velocity /= 2;\n if (Math.abs(swiper.velocity) < freeModeParams.minimumVelocity) {\n swiper.velocity = 0;\n }\n // this implies that the user stopped moving a finger then released.\n // There would be no events with distance zero, so the last event is stale.\n if (time > 150 || (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)() - lastMoveEvent.time > 300) {\n swiper.velocity = 0;\n }\n }\n else {\n swiper.velocity = 0;\n }\n swiper.velocity *= freeModeParams.momentumVelocityRatio;\n data.velocities.length = 0;\n let momentumDuration = 1000 * freeModeParams.momentumRatio;\n const momentumDistance = swiper.velocity * momentumDuration;\n let newPosition = swiper.translate + momentumDistance;\n if (rtl)\n newPosition = -newPosition;\n let doBounce = false;\n let afterBouncePosition;\n const bounceAmount = Math.abs(swiper.velocity) * 20 * freeModeParams.momentumBounceRatio;\n let needsLoopFix = false;\n if (newPosition < swiper.maxTranslate()) {\n if (freeModeParams.momentumBounce) {\n if (newPosition + swiper.maxTranslate() < -bounceAmount) {\n newPosition = swiper.maxTranslate() - bounceAmount;\n }\n afterBouncePosition = swiper.maxTranslate();\n doBounce = true;\n data.allowMomentumBounce = true;\n }\n else {\n newPosition = swiper.maxTranslate();\n }\n if (params.loop && params.centeredSlides)\n needsLoopFix = true;\n }\n else if (newPosition > swiper.minTranslate()) {\n if (freeModeParams.momentumBounce) {\n if (newPosition - swiper.minTranslate() > bounceAmount) {\n newPosition = swiper.minTranslate() + bounceAmount;\n }\n afterBouncePosition = swiper.minTranslate();\n doBounce = true;\n data.allowMomentumBounce = true;\n }\n else {\n newPosition = swiper.minTranslate();\n }\n if (params.loop && params.centeredSlides)\n needsLoopFix = true;\n }\n else if (freeModeParams.sticky) {\n let nextSlide = 0;\n for (let j = 0; j < snapGrid.length; j += 1) {\n if (snapGrid[j] > -newPosition) {\n nextSlide = j;\n break;\n }\n }\n if (Math.abs(snapGrid[nextSlide] - newPosition) <\n Math.abs((snapGrid[nextSlide - 1] ?? snapGrid[nextSlide]) - newPosition) ||\n swiper.swipeDirection === 'next') {\n newPosition = snapGrid[nextSlide];\n }\n else {\n newPosition = snapGrid[nextSlide - 1];\n }\n newPosition = -newPosition;\n }\n if (needsLoopFix) {\n once('transitionEnd', () => {\n swiper.loopFix();\n });\n }\n // Fix duration\n if (swiper.velocity !== 0) {\n if (rtl) {\n momentumDuration = Math.abs((-newPosition - swiper.translate) / swiper.velocity);\n }\n else {\n momentumDuration = Math.abs((newPosition - swiper.translate) / swiper.velocity);\n }\n if (freeModeParams.sticky) {\n // If freeMode.sticky is active and the user ends a swipe with a slow-velocity\n // event, then durations can be 20+ seconds to slide one (or zero!) slides.\n // It's easy to see this when simulating touch with mouse events. To fix this,\n // limit single-slide swipes to the default slide duration. This also has the\n // nice side effect of matching slide speed if the user stopped moving before\n // lifting finger or mouse vs. moving slowly before lifting the finger/mouse.\n // For faster swipes, also apply limits (albeit higher ones).\n const moveDistance = Math.abs((rtl ? -newPosition : newPosition) - swiper.translate);\n const currentSlideSize = swiper.slidesSizesGrid[swiper.activeIndex];\n const speed = params.speed;\n if (moveDistance < currentSlideSize) {\n momentumDuration = speed;\n }\n else if (moveDistance < 2 * currentSlideSize) {\n momentumDuration = speed * 1.5;\n }\n else {\n momentumDuration = speed * 2.5;\n }\n }\n }\n else if (freeModeParams.sticky) {\n swiper.slideToClosest();\n return;\n }\n if (freeModeParams.momentumBounce && doBounce && afterBouncePosition !== undefined) {\n swiper.updateProgress(afterBouncePosition);\n swiper.setTransition(momentumDuration);\n swiper.setTranslate(newPosition);\n swiper.transitionStart(true, swiper.swipeDirection);\n swiper.animating = true;\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.m)(wrapperEl, () => {\n if (!swiper || swiper.destroyed || !data.allowMomentumBounce)\n return;\n emit('momentumBounce');\n swiper.setTransition(params.speed);\n setTimeout(() =>
1283 {\n swiper.setTranslate(afterBouncePosition);\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.m)(wrapperEl, () => {\n if (!swiper || swiper.destroyed)\n return;\n swiper.transitionEnd();\n });\n }, 0);\n });\n }\n else if (swiper.velocity) {\n emit('_freeModeNoMomentumRelease');\n swiper.updateProgress(newPosition);\n swiper.setTransition(momentumDuration);\n swiper.setTranslate(newPosition);\n swiper.transitionStart(true, swiper.swipeDirection);\n if (!swiper.animating) {\n swiper.animating = true;\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.m)(wrapperEl, () => {\n if (!swiper || swiper.destroyed)\n return;\n swiper.transitionEnd();\n });\n }\n }\n else {\n swiper.updateProgress(newPosition);\n }\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n }\n else if (freeModeParams.sticky) {\n swiper.slideToClosest();\n return;\n }\n else {\n emit('_freeModeNoMomentumRelease');\n }\n if (!freeModeParams.momentum || timeDiff >= params.longSwipesMs) {\n emit('_freeModeStaticRelease');\n swiper.updateProgress();\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n }\n }\n swiper.freeMode = {\n onTouchStart,\n onTouchMove,\n onTouchEnd,\n };\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/free-mode.mjs?\n}"); 1284 1285/***/ }, 1286 1287/***/ "./node_modules/swiper/modules/grid.mjs" 1288/*!**********************************************!*\ 1289 !*** ./node_modules/swiper/modules/grid.mjs ***! 1290 \**********************************************/ 1291(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1292 1293"use strict"; 1294eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Grid)\n/* harmony export */ });\nconst Grid = ({ swiper, extendParams, on }) => {\n extendParams({\n grid: {\n rows: 1,\n fill: 'column',\n },\n });\n function getParams() {\n return swiper.params.grid;\n }\n let slidesNumberEvenToRows;\n let slidesPerRow;\n let numFullColumns;\n let wasMultiRow;\n const getSpaceBetween = () => {\n let spaceBetween = swiper.params.spaceBetween ?? 0;\n if (typeof spaceBetween === 'string' && spaceBetween.indexOf('%') >= 0) {\n spaceBetween = (parseFloat(spaceBetween.replace('%', '')) / 100) * swiper.size;\n }\n else if (typeof spaceBetween === 'string') {\n spaceBetween = parseFloat(spaceBetween);\n }\n return spaceBetween;\n };\n const isVirtualEnabled = () => {\n const virtualParams = swiper.params.virtual;\n return (!!swiper.virtual &&\n typeof virtualParams === 'object' &&\n virtualParams !== null &&\n !!virtualParams.enabled);\n };\n const initSlides = (slides) => {\n const { slidesPerView } = swiper.params;\n const { rows, fill } = getParams();\n const slidesLength = isVirtualEnabled() ? swiper.virtual.slides.length : slides.length;\n numFullColumns = Math.floor(slidesLength / rows);\n if (Math.floor(slidesLength / rows) === slidesLength / rows) {\n slidesNumberEvenToRows = slidesLength;\n }\n else {\n slidesNumberEvenToRows = Math.ceil(slidesLength / rows) * rows;\n }\n if (slidesPerView !== 'auto' && fill === 'row') {\n slidesNumber
1294EvenToRows = Math.max(slidesNumberEvenToRows, Math.floor(slidesPerView ?? 1) * rows);\n }\n slidesPerRow = slidesNumberEvenToRows / rows;\n };\n const unsetSlides = () => {\n if (swiper.slides) {\n swiper.slides.forEach((slide) => {\n const gridSlide = slide;\n if (gridSlide.swiperSlideGridSet) {\n slide.style.height = '';\n slide.style.setProperty(swiper.getDirectionLabel('margin-top'), '');\n }\n });\n }\n };\n const updateSlide = (i, slide, slides) => {\n const { slidesPerGroup } = swiper.params;\n const spaceBetween = getSpaceBetween();\n const { rows, fill } = getParams();\n const slidesLength = isVirtualEnabled() ? swiper.virtual.slides.length : slides.length;\n // Set slides order\n let newSlideOrderIndex;\n let column;\n let row;\n if (fill === 'row' && (slidesPerGroup ?? 1) > 1) {\n const groupsPer = slidesPerGroup ?? 1;\n const groupIndex = Math.floor(i / (groupsPer * rows));\n const slideIndexInGroup = i - rows * groupsPer * groupIndex;\n const columnsInGroup = groupIndex === 0\n ? groupsPer\n : Math.min(Math.ceil((slidesLength - groupIndex * rows * groupsPer) / rows), groupsPer);\n row = Math.floor(slideIndexInGroup / columnsInGroup);\n column = slideIndexInGroup - row * columnsInGroup + groupIndex * groupsPer;\n newSlideOrderIndex = column + (row * slidesNumberEvenToRows) / rows;\n slide.style.order = String(newSlideOrderIndex);\n }\n else if (fill === 'column') {\n column = Math.floor(i / rows);\n row = i - column * rows;\n if (column > numFullColumns || (column === numFullColumns && row === rows - 1)) {\n row += 1;\n if (row >= rows) {\n row = 0;\n column += 1;\n }\n }\n }\n else {\n row = Math.floor(i / slidesPerRow);\n column = i - row * slidesPerRow;\n }\n const gridSlide = slide;\n gridSlide.row = row;\n gridSlide.column = column;\n slide.style.height = `calc((100% - ${(rows - 1) * spaceBetween}px) / ${rows})`;\n slide.style.setProperty(swiper.getDirectionLabel('margin-top'), row !== 0 && spaceBetween ? `${spaceBetween}px` : '');\n gridSlide.swiperSlideGridSet = true;\n };\n const updateWrapperSize = (slideSize, snapGrid) => {\n const { centeredSlides, roundLengths } = swiper.params;\n const spaceBetween = getSpaceBetween();\n const { rows } = getParams();\n swiper.virtualSize = (slideSize + spaceBetween) * slidesNumberEvenToRows;\n swiper.virtualSize = Math.ceil(swiper.virtualSize / rows) - spaceBetween;\n if (!swiper.params.cssMode) {\n swiper.wrapperEl.style.setProperty(swiper.getDirectionLabel('width'), `${swiper.virtualSize + spaceBetween}px`);\n }\n if (centeredSlides) {\n const newSlidesGrid = [];\n for (let i = 0; i < snapGrid.length; i += 1) {\n let slidesGridItem = snapGrid[i];\n if (roundLengths)\n slidesGridItem = Math.floor(slidesGridItem);\n if (snapGrid[i] < swiper.virtualSize + snapGrid[0])\n newSlidesGrid.push(slidesGridItem);\n }\n snapGrid.splice(0, snapGrid.length);\n snapGrid.push(...newSlidesGrid);\n }\n };\n const onInit = () => {\n const gridParams = swiper.params.grid;\n wasMultiRow = !!(gridParams && (gridParams.rows ?? 1) > 1);\n };\n const onUpdate = () => {\n const { params, el } = swiper;\n const gridParams = params.grid;\n const isMultiRow = !!(gridParams && (gridParams.rows ?? 1) > 1);\n if (wasMultiRow && !isMultiRow) {\n el.classList.remove(`${params.containerModifierClass}grid`, `${params.containerModifierClass}grid-column`);\n numFullColumns = 1;\n swiper.emitContainerClasses();\n }\n else if (!wasMultiRow && isMultiRow) {\n el.classList.add(`${params.containerModifierClass}grid`);\n if (gridParams.fill === 'column') {\n el.classList.add(`${params.containerModifierClass}grid-column`);\n }\n swiper.emitContainerClasses();\n }\n wasMultiRow = isMultiRow;\n };\n on('init', onInit);\n on('update', onUpdate);\n swiper.grid = {\n initSlides,\n unsetSlides,\n updateSlide,\n updateWrapperSize,\n };\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/grid.mjs?\n}"); 1295 1296/***/ }, 1297 1298/***/ "./node_modules/swiper/modules/hash-navigation.mjs" 1299/*!*********************************************************!*\ 1300 !*** ./node_modules/swiper/modules/hash-navigation.mjs ***! 1301 \*********************************************************/ 1302(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1303 1304"use strict"; 1305eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ HashNavigation)\n/* harmony export */ });\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nconst isVirtualEnabled = (swiper) => !!swiper.virtual && !!swiper.params.virtual?.enabled;\nconst HashNavigation = ({ swiper, extendParams, emit, on }) =>
1305 {\n let initialized = false;\n extendParams({\n hashNavigation: {\n enabled: false,\n replaceState: false,\n watchState: false,\n getSlideIndex(_s, hash) {\n if (isVirtualEnabled(swiper)) {\n const slideWithHash = swiper.slides.find((slideEl) => slideEl.getAttribute('data-hash') === hash);\n if (!slideWithHash)\n return 0;\n const index = parseInt(slideWithHash.getAttribute('data-swiper-slide-index') || '0', 10);\n return index;\n }\n const matched = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(swiper.slidesEl, `.${swiper.params.slideClass}[data-hash=\"${hash}\"], swiper-slide[data-hash=\"${hash}\"]`)[0];\n return matched ? swiper.getSlideIndex(matched) : 0;\n },\n },\n });\n function getParams() {\n return swiper.params.hashNavigation;\n }\n const onHashChange = () => {\n emit('hashChange');\n const newHash = document.location.hash.replace('#', '');\n const activeSlideEl = isVirtualEnabled(swiper)\n ? swiper.slidesEl.querySelector(`[data-swiper-slide-index=\"${swiper.activeIndex}\"]`)\n : swiper.slides[swiper.activeIndex];\n const activeSlideHash = activeSlideEl ? activeSlideEl.getAttribute('data-hash') : '';\n if (newHash !== activeSlideHash) {\n const newIndex = getParams().getSlideIndex(swiper, newHash);\n if (typeof newIndex === 'undefined' || Number.isNaN(newIndex))\n return;\n swiper.slideTo(newIndex);\n }\n };\n const setHash = () => {\n const params = getParams();\n if (!initialized || !params.enabled)\n return;\n const activeSlideEl = isVirtualEnabled(swiper)\n ? swiper.slidesEl.querySelector(`[data-swiper-slide-index=\"${swiper.activeIndex}\"]`)\n : swiper.slides[swiper.activeIndex];\n const activeSlideHash = activeSlideEl\n ? activeSlideEl.getAttribute('data-hash') || activeSlideEl.getAttribute('data-history')\n : '';\n if (params.replaceState && window.history && window.history.replaceState) {\n window.history.replaceState(null, '', `#${activeSlideHash}` || '');\n emit('hashSet');\n }\n else {\n document.location.hash = activeSlideHash || '';\n emit('hashSet');\n }\n };\n const init = () => {\n const params = getParams();\n const historyParams = swiper.params.history;\n if (!params.enabled || (historyParams && historyParams.enabled))\n return;\n initialized = true;\n const hash = document.location.hash.replace('#', '');\n if (hash) {\n const speed = 0;\n const index = params.getSlideIndex(swiper, hash);\n swiper.slideTo(index || 0, speed, swiper.params.runCallbacksOnInit, true);\n }\n if (params.watchState) {\n window.addEventListener('hashchange', onHashChange);\n }\n };\n const destroy = () => {\n if (getParams().watchState) {\n window.removeEventListener('hashchange', onHashChange);\n }\n };\n on('init', () => {\n if (getParams().enabled) {\n init();\n }\n });\n on('destroy', () => {\n if (getParams().enabled) {\n destroy();\n }\n });\n on('transitionEnd _freeModeNoMomentumRelease', () => {\n if (initialized) {\n setHash();\n }\n });\n on('slideChange', () => {\n if (initialized && swiper.params.cssMode) {\n setHash();\n }\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/hash-navigation.mjs?\n}"); 1306 1307/***/ }, 1308 1309/***/ "./node_modules/swiper/modules/history.mjs" 1310/*!*************************************************!*\ 1311 !*** ./node_modules/swiper/modules/history.mjs ***! 1312 \*************************************************/ 1313(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1314 1315"use strict"; 1316eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ History)\n/* harmony export */ });\nconst History = ({ swiper, extendParams, on }) =>
1316 {\n extendParams({\n history: {\n enabled: false,\n root: '',\n replaceState: false,\n key: 'slides',\n keepQuery: false,\n },\n });\n let initialized = false;\n let paths = { key: undefined, value: undefined };\n function getParams() {\n return swiper.params.history;\n }\n const slugify = (text) => {\n return text\n .toString()\n .replace(/\\s+/g, '-')\n .replace(/[^\\w-]+/g, '')\n .replace(/--+/g, '-')\n .replace(/^-+/, '')\n .replace(/-+$/, '');\n };\n const getPathValues = (urlOverride) => {\n let location;\n if (urlOverride) {\n location = new URL(urlOverride);\n }\n else {\n location = window.location;\n }\n const pathArray = location.pathname\n .slice(1)\n .split('/')\n .filter((part) => part !== '');\n const total = pathArray.length;\n const key = pathArray[total - 2];\n const value = pathArray[total - 1];\n return { key, value };\n };\n const setHistory = (key, index) => {\n const params = getParams();\n if (!initialized || !params.enabled)\n return;\n let location;\n if (swiper.params.url) {\n location = new URL(swiper.params.url);\n }\n else {\n location = window.location;\n }\n const isVirtualEnabled = !!swiper.params.virtual\n ?.enabled;\n const slide = swiper.virtual && isVirtualEnabled\n ? swiper.slidesEl.querySelector(`[data-swiper-slide-index=\"${index}\"]`)\n : swiper.slides[index];\n if (!slide)\n return;\n let value = slugify(slide.getAttribute('data-history') || '');\n const root = params.root;\n if (root.length > 0) {\n const trimmedRoot = root[root.length - 1] === '/' ? root.slice(0, root.length - 1) : root;\n value = `${trimmedRoot}/${key ? `${key}/` : ''}${value}`;\n }\n else if (!location.pathname.includes(key || '')) {\n value = `${key ? `${key}/` : ''}${value}`;\n }\n if (params.keepQuery) {\n value += location.search;\n }\n const currentState = window.history.state;\n if (currentState && currentState.value === value) {\n return;\n }\n if (params.replaceState) {\n window.history.replaceState({ value }, '', value);\n }\n else {\n window.history.pushState({ value }, '', value);\n }\n };\n const scrollToSlide = (speed, value, runCallbacks) => {\n if (value) {\n for (let i = 0, length = swiper.slides.length; i < length; i += 1) {\n const slide = swiper.slides[i];\n const slideHistory = slugify(slide.getAttribute('data-history') || '');\n if (slideHistory === value) {\n const index = swiper.getSlideIndex(slide);\n swiper.slideTo(index, speed, runCallbacks);\n }\n }\n }\n else {\n swiper.slideTo(0, speed, runCallbacks);\n }\n };\n const setHistoryPopState = () => {\n paths = getPathValues(swiper.params.url);\n scrollToSlide(swiper.params.speed, paths.value, false);\n };\n const init = () => {\n const params = swiper.params.history;\n if (!params)\n return;\n if (!window.history || !window.history.pushState) {\n params.enabled = false;\n const hashParams = swiper.params.hashNavigation;\n if (hashParams)\n hashParams.enabled = true;\n return;\n }\n initialized = true;\n paths = getPathValues(swiper.params.url);\n if (!paths.key && !paths.value) {\n if (!params.replaceState) {\n window.addEventListener('popstate', setHistoryPopState);\n }\n return;\n }\n scrollToSlide(0, paths.value, swiper.params.runCallbacksOnInit);\n if (!params.replaceState) {\n window.addEventListener('popstate', setHistoryPopState);\n }\n };\n const destroy = () => {\n if (!getParams().replaceState) {\n window.removeEventListener('popstate', setHistoryPopState);\n }\n };\n on('init', () => {\n if (getParams().enabled) {\n init();\n }\n });\n on('destroy', () => {\n if (getParams().enabled) {\n destroy();\n }\n });\n on('transitionEnd _freeModeNoMomentumRelease', () => {\n if (initialized) {\n setHistory(getParams().key, swiper.activeIndex);\n }\n });\n on('slideChange', () => {\n if (initialized && swiper.params.cssMode) {\n setHistory(getParams().key, swiper.activeIndex);\n }\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/history.mjs?\n}"); 1317 1318/***/ }, 1319 1320/***/ "./node_modules/swiper/modules/index.mjs" 1321/*!***********************************************!*\ 1322 !*** ./node_modules/swiper/modules/index.mjs ***! 1323 \***********************************************/ 1324(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1325 1326"use strict"; 1327eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ A11y: () => (/* reexport safe */ _a11y_mjs__WEBPACK_IMPORTED_MODULE_9__[\"default\"]),\n/* harmony export */ Autoplay: () => (/* reexport safe */ _autoplay_mjs__WEBPACK_IMPORTED_MODULE_12__[\"default\"]),\n/* harmony export */ Controller: () => (/* reexport safe */ _controller_mjs__WEBPACK_IMPORTED_MODULE_8__[\"default\"]),\n/* harmony export */ EffectCards: () => (/* reexport safe */ _effect_cards_mjs__WEBPACK_IMPORTED_MODULE_22__[\"default\"]),\n/* harmony export */ EffectCoverflow: () => (/* reexport safe */ _effect_coverflow_mjs__WEBPACK_IMPORTED_MODULE_20__[\"default\"]),\n/* harmony export */ EffectCreative: () => (/* reexport safe */ _effect_creative_mjs__WEBPACK_IMPORTED_MODULE_21__[\"default\"]),\n/* harmony export */ EffectCube: () => (/* reexport safe */ _effect_cube_mjs__WEBPACK_IMPORTED_MODULE_18__[\"default\"]),\n/* harmony export */ EffectFade: () => (/* reexport safe */ _effect_fade_mjs__WEBPACK_IMPORTED_MODULE_17__[\"default\"]),\n/* harmony export */ EffectFlip: () => (/* reexport safe */ _effect_flip_mjs__WEBPACK_IMPORTED_MODULE_19__[\"default\"]),\n/* harmony export */ FreeMode: () => (/* reexport safe */ _free_mode_mjs__WEBPACK_IMPORTED_MODULE_14__[\"default\"]),\n/* harmony export */ Grid: () => (/* reexport safe */ _grid_mjs__WEBPACK_IMPORTED_MODULE_15__[\"default\"]),\n/* harmony export */ HashNavigation: () => (/* reexport safe */ _hash_navigation_mjs__WEBPACK_IMPORTED_MODULE_11__[\"default\"]),\n/* harmony export */ History: () => (/* reexport safe */ _history_mjs__WEBPACK_IMPORTED_MODULE_10__[\"default\"]),\n/* harmony export */ Keyboard: () => (/* reexport safe */ _keyboard_mjs__WEBPACK_IMPORTED_MODULE_1__[\"default\"]),\n/* harmony export */ Manipulation: () => (/* reexport safe */ _manipulation_mjs__WEBPACK_IMPORTED_MODULE_16__[\"default\"]),\n/* harmony export */ Mousewheel: () => (/* reexport safe */ _mousewheel_mjs__WEBPACK_IMPORTED_MODULE_2__[\"default\"]),\n/* harmony export */ Navigation: () => (/* reexport safe */ _navigation_mjs__WEBPACK_IMPORTED_MODULE_3__[\"default\"]),\n/* harmony export */ Pagination: () => (/* reexport safe */ _pagination_mjs__WEBPACK_IMPORTED_MODULE_4__[\"default\"]),\n/* harmony export */ Parallax: () => (/* reexport safe */ _parallax_mjs__WEBPACK_IMPORTED_MODULE_6__[\"default\"]),\n/* harmony export */ Scrollbar: () => (/* reexport safe */ _scrollbar_mjs__WEBPACK_IMPORTED_MODULE_5__[\"default\"]),\n/* harmony export */ Thumbs: () => (/* reexport safe */ _thumbs_mjs__WEBPACK_IMPORTED_MODULE_13__[\"default\"]),\n/* harmony export */ Virtual: () => (/* reexport safe */ _virtual_mjs__WEBPACK_IMPORTED_MODULE_0__[\"default\"]),\n/* harmony export */ Zoom: () => (/* reexport safe */ _zoom_mjs__WEBPACK_IMPORTED_MODULE_7__[\"default\"])\n/* harmony export */ });\n/* harmony import */ var _virtual_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./virtual.mjs */ \"./node_modules/swiper/modules/virtual.mjs\");\n/* harmony import */ var _keyboard_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./keyboard.mjs */ \"./node_modules/swiper/modules/keyboard.mjs\");\n/* harmony import */ var _mousewheel_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./mousewheel.mjs */ \"./node_modules/swiper/modules/mousewheel.mjs\");\n/* harmony import */ var _navigation_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./navigation.mjs */ \"./node_modules/swiper/modules/navigation.mjs\");\n/* harmony import */ var _pagination_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./pagination.mjs */ \"./node_modules/swiper/modules/pagination.mjs\");\n/* harmony import */ var _scrollbar_mjs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./scrollbar.mjs */ \"./node_modules/swiper/modules/scrollbar.mjs\");\n/* harmony import */ var _parallax_mjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./parallax.mjs */ \"./node_modules/swiper/modules/parallax.mjs\");\n/* harmony import */ var _zoom_mjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./zoom.mjs */ \"./node_modules/swiper/modules/zoom.mjs\");\n/* harmony import */ var _controller_mjs__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./controller.mjs */ \"./node_modules/swiper/modules/controller.mjs\");\n/* harmony import */ var _a11y_mjs__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./a11y.mjs */ \"./node_modules/swiper/modules/a11y.mjs\");\n/* harmony import */ var _history_mjs__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./history.mjs */ \"./node_modules/swiper/modules/history.mjs\");\n/* harmony import */ var _hash_navigation_mjs__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./hash-navigation.mjs */ \"./node_modules/swiper/modules/hash-navigation.mjs\");\n/* harmony import */ var _autoplay_mjs__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./autoplay.mjs */ \"./node_modules/swiper/modules/autoplay.mjs\");\n/* harmony import */ var _thumbs_mjs__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./thumbs.mjs */ \"./node_modules/swiper/modules/thumbs.mjs\");\n/* harmony import */ var _free_mode_mjs__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./free-mode.mjs */ \"./node_modules/swiper/modules/free-mode.mjs\");\n/* harmony import */ var _grid_mjs__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./grid.mjs */ \"./node_modules/swiper/modules/grid.mjs\");\n/* harmony import */ var _manipulation_mjs__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./manipulation.mjs */ \"./node_modules/swiper/modules/manipulation.mjs\");\n/* harmony import */ var _effect_fade_mjs__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./effect-fade.mjs */ \"./node_modules/swiper/modules/effect-fade.mjs\");\n/* harmony import */ var _effect_cube_mjs__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./effect-cube.mjs */ \"./node_modules/swiper/modules/effect-cube.mjs\");\n/* harmony import */ var _effect_flip_mjs__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./effect-flip.mjs */ \"./node_modules/swiper/modules/effect-flip.mjs\");\n/* harmony import */ var _effect_coverflow_mjs__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./effect-coverflow.mjs */ \"./node_modules/swiper/modules/effect-coverflow.mjs\");\n/* harmony import */ var _effect_creative_mjs__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! ./effect-creative.mjs */ \"./node_modules/swiper/modules/effect-creative.mjs\");\n/* harmony import */ var _effect_cards_mjs__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ./effect-cards.mjs */ \"./node_modules/swiper/modules/effect-cards.mjs\");\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/index.mjs?\n}"); 1328 1329/***/ }, 1330 1331/***/ "./node_modules/swiper/modules/keyboard.mjs" 1332/*!**************************************************!*\ 1333 !*** ./node_modules/swiper/modules/keyboard.mjs ***! 1334 \**************************************************/ 1335(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1336 1337"use strict"; 1338eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Keyboard)\n/* harmony export */ });\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nconst Keyboard = ({ swiper, extendParams, on, emit }) =>
1338 {\n extendParams({\n keyboard: {\n enabled: false,\n onlyInViewport: true,\n pageUpDown: true,\n speed: undefined,\n },\n });\n function getParams() {\n return swiper.params.keyboard;\n }\n function handle(event) {\n if (!swiper.enabled)\n return;\n const { rtlTranslate: rtl } = swiper;\n const e = 'originalEvent' in event && event.originalEvent ? event.originalEvent : event;\n const kc = e.keyCode || e.charCode;\n const params = getParams();\n const pageUpDown = !!params.pageUpDown;\n const isPageUp = pageUpDown && kc === 33;\n const isPageDown = pageUpDown && kc === 34;\n const isArrowLeft = kc === 37;\n const isArrowRight = kc === 39;\n const isArrowUp = kc === 38;\n const isArrowDown = kc === 40;\n // Directions locks\n if (!swiper.allowSlideNext &&\n ((swiper.isHorizontal() && isArrowRight) ||\n (swiper.isVertical() && isArrowDown) ||\n isPageDown)) {\n return false;\n }\n if (!swiper.allowSlidePrev &&\n ((swiper.isHorizontal() && isArrowLeft) || (swiper.isVertical() && isArrowUp) || isPageUp)) {\n return false;\n }\n if (e.shiftKey || e.altKey || e.ctrlKey || e.metaKey) {\n return undefined;\n }\n const activeElement = document.activeElement;\n if (activeElement &&\n (activeElement.isContentEditable ||\n (activeElement.nodeName &&\n (activeElement.nodeName.toLowerCase() === 'input' ||\n activeElement.nodeName.toLowerCase() === 'textarea')))) {\n return undefined;\n }\n if (params.onlyInViewport &&\n (isPageUp || isPageDown || isArrowLeft || isArrowRight || isArrowUp || isArrowDown)) {\n let inView = false;\n // Check that swiper should be inside of visible area of window\n if ((0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.j)(swiper.el, `.${swiper.params.slideClass}, swiper-slide`).length > 0 &&\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.j)(swiper.el, `.${swiper.params.slideActiveClass}`).length === 0) {\n return undefined;\n }\n const el = swiper.el;\n const swiperWidth = el.clientWidth;\n const swiperHeight = el.clientHeight;\n const windowWidth = window.innerWidth;\n const windowHeight = window.innerHeight;\n const swiperOffset = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.h)(el);\n if (rtl)\n swiperOffset.left -= el.scrollLeft;\n const swiperCoord = [\n [swiperOffset.left, swiperOffset.top],\n [swiperOffset.left + swiperWidth, swiperOffset.top],\n [swiperOffset.left, swiperOffset.top + swiperHeight],\n [swiperOffset.left + swiperWidth, swiperOffset.top + swiperHeight],\n ];\n for (let i = 0; i < swiperCoord.length; i += 1) {\n const point = swiperCoord[i];\n if (point[0] >= 0 && point[0] <= windowWidth && point[1] >= 0 && point[1] <= windowHeight) {\n if (point[0] === 0 && point[1] === 0)\n continue;\n inView = true;\n }\n }\n if (!inView)\n return undefined;\n }\n const speed = params.speed;\n if (swiper.isHorizontal()) {\n if (isPageUp || isPageDown || isArrowLeft || isArrowRight) {\n if (e.cancelable)\n e.preventDefault();\n }\n if (((isPageDown || isArrowRight) && !rtl) || ((isPageUp || isArrowLeft) && rtl))\n swiper.slideNext(speed);\n if (((isPageUp || isArrowLeft) && !rtl) || ((isPageDown || isArrowRight) && rtl))\n swiper.slidePrev(speed);\n }\n else {\n if (isPageUp || isPageDown || isArrowUp || isArrowDown) {\n if (e.cancelable)\n e.preventDefault();\n }\n if (isPageDown || isArrowDown)\n swiper.slideNext(speed);\n if (isPageUp || isArrowUp)\n swiper.slidePrev(speed);\n }\n emit('keyPress', kc);\n return undefined;\n }\n function enable() {\n if (swiper.keyboard.enabled)\n return;\n document.addEventListener('keydown', handle);\n swiper.keyboard.enabled = true;\n }\n function disable() {\n if (!swiper.keyboard.enabled)\n return;\n document.removeEventListener('keydown', handle);\n swiper.keyboard.enabled = false;\n }\n swiper.keyboard = {\n enabled: false,\n enable,\n disable,\n };\n on('init', () => {\n if (getParams().enabled) {\n enable();\n }\n });\n on('destroy', () => {\n if (swiper.keyboard.enabled) {\n disable();\n }\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/keyboard.mjs?\n}"); 1339 1340/***/ }, 1341 1342/***/ "./node_modules/swiper/modules/manipulation.mjs" 1343/*!******************************************************!*\ 1344 !*** ./node_modules/swiper/modules/manipulation.mjs ***! 1345 \******************************************************/ 1346(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1347 1348"use strict"; 1349eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Manipulation)\n/* harmony export */ });\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nfunction addSlide(index, slides) {\n const swiper = this;\n const { params, activeIndex, slidesEl } = swiper;\n let activeIndexBuffer = activeIndex;\n if (params.loop) {\n activeIndexBuffer -= swiper.loopedSlides ?? 0;\n swiper.loopDestroy();\n swiper.recalcSlides();\n }\n const baseLength = swiper.slides.length;\n if (index <= 0) {\n swiper.prependSlide(slides);\n return;\n }\n if (index >= baseLength) {\n swiper.appendSlide(slides);\n return;\n }\n let newActiveIndex = activeIndexBuffer > index ? activeIndexBuffer + 1 : activeIndexBuffer;\n const slidesBuffer = [];\n for (let i = baseLength - 1; i >= index; i -= 1) {\n const currentSlide = swiper.slides[i];\n if (!currentSlide)\n continue;\n currentSlide.remove();\n slidesBuffer.unshift(currentSlide);\n }\n if (Array.isArray(slides)) {\n for (let i = 0; i < slides.length; i += 1) {\n const slide = slides[i];\n if (slide)\n slidesEl.append(slide);\n }\n newActiveIndex =\n activeIndexBuffer > index ? activeIndexBuffer + slides.length : activeIndexBuffer;\n }\n else {\n slidesEl.append(slides);\n }\n for (let i = 0; i < slidesBuffer.length; i += 1) {\n slidesEl.append(slidesBuffer[i]);\n }\n swiper.recalcSlides();\n if (params.loop) {\n swiper.loopCreate();\n }\n if (!params.observer || swiper.isElement) {\n swiper.update(
1349);\n }\n if (params.loop) {\n swiper.slideTo(newActiveIndex + (swiper.loopedSlides ?? 0), 0, false);\n }\n else {\n swiper.slideTo(newActiveIndex, 0, false);\n }\n}\n\nfunction appendSlide(slides) {\n const swiper = this;\n const { params, slidesEl } = swiper;\n if (params.loop) {\n swiper.loopDestroy();\n }\n const appendElement = (slideEl) => {\n if (typeof slideEl === 'string') {\n const tempDOM = document.createElement('div');\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.w)(tempDOM, slideEl);\n const child = tempDOM.children[0];\n if (child)\n slidesEl.append(child);\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.w)(tempDOM, '');\n }\n else {\n slidesEl.append(slideEl);\n }\n };\n if (Array.isArray(slides)) {\n for (let i = 0; i < slides.length; i += 1) {\n const slide = slides[i];\n if (slide)\n appendElement(slide);\n }\n }\n else {\n appendElement(slides);\n }\n swiper.recalcSlides();\n if (params.loop) {\n swiper.loopCreate();\n }\n if (!params.observer || swiper.isElement) {\n swiper.update();\n }\n}\n\nfunction prependSlide(slides) {\n const swiper = this;\n const { params, activeIndex, slidesEl } = swiper;\n if (params.loop) {\n swiper.loopDestroy();\n }\n let newActiveIndex = activeIndex + 1;\n const prependElement = (slideEl) => {\n if (typeof slideEl === 'string') {\n const tempDOM = document.createElement('div');\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.w)(tempDOM, slideEl);\n const child = tempDOM.children[0];\n if (child)\n slidesEl.prepend(child);\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.w)(tempDOM, '');\n }\n else {\n slidesEl.prepend(slideEl);\n }\n };\n if (Array.isArray(slides)) {\n for (let i = 0; i < slides.length; i += 1) {\n const slide = slides[i];\n if (slide)\n prependElement(slide);\n }\n newActiveIndex = activeIndex + slides.length;\n }\n else {\n prependElement(slides);\n }\n swiper.recalcSlides();\n if (params.loop) {\n swiper.loopCreate();\n }\n if (!params.observer || swiper.isElement) {\n swiper.update();\n }\n swiper.slideTo(newActiveIndex, 0, false);\n}\n\nfunction removeAllSlides() {\n const swiper = this;\n const slidesIndexes = [];\n for (let i = 0; i < swiper.slides.length; i += 1) {\n slidesIndexes.push(i);\n }\n swiper.removeSlide(slidesIndexes);\n}\n\nfunction removeSlide(slidesIndexes) {\n const swiper = this;\n const { params, activeIndex } = swiper;\n let activeIndexBuffer = activeIndex;\n if (params.loop) {\n activeIndexBuffer -= swiper.loopedSlides ?? 0;\n swiper.loopDestroy();\n }\n let newActiveIndex = activeIndexBuffer;\n if (Array.isArray(slidesIndexes)) {\n for (let i = 0; i < slidesIndexes.length; i += 1) {\n const indexToRemove = slidesIndexes[i];\n if (swiper.slides[indexToRemove])\n swiper.slides[indexToRemove].remove();\n if (indexToRemove < newActiveIndex)\n newActiveIndex -= 1;\n }\n newActiveIndex = Math.max(newActiveIndex, 0);\n }\n else {\n const indexToRemove = slidesIndexes;\n if (swiper.slides[indexToRemove])\n swiper.slides[indexToRemove].remove();\n if (indexToRemove < newActiveIndex)\n newActiveIndex -= 1;\n newActiveIndex = Math.max(newActiveIndex, 0);\n }\n swiper.recalcSlides();\n if (params.loop) {\n swiper.loopCreate();\n }\n if (!params.observer || swiper.isElement) {\n swiper.update();\n }\n if (params.loop) {\n swiper.slideTo(newActiveIndex + (swiper.loopedSlides ?? 0), 0, false);\n }\n else {\n swiper.slideTo(newActiveIndex, 0, false);\n }\n}\n\nconst Manipulation = ({ swiper }) =>
1349 {\n Object.assign(swiper, {\n appendSlide: appendSlide.bind(swiper),\n prependSlide: prependSlide.bind(swiper),\n addSlide: addSlide.bind(swiper),\n removeSlide: removeSlide.bind(swiper),\n removeAllSlides: removeAllSlides.bind(swiper),\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/manipulation.mjs?\n}"); 1350 1351/***/ }, 1352 1353/***/ "./node_modules/swiper/modules/mousewheel.mjs" 1354/*!****************************************************!*\ 1355 !*** ./node_modules/swiper/modules/mousewheel.mjs ***! 1356 \****************************************************/ 1357(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1358 1359"use strict"; 1360eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Mousewheel)\n/* harmony export */ });\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nconst Mousewheel = ({ swiper, extendParams, on, emit }) => {\n extendParams({\n mousewheel: {\n enabled: false,\n releaseOnEdges: false,\n invert: false,\n forceToAxis: fal
1360se,\n sensitivity: 1,\n eventsTarget: 'container',\n thresholdDelta: null,\n thresholdTime: null,\n noMousewheelClass: 'swiper-no-mousewheel',\n },\n });\n let timeout;\n let lastScrollTime = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)();\n let lastEventBeforeSnap;\n let mouseEntered = false;\n const recentWheelEvents = [];\n function getParams() {\n return swiper.params.mousewheel;\n }\n function normalize(e) {\n // Reasonable defaults\n const PIXEL_STEP = 10;\n const LINE_HEIGHT = 40;\n const PAGE_HEIGHT = 800;\n const ev = e;\n let sX = 0;\n let sY = 0; // spinX, spinY\n let pX = 0;\n let pY = 0; // pixelX, pixelY\n // Legacy\n if (ev.detail !== undefined) {\n sY = ev.detail;\n }\n if (ev.wheelDelta !== undefined) {\n sY = -ev.wheelDelta / 120;\n }\n if (ev.wheelDeltaY !== undefined) {\n sY = -ev.wheelDeltaY / 120;\n }\n if (ev.wheelDeltaX !== undefined) {\n sX = -ev.wheelDeltaX / 120;\n }\n // side scrolling on FF with DOMMouseScroll\n if (ev.axis !== undefined &&\n ev.HORIZONTAL_AXIS !== undefined &&\n ev.axis === ev.HORIZONTAL_AXIS) {\n sX = sY;\n sY = 0;\n }\n pX = sX * PIXEL_STEP;\n pY = sY * PIXEL_STEP;\n if (ev.deltaY !== undefined) {\n pY = ev.deltaY;\n }\n if (ev.deltaX !== undefined) {\n pX = ev.deltaX;\n }\n if (ev.shiftKey && !pX) {\n // if user scrolls with shift he wants horizontal scroll\n pX = pY;\n pY = 0;\n }\n if ((pX || pY) && ev.deltaMode) {\n if (ev.deltaMode === 1) {\n // delta in LINE units\n pX *= LINE_HEIGHT;\n pY *= LINE_HEIGHT;\n }\n else {\n // delta in PAGE units\n pX *= PAGE_HEIGHT;\n pY *= PAGE_HEIGHT;\n }\n }\n // Fall-back if spin cannot be determined\n if (pX && !sX) {\n sX = pX < 1 ? -1 : 1;\n }\n if (pY && !sY) {\n sY = pY < 1 ? -1 : 1;\n }\n return {\n spinX: sX,\n spinY: sY,\n pixelX: pX,\n pixelY: pY,\n };\n }\n function handleMouseEnter() {\n if (!swiper.enabled)\n return;\n mouseEntered = true;\n }\n function handleMouseLeave() {\n if (!swiper.enabled)\n return;\n mouseEntered = false;\n }\n function animateSlider(newEvent) {\n const params = getParams();\n if (params.thresholdDelta && newEvent.delta < params.thresholdDelta) {\n // Prevent if delta of wheel scroll delta is below configured threshold\n return false;\n }\n if (params.thresholdTime && (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)() - lastScrollTime < params.thresholdTime) {\n // Prevent if time between scrolls is below configured threshold\n return false;\n }\n // If the movement is NOT big enough and\n // if the last time the user scrolled was too close to the current one (avoid continuously triggering the slider):\n // Don't go any further (avoid insignificant scroll movement).\n if (newEvent.delta >= 6 && (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)() - lastScrollTime < 60) {\n // Return false as a default\n return true;\n }\n if (newEvent.direction < 0) {\n if ((!swiper.isEnd || swiper.params.loop) && !swiper.animating) {\n swiper.slideNext();\n emit('scroll', newEvent.raw);\n }\n }\n else if ((!swiper.isBeginning || swiper.params.loop) && !swiper.animating) {\n swiper.slidePrev();\n emit('scroll', newEvent.raw);\n }\n // If you got here is because an animation has been triggered so store the current time\n lastScrollTime = new window.Date().getTime();\n // Return false as a default\n return false;\n }\n function releaseScroll(newEvent) {\n const params = getParams();\n if (newEvent.direction < 0) {\n if (swiper.isEnd && !swiper.params.loop && params.releaseOnEdges) {\n // Return true to animate scroll on edges\n return true;\n }\n }\n else if (swiper.isBeginning && !swiper.params.loop && params.releaseOnEdges) {\n // Return true to animate scroll on edges\n return true;\n }\n return false;\n }\n function handle(event) {\n let e = 'originalEvent' in event && event.originalEvent ? event.originalEvent : event;\n let disableParentSwiper = true;\n if (!swiper.enabled)\n return false;\n // Ignore event if the target or its parents have the swiper-no-mousewheel class\n const params = getParams();\n if (event.target.closest(`.${params.noMousewheelClass}`))\n return false;\n if (swiper.params.cssMode) {\n e.preventDefault();\n }\n let targetEl = swiper.el;\n if (params.eventsTarget !== 'container') {\n targetEl = document.querySelector(params.eventsTarget);\n }\n const targetElContainsTarget = targetEl && targetEl.contains(e.target);\n if (!mouseEntered && !targetElContainsTarget && !params.releaseOnEdges)\n return true;\n let delta = 0;\n const rtlFactor = swiper.rtlTranslate ? -1 : 1;\n const data = normalize(e);\n if (params.forceToAxis) {\n if (swiper.isHorizontal()) {\n if (Math.abs(data.pixelX) > Math.abs(data.pixelY))\n delta = -data.pixelX * rtlFactor;
1360\n else\n return true;\n }\n else if (Math.abs(data.pixelY) > Math.abs(data.pixelX))\n delta = -data.pixelY;\n else\n return true;\n }\n else {\n delta =\n Math.abs(data.pixelX) > Math.abs(data.pixelY) ? -data.pixelX * rtlFactor : -data.pixelY;\n }\n if (delta === 0)\n return true;\n if (params.invert)\n delta = -delta;\n // Get the scroll positions\n let positions = swiper.getTranslate() + delta * (params.sensitivity ?? 1);\n if (positions >= swiper.minTranslate())\n positions = swiper.minTranslate();\n if (positions <= swiper.maxTranslate())\n positions = swiper.maxTranslate();\n // When loop is true:\n // the disableParentSwiper will be true.\n // When loop is false:\n // if the scroll positions is not on edge,\n // then the disableParentSwiper will be true.\n // if the scroll on edge positions,\n // then the disableParentSwiper will be false.\n disableParentSwiper = swiper.params.loop\n ? true\n : !(positions === swiper.minTranslate() || positions === swiper.maxTranslate());\n if (disableParentSwiper && swiper.params.nested)\n e.stopPropagation();\n const freeModeParams = swiper.params.freeMode;\n if (!swiper.params.freeMode || !freeModeParams?.enabled) {\n // Register the new event in a variable which stores the relevant data\n const newEvent = {\n time: (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)(),\n delta: Math.abs(delta),\n direction: Math.sign(delta),\n raw: event,\n };\n // Keep the most recent events\n if (recentWheelEvents.length >= 2) {\n recentWheelEvents.shift(); // only store the last N events\n }\n const prevEvent = recentWheelEvents.length\n ? recentWheelEvents[recentWheelEvents.length - 1]\n : undefined;\n recentWheelEvents.push(newEvent);\n if (prevEvent) {\n if (newEvent.direction !== prevEvent.direction ||\n newEvent.delta > prevEvent.delta ||\n newEvent.time > prevEvent.time + 150) {\n animateSlider(newEvent);\n }\n }\n else {\n animateSlider(newEvent);\n }\n // If it's time to release the scroll:\n // Return now so you don't hit the preventDefault.\n if (releaseScroll(newEvent)) {\n return true;\n }\n }\n else {\n // Freemode or scrollContainer:\n const newEvent = {\n time: (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)(),\n delta: Math.abs(delta),\n direction: Math.sign(delta),\n };\n const ignoreWheelEvents = lastEventBeforeSnap &&\n newEvent.time < lastEventBeforeSnap.time + 500 &&\n newEvent.delta <= lastEventBeforeSnap.delta &&\n newEvent.direction === lastEventBeforeSnap.direction;\n if (!ignoreWheelEvents) {\n lastEventBeforeSnap = undefined;\n let position = swiper.getTranslate() + delta * (params.sensitivity ?? 1);\n const wasBeginning = swiper.isBeginning;\n const wasEnd = swiper.isEnd;\n if (position >= swiper.minTranslate())\n position = swiper.minTranslate();\n if (position <= swiper.maxTranslate())\n position = swiper.maxTranslate();\n swiper.setTransition(0);\n swiper.setTranslate(position);\n swiper.updateProgress();\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n if ((!wasBeginning && swiper.isBeginning) || (!wasEnd && swiper.isEnd)) {\n swiper.updateSlidesClasses();\n }\n if (swiper.params.loop) {\n swiper.loopFix({\n direction: newEvent.direction < 0 ? 'next' : 'prev',\n byMousewheel: true,\n });\n }\n if (freeModeParams?.sticky) {\n clearTimeout(timeout);\n timeout = undefined;\n if (recentWheelEvents.length >= 15) {\n recentWheelEvents.shift(); // only store the last N events\n }\n const prevEvent = recentWheelEvents.length\n ? recentWheelEvents[recentWheelEvents.length - 1]\n : undefined;\n const firstEvent = recentWheelEvents[0];\n recentWheelEvents.push(newEvent);\n if (prevEvent &&\n (newEvent.delta > prevEvent.delta || newEvent.direction !== prevEvent.direction)) {\n // Increasing or reverse-sign delta means the user started scrolling again. Clear the wheel event log.\n recentWheelEvents.splice(0);\n }\n else if (recentWheelEvents.length >= 15 &&\n firstEvent &&\n newEvent.time - firstEvent.time < 500 &&\n firstEvent.delta - newEvent.delta >= 1 &&\n newEvent.delta <= 6) {\n const snapToThreshold = delta > 0 ? 0.8 : 0.2;\n lastEventBeforeSnap = newEvent;\n recentWheelEvents.splice(0);\n timeout = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.t)(() =>
1360 {\n if (swiper.destroyed || !swiper.params)\n return;\n swiper.slideToClosest(swiper.params.speed, true, undefined, snapToThreshold);\n }, 0); // no delay; move on next tick\n }\n if (!timeout) {\n timeout = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.t)(() => {\n if (swiper.destroyed || !swiper.params)\n return;\n const snapToThreshold = 0.5;\n lastEventBeforeSnap = newEvent;\n recentWheelEvents.splice(0);\n swiper.slideToClosest(swiper.params.speed, true, undefined, snapToThreshold);\n }, 500);\n }\n }\n // Emit event\n if (!ignoreWheelEvents)\n emit('scroll', e);\n // Stop autoplay\n const autoplayParams = swiper.params.autoplay;\n if (swiper.params.autoplay && autoplayParams?.disableOnInteraction) {\n swiper.autoplay.stop();\n }\n // Return page scroll on edge positions\n if (params.releaseOnEdges &&\n (position === swiper.minTranslate() || position === swiper.maxTranslate())) {\n return true;\n }\n }\n }\n if (e.cancelable)\n e.preventDefault();\n return false;\n }\n function events(method) {\n const params = getParams();\n let targetEl = swiper.el;\n if (params.eventsTarget !== 'container') {\n targetEl = document.querySelector(params.eventsTarget);\n }\n targetEl[method]('mouseenter', handleMouseEnter);\n targetEl[method]('mouseleave', handleMouseLeave);\n targetEl[method]('wheel', handle);\n }\n function enable() {\n if (swiper.params.cssMode) {\n swiper.wrapperEl.removeEventListener('wheel', handle);\n return true;\n }\n if (swiper.mousewheel.enabled)\n return false;\n events('addEventListener');\n swiper.mousewheel.enabled = true;\n return true;\n }\n function disable() {\n if (swiper.params.cssMode) {\n swiper.wrapperEl.addEventListener('wheel', handle);\n return true;\n }\n if (!swiper.mousewheel.enabled)\n return false;\n events('removeEventListener');\n swiper.mousewheel.enabled = false;\n return true;\n }\n on('init', () => {\n const params = getParams();\n if (!params.enabled && swiper.params.cssMode) {\n disable();\n }\n if (params.enabled)\n enable();\n });\n swiper.mousewheel = {\n enabled: false,\n enable,\n disable,\n };\n on('destroy', () => {\n if (swiper.params.cssMode) {\n enable();\n }\n if (swiper.mousewheel.enabled)\n disable();\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/mousewheel.mjs?\n}"); 1361 1362/***/ }, 1363 1364/***/ "./node_modules/swiper/modules/navigation.mjs" 1365/*!****************************************************!*\ 1366 !*** ./node_modules/swiper/modules/navigation.mjs ***! 1367 \****************************************************/ 1368(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1369 1370"use strict"; 1371eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Navigation)\n/* harmony export */ });\n/* harmony import */ var _shared_create_element_if_not_defined_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/create-element-if-not-defined.mjs */ \"./node_modules/swiper/shared/create-element-if-not-defined.mjs\");\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\n\nconst arrowSvg = `<svg class=\"swiper-navigation-icon\" width=\"11\" height=\"20\" viewBox=\"0 0 11 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M0.38296 20.0762C0.111788 19.805 0.111788 19.3654 0.38296 19.0942L9.19758 10.2796L0.38296 1.46497C0.111788 1.19379 0.111788 0.754138 0.38296 0.482966C0.654131 0.211794 1.09379 0.211794 1.36496 0.482966L10.4341 9.55214C10.8359 9.9539 10.8359 10.6053 10.4341 11.007L1.36496 20.0762C1.09379 20.3474 0.654131 20.3474 0.38296 20.0762Z\" fill=\"currentColor\"/></svg>`;\nconst Navigation = ({ swiper, extendParams, on, emit }) =>
1371 {\n extendParams({\n navigation: {\n nextEl: null,\n prevEl: null,\n addIcons: true,\n hideOnClick: false,\n disabledClass: 'swiper-button-disabled',\n hiddenClass: 'swiper-button-hidden',\n lockClass: 'swiper-button-lock',\n navigationDisabledClass: 'swiper-navigation-disabled',\n },\n });\n // Initialized as a partial; remaining methods (update, init, destroy,\n // enable, disable) attach after their definitions below.\n swiper.navigation = {\n nextEl: null,\n prevEl: null,\n arrowSvg,\n };\n function getParams() {\n return swiper.params.navigation;\n }\n function getEl(el) {\n let res;\n if (el && typeof el === 'string' && swiper.isElement) {\n res = (swiper.el.querySelector(el) || swiper.hostEl.querySelector(el));\n if (res)\n return res;\n }\n if (el) {\n if (typeof el === 'string')\n res = [...document.querySelectorAll(el)];\n if (swiper.params.uniqueNavElements &&\n typeof el === 'string' &&\n res &&\n res.length > 1 &&\n swiper.el.querySelectorAll(el).length === 1) {\n res = swiper.el.querySelector(el);\n }\n else if (res && res.length === 1) {\n res = res[0];\n }\n }\n if (el && !res)\n return el;\n return res;\n }\n function toggleEl(el, disabled) {\n const params = getParams();\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(el);\n els.forEach((subEl) => {\n if (subEl) {\n subEl.classList[disabled ? 'add' : 'remove'](...params.disabledClass.split(' '));\n if (subEl.tagName === 'BUTTON')\n subEl.disabled = disabled;\n if (swiper.params.watchOverflow && swiper.enabled) {\n subEl.classList[swiper.isLocked ? 'add' : 'remove'](params.lockClass);\n }\n }\n });\n }\n function update() {\n // Update Navigation Buttons\n const { nextEl, prevEl } = swiper.navigation;\n if (swiper.params.loop) {\n toggleEl(prevEl, false);\n toggleEl(nextEl, false);\n return;\n }\n toggleEl(prevEl, swiper.isBeginning && !swiper.params.rewind);\n toggleEl(nextEl, swiper.isEnd && !swiper.params.rewind);\n }\n function onPrevClick(e) {\n e.preventDefault();\n if (swiper.isBeginning && !swiper.params.loop && !swiper.params.rewind)\n return;\n swiper.slidePrev();\n emit('navigationPrev');\n }\n function onNextClick(e) {\n e.preventDefault();\n if (swiper.isEnd && !swiper.params.loop && !swiper.params.rewind)\n return;\n swiper.slideNext();\n emit('navigationNext');\n }\n function init() {\n swiper.params.navigation = (0,_shared_create_element_if_not_defined_mjs__WEBPACK_IMPORTED_MODULE_0__.c)(swiper, swiper.originalParams.navigation, swiper.params.navigation, {\n nextEl: 'swiper-button-next',\n prevEl: 'swiper-button-prev',\n });\n const params = getParams();\n if (!(params.nextEl || params.prevEl))\n return;\n const nextEl = getEl(params.nextEl);\n const prevEl = getEl(params.prevEl);\n Object.assign(swiper.navigation, {\n nextEl,\n prevEl,\n });\n const nextEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(nextEl);\n const prevEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(prevEl);\n const initButton = (el, dir) => {\n if (el) {\n if (params.addIcons &&\n el.matches('.swiper-button-next,.swiper-button-prev') &&\n !el.querySelector('svg')) {\n const tempEl = document.createElement('div');\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.w)(tempEl, arrowSvg);\n const svgEl = tempEl.querySelector('svg');\n if (svgEl)\n el.appendChild(svgEl);\n tempEl.remove();\n }\n el.addEventListener('click', dir === 'next' ? onNextClick : onPrevClick);\n }\n if (!swiper.enabled && el) {\n el.classList.add(...params.lockClass.split(' '));\n }\n };
1371\n nextEls.forEach((el) => initButton(el, 'next'));\n prevEls.forEach((el) => initButton(el, 'prev'));\n }\n function destroy() {\n const params = getParams();\n const { nextEl, prevEl } = swiper.navigation;\n const nextEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(nextEl);\n const prevEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(prevEl);\n const destroyButton = (el, dir) => {\n el.removeEventListener('click', dir === 'next' ? onNextClick : onPrevClick);\n el.classList.remove(...params.disabledClass.split(' '));\n };\n nextEls.forEach((el) => destroyButton(el, 'next'));\n prevEls.forEach((el) => destroyButton(el, 'prev'));\n }\n on('init', () => {\n if (getParams().enabled === false) {\n disable();\n }\n else {\n init();\n update();\n }\n });\n on('toEdge fromEdge lock unlock', () => {\n update();\n });\n on('destroy', () => {\n destroy();\n });\n on('enable disable', () => {\n const params = getParams();\n const { nextEl, prevEl } = swiper.navigation;\n const nextEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(nextEl);\n const prevEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(prevEl);\n if (swiper.enabled) {\n update();\n return;\n }\n [...nextEls, ...prevEls]\n .filter((el) => !!el)\n .forEach((el) => el.classList.add(params.lockClass));\n });\n on('click', (_s, e) => {\n const params = getParams();\n const { nextEl, prevEl } = swiper.navigation;\n const nextEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(nextEl);\n const prevEls = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(prevEl);\n const targetEl = e.target;\n let targetIsButton = prevEls.includes(targetEl) || nextEls.includes(targetEl);\n if (swiper.isElement && !targetIsButton) {\n const path = e.composedPath ? e.composedPath() : [];\n if (path.length) {\n targetIsButton = path.find((pathEl) => nextEls.includes(pathEl) || prevEls.includes(pathEl));\n }\n }\n if (params.hideOnClick && !targetIsButton) {\n if (swiper.pagination &&\n swiper.params.pagination &&\n swiper.params.pagination.clickable &&\n (swiper.pagination.el === targetEl || swiper.pagination.el.contains(targetEl)))\n return;\n let isHidden;\n if (nextEls.length) {\n isHidden = nextEls[0].classList.contains(params.hiddenClass);\n }\n else if (prevEls.length) {\n isHidden = prevEls[0].classList.contains(params.hiddenClass);\n }\n if (isHidden === true) {\n emit('navigationShow');\n }\n else {\n emit('navigationHide');\n }\n [...nextEls, ...prevEls]\n .filter((el) => !!el)\n .forEach((el) => el.classList.toggle(params.hiddenClass));\n }\n });\n const enable = () => {\n const params = getParams();\n swiper.el.classList.remove(...params.navigationDisabledClass.split(' '));\n init();\n update();\n };\n const disable = () => {\n const params = getParams();\n swiper.el.classList.add(...params.navigationDisabledClass.split(' '));\n destroy();\n };\n Object.assign(swiper.navigation, {\n enable,\n disable,\n update,\n init,\n destroy,\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/navigation.mjs?\n}"); 1372 1373/***/ }, 1374 1375/***/ "./node_modules/swiper/modules/pagination.mjs" 1376/*!****************************************************!*\ 1377 !*** ./node_modules/swiper/modules/pagination.mjs ***! 1378 \****************************************************/ 1379(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1380 1381"use strict"; 1382eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Pagination)\n/* harmony export */ });\n/* harmony import */ var _shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/classes-to-selector.mjs */ \"./node_modules/swiper/shared/classes-to-selector.mjs\");\n/* harmony import */ var _shared_create_element_if_not_defined_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../shared/create-element-if-not-defined.mjs */ \"./node_modules/swiper/shared/create-element-if-not-defined.mjs\");\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\n\n\nconst isVirtualEnabled = (swiper) => !!swiper.virtual && !!swiper.params.virtual?.enabled;\nconst isFreeModeEnabled = (swiper) => !!swiper.params.freeMode?.enabled;\n// Slides count for bullets/fraction/progressbar totals: with grid rows the\n// slides that share a column collapse into one snap position.\nconst getSlidesLength = (swiper) => {\n if (isVirtualEnabled(swiper))\n return swiper.virtual.slides.length;\n const gridRows = swiper.params.grid?.rows;\n if (swiper.grid && gridRows && gridRows > 1) {\n return swiper.slides.length / Math.ceil(gridRows);\n }\n return swiper.slides.length;\n};\nconst Pagination = ({ swiper, extendParams, on, emit }) =>
1382 {\n const pfx = 'swiper-pagination';\n extendParams({\n pagination: {\n el: null,\n bulletElement: 'span',\n clickable: false,\n hideOnClick: false,\n renderBullet: null,\n renderProgressbar: null,\n renderFraction: null,\n renderCustom: null,\n progressbarOpposite: false,\n type: 'bullets', // 'bullets' or 'progressbar' or 'fraction' or 'custom'\n dynamicBullets: false,\n dynamicMainBullets: 1,\n formatFractionCurrent: (number) => number,\n formatFractionTotal: (number) => number,\n bulletClass: `${pfx}-bullet`,\n bulletActiveClass: `${pfx}-bullet-active`,\n modifierClass: `${pfx}-`,\n currentClass: `${pfx}-current`,\n totalClass: `${pfx}-total`,\n hiddenClass: `${pfx}-hidden`,\n progressbarFillClass: `${pfx}-progressbar-fill`,\n progressbarOppositeClass: `${pfx}-progressbar-opposite`,\n clickableClass: `${pfx}-clickable`,\n lockClass: `${pfx}-lock`,\n horizontalClass: `${pfx}-horizontal`,\n verticalClass: `${pfx}-vertical`,\n paginationDisabledClass: `${pfx}-disabled`,\n },\n });\n // Initialized as a partial; remaining methods (render, update, init,\n // destroy, enable, disable) attach after their definitions below.\n swiper.pagination = {\n el: null,\n bullets: [],\n };\n let bulletSize;\n let dynamicBulletIndex = 0;\n function getParams() {\n return swiper.params.pagination;\n }\n function isPaginationDisabled() {\n const elParam = getParams().el;\n return (!elParam ||\n !swiper.pagination.el ||\n (Array.isArray(swiper.pagination.el) &&\n swiper.pagination.el.length === 0));\n }\n function setSideBullets(bulletEl, position) {\n const { bulletActiveClass } = getParams();\n if (!bulletEl)\n return;\n let current = bulletEl[`${position === 'prev' ? 'previous' : 'next'}ElementSibling`];\n if (current) {\n current.classList.add(`${bulletActiveClass}-${position}`);\n current = current[`${position === 'prev' ? 'previous' : 'next'}ElementSibling`];\n if (current) {\n current.classList.add(`${bulletActiveClass}-${position}-${position}`);\n }\n }\n }\n function getMoveDirection(prevIndex, nextIndex, length) {\n prevIndex = prevIndex % length;\n nextIndex = nextIndex % length;\n if (nextIndex === prevIndex + 1) {\n return 'next';\n }\n else if (nextIndex === prevIndex - 1) {\n return 'previous';\n }\n return undefined;\n }\n function onBulletClick(e) {\n const targetEl = e.target;\n const bulletEl = targetEl.closest((0,_shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__.c)(getParams().bulletClass));\n if (!bulletEl) {\n return;\n }\n e.preventDefault();\n const index = ((0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.b)(bulletEl) ?? 0) * (swiper.params.slidesPerGroup ?? 1);\n if (swiper.params.loop) {\n if (swiper.realIndex === index)\n return;\n const moveDirection = getMoveDirection(swiper.realIndex, index, swiper.slides.length);\n if (moveDirection === 'next') {\n swiper.slideNext();\n }\n else if (moveDirection === 'previous') {\n swiper.slidePrev();\n }\n else {\n swiper.slideToLoop(index);\n }\n }\n else {\n swiper.slideTo(index);\n }\n }\n function update() {\n // Render || Update Pagination bullets/items\n const rtl = swiper.rtl;\n const params = getParams();\n if (isPaginationDisabled())\n return;\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.s)(swiper.pagination.el);\n // Current/Total\n let current;\n let previousIndex;\n const slidesLength = getSlidesLength(swiper);\n const total = swiper.params.loop\n ? Math.ceil(slidesLength / (swiper.params.slidesPerGroup ?? 1))\n : swiper.snapGrid.length;\n if (swiper.params.loop) {\n previousIndex = swiper.previousRealIndex || 0;\n current =\n (swiper.params.slidesPerGroup ?? 1) > 1\n ? Math.floor(swiper.realIndex / (swiper.params.slidesPerGroup ?? 1))\n : swiper.realIndex;\n }\n else if (typeof swiper.snapIndex !== 'undefined') {\n current = swiper.snapIndex;\n previousIndex = swiper.previousSnapIndex;\n }\n else {\n previousIndex = swiper.previousIndex || 0;\n current = swiper.activeIndex || 0;\n }\n // Types\n if (params.type === 'bullets' &&\n swiper.pagination.bullets &&\n swiper.pagination.bullets.length > 0) {\n const bullets = swiper.pagination.bullets;\n let firstIndex = 0;\n let lastIndex = 0;\n let midIndex = 0;\n if (params.dynamicBullets) {\n bulletSize = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.i)(bullets[0], swiper.isHorizontal() ? 'width' : 'height');\n const dim = swiper.isHorizontal() ? 'width' : 'height';
1382\n els.forEach((subEl) => {\n subEl.style[dim] = `${(bulletSize ?? 0) * (params.dynamicMainBullets + 4)}px`;\n });\n if (params.dynamicMainBullets > 1 && previousIndex !== undefined) {\n dynamicBulletIndex += current - (previousIndex || 0);\n if (dynamicBulletIndex > params.dynamicMainBullets - 1) {\n dynamicBulletIndex = params.dynamicMainBullets - 1;\n }\n else if (dynamicBulletIndex < 0) {\n dynamicBulletIndex = 0;\n }\n }\n firstIndex = Math.max(current - dynamicBulletIndex, 0);\n lastIndex = firstIndex + (Math.min(bullets.length, params.dynamicMainBullets) - 1);\n midIndex = (lastIndex + firstIndex) / 2;\n }\n bullets.forEach((bulletEl) => {\n const classesToRemove = [\n '',\n '-next',\n '-next-next',\n '-prev',\n '-prev-prev',\n '-main',\n ]\n .map((suffix) => `${params.bulletActiveClass}${suffix}`)\n .flatMap((s) => (typeof s === 'string' && s.includes(' ') ? s.split(' ') : [s]));\n bulletEl.classList.remove(...classesToRemove);\n });\n if (els.length > 1) {\n bullets.forEach((bullet) => {\n const bulletIndex = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.b)(bullet);\n if (bulletIndex === current) {\n bullet.classList.add(...params.bulletActiveClass.split(' '));\n }\n else if (swiper.isElement) {\n bullet.setAttribute('part', 'bullet');\n }\n if (params.dynamicBullets && bulletIndex !== undefined) {\n if (bulletIndex >= firstIndex && bulletIndex <= lastIndex) {\n bullet.classList.add(...`${params.bulletActiveClass}-main`.split(' '));\n }\n if (bulletIndex === firstIndex) {\n setSideBullets(bullet, 'prev');\n }\n if (bulletIndex === lastIndex) {\n setSideBullets(bullet, 'next');\n }\n }\n });\n }\n else {\n const bullet = bullets[current];\n if (bullet) {\n bullet.classList.add(...params.bulletActiveClass.split(' '));\n }\n if (swiper.isElement) {\n bullets.forEach((bulletEl, bulletIndex) => {\n bulletEl.setAttribute('part', bulletIndex === current ? 'bullet-active' : 'bullet');\n });\n }\n if (params.dynamicBullets) {\n const firstDisplayedBullet = bullets[firstIndex];\n const lastDisplayedBullet = bullets[lastIndex];\n for (let i = firstIndex; i <= lastIndex; i += 1) {\n if (bullets[i]) {\n bullets[i].classList.add(...`${params.bulletActiveClass}-main`.split(' '));\n }\n }\n setSideBullets(firstDisplayedBullet, 'prev');\n setSideBullets(lastDisplayedBullet, 'next');\n }\n }\n if (params.dynamicBullets) {\n const dynamicBulletsLength = Math.min(bullets.length, params.dynamicMainBullets + 4);\n const bulletsOffset = ((bulletSize ?? 0) * dynamicBulletsLength - (bulletSize ?? 0)) / 2 -\n midIndex * (bulletSize ?? 0);\n const offsetProp = rtl ? 'right' : 'left';\n const positionDim = swiper.isHorizontal() ? offsetProp : 'top';
1382\n bullets.forEach((bullet) => {\n bullet.style[positionDim] = `${bulletsOffset}px`;\n });\n }\n }\n els.forEach((subEl, subElIndex) => {\n if (params.type === 'fraction') {\n subEl.querySelectorAll((0,_shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__.c)(params.currentClass)).forEach((fractionEl) => {\n fractionEl.textContent = String(params.formatFractionCurrent(current + 1));\n });\n subEl.querySelectorAll((0,_shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__.c)(params.totalClass)).forEach((totalEl) => {\n totalEl.textContent = String(params.formatFractionTotal(total));\n });\n }\n if (params.type === 'progressbar') {\n let progressbarDirection;\n if (params.progressbarOpposite) {\n progressbarDirection = swiper.isHorizontal() ? 'vertical' : 'horizontal';\n }\n else {\n progressbarDirection = swiper.isHorizontal() ? 'horizontal' : 'vertical';\n }\n const scale = (current + 1) / total;\n let scaleX = 1;\n let scaleY = 1;\n if (progressbarDirection === 'horizontal') {\n scaleX = scale;\n }\n else {\n scaleY = scale;\n }\n subEl\n .querySelectorAll((0,_shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__.c)(params.progressbarFillClass))\n .forEach((progressEl) => {\n progressEl.style.transform = `translate3d(0,0,0) scaleX(${scaleX}) scaleY(${scaleY})`;\n progressEl.style.transitionDuration = `${swiper.params.speed}ms`;\n });\n }\n if (params.type === 'custom' && params.renderCustom) {\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.w)(subEl, params.renderCustom(swiper, current + 1, total));\n if (subElIndex === 0)\n emit('paginationRender', subEl);\n }\n else {\n if (subElIndex === 0)\n emit('paginationRender', subEl);\n emit('paginationUpdate', subEl);\n }\n if (swiper.params.watchOverflow && swiper.enabled) {\n subEl.classList[swiper.isLocked ? 'add' : 'remove'](params.lockClass);\n }\n });\n }\n function render() {\n // Render Container\n const params = getParams();\n if (isPaginationDisabled())\n return;\n const slidesLength = getSlidesLength(swiper);\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.s)(swiper.pagination.el);\n let paginationHTML = '';\n if (params.type === 'bullets') {\n let numberOfBullets = swiper.params.loop\n ? Math.ceil(slidesLength / (swiper.params.slidesPerGroup ?? 1))\n : swiper.snapGrid.length;\n if (swiper.params.freeMode && isFreeModeEnabled(swiper) && numberOfBullets > slidesLength) {\n numberOfBullets = slidesLength;\n }\n for (let i = 0; i < numberOfBullets; i += 1) {\n if (params.renderBullet) {\n paginationHTML += params.renderBullet.call(swiper, i, params.bulletClass);\n }\n else {\n // oxfmt-ignore\n paginationHTML += `<${params.bulletElement} ${swiper.isElement ? 'part=\"bullet\"' : ''} class=\"${params.bulletClass}\"></${params.bulletElement}>`;\n }\n }\n }\n if (params.type === 'fraction') {\n if (params.renderFraction) {\n paginationHTML = params.renderFraction.call(swiper, params.currentClass, params.totalClass);\n }\n else {\n paginationHTML =\n `<span class=\"${params.currentClass}\"></span>` +\n ' / ' +\n `<span class=\"${params.totalClass}\"></span>`;\n }\n }\n if (params.type === 'progressbar') {\n if (params.renderProgressbar) {\n paginationHTML = params.renderProgressbar.call(swi
1382per, params.progressbarFillClass);\n }\n else {\n paginationHTML = `<span class=\"${params.progressbarFillClass}\"></span>`;\n }\n }\n swiper.pagination.bullets = [];\n els.forEach((subEl) => {\n if (params.type !== 'custom') {\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.w)(subEl, paginationHTML || '');\n }\n if (params.type === 'bullets') {\n swiper.pagination.bullets.push(...Array.from(subEl.querySelectorAll((0,_shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__.c)(params.bulletClass))));\n }\n });\n if (params.type !== 'custom') {\n emit('paginationRender', els[0]);\n }\n }\n function init() {\n swiper.params.pagination = (0,_shared_create_element_if_not_defined_mjs__WEBPACK_IMPORTED_MODULE_1__.c)(swiper, swiper.originalParams.pagination, swiper.params.pagination, { el: 'swiper-pagination' });\n const params = getParams();\n if (!params.el)\n return;\n let el;\n if (typeof params.el === 'string' && swiper.isElement) {\n el = swiper.el.querySelector(params.el);\n }\n if (!el && typeof params.el === 'string') {\n el = [...document.querySelectorAll(params.el)];\n }\n if (!el) {\n el = params.el;\n }\n if (!el || (Array.isArray(el) && el.length === 0))\n return;\n if (swiper.params.uniqueNavElements &&\n typeof params.el === 'string' &&\n Array.isArray(el) &&\n el.length > 1) {\n el = [...swiper.el.querySelectorAll(params.el)];\n // check if it belongs to another nested Swiper\n if (el.length > 1) {\n const found = el.find((subEl) => {\n if ((0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.j)(subEl, '.swiper')[0] !== swiper.el)\n return false;\n return true;\n });\n if (found)\n el = found;\n }\n }\n if (Array.isArray(el) && el.length === 1)\n el = el[0];\n Object.assign(swiper.pagination, {\n el,\n });\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.s)(el);\n els.forEach((subEl) => {\n if (params.type === 'bullets' && params.clickable) {\n subEl.classList.add(...(params.clickableClass || '').split(' '));\n }\n subEl.classList.add(params.modifierClass + params.type);\n subEl.classList.add(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);\n if (params.type === 'bullets' && params.dynamicBullets) {\n subEl.classList.add(`${params.modifierClass}${params.type}-dynamic`);\n dynamicBulletIndex = 0;\n if (params.dynamicMainBullets < 1) {\n params.dynamicMainBullets = 1;\n }\n }\n if (params.type === 'progressbar' && params.progressbarOpposite) {\n subEl.classList.add(params.progressbarOppositeClass);\n }\n if (params.clickable) {\n subEl.addEventListener('click', onBulletClick);\n }\n if (!swiper.enabled) {\n subEl.classList.add(params.lockClass);\n }\n });\n }\n function destroy() {\n const params = getParams();\n if (isPaginationDisabled())\n return;\n const el = swiper.pagination.el;\n if (el) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.s)(el);\n els.forEach((subEl) => {\n subEl.classList.remove(params.hiddenClass);\n subEl.classList.remove(params.modifierClass + params.type);\n subEl.classList.remove(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);\n if (params.clickable) {\n subEl.classList.remove(...(params.clickableClass || '').split(' '));\n subEl.removeEventListener('click', onBulletClick);\n }\n });\n }\n if (swiper.pagination.bullets)\n swiper.pagination.bullets.forEac
1382h((subEl) => subEl.classList.remove(...params.bulletActiveClass.split(' ')));\n }\n on('changeDirection', () => {\n if (!swiper.pagination || !swiper.pagination.el)\n return;\n const params = getParams();\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.s)(swiper.pagination.el);\n els.forEach((subEl) => {\n subEl.classList.remove(params.horizontalClass, params.verticalClass);\n subEl.classList.add(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);\n });\n });\n on('init', () => {\n if (getParams().enabled === false) {\n disable();\n }\n else {\n init();\n render();\n update();\n }\n });\n on('activeIndexChange', () => {\n if (typeof swiper.snapIndex === 'undefined') {\n update();\n }\n });\n on('snapIndexChange', () => {\n update();\n });\n on('snapGridLengthChange', () => {\n render();\n update();\n });\n on('destroy', () => {\n destroy();\n });\n on('enable disable', () => {\n const { el } = swiper.pagination;\n if (el) {\n const params = getParams();\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.s)(el);\n els.forEach((subEl) => subEl.classList[swiper.enabled ? 'remove' : 'add'](params.lockClass));\n }\n });\n on('lock unlock', () => {\n update();\n });\n on('click', (_s, e) => {\n const targetEl = e.target;\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.s)(swiper.pagination.el);\n const params = getParams();\n if (params.el &&\n params.hideOnClick &&\n els &&\n els.length > 0 &&\n !targetEl.classList.contains(params.bulletClass)) {\n if (swiper.navigation &&\n ((swiper.navigation.nextEl && targetEl === swiper.navigation.nextEl) ||\n (swiper.navigation.prevEl && targetEl === swiper.navigation.prevEl)))\n return;\n const isHidden = els[0].classList.contains(params.hiddenClass);\n if (isHidden === true) {\n emit('paginationShow');\n }\n else {\n emit('paginationHide');\n }\n els.forEach((subEl) => subEl.classList.toggle(params.hiddenClass));\n }\n });\n const enable = () => {\n const params = getParams();\n swiper.el.classList.remove(params.paginationDisabledClass);\n const { el } = swiper.pagination;\n if (el) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.s)(el);\n els.forEach((subEl) => subEl.classList.remove(params.paginationDisabledClass));\n }\n init();\n render();\n update();\n };\n const disable = () => {\n const params = getParams();\n swiper.el.classList.add(params.paginationDisabledClass);\n const { el } = swiper.pagination;\n if (el) {\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.s)(el);\n els.forEach((subEl) => subEl.classList.add(params.paginationDisabledClass));\n }\n destroy();\n };\n Object.assign(swiper.pagination, {\n enable,\n disable,\n render,\n update,\n init,\n destroy,\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/pagination.mjs?\n}"); 1383 1384/***/ }, 1385 1386/***/ "./node_modules/swiper/modules/parallax.mjs" 1387/*!**************************************************!*\ 1388 !*** ./node_modules/swiper/modules/parallax.mjs ***! 1389 \**************************************************/ 1390(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1391 1392"use strict"; 1393eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Parallax)\n/* harmony export */ });\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nconst Parallax = ({ swiper, extendParams, on }) =>
1393 {\n extendParams({\n parallax: {\n enabled: false,\n },\n });\n function getParams() {\n return swiper.params.parallax;\n }\n const elementsSelector = '[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]';\n const setTransform = (el, progress) => {\n const { rtl } = swiper;\n const rtlFactor = rtl ? -1 : 1;\n const p = el.getAttribute('data-swiper-parallax') || '0';\n let x = el.getAttribute('data-swiper-parallax-x');\n let y = el.getAttribute('data-swiper-parallax-y');\n const scale = el.getAttribute('data-swiper-parallax-scale');\n const opacity = el.getAttribute('data-swiper-parallax-opacity');\n const rotate = el.getAttribute('data-swiper-parallax-rotate');\n if (x || y) {\n x = x || '0';\n y = y || '0';\n }\n else if (swiper.isHorizontal()) {\n x = p;\n y = '0';\n }\n else {\n y = p;\n x = '0';\n }\n if (x.indexOf('%') >= 0) {\n x = `${parseInt(x, 10) * progress * rtlFactor}%`;\n }\n else {\n x = `${Number(x) * progress * rtlFactor}px`;\n }\n if (y.indexOf('%') >= 0) {\n y = `${parseInt(y, 10) * progress}%`;\n }\n else {\n y = `${Number(y) * progress}px`;\n }\n if (typeof opacity !== 'undefined' && opacity !== null) {\n const opacityNum = Number(opacity);\n const currentOpacity = opacityNum - (opacityNum - 1) * (1 - Math.abs(progress));\n el.style.opacity = String(currentOpacity);\n }\n let transform = `translate3d(${x}, ${y}, 0px)`;\n if (typeof scale !== 'undefined' && scale !== null) {\n const scaleNum = Number(scale);\n const currentScale = scaleNum - (scaleNum - 1) * (1 - Math.abs(progress));\n transform += ` scale(${currentScale})`;\n }\n if (rotate && typeof rotate !== 'undefined' && rotate !== null) {\n const currentRotate = Number(rotate) * progress * -1;\n transform += ` rotate(${currentRotate}deg)`;\n }\n el.style.transform = transform;\n };\n const setTranslate = () => {\n const { el, slides, progress, snapGrid } = swiper;\n const elements = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(el, elementsSelector);\n if (swiper.isElement) {\n elements.push(...(0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(swiper.hostEl, elementsSelector));\n }\n elements.forEach((subEl) => {\n setTransform(subEl, progress);\n });\n slides.forEach((slideEl, slideIndex) => {\n let slideProgress = slideEl.progress ?? 0;\n const slidesPerGroup = swiper.params.slidesPerGroup ?? 1;\n if (slidesPerGroup > 1 && swiper.params.slidesPerView !== 'auto') {\n slideProgress += Math.ceil(slideIndex / 2) - progress * (snapGrid.length - 1);\n }\n slideProgress = Math.min(Math.max(slideProgress, -1), 1);\n slideEl\n .querySelectorAll(`${elementsSelector}, [data-swiper-parallax-rotate]`)\n .forEach((subEl) => {\n setTransform(subEl, slideProgress);\n });\n });\n };\n const setTransition = (duration = swiper.params.speed ?? 300) => {\n const { el, hostEl } = swiper;\n const elements = [...el.querySelectorAll(elementsSelector)];\n if (swiper.isElement) {\n elements.push(...hostEl.querySelectorAll(elementsSelector));\n }\n elements.forEach((parallaxEl) => {\n const attr = parallaxEl.getAttribute('data-swiper-parallax-duration');\n let parallaxDuration = (attr ? parseInt(attr, 10) : 0) || duration;\n if (duration === 0)\n parallaxDuration = 0;\n parallaxEl.style.transitionDuration = `${parallaxDuration}ms`;\n });\n };\n on('beforeInit', () => {\n if (!getParams().enabled)\n return;\n swiper.params.watchSlidesProgress = true;\n swiper.originalParams.watchSlidesProgress = true;\n });\n on('init', () => {\n if (!getParams().enabled)\n return;\n setTranslate();\n });\n on('setTranslate', () => {\n if (!getParams().enabled)\n return;\n setTranslate();\n });\n on('setTransition', (_swiper, duration) =>
1393 {\n if (!getParams().enabled)\n return;\n setTransition(duration);\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/parallax.mjs?\n}"); 1394 1395/***/ }, 1396 1397/***/ "./node_modules/swiper/modules/scrollbar.mjs" 1398/*!***************************************************!*\ 1399 !*** ./node_modules/swiper/modules/scrollbar.mjs ***! 1400 \***************************************************/ 1401(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1402 1403"use strict"; 1404eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Scrollbar)\n/* harmony export */ });\n/* harmony import */ var _shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/classes-to-selector.mjs */ \"./node_modules/swiper/shared/classes-to-selector.mjs\");\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n/* harmony import */ var _shared_create_element_if_not_defined_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../shared/create-element-if-not-defined.mjs */ \"./node_modules/swiper/shared/create-element-if-not-defined.mjs\");\n\n\n\n\nconst Scrollbar = ({ swiper, extendParams, on, emit }) => {\n let isTouched = false;\n let timeout = null;\n let dragTimeout = null;\n let dragStartPos = 0;\n let dragSize = 0;\n let trackSize = 0;\n let divider = 0;\n extendParams({\n scrollbar: {\n el: null,\n dragSize: 'auto',\n hide: false,\n draggable: false,\n snapOnRelease: true,\n lockClass: 'swiper-scrollbar-lock',\n dragClass: 'swiper-scrollbar-drag',\n scrollbarDisabledClass: 'swiper-scrollbar-disabled',\n horizontalClass: `swiper-scrollbar-horizontal`,\n verticalClass: `swiper-scrollbar-vertical`,\n },\n });\n // Initialized as a partial; remaining methods (updateSize, setTranslate,\n // init, destroy, enable, disable) attach after their definitions below.\n swiper.scrollbar = {\n el: null,\n dragEl: null,\n };\n function getParams() {\n return swiper.params.scrollbar;\n }\n function setTranslate() {\n const params = getParams();\n if (!params.el || !swiper.scrollbar.el)\n return;\n const { scrollbar, rtlTranslate: rtl } = swiper;\n const { dragEl, el } = scrollbar;\n const progress = swiper.params.loop ? (swiper.progressLoop ?? 0) : swiper.progress;\n let newSize = dragSize;\n let newPos = (trackSize - dragSize) * progress;\n if (rtl) {\n newPos = -newPos;\n if (newPos > 0) {\n newSize = dragSize - newPos;\n newPos = 0;\n }\n else if (-newPos + dragSize > trackSize) {\n newSize = trackSize + newPos;\n }\n }\n else if (newPos < 0) {\n newSize = dragSize + newPos;\n newPos = 0;\n }\n else if (newPos + dragSize > trackSize) {\n newSize = trackSize - newPos;\n }\n if (swiper.isHorizontal()) {\n dragEl.style.transform = `translate3d(${newPos}px, 0, 0)`;\n dragEl.style.width = `${newSize}px`;\n }\n else {\n dragEl.style.transform = `translate3d(0px, ${newPos}px, 0)`;\n dragEl.style.height = `${newSize}px`;\n }\n if (params.hide) {\n if (timeout)\n clearTimeout(timeout);\n el.style.opacity = '1';\n timeout = setTimeout(() => {\n el.style.opacity = '0';\n el.style.transitionDuration = '400ms';\n }, 1000);\n }\n }\n function setTransition(duration) {\n if (!getParams().el || !swiper.scrollbar.el)\n return;\n swiper.scrollbar.dragEl.style.transitionDuration = `${duration}ms`;\n }\n function updateSize() {\n const params = getParams();\n if (!params.el || !swiper.scrollbar.el)\n return;\n const { scrollbar } = swiper;\n const { dragEl, el } = scrollbar;\n dragEl.style.width = '';\n dragEl.style.height = '';\n trackSize = swiper.isHorizontal() ? el.offsetWidth : el.offsetHeight;\n divider =\n swiper.size /\n (swiper.virtualSize +\n (swiper.params.slidesOffsetBefore ?? 0) -\n (swiper.params.centeredSlides ? swiper.snapGrid[0] : 0));\n if (params.dragSize === 'auto') {\n dragSize = trackSize * divider;\n }\n else {\n dragSize = parseInt(String(params.dragSize), 10);\n }\n if (swiper.isHorizontal()) {\n dragEl.style.width = `${dragSize}px`;\n }\n else {\n dragEl.style.height = `${dragSize}px`;\n }\n if (divider >= 1) {\n el.style.display = 'none';\n }\n else {\n el.style.display = '';\n }\n if (params.hide) {\n el.style.opacity = '0';\n }\n if (swiper.params.watchOverflow && swiper.enabled) {\n scrollbar.el.classList[swiper.isLocked ? 'add' : 'remove'](params.lockClass);\n }\n }\n function getPointerPosition(e) {\n if (swiper.isHorizontal()) {\n return e.clientX ?? e.touches?.[0]?.clientX ?? 0;\n }\n return e.clientY ?? e.touches?.[0]?.clientY ?? 0;\n }\n function setDragPosition(e) {\n const { scrollbar, rtlTranslate: rtl } = swiper;\n const { el } = scrollbar;\n let positionRatio;\n positionRatio =\n (getPointerPosition(e) -\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.h)(el)[swiper.isHorizontal() ? 'left' : 'top'] -\n (dragStartPos !== null ? dragStartPos : dragSize / 2)) /\n (trackSize - dragSize);\n positionRatio = Math.max(Math.min(positionRatio, 1), 0);\n if (rtl) {\n positionRatio = 1 - positionRatio;\n }\n const position = swiper.minTranslate() + (swiper.maxTranslate() - swiper.minTranslate()) * positionRatio;\n swiper.updateProgress(position);\n swiper.setTranslate(position);\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n }\n function onDragStart(e) {\n const params = getParams();\n const { scrollbar, wrapperEl } = swiper;\n const { el, dragEl } = scrollbar;\n isTouched = true;\n dragStartPos =\n e.target === dragEl\n ? getPointerPosition(e) -\n e.target.getBoundingClientRect()[swiper.isHorizontal() ? 'left' : 'top']\n : null;\n e.preventDefault();\n e.stopPropagation();\n wrapperEl.style.transitionDuration = '100ms';\n dragEl.style.transitionDuration = '100ms';\n setDragPosition(e);\n if (dragTimeout)\n clearTimeout(dragTimeout);\n el.style.transitionDuration = '0ms';
1404\n if (params.hide) {\n el.style.opacity = '1';\n }\n if (swiper.params.cssMode) {\n swiper.wrapperEl.style.scrollSnapType = 'none';\n }\n emit('scrollbarDragStart', e);\n }\n function onDragMove(e) {\n const { scrollbar, wrapperEl } = swiper;\n const { el, dragEl } = scrollbar;\n if (!isTouched)\n return;\n if (e.cancelable)\n e.preventDefault();\n setDragPosition(e);\n wrapperEl.style.transitionDuration = '0ms';\n el.style.transitionDuration = '0ms';\n dragEl.style.transitionDuration = '0ms';\n emit('scrollbarDragMove', e);\n }\n function onDragEnd(e) {\n const params = getParams();\n const { scrollbar, wrapperEl } = swiper;\n const { el } = scrollbar;\n if (!isTouched)\n return;\n isTouched = false;\n if (swiper.params.cssMode) {\n swiper.wrapperEl.style.scrollSnapType = '';\n wrapperEl.style.transitionDuration = '';\n }\n if (params.hide) {\n if (dragTimeout)\n clearTimeout(dragTimeout);\n dragTimeout = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.t)(() => {\n el.style.opacity = '0';\n el.style.transitionDuration = '400ms';\n }, 1000);\n }\n emit('scrollbarDragEnd', e);\n if (params.snapOnRelease) {\n swiper.slideToClosest();\n }\n }\n function events(method) {\n const { scrollbar, params } = swiper;\n const el = scrollbar.el;\n if (!el)\n return;\n const activeListener = params.passiveListeners ? { passive: false, capture: false } : false;\n const passiveListener = params.passiveListeners ? { passive: true, capture: false } : false;\n const eventMethod = method === 'on' ? 'addEventListener' : 'removeEventListener';\n el[eventMethod]('pointerdown', onDragStart, activeListener);\n document[eventMethod]('pointermove', onDragMove, activeListener);\n document[eventMethod]('pointerup', onDragEnd, passiveListener);\n }\n function enableDraggable() {\n if (!getParams().el || !swiper.scrollbar.el)\n return;\n events('on');\n }\n function disableDraggable() {\n if (!getParams().el || !swiper.scrollbar.el)\n return;\n events('off');\n }\n function init() {\n const { scrollbar, el: swiperEl } = swiper;\n swiper.params.scrollbar = (0,_shared_create_element_if_not_defined_mjs__WEBPACK_IMPORTED_MODULE_2__.c)(swiper, swiper.originalParams.scrollbar, swiper.params.scrollbar, { el: 'swiper-scrollbar' });\n const params = getParams();\n if (!params.el)\n return;\n let el;\n if (typeof params.el === 'string' && swiper.isElement) {\n el = swiper.el.querySelector(params.el);\n }\n else {\n el = params.el;\n }\n if (!el && typeof params.el === 'string') {\n el = document.querySelectorAll(params.el);\n if (!el.length)\n return;\n }\n else if (!el) {\n el = params.el;\n }\n if (swiper.params.uniqueNavElements &&\n typeof params.el === 'string' &&\n el.length > 1 &&\n swiperEl.querySelectorAll(params.el).length === 1) {\n el = swiperEl.querySelector(params.el);\n }\n if (el.length > 0) {\n el = el[0];\n }\n const elTyped = el;\n elTyped.classList.add(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);\n let dragEl = null;\n if (elTyped) {\n dragEl = elTyped.querySelector((0,_shared_classes_to_selector_mjs__WEBPACK_IMPORTED_MODULE_0__.c)(params.dragClass));\n if (!dragEl) {\n dragEl = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.a)('div', params.dragClass);\n elTyped.append(dragEl);\n }\n }\n Object.assign(scrollbar, {\n el: elTyped,\n dragEl,\n });\n if (params.draggable) {\n enableDraggable();\n }\n if (elTyped) {\n elTyped.classList[swiper.enabled ? 'remove' : 'add'](...(0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.c)(params.lockClass));\n }\n }\n function destroy() {\n const params = getParams();\n const el = swiper.scrollbar.el;\n if (el) {\n el.classList.remove(...(0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.c)(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass));\n }\n disableDraggable();\n }\n on('changeDirection', () => {\n if (!swiper.scrollbar || !swiper.scrollbar.el)\n return;\n const params = getParams();\n const els = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.s)(swiper.scrollbar.el);
1404\n els.forEach((subEl) => {\n subEl.classList.remove(params.horizontalClass, params.verticalClass);\n subEl.classList.add(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);\n });\n });\n on('init', () => {\n if (getParams().enabled === false) {\n disable();\n }\n else {\n init();\n updateSize();\n setTranslate();\n }\n });\n on('update resize observerUpdate lock unlock changeDirection', () => {\n updateSize();\n });\n on('setTranslate', () => {\n setTranslate();\n });\n on('setTransition', (_s, duration) => {\n setTransition(duration);\n });\n on('enable disable', () => {\n const { el } = swiper.scrollbar;\n if (el) {\n el.classList[swiper.enabled ? 'remove' : 'add'](...(0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.c)(getParams().lockClass));\n }\n });\n on('destroy', () => {\n destroy();\n });\n const enable = () => {\n const params = getParams();\n swiper.el.classList.remove(...(0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.c)(params.scrollbarDisabledClass));\n if (swiper.scrollbar.el) {\n swiper.scrollbar.el.classList.remove(...(0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.c)(params.scrollbarDisabledClass));\n }\n init();\n updateSize();\n setTranslate();\n };\n const disable = () => {\n const params = getParams();\n swiper.el.classList.add(...(0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.c)(params.scrollbarDisabledClass));\n if (swiper.scrollbar.el) {\n swiper.scrollbar.el.classList.add(...(0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.c)(params.scrollbarDisabledClass));\n }\n destroy();\n };\n Object.assign(swiper.scrollbar, {\n enable,\n disable,\n updateSize,\n setTranslate,\n init,\n destroy,\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/scrollbar.mjs?\n}"); 1405 1406/***/ }, 1407 1408/***/ "./node_modules/swiper/modules/thumbs.mjs" 1409/*!************************************************!*\ 1410 !*** ./node_modules/swiper/modules/thumbs.mjs ***! 1411 \************************************************/ 1412(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1413 1414"use strict"; 1415eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Thumb)\n/* harmony export */ });\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nconst Thumb = ({ swiper, extendParams, on }) => {\n extendParams({\n thumbs: {\n swiper: null,\n multipleActiveThumbs: true,\n autoScrollOffset: 0,\n slideThumbActiveClass: 'swiper-slide-thumb-active',\n thumbsContainerClass: 'swiper-thumbs',\n },\n });\n let initialized = false;\n let swiperCreated = false;\n swiper.thumbs = {\n swiper: null,\n };\n function getParams() {\n return swiper.params.thumbs;\n }\n function isVirtualEnabled() {\n const thumbsSwiper = swiper.thumbs.swiper;\n if (!thumbsSwiper || thumbsSwiper.destroyed)\n return false;\n const virtual = thumbsSwiper.params.virtual;\n return !!virtual && !!virtual.enabled;\n }\n function onThumbClick() {\n const thumbsSwiper = swiper.thumbs.swiper;\n if (!thumbsSwiper || thumbsSwiper.destroyed)\n return;\n const clickedIndex = thumbsSwiper.clickedIndex;\n const clickedSlide = thumbsSwiper.clickedSlide;\n const thumbsParams = getParams();\n if (clickedSlide && clickedSlide.classList.contains(thumbsParams.slideThumbActiveClass))\n return;\n if (typeof clickedIndex === 'undefined' || clickedIndex === null)\n return;\n let slideToIndex;\n if (thumbsSwiper.params.loop) {\n const attr = thumbsSwiper.clickedSlide?.getAttribute('data-swiper-slide-index');\n slideToIndex = attr == null ? clickedIndex : parseInt(attr, 10);\n }\n else {\n slideToIndex = clickedIndex;\n }\n if (swiper.params.loop) {\n swiper.slideToLoop(slideToIndex);\n }\n else {\n swiper.slideTo(slideToIndex);\n }\n }
1415\n function init() {\n const thumbsParams = getParams();\n if (initialized)\n return false;\n initialized = true;\n const SwiperClass = swiper.constructor;\n if (thumbsParams.swiper instanceof SwiperClass) {\n if (thumbsParams.swiper.destroyed) {\n initialized = false;\n return false;\n }\n const thumbsSwiper = thumbsParams.swiper;\n swiper.thumbs.swiper = thumbsSwiper;\n Object.assign(thumbsSwiper.originalParams, {\n watchSlidesProgress: true,\n slideToClickedSlide: false,\n });\n Object.assign(thumbsSwiper.params, {\n watchSlidesProgress: true,\n slideToClickedSlide: false,\n });\n thumbsSwiper.update();\n }\n else if ((0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.r)(thumbsParams.swiper)) {\n const thumbsSwiperParams = Object.assign({}, thumbsParams.swiper);\n Object.assign(thumbsSwiperParams, {\n watchSlidesProgress: true,\n slideToClickedSlide: false,\n });\n swiper.thumbs.swiper = new SwiperClass(thumbsSwiperParams);\n swiperCreated = true;\n }\n const thumbsSwiper = swiper.thumbs.swiper;\n if (!thumbsSwiper)\n return false;\n thumbsSwiper.el.classList.add(thumbsParams.thumbsContainerClass);\n thumbsSwiper.on('tap', onThumbClick);\n if (isVirtualEnabled()) {\n thumbsSwiper.on('virtualUpdate', () => {\n update(false, { autoScroll: false });\n });\n }\n return true;\n }\n function update(initial, p) {\n const thumbsSwiper = swiper.thumbs.swiper;\n if (!thumbsSwiper || thumbsSwiper.destroyed)\n return;\n // Activate thumbs\n let thumbsToActivate = 1;\n const thumbsParams = getParams();\n const thumbActiveClass = thumbsParams.slideThumbActiveClass;\n const slidesPerView = swiper.params.slidesPerView;\n if (typeof slidesPerView === 'number' && slidesPerView > 1 && !swiper.params.centeredSlides) {\n thumbsToActivate = slidesPerView;\n }\n if (!thumbsParams.multipleActiveThumbs) {\n thumbsToActivate = 1;\n }\n thumbsToActivate = Math.floor(thumbsToActivate);\n thumbsSwiper.slides.forEach((slideEl) => slideEl.classList.remove(thumbActiveClass));\n if (thumbsSwiper.params.loop || isVirtualEnabled()) {\n for (let i = 0; i < thumbsToActivate; i += 1) {\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(thumbsSwiper.slidesEl, `[data-swiper-slide-index=\"${swiper.realIndex + i}\"]`).forEach((slideEl) => {\n slideEl.classList.add(thumbActiveClass);\n });\n }\n }\n else {\n for (let i = 0; i < thumbsToActivate; i += 1) {\n const slide = thumbsSwiper.slides[swiper.realIndex + i];\n if (slide) {\n slide.classList.add(thumbActiveClass);\n }\n }\n }\n if (p?.autoScroll ?? true) {\n autoScroll(initial ? 0 : undefined);\n }\n }\n function autoScroll(slideSpeed) {\n const thumbsSwiper = swiper.thumbs.swiper;\n if (!thumbsSwiper || thumbsSwiper.destroyed)\n return;\n const thumbsSlidesPerView = thumbsSwiper.params.slidesPerView;\n const slidesPerView = thumbsSlidesPerView === 'auto'\n ? thumbsSwiper.slidesPerViewDynamic()\n : (thumbsSlidesPerView ?? 1);\n const autoScrollOffset = getParams().autoScrollOffset;\n const useOffset = autoScrollOffset && !thumbsSwiper.params.loop;\n if (swiper.realIndex !== thumbsSwiper.realIndex || useOffset) {\n const currentThumbsIndex = thumbsSwiper.activeIndex;\n let newThumbsIndex;\n let direction;\n if (thumbsSwiper.params.loop) {\n const newThumbsSlide = thumbsSwiper.slides.find((slideEl) => slideEl.getAttribute('data-swiper-slide-index') === `${swiper.realIndex}`);\n newThumbsIndex = newThumbsSlide ? thumbsSwiper.slides.indexOf(newThumbsSlide) : -1;\n direction = swiper.activeIndex > swiper.previousIndex ? 'next' : 'prev';\n }\n else {\n newThumbsIndex = swiper.realIndex;\n direction = newThumbsIndex > swiper.previousIndex ? 'next' : 'prev';\n }\n if (useOffset) {\n newThumbsIndex += direction === 'next' ? autoScrollOffset : -1 * autoScrollOffset;\n }\n if (thumbsSwiper.visibleSlidesIndexes &&\n thumbsSwiper.visibleSlidesIndexes.indexOf(newThumbsIndex) < 0) {\n if (thumbsSwiper.params.centeredSlides) {\n if (newThumbsIndex > currentThumbsIndex) {\n newThumbsIndex = newThumbsIndex - Math.floor(slidesPerView / 2) + 1;\n }\n else {\n newThumbsIndex = newThumbsIndex + Math.floor(slidesPerView / 2) - 1;\n }\n }\n else if (newThumbsIndex > currentThumbsIndex &&\n thumbsSwiper.params.slidesPerGroup === 1) ;\n thumbsSwiper.slideTo(newThumbsIndex, slideSpeed);\n }\n }\n }\n on('beforeInit', () => {\n const thumbs = swiper.params.thumbs;\n if (!thumbs || !thumbs.swiper)\n return;\n if (typeof thumbs.swiper === 'string' || thumbs.swiper instanceof HTMLElement) {\n const getThumbsElementAndInit = () => {\n const thumbsElement = typeof thumbs.swiper === 'string'\n ? document.querySelector(thumbs.swiper)\n : thumbs.swiper;\n if (thumbsElement && thumbsElement.swiper) {\n thumbs.swiper = thumbsElement.swiper;\n init();\n update(true);\n }\n else if (thumbsElement) {\n const eventName = `${swiper.params.eventsPrefix}init`;\n const onThumbsSwiper = (e) => {\n const detail = e.detail;\n thumbs.swiper = detail[0];\n thumbsElement.removeEventListener(eventName, onThumbsSwiper);\n init();\n update(true);
1415\n thumbs.swiper.update();\n swiper.update();\n };\n thumbsElement.addEventListener(eventName, onThumbsSwiper);\n }\n return thumbsElement;\n };\n const watchForThumbsToAppear = () => {\n if (swiper.destroyed)\n return;\n const thumbsElement = getThumbsElementAndInit();\n if (!thumbsElement) {\n requestAnimationFrame(watchForThumbsToAppear);\n }\n };\n requestAnimationFrame(watchForThumbsToAppear);\n }\n else {\n init();\n update(true);\n }\n });\n on('slideChange update resize observerUpdate', () => {\n update();\n });\n on('setTransition', (_s, duration) => {\n const thumbsSwiper = swiper.thumbs.swiper;\n if (!thumbsSwiper || thumbsSwiper.destroyed)\n return;\n thumbsSwiper.setTransition(duration);\n });\n on('beforeDestroy', () => {\n const thumbsSwiper = swiper.thumbs.swiper;\n if (!thumbsSwiper || thumbsSwiper.destroyed)\n return;\n if (swiperCreated) {\n thumbsSwiper.destroy();\n }\n });\n Object.assign(swiper.thumbs, {\n init,\n update,\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/thumbs.mjs?\n}"); 1416 1417/***/ }, 1418 1419/***/ "./node_modules/swiper/modules/virtual.mjs" 1420/*!*************************************************!*\ 1421 !*** ./node_modules/swiper/modules/virtual.mjs ***! 1422 \*************************************************/ 1423(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1424 1425"use strict"; 1426eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Virtual)\n/* harmony export */ });\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nconst Virtual = ({ swiper, extendParams, on, emit }) => {\n extendParams({\n virtual: {\n enabled: false,\n slides: [],\n cache: true,\n slidesPerViewAutoSlideSize: 320,\n renderSlide: null,\n renderExternal: null,\n renderExternalUpdate: true,\n addSlidesBefore: 0,\n addSlidesAfter: 0,\n },\n });
1426\n let cssModeTimeout;\n // Methods (appendSlide/prependSlide/removeSlide/removeAllSlides/update) are\n // attached via Object.assign below once they're defined. Cast through\n // Partial<> so the initial state-only literal can be assigned without\n // pretending the methods exist yet.\n swiper.virtual = {\n cache: {},\n from: 0,\n // -1 marks \"nothing rendered yet\": no real update can produce to < from,\n // so the first update() never mistakes slide 0 for an already-rendered\n // slide and always appends the full [from, to] window (#8202).\n to: -1,\n slides: [],\n offset: 0,\n slidesGrid: [],\n };\n function getParams() {\n return swiper.params.virtual;\n }\n // Created lazily so module init does not touch the DOM (SSR / Node safe).\n let tempDOM;\n const getTempDOM = () => (tempDOM ??= document.createElement('div'));\n function renderSlide(slide, index) {\n const params = getParams();\n if (params.cache && swiper.virtual.cache[index]) {\n return swiper.virtual.cache[index];\n }\n let slideEl;\n if (params.renderSlide) {\n const rendered = params.renderSlide.call(swiper, slide, index);\n if (typeof rendered === 'string') {\n const el = getTempDOM();\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.w)(el, rendered);\n slideEl = el.children[0];\n }\n else {\n slideEl = rendered;\n }\n }\n else if (swiper.isElement) {\n slideEl = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.a)('swiper-slide');\n }\n else {\n slideEl = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.a)('div', swiper.params.slideClass);\n }\n slideEl.setAttribute('data-swiper-slide-index', String(index));\n if (!params.renderSlide) {\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.w)(slideEl, slide);\n }\n if (params.cache) {\n swiper.virtual.cache[index] = slideEl;\n }\n return slideEl;\n }\n function update(force, beforeInit, forceActiveIndex) {\n const { slidesPerGroup, centeredSlides, slidesPerView, loop: isLoop, initialSlide, } = swiper.params;\n if (beforeInit && !isLoop && (initialSlide ?? 0) > 0) {\n return;\n }\n const { addSlidesBefore, addSlidesAfter, slidesPerViewAutoSlideSize } = getParams();\n const { from: previousFrom, to: previousTo, slides, slidesGrid: previousSlidesGrid, offset: previousOffset, } = swiper.virtual;\n if (!swiper.params.cssMode) {\n swiper.updateActiveIndex();\n }\n const activeIndex = typeof forceActiveIndex === 'undefined' ? swiper.activeIndex || 0 : forceActiveIndex;\n let offsetProp;\n if (swiper.rtlTranslate)\n offsetProp = 'right';\n else\n offsetProp = swiper.isHorizontal() ? 'left' : 'top';\n let slidesPerViewNumeric;\n if (slidesPerView === 'auto') {\n if (slidesPerViewAutoSlideSize) {\n let swiperSize = swiper.size;\n if (!swiperSize) {\n swiperSize = swiper.isHorizontal()\n ? swiper.el.getBoundingClientRect().width\n : swiper.el.getBoundingClientRect().height;\n }\n slidesPerViewNumeric = Math.max(1, Math.ceil(swiperSize / slidesPerViewAutoSlideSize));\n }\n else {\n slidesPerViewNumeric = 1;\n }\n }\n else {\n slidesPerViewNumeric = slidesPerView ?? 1;\n }\n const groupSize = slidesPerGroup ?? 1;\n let slidesAfter;\n let slidesBefore;\n if (centeredSlides) {\n slidesAfter = Math.floor(slidesPerViewNumeric / 2) + groupSize + addSlidesAfter;\n slidesBefore = Math.floor(slidesPerViewNumeric / 2) + groupSize + addSlidesBefore;\n }\n else {\n slidesAfter = slidesPerViewNumeric + (groupSize - 1) + addSlidesAfter;\n slidesBefore = (isLoop ? slidesPerViewNumeric : groupSize) + addSlidesBefore;\n }\n let from = activeIndex - slidesBefore;\n let to = activeIndex + slidesAfter;\n if (!isLoop) {\n from = Math.max(from, 0);\n to = Math.min(to, slides.length - 1);\n }\n let offset = (swiper.slidesGrid[from] || 0) - (swiper.slidesGrid[0] || 0);\n if (isLoop && activeIndex >= slidesBefore) {\n from -= slidesBefore;\n if (!centeredSlides)\n offset += swiper.slidesGrid[0];\n }\n else if (isLoop && activeIndex < slidesBefore) {\n from = -slidesBefore;\n if (centeredSlides)\n offset += swiper.slidesGrid[0];\n }\n Object.assign(swiper.virtual, {\n from,\n to,\n offset,\n slidesGrid: swiper.slidesGrid,\n slidesBefore,\n slidesAfter,\n });
1426\n function onRendered() {\n swiper.updateSlides();\n swiper.updateProgress();\n swiper.updateSlidesClasses();\n emit('virtualUpdate');\n }\n if (previousFrom === from && previousTo === to && !force) {\n if (swiper.slidesGrid !== previousSlidesGrid && offset !== previousOffset) {\n swiper.slides.forEach((slideEl) => {\n slideEl.style.setProperty(offsetProp, `${offset - Math.abs(swiper.cssOverflowAdjustment())}px`);\n });\n }\n swiper.updateProgress();\n emit('virtualUpdate');\n return;\n }\n const virtualParams = getParams();\n if (virtualParams.renderExternal) {\n const slidesToRender = [];\n for (let i = from; i <= to; i += 1) {\n slidesToRender.push(slides[i]);\n }\n virtualParams.renderExternal.call(swiper, {\n offset,\n from,\n to,\n slides: slidesToRender,\n });\n if (virtualParams.renderExternalUpdate) {\n onRendered();\n }\n else {\n emit('virtualUpdate');\n }\n return;\n }\n const prependIndexes = [];\n const appendIndexes = [];\n const getSlideIndex = (index) => {\n let slideIndex = index;\n if (index < 0) {\n slideIndex = slides.length + index;\n }\n else if (slideIndex >= slides.length) {\n slideIndex = slideIndex - slides.length;\n }\n return slideIndex;\n };\n if (force) {\n swiper.slides\n .filter((el) => el.matches(`.${swiper.params.slideClass}, swiper-slide`))\n .forEach((slideEl) => {\n slideEl.remove();\n });\n }\n else {\n for (let i = previousFrom; i <= previousTo; i += 1) {\n if (i < from || i > to) {\n const slideIndex = getSlideIndex(i);\n swiper.slides\n .filter((el) => el.matches(`.${swiper.params.slideClass}[data-swiper-slide-index=\"${slideIndex}\"], swiper-slide[data-swiper-slide-index=\"${slideIndex}\"]`))\n .forEach((slideEl) => {\n slideEl.remove();\n });\n }\n }\n }\n const loopFrom = isLoop ? -slides.length : 0;\n const loopTo = isLoop ? slides.length * 2 : slides.length;\n for (let i = loopFrom; i < loopTo; i += 1) {\n if (i >= from && i <= to) {\n const slideIndex = getSlideIndex(i);\n if (typeof previousTo === 'undefined' || force) {\n appendIndexes.push(slideIndex);\n }\n else {\n if (i > previousTo)\n appendIndexes.push(slideIndex);\n if (i < previousFrom)\n prependIndexes.push(slideIndex);\n }\n }\n }\n appendIndexes.forEach((index) => {\n swiper.slidesEl.append(renderSlide(slides[index], index));\n });\n if (isLoop) {\n for (let i = prependIndexes.length - 1; i >= 0; i -= 1) {\n const index = prependIndexes[i];\n swiper.slidesEl.prepend(renderSlide(slides[index], index));\n }\n }\n else {\n prependIndexes.sort((a, b) => b - a);\n prependIndexes.forEach((index) => {\n swiper.slidesEl.prepend(renderSlide(slides[index], index));\n });\n }\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(swiper.slidesEl, '.swiper-slide, swiper-slide').forEach((slideEl) => {\n slideEl.style.setProperty(offsetProp, `${offset - Math.abs(swiper.cssOverflowAdjustment())}px`);\n });\n onRendered();\n }\n function appendSlide(slides) {\n if (slides !== null &&\n typeof slides === 'object' &&\n 'length' in slides) {\n const arr = slides;\n for (let i = 0; i < arr.length; i += 1) {\n if (arr[i])\n swiper.virtual.slides.push(arr[i]);\n }\n }\n else {\n swiper.virtual.slides.push(slides);\n }\n update(true);\n }\n function prependSlide(slides) {\n const activeIndex = swiper.activeIndex;\n let newActiveIndex = activeIndex + 1;\n let numberOfNewSlides = 1;\n if (Array.isArray(slides)) {\n for (let i = 0; i < slides.length; i += 1) {\n if (slides[i])\n swiper.virtual.slides.unshift(slides[i]);\n }\n newActiveIndex = activeIndex + slides.length;\n numberOfNewSlides = slides.length;\n }\n else {\n swiper.virtual.slides.unshift(slides);\n }\n if (getParams().cache) {\n const cache = swiper.virtual.cache;\n const newCache = {};\n Object.keys(cache).forEach((cachedIndex) =>
1426 {\n const cachedEl = cache[Number(cachedIndex)];\n const cachedElIndex = cachedEl.getAttribute('data-swiper-slide-index');\n if (cachedElIndex) {\n cachedEl.setAttribute('data-swiper-slide-index', String(parseInt(cachedElIndex, 10) + numberOfNewSlides));\n }\n newCache[parseInt(cachedIndex, 10) + numberOfNewSlides] = cachedEl;\n });\n swiper.virtual.cache = newCache;\n }\n update(true);\n swiper.slideTo(newActiveIndex, 0);\n }\n function removeSlide(slidesIndexes) {\n if (typeof slidesIndexes === 'undefined' || slidesIndexes === null)\n return;\n let activeIndex = swiper.activeIndex;\n const shiftCacheDownFrom = (removedIndex) => {\n Object.keys(swiper.virtual.cache).forEach((key) => {\n const numericKey = Number(key);\n if (numericKey > removedIndex) {\n const shifted = swiper.virtual.cache[numericKey];\n swiper.virtual.cache[numericKey - 1] = shifted;\n shifted.setAttribute('data-swiper-slide-index', String(numericKey - 1));\n delete swiper.virtual.cache[numericKey];\n }\n });\n };\n if (Array.isArray(slidesIndexes)) {\n for (let i = slidesIndexes.length - 1; i >= 0; i -= 1) {\n if (getParams().cache) {\n delete swiper.virtual.cache[slidesIndexes[i]];\n shiftCacheDownFrom(slidesIndexes[i]);\n }\n swiper.virtual.slides.splice(slidesIndexes[i], 1);\n if (slidesIndexes[i] < activeIndex)\n activeIndex -= 1;\n activeIndex = Math.max(activeIndex, 0);\n }\n }\n else {\n if (getParams().cache) {\n delete swiper.virtual.cache[slidesIndexes];\n shiftCacheDownFrom(slidesIndexes);\n }\n swiper.virtual.slides.splice(slidesIndexes, 1);\n if (slidesIndexes < activeIndex)\n activeIndex -= 1;\n activeIndex = Math.max(activeIndex, 0);\n }\n update(true);\n swiper.slideTo(activeIndex, 0);\n }\n function removeAllSlides() {\n swiper.virtual.slides = [];\n if (getParams().cache) {\n swiper.virtual.cache = {};\n }\n update(true);\n swiper.slideTo(0, 0);\n }\n on('beforeInit', () => {\n if (!getParams().enabled)\n return;\n let domSlidesAssigned = false;\n const passedVirtual = swiper.passedParams.virtual;\n const passedSlidesUndefined = !passedVirtual || typeof passedVirtual !== 'object' || passedVirtual.slides === undefined;\n if (passedSlidesUndefined) {\n const slides = [...swiper.slidesEl.children].filter((el) => el.matches(`.${swiper.params.slideClass}, swiper-slide`));\n if (slides && slides.length) {\n swiper.virtual.slides = [...slides];\n domSlidesAssigned = true;\n slides.forEach((slideEl, slideIndex) => {\n slideEl.setAttribute('data-swiper-slide-index', String(slideIndex));\n swiper.virtual.cache[slideIndex] = slideEl;\n slideEl.remove();\n });\n }\n }\n if (!domSlidesAssigned) {\n swiper.virtual.slides = getParams().slides;\n }\n swiper.classNames.push(`${swiper.params.containerModifierClass}virtual`);\n swiper.params.watchSlidesProgress = true;\n swiper.originalParams.watchSlidesProgress = true;\n update(false, true);\n });\n on('setTranslate', () => {\n if (!getParams().enabled)\n return;\n if (swiper.params.cssMode && !swiper._immediateVirtual) {\n clearTimeout(cssModeTimeout);\n cssModeTimeout = setTimeout(() => {\n update();\n }, 100);\n }\n else {\n update();\n }\n });\n on('init update resize', () => {\n if (!getParams().enabled)\n return;\n if (swiper.params.cssMode) {\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.v)(swiper.wrapperEl, '--swiper-virtual-size', `${swiper.virtualSize}px`);\n }\n });\n Object.assign(swiper.virtual, {\n appendSlide,\n prependSlide,\n removeSlide,\n removeAllSlides,\n update,\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/virtual.mjs?\n}"); 1427 1428/***/ }, 1429 1430/***/ "./node_modules/swiper/modules/zoom.mjs" 1431/*!**********************************************!*\ 1432 !*** ./node_modules/swiper/modules/zoom.mjs ***! 1433 \**********************************************/ 1434(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1435 1436"use strict"; 1437eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (/* binding */ Zoom)\n/* harmony export */ });\n/* harmony import */ var _shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../shared/utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nconst Zoom = ({ swiper, extendParams, on, emit }) =>
1437 {\n extendParams({\n zoom: {\n enabled: false,\n limitToOriginalSize: false,\n maxRatio: 3,\n minRatio: 1,\n panOnMouseMove: false,\n toggle: true,\n containerClass: 'swiper-zoom-container',\n zoomedSlideClass: 'swiper-slide-zoomed',\n },\n });\n swiper.zoom = {\n enabled: false,\n };\n function getParams() {\n return swiper.params.zoom;\n }\n let currentScale = 1;\n let isScaling = false;\n let isPanningWithMouse = false;\n let mousePanStart = { x: 0, y: 0 };\n const mousePanSensitivity = -3; // Negative to invert pan direction\n let fakeGestureTouched = false;\n let fakeGestureMoved = false;\n const evCache = [];\n const gesture = {\n originX: 0,\n originY: 0,\n slideEl: undefined,\n slideWidth: undefined,\n slideHeight: undefined,\n imageEl: undefined,\n imageWrapEl: undefined,\n maxRatio: 3,\n };\n const image = {\n isTouched: undefined,\n isMoved: undefined,\n currentX: undefined,\n currentY: undefined,\n minX: undefined,\n minY: undefined,\n maxX: undefined,\n maxY: undefined,\n width: undefined,\n height: undefined,\n startX: undefined,\n startY: undefined,\n touchesStart: {},\n touchesCurrent: {},\n };\n const velocity = {\n x: undefined,\n y: undefined,\n prevPositionX: undefined,\n prevPositionY: undefined,\n prevTime: undefined,\n };\n let scale = 1;\n Object.defineProperty(swiper.zoom, 'scale', {\n get() {\n return scale;\n },\n set(value) {\n if (scale !== value) {\n const imageEl = gesture.imageEl;\n const slideEl = gesture.slideEl;\n emit('zoomChange', value, imageEl, slideEl);\n }\n scale = value;\n },\n });\n function getDistanceBetweenTouches() {\n if (evCache.length < 2)\n return 1;\n const x1 = evCache[0].pageX;\n const y1 = evCache[0].pageY;\n const x2 = evCache[1].pageX;\n const y2 = evCache[1].pageY;\n const distance = Math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2);\n return distance;\n }\n function getMaxRatio() {\n const params = getParams();\n const attr = gesture.imageWrapEl?.getAttribute('data-swiper-zoom');\n const maxRatio = attr != null ? Number(attr) : params.maxRatio;\n const imageEl = gesture.imageEl;\n if (params.limitToOriginalSize && imageEl && imageEl.naturalWidth) {\n const imageMaxRatio = imageEl.naturalWidth / imageEl.offsetWidth;\n return Math.min(imageMaxRatio, maxRatio);\n }\n return maxRatio;\n }\n function getScaleOrigin() {\n if (evCache.length < 2 || !gesture.imageEl)\n return [null, null];\n const box = gesture.imageEl.getBoundingClientRect();\n return [\n (evCache[0].pageX + (evCache[1].pageX - evCache[0].pageX) / 2 - box.x - window.scrollX) /\n currentScale,\n (evCache[0].pageY + (evCache[1].pageY - evCache[0].pageY) / 2 - box.y - window.scrollY) /\n currentScale,\n ];\n }\n function getSlideSelector() {\n return swiper.isElement ? `swiper-slide` : `.${swiper.params.slideClass}`;\n }\n function eventWithinSlide(e) {\n const slideSelector = getSlideSelector();\n const target = e.target;\n if (!target)\n return false;\n if (target.matches(slideSelector))\n return true;\n if (swiper.slides.filter((slideEl) => slideEl.contains(target)).length > 0)\n return true;\n return false;\n }\n function eventWithinZoomContainer(e) {\n const selector = `.${getParams().containerClass}`;\n const target = e.target;\n if (!target)\n return false;\n if (target.matches(selector))\n return true;\n if ([...swiper.hostEl.querySelectorAll(selector)].filter((containerEl) => containerEl.contains(target)).length > 0)\n return true;\n return false;\n }\n // Events\n function onGestureStart(e) {\n if (e.pointerType === 'mouse') {\n evCache.splice(0, evCache.length);\n }\n if (!eventWithinSlide(e))\n return;\n const params = getParams();\n fakeGestureTouched = false;\n fakeGestureMoved = false;\n evCache.push(e);\n if (evCache.length < 2) {\n return;\n }\n fakeGestureTouched = true;\n gesture.scaleStart = getDistanceBetweenTouches();\n if (!gesture.slideEl) {\n const target = e.target;\n gesture.slideEl =\n target?.closest(`.${swiper.params.slideClass}, swiper-slide`) ??\n undefined;\n if (!gesture.slideEl)\n gesture.slideEl = swiper.slides[swiper.activeIndex];\n let imageEl = gesture.slideEl?.querySelector(`.${params.containerClass}`) ?? null;\n if (imageEl) {\n imageEl =\n imageEl.querySelectorAll('picture, img, svg, canvas, .swiper-zoom-target')[0] ?? null;\n }\n gesture.imageEl = imageEl ?? undefined;\n if (imageEl) {\n gesture.imageWrapEl =\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.j)(imageEl, `.${params.containerClass}
1437`)[0] ??\n undefined;\n }\n else {\n gesture.imageWrapEl = undefined;\n }\n if (!gesture.imageWrapEl) {\n gesture.imageEl = undefined;\n return;\n }\n gesture.maxRatio = getMaxRatio();\n }\n if (gesture.imageEl) {\n const [originX, originY] = getScaleOrigin();\n gesture.originX = originX ?? 0;\n gesture.originY = originY ?? 0;\n gesture.imageEl.style.transitionDuration = '0ms';\n }\n isScaling = true;\n }\n function onGestureChange(e) {\n if (!eventWithinSlide(e))\n return;\n const params = getParams();\n const zoom = swiper.zoom;\n const pointerIndex = evCache.findIndex((cachedEv) => cachedEv.pointerId === e.pointerId);\n if (pointerIndex >= 0)\n evCache[pointerIndex] = e;\n if (evCache.length < 2) {\n return;\n }\n fakeGestureMoved = true;\n gesture.scaleMove = getDistanceBetweenTouches();\n if (!gesture.imageEl) {\n return;\n }\n zoom.scale = (gesture.scaleMove / (gesture.scaleStart ?? 1)) * currentScale;\n if (zoom.scale > gesture.maxRatio) {\n zoom.scale = gesture.maxRatio - 1 + (zoom.scale - gesture.maxRatio + 1) ** 0.5;\n }\n if (zoom.scale < params.minRatio) {\n zoom.scale = params.minRatio + 1 - (params.minRatio - zoom.scale + 1) ** 0.5;\n }\n gesture.imageEl.style.transform = `translate3d(0,0,0) scale(${zoom.scale})`;\n }\n function onGestureEnd(e) {\n if (!eventWithinSlide(e))\n return;\n if (e.pointerType === 'mouse' && e.type === 'pointerout')\n return;\n const params = getParams();\n const zoom = swiper.zoom;\n const pointerIndex = evCache.findIndex((cachedEv) => cachedEv.pointerId === e.pointerId);\n if (pointerIndex >= 0)\n evCache.splice(pointerIndex, 1);\n if (!fakeGestureTouched || !fakeGestureMoved) {\n return;\n }\n fakeGestureTouched = false;\n fakeGestureMoved = false;\n if (!gesture.imageEl)\n return;\n zoom.scale = Math.max(Math.min(zoom.scale, gesture.maxRatio), params.minRatio);\n gesture.imageEl.style.transitionDuration = `${swiper.params.speed}ms`;\n gesture.imageEl.style.transform = `translate3d(0,0,0) scale(${zoom.scale})`;\n currentScale = zoom.scale;\n isScaling = false;\n if (zoom.scale > 1 && gesture.slideEl) {\n gesture.slideEl.classList.add(`${params.zoomedSlideClass}`);\n }\n else if (zoom.scale <= 1 && gesture.slideEl) {\n gesture.slideEl.classList.remove(`${params.zoomedSlideClass}`);\n }\n if (zoom.scale === 1) {\n gesture.originX = 0;\n gesture.originY = 0;\n gesture.slideEl = undefined;\n }\n }\n let allowTouchMoveTimeout;\n function allowTouchMove() {\n swiper.touchEventsData.preventTouchMoveFromPointerMove = false;\n }\n function preventTouchMove() {\n if (allowTouchMoveTimeout !== undefined)\n clearTimeout(allowTouchMoveTimeout);\n swiper.touchEventsData.preventTouchMoveFromPointerMove = true;\n allowTouchMoveTimeout = setTimeout(() => {\n if (swiper.destroyed)\n return;\n allowTouchMove();\n });\n }\n function onTouchStart(e) {\n const device = swiper.device;\n if (!gesture.imageEl)\n return;\n if (image.isTouched)\n return;\n if (device.android && e.cancelable)\n e.preventDefault();\n image.isTouched = true;\n const event = evCache.length > 0 ? evCache[0] : e;\n image.touchesStart.x = event.pageX;\n image.touchesStart.y = event.pageY;\n }\n function onTouchMove(e) {\n const isMouseEvent = e.pointerType === 'mouse';\n const isMousePan = isMouseEvent && getParams().panOnMouseMove;\n if (!eventWithinSlide(e) || !eventWithinZoomContainer(e)) {\n return;\n }\n const zoom = swiper.zoom;\n if (!gesture.imageEl) {\n return;\n }\n if (!image.isTouched || !gesture.slideEl) {\n if (isMousePan)\n onMouseMove(e);\n return;\n }\n if (isMousePan) {\n onMouseMove(e);\n return;\n }\n if (!image.isMoved) {\n image.width = gesture.imageEl.offsetWidth || gesture.imageEl.clientWidth;\n image.height = gesture.imageEl.offsetHeight || gesture.imageEl.clientHeight;\n image.startX = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.q)(gesture.imageWrapEl, 'x') || 0;\n image.startY = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.q)(gesture.imageWrapEl, 'y') || 0;\n gesture.slideWidth = gesture.slideEl.offsetWidth;\n gesture.slideHeight = gesture.slideEl.offsetHeight;\n gesture.imageWrapEl.style.transitionDuration = '0ms';
1437\n }\n // Define if we need image drag\n const scaledWidth = image.width * zoom.scale;\n const scaledHeight = image.height * zoom.scale;\n image.minX = Math.min(gesture.slideWidth / 2 - scaledWidth / 2, 0);\n image.maxX = -image.minX;\n image.minY = Math.min(gesture.slideHeight / 2 - scaledHeight / 2, 0);\n image.maxY = -image.minY;\n image.touchesCurrent.x = evCache.length > 0 ? evCache[0].pageX : e.pageX;\n image.touchesCurrent.y = evCache.length > 0 ? evCache[0].pageY : e.pageY;\n const touchesDiff = Math.max(Math.abs(image.touchesCurrent.x - (image.touchesStart.x ?? 0)), Math.abs(image.touchesCurrent.y - (image.touchesStart.y ?? 0)));\n if (touchesDiff > 5) {\n swiper.allowClick = false;\n }\n const startX = image.startX ?? 0;\n const startY = image.startY ?? 0;\n if (!image.isMoved && !isScaling) {\n if (swiper.isHorizontal() &&\n ((Math.floor(image.minX) === Math.floor(startX) &&\n image.touchesCurrent.x < (image.touchesStart.x ?? 0)) ||\n (Math.floor(image.maxX) === Math.floor(startX) &&\n image.touchesCurrent.x > (image.touchesStart.x ?? 0)))) {\n image.isTouched = false;\n allowTouchMove();\n return;\n }\n if (!swiper.isHorizontal() &&\n ((Math.floor(image.minY) === Math.floor(startY) &&\n image.touchesCurrent.y < (image.touchesStart.y ?? 0)) ||\n (Math.floor(image.maxY) === Math.floor(startY) &&\n image.touchesCurrent.y > (image.touchesStart.y ?? 0)))) {\n image.isTouched = false;\n allowTouchMove();\n return;\n }\n }\n if (e.cancelable) {\n e.preventDefault();\n }\n e.stopPropagation();\n preventTouchMove();\n image.isMoved = true;\n const scaleRatio = (zoom.scale - currentScale) / (gesture.maxRatio - getParams().minRatio);\n const { originX, originY } = gesture;\n image.currentX =\n image.touchesCurrent.x -\n (image.touchesStart.x ?? 0) +\n startX +\n scaleRatio * (image.width - originX * 2);\n image.currentY =\n image.touchesCurrent.y -\n (image.touchesStart.y ?? 0) +\n startY +\n scaleRatio * (image.height - originY * 2);\n if (image.currentX < image.minX) {\n image.currentX = image.minX + 1 - (image.minX - image.currentX + 1) ** 0.8;\n }\n if (image.currentX > image.maxX) {\n image.currentX = image.maxX - 1 + (image.currentX - image.maxX + 1) ** 0.8;\n }\n if (image.currentY < image.minY) {\n image.currentY = image.minY + 1 - (image.minY - image.currentY + 1) ** 0.8;\n }\n if (image.currentY > image.maxY) {\n image.currentY = image.maxY - 1 + (image.currentY - image.maxY + 1) ** 0.8;\n }\n // Velocity\n if (!velocity.prevPositionX)\n velocity.prevPositionX = image.touchesCurrent.x;\n if (!velocity.prevPositionY)\n velocity.prevPositionY = image.touchesCurrent.y;\n if (!velocity.prevTime)\n velocity.prevTime = Date.now();\n velocity.x =\n (image.touchesCurrent.x - velocity.prevPositionX) / (Date.now() - velocity.prevTime) / 2;\n velocity.y =\n (image.touchesCurrent.y - velocity.prevPositionY) / (Date.now() - velocity.prevTime) / 2;\n if (Math.abs(image.touchesCurrent.x - velocity.prevPositionX) < 2)\n velocity.x = 0;\n if (Math.abs(image.touchesCurrent.y - velocity.prevPositionY) < 2)\n velocity.y = 0;\n velocity.prevPositionX = image.touchesCurrent.x;\n velocity.prevPositionY = image.touchesCurrent.y;\n velocity.prevTime = Date.now();\n gesture.imageWrapEl.style.transform = `translate3d(${image.currentX}px, ${image.currentY}px,0)`;\n }\n function onTouchEnd() {\n const zoom = swiper.zoom;\n evCache.length = 0;\n if (!gesture.imageEl)\n return;\n if (!image.isTouched || !image.isMoved) {\n image.isTouched = false;\n image.isMoved = false;\n return;\n }\n image.isTouched = false;\n image.isMoved = false;\n let momentumDurationX = 300;\n let momentumDurationY = 300;\n const velocityX = velocity.x ?? 0;\n const velocityY = velocity.y ?? 0;\n const momentumDistanceX = velocityX * momentumDurationX;\n const newPositionX = image.currentX + momentumDistanceX;\n const momentumDistanceY = velocityY * momentumDurationY;\n const newPositionY = image.currentY + momentumDistanceY;\n // Fix duration\n if (velocityX !== 0)\n momentumDurationX = Math.abs((newPositionX - image.currentX) / velocityX);\n if (velocityY !== 0)\n momentumDurationY = Math.abs((newPositionY - image.currentY) / velocityY);\n const momentumDuration = Math.max(momentumDurationX, momentumDurationY);\n image.currentX = newPositionX;\n image.currentY = newPositionY;\n // Define if we need image drag\n const scaledWidth = image.width * zoom.scale;\n const scaledHeight = image.height * zoom.scale;\n image.minX = Math.min(gesture.slideWidth / 2 - scaledWidth / 2, 0);\n image.maxX = -image.minX;\n image.minY = Math.min(gesture.slideHeight / 2 - scaledHeight / 2, 0);\n image.maxY = -image.minY;\n image.currentX = Math.max(Math.min(image.currentX, image.maxX), image.minX);\n image.currentY = Math.max(Math.min(image.currentY, image.maxY), image.minY);\n gesture.imageWrapEl.style.transitionDuration = `${momentumDuration}ms`;\n gesture.imageWrapEl.style.transform = `translate3d(${image.currentX}px, ${image.currentY}px,0)`;\n }\n function onTransitionEnd() {\n const zoom = swiper.zoom;\n if (gesture.slideEl && swiper.activeIndex !== swiper.slides.indexOf(gesture.slideEl)) {\n if (gesture.imageEl) {\n gesture.imageEl.style.transform = 'translate3d(0,
14370,0) scale(1)';\n }\n if (gesture.imageWrapEl) {\n gesture.imageWrapEl.style.transform = 'translate3d(0,0,0)';\n }\n gesture.slideEl.classList.remove(`${getParams().zoomedSlideClass}`);\n zoom.scale = 1;\n currentScale = 1;\n gesture.slideEl = undefined;\n gesture.imageEl = undefined;\n gesture.imageWrapEl = undefined;\n gesture.originX = 0;\n gesture.originY = 0;\n }\n }\n function onMouseMove(e) {\n // Only pan if zoomed in and mouse panning is enabled\n if (currentScale <= 1 || !gesture.imageWrapEl)\n return;\n if (!eventWithinSlide(e) || !eventWithinZoomContainer(e))\n return;\n const currentTransform = window.getComputedStyle(gesture.imageWrapEl).transform;\n const matrix = new window.DOMMatrix(currentTransform);\n if (!isPanningWithMouse) {\n isPanningWithMouse = true;\n mousePanStart.x = e.clientX;\n mousePanStart.y = e.clientY;\n image.startX = matrix.e;\n image.startY = matrix.f;\n image.width = gesture.imageEl.offsetWidth || gesture.imageEl.clientWidth;\n image.height = gesture.imageEl.offsetHeight || gesture.imageEl.clientHeight;\n gesture.slideWidth = gesture.slideEl.offsetWidth;\n gesture.slideHeight = gesture.slideEl.offsetHeight;\n return;\n }\n const deltaX = (e.clientX - mousePanStart.x) * mousePanSensitivity;\n const deltaY = (e.clientY - mousePanStart.y) * mousePanSensitivity;\n const scaledWidth = image.width * currentScale;\n const scaledHeight = image.height * currentScale;\n const slideWidth = gesture.slideWidth;\n const slideHeight = gesture.slideHeight;\n const minX = Math.min(slideWidth / 2 - scaledWidth / 2, 0);\n const maxX = -minX;\n const minY = Math.min(slideHeight / 2 - scaledHeight / 2, 0);\n const maxY = -minY;\n const newX = Math.max(Math.min(image.startX + deltaX, maxX), minX);\n const newY = Math.max(Math.min(image.startY + deltaY, maxY), minY);\n gesture.imageWrapEl.style.transitionDuration = '0ms';\n gesture.imageWrapEl.style.transform = `translate3d(${newX}px, ${newY}px, 0)`;\n mousePanStart.x = e.clientX;\n mousePanStart.y = e.clientY;\n image.startX = newX;\n image.startY = newY;\n image.currentX = newX;\n image.currentY = newY;\n }\n function zoomIn(e) {\n const zoom = swiper.zoom;\n const params = getParams();\n if (!gesture.slideEl) {\n if (e && typeof e !== 'number' && 'target' in e && e.target) {\n gesture.slideEl =\n e.target.closest(`.${swiper.params.slideClass}, swiper-slide`) ?? undefined;\n }\n if (!gesture.slideEl) {\n const virtual = swiper.params.virtual;\n if (virtual && virtual.enabled && swiper.virtual) {\n gesture.slideEl =\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(swiper.slidesEl, `.${swiper.params.slideActiveClass}`)[0] ?? undefined;\n }\n else {\n gesture.slideEl = swiper.slides[swiper.activeIndex];\n }\n }\n let imageEl = gesture.slideEl?.querySelector(`.${params.containerClass}`) ?? null;\n if (imageEl) {\n imageEl =\n imageEl.querySelectorAll('picture, img, svg, canvas, .swiper-zoom-target')[0] ?? null;\n }\n gesture.imageEl = imageEl ?? undefined;\n if (imageEl) {\n gesture.imageWrapEl =\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.j)(imageEl, `.${params.containerClass}`)[0] ??\n undefined;\n }\n else {\n gesture.imageWrapEl = undefined;\n }\n }\n if (!gesture.imageEl || !gesture.imageWrapEl || !gesture.slideEl)\n return;\n gesture.maxRatio = getMaxRatio();\n if (swiper.params.cssMode) {\n swiper.wrapperEl.style.overflow = 'hidden';
1437\n swiper.wrapperEl.style.touchAction = 'none';\n }\n gesture.slideEl.classList.add(`${params.zoomedSlideClass}`);\n let touchX;\n let touchY;\n let offsetX;\n let offsetY;\n let diffX;\n let diffY;\n let translateX;\n let translateY;\n let imageWidth;\n let imageHeight;\n let scaledWidth;\n let scaledHeight;\n let translateMinX;\n let translateMinY;\n let translateMaxX;\n let translateMaxY;\n let slideWidth;\n let slideHeight;\n const eventIsPointer = e && typeof e !== 'number';\n if (typeof image.touchesStart.x === 'undefined' && eventIsPointer) {\n touchX = e.pageX;\n touchY = e.pageY;\n }\n else {\n touchX = image.touchesStart.x;\n touchY = image.touchesStart.y;\n }\n const prevScale = currentScale;\n const forceZoomRatio = typeof e === 'number' ? e : null;\n if (currentScale === 1 && forceZoomRatio) {\n touchX = undefined;\n touchY = undefined;\n image.touchesStart.x = undefined;\n image.touchesStart.y = undefined;\n }\n const maxRatio = getMaxRatio();\n zoom.scale = forceZoomRatio || maxRatio;\n currentScale = forceZoomRatio || maxRatio;\n if (e && !(currentScale === 1 && forceZoomRatio)) {\n slideWidth = gesture.slideEl.offsetWidth;\n slideHeight = gesture.slideEl.offsetHeight;\n offsetX = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.h)(gesture.slideEl).left + window.scrollX;\n offsetY = (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.h)(gesture.slideEl).top + window.scrollY;\n diffX = offsetX + slideWidth / 2 - (touchX ?? 0);\n diffY = offsetY + slideHeight / 2 - (touchY ?? 0);\n imageWidth = gesture.imageEl.offsetWidth || gesture.imageEl.clientWidth;\n imageHeight = gesture.imageEl.offsetHeight || gesture.imageEl.clientHeight;\n scaledWidth = imageWidth * zoom.scale;\n scaledHeight = imageHeight * zoom.scale;\n translateMinX = Math.min(slideWidth / 2 - scaledWidth / 2, 0);\n translateMinY = Math.min(slideHeight / 2 - scaledHeight / 2, 0);\n translateMaxX = -translateMinX;\n translateMaxY = -translateMinY;\n if (prevScale > 0 &&\n forceZoomRatio &&\n typeof image.currentX === 'number' &&\n typeof image.currentY === 'number') {\n translateX = (image.currentX * zoom.scale) / prevScale;\n translateY = (image.currentY * zoom.scale) / prevScale;\n }\n else {\n translateX = diffX * zoom.scale;\n translateY = diffY * zoom.scale;\n }\n if (translateX < translateMinX) {\n translateX = translateMinX;\n }\n if (translateX > translateMaxX) {\n translateX = translateMaxX;\n }\n if (translateY < translateMinY) {\n translateY = translateMinY;\n }\n if (translateY > translateMaxY) {\n translateY = translateMaxY;\n }\n }\n else {\n translateX = 0;\n translateY = 0;\n }\n if (forceZoomRatio && zoom.scale === 1) {\n gesture.originX = 0;\n gesture.originY = 0;\n }\n image.currentX = translateX;\n image.currentY = translateY;\n gesture.imageWrapEl.style.transitionDuration = '300ms';\n gesture.imageWrapEl.style.transform = `translate3d(${translateX}px, ${translateY}px,0)`;\n gesture.imageEl.style.transitionDuration = '300ms';\n gesture.imageEl.style.transform = `translate3d(0,0,0) scale(${zoom.scale})`;\n }\n function zoomOut() {\n const zoom = swiper.zoom;\n const params = getParams();\n if (!gesture.slideEl) {\n const virtual = swiper.params.virtual;\n if (virtual && virtual.enabled && swiper.virtual) {\n gesture.slideEl =\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(swiper.slidesEl, `.${swiper.params.slideActiveClass}`)[0] ?? undefined;\n }\n else {\n gesture.slideEl = swiper.slides[swiper.activeIndex];\n }\n let imageEl = gesture.slideEl?.querySelector(`.${params.containerClass}`) ?? null;\n if (imageEl) {\n imageEl =\n imageEl.querySelectorAll('picture, img, svg, canvas, .swiper-zoom-target')[0] ?? null;\n }\n gesture.imageEl = imageEl ?? undefined;\n if (imageEl) {\n gesture.imageWrapEl =\n (0,_shared_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.j)(imageEl, `.${params.containerClass}
1437`)[0] ??\n undefined;\n }\n else {\n gesture.imageWrapEl = undefined;\n }\n }\n if (!gesture.imageEl || !gesture.imageWrapEl || !gesture.slideEl)\n return;\n gesture.maxRatio = getMaxRatio();\n if (swiper.params.cssMode) {\n swiper.wrapperEl.style.overflow = '';\n swiper.wrapperEl.style.touchAction = '';\n }\n zoom.scale = 1;\n currentScale = 1;\n image.currentX = undefined;\n image.currentY = undefined;\n image.touchesStart.x = undefined;\n image.touchesStart.y = undefined;\n gesture.imageWrapEl.style.transitionDuration = '300ms';\n gesture.imageWrapEl.style.transform = 'translate3d(0,0,0)';\n gesture.imageEl.style.transitionDuration = '300ms';\n gesture.imageEl.style.transform = 'translate3d(0,0,0) scale(1)';\n gesture.slideEl.classList.remove(`${params.zoomedSlideClass}`);\n gesture.slideEl = undefined;\n gesture.originX = 0;\n gesture.originY = 0;\n if (params.panOnMouseMove) {\n mousePanStart = { x: 0, y: 0 };\n if (isPanningWithMouse) {\n isPanningWithMouse = false;\n image.startX = 0;\n image.startY = 0;\n }\n }\n }\n // Toggle Zoom\n function zoomToggle(e) {\n const zoom = swiper.zoom;\n if (zoom.scale && zoom.scale !== 1) {\n // Zoom Out\n zoomOut();\n }\n else {\n // Zoom In\n zoomIn(e);\n }\n }\n function getListeners() {\n const passiveListener = swiper.params.passiveListeners\n ? { passive: true, capture: false }\n : false;\n const activeListenerWithCapture = swiper.params.passiveListeners\n ? { passive: false, capture: true }\n : true;\n return { passiveListener, activeListenerWithCapture };\n }\n // Attach/Detach Events\n function enable() {\n const zoom = swiper.zoom;\n if (zoom.enabled)\n return;\n zoom.enabled = true;\n const { passiveListener, activeListenerWithCapture } = getListeners();\n // Scale image\n swiper.wrapperEl.addEventListener('pointerdown', onGestureStart, passiveListener);\n swiper.wrapperEl.addEventListener('pointermove', onGestureChange, activeListenerWithCapture);\n ['pointerup', 'pointercancel', 'pointerout'].forEach((eventName) => {\n swiper.wrapperEl.addEventListener(eventName, onGestureEnd, passiveListener);\n });\n // Move image\n swiper.wrapperEl.addEventListener('pointermove', onTouchMove, activeListenerWithCapture);\n }\n function disable() {\n const zoom = swiper.zoom;\n if (!zoom.enabled)\n return;\n zoom.enabled = false;\n const { passiveListener, activeListenerWithCapture } = getListeners();\n // Scale image\n swiper.wrapperEl.removeEventListener('pointerdown', onGestureStart, passiveListener);\n swiper.wrapperEl.removeEventListener('pointermove', onGestureChange, activeListenerWithCapture);\n ['pointerup', 'pointercancel', 'pointerout'].forEach((eventName) => {\n swiper.wrapperEl.removeEventListener(eventName, onGestureEnd, passiveListener);\n });\n // Move image\n swiper.wrapperEl.removeEventListener('pointermove', onTouchMove, activeListenerWithCapture);\n }\n on('init', () => {\n if (getParams().enabled) {\n enable();\n }\n });\n on('destroy', () => {\n disable();\n });\n on('touchStart', (_s, e) => {\n if (!swiper.zoom.enabled)\n return;\n onTouchStart(e);\n });\n on('touchEnd', () => {\n if (!swiper.zoom.enabled)\n return;\n onTouchEnd();\n });\n on('doubleTap', (_s, e) => {\n if (!swiper.animating && getParams().enabled && swiper.zoom.enabled && getParams().toggle) {\n zoomToggle(e);\n }\n });\n on('transitionEnd', () => {\n if (swiper.zoom.enabled && getParams().enabled) {\n onTransitionEnd();\n }\n });\n on('slideChange', () => {\n if (swiper.zoom.enabled && getParams().enabled && swiper.params.cssMode) {\n onTransitionEnd();\n }\n });\n Object.assign(swiper.zoom, {\n enable,\n disable,\n in: zoomIn,\n out: zoomOut,\n toggle: zoomToggle,\n });\n};\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/modules/zoom.mjs?\n}"); 1438 1439/***/ }, 1440 1441/***/ "./node_modules/swiper/shared/classes-to-selector.mjs" 1442/*!************************************************************!*\ 1443 !*** ./node_modules/swiper/shared/classes-to-selector.mjs ***! 1444 \************************************************************/ 1445(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1446 1447"use strict"; 1448eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ c: () => (/* binding */ classesToSelector)\n/* harmony export */ });\nfunction classesToSelector(classes = '') {\n return `.${classes\n .trim()\n .replace(/([.:!+/()[\\]#>~*^$|=,'\"@{}\\\\])/g, '\\\\$1')\n .replace(/ /g, '.')}`;\n}\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/shared/classes-to-selector.mjs?\n}"); 1449 1450/***/ }, 1451 1452/***/ "./node_modules/swiper/shared/create-element-if-not-defined.mjs" 1453/*!**********************************************************************!*\ 1454 !*** ./node_modules/swiper/shared/create-element-if-not-defined.mjs ***! 1455 \**********************************************************************/ 1456(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1457 1458"use strict"; 1459eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ c: () => (/* binding */ createElementIfNotDefined)\n/* harmony export */ });\n/* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nfunction createElementIfNotDefined(swiper, originalParams, params, checkProps) {\
1459n const target = (params ?? {});\n const original = (originalParams ?? {});\n if (swiper.params.createElements) {\n Object.keys(checkProps).forEach((key) => {\n if (!target[key] && target.auto === true) {\n let element = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(swiper.el, `.${checkProps[key]}`)[0];\n if (!element) {\n element = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.a)('div', checkProps[key]);\n element.className = checkProps[key];\n swiper.el.append(element);\n }\n target[key] = element;\n original[key] = element;\n }\n });\n }\n return target;\n}\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/shared/create-element-if-not-defined.mjs?\n}"); 1460 1461/***/ }, 1462 1463/***/ "./node_modules/swiper/shared/create-shadow.mjs" 1464/*!******************************************************!*\ 1465 !*** ./node_modules/swiper/shared/create-shadow.mjs ***! 1466 \******************************************************/ 1467(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1468 1469"use strict"; 1470eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ c: () => (/* binding */ createShadow)\n/* harmony export */ });\n/* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nfunction createShadow(suffix, slideEl, side) {\n const shadowClass = `swiper-slide-shadow${side ? `-${side}` : ''}${suffix ? ` swiper-slide-shadow-${suffix}` : ''}`;\n const shadowContainer = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.p)(slideEl);\n const selector = `.${shadowClass.split(' ').join('.')}`;\n const existing = shadowContainer.querySelector(selector);\n if (existing)\n return existing;\n const created = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.a)('div', shadowClass.split(' '));\n shadowContainer.append(created);\n return created;\n}\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/shared/create-shadow.mjs?\n}"); 1471 1472/***/ }, 1473 1474/***/ "./node_modules/swiper/shared/effect-init.mjs" 1475/*!****************************************************!*\ 1476 !*** ./node_modules/swiper/shared/effect-init.mjs ***! 1477 \****************************************************/ 1478(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1479 1480"use strict"; 1481eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ e: () => (/* binding */ effectInit)\n/* harmony export */ });\nfunction effectInit(params) {\n const { effect, swiper, on, setTranslate, setTransition, overwriteParams, perspective, recreateShadows, getEffectParams, } = params;\n on('beforeInit', () => {\n if (swiper.params.effect !== effect)\n return;\n swiper.classNames.push(`${swiper.params.containerModifierClass}${effect}`);\n if (perspective && perspective()) {\n swiper.classNames.push(`${swiper.params.containerModifierClass}3d`);\n }\n const overwriteParamsResult = overwriteParams ? overwriteParams() : {};\n Object.assign(swiper.params, overwriteParamsResult);\n Object.assign(swiper.originalParams, overwriteParamsResult);\n });\n on('setTranslate _virtualUpdated', () => {\n if (swiper.params.effect !== effect)\n return;\n setTranslate();\n });\n on('setTransition', (_s, duration) => {\n if (swiper.params.effect !== effect)\n return;\n setTransition(duration);\n });\n on('transitionEnd', () => {\n if (swiper.params.effect !== effect)\n return;\n if (recreateShadows) {\n const effectParams = getEffectParams ? getEffectParams() : undefined;\n if (!effectParams || !effectParams.slideShadows)\n return;
1481\n swiper.slides.forEach((slideEl) => {\n slideEl\n .querySelectorAll('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left')\n .forEach((shadowEl) => shadowEl.remove());\n });\n recreateShadows();\n }\n });\n let requireUpdateOnVirtual = false;\n on('virtualUpdate', () => {\n if (swiper.params.effect !== effect)\n return;\n if (!swiper.slides.length) {\n requireUpdateOnVirtual = true;\n }\n requestAnimationFrame(() => {\n if (requireUpdateOnVirtual && swiper.slides && swiper.slides.length) {\n setTranslate();\n requireUpdateOnVirtual = false;\n }\n });\n });\n}\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/shared/effect-init.mjs?\n}"); 1482 1483/***/ }, 1484 1485/***/ "./node_modules/swiper/shared/effect-target.mjs" 1486/*!******************************************************!*\ 1487 !*** ./node_modules/swiper/shared/effect-target.mjs ***! 1488 \******************************************************/ 1489(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1490 1491"use strict"; 1492eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ e: () => (/* binding */ effectTarget)\n/* harmony export */ });\n/* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nfunction effectTarget(_effectParams, slideEl) {\n const transformEl = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.p)(slideEl);\n if (transformEl !== slideEl) {\n transformEl.style.backfaceVisibility = 'hidden';\n transformEl.style.setProperty('-webkit-backface-visibility', 'hidden');\n }\n return transformEl;\n}\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/shared/effect-target.mjs?\n}"); 1493 1494/***/ }, 1495 1496/***/ "./node_modules/swiper/shared/effect-virtual-transition-end.mjs" 1497/*!**********************************************************************!*\ 1498 !*** ./node_modules/swiper/shared/effect-virtual-transition-end.mjs ***! 1499 \**********************************************************************/ 1500(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1501 1502"use strict"; 1503eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ e: () => (/* binding */ effectVirtualTransitionEnd)\n/* harmony export */ });\n/* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nfunction effectVirtualTransitionEnd({ swiper, duration, transformElements, allSlides, }) {\n const { activeIndex } = swiper;\n const getSlide = (el) => {\n if (!el.parentElement) {\n // assume shadow root\n return swiper.slides.find((slideEl) => slideEl.shadowRoot && slideEl.shadowRoot === el.parentNode);\n }\n if (el.parentElement instanceof HTMLElement)\n return el.parentElement;\n return undefined;\n };\n if (swiper.params.virtualTranslate && duration !== 0) {\n let eventTriggered = false;\n let transitionEndTarget;\n if (allSlides) {\n transitionEndTarget = transformElements;\n }\n else {\n transitionEndTarget = transformElements.filter((transformEl) => {\n const el = transformEl.classList.contains('swiper-slide-transform')\n ? getSlide(transformEl)\n : transformEl;\n return !!el && swiper.getSlideIndex(el) === activeIndex;\n });\n }\n transitionEndTarget.forEach((el) => {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.m)(el, () => {\n if (eventTriggered)\n return;\n if (!swiper || swiper.destroyed)\n return;\n eventTriggered = true;\n swiper.animating = false;\n const evt = new CustomEvent('transitionend', { bubbles: true, cancelable: true });
1503\n swiper.wrapperEl.dispatchEvent(evt);\n });\n });\n }\n}\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/shared/effect-virtual-transition-end.mjs?\n}"); 1504 1505/***/ }, 1506 1507/***/ "./node_modules/swiper/shared/swiper-core.mjs" 1508/*!****************************************************!*\ 1509 !*** ./node_modules/swiper/shared/swiper-core.mjs ***! 1510 \****************************************************/ 1511(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1512 1513"use strict"; 1514eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ S: () => (/* binding */ Swiper),\n/* harmony export */ d: () => (/* binding */ defaults)\n/* harmony export */ });\n/* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./utils.mjs */ \"./node_modules/swiper/shared/utils.mjs\");\n\n\nlet supportCached;\nfunction calcSupport() {\n if (typeof window === 'undefined')\n return { touch: false };\n return {\n touch: 'ontouchstart' in window || navigator.maxTouchPoints > 0,\n };\n}\nfunction getSupport() {\n if (!supportCached)\n supportCached = calcSupport();\n return supportCached;\n}\n\nlet deviceCached;\nfunction calcDevice({ userAgent } = {}) {\n if (typeof window === 'undefined')\n return { ios: false, android: false };
1514\n const support = getSupport();\n const platform = navigator.platform;\n const ua = userAgent || navigator.userAgent;\n const device = { ios: false, android: false };\n const isAndroid = /(Android);?[\\s/]+([\\d.]+)?/.test(ua);\n const isIPhoneOrIPod = /(iPhone\\sOS|iOS|iPod)/.test(ua);\n const isIPadDirect = /iPad/.test(ua);\n // iPad on iPadOS 13+ reports as MacIntel; distinguish from a real Mac by touch capability.\n const isIPadMasquerade = platform === 'MacIntel' && support.touch && navigator.maxTouchPoints > 1;\n const isIPad = isIPadDirect || isIPadMasquerade;\n const isWindows = platform === 'Win32';\n if (isAndroid && !isWindows) {\n device.os = 'android';\n device.android = true;\n }\n if (isIPad || isIPhoneOrIPod) {\n device.os = 'ios';\n device.ios = true;\n }\n return device;\n}\nfunction getDevice(overrides = {}) {\n if (!deviceCached)\n deviceCached = calcDevice(overrides);\n return deviceCached;\n}\n\nlet browserCached;\nfunction calcBrowser() {\n if (typeof window === 'undefined') {\n return { isSafari: false, isWebView: false, need3dFix: false };\n }\n const device = getDevice();\n const ua = navigator.userAgent;\n const uaLower = ua.toLowerCase();\n const isSafari = uaLower.includes('safari') && !uaLower.includes('chrome') && !uaLower.includes('android');\n const isWebView = /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(ua);\n // 3D transform glitches still affect iOS WebView and Safari at the baseline (16.4+).\n const need3dFix = isSafari || (isWebView && device.ios);\n return { isSafari, isWebView, need3dFix };\n}\nfunction getBrowser() {\n if (!browserCached)\n browserCached = calcBrowser();\n return browserCached;\n}\n\nconst processLazyPreloader = (swiper, imageEl) => {\n if (!swiper || swiper.destroyed || !swiper.params)\n return;\n const slideSelector = () => (swiper.isElement ? 'swiper-slide' : `.${swiper.params.slideClass}`);\n const slideEl = imageEl.closest(slideSelector());\n if (slideEl) {\n let lazyEl = slideEl.querySelector(`.${swiper.params.lazyPreloaderClass}`);\n if (!lazyEl && swiper.isElement) {\n if (slideEl.shadowRoot) {\n lazyEl = slideEl.shadowRoot.querySelector(`.${swiper.params.lazyPreloaderClass}`);\n }\n else {\n requestAnimationFrame(() => {\n if (slideEl.shadowRoot) {\n const innerLazy = slideEl.shadowRoot.querySelector(`.${swiper.params.lazyPreloaderClass}`);\n if (innerLazy && !innerLazy.lazyPreloaderManaged)\n innerLazy.remove();\n }\n });\n }\n }\n if (lazyEl && !lazyEl.lazyPreloaderManaged)\n lazyEl.remove();\n }\n};\nconst unlazy = (swiper, index) => {\n if (!swiper.slides[index])\n return;\n const imageEl = swiper.slides[index].querySelector('[loading=\"lazy\"]');\n if (imageEl)\n imageEl.removeAttribute('loading');\n};\nconst preload = (swiper) => {\n if (!swiper || swiper.destroyed || !swiper.params)\n return;\n let amount = swiper.params.lazyPreloadPrevNext;\n const len = swiper.slides.length;\n if (!len || !amount || amount < 0)\n return;\n amount = Math.min(amount, len);\n const slidesPerView = swiper.params.slidesPerView === 'auto'\n ? swiper.slidesPerViewDynamic()\n : Math.ceil(swiper.params.slidesPerView);\n const activeIndex = swiper.activeIndex;\n if (swiper.params.grid && (swiper.params.grid.rows ?? 1) > 1) {\n const activeColumn = activeIndex;\n const preloadColumns = [activeColumn - amount];\n preloadColumns.push(...Array.from({ length: amount }).map((_, i) => activeColumn + slidesPerView + i));\n swiper.slides.forEach((slideEl, i) => {\n if (slideEl.column !== undefined && preloadColumns.includes(slideEl.column))\n unlazy(swiper, i);\n });\n return;\n }\n const slideIndexLastInView = activeIndex + slidesPerView - 1;\n if (swiper.params.rewind || swiper.params.loop) {\n for (let i = activeIndex - amount; i <= slideIndexLastInView + amount; i += 1) {\n const realIndex = ((i % len) + len) % len;\n if (realIndex < activeIndex || realIndex > slideIndexLastInView)\n unlazy(swiper, realIndex);\n }\n }\n else {\n for (let i = Math.max(activeIndex - amount, 0); i <= Math.min(slideIndexLastInView + amount, len - 1); i += 1) {\n if (i !== activeIndex && (i > slideIndexLastInView || i < activeIndex)) {\n unlazy(swiper, i);\n }\n }\n }\n};
1514\n\nfunction getBreakpoint(breakpoints, base = 'window', containerEl) {\n if (!breakpoints || (base === 'container' && !containerEl))\n return undefined;\n let breakpoint = false;\n const currentHeight = base === 'window' ? window.innerHeight : containerEl.clientHeight;\n const points = Object.keys(breakpoints).map((point) => {\n if (typeof point === 'string' && point.indexOf('@') === 0) {\n const minRatio = parseFloat(point.substr(1));\n const value = currentHeight * minRatio;\n return { value, point };\n }\n return { value: point, point };\n });\n points.sort((a, b) => parseInt(String(a.value), 10) - parseInt(String(b.value), 10));\n for (let i = 0; i < points.length; i += 1) {\n const { point, value } = points[i];\n if (base === 'window') {\n if (window.matchMedia(`(min-width: ${value}px)`).matches) {\n breakpoint = point;\n }\n }\n else if (value <= containerEl.clientWidth) {\n breakpoint = point;\n }\n }\n return breakpoint || 'max';\n}\n\nconst isGridEnabled = (swiper, params) => {\n return !!(swiper.grid && params.grid && params.grid.rows > 1);\n};\nfunction setBreakpoint() {\n const swiper = this;\n const { realIndex, initialized, params, el } = swiper;\n const breakpoints = params.breakpoints;\n if (!breakpoints || (breakpoints && Object.keys(breakpoints).length === 0))\n return;\n // Get breakpoint for window/container width and update parameters\n const breakpointsBase = params.breakpointsBase === 'window' || !params.breakpointsBase\n ? params.breakpointsBase\n : 'container';\n const breakpointContainer = ['window', 'container'].includes(params.breakpointsBase) || !params.breakpointsBase\n ? swiper.el\n : document.querySelector(params.breakpointsBase);\n const breakpoint = swiper.getBreakpoint(breakpoints, breakpointsBase, breakpointContainer);\n if (!breakpoint || swiper.currentBreakpoint === breakpoint)\n return;\n const breakpointsRecord = breakpoints;\n const breakpointOnlyParams = breakpoint in breakpointsRecord ? breakpointsRecord[breakpoint] : undefined;\n const breakpointParams = breakpointOnlyParams || swiper.originalParams;\n const wasMultiRow = isGridEnabled(swiper, params);\n const isMultiRow = isGridEnabled(swiper, breakpointParams);\n const wasGrabCursor = swiper.params.grabCursor;\n const isGrabCursor = breakpointParams.grabCursor;\n const wasEnabled = params.enabled;\n if (wasMultiRow && !isMultiRow) {\n el.classList.remove(`${params.containerModifierClass}grid`, `${params.containerModifierClass}grid-column`);\n swiper.emitContainerClasses();\n }\n else if (!wasMultiRow && isMultiRow) {\n el.classList.add(`${params.containerModifierClass}grid`);\n if ((breakpointParams.grid.fill && breakpointParams.grid.fill === 'column') ||\n (!breakpointParams.grid.fill && params.grid.fill === 'column')) {\n el.classList.add(`${params.containerModifierClass}grid-column`);\n }\n swiper.emitContainerClasses();\n }\n if (wasGrabCursor && !isGrabCursor) {\n swiper.unsetGrabCursor();\n }\n else if (!wasGrabCursor && isGrabCursor) {\n swiper.setGrabCursor();\n }\n const moduleOpt = (opts, prop) => opts[prop];\n ['navigation', 'pagination', 'scrollbar'].forEach((prop) => {\n const bpOpts = moduleOpt(breakpointParams, prop);\n if (typeof bpOpts === 'undefined')\n return;\n const paramsOpts = moduleOpt(params, prop);\n const wasModuleEnabled = typeof paramsOpts === 'object' && paramsOpts !== null && paramsOpts.enabled;\n const isModuleEnabled = typeof bpOpts === 'object' && bpOpts !== null && bpOpts.enabled;\n const moduleApi = swiper[prop];\n if (wasModuleEnabled && !isModuleEnabled)\n moduleApi?.disable?.();\n if (!wasModuleEnabled && isModuleEnabled)\n moduleApi?.enable?.();\n });\n const directionChanged = breakpointParams.direction && breakpointParams.direction !== params.direction;\n const needsReLoop = params.loop && (breakpointParams.slidesPerView !== params.slidesPerView || directionChanged);\n const wasLoop = params.loop;\n if (directionChanged && initialized) {\n swiper.changeDirection();\n }\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)(swiper.params, breakpointParams);\n const isEnabled = swiper.params.enabled;\n const hasLoop = swiper.params.loop;\n Object.assign(swiper, {\n allowTouchMove: swiper.params.allowTouchMove,\n allowSlideNext: swiper.params.allowSlideNext,\n allowSlidePrev: swiper.params.allowSlidePrev,\n });\n if (wasEnabled && !isEnabled) {\n swiper.disable();\n }\n else if (!wasEnabled && isEnabled) {\n swiper.enable();\n }\n swiper.currentBreakpoint = breakpoint;\n swiper.emit('_beforeBreakpoint', breakpointParams);\n if (initialized) {\n if (needsReLoop) {\n swiper.loopDestroy();\n swiper.loopCreate(realIndex);\n swiper.updateSlides();\n }\n else if (!wasLoop && hasLoop) {\n swiper.loopCreate(realIndex);\n swiper.updateSlides();\n }\n else if (wasLoop && !hasLoop) {\n swiper.loopDestroy();\n }\n }\n swiper.emit('breakpoint', breakpointParams);\n}
1514\n\nvar breakpoints = { setBreakpoint, getBreakpoint };\n\nfunction checkOverflow() {\n const swiper = this;\n const { isLocked: wasLocked, params } = swiper;\n const { slidesOffsetBefore } = params;\n if (slidesOffsetBefore) {\n const lastSlideIndex = swiper.slides.length - 1;\n const lastSlideRightEdge = swiper.slidesGrid[lastSlideIndex] +\n swiper.slidesSizesGrid[lastSlideIndex] +\n slidesOffsetBefore * 2;\n swiper.isLocked = swiper.size > lastSlideRightEdge;\n }\n else {\n swiper.isLocked = swiper.snapGrid.length === 1;\n }\n if (params.allowSlideNext === true) {\n swiper.allowSlideNext = !swiper.isLocked;\n }\n if (params.allowSlidePrev === true) {\n swiper.allowSlidePrev = !swiper.isLocked;\n }\n if (wasLocked && wasLocked !== swiper.isLocked) {\n swiper.isEnd = false;\n }\n if (wasLocked !== swiper.isLocked) {\n swiper.emit(swiper.isLocked ? 'lock' : 'unlock');\n }\n}\nvar checkOverflow$1 = { checkOverflow };\n\nfunction prepareClasses(entries, prefix) {\n const resultClasses = [];\n entries.forEach((item) => {\n if (typeof item === 'object') {\n Object.keys(item).forEach((classNames) => {\n if (item[classNames]) {\n resultClasses.push(prefix + classNames);\n }\n });\n }\n else if (typeof item === 'string') {\n resultClasses.push(prefix + item);\n }\n });\n return resultClasses;\n}\nfunction addClasses() {\n const swiper = this;\n const { classNames, params, rtl, el, device } = swiper;\n // oxfmt-ignore\n const suffixes = prepareClasses([\n 'initialized',\n params.direction,\n { 'free-mode': swiper.params.freeMode && params.freeMode.enabled },\n { 'autoheight': params.autoHeight },\n { 'rtl': rtl },\n { 'grid': params.grid && params.grid.rows > 1 },\n { 'grid-column': params.grid && params.grid.rows > 1 && params.grid.fill === 'column' },\n { 'android': device.android },\n { 'ios': device.ios },\n { 'css-mode': params.cssMode },\n { 'centered': params.cssMode && params.centeredSlides },\n { 'watch-progress': params.watchSlidesProgress },\n ], params.containerModifierClass);\n classNames.push(...suffixes);\n el.classList.add(...classNames);\n swiper.emitContainerClasses();\n}\n\nfunction removeClasses() {\n const swiper = this;\n const { el, classNames } = swiper;\n if (!el || typeof el === 'string')\n return;\n el.classList.remove(...classNames);\n swiper.emitContainerClasses();\n}\n\nvar classes = { addClasses, removeClasses };\n\nconst defaults = {\n init: true,\n direction: 'horizontal',\n oneWayMovement: false,\n swiperElementNodeName: 'SWIPER-CONTAINER',\n touchEventsTarget: 'wrapper',\n initialSlide: 0,\n speed: 300,\n cssMode: false,\n updateOnWindowResize: true,\n resizeObserver: true,\n nested: false,\n createElements: false,\n eventsPrefix: 'swiper',\n enabled: true,\n focusableElements: 'input, select, option, textarea, button, video, label',\n // Overrides\n width: null,\n height: null,\n //\n preventInteractionOnTransition: false,\n // ssr\n userAgent: null,\n url: null,\n // To support iOS's swipe-to-go-back gesture (when being used in-app).\n edgeSwipeDetection: false,\n edgeSwipeThreshold: 20,\n // Autoheight\n autoHeight: false,\n // Set wrapper width\n setWrapperSize: false,\n // Virtual Translate\n virtualTranslate: false,\n // Effects\n effect: 'slide',\n // Breakp
1514oints\n breakpoints: undefined,\n breakpointsBase: 'window',\n // Slides grid\n spaceBetween: 0,\n slidesPerView: 1,\n slidesPerGroup: 1,\n slidesPerGroupSkip: 0,\n slidesPerGroupAuto: false,\n centeredSlides: false,\n centeredSlidesBounds: false,\n slidesOffsetBefore: 0,\n slidesOffsetAfter: 0,\n normalizeSlideIndex: true,\n centerInsufficientSlides: false,\n snapToSlideEdge: false,\n // Disable swiper and hide navigation when container not overflow\n watchOverflow: true,\n // Round length\n roundLengths: false,\n // Touches\n touchRatio: 1,\n touchAngle: 45,\n simulateTouch: true,\n shortSwipes: true,\n longSwipes: true,\n longSwipesRatio: 0.5,\n longSwipesMs: 300,\n followFinger: true,\n allowTouchMove: true,\n threshold: 5,\n touchMoveStopPropagation: false,\n touchStartPreventDefault: true,\n touchStartForcePreventDefault: false,\n touchReleaseOnEdges: false,\n // Unique Navigation Elements\n uniqueNavElements: true,\n // Resistance\n resistance: true,\n resistanceRatio: 0.85,\n // Progress\n watchSlidesProgress: false,\n // Cursor\n grabCursor: false,\n // Clicks\n preventClicks: true,\n preventClicksPropagation: true,\n slideToClickedSlide: false,\n // loop\n loop: false,\n loopAddBlankSlides: true,\n loopAdditionalSlides: 0,\n loopPreventsSliding: true,\n // rewind\n rewind: false,\n // Swiping/no swiping\n allowSlidePrev: true,\n allowSlideNext: true,\n swipeHandler: null,\n noSwiping: true,\n noSwipingClass: 'swiper-no-swiping',\n noSwipingSelector: null,\n // Passive Listeners\n passiveListeners: true,\n maxBackfaceHiddenSlides: 10,\n // NS\n containerModifierClass: 'swiper-',\n slideClass: 'swiper-slide',\n slideBlankClass: 'swiper-slide-blank',\n slideActiveClass: 'swiper-slide-active',\n slideVisibleClass: 'swiper-slide-visible',\n slideFullyVisibleClass: 'swiper-slide-fully-visible',\n slideNextClass: 'swiper-slide-next',\n slidePrevClass: 'swiper-slide-prev',\n wrapperClass: 'swiper-wrapper',\n lazyPreloaderClass: 'swiper-lazy-preloader',\n lazyPreloadPrevNext: 0,\n // Callbacks\n runCallbacksOnInit: true,\n // Internals\n _emitClasses: false,\n};\n\nvar eventsEmitter = {\n on(events, handler, priority) {\n const self = this;\n if (!self.eventsListeners || self.destroyed)\n return self;\n if (typeof handler !== 'function')\n return self;\n const method = priority ? 'unshift' : 'push';\n events.split(' ').forEach((event) => {\n if (!self.eventsListeners[event])\n self.eventsListeners[event] = [];\n self.eventsListeners[event][method](handler);\n });\n return self;\n },\n once(events, handler, priority) {\n const self = this;\n if (!self.eventsListeners || self.destroyed)\n return self;\n if (typeof handler !== 'function')\n return self;\n const onceHandler = function onceHandlerFn(...args) {\n self.off(events, onceHandler);\n if (onceHandler.__emitterProxy) {\n delete onceHandler.__emitterProxy;\n }\n handler.apply(self, args);\n };\n onceHandler.__emitterProxy = handler;\n return self.on(events, onceHandler, priority);\n },\n onAny(handler, priority) {\n const self = this;\n if (!self.eventsListeners || self.destroyed)\n return self;\n if (typeof handler !== 'function')\n return self;\n const method = priority ? 'unshift' : 'push';\n if (self.eventsAnyListeners.indexOf(handler) < 0) {\n self.eventsAnyListeners[method](handler);\n }\n return self;\n },\n offAny(handler) {\n const self = this;\n if (!self.eventsListeners || self.destroyed)\n return self;\n if (!self.eventsAnyListeners)\n return self;\n const index = self.eventsAnyListeners.indexOf(handler);\n if (index >= 0) {\n self.eventsAnyListeners.splice(index, 1);\n }\n return self;\n },\n off(events, handler) {\n const self = this;\n if (!self.eventsListeners || self.destroyed)\n return self;\n if (!self.eventsListeners)\n return self;\n events.split(' ').forEach((event) => {\n if (typeof handler === 'undefined') {\n self.eventsListeners[event] = [];\n }\n else if (self.eventsListeners[event]) {\n self.eventsListeners[event].forEach((eventHandler, index) =>
1514 {\n if (eventHandler === handler ||\n (eventHandler.__emitterProxy && eventHandler.__emitterProxy === handler)) {\n self.eventsListeners[event].splice(index, 1);\n }\n });\n }\n });\n return self;\n },\n emit(...args) {\n const self = this;\n if (!self.eventsListeners || self.destroyed)\n return self;\n if (!self.eventsListeners)\n return self;\n let events;\n let data;\n let context;\n if (typeof args[0] === 'string' || Array.isArray(args[0])) {\n events = args[0];\n data = args.slice(1, args.length);\n context = self;\n }\n else {\n const opts = args[0];\n events = opts.events;\n data = opts.data ?? [];\n context = opts.context || self;\n }\n data.unshift(context);\n const eventsArray = Array.isArray(events) ? events : events.split(' ');\n eventsArray.forEach((event) => {\n if (self.eventsAnyListeners && self.eventsAnyListeners.length) {\n self.eventsAnyListeners.forEach((eventHandler) => {\n eventHandler.apply(context, [event, ...data]);\n });\n }\n if (self.eventsListeners && self.eventsListeners[event]) {\n self.eventsListeners[event].forEach((eventHandler) => {\n eventHandler.apply(context, data);\n });\n }\n });\n return self;\n },\n};\n\nfunction onClick(e) {\n const swiper = this;\n if (swiper.destroyed)\n return;\n if (!swiper.enabled)\n return;\n if (!swiper.allowClick) {\n if (swiper.params.preventClicks)\n e.preventDefault();\n if (swiper.params.preventClicksPropagation && swiper.animating) {\n e.stopPropagation();\n e.stopImmediatePropagation();\n }\n }\n}\n\nfunction onDocumentTouchStart() {\n const swiper = this;\n if (swiper.destroyed)\n return;\n if (swiper.documentTouchHandlerProceeded)\n return;\n swiper.documentTouchHandlerProceeded = true;\n if (swiper.params.touchReleaseOnEdges) {\n swiper.el.style.touchAction = 'auto';\n }\n}\n\nfunction onLoad(e) {\n const swiper = this;\n if (swiper.destroyed)\n return;\n processLazyPreloader(swiper, e.target);\n if (swiper.params.cssMode ||\n (swiper.params.slidesPerView !== 'auto' && !swiper.params.autoHeight)) {\n return;\n }\n swiper.update();\n}\n\nfunction onResize() {\n const swiper = this;\n const { params, el } = swiper;\n if (el && el.offsetWidth === 0)\n return;
1514\n // Breakpoints\n if (params.breakpoints) {\n swiper.setBreakpoint();\n }\n // Save locks\n const { allowSlideNext, allowSlidePrev, snapGrid } = swiper;\n const isVirtual = swiper.virtual && swiper.params.virtual?.enabled;\n // Disable locks on resize\n swiper.allowSlideNext = true;\n swiper.allowSlidePrev = true;\n swiper.updateSize();\n swiper.updateSlides();\n swiper.updateSlidesClasses();\n const isVirtualLoop = isVirtual && params.loop;\n if ((params.slidesPerView === 'auto' || params.slidesPerView > 1) &&\n swiper.isEnd &&\n !swiper.isBeginning &&\n !swiper.params.centeredSlides &&\n !isVirtualLoop) {\n const slidesLength = isVirtual ? swiper.virtual.slides.length : swiper.slides.length;\n swiper.slideTo(slidesLength - 1, 0, false, true);\n }\n else {\n if (swiper.params.loop && !isVirtual) {\n swiper.slideToLoop(swiper.realIndex, 0, false, true);\n }\n else {\n swiper.slideTo(swiper.activeIndex, 0, false, true);\n }\n }\n if (swiper.autoplay && swiper.autoplay.running && swiper.autoplay.paused) {\n const autoplay = swiper.autoplay;\n clearTimeout(autoplay.resizeTimeout);\n autoplay.resizeTimeout = setTimeout(() => {\n if (swiper.autoplay && swiper.autoplay.running && swiper.autoplay.paused) {\n swiper.autoplay.resume();\n }\n }, 500);\n }\n // Return locks after resize\n swiper.allowSlidePrev = allowSlidePrev;\n swiper.allowSlideNext = allowSlideNext;\n if (swiper.params.watchOverflow && snapGrid !== swiper.snapGrid) {\n swiper.checkOverflow();\n }\n}\n\nfunction onScroll() {\n const swiper = this;\n if (swiper.destroyed)\n return;\n const { wrapperEl, rtlTranslate, enabled } = swiper;\n if (!enabled)\n return;\n swiper.previousTranslate = swiper.translate;\n if (swiper.isHorizontal()) {\n swiper.translate = -wrapperEl.scrollLeft;\n }\n else {\n swiper.translate = -wrapperEl.scrollTop;\n }\n if (swiper.translate === 0)\n swiper.translate = 0;\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n let newProgress;\n const translatesDiff = swiper.maxTranslate() - swiper.minTranslate();\n if (translatesDiff === 0) {\n newProgress = 0;\n }\n else {\n newProgress = (swiper.translate - swiper.minTranslate()) / translatesDiff;\n }\n if (newProgress !== swiper.progress) {\n swiper.updateProgress(rtlTranslate ? -swiper.translate : swiper.translate);\n }\n swiper.emit('setTranslate', swiper.translate, false);\n}\n\nfunction onTouchEnd(event) {\n const swiper = this;\n if (swiper.destroyed)\n return;\n const data = swiper.touchEventsData;\n let e = event.originalEvent ?? event;\n const isTouchEvent = e.type === 'touchend' || e.type === 'touchcancel';\n if (!isTouchEvent) {\n if (data.touchId !== null)\n return; // return from pointer if we use touch\n const pe = e;\n if (pe.pointerId !== data.pointerId)\n return;\n }\n else {\n const te = e;\n const found = [...te.changedTouches].find((t) => t.identifier === data.touchId);\n if (!found || found.identifier !== data.touchId)\n return;\n }\n if (['pointercancel', 'pointerout', 'pointerleave', 'contextmenu'].includes(e.type)) {\n const proceed = ['pointercancel', 'contextmenu'].includes(e.type) &&\n (swiper.browser.isSafari || swiper.browser.isWebView);\n if (!proceed) {\n return;\n }\n }\n data.pointerId = null;\n data.touchId = null;\n const { params, touches, rtlTranslate: rtl, slidesGrid, enabled } = swiper;\n if (!enabled)\n return;\n if (!params.simulateTouch && e.pointerType === 'mouse')\n return;\n if (data.allowTouchCallbacks) {\n swiper.emit('touchEnd', e);\n }\n data.allowTouchCallbacks = false;\n if (!data.isTouched) {\n if (data.isMoved && params.grabCursor) {\n swiper.setGrabCursor(false);\n }\n data.isMoved = false;\n data.startMoving = false;\n return;\n }\n // Return Grab Cursor\n if (params.grabCursor &&\n data.isMoved &&\n data.isTouched &&\n (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) {\n swiper.setGrabCursor(false);\n }\n // Time diff\n const touchEndTime = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)();\n const timeDiff = touchEndTime - data.touchStartTime;
1514\n // Tap, doubleTap, Click\n if (swiper.allowClick) {\n // Legacy `e.path` was a non-standard Chrome extension; `composedPath()` is the modern API.\n const pathTree = e.path ?? (e.composedPath && e.composedPath());\n swiper.updateClickedSlide((pathTree && pathTree[0]), pathTree);\n swiper.emit('tap click', e);\n if (timeDiff < 300 && touchEndTime - data.lastClickTime < 300) {\n swiper.emit('doubleTap doubleClick', e);\n }\n }\n data.lastClickTime = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)();\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.t)(() => {\n if (!swiper.destroyed)\n swiper.allowClick = true;\n });\n if (!data.isTouched ||\n !data.isMoved ||\n !swiper.swipeDirection ||\n (touches.diff === 0 && !data.loopSwapReset) ||\n (data.currentTranslate === data.startTranslate && !data.loopSwapReset)) {\n data.isTouched = false;\n data.isMoved = false;\n data.startMoving = false;\n return;\n }\n data.isTouched = false;\n data.isMoved = false;\n data.startMoving = false;\n let currentPos;\n if (params.followFinger) {\n currentPos = rtl ? swiper.translate : -swiper.translate;\n }\n else {\n currentPos = -(data.currentTranslate ?? 0);\n }\n if (params.cssMode) {\n return;\n }\n if (params.freeMode && params.freeMode.enabled) {\n swiper.freeMode.onTouchEnd({ currentPos });\n return;\n }\n // Find current slide\n const swipeToLast = currentPos >= -swiper.maxTranslate() && !swiper.params.loop;\n let stopIndex = 0;\n let groupSize = swiper.slidesSizesGrid[0];\n for (let i = 0; i < slidesGrid.length; i += i < params.slidesPerGroupSkip ? 1 : params.slidesPerGroup) {\n const increment = i < params.slidesPerGroupSkip - 1 ? 1 : params.slidesPerGroup;\n if (typeof slidesGrid[i + increment] !== 'undefined') {\n if (swipeToLast ||\n (currentPos >= slidesGrid[i] && currentPos < slidesGrid[i + increment])) {\n stopIndex = i;\n groupSize = slidesGrid[i + increment] - slidesGrid[i];\n }\n }\n else if (swipeToLast || currentPos >= slidesGrid[i]) {\n stopIndex = i;\n groupSize = slidesGrid[slidesGrid.length - 1] - slidesGrid[slidesGrid.length - 2];\n }\n }\n let rewindFirstIndex = null;\n let rewindLastIndex = null;\n if (params.rewind) {\n if (swiper.isBeginning) {\n rewindLastIndex =\n params.virtual?.enabled && swiper.virtual\n ? swiper.virtual.slides.length - 1\n : swiper.slides.length - 1;\n }\n else if (swiper.isEnd) {\n rewindFirstIndex = 0;\n }\n }\n // Find current slide size\n const ratio = (currentPos - slidesGrid[stopIndex]) / groupSize;\n const increment = stopIndex < params.slidesPerGroupSkip - 1 ? 1 : params.slidesPerGroup;\n if (timeDiff > params.longSwipesMs) {\n // Long touches\n if (!params.longSwipes) {\n swiper.slideTo(swiper.activeIndex);\n return;\n }\n if (swiper.swipeDirection === 'next') {\n if (ratio >= params.longSwipesRatio)\n swiper.slideTo(params.rewind && swiper.isEnd ? rewindFirstIndex : stopIndex + increment);\n else\n swiper.slideTo(stopIndex);\n }\n if (swiper.swipeDirection === 'prev') {\n if (ratio > 1 - params.longSwipesRatio) {\n swiper.slideTo(stopIndex + increment);\n }\n else if (rewindLastIndex !== null &&\n ratio < 0 &&\n Math.abs(ratio) > params.longSwipesRatio) {\n swiper.slideTo(rewindLastIndex);\n }\n else {\n swiper.slideTo(stopIndex);\n }\n }\n }\n else {\n // Short swipes\n if (!params.shortSwipes) {\n swiper.slideTo(swiper.activeIndex);\n return;\n }\n const isNavButtonTarget = swiper.navigation &&\n (e.target === swiper.navigation.nextEl || e.target === swiper.navigation.prevEl);\n if (!isNavButtonTarget) {\n if (swiper.swipeDirection === 'next') {\n swiper.slideTo(rewindFirstIndex !== null ? rewindFirstIndex : stopIndex + increment);\n }\n if (swiper.swipeDirection === 'prev') {\n swiper.slideTo(rewindLastIndex !== null ? rewindLastIndex : stopIndex);\n }\n }\n else if (e.target === swiper.navigation.nextEl) {\n swiper.slideTo(stopIndex + increment);\n }\n else {\n swiper.slideTo(stopIndex);\n }\n }\n}\n\nfunction onTouchMove(event) {\n const swiper = this;\n if (swiper.destroyed)\n return;\n const data = swiper.touchEventsData;\n const { params, touches, rtlTranslate: rtl, enabled } = swiper;\n if (!enabled)\n return;\n if (!params.simulateTouch && event.pointerType === 'mouse')\n return;\n // Legacy event wrappers nest the native event under .originalEvent.\n const wrapped = event;\n const e = wrapped.originalEvent ?? wrapped;\n if (e.type === 'pointermove') {\n if (data.touchId !== null)\n return; // return from pointer if we use touch\n const pe = e;\n if (pe.pointerId !== data.pointerId)\n return;\n }\n let targetTouch;\n if (e.type === 'touchmove') {\n const te = e;\n const found = [...te.changedTouches].find((t) => t.identifier === data.touchId);\n if (!found || found.identifier !== data.touchId)\n return;\n targetTouch = found;\n }\n else {\n targetTouch = e;
1514\n }\n if (!data.isTouched) {\n if (data.startMoving && data.isScrolling) {\n swiper.emit('touchMoveOpposite', e);\n }\n return;\n }\n const pageX = targetTouch.pageX;\n const pageY = targetTouch.pageY;\n if (e.preventedByNestedSwiper) {\n touches.startX = pageX;\n touches.startY = pageY;\n return;\n }\n if (!swiper.allowTouchMove) {\n if (!e.target.matches(data.focusableElements)) {\n swiper.allowClick = false;\n }\n if (data.isTouched) {\n Object.assign(touches, {\n startX: pageX,\n startY: pageY,\n currentX: pageX,\n currentY: pageY,\n });\n data.touchStartTime = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)();\n }\n return;\n }\n if (params.touchReleaseOnEdges && !params.loop) {\n if (swiper.isVertical()) {\n // Vertical\n if ((pageY < touches.startY && swiper.translate <= swiper.maxTranslate()) ||\n (pageY > touches.startY && swiper.translate >= swiper.minTranslate())) {\n data.isTouched = false;\n data.isMoved = false;\n return;\n }\n }\n else if (rtl &&\n ((pageX > touches.startX && -swiper.translate <= swiper.maxTranslate()) ||\n (pageX < touches.startX && -swiper.translate >= swiper.minTranslate()))) {\n return;\n }\n else if (!rtl &&\n ((pageX < touches.startX && swiper.translate <= swiper.maxTranslate()) ||\n (pageX > touches.startX && swiper.translate >= swiper.minTranslate()))) {\n return;\n }\n }\n if (document.activeElement &&\n document.activeElement.matches(data.focusableElements) &&\n document.activeElement !== e.target &&\n e.pointerType !== 'mouse') {\n document.activeElement.blur();\n }\n if (document.activeElement) {\n if (e.target === document.activeElement &&\n e.target.matches(data.focusableElements)) {\n data.isMoved = true;\n swiper.allowClick = false;\n return;\n }\n }\n if (data.allowTouchCallbacks) {\n swiper.emit('touchMove', e);\n }\n touches.previousX = touches.currentX;\n touches.previousY = touches.currentY;\n touches.currentX = pageX;\n touches.currentY = pageY;\n const diffX = touches.currentX - touches.startX;\n const diffY = touches.currentY - touches.startY;\n if (swiper.params.threshold && Math.sqrt(diffX ** 2 + diffY ** 2) < swiper.params.threshold)\n return;\n if (typeof data.isScrolling === 'undefined') {\n let touchAngle;\n if ((swiper.isHorizontal() && touches.currentY === touches.startY) ||\n (swiper.isVertical() && touches.currentX === touches.startX)) {\n data.isScrolling = false;\n }\n else {\n if (diffX * diffX + diffY * diffY >= 25) {\n touchAngle = (Math.atan2(Math.abs(diffY), Math.abs(diffX)) * 180) / Math.PI;\n data.isScrolling = swiper.isHorizontal()\n ? touchAngle > params.touchAngle\n : 90 - touchAngle > params.touchAngle;\n }\n }\n }\n if (data.isScrolling) {\n swiper.emit('touchMoveOpposite', e);\n }\n if (typeof data.startMoving === 'undefined') {\n if (touches.currentX !== touches.startX || touches.currentY !== touches.startY) {\n data.startMoving = true;\n }\n }\n if (data.isScrolling || (e.type === 'touchmove' && data.preventTouchMoveFromPointerMove)) {\n data.isTouched = false;\n return;\n }\n if (!data.startMoving) {\n return;\n }\n swiper.allowClick = false;\n if (!params.cssMode && e.cancelable) {\n e.preventDefault();\n }\n if (params.touchMoveStopPropagation && !params.nested) {\n e.stopPropagation();\n }\n let diff = swiper.isHorizontal() ? diffX : diffY;\n let touchesDiff = swiper.isHorizontal()\n ? touches.currentX - touches.previousX\n : touches.currentY - touches.previousY;\n if (params.oneWayMovement) {\n diff = Math.abs(diff) * (rtl ? 1 : -1);\n touchesDiff = Math.abs(touchesDiff) * (rtl ? 1 : -1);\n }\n touches.diff = diff;\n diff *= params.touchRatio;\n if (rtl) {\n diff = -diff;\n touchesDiff = -touchesDiff;\n }\n const prevTouchesDirection = swiper.touchesDirection;\n swiper.swipeDirection = diff > 0 ? 'prev' : 'next';\n swiper.touchesDirection = touchesDiff > 0 ? 'prev' : 'next';\n const isLoop = swiper.params.loop && !params.cssMode;\n const allowLoopFix = (swiper.touchesDirection === 'next' && swiper.allowSlideNext) ||\n (swiper.touchesDirection === 'prev' && swiper.allowSlidePrev);\n if (!data.isMoved) {\n if (isLoop && allowLoopFix) {\n swiper.loopFix({ direction: swiper.swipeDirection });\n }\n data.startTranslate = swiper.getTranslate();\n swiper.setTransition(0);\n if (swiper.animating) {\n const evt = new window.CustomEvent('transitionend', {\n bubbles: true,\n cancelable: true,\n detail: {\n bySwiperTouchMove: true,\n },\n });
1514\n swiper.wrapperEl.dispatchEvent(evt);\n }\n data.allowMomentumBounce = false;\n // Grab Cursor\n if (params.grabCursor && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) {\n swiper.setGrabCursor(true);\n }\n swiper.emit('sliderFirstMove', e);\n }\n new Date().getTime();\n if (params._loopSwapReset !== false &&\n data.isMoved &&\n data.allowThresholdMove &&\n prevTouchesDirection !== swiper.touchesDirection &&\n isLoop &&\n allowLoopFix &&\n Math.abs(diff) >= 1) {\n Object.assign(touches, {\n startX: pageX,\n startY: pageY,\n currentX: pageX,\n currentY: pageY,\n startTranslate: data.currentTranslate,\n });\n data.loopSwapReset = true;\n data.startTranslate = data.currentTranslate;\n return;\n }\n swiper.emit('sliderMove', e);\n data.isMoved = true;\n // startTranslate is guaranteed to be set by this point (set in onTouchStart-side init).\n const startTranslate = data.startTranslate ?? 0;\n data.currentTranslate = diff + startTranslate;\n let disableParentSwiper = true;\n let resistanceRatio = params.resistanceRatio;\n if (params.touchReleaseOnEdges) {\n resistanceRatio = 0;\n }\n if (diff > 0) {\n if (isLoop &&\n allowLoopFix &&\n true &&\n data.allowThresholdMove &&\n data.currentTranslate >\n (params.centeredSlides\n ? swiper.minTranslate() -\n swiper.slidesSizesGrid[swiper.activeIndex + 1] -\n (params.slidesPerView !== 'auto' &&\n swiper.slides.length - params.slidesPerView >= 2\n ? swiper.slidesSizesGrid[swiper.activeIndex + 1] +\n swiper.params.spaceBetween\n : 0) -\n swiper.params.spaceBetween\n : swiper.minTranslate())) {\n swiper.loopFix({ direction: 'prev', setTranslate: true, activeSlideIndex: 0 });\n }\n if (data.currentTranslate > swiper.minTranslate()) {\n disableParentSwiper = false;\n if (params.resistance) {\n data.currentTranslate =\n swiper.minTranslate() -\n 1 +\n (-swiper.minTranslate() + startTranslate + diff) ** resistanceRatio;\n }\n }\n }\n else if (diff < 0) {\n if (isLoop &&\n allowLoopFix &&\n true &&\n data.allowThresholdMove &&\n data.currentTranslate <\n (params.centeredSlides\n ? swiper.maxTranslate() +\n swiper.slidesSizesGrid[swiper.slidesSizesGrid.length - 1] +\n swiper.params.spaceBetween +\n (params.slidesPerView !== 'auto' &&\n swiper.slides.length - params.slidesPerView >= 2\n ? swiper.slidesSizesGrid[swiper.slidesSizesGrid.length - 1] +\n swiper.params.spaceBetween\n : 0)\n : swiper.maxTranslate())) {\n swiper.loopFix({\n direction: 'next',\n setTranslate: true,\n activeSlideIndex: swiper.slides.length -\n (params.slidesPerView === 'auto'\n ? swiper.slidesPerViewDynamic()\n : Math.ceil(parseFloat(String(params.slidesPerView)))),\n });\n }\n if (data.currentTranslate < swiper.maxTranslate()) {\n disableParentSwiper = false;\n if (params.resistance) {\n data.currentTranslate =\n swiper.maxTranslate() +\n 1 -\n (swiper.maxTranslate() - startTranslate - diff) ** resistanceRatio;\n }\n }\n }\n if (disableParentSwiper) {\n e.preventedByNestedSwiper = true;\n }\n // Directions locks\n if (!swiper.allowSlideNext &&\n swiper.swipeDirection === 'next' &&\n (data.currentTranslate ?? 0) < startTranslate) {\n data.currentTranslate = startTranslate;\n }\n if (!swiper.allowSlidePrev &&\n swiper.swipeDirection === 'prev' &&\n (data.currentTranslate ?? 0) > startTranslate) {\n data.currentTranslate = startTranslate;\n }\n if (!swiper.allowSlidePrev && !swiper.allowSlideNext) {\n data.currentTranslate = startTranslate;\n }\n // Threshold\n if (params.threshold > 0) {\n if (Math.abs(diff) > params.threshold || data.allowThresholdMove) {\n if (!data.allowThresholdMove) {\n data.allowThresholdMove = true;\n touches.startX = touches.currentX;\n touches.startY = touches.currentY;\n data.currentTranslate = data.startTranslate;\n touches.diff = swiper.isHorizontal()\n ? touches.currentX - touches.startX\n : touches.currentY - touches.startY;\n return;\n }\n }\n else {\n data.currentTranslate = data.startTranslate;\n return;\n }\n }\n if (!params.followFinger || params.cssMode)\n return;\n // Update active index in free mode\n if ((params.freeMode && params.freeMode.enabled && swiper.freeMode) ||\n params.watchSlidesProgress) {\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n }\n if (params.freeMode && params.freeMode.enabled && swiper.freeMode) {\n swiper.freeMode.onTouchMove();\n }\n // Update progress\n swiper.updateProgress(data.currentTranslate);\n // Update translate\n swiper.setTranslate(data.currentTranslate ?? 0);\n}\n\n// Modified from https://stackoverflow.com/questions/54520554/custom-element-getrootnode-closest-function-crossing-multiple-parent-shadowd\nfunction closestElement(selector, base) {\n function __closestFrom(el) {\n if (!el || el === document || el === window)\n return null;\n let cur = el;\n if (cur.assignedSlot)\n cur = cur.assignedSlot;\n const found = cur.closest(selector);\n if (!found && !cur.getRootNode) {\n return null;\n }\n const root = cur.getRootNode();\n return found || __closestFrom(root.host);\n }\n return __closestFrom(base);\n}\nfunction preventEdgeSwipe(swiper, event, startX) {\n const { params } = swiper;\n const edgeSwipeDetection = params.edgeSwipeDetection;\n const edgeSwipeThreshold = params.edgeSwipeThreshold;\n if (edgeSwipeDetection &&\n (startX <= edgeSwipeThreshold || startX >= window.innerWidth - edgeSwipeThreshold)) {\n if (edgeSwipeDetection === 'prevent') {\n event.preventDefault();\n return true;\n }\n return false;\n }\n return true;\n}\nfunction onTouchStart(event) {\n const swiper = this;\n if (swiper.destroyed)\n return;\n const e = event.originalEvent ?? event;\n const data = swiper.touchEventsData;\n if (e.type === 'pointerdown') {\n const pe = e;\n if (data.pointerId !== null && data.pointerId !== pe.pointerId) {\n return;\n }\n data.pointerId = pe.pointerId;\n }\n else if (e.type === 'touchstart' && e.targetTouches.length === 1) {\n data.touchId = e.targetTouches[0].identifier;\n }\n if (e.type === 'touchstart') {\n // don't proceed touch event\n preventEdgeSwipe(swiper, e, e.targetTouches[0].pageX);\n return;\n }\n const { params, touches, enabled } = swiper;\n if (!enabled)\n return;\n if (!params.simulateTouch && e.pointerType === 'mouse')\n return;\n if (swiper.animating && params.preventInteractionOnTransition) {\n return;\n }\n if (!swiper.animating && params.cssMode && params.loop) {\n swiper.loopFix();\n }\n let targetEl = e.target;\n if (params.touchEventsTarget === 'wrapper') {\n if (!(0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.f)(targetEl, swiper.wrapperEl))\n return;\n }\n // Secondary mouse buttons (right-click / middle-click) shouldn't start a swipe.\n const mouseLike = e;\n if (typeof mouseLike.which === 'number' && mouseLike.which === 3)\n return;\n if (typeof mouseLike.button === 'number' && mouseLike.button > 0)\n return;\n if (data.isTouched && data.isMoved)\n return;\n // change target el for shadow root component\n const swipingClassHasValue = !!params.noSwipingClass && params.noSwipingClass !== '';\n // `path` is a non-standard Chrome extension; `composedPath()` is the modern API.\n const eventPath = e.composedPath\n ? e.composedPath()\n : e.path;\n if (swipingClassHasValue &&\n e.target &&\n e.target.shadowRoot &&\n eventPath) {\n targetEl = eventPath[0];\n }\n const noSwipingSelector = params.noSwipingSelector\n ? params.noSwipingSelector\n : `.${params.noSwipingClass}`;\n const isTargetShadow = !!(e.target && e.target.shadowRoot);\n // use closestElement for shadow root element to get the actual closest for nested shadow root element\n if (params.noSwiping &&\
1514n (isTargetShadow\n ? closestElement(noSwipingSelector, targetEl)\n : targetEl.closest(noSwipingSelector))) {\n swiper.allowClick = true;\n return;\n }\n if (params.swipeHandler) {\n if (typeof params.swipeHandler === 'string' && !targetEl.closest(params.swipeHandler))\n return;\n }\n // At this point `e` is a PointerEvent or MouseEvent (touchstart returned earlier).\n const pe = e;\n touches.currentX = pe.pageX;\n touches.currentY = pe.pageY;\n const startX = touches.currentX;\n const startY = touches.currentY;\n // Do NOT start if iOS edge swipe is detected. Otherwise iOS app cannot swipe-to-go-back anymore\n if (!preventEdgeSwipe(swiper, e, startX)) {\n return;\n }\n Object.assign(data, {\n isTouched: true,\n isMoved: false,\n allowTouchCallbacks: true,\n isScrolling: undefined,\n startMoving: undefined,\n });\n touches.startX = startX;\n touches.startY = startY;\n data.touchStartTime = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.u)();\n swiper.allowClick = true;\n swiper.updateSize();\n swiper.swipeDirection = undefined;\n if (params.threshold > 0)\n data.allowThresholdMove = false;\n let preventDefault = true;\n if (targetEl.matches(data.focusableElements)) {\n preventDefault = false;\n if (targetEl.nodeName === 'SELECT') {\n data.isTouched = false;\n }\n }\n if (document.activeElement &&\n document.activeElement.matches(data.focusableElements) &&\n document.activeElement !== targetEl &&\n (pe.pointerType === 'mouse' ||\n (pe.pointerType !== 'mouse' && !targetEl.matches(data.focusableElements)))) {\n document.activeElement.blur();\n }\n const shouldPreventDefault = preventDefault && swiper.allowTouchMove && params.touchStartPreventDefault;\n if ((params.touchStartForcePreventDefault || shouldPreventDefault) &&\n !targetEl.isContentEditable) {\n e.preventDefault();\n }\n if (params.freeMode &&\n params.freeMode.enabled &&\n swiper.freeMode &&\n swiper.animating &&\n !params.cssMode) {\n swiper.freeMode.onTouchStart();\n }\n swiper.emit('touchStart', e);\n}\n\nconst events = (swiper, method) => {\n const { params, el, wrapperEl, device } = swiper;\n const capture = !!params.nested;\n const domMethod = method === 'on' ? 'addEventListener' : 'removeEventListener';\n const swiperMethod = method;\n if (!el || typeof el === 'string')\n return;\n // Touch Events\n document[domMethod]('touchstart', swiper.onDocumentTouchStart, {\n passive: false,\n capture,\n });\n el[domMethod]('touchstart', swiper.onTouchStart, { passive: false });\n el[domMethod]('pointerdown', swiper.onTouchStart, { passive: false });\n document[domMethod]('touchmove', swiper.onTouchMove, {\n passive: false,\n capture,\n });\n document[domMethod]('pointermove', swiper.onTouchMove, {\n passive: false,\n capture,\n });\n document[domMethod]('touchend', swiper.onTouchEnd, { passive: true });\n document[domMethod]('pointerup', swiper.onTouchEnd, { passive: true });\n document[domMethod]('pointercancel', swiper.onTouchEnd, { passive: true });\n document[domMethod]('touchcancel', swiper.onTouchEnd, { passive: true });\n document[domMethod]('pointerout', swiper.onTouchEnd, { passive: true });\n document[domMethod]('pointerleave', swiper.onTouchEnd, { passive: true });\n document[domMethod]('contextmenu', swiper.onTouchEnd, { passive: true });\n // Prevent Links Clicks\n if (params.preventClicks || params.preventClicksPropagation) {\n el[domMethod]('click', swiper.onClick, true);\n }\n if (params.cssMode) {\n wrapperEl[domMethod]('scroll', swiper.onScroll);\n }\n // Resize handler\n const subscribe = (events) => {\n swiper[swiperMethod](events, onResize, true);\n };\n if (params.updateOnWindowResize) {\n subscribe(device.ios || device.android\n ? 'resize orientationchange observerUpdate'\n : 'resize observerUpdate');\n }\n else {\n subscribe('observerUpdate');\n }\n // Images loader\n el[domMethod]('load', swiper.onLoad, { capture: true });\n};\nfunction attachEvents() {\n const swiper = this;\n const { params } = swiper;\n swiper.onTouchStart = onTouchStart.bind(swiper);\n swiper.onTouchMove = onTouchMove.bind(swiper);\n swiper.onTouchEnd = onTouchEnd.bind(swiper);\n swiper.onDocumentTouchStart = onDocumentTouchStart.bind(swiper);\n if (params.cssMode) {\n swiper.onScroll = onScroll.bind(swiper);\n }\n swiper.onClick = onClick.bind(swiper);\n swiper.onLoad = onLoad.bind(swiper);\n events(swiper, 'on');\n}\nfunction detachEvents() {\n const swiper = this;\n events(swiper, 'off');\n}\nvar events$1 = {\n attachEvents,\n detachEvents,\n};\n\nfunction setGrabCursor(moving) {\n const swiper = this;\n if (!swiper.params.simulateTouch ||\n (swiper.params.watchOverflow && swiper.isLocked) ||\n swiper.params.cssMode)\n return;\n const el = swiper.params.touchEventsTarget === 'container' ? swiper.el : swiper.wrapperEl;\n if (swiper.isElement) {\n swiper.__preventObserver__ = true;\n }\n el.style.cursor = 'move';\n el.style.cursor = moving ? 'grabbing' : 'grab';\n if (swiper.isElement) {\n requestAnimationFrame(() =>
1514 {\n swiper.__preventObserver__ = false;\n });\n }\n}\n\nfunction unsetGrabCursor() {\n const swiper = this;\n if ((swiper.params.watchOverflow && swiper.isLocked) || swiper.params.cssMode) {\n return;\n }\n if (swiper.isElement) {\n swiper.__preventObserver__ = true;\n }\n swiper[swiper.params.touchEventsTarget === 'container' ? 'el' : 'wrapperEl'].style.cursor = '';\n if (swiper.isElement) {\n requestAnimationFrame(() => {\n swiper.__preventObserver__ = false;\n });\n }\n}\n\nvar grabCursor = {\n setGrabCursor,\n unsetGrabCursor,\n};\n\nfunction loopCreate(slideRealIndex, initial) {\n const swiper = this;\n const { params, slidesEl } = swiper;\n if (!params.loop || (swiper.virtual && swiper.params.virtual?.enabled))\n return;\n const initSlides = () => {\n const slides = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(slidesEl, `.${params.slideClass}, swiper-slide`);\n slides.forEach((el, index) => {\n el.setAttribute('data-swiper-slide-index', String(index));\n });\n };\n const clearBlankSlides = () => {\n const slides = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(slidesEl, `.${params.slideBlankClass}`);\n slides.forEach((el) => {\n el.remove();\n });\n if (slides.length > 0) {\n swiper.recalcSlides();\n swiper.updateSlides();\n }\n };\n const gridEnabled = swiper.grid && params.grid && params.grid.rows > 1;\n if (params.loopAddBlankSlides && (params.slidesPerGroup > 1 || gridEnabled)) {\n clearBlankSlides();\n }\n const slidesPerGroup = params.slidesPerGroup * (gridEnabled ? params.grid.rows : 1);\n const shouldFillGroup = swiper.slides.length % slidesPerGroup !== 0;\n const shouldFillGrid = gridEnabled && swiper.slides.length % params.grid.rows !== 0;\n const addBlankSlides = (amountOfSlides) => {\n for (let i = 0; i < amountOfSlides; i += 1) {\n const slideEl = swiper.isElement\n ? (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.a)('swiper-slide', [params.slideBlankClass])\n : (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.a)('div', [params.slideClass, params.slideBlankClass]);\n swiper.slidesEl.append(slideEl);\n }\n };\n if (shouldFillGroup) {\n if (params.loopAddBlankSlides) {\n const slidesToAdd = slidesPerGroup - (swiper.slides.length % slidesPerGroup);\n addBlankSlides(slidesToAdd);\n swiper.recalcSlides();\n swiper.updateSlides();\n }\n else {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.x)('Swiper Loop Warning: The number of slides is not even to slidesPerGroup, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)');\n }\n initSlides();\n }\n else if (shouldFillGrid) {\n if (params.loopAddBlankSlides) {\n const slidesToAdd = params.grid.rows - (swiper.slides.length % params.grid.rows);\n addBlankSlides(slidesToAdd);\n swiper.recalcSlides();\n swiper.updateSlides();\n }\n else {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.x)('Swiper Loop Warning: The number of slides is not even to grid.rows, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)');\n }\n initSlides();\n }\n else {\n initSlides();\n }\n const bothDirections = params.centeredSlides || !!params.slidesOffsetBefore || !!params.slidesOffsetAfter;\n swiper.loopFix({\n slideRealIndex,\n direction: bothDirections ? undefined : 'next',\n initial,\n });\n}\n\nfunction loopDestroy() {\n const swiper = this;\n const { params, slidesEl } = swiper;\n if (!params.loop || !slidesEl || (swiper.virtual && swiper.params.virtual?.enabled))\n return;\n swiper.recalcSlides();\n const newSlidesOrder = [];
1514\n swiper.slides.forEach((slideEl) => {\n const loopSlideEl = slideEl;\n const index = typeof loopSlideEl.swiperSlideIndex === 'undefined'\n ? Number(slideEl.getAttribute('data-swiper-slide-index'))\n : loopSlideEl.swiperSlideIndex;\n newSlidesOrder[index] = slideEl;\n });\n swiper.slides.forEach((slideEl) => {\n slideEl.removeAttribute('data-swiper-slide-index');\n });\n newSlidesOrder.forEach((slideEl) => {\n slidesEl.append(slideEl);\n });\n swiper.recalcSlides();\n swiper.slideTo(swiper.realIndex, 0);\n}\n\nfunction loopFix(options = {}) {\n const { slideRealIndex, slideTo = true, direction, setTranslate, activeSlideIndex: activeSlideIndexParam, initial, byController, byMousewheel, } = options;\n let activeSlideIndex = activeSlideIndexParam;\n const swiper = this;\n if (!swiper.params.loop)\n return;\n swiper.emit('beforeLoopFix');\n const { slides, allowSlidePrev, allowSlideNext, slidesEl, params } = swiper;\n const { centeredSlides, slidesOffsetBefore, slidesOffsetAfter, initialSlide } = params;\n const bothDirections = centeredSlides || !!slidesOffsetBefore || !!slidesOffsetAfter;\n swiper.allowSlidePrev = true;\n swiper.allowSlideNext = true;\n if (swiper.virtual && params.virtual?.enabled) {\n if (slideTo) {\n const virtualSlidesLength = swiper.virtual.slides.length;\n const virtualSlidesBefore = swiper.virtual.slidesBefore ?? 0;\n if (!bothDirections && swiper.snapIndex === 0) {\n swiper.slideTo(virtualSlidesLength, 0, false, true);\n }\n else if (bothDirections && swiper.snapIndex < params.slidesPerView) {\n swiper.slideTo(virtualSlidesLength + swiper.snapIndex, 0, false, true);\n }\n else if (swiper.snapIndex === swiper.snapGrid.length - 1) {\n swiper.slideTo(virtualSlidesBefore, 0, false, true);\n }\n }\n swiper.allowSlidePrev = allowSlidePrev;\n swiper.allowSlideNext = allowSlideNext;\n swiper.emit('loopFix');\n return;\n }\n let slidesPerView = params.slidesPerView;\n if (slidesPerView === 'auto') {\n slidesPerView = swiper.slidesPerViewDynamic();\n }\n else {\n slidesPerView = Math.ceil(parseFloat(String(params.slidesPerView)));\n if (bothDirections && slidesPerView % 2 === 0) {\n slidesPerView = slidesPerView + 1;\n }\n }\n const slidesPerGroup = params.slidesPerGroupAuto\n ? slidesPerView\n : params.slidesPerGroup;\n let loopedSlides = bothDirections\n ? Math.max(slidesPerGroup, Math.ceil(slidesPerView / 2))\n : slidesPerGroup;\n if (loopedSlides % slidesPerGroup !== 0) {\n loopedSlides += slidesPerGroup - (loopedSlides % slidesPerGroup);\n }\n loopedSlides += params.loopAdditionalSlides;\n swiper.loopedSlides = loopedSlides;\n const gridEnabled = swiper.grid && params.grid && params.grid.rows > 1;\n if (slides.length < slidesPerView + loopedSlides ||\n (swiper.params.effect === 'cards' && slides.length < slidesPerView + loopedSlides * 2)) {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.x)('Swiper Loop Warning: The number of slides is not enough for loop mode, it will be disabled or not function properly. You need to add more slides (or make duplicates) or lower the values of slidesPerView and slidesPerGroup parameters');\n }\n else if (gridEnabled && params.grid.fill === 'row') {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.x)('Swiper Loop Warning: Loop mode is not compatible with grid.fill = `row`');\n }\n const prependSlidesIndexes = [];\n const appendSlidesIndexes = [];\n const cols = gridEnabled ? Math.ceil(slides.length / params.grid.rows) : slides.length;\n const isInitialOverflow = initial && cols - initialSlide < slidesPerView && !bothDirections;\n let activeIndex = isInitialOverflow ? initialSlide : swiper.activeIndex;\n if (typeof activeSlideIndex === 'undefined') {\n activeSlideIndex = swiper.getSlideIndex(slides.find((el) => el.classList.contains(params.slideActiveClass)));\n }\n else {\n activeIndex = activeSlideIndex;\n }\n const isNext = direction === 'next' || !direction;\n const isPrev = direction === 'prev' || !direction;\n let slidesPrepended = 0;\n let slidesAppended = 0;\n const activeColIndex = gridEnabled\n ? (slides[activeSlideIndex].column ?? 0)\n : activeSlideIndex;\n const activeColIndexWithShift = activeColIndex +\n (bothDirections && typeof setTranslate === 'undefined' ? -slidesPerView / 2 + 0.5 : 0);\n // prepend last slides before start\n if (activeColIndexWithShift < loopedSlides) {\n slidesPrepended = Math.max(loopedSlides - activeColIndexWithShift, slidesPerGroup);\n for (let i = 0; i < loopedSlides - activeColIndexWithShift;
1514 i += 1) {\n const index = i - Math.floor(i / cols) * cols;\n if (gridEnabled) {\n const colIndexToPrepend = cols - index - 1;\n for (let j = slides.length - 1; j >= 0; j -= 1) {\n if (slides[j].column === colIndexToPrepend)\n prependSlidesIndexes.push(j);\n }\n }\n else {\n prependSlidesIndexes.push(cols - index - 1);\n }\n }\n }\n else if (activeColIndexWithShift + slidesPerView > cols - loopedSlides) {\n slidesAppended = Math.max(activeColIndexWithShift - (cols - loopedSlides * 2), slidesPerGroup);\n if (isInitialOverflow) {\n slidesAppended = Math.max(slidesAppended, slidesPerView - cols + initialSlide + 1);\n }\n for (let i = 0; i < slidesAppended; i += 1) {\n const index = i - Math.floor(i / cols) * cols;\n if (gridEnabled) {\n slides.forEach((slide, slideIndex) => {\n if (slide.column === index)\n appendSlidesIndexes.push(slideIndex);\n });\n }\n else {\n appendSlidesIndexes.push(index);\n }\n }\n }\n swiper.__preventObserver__ = true;\n requestAnimationFrame(() => {\n swiper.__preventObserver__ = false;\n });\n if (swiper.params.effect === 'cards' && slides.length < slidesPerView + loopedSlides * 2) {\n if (appendSlidesIndexes.includes(activeSlideIndex)) {\n appendSlidesIndexes.splice(appendSlidesIndexes.indexOf(activeSlideIndex), 1);\n }\n if (prependSlidesIndexes.includes(activeSlideIndex)) {\n prependSlidesIndexes.splice(prependSlidesIndexes.indexOf(activeSlideIndex), 1);\n }\n }\n if (isPrev) {\n prependSlidesIndexes.forEach((index) => {\n const slideEl = slides[index];\n slideEl.swiperLoopMoveDOM = true;\n slidesEl.prepend(slideEl);\n slideEl.swiperLoopMoveDOM = false;\n });\n }\n if (isNext) {\n appendSlidesIndexes.forEach((index) => {\n const slideEl = slides[index];\n slideEl.swiperLoopMoveDOM = true;\n slidesEl.append(slideEl);\n slideEl.swiperLoopMoveDOM = false;\n });\n }\n swiper.recalcSlides();\n if (params.slidesPerView === 'auto') {\n swiper.updateSlides();\n }\n else if (gridEnabled &&\n ((prependSlidesIndexes.length > 0 && isPrev) || (appendSlidesIndexes.length > 0 && isNext))) {\n swiper.slides.forEach((slide, slideIndex) => {\n swiper.grid.updateSlide(slideIndex, slide, swiper.slides);\n });\n }\n if (params.watchSlidesProgress) {\n swiper.updateSlidesOffset();\n }\n if (slideTo) {\n if (prependSlidesIndexes.length > 0 && isPrev) {\n if (typeof slideRealIndex === 'undefined') {\n const currentSlideTranslate = swiper.slidesGrid[activeIndex];\n const newSlideTranslate = swiper.slidesGrid[activeIndex + slidesPrepended];\n const diff = newSlideTranslate - currentSlideTranslate;\n if (byMousewheel) {\n swiper.setTranslate(swiper.translate - diff);\n }\n else {\n swiper.slideTo(activeIndex + Math.ceil(slidesPrepended), 0, false, true);\n if (setTranslate) {\n swiper.touchEventsData.startTranslate =\n swiper.touchEventsData.startTranslate - diff;\n swiper.touchEventsData.currentTranslate =\n swiper.touchEventsData.currentTranslate - diff;\n }\n }\n }\n else {\n if (setTranslate) {\n const shift = gridEnabled\n ? prependSlidesIndexes.length / params.grid.rows\n : prependSlidesIndexes.length;\n swiper.slideTo(swiper.activeIndex + shift, 0, false, true);\n swiper.touchEventsData.currentTranslate = swiper.translate;\n }\n }\n }\n else if (appendSlidesIndexes.length > 0 && isNext) {\n if (typeof slideRealIndex === 'undefined') {\n const currentSlideTranslate = swiper.slidesGrid[activeIndex];\n const newSlideTranslate = swiper.slidesGrid[activeIndex - slidesAppended];\n const diff = newSlideTranslate - currentSlideTranslate;\n if (byMousewheel) {\n swiper.setTranslate(swiper.translate - diff);\n }\n else {\n swiper.slideTo(activeIndex - slidesAppended, 0, false, true);\n if (setTranslate) {\n swiper.touchEventsData.startTranslate =\n swiper.touchEventsData.startTranslate - diff;\n swiper.touchEventsData.currentTranslate =\n swiper.touchEventsData.currentTranslate - diff;\n }\n }\n }\n else {\n const shift = gridEnabled\n ? appendSlidesIndexes.length / params.grid.rows\n : appendSlidesIndexes.length;\n swiper.slideTo(swiper.activeIndex - shift, 0, false, true);\n }\n }\n }\n swiper.allowSlidePrev = allowSlidePrev;\n swiper.allowSlideNext = allowSlideNext;\n const controlled = swiper.controller?.control;\n if (controlled && !byController) {\n const loopParams = {\n slideRealIndex,\n direction,\n setTranslate,\n activeSlideIndex,\n byController: true,\n };\n if (Array.isArray(controlled)) {\n controlled.forEach((c) =>
1514 {\n if (!c.destroyed && c.params.loop)\n c.loopFix({\n ...loopParams,\n slideTo: c.params.slidesPerView === params.slidesPerView ? slideTo : false,\n });\n });\n }\n else if (controlled instanceof swiper.constructor &&\n controlled.params.loop) {\n controlled.loopFix({\n ...loopParams,\n slideTo: controlled.params.slidesPerView === params.slidesPerView ? slideTo : false,\n });\n }\n }\n swiper.emit('loopFix');\n}\n\nvar loop = {\n loopCreate,\n loopFix,\n loopDestroy,\n};\n\nfunction moduleExtendParams(params, allModulesParams) {\n return function extendParams(obj = {}) {\n const moduleParamName = Object.keys(obj)[0];\n const moduleParams = obj[moduleParamName];\n if (typeof moduleParams !== 'object' || moduleParams === null) {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)(allModulesParams, obj);\n return;\n }\n if (params[moduleParamName] === true) {\n params[moduleParamName] = { enabled: true };\n }\n if (moduleParamName === 'navigation' &&\n params[moduleParamName] &&\n params[moduleParamName].enabled &&\n !params[moduleParamName].prevEl &&\n !params[moduleParamName].nextEl) {\n params[moduleParamName].auto = true;\n }\n if (['pagination', 'scrollbar'].indexOf(moduleParamName) >= 0 &&\n params[moduleParamName] &&\n params[moduleParamName].enabled &&\n !params[moduleParamName].el) {\n params[moduleParamName].auto = true;\n }\n if (!(moduleParamName in params && 'enabled' in moduleParams)) {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)(allModulesParams, obj);\n return;\n }\n if (typeof params[moduleParamName] === 'object' && !('enabled' in params[moduleParamName])) {\n params[moduleParamName].enabled = true;\n }\n if (!params[moduleParamName])\n params[moduleParamName] = { enabled: false };\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)(allModulesParams, obj);\n };\n}\n\nconst Observer = ({ swiper, extendParams, on }) => {\n const observers = [];\n const attach = (target, options = {}) => {\n const ObserverFunc = window.MutationObserver ||\n window\n .WebkitMutationObserver;\n if (!ObserverFunc)\n return;\n const observer = new ObserverFunc((mutations) => {\n // The observerUpdate event should only be triggered\n // once despite the number of mutations. Additional\n // triggers are redundant and are very costly\n if (swiper.__preventObserver__)\n return;\n if (mutations.length === 1) {\n swiper.emit('observerUpdate', mutations[0]);\n return;\n }\n const observerUpdate = function observerUpdate() {\n swiper.emit('observerUpdate', mutations[0]);\n };\n if (window.requestAnimationFrame) {\n window.requestAnimationFrame(observerUpdate);\n }\n else {\n window.setTimeout(observerUpdate, 0);\n }\n });\n observer.observe(target, {\n attributes: typeof options.attributes === 'undefined' ? true : options.attributes,\n childList: swiper.isElement || (typeof options.childList === 'undefined' ? true : options.childList),\n characterData: typeof options.characterData === 'undefined' ? true : options.characterData,\n });\n observers.push(observer);\n };\n const init = () => {\n if (!swiper.params.observer)\n return;\n if (swiper.params.observeParents) {\n const containerParents = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.j)(swiper.hostEl);\n for (let i = 0; i < containerParents.length; i += 1) {\n attach(containerParents[i]);\n }\n }\n // Observe container\n attach(swiper.hostEl, {\n childList: swiper.params.observeSlideChildren,\n });\n // Observe wrapper\n attach(swiper.wrapperEl, { attributes: false });\n };\n const destroy = () =>
1514 {\n observers.forEach((observer) => {\n observer.disconnect();\n });\n observers.splice(0, observers.length);\n };\n extendParams({\n observer: false,\n observeParents: false,\n observeSlideChildren: false,\n });\n on('init', init);\n on('destroy', destroy);\n};\n\nconst Resize = ({ swiper, on, emit }) => {\n let observer = null;\n let animationFrame = null;\n const resizeHandler = () => {\n if (!swiper || swiper.destroyed || !swiper.initialized)\n return;\n emit('beforeResize');\n emit('resize');\n };\n const createObserver = () => {\n if (!swiper || swiper.destroyed || !swiper.initialized)\n return;\n observer = new ResizeObserver((entries) => {\n animationFrame = window.requestAnimationFrame(() => {\n const { width, height } = swiper;\n let newWidth = width;\n let newHeight = height;\n entries.forEach(({ contentBoxSize, contentRect, target }) =>
1514 {\n if (target && target !== swiper.el)\n return;\n // Older Safari (â¤15) exposed `contentBoxSize` as a single object instead of an array.\n const box = Array.isArray(contentBoxSize)\n ? contentBoxSize[0]\n : contentBoxSize;\n newWidth = contentRect ? contentRect.width : box.inlineSize;\n newHeight = contentRect ? contentRect.height : box.blockSize;\n });\n if (newWidth !== width || newHeight !== height) {\n resizeHandler();\n }\n });\n });\n observer.observe(swiper.el);\n };\n const removeObserver = () => {\n if (animationFrame) {\n window.cancelAnimationFrame(animationFrame);\n }\n if (observer && observer.unobserve && swiper.el) {\n observer.unobserve(swiper.el);\n observer = null;\n }\n };\n const orientationChangeHandler = () => {\n if (!swiper || swiper.destroyed || !swiper.initialized)\n return;\n emit('orientationchange');\n };\n on('init', () => {\n if (swiper.params.resizeObserver && typeof window.ResizeObserver !== 'undefined') {\n createObserver();\n return;\n }\n window.addEventListener('resize', resizeHandler);\n window.addEventListener('orientationchange', orientationChangeHandler);\n });\n on('destroy', () => {\n removeObserver();\n window.removeEventListener('resize', resizeHandler);\n window.removeEventListener('orientationchange', orientationChangeHandler);\n });\n};\n\nfunction slideNext(speed, runCallbacks = true, internal) {\n const swiper = this;\n const { enabled, params, animating } = swiper;\n if (!enabled || swiper.destroyed)\n return swiper;\n if (typeof speed === 'undefined') {\n speed = swiper.params.speed;\n }\n let perGroup = params.slidesPerGroup;\n if (params.slidesPerView === 'auto' && params.slidesPerGroup === 1 && params.slidesPerGroupAuto) {\n perGroup = Math.max(swiper.slidesPerViewDynamic('current', true), 1);\n }\n const increment = swiper.activeIndex < params.slidesPerGroupSkip ? 1 : perGroup;\n const isVirtual = swiper.virtual && params.virtual?.enabled;\n if (params.loop) {\n if (animating && !isVirtual && params.loopPreventsSliding)\n return false;\n swiper.loopFix({ direction: 'next' });\n swiper._clientLeft = swiper.wrapperEl.clientLeft;\n if (swiper.activeIndex === swiper.slides.length - 1 && params.cssMode) {\n requestAnimationFrame(() => {\n swiper.slideTo(swiper.activeIndex + increment, speed, runCallbacks, internal);\n });\n return true;\n }\n }\n if (params.rewind && swiper.isEnd) {\n return swiper.slideTo(0, speed, runCallbacks, internal);\n }\n return swiper.slideTo(swiper.activeIndex + increment, speed, runCallbacks, internal);\n}\n\nfunction slidePrev(speed, runCallbacks = true, internal) {\n const swiper = this;\n const { params, snapGrid, slidesGrid, rtlTranslate, enabled, animating } = swiper;\n if (!enabled || swiper.destroyed)\n return swiper;\n if (typeof speed === 'undefined') {\n speed = swiper.params.speed;\n }\n const isVirtual = swiper.virtual && params.virtual?.enabled;\n if (params.loop) {\n if (animating && !isVirtual && params.loopPreventsSliding)\n return false;\n swiper.loopFix({ direction: 'prev' });\n swiper._clientLeft = swiper.wrapperEl.clientLeft;\n }\n const translate = rtlTranslate ? swiper.translate : -swiper.translate;\n function normalize(val) {\n if (val < 0)\n return -Math.floor(Math.abs(val));\n return Math.floor(val);\n }\n const normalizedTranslate = normalize(translate);\n const normalizedSnapGrid = snapGrid.map((val) => normalize(val));\n const isFreeMode = params.freeMode && params.freeMode.enabled;\n let prevSnap = snapGrid[normalizedSnapGrid.indexOf(normalizedTranslate) - 1];\n if (typeof prevSnap === 'undefined' && (params.cssMode || isFreeMode)) {\n let prevSnapIndex;
1514\n snapGrid.forEach((snap, snapIndex) => {\n if (normalizedTranslate >= snap) {\n prevSnapIndex = snapIndex;\n }\n });\n if (typeof prevSnapIndex !== 'undefined') {\n prevSnap = isFreeMode\n ? snapGrid[prevSnapIndex]\n : snapGrid[prevSnapIndex > 0 ? prevSnapIndex - 1 : prevSnapIndex];\n }\n }\n let prevIndex = 0;\n if (typeof prevSnap !== 'undefined') {\n prevIndex = slidesGrid.indexOf(prevSnap);\n if (prevIndex < 0)\n prevIndex = swiper.activeIndex - 1;\n if (params.slidesPerView === 'auto' &&\n params.slidesPerGroup === 1 &&\n params.slidesPerGroupAuto) {\n prevIndex = prevIndex - swiper.slidesPerViewDynamic('previous', true) + 1;\n prevIndex = Math.max(prevIndex, 0);\n }\n }\n if (params.rewind && swiper.isBeginning) {\n const lastIndex = swiper.params.virtual?.enabled && swiper.virtual\n ? swiper.virtual.slides.length - 1\n : swiper.slides.length - 1;\n return swiper.slideTo(lastIndex, speed, runCallbacks, internal);\n }\n else if (params.loop && swiper.activeIndex === 0 && params.cssMode) {\n requestAnimationFrame(() => {\n swiper.slideTo(prevIndex, speed, runCallbacks, internal);\n });\n return true;\n }\n return swiper.slideTo(prevIndex, speed, runCallbacks, internal);\n}\n\nfunction slideReset(speed, runCallbacks = true, internal) {\n const swiper = this;\n if (swiper.destroyed)\n return;\n if (typeof speed === 'undefined') {\n speed = swiper.params.speed;\n }\n return swiper.slideTo(swiper.activeIndex, speed, runCallbacks, internal);\n}\n\nfunction slideTo(index = 0, speed, runCallbacks = true, internal, initial) {\n if (typeof index === 'string') {\n index = parseInt(index, 10);\n }\n const swiper = this;\n let slideIndex = index;\n if (slideIndex < 0)\n slideIndex = 0;\n const { params, snapGrid, slidesGrid, previousIndex, activeIndex, rtlTranslate: rtl, wrapperEl, enabled, } = swiper;\n if ((!enabled && !internal && !initial) ||\n swiper.destroyed ||\n (swiper.animating && params.preventInteractionOnTransition)) {\n return false;\n }\n if (typeof speed === 'undefined') {\n speed = swiper.params.speed;\n }\n const skip = Math.min(swiper.params.slidesPerGroupSkip, slideIndex);\n let snapIndex = skip + Math.floor((slideIndex - skip) / swiper.params.slidesPerGroup);\n if (snapIndex >= snapGrid.length)\n snapIndex = snapGrid.length - 1;\n const translate = -snapGrid[snapIndex];\n // Normalize slideIndex\n if (params.normalizeSlideIndex) {\n for (let i = 0; i < slidesGrid.length; i += 1) {\n const normalizedTranslate = -Math.floor(translate * 100);\n const normalizedGrid = Math.floor(slidesGrid[i] * 100);\n const normalizedGridNext = Math.floor(slidesGrid[i + 1] * 100);\n if (typeof slidesGrid[i + 1] !== 'undefined') {\n if (normalizedTranslate >= normalizedGrid &&\n normalizedTranslate < normalizedGridNext - (normalizedGridNext - normalizedGrid) / 2) {\n slideIndex = i;\n }\n else if (normalizedTranslate >= normalizedGrid &&\n normalizedTranslate < normalizedGridNext) {\n slideIndex = i + 1;\n }\n }\n else if (normalizedTranslate >= normalizedGrid) {\n slideIndex = i;\n }\n }\n }\n // Directions locks\n if (swiper.initialized && slideIndex !== activeIndex) {\n if (!swiper.allowSlideNext &&\n (rtl\n ? translate > swiper.translate && translate > swiper.minTranslate()\n : translate < swiper.translate && translate < swiper.minTranslate())) {\n return false;\n }\n if (!swiper.allowSlidePrev &&\n translate >
1514 swiper.translate &&\n translate > swiper.maxTranslate()) {\n if ((activeIndex || 0) !== slideIndex) {\n return false;\n }\n }\n }\n if (slideIndex !== (previousIndex || 0) && runCallbacks) {\n swiper.emit('beforeSlideChangeStart');\n }\n // Update progress\n swiper.updateProgress(translate);\n let direction;\n if (slideIndex > activeIndex)\n direction = 'next';\n else if (slideIndex < activeIndex)\n direction = 'prev';\n else\n direction = 'reset';\n // initial virtual\n const isVirtual = swiper.virtual && swiper.params.virtual?.enabled;\n const isInitialVirtual = isVirtual && initial;\n // Update Index\n if (!isInitialVirtual &&\n ((rtl && -translate === swiper.translate) || (!rtl && translate === swiper.translate))) {\n swiper.updateActiveIndex(slideIndex);\n // Update Height\n if (params.autoHeight) {\n swiper.updateAutoHeight();\n }\n swiper.updateSlidesClasses();\n if (params.effect !== 'slide') {\n swiper.setTranslate(translate);\n }\n if (direction !== 'reset') {\n swiper.transitionStart(runCallbacks, direction);\n swiper.transitionEnd(runCallbacks, direction);\n }\n return false;\n }\n if (params.cssMode) {\n const isH = swiper.isHorizontal();\n const t = rtl ? translate : -translate;\n if (speed === 0) {\n if (isVirtual) {\n swiper.wrapperEl.style.scrollSnapType = 'none';\n swiper._immediateVirtual = true;\n }\n if (isVirtual && !swiper._cssModeVirtualInitialSet && (swiper.params.initialSlide ?? 0) > 0) {\n swiper._cssModeVirtualInitialSet = true;\n requestAnimationFrame(() => {\n wrapperEl[isH ? 'scrollLeft' : 'scrollTop'] = t;\n });\n }\n else {\n wrapperEl[isH ? 'scrollLeft' : 'scrollTop'] = t;\n }\n if (isVirtual) {\n requestAnimationFrame(() => {\n swiper.wrapperEl.style.scrollSnapType = '';\n swiper._immediateVirtual = false;\n });\n }\n }\n else {\n wrapperEl.scrollTo({\n [isH ? 'left' : 'top']: t,\n behavior: 'smooth',\n });\n }\n return true;\n }\n const browser = getBrowser();\n const isSafari = browser.isSafari;\n if (isVirtual && !initial && isSafari && swiper.isElement) {\n swiper.virtual.update(false, false, slideIndex);\n }\n swiper.setTransition(speed);\n swiper.setTranslate(translate);\n swiper.updateActiveIndex(slideIndex);\n swiper.updateSlidesClasses();\n swiper.emit('beforeTransitionStart', speed, internal);\n swiper.transitionStart(runCallbacks, direction);\n if (speed === 0) {\n swiper.transitionEnd(runCallbacks, direction);\n }\n else if (!swiper.animating) {\n swiper.animating = true;\n if (!swiper.onSlideToWrapperTransitionEnd) {\n swiper.onSlideToWrapperTransitionEnd = function transitionEnd(e) {\n if (!swiper || swiper.destroyed)\n return;\n if (e.target !== this)\n return;\n swiper.wrapperEl.removeEventListener('transitionend', swiper.onSlideToWrapperTransitionEnd);\n swiper.onSlideToWrapperTransitionEnd = null;\n delete swiper.onSlideToWrapperTransitionEnd;\n swiper.transitionEnd(runCallbacks, direction);\n };\n }\n swiper.wrapperEl.addEventListener('transitionend', swiper.onSlideToWrapperTransitionEnd);\n }\n return true;\n}\n\nfunction slideToClickedSlide() {\n const swiper = this;\n if (swiper.destroyed)\n return;\n const { params, slidesEl, clickedSlide, clickedIndex } = swiper;\n if (clickedSlide === undefined || clickedIndex === undefined)\n return;\n const slidesPerView = params.slidesPerView === 'auto'\n ? swiper.slidesPerViewDynamic()\n : params.slidesPerView;\n let slideToIndex = swiper.getSlideIndexWhenGrid(clickedIndex);\n let realIndex;\n const slideSelector = swiper.isElement ? `swiper-slide` : `.${params.slideClass}`;\n const isGrid = swiper.grid && swiper.params.grid && swiper.params.grid.rows > 1;\n if (params.loop) {\n if (swiper.animating)\n return;\n realIndex = parseInt(clickedSlide.getAttribute('data-swiper-slide-index'), 10);\n if (params.centeredSlides) {\n swiper.slideToLoop(realIndex);\n }\n else if (slideToIndex >\n (isGrid\n ? (swiper.slides.length - slidesPerView) / 2 - (swiper.params.grid.rows - 1)\n : swiper.slides.length - slidesPerView)) {\n swiper.loopFix();\n slideToIndex = swiper.getSlideIndex((0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(slidesEl, `${slideSelector}[data-swiper-slide-index=\"${realIndex}\"]`)[0]);\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.t)(() =>
1514 {\n swiper.slideTo(slideToIndex);\n });\n }\n else {\n swiper.slideTo(slideToIndex);\n }\n }\n else {\n swiper.slideTo(slideToIndex);\n }\n}\n\nfunction slideToClosest(speed, runCallbacks = true, internal, threshold = 0.5) {\n const swiper = this;\n if (swiper.destroyed)\n return;\n if (typeof speed === 'undefined') {\n speed = swiper.params.speed;\n }\n let index = swiper.activeIndex;\n const skip = Math.min(swiper.params.slidesPerGroupSkip, index);\n const snapIndex = skip + Math.floor((index - skip) / swiper.params.slidesPerGroup);\n const translate = swiper.rtlTranslate ? swiper.translate : -swiper.translate;\n if (translate >= swiper.snapGrid[snapIndex]) {\n // The current translate is on or after the current snap index, so the choice\n // is between the current index and the one after it.\n const currentSnap = swiper.snapGrid[snapIndex];\n const nextSnap = swiper.snapGrid[snapIndex + 1];\n if (translate - currentSnap > (nextSnap - currentSnap) * threshold) {\n index += swiper.params.slidesPerGroup;\n }\n }\n else {\n // The current translate is before the current snap index, so the choice\n // is between the current index and the one before it.\n const prevSnap = swiper.snapGrid[snapIndex - 1];\n const currentSnap = swiper.snapGrid[snapIndex];\n if (translate - prevSnap <= (currentSnap - prevSnap) * threshold) {\n index -= swiper.params.slidesPerGroup;\n }\n }\n index = Math.max(index, 0);\n index = Math.min(index, swiper.slidesGrid.length - 1);\n return swiper.slideTo(index, speed, runCallbacks, internal);\n}\n\nfunction slideToLoop(index = 0, speed, runCallbacks = true, internal) {\n if (typeof index === 'string') {\n const indexAsNumber = parseInt(index, 10);\n index = indexAsNumber;\n }\n const swiper = this;\n if (swiper.destroyed)\n return;\n if (typeof speed === 'undefined') {\n speed = swiper.params.speed;\n }\n const gridEnabled = swiper.grid && swiper.params.grid && swiper.params.grid.rows > 1;\n let newIndex = index;\n if (swiper.params.loop) {\n if (swiper.virtual && swiper.params.virtual?.enabled) {\n newIndex = newIndex + (swiper.virtual.slidesBefore ?? 0);\n }\n else {\n let targetSlideIndex;\n if (gridEnabled) {\n const slideIndex = newIndex * swiper.params.grid.rows;\n const targetSlideEl = swiper.slides.find((slideEl) => Number(slideEl.getAttribute('data-swiper-slide-index')) === slideIndex);\n targetSlideIndex = targetSlideEl?.column ?? 0;\n }\n else {\n targetSlideIndex = swiper.getSlideIndexByData(newIndex);\n }\n const cols = gridEnabled\n ? Math.ceil(swiper.slides.length / swiper.params.grid.rows)\n : swiper.slides.length;\n const { centeredSlides, slidesOffsetBefore, slidesOffsetAfter } = swiper.params;\n const bothDirections = centeredSlides || !!slidesOffsetBefore || !!slidesOffsetAfter;\n let slidesPerView;\n if (swiper.params.slidesPerView === 'auto') {\n slidesPerView = swiper.slidesPerViewDynamic();\n }\n else {\n slidesPerView = Math.ceil(parseFloat(String(swiper.params.slidesPerView)));\n if (bothDirections && slidesPerView % 2 === 0) {\n slidesPerView = slidesPerView + 1;\n }\n }\n let needLoopFix = cols - targetSlideIndex < slidesPerView;\n if (bothDirections) {\n needLoopFix = needLoopFix || targetSlideIndex < Math.ceil(slidesPerView / 2);\n }\n if (internal && bothDirections && swiper.params.slidesPerView !== 'auto' && !gridEnabled) {\n needLoopFix = false;\n }\n if (needLoopFix) {\n const direction = bothDirections\n ? targetSlideIndex < swiper.activeIndex\n ? 'prev'\n : 'next'\n : targetSlideIndex - swiper.activeIndex - 1 < swiper.params.slidesPerView\n ? 'next'\n : 'prev';\n swiper.loopFix({\n direction,\n slideTo: true,\n activeSlideIndex: direction === 'next' ? targetSlideIndex + 1 : targetSlideIndex - cols + 1,\n slideRealIndex: direction === 'next' ? swiper.realIndex : undefined,\n });\n }\n if (gridEnabled) {\n const slideIndex = newIndex * swiper.params.grid.rows;\n const targetSlideEl = swiper.slides.find((slideEl) => Number(slideEl.getAttribute('data-swiper-slide-index')) === slideIndex);\n newIndex = targetSlideEl?.column ?? 0;\n }\n else {\n newIndex = swiper.getSlideIndexByData(newIndex);\n }\n }\n }\n requestAnimationFrame(() =>
1514 {\n swiper.slideTo(newIndex, speed, runCallbacks, internal);\n });\n return swiper;\n}\n\nvar slide = {\n slideTo,\n slideToLoop,\n slideNext,\n slidePrev,\n slideReset,\n slideToClosest,\n slideToClickedSlide,\n};\n\nfunction setTransition(duration, byController) {\n const swiper = this;\n if (!swiper.params.cssMode) {\n swiper.wrapperEl.style.transitionDuration = `${duration}ms`;\n swiper.wrapperEl.style.transitionDelay = duration === 0 ? `0ms` : '';\n }\n swiper.emit('setTransition', duration, byController);\n}\n\nfunction transitionEmit({ swiper, runCallbacks, direction, step, }) {\n const { activeIndex, previousIndex } = swiper;\n let dir = direction;\n if (!dir) {\n if (activeIndex > previousIndex)\n dir = 'next';\n else if (activeIndex < previousIndex)\n dir = 'prev';\n else\n dir = 'reset';\n }\n swiper.emit(`transition${step}`);\n if (runCallbacks && dir === 'reset') {\n swiper.emit(`slideResetTransition${step}`);\n }\n else if (runCallbacks && activeIndex !== previousIndex) {\n swiper.emit(`slideChangeTransition${step}`);\n if (dir === 'next') {\n swiper.emit(`slideNextTransition${step}`);\n }\n else {\n swiper.emit(`slidePrevTransition${step}`);\n }\n }\n}\n\nfunction transitionEnd(runCallbacks = true, direction) {\n const swiper = this;\n const { params } = swiper;\n swiper.animating = false;\n if (params.cssMode)\n return;\n swiper.setTransition(0);\n transitionEmit({ swiper, runCallbacks, direction, step: 'End' });\n}\n\nfunction transitionStart(runCallbacks = true, direction) {\n const swiper = this;\n const { params } = swiper;\n if (params.cssMode)\n return;\n if (params.autoHeight) {\n swiper.updateAutoHeight();\n }\n transitionEmit({ swiper, runCallbacks, direction, step: 'Start' });\n}\n\nvar transition = {\n setTransition,\n transitionStart,\n transitionEnd,\n};\n\nfunction getSwiperTranslate(axis = this.isHorizontal() ? 'x' : 'y') {\n const swiper = this;\n const { params, rtlTranslate: rtl, translate, wrapperEl } = swiper;\n if (params.virtualTranslate) {\n return rtl ? -translate : translate;\n }\n if (params.cssMode) {\n return translate;\n }\n let currentTranslate = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.q)(wrapperEl, axis);\n currentTranslate += swiper.cssOverflowAdjustment();\n if (rtl)\n currentTranslate = -currentTranslate;\n return currentTranslate || 0;\n}\n\nfunction maxTranslate() {\n return -this.snapGrid[this.snapGrid.length - 1];\n}\n\nfunction minTranslate() {\n return -this.snapGrid[0];\n}\n\nfunction setTranslate(translate, byController) {\n const swiper = this;\n const { rtlTranslate: rtl, params, wrapperEl, progress } = swiper;\n let x = 0;\n let y = 0;\n const z = 0;\n if (swiper.isHorizontal()) {\n x = rtl ? -translate : translate;\n }\n else {\n y = translate;\n }\n if (params.roundLengths) {\n x = Math.floor(x);\n y = Math.floor(y);\n }\n swiper.previousTranslate = swiper.translate;\n swiper.translate = swiper.isHorizontal() ? x : y;\n if (params.cssMode) {\n wrapperEl[swiper.isHorizontal() ? 'scrollLeft' : 'scrollTop'] = swiper.isHorizontal() ? -x : -y;\n }\n else if (!params.virtualTranslate) {\n if (swiper.isHorizontal()) {\n x -= swiper.cssOverflowAdjustment();\n }\n else {\n y -= swiper.cssOverflowAdjustment();\n }\n wrapperEl.style.transform = `translate3d(${x}px, ${y}px, ${z}px)`;\n }\n // Check if we need to update progress\n let newProgress;\n const translatesDiff = swiper.maxTranslate() - swiper.minTranslate();\n if (translatesDiff === 0) {\n newProgress = 0;\n }\n else {\n newProgress = (translate - swiper.minTranslate()) / translatesDiff;\n }\n if (newProgress !== progress) {\n swiper.updateProgress(translate);\n }\n swiper.emit('setTranslate', swiper.translate, byController);\n}\n\nfunction translateTo(translate = 0, speed = this.params.speed, runCallbacks = true, translateBounds = true, internal) {\n const swiper = this;\n const { params, wrapperEl } = swiper;\n if (swiper.animating && params.preventInteractionOnTransition) {\n return false;\n }\n const minTranslate = swiper.minTranslate();\n const maxTranslate = swiper.maxTranslate();\n let newTranslate;\n if (translateBounds && translate > minTranslate)\n newTranslate = minTranslate;\n else if (translateBounds && translate < maxTranslate)\n newTranslate = maxTranslate;\n else\n newTranslate = translate;\n // Update progress\n swiper.updateProgress(newTranslate);\n if (params.cssMode) {\n const isH = swiper.isHorizontal();\n if (speed === 0) {\n wrapperEl[isH ? 'scrollLeft' : 'scrollTop'] = -newTranslate;\n }\n else {\n wrapperEl.scrollTo({\n [isH ? 'left' : 'top']: -newTranslate,\n behavior: 'smooth',\n });\n }\n return true;\n }\n if (speed === 0) {\n swiper.setTransition(0);\n swiper.setTranslate(newTranslate);\n if (runCallbacks) {\n swiper.emit('beforeTransitionStart', speed, internal);\n swiper.emit('transitionEnd');\n }\n }\n else {\n swiper.setTransition(speed);\n swiper.setTranslate(newTranslate);\n if (runCallbacks) {\n swiper.emit('beforeTransitionStart', speed, internal);\n swiper.emit('transitionStart');\n }\n if (!swiper.animating) {\n swiper.animating = true;\n if (!swiper.onTranslateToWrapperTransitionEnd) {\n swiper.onTranslateToWrapperTransitionEnd = function transitionEnd(e) {\n if (!swiper || swiper.destroyed)\n return;\n if (e.target !== this)\n return;\n swiper.wrapperEl.removeEventListener('transitionend', swiper.onTranslateToWrapperTransitionEnd);\n swiper.onTranslateToWrapperTransitionEnd = null;\n delete swiper.onTranslateToWrapperTransitionEnd;\n swiper.animating = false;\n if (runCallbacks) {\n swiper.emit('transitionEnd');\n }\n };\n }\n swiper.wrapperEl.addEventListener('transitionend', swiper.onTranslateToWrapperTransitionEnd);\n }\n }\n return true;\n}\n\nvar translate = {\n getTranslate: getSwiperTranslate,\n setTranslate,\n minTranslate,\n maxTranslate,\n translateTo,\n};\n\nfunction getActiveIndexByTranslate(swiper) {\n const { slidesGrid, params } = swiper;\n const translate = swiper.rtlTranslate ? swiper.translate : -swi
1514per.translate;\n let activeIndex;\n for (let i = 0; i < slidesGrid.length; i += 1) {\n if (typeof slidesGrid[i + 1] !== 'undefined') {\n if (translate >= slidesGrid[i] &&\n translate < slidesGrid[i + 1] - (slidesGrid[i + 1] - slidesGrid[i]) / 2) {\n activeIndex = i;\n }\n else if (translate >= slidesGrid[i] && translate < slidesGrid[i + 1]) {\n activeIndex = i + 1;\n }\n }\n else if (translate >= slidesGrid[i]) {\n activeIndex = i;\n }\n }\n // Normalize slideIndex\n if (params.normalizeSlideIndex) {\n if (activeIndex < 0 || typeof activeIndex === 'undefined')\n activeIndex = 0;\n }\n return activeIndex;\n}\nfunction updateActiveIndex(newActiveIndex) {\n const swiper = this;\n const translate = swiper.rtlTranslate ? swiper.translate : -swiper.translate;\n const { snapGrid, params, activeIndex: previousIndex, realIndex: previousRealIndex, snapIndex: previousSnapIndex, } = swiper;\n let activeIndex = newActiveIndex;\n let snapIndex;\n const getVirtualRealIndex = (aIndex) => {\n const virtualSlides = swiper.virtual.slides;\n let realIndex = aIndex - (swiper.virtual.slidesBefore ?? 0);\n if (realIndex < 0) {\n realIndex = virtualSlides.length + realIndex;\n }\n if (realIndex >= virtualSlides.length) {\n realIndex -= virtualSlides.length;\n }\n return realIndex;\n };\n if (typeof activeIndex === 'undefined') {\n activeIndex = getActiveIndexByTranslate(swiper);\n }\n if (snapGrid.indexOf(translate) >= 0) {\n snapIndex = snapGrid.indexOf(translate);\n }\n else {\n const skip = Math.min(params.slidesPerGroupSkip, activeIndex);\n snapIndex = skip + Math.floor((activeIndex - skip) / params.slidesPerGroup);\n }\n if (snapIndex >= snapGrid.length)\n snapIndex = snapGrid.length - 1;\n if (activeIndex === previousIndex && !swiper.params.loop) {\n if (snapIndex !== previousSnapIndex) {\n swiper.snapIndex = snapIndex;\n swiper.emit('snapIndexChange');\n }\n return;\n }\n if (activeIndex === previousIndex &&\n swiper.params.loop &&\n swiper.virtual &&\n swiper.params.virtual?.enabled) {\n swiper.realIndex = getVirtualRealIndex(activeIndex);\n return;\n }\n const gridEnabled = swiper.grid && params.grid && params.grid.rows > 1;\n // Get real index\n let realIndex;\n if (swiper.virtual && params.virtual?.enabled) {\n if (params.loop) {\n realIndex = getVirtualRealIndex(activeIndex);\n }\n else {\n realIndex = activeIndex;\n }\n }\n else if (gridEnabled) {\n const firstSlideInColumn = swiper.slides.find((slideEl) => slideEl.column === activeIndex);\n let activeSlideIndex = parseInt(firstSlideInColumn.getAttribute('data-swiper-slide-index'), 10);\n if (Number.isNaN(activeSlideIndex)) {\n activeSlideIndex = Math.max(swiper.slides.indexOf(firstSlideInColumn), 0);\n }\n realIndex = Math.floor(activeSlideIndex / params.grid.rows);\n }\n else if (swiper.slides[activeIndex]) {\n const slideIndex = swiper.slides[activeIndex].getAttribute('data-swiper-slide-index');\n if (slideIndex) {\n realIndex = parseInt(slideIndex, 10);\n }\n else {\n realIndex = activeIndex;\n }\n }\n else {\n realIndex = activeIndex;\n }\n Object.assign(swiper, {\n previousSnapIndex,\n snapIndex,\n previousRealIndex,\n realIndex,\n previousIndex,\n activeIndex,\n });\n if (swiper.initialized) {\n preload(swiper);\n }\n swiper.emit('activeIndexChange');\n swiper.emit('snapIndexChange');\n if (swiper.initialized || swiper.params.runCallbacksOnInit) {\n if (previousRealIndex !== realIndex) {\n swiper.emit('realIndexChange');\n }\n swiper.emit('slideChange');\n }\n}\n\nfunction updateAutoHeight(speed) {\n const swiper = this;\n const activeSlides = [];\n const isVirtual = swiper.virtual && swiper.params.virtual?.enabled;\n let newHeight = 0;\n let i;\n if (typeof speed === 'number') {\n swiper.setTransition(speed);\n }\n else if (speed === true) {\n swiper.setTransition(swiper.params.speed);\n }\n const getSlideByIndex = (index) =>
1514 {\n if (isVirtual) {\n return swiper.slides[swiper.getSlideIndexByData(index)];\n }\n return swiper.slides[index];\n };\n // Find slides currently in view\n if (swiper.params.slidesPerView !== 'auto' && swiper.params.slidesPerView > 1) {\n if (swiper.params.centeredSlides) {\n (swiper.visibleSlides || []).forEach((slide) => {\n activeSlides.push(slide);\n });\n }\n else {\n for (i = 0; i < Math.ceil(swiper.params.slidesPerView); i += 1) {\n const index = swiper.activeIndex + i;\n if (index > swiper.slides.length && !isVirtual)\n break;\n const slide = getSlideByIndex(index);\n if (slide)\n activeSlides.push(slide);\n }\n }\n }\n else {\n const slide = getSlideByIndex(swiper.activeIndex);\n if (slide)\n activeSlides.push(slide);\n }\n // Find new height from highest slide in view\n for (i = 0; i < activeSlides.length; i += 1) {\n if (typeof activeSlides[i] !== 'undefined') {\n const height = activeSlides[i].offsetHeight;\n newHeight = height > newHeight ? height : newHeight;\n }\n }\n // Update Height\n if (newHeight || newHeight === 0)\n swiper.wrapperEl.style.height = `${newHeight}px`;\n}\n\nfunction updateClickedSlide(el, path) {\n const swiper = this;\n const params = swiper.params;\n let slide = el.closest(`.${params.slideClass}, swiper-slide`);\n if (!slide && swiper.isElement && path && path.length > 1 && path.includes(el)) {\n [...path.slice(path.indexOf(el) + 1, path.length)].forEac
1514h((pathEl) => {\n if (!slide &&\n pathEl.matches &&\n pathEl.matches(`.${params.slideClass}, swiper-slide`)) {\n slide = pathEl;\n }\n });\n }\n let slideFound = false;\n let slideIndex;\n if (slide) {\n for (let i = 0; i < swiper.slides.length; i += 1) {\n if (swiper.slides[i] === slide) {\n slideFound = true;\n slideIndex = i;\n break;\n }\n }\n }\n if (slide && slideFound) {\n swiper.clickedSlide = slide;\n if (swiper.virtual && swiper.params.virtual?.enabled) {\n swiper.clickedIndex = parseInt(slide.getAttribute('data-swiper-slide-index'), 10);\n }\n else {\n swiper.clickedIndex = slideIndex;\n }\n }\n else {\n swiper.clickedSlide = undefined;\n swiper.clickedIndex = undefined;\n return;\n }\n if (params.slideToClickedSlide &&\n swiper.clickedIndex !== undefined &&\n swiper.clickedIndex !== swiper.activeIndex) {\n swiper.slideToClickedSlide();\n }\n}\n\nfunction updateProgress(translate) {\n const swiper = this;\n if (typeof translate === 'undefined') {\n const multiplier = swiper.rtlTranslate ? -1 : 1;\n translate = (swiper && swiper.translate && swiper.translate * multiplier) || 0;\n }\n const params = swiper.params;\n const translatesDiff = swiper.maxTranslate() - swiper.minTranslate();\n let { progress, isBeginning, isEnd } = swiper;\n let progressLoop = swiper.progressLoop;\n const wasBeginning = isBeginning;\n const wasEnd = isEnd;\n if (translatesDiff === 0) {\n progress = 0;\n isBeginning = true;\n isEnd = true;\n }\n else {\n progress = (translate - swiper.minTranslate()) / translatesDiff;\n const isBeginningRounded = Math.abs(translate - swiper.minTranslate()) < 1;\n const isEndRounded = Math.abs(translate - swiper.maxTranslate()) < 1;\n isBeginning = isBeginningRounded || progress <= 0;\n isEnd = isEndRounded || progress >= 1;\n if (isBeginningRounded)\n progress = 0;\n if (isEndRounded)\n progress = 1;\n }\n if (params.loop) {\n const firstSlideIndex = swiper.getSlideIndexByData(0);\n const lastSlideIndex = swiper.getSlideIndexByData(swiper.slides.length - 1);\n const firstSlideTranslate = swiper.slidesGrid[firstSlideIndex];\n const lastSlideTranslate = swiper.slidesGrid[lastSlideIndex];\n const translateMax = swiper.slidesGrid[swiper.slidesGrid.length - 1];\n const translateAbs = Math.abs(translate);\n if (translateAbs >= firstSlideTranslate) {\n progressLoop = (translateAbs - firstSlideTranslate) / translateMax;\n }\n else {\n progressLoop = (translateAbs + translateMax - lastSlideTranslate) / translateMax;\n }\n if (progressLoop > 1)\n progressLoop -= 1;\n }\n Object.assign(swiper, {\n progress,\n progressLoop,\n isBeginning,\n isEnd,\n });\n if (params.watchSlidesProgress || (params.centeredSlides && params.autoHeight))\n swiper.updateSlidesProgress(translate);\n if (isBeginning && !wasBeginning) {\n swiper.emit('reachBeginning toEdge');\n }\n if (isEnd && !wasEnd) {\n swiper.emit('reachEnd toEdge');\n }\n if ((wasBeginning && !isBeginning) || (wasEnd && !isEnd)) {\n swiper.emit('fromEdge');\n }\n swiper.emit('progress', progress);\n}\n\nfunction updateSize() {\n const swiper = this;\n let width;\n let height;\n const el = swiper.el;\n if (typeof swiper.params.width !== 'undefined' && swiper.params.width !== null) {\n width = swiper.params.width;\n }\n else {\n width = el.clientWidth;\n }\n if (typeof swiper.params.height !== 'undefined' && swiper.params.height !== null) {\n height = swiper.params.height;\n }\n else {\n height = el.clientHeight;\n }\n if ((width === 0 && swiper.isHorizontal()) || (height === 0 && swiper.isVertical())) {\n return;\n }\n // Subtract paddings\n width =\n width -\n parseInt((0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.l)(el, 'padding-left') || '0', 10) -\n parseInt((0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.l)(el, 'padding-right') || '0', 10);\n height =\n height -\n parseInt((0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.l)(el, 'padding-top') || '0', 10) -\n parseInt((0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.l)(el, 'padding-bottom') || '0', 10);\n if (Number.isNaN(width))\n width = 0;\n if (Number.isNaN(height))\n height = 0;\n Object.assign(swiper, {\n width,\n height,\n size: swiper.isHorizontal() ? width : height,\n });\n}\n\nfunction updateSlides() {\n const swiper = this;\n function getDirectionPropertyValue(node, label) {\n return parseFloat(node.getPropertyValue(swiper.getDirectionLabel(label)) || '0');\n }\n const params = swiper.params;\n const { wrapperEl, slidesEl, rtlTranslate: rtl, wrongRTL } = swiper;\n const isVirtual = !!(swiper.virtual && params.virtual?.enabled);\n const previousSlidesLength = isVirtual ? swiper.virtual.slides.length : swiper.slides.length;\n const slides = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(slidesEl, `.${swiper.params.slideClass}, swiper-slide`);\n const slidesLength = isVirtual ? swiper.virtual.slides.length : slides.length;\n let snapGrid = [];\n const slidesGrid = [];\n const slidesSizesGrid = [];\n const resolveOffset = (value) =>
1514 typeof value === 'function' ? value.call(swiper) : value;\n const offsetBefore = resolveOffset(params.slidesOffsetBefore);\n const offsetAfter = resolveOffset(params.slidesOffsetAfter);\n const previousSnapGridLength = swiper.snapGrid.length;\n const previousSlidesGridLength = swiper.slidesGrid.length;\n const swiperSize = swiper.size - offsetBefore - offsetAfter;\n let spaceBetween = params.spaceBetween;\n let slidePosition = -offsetBefore;\n let prevSlideSize = 0;\n let index = 0;\n if (typeof swiperSize === 'undefined') {\n return;\n }\n if (typeof spaceBetween === 'string' && spaceBetween.indexOf('%') >= 0) {\n spaceBetween = (parseFloat(spaceBetween.replace('%', '')) / 100) * swiperSize;\n }\n else if (typeof spaceBetween === 'string') {\n spaceBetween = parseFloat(spaceBetween);\n }\n swiper.virtualSize =\n -spaceBetween - offsetBefore - offsetAfter;\n // reset margins\n slides.forEach((slideEl) => {\n if (rtl) {\n slideEl.style.marginLeft = '';\n }\n else {\n slideEl.style.marginRight = '';\n }\n slideEl.style.marginBottom = '';\n slideEl.style.marginTop = '';\n });\n // reset cssMode offsets\n if (params.centeredSlides && params.cssMode) {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.v)(wrapperEl, '--swiper-centered-offset-before', '');\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.v)(wrapperEl, '--swiper-centered-offset-after', '');\n }\n // set cssMode offsets\n if (params.cssMode) {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.v)(wrapperEl, '--swiper-slides-offset-before', `${offsetBefore}px`);\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.v)(wrapperEl, '--swiper-slides-offset-after', `${offsetAfter}px`);\n }\n const gridEnabled = params.grid && params.grid.rows > 1 && swiper.grid;\n if (gridEnabled) {\n swiper.grid.initSlides(slides);\n }\n else if (swiper.grid) {\n swiper.grid.unsetSlides();\n }\n // Calc slides\n let slideSize = 0;\n const shouldResetSlideSize = params.slidesPerView === 'auto' &&\n params.breakpoints &&\n Object.keys(params.breakpoints).filter((key) => {\n const bp = params.breakpoints[key];\n return typeof bp?.slidesPerView !== 'undefined';\n }).length > 0;\n for (let i = 0; i < slidesLength; i += 1) {\n slideSize = 0;\n const slide = slides[i];\n if (slide) {\n if (gridEnabled) {\n swiper.grid.updateSlide(i, slide, slides);\n }\n if ((0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.l)(slide, 'display') === 'none')\n continue;\n }\n if (isVirtual && params.slidesPerView === 'auto') {\n if (params.virtual?.slidesPerViewAutoSlideSize) {\n slideSize = params.virtual.slidesPerViewAutoSlideSize;\n }\n if (slideSize && slide) {\n if (params.roundLengths)\n slideSize = Math.floor(slideSize);\n slide.style[swiper.getDirectionLabel('width')] =\n `${slideSize}px`;\n }\n }\n else if (params.slidesPerView === 'auto') {\n if (shouldResetSlideSize) {\n slide.style[swiper.getDirectionLabel('width')] = ``;\n }\n const slideStyles = getComputedStyle(slide);\n const currentTransform = slide.style.transform;\n const currentWebKitTransform = slide.style.webkitTransform;\n if (currentTransform) {\n slide.style.transform = 'none';\n }\n if (currentWebKitTransform) {\n slide.style.webkitTransform =\n 'none';\n }\n if (params.roundLengths) {\n slideSize = swiper.isHorizontal()\n ? (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.i)(slide, 'width')\n : (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.i)(slide, 'height');\n }\n else {\n const width = getDirectionPropertyValue(slideStyles, 'width');\n const paddingLeft = getDirectionPropertyValue(slideStyles, 'padding-left');\n const paddingRight = getDirectionPropertyValue(slideStyles, 'padding-right');\n const marginLeft = getDirectionPropertyValue(slideStyles, 'margin-left');\n const marginRight = getDirectionPropertyValue(slideStyles, 'margin-right');\n const boxSizing = slideStyles.getPropertyValue('box-sizing');\n if (boxSizing && boxSizing === 'border-box') {\n slideSize = width + marginLeft + marginRight;\n }\n else {\n const { clientWidth, offsetWidth } = slide;\n slideSize =\n width +\n paddingLeft +\n paddingRight +\n marginLeft +\n marginRight +\n (offsetWidth - clientWidth);\n }\n }\n if (currentTransform) {\n slide.style.transform = currentTransform;\n }\n if (currentWebKitTransform) {\n slide.style.webkitTransform =\n currentWebKitTransform;\n }\n if (params.roundLengths)\n slideSize = Math.floor(slideSize);\n }\n else {\n slideSize =\n (swiperSize - (params.slidesPerView - 1) * spaceBetween) /\n params.slidesPerView;\n if (params.roundLengths)\n slideSize = Math.floor(slideSize);\n if (slide) {\n slide.style[swiper.getDirectionLabel('width')] =\n `${slideSize}px`;\n }\n }\n if (slide) {\n slide.swiperSlideSize = slideSize;\n }\n slidesSizesGrid.push(slideSize);\n if (params.centeredSlides) {\n slidePosition = slidePosition + slideSize / 2 + prevSlideSize / 2 + spaceBetween;\n if (prevSlideSize === 0 && i !== 0)\n slidePosition = slidePosition - swiperSize / 2 - spaceBetween;\n if (i === 0)\n slidePosition = slidePosition - swiperSize / 2 - spaceBetween;\n if (Math.abs(slidePosition) < 1 / 1000)\n slidePosition = 0;\n if (params.roundLengths)\n slidePosition = Math.floor(slidePosition);\n if (index % params.slidesPerGroup === 0)\n snapGrid.push(slidePosition);\n slidesGrid.push(slidePosition);\n }\n else {\n if (params.roundLengths)\n slidePosition = Math.floor(slidePosition);\n if ((index - Math.min(swiper.params.slidesPerGroupSkip, index)) %\n swiper.params.slidesPerGroup ===\n 0)\n snapGrid.push(slidePosition);\n slidesGrid.push(slidePosition);\n slidePosition = slidePosition + slideSize + spaceBetween;\n }\n swiper.virtualSize += slideSize + spaceBetween;\n prevSlideSize = slideSize;\n index += 1;\n }\n swiper.virtualSize = Math.max(swiper.virtualSize, swiperSize) + offsetAfter;\n if (rtl && wrongRTL && (params.effect === 'slide' || params.effect === 'coverflow')) {\n wrapperEl.style.width = `${swiper.virtualSize + spaceBetween}px`;\n }\n if (params.setWrapperSize) {\n wrapperEl.style[swiper.getDirectionLabel('width')] = `${swiper.virtualSize + spaceBetween}px`;\n }\n if (gridEnabled) {\n swiper.grid.updateWrapperSize(slideSize, snapGrid);\n }\n // Remove last grid elements depending on width\n if (!params.centeredSlides) {\n // Check if snapToSlideEdge should be applied\n const isFractionalSlidesPerView = params.slidesPerView !== 'auto' && params.slidesPerView % 1 !== 0;\n const shouldSnapToSlideEdge = params.snapToSlideEdge &&\n !params.loop &&\n (params.slidesPerView === 'auto' || isFractionalSlidesPerView);\n // Calculate the last allowed snap index when snapToSlideEdge is enabled\n // This ensures minimum slides are visible at the end\n let lastAllowedSnapIndex = snapGrid.length;\n if (shouldSnapToSlideEdge) {\n let minVisibleSlides;\n if (params.slidesPerView === 'auto') {\n // For 'auto' mode, calculate how many slides fit based on actual sizes\n minVisibleSlides = 1;\n let accumulatedSize = 0;\n for (let i = slidesSizesGrid.length - 1; i >= 0; i -= 1) {\n accumulatedSize +=\n slidesSizesGrid[i] + (i < slidesSizesGrid.length - 1 ? spaceBetween : 0);\n if (accumulatedSize <= swiperSize) {\n minVisibleSlides = slidesSizesGrid.length - i;\n }\n else {\n break;\n }\n }\n }\n else {\n minVisibleSlides = Math.floor(params.slidesPerView);\n }\n lastAllowedSnapIndex = Math.max(slidesLength - minVisibleSlides, 0);\n }\n const newSlidesGrid = [];\n for (let i = 0; i < snapGrid.length; i += 1) {\n let slidesGridItem = snapGrid[i];\n if (params.roundLengths)\n slidesGridItem = Math.floor(slidesGridItem);\n if (shouldSnapToSlideEdge) {\n // When snapToSlideEdge is enabled, only keep snaps up to lastAllowedSnapIndex\n if (i <= lastAllowedSnapIndex) {\n newSlidesGrid.push(slidesGridItem);\n }\n }
1514\n else if (snapGrid[i] <= swiper.virtualSize - swiperSize) {\n // When snapToSlideEdge is disabled, keep snaps that fit within scrollable area\n newSlidesGrid.push(slidesGridItem);\n }\n }\n snapGrid = newSlidesGrid;\n if (Math.floor(swiper.virtualSize - swiperSize) - Math.floor(snapGrid[snapGrid.length - 1]) >\n 1) {\n // Only add edge-aligned snap if snapToSlideEdge is not enabled\n if (!shouldSnapToSlideEdge) {\n snapGrid.push(swiper.virtualSize - swiperSize);\n }\n }\n }\n if (isVirtual && params.loop) {\n const size = slidesSizesGrid[0] + spaceBetween;\n const slidesBefore = swiper.virtual.slidesBefore ?? 0;\n const slidesAfter = swiper.virtual.slidesAfter ?? 0;\n const virtualLoopCount = slidesBefore + slidesAfter;\n if (params.slidesPerGroup > 1) {\n const groups = Math.ceil(virtualLoopCount / params.slidesPerGroup);\n const groupSize = size * params.slidesPerGroup;\n for (let i = 0; i < groups; i += 1) {\n snapGrid.push(snapGrid[snapGrid.length - 1] + groupSize);\n }\n }\n for (let i = 0; i < virtualLoopCount; i += 1) {\n if (params.slidesPerGroup === 1) {\n snapGrid.push(snapGrid[snapGrid.length - 1] + size);\n }\n slidesGrid.push(slidesGrid[slidesGrid.length - 1] + size);\n swiper.virtualSize += size;\n }\n }\n if (snapGrid.length === 0)\n snapGrid = [0];\n if (spaceBetween !== 0) {\n const key = swiper.isHorizontal() && rtl ? 'marginLeft' : swiper.getDirectionLabel('marginRight');\n slides\n .filter((_, slideIndex) => {\n if (!params.cssMode || params.loop)\n return true;\n if (slideIndex === slides.length - 1) {\n return false;\n }\n return true;\n })\n .forEach((slideEl) => {\n slideEl.style[key] = `${spaceBetween}px`;\n });\n }\n if (params.centeredSlides && params.centeredSlidesBounds) {\n let allSlidesSize = 0;\n slidesSizesGrid.forEach((slideSizeValue) => {\n allSlidesSize += slideSizeValue + (spaceBetween || 0);\n });\n allSlidesSize -= spaceBetween;\n const maxSnap = allSlidesSize > swiperSize ? allSlidesSize - swiperSize : 0;\n snapGrid = snapGrid.map((snap) => {\n if (snap <= 0)\n return -offsetBefore;\n if (snap > maxSnap)\n return maxSnap + offsetAfter;\n return snap;\n });\n }\n if (params.centerInsufficientSlides) {\n let allSlidesSize = 0;\n slidesSizesGrid.forEach((slideSizeValue) => {\n allSlidesSize += slideSizeValue + (spaceBetween || 0);\n });\n allSlidesSize -= spaceBetween;\n if (allSlidesSize < swiperSize) {\n const allSlidesOffset = (swiperSize - allSlidesSize) / 2;\n snapGrid.forEach((snap, snapIndex) => {\n snapGrid[snapIndex] = snap - allSlidesOffset;\n });\n slidesGrid.forEach((snap, snapIndex) => {\n slidesGrid[snapIndex] = snap + allSlidesOffset;\n });\n }\n }\n Object.assign(swiper, {\n slides,\n snapGrid,\n slidesGrid,\n slidesSizesGrid,\n });\n if (params.centeredSlides && params.cssMode && !params.centeredSlidesBounds) {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.v)(wrapperEl, '--swiper-centered-offset-before', `${-snapGrid[0]}px`);\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.v)(wrapperEl, '--swiper-centered-offset-after', `${swiper.size / 2 - slidesSizesGrid[slidesSizesGrid.length - 1] / 2}px`);\n const addToSnapGrid = -swiper.snapGrid[0];\n const addToSlidesGrid = -swiper.slidesGrid[0];\n swiper.snapGrid = swiper.snapGrid.map((v) => v + addToSnapGrid);\n swiper.slidesGrid = swiper.slidesGrid.map((v) => v + addToSlidesGrid);\n }\n if (slidesLength !== previousSlidesLength) {\n swiper.emit('slidesLengthChange');\n }
1514\n if (snapGrid.length !== previousSnapGridLength) {\n if (swiper.params.watchOverflow)\n swiper.checkOverflow();\n swiper.emit('snapGridLengthChange');\n }\n if (slidesGrid.length !== previousSlidesGridLength) {\n swiper.emit('slidesGridLengthChange');\n }\n if (params.watchSlidesProgress) {\n swiper.updateSlidesOffset();\n }\n swiper.emit('slidesUpdated');\n if (!isVirtual && !params.cssMode && (params.effect === 'slide' || params.effect === 'fade')) {\n const backFaceHiddenClass = `${params.containerModifierClass}backface-hidden`;\n const hasClassBackfaceClassAdded = swiper.el.classList.contains(backFaceHiddenClass);\n if (slidesLength <= params.maxBackfaceHiddenSlides) {\n if (!hasClassBackfaceClassAdded)\n swiper.el.classList.add(backFaceHiddenClass);\n }\n else if (hasClassBackfaceClassAdded) {\n swiper.el.classList.remove(backFaceHiddenClass);\n }\n }\n}\n\nconst toggleSlideClasses$1 = (slideEl, condition, className) => {\n if (condition && !slideEl.classList.contains(className)) {\n slideEl.classList.add(className);\n }\n else if (!condition && slideEl.classList.contains(className)) {\n slideEl.classList.remove(className);\n }\n};\nfunction updateSlidesClasses() {\n const swiper = this;\n const { slides, params, slidesEl, activeIndex } = swiper;\n const isVirtual = !!(swiper.virtual && params.virtual?.enabled);\n const gridEnabled = swiper.grid && params.grid && params.grid.rows > 1;\n const getFilteredSlide = (selector) => {\n return (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(slidesEl, `.${params.slideClass}${selector}, swiper-slide${selector}`)[0];\n };\n let activeSlide;\n let prevSlide;\n let nextSlide;\n if (isVirtual) {\n if (params.loop) {\n const virtualSlides = swiper.virtual.slides;\n let slideIndex = activeIndex - (swiper.virtual.slidesBefore ?? 0);\n if (slideIndex < 0)\n slideIndex = virtualSlides.length + slideIndex;\n if (slideIndex >= virtualSlides.length)\n slideIndex -= virtualSlides.length;\n activeSlide = getFilteredSlide(`[data-swiper-slide-index=\"${slideIndex}\"]`);\n }\n else {\n activeSlide = getFilteredSlide(`[data-swiper-slide-index=\"${activeIndex}\"]`);\n }\n }\n else if (gridEnabled) {\n activeSlide = slides.find((slideEl) => slideEl.column === activeIndex);\n nextSlide = slides.find((slideEl) => slideEl.column === activeIndex + 1);\n prevSlide = slides.find((slideEl) => slideEl.column === activeIndex - 1);\n }\n else {\n activeSlide = slides[activeIndex];\n }\n if (activeSlide) {\n if (!gridEnabled) {\n // Next Slide\n nextSlide = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.g)(activeSlide, `.${params.slideClass}, swiper-slide`)[0];\n if (params.loop && !nextSlide) {\n nextSlide = slides[0];\n }\n // Prev Slide\n prevSlide = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.k)(activeSlide, `.${params.slideClass}, swiper-slide`)[0];\n // NOTE: legacy guard from v9; `(!prevSlide) === 0` is always false, but we preserve\n // the original behaviour (no-op) to avoid runtime changes in v14. Audit candidate.\n if (params.loop && !prevSlide === 0) {\n prevSlide = slides[slides.length - 1];\n }\n }\n }\n slides.forEach((slideEl) =>
1514 {\n toggleSlideClasses$1(slideEl, slideEl === activeSlide, params.slideActiveClass);\n toggleSlideClasses$1(slideEl, slideEl === nextSlide, params.slideNextClass);\n toggleSlideClasses$1(slideEl, slideEl === prevSlide, params.slidePrevClass);\n });\n swiper.emitSlidesClasses();\n}\n\nfunction updateSlidesOffset() {\n const swiper = this;\n const slides = swiper.slides;\n const minusOffset = swiper.isElement\n ? swiper.isHorizontal()\n ? swiper.wrapperEl.offsetLeft\n : swiper.wrapperEl.offsetTop\n : 0;\n for (let i = 0; i < slides.length; i += 1) {\n slides[i].swiperSlideOffset =\n (swiper.isHorizontal() ? slides[i].offsetLeft : slides[i].offsetTop) -\n minusOffset -\n swiper.cssOverflowAdjustment();\n }\n}\n\nconst toggleSlideClasses = (slideEl, condition, className) => {\n if (condition && !slideEl.classList.contains(className)) {\n slideEl.classList.add(className);\n }\n else if (!condition && slideEl.classList.contains(className)) {\n slideEl.classList.remove(className);\n }\n};\nfunction updateSlidesProgress(translate = (this && this.translate) || 0) {\n const swiper = this;\n const params = swiper.params;\n const { slides, rtlTranslate: rtl, snapGrid } = swiper;\n if (slides.length === 0)\n return;\n if (typeof slides[0].swiperSlideOffset === 'undefined')\n swiper.updateSlidesOffset();\n let offsetCenter = -translate;\n if (rtl)\n offsetCenter = translate;\n swiper.visibleSlidesIndexes = [];\n swiper.visibleSlides = [];\n let spaceBetween = params.spaceBetween;\n if (typeof spaceBetween === 'string' && spaceBetween.indexOf('%') >= 0) {\n spaceBetween = (parseFloat(spaceBetween.replace('%', '')) / 100) * swiper.size;\n }\n else if (typeof spaceBetween === 'string') {\n spaceBetween = parseFloat(spaceBetween);\n }\n for (let i = 0; i < slides.length; i += 1) {\n const slide = slides[i];\n let slideOffset = slide.swiperSlideOffset ?? 0;\n if (params.cssMode && params.centeredSlides) {\n slideOffset -= slides[0].swiperSlideOffset ?? 0;\n }\n const slideSize = slide.swiperSlideSize ?? 0;\n const slideProgress = (offsetCenter + (params.centeredSlides ? swiper.minTranslate() : 0) - slideOffset) /\n (slideSize + spaceBetween);\n const originalSlideProgress = (offsetCenter -\n snapGrid[0] +\n (params.centeredSlides ? swiper.minTranslate() : 0) -\n slideOffset) /\n (slideSize + spaceBetween);\n const slideBefore = -(offsetCenter - slideOffset);\n const slideAfter = slideBefore + swiper.slidesSizesGrid[i];\n const isFullyVisible = slideBefore >= 0 && slideBefore <= swiper.size - swiper.slidesSizesGrid[i];\n const isVisible = (slideBefore >= 0 && slideBefore < swiper.size - 1) ||\n (slideAfter > 1 && slideAfter <= swiper.size) ||\n (slideBefore <= 0 && slideAfter >= swiper.size);\n if (isVisible) {\n swiper.visibleSlides.push(slide);\n swiper.visibleSlidesIndexes.push(i);\n }\n toggleSlideClasses(slide, isVisible, params.slideVisibleClass);\n toggleSlideClasses(slide, isFullyVisible, params.slideFullyVisibleClass);\n slide.progress = rtl ? -slideProgress : slideProgress;\n slide.originalProgress = rtl ? -originalSlideProgress : originalSlideProgress;\n }\n}\n\nvar update = {\n updateSize,\n updateSlides,\n updateAutoHeight,\n updateSlidesOffset,\n updateSlidesProgress,\n updateProgress,\n updateSlidesClasses,\n updateActiveIndex,\n updateClickedSlide,\n};\n\nconst prototypes = {\n eventsEmitter,\n update,\n translate,\n transition,\n slide,\n loop,\n grabCursor,\n events: events$1,\n breakpoints,\n checkOverflow: checkOverflow$1,\n classes,\n};\nconst extendedDefaults = {};\nclass Swiper {\n static extendedDefaults;\n static defaults;\n constructor(...args) {\n let el;\n let params;\n if (args.length === 1 &&\n args[0] !== null &&\n typeof args[0] === 'object' &&\n Object.prototype.toString.call(args[0]).slice(8, -1) === 'Object') {\n params = args[0];\n }\n else {\n [el, params] = args;\n }\n if (!params)\n params = {};\n params = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)({}, params);\n if (el && !params.el)\n params.el = el;\n if (params.el &&\n typeof params.el === 'string' &&\n typeof document !== 'undefined' &&\n document.querySelectorAll(params.el).length > 1) {\n const swipers = [];\n document.querySelectorAll(params.el).forEach((containerEl) => {\n const newParams = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)({}, params, { el: containerEl });\n swipers.push(new Swiper(newParams));\n });\n return swipers;\n }\n // Swiper Instance\n const swiper = this;\n swiper.__swiper__ = true;
1514\n swiper.support = getSupport();\n swiper.device = getDevice({ userAgent: params.userAgent ?? undefined });\n swiper.browser = getBrowser();\n swiper.eventsListeners = {};\n swiper.eventsAnyListeners = [];\n swiper.modules = [...(swiper.__modules__ || [])];\n if (params.modules && Array.isArray(params.modules)) {\n params.modules.forEach((mod) => {\n const fn = mod;\n if (typeof fn === 'function' && swiper.modules.indexOf(fn) < 0) {\n swiper.modules.push(fn);\n }\n });\n }\n const allModulesParams = {};\n swiper.modules.forEach((mod) => {\n mod({\n params: params,\n swiper,\n extendParams: moduleExtendParams(params, allModulesParams),\n on: swiper.on.bind(swiper),\n once: swiper.once.bind(swiper),\n off: swiper.off.bind(swiper),\n emit: swiper.emit.bind(swiper),\n });\n });\n // Extend defaults with modules params\n const swiperParams = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)({}, defaults, allModulesParams);\n // Extend defaults with passed params\n swiper.params = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)({}, swiperParams, extendedDefaults, params);\n swiper.originalParams = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)({}, swiper.params);\n swiper.passedParams = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)({}, params);\n // add event listeners\n if (swiper.params && swiper.params.on) {\n const onHandlers = swiper.params.on;\n Object.keys(onHandlers).forEach((eventName) => {\n const handler = onHandlers[eventName];\n if (handler)\n swiper.on(eventName, handler);\n });\n }\n if (swiper.params && swiper.params.onAny) {\n swiper.onAny(swiper.params.onAny);\n }\n // Extend Swiper\n Object.assign(swiper, {\n enabled: swiper.params.enabled,\n el,\n // Classes\n classNames: [],\n // Slides\n slides: [],\n slidesGrid: [],\n snapGrid: [],\n slidesSizesGrid: [],\n // isDirection\n isHorizontal() {\n return swiper.params.direction === 'horizontal';\n },\n isVertical() {\n return swiper.params.direction === 'vertical';\n },\n // Indexes\n activeIndex: 0,\n realIndex: 0,\n //\n isBeginning: true,\n isEnd: false,\n // Props\n translate: 0,\n previousTranslate: 0,\n progress: 0,\n velocity: 0,\n animating: false,\n cssOverflowAdjustment() {\n // Returns 0 unless `translate` is > 2**23\n // Should be subtracted from css values to prevent overflow\n return Math.trunc(this.translate / 2 ** 23) * 2 ** 23;\n },\n // Locks\n allowSlideNext: swiper.params.allowSlideNext,\n allowSlidePrev: swiper.params.allowSlidePrev,\n // Touch Events\n touchEventsData: {\n isTouched: undefined,\n isMoved: undefined,\n allowTouchCallbacks: undefined,\n touchStartTime: undefined,\n isScrolling: undefined,\n currentTranslate: undefined,\n startTranslate: undefined,\n allowThresholdMove: undefined,\n // Form elements to match\n focusableElements: swiper.params.focusableElements,\n // Last click time\n lastClickTime: 0,\n clickTimeout: undefined,\n // Velocities\n velocities: [],\n allowMomentumBounce: undefined,\n startMoving: undefined,\n pointerId: null,\n touchId: null,\n },\n // Clicks\n allowClick: true,\n // Touches\n allowTouchMove: swiper.params.allowTouchMove,\n touches: {\n startX: 0,\n startY: 0,\n currentX: 0,\n currentY: 0,\n diff: 0,\n },\n // Images\n imagesToLoad: [],\n imagesLoaded: 0,\n });\n swiper.emit('_swiper');\n // Init\n if (swiper.params.init) {\n swiper.init();\n }\n // Return app instance\n return swiper;\n }\n getDirectionLabel(property) {\n if (this.isHorizontal()) {\n return property;\n }\n // oxfmt-ignore\n return {\n 'width': 'height',\n 'margin-top': 'margin-left',\n 'margin-bottom ': 'margin-right',\n 'margin-left': 'margin-top',\n 'margin-right': 'margin-bottom',\n 'padding-left': 'padding-top',\n 'padding-right': 'padding-bottom',\n 'marginRight': 'marginBottom',\n }[property];\n }
1514\n /**\n * !INTERNAL\n */\n isHorizontal() {\n return this.params.direction === 'horizontal';\n }\n isVertical() {\n return this.params.direction === 'vertical';\n }\n cssOverflowAdjustment() {\n return Math.trunc(this.translate / 2 ** 23) * 2 ** 23;\n }\n getSlideIndex(slideEl) {\n const { slidesEl, params } = this;\n const slides = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(slidesEl, `.${params.slideClass}, swiper-slide`);\n const firstSlideIndex = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.b)(slides[0]);\n return (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.b)(slideEl) - (firstSlideIndex ?? 0);\n }\n getSlideIndexByData(index) {\n return this.getSlideIndex(this.slides.find((slideEl) => Number(slideEl.getAttribute('data-swiper-slide-index')) === index));\n }\n getSlideIndexWhenGrid(index) {\n if (this.grid && this.params.grid && this.params.grid.rows > 1) {\n if (this.params.grid.fill === 'column') {\n index = Math.floor(index / this.params.grid.rows);\n }\n else if (this.params.grid.fill === 'row') {\n index = index % Math.
1514ceil(this.slides.length / this.params.grid.rows);\n }\n }\n return index;\n }\n recalcSlides() {\n const { slidesEl, params } = this;\n this.slides = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(slidesEl, `.${params.slideClass}, swiper-slide`);\n }\n /**\n * Enable Swiper (if it was disabled)\n */\n enable() {\n if (this.enabled)\n return;\n this.enabled = true;\n if (this.params.grabCursor) {\n this.setGrabCursor();\n }\n this.emit('enable');\n }\n /**\n * Disable Swiper (if it was enabled). When Swiper is disabled, it will hide all navigation elements and won't respond to any events and interactions\n */\n disable() {\n if (!this.enabled)\n return;\n this.enabled = false;\n if (this.params.grabCursor) {\n this.unsetGrabCursor();\n }\n this.emit('disable');\n }\n /**\n * Set Swiper translate progress (from 0 to 1). Where 0 - its initial position (offset) on first slide, and 1 - its maximum position (offset) on last slide\n *\n * @param progress Swiper translate progress (from 0 to 1).\n * @param speed Transition duration (in ms).\n */\n setProgress(progress, speed) {\n progress = Math.min(Math.max(progress, 0), 1);\n const min = this.minTranslate();\n const max = this.maxTranslate();\n const current = (max - min) * progress + min;\n this.translateTo(current, typeof speed === 'undefined' ? 0 : speed);\n this.updateActiveIndex();\n this.updateSlidesClasses();\n }\n emitContainerClasses() {\n if (!this.params._emitClasses || !this.el)\n return;\n const cls = this.el.className.split(' ').filter((className) => {\n return (className.indexOf('swiper') === 0 ||\n className.indexOf(this.params.containerModifierClass) === 0);\n });\n this.emit('_containerClasses', cls.join(' '));\n }\n getSlideClasses(slideEl) {\n if (this.destroyed)\n return '';\n return slideEl.className\n .split(' ')\n .filter((className) => {\n return (className.indexOf('swiper-slide') === 0 ||\n className.indexOf(this.params.slideClass) === 0);\n })\n .join(' ');\n }\n emitSlidesClasses() {\n if (!this.params._emitClasses || !this.el)\n return;\n const updates = [];\n this.slides.forEach((slideEl) => {\n const classNames = this.getSlideClasses(slideEl);\n updates.push({ slideEl, classNames });\n this.emit('_slideClass', slideEl, classNames);\n });\n this.emit('_slideClasses', updates);\n }\n /**\n * Get dynamically calculated amount of slides per view, useful only when slidesPerView set to `auto`\n */\n slidesPerViewDynamic(view = 'current', exact = false) {\n const { params, slides, slidesGrid, slidesSizesGrid, size: swiperSize, activeIndex } = this;\n let spv = 1;\n if (typeof params.slidesPerView === 'number')\n return params.slidesPerView;\n if (params.centeredSlides) {\n let slideSize = slides[activeIndex] ? Math.ceil(slides[activeIndex].swiperSlideSize ?? 0) : 0;\n let breakLoop = false;\n for (let i = activeIndex + 1; i < slides.length; i += 1) {\n if (slides[i] && !breakLoop) {\n slideSize += Math.ceil(slides[i].swiperSlideSize ?? 0);\n spv += 1;\n if (slideSize > swiperSize)\n breakLoop = true;\n }\n }\n for (let i = activeIndex - 1; i >= 0; i -= 1) {\n if (slides[i] && !breakLoop) {\n slideSize += slides[i].swiperSlideSize ?? 0;\n spv += 1;\n if (slideSize > swiperSize)\n breakLoop = true;\n }\n }\n }\n else if (view === 'current') {\n for (let i = activeIndex + 1; i < slides.length; i += 1) {\n const slideInView = exact\n ? slidesGrid[i] + slidesSizesGrid[i] - slidesGrid[activeIndex] < swiperSize\n : slidesGrid[i] - slidesGrid[activeIndex] < swiperSize;\n if (slideInView) {\n spv += 1;\n }\n }\n }\n else {\n // previous\n for (let i = activeIndex - 1; i >= 0; i -= 1) {\n const slideInView = slidesGrid[activeIndex] - slidesGrid[i] < swiperSize;\n if (slideInView) {\n spv += 1;\n }\n }\n }\n return spv;\n }\n /**\n * You should call it after you add/remove slides\n * manually, or after you hide/show it, or do any\n * custom DOM modifications with Swiper\n * This method also includes subcall of the following\n * methods which you can use separately:\n */\n update() {\n const swiper = this;\n if (!swiper || swiper.destroyed)\n return;\n const { snapGrid, params } = swiper;
1514\n // Breakpoints\n if (params.breakpoints) {\n swiper.setBreakpoint();\n }\n [...swiper.el.querySelectorAll('[loading=\"lazy\"]')].forEach((imageEl) => {\n if (imageEl.complete) {\n processLazyPreloader(swiper, imageEl);\n }\n });\n swiper.updateSize();\n swiper.updateSlides();\n swiper.updateProgress();\n swiper.updateSlidesClasses();\n function setTranslate() {\n const translateValue = swiper.rtlTranslate ? swiper.translate * -1 : swiper.translate;\n const newTranslate = Math.min(Math.max(translateValue, swiper.maxTranslate()), swiper.minTranslate());\n swiper.setTranslate(newTranslate);\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n }\n let translated;\n if (params.freeMode?.enabled && !params.cssMode) {\n setTranslate();\n if (params.autoHeight) {\n swiper.updateAutoHeight();\n }\n }\n else {\n if ((params.slidesPerView === 'auto' || params.slidesPerView > 1) &&\n swiper.isEnd &&\n !params.centeredSlides) {\n const slidesLength = swiper.virtual && params.virtual?.enabled\n ? swiper.virtual.slides.length\n : swiper.slides.length;\n translated = swiper.slideTo(slidesLength - 1, 0, false, true);\n }\n else {\n translated = swiper.slideTo(swiper.activeIndex, 0, false, true);\n }\n if (!translated) {\n setTranslate();\n }\n }\n if (params.watchOverflow && snapGrid !== swiper.snapGrid) {\n swiper.checkOverflow();\n }\n swiper.emit('update');\n }\n /**\n * Changes slider direction from horizontal to vertical and back.\n *\n * @param direction New direction. If not specified, then will automatically changed to opposite direction\n * @param needUpdate Will call swiper.update(). Default true\n */\n changeDirection(newDirection, needUpdate = true) {\n const swiper = this;\n const currentDirection = swiper.params.direction;\n if (!newDirection) {\n newDirection = currentDirection === 'horizontal' ? 'vertical' : 'horizontal';\n }\n if (newDirection === currentDirection ||\n (newDirection !== 'horizontal' && newDirection !== 'vertical')) {\n return swiper;\n }\n swiper.el.classList.remove(`${swiper.params.containerModifierClass}${currentDirection}`);\n swiper.el.classList.add(`${swiper.params.containerModifierClass}${newDirection}`);\n swiper.emitContainerClasses();\n swiper.params.direction = newDirection;\n swiper.slides.forEach((slideEl) => {\n if (newDirection === 'vertical') {\n slideEl.style.width = '';\n }\n else {\n slideEl.style.height = '';\n }\n });\n swiper.emit('changeDirection');\n if (needUpdate)\n swiper.update();\n return swiper;\n }\n /**\n * Changes slider language\n *\n * @param direction New direction. Should be `rtl` or `ltr`\n */\n changeLanguageDirection(direction) {\n const swiper = this;\n if ((swiper.rtl && direction === 'rtl') || (!swiper.rtl && direction === 'ltr'))\n return;\n swiper.rtl = direction === 'rtl';\n swiper.rtlTranslate = swiper.params.direction === 'horizontal' && swiper.rtl;\n if (swiper.rtl) {\n swiper.el.classList.add(`${swiper.params.containerModifierClass}rtl`);\n swiper.el.dir = 'rtl';\n }\n else {\n swiper.el.classList.remove(`${swiper.params.containerModifierClass}rtl`);\n swiper.el.dir = 'ltr';\n }\n swiper.update();\n }\n mount(element) {\n const swiper = this;\n if (swiper.mounted)\n return true;\n // No DOM (SSR / Node) â nothing to mount to.\n if (typeof document === 'undefined')\n return false;\n // Find el (params.el can be a CSSSelector, HTMLElement, or undefined)\n const initialEl = element ?? swiper.params.el;\n let el = null;\n if (typeof initialEl === 'string') {\n el = document.querySelector(initialEl);\n }\n else if (initialEl instanceof HTMLElement) {\n el = initialEl;\n }\n if (!el) {\n return false;\n }\n el.swiper = swiper;\n const parent = el.parentNode;\n if (parent &&\n parent.host &&\n parent.host.nodeName === swiper.params.swiperElementNodeName.toUpperCase()) {\n swiper.isElement = true;\n }\n const getWrapperSelector = () => {\n return `.${(swiper.params.wrapperClass || '').trim().split(' ').join('.')}`;\n };\n const getWrapper = () => {\n if (el && el.shadowRoot) {\n const res = el.shadowRoot.querySelector(getWrapperSelector());\n // Children needs to return slot items\n return res;\n }\n return (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(el, getWrapperSelector())[0];\n };\n // Find Wrapper\n let wrapperEl = getWrapper();\n if (!wrapperEl && swiper.params.createElements) {\n wrapperEl = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.a)('div', swiper.params.wrapperClass);\n el.append(wrapperEl);\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.e)(el, `.${swiper.params.slideClass}`).forEach((slideEl) => {\n wrapperEl.append(slideEl);\n });\n }\n const host = swiper.isElement ? el.parentNode.host : null;\n Object.assign(swiper, {\n el,\n wrapperEl,\n slidesEl: swiper.isElement && !host.slideSlots ? host : wrapperEl,\n hostEl: swiper.isElement ? host : el,\n mounted: true,\n // RTL\n rtl: el.dir.toLowerCase() === 'rtl' || (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.l)(el, 'direction') === 'rtl',\n rtlTranslate: swiper.params.direction === 'horizontal' &&\n (el.dir.toLowerCase() === 'rtl' || (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.l)(el, 'direction') === 'rtl'),\n wrongRTL: (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.l)(wrapperEl, 'display') === '-webkit-box',\n });\n return true;\n }\n /**\n * Initialize slider\n */\n init(el) {\n const swiper = this;\n if (swiper.initialized)\n return swiper;\n const mounted = swiper.mount(el);\n if (mounted === false)\n return swiper;\n swiper.emit('beforeInit');\n // Set breakpoint\n if (swiper.params.breakpoints) {\n swiper.setBreakpoint();\n }\n // Add Classes\n swiper.addClasses();\n // Update size\n swiper.updateSize();\n // Update slides\n swiper.updateSlides();\n if (swiper.params.watchOverflow) {\n swiper.checkOverflow();\n }\n // Set Grab Cursor\n if (swiper.params.grabCursor && swiper.enabled) {\n swiper.setGrabCursor(
1514);\n }\n // Slide To Initial Slide\n if (swiper.params.loop && swiper.virtual && swiper.params.virtual?.enabled) {\n swiper.slideTo((swiper.params.initialSlide ?? 0) + (swiper.virtual.slidesBefore ?? 0), 0, swiper.params.runCallbacksOnInit, false, true);\n }\n else {\n swiper.slideTo(swiper.params.initialSlide, 0, swiper.params.runCallbacksOnInit, false, true);\n }\n // Create loop\n if (swiper.params.loop) {\n swiper.loopCreate(undefined, true);\n }\n // Attach events\n swiper.attachEvents();\n const lazyElements = [...swiper.el.querySelectorAll('[loading=\"lazy\"]')];\n if (swiper.isElement) {\n lazyElements.push(...swiper.hostEl.querySelectorAll('[loading=\"lazy\"]'));\n }\n lazyElements.forEach((imageEl) => {\n if (imageEl.complete) {\n processLazyPreloader(swiper, imageEl);\n }\n else {\n imageEl.addEventListener('load', (e) => {\n processLazyPreloader(swiper, e.target);\n });\n }\n });\n preload(swiper);\n // Init Flag\n swiper.initialized = true;\n preload(swiper);\n // Emit\n swiper.emit('init');\n swiper.emit('afterInit');\n return swiper;\n }\n /**\n * Destroy slider instance and detach all events listeners\n *\n * @param deleteInstance Set it to false (by default it is true) to not to delete Swiper instance\n * @param cleanStyles Set it to true (by default it is true) and all custom styles will be removed from slides, wrapper and container.\n * Useful if you need to destroy Swiper and to init again with
1514new options or in different direction\n */\n destroy(deleteInstance = true, cleanStyles = true) {\n const swiper = this;\n const { params, el, wrapperEl, slides } = swiper;\n if (typeof swiper.params === 'undefined' || swiper.destroyed) {\n return null;\n }\n swiper.emit('beforeDestroy');\n // Init Flag\n swiper.initialized = false;\n // Detach events\n swiper.detachEvents();\n // Destroy loop\n if (params.loop) {\n swiper.loopDestroy();\n }\n // Cleanup styles\n if (cleanStyles) {\n swiper.removeClasses();\n if (el && typeof el !== 'string') {\n el.removeAttribute('style');\n }\n if (wrapperEl) {\n wrapperEl.removeAttribute('style');\n }\n if (slides && slides.length) {\n slides.forEach((slideEl) => {\n slideEl.classList.remove(params.slideVisibleClass, params.slideFullyVisibleClass, params.slideActiveClass, params.slideNextClass, params.slidePrevClass);\n slideEl.removeAttribute('style');\n slideEl.removeAttribute('data-swiper-slide-index');\n });\n }\n }\n swiper.emit('destroy');\n // Detach emitter events\n Object.keys(swiper.eventsListeners).forEach((eventName) => {\n swiper.off(eventName);\n });\n if (deleteInstance !== false) {\n if (swiper.el && typeof swiper.el !== 'string') {\n swiper.el.swiper = null;\n }\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.d)(swiper);\n }\n swiper.destroyed = true;\n return null;\n }\n static extendDefaults(newDefaults) {\n (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.n)(extendedDefaults, newDefaults);\n }\n static installModule(mod) {\n if (!Swiper.prototype.__modules__)\n Swiper.prototype.__modules__ = [];\n const modules = Swiper.prototype.__modules__;\n if (typeof mod === 'function' && modules.indexOf(mod) < 0) {\n modules.push(mod);\n }\n }\n static use(module) {\n if (Array.isArray(module)) {\n module.forEach((m) => Swiper.installModule(m));\n return Swiper;\n }\n Swiper.installModule(module);\n return Swiper;\n }\n}\nObject.defineProperty(Swiper, 'extendedDefaults', {\n get() {\n return extendedDefaults;\n },\n});\nObject.defineProperty(Swiper, 'defaults', {\n get() {\n return defaults;\n },\n});\n// Attach prototype-mixin method groups onto Swiper.prototype. Each group is a\n// plain record of method-name â function; we copy them across as-is.\nconst prototypeRecord = prototypes;\nconst swiperProto = Swiper.prototype;\nObject.keys(prototypeRecord).forEach((prototypeGroup) => {\n const group = prototypeRecord[prototypeGroup];\n Object.keys(group).forEach((protoMethod) => {\n swiperProto[protoMethod] = group[protoMethod];\n });\n});\nSwiper.use([Resize, Observer]);\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/shared/swiper-core.mjs?\n}"); 1515 1516/***/ }, 1517 1518/***/ "./node_modules/swiper/shared/utils.mjs" 1519/*!**********************************************!*\ 1520 !*** ./node_modules/swiper/shared/utils.mjs ***! 1521 \**********************************************/ 1522(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1523 1524"use strict"; 1525eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ a: () => (/* binding */ createElement),\n/* harmony export */ b: () => (/* binding */ elementIndex),\n/* harmony export */ c: () => (/* binding */ classesToTokens),\n/* harmony export */ d: () => (/* binding */ deleteProps),\n/* harmony export */ e: () => (/* binding */ elementChildren),\n/* harmony export */ f: () => (/* binding */ elementIsChildOf),\n/* harmony export */ g: () => (/* binding */ elementNextAll),\n/* harmony export */ h: () => (/* binding */ elementOffset),\n/* harmony export */ i: () => (/* binding */ elementOuterSize),\n/* harmony export */ j: () => (/* binding */ elementParents),\n/* harmony export */ k: () => (/* binding */ elementPrevAll),\n/* harmony export */ l: () => (/* binding */ elementStyle),\n/* harmony export */ m: () => (/* binding */ elementTransitionEnd),\n/* harmony export */ n: () => (/* binding */ extend),\n/* harmony export */ o: () => (/* binding */ getRotateFix),\n/* harmony export */ p: () => (/* binding */ getSlideTransformEl),\n/* harmony export */ q: () => (/* binding */ getTranslate),\n/* harmony export */ r: () => (/* binding */ isObject),\n/* harmony export */ s: () => (/* binding */ makeElementsArray),\n/* harmony export */ t: () => (/* binding */ nextTick),\n/* harmony export */ u: () => (/* binding */ now),\n/* harmony export */ v: () => (/* binding */ setCSSProperty),\n/* harmony export */ w: () => (/* binding */ setInnerHTML),\n/* harmony export */ x: () => (/* binding */ showWarning)\n/* harmony export */ });
1525\nfunction classesToTokens(classes = '') {\n return classes\n .trim()\n .split(' ')\n .filter((c) => !!c.trim());\n}\n\nfunction deleteProps(obj) {\n Object.keys(obj).forEach((key) => {\n try {\n obj[key] = null;\n }\n catch {\n // no getter for object\n }\n try {\n delete obj[key];\n }\n catch {\n // something got wrong\n }\n });\n}\nfunction nextTick(callback, delay = 0) {\n return setTimeout(callback, delay);\n}\nfunction now() {\n return Date.now();\n}\nfunction getComputedStyle(el) {\n return window.getComputedStyle(el, null);\n}\nfunction getTranslate(el, axis = 'x') {\n const style = getComputedStyle(el);\n const transform = style.transform || style.webkitTransform;\n if (!transform || transform === 'none')\n return 0;\n const matrix = new DOMMatrixReadOnly(transform);\n return axis === 'x' ? matrix.m41 : matrix.m42;\n}\nfunction isObject(o) {\n return (typeof o === 'object' &&\n o !== null &&\n o.constructor === Object &&\n Object.prototype.toString.call(o).slice(8, -1) === 'Object');\n}\nfunction isNode(node) {\n if (typeof HTMLElement !== 'undefined' && node instanceof HTMLElement)\n return true;\n return (!!node &&\n typeof node === 'object' &&\n (node.nodeType === 1 || node.nodeType === 11));\n}\nfunction extend(target, ...sources) {\n const to = Object(target);\n for (let i = 0; i < sources.length; i += 1) {\n const nextSource = sources[i];\n if (nextSource === undefined || nextSource === null || isNode(nextSource))\n continue;\n const sourceObj = nextSource;\n const keysArray = Object.keys(Object(sourceObj)).filter((key) => key !== '__proto__' && key !== 'constructor' && key !== 'prototype');\n for (const nextKey of keysArray) {\n const desc = Object.getOwnPropertyDescriptor(sourceObj, nextKey);\n if (!desc || !desc.enumerable)\n continue;\n const sourceVal = sourceObj[nextKey];\n if (isObject(to[nextKey]) && isObject(sourceVal)) {\n if (sourceVal.__swiper__) {\n to[nextKey] = sourceVal;\n }\n else {\n extend(to[nextKey], sourceVal);\n }\n }\n else if (!isObject(to[nextKey]) && isObject(sourceVal)) {\n to[nextKey] = {};\n if (sourceVal.__swiper__) {\n to[nextKey] = sourceVal;\n }\n else {\n extend(to[nextKey], sourceVal);\n }\n }\n else {\n to[nextKey] = sourceVal;\n }\n }\n }\n return to;\n}\nfunction setCSSProperty(el, varName, varValue) {\n el.style.setProperty(varName, varValue);\n}\nfunction getSlideTransformEl(slideEl) {\n const direct = slideEl.querySelector('.swiper-slide-transform');\n if (direct)\n return direct;
1525\n if (slideEl.shadowRoot) {\n const shadowed = slideEl.shadowRoot.querySelector('.swiper-slide-transform');\n if (shadowed)\n return shadowed;\n }\n return slideEl;\n}\nfunction elementChildren(element, selector = '') {\n const children = [...element.children];\n if (element instanceof HTMLSlotElement) {\n children.push(...element.assignedElements());\n }\n return selector ? children.filter((el) => el.matches(selector)) : children;\n}\nfunction elementIsChildOfSlot(el, slot) {\n const queue = [slot];\n while (queue.length > 0) {\n const cur = queue.shift();\n if (el === cur)\n return true;\n queue.push(...cur.children, ...(cur.shadowRoot ? cur.shadowRoot.children : []), ...(cur.assignedElements\n ? cur.assignedElements()\n : []));\n }\n return false;\n}\nfunction elementIsChildOf(el, parent) {\n let isChild = parent.contains(el);\n if (!isChild && parent instanceof HTMLSlotElement) {\n const children = [...parent.assignedElements()];\n isChild = children.includes(el);\n if (!isChild)\n isChild = elementIsChildOfSlot(el, parent);\n }\n return isChild;\n}\nfunction showWarning(text) {\n try {\n console.warn(text);\n }\n catch {\n // err\n }\n}\nfunction createElement(tag, classes = []) {\n const el = document.createElement(tag);\n el.classList.add(...(Array.isArray(classes) ? classes : classesToTokens(classes)));\n return el;\n}\nfunction elementOffset(el) {\n const box = el.getBoundingClientRect();\n return {\n top: box.top + window.scrollY - (el.clientTop || 0),\n left: box.left + window.scrollX - (el.clientLeft || 0),\n };\n}\nfunction elementPrevAll(el, selector) {\n const prevEls = [];\n let prev = el.previousElementSibling;\n while (prev) {\n if (!selector || prev.matches(selector))\n prevEls.push(prev);\n prev = prev.previousElementSibling;\n }\n return prevEls;\n}\nfunction elementNextAll(el, selector) {\n const nextEls = [];\n let next = el.nextElementSibling;\n while (next) {\n if (!selector || next.matches(selector))\n nextEls.push(next);\n next = next.nextElementSibling;\n }\n return nextEls;\n}\nfunction elementStyle(el, prop) {\n return window.getComputedStyle(el, null).getPropertyValue(prop);\n}\nfunction elementIndex(el) {\n if (!el || !el.parentNode)\n return undefined;\n return [...el.parentNode.children].indexOf(el);\n}\nfunction elementParents(el, selector) {\n const parents = [];\n let parent = el.parentElement;\n while (parent) {\n if (!selector || parent.matches(selector))\n parents.push(parent);\n parent = parent.parentElement;\n }\n return parents;\n}\nfunction elementTransitionEnd(el, callback) {\n if (!callback)\n return;\n el.addEventListener('transitionend', function fireCallBack(e) {\n if (e.target !== el)\n return;\n callback.call(el, e);\n }, { once: true });\n}\nfunction elementOuterSize(el, size, includeMargins) {\n {\n const style = window.getComputedStyle(el, null);\n return (el[size === 'width' ? 'offsetWidth' : 'offsetHeight'] +\n parseFloat(style.getPropertyValue(size === 'width' ? 'margin-right' : 'margin-top')) +\n parseFloat(style.getPropertyValue(size === 'width' ? 'margin-left' : 'margin-bottom')));\n }\n}\nfunction makeElementsArray(el) {\n return (Array.isArray(el) ? el : [el]).filter((e) => !!e);\n}\nfunction getRotateFix(swiper) {\n return (v) => {\n if (Math.abs(v) > 0 && swiper.browser && swiper.browser.need3dFix && Math.abs(v) % 90 === 0) {\n return v + 0.001;\n }\n return v;\n };\n}\nfunction setInnerHTML(el, html = '') {\n const tt = globalThis.trustedTypes;\n if (typeof tt !== 'undefined') {\n el.innerHTML = tt.createPolicy('html', { createHTML: (s) => s }).createHTML(html);\n }\n else {\n el.innerHTML = html;\n }\n}\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/shared/utils.mjs?\n}"); 1526 1527/***/ }, 1528 1529/***/ "./node_modules/swiper/swiper.mjs" 1530/*!****************************************!*\ 1531 !*** ./node_modules/swiper/swiper.mjs ***! 1532 \****************************************/ 1533(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { 1534 1535"use strict"; 1536eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Swiper: () => (/* reexport safe */ _shared_swiper_core_mjs__WEBPACK_IMPORTED_MODULE_0__.S),\
vendor: 4,558 bytes, lines 1536-1636
1536n/* harmony export */ \"default\": () => (/* reexport safe */ _shared_swiper_core_mjs__WEBPACK_IMPORTED_MODULE_0__.S)\n/* harmony export */ });\n/* harmony import */ var _shared_swiper_core_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./shared/swiper-core.mjs */ \"./node_modules/swiper/shared/swiper-core.mjs\");\n/**\n * Swiper 14.0.5\n * Most modern mobile touch slider and framework with hardware accelerated transitions\n * https://swiperjs.com\n *\n * Copyright 2014-2026 Vladimir Kharlampidi\n *\n * Released under the MIT License\n *\n * Released on: July 9, 2026\n */\n\n\n\n\n//# sourceURL=webpack://gotbagtheme/./node_modules/swiper/swiper.mjs?\n}"); 1537 1538/***/ } 1539 1540/******/ }); 1541/************************************************************************/ 1542/******/ // The module cache 1543/******/ const __webpack_module_cache__ = {}; 1544/******/ 1545/******/ // The require function 1546/******/ function __webpack_require__(moduleId) { 1547/******/ // Check if module is in cache 1548/******/ const cachedModule = __webpack_module_cache__[moduleId]; 1549/******/ if (cachedModule !== undefined) { 1550/******/ return cachedModule.exports; 1551/******/ } 1552/******/ // Create a new module (and put it into the cache) 1553/******/ const module = __webpack_module_cache__[moduleId] = { 1554/******/ // no module.id needed 1555/******/ // no module.loaded needed 1556/******/ exports: {} 1557/******/ }; 1558/******/ 1559/******/ // Execute the module function 1560/******/ if (!(moduleId in __webpack_modules__)) { 1561/******/ delete __webpack_module_cache__[moduleId]; 1562/******/ const e = new Error("Cannot find module '" + moduleId + "'"); 1563/******/ e.code = 'MODULE_NOT_FOUND'; 1564/******/ throw e; 1565/******/ } 1566/******/ __webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__); 1567/******/ 1568/******/ // Return the exports of the module 1569/******/ return module.exports; 1570/******/ } 1571/******/ 1572/************************************************************************/ 1573/******/ /* webpack/runtime/compat get default export */ 1574/******/ (() => { 1575/******/ // getDefaultExport function for compatibility with non-harmony modules 1576/******/ __webpack_require__.n = (module) => { 1577/******/ const getter = module && module.__esModule ? 1578/******/ () => (module['default']) : 1579/******/ () => (module); 1580/******/ __webpack_require__.d(getter, { a: getter }); 1581/******/ return getter; 1582/******/ }; 1583/******/ })(); 1584/******/ 1585/******/ /* webpack/runtime/define property getters */ 1586/******/ (() => { 1587/******/ // define getter/value functions for harmony exports 1588/******/ __webpack_require__.d = (exports, definition) => { 1589/******/ if(Array.isArray(definition)) { 1590/******/ var i = 0; 1591/******/ while(i < definition.length) { 1592/******/ var key = definition[i++]; 1593/******/ var binding = definition[i++]; 1594/******/ if(!__webpack_require__.o(exports, key)) { 1595/******/ if(binding === 0) { 1596/******/ Object.defineProperty(exports, key, { enumerable: true, value: definition[i++] }); 1597/******/ } else { 1598/******/ Object.defineProperty(exports, key, { enumerable: true, get: binding }); 1599/******/ } 1600/******/ } else if(binding === 0) { i++; } 1601/******/ } 1602/******/ } else { 1603/******/ for(var key in definition) { 1604/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 1605/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); 1606/******/ } 1607/******/ } 1608/******/ } 1609/******/ }; 1610/******/ })(); 1611/******/ 1612/******/ /* webpack/runtime/hasOwnProperty shorthand */ 1613/******/ (() => { 1614/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) 1615/******/ })(); 1616/******/ 1617/******/ /* webpack/runtime/make namespace object */ 1618/******/ (() => { 1619/******/ // define __esModule on exports 1620/******/ __webpack_require__.r = (exports) => { 1621/******/ if(Symbol.toStringTag) { 1622/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); 1623/******/ } 1624/******/ Object.defineProperty(exports, '__esModule', { value: true }); 1625/******/ }; 1626/******/ })(); 1627/******/ 1628/************************************************************************/ 1629/******/ 1630/******/ // startup 1631/******/ // Load entry module and return exports 1632/******/ // This entry module can't be inlined because the eval devtool is used. 1633/******/ let __webpack_exports__ = __webpack_require__("./dev/js/app.js"); 1634/******/ 1635/******/ })() 1636;
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.