@letscooee/web-sdk 11.0.0 → 11.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunk-HUUMC22E.js +29 -0
- package/dist/main.min.js +29 -29
- package/dist/video-detail-dialog.component-ME6ASA7O.js +3 -0
- package/dist/widget.min.css +1 -1
- package/dist/widget.min.js +17 -18
- package/package.json +2 -2
- package/dist/chunk-F2TELYIQ.js +0 -27
- package/dist/video-detail-dialog.component-UWZTKDH6.js +0 -3
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import{$a as Si,Aa as bt,Ab as ul,B as lt,Ba as Or,Bb as fl,C as Ze,Ca as ne,Cb as Ti,Da as qc,Db as Jt,E as xt,Ea as Kc,Eb as Pt,Fa as Jc,Ga as Zc,Gb as xi,H as Tr,Ha as Qc,Hb as Rr,I as ut,Ib as dl,J as Gc,Jb as Mr,K as Wt,Ka as Xt,Kb as pl,L as cn,Lb as hl,Ma as Ar,Mb as Oi,N as $,Na as Ei,Oa as bi,Pa as we,Q as vi,Qa as un,Ra as Wn,S as Hn,T as xr,U as ns,V as rs,Va as Rt,W as ve,Wa as Mt,X as Sn,Xa as Qe,Y as jn,Ya as el,Z as Wc,Za as tl,_ as Cn,_a as wi,a as Lc,aa as Ot,ab as Ci,ba as vt,bb as wt,c as Ke,ca as Et,cb as St,d as Fc,da as ln,ea as is,eb as Dr,fa as At,g as kc,ga as Ee,gb as qt,ha as be,hb as Kt,i as Bc,ib as fn,ja as $n,jb as Ge,ka as Gn,l as Vc,la as De,lb as Nr,m as Uc,ma as ce,mb as os,n as Hc,na as ue,o as jc,oa as ft,pa as Ue,pb as nl,q as $c,qa as We,qb as rl,ra as Yt,rb as il,s as Be,sb as ol,t as wn,tb as sl,u as Je,ua as zt,v as U,va as Yc,vb as al,w as yi,wa as zc,x as tt,xa as Xc,xb as cl,y as nt,ya as Dt,yb as Ii,za as Nt,zb as ll}from"./chunk-WCCK4F5X.js";import{a as I,b as K,c as Ir,d as Pc,e as es,f as ts,g as _i}from"./chunk-V7UGKYBN.js";var _l=es((gl,Di)=>{"use strict";(function(t){"use strict";var e={};e.VERSION="1.6.1";var n,r={},i=function(d,_){return function(){return _.apply(d,arguments)}},o=function(){var d=arguments,_=d[0],p,v;for(v=1;v<d.length;v++)for(p in d[v])!(p in _)&&d[v].hasOwnProperty(p)&&(_[p]=d[v][p]);return _},s=function(d,_){return{value:d,name:_}};e.TRACE=s(1,"TRACE"),e.DEBUG=s(2,"DEBUG"),e.INFO=s(3,"INFO"),e.TIME=s(4,"TIME"),e.WARN=s(5,"WARN"),e.ERROR=s(8,"ERROR"),e.OFF=s(99,"OFF");var l=function(d){this.context=d,this.setLevel(d.filterLevel),this.log=this.info};l.prototype={setLevel:function(d){d&&"value"in d&&(this.context.filterLevel=d)},getLevel:function(){return this.context.filterLevel},enabledFor:function(d){var _=this.context.filterLevel;return d.value>=_.value},trace:function(){this.invoke(e.TRACE,arguments)},debug:function(){this.invoke(e.DEBUG,arguments)},info:function(){this.invoke(e.INFO,arguments)},warn:function(){this.invoke(e.WARN,arguments)},error:function(){this.invoke(e.ERROR,arguments)},time:function(d){typeof d=="string"&&d.length>0&&this.invoke(e.TIME,[d,"start"])},timeEnd:function(d){typeof d=="string"&&d.length>0&&this.invoke(e.TIME,[d,"end"])},invoke:function(d,_){n&&this.enabledFor(d)&&n(_,o({level:d},this.context))}};var u=new l({filterLevel:e.OFF});(function(){var d=e;d.enabledFor=i(u,u.enabledFor),d.trace=i(u,u.trace),d.debug=i(u,u.debug),d.time=i(u,u.time),d.timeEnd=i(u,u.timeEnd),d.info=i(u,u.info),d.warn=i(u,u.warn),d.error=i(u,u.error),d.log=d.info})(),e.setHandler=function(d){n=d},e.setLevel=function(d){u.setLevel(d);for(var _ in r)r.hasOwnProperty(_)&&r[_].setLevel(d)},e.getLevel=function(){return u.getLevel()},e.get=function(d){return r[d]||(r[d]=new l(o({name:d},u.context)))},e.createDefaultHandler=function(d){d=d||{},d.formatter=d.formatter||function(E,T){T.name&&E.unshift("["+T.name+"]")};var _={},p=function(v,E){Function.prototype.apply.call(v,console,E)};return typeof console>"u"?function(){}:function(v,E){v=Array.prototype.slice.call(v);var T=console.log,N;E.level===e.TIME?(N=(E.name?"["+E.name+"] ":"")+v[0],v[1]==="start"?console.time?console.time(N):_[N]=new Date().getTime():console.timeEnd?console.timeEnd(N):p(T,[N+": "+(new Date().getTime()-_[N])+"ms"])):(E.level===e.WARN&&console.warn?T=console.warn:E.level===e.ERROR&&console.error?T=console.error:E.level===e.INFO&&console.info?T=console.info:E.level===e.DEBUG&&console.debug?T=console.debug:E.level===e.TRACE&&console.trace&&(T=console.trace),d.formatter(v,E),p(T,v))}},e.useDefaults=function(d){e.setLevel(d&&d.defaultLevel||e.DEBUG),e.setHandler(e.createDefaultHandler(d))},e.setDefaults=e.useDefaults,typeof define=="function"&&define.amd?define(e):typeof Di<"u"&&Di.exports?Di.exports=e:(e._prevLogger=t.Logger,e.noConflict=function(){return t.Logger=e._prevLogger,e},t.Logger=e)})(gl)});var nu=es((tu,ws)=>{"use strict";(function(t){if(typeof tu=="object"&&typeof ws<"u")ws.exports=t();else if(typeof define=="function"&&define.amd)define([],t);else{var e;typeof window<"u"?e=window:typeof global<"u"?e=global:typeof self<"u"?e=self:e=this,e.localforage=t()}})(function(){var t,e,n;return(function r(i,o,s){function l(_,p){if(!o[_]){if(!i[_]){var v=typeof Ir=="function"&&Ir;if(!p&&v)return v(_,!0);if(u)return u(_,!0);var E=new Error("Cannot find module '"+_+"'");throw E.code="MODULE_NOT_FOUND",E}var T=o[_]={exports:{}};i[_][0].call(T.exports,function(N){var F=i[_][1][N];return l(F||N)},T,T.exports,r,i,o,s)}return o[_].exports}for(var u=typeof Ir=="function"&&Ir,d=0;d<s.length;d++)l(s[d]);return l})({1:[function(r,i,o){(function(s){"use strict";var l=s.MutationObserver||s.WebKitMutationObserver,u;if(l){var d=0,_=new l(N),p=s.document.createTextNode("");_.observe(p,{characterData:!0}),u=function(){p.data=d=++d%2}}else if(!s.setImmediate&&typeof s.MessageChannel<"u"){var v=new s.MessageChannel;v.port1.onmessage=N,u=function(){v.port2.postMessage(0)}}else"document"in s&&"onreadystatechange"in s.document.createElement("script")?u=function(){var B=s.document.createElement("script");B.onreadystatechange=function(){N(),B.onreadystatechange=null,B.parentNode.removeChild(B),B=null},s.document.documentElement.appendChild(B)}:u=function(){setTimeout(N,0)};var E,T=[];function N(){E=!0;for(var B,k,W=T.length;W;){for(k=T,T=[],B=-1;++B<W;)k[B]();W=T.length}E=!1}i.exports=F;function F(B){T.push(B)===1&&!E&&u()}}).call(this,typeof global<"u"?global:typeof self<"u"?self:typeof window<"u"?window:{})},{}],2:[function(r,i,o){"use strict";var s=r(1);function l(){}var u={},d=["REJECTED"],_=["FULFILLED"],p=["PENDING"];i.exports=v;function v(P){if(typeof P!="function")throw new TypeError("resolver must be a function");this.state=p,this.queue=[],this.outcome=void 0,P!==l&&F(this,P)}v.prototype.catch=function(P){return this.then(null,P)},v.prototype.then=function(P,q){if(typeof P!="function"&&this.state===_||typeof q!="function"&&this.state===d)return this;var z=new this.constructor(l);if(this.state!==p){var J=this.state===_?P:q;T(z,J,this.outcome)}else this.queue.push(new E(z,P,q));return z};function E(P,q,z){this.promise=P,typeof q=="function"&&(this.onFulfilled=q,this.callFulfilled=this.otherCallFulfilled),typeof z=="function"&&(this.onRejected=z,this.callRejected=this.otherCallRejected)}E.prototype.callFulfilled=function(P){u.resolve(this.promise,P)},E.prototype.otherCallFulfilled=function(P){T(this.promise,this.onFulfilled,P)},E.prototype.callRejected=function(P){u.reject(this.promise,P)},E.prototype.otherCallRejected=function(P){T(this.promise,this.onRejected,P)};function T(P,q,z){s(function(){var J;try{J=q(z)}catch(me){return u.reject(P,me)}J===P?u.reject(P,new TypeError("Cannot resolve promise with itself")):u.resolve(P,J)})}u.resolve=function(P,q){var z=B(N,q);if(z.status==="error")return u.reject(P,z.value);var J=z.value;if(J)F(P,J);else{P.state=_,P.outcome=q;for(var me=-1,se=P.queue.length;++me<se;)P.queue[me].callFulfilled(q)}return P},u.reject=function(P,q){P.state=d,P.outcome=q;for(var z=-1,J=P.queue.length;++z<J;)P.queue[z].callRejected(q);return P};function N(P){var q=P&&P.then;if(P&&(typeof P=="object"||typeof P=="function")&&typeof q=="function")return function(){q.apply(P,arguments)}}function F(P,q){var z=!1;function J(Oe){z||(z=!0,u.reject(P,Oe))}function me(Oe){z||(z=!0,u.resolve(P,Oe))}function se(){q(me,J)}var ge=B(se);ge.status==="error"&&J(ge.value)}function B(P,q){var z={};try{z.value=P(q),z.status="success"}catch(J){z.status="error",z.value=J}return z}v.resolve=k;function k(P){return P instanceof this?P:u.resolve(new this(l),P)}v.reject=W;function W(P){var q=new this(l);return u.reject(q,P)}v.all=V;function V(P){var q=this;if(Object.prototype.toString.call(P)!=="[object Array]")return this.reject(new TypeError("must be an array"));var z=P.length,J=!1;if(!z)return this.resolve([]);for(var me=new Array(z),se=0,ge=-1,Oe=new this(l);++ge<z;)Fe(P[ge],ge);return Oe;function Fe(Tt,yt){q.resolve(Tt).then(pe,function(ke){J||(J=!0,u.reject(Oe,ke))});function pe(ke){me[yt]=ke,++se===z&&!J&&(J=!0,u.resolve(Oe,me))}}}v.race=he;function he(P){var q=this;if(Object.prototype.toString.call(P)!=="[object Array]")return this.reject(new TypeError("must be an array"));var z=P.length,J=!1;if(!z)return this.resolve([]);for(var me=-1,se=new this(l);++me<z;)ge(P[me]);return se;function ge(Oe){q.resolve(Oe).then(function(Fe){J||(J=!0,u.resolve(se,Fe))},function(Fe){J||(J=!0,u.reject(se,Fe))})}}},{1:1}],3:[function(r,i,o){(function(s){"use strict";typeof s.Promise!="function"&&(s.Promise=r(2))}).call(this,typeof global<"u"?global:typeof self<"u"?self:typeof window<"u"?window:{})},{2:2}],4:[function(r,i,o){"use strict";var s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(f){return typeof f}:function(f){return f&&typeof Symbol=="function"&&f.constructor===Symbol&&f!==Symbol.prototype?"symbol":typeof f};function l(f,y){if(!(f instanceof y))throw new TypeError("Cannot call a class as a function")}function u(){try{if(typeof indexedDB<"u")return indexedDB;if(typeof webkitIndexedDB<"u")return webkitIndexedDB;if(typeof mozIndexedDB<"u")return mozIndexedDB;if(typeof OIndexedDB<"u")return OIndexedDB;if(typeof msIndexedDB<"u")return msIndexedDB}catch{return}}var d=u();function _(){try{if(!d||!d.open)return!1;var f=typeof openDatabase<"u"&&/(Safari|iPhone|iPad|iPod)/.test(navigator.userAgent)&&!/Chrome/.test(navigator.userAgent)&&!/BlackBerry/.test(navigator.platform),y=typeof fetch=="function"&&fetch.toString().indexOf("[native code")!==-1;return(!f||y)&&typeof indexedDB<"u"&&typeof IDBKeyRange<"u"}catch{return!1}}function p(f,y){f=f||[],y=y||{};try{return new Blob(f,y)}catch(b){if(b.name!=="TypeError")throw b;for(var m=typeof BlobBuilder<"u"?BlobBuilder:typeof MSBlobBuilder<"u"?MSBlobBuilder:typeof MozBlobBuilder<"u"?MozBlobBuilder:WebKitBlobBuilder,w=new m,S=0;S<f.length;S+=1)w.append(f[S]);return w.getBlob(y.type)}}typeof Promise>"u"&&r(3);var v=Promise;function E(f,y){y&&f.then(function(m){y(null,m)},function(m){y(m)})}function T(f,y,m){typeof y=="function"&&f.then(y),typeof m=="function"&&f.catch(m)}function N(f){return typeof f!="string"&&(console.warn(f+" used as a key, but it is not a string."),f=String(f)),f}function F(){if(arguments.length&&typeof arguments[arguments.length-1]=="function")return arguments[arguments.length-1]}var B="local-forage-detect-blob-support",k=void 0,W={},V=Object.prototype.toString,he="readonly",P="readwrite";function q(f){for(var y=f.length,m=new ArrayBuffer(y),w=new Uint8Array(m),S=0;S<y;S++)w[S]=f.charCodeAt(S);return m}function z(f){return new v(function(y){var m=f.transaction(B,P),w=p([""]);m.objectStore(B).put(w,"key"),m.onabort=function(S){S.preventDefault(),S.stopPropagation(),y(!1)},m.oncomplete=function(){var S=navigator.userAgent.match(/Chrome\/(\d+)/),b=navigator.userAgent.match(/Edge\//);y(b||!S||parseInt(S[1],10)>=43)}}).catch(function(){return!1})}function J(f){return typeof k=="boolean"?v.resolve(k):z(f).then(function(y){return k=y,k})}function me(f){var y=W[f.name],m={};m.promise=new v(function(w,S){m.resolve=w,m.reject=S}),y.deferredOperations.push(m),y.dbReady?y.dbReady=y.dbReady.then(function(){return m.promise}):y.dbReady=m.promise}function se(f){var y=W[f.name],m=y.deferredOperations.pop();if(m)return m.resolve(),m.promise}function ge(f,y){var m=W[f.name],w=m.deferredOperations.pop();if(w)return w.reject(y),w.promise}function Oe(f,y){return new v(function(m,w){if(W[f.name]=W[f.name]||yr(),f.db)if(y)me(f),f.db.close();else return m(f.db);var S=[f.name];y&&S.push(f.version);var b=d.open.apply(d,S);y&&(b.onupgradeneeded=function(x){var A=b.result;try{A.createObjectStore(f.storeName),x.oldVersion<=1&&A.createObjectStore(B)}catch(R){if(R.name==="ConstraintError")console.warn('The database "'+f.name+'" has been upgraded from version '+x.oldVersion+" to version "+x.newVersion+', but the storage "'+f.storeName+'" already exists.');else throw R}}),b.onerror=function(x){x.preventDefault(),w(b.error)},b.onsuccess=function(){var x=b.result;x.onversionchange=function(A){A.target.close()},m(x),se(f)}})}function Fe(f){return Oe(f,!1)}function Tt(f){return Oe(f,!0)}function yt(f,y){if(!f.db)return!0;var m=!f.db.objectStoreNames.contains(f.storeName),w=f.version<f.db.version,S=f.version>f.db.version;if(w&&(f.version!==y&&console.warn('The database "'+f.name+`" can't be downgraded from version `+f.db.version+" to version "+f.version+"."),f.version=f.db.version),S||m){if(m){var b=f.db.version+1;b>f.version&&(f.version=b)}return!0}return!1}function pe(f){return new v(function(y,m){var w=new FileReader;w.onerror=m,w.onloadend=function(S){var b=btoa(S.target.result||"");y({__local_forage_encoded_blob:!0,data:b,type:f.type})},w.readAsBinaryString(f)})}function ke(f){var y=q(atob(f.data));return p([y],{type:f.type})}function te(f){return f&&f.__local_forage_encoded_blob}function Z(f){var y=this,m=y._initReady().then(function(){var w=W[y._dbInfo.name];if(w&&w.dbReady)return w.dbReady});return T(m,f,f),m}function $e(f){me(f);for(var y=W[f.name],m=y.forages,w=0;w<m.length;w++){var S=m[w];S._dbInfo.db&&(S._dbInfo.db.close(),S._dbInfo.db=null)}return f.db=null,Fe(f).then(function(b){return f.db=b,yt(f)?Tt(f):b}).then(function(b){f.db=y.db=b;for(var x=0;x<m.length;x++)m[x]._dbInfo.db=b}).catch(function(b){throw ge(f,b),b})}function st(f,y,m,w){w===void 0&&(w=1);try{var S=f.db.transaction(f.storeName,y);m(null,S)}catch(b){if(w>0&&(!f.db||b.name==="InvalidStateError"||b.name==="NotFoundError"))return v.resolve().then(function(){if(!f.db||b.name==="NotFoundError"&&!f.db.objectStoreNames.contains(f.storeName)&&f.version<=f.db.version)return f.db&&(f.version=f.db.version+1),Tt(f)}).then(function(){return $e(f).then(function(){st(f,y,m,w-1)})}).catch(m);m(b)}}function yr(){return{forages:[],db:null,dbReady:null,deferredOperations:[]}}function hi(f){var y=this,m={db:null};if(f)for(var w in f)m[w]=f[w];var S=W[m.name];S||(S=yr(),W[m.name]=S),S.forages.push(y),y._initReady||(y._initReady=y.ready,y.ready=Z);var b=[];function x(){return v.resolve()}for(var A=0;A<S.forages.length;A++){var R=S.forages[A];R!==y&&b.push(R._initReady().catch(x))}var M=S.forages.slice(0);return v.all(b).then(function(){return m.db=S.db,Fe(m)}).then(function(L){return m.db=L,yt(m,y._defaultConfig.version)?Tt(m):L}).then(function(L){m.db=S.db=L,y._dbInfo=m;for(var j=0;j<M.length;j++){var Q=M[j];Q!==y&&(Q._dbInfo.db=m.db,Q._dbInfo.version=m.version)}})}function $o(f,y){var m=this;f=N(f);var w=new v(function(S,b){m.ready().then(function(){st(m._dbInfo,he,function(x,A){if(x)return b(x);try{var R=A.objectStore(m._dbInfo.storeName),M=R.get(f);M.onsuccess=function(){var L=M.result;L===void 0&&(L=null),te(L)&&(L=ke(L)),S(L)},M.onerror=function(){b(M.error)}}catch(L){b(L)}})}).catch(b)});return E(w,y),w}function Go(f,y){var m=this,w=new v(function(S,b){m.ready().then(function(){st(m._dbInfo,he,function(x,A){if(x)return b(x);try{var R=A.objectStore(m._dbInfo.storeName),M=R.openCursor(),L=1;M.onsuccess=function(){var j=M.result;if(j){var Q=j.value;te(Q)&&(Q=ke(Q));var oe=f(Q,j.key,L++);oe!==void 0?S(oe):j.continue()}else S()},M.onerror=function(){b(M.error)}}catch(j){b(j)}})}).catch(b)});return E(w,y),w}function vr(f,y,m){var w=this;f=N(f);var S=new v(function(b,x){var A;w.ready().then(function(){return A=w._dbInfo,V.call(y)==="[object Blob]"?J(A.db).then(function(R){return R?y:pe(y)}):y}).then(function(R){st(w._dbInfo,P,function(M,L){if(M)return x(M);try{var j=L.objectStore(w._dbInfo.storeName);R===null&&(R=void 0);var Q=j.put(R,f);L.oncomplete=function(){R===void 0&&(R=null),b(R)},L.onabort=L.onerror=function(){var oe=Q.error?Q.error:Q.transaction.error;x(oe)}}catch(oe){x(oe)}})}).catch(x)});return E(S,m),S}function Wo(f,y){var m=this;f=N(f);var w=new v(function(S,b){m.ready().then(function(){st(m._dbInfo,P,function(x,A){if(x)return b(x);try{var R=A.objectStore(m._dbInfo.storeName),M=R.delete(f);A.oncomplete=function(){S()},A.onerror=function(){b(M.error)},A.onabort=function(){var L=M.error?M.error:M.transaction.error;b(L)}}catch(L){b(L)}})}).catch(b)});return E(w,y),w}function Yo(f){var y=this,m=new v(function(w,S){y.ready().then(function(){st(y._dbInfo,P,function(b,x){if(b)return S(b);try{var A=x.objectStore(y._dbInfo.storeName),R=A.clear();x.oncomplete=function(){w()},x.onabort=x.onerror=function(){var M=R.error?R.error:R.transaction.error;S(M)}}catch(M){S(M)}})}).catch(S)});return E(m,f),m}function mi(f){var y=this,m=new v(function(w,S){y.ready().then(function(){st(y._dbInfo,he,function(b,x){if(b)return S(b);try{var A=x.objectStore(y._dbInfo.storeName),R=A.count();R.onsuccess=function(){w(R.result)},R.onerror=function(){S(R.error)}}catch(M){S(M)}})}).catch(S)});return E(m,f),m}function Vn(f,y){var m=this,w=new v(function(S,b){if(f<0){S(null);return}m.ready().then(function(){st(m._dbInfo,he,function(x,A){if(x)return b(x);try{var R=A.objectStore(m._dbInfo.storeName),M=!1,L=R.openKeyCursor();L.onsuccess=function(){var j=L.result;if(!j){S(null);return}f===0||M?S(j.key):(M=!0,j.advance(f))},L.onerror=function(){b(L.error)}}catch(j){b(j)}})}).catch(b)});return E(w,y),w}function at(f){var y=this,m=new v(function(w,S){y.ready().then(function(){st(y._dbInfo,he,function(b,x){if(b)return S(b);try{var A=x.objectStore(y._dbInfo.storeName),R=A.openKeyCursor(),M=[];R.onsuccess=function(){var L=R.result;if(!L){w(M);return}M.push(L.key),L.continue()},R.onerror=function(){S(R.error)}}catch(L){S(L)}})}).catch(S)});return E(m,f),m}function Er(f,y){y=F.apply(this,arguments);var m=this.config();f=typeof f!="function"&&f||{},f.name||(f.name=f.name||m.name,f.storeName=f.storeName||m.storeName);var w=this,S;if(!f.name)S=v.reject("Invalid arguments");else{var b=f.name===m.name&&w._dbInfo.db,x=b?v.resolve(w._dbInfo.db):Fe(f).then(function(A){var R=W[f.name],M=R.forages;R.db=A;for(var L=0;L<M.length;L++)M[L]._dbInfo.db=A;return A});f.storeName?S=x.then(function(A){if(A.objectStoreNames.contains(f.storeName)){var R=A.version+1;me(f);var M=W[f.name],L=M.forages;A.close();for(var j=0;j<L.length;j++){var Q=L[j];Q._dbInfo.db=null,Q._dbInfo.version=R}var oe=new v(function(ae,xe){var Ie=d.open(f.name,R);Ie.onerror=function(ct){var Cr=Ie.result;Cr.close(),xe(ct)},Ie.onupgradeneeded=function(){var ct=Ie.result;ct.deleteObjectStore(f.storeName)},Ie.onsuccess=function(){var ct=Ie.result;ct.close(),ae(ct)}});return oe.then(function(ae){M.db=ae;for(var xe=0;xe<L.length;xe++){var Ie=L[xe];Ie._dbInfo.db=ae,se(Ie._dbInfo)}}).catch(function(ae){throw(ge(f,ae)||v.resolve()).catch(function(){}),ae})}}):S=x.then(function(A){me(f);var R=W[f.name],M=R.forages;A.close();for(var L=0;L<M.length;L++){var j=M[L];j._dbInfo.db=null}var Q=new v(function(oe,ae){var xe=d.deleteDatabase(f.name);xe.onerror=function(){var Ie=xe.result;Ie&&Ie.close(),ae(xe.error)},xe.onblocked=function(){console.warn('dropInstance blocked for database "'+f.name+'" until all open connections are closed')},xe.onsuccess=function(){var Ie=xe.result;Ie&&Ie.close(),oe(Ie)}});return Q.then(function(oe){R.db=oe;for(var ae=0;ae<M.length;ae++){var xe=M[ae];se(xe._dbInfo)}}).catch(function(oe){throw(ge(f,oe)||v.resolve()).catch(function(){}),oe})})}return E(S,y),S}var zo={_driver:"asyncStorage",_initStorage:hi,_support:_(),iterate:Go,getItem:$o,setItem:vr,removeItem:Wo,clear:Yo,length:mi,key:Vn,keys:at,dropInstance:Er};function h(){return typeof openDatabase=="function"}var a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",c="~~local_forage_type~",g=/^~~local_forage_type~([^~]+)~/,C="__lfsc__:",O=C.length,D="arbf",ee="blob",ie="si08",le="ui08",Ae="uic8",_e="si16",bn="si32",br="ur16",wr="ui32",Sc="fl32",Cc="fl64",Ic=O+D.length,Tc=Object.prototype.toString;function xc(f){var y=f.length*.75,m=f.length,w,S=0,b,x,A,R;f[f.length-1]==="="&&(y--,f[f.length-2]==="="&&y--);var M=new ArrayBuffer(y),L=new Uint8Array(M);for(w=0;w<m;w+=4)b=a.indexOf(f[w]),x=a.indexOf(f[w+1]),A=a.indexOf(f[w+2]),R=a.indexOf(f[w+3]),L[S++]=b<<2|x>>4,L[S++]=(x&15)<<4|A>>2,L[S++]=(A&3)<<6|R&63;return M}function Xo(f){var y=new Uint8Array(f),m="",w;for(w=0;w<y.length;w+=3)m+=a[y[w]>>2],m+=a[(y[w]&3)<<4|y[w+1]>>4],m+=a[(y[w+1]&15)<<2|y[w+2]>>6],m+=a[y[w+2]&63];return y.length%3===2?m=m.substring(0,m.length-1)+"=":y.length%3===1&&(m=m.substring(0,m.length-2)+"=="),m}function np(f,y){var m="";if(f&&(m=Tc.call(f)),f&&(m==="[object ArrayBuffer]"||f.buffer&&Tc.call(f.buffer)==="[object ArrayBuffer]")){var w,S=C;f instanceof ArrayBuffer?(w=f,S+=D):(w=f.buffer,m==="[object Int8Array]"?S+=ie:m==="[object Uint8Array]"?S+=le:m==="[object Uint8ClampedArray]"?S+=Ae:m==="[object Int16Array]"?S+=_e:m==="[object Uint16Array]"?S+=br:m==="[object Int32Array]"?S+=bn:m==="[object Uint32Array]"?S+=wr:m==="[object Float32Array]"?S+=Sc:m==="[object Float64Array]"?S+=Cc:y(new Error("Failed to get type for BinaryArray"))),y(S+Xo(w))}else if(m==="[object Blob]"){var b=new FileReader;b.onload=function(){var x=c+f.type+"~"+Xo(this.result);y(C+ee+x)},b.readAsArrayBuffer(f)}else try{y(JSON.stringify(f))}catch(x){console.error("Couldn't convert value into a JSON string: ",f),y(null,x)}}function rp(f){if(f.substring(0,O)!==C)return JSON.parse(f);var y=f.substring(Ic),m=f.substring(O,Ic),w;if(m===ee&&g.test(y)){var S=y.match(g);w=S[1],y=y.substring(S[0].length)}var b=xc(y);switch(m){case D:return b;case ee:return p([b],{type:w});case ie:return new Int8Array(b);case le:return new Uint8Array(b);case Ae:return new Uint8ClampedArray(b);case _e:return new Int16Array(b);case br:return new Uint16Array(b);case bn:return new Int32Array(b);case wr:return new Uint32Array(b);case Sc:return new Float32Array(b);case Cc:return new Float64Array(b);default:throw new Error("Unkown type: "+m)}}var qo={serialize:np,deserialize:rp,stringToBuffer:xc,bufferToString:Xo};function Oc(f,y,m,w){f.executeSql("CREATE TABLE IF NOT EXISTS "+y.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],m,w)}function ip(f){var y=this,m={db:null};if(f)for(var w in f)m[w]=typeof f[w]!="string"?f[w].toString():f[w];var S=new v(function(b,x){try{m.db=openDatabase(m.name,String(m.version),m.description,m.size)}catch(A){return x(A)}m.db.transaction(function(A){Oc(A,m,function(){y._dbInfo=m,b()},function(R,M){x(M)})},x)});return m.serializer=qo,S}function an(f,y,m,w,S,b){f.executeSql(m,w,S,function(x,A){A.code===A.SYNTAX_ERR?x.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name = ?",[y.storeName],function(R,M){M.rows.length?b(R,A):Oc(R,y,function(){R.executeSql(m,w,S,b)},b)},b):b(x,A)},b)}function op(f,y){var m=this;f=N(f);var w=new v(function(S,b){m.ready().then(function(){var x=m._dbInfo;x.db.transaction(function(A){an(A,x,"SELECT * FROM "+x.storeName+" WHERE key = ? LIMIT 1",[f],function(R,M){var L=M.rows.length?M.rows.item(0).value:null;L&&(L=x.serializer.deserialize(L)),S(L)},function(R,M){b(M)})})}).catch(b)});return E(w,y),w}function sp(f,y){var m=this,w=new v(function(S,b){m.ready().then(function(){var x=m._dbInfo;x.db.transaction(function(A){an(A,x,"SELECT * FROM "+x.storeName,[],function(R,M){for(var L=M.rows,j=L.length,Q=0;Q<j;Q++){var oe=L.item(Q),ae=oe.value;if(ae&&(ae=x.serializer.deserialize(ae)),ae=f(ae,oe.key,Q+1),ae!==void 0){S(ae);return}}S()},function(R,M){b(M)})})}).catch(b)});return E(w,y),w}function Ac(f,y,m,w){var S=this;f=N(f);var b=new v(function(x,A){S.ready().then(function(){y===void 0&&(y=null);var R=y,M=S._dbInfo;M.serializer.serialize(y,function(L,j){j?A(j):M.db.transaction(function(Q){an(Q,M,"INSERT OR REPLACE INTO "+M.storeName+" (key, value) VALUES (?, ?)",[f,L],function(){x(R)},function(oe,ae){A(ae)})},function(Q){if(Q.code===Q.QUOTA_ERR){if(w>0){x(Ac.apply(S,[f,R,m,w-1]));return}A(Q)}})})}).catch(A)});return E(b,m),b}function ap(f,y,m){return Ac.apply(this,[f,y,m,1])}function cp(f,y){var m=this;f=N(f);var w=new v(function(S,b){m.ready().then(function(){var x=m._dbInfo;x.db.transaction(function(A){an(A,x,"DELETE FROM "+x.storeName+" WHERE key = ?",[f],function(){S()},function(R,M){b(M)})})}).catch(b)});return E(w,y),w}function lp(f){var y=this,m=new v(function(w,S){y.ready().then(function(){var b=y._dbInfo;b.db.transaction(function(x){an(x,b,"DELETE FROM "+b.storeName,[],function(){w()},function(A,R){S(R)})})}).catch(S)});return E(m,f),m}function up(f){var y=this,m=new v(function(w,S){y.ready().then(function(){var b=y._dbInfo;b.db.transaction(function(x){an(x,b,"SELECT COUNT(key) as c FROM "+b.storeName,[],function(A,R){var M=R.rows.item(0).c;w(M)},function(A,R){S(R)})})}).catch(S)});return E(m,f),m}function fp(f,y){var m=this,w=new v(function(S,b){m.ready().then(function(){var x=m._dbInfo;x.db.transaction(function(A){an(A,x,"SELECT key FROM "+x.storeName+" WHERE id = ? LIMIT 1",[f+1],function(R,M){var L=M.rows.length?M.rows.item(0).key:null;S(L)},function(R,M){b(M)})})}).catch(b)});return E(w,y),w}function dp(f){var y=this,m=new v(function(w,S){y.ready().then(function(){var b=y._dbInfo;b.db.transaction(function(x){an(x,b,"SELECT key FROM "+b.storeName,[],function(A,R){for(var M=[],L=0;L<R.rows.length;L++)M.push(R.rows.item(L).key);w(M)},function(A,R){S(R)})})}).catch(S)});return E(m,f),m}function pp(f){return new v(function(y,m){f.transaction(function(w){w.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name <> '__WebKitDatabaseInfoTable__'",[],function(S,b){for(var x=[],A=0;A<b.rows.length;A++)x.push(b.rows.item(A).name);y({db:f,storeNames:x})},function(S,b){m(b)})},function(w){m(w)})})}function hp(f,y){y=F.apply(this,arguments);var m=this.config();f=typeof f!="function"&&f||{},f.name||(f.name=f.name||m.name,f.storeName=f.storeName||m.storeName);var w=this,S;return f.name?S=new v(function(b){var x;f.name===m.name?x=w._dbInfo.db:x=openDatabase(f.name,"","",0),f.storeName?b({db:x,storeNames:[f.storeName]}):b(pp(x))}).then(function(b){return new v(function(x,A){b.db.transaction(function(R){function M(oe){return new v(function(ae,xe){R.executeSql("DROP TABLE IF EXISTS "+oe,[],function(){ae()},function(Ie,ct){xe(ct)})})}for(var L=[],j=0,Q=b.storeNames.length;j<Q;j++)L.push(M(b.storeNames[j]));v.all(L).then(function(){x()}).catch(function(oe){A(oe)})},function(R){A(R)})})}):S=v.reject("Invalid arguments"),E(S,y),S}var mp={_driver:"webSQLStorage",_initStorage:ip,_support:h(),iterate:sp,getItem:op,setItem:ap,removeItem:cp,clear:lp,length:up,key:fp,keys:dp,dropInstance:hp};function gp(){try{return typeof localStorage<"u"&&"setItem"in localStorage&&!!localStorage.setItem}catch{return!1}}function Dc(f,y){var m=f.name+"/";return f.storeName!==y.storeName&&(m+=f.storeName+"/"),m}function _p(){var f="_localforage_support_test";try{return localStorage.setItem(f,!0),localStorage.removeItem(f),!1}catch{return!0}}function yp(){return!_p()||localStorage.length>0}function vp(f){var y=this,m={};if(f)for(var w in f)m[w]=f[w];return m.keyPrefix=Dc(f,y._defaultConfig),yp()?(y._dbInfo=m,m.serializer=qo,v.resolve()):v.reject()}function Ep(f){var y=this,m=y.ready().then(function(){for(var w=y._dbInfo.keyPrefix,S=localStorage.length-1;S>=0;S--){var b=localStorage.key(S);b.indexOf(w)===0&&localStorage.removeItem(b)}});return E(m,f),m}function bp(f,y){var m=this;f=N(f);var w=m.ready().then(function(){var S=m._dbInfo,b=localStorage.getItem(S.keyPrefix+f);return b&&(b=S.serializer.deserialize(b)),b});return E(w,y),w}function wp(f,y){var m=this,w=m.ready().then(function(){for(var S=m._dbInfo,b=S.keyPrefix,x=b.length,A=localStorage.length,R=1,M=0;M<A;M++){var L=localStorage.key(M);if(L.indexOf(b)===0){var j=localStorage.getItem(L);if(j&&(j=S.serializer.deserialize(j)),j=f(j,L.substring(x),R++),j!==void 0)return j}}});return E(w,y),w}function Sp(f,y){var m=this,w=m.ready().then(function(){var S=m._dbInfo,b;try{b=localStorage.key(f)}catch{b=null}return b&&(b=b.substring(S.keyPrefix.length)),b});return E(w,y),w}function Cp(f){var y=this,m=y.ready().then(function(){for(var w=y._dbInfo,S=localStorage.length,b=[],x=0;x<S;x++){var A=localStorage.key(x);A.indexOf(w.keyPrefix)===0&&b.push(A.substring(w.keyPrefix.length))}return b});return E(m,f),m}function Ip(f){var y=this,m=y.keys().then(function(w){return w.length});return E(m,f),m}function Tp(f,y){var m=this;f=N(f);var w=m.ready().then(function(){var S=m._dbInfo;localStorage.removeItem(S.keyPrefix+f)});return E(w,y),w}function xp(f,y,m){var w=this;f=N(f);var S=w.ready().then(function(){y===void 0&&(y=null);var b=y;return new v(function(x,A){var R=w._dbInfo;R.serializer.serialize(y,function(M,L){if(L)A(L);else try{localStorage.setItem(R.keyPrefix+f,M),x(b)}catch(j){(j.name==="QuotaExceededError"||j.name==="NS_ERROR_DOM_QUOTA_REACHED")&&A(j),A(j)}})})});return E(S,m),S}function Op(f,y){if(y=F.apply(this,arguments),f=typeof f!="function"&&f||{},!f.name){var m=this.config();f.name=f.name||m.name,f.storeName=f.storeName||m.storeName}var w=this,S;return f.name?S=new v(function(b){f.storeName?b(Dc(f,w._defaultConfig)):b(f.name+"/")}).then(function(b){for(var x=localStorage.length-1;x>=0;x--){var A=localStorage.key(x);A.indexOf(b)===0&&localStorage.removeItem(A)}}):S=v.reject("Invalid arguments"),E(S,y),S}var Ap={_driver:"localStorageWrapper",_initStorage:vp,_support:gp(),iterate:wp,getItem:bp,setItem:xp,removeItem:Tp,clear:Ep,length:Ip,key:Sp,keys:Cp,dropInstance:Op},Dp=function(y,m){return y===m||typeof y=="number"&&typeof m=="number"&&isNaN(y)&&isNaN(m)},Np=function(y,m){for(var w=y.length,S=0;S<w;){if(Dp(y[S],m))return!0;S++}return!1},Nc=Array.isArray||function(f){return Object.prototype.toString.call(f)==="[object Array]"},Sr={},Rc={},Un={INDEXEDDB:zo,WEBSQL:mp,LOCALSTORAGE:Ap},Rp=[Un.INDEXEDDB._driver,Un.WEBSQL._driver,Un.LOCALSTORAGE._driver],gi=["dropInstance"],Ko=["clear","getItem","iterate","key","keys","length","removeItem","setItem"].concat(gi),Mp={description:"",driver:Rp.slice(),name:"localforage",size:4980736,storeName:"keyvaluepairs",version:1};function Pp(f,y){f[y]=function(){var m=arguments;return f.ready().then(function(){return f[y].apply(f,m)})}}function Jo(){for(var f=1;f<arguments.length;f++){var y=arguments[f];if(y)for(var m in y)y.hasOwnProperty(m)&&(Nc(y[m])?arguments[0][m]=y[m].slice():arguments[0][m]=y[m])}return arguments[0]}var Lp=(function(){function f(y){l(this,f);for(var m in Un)if(Un.hasOwnProperty(m)){var w=Un[m],S=w._driver;this[m]=S,Sr[S]||this.defineDriver(w)}this._defaultConfig=Jo({},Mp),this._config=Jo({},this._defaultConfig,y),this._driverSet=null,this._initDriver=null,this._ready=!1,this._dbInfo=null,this._wrapLibraryMethodsWithReady(),this.setDriver(this._config.driver).catch(function(){})}return f.prototype.config=function(m){if((typeof m>"u"?"undefined":s(m))==="object"){if(this._ready)return new Error("Can't call config() after localforage has been used.");for(var w in m){if(w==="storeName"&&(m[w]=m[w].replace(/\W/g,"_")),w==="version"&&typeof m[w]!="number")return new Error("Database version must be a number.");this._config[w]=m[w]}return"driver"in m&&m.driver?this.setDriver(this._config.driver):!0}else return typeof m=="string"?this._config[m]:this._config},f.prototype.defineDriver=function(m,w,S){var b=new v(function(x,A){try{var R=m._driver,M=new Error("Custom driver not compliant; see https://mozilla.github.io/localForage/#definedriver");if(!m._driver){A(M);return}for(var L=Ko.concat("_initStorage"),j=0,Q=L.length;j<Q;j++){var oe=L[j],ae=!Np(gi,oe);if((ae||m[oe])&&typeof m[oe]!="function"){A(M);return}}var xe=function(){for(var Cr=function(Bp){return function(){var Vp=new Error("Method "+Bp+" is not implemented by the current driver"),Mc=v.reject(Vp);return E(Mc,arguments[arguments.length-1]),Mc}},Zo=0,kp=gi.length;Zo<kp;Zo++){var Qo=gi[Zo];m[Qo]||(m[Qo]=Cr(Qo))}};xe();var Ie=function(Cr){Sr[R]&&console.info("Redefining LocalForage driver: "+R),Sr[R]=m,Rc[R]=Cr,x()};"_support"in m?m._support&&typeof m._support=="function"?m._support().then(Ie,A):Ie(!!m._support):Ie(!0)}catch(ct){A(ct)}});return T(b,w,S),b},f.prototype.driver=function(){return this._driver||null},f.prototype.getDriver=function(m,w,S){var b=Sr[m]?v.resolve(Sr[m]):v.reject(new Error("Driver not found."));return T(b,w,S),b},f.prototype.getSerializer=function(m){var w=v.resolve(qo);return T(w,m),w},f.prototype.ready=function(m){var w=this,S=w._driverSet.then(function(){return w._ready===null&&(w._ready=w._initDriver()),w._ready});return T(S,m,m),S},f.prototype.setDriver=function(m,w,S){var b=this;Nc(m)||(m=[m]);var x=this._getSupportedDrivers(m);function A(){b._config.driver=b.driver()}function R(j){return b._extend(j),A(),b._ready=b._initStorage(b._config),b._ready}function M(j){return function(){var Q=0;function oe(){for(;Q<j.length;){var ae=j[Q];return Q++,b._dbInfo=null,b._ready=null,b.getDriver(ae).then(R).catch(oe)}A();var xe=new Error("No available storage method found.");return b._driverSet=v.reject(xe),b._driverSet}return oe()}}var L=this._driverSet!==null?this._driverSet.catch(function(){return v.resolve()}):v.resolve();return this._driverSet=L.then(function(){var j=x[0];return b._dbInfo=null,b._ready=null,b.getDriver(j).then(function(Q){b._driver=Q._driver,A(),b._wrapLibraryMethodsWithReady(),b._initDriver=M(x)})}).catch(function(){A();var j=new Error("No available storage method found.");return b._driverSet=v.reject(j),b._driverSet}),T(this._driverSet,w,S),this._driverSet},f.prototype.supports=function(m){return!!Rc[m]},f.prototype._extend=function(m){Jo(this,m)},f.prototype._getSupportedDrivers=function(m){for(var w=[],S=0,b=m.length;S<b;S++){var x=m[S];this.supports(x)&&w.push(x)}return w},f.prototype._wrapLibraryMethodsWithReady=function(){for(var m=0,w=Ko.length;m<w;m++)Pp(this,Ko[m])},f.prototype.createInstance=function(m){return new f(m)},f})(),Fp=new Lp;i.exports=Fp},{3:3}]},{},[4])(4)})});var vu=es((Bs,Vs)=>{"use strict";(function(t,e){typeof Bs=="object"&&typeof Vs<"u"?Vs.exports=e():typeof define=="function"&&define.amd?define(e):(t=typeof globalThis<"u"?globalThis:t||self,t.fetchRetry=e())})(Bs,function(){"use strict";var t=function(r,i){if(i=i||{},typeof r!="function")throw new n("fetch must be a function");if(typeof i!="object")throw new n("defaults must be an object");if(i.retries!==void 0&&!e(i.retries))throw new n("retries must be a positive integer");if(i.retryDelay!==void 0&&!e(i.retryDelay)&&typeof i.retryDelay!="function")throw new n("retryDelay must be a positive integer or a function returning a positive integer");if(i.retryOn!==void 0&&!Array.isArray(i.retryOn)&&typeof i.retryOn!="function")throw new n("retryOn property expects an array or function");var o={retries:3,retryDelay:1e3,retryOn:[]};return i=Object.assign(o,i),function(l,u){var d=i.retries,_=i.retryDelay,p=i.retryOn;if(u&&u.retries!==void 0)if(e(u.retries))d=u.retries;else throw new n("retries must be a positive integer");if(u&&u.retryDelay!==void 0)if(e(u.retryDelay)||typeof u.retryDelay=="function")_=u.retryDelay;else throw new n("retryDelay must be a positive integer or a function returning a positive integer");if(u&&u.retryOn)if(Array.isArray(u.retryOn)||typeof u.retryOn=="function")p=u.retryOn;else throw new n("retryOn property expects an array or function");return new Promise(function(v,E){var T=function(F){var B=typeof Request<"u"&&l instanceof Request?l.clone():l;r(B,u).then(function(k){if(Array.isArray(p)&&p.indexOf(k.status)===-1)v(k);else if(typeof p=="function")try{return Promise.resolve(p(F,null,k)).then(function(W){W?N(F,null,k):v(k)}).catch(E)}catch(W){E(W)}else F<d?N(F,null,k):v(k)}).catch(function(k){if(typeof p=="function")try{Promise.resolve(p(F,k,null)).then(function(W){W?N(F,k,null):E(k)}).catch(function(W){E(W)})}catch(W){E(W)}else F<d?N(F,k,null):E(k)})};function N(F,B,k){var W=typeof _=="function"?_(F,B,k):_;setTimeout(function(){T(++F)},W)}T(0)})}};function e(r){return Number.isInteger(r)&&r>=0}function n(r){this.name="ArgumentError",this.message=r}return t})});var ss="11.1.0";var Hp=ss.split("-")[0].split(".").slice(0,3).map(t=>t.padStart(2,"0")).join("");var ml="CooeeSDK",Yn=ss,Fv=parseInt(Hp,10);var Ai=`https://cdn.jsdelivr.net/npm/@letscooee/web-sdk@${Yn}/dist`,Lt={apiURL:"https://api.sdk.letscooee.com",debug:!1,mode:"production",baseURL:Ai,styleURL:`${Ai}/widget.min.css`,widgetURL:`${Ai}/widget.min.js`,swiperStyleURL:`${Ai}/swiper-bundle.min.css`};var rt=ts(_l());var Te=class{static debuggerEl;static infoLogs=[];static log(...e){rt.default.info(...e)}static verbose(...e){rt.default.debug(...e)}static error(...e){rt.default.error(...e)}static warn(...e){rt.default.warn(...e)}static info(...e){rt.default.info(...e),this.infoLogs.unshift({time:new Date,message:e.join(" ")}),this.addToDebugger()}static trace(...e){rt.default.trace(...e)}static addToDebugger(){sessionStorage.cooeeDebug&&(this.debuggerEl=this.debuggerEl??document.querySelector("cooee-debugger"),this.debuggerEl&&this.debuggerEl&&(this.debuggerEl.logs=[...this.infoLogs]))}};function jv(t=ml){rt.default.useDefaults({formatter:function(n){n.unshift(`${t} (v${Yn}):`)}});let e=jp();(e==="1"||e==="on")&&(localStorage.cooeeLogLevel="TRACE"),localStorage.cooeeLogLevel?rt.default.setLevel(rt.default[localStorage.cooeeLogLevel]):rt.default.setLevel(Lt.debug?rt.default.TRACE:rt.default.OFF)}function jp(){return new URL(location.href).searchParams?.get("cooee-debug")}var dn=class{gaEnabled;gaMeasurementID;pixelPush;website;currencyCount;money;storefrontToken;skipItemAttribute;currency;static get(){return window.CooeeSDK.config}update(e){return e??={},this.gaEnabled=e.gaEnabled,this.gaMeasurementID=e.gaMeasurementID,this.pixelPush=e.pixelPush,this.website=e.website??{},this.currencyCount=e.currencyCount??0,this.money=e.money,this.currency=e.currency,this.storefrontToken=e.storefrontToken,this.skipItemAttribute=e.skipItemAttribute,this}};var yl=0;function $p(t=document.head){return vl(Lt.styleURL,t,"cooee-global-styles")}function Gp(t=document.head){return vl(Lt.swiperStyleURL,t,"cooee-swiper-styles")}function vl(t,e=document.head,n){return new Promise(r=>{if(e.querySelector(`#${n}`)){r();return}let o=document.createElement("link");o.rel="stylesheet",o.href=t,o.id=n,o.onload=()=>{r()},o.onerror=()=>{console.error("Failed to load stylesheet:",t),r()},e.appendChild(o)})}function as(t,e=document.head){if(!t)return;yl++;let n=document.createElement("style");n.id=`cooee-app-css-${yl}`,n.textContent=t,e.appendChild(n)}async function El(){let t=(await import("./swiper-bundle-WHJS64TU.js")).default;return window.CooeeSDK.Swiper=t}async function bl(t,e=!0){if(!t)return;let n=[];e&&n.push(Gp(t)),n.push($p(t)),await Promise.all(n);let r=dn.get().website.commonCSS;as(r,t)}var Pr=new Je("EngagementContext"),Ni=new Je("EventData");function Wp(t,e){return e={exports:{}},t(e,e.exports),e.exports}var Yp=Kp,zp=Zp,Xp=th,kt=[],pt=[],qp=typeof Uint8Array<"u"?Uint8Array:Array,cs="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(In=0,wl=cs.length;In<wl;++In)kt[In]=cs[In],pt[cs.charCodeAt(In)]=In;var In,wl;pt[45]=62;pt[95]=63;function Bl(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=t.indexOf("=");n===-1&&(n=e);var r=n===e?0:4-n%4;return[n,r]}function Kp(t){var e=Bl(t),n=e[0],r=e[1];return(n+r)*3/4-r}function Jp(t,e,n){return(e+n)*3/4-n}function Zp(t){var e,n=Bl(t),r=n[0],i=n[1],o=new qp(Jp(t,r,i)),s=0,l=i>0?r-4:r,u;for(u=0;u<l;u+=4)e=pt[t.charCodeAt(u)]<<18|pt[t.charCodeAt(u+1)]<<12|pt[t.charCodeAt(u+2)]<<6|pt[t.charCodeAt(u+3)],o[s++]=e>>16&255,o[s++]=e>>8&255,o[s++]=e&255;return i===2&&(e=pt[t.charCodeAt(u)]<<2|pt[t.charCodeAt(u+1)]>>4,o[s++]=e&255),i===1&&(e=pt[t.charCodeAt(u)]<<10|pt[t.charCodeAt(u+1)]<<4|pt[t.charCodeAt(u+2)]>>2,o[s++]=e>>8&255,o[s++]=e&255),o}function Qp(t){return kt[t>>18&63]+kt[t>>12&63]+kt[t>>6&63]+kt[t&63]}function eh(t,e,n){for(var r,i=[],o=e;o<n;o+=3)r=(t[o]<<16&16711680)+(t[o+1]<<8&65280)+(t[o+2]&255),i.push(Qp(r));return i.join("")}function th(t){for(var e,n=t.length,r=n%3,i=[],o=16383,s=0,l=n-r;s<l;s+=o)i.push(eh(t,s,s+o>l?l:s+o));return r===1?(e=t[n-1],i.push(kt[e>>2]+kt[e<<4&63]+"==")):r===2&&(e=(t[n-2]<<8)+t[n-1],i.push(kt[e>>10]+kt[e>>4&63]+kt[e<<2&63]+"=")),i.join("")}var ls={byteLength:Yp,toByteArray:zp,fromByteArray:Xp};var nh=function(e,n,r,i,o){var s,l,u=o*8-i-1,d=(1<<u)-1,_=d>>1,p=-7,v=r?o-1:0,E=r?-1:1,T=e[n+v];for(v+=E,s=T&(1<<-p)-1,T>>=-p,p+=u;p>0;s=s*256+e[n+v],v+=E,p-=8);for(l=s&(1<<-p)-1,s>>=-p,p+=i;p>0;l=l*256+e[n+v],v+=E,p-=8);if(s===0)s=1-_;else{if(s===d)return l?NaN:(T?-1:1)*(1/0);l=l+Math.pow(2,i),s=s-_}return(T?-1:1)*l*Math.pow(2,s-i)},rh=function(e,n,r,i,o,s){var l,u,d,_=s*8-o-1,p=(1<<_)-1,v=p>>1,E=o===23?Math.pow(2,-24)-Math.pow(2,-77):0,T=i?0:s-1,N=i?1:-1,F=n<0||n===0&&1/n<0?1:0;for(n=Math.abs(n),isNaN(n)||n===1/0?(u=isNaN(n)?1:0,l=p):(l=Math.floor(Math.log(n)/Math.LN2),n*(d=Math.pow(2,-l))<1&&(l--,d*=2),l+v>=1?n+=E/d:n+=E*Math.pow(2,1-v),n*d>=2&&(l++,d/=2),l+v>=p?(u=0,l=p):l+v>=1?(u=(n*d-1)*Math.pow(2,o),l=l+v):(u=n*Math.pow(2,v-1)*Math.pow(2,o),l=0));o>=8;e[r+T]=u&255,T+=N,u/=256,o-=8);for(l=l<<o|u,_+=o;_>0;e[r+T]=l&255,T+=N,l/=256,_-=8);e[r+T-N]|=F*128},zn={read:nh,write:rh},Pi=Wp(function(t,e){var n=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=s,e.SlowBuffer=B,e.INSPECT_MAX_BYTES=50;var r=2147483647;e.kMaxLength=r,s.TYPED_ARRAY_SUPPORT=i(),!s.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function i(){try{var h=new Uint8Array(1),a={foo:function(){return 42}};return Object.setPrototypeOf(a,Uint8Array.prototype),Object.setPrototypeOf(h,a),h.foo()===42}catch{return!1}}Object.defineProperty(s.prototype,"parent",{enumerable:!0,get:function(){if(s.isBuffer(this))return this.buffer}}),Object.defineProperty(s.prototype,"offset",{enumerable:!0,get:function(){if(s.isBuffer(this))return this.byteOffset}});function o(h){if(h>r)throw new RangeError('The value "'+h+'" is invalid for option "size"');var a=new Uint8Array(h);return Object.setPrototypeOf(a,s.prototype),a}function s(h,a,c){if(typeof h=="number"){if(typeof a=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return _(h)}return l(h,a,c)}s.poolSize=8192;function l(h,a,c){if(typeof h=="string")return p(h,a);if(ArrayBuffer.isView(h))return E(h);if(h==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+babelHelpers.typeof(h));if(at(h,ArrayBuffer)||h&&at(h.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(at(h,SharedArrayBuffer)||h&&at(h.buffer,SharedArrayBuffer)))return T(h,a,c);if(typeof h=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var g=h.valueOf&&h.valueOf();if(g!=null&&g!==h)return s.from(g,a,c);var C=N(h);if(C)return C;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof h[Symbol.toPrimitive]=="function")return s.from(h[Symbol.toPrimitive]("string"),a,c);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+babelHelpers.typeof(h))}s.from=function(h,a,c){return l(h,a,c)},Object.setPrototypeOf(s.prototype,Uint8Array.prototype),Object.setPrototypeOf(s,Uint8Array);function u(h){if(typeof h!="number")throw new TypeError('"size" argument must be of type number');if(h<0)throw new RangeError('The value "'+h+'" is invalid for option "size"')}function d(h,a,c){return u(h),h<=0?o(h):a!==void 0?typeof c=="string"?o(h).fill(a,c):o(h).fill(a):o(h)}s.alloc=function(h,a,c){return d(h,a,c)};function _(h){return u(h),o(h<0?0:F(h)|0)}s.allocUnsafe=function(h){return _(h)},s.allocUnsafeSlow=function(h){return _(h)};function p(h,a){if((typeof a!="string"||a==="")&&(a="utf8"),!s.isEncoding(a))throw new TypeError("Unknown encoding: "+a);var c=k(h,a)|0,g=o(c),C=g.write(h,a);return C!==c&&(g=g.slice(0,C)),g}function v(h){for(var a=h.length<0?0:F(h.length)|0,c=o(a),g=0;g<a;g+=1)c[g]=h[g]&255;return c}function E(h){if(at(h,Uint8Array)){var a=new Uint8Array(h);return T(a.buffer,a.byteOffset,a.byteLength)}return v(h)}function T(h,a,c){if(a<0||h.byteLength<a)throw new RangeError('"offset" is outside of buffer bounds');if(h.byteLength<a+(c||0))throw new RangeError('"length" is outside of buffer bounds');var g;return a===void 0&&c===void 0?g=new Uint8Array(h):c===void 0?g=new Uint8Array(h,a):g=new Uint8Array(h,a,c),Object.setPrototypeOf(g,s.prototype),g}function N(h){if(s.isBuffer(h)){var a=F(h.length)|0,c=o(a);return c.length===0||h.copy(c,0,0,a),c}if(h.length!==void 0)return typeof h.length!="number"||Er(h.length)?o(0):v(h);if(h.type==="Buffer"&&Array.isArray(h.data))return v(h.data)}function F(h){if(h>=r)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+r.toString(16)+" bytes");return h|0}function B(h){return+h!=h&&(h=0),s.alloc(+h)}s.isBuffer=function(a){return a!=null&&a._isBuffer===!0&&a!==s.prototype},s.compare=function(a,c){if(at(a,Uint8Array)&&(a=s.from(a,a.offset,a.byteLength)),at(c,Uint8Array)&&(c=s.from(c,c.offset,c.byteLength)),!s.isBuffer(a)||!s.isBuffer(c))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(a===c)return 0;for(var g=a.length,C=c.length,O=0,D=Math.min(g,C);O<D;++O)if(a[O]!==c[O]){g=a[O],C=c[O];break}return g<C?-1:C<g?1:0},s.isEncoding=function(a){switch(String(a).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},s.concat=function(a,c){if(!Array.isArray(a))throw new TypeError('"list" argument must be an Array of Buffers');if(a.length===0)return s.alloc(0);var g;if(c===void 0)for(c=0,g=0;g<a.length;++g)c+=a[g].length;var C=s.allocUnsafe(c),O=0;for(g=0;g<a.length;++g){var D=a[g];if(at(D,Uint8Array))O+D.length>C.length?s.from(D).copy(C,O):Uint8Array.prototype.set.call(C,D,O);else if(s.isBuffer(D))D.copy(C,O);else throw new TypeError('"list" argument must be an Array of Buffers');O+=D.length}return C};function k(h,a){if(s.isBuffer(h))return h.length;if(ArrayBuffer.isView(h)||at(h,ArrayBuffer))return h.byteLength;if(typeof h!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+babelHelpers.typeof(h));var c=h.length,g=arguments.length>2&&arguments[2]===!0;if(!g&&c===0)return 0;for(var C=!1;;)switch(a){case"ascii":case"latin1":case"binary":return c;case"utf8":case"utf-8":return vr(h).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return c*2;case"hex":return c>>>1;case"base64":return mi(h).length;default:if(C)return g?-1:vr(h).length;a=(""+a).toLowerCase(),C=!0}}s.byteLength=k;function W(h,a,c){var g=!1;if((a===void 0||a<0)&&(a=0),a>this.length||((c===void 0||c>this.length)&&(c=this.length),c<=0)||(c>>>=0,a>>>=0,c<=a))return"";for(h||(h="utf8");;)switch(h){case"hex":return ke(this,a,c);case"utf8":case"utf-8":return Oe(this,a,c);case"ascii":return yt(this,a,c);case"latin1":case"binary":return pe(this,a,c);case"base64":return ge(this,a,c);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return te(this,a,c);default:if(g)throw new TypeError("Unknown encoding: "+h);h=(h+"").toLowerCase(),g=!0}}s.prototype._isBuffer=!0;function V(h,a,c){var g=h[a];h[a]=h[c],h[c]=g}s.prototype.swap16=function(){var a=this.length;if(a%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var c=0;c<a;c+=2)V(this,c,c+1);return this},s.prototype.swap32=function(){var a=this.length;if(a%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var c=0;c<a;c+=4)V(this,c,c+3),V(this,c+1,c+2);return this},s.prototype.swap64=function(){var a=this.length;if(a%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var c=0;c<a;c+=8)V(this,c,c+7),V(this,c+1,c+6),V(this,c+2,c+5),V(this,c+3,c+4);return this},s.prototype.toString=function(){var a=this.length;return a===0?"":arguments.length===0?Oe(this,0,a):W.apply(this,arguments)},s.prototype.toLocaleString=s.prototype.toString,s.prototype.equals=function(a){if(!s.isBuffer(a))throw new TypeError("Argument must be a Buffer");return this===a?!0:s.compare(this,a)===0},s.prototype.inspect=function(){var a="",c=e.INSPECT_MAX_BYTES;return a=this.toString("hex",0,c).replace(/(.{2})/g,"$1 ").trim(),this.length>c&&(a+=" ... "),"<Buffer "+a+">"},n&&(s.prototype[n]=s.prototype.inspect),s.prototype.compare=function(a,c,g,C,O){if(at(a,Uint8Array)&&(a=s.from(a,a.offset,a.byteLength)),!s.isBuffer(a))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+babelHelpers.typeof(a));if(c===void 0&&(c=0),g===void 0&&(g=a?a.length:0),C===void 0&&(C=0),O===void 0&&(O=this.length),c<0||g>a.length||C<0||O>this.length)throw new RangeError("out of range index");if(C>=O&&c>=g)return 0;if(C>=O)return-1;if(c>=g)return 1;if(c>>>=0,g>>>=0,C>>>=0,O>>>=0,this===a)return 0;for(var D=O-C,ee=g-c,ie=Math.min(D,ee),le=this.slice(C,O),Ae=a.slice(c,g),_e=0;_e<ie;++_e)if(le[_e]!==Ae[_e]){D=le[_e],ee=Ae[_e];break}return D<ee?-1:ee<D?1:0};function he(h,a,c,g,C){if(h.length===0)return-1;if(typeof c=="string"?(g=c,c=0):c>2147483647?c=2147483647:c<-2147483648&&(c=-2147483648),c=+c,Er(c)&&(c=C?0:h.length-1),c<0&&(c=h.length+c),c>=h.length){if(C)return-1;c=h.length-1}else if(c<0)if(C)c=0;else return-1;if(typeof a=="string"&&(a=s.from(a,g)),s.isBuffer(a))return a.length===0?-1:P(h,a,c,g,C);if(typeof a=="number")return a=a&255,typeof Uint8Array.prototype.indexOf=="function"?C?Uint8Array.prototype.indexOf.call(h,a,c):Uint8Array.prototype.lastIndexOf.call(h,a,c):P(h,[a],c,g,C);throw new TypeError("val must be string, number or Buffer")}function P(h,a,c,g,C){var O=1,D=h.length,ee=a.length;if(g!==void 0&&(g=String(g).toLowerCase(),g==="ucs2"||g==="ucs-2"||g==="utf16le"||g==="utf-16le")){if(h.length<2||a.length<2)return-1;O=2,D/=2,ee/=2,c/=2}function ie(br,wr){return O===1?br[wr]:br.readUInt16BE(wr*O)}var le;if(C){var Ae=-1;for(le=c;le<D;le++)if(ie(h,le)===ie(a,Ae===-1?0:le-Ae)){if(Ae===-1&&(Ae=le),le-Ae+1===ee)return Ae*O}else Ae!==-1&&(le-=le-Ae),Ae=-1}else for(c+ee>D&&(c=D-ee),le=c;le>=0;le--){for(var _e=!0,bn=0;bn<ee;bn++)if(ie(h,le+bn)!==ie(a,bn)){_e=!1;break}if(_e)return le}return-1}s.prototype.includes=function(a,c,g){return this.indexOf(a,c,g)!==-1},s.prototype.indexOf=function(a,c,g){return he(this,a,c,g,!0)},s.prototype.lastIndexOf=function(a,c,g){return he(this,a,c,g,!1)};function q(h,a,c,g){c=Number(c)||0;var C=h.length-c;g?(g=Number(g),g>C&&(g=C)):g=C;var O=a.length;g>O/2&&(g=O/2);for(var D=0;D<g;++D){var ee=parseInt(a.substr(D*2,2),16);if(Er(ee))return D;h[c+D]=ee}return D}function z(h,a,c,g){return Vn(vr(a,h.length-c),h,c,g)}function J(h,a,c,g){return Vn(Wo(a),h,c,g)}function me(h,a,c,g){return Vn(mi(a),h,c,g)}function se(h,a,c,g){return Vn(Yo(a,h.length-c),h,c,g)}s.prototype.write=function(a,c,g,C){if(c===void 0)C="utf8",g=this.length,c=0;else if(g===void 0&&typeof c=="string")C=c,g=this.length,c=0;else if(isFinite(c))c=c>>>0,isFinite(g)?(g=g>>>0,C===void 0&&(C="utf8")):(C=g,g=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var O=this.length-c;if((g===void 0||g>O)&&(g=O),a.length>0&&(g<0||c<0)||c>this.length)throw new RangeError("Attempt to write outside buffer bounds");C||(C="utf8");for(var D=!1;;)switch(C){case"hex":return q(this,a,c,g);case"utf8":case"utf-8":return z(this,a,c,g);case"ascii":case"latin1":case"binary":return J(this,a,c,g);case"base64":return me(this,a,c,g);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return se(this,a,c,g);default:if(D)throw new TypeError("Unknown encoding: "+C);C=(""+C).toLowerCase(),D=!0}},s.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function ge(h,a,c){return a===0&&c===h.length?ls.fromByteArray(h):ls.fromByteArray(h.slice(a,c))}function Oe(h,a,c){c=Math.min(h.length,c);for(var g=[],C=a;C<c;){var O=h[C],D=null,ee=O>239?4:O>223?3:O>191?2:1;if(C+ee<=c){var ie,le,Ae,_e;switch(ee){case 1:O<128&&(D=O);break;case 2:ie=h[C+1],(ie&192)===128&&(_e=(O&31)<<6|ie&63,_e>127&&(D=_e));break;case 3:ie=h[C+1],le=h[C+2],(ie&192)===128&&(le&192)===128&&(_e=(O&15)<<12|(ie&63)<<6|le&63,_e>2047&&(_e<55296||_e>57343)&&(D=_e));break;case 4:ie=h[C+1],le=h[C+2],Ae=h[C+3],(ie&192)===128&&(le&192)===128&&(Ae&192)===128&&(_e=(O&15)<<18|(ie&63)<<12|(le&63)<<6|Ae&63,_e>65535&&_e<1114112&&(D=_e))}}D===null?(D=65533,ee=1):D>65535&&(D-=65536,g.push(D>>>10&1023|55296),D=56320|D&1023),g.push(D),C+=ee}return Tt(g)}var Fe=4096;function Tt(h){var a=h.length;if(a<=Fe)return String.fromCharCode.apply(String,h);for(var c="",g=0;g<a;)c+=String.fromCharCode.apply(String,h.slice(g,g+=Fe));return c}function yt(h,a,c){var g="";c=Math.min(h.length,c);for(var C=a;C<c;++C)g+=String.fromCharCode(h[C]&127);return g}function pe(h,a,c){var g="";c=Math.min(h.length,c);for(var C=a;C<c;++C)g+=String.fromCharCode(h[C]);return g}function ke(h,a,c){var g=h.length;(!a||a<0)&&(a=0),(!c||c<0||c>g)&&(c=g);for(var C="",O=a;O<c;++O)C+=zo[h[O]];return C}function te(h,a,c){for(var g=h.slice(a,c),C="",O=0;O<g.length-1;O+=2)C+=String.fromCharCode(g[O]+g[O+1]*256);return C}s.prototype.slice=function(a,c){var g=this.length;a=~~a,c=c===void 0?g:~~c,a<0?(a+=g,a<0&&(a=0)):a>g&&(a=g),c<0?(c+=g,c<0&&(c=0)):c>g&&(c=g),c<a&&(c=a);var C=this.subarray(a,c);return Object.setPrototypeOf(C,s.prototype),C};function Z(h,a,c){if(h%1!==0||h<0)throw new RangeError("offset is not uint");if(h+a>c)throw new RangeError("Trying to access beyond buffer length")}s.prototype.readUintLE=s.prototype.readUIntLE=function(a,c,g){a=a>>>0,c=c>>>0,g||Z(a,c,this.length);for(var C=this[a],O=1,D=0;++D<c&&(O*=256);)C+=this[a+D]*O;return C},s.prototype.readUintBE=s.prototype.readUIntBE=function(a,c,g){a=a>>>0,c=c>>>0,g||Z(a,c,this.length);for(var C=this[a+--c],O=1;c>0&&(O*=256);)C+=this[a+--c]*O;return C},s.prototype.readUint8=s.prototype.readUInt8=function(a,c){return a=a>>>0,c||Z(a,1,this.length),this[a]},s.prototype.readUint16LE=s.prototype.readUInt16LE=function(a,c){return a=a>>>0,c||Z(a,2,this.length),this[a]|this[a+1]<<8},s.prototype.readUint16BE=s.prototype.readUInt16BE=function(a,c){return a=a>>>0,c||Z(a,2,this.length),this[a]<<8|this[a+1]},s.prototype.readUint32LE=s.prototype.readUInt32LE=function(a,c){return a=a>>>0,c||Z(a,4,this.length),(this[a]|this[a+1]<<8|this[a+2]<<16)+this[a+3]*16777216},s.prototype.readUint32BE=s.prototype.readUInt32BE=function(a,c){return a=a>>>0,c||Z(a,4,this.length),this[a]*16777216+(this[a+1]<<16|this[a+2]<<8|this[a+3])},s.prototype.readIntLE=function(a,c,g){a=a>>>0,c=c>>>0,g||Z(a,c,this.length);for(var C=this[a],O=1,D=0;++D<c&&(O*=256);)C+=this[a+D]*O;return O*=128,C>=O&&(C-=Math.pow(2,8*c)),C},s.prototype.readIntBE=function(a,c,g){a=a>>>0,c=c>>>0,g||Z(a,c,this.length);for(var C=c,O=1,D=this[a+--C];C>0&&(O*=256);)D+=this[a+--C]*O;return O*=128,D>=O&&(D-=Math.pow(2,8*c)),D},s.prototype.readInt8=function(a,c){return a=a>>>0,c||Z(a,1,this.length),this[a]&128?(255-this[a]+1)*-1:this[a]},s.prototype.readInt16LE=function(a,c){a=a>>>0,c||Z(a,2,this.length);var g=this[a]|this[a+1]<<8;return g&32768?g|4294901760:g},s.prototype.readInt16BE=function(a,c){a=a>>>0,c||Z(a,2,this.length);var g=this[a+1]|this[a]<<8;return g&32768?g|4294901760:g},s.prototype.readInt32LE=function(a,c){return a=a>>>0,c||Z(a,4,this.length),this[a]|this[a+1]<<8|this[a+2]<<16|this[a+3]<<24},s.prototype.readInt32BE=function(a,c){return a=a>>>0,c||Z(a,4,this.length),this[a]<<24|this[a+1]<<16|this[a+2]<<8|this[a+3]},s.prototype.readFloatLE=function(a,c){return a=a>>>0,c||Z(a,4,this.length),zn.read(this,a,!0,23,4)},s.prototype.readFloatBE=function(a,c){return a=a>>>0,c||Z(a,4,this.length),zn.read(this,a,!1,23,4)},s.prototype.readDoubleLE=function(a,c){return a=a>>>0,c||Z(a,8,this.length),zn.read(this,a,!0,52,8)},s.prototype.readDoubleBE=function(a,c){return a=a>>>0,c||Z(a,8,this.length),zn.read(this,a,!1,52,8)};function $e(h,a,c,g,C,O){if(!s.isBuffer(h))throw new TypeError('"buffer" argument must be a Buffer instance');if(a>C||a<O)throw new RangeError('"value" argument is out of bounds');if(c+g>h.length)throw new RangeError("Index out of range")}s.prototype.writeUintLE=s.prototype.writeUIntLE=function(a,c,g,C){if(a=+a,c=c>>>0,g=g>>>0,!C){var O=Math.pow(2,8*g)-1;$e(this,a,c,g,O,0)}var D=1,ee=0;for(this[c]=a&255;++ee<g&&(D*=256);)this[c+ee]=a/D&255;return c+g},s.prototype.writeUintBE=s.prototype.writeUIntBE=function(a,c,g,C){if(a=+a,c=c>>>0,g=g>>>0,!C){var O=Math.pow(2,8*g)-1;$e(this,a,c,g,O,0)}var D=g-1,ee=1;for(this[c+D]=a&255;--D>=0&&(ee*=256);)this[c+D]=a/ee&255;return c+g},s.prototype.writeUint8=s.prototype.writeUInt8=function(a,c,g){return a=+a,c=c>>>0,g||$e(this,a,c,1,255,0),this[c]=a&255,c+1},s.prototype.writeUint16LE=s.prototype.writeUInt16LE=function(a,c,g){return a=+a,c=c>>>0,g||$e(this,a,c,2,65535,0),this[c]=a&255,this[c+1]=a>>>8,c+2},s.prototype.writeUint16BE=s.prototype.writeUInt16BE=function(a,c,g){return a=+a,c=c>>>0,g||$e(this,a,c,2,65535,0),this[c]=a>>>8,this[c+1]=a&255,c+2},s.prototype.writeUint32LE=s.prototype.writeUInt32LE=function(a,c,g){return a=+a,c=c>>>0,g||$e(this,a,c,4,4294967295,0),this[c+3]=a>>>24,this[c+2]=a>>>16,this[c+1]=a>>>8,this[c]=a&255,c+4},s.prototype.writeUint32BE=s.prototype.writeUInt32BE=function(a,c,g){return a=+a,c=c>>>0,g||$e(this,a,c,4,4294967295,0),this[c]=a>>>24,this[c+1]=a>>>16,this[c+2]=a>>>8,this[c+3]=a&255,c+4},s.prototype.writeIntLE=function(a,c,g,C){if(a=+a,c=c>>>0,!C){var O=Math.pow(2,8*g-1);$e(this,a,c,g,O-1,-O)}var D=0,ee=1,ie=0;for(this[c]=a&255;++D<g&&(ee*=256);)a<0&&ie===0&&this[c+D-1]!==0&&(ie=1),this[c+D]=(a/ee>>0)-ie&255;return c+g},s.prototype.writeIntBE=function(a,c,g,C){if(a=+a,c=c>>>0,!C){var O=Math.pow(2,8*g-1);$e(this,a,c,g,O-1,-O)}var D=g-1,ee=1,ie=0;for(this[c+D]=a&255;--D>=0&&(ee*=256);)a<0&&ie===0&&this[c+D+1]!==0&&(ie=1),this[c+D]=(a/ee>>0)-ie&255;return c+g},s.prototype.writeInt8=function(a,c,g){return a=+a,c=c>>>0,g||$e(this,a,c,1,127,-128),a<0&&(a=255+a+1),this[c]=a&255,c+1},s.prototype.writeInt16LE=function(a,c,g){return a=+a,c=c>>>0,g||$e(this,a,c,2,32767,-32768),this[c]=a&255,this[c+1]=a>>>8,c+2},s.prototype.writeInt16BE=function(a,c,g){return a=+a,c=c>>>0,g||$e(this,a,c,2,32767,-32768),this[c]=a>>>8,this[c+1]=a&255,c+2},s.prototype.writeInt32LE=function(a,c,g){return a=+a,c=c>>>0,g||$e(this,a,c,4,2147483647,-2147483648),this[c]=a&255,this[c+1]=a>>>8,this[c+2]=a>>>16,this[c+3]=a>>>24,c+4},s.prototype.writeInt32BE=function(a,c,g){return a=+a,c=c>>>0,g||$e(this,a,c,4,2147483647,-2147483648),a<0&&(a=4294967295+a+1),this[c]=a>>>24,this[c+1]=a>>>16,this[c+2]=a>>>8,this[c+3]=a&255,c+4};function st(h,a,c,g,C,O){if(c+g>h.length)throw new RangeError("Index out of range");if(c<0)throw new RangeError("Index out of range")}function yr(h,a,c,g,C){return a=+a,c=c>>>0,C||st(h,a,c,4),zn.write(h,a,c,g,23,4),c+4}s.prototype.writeFloatLE=function(a,c,g){return yr(this,a,c,!0,g)},s.prototype.writeFloatBE=function(a,c,g){return yr(this,a,c,!1,g)};function hi(h,a,c,g,C){return a=+a,c=c>>>0,C||st(h,a,c,8),zn.write(h,a,c,g,52,8),c+8}s.prototype.writeDoubleLE=function(a,c,g){return hi(this,a,c,!0,g)},s.prototype.writeDoubleBE=function(a,c,g){return hi(this,a,c,!1,g)},s.prototype.copy=function(a,c,g,C){if(!s.isBuffer(a))throw new TypeError("argument should be a Buffer");if(g||(g=0),!C&&C!==0&&(C=this.length),c>=a.length&&(c=a.length),c||(c=0),C>0&&C<g&&(C=g),C===g||a.length===0||this.length===0)return 0;if(c<0)throw new RangeError("targetStart out of bounds");if(g<0||g>=this.length)throw new RangeError("Index out of range");if(C<0)throw new RangeError("sourceEnd out of bounds");C>this.length&&(C=this.length),a.length-c<C-g&&(C=a.length-c+g);var O=C-g;return this===a&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(c,g,C):Uint8Array.prototype.set.call(a,this.subarray(g,C),c),O},s.prototype.fill=function(a,c,g,C){if(typeof a=="string"){if(typeof c=="string"?(C=c,c=0,g=this.length):typeof g=="string"&&(C=g,g=this.length),C!==void 0&&typeof C!="string")throw new TypeError("encoding must be a string");if(typeof C=="string"&&!s.isEncoding(C))throw new TypeError("Unknown encoding: "+C);if(a.length===1){var O=a.charCodeAt(0);(C==="utf8"&&O<128||C==="latin1")&&(a=O)}}else typeof a=="number"?a=a&255:typeof a=="boolean"&&(a=Number(a));if(c<0||this.length<c||this.length<g)throw new RangeError("Out of range index");if(g<=c)return this;c=c>>>0,g=g===void 0?this.length:g>>>0,a||(a=0);var D;if(typeof a=="number")for(D=c;D<g;++D)this[D]=a;else{var ee=s.isBuffer(a)?a:s.from(a,C),ie=ee.length;if(ie===0)throw new TypeError('The value "'+a+'" is invalid for argument "value"');for(D=0;D<g-c;++D)this[D+c]=ee[D%ie]}return this};var $o=/[^+/0-9A-Za-z-_]/g;function Go(h){if(h=h.split("=")[0],h=h.trim().replace($o,""),h.length<2)return"";for(;h.length%4!==0;)h=h+"=";return h}function vr(h,a){a=a||1/0;for(var c,g=h.length,C=null,O=[],D=0;D<g;++D){if(c=h.charCodeAt(D),c>55295&&c<57344){if(!C){if(c>56319){(a-=3)>-1&&O.push(239,191,189);continue}else if(D+1===g){(a-=3)>-1&&O.push(239,191,189);continue}C=c;continue}if(c<56320){(a-=3)>-1&&O.push(239,191,189),C=c;continue}c=(C-55296<<10|c-56320)+65536}else C&&(a-=3)>-1&&O.push(239,191,189);if(C=null,c<128){if((a-=1)<0)break;O.push(c)}else if(c<2048){if((a-=2)<0)break;O.push(c>>6|192,c&63|128)}else if(c<65536){if((a-=3)<0)break;O.push(c>>12|224,c>>6&63|128,c&63|128)}else if(c<1114112){if((a-=4)<0)break;O.push(c>>18|240,c>>12&63|128,c>>6&63|128,c&63|128)}else throw new Error("Invalid code point")}return O}function Wo(h){for(var a=[],c=0;c<h.length;++c)a.push(h.charCodeAt(c)&255);return a}function Yo(h,a){for(var c,g,C,O=[],D=0;D<h.length&&!((a-=2)<0);++D)c=h.charCodeAt(D),g=c>>8,C=c%256,O.push(C),O.push(g);return O}function mi(h){return ls.toByteArray(Go(h))}function Vn(h,a,c,g){for(var C=0;C<g&&!(C+c>=a.length||C>=h.length);++C)a[C+c]=h[C];return C}function at(h,a){return h instanceof a||h!=null&&h.constructor!=null&&h.constructor.name!=null&&h.constructor.name===a.name}function Er(h){return h!==h}var zo=(function(){for(var h="0123456789abcdef",a=new Array(256),c=0;c<16;++c)for(var g=c*16,C=0;C<16;++C)a[g+C]=h[c]+h[C];return a})()}),re=Pi.Buffer;Pi.SlowBuffer;Pi.INSPECT_MAX_BYTES;Pi.kMaxLength;var hs=function(e,n){return hs=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)i.hasOwnProperty(o)&&(r[o]=i[o])},hs(e,n)};function Li(t,e){hs(t,e);function n(){this.constructor=t}t.prototype=e===null?Object.create(e):(n.prototype=e.prototype,new n)}var xn=(function(t){Li(e,t);function e(n){var r=t.call(this,n)||this;return Object.setPrototypeOf(r,e.prototype),r}return Object.defineProperty(e.prototype,"name",{get:function(){return"BSONError"},enumerable:!1,configurable:!0}),e})(Error),Se=(function(t){Li(e,t);function e(n){var r=t.call(this,n)||this;return Object.setPrototypeOf(r,e.prototype),r}return Object.defineProperty(e.prototype,"name",{get:function(){return"BSONTypeError"},enumerable:!1,configurable:!0}),e})(TypeError);function Ri(t){return t&&t.Math==Math&&t}function Vl(){return Ri(typeof globalThis=="object"&&globalThis)||Ri(typeof window=="object"&&window)||Ri(typeof self=="object"&&self)||Ri(typeof global=="object"&&global)||Function("return this")()}function ih(){var t=Vl();return typeof t.navigator=="object"&&t.navigator.product==="ReactNative"}var oh=function(e){var n=ih()?"BSON: For React Native please polyfill crypto.getRandomValues, e.g. using: https://www.npmjs.com/package/react-native-get-random-values.":"BSON: No cryptographic implementation for random bytes present, falling back to a less secure implementation.";console.warn(n);for(var r=re.alloc(e),i=0;i<e;++i)r[i]=Math.floor(Math.random()*256);return r},sh=function(){{if(typeof window<"u"){var t=window.crypto||window.msCrypto;if(t&&t.getRandomValues)return function(e){return t.getRandomValues(re.alloc(e))}}return typeof global<"u"&&global.crypto&&global.crypto.getRandomValues?function(e){return global.crypto.getRandomValues(re.alloc(e))}:oh}},Ul=sh();function ah(t){return["[object ArrayBuffer]","[object SharedArrayBuffer]"].includes(Object.prototype.toString.call(t))}function gs(t){return Object.prototype.toString.call(t)==="[object Uint8Array]"}function ch(t){return Object.prototype.toString.call(t)==="[object RegExp]"}function lh(t){return Br(t)&&Object.prototype.toString.call(t)==="[object Date]"}function Br(t){return typeof t=="object"&&t!==null}function Fi(t,e){var n=!1;function r(){for(var i=[],o=0;o<arguments.length;o++)i[o]=arguments[o];return n||(console.warn(e),n=!0),t.apply(this,i)}return r}function Mi(t){if(ArrayBuffer.isView(t))return re.from(t.buffer,t.byteOffset,t.byteLength);if(ah(t))return re.from(t);throw new Se("Must use either Buffer or TypedArray")}var uh=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|[0-9a-f]{12}4[0-9a-f]{3}[89ab][0-9a-f]{15})$/i,Hl=function(t){return typeof t=="string"&&uh.test(t)},ms=function(t){if(!Hl(t))throw new Se('UUID string representations must be a 32 or 36 character hex string (dashes excluded/included). Format: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" or "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx".');var e=t.replace(/-/g,"");return re.from(e,"hex")},Sl=function(t,e){return e===void 0&&(e=!0),e?t.toString("hex",0,4)+"-"+t.toString("hex",4,6)+"-"+t.toString("hex",6,8)+"-"+t.toString("hex",8,10)+"-"+t.toString("hex",10,16):t.toString("hex")};var Jv=Math.pow(2,63)-1,Zv=-Math.pow(2,63),fh=Math.pow(2,53),dh=-Math.pow(2,53);var jl=4;var On=(function(){function t(e,n){if(!(this instanceof t))return new t(e,n);if(e!=null&&typeof e!="string"&&!ArrayBuffer.isView(e)&&!(e instanceof ArrayBuffer)&&!Array.isArray(e))throw new Se("Binary can only be constructed from string, Buffer, TypedArray, or Array<number>");this.sub_type=n??t.BSON_BINARY_SUBTYPE_DEFAULT,e==null?(this.buffer=re.alloc(t.BUFFER_SIZE),this.position=0):(typeof e=="string"?this.buffer=re.from(e,"binary"):Array.isArray(e)?this.buffer=re.from(e):this.buffer=Mi(e),this.position=this.buffer.byteLength)}return t.prototype.put=function(e){if(typeof e=="string"&&e.length!==1)throw new Se("only accepts single character String");if(typeof e!="number"&&e.length!==1)throw new Se("only accepts single character Uint8Array or Array");var n;if(typeof e=="string"?n=e.charCodeAt(0):typeof e=="number"?n=e:n=e[0],n<0||n>255)throw new Se("only accepts number in a valid unsigned byte range 0-255");if(this.buffer.length>this.position)this.buffer[this.position++]=n;else{var r=re.alloc(t.BUFFER_SIZE+this.buffer.length);this.buffer.copy(r,0,0,this.buffer.length),this.buffer=r,this.buffer[this.position++]=n}},t.prototype.write=function(e,n){if(n=typeof n=="number"?n:this.position,this.buffer.length<n+e.length){var r=re.alloc(this.buffer.length+e.length);this.buffer.copy(r,0,0,this.buffer.length),this.buffer=r}ArrayBuffer.isView(e)?(this.buffer.set(Mi(e),n),this.position=n+e.byteLength>this.position?n+e.length:this.position):typeof e=="string"&&(this.buffer.write(e,n,e.length,"binary"),this.position=n+e.length>this.position?n+e.length:this.position)},t.prototype.read=function(e,n){return n=n&&n>0?n:this.position,this.buffer.slice(e,e+n)},t.prototype.value=function(e){return e=!!e,e&&this.buffer.length===this.position?this.buffer:e?this.buffer.slice(0,this.position):this.buffer.toString("binary",0,this.position)},t.prototype.length=function(){return this.position},t.prototype.toJSON=function(){return this.buffer.toString("base64")},t.prototype.toString=function(e){return this.buffer.toString(e)},t.prototype.toExtendedJSON=function(e){e=e||{};var n=this.buffer.toString("base64"),r=Number(this.sub_type).toString(16);return e.legacy?{$binary:n,$type:r.length===1?"0"+r:r}:{$binary:{base64:n,subType:r.length===1?"0"+r:r}}},t.prototype.toUUID=function(){if(this.sub_type===t.SUBTYPE_UUID)return new Cl(this.buffer.slice(0,this.position));throw new xn('Binary sub_type "'.concat(this.sub_type,'" is not supported for converting to UUID. Only "').concat(t.SUBTYPE_UUID,'" is currently supported.'))},t.fromExtendedJSON=function(e,n){n=n||{};var r,i;if("$binary"in e?n.legacy&&typeof e.$binary=="string"&&"$type"in e?(i=e.$type?parseInt(e.$type,16):0,r=re.from(e.$binary,"base64")):typeof e.$binary!="string"&&(i=e.$binary.subType?parseInt(e.$binary.subType,16):0,r=re.from(e.$binary.base64,"base64")):"$uuid"in e&&(i=4,r=ms(e.$uuid)),!r)throw new Se("Unexpected Binary Extended JSON format ".concat(JSON.stringify(e)));return i===jl?new Cl(r):new t(r,i)},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t.prototype.inspect=function(){var e=this.value(!0);return'new Binary(Buffer.from("'.concat(e.toString("hex"),'", "hex"), ').concat(this.sub_type,")")},t.BSON_BINARY_SUBTYPE_DEFAULT=0,t.BUFFER_SIZE=256,t.SUBTYPE_DEFAULT=0,t.SUBTYPE_FUNCTION=1,t.SUBTYPE_BYTE_ARRAY=2,t.SUBTYPE_UUID_OLD=3,t.SUBTYPE_UUID=4,t.SUBTYPE_MD5=5,t.SUBTYPE_ENCRYPTED=6,t.SUBTYPE_COLUMN=7,t.SUBTYPE_USER_DEFINED=128,t})();Object.defineProperty(On.prototype,"_bsontype",{value:"Binary"});var us=16,Cl=(function(t){Li(e,t);function e(n){var r=this,i,o;if(n==null)i=e.generate();else if(n instanceof e)i=re.from(n.buffer),o=n.__id;else if(ArrayBuffer.isView(n)&&n.byteLength===us)i=Mi(n);else if(typeof n=="string")i=ms(n);else throw new Se("Argument passed in UUID constructor must be a UUID, a 16 byte Buffer or a 32/36 character hex string (dashes excluded/included, format: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).");return r=t.call(this,i,jl)||this,r.__id=o,r}return Object.defineProperty(e.prototype,"id",{get:function(){return this.buffer},set:function(n){this.buffer=n,e.cacheHexString&&(this.__id=Sl(n))},enumerable:!1,configurable:!0}),e.prototype.toHexString=function(n){if(n===void 0&&(n=!0),e.cacheHexString&&this.__id)return this.__id;var r=Sl(this.id,n);return e.cacheHexString&&(this.__id=r),r},e.prototype.toString=function(n){return n?this.id.toString(n):this.toHexString()},e.prototype.toJSON=function(){return this.toHexString()},e.prototype.equals=function(n){if(!n)return!1;if(n instanceof e)return n.id.equals(this.id);try{return new e(n).id.equals(this.id)}catch{return!1}},e.prototype.toBinary=function(){return new On(this.id,On.SUBTYPE_UUID)},e.generate=function(){var n=Ul(us);return n[6]=n[6]&15|64,n[8]=n[8]&63|128,re.from(n)},e.isValid=function(n){return n?n instanceof e?!0:typeof n=="string"?Hl(n):gs(n)?n.length!==us?!1:(n[6]&240)===64&&(n[8]&128)===128:!1:!1},e.createFromHexString=function(n){var r=ms(n);return new e(r)},e.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},e.prototype.inspect=function(){return'new UUID("'.concat(this.toHexString(),'")')},e})(On),ki=(function(){function t(e,n){if(!(this instanceof t))return new t(e,n);this.code=e,this.scope=n}return t.prototype.toJSON=function(){return{code:this.code,scope:this.scope}},t.prototype.toExtendedJSON=function(){return this.scope?{$code:this.code,$scope:this.scope}:{$code:this.code}},t.fromExtendedJSON=function(e){return new t(e.$code,e.$scope)},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t.prototype.inspect=function(){var e=this.toJSON();return'new Code("'.concat(String(e.code),'"').concat(e.scope?", ".concat(JSON.stringify(e.scope)):"",")")},t})();Object.defineProperty(ki.prototype,"_bsontype",{value:"Code"});function ph(t){return Br(t)&&t.$id!=null&&typeof t.$ref=="string"&&(t.$db==null||typeof t.$db=="string")}var Fr=(function(){function t(e,n,r,i){if(!(this instanceof t))return new t(e,n,r,i);var o=e.split(".");o.length===2&&(r=o.shift(),e=o.shift()),this.collection=e,this.oid=n,this.db=r,this.fields=i||{}}return Object.defineProperty(t.prototype,"namespace",{get:function(){return this.collection},set:function(e){this.collection=e},enumerable:!1,configurable:!0}),t.prototype.toJSON=function(){var e=Object.assign({$ref:this.collection,$id:this.oid},this.fields);return this.db!=null&&(e.$db=this.db),e},t.prototype.toExtendedJSON=function(e){e=e||{};var n={$ref:this.collection,$id:this.oid};return e.legacy||(this.db&&(n.$db=this.db),n=Object.assign(n,this.fields)),n},t.fromExtendedJSON=function(e){var n=Object.assign({},e);return delete n.$ref,delete n.$id,delete n.$db,new t(e.$ref,e.$id,e.$db,n)},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t.prototype.inspect=function(){var e=this.oid===void 0||this.oid.toString===void 0?this.oid:this.oid.toString();return'new DBRef("'.concat(this.namespace,'", new ObjectId("').concat(String(e),'")').concat(this.db?', "'.concat(this.db,'"'):"",")")},t})();Object.defineProperty(Fr.prototype,"_bsontype",{value:"DBRef"});var dt=void 0;try{dt=new WebAssembly.Instance(new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0,1,13,2,96,0,1,127,96,4,127,127,127,127,1,127,3,7,6,0,1,1,1,1,1,6,6,1,127,1,65,0,11,7,50,6,3,109,117,108,0,1,5,100,105,118,95,115,0,2,5,100,105,118,95,117,0,3,5,114,101,109,95,115,0,4,5,114,101,109,95,117,0,5,8,103,101,116,95,104,105,103,104,0,0,10,191,1,6,4,0,35,0,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,126,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,127,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,128,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,129,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,130,34,4,66,32,135,167,36,0,32,4,167,11])),{}).exports}catch{}var Il=65536,hh=1<<24,qn=Il*Il,$l=qn*qn,Tl=$l/2,xl={},Ol={},G=(function(){function t(e,n,r){if(e===void 0&&(e=0),!(this instanceof t))return new t(e,n,r);typeof e=="bigint"?Object.assign(this,t.fromBigInt(e,!!n)):typeof e=="string"?Object.assign(this,t.fromString(e,!!n)):(this.low=e|0,this.high=n|0,this.unsigned=!!r),Object.defineProperty(this,"__isLong__",{value:!0,configurable:!1,writable:!1,enumerable:!1})}return t.fromBits=function(e,n,r){return new t(e,n,r)},t.fromInt=function(e,n){var r,i,o;return n?(e>>>=0,(o=0<=e&&e<256)&&(i=Ol[e],i)?i:(r=t.fromBits(e,(e|0)<0?-1:0,!0),o&&(Ol[e]=r),r)):(e|=0,(o=-128<=e&&e<128)&&(i=xl[e],i)?i:(r=t.fromBits(e,e<0?-1:0,!1),o&&(xl[e]=r),r))},t.fromNumber=function(e,n){if(isNaN(e))return n?t.UZERO:t.ZERO;if(n){if(e<0)return t.UZERO;if(e>=$l)return t.MAX_UNSIGNED_VALUE}else{if(e<=-Tl)return t.MIN_VALUE;if(e+1>=Tl)return t.MAX_VALUE}return e<0?t.fromNumber(-e,n).neg():t.fromBits(e%qn|0,e/qn|0,n)},t.fromBigInt=function(e,n){return t.fromString(e.toString(),n)},t.fromString=function(e,n,r){if(e.length===0)throw Error("empty string");if(e==="NaN"||e==="Infinity"||e==="+Infinity"||e==="-Infinity")return t.ZERO;if(typeof n=="number"?(r=n,n=!1):n=!!n,r=r||10,r<2||36<r)throw RangeError("radix");var i;if((i=e.indexOf("-"))>0)throw Error("interior hyphen");if(i===0)return t.fromString(e.substring(1),n,r).neg();for(var o=t.fromNumber(Math.pow(r,8)),s=t.ZERO,l=0;l<e.length;l+=8){var u=Math.min(8,e.length-l),d=parseInt(e.substring(l,l+u),r);if(u<8){var _=t.fromNumber(Math.pow(r,u));s=s.mul(_).add(t.fromNumber(d))}else s=s.mul(o),s=s.add(t.fromNumber(d))}return s.unsigned=n,s},t.fromBytes=function(e,n,r){return r?t.fromBytesLE(e,n):t.fromBytesBE(e,n)},t.fromBytesLE=function(e,n){return new t(e[0]|e[1]<<8|e[2]<<16|e[3]<<24,e[4]|e[5]<<8|e[6]<<16|e[7]<<24,n)},t.fromBytesBE=function(e,n){return new t(e[4]<<24|e[5]<<16|e[6]<<8|e[7],e[0]<<24|e[1]<<16|e[2]<<8|e[3],n)},t.isLong=function(e){return Br(e)&&e.__isLong__===!0},t.fromValue=function(e,n){return typeof e=="number"?t.fromNumber(e,n):typeof e=="string"?t.fromString(e,n):t.fromBits(e.low,e.high,typeof n=="boolean"?n:e.unsigned)},t.prototype.add=function(e){t.isLong(e)||(e=t.fromValue(e));var n=this.high>>>16,r=this.high&65535,i=this.low>>>16,o=this.low&65535,s=e.high>>>16,l=e.high&65535,u=e.low>>>16,d=e.low&65535,_=0,p=0,v=0,E=0;return E+=o+d,v+=E>>>16,E&=65535,v+=i+u,p+=v>>>16,v&=65535,p+=r+l,_+=p>>>16,p&=65535,_+=n+s,_&=65535,t.fromBits(v<<16|E,_<<16|p,this.unsigned)},t.prototype.and=function(e){return t.isLong(e)||(e=t.fromValue(e)),t.fromBits(this.low&e.low,this.high&e.high,this.unsigned)},t.prototype.compare=function(e){if(t.isLong(e)||(e=t.fromValue(e)),this.eq(e))return 0;var n=this.isNegative(),r=e.isNegative();return n&&!r?-1:!n&&r?1:this.unsigned?e.high>>>0>this.high>>>0||e.high===this.high&&e.low>>>0>this.low>>>0?-1:1:this.sub(e).isNegative()?-1:1},t.prototype.comp=function(e){return this.compare(e)},t.prototype.divide=function(e){if(t.isLong(e)||(e=t.fromValue(e)),e.isZero())throw Error("division by zero");if(dt){if(!this.unsigned&&this.high===-2147483648&&e.low===-1&&e.high===-1)return this;var n=(this.unsigned?dt.div_u:dt.div_s)(this.low,this.high,e.low,e.high);return t.fromBits(n,dt.get_high(),this.unsigned)}if(this.isZero())return this.unsigned?t.UZERO:t.ZERO;var r,i,o;if(this.unsigned){if(e.unsigned||(e=e.toUnsigned()),e.gt(this))return t.UZERO;if(e.gt(this.shru(1)))return t.UONE;o=t.UZERO}else{if(this.eq(t.MIN_VALUE)){if(e.eq(t.ONE)||e.eq(t.NEG_ONE))return t.MIN_VALUE;if(e.eq(t.MIN_VALUE))return t.ONE;var s=this.shr(1);return r=s.div(e).shl(1),r.eq(t.ZERO)?e.isNegative()?t.ONE:t.NEG_ONE:(i=this.sub(e.mul(r)),o=r.add(i.div(e)),o)}else if(e.eq(t.MIN_VALUE))return this.unsigned?t.UZERO:t.ZERO;if(this.isNegative())return e.isNegative()?this.neg().div(e.neg()):this.neg().div(e).neg();if(e.isNegative())return this.div(e.neg()).neg();o=t.ZERO}for(i=this;i.gte(e);){r=Math.max(1,Math.floor(i.toNumber()/e.toNumber()));for(var l=Math.ceil(Math.log(r)/Math.LN2),u=l<=48?1:Math.pow(2,l-48),d=t.fromNumber(r),_=d.mul(e);_.isNegative()||_.gt(i);)r-=u,d=t.fromNumber(r,this.unsigned),_=d.mul(e);d.isZero()&&(d=t.ONE),o=o.add(d),i=i.sub(_)}return o},t.prototype.div=function(e){return this.divide(e)},t.prototype.equals=function(e){return t.isLong(e)||(e=t.fromValue(e)),this.unsigned!==e.unsigned&&this.high>>>31===1&&e.high>>>31===1?!1:this.high===e.high&&this.low===e.low},t.prototype.eq=function(e){return this.equals(e)},t.prototype.getHighBits=function(){return this.high},t.prototype.getHighBitsUnsigned=function(){return this.high>>>0},t.prototype.getLowBits=function(){return this.low},t.prototype.getLowBitsUnsigned=function(){return this.low>>>0},t.prototype.getNumBitsAbs=function(){if(this.isNegative())return this.eq(t.MIN_VALUE)?64:this.neg().getNumBitsAbs();var e=this.high!==0?this.high:this.low,n;for(n=31;n>0&&(e&1<<n)===0;n--);return this.high!==0?n+33:n+1},t.prototype.greaterThan=function(e){return this.comp(e)>0},t.prototype.gt=function(e){return this.greaterThan(e)},t.prototype.greaterThanOrEqual=function(e){return this.comp(e)>=0},t.prototype.gte=function(e){return this.greaterThanOrEqual(e)},t.prototype.ge=function(e){return this.greaterThanOrEqual(e)},t.prototype.isEven=function(){return(this.low&1)===0},t.prototype.isNegative=function(){return!this.unsigned&&this.high<0},t.prototype.isOdd=function(){return(this.low&1)===1},t.prototype.isPositive=function(){return this.unsigned||this.high>=0},t.prototype.isZero=function(){return this.high===0&&this.low===0},t.prototype.lessThan=function(e){return this.comp(e)<0},t.prototype.lt=function(e){return this.lessThan(e)},t.prototype.lessThanOrEqual=function(e){return this.comp(e)<=0},t.prototype.lte=function(e){return this.lessThanOrEqual(e)},t.prototype.modulo=function(e){if(t.isLong(e)||(e=t.fromValue(e)),dt){var n=(this.unsigned?dt.rem_u:dt.rem_s)(this.low,this.high,e.low,e.high);return t.fromBits(n,dt.get_high(),this.unsigned)}return this.sub(this.div(e).mul(e))},t.prototype.mod=function(e){return this.modulo(e)},t.prototype.rem=function(e){return this.modulo(e)},t.prototype.multiply=function(e){if(this.isZero())return t.ZERO;if(t.isLong(e)||(e=t.fromValue(e)),dt){var n=dt.mul(this.low,this.high,e.low,e.high);return t.fromBits(n,dt.get_high(),this.unsigned)}if(e.isZero())return t.ZERO;if(this.eq(t.MIN_VALUE))return e.isOdd()?t.MIN_VALUE:t.ZERO;if(e.eq(t.MIN_VALUE))return this.isOdd()?t.MIN_VALUE:t.ZERO;if(this.isNegative())return e.isNegative()?this.neg().mul(e.neg()):this.neg().mul(e).neg();if(e.isNegative())return this.mul(e.neg()).neg();if(this.lt(t.TWO_PWR_24)&&e.lt(t.TWO_PWR_24))return t.fromNumber(this.toNumber()*e.toNumber(),this.unsigned);var r=this.high>>>16,i=this.high&65535,o=this.low>>>16,s=this.low&65535,l=e.high>>>16,u=e.high&65535,d=e.low>>>16,_=e.low&65535,p=0,v=0,E=0,T=0;return T+=s*_,E+=T>>>16,T&=65535,E+=o*_,v+=E>>>16,E&=65535,E+=s*d,v+=E>>>16,E&=65535,v+=i*_,p+=v>>>16,v&=65535,v+=o*d,p+=v>>>16,v&=65535,v+=s*u,p+=v>>>16,v&=65535,p+=r*_+i*d+o*u+s*l,p&=65535,t.fromBits(E<<16|T,p<<16|v,this.unsigned)},t.prototype.mul=function(e){return this.multiply(e)},t.prototype.negate=function(){return!this.unsigned&&this.eq(t.MIN_VALUE)?t.MIN_VALUE:this.not().add(t.ONE)},t.prototype.neg=function(){return this.negate()},t.prototype.not=function(){return t.fromBits(~this.low,~this.high,this.unsigned)},t.prototype.notEquals=function(e){return!this.equals(e)},t.prototype.neq=function(e){return this.notEquals(e)},t.prototype.ne=function(e){return this.notEquals(e)},t.prototype.or=function(e){return t.isLong(e)||(e=t.fromValue(e)),t.fromBits(this.low|e.low,this.high|e.high,this.unsigned)},t.prototype.shiftLeft=function(e){return t.isLong(e)&&(e=e.toInt()),(e&=63)===0?this:e<32?t.fromBits(this.low<<e,this.high<<e|this.low>>>32-e,this.unsigned):t.fromBits(0,this.low<<e-32,this.unsigned)},t.prototype.shl=function(e){return this.shiftLeft(e)},t.prototype.shiftRight=function(e){return t.isLong(e)&&(e=e.toInt()),(e&=63)===0?this:e<32?t.fromBits(this.low>>>e|this.high<<32-e,this.high>>e,this.unsigned):t.fromBits(this.high>>e-32,this.high>=0?0:-1,this.unsigned)},t.prototype.shr=function(e){return this.shiftRight(e)},t.prototype.shiftRightUnsigned=function(e){if(t.isLong(e)&&(e=e.toInt()),e&=63,e===0)return this;var n=this.high;if(e<32){var r=this.low;return t.fromBits(r>>>e|n<<32-e,n>>>e,this.unsigned)}else return e===32?t.fromBits(n,0,this.unsigned):t.fromBits(n>>>e-32,0,this.unsigned)},t.prototype.shr_u=function(e){return this.shiftRightUnsigned(e)},t.prototype.shru=function(e){return this.shiftRightUnsigned(e)},t.prototype.subtract=function(e){return t.isLong(e)||(e=t.fromValue(e)),this.add(e.neg())},t.prototype.sub=function(e){return this.subtract(e)},t.prototype.toInt=function(){return this.unsigned?this.low>>>0:this.low},t.prototype.toNumber=function(){return this.unsigned?(this.high>>>0)*qn+(this.low>>>0):this.high*qn+(this.low>>>0)},t.prototype.toBigInt=function(){return BigInt(this.toString())},t.prototype.toBytes=function(e){return e?this.toBytesLE():this.toBytesBE()},t.prototype.toBytesLE=function(){var e=this.high,n=this.low;return[n&255,n>>>8&255,n>>>16&255,n>>>24,e&255,e>>>8&255,e>>>16&255,e>>>24]},t.prototype.toBytesBE=function(){var e=this.high,n=this.low;return[e>>>24,e>>>16&255,e>>>8&255,e&255,n>>>24,n>>>16&255,n>>>8&255,n&255]},t.prototype.toSigned=function(){return this.unsigned?t.fromBits(this.low,this.high,!1):this},t.prototype.toString=function(e){if(e=e||10,e<2||36<e)throw RangeError("radix");if(this.isZero())return"0";if(this.isNegative())if(this.eq(t.MIN_VALUE)){var n=t.fromNumber(e),r=this.div(n),i=r.mul(n).sub(this);return r.toString(e)+i.toInt().toString(e)}else return"-"+this.neg().toString(e);for(var o=t.fromNumber(Math.pow(e,6),this.unsigned),s=this,l="";;){var u=s.div(o),d=s.sub(u.mul(o)).toInt()>>>0,_=d.toString(e);if(s=u,s.isZero())return _+l;for(;_.length<6;)_="0"+_;l=""+_+l}},t.prototype.toUnsigned=function(){return this.unsigned?this:t.fromBits(this.low,this.high,!0)},t.prototype.xor=function(e){return t.isLong(e)||(e=t.fromValue(e)),t.fromBits(this.low^e.low,this.high^e.high,this.unsigned)},t.prototype.eqz=function(){return this.isZero()},t.prototype.le=function(e){return this.lessThanOrEqual(e)},t.prototype.toExtendedJSON=function(e){return e&&e.relaxed?this.toNumber():{$numberLong:this.toString()}},t.fromExtendedJSON=function(e,n){var r=t.fromString(e.$numberLong);return n&&n.relaxed?r.toNumber():r},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t.prototype.inspect=function(){return'new Long("'.concat(this.toString(),'"').concat(this.unsigned?", true":"",")")},t.TWO_PWR_24=t.fromInt(hh),t.MAX_UNSIGNED_VALUE=t.fromBits(-1,-1,!0),t.ZERO=t.fromInt(0),t.UZERO=t.fromInt(0,!0),t.ONE=t.fromInt(1),t.UONE=t.fromInt(1,!0),t.NEG_ONE=t.fromInt(-1),t.MAX_VALUE=t.fromBits(-1,2147483647,!1),t.MIN_VALUE=t.fromBits(0,-2147483648,!1),t})();Object.defineProperty(G.prototype,"__isLong__",{value:!0});Object.defineProperty(G.prototype,"_bsontype",{value:"Long"});var mh=/^(\+|-)?(\d+|(\d*\.\d*))?(E|e)?([-+])?(\d+)?$/,gh=/^(\+|-)?(Infinity|inf)$/i,_h=/^(\+|-)?NaN$/i,Lr=6111,fs=-6176,Al=6176,yh=34,ds=[124,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0].reverse(),Dl=[248,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0].reverse(),Nl=[120,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0].reverse(),vh=/^([-+])?(\d+)?$/,Eh=31,Rl=16383,bh=30,wh=31;function Ml(t){return!isNaN(parseInt(t,10))}function Sh(t){var e=G.fromNumber(1e9),n=G.fromNumber(0);if(!t.parts[0]&&!t.parts[1]&&!t.parts[2]&&!t.parts[3])return{quotient:t,rem:n};for(var r=0;r<=3;r++)n=n.shiftLeft(32),n=n.add(new G(t.parts[r],0)),t.parts[r]=n.div(e).low,n=n.modulo(e);return{quotient:t,rem:n}}function Ch(t,e){if(!t&&!e)return{high:G.fromNumber(0),low:G.fromNumber(0)};var n=t.shiftRightUnsigned(32),r=new G(t.getLowBits(),0),i=e.shiftRightUnsigned(32),o=new G(e.getLowBits(),0),s=n.multiply(i),l=n.multiply(o),u=r.multiply(i),d=r.multiply(o);return s=s.add(l.shiftRightUnsigned(32)),l=new G(l.getLowBits(),0).add(u).add(d.shiftRightUnsigned(32)),s=s.add(l.shiftRightUnsigned(32)),d=l.shiftLeft(32).add(new G(d.getLowBits(),0)),{high:s,low:d}}function Ih(t,e){var n=t.high>>>0,r=e.high>>>0;if(n<r)return!0;if(n===r){var i=t.low>>>0,o=e.low>>>0;if(i<o)return!0}return!1}function Xn(t,e){throw new Se('"'.concat(t,'" is not a valid Decimal128 string - ').concat(e))}var _s=(function(){function t(e){if(!(this instanceof t))return new t(e);if(typeof e=="string")this.bytes=t.fromString(e).bytes;else if(gs(e)){if(e.byteLength!==16)throw new Se("Decimal128 must take a Buffer of 16 bytes");this.bytes=e}else throw new Se("Decimal128 must take a Buffer or string")}return t.fromString=function(e){var n=!1,r=!1,i=!1,o=0,s=0,l=0,u=0,d=0,_=[0],p=0,v=0,E=0,T=0,N=0,F=0,B=new G(0,0),k=new G(0,0),W=0,V=0;if(e.length>=7e3)throw new Se(""+e+" not a valid Decimal128 string");var he=e.match(mh),P=e.match(gh),q=e.match(_h);if(!he&&!P&&!q||e.length===0)throw new Se(""+e+" not a valid Decimal128 string");if(he){var z=he[2],J=he[4],me=he[5],se=he[6];J&&se===void 0&&Xn(e,"missing exponent power"),J&&z===void 0&&Xn(e,"missing exponent base"),J===void 0&&(me||se)&&Xn(e,"missing e before exponent")}if((e[V]==="+"||e[V]==="-")&&(n=e[V++]==="-"),!Ml(e[V])&&e[V]!=="."){if(e[V]==="i"||e[V]==="I")return new t(re.from(n?Dl:Nl));if(e[V]==="N")return new t(re.from(ds))}for(;Ml(e[V])||e[V]===".";){if(e[V]==="."){r&&Xn(e,"contains multiple periods"),r=!0,V=V+1;continue}p<34&&(e[V]!=="0"||i)&&(i||(d=s),i=!0,_[v++]=parseInt(e[V],10),p=p+1),i&&(l=l+1),r&&(u=u+1),s=s+1,V=V+1}if(r&&!s)throw new Se(""+e+" not a valid Decimal128 string");if(e[V]==="e"||e[V]==="E"){var ge=e.substr(++V).match(vh);if(!ge||!ge[2])return new t(re.from(ds));N=parseInt(ge[0],10),V=V+ge[0].length}if(e[V])return new t(re.from(ds));if(E=0,!p)E=0,T=0,_[0]=0,l=1,p=1,o=0;else if(T=p-1,o=l,o!==1)for(;_[d+o-1]===0;)o=o-1;for(N<=u&&u-N>16384?N=fs:N=N-u;N>Lr;){if(T=T+1,T-E>yh){var Oe=_.join("");if(Oe.match(/^0+$/)){N=Lr;break}Xn(e,"overflow")}N=N-1}for(;N<fs||p<l;){if(T===0&&o<p){N=fs,o=0;break}if(p<l?l=l-1:T=T-1,N<Lr)N=N+1;else{var Oe=_.join("");if(Oe.match(/^0+$/)){N=Lr;break}Xn(e,"overflow")}}if(T-E+1<o){var Fe=s;r&&(d=d+1,Fe=Fe+1),n&&(d=d+1,Fe=Fe+1);var Tt=parseInt(e[d+T+1],10),yt=0;if(Tt>=5&&(yt=1,Tt===5)){for(yt=_[T]%2===1?1:0,F=d+T+2;F<Fe;F++)if(parseInt(e[F],10)){yt=1;break}}if(yt){for(var pe=T;pe>=0;pe--)if(++_[pe]>9&&(_[pe]=0,pe===0))if(N<Lr)N=N+1,_[pe]=1;else return new t(re.from(n?Dl:Nl))}}if(B=G.fromNumber(0),k=G.fromNumber(0),o===0)B=G.fromNumber(0),k=G.fromNumber(0);else if(T-E<17){var pe=E;for(k=G.fromNumber(_[pe++]),B=new G(0,0);pe<=T;pe++)k=k.multiply(G.fromNumber(10)),k=k.add(G.fromNumber(_[pe]))}else{var pe=E;for(B=G.fromNumber(_[pe++]);pe<=T-17;pe++)B=B.multiply(G.fromNumber(10)),B=B.add(G.fromNumber(_[pe]));for(k=G.fromNumber(_[pe++]);pe<=T;pe++)k=k.multiply(G.fromNumber(10)),k=k.add(G.fromNumber(_[pe]))}var ke=Ch(B,G.fromString("100000000000000000"));ke.low=ke.low.add(k),Ih(ke.low,k)&&(ke.high=ke.high.add(G.fromNumber(1))),W=N+Al;var te={low:G.fromNumber(0),high:G.fromNumber(0)};ke.high.shiftRightUnsigned(49).and(G.fromNumber(1)).equals(G.fromNumber(1))?(te.high=te.high.or(G.fromNumber(3).shiftLeft(61)),te.high=te.high.or(G.fromNumber(W).and(G.fromNumber(16383).shiftLeft(47))),te.high=te.high.or(ke.high.and(G.fromNumber(0x7fffffffffff)))):(te.high=te.high.or(G.fromNumber(W&16383).shiftLeft(49)),te.high=te.high.or(ke.high.and(G.fromNumber(562949953421311)))),te.low=ke.low,n&&(te.high=te.high.or(G.fromString("9223372036854775808")));var Z=re.alloc(16);return V=0,Z[V++]=te.low.low&255,Z[V++]=te.low.low>>8&255,Z[V++]=te.low.low>>16&255,Z[V++]=te.low.low>>24&255,Z[V++]=te.low.high&255,Z[V++]=te.low.high>>8&255,Z[V++]=te.low.high>>16&255,Z[V++]=te.low.high>>24&255,Z[V++]=te.high.low&255,Z[V++]=te.high.low>>8&255,Z[V++]=te.high.low>>16&255,Z[V++]=te.high.low>>24&255,Z[V++]=te.high.high&255,Z[V++]=te.high.high>>8&255,Z[V++]=te.high.high>>16&255,Z[V++]=te.high.high>>24&255,new t(Z)},t.prototype.toString=function(){for(var e,n=0,r=new Array(36),i=0;i<r.length;i++)r[i]=0;var o=0,s=!1,l,u={parts:[0,0,0,0]},d,_,p=[];o=0;var v=this.bytes,E=v[o++]|v[o++]<<8|v[o++]<<16|v[o++]<<24,T=v[o++]|v[o++]<<8|v[o++]<<16|v[o++]<<24,N=v[o++]|v[o++]<<8|v[o++]<<16|v[o++]<<24,F=v[o++]|v[o++]<<8|v[o++]<<16|v[o++]<<24;o=0;var B={low:new G(E,T),high:new G(N,F)};B.high.lessThan(G.ZERO)&&p.push("-");var k=F>>26&Eh;if(k>>3===3){if(k===bh)return p.join("")+"Infinity";if(k===wh)return"NaN";e=F>>15&Rl,l=8+(F>>14&1)}else l=F>>14&7,e=F>>17&Rl;var W=e-Al;if(u.parts[0]=(F&16383)+((l&15)<<14),u.parts[1]=N,u.parts[2]=T,u.parts[3]=E,u.parts[0]===0&&u.parts[1]===0&&u.parts[2]===0&&u.parts[3]===0)s=!0;else for(_=3;_>=0;_--){var V=0,he=Sh(u);if(u=he.quotient,V=he.rem.low,!!V)for(d=8;d>=0;d--)r[_*9+d]=V%10,V=Math.floor(V/10)}if(s)n=1,r[o]=0;else for(n=36;!r[o];)n=n-1,o=o+1;var P=n-1+W;if(P>=34||P<=-7||W>0){if(n>34)return p.push("".concat(0)),W>0?p.push("E+".concat(W)):W<0&&p.push("E".concat(W)),p.join("");p.push("".concat(r[o++])),n=n-1,n&&p.push(".");for(var i=0;i<n;i++)p.push("".concat(r[o++]));p.push("E"),P>0?p.push("+".concat(P)):p.push("".concat(P))}else if(W>=0)for(var i=0;i<n;i++)p.push("".concat(r[o++]));else{var q=n+W;if(q>0)for(var i=0;i<q;i++)p.push("".concat(r[o++]));else p.push("0");for(p.push(".");q++<0;)p.push("0");for(var i=0;i<n-Math.max(q-1,0);i++)p.push("".concat(r[o++]))}return p.join("")},t.prototype.toJSON=function(){return{$numberDecimal:this.toString()}},t.prototype.toExtendedJSON=function(){return{$numberDecimal:this.toString()}},t.fromExtendedJSON=function(e){return t.fromString(e.$numberDecimal)},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t.prototype.inspect=function(){return'new Decimal128("'.concat(this.toString(),'")')},t})();Object.defineProperty(_s.prototype,"_bsontype",{value:"Decimal128"});var Bi=(function(){function t(e){if(!(this instanceof t))return new t(e);e instanceof Number&&(e=e.valueOf()),this.value=+e}return t.prototype.valueOf=function(){return this.value},t.prototype.toJSON=function(){return this.value},t.prototype.toString=function(e){return this.value.toString(e)},t.prototype.toExtendedJSON=function(e){return e&&(e.legacy||e.relaxed&&isFinite(this.value))?this.value:Object.is(Math.sign(this.value),-0)?{$numberDouble:"-".concat(this.value.toFixed(1))}:{$numberDouble:Number.isInteger(this.value)?this.value.toFixed(1):this.value.toString()}},t.fromExtendedJSON=function(e,n){var r=parseFloat(e.$numberDouble);return n&&n.relaxed?r:new t(r)},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t.prototype.inspect=function(){var e=this.toExtendedJSON();return"new Double(".concat(e.$numberDouble,")")},t})();Object.defineProperty(Bi.prototype,"_bsontype",{value:"Double"});var Vi=(function(){function t(e){if(!(this instanceof t))return new t(e);e instanceof Number&&(e=e.valueOf()),this.value=+e|0}return t.prototype.valueOf=function(){return this.value},t.prototype.toString=function(e){return this.value.toString(e)},t.prototype.toJSON=function(){return this.value},t.prototype.toExtendedJSON=function(e){return e&&(e.relaxed||e.legacy)?this.value:{$numberInt:this.value.toString()}},t.fromExtendedJSON=function(e,n){return n&&n.relaxed?parseInt(e.$numberInt,10):new t(e.$numberInt)},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t.prototype.inspect=function(){return"new Int32(".concat(this.valueOf(),")")},t})();Object.defineProperty(Vi.prototype,"_bsontype",{value:"Int32"});var ys=(function(){function t(){if(!(this instanceof t))return new t}return t.prototype.toExtendedJSON=function(){return{$maxKey:1}},t.fromExtendedJSON=function(){return new t},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t.prototype.inspect=function(){return"new MaxKey()"},t})();Object.defineProperty(ys.prototype,"_bsontype",{value:"MaxKey"});var vs=(function(){function t(){if(!(this instanceof t))return new t}return t.prototype.toExtendedJSON=function(){return{$minKey:1}},t.fromExtendedJSON=function(){return new t},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t.prototype.inspect=function(){return"new MinKey()"},t})();Object.defineProperty(vs.prototype,"_bsontype",{value:"MinKey"});var Th=new RegExp("^[0-9a-fA-F]{24}$"),Tn=null,Ft=Symbol("id"),Ye=(function(){function t(e){if(!(this instanceof t))return new t(e);var n;if(typeof e=="object"&&e&&"id"in e){if(typeof e.id!="string"&&!ArrayBuffer.isView(e.id))throw new Se("Argument passed in must have an id that is of type string or Buffer");"toHexString"in e&&typeof e.toHexString=="function"?n=re.from(e.toHexString(),"hex"):n=e.id}else n=e;if(n==null||typeof n=="number")this[Ft]=t.generate(typeof n=="number"?n:void 0);else if(ArrayBuffer.isView(n)&&n.byteLength===12)this[Ft]=n instanceof re?n:Mi(n);else if(typeof n=="string")if(n.length===12){var r=re.from(n);if(r.byteLength===12)this[Ft]=r;else throw new Se("Argument passed in must be a string of 12 bytes")}else if(n.length===24&&Th.test(n))this[Ft]=re.from(n,"hex");else throw new Se("Argument passed in must be a string of 12 bytes or a string of 24 hex characters or an integer");else throw new Se("Argument passed in does not match the accepted types");t.cacheHexString&&(this.__id=this.id.toString("hex"))}return Object.defineProperty(t.prototype,"id",{get:function(){return this[Ft]},set:function(e){this[Ft]=e,t.cacheHexString&&(this.__id=e.toString("hex"))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"generationTime",{get:function(){return this.id.readInt32BE(0)},set:function(e){this.id.writeUInt32BE(e,0)},enumerable:!1,configurable:!0}),t.prototype.toHexString=function(){if(t.cacheHexString&&this.__id)return this.__id;var e=this.id.toString("hex");return t.cacheHexString&&!this.__id&&(this.__id=e),e},t.getInc=function(){return t.index=(t.index+1)%16777215},t.generate=function(e){typeof e!="number"&&(e=Math.floor(Date.now()/1e3));var n=t.getInc(),r=re.alloc(12);return r.writeUInt32BE(e,0),Tn===null&&(Tn=Ul(5)),r[4]=Tn[0],r[5]=Tn[1],r[6]=Tn[2],r[7]=Tn[3],r[8]=Tn[4],r[11]=n&255,r[10]=n>>8&255,r[9]=n>>16&255,r},t.prototype.toString=function(e){return e?this.id.toString(e):this.toHexString()},t.prototype.toJSON=function(){return this.toHexString()},t.prototype.equals=function(e){if(e==null)return!1;if(e instanceof t)return this[Ft][11]===e[Ft][11]&&this[Ft].equals(e[Ft]);if(typeof e=="string"&&t.isValid(e)&&e.length===12&&gs(this.id))return e===re.prototype.toString.call(this.id,"latin1");if(typeof e=="string"&&t.isValid(e)&&e.length===24)return e.toLowerCase()===this.toHexString();if(typeof e=="string"&&t.isValid(e)&&e.length===12)return re.from(e).equals(this.id);if(typeof e=="object"&&"toHexString"in e&&typeof e.toHexString=="function"){var n=e.toHexString(),r=this.toHexString().toLowerCase();return typeof n=="string"&&n.toLowerCase()===r}return!1},t.prototype.getTimestamp=function(){var e=new Date,n=this.id.readUInt32BE(0);return e.setTime(Math.floor(n)*1e3),e},t.createPk=function(){return new t},t.createFromTime=function(e){var n=re.from([0,0,0,0,0,0,0,0,0,0,0,0]);return n.writeUInt32BE(e,0),new t(n)},t.createFromHexString=function(e){if(typeof e>"u"||e!=null&&e.length!==24)throw new Se("Argument passed in must be a single String of 12 bytes or a string of 24 hex characters");return new t(re.from(e,"hex"))},t.isValid=function(e){if(e==null)return!1;try{return new t(e),!0}catch{return!1}},t.prototype.toExtendedJSON=function(){return this.toHexString?{$oid:this.toHexString()}:{$oid:this.toString("hex")}},t.fromExtendedJSON=function(e){return new t(e.$oid)},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t.prototype.inspect=function(){return'new ObjectId("'.concat(this.toHexString(),'")')},t.index=Math.floor(Math.random()*16777215),t})();Object.defineProperty(Ye.prototype,"generate",{value:Fi(function(t){return Ye.generate(t)},"Please use the static `ObjectId.generate(time)` instead")});Object.defineProperty(Ye.prototype,"getInc",{value:Fi(function(){return Ye.getInc()},"Please use the static `ObjectId.getInc()` instead")});Object.defineProperty(Ye.prototype,"get_inc",{value:Fi(function(){return Ye.getInc()},"Please use the static `ObjectId.getInc()` instead")});Object.defineProperty(Ye,"get_inc",{value:Fi(function(){return Ye.getInc()},"Please use the static `ObjectId.getInc()` instead")});Object.defineProperty(Ye.prototype,"_bsontype",{value:"ObjectID"});function xh(t){return t.split("").sort().join("")}var kr=(function(){function t(e,n){if(!(this instanceof t))return new t(e,n);if(this.pattern=e,this.options=xh(n??""),this.pattern.indexOf("\0")!==-1)throw new xn("BSON Regex patterns cannot contain null bytes, found: ".concat(JSON.stringify(this.pattern)));if(this.options.indexOf("\0")!==-1)throw new xn("BSON Regex options cannot contain null bytes, found: ".concat(JSON.stringify(this.options)));for(var r=0;r<this.options.length;r++)if(!(this.options[r]==="i"||this.options[r]==="m"||this.options[r]==="x"||this.options[r]==="l"||this.options[r]==="s"||this.options[r]==="u"))throw new xn("The regular expression option [".concat(this.options[r],"] is not supported"))}return t.parseOptions=function(e){return e?e.split("").sort().join(""):""},t.prototype.toExtendedJSON=function(e){return e=e||{},e.legacy?{$regex:this.pattern,$options:this.options}:{$regularExpression:{pattern:this.pattern,options:this.options}}},t.fromExtendedJSON=function(e){if("$regex"in e)if(typeof e.$regex!="string"){if(e.$regex._bsontype==="BSONRegExp")return e}else return new t(e.$regex,t.parseOptions(e.$options));if("$regularExpression"in e)return new t(e.$regularExpression.pattern,t.parseOptions(e.$regularExpression.options));throw new Se("Unexpected BSONRegExp EJSON object form: ".concat(JSON.stringify(e)))},t})();Object.defineProperty(kr.prototype,"_bsontype",{value:"BSONRegExp"});var Es=(function(){function t(e){if(!(this instanceof t))return new t(e);this.value=e}return t.prototype.valueOf=function(){return this.value},t.prototype.toString=function(){return this.value},t.prototype.inspect=function(){return'new BSONSymbol("'.concat(this.value,'")')},t.prototype.toJSON=function(){return this.value},t.prototype.toExtendedJSON=function(){return{$symbol:this.value}},t.fromExtendedJSON=function(e){return new t(e.$symbol)},t.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},t})();Object.defineProperty(Es.prototype,"_bsontype",{value:"Symbol"});var Oh=G,Gl=(function(t){Li(e,t);function e(n,r){var i=this;return i instanceof e?(G.isLong(n)?i=t.call(this,n.low,n.high,!0)||this:Br(n)&&typeof n.t<"u"&&typeof n.i<"u"?i=t.call(this,n.i,n.t,!0)||this:i=t.call(this,n,r,!0)||this,Object.defineProperty(i,"_bsontype",{value:"Timestamp",writable:!1,configurable:!1,enumerable:!1}),i):new e(n,r)}return e.prototype.toJSON=function(){return{$timestamp:this.toString()}},e.fromInt=function(n){return new e(G.fromInt(n,!0))},e.fromNumber=function(n){return new e(G.fromNumber(n,!0))},e.fromBits=function(n,r){return new e(n,r)},e.fromString=function(n,r){return new e(G.fromString(n,!0,r))},e.prototype.toExtendedJSON=function(){return{$timestamp:{t:this.high>>>0,i:this.low>>>0}}},e.fromExtendedJSON=function(n){return new e(n.$timestamp)},e.prototype[Symbol.for("nodejs.util.inspect.custom")]=function(){return this.inspect()},e.prototype.inspect=function(){return"new Timestamp({ t: ".concat(this.getHighBits(),", i: ").concat(this.getLowBits()," })")},e.MAX_VALUE=G.MAX_UNSIGNED_VALUE,e})(Oh);function Ah(t){return Br(t)&&Reflect.has(t,"_bsontype")&&typeof t._bsontype=="string"}var Wl=2147483647,Yl=-2147483648,zl=9223372036854776e3,Xl=-9223372036854776e3,Dh={$oid:Ye,$binary:On,$uuid:On,$symbol:Es,$numberInt:Vi,$numberDecimal:_s,$numberDouble:Bi,$numberLong:G,$minKey:vs,$maxKey:ys,$regex:kr,$regularExpression:kr,$timestamp:Gl};function ql(t,e){if(e===void 0&&(e={}),typeof t=="number"){if(e.relaxed||e.legacy)return t;if(Math.floor(t)===t){if(t>=Yl&&t<=Wl)return new Vi(t);if(t>=Xl&&t<=zl)return G.fromNumber(t)}return new Bi(t)}if(t==null||typeof t!="object")return t;if(t.$undefined)return null;for(var n=Object.keys(t).filter(function(p){return p.startsWith("$")&&t[p]!=null}),r=0;r<n.length;r++){var i=Dh[n[r]];if(i)return i.fromExtendedJSON(t,e)}if(t.$date!=null){var o=t.$date,s=new Date;return e.legacy?typeof o=="number"?s.setTime(o):typeof o=="string"&&s.setTime(Date.parse(o)):typeof o=="string"?s.setTime(Date.parse(o)):G.isLong(o)?s.setTime(o.toNumber()):typeof o=="number"&&e.relaxed&&s.setTime(o),s}if(t.$code!=null){var l=Object.assign({},t);return t.$scope&&(l.$scope=ql(t.$scope)),ki.fromExtendedJSON(t)}if(ph(t)||t.$dbPointer){var u=t.$ref?t:t.$dbPointer;if(u instanceof Fr)return u;var d=Object.keys(u).filter(function(p){return p.startsWith("$")}),_=!0;if(d.forEach(function(p){["$ref","$id","$db"].indexOf(p)===-1&&(_=!1)}),_)return Fr.fromExtendedJSON(u)}return t}function Nh(t,e){return t.map(function(n,r){e.seenObjects.push({propertyName:"index ".concat(r),obj:null});try{return pn(n,e)}finally{e.seenObjects.pop()}})}function Pl(t){var e=t.toISOString();return t.getUTCMilliseconds()!==0?e:e.slice(0,-5)+"Z"}function pn(t,e){if((typeof t=="object"||typeof t=="function")&&t!==null){var n=e.seenObjects.findIndex(function(B){return B.obj===t});if(n!==-1){var r=e.seenObjects.map(function(B){return B.propertyName}),i=r.slice(0,n).map(function(B){return"".concat(B," -> ")}).join(""),o=r[n],s=" -> "+r.slice(n+1,r.length-1).map(function(B){return"".concat(B," -> ")}).join(""),l=r[r.length-1],u=" ".repeat(i.length+o.length/2),d="-".repeat(s.length+(o.length+l.length)/2-1);throw new Se(`Converting circular structure to EJSON:
|
|
2
|
+
`+" ".concat(i).concat(o).concat(s).concat(l,`
|
|
3
|
+
`)+" ".concat(u,"\\").concat(d,"/"))}e.seenObjects[e.seenObjects.length-1].obj=t}if(Array.isArray(t))return Nh(t,e);if(t===void 0)return null;if(t instanceof Date||lh(t)){var _=t.getTime(),p=_>-1&&_<2534023188e5;return e.legacy?e.relaxed&&p?{$date:t.getTime()}:{$date:Pl(t)}:e.relaxed&&p?{$date:Pl(t)}:{$date:{$numberLong:t.getTime().toString()}}}if(typeof t=="number"&&(!e.relaxed||!isFinite(t))){if(Math.floor(t)===t){var v=t>=Yl&&t<=Wl,E=t>=Xl&&t<=zl;if(v)return{$numberInt:t.toString()};if(E)return{$numberLong:t.toString()}}return{$numberDouble:t.toString()}}if(t instanceof RegExp||ch(t)){var T=t.flags;if(T===void 0){var N=t.toString().match(/[gimuy]*$/);N&&(T=N[0])}var F=new kr(t.source,T);return F.toExtendedJSON(e)}return t!=null&&typeof t=="object"?Mh(t,e):t}var Rh={Binary:function(t){return new On(t.value(),t.sub_type)},Code:function(t){return new ki(t.code,t.scope)},DBRef:function(t){return new Fr(t.collection||t.namespace,t.oid,t.db,t.fields)},Decimal128:function(t){return new _s(t.bytes)},Double:function(t){return new Bi(t.value)},Int32:function(t){return new Vi(t.value)},Long:function(t){return G.fromBits(t.low!=null?t.low:t.low_,t.low!=null?t.high:t.high_,t.low!=null?t.unsigned:t.unsigned_)},MaxKey:function(){return new ys},MinKey:function(){return new vs},ObjectID:function(t){return new Ye(t)},ObjectId:function(t){return new Ye(t)},BSONRegExp:function(t){return new kr(t.pattern,t.options)},Symbol:function(t){return new Es(t.value)},Timestamp:function(t){return Gl.fromBits(t.low,t.high)}};function Mh(t,e){if(t==null||typeof t!="object")throw new xn("not an object instance");var n=t._bsontype;if(typeof n>"u"){var r={};for(var i in t){e.seenObjects.push({propertyName:i,obj:null});try{var o=pn(t[i],e);i==="__proto__"?Object.defineProperty(r,i,{value:o,writable:!0,enumerable:!0,configurable:!0}):r[i]=o}finally{e.seenObjects.pop()}}return r}else if(Ah(t)){var s=t;if(typeof s.toExtendedJSON!="function"){var l=Rh[t._bsontype];if(!l)throw new Se("Unrecognized or invalid _bsontype: "+t._bsontype);s=l(s)}return n==="Code"&&s.scope?s=new ki(s.code,pn(s.scope,e)):n==="DBRef"&&s.oid&&(s=new Fr(pn(s.collection,e),pn(s.oid,e),pn(s.db,e),pn(s.fields,e))),s.toExtendedJSON(e)}else throw new xn("_bsontype must be a string, but was: "+typeof n)}var Ll;(function(t){function e(o,s){var l=Object.assign({},{relaxed:!0,legacy:!1},s);return typeof l.relaxed=="boolean"&&(l.strict=!l.relaxed),typeof l.strict=="boolean"&&(l.relaxed=!l.strict),JSON.parse(o,function(u,d){if(u.indexOf("\0")!==-1)throw new xn("BSON Document field names cannot contain null bytes, found: ".concat(JSON.stringify(u)));return ql(d,l)})}t.parse=e;function n(o,s,l,u){l!=null&&typeof l=="object"&&(u=l,l=0),s!=null&&typeof s=="object"&&!Array.isArray(s)&&(u=s,s=void 0,l=0);var d=Object.assign({relaxed:!0,legacy:!1},u,{seenObjects:[{propertyName:"(root)",obj:null}]}),_=pn(o,d);return JSON.stringify(_,s,l)}t.stringify=n;function r(o,s){return s=s||{},JSON.parse(n(o,s))}t.serialize=r;function i(o,s){return s=s||{},e(JSON.stringify(o),s)}t.deserialize=i})(Ll||(Ll={}));var Fl,kl=Vl();kl.Map?Fl=kl.Map:Fl=(function(){function t(e){e===void 0&&(e=[]),this._keys=[],this._values={};for(var n=0;n<e.length;n++)if(e[n]!=null){var r=e[n],i=r[0],o=r[1];this._keys.push(i),this._values[i]={v:o,i:this._keys.length-1}}}return t.prototype.clear=function(){this._keys=[],this._values={}},t.prototype.delete=function(e){var n=this._values[e];return n==null?!1:(delete this._values[e],this._keys.splice(n.i,1),!0)},t.prototype.entries=function(){var e=this,n=0;return{next:function(){var r=e._keys[n++];return{value:r!==void 0?[r,e._values[r].v]:void 0,done:r===void 0}}}},t.prototype.forEach=function(e,n){n=n||this;for(var r=0;r<this._keys.length;r++){var i=this._keys[r];e.call(n,this._values[i].v,i,n)}},t.prototype.get=function(e){return this._values[e]?this._values[e].v:void 0},t.prototype.has=function(e){return this._values[e]!=null},t.prototype.keys=function(){var e=this,n=0;return{next:function(){var r=e._keys[n++];return{value:r!==void 0?r:void 0,done:r===void 0}}}},t.prototype.set=function(e,n){return this._values[e]?(this._values[e].v=n,this):(this._keys.push(e),this._values[e]={v:n,i:this._keys.length-1},this)},t.prototype.values=function(){var e=this,n=0;return{next:function(){var r=e._keys[n++];return{value:r!==void 0?e._values[r].v:void 0,done:r===void 0}}}},Object.defineProperty(t.prototype,"size",{get:function(){return this._keys.length},enumerable:!1,configurable:!0}),t})();var Qv=G.fromNumber(fh),e0=G.fromNumber(dh);var ps=new Uint8Array(8),t0=new DataView(ps.buffer,ps.byteOffset,ps.byteLength);var Ph=1024*1024*17,n0=re.alloc(Ph);var Ui=class{triggerID;nudgeID;engagementID;contentID;shortID;contentType;variation;props;objective;onsiteDeliveryType;holdout;constructor(e){e=e||{},this.triggerID=e.id||e.triggerID,this.nudgeID=e.nudgeID,this.shortID=e.shortID,this.contentType=e.contentType,this.engagementID=e.engagementID,this.contentID=e.contentID,this.variation=e.variation,this.props=e.props,this.objective=e.objective,this.onsiteDeliveryType=e.onsiteDeliveryType,this.holdout=e.holdout}};var Hi=class{constructor(e,n={},r,i){this.name=e;this.properties=n;this.id=i?new Ye(i):new Ye,this.occurred=new Date,r&&(this.trigger=new Ui(r)),this.newEvent=!i}trigger;items;videos;id;newEvent;cart;currentItem;deviceProps;landingPage;occurred;page;sessionID;sessionNumber;locale;setVideos(e){e&&(this.videos=[e.id])}};var Lh={"[class.ng-untouched]":"isUntouched","[class.ng-touched]":"isTouched","[class.ng-pristine]":"isPristine","[class.ng-dirty]":"isDirty","[class.ng-valid]":"isValid","[class.ng-invalid]":"isInvalid","[class.ng-pending]":"isPending"},x0=K(I({},Lh),{"[class.ng-submitted]":"isSubmitted"});var Fh=new Je("",{providedIn:"root",factory:()=>Zl}),Zl="always";var kh=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275mod=Sn({type:t});static \u0275inj=wn({})}return t})();var Ql=(()=>{class t{static withConfig(n){return{ngModule:t,providers:[{provide:Fh,useValue:n.callSetDisabledState??Zl}]}}static \u0275fac=function(r){return new(r||t)};static \u0275mod=Sn({type:t});static \u0275inj=wn({imports:[kh]})}return t})();var bs=(function(t){return t.SHOPIFY_CHECKOUT="shopify_checkout",t.THIRD_PARTY_CHECKOUT="third_party_checkout",t.CART_PAGE="cart_page",t.CART_DRAWER="cart_drawer",t})(bs||{});var Zt=(function(t){return t[t.NONE=0]="NONE",t[t.REJECT_POPUP=1]="REJECT_POPUP",t[t.ACCEPT_POPUP=2]="ACCEPT_POPUP",t[t.GO_TO_URL=4]="GO_TO_URL",t[t.SHARE=5]="SHARE",t[t.KEY_VALUE=100]="KEY_VALUE",t[t.GO_TO_PRODUCT=101]="GO_TO_PRODUCT",t[t.ADD_TO_CART=102]="ADD_TO_CART",t[t.COPY_COUPON_CODE=103]="COPY_COUPON_CODE",t[t.GO_TO_COLLECTION=104]="GO_TO_COLLECTION",t[t.OPEN_CART=105]="OPEN_CART",t[t.SUBMIT_FORM=106]="SUBMIT_FORM",t[t.INITIATE_CHECKOUT=107]="INITIATE_CHECKOUT",t[t.ADD_BUNDLE=108]="ADD_BUNDLE",t[t.UPGRADE_TO_SUBSCRIPTION=109]="UPGRADE_TO_SUBSCRIPTION",t[t.BUY_NOW=110]="BUY_NOW",t[t.QUICK_VIEW=111]="QUICK_VIEW",t})(Zt||{});var Bh=(function(t){return t.FREE_SHIPPING="FREE_SHIPPING",t.DISCOUNT="DISCOUNT",t.FREE_AUTO_GIFT="FREE_AUTO_GIFT",t.FREE_GIFT_SELECT="FREE_GIFT_SELECT",t.UI_ONLY="UI_ONLY",t})(Bh||{});var hn=class t{engagementContext=U(Pr);eventData=U(Ni);constructor(){}executeCTA(e,n){let r,i=this.engagementContext();if(!i){Te.error("Engagement context is not available; aborting executeCTA.");return}if(e===Zt.ADD_TO_CART)r="CE Add To Cart Clicked";else if(e===Zt.GO_TO_PRODUCT)r="CE View Item Clicked";else if(e===Zt.OPEN_CART)r="CE Open Cart Clicked",i.triggerData.redirectBehaviour=bs.CART_DRAWER;else{Te.warn(`Unsupported CTA type: ${e}`);return}window.CooeeSDK.executeCTA(i,I({clickAction:{at:e}},n));let o=new Hi(r,this.eventData.props,i.triggerData);n?.video?o.setVideos(n.video):this.eventData.video&&o.setVideos(this.eventData.video),window.CooeeSDK.sendEvent(o)}static \u0275fac=function(n){return new(n||t)};static \u0275prov=Be({token:t,factory:t.\u0275fac})};function tE(t,e){return[hn,...Uh(t,e)]}function Uh(t,e){return[{provide:Pr,useValue:xt(t)},{provide:Ni,useValue:I({},e)}]}var ji=class t{elementRef=U(ut);engagementService=U(hn);hasSwiper=!1;_engagementTrigger=xt(null);_triggerContext=U(Pr);constructor(){this.elementRef.nativeElement.update=this.update.bind(this)}get classes(){let e=["letscooee-widget"],n=this._engagementTrigger();return e.push(`widget-${n?.shortID}`),e}get triggerContext(){return this._triggerContext()}set triggerContext(e){this._triggerContext.set(e),this._engagementTrigger.set(e.triggerData),this.engagementTriggerReceived(e.triggerData)}get engagementTrigger(){return this._engagementTrigger()}ngOnInit(){Te.verbose("Init",this.constructor.name);let e=this.elementRef.nativeElement.shadowRoot;e&&bl(e,this.hasSwiper)}ngOnDestroy(){Te.verbose("Destroying",this.constructor.name)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=ve({type:t,selectors:[["ng-component"]],hostVars:2,hostBindings:function(n,r){n&2&&bi(r.classes)},inputs:{triggerContext:"triggerContext"},decls:1,vars:0,template:function(n,r){n&1&&Xc(0)},encapsulation:2})};var Hh=(t,e)=>({"--option-color":t,"background-color":e}),eu=(t,e)=>e.id;function jh(t,e){if(t&1&&(ce(0,"span",6),we(1),ue()),t&2){ne();let n=Qe(0);$(),un(n)}}function $h(t,e){if(t&1){let n=Dt();Rt(0),ce(1,"button",5),bt("click",function(){let i=tt(n).$implicit,o=ne().$implicit,s=ne();return nt(s.onOptionChange(o,i))}),Ee(2,jh,2,1,"span",6),ue()}if(t&2){let n=e.$implicit,r=ne().$implicit,i=Qe(1),o=n.name,s=Mt(n.displayName||n.name),l=i?n.hexColor??o:"",u=ne().selectedOptions()[r.name]===o;$(),Ar("color-type",i)("selected",u)("disabled",n.disabled),De("title",s)("ngStyle",Ci(14,Hh,l,l)),At("aria-checked",u?"true":"false")("data-value",o)("aria-disabled",n.disabled?"true":null)("aria-label",s),$(),be(i?-1:2)}}function Gh(t,e){if(t&1&&(ce(0,"div"),Rt(1),ce(2,"div",1),we(3),ue(),ce(4,"div",2),we(5),ue(),ce(6,"div",3),$n(7,$h,3,17,"button",4,eu),ue()()),t&2){let n=e.$implicit,r=ne();bi(tl("option-group ",n.name.toLowerCase())),$(),Mt(r.hasHexColors(n)),$(2),Wn("",n.name,":"),$(2),un(r.selectedOptions()[n.name]),$(),At("aria-label",n.name),$(),Gn(n.optionValues)}}var Vr=t=>t.trim().toLowerCase(),$i=class t extends ji{selectedVariant=new vt;item=Ge.required();selectedOptions=xt({});options=qt(()=>{let e=this.item();if(!e.options||e.vars.length===1)return[];if(window.cooeeManipulateProduct)try{window.cooeeManipulateProduct(e,this.engagementTrigger)}catch(n){Te.error(n)}return e.options.forEach(n=>{n.optionValues.forEach(r=>{r.disabled=this.isOptionValueDisabledFast(n,r)})}),e.options});matchedVariant=qt(()=>{let e=this.item(),n=this.selectedOptions();return e.vars.find(r=>e.options.every(i=>{let o=r.selectedOptions.find(s=>s.name===i.name)?.value;return n[i.name]===o}))});availabilityIndex=qt(()=>{let e=this.item(),n=new Map;return e?.vars?.length&&e.vars.forEach((r,i)=>{if(r.isAvailable)for(let o of r.selectedOptions){let s=Vr(o.name),l=o.value,u=n.get(s);u||n.set(s,u=new Map);let d=u.get(l);d||u.set(l,d=new Set),d.add(i)}}),n});constructor(){super(),Kt(()=>{let n=this.matchedVariant();n&&(this.item().setSelectedVariant(n),this.selectedVariant.emit(n))});let e=Kt(()=>{let n=this.item();if(!n?.options)return;let r=I({},this.selectedOptions()),i=n.vars.find(o=>o.isAvailable)??n.vars[0];n.options.forEach(o=>{let s=i?.selectedOptions.find(l=>l.name===o.name)?.value;s&&(r[o.name]=s)}),this.selectedOptions.set(r),e.destroy()})}ngOnInit(){super.ngOnInit();let e=this.elementRef.nativeElement.shadowRoot;if(!e)return;let n=dn.get().website?.itemSwatchMapping;n&&as(n,e)}onOptionChange(e,n){let r=I({},this.selectedOptions());r[e.name]=n.name,this.selectedOptions.set(r)}engagementTriggerReceived(){}update(){}hasHexColors(e){return!!e.optionValues[0]?.name.match(/#[a-f0-9]{6}\b/i)}getCandidateVariantsExcluding(e){let n=this.item(),r=this.availabilityIndex(),i=new Set;n.vars.forEach((s,l)=>{s.isAvailable&&i.add(l)});let o=i;for(let[s,l]of Object.entries(this.selectedOptions())){if(Vr(s)===Vr(e))continue;let u=r.get(Vr(s));if(!u)return new Set;let d=u.get(String(l));if(!d)return new Set;if(o=new Set([...o].filter(_=>d.has(_))),o.size===0)return o}return o}isOptionValueDisabledFast(e,n){let i=this.availabilityIndex().get(Vr(e.name));if(!i)return!0;let o=n.name,s=i.get(o);if(!s||s.size===0)return!0;let l=this.getCandidateVariantsExcluding(e.name);if(l.size===0)return!0;for(let u of l)if(s.has(u))return!1;return!0}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=ve({type:t,selectors:[["cooee-item-options-picker"]],inputs:{item:[1,"item"]},outputs:{selectedVariant:"selectedVariant"},features:[Cn],decls:2,vars:0,consts:[[3,"class"],[1,"name"],[1,"selected-value"],["role","radiogroup",1,"option-values"],["type","button","role","radio",1,"option-value",3,"color-type","selected","disabled","title","ngStyle"],["type","button","role","radio",1,"option-value",3,"click","title","ngStyle"],[1,"title"]],template:function(n,r){n&1&&$n(0,Gh,9,7,"div",0,eu),n&2&&Gn(r.options())},dependencies:[al,ol,Ql],styles:[`.option-group{display:flex;gap:4px;align-items:center}.option-group+.option-group{margin-top:8px}.option-values{display:flex;flex-wrap:nowrap;overflow-x:auto;padding:6px;gap:4px;scrollbar-gutter:stable both-edges;scrollbar-width:none}.option-values::-webkit-scrollbar{display:none}.selected-value{display:none}.option-value{padding:5px 10px;border:1px solid #ccc;cursor:pointer;border-radius:4px;min-width:32px;min-height:32px;text-align:center;position:relative;flex-shrink:0;--selected-color: var(--option-color, rgba(var(--lc-primary-button-bg-color, 0 0 0)))}.option-value.selected{box-shadow:#fff 0 0 0 2px,var(--selected-color) 0 0 0 4px}.option-value.disabled{opacity:.5;pointer-events:none}
|
|
4
|
+
`],encapsulation:3})};var Ss=ts(nu());function Gi(t){return Ss.default.createInstance({name:"lc",storeName:t,driver:Ss.default.LOCALSTORAGE})}var Kn=class{static storage;static async get(e,n){return await this.storage?.getItem(e)??n}static set(e,n){return this.storage?.setItem(e,n)}static remove(e){return this.storage?.removeItem(e)}static clear(){return this.storage?.clear()}static getForage(){return this.storage}};var Ur=class Ur extends Kn{};_i(Ur,"storeName","usr"),Ur.storage=Gi(Ur.storeName);var Cs=Ur;var Hr=class{_attachedHost;attach(e){return this._attachedHost=e,e.attach(this)}detach(){let e=this._attachedHost;e!=null&&(this._attachedHost=null,e.detach())}get isAttached(){return this._attachedHost!=null}setAttachedHost(e){this._attachedHost=e}},Jn=class extends Hr{component;viewContainerRef;injector;projectableNodes;constructor(e,n,r,i){super(),this.component=e,this.viewContainerRef=n,this.injector=r,this.projectableNodes=i}},Zn=class extends Hr{templateRef;viewContainerRef;context;injector;constructor(e,n,r,i){super(),this.templateRef=e,this.viewContainerRef=n,this.context=r,this.injector=i}get origin(){return this.templateRef.elementRef}attach(e,n=this.context){return this.context=n,super.attach(e)}detach(){return this.context=void 0,super.detach()}},Is=class extends Hr{element;constructor(e){super(),this.element=e instanceof ut?e.nativeElement:e}},Qn=class{_attachedPortal;_disposeFn;_isDisposed=!1;hasAttached(){return!!this._attachedPortal}attach(e){if(e instanceof Jn)return this._attachedPortal=e,this.attachComponentPortal(e);if(e instanceof Zn)return this._attachedPortal=e,this.attachTemplatePortal(e);if(this.attachDomPortal&&e instanceof Is)return this._attachedPortal=e,this.attachDomPortal(e)}attachDomPortal=null;detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(e){this._disposeFn=e}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}},Wi=class extends Qn{outletElement;_appRef;_defaultInjector;constructor(e,n,r){super(),this.outletElement=e,this._appRef=n,this._defaultInjector=r}attachComponentPortal(e){let n;if(e.viewContainerRef){let r=e.injector||e.viewContainerRef.injector,i=r.get(rs,null,{optional:!0})||void 0;n=e.viewContainerRef.createComponent(e.component,{index:e.viewContainerRef.length,injector:r,ngModuleRef:i,projectableNodes:e.projectableNodes||void 0}),this.setDisposeFn(()=>n.destroy())}else{let r=this._appRef,i=e.injector||this._defaultInjector||lt.NULL,o=i.get(yi,r.injector);n=nl(e.component,{elementInjector:i,environmentInjector:o,projectableNodes:e.projectableNodes||void 0}),r.attachView(n.hostView),this.setDisposeFn(()=>{r.viewCount>0&&r.detachView(n.hostView),n.destroy()})}return this.outletElement.appendChild(this._getComponentRootNode(n)),this._attachedPortal=e,n}attachTemplatePortal(e){let n=e.viewContainerRef,r=n.createEmbeddedView(e.templateRef,e.context,{injector:e.injector});return r.rootNodes.forEach(i=>this.outletElement.appendChild(i)),r.detectChanges(),this.setDisposeFn(()=>{let i=n.indexOf(r);i!==-1&&n.remove(i)}),this._attachedPortal=e,r}attachDomPortal=e=>{let n=e.element;n.parentNode;let r=this.outletElement.ownerDocument.createComment("dom-portal");n.parentNode.insertBefore(r,n),this.outletElement.appendChild(n),this._attachedPortal=e,super.setDisposeFn(()=>{r.parentNode&&r.parentNode.replaceChild(n,r)})};dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(e){return e.hostView.rootNodes[0]}};var Ts=(()=>{class t extends Qn{_moduleRef=U(rs,{optional:!0});_document=U(Ze);_viewContainerRef=U(ns);_isInitialized=!1;_attachedRef;constructor(){super()}get portal(){return this._attachedPortal}set portal(n){this.hasAttached()&&!n&&!this._isInitialized||(this.hasAttached()&&super.detach(),n&&super.attach(n),this._attachedPortal=n||null)}attached=new vt;get attachedRef(){return this._attachedRef}ngOnInit(){this._isInitialized=!0}ngOnDestroy(){super.dispose(),this._attachedRef=this._attachedPortal=null}attachComponentPortal(n){n.setAttachedHost(this);let r=n.viewContainerRef!=null?n.viewContainerRef:this._viewContainerRef,i=r.createComponent(n.component,{index:r.length,injector:n.injector||r.injector,projectableNodes:n.projectableNodes||void 0,ngModuleRef:this._moduleRef||void 0});return r!==this._viewContainerRef&&this._getRootNode().appendChild(i.hostView.rootNodes[0]),super.setDisposeFn(()=>i.destroy()),this._attachedPortal=n,this._attachedRef=i,this.attached.emit(i),i}attachTemplatePortal(n){n.setAttachedHost(this);let r=this._viewContainerRef.createEmbeddedView(n.templateRef,n.context,{injector:n.injector});return super.setDisposeFn(()=>this._viewContainerRef.clear()),this._attachedPortal=n,this._attachedRef=r,this.attached.emit(r),r}attachDomPortal=n=>{let r=n.element;r.parentNode;let i=this._document.createComment("dom-portal");n.setAttachedHost(this),r.parentNode.insertBefore(i,r),this._getRootNode().appendChild(r),this._attachedPortal=n,super.setDisposeFn(()=>{i.parentNode&&i.parentNode.replaceChild(r,i)})};_getRootNode(){let n=this._viewContainerRef.element.nativeElement;return n.nodeType===n.ELEMENT_NODE?n:n.parentNode}static \u0275fac=function(r){return new(r||t)};static \u0275dir=jn({type:t,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:[0,"cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[Cn]})}return t})();var jr;function Wh(){if(jr==null&&typeof window<"u")try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>jr=!0}))}finally{jr=jr||!1}return jr}function ru(t){return Wh()?t:!!t.capture}var Yh=new Je("cdk-input-modality-detector-options"),zh={ignoreKeys:[18,17,224,91,16]},iu=650,xs={passive:!0,capture:!0},Xh=(()=>{class t{_platform=U(Pt);_listenerCleanups;modalityDetected;modalityChanged;get mostRecentModality(){return this._modality.value}_mostRecentTarget=null;_modality=new Fc(null);_options;_lastTouchMs=0;_onKeydown=n=>{this._options?.ignoreKeys?.some(r=>r===n.keyCode)||(this._modality.next("keyboard"),this._mostRecentTarget=Jt(n))};_onMousedown=n=>{Date.now()-this._lastTouchMs<iu||(this._modality.next(ll(n)?"keyboard":"mouse"),this._mostRecentTarget=Jt(n))};_onTouchstart=n=>{if(ul(n)){this._modality.next("keyboard");return}this._lastTouchMs=Date.now(),this._modality.next("touch"),this._mostRecentTarget=Jt(n)};constructor(){let n=U(Et),r=U(Ze),i=U(Yh,{optional:!0});if(this._options=I(I({},zh),i),this.modalityDetected=this._modality.pipe(Hc(1)),this.modalityChanged=this.modalityDetected.pipe(Uc()),this._platform.isBrowser){let o=U(Hn).createRenderer(null,null);this._listenerCleanups=n.runOutsideAngular(()=>[o.listen(r,"keydown",this._onKeydown,xs),o.listen(r,"mousedown",this._onMousedown,xs),o.listen(r,"touchstart",this._onTouchstart,xs)])}}ngOnDestroy(){this._modality.complete(),this._listenerCleanups?.forEach(n=>n())}static \u0275fac=function(r){return new(r||t)};static \u0275prov=Be({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),zi=(function(t){return t[t.IMMEDIATE=0]="IMMEDIATE",t[t.EVENTUAL=1]="EVENTUAL",t})(zi||{}),qh=new Je("cdk-focus-monitor-default-options"),Yi=ru({passive:!0,capture:!0}),ou=(()=>{class t{_ngZone=U(Et);_platform=U(Pt);_inputModalityDetector=U(Xh);_origin=null;_lastFocusOrigin;_windowFocused=!1;_windowFocusTimeoutId;_originTimeoutId;_originFromTouchInteraction=!1;_elementInfo=new Map;_monitoredElementCount=0;_rootNodeFocusListenerCount=new Map;_detectionMode;_windowFocusListener=()=>{this._windowFocused=!0,this._windowFocusTimeoutId=setTimeout(()=>this._windowFocused=!1)};_document=U(Ze);_stopInputModalityDetector=new Ke;constructor(){let n=U(qh,{optional:!0});this._detectionMode=n?.detectionMode||zi.IMMEDIATE}_rootNodeFocusAndBlurListener=n=>{let r=Jt(n);for(let i=r;i;i=i.parentElement)n.type==="focus"?this._onFocus(n,i):this._onBlur(n,i)};monitor(n,r=!1){let i=xi(n);if(!this._platform.isBrowser||i.nodeType!==1)return kc();let o=fl(i)||this._document,s=this._elementInfo.get(i);if(s)return r&&(s.checkChildren=!0),s.subject;let l={checkChildren:r,subject:new Ke,rootNode:o};return this._elementInfo.set(i,l),this._registerGlobalListeners(l),l.subject}stopMonitoring(n){let r=xi(n),i=this._elementInfo.get(r);i&&(i.subject.complete(),this._setClasses(r),this._elementInfo.delete(r),this._removeGlobalListeners(i))}focusVia(n,r,i){let o=xi(n),s=this._document.activeElement;o===s?this._getClosestElementsInfo(o).forEach(([l,u])=>this._originChanged(l,r,u)):(this._setOrigin(r),typeof o.focus=="function"&&o.focus(i))}ngOnDestroy(){this._elementInfo.forEach((n,r)=>this.stopMonitoring(r))}_getWindow(){return this._document.defaultView||window}_getFocusOrigin(n){return this._origin?this._originFromTouchInteraction?this._shouldBeAttributedToTouch(n)?"touch":"program":this._origin:this._windowFocused&&this._lastFocusOrigin?this._lastFocusOrigin:n&&this._isLastInteractionFromInputLabel(n)?"mouse":"program"}_shouldBeAttributedToTouch(n){return this._detectionMode===zi.EVENTUAL||!!n?.contains(this._inputModalityDetector._mostRecentTarget)}_setClasses(n,r){n.classList.toggle("cdk-focused",!!r),n.classList.toggle("cdk-touch-focused",r==="touch"),n.classList.toggle("cdk-keyboard-focused",r==="keyboard"),n.classList.toggle("cdk-mouse-focused",r==="mouse"),n.classList.toggle("cdk-program-focused",r==="program")}_setOrigin(n,r=!1){this._ngZone.runOutsideAngular(()=>{if(this._origin=n,this._originFromTouchInteraction=n==="touch"&&r,this._detectionMode===zi.IMMEDIATE){clearTimeout(this._originTimeoutId);let i=this._originFromTouchInteraction?iu:1;this._originTimeoutId=setTimeout(()=>this._origin=null,i)}})}_onFocus(n,r){let i=this._elementInfo.get(r),o=Jt(n);!i||!i.checkChildren&&r!==o||this._originChanged(r,this._getFocusOrigin(o),i)}_onBlur(n,r){let i=this._elementInfo.get(r);!i||i.checkChildren&&n.relatedTarget instanceof Node&&r.contains(n.relatedTarget)||(this._setClasses(r),this._emitOrigin(i,null))}_emitOrigin(n,r){n.subject.observers.length&&this._ngZone.run(()=>n.subject.next(r))}_registerGlobalListeners(n){if(!this._platform.isBrowser)return;let r=n.rootNode,i=this._rootNodeFocusListenerCount.get(r)||0;i||this._ngZone.runOutsideAngular(()=>{r.addEventListener("focus",this._rootNodeFocusAndBlurListener,Yi),r.addEventListener("blur",this._rootNodeFocusAndBlurListener,Yi)}),this._rootNodeFocusListenerCount.set(r,i+1),++this._monitoredElementCount===1&&(this._ngZone.runOutsideAngular(()=>{this._getWindow().addEventListener("focus",this._windowFocusListener)}),this._inputModalityDetector.modalityDetected.pipe($c(this._stopInputModalityDetector)).subscribe(o=>{this._setOrigin(o,!0)}))}_removeGlobalListeners(n){let r=n.rootNode;if(this._rootNodeFocusListenerCount.has(r)){let i=this._rootNodeFocusListenerCount.get(r);i>1?this._rootNodeFocusListenerCount.set(r,i-1):(r.removeEventListener("focus",this._rootNodeFocusAndBlurListener,Yi),r.removeEventListener("blur",this._rootNodeFocusAndBlurListener,Yi),this._rootNodeFocusListenerCount.delete(r))}--this._monitoredElementCount||(this._getWindow().removeEventListener("focus",this._windowFocusListener),this._stopInputModalityDetector.next(),clearTimeout(this._windowFocusTimeoutId),clearTimeout(this._originTimeoutId))}_originChanged(n,r,i){this._setClasses(n,r),this._emitOrigin(i,r),this._lastFocusOrigin=r}_getClosestElementsInfo(n){let r=[];return this._elementInfo.forEach((i,o)=>{(o===n||i.checkChildren&&o.contains(n))&&r.push([o,i])}),r}_isLastInteractionFromInputLabel(n){let{_mostRecentTarget:r,mostRecentModality:i}=this._inputModalityDetector;if(i!=="mouse"||!r||r===n||n.nodeName!=="INPUT"&&n.nodeName!=="TEXTAREA"||n.disabled)return!1;let o=n.labels;if(o){for(let s=0;s<o.length;s++)if(o[s].contains(r))return!0}return!1}static \u0275fac=function(r){return new(r||t)};static \u0275prov=Be({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var su=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275cmp=ve({type:t,selectors:[["ng-component"]],exportAs:["cdkVisuallyHidden"],decls:0,vars:0,template:function(r,i){},styles:[`.cdk-visually-hidden{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap;outline:0;-webkit-appearance:none;-moz-appearance:none;left:0}[dir=rtl] .cdk-visually-hidden{left:auto;right:0}
|
|
5
|
+
`],encapsulation:2,changeDetection:0})}return t})();var As=(()=>{class t{_platform=U(Pt);constructor(){}isDisabled(n){return n.hasAttribute("disabled")}isVisible(n){return Jh(n)&&getComputedStyle(n).visibility==="visible"}isTabbable(n){if(!this._platform.isBrowser)return!1;let r=Kh(om(n));if(r&&(au(r)===-1||!this.isVisible(r)))return!1;let i=n.nodeName.toLowerCase(),o=au(n);return n.hasAttribute("contenteditable")?o!==-1:i==="iframe"||i==="object"||this._platform.WEBKIT&&this._platform.IOS&&!rm(n)?!1:i==="audio"?n.hasAttribute("controls")?o!==-1:!1:i==="video"?o===-1?!1:o!==null?!0:this._platform.FIREFOX||n.hasAttribute("controls"):n.tabIndex>=0}isFocusable(n,r){return im(n)&&!this.isDisabled(n)&&(r?.ignoreVisibility||this.isVisible(n))}static \u0275fac=function(r){return new(r||t)};static \u0275prov=Be({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function Kh(t){try{return t.frameElement}catch{return null}}function Jh(t){return!!(t.offsetWidth||t.offsetHeight||typeof t.getClientRects=="function"&&t.getClientRects().length)}function Zh(t){let e=t.nodeName.toLowerCase();return e==="input"||e==="select"||e==="button"||e==="textarea"}function Qh(t){return tm(t)&&t.type=="hidden"}function em(t){return nm(t)&&t.hasAttribute("href")}function tm(t){return t.nodeName.toLowerCase()=="input"}function nm(t){return t.nodeName.toLowerCase()=="a"}function cu(t){if(!t.hasAttribute("tabindex")||t.tabIndex===void 0)return!1;let e=t.getAttribute("tabindex");return!!(e&&!isNaN(parseInt(e,10)))}function au(t){if(!cu(t))return null;let e=parseInt(t.getAttribute("tabindex")||"",10);return isNaN(e)?-1:e}function rm(t){let e=t.nodeName.toLowerCase(),n=e==="input"&&t.type;return n==="text"||n==="password"||e==="select"||e==="textarea"}function im(t){return Qh(t)?!1:Zh(t)||em(t)||t.hasAttribute("contenteditable")||cu(t)}function om(t){return t.ownerDocument&&t.ownerDocument.defaultView||window}var Os=class{_element;_checker;_ngZone;_document;_injector;_startAnchor;_endAnchor;_hasAttached=!1;startAnchorListener=()=>this.focusLastTabbableElement();endAnchorListener=()=>this.focusFirstTabbableElement();get enabled(){return this._enabled}set enabled(e){this._enabled=e,this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(e,this._startAnchor),this._toggleAnchorTabIndex(e,this._endAnchor))}_enabled=!0;constructor(e,n,r,i,o=!1,s){this._element=e,this._checker=n,this._ngZone=r,this._document=i,this._injector=s,o||this.attachAnchors()}destroy(){let e=this._startAnchor,n=this._endAnchor;e&&(e.removeEventListener("focus",this.startAnchorListener),e.remove()),n&&(n.removeEventListener("focus",this.endAnchorListener),n.remove()),this._startAnchor=this._endAnchor=null,this._hasAttached=!1}attachAnchors(){return this._hasAttached?!0:(this._ngZone.runOutsideAngular(()=>{this._startAnchor||(this._startAnchor=this._createAnchor(),this._startAnchor.addEventListener("focus",this.startAnchorListener)),this._endAnchor||(this._endAnchor=this._createAnchor(),this._endAnchor.addEventListener("focus",this.endAnchorListener))}),this._element.parentNode&&(this._element.parentNode.insertBefore(this._startAnchor,this._element),this._element.parentNode.insertBefore(this._endAnchor,this._element.nextSibling),this._hasAttached=!0),this._hasAttached)}focusInitialElementWhenReady(e){return new Promise(n=>{this._executeOnStable(()=>n(this.focusInitialElement(e)))})}focusFirstTabbableElementWhenReady(e){return new Promise(n=>{this._executeOnStable(()=>n(this.focusFirstTabbableElement(e)))})}focusLastTabbableElementWhenReady(e){return new Promise(n=>{this._executeOnStable(()=>n(this.focusLastTabbableElement(e)))})}_getRegionBoundary(e){let n=this._element.querySelectorAll(`[cdk-focus-region-${e}], [cdkFocusRegion${e}], [cdk-focus-${e}]`);return e=="start"?n.length?n[0]:this._getFirstTabbableElement(this._element):n.length?n[n.length-1]:this._getLastTabbableElement(this._element)}focusInitialElement(e){let n=this._element.querySelector("[cdk-focus-initial], [cdkFocusInitial]");if(n){if(!this._checker.isFocusable(n)){let r=this._getFirstTabbableElement(n);return r?.focus(e),!!r}return n.focus(e),!0}return this.focusFirstTabbableElement(e)}focusFirstTabbableElement(e){let n=this._getRegionBoundary("start");return n&&n.focus(e),!!n}focusLastTabbableElement(e){let n=this._getRegionBoundary("end");return n&&n.focus(e),!!n}hasAttached(){return this._hasAttached}_getFirstTabbableElement(e){if(this._checker.isFocusable(e)&&this._checker.isTabbable(e))return e;let n=e.children;for(let r=0;r<n.length;r++){let i=n[r].nodeType===this._document.ELEMENT_NODE?this._getFirstTabbableElement(n[r]):null;if(i)return i}return null}_getLastTabbableElement(e){if(this._checker.isFocusable(e)&&this._checker.isTabbable(e))return e;let n=e.children;for(let r=n.length-1;r>=0;r--){let i=n[r].nodeType===this._document.ELEMENT_NODE?this._getLastTabbableElement(n[r]):null;if(i)return i}return null}_createAnchor(){let e=this._document.createElement("div");return this._toggleAnchorTabIndex(this._enabled,e),e.classList.add("cdk-visually-hidden"),e.classList.add("cdk-focus-trap-anchor"),e.setAttribute("aria-hidden","true"),e}_toggleAnchorTabIndex(e,n){e?n.setAttribute("tabindex","0"):n.removeAttribute("tabindex")}toggleAnchors(e){this._startAnchor&&this._endAnchor&&(this._toggleAnchorTabIndex(e,this._startAnchor),this._toggleAnchorTabIndex(e,this._endAnchor))}_executeOnStable(e){this._injector?ln(e,{injector:this._injector}):setTimeout(e)}},lu=(()=>{class t{_checker=U(As);_ngZone=U(Et);_document=U(Ze);_injector=U(lt);constructor(){U(Rr).load(su)}create(n,r=!1){return new Os(n,this._checker,this._ngZone,this._document,r,this._injector)}static \u0275fac=function(r){return new(r||t)};static \u0275prov=Be({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function uu(t,...e){return e.length?e.some(n=>t[n]):t.altKey||t.shiftKey||t.ctrlKey||t.metaKey}function Ds(){return typeof __karma__<"u"&&!!__karma__||typeof jasmine<"u"&&!!jasmine||typeof jest<"u"&&!!jest||typeof Mocha<"u"&&!!Mocha}function Qt(t){return t==null?"":typeof t=="string"?t:`${t}px`}var fu=pl();function hu(t){return new Ns(t.get(hl),t.get(Ze))}var Ns=class{_viewportRuler;_previousHTMLStyles={top:"",left:""};_previousScrollPosition;_isEnabled=!1;_document;constructor(e,n){this._viewportRuler=e,this._document=n}attach(){}enable(){if(this._canBeEnabled()){let e=this._document.documentElement;this._previousScrollPosition=this._viewportRuler.getViewportScrollPosition(),this._previousHTMLStyles.left=e.style.left||"",this._previousHTMLStyles.top=e.style.top||"",e.style.left=Qt(-this._previousScrollPosition.left),e.style.top=Qt(-this._previousScrollPosition.top),e.classList.add("cdk-global-scrollblock"),this._isEnabled=!0}}disable(){if(this._isEnabled){let e=this._document.documentElement,n=this._document.body,r=e.style,i=n.style,o=r.scrollBehavior||"",s=i.scrollBehavior||"";this._isEnabled=!1,r.left=this._previousHTMLStyles.left,r.top=this._previousHTMLStyles.top,e.classList.remove("cdk-global-scrollblock"),fu&&(r.scrollBehavior=i.scrollBehavior="auto"),window.scroll(this._previousScrollPosition.left,this._previousScrollPosition.top),fu&&(r.scrollBehavior=o,i.scrollBehavior=s)}}_canBeEnabled(){if(this._document.documentElement.classList.contains("cdk-global-scrollblock")||this._isEnabled)return!1;let n=this._document.documentElement,r=this._viewportRuler.getViewportSize();return n.scrollHeight>r.height||n.scrollWidth>r.width}};var Rs=class{enable(){}disable(){}attach(){}};var $r=class{positionStrategy;scrollStrategy=new Rs;panelClass="";hasBackdrop=!1;backdropClass="cdk-overlay-dark-backdrop";disableAnimations;width;height;minWidth;minHeight;maxWidth;maxHeight;direction;disposeOnNavigation=!1;constructor(e){if(e){let n=Object.keys(e);for(let r of n)e[r]!==void 0&&(this[r]=e[r])}}};var mu=(()=>{class t{_attachedOverlays=[];_document=U(Ze);_isAttached;constructor(){}ngOnDestroy(){this.detach()}add(n){this.remove(n),this._attachedOverlays.push(n)}remove(n){let r=this._attachedOverlays.indexOf(n);r>-1&&this._attachedOverlays.splice(r,1),this._attachedOverlays.length===0&&this.detach()}static \u0275fac=function(r){return new(r||t)};static \u0275prov=Be({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),am=(()=>{class t extends mu{_ngZone=U(Et);_renderer=U(Hn).createRenderer(null,null);_cleanupKeydown;add(n){super.add(n),this._isAttached||(this._ngZone.runOutsideAngular(()=>{this._cleanupKeydown=this._renderer.listen("body","keydown",this._keydownListener)}),this._isAttached=!0)}detach(){this._isAttached&&(this._cleanupKeydown?.(),this._isAttached=!1)}_keydownListener=n=>{let r=this._attachedOverlays;for(let i=r.length-1;i>-1;i--)if(r[i]._keydownEvents.observers.length>0){this._ngZone.run(()=>r[i]._keydownEvents.next(n));break}};static \u0275fac=(()=>{let n;return function(i){return(n||(n=Tr(t)))(i||t)}})();static \u0275prov=Be({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),cm=(()=>{class t extends mu{_platform=U(Pt);_ngZone=U(Et);_renderer=U(Hn).createRenderer(null,null);_cursorOriginalValue;_cursorStyleIsSet=!1;_pointerDownEventTarget;_cleanups;add(n){if(super.add(n),!this._isAttached){let r=this._document.body,i={capture:!0},o=this._renderer;this._cleanups=this._ngZone.runOutsideAngular(()=>[o.listen(r,"pointerdown",this._pointerDownListener,i),o.listen(r,"click",this._clickListener,i),o.listen(r,"auxclick",this._clickListener,i),o.listen(r,"contextmenu",this._clickListener,i)]),this._platform.IOS&&!this._cursorStyleIsSet&&(this._cursorOriginalValue=r.style.cursor,r.style.cursor="pointer",this._cursorStyleIsSet=!0),this._isAttached=!0}}detach(){this._isAttached&&(this._cleanups?.forEach(n=>n()),this._cleanups=void 0,this._platform.IOS&&this._cursorStyleIsSet&&(this._document.body.style.cursor=this._cursorOriginalValue,this._cursorStyleIsSet=!1),this._isAttached=!1)}_pointerDownListener=n=>{this._pointerDownEventTarget=Jt(n)};_clickListener=n=>{let r=Jt(n),i=n.type==="click"&&this._pointerDownEventTarget?this._pointerDownEventTarget:r;this._pointerDownEventTarget=null;let o=this._attachedOverlays.slice();for(let s=o.length-1;s>-1;s--){let l=o[s];if(l._outsidePointerEvents.observers.length<1||!l.hasAttached())continue;if(du(l.overlayElement,r)||du(l.overlayElement,i))break;let u=l._outsidePointerEvents;this._ngZone?this._ngZone.run(()=>u.next(n)):u.next(n)}};static \u0275fac=(()=>{let n;return function(i){return(n||(n=Tr(t)))(i||t)}})();static \u0275prov=Be({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function du(t,e){let n=typeof ShadowRoot<"u"&&ShadowRoot,r=e;for(;r;){if(r===t)return!0;r=n&&r instanceof ShadowRoot?r.host:r.parentNode}return!1}var gu=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275cmp=ve({type:t,selectors:[["ng-component"]],hostAttrs:["cdk-overlay-style-loader",""],decls:0,vars:0,template:function(r,i){},styles:[`.cdk-overlay-container,.cdk-global-overlay-wrapper{pointer-events:none;top:0;left:0;height:100%;width:100%}.cdk-overlay-container{position:fixed}@layer cdk-overlay{.cdk-overlay-container{z-index:1000}}.cdk-overlay-container:empty{display:none}.cdk-global-overlay-wrapper{display:flex;position:absolute}@layer cdk-overlay{.cdk-global-overlay-wrapper{z-index:1000}}.cdk-overlay-pane{position:absolute;pointer-events:auto;box-sizing:border-box;display:flex;max-width:100%;max-height:100%}@layer cdk-overlay{.cdk-overlay-pane{z-index:1000}}.cdk-overlay-backdrop{position:absolute;top:0;bottom:0;left:0;right:0;pointer-events:auto;-webkit-tap-highlight-color:rgba(0,0,0,0);opacity:0;touch-action:manipulation}@layer cdk-overlay{.cdk-overlay-backdrop{z-index:1000;transition:opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}}@media(prefers-reduced-motion){.cdk-overlay-backdrop{transition-duration:1ms}}.cdk-overlay-backdrop-showing{opacity:1}@media(forced-colors: active){.cdk-overlay-backdrop-showing{opacity:.6}}@layer cdk-overlay{.cdk-overlay-dark-backdrop{background:rgba(0,0,0,.32)}}.cdk-overlay-transparent-backdrop{transition:visibility 1ms linear,opacity 1ms linear;visibility:hidden;opacity:1}.cdk-overlay-transparent-backdrop.cdk-overlay-backdrop-showing,.cdk-high-contrast-active .cdk-overlay-transparent-backdrop{opacity:0;visibility:visible}.cdk-overlay-backdrop-noop-animation{transition:none}.cdk-overlay-connected-position-bounding-box{position:absolute;display:flex;flex-direction:column;min-width:1px;min-height:1px}@layer cdk-overlay{.cdk-overlay-connected-position-bounding-box{z-index:1000}}.cdk-global-scrollblock{position:fixed;width:100%;overflow-y:scroll}
|
|
6
|
+
`],encapsulation:2,changeDetection:0})}return t})(),Ls=(()=>{class t{_platform=U(Pt);_containerElement;_document=U(Ze);_styleLoader=U(Rr);constructor(){}ngOnDestroy(){this._containerElement?.remove()}getContainerElement(){return this._loadStyles(),this._containerElement||this._createContainer(),this._containerElement}_createContainer(){let n="cdk-overlay-container";if(this._platform.isBrowser||Ds()){let i=this._document.querySelectorAll(`.${n}[platform="server"], .${n}[platform="test"]`);for(let o=0;o<i.length;o++)i[o].remove()}let r=this._document.createElement("div");r.classList.add(n),Ds()?r.setAttribute("platform","test"):this._platform.isBrowser||r.setAttribute("platform","server"),this._document.body.appendChild(r),this._containerElement=r}_loadStyles(){this._styleLoader.load(gu)}static \u0275fac=function(r){return new(r||t)};static \u0275prov=Be({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Ms=class{_renderer;_ngZone;element;_cleanupClick;_cleanupTransitionEnd;_fallbackTimeout;constructor(e,n,r,i){this._renderer=n,this._ngZone=r,this.element=e.createElement("div"),this.element.classList.add("cdk-overlay-backdrop"),this._cleanupClick=n.listen(this.element,"click",i)}detach(){this._ngZone.runOutsideAngular(()=>{let e=this.element;clearTimeout(this._fallbackTimeout),this._cleanupTransitionEnd?.(),this._cleanupTransitionEnd=this._renderer.listen(e,"transitionend",this.dispose),this._fallbackTimeout=setTimeout(this.dispose,500),e.style.pointerEvents="none",e.classList.remove("cdk-overlay-backdrop-showing")})}dispose=()=>{clearTimeout(this._fallbackTimeout),this._cleanupClick?.(),this._cleanupTransitionEnd?.(),this._cleanupClick=this._cleanupTransitionEnd=this._fallbackTimeout=void 0,this.element.remove()}},Gr=class{_portalOutlet;_host;_pane;_config;_ngZone;_keyboardDispatcher;_document;_location;_outsideClickDispatcher;_animationsDisabled;_injector;_renderer;_backdropClick=new Ke;_attachments=new Ke;_detachments=new Ke;_positionStrategy;_scrollStrategy;_locationChanges=Lc.EMPTY;_backdropRef=null;_detachContentMutationObserver;_detachContentAfterRenderRef;_previousHostParent;_keydownEvents=new Ke;_outsidePointerEvents=new Ke;_afterNextRenderRef;constructor(e,n,r,i,o,s,l,u,d,_=!1,p,v){this._portalOutlet=e,this._host=n,this._pane=r,this._config=i,this._ngZone=o,this._keyboardDispatcher=s,this._document=l,this._location=u,this._outsideClickDispatcher=d,this._animationsDisabled=_,this._injector=p,this._renderer=v,i.scrollStrategy&&(this._scrollStrategy=i.scrollStrategy,this._scrollStrategy.attach(this)),this._positionStrategy=i.positionStrategy}get overlayElement(){return this._pane}get backdropElement(){return this._backdropRef?.element||null}get hostElement(){return this._host}attach(e){!this._host.parentElement&&this._previousHostParent&&this._previousHostParent.appendChild(this._host);let n=this._portalOutlet.attach(e);return this._positionStrategy&&this._positionStrategy.attach(this),this._updateStackingOrder(),this._updateElementSize(),this._updateElementDirection(),this._scrollStrategy&&this._scrollStrategy.enable(),this._afterNextRenderRef?.destroy(),this._afterNextRenderRef=ln(()=>{this.hasAttached()&&this.updatePosition()},{injector:this._injector}),this._togglePointerEvents(!0),this._config.hasBackdrop&&this._attachBackdrop(),this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!0),this._attachments.next(),this._completeDetachContent(),this._keyboardDispatcher.add(this),this._config.disposeOnNavigation&&(this._locationChanges=this._location.subscribe(()=>this.dispose())),this._outsideClickDispatcher.add(this),typeof n?.onDestroy=="function"&&n.onDestroy(()=>{this.hasAttached()&&this._ngZone.runOutsideAngular(()=>Promise.resolve().then(()=>this.detach()))}),n}detach(){if(!this.hasAttached())return;this.detachBackdrop(),this._togglePointerEvents(!1),this._positionStrategy&&this._positionStrategy.detach&&this._positionStrategy.detach(),this._scrollStrategy&&this._scrollStrategy.disable();let e=this._portalOutlet.detach();return this._detachments.next(),this._completeDetachContent(),this._keyboardDispatcher.remove(this),this._detachContentWhenEmpty(),this._locationChanges.unsubscribe(),this._outsideClickDispatcher.remove(this),e}dispose(){let e=this.hasAttached();this._positionStrategy&&this._positionStrategy.dispose(),this._disposeScrollStrategy(),this._backdropRef?.dispose(),this._locationChanges.unsubscribe(),this._keyboardDispatcher.remove(this),this._portalOutlet.dispose(),this._attachments.complete(),this._backdropClick.complete(),this._keydownEvents.complete(),this._outsidePointerEvents.complete(),this._outsideClickDispatcher.remove(this),this._host?.remove(),this._afterNextRenderRef?.destroy(),this._previousHostParent=this._pane=this._host=this._backdropRef=null,e&&this._detachments.next(),this._detachments.complete(),this._completeDetachContent()}hasAttached(){return this._portalOutlet.hasAttached()}backdropClick(){return this._backdropClick}attachments(){return this._attachments}detachments(){return this._detachments}keydownEvents(){return this._keydownEvents}outsidePointerEvents(){return this._outsidePointerEvents}getConfig(){return this._config}updatePosition(){this._positionStrategy&&this._positionStrategy.apply()}updatePositionStrategy(e){e!==this._positionStrategy&&(this._positionStrategy&&this._positionStrategy.dispose(),this._positionStrategy=e,this.hasAttached()&&(e.attach(this),this.updatePosition()))}updateSize(e){this._config=I(I({},this._config),e),this._updateElementSize()}setDirection(e){this._config=K(I({},this._config),{direction:e}),this._updateElementDirection()}addPanelClass(e){this._pane&&this._toggleClasses(this._pane,e,!0)}removePanelClass(e){this._pane&&this._toggleClasses(this._pane,e,!1)}getDirection(){let e=this._config.direction;return e?typeof e=="string"?e:e.value:"ltr"}updateScrollStrategy(e){e!==this._scrollStrategy&&(this._disposeScrollStrategy(),this._scrollStrategy=e,this.hasAttached()&&(e.attach(this),e.enable()))}_updateElementDirection(){this._host.setAttribute("dir",this.getDirection())}_updateElementSize(){if(!this._pane)return;let e=this._pane.style;e.width=Qt(this._config.width),e.height=Qt(this._config.height),e.minWidth=Qt(this._config.minWidth),e.minHeight=Qt(this._config.minHeight),e.maxWidth=Qt(this._config.maxWidth),e.maxHeight=Qt(this._config.maxHeight)}_togglePointerEvents(e){this._pane.style.pointerEvents=e?"":"none"}_attachBackdrop(){let e="cdk-overlay-backdrop-showing";this._backdropRef?.dispose(),this._backdropRef=new Ms(this._document,this._renderer,this._ngZone,n=>{this._backdropClick.next(n)}),this._animationsDisabled&&this._backdropRef.element.classList.add("cdk-overlay-backdrop-noop-animation"),this._config.backdropClass&&this._toggleClasses(this._backdropRef.element,this._config.backdropClass,!0),this._host.parentElement.insertBefore(this._backdropRef.element,this._host),!this._animationsDisabled&&typeof requestAnimationFrame<"u"?this._ngZone.runOutsideAngular(()=>{requestAnimationFrame(()=>this._backdropRef?.element.classList.add(e))}):this._backdropRef.element.classList.add(e)}_updateStackingOrder(){this._host.nextSibling&&this._host.parentNode.appendChild(this._host)}detachBackdrop(){this._animationsDisabled?(this._backdropRef?.dispose(),this._backdropRef=null):this._backdropRef?.detach()}_toggleClasses(e,n,r){let i=dl(n||[]).filter(o=>!!o);i.length&&(r?e.classList.add(...i):e.classList.remove(...i))}_detachContentWhenEmpty(){let e=!1;try{this._detachContentAfterRenderRef=ln(()=>{e=!0,this._detachContent()},{injector:this._injector})}catch(n){if(e)throw n;this._detachContent()}globalThis.MutationObserver&&this._pane&&(this._detachContentMutationObserver||=new globalThis.MutationObserver(()=>{this._detachContent()}),this._detachContentMutationObserver.observe(this._pane,{childList:!0}))}_detachContent(){(!this._pane||!this._host||this._pane.children.length===0)&&(this._pane&&this._config.panelClass&&this._toggleClasses(this._pane,this._config.panelClass,!1),this._host&&this._host.parentElement&&(this._previousHostParent=this._host.parentElement,this._host.remove()),this._completeDetachContent())}_completeDetachContent(){this._detachContentAfterRenderRef?.destroy(),this._detachContentAfterRenderRef=void 0,this._detachContentMutationObserver?.disconnect()}_disposeScrollStrategy(){let e=this._scrollStrategy;e?.disable(),e?.detach?.()}};var pu="cdk-global-overlay-wrapper";function _u(t){return new Ps}var Ps=class{_overlayRef;_cssPosition="static";_topOffset="";_bottomOffset="";_alignItems="";_xPosition="";_xOffset="";_width="";_height="";_isDisposed=!1;attach(e){let n=e.getConfig();this._overlayRef=e,this._width&&!n.width&&e.updateSize({width:this._width}),this._height&&!n.height&&e.updateSize({height:this._height}),e.hostElement.classList.add(pu),this._isDisposed=!1}top(e=""){return this._bottomOffset="",this._topOffset=e,this._alignItems="flex-start",this}left(e=""){return this._xOffset=e,this._xPosition="left",this}bottom(e=""){return this._topOffset="",this._bottomOffset=e,this._alignItems="flex-end",this}right(e=""){return this._xOffset=e,this._xPosition="right",this}start(e=""){return this._xOffset=e,this._xPosition="start",this}end(e=""){return this._xOffset=e,this._xPosition="end",this}width(e=""){return this._overlayRef?this._overlayRef.updateSize({width:e}):this._width=e,this}height(e=""){return this._overlayRef?this._overlayRef.updateSize({height:e}):this._height=e,this}centerHorizontally(e=""){return this.left(e),this._xPosition="center",this}centerVertically(e=""){return this.top(e),this._alignItems="center",this}apply(){if(!this._overlayRef||!this._overlayRef.hasAttached())return;let e=this._overlayRef.overlayElement.style,n=this._overlayRef.hostElement.style,r=this._overlayRef.getConfig(),{width:i,height:o,maxWidth:s,maxHeight:l}=r,u=(i==="100%"||i==="100vw")&&(!s||s==="100%"||s==="100vw"),d=(o==="100%"||o==="100vh")&&(!l||l==="100%"||l==="100vh"),_=this._xPosition,p=this._xOffset,v=this._overlayRef.getConfig().direction==="rtl",E="",T="",N="";u?N="flex-start":_==="center"?(N="center",v?T=p:E=p):v?_==="left"||_==="end"?(N="flex-end",E=p):(_==="right"||_==="start")&&(N="flex-start",T=p):_==="left"||_==="start"?(N="flex-start",E=p):(_==="right"||_==="end")&&(N="flex-end",T=p),e.position=this._cssPosition,e.marginLeft=u?"0":E,e.marginTop=d?"0":this._topOffset,e.marginBottom=this._bottomOffset,e.marginRight=u?"0":T,n.justifyContent=N,n.alignItems=d?"flex-start":this._alignItems}dispose(){if(this._isDisposed||!this._overlayRef)return;let e=this._overlayRef.overlayElement.style,n=this._overlayRef.hostElement,r=n.style;n.classList.remove(pu),r.justifyContent=r.alignItems=e.marginTop=e.marginBottom=e.marginLeft=e.marginRight=e.position="",this._overlayRef=null,this._isDisposed=!0}};function yu(t,e){t.get(Rr).load(gu);let n=t.get(Ls),r=t.get(Ze),i=t.get(Oi),o=t.get(is),s=t.get(Mr),l=r.createElement("div"),u=r.createElement("div");u.id=i.getId("cdk-overlay-"),u.classList.add("cdk-overlay-pane"),l.appendChild(u),n.getContainerElement().appendChild(l);let d=new Wi(u,o,t),_=new $r(e),p=t.get(xr,null,{optional:!0})||t.get(Hn).createRenderer(null,null);return _.direction=_.direction||s.value,new Gr(d,l,u,_,t.get(Et),t.get(am),r,t.get(rl),t.get(cm),e?.disableAnimations??t.get(Gc,null,{optional:!0})==="NoopAnimations",t.get(yi),p)}function lm(t,e){}var er=class{viewContainerRef;injector;id;role="dialog";panelClass="";hasBackdrop=!0;backdropClass="";disableClose=!1;closePredicate;width="";height="";minWidth;minHeight;maxWidth;maxHeight;positionStrategy;data=null;direction;ariaDescribedBy=null;ariaLabelledBy=null;ariaLabel=null;ariaModal=!1;autoFocus="first-tabbable";restoreFocus=!0;scrollStrategy;closeOnNavigation=!0;closeOnDestroy=!0;closeOnOverlayDetachments=!0;disableAnimations=!1;providers;container;templateContext};var um=(()=>{class t extends Qn{_elementRef=U(ut);_focusTrapFactory=U(lu);_config;_interactivityChecker=U(As);_ngZone=U(Et);_focusMonitor=U(ou);_renderer=U(xr);_changeDetectorRef=U(os);_injector=U(lt);_platform=U(Pt);_document=U(Ze);_portalOutlet;_focusTrapped=new Ke;_focusTrap=null;_elementFocusedBeforeDialogWasOpened=null;_closeInteractionType=null;_ariaLabelledByQueue=[];_isDestroyed=!1;constructor(){super(),this._config=U(er,{optional:!0})||new er,this._config.ariaLabelledBy&&this._ariaLabelledByQueue.push(this._config.ariaLabelledBy)}_addAriaLabelledBy(n){this._ariaLabelledByQueue.push(n),this._changeDetectorRef.markForCheck()}_removeAriaLabelledBy(n){let r=this._ariaLabelledByQueue.indexOf(n);r>-1&&(this._ariaLabelledByQueue.splice(r,1),this._changeDetectorRef.markForCheck())}_contentAttached(){this._initializeFocusTrap(),this._captureInitialFocus()}_captureInitialFocus(){this._trapFocus()}ngOnDestroy(){this._focusTrapped.complete(),this._isDestroyed=!0,this._restoreFocus()}attachComponentPortal(n){this._portalOutlet.hasAttached();let r=this._portalOutlet.attachComponentPortal(n);return this._contentAttached(),r}attachTemplatePortal(n){this._portalOutlet.hasAttached();let r=this._portalOutlet.attachTemplatePortal(n);return this._contentAttached(),r}attachDomPortal=n=>{this._portalOutlet.hasAttached();let r=this._portalOutlet.attachDomPortal(n);return this._contentAttached(),r};_recaptureFocus(){this._containsFocus()||this._trapFocus()}_forceFocus(n,r){this._interactivityChecker.isFocusable(n)||(n.tabIndex=-1,this._ngZone.runOutsideAngular(()=>{let i=()=>{o(),s(),n.removeAttribute("tabindex")},o=this._renderer.listen(n,"blur",i),s=this._renderer.listen(n,"mousedown",i)})),n.focus(r)}_focusByCssSelector(n,r){let i=this._elementRef.nativeElement.querySelector(n);i&&this._forceFocus(i,r)}_trapFocus(n){this._isDestroyed||ln(()=>{let r=this._elementRef.nativeElement;switch(this._config.autoFocus){case!1:case"dialog":this._containsFocus()||r.focus(n);break;case!0:case"first-tabbable":this._focusTrap?.focusInitialElement(n)||this._focusDialogContainer(n);break;case"first-heading":this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role="heading"]',n);break;default:this._focusByCssSelector(this._config.autoFocus,n);break}this._focusTrapped.next()},{injector:this._injector})}_restoreFocus(){let n=this._config.restoreFocus,r=null;if(typeof n=="string"?r=this._document.querySelector(n):typeof n=="boolean"?r=n?this._elementFocusedBeforeDialogWasOpened:null:n&&(r=n),this._config.restoreFocus&&r&&typeof r.focus=="function"){let i=Ti(),o=this._elementRef.nativeElement;(!i||i===this._document.body||i===o||o.contains(i))&&(this._focusMonitor?(this._focusMonitor.focusVia(r,this._closeInteractionType),this._closeInteractionType=null):r.focus())}this._focusTrap&&this._focusTrap.destroy()}_focusDialogContainer(n){this._elementRef.nativeElement.focus?.(n)}_containsFocus(){let n=this._elementRef.nativeElement,r=Ti();return n===r||n.contains(r)}_initializeFocusTrap(){this._platform.isBrowser&&(this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._document&&(this._elementFocusedBeforeDialogWasOpened=Ti()))}static \u0275fac=function(r){return new(r||t)};static \u0275cmp=ve({type:t,selectors:[["cdk-dialog-container"]],viewQuery:function(r,i){if(r&1&&Jc(Ts,7),r&2){let o;Zc(o=Qc())&&(i._portalOutlet=o.first)}},hostAttrs:["tabindex","-1",1,"cdk-dialog-container"],hostVars:6,hostBindings:function(r,i){r&2&&At("id",i._config.id||null)("role",i._config.role)("aria-modal",i._config.ariaModal)("aria-labelledby",i._config.ariaLabel?null:i._ariaLabelledByQueue[0])("aria-label",i._config.ariaLabel)("aria-describedby",i._config.ariaDescribedBy||null)},features:[Cn],decls:1,vars:0,consts:[["cdkPortalOutlet",""]],template:function(r,i){r&1&&Ot(0,lm,0,0,"ng-template",0)},dependencies:[Ts],styles:[`.cdk-dialog-container{display:block;width:100%;height:100%;min-height:inherit;max-height:inherit}
|
|
7
|
+
`],encapsulation:2})}return t})(),Wr=class{overlayRef;config;componentInstance;componentRef;containerInstance;disableClose;closed=new Ke;backdropClick;keydownEvents;outsidePointerEvents;id;_detachSubscription;constructor(e,n){this.overlayRef=e,this.config=n,this.disableClose=n.disableClose,this.backdropClick=e.backdropClick(),this.keydownEvents=e.keydownEvents(),this.outsidePointerEvents=e.outsidePointerEvents(),this.id=n.id,this.keydownEvents.subscribe(r=>{r.keyCode===27&&!this.disableClose&&!uu(r)&&(r.preventDefault(),this.close(void 0,{focusOrigin:"keyboard"}))}),this.backdropClick.subscribe(()=>{!this.disableClose&&this._canClose()?this.close(void 0,{focusOrigin:"mouse"}):this.containerInstance._recaptureFocus?.()}),this._detachSubscription=e.detachments().subscribe(()=>{n.closeOnOverlayDetachments!==!1&&this.close()})}close(e,n){if(this._canClose(e)){let r=this.closed;this.containerInstance._closeInteractionType=n?.focusOrigin||"program",this._detachSubscription.unsubscribe(),this.overlayRef.dispose(),r.next(e),r.complete(),this.componentInstance=this.containerInstance=null}}updatePosition(){return this.overlayRef.updatePosition(),this}updateSize(e="",n=""){return this.overlayRef.updateSize({width:e,height:n}),this}addPanelClass(e){return this.overlayRef.addPanelClass(e),this}removePanelClass(e){return this.overlayRef.removePanelClass(e),this}_canClose(e){let n=this.config;return!!this.containerInstance&&(!n.closePredicate||n.closePredicate(e,n,this.componentInstance))}},fm=new Je("DialogScrollStrategy",{providedIn:"root",factory:()=>{let t=U(lt);return()=>hu(t)}}),dm=new Je("DialogData"),pm=new Je("DefaultDialogConfig");function hm(t){let e=xt(t),n=new vt;return{valueSignal:e,get value(){return e()},change:n,ngOnDestroy(){n.complete()}}}var tw=(()=>{class t{_injector=U(lt);_defaultOptions=U(pm,{optional:!0});_parentDialog=U(t,{optional:!0,skipSelf:!0});_overlayContainer=U(Ls);_idGenerator=U(Oi);_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new Ke;_afterOpenedAtThisLevel=new Ke;_ariaHiddenElements=new Map;_scrollStrategy=U(fm);get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}afterAllClosed=Bc(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(jc(void 0)));constructor(){}open(n,r){let i=this._defaultOptions||new er;r=I(I({},i),r),r.id=r.id||this._idGenerator.getId("cdk-dialog-"),r.id&&this.getDialogById(r.id);let o=this._getOverlayConfig(r),s=yu(this._injector,o),l=new Wr(s,r),u=this._attachContainer(s,l,r);if(l.containerInstance=u,!this.openDialogs.length){let d=this._overlayContainer.getContainerElement();u._focusTrapped?u._focusTrapped.pipe(Vc(1)).subscribe(()=>{this._hideNonDialogContentFromAssistiveTechnology(d)}):this._hideNonDialogContentFromAssistiveTechnology(d)}return this._attachDialogContent(n,l,u,r),this.openDialogs.push(l),l.closed.subscribe(()=>this._removeOpenDialog(l,!0)),this.afterOpened.next(l),l}closeAll(){Fs(this.openDialogs,n=>n.close())}getDialogById(n){return this.openDialogs.find(r=>r.id===n)}ngOnDestroy(){Fs(this._openDialogsAtThisLevel,n=>{n.config.closeOnDestroy===!1&&this._removeOpenDialog(n,!1)}),Fs(this._openDialogsAtThisLevel,n=>n.close()),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete(),this._openDialogsAtThisLevel=[]}_getOverlayConfig(n){let r=new $r({positionStrategy:n.positionStrategy||_u().centerHorizontally().centerVertically(),scrollStrategy:n.scrollStrategy||this._scrollStrategy(),panelClass:n.panelClass,hasBackdrop:n.hasBackdrop,direction:n.direction,minWidth:n.minWidth,minHeight:n.minHeight,maxWidth:n.maxWidth,maxHeight:n.maxHeight,width:n.width,height:n.height,disposeOnNavigation:n.closeOnNavigation,disableAnimations:n.disableAnimations});return n.backdropClass&&(r.backdropClass=n.backdropClass),r}_attachContainer(n,r,i){let o=i.injector||i.viewContainerRef?.injector,s=[{provide:er,useValue:i},{provide:Wr,useValue:r},{provide:Gr,useValue:n}],l;i.container?typeof i.container=="function"?l=i.container:(l=i.container.type,s.push(...i.container.providers(i))):l=um;let u=new Jn(l,i.viewContainerRef,lt.create({parent:o||this._injector,providers:s}));return n.attach(u).instance}_attachDialogContent(n,r,i,o){if(n instanceof vi){let s=this._createInjector(o,r,i,void 0),l={$implicit:o.data,dialogRef:r};o.templateContext&&(l=I(I({},l),typeof o.templateContext=="function"?o.templateContext():o.templateContext)),i.attachTemplatePortal(new Zn(n,null,l,s))}else{let s=this._createInjector(o,r,i,this._injector),l=i.attachComponentPortal(new Jn(n,o.viewContainerRef,s));r.componentRef=l,r.componentInstance=l.instance}}_createInjector(n,r,i,o){let s=n.injector||n.viewContainerRef?.injector,l=[{provide:dm,useValue:n.data},{provide:Wr,useValue:r}];return n.providers&&(typeof n.providers=="function"?l.push(...n.providers(r,n,i)):l.push(...n.providers)),n.direction&&(!s||!s.get(Mr,null,{optional:!0}))&&l.push({provide:Mr,useValue:hm(n.direction)}),lt.create({parent:s||o,providers:l})}_removeOpenDialog(n,r){let i=this.openDialogs.indexOf(n);i>-1&&(this.openDialogs.splice(i,1),this.openDialogs.length||(this._ariaHiddenElements.forEach((o,s)=>{o?s.setAttribute("aria-hidden",o):s.removeAttribute("aria-hidden")}),this._ariaHiddenElements.clear(),r&&this._getAfterAllClosed().next()))}_hideNonDialogContentFromAssistiveTechnology(n){if(n.parentElement){let r=n.parentElement.children;for(let i=r.length-1;i>-1;i--){let o=r[i];o!==n&&o.nodeName!=="SCRIPT"&&o.nodeName!=="STYLE"&&!o.hasAttribute("aria-live")&&(this._ariaHiddenElements.set(o,o.getAttribute("aria-hidden")),o.setAttribute("aria-hidden","true"))}}}_getAfterAllClosed(){let n=this._parentDialog;return n?n._getAfterAllClosed():this._afterAllClosedAtThisLevel}static \u0275fac=function(r){return new(r||t)};static \u0275prov=Be({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function Fs(t,e){let n=t.length;for(;n--;)e(t[n])}function ks(){return window.CooeeSDK?.uaParser.getDevice().type==="mobile"}var tr=class{lastWidth;lastHeight;resizeTimeout=null;debounceDelay=200;onResizeCallback;constructor(e){this.onResizeCallback=e,this.lastWidth=window.innerWidth,this.lastHeight=window.innerHeight,window.addEventListener("resize",this.debouncedResize),window.addEventListener("orientationchange",this.handleImmediateResize)}destroy(){window.removeEventListener("resize",this.debouncedResize),window.removeEventListener("orientationchange",this.handleImmediateResize)}handleImmediateResize=()=>{this.triggerResize()};debouncedResize=()=>{this.resizeTimeout!==null&&clearTimeout(this.resizeTimeout),this.resizeTimeout=window.setTimeout(()=>{this.triggerResize()},this.debounceDelay)};triggerResize(){let e=window.innerWidth,n=window.innerHeight;(n!==this.lastHeight||e!==this.lastWidth)&&(this.onResizeCallback(),this.lastWidth=e,this.lastHeight=n)}};var Eu=ts(vu());var mm=5,gm=500,_m=(0,Eu.default)(fetch),ym={retryDelay:t=>Math.pow(2,t)*gm,retryOn:(t,e,n)=>t>=mm?!1:!!(e!==null||n?.status&&n?.status>=500)},Yr=class extends Error{request;response;status;requestBody;responseText;constructor(e="Failed to fetch"){super(e),this.name="FetchError",Object.setPrototypeOf(this,new.target.prototype)}is40x(){return!!this.response&&this.response.status>=400&&this.response.status<500}};async function bu(t,e,n){let r=Date.now(),i=new Request(t,e),o;try{o=await _m(i,I(I({},ym),n))}catch{}if(!o||!o.ok){let _=new Yr;throw _.request=i.clone(),_.response=o?.clone(),_.status=o?.status,_.requestBody=e?.body,_.responseText=await vm(o),_}let s,l=(o.headers.get("content-type")||"").toLowerCase(),u=o.headers.get("content-length"),d=i.method?.toUpperCase()||"GET";return o.status===204||o.status===205||d==="HEAD"||u==="0"?s=void 0:l.includes("application/json")||l.includes("application/problem+json")||l.includes("text/javascript")?s=await o.json():l.includes("text/")||l.includes("image/svg+xml")?s=await o.text():s=await o.arrayBuffer(),{data:s,status:o.status,statusText:o.statusText,headers:o.headers,timeTakenMs:Date.now()-r,options:e,request:i}}async function vm(t){if(t){try{return t=t.clone(),await t.json()}catch{}try{return await t.text()}catch{}}}var Xi=class t{static cache=new Map;static loadingPromises=new Map;async getSvg(e){if(t.cache.has(e))return t.cache.get(e);if(t.loadingPromises.has(e))return t.loadingPromises.get(e);let n=this.fetchSvgContent(e);t.loadingPromises.set(e,n);try{let r=await n;return t.cache.set(e,r),r}finally{t.loadingPromises.delete(e)}}getCachedSvg(e){return t.cache.get(e)??null}async preloadIcons(e){let n=e.map(r=>this.getSvg(r).catch(i=>(Te.error(`Failed to preload icon: ${r}`,i),"")));await Promise.all(n)}clearCache(){t.cache.clear(),t.loadingPromises.clear()}async fetchSvgContent(e){let n=`${Lt.baseURL}/svg/${e}.svg`;try{return(await bu(n,{cache:"force-cache",headers:{Accept:"image/svg+xml,text/plain"}})).data}catch(r){return Te.error(`Unable to get the icon: ${e}`,r),""}}static \u0275fac=function(n){return new(n||t)};static \u0275prov=Be({token:t,factory:t.\u0275fac,providedIn:"root"})};var nr=class t{name=Ge.required();rawSvg=xt("");sanitisedSvg=qt(()=>this.sanitizer.bypassSecurityTrustHtml(this.rawSvg()));sanitizer=U(cl);iconService=U(Xi);constructor(){Kt(()=>{let e=this.name();this.loadIcon(e)})}async loadIcon(e){try{let n=await this.iconService.getSvg(e);this.rawSvg.set(n)}catch{this.rawSvg.set("")}}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=ve({type:t,selectors:[["cooee-icon"]],hostAttrs:["role","img"],hostVars:2,hostBindings:function(n,r){n&2&&(Nt("innerHTML",r.sanitisedSvg(),Wt),At("aria-label",r.name()))},inputs:{name:[1,"name"]},decls:0,vars:0,template:function(n,r){},encapsulation:2})};var wu=(n=>(n.SINGLE_PANE="SINGLE_PANE",n.TWO_PANE="TWO_PANE",n))(wu||{});var zr=class zr extends Kn{};_i(zr,"storeName","ses"),zr.storage=Gi(zr.storeName);var Us=zr;var Y=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;var X=globalThis;var Bt="9.42.0";function Dn(){return Nn(X),X}function Nn(t){let e=t.__SENTRY__=t.__SENTRY__||{};return e.version=e.version||Bt,e[Bt]=e[Bt]||{}}function en(t,e,n=X){let r=n.__SENTRY__=n.__SENTRY__||{},i=r[Bt]=r[Bt]||{};return i[t]||(i[t]=e())}var Hs=["debug","info","warn","error","log","assert","trace"],Em="Sentry Logger ",rr={};function mn(t){if(!("console"in X))return t();let e=X.console,n={},r=Object.keys(rr);r.forEach(i=>{let o=rr[i];n[i]=e[i],e[i]=o});try{return t()}finally{r.forEach(i=>{e[i]=n[i]})}}function bm(){$s().enabled=!0}function wm(){$s().enabled=!1}function Su(){return $s().enabled}function Sm(...t){js("log",...t)}function Cm(...t){js("warn",...t)}function Im(...t){js("error",...t)}function js(t,...e){Y&&Su()&&mn(()=>{X.console[t](`${Em}[${t}]:`,...e)})}function $s(){return Y?en("loggerSettings",()=>({enabled:!1})):{enabled:!1}}var H={enable:bm,disable:wm,isEnabled:Su,log:Sm,warn:Cm,error:Im};var Cu=/\(error: (.*)\)/,Iu=/captureMessage|captureException/;function Ws(...t){let e=t.sort((n,r)=>n[0]-r[0]).map(n=>n[1]);return(n,r=0,i=0)=>{let o=[],s=n.split(`
|
|
8
|
+
`);for(let l=r;l<s.length;l++){let u=s[l];if(u.length>1024)continue;let d=Cu.test(u)?u.replace(Cu,"$1"):u;if(!d.match(/\S*Error: /)){for(let _ of e){let p=_(d);if(p){o.push(p);break}}if(o.length>=50+i)break}}return Tu(o.slice(i))}}function Tu(t){if(!t.length)return[];let e=Array.from(t);return/sentryWrapped/.test(qi(e).function||"")&&e.pop(),e.reverse(),Iu.test(qi(e).function||"")&&(e.pop(),Iu.test(qi(e).function||"")&&e.pop()),e.slice(0,50).map(n=>K(I({},n),{filename:n.filename||qi(e).filename,function:n.function||"?"}))}function qi(t){return t[t.length-1]||{}}var Gs="<anonymous>";function ht(t){try{return!t||typeof t!="function"?Gs:t.name||Gs}catch{return Gs}}function Ki(t){let e=t.exception;if(e){let n=[];try{return e.values.forEach(r=>{r.stacktrace.frames&&n.push(...r.stacktrace.frames)}),n}catch{return}}}var Ji={},xu={};function ze(t,e){Ji[t]=Ji[t]||[],Ji[t].push(e)}function Xe(t,e){if(!xu[t]){xu[t]=!0;try{e()}catch(n){Y&&H.error(`Error while instrumenting ${t}`,n)}}}function Ne(t,e){let n=t&&Ji[t];if(n)for(let r of n)try{r(e)}catch(i){Y&&H.error(`Error while triggering instrumentation handler.
|
|
9
|
+
Type: ${t}
|
|
10
|
+
Name: ${ht(r)}
|
|
11
|
+
Error:`,i)}}var Ys=null;function zs(t){let e="error";ze(e,t),Xe(e,Tm)}function Tm(){Ys=X.onerror,X.onerror=function(t,e,n,r,i){return Ne("error",{column:r,error:i,line:n,msg:t,url:e}),Ys?Ys.apply(this,arguments):!1},X.onerror.__SENTRY_INSTRUMENTED__=!0}var Xs=null;function qs(t){let e="unhandledrejection";ze(e,t),Xe(e,xm)}function xm(){Xs=X.onunhandledrejection,X.onunhandledrejection=function(t){return Ne("unhandledrejection",t),Xs?Xs.apply(this,arguments):!0},X.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}var Ou=Object.prototype.toString;function Rn(t){switch(Ou.call(t)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return Ct(t,Error)}}function ir(t,e){return Ou.call(t)===`[object ${e}]`}function Zi(t){return ir(t,"ErrorEvent")}function Qi(t){return ir(t,"DOMError")}function Ks(t){return ir(t,"DOMException")}function qe(t){return ir(t,"String")}function or(t){return typeof t=="object"&&t!==null&&"__sentry_template_string__"in t&&"__sentry_template_values__"in t}function Mn(t){return t===null||or(t)||typeof t!="object"&&typeof t!="function"}function tn(t){return ir(t,"Object")}function Pn(t){return typeof Event<"u"&&Ct(t,Event)}function Js(t){return typeof Element<"u"&&Ct(t,Element)}function Zs(t){return ir(t,"RegExp")}function nn(t){return!!(t?.then&&typeof t.then=="function")}function Qs(t){return tn(t)&&"nativeEvent"in t&&"preventDefault"in t&&"stopPropagation"in t}function Ct(t,e){try{return t instanceof e}catch{return!1}}function Xr(t){return!!(typeof t=="object"&&t!==null&&(t.__isVue||t._isVue))}function Au(t){return typeof Request<"u"&&Ct(t,Request)}var ea=X,Om=80;function qr(t,e={}){if(!t)return"<unknown>";try{let n=t,r=5,i=[],o=0,s=0,l=" > ",u=l.length,d,_=Array.isArray(e)?e:e.keyAttrs,p=!Array.isArray(e)&&e.maxStringLength||Om;for(;n&&o++<r&&(d=Am(n,_),!(d==="html"||o>1&&s+i.length*u+d.length>=p));)i.push(d),s+=d.length,n=n.parentNode;return i.reverse().join(l)}catch{return"<unknown>"}}function Am(t,e){let n=t,r=[];if(!n?.tagName)return"";if(ea.HTMLElement&&n instanceof HTMLElement&&n.dataset){if(n.dataset.sentryComponent)return n.dataset.sentryComponent;if(n.dataset.sentryElement)return n.dataset.sentryElement}r.push(n.tagName.toLowerCase());let i=e?.length?e.filter(s=>n.getAttribute(s)).map(s=>[s,n.getAttribute(s)]):null;if(i?.length)i.forEach(s=>{r.push(`[${s[0]}="${s[1]}"]`)});else{n.id&&r.push(`#${n.id}`);let s=n.className;if(s&&qe(s)){let l=s.split(/\s+/);for(let u of l)r.push(`.${u}`)}}let o=["aria-label","type","name","title","alt"];for(let s of o){let l=n.getAttribute(s);l&&r.push(`[${s}="${l}"]`)}return r.join("")}function Kr(){try{return ea.document.location.href}catch{return""}}function ta(t){if(!ea.HTMLElement)return null;let e=t,n=5;for(let r=0;r<n;r++){if(!e)return null;if(e instanceof HTMLElement){if(e.dataset.sentryComponent)return e.dataset.sentryComponent;if(e.dataset.sentryElement)return e.dataset.sentryElement}e=e.parentNode}return null}function gn(t,e=0){return typeof t!="string"||e===0||t.length<=e?t:`${t.slice(0,e)}...`}function eo(t,e){if(!Array.isArray(t))return"";let n=[];for(let r=0;r<t.length;r++){let i=t[r];try{Xr(i)?n.push("[VueViewModel]"):n.push(String(i))}catch{n.push("[value cannot be serialized]")}}return n.join(e)}function Du(t,e,n=!1){return qe(t)?Zs(e)?e.test(t):qe(e)?n?t===e:t.includes(e):!1:!1}function sr(t,e=[],n=!1){return e.some(r=>Du(t,r,n))}function Re(t,e,n){if(!(e in t))return;let r=t[e];if(typeof r!="function")return;let i=n(r);typeof i=="function"&&to(i,r);try{t[e]=i}catch{Y&&H.log(`Failed to replace method "${e}" in object`,t)}}function it(t,e,n){try{Object.defineProperty(t,e,{value:n,writable:!0,configurable:!0})}catch{Y&&H.log(`Failed to add non-enumerable property "${e}" to object`,t)}}function to(t,e){try{let n=e.prototype||{};t.prototype=e.prototype=n,it(t,"__sentry_original__",e)}catch{}}function Ln(t){return t.__sentry_original__}function no(t){if(Rn(t))return I({message:t.message,name:t.name,stack:t.stack},Ru(t));if(Pn(t)){let e=I({type:t.type,target:Nu(t.target),currentTarget:Nu(t.currentTarget)},Ru(t));return typeof CustomEvent<"u"&&Ct(t,CustomEvent)&&(e.detail=t.detail),e}else return t}function Nu(t){try{return Js(t)?qr(t):Object.prototype.toString.call(t)}catch{return"<unknown>"}}function Ru(t){if(typeof t=="object"&&t!==null){let e={};for(let n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}else return{}}function na(t,e=40){let n=Object.keys(no(t));n.sort();let r=n[0];if(!r)return"[object has no keys]";if(r.length>=e)return gn(r,e);for(let i=n.length;i>0;i--){let o=n.slice(0,i).join(", ");if(!(o.length>e))return i===n.length?o:gn(o,e)}return""}function Dm(){let t=X;return t.crypto||t.msCrypto}function Me(t=Dm()){let e=()=>Math.random()*16;try{if(t?.randomUUID)return t.randomUUID().replace(/-/g,"");t?.getRandomValues&&(e=()=>{let n=new Uint8Array(1);return t.getRandomValues(n),n[0]})}catch{}return("10000000100040008000"+1e11).replace(/[018]/g,n=>(n^(e()&15)>>n/4).toString(16))}function Mu(t){return t.exception?.values?.[0]}function Vt(t){let{message:e,event_id:n}=t;if(e)return e;let r=Mu(t);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function ar(t,e,n){let r=t.exception=t.exception||{},i=r.values=r.values||[],o=i[0]=i[0]||{};o.value||(o.value=e||""),o.type||(o.type=n||"Error")}function Ut(t,e){let n=Mu(t);if(!n)return;let r={type:"generic",handled:!0},i=n.mechanism;if(n.mechanism=I(I(I({},r),i),e),e&&"data"in e){let o=I(I({},i?.data),e.data);n.mechanism.data=o}}function ro(t){if(Nm(t))return!0;try{it(t,"__sentry_captured__",!0)}catch{}return!1}function Nm(t){try{return t.__sentry_captured__}catch{}}var Lu=1e3;function Ht(){return Date.now()/Lu}function Rm(){let{performance:t}=X;if(!t?.now||!t.timeOrigin)return Ht;let e=t.timeOrigin;return()=>(e+t.now())/Lu}var Pu;function et(){return(Pu??(Pu=Rm()))()}function Fu(t){let e=et(),n={sid:Me(),init:!0,timestamp:e,started:e,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>Mm(n)};return t&&rn(n,t),n}function rn(t,e={}){if(e.user&&(!t.ipAddress&&e.user.ip_address&&(t.ipAddress=e.user.ip_address),!t.did&&!e.did&&(t.did=e.user.id||e.user.email||e.user.username)),t.timestamp=e.timestamp||et(),e.abnormal_mechanism&&(t.abnormal_mechanism=e.abnormal_mechanism),e.ignoreDuration&&(t.ignoreDuration=e.ignoreDuration),e.sid&&(t.sid=e.sid.length===32?e.sid:Me()),e.init!==void 0&&(t.init=e.init),!t.did&&e.did&&(t.did=`${e.did}`),typeof e.started=="number"&&(t.started=e.started),t.ignoreDuration)t.duration=void 0;else if(typeof e.duration=="number")t.duration=e.duration;else{let n=t.timestamp-t.started;t.duration=n>=0?n:0}e.release&&(t.release=e.release),e.environment&&(t.environment=e.environment),!t.ipAddress&&e.ipAddress&&(t.ipAddress=e.ipAddress),!t.userAgent&&e.userAgent&&(t.userAgent=e.userAgent),typeof e.errors=="number"&&(t.errors=e.errors),e.status&&(t.status=e.status)}function ku(t,e){let n={};e?n={status:e}:t.status==="ok"&&(n={status:"exited"}),rn(t,n)}function Mm(t){return{sid:`${t.sid}`,init:t.init,started:new Date(t.started*1e3).toISOString(),timestamp:new Date(t.timestamp*1e3).toISOString(),status:t.status,errors:t.errors,did:typeof t.did=="number"||typeof t.did=="string"?`${t.did}`:void 0,duration:t.duration,abnormal_mechanism:t.abnormal_mechanism,attrs:{release:t.release,environment:t.environment,ip_address:t.ipAddress,user_agent:t.userAgent}}}function _n(t,e,n=2){if(!e||typeof e!="object"||n<=0)return e;if(t&&Object.keys(e).length===0)return t;let r=I({},t);for(let i in e)Object.prototype.hasOwnProperty.call(e,i)&&(r[i]=_n(r[i],e[i],n-1));return r}function ra(){return Me()}function io(){return Me().substring(16)}var ia="_sentrySpan";function oa(t,e){e?it(t,ia,e):delete t[ia]}function sa(t){return t[ia]}var Pm=100,je=class t{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:ra(),sampleRand:Math.random()}}clone(){let e=new t;return e._breadcrumbs=[...this._breadcrumbs],e._tags=I({},this._tags),e._extra=I({},this._extra),e._contexts=I({},this._contexts),this._contexts.flags&&(e._contexts.flags={values:[...this._contexts.flags.values]}),e._user=this._user,e._level=this._level,e._session=this._session,e._transactionName=this._transactionName,e._fingerprint=this._fingerprint,e._eventProcessors=[...this._eventProcessors],e._attachments=[...this._attachments],e._sdkProcessingMetadata=I({},this._sdkProcessingMetadata),e._propagationContext=I({},this._propagationContext),e._client=this._client,e._lastEventId=this._lastEventId,oa(e,sa(this)),e}setClient(e){this._client=e}setLastEventId(e){this._lastEventId=e}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&rn(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}setTags(e){return this._tags=I(I({},this._tags),e),this._notifyScopeListeners(),this}setTag(e,n){return this._tags=K(I({},this._tags),{[e]:n}),this._notifyScopeListeners(),this}setExtras(e){return this._extra=I(I({},this._extra),e),this._notifyScopeListeners(),this}setExtra(e,n){return this._extra=K(I({},this._extra),{[e]:n}),this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,n){return n===null?delete this._contexts[e]:this._contexts[e]=n,this._notifyScopeListeners(),this}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(e){if(!e)return this;let n=typeof e=="function"?e(this):e,r=n instanceof t?n.getScopeData():tn(n)?e:void 0,{tags:i,extra:o,user:s,contexts:l,level:u,fingerprint:d=[],propagationContext:_}=r||{};return this._tags=I(I({},this._tags),i),this._extra=I(I({},this._extra),o),this._contexts=I(I({},this._contexts),l),s&&Object.keys(s).length&&(this._user=s),u&&(this._level=u),d.length&&(this._fingerprint=d),_&&(this._propagationContext=_),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._session=void 0,oa(this,void 0),this._attachments=[],this.setPropagationContext({traceId:ra(),sampleRand:Math.random()}),this._notifyScopeListeners(),this}addBreadcrumb(e,n){let r=typeof n=="number"?n:Pm;if(r<=0)return this;let i=K(I({timestamp:Ht()},e),{message:e.message?gn(e.message,2048):e.message});return this._breadcrumbs.push(i),this._breadcrumbs.length>r&&(this._breadcrumbs=this._breadcrumbs.slice(-r),this._client?.recordDroppedEvent("buffer_overflow","log_item")),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:sa(this)}}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata=_n(this._sdkProcessingMetadata,e,2),this}setPropagationContext(e){return this._propagationContext=e,this}getPropagationContext(){return this._propagationContext}captureException(e,n){let r=n?.event_id||Me();if(!this._client)return Y&&H.warn("No client configured on scope - will not capture exception!"),r;let i=new Error("Sentry syntheticException");return this._client.captureException(e,K(I({originalException:e,syntheticException:i},n),{event_id:r}),this),r}captureMessage(e,n,r){let i=r?.event_id||Me();if(!this._client)return Y&&H.warn("No client configured on scope - will not capture message!"),i;let o=new Error(e);return this._client.captureMessage(e,n,K(I({originalException:e,syntheticException:o},r),{event_id:i}),this),i}captureEvent(e,n){let r=n?.event_id||Me();return this._client?(this._client.captureEvent(e,K(I({},n),{event_id:r}),this),r):(Y&&H.warn("No client configured on scope - will not capture event!"),r)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(e=>{e(this)}),this._notifyingListeners=!1)}};function Bu(){return en("defaultCurrentScope",()=>new je)}function Vu(){return en("defaultIsolationScope",()=>new je)}var aa=class{constructor(e,n){let r;e?r=e:r=new je;let i;n?i=n:i=new je,this._stack=[{scope:r}],this._isolationScope=i}withScope(e){let n=this._pushScope(),r;try{r=e(n)}catch(i){throw this._popScope(),i}return nn(r)?r.then(i=>(this._popScope(),i),i=>{throw this._popScope(),i}):(this._popScope(),r)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){let e=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:e}),e}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}};function cr(){let t=Dn(),e=Nn(t);return e.stack=e.stack||new aa(Bu(),Vu())}function Lm(t){return cr().withScope(t)}function Fm(t,e){let n=cr();return n.withScope(()=>(n.getStackTop().scope=t,e(t)))}function Uu(t){return cr().withScope(()=>t(cr().getIsolationScope()))}function Hu(){return{withIsolationScope:Uu,withScope:Lm,withSetScope:Fm,withSetIsolationScope:(t,e)=>Uu(e),getCurrentScope:()=>cr().getScope(),getIsolationScope:()=>cr().getIsolationScope()}}function oo(t){let e=Nn(t);return e.acs?e.acs:Hu()}function jt(){let t=Dn();return oo(t).getCurrentScope()}function $t(){let t=Dn();return oo(t).getIsolationScope()}function so(){return en("globalScope",()=>new je)}function Jr(...t){let e=Dn(),n=oo(e);if(t.length===2){let[r,i]=t;return r?n.withSetScope(r,i):n.withScope(i)}return n.withScope(t[0])}function ye(){return jt().getClient()}function ca(t){let e=t.getPropagationContext(),{traceId:n,parentSpanId:r,propagationSpanId:i}=e,o={trace_id:n,span_id:i||io()};return r&&(o.parent_span_id=r),o}var ao="sentry.source",la="sentry.sample_rate",ju="sentry.previous_trace_sample_rate",ua="sentry.op",fa="sentry.origin";var da="sentry.profile_id",pa="sentry.exclusive_time";var km="_sentryScope",Bm="_sentryIsolationScope";function co(t){return{scope:t[km],isolationScope:t[Bm]}}var Vm="sentry-",Um=/^sentry-/;function Gu(t){let e=Hm(t);if(!e)return;let n=Object.entries(e).reduce((r,[i,o])=>{if(i.match(Um)){let s=i.slice(Vm.length);r[s]=o}return r},{});if(Object.keys(n).length>0)return n}function Hm(t){if(!(!t||!qe(t)&&!Array.isArray(t)))return Array.isArray(t)?t.reduce((e,n)=>{let r=$u(n);return Object.entries(r).forEach(([i,o])=>{e[i]=o}),e},{}):$u(t)}function $u(t){return t.split(",").map(e=>e.split("=").map(n=>{try{return decodeURIComponent(n.trim())}catch{return}})).reduce((e,[n,r])=>(n&&r&&(e[n]=r),e),{})}function Wu(t){if(typeof t=="boolean")return Number(t);let e=typeof t=="string"?parseFloat(t):t;if(!(typeof e!="number"||isNaN(e)||e<0||e>1))return e}var qu=1,Yu=!1;function ha(t){let{spanId:e,traceId:n,isRemote:r}=t.spanContext(),i=r?e:lr(t).parent_span_id,o=co(t).scope,s=r?o?.getPropagationContext().propagationSpanId||io():e;return{parent_span_id:i,span_id:s,trace_id:n}}function jm(t){if(t&&t.length>0)return t.map(s=>{var l=s,{context:u}=l,d=u,{spanId:e,traceId:n,traceFlags:r}=d,i=Pc(d,["spanId","traceId","traceFlags"]),{attributes:o}=l;return I({span_id:e,trace_id:n,sampled:r===qu,attributes:o},i)})}function zu(t){return typeof t=="number"?Xu(t):Array.isArray(t)?t[0]+t[1]/1e9:t instanceof Date?Xu(t.getTime()):et()}function Xu(t){return t>9999999999?t/1e3:t}function lr(t){if(Gm(t))return t.getSpanJSON();let{spanId:e,traceId:n}=t.spanContext();if($m(t)){let{attributes:r,startTime:i,name:o,endTime:s,status:l,links:u}=t,d="parentSpanId"in t?t.parentSpanId:"parentSpanContext"in t?t.parentSpanContext?.spanId:void 0;return{span_id:e,trace_id:n,data:r,description:o,parent_span_id:d,start_timestamp:zu(i),timestamp:zu(s)||void 0,status:Wm(l),op:r[ua],origin:r[fa],links:jm(u)}}return{span_id:e,trace_id:n,start_timestamp:0,data:{}}}function $m(t){let e=t;return!!e.attributes&&!!e.startTime&&!!e.name&&!!e.endTime&&!!e.status}function Gm(t){return typeof t.getSpanJSON=="function"}function Ku(t){let{traceFlags:e}=t.spanContext();return e===qu}function Wm(t){if(!(!t||t.code===0))return t.code===1?"ok":t.message||"unknown_error"}var Ym="_sentryRootSpan";function Zr(t){return t[Ym]||t}function ma(){Yu||(mn(()=>{console.warn("[Sentry] Returning null from `beforeSendSpan` is disallowed. To drop certain spans, configure the respective integrations directly.")}),Yu=!0)}function Ju(t){if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;let e=t||ye()?.getOptions();return!!e&&(e.tracesSampleRate!=null||!!e.tracesSampler)}var ur="production";var zm=/^o(\d+)\./,Xm=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function qm(t){return t==="http"||t==="https"}function yn(t,e=!1){let{host:n,path:r,pass:i,port:o,projectId:s,protocol:l,publicKey:u}=t;return`${l}://${u}${e&&i?`:${i}`:""}@${n}${o?`:${o}`:""}/${r&&`${r}/`}${s}`}function Km(t){let e=Xm.exec(t);if(!e){mn(()=>{console.error(`Invalid Sentry Dsn: ${t}`)});return}let[n,r,i="",o="",s="",l=""]=e.slice(1),u="",d=l,_=d.split("/");if(_.length>1&&(u=_.slice(0,-1).join("/"),d=_.pop()),d){let p=d.match(/^\d+/);p&&(d=p[0])}return Zu({host:o,pass:i,path:u,projectId:d,port:s,protocol:n,publicKey:r})}function Zu(t){return{protocol:t.protocol,publicKey:t.publicKey||"",pass:t.pass||"",host:t.host,port:t.port||"",path:t.path||"",projectId:t.projectId}}function Jm(t){if(!Y)return!0;let{port:e,projectId:n,protocol:r}=t;return["protocol","publicKey","host","projectId"].find(s=>t[s]?!1:(H.error(`Invalid Sentry Dsn: ${s} missing`),!0))?!1:n.match(/^\d+$/)?qm(r)?e&&isNaN(parseInt(e,10))?(H.error(`Invalid Sentry Dsn: Invalid port ${e}`),!1):!0:(H.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(H.error(`Invalid Sentry Dsn: Invalid projectId ${n}`),!1)}function Qu(t){return t.match(zm)?.[1]}function ef(t){let e=typeof t=="string"?Km(t):Zu(t);if(!(!e||!Jm(e)))return e}var Zm="_frozenDsc";function tf(t,e){let n=e.getOptions(),{publicKey:r,host:i}=e.getDsn()||{},o;n.orgId?o=String(n.orgId):i&&(o=Qu(i));let s={environment:n.environment||ur,release:n.release,public_key:r,trace_id:t,org_id:o};return e.emit("createDsc",s),s}function nf(t,e){let n=e.getPropagationContext();return n.dsc||tf(n.traceId,t)}function ga(t){let e=ye();if(!e)return{};let n=Zr(t),r=lr(n),i=r.data,o=n.spanContext().traceState,s=o?.get("sentry.sample_rate")??i[la]??i[ju];function l(T){return(typeof s=="number"||typeof s=="string")&&(T.sample_rate=`${s}`),T}let u=n[Zm];if(u)return l(u);let d=o?.get("sentry.dsc"),_=d&&Gu(d);if(_)return l(_);let p=tf(t.spanContext().traceId,e),v=i[ao],E=r.description;return v!=="url"&&E&&(p.transaction=E),Ju()&&(p.sampled=String(Ku(n)),p.sample_rand=o?.get("sentry.sample_rand")??co(n).scope?.getPropagationContext().sampleRand.toString()),l(p),e.emit("createDsc",p,n),p}function mt(t,e=100,n=1/0){try{return _a("",t,e,n)}catch(r){return{ERROR:`**non-serializable** (${r})`}}}function lo(t,e=3,n=100*1024){let r=mt(t,e);return ng(r)>n?lo(t,e-1,n):r}function _a(t,e,n=1/0,r=1/0,i=rg()){let[o,s]=i;if(e==null||["boolean","string"].includes(typeof e)||typeof e=="number"&&Number.isFinite(e))return e;let l=Qm(t,e);if(!l.startsWith("[object "))return l;if(e.__sentry_skip_normalization__)return e;let u=typeof e.__sentry_override_normalization_depth__=="number"?e.__sentry_override_normalization_depth__:n;if(u===0)return l.replace("object ","");if(o(e))return"[Circular ~]";let d=e;if(d&&typeof d.toJSON=="function")try{let E=d.toJSON();return _a("",E,u-1,r,i)}catch{}let _=Array.isArray(e)?[]:{},p=0,v=no(e);for(let E in v){if(!Object.prototype.hasOwnProperty.call(v,E))continue;if(p>=r){_[E]="[MaxProperties ~]";break}let T=v[E];_[E]=_a(E,T,u-1,r,i),p++}return s(e),_}function Qm(t,e){try{if(t==="domain"&&e&&typeof e=="object"&&e._events)return"[Domain]";if(t==="domainEmitter")return"[DomainEmitter]";if(typeof global<"u"&&e===global)return"[Global]";if(typeof window<"u"&&e===window)return"[Window]";if(typeof document<"u"&&e===document)return"[Document]";if(Xr(e))return"[VueViewModel]";if(Qs(e))return"[SyntheticEvent]";if(typeof e=="number"&&!Number.isFinite(e))return`[${e}]`;if(typeof e=="function")return`[Function: ${ht(e)}]`;if(typeof e=="symbol")return`[${String(e)}]`;if(typeof e=="bigint")return`[BigInt: ${String(e)}]`;let n=eg(e);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(n){return`**non-serializable** (${n})`}}function eg(t){let e=Object.getPrototypeOf(t);return e?.constructor?e.constructor.name:"null prototype"}function tg(t){return~-encodeURI(t).split(/%..|./).length}function ng(t){return tg(JSON.stringify(t))}function rg(){let t=new WeakSet;function e(r){return t.has(r)?!0:(t.add(r),!1)}function n(r){t.delete(r)}return[e,n]}function on(t,e=[]){return[t,e]}function rf(t,e){let[n,r]=t;return[n,[...r,e]]}function va(t,e){let n=t[1];for(let r of n){let i=r[0].type;if(e(r,i))return!0}return!1}function ya(t){let e=Nn(X);return e.encodePolyfill?e.encodePolyfill(t):new TextEncoder().encode(t)}function of(t){let[e,n]=t,r=JSON.stringify(e);function i(o){typeof r=="string"?r=typeof o=="string"?r+o:[ya(r),o]:r.push(typeof o=="string"?ya(o):o)}for(let o of n){let[s,l]=o;if(i(`
|
|
12
|
+
${JSON.stringify(s)}
|
|
13
|
+
`),typeof l=="string"||l instanceof Uint8Array)i(l);else{let u;try{u=JSON.stringify(l)}catch{u=JSON.stringify(mt(l))}i(u)}}return typeof r=="string"?r:ig(r)}function ig(t){let e=t.reduce((i,o)=>i+o.length,0),n=new Uint8Array(e),r=0;for(let i of t)n.set(i,r),r+=i.length;return n}function sf(t){let e=typeof t.data=="string"?ya(t.data):t.data;return[{type:"attachment",length:e.length,filename:t.filename,content_type:t.contentType,attachment_type:t.attachmentType},e]}var og={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",raw_security:"security",log:"log_item"};function Ea(t){return og[t]}function ba(t){if(!t?.sdk)return;let{name:e,version:n}=t.sdk;return{name:e,version:n}}function af(t,e,n,r){let i=t.sdkProcessingMetadata?.dynamicSamplingContext;return I(I(I({event_id:t.event_id,sent_at:new Date().toISOString()},e&&{sdk:e}),!!n&&r&&{dsn:yn(r)}),i&&{trace:i})}function sg(t,e){return e&&(t.sdk=t.sdk||{},t.sdk.name=t.sdk.name||e.name,t.sdk.version=t.sdk.version||e.version,t.sdk.integrations=[...t.sdk.integrations||[],...e.integrations||[]],t.sdk.packages=[...t.sdk.packages||[],...e.packages||[]]),t}function cf(t,e,n,r){let i=ba(n),o=I(I({sent_at:new Date().toISOString()},i&&{sdk:i}),!!r&&e&&{dsn:yn(e)}),s="aggregates"in t?[{type:"sessions"},t]:[{type:"session"},t.toJSON()];return on(o,[s])}function lf(t,e,n,r){let i=ba(n),o=t.type&&t.type!=="replay_event"?t.type:"event";sg(t,n?.sdk);let s=af(t,i,r,e);return delete t.sdkProcessingMetadata,on(s,[[{type:o},t]])}var wa=0,uf=1,ff=2;function gt(t){return new It(e=>{e(t)})}function vn(t){return new It((e,n)=>{n(t)})}var It=class t{constructor(e){this._state=wa,this._handlers=[],this._runExecutor(e)}then(e,n){return new t((r,i)=>{this._handlers.push([!1,o=>{if(!e)r(o);else try{r(e(o))}catch(s){i(s)}},o=>{if(!n)i(o);else try{r(n(o))}catch(s){i(s)}}]),this._executeHandlers()})}catch(e){return this.then(n=>n,e)}finally(e){return new t((n,r)=>{let i,o;return this.then(s=>{o=!1,i=s,e&&e()},s=>{o=!0,i=s,e&&e()}).then(()=>{if(o){r(i);return}n(i)})})}_executeHandlers(){if(this._state===wa)return;let e=this._handlers.slice();this._handlers=[],e.forEach(n=>{n[0]||(this._state===uf&&n[1](this._value),this._state===ff&&n[2](this._value),n[0]=!0)})}_runExecutor(e){let n=(o,s)=>{if(this._state===wa){if(nn(s)){s.then(r,i);return}this._state=o,this._value=s,this._executeHandlers()}},r=o=>{n(uf,o)},i=o=>{n(ff,o)};try{e(r,i)}catch(o){i(o)}}};function uo(t,e,n,r=0){return new It((i,o)=>{let s=t[r];if(e===null||typeof s!="function")i(e);else{let l=s(I({},e),n);Y&&s.id&&l===null&&H.log(`Event processor "${s.id}" dropped event`),nn(l)?l.then(u=>uo(t,u,n,r+1).then(i)).then(null,o):uo(t,l,n,r+1).then(i).then(null,o)}})}function df(t,e){let{fingerprint:n,span:r,breadcrumbs:i,sdkProcessingMetadata:o}=e;ag(t,e),r&&ug(t,r),fg(t,n),cg(t,i),lg(t,o)}function Sa(t,e){let{extra:n,tags:r,user:i,contexts:o,level:s,sdkProcessingMetadata:l,breadcrumbs:u,fingerprint:d,eventProcessors:_,attachments:p,propagationContext:v,transactionName:E,span:T}=e;fo(t,"extra",n),fo(t,"tags",r),fo(t,"user",i),fo(t,"contexts",o),t.sdkProcessingMetadata=_n(t.sdkProcessingMetadata,l,2),s&&(t.level=s),E&&(t.transactionName=E),T&&(t.span=T),u.length&&(t.breadcrumbs=[...t.breadcrumbs,...u]),d.length&&(t.fingerprint=[...t.fingerprint,...d]),_.length&&(t.eventProcessors=[...t.eventProcessors,..._]),p.length&&(t.attachments=[...t.attachments,...p]),t.propagationContext=I(I({},t.propagationContext),v)}function fo(t,e,n){t[e]=_n(t[e],n,1)}function ag(t,e){let{extra:n,tags:r,user:i,contexts:o,level:s,transactionName:l}=e;Object.keys(n).length&&(t.extra=I(I({},n),t.extra)),Object.keys(r).length&&(t.tags=I(I({},r),t.tags)),Object.keys(i).length&&(t.user=I(I({},i),t.user)),Object.keys(o).length&&(t.contexts=I(I({},o),t.contexts)),s&&(t.level=s),l&&t.type!=="transaction"&&(t.transaction=l)}function cg(t,e){let n=[...t.breadcrumbs||[],...e];t.breadcrumbs=n.length?n:void 0}function lg(t,e){t.sdkProcessingMetadata=I(I({},t.sdkProcessingMetadata),e)}function ug(t,e){t.contexts=I({trace:ha(e)},t.contexts),t.sdkProcessingMetadata=I({dynamicSamplingContext:ga(e)},t.sdkProcessingMetadata);let n=Zr(e),r=lr(n).description;r&&!t.transaction&&t.type==="transaction"&&(t.transaction=r)}function fg(t,e){t.fingerprint=t.fingerprint?Array.isArray(t.fingerprint)?t.fingerprint:[t.fingerprint]:[],e&&(t.fingerprint=t.fingerprint.concat(e)),t.fingerprint.length||delete t.fingerprint}var po,pf,ho;function hf(t){let e=X._sentryDebugIds;if(!e)return{};let n=Object.keys(e);return ho&&n.length===pf||(pf=n.length,ho=n.reduce((r,i)=>{po||(po={});let o=po[i];if(o)r[o[0]]=o[1];else{let s=t(i);for(let l=s.length-1;l>=0;l--){let d=s[l]?.filename,_=e[i];if(d&&_){r[d]=_,po[i]=[d,_];break}}}return r},{})),ho}function mf(t,e,n,r,i,o){let{normalizeDepth:s=3,normalizeMaxBreadth:l=1e3}=t,u=K(I({},e),{event_id:e.event_id||n.event_id||Me(),timestamp:e.timestamp||Ht()}),d=n.integrations||t.integrations.map(F=>F.name);dg(u,t),mg(u,d),i&&i.emit("applyFrameMetadata",e),e.type===void 0&&pg(u,t.stackParser);let _=_g(r,n.captureContext);n.mechanism&&Ut(u,n.mechanism);let p=i?i.getEventProcessors():[],v=so().getScopeData();if(o){let F=o.getScopeData();Sa(v,F)}if(_){let F=_.getScopeData();Sa(v,F)}let E=[...n.attachments||[],...v.attachments];E.length&&(n.attachments=E),df(u,v);let T=[...p,...v.eventProcessors];return uo(T,u,n).then(F=>(F&&hg(F),typeof s=="number"&&s>0?gg(F,s,l):F))}function dg(t,e){let{environment:n,release:r,dist:i,maxValueLength:o=250}=e;t.environment=t.environment||n||ur,!t.release&&r&&(t.release=r),!t.dist&&i&&(t.dist=i);let s=t.request;s?.url&&(s.url=gn(s.url,o))}function pg(t,e){let n=hf(e);t.exception?.values?.forEach(r=>{r.stacktrace?.frames?.forEach(i=>{i.filename&&(i.debug_id=n[i.filename])})})}function hg(t){let e={};if(t.exception?.values?.forEach(r=>{r.stacktrace?.frames?.forEach(i=>{i.debug_id&&(i.abs_path?e[i.abs_path]=i.debug_id:i.filename&&(e[i.filename]=i.debug_id),delete i.debug_id)})}),Object.keys(e).length===0)return;t.debug_meta=t.debug_meta||{},t.debug_meta.images=t.debug_meta.images||[];let n=t.debug_meta.images;Object.entries(e).forEach(([r,i])=>{n.push({type:"sourcemap",code_file:r,debug_id:i})})}function mg(t,e){e.length>0&&(t.sdk=t.sdk||{},t.sdk.integrations=[...t.sdk.integrations||[],...e])}function gg(t,e,n){if(!t)return null;let r=I(I(I(I(I({},t),t.breadcrumbs&&{breadcrumbs:t.breadcrumbs.map(i=>I(I({},i),i.data&&{data:mt(i.data,e,n)}))}),t.user&&{user:mt(t.user,e,n)}),t.contexts&&{contexts:mt(t.contexts,e,n)}),t.extra&&{extra:mt(t.extra,e,n)});return t.contexts?.trace&&r.contexts&&(r.contexts.trace=t.contexts.trace,t.contexts.trace.data&&(r.contexts.trace.data=mt(t.contexts.trace.data,e,n))),t.spans&&(r.spans=t.spans.map(i=>I(I({},i),i.data&&{data:mt(i.data,e,n)}))),t.contexts?.flags&&r.contexts&&(r.contexts.flags=mt(t.contexts.flags,3,n)),r}function _g(t,e){if(!e)return t;let n=t?t.clone():new je;return n.update(e),n}function gf(t){if(t)return yg(t)?{captureContext:t}:Eg(t)?{captureContext:t}:t}function yg(t){return t instanceof je||typeof t=="function"}var vg=["user","level","extra","contexts","tags","fingerprint","propagationContext"];function Eg(t){return Object.keys(t).some(e=>vg.includes(e))}function mo(t,e){return jt().captureException(t,gf(e))}function Qr(t,e){return jt().captureEvent(t,e)}function ei(t){let e=$t(),n=jt(),{userAgent:r}=X.navigator||{},i=Fu(I(I({user:n.getUser()||e.getUser()},r&&{userAgent:r}),t)),o=e.getSession();return o?.status==="ok"&&rn(o,{status:"exited"}),go(),e.setSession(i),i}function go(){let t=$t(),n=jt().getSession()||t.getSession();n&&ku(n),yf(),t.setSession()}function yf(){let t=$t(),e=ye(),n=t.getSession();n&&e&&e.captureSession(n)}function ti(t=!1){if(t){go();return}yf()}var bg="7";function wg(t){let e=t.protocol?`${t.protocol}:`:"",n=t.port?`:${t.port}`:"";return`${e}//${t.host}${n}${t.path?`/${t.path}`:""}/api/`}function Sg(t){return`${wg(t)}${t.projectId}/envelope/`}function Cg(t,e){let n={sentry_version:bg};return t.publicKey&&(n.sentry_key=t.publicKey),e&&(n.sentry_client=`${e.name}/${e.version}`),new URLSearchParams(n).toString()}function vf(t,e,n){return e||`${Sg(t)}?${Cg(t,n)}`}var Ef=[];function bf(t,e){let n={};return e.forEach(r=>{r&&Ia(t,r,n)}),n}function Ca(t,e){for(let n of e)n?.afterAllSetup&&n.afterAllSetup(t)}function Ia(t,e,n){if(n[e.name]){Y&&H.log(`Integration skipped because it was already installed: ${e.name}`);return}if(n[e.name]=e,Ef.indexOf(e.name)===-1&&typeof e.setupOnce=="function"&&(e.setupOnce(),Ef.push(e.name)),e.setup&&typeof e.setup=="function"&&e.setup(t),typeof e.preprocessEvent=="function"){let r=e.preprocessEvent.bind(e);t.on("preprocessEvent",(i,o)=>r(i,o,t))}if(typeof e.processEvent=="function"){let r=e.processEvent.bind(e),i=Object.assign((o,s)=>r(o,s,t),{id:e.name});t.addEventProcessor(i)}Y&&H.log(`Integration installed: ${e.name}`)}function wf(t,e,n){let r=[{type:"client_report"},{timestamp:n||Ht(),discarded_events:t}];return on(e?{dsn:e}:{},[r])}function _o(t){let e=[];t.message&&e.push(t.message);try{let n=t.exception.values[t.exception.values.length-1];n?.value&&(e.push(n.value),n.type&&e.push(`${n.type}: ${n.value}`))}catch{}return e}function Sf(t){let{trace_id:e,parent_span_id:n,span_id:r,status:i,origin:o,data:s,op:l}=t.contexts?.trace??{};return{data:s??{},description:t.transaction,op:l,parent_span_id:n,span_id:r??"",start_timestamp:t.start_timestamp??0,status:i,timestamp:t.timestamp,trace_id:e??"",origin:o,profile_id:s?.[da],exclusive_time:s?.[pa],measurements:t.measurements,is_segment:!0}}function Cf(t){return{type:"transaction",timestamp:t.timestamp,start_timestamp:t.start_timestamp,transaction:t.description,contexts:{trace:{trace_id:t.trace_id,span_id:t.span_id,parent_span_id:t.parent_span_id,op:t.op,status:t.status,origin:t.origin,data:I(I(I({},t.data),t.profile_id&&{[da]:t.profile_id}),t.exclusive_time&&{[pa]:t.exclusive_time})}},measurements:t.measurements}}var If="Not capturing exception because it's already been captured.",Tf="Discarded session because of missing or non-string release",Af=Symbol.for("SentryInternalError"),Df=Symbol.for("SentryDoNotSendEventError");function yo(t){return{message:t,[Af]:!0}}function Ta(t){return{message:t,[Df]:!0}}function xf(t){return!!t&&typeof t=="object"&&Af in t}function Of(t){return!!t&&typeof t=="object"&&Df in t}var ni=class{constructor(e){if(this._options=e,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],e.dsn?this._dsn=ef(e.dsn):Y&&H.warn("No DSN provided, client will not send events."),this._dsn){let n=vf(this._dsn,e.tunnel,e._metadata?e._metadata.sdk:void 0);this._transport=e.transport(K(I({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this)},e.transportOptions),{url:n}))}}captureException(e,n,r){let i=Me();if(ro(e))return Y&&H.log(If),i;let o=I({event_id:i},n);return this._process(this.eventFromException(e,o).then(s=>this._captureEvent(s,o,r))),o.event_id}captureMessage(e,n,r,i){let o=I({event_id:Me()},r),s=or(e)?e:String(e),l=Mn(e)?this.eventFromMessage(s,n,o):this.eventFromException(e,o);return this._process(l.then(u=>this._captureEvent(u,o,i))),o.event_id}captureEvent(e,n,r){let i=Me();if(n?.originalException&&ro(n.originalException))return Y&&H.log(If),i;let o=I({event_id:i},n),s=e.sdkProcessingMetadata||{},l=s.capturedSpanScope,u=s.capturedSpanIsolationScope;return this._process(this._captureEvent(e,o,l||r,u)),o.event_id}captureSession(e){this.sendSession(e),rn(e,{init:!1})}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(e){let n=this._transport;return n?(this.emit("flush"),this._isClientDoneProcessing(e).then(r=>n.flush(e).then(i=>r&&i))):gt(!0)}close(e){return this.flush(e).then(n=>(this.getOptions().enabled=!1,this.emit("close"),n))}getEventProcessors(){return this._eventProcessors}addEventProcessor(e){this._eventProcessors.push(e)}init(){(this._isEnabled()||this._options.integrations.some(({name:e})=>e.startsWith("Spotlight")))&&this._setupIntegrations()}getIntegrationByName(e){return this._integrations[e]}addIntegration(e){let n=this._integrations[e.name];Ia(this,e,this._integrations),n||Ca(this,[e])}sendEvent(e,n={}){this.emit("beforeSendEvent",e,n);let r=lf(e,this._dsn,this._options._metadata,this._options.tunnel);for(let o of n.attachments||[])r=rf(r,sf(o));let i=this.sendEnvelope(r);i&&i.then(o=>this.emit("afterSendEvent",e,o),null)}sendSession(e){let{release:n,environment:r=ur}=this._options;if("aggregates"in e){let o=e.attrs||{};if(!o.release&&!n){Y&&H.warn(Tf);return}o.release=o.release||n,o.environment=o.environment||r,e.attrs=o}else{if(!e.release&&!n){Y&&H.warn(Tf);return}e.release=e.release||n,e.environment=e.environment||r}this.emit("beforeSendSession",e);let i=cf(e,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(i)}recordDroppedEvent(e,n,r=1){if(this._options.sendClientReports){let i=`${e}:${n}`;Y&&H.log(`Recording outcome: "${i}"${r>1?` (${r} times)`:""}`),this._outcomes[i]=(this._outcomes[i]||0)+r}}on(e,n){let r=this._hooks[e]=this._hooks[e]||[];return r.push(n),()=>{let i=r.indexOf(n);i>-1&&r.splice(i,1)}}emit(e,...n){let r=this._hooks[e];r&&r.forEach(i=>i(...n))}sendEnvelope(e){return this.emit("beforeEnvelope",e),this._isEnabled()&&this._transport?this._transport.send(e).then(null,n=>(Y&&H.error("Error while sending envelope:",n),n)):(Y&&H.error("Transport disabled"),gt({}))}_setupIntegrations(){let{integrations:e}=this._options;this._integrations=bf(this,e),Ca(this,e)}_updateSessionFromEvent(e,n){let r=n.level==="fatal",i=!1,o=n.exception?.values;if(o){i=!0;for(let u of o)if(u.mechanism?.handled===!1){r=!0;break}}let s=e.status==="ok";(s&&e.errors===0||s&&r)&&(rn(e,K(I({},r&&{status:"crashed"}),{errors:e.errors||Number(i||r)})),this.captureSession(e))}_isClientDoneProcessing(e){return new It(n=>{let r=0,i=1,o=setInterval(()=>{this._numProcessing==0?(clearInterval(o),n(!0)):(r+=i,e&&r>=e&&(clearInterval(o),n(!1)))},i)})}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(e,n,r,i){let o=this.getOptions(),s=Object.keys(this._integrations);return!n.integrations&&s?.length&&(n.integrations=s),this.emit("preprocessEvent",e,n),e.type||i.setLastEventId(e.event_id||n.event_id),mf(o,e,n,r,this,i).then(l=>{if(l===null)return l;this.emit("postprocessEvent",l,n),l.contexts=I({trace:ca(r)},l.contexts);let u=nf(this,r);return l.sdkProcessingMetadata=I({dynamicSamplingContext:u},l.sdkProcessingMetadata),l})}_captureEvent(e,n={},r=jt(),i=$t()){return Y&&xa(e)&&H.log(`Captured error event \`${_o(e)[0]||"<unknown>"}\``),this._processEvent(e,n,r,i).then(o=>o.event_id,o=>{Y&&(Of(o)?H.log(o.message):xf(o)?H.warn(o.message):H.warn(o))})}_processEvent(e,n,r,i){let o=this.getOptions(),{sampleRate:s}=o,l=Nf(e),u=xa(e),d=e.type||"error",_=`before send for type \`${d}\``,p=typeof s>"u"?void 0:Wu(s);if(u&&typeof p=="number"&&Math.random()>p)return this.recordDroppedEvent("sample_rate","error"),vn(Ta(`Discarding event because it's not included in the random sample (sampling rate = ${s})`));let v=d==="replay_event"?"replay":d;return this._prepareEvent(e,n,r,i).then(E=>{if(E===null)throw this.recordDroppedEvent("event_processor",v),Ta("An event processor returned `null`, will not send event.");if(n.data&&n.data.__sentry__===!0)return E;let N=xg(this,o,E,n);return Tg(N,_)}).then(E=>{if(E===null){if(this.recordDroppedEvent("before_send",v),l){let B=1+(e.spans||[]).length;this.recordDroppedEvent("before_send","span",B)}throw Ta(`${_} returned \`null\`, will not send event.`)}let T=r.getSession()||i.getSession();if(u&&T&&this._updateSessionFromEvent(T,E),l){let F=E.sdkProcessingMetadata?.spanCountBeforeProcessing||0,B=E.spans?E.spans.length:0,k=F-B;k>0&&this.recordDroppedEvent("before_send","span",k)}let N=E.transaction_info;if(l&&N&&E.transaction!==e.transaction){let F="custom";E.transaction_info=K(I({},N),{source:F})}return this.sendEvent(E,n),E}).then(null,E=>{throw Of(E)||xf(E)?E:(this.captureException(E,{data:{__sentry__:!0},originalException:E}),yo(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.
|
|
14
|
+
Reason: ${E}`))})}_process(e){this._numProcessing++,e.then(n=>(this._numProcessing--,n),n=>(this._numProcessing--,n))}_clearOutcomes(){let e=this._outcomes;return this._outcomes={},Object.entries(e).map(([n,r])=>{let[i,o]=n.split(":");return{reason:i,category:o,quantity:r}})}_flushOutcomes(){Y&&H.log("Flushing outcomes...");let e=this._clearOutcomes();if(e.length===0){Y&&H.log("No outcomes to send");return}if(!this._dsn){Y&&H.log("No dsn provided, will not send outcomes");return}Y&&H.log("Sending outcomes:",e);let n=wf(e,this._options.tunnel&&yn(this._dsn));this.sendEnvelope(n)}};function Tg(t,e){let n=`${e} must return \`null\` or a valid event.`;if(nn(t))return t.then(r=>{if(!tn(r)&&r!==null)throw yo(n);return r},r=>{throw yo(`${e} rejected with ${r}`)});if(!tn(t)&&t!==null)throw yo(n);return t}function xg(t,e,n,r){let{beforeSend:i,beforeSendTransaction:o,beforeSendSpan:s}=e,l=n;if(xa(l)&&i)return i(l,r);if(Nf(l)){if(s){let u=s(Sf(l));if(u?l=_n(n,Cf(u)):ma(),l.spans){let d=[];for(let _ of l.spans){let p=s(_);p?d.push(p):(ma(),d.push(_))}l.spans=d}}if(o){if(l.spans){let u=l.spans.length;l.sdkProcessingMetadata=K(I({},n.sdkProcessingMetadata),{spanCountBeforeProcessing:u})}return o(l,r)}}return l}function xa(t){return t.type===void 0}function Nf(t){return t.type==="transaction"}function Og(t){return[{type:"log",item_count:t.length,content_type:"application/vnd.sentry.items.log+json"},{items:t}]}function Rf(t,e,n,r){let i={};return e?.sdk&&(i.sdk={name:e.sdk.name,version:e.sdk.version}),n&&r&&(i.dsn=yn(r)),on(i,[Og(t)])}function ri(t,e){let n=e??Ag(t)??[];if(n.length===0)return;let r=t.getOptions(),i=Rf(n,r._metadata,r.tunnel,t.getDsn());Mf().set(t,[]),t.emit("flushLogs"),t.sendEnvelope(i)}function Ag(t){return Mf().get(t)}function Mf(){return en("clientToLogBufferMap",()=>new WeakMap)}var Oa=Symbol.for("SentryBufferFullError");function Pf(t){let e=[];function n(){return t===void 0||e.length<t}function r(s){return e.splice(e.indexOf(s),1)[0]||Promise.resolve(void 0)}function i(s){if(!n())return vn(Oa);let l=s();return e.indexOf(l)===-1&&e.push(l),l.then(()=>r(l)).then(null,()=>r(l).then(null,()=>{})),l}function o(s){return new It((l,u)=>{let d=e.length;if(!d)return l(!0);let _=setTimeout(()=>{s&&s>0&&l(!1)},s);e.forEach(p=>{gt(p).then(()=>{--d||(clearTimeout(_),l(!0))},u)})})}return{$:e,add:i,drain:o}}function Dg(t,e=Date.now()){let n=parseInt(`${t}`,10);if(!isNaN(n))return n*1e3;let r=Date.parse(`${t}`);return isNaN(r)?6e4:r-e}function Ng(t,e){return t[e]||t.all||0}function Lf(t,e,n=Date.now()){return Ng(t,e)>n}function Ff(t,{statusCode:e,headers:n},r=Date.now()){let i=I({},t),o=n?.["x-sentry-rate-limits"],s=n?.["retry-after"];if(o)for(let l of o.trim().split(",")){let[u,d,,,_]=l.split(":",5),p=parseInt(u,10),v=(isNaN(p)?60:p)*1e3;if(!d)i.all=r+v;else for(let E of d.split(";"))E==="metric_bucket"?(!_||_.split(";").includes("custom"))&&(i[E]=r+v):i[E]=r+v}else s?i.all=r+Dg(s,r):e===429&&(i.all=r+60*1e3);return i}var Rg=64;function vo(t,e,n=Pf(t.bufferSize||Rg)){let r={},i=s=>n.drain(s);function o(s){let l=[];if(va(s,(p,v)=>{let E=Ea(v);Lf(r,E)?t.recordDroppedEvent("ratelimit_backoff",E):l.push(p)}),l.length===0)return gt({});let u=on(s[0],l),d=p=>{va(u,(v,E)=>{t.recordDroppedEvent(p,Ea(E))})},_=()=>e({body:of(u)}).then(p=>(p.statusCode!==void 0&&(p.statusCode<200||p.statusCode>=300)&&Y&&H.warn(`Sentry responded with status code ${p.statusCode} to sent event.`),r=Ff(r,p),p),p=>{throw d("network_error"),Y&&H.error("Encountered error running transport request:",p),p});return n.add(_).then(p=>p,p=>{if(p===Oa)return Y&&H.error("Skipped sending event because buffer is full."),d("queue_overflow"),gt({});throw p})}return{send:o,flush:i}}function Aa(t){t.user?.ip_address===void 0&&(t.user=K(I({},t.user),{ip_address:"{{auto}}"}))}function Da(t){"aggregates"in t?t.attrs?.ip_address===void 0&&(t.attrs=K(I({},t.attrs),{ip_address:"{{auto}}"})):t.ipAddress===void 0&&(t.ipAddress="{{auto}}")}function Na(t,e,n=[e],r="npm"){let i=t._metadata||{};i.sdk||(i.sdk={name:`sentry.javascript.${e}`,packages:n.map(o=>({name:`${r}:@sentry/${o}`,version:Bt})),version:Bt}),t._metadata=i}var Mg=100;function Gt(t,e){let n=ye(),r=$t();if(!n)return;let{beforeBreadcrumb:i=null,maxBreadcrumbs:o=Mg}=n.getOptions();if(o<=0)return;let s=Ht(),l=I({timestamp:s},t),u=i?mn(()=>i(l,e)):l;u!==null&&(n.emit&&n.emit("beforeAddBreadcrumb",u,e),r.addBreadcrumb(u,o))}var kf,Pg="FunctionToString",Bf=new WeakMap,Lg=()=>({name:Pg,setupOnce(){kf=Function.prototype.toString;try{Function.prototype.toString=function(...t){let e=Ln(this),n=Bf.has(ye())&&e!==void 0?e:this;return kf.apply(n,t)}}catch{}},setup(t){Bf.set(t,!0)}}),Eo=Lg;var Fg=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,/^Can't find variable: gmo$/,/^undefined is not an object \(evaluating 'a\.[A-Z]'\)$/,`can't redefine non-configurable property "solana"`,"vv().getRestrictions is not a function. (In 'vv().getRestrictions(1,a)', 'vv().getRestrictions' is undefined)","Can't find variable: _AutofillCallbackHandler",/^Non-Error promise rejection captured with value: Object Not Found Matching Id:\d+, MethodName:simulateEvent, ParamCount:\d+$/,/^Java exception was raised during method invocation$/],kg="EventFilters",Ra=(t={})=>{let e;return{name:kg,setup(n){let r=n.getOptions();e=Vf(t,r)},processEvent(n,r,i){if(!e){let o=i.getOptions();e=Vf(t,o)}return Bg(n,e)?null:n}}},wo=(t={})=>K(I({},Ra(t)),{name:"InboundFilters"});function Vf(t={},e={}){return{allowUrls:[...t.allowUrls||[],...e.allowUrls||[]],denyUrls:[...t.denyUrls||[],...e.denyUrls||[]],ignoreErrors:[...t.ignoreErrors||[],...e.ignoreErrors||[],...t.disableErrorDefaults?[]:Fg],ignoreTransactions:[...t.ignoreTransactions||[],...e.ignoreTransactions||[]]}}function Bg(t,e){if(t.type){if(t.type==="transaction"&&Ug(t,e.ignoreTransactions))return Y&&H.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.
|
|
15
|
+
Event: ${Vt(t)}`),!0}else{if(Vg(t,e.ignoreErrors))return Y&&H.warn(`Event dropped due to being matched by \`ignoreErrors\` option.
|
|
16
|
+
Event: ${Vt(t)}`),!0;if(Gg(t))return Y&&H.warn(`Event dropped due to not having an error message, error type or stacktrace.
|
|
17
|
+
Event: ${Vt(t)}`),!0;if(Hg(t,e.denyUrls))return Y&&H.warn(`Event dropped due to being matched by \`denyUrls\` option.
|
|
18
|
+
Event: ${Vt(t)}.
|
|
19
|
+
Url: ${bo(t)}`),!0;if(!jg(t,e.allowUrls))return Y&&H.warn(`Event dropped due to not being matched by \`allowUrls\` option.
|
|
20
|
+
Event: ${Vt(t)}.
|
|
21
|
+
Url: ${bo(t)}`),!0}return!1}function Vg(t,e){return e?.length?_o(t).some(n=>sr(n,e)):!1}function Ug(t,e){if(!e?.length)return!1;let n=t.transaction;return n?sr(n,e):!1}function Hg(t,e){if(!e?.length)return!1;let n=bo(t);return n?sr(n,e):!1}function jg(t,e){if(!e?.length)return!0;let n=bo(t);return n?sr(n,e):!0}function $g(t=[]){for(let e=t.length-1;e>=0;e--){let n=t[e];if(n&&n.filename!=="<anonymous>"&&n.filename!=="[native code]")return n.filename||null}return null}function bo(t){try{let n=[...t.exception?.values??[]].reverse().find(r=>r.mechanism?.parent_id===void 0&&r.stacktrace?.frames?.length)?.stacktrace?.frames;return n?$g(n):null}catch{return Y&&H.error(`Cannot extract url for event ${Vt(t)}`),null}}function Gg(t){return t.exception?.values?.length?!t.message&&!t.exception.values.some(e=>e.stacktrace||e.type&&e.type!=="Error"||e.value):!1}function Pa(t,e,n,r,i,o){if(!i.exception?.values||!o||!Ct(o.originalException,Error))return;let s=i.exception.values.length>0?i.exception.values[i.exception.values.length-1]:void 0;s&&(i.exception.values=Ma(t,e,r,o.originalException,n,i.exception.values,s,0))}function Ma(t,e,n,r,i,o,s,l){if(o.length>=n+1)return o;let u=[...o];if(Ct(r[i],Error)){Uf(s,l);let d=t(e,r[i]),_=u.length;Hf(d,i,_,l),u=Ma(t,e,n,r[i],i,[d,...u],d,_)}return Array.isArray(r.errors)&&r.errors.forEach((d,_)=>{if(Ct(d,Error)){Uf(s,l);let p=t(e,d),v=u.length;Hf(p,`errors[${_}]`,v,l),u=Ma(t,e,n,d,i,[p,...u],p,v)}}),u}function Uf(t,e){t.mechanism=t.mechanism||{type:"generic",handled:!0},t.mechanism=K(I(I({},t.mechanism),t.type==="AggregateError"&&{is_exception_group:!0}),{exception_id:e})}function Hf(t,e,n,r){t.mechanism=t.mechanism||{type:"generic",handled:!0},t.mechanism=K(I({},t.mechanism),{type:"chained",source:e,exception_id:n,parent_id:r})}function La(t){let e="console";ze(e,t),Xe(e,Wg)}function Wg(){"console"in X&&Hs.forEach(function(t){t in X.console&&Re(X.console,t,function(e){return rr[t]=e,function(...n){Ne("console",{args:n,level:t}),rr[t]?.apply(X.console,n)}})})}function Fa(t){return t==="warn"?"warning":["fatal","error","warning","log","info","debug"].includes(t)?t:"log"}var Yg="Dedupe",zg=()=>{let t;return{name:Yg,processEvent(e){if(e.type)return e;try{if(Xg(e,t))return Y&&H.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return t=e}}},So=zg;function Xg(t,e){return e?!!(qg(t,e)||Kg(t,e)):!1}function qg(t,e){let n=t.message,r=e.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!Gf(t,e)||!$f(t,e))}function Kg(t,e){let n=jf(e),r=jf(t);return!(!n||!r||n.type!==r.type||n.value!==r.value||!Gf(t,e)||!$f(t,e))}function $f(t,e){let n=Ki(t),r=Ki(e);if(!n&&!r)return!0;if(n&&!r||!n&&r||(n=n,r=r,r.length!==n.length))return!1;for(let i=0;i<r.length;i++){let o=r[i],s=n[i];if(o.filename!==s.filename||o.lineno!==s.lineno||o.colno!==s.colno||o.function!==s.function)return!1}return!0}function Gf(t,e){let n=t.fingerprint,r=e.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return n.join("")===r.join("")}catch{return!1}}function jf(t){return t.exception?.values?.[0]}function ii(t){if(!t)return{};let e=t.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!e)return{};let n=e[6]||"",r=e[8]||"";return{host:e[4],path:e[5],protocol:e[2],search:n,hash:r,relative:e[5]+n+r}}function Co(t){if(t!==void 0)return t>=400&&t<500?"warning":t>=500?"error":void 0}var oi=X;function ka(){return"history"in oi&&!!oi.history}function Jg(){if(!("fetch"in oi))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function si(t){return t&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(t.toString())}function Ba(){if(typeof EdgeRuntime=="string")return!0;if(!Jg())return!1;if(si(oi.fetch))return!0;let t=!1,e=oi.document;if(e&&typeof e.createElement=="function")try{let n=e.createElement("iframe");n.hidden=!0,e.head.appendChild(n),n.contentWindow?.fetch&&(t=si(n.contentWindow.fetch)),e.head.removeChild(n)}catch(n){Y&&H.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",n)}return t}function Ua(t,e){let n="fetch";ze(n,t),Xe(n,()=>Zg(void 0,e))}function Zg(t,e=!1){e&&!Ba()||Re(X,"fetch",function(n){return function(...r){let i=new Error,{method:o,url:s}=Qg(r),l={args:r,fetchData:{method:o,url:s},startTimestamp:et()*1e3,virtualError:i,headers:e_(r)};return t||Ne("fetch",I({},l)),n.apply(X,r).then(async u=>(t?t(u):Ne("fetch",K(I({},l),{endTimestamp:et()*1e3,response:u})),u),u=>{if(Ne("fetch",K(I({},l),{endTimestamp:et()*1e3,error:u})),Rn(u)&&u.stack===void 0&&(u.stack=i.stack,it(u,"framesToPop",1)),u instanceof TypeError&&(u.message==="Failed to fetch"||u.message==="Load failed"||u.message==="NetworkError when attempting to fetch resource."))try{let d=new URL(l.fetchData.url);u.message=`${u.message} (${d.host})`}catch{}throw u})}})}function Va(t,e){return!!t&&typeof t=="object"&&!!t[e]}function Wf(t){return typeof t=="string"?t:t?Va(t,"url")?t.url:t.toString?t.toString():"":""}function Qg(t){if(t.length===0)return{method:"GET",url:""};if(t.length===2){let[n,r]=t;return{url:Wf(n),method:Va(r,"method")?String(r.method).toUpperCase():"GET"}}let e=t[0];return{url:Wf(e),method:Va(e,"method")?String(e.method).toUpperCase():"GET"}}function e_(t){let[e,n]=t;try{if(typeof n=="object"&&n!==null&&"headers"in n&&n.headers)return new Headers(n.headers);if(Au(e))return new Headers(e.headers)}catch{}}function Ha(){return"npm"}var Ce=X,ja=0;function $a(){return ja>0}function m_(){ja++,setTimeout(()=>{ja--})}function Fn(t,e={}){function n(i){return typeof i=="function"}if(!n(t))return t;try{let i=t.__sentry_wrapped__;if(i)return typeof i=="function"?i:t;if(Ln(t))return t}catch{return t}let r=function(...i){try{let o=i.map(s=>Fn(s,e));return t.apply(this,o)}catch(o){throw m_(),Jr(s=>{s.addEventProcessor(l=>(e.mechanism&&(ar(l,void 0,void 0),Ut(l,e.mechanism)),l.extra=K(I({},l.extra),{arguments:i}),l)),mo(o)}),o}};try{for(let i in t)Object.prototype.hasOwnProperty.call(t,i)&&(r[i]=t[i])}catch{}to(r,t),it(t,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return t.name}})}catch{}return r}function Yf(){let t=Kr(),{referrer:e}=Ce.document||{},{userAgent:n}=Ce.navigator||{},r=I(I({},e&&{Referer:e}),n&&{"User-Agent":n});return{url:t,headers:r}}function Io(t,e){let n=Ya(t,e),r={type:E_(e),value:b_(e)};return n.length&&(r.stacktrace={frames:n}),r.type===void 0&&r.value===""&&(r.value="Unrecoverable error caught"),r}function g_(t,e,n,r){let o=ye()?.getOptions().normalizeDepth,s=C_(e),l={__serialized__:lo(e,o)};if(s)return{exception:{values:[Io(t,s)]},extra:l};let u={exception:{values:[{type:Pn(e)?e.constructor.name:r?"UnhandledRejection":"Error",value:w_(e,{isUnhandledRejection:r})}]},extra:l};if(n){let d=Ya(t,n);d.length&&(u.exception.values[0].stacktrace={frames:d})}return u}function Ga(t,e){return{exception:{values:[Io(t,e)]}}}function Ya(t,e){let n=e.stacktrace||e.stack||"",r=y_(e),i=v_(e);try{return t(n,r,i)}catch{}return[]}var __=/Minified React error #\d+;/i;function y_(t){return t&&__.test(t.message)?1:0}function v_(t){return typeof t.framesToPop=="number"?t.framesToPop:0}function zf(t){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"?t instanceof WebAssembly.Exception:!1}function E_(t){let e=t?.name;return!e&&zf(t)?t.message&&Array.isArray(t.message)&&t.message.length==2?t.message[0]:"WebAssembly.Exception":e}function b_(t){let e=t?.message;return zf(t)?Array.isArray(t.message)&&t.message.length==2?t.message[1]:"wasm exception":e?e.error&&typeof e.error.message=="string"?e.error.message:e:"No error message"}function Xf(t,e,n,r){let i=n?.syntheticException||void 0,o=To(t,e,i,r);return Ut(o),o.level="error",n?.event_id&&(o.event_id=n.event_id),gt(o)}function qf(t,e,n="info",r,i){let o=r?.syntheticException||void 0,s=Wa(t,e,o,i);return s.level=n,r?.event_id&&(s.event_id=r.event_id),gt(s)}function To(t,e,n,r,i){let o;if(Zi(e)&&e.error)return Ga(t,e.error);if(Qi(e)||Ks(e)){let s=e;if("stack"in e)o=Ga(t,e);else{let l=s.name||(Qi(s)?"DOMError":"DOMException"),u=s.message?`${l}: ${s.message}`:l;o=Wa(t,u,n,r),ar(o,u)}return"code"in s&&(o.tags=K(I({},o.tags),{"DOMException.code":`${s.code}`})),o}return Rn(e)?Ga(t,e):tn(e)||Pn(e)?(o=g_(t,e,n,i),Ut(o,{synthetic:!0}),o):(o=Wa(t,e,n,r),ar(o,`${e}`,void 0),Ut(o,{synthetic:!0}),o)}function Wa(t,e,n,r){let i={};if(r&&n){let o=Ya(t,n);o.length&&(i.exception={values:[{value:e,stacktrace:{frames:o}}]}),Ut(i,{synthetic:!0})}if(or(e)){let{__sentry_template_string__:o,__sentry_template_values__:s}=e;return i.logentry={message:o,params:s},i}return i.message=e,i}function w_(t,{isUnhandledRejection:e}){let n=na(t),r=e?"promise rejection":"exception";return Zi(t)?`Event \`ErrorEvent\` captured as ${r} with message \`${t.message}\``:Pn(t)?`Event \`${S_(t)}\` (type=${t.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function S_(t){try{let e=Object.getPrototypeOf(t);return e?e.constructor.name:void 0}catch{}}function C_(t){for(let e in t)if(Object.prototype.hasOwnProperty.call(t,e)){let n=t[e];if(n instanceof Error)return n}}var I_=5e3,ai=class extends ni{constructor(e){let n=T_(e),r=Ce.SENTRY_SDK_SOURCE||Ha();Na(n,"browser",["browser"],r),super(n);let{sendDefaultPii:i,sendClientReports:o,enableLogs:s,_experiments:l}=this._options,u=s??l?.enableLogs;Ce.document&&(o||u)&&Ce.document.addEventListener("visibilitychange",()=>{Ce.document.visibilityState==="hidden"&&(o&&this._flushOutcomes(),u&&ri(this))}),u&&(this.on("flush",()=>{ri(this)}),this.on("afterCaptureLog",()=>{this._logFlushIdleTimeout&&clearTimeout(this._logFlushIdleTimeout),this._logFlushIdleTimeout=setTimeout(()=>{ri(this)},I_)})),i&&(this.on("postprocessEvent",Aa),this.on("beforeSendSession",Da))}eventFromException(e,n){return Xf(this._options.stackParser,e,n,this._options.attachStacktrace)}eventFromMessage(e,n="info",r){return qf(this._options.stackParser,e,n,r,this._options.attachStacktrace)}_prepareEvent(e,n,r,i){return e.platform=e.platform||"javascript",super._prepareEvent(e,n,r,i)}};function T_(t){return I({release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:Ce.SENTRY_RELEASE?.id,sendClientReports:!0,parentSpanIsAlwaysRootSpan:!0},t)}var Kf=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;var Pe=X;var x_=1e3,Jf,za,Xa;function qa(t){ze("dom",t),Xe("dom",O_)}function O_(){if(!Pe.document)return;let t=Ne.bind(null,"dom"),e=Zf(t,!0);Pe.document.addEventListener("click",e,!1),Pe.document.addEventListener("keypress",e,!1),["EventTarget","Node"].forEach(n=>{let i=Pe[n]?.prototype;i?.hasOwnProperty?.("addEventListener")&&(Re(i,"addEventListener",function(o){return function(s,l,u){if(s==="click"||s=="keypress")try{let d=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},_=d[s]=d[s]||{refCount:0};if(!_.handler){let p=Zf(t);_.handler=p,o.call(this,s,p,u)}_.refCount++}catch{}return o.call(this,s,l,u)}}),Re(i,"removeEventListener",function(o){return function(s,l,u){if(s==="click"||s=="keypress")try{let d=this.__sentry_instrumentation_handlers__||{},_=d[s];_&&(_.refCount--,_.refCount<=0&&(o.call(this,s,_.handler,u),_.handler=void 0,delete d[s]),Object.keys(d).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return o.call(this,s,l,u)}}))})}function A_(t){if(t.type!==za)return!1;try{if(!t.target||t.target._sentryId!==Xa)return!1}catch{}return!0}function D_(t,e){return t!=="keypress"?!1:e?.tagName?!(e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.isContentEditable):!0}function Zf(t,e=!1){return n=>{if(!n||n._sentryCaptured)return;let r=N_(n);if(D_(n.type,r))return;it(n,"_sentryCaptured",!0),r&&!r._sentryId&&it(r,"_sentryId",Me());let i=n.type==="keypress"?"input":n.type;A_(n)||(t({event:n,name:i,global:e}),za=n.type,Xa=r?r._sentryId:void 0),clearTimeout(Jf),Jf=Pe.setTimeout(()=>{Xa=void 0,za=void 0},x_)}}function N_(t){try{return t.target}catch{return null}}var xo;function ci(t){let e="history";ze(e,t),Xe(e,R_)}function R_(){if(Pe.addEventListener("popstate",()=>{let e=Pe.location.href,n=xo;if(xo=e,n===e)return;Ne("history",{from:n,to:e})}),!ka())return;function t(e){return function(...n){let r=n.length>2?n[2]:void 0;if(r){let i=xo,o=M_(String(r));if(xo=o,i===o)return e.apply(this,n);Ne("history",{from:i,to:o})}return e.apply(this,n)}}Re(Pe.history,"pushState",t),Re(Pe.history,"replaceState",t)}function M_(t){try{return new URL(t,Pe.location.origin).toString()}catch{return t}}var Oo={};function Ka(t){let e=Oo[t];if(e)return e;let n=Pe[t];if(si(n))return Oo[t]=n.bind(Pe);let r=Pe.document;if(r&&typeof r.createElement=="function")try{let i=r.createElement("iframe");i.hidden=!0,r.head.appendChild(i);let o=i.contentWindow;o?.[t]&&(n=o[t]),r.head.removeChild(i)}catch(i){Kf&&H.warn(`Could not create sandbox iframe for ${t} check, bailing to window.${t}: `,i)}return n&&(Oo[t]=n.bind(Pe))}function Ao(t){Oo[t]=void 0}var kn="__sentry_xhr_v3__";function Ja(t){ze("xhr",t),Xe("xhr",P_)}function P_(){if(!Pe.XMLHttpRequest)return;let t=XMLHttpRequest.prototype;t.open=new Proxy(t.open,{apply(e,n,r){let i=new Error,o=et()*1e3,s=qe(r[0])?r[0].toUpperCase():void 0,l=L_(r[1]);if(!s||!l)return e.apply(n,r);n[kn]={method:s,url:l,request_headers:{}},s==="POST"&&l.match(/sentry_key/)&&(n.__sentry_own_request__=!0);let u=()=>{let d=n[kn];if(d&&n.readyState===4){try{d.status_code=n.status}catch{}let _={endTimestamp:et()*1e3,startTimestamp:o,xhr:n,virtualError:i};Ne("xhr",_)}};return"onreadystatechange"in n&&typeof n.onreadystatechange=="function"?n.onreadystatechange=new Proxy(n.onreadystatechange,{apply(d,_,p){return u(),d.apply(_,p)}}):n.addEventListener("readystatechange",u),n.setRequestHeader=new Proxy(n.setRequestHeader,{apply(d,_,p){let[v,E]=p,T=_[kn];return T&&qe(v)&&qe(E)&&(T.request_headers[v.toLowerCase()]=E),d.apply(_,p)}}),e.apply(n,r)}}),t.send=new Proxy(t.send,{apply(e,n,r){let i=n[kn];if(!i)return e.apply(n,r);r[0]!==void 0&&(i.body=r[0]);let o={startTimestamp:et()*1e3,xhr:n};return Ne("xhr",o),e.apply(n,r)}})}function L_(t){if(qe(t))return t;try{return t.toString()}catch{}}function Za(t,e=Ka("fetch")){let n=0,r=0;function i(o){let s=o.body.length;n+=s,r++;let l=I({body:o.body,method:"POST",referrerPolicy:"strict-origin",headers:t.headers,keepalive:n<=6e4&&r<15},t.fetchOptions);if(!e)return Ao("fetch"),vn("No fetch implementation available");try{return e(t.url,l).then(u=>(n-=s,r--,{statusCode:u.status,headers:{"x-sentry-rate-limits":u.headers.get("X-Sentry-Rate-Limits"),"retry-after":u.headers.get("Retry-After")}}))}catch(u){return Ao("fetch"),n-=s,r--,vn(u)}}return vo(t,i)}var F_=30;var k_=50;function Qa(t,e,n,r){let i={filename:t,function:e==="<anonymous>"?"?":e,in_app:!0};return n!==void 0&&(i.lineno=n),r!==void 0&&(i.colno=r),i}var B_=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,V_=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,U_=/\((\S*)(?::(\d+))(?::(\d+))\)/,H_=t=>{let e=B_.exec(t);if(e){let[,r,i,o]=e;return Qa(r,"?",+i,+o)}let n=V_.exec(t);if(n){if(n[2]&&n[2].indexOf("eval")===0){let s=U_.exec(n[2]);s&&(n[2]=s[1],n[3]=s[2],n[4]=s[3])}let[i,o]=nd(n[1]||"?",n[2]);return Qa(o,i,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}},Qf=[F_,H_],j_=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,$_=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,G_=t=>{let e=j_.exec(t);if(e){if(e[3]&&e[3].indexOf(" > eval")>-1){let o=$_.exec(e[3]);o&&(e[1]=e[1]||"eval",e[3]=o[1],e[4]=o[2],e[5]="")}let r=e[3],i=e[1]||"?";return[i,r]=nd(i,r),Qa(r,i,e[4]?+e[4]:void 0,e[5]?+e[5]:void 0)}},ed=[k_,G_];var td=[Qf,ed],ec=Ws(...td),nd=(t,e)=>{let n=t.indexOf("safari-extension")!==-1,r=t.indexOf("safari-web-extension")!==-1;return n||r?[t.indexOf("@")!==-1?t.split("@")[0]:"?",n?`safari-extension:${e}`:`safari-web-extension:${e}`]:[t,e]};var fr=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;var Do=1024,W_="Breadcrumbs",Y_=(t={})=>{let e=I({console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0},t);return{name:W_,setup(n){e.console&&La(q_(n)),e.dom&&qa(X_(n,e.dom)),e.xhr&&Ja(K_(n)),e.fetch&&Ua(J_(n)),e.history&&ci(Z_(n)),e.sentry&&n.on("beforeSendEvent",z_(n))}}},rd=Y_;function z_(t){return function(n){ye()===t&&Gt({category:`sentry.${n.type==="transaction"?"transaction":"event"}`,event_id:n.event_id,level:n.level,message:Vt(n)},{event:n})}}function X_(t,e){return function(r){if(ye()!==t)return;let i,o,s=typeof e=="object"?e.serializeAttribute:void 0,l=typeof e=="object"&&typeof e.maxStringLength=="number"?e.maxStringLength:void 0;l&&l>Do&&(fr&&H.warn(`\`dom.maxStringLength\` cannot exceed ${Do}, but a value of ${l} was configured. Sentry will use ${Do} instead.`),l=Do),typeof s=="string"&&(s=[s]);try{let d=r.event,_=Q_(d)?d.target:d;i=qr(_,{keyAttrs:s,maxStringLength:l}),o=ta(_)}catch{i="<unknown>"}if(i.length===0)return;let u={category:`ui.${r.name}`,message:i};o&&(u.data={"ui.component_name":o}),Gt(u,{event:r.event,name:r.name,global:r.global})}}function q_(t){return function(n){if(ye()!==t)return;let r={category:"console",data:{arguments:n.args,logger:"console"},level:Fa(n.level),message:eo(n.args," ")};if(n.level==="assert")if(n.args[0]===!1)r.message=`Assertion failed: ${eo(n.args.slice(1)," ")||"console.assert"}`,r.data.arguments=n.args.slice(1);else return;Gt(r,{input:n.args,level:n.level})}}function K_(t){return function(n){if(ye()!==t)return;let{startTimestamp:r,endTimestamp:i}=n,o=n.xhr[kn];if(!r||!i||!o)return;let{method:s,url:l,status_code:u,body:d}=o,_={method:s,url:l,status_code:u},p={xhr:n.xhr,input:d,startTimestamp:r,endTimestamp:i},v={category:"xhr",data:_,type:"http",level:Co(u)};t.emit("beforeOutgoingRequestBreadcrumb",v,p),Gt(v,p)}}function J_(t){return function(n){if(ye()!==t)return;let{startTimestamp:r,endTimestamp:i}=n;if(i&&!(n.fetchData.url.match(/sentry_key/)&&n.fetchData.method==="POST"))if(n.fetchData.method,n.fetchData.url,n.error){let o=n.fetchData,s={data:n.error,input:n.args,startTimestamp:r,endTimestamp:i},l={category:"fetch",data:o,level:"error",type:"http"};t.emit("beforeOutgoingRequestBreadcrumb",l,s),Gt(l,s)}else{let o=n.response,s=K(I({},n.fetchData),{status_code:o?.status});n.fetchData.request_body_size,n.fetchData.response_body_size,o?.status;let l={input:n.args,response:o,startTimestamp:r,endTimestamp:i},u={category:"fetch",data:s,type:"http",level:Co(s.status_code)};t.emit("beforeOutgoingRequestBreadcrumb",u,l),Gt(u,l)}}}function Z_(t){return function(n){if(ye()!==t)return;let r=n.from,i=n.to,o=ii(Ce.location.href),s=r?ii(r):void 0,l=ii(i);s?.path||(s=o),o.protocol===l.protocol&&o.host===l.host&&(i=l.relative),o.protocol===s.protocol&&o.host===s.host&&(r=s.relative),Gt({category:"navigation",data:{from:r,to:i}})}}function Q_(t){return!!t&&!!t.target}var ey=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],ty="BrowserApiErrors",ny=(t={})=>{let e=I({XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,unregisterOriginalCallbacks:!1},t);return{name:ty,setupOnce(){e.setTimeout&&Re(Ce,"setTimeout",id),e.setInterval&&Re(Ce,"setInterval",id),e.requestAnimationFrame&&Re(Ce,"requestAnimationFrame",ry),e.XMLHttpRequest&&"XMLHttpRequest"in Ce&&Re(XMLHttpRequest.prototype,"send",iy);let n=e.eventTarget;n&&(Array.isArray(n)?n:ey).forEach(i=>oy(i,e))}}},od=ny;function id(t){return function(...e){let n=e[0];return e[0]=Fn(n,{mechanism:{data:{function:ht(t)},handled:!1,type:"instrument"}}),t.apply(this,e)}}function ry(t){return function(e){return t.apply(this,[Fn(e,{mechanism:{data:{function:"requestAnimationFrame",handler:ht(t)},handled:!1,type:"instrument"}})])}}function iy(t){return function(...e){let n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(i=>{i in n&&typeof n[i]=="function"&&Re(n,i,function(o){let s={mechanism:{data:{function:i,handler:ht(o)},handled:!1,type:"instrument"}},l=Ln(o);return l&&(s.mechanism.data.handler=ht(l)),Fn(o,s)})}),t.apply(this,e)}}function oy(t,e){let r=Ce[t]?.prototype;r?.hasOwnProperty?.("addEventListener")&&(Re(r,"addEventListener",function(i){return function(o,s,l){try{sy(s)&&(s.handleEvent=Fn(s.handleEvent,{mechanism:{data:{function:"handleEvent",handler:ht(s),target:t},handled:!1,type:"instrument"}}))}catch{}return e.unregisterOriginalCallbacks&&ay(this,o,s),i.apply(this,[o,Fn(s,{mechanism:{data:{function:"addEventListener",handler:ht(s),target:t},handled:!1,type:"instrument"}}),l])}}),Re(r,"removeEventListener",function(i){return function(o,s,l){try{let u=s.__sentry_wrapped__;u&&i.call(this,o,u,l)}catch{}return i.call(this,o,s,l)}}))}function sy(t){return typeof t.handleEvent=="function"}function ay(t,e,n){t&&typeof t=="object"&&"removeEventListener"in t&&typeof t.removeEventListener=="function"&&t.removeEventListener(e,n)}var sd=()=>({name:"BrowserSession",setupOnce(){if(typeof Ce.document>"u"){fr&&H.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}ei({ignoreDuration:!0}),ti(),ci(({from:t,to:e})=>{t!==void 0&&t!==e&&(ei({ignoreDuration:!0}),ti())})}});var cy="GlobalHandlers",ly=(t={})=>{let e=I({onerror:!0,onunhandledrejection:!0},t);return{name:cy,setupOnce(){Error.stackTraceLimit=50},setup(n){e.onerror&&(uy(n),ad("onerror")),e.onunhandledrejection&&(fy(n),ad("onunhandledrejection"))}}},cd=ly;function uy(t){zs(e=>{let{stackParser:n,attachStacktrace:r}=ld();if(ye()!==t||$a())return;let{msg:i,url:o,line:s,column:l,error:u}=e,d=hy(To(n,u||i,void 0,r,!1),o,s,l);d.level="error",Qr(d,{originalException:u,mechanism:{handled:!1,type:"onerror"}})})}function fy(t){qs(e=>{let{stackParser:n,attachStacktrace:r}=ld();if(ye()!==t||$a())return;let i=dy(e),o=Mn(i)?py(i):To(n,i,void 0,r,!0);o.level="error",Qr(o,{originalException:i,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function dy(t){if(Mn(t))return t;try{if("reason"in t)return t.reason;if("detail"in t&&"reason"in t.detail)return t.detail.reason}catch{}return t}function py(t){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(t)}`}]}}}function hy(t,e,n,r){let i=t.exception=t.exception||{},o=i.values=i.values||[],s=o[0]=o[0]||{},l=s.stacktrace=s.stacktrace||{},u=l.frames=l.frames||[],d=r,_=n,p=qe(e)&&e.length>0?e:Kr();return u.length===0&&u.push({colno:d,filename:p,function:"?",in_app:!0,lineno:_}),t}function ad(t){fr&&H.log(`Global Handler attached: ${t}`)}function ld(){return ye()?.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}var ud=()=>({name:"HttpContext",preprocessEvent(t){if(!Ce.navigator&&!Ce.location&&!Ce.document)return;let e=Yf(),n=I(I({},e.headers),t.request?.headers);t.request=K(I(I({},e),t.request),{headers:n})}});var my="cause",gy=5,_y="LinkedErrors",yy=(t={})=>{let e=t.limit||gy,n=t.key||my;return{name:_y,preprocessEvent(r,i,o){let s=o.getOptions();Pa(Io,s.stackParser,n,e,r,i)}}},fd=yy;function tc(t){return[wo(),Eo(),od(),rd(),cd(),fd(),So(),ud(),sd()]}var dd={},pd,nc,vy;(()=>{let t=tc({}).filter(e=>!["BrowserApiErrors","Breadcrumbs","GlobalHandlers"].includes(e.name));nc=new ai({dsn:"https://1bc3dda4c861f60cd6be1b67584f4bc6@o559187.ingest.us.sentry.io/4507626484203520",transport:Za,stackParser:ec,integrations:t,environment:Lt.mode,release:`web-sdk@${Yn}`,debug:Lt.debug}),nc.init()})();function hd(t,e,n){Te.error(`${e}:`,t);let r=wy(n);if(r.setTag("operation",e),t instanceof Yr){Ey(r,t,e);return}r.captureException(t)}function Ey(t,e,n){if(by(t,e),e.response){let r=e.response;t.setTag("http.status_code",r.status),t.setExtras({responseText:e.responseText,statusText:r.statusText,responseType:r.type,redirected:r.redirected,responseUrl:r.url}),t.captureMessage(`${n} failed with ${r.status}`,"error");return}if(e.request){t.captureMessage(`No response was received for ${n}`,"error");return}}function by(t,e){let n=e.request;n&&t.setExtras({body:e.requestBody,headers:n.headers,method:n.method,url:n.url})}function wy(t){t??={};let{extra:e,tags:n}=t,r=new je;if(r.setClient(nc),r.setUser(vy),t.triggerContext&&!t.engagementTrigger&&(t.engagementTrigger=t.triggerContext.triggerData),t.engagementTrigger){let i=t.engagementTrigger;r.setTags({"engagement.id":i.engagementID,"engagement.short_id":i.shortID,"engagement.objective":i.objective,"engagement.delivery_type":i.onsiteDeliveryType,"engagement.content_id":i.contentID,"engagement.variation":i.variation,"engagement.currency":i.currency})}return e&&r.setExtras(e),n&&r.setTags(n),pd&&r.setTags(pd),Object.keys(dd).forEach(i=>{r.setContext(i,dd[i])}),r.setTag("language",navigator.language),r.setTag("timezone",md()),Sy(r),r}function Sy(t){window.Shopify&&(t.setTag("shopify.shop",window.Shopify.shop),t.setTag("shopify.currency",window.Shopify.currency?.active),t.setTag("shopify.locale",window.Shopify.locale),t.setTag("theme.schema_name",window.Shopify.theme?.schema_name),t.setTag("theme.schema_version",window.Shopify.theme?.schema_version))}var Ro=class{static format(e,n){let r=/{{\s*(\w+)\s*}}/;return n.replace(r,(i,o)=>{switch(o){case"amount":return this.formatWithDelimiters(e,2);case"amount_no_decimals":return this.formatWithDelimiters(e,0);case"amount_with_comma_separator":return this.formatWithDelimiters(e,2,".",",");case"amount_no_decimals_with_comma_separator":return this.formatWithDelimiters(e,0,".",",");case"amount_with_apostrophe_separator":return this.formatWithDelimiters(e,2,"'",".");case"amount_no_decimals_with_space_separator":return this.formatWithDelimiters(e,0," ");case"amount_with_space_separator":return this.formatWithDelimiters(e,2," ",",");case"amount_with_period_and_space_separator":return this.formatWithDelimiters(e,2," ",".");default:return i}})}static formatWithDelimiters(e,n=2,r=",",i="."){if(isNaN(e)||e==null)return"0";let s=(e/100).toFixed(n).split("."),l=s[0].replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1"+r),u=s[1]?i+s[1]:"";return l+u}};var li=class{id;mID;vID;vName;imageURL;name;link;quantity;price;finalPrice;constructor(e){this.id=e.id,this.mID=e.mID,this.vID=e.vID,this.vName=e.vName,this.imageURL=e.imageURL,this.name=e.name,this.link=e.link,this.quantity=e.quantity,this.price=e.price,this.finalPrice=e.finalPrice??e.price}};function gd(t){let e=new Date(Date.UTC(0,0,0,0,0,0,t)),n=[];return e.getUTCMinutes()&&n.push(e.getUTCMinutes()+"m"),e.getUTCSeconds()&&n.push(e.getUTCSeconds()+"s"),e.getUTCMilliseconds()&&n.push(e.getUTCMilliseconds()+"ms"),n.length||n.push("0ms"),n.join(" ")}var Mo=class{constructor(e){this.sdkLoadTime=e}isCartDirty=!0;cartEngagements;isGoKwikPopupOpen;previewIDs;previewVariant;pageName;moneyFormat;jsLoadTime=new Date;shopCurrencyCode;locale;customContext={};activeExperiments;currentItem;inInactive=!1;lastEnterActive=new Date;lastEnterInactive=null;_currencyCode;get currencyCode(){return this._currencyCode}set currencyCode(e){this._currencyCode=e}static get(){return window.CooeeSDK.runtimeData}isInactive(){return this.inInactive}async setInactive(){return this.inInactive?0:(this.inInactive=!0,this.lastEnterInactive=new Date,Math.max((this.lastEnterInactive.getTime()-this.lastEnterActive.getTime())/1e3,0))}setActive(){return this.inInactive?(this.inInactive=!1,this.lastEnterActive=new Date,Math.max((this.lastEnterActive.getTime()-this.lastEnterInactive.getTime())/1e3,0)):0}isFirstActive(){return this.lastEnterInactive==null}getCurrentItem(){return this.currentItem}setCurrentItem(e){if(this.currentItem&&this.currentItem.vID!==e.vID){let n=new CustomEvent("letscooee:variant-change",{detail:{variantID:e.vID}});document.dispatchEvent(n)}this.currentItem=new li(e)}getSDKLoadTimeDiff(){return gd(Date.now()-this.sdkLoadTime.getTime())}};function Cy(t,e,n){return{[t]:rc(e,n),[t+"_wo_currency"]:e}}function rc(t,e){if(t==0&&e)return"Free";let n=Mo.get(),r=dn.get(),i=n.shopCurrencyCode||r.currency,o=n.currencyCode;o||Te.warn("Currency code is not set in RuntimeData");let s=r.money?.format??n.moneyFormat,l;if(s&&i===o)l=Ro.format(t*100,s);else{let u;try{u=new Intl.NumberFormat(Iy(),{style:"currency",currency:o||i,minimumFractionDigits:0,maximumFractionDigits:2})}catch(d){return hd(d,"format-currency",{extra:{currentCurrency:o,shopCurrency:i}}),""}l=u.format(t),l=l.replace("\u20B9","Rs. "),r.money?.showCurrency&&o!=="INR"&&(l=l.concat(` ${o}`))}return l}function Iy(){return navigator.languages!==void 0?navigator.languages[0].split("-")[0]:navigator.language??"en"}var Po;function md(){if(Po)return Po;try{return Po=Intl.DateTimeFormat().resolvedOptions().timeZone,Po}catch{return""}}var dr=class t{transform(e){return e==null?null:rc(e)}static \u0275fac=function(n){return new(n||t)};static \u0275pipe=Wc({name:"cooeeCurrency",type:t,pure:!0})};var Ty=t=>({active:t}),xy=(t,e)=>e.url,Oy=(t,e)=>e.mID;function Ay(t,e){t&1&&zt(0)}function Dy(t,e){t&1&&zt(0)}function Ny(t,e){t&1&&zt(0)}function Ry(t,e){t&1&&zt(0)}function My(t,e){if(t&1&&(ce(0,"div",4)(1,"div",6)(2,"div",7),we(3,"Shop Now"),ue(),Ot(4,Ay,1,0,"ng-container",8),ue(),ce(5,"div",9),Ot(6,Dy,1,0,"ng-container",8),ce(7,"div",10),Ot(8,Ny,1,0,"ng-container",8),ue()(),ce(9,"div",11),Ot(10,Ry,1,0,"ng-container",8),ue()()),t&2){ne();let n=Xt(4),r=Xt(6),i=Xt(8),o=Xt(10);$(4),De("ngTemplateOutlet",n),$(2),De("ngTemplateOutlet",r),$(2),De("ngTemplateOutlet",i),$(2),De("ngTemplateOutlet",o)}}function Py(t,e){t&1&&zt(0)}function Ly(t,e){t&1&&zt(0)}function Fy(t,e){t&1&&zt(0)}function ky(t,e){t&1&&zt(0)}function By(t,e){if(t&1&&(ce(0,"div",5)(1,"div",12),Ot(2,Py,1,0,"ng-container",8),ue(),ce(3,"div",13),Ot(4,Ly,1,0,"ng-container",8)(5,Fy,1,0,"ng-container",8)(6,ky,1,0,"ng-container",8),ue()()),t&2){ne();let n=Xt(4),r=Xt(6),i=Xt(8),o=Xt(10);$(2),De("ngTemplateOutlet",r),$(2),De("ngTemplateOutlet",n),$(),De("ngTemplateOutlet",i),$(),De("ngTemplateOutlet",o)}}function Vy(t,e){if(t&1){let n=Dt();ce(0,"button",14),bt("click",function(){tt(n);let i=ne();return nt(i.close())}),ft(1,"cooee-icon",15),ue()}}function Uy(t,e){if(t&1&&ft(0,"img",17),t&2){let n=e.$implicit,r=ne(2);De("src",n.url,cn)("alt",r.item().name)}}function Hy(t,e){if(t&1&&(ce(0,"div",16),$n(1,Uy,1,2,"img",17,xy),ue()),t&2){let n=ne();$(),Gn(n.item().imgs)}}function jy(t,e){if(t&1&&(ft(0,"span",20),wt(1,"cooeeCurrency"),wt(2,"safeHtml")),t&2){ne(2);let n=Qe(2);De("innerHTML",St(2,3,St(1,1,n.d)),Wt)}}function $y(t,e){if(t&1&&(ft(0,"span",21),wt(1,"cooeeCurrency"),wt(2,"safeHtml")),t&2){ne(2);let n=Qe(2);De("innerHTML",St(2,3,St(1,1,n.cmp)),Wt)}}function Gy(t,e){if(t&1&&(ce(0,"div",19),Ee(1,jy,3,5,"span",20),Ee(2,$y,3,5,"span",21),ue()),t&2){ne();let n=Qe(2);$(),be(n.d?1:-1),$(),be(n.cmp?2:-1)}}function Wy(t,e){if(t&1){let n=Dt();ce(0,"a",25),bt("click",function(i){let o=tt(n).$implicit,s=ne(3);return nt(s.changeItem(i,o))}),ft(1,"img",17),ue()}if(t&2){let n=e.$implicit,r=ne(3);De("ngClass",Si(3,Ty,n.mID===r.item().mID+"")),$(),De("src",n.firstImageURL,cn)("alt",r.item().name)}}function Yy(t,e){if(t&1&&(ce(0,"span",22),we(1,"Select product"),ue(),ce(2,"div",23),$n(3,Wy,2,5,"a",24,Oy),ue()),t&2){let n=ne(2);$(3),Gn(n.similarItems())}}function zy(t,e){if(t&1&&(ce(0,"span",26),we(1,"Select variant"),ue(),ft(2,"cooee-item-options-picker",27)),t&2){let n=ne(2);$(2),De("item",n.item())}}function Xy(t,e){if(t&1&&(ce(0,"div",28),we(1,"Description"),ue(),ft(2,"div",29),wt(3,"safeHtml")),t&2){let n=ne(2);$(2),De("innerHTML",St(3,1,n.item().desc),Wt)}}function qy(t,e){if(t&1&&(ce(0,"div",18),we(1),ue(),Rt(2),Ee(3,Gy,3,2,"div",19),Ee(4,Yy,5,0),Ee(5,zy,3,1),Ee(6,Xy,4,3)),t&2){let n=ne(),r=Qe(0);$(),un(n.item().name),$();let i=Mt(r.price);$(),be(i?3:-1),$(),be(n.similarItems().length>1?4:-1),$(),be(n.item().hasVariants()?5:-1),$(),be(n.item().desc?6:-1)}}function Ky(t,e){t&1&&we(0," Add To Cart ")}function Jy(t,e){t&1&&we(0," Out of stock ")}function Zy(t,e){if(t&1){let n=Dt();ce(0,"div",30)(1,"button",31),bt("click",function(){tt(n);let i=ne();return nt(i.clickAddToCart())}),Ee(2,Ky,1,0)(3,Jy,1,0),ue(),ce(4,"button",32),bt("click",function(){tt(n);let i=ne();return nt(i.goToPDP())}),we(5," More Info "),ue(),ce(6,"button",33),bt("click",function(){tt(n);let i=ne();return nt(i.openCart())}),ft(7,"img",34),ue()()}if(t&2){ne();let n=Qe(0);$(),De("disabled",!n.isAvailable),$(),be(n.isAvailable?2:3)}}var _d=class t{closeClick=new vt;layout=Nr("SINGLE_PANE");item=Nr.required();similarItems=Ge([]);engagementService=U(hn);lastLayout=null;resizeObserver=new tr(()=>{ks()?(this.lastLayout===null&&(this.lastLayout=this.layout()),this.layout.set("SINGLE_PANE")):this.lastLayout!==null&&(this.layout.set(this.lastLayout),this.lastLayout=null)});ngOnDestroy(){this.resizeObserver.destroy()}close(){this.closeClick.emit()}clickAddToCart(){this.engagementService.executeCTA(Zt.ADD_TO_CART,{item:this.item()})}openCart(){this.engagementService.executeCTA(Zt.OPEN_CART)}changeItem(e,n){e.stopPropagation(),e.preventDefault(),this.item.set(n)}goToPDP(){this.engagementService.executeCTA(Zt.GO_TO_PRODUCT,{item:this.item()})}isSinglePane(){return this.layout()!=="TWO_PANE"||ks()}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=ve({type:t,selectors:[["cooee-item-detail"]],hostAttrs:[1,"letscooee-widget"],inputs:{layout:[1,"layout"],item:[1,"item"],similarItems:[1,"similarItems"]},outputs:{closeClick:"closeClick",layout:"layoutChange",item:"itemChange"},features:[wi([hn])],decls:11,vars:2,consts:[["closeButtonTemplate",""],["imageStripTemplate",""],["bodyTemplate",""],["footerButtonsTemplate",""],[1,"lc-card-wrapper","card-wrapper","single-pane"],[1,"card-wrapper","two-pane"],[1,"lc-card-header","card-header"],[1,"lc-header","header"],[4,"ngTemplateOutlet"],[1,"card-content"],[1,"lc-inner-body","inner-body"],[1,"lc-card-footer","card-footer"],[1,"images-container"],[1,"inner-body"],["type","button","aria-label","Close product details",1,"lc-close-button","close-button",3,"click"],["name","close","aria-hidden","true"],[1,"image-strip"],[3,"src","alt"],[1,"lc-item-name","item-name"],[1,"lc-prices","prices"],[1,"lc-item-price","item-price",3,"innerHTML"],[1,"lc-item-cmp-price","item-cmp-price",3,"innerHTML"],[1,"lc-selected-product-title","selected-product-title"],[1,"lc-image-strip","image-strip"],["href","#",1,"product-selector",3,"ngClass"],["href","#",1,"product-selector",3,"click","ngClass"],[1,"selected-variant-title"],[3,"item"],[1,"lc-description-title","description-title"],[1,"lc-description","description",3,"innerHTML"],[1,"footer-buttons"],["type","button",1,"lc-cta-button","cta-button",3,"click","disabled"],["type","button",1,"lc-more-info-button","more-info-button",3,"click"],["type","button","aria-label","View Cart","title","View Cart",1,"view-cart-button",3,"click"],["width","32","height","32","src","https://img.icons8.com/material-sharp/48/shopping-cart.png","alt","shopping-cart"]],template:function(n,r){n&1&&(Rt(0),Ee(1,My,11,4,"div",4)(2,By,7,4,"div",5),Ot(3,Vy,2,0,"ng-template",null,0,Dr)(5,Hy,3,0,"ng-template",null,1,Dr)(7,qy,7,6,"ng-template",null,2,Dr)(9,Zy,8,2,"ng-template",null,3,Dr)),n&2&&(Mt(r.item().selectedOrFirstVariant.value),$(),be(r.isSinglePane()?1:2))},dependencies:[il,$i,nr,sl,Ii,dr],styles:["[_nghost-%COMP%]{display:block;background:#fff}.card-wrapper[_ngcontent-%COMP%]{position:relative}.card-wrapper.single-pane[_ngcontent-%COMP%]{display:flex;flex-direction:column;height:100%;overflow:auto}.card-wrapper.two-pane[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr}.card-header[_ngcontent-%COMP%]{display:var(--header-display, flex);flex-direction:row;justify-content:space-between;align-items:center;padding:8px 16px;border-bottom:1px solid var(--lc-color-gray-300)}.header[_ngcontent-%COMP%]{font-size:24px;font-weight:var(--lc-subheading-weight);color:rgba(var(--lc-subheading-color))}.close-button[_ngcontent-%COMP%]{background:transparent;border:none;width:36px;height:36px}.close-button[_ngcontent-%COMP%] cooee-icon[_ngcontent-%COMP%]{color:#000000b3}.two-pane[_ngcontent-%COMP%] .close-button[_ngcontent-%COMP%]{position:absolute;top:8px;right:4px}.card-content[_ngcontent-%COMP%]{flex:1;overflow-y:auto;overscroll-behavior:contain}.inner-body[_ngcontent-%COMP%]{padding:16px;display:flex;flex-direction:column;gap:8px}.images-container[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:start}.image-strip[_ngcontent-%COMP%]{width:100%;display:flex;overflow-x:auto;gap:8px;flex-wrap:nowrap}.image-strip[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{width:auto;height:200px}.two-pane[_ngcontent-%COMP%] .image-strip[_ngcontent-%COMP%]{padding:16px}.product-selector[_ngcontent-%COMP%]{height:100px;flex-shrink:0;border-radius:var(--lc-media-radius);padding:2px}.product-selector.active[_ngcontent-%COMP%]{border:1px solid rgba(var(--lc-primary-color))}.product-selector[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-height:100%;border-radius:var(--lc-media-radius)}.description-title[_ngcontent-%COMP%], .selected-product-title[_ngcontent-%COMP%], .selected-variant-title[_ngcontent-%COMP%]{font-size:var(--lc-subheading-size);font-weight:var(--lc-subheading-weight);color:rgba(var(--lc-subheading-color));margin-top:8px;line-height:normal}.description[_ngcontent-%COMP%]{line-height:normal;color:#000;font-size:var(--lc-description-size);font-weight:var(--lc-description-weight)}.card-footer[_ngcontent-%COMP%]{padding:var(--lc-item-detail-footer-padding);background-color:rgba(var(--lc-item-detail-footer-bg-color));box-shadow:var(--lc-item-detail-footer-box-shadow)}.footer-buttons[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center;gap:12px}.two-pane[_ngcontent-%COMP%] .footer-buttons[_ngcontent-%COMP%]{margin-top:16px}.cta-button[_ngcontent-%COMP%], .more-info-button[_ngcontent-%COMP%]{width:50%;padding:12px;display:flex;justify-content:center;align-items:center}.more-info-button[_ngcontent-%COMP%]{background-color:rgba(var(--lc-secondary-button-bg-color));color:rgba(var(--lc-secondary-button-color));font-weight:var(--lc-secondary-button-weight);text-transform:var(--lc-secondary-button-transform);border-radius:var(--lc-button-radius);font-size:var(--lc-button-size);font-family:var(--lc-button-family),serif;height:var(--lc-button-height);letter-spacing:var(--lc-button-letter-spacing);transition:filter .12s ease,background-color .2s ease,color .2s ease;border-width:1px;border-style:solid;border-color:rgba(var(--lc-secondary-button-border-color));display:flex;align-items:center;justify-content:center}.more-info-button[_ngcontent-%COMP%]:hover{filter:brightness(.95)}.more-info-button[_ngcontent-%COMP%]:active{filter:brightness(.9)}.more-info-button[_ngcontent-%COMP%]:focus-visible{outline:2px solid rgba(var(--lc-primary-color, 0, 0, 0));outline-offset:2px}"]})};var ui="a-f\\d",Qy=`#?[${ui}]{3}[${ui}]?`,ev=`#?[${ui}]{6}([${ui}]{2})?`,tv=new RegExp(`[^#${ui}]`,"gi"),nv=new RegExp(`^${Qy}$|^${ev}$`,"i");function ic(t,e={}){if(typeof t!="string"||tv.test(t)||!nv.test(t))throw new TypeError("Expected a valid hex string");t=t.replace(/^#/,"");let n=1;t.length===8&&(n=Number.parseInt(t.slice(6,8),16)/255,t=t.slice(0,6)),t.length===4&&(n=Number.parseInt(t.slice(3,4).repeat(2),16)/255,t=t.slice(0,3)),t.length===3&&(t=t[0]+t[0]+t[1]+t[1]+t[2]+t[2]);let r=Number.parseInt(t,16),i=r>>16,o=r>>8&255,s=r&255,l=typeof e.alpha=="number"?e.alpha:n;if(e.format==="array")return[i,o,s,l];if(e.format==="css"){let u=l===1?"":` / ${Number((l*100).toFixed(2))}%`;return`rgb(${i} ${o} ${s}${u})`}return{red:i,green:o,blue:s,alpha:l}}var _t=class{h;a=100;g;constructor(e){e??={},this.h=e.h,this.a=e.a,this.g=e.g}get hex(){return this.h}get grad(){return this.g}get rgba(){if(!this.hex)return"";try{return ic(this.hex,{format:"css",alpha:this.getAlpha()})}catch(e){return console.error("Invalid hex",e),"#000000"}}getAlpha(){return(this.a??100)/100}};var Lo=class t{static DEFAULT_FALLBACK=new _t({h:"#000000",a:50});r;c;fb;constructor(e){this.r=e.r,e.c&&(this.c=new _t(e.c)),e.fb&&(this.fb=new _t(e.fb))}get radius(){return this.r}get color(){return this.c}get fallback(){return this.fb??t.DEFAULT_FALLBACK}};var yd=class{size;enabled;color;constructor(e){e??={},this.enabled=e.enabled,this.size=e.size,this.color=new _t(e.color)}};var Sd,fe,Cd,lc,Bn,vd,Id,Td,xd,uc,sc,ac,rv,cc={},Od=[],iv=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,Bo=Array.isArray;function sn(t,e){for(var n in e)t[n]=e[n];return t}function fc(t){t&&t.parentNode&&t.parentNode.removeChild(t)}function oc(t,e,n,r,i){var o={type:t,props:e,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:i??++Cd,__i:-1,__u:0};return i==null&&fe.vnode!=null&&fe.vnode(o),o}function dc(t){return t.children}function pr(t,e){this.props=t,this.context=e}function hr(t,e){if(e==null)return t.__?hr(t.__,t.__i+1):null;for(var n;e<t.__k.length;e++)if((n=t.__k[e])!=null&&n.__e!=null)return n.__e;return typeof t.type=="function"?hr(t):null}function Ad(t){var e,n;if((t=t.__)!=null&&t.__c!=null){for(t.__e=t.__c.base=null,e=0;e<t.__k.length;e++)if((n=t.__k[e])!=null&&n.__e!=null){t.__e=t.__c.base=n.__e;break}return Ad(t)}}function Ed(t){(!t.__d&&(t.__d=!0)&&Bn.push(t)&&!ko.__r++||vd!=fe.debounceRendering)&&((vd=fe.debounceRendering)||Id)(ko)}function ko(){for(var t,e,n,r,i,o,s,l=1;Bn.length;)Bn.length>l&&Bn.sort(Td),t=Bn.shift(),l=Bn.length,t.__d&&(n=void 0,i=(r=(e=t).__v).__e,o=[],s=[],e.__P&&((n=sn({},r)).__v=r.__v+1,fe.vnode&&fe.vnode(n),Rd(e.__P,n,r,e.__n,e.__P.namespaceURI,32&r.__u?[i]:null,o,i??hr(r),!!(32&r.__u),s),n.__v=r.__v,n.__.__k[n.__i]=n,av(o,n,s),n.__e!=i&&Ad(n)));ko.__r=0}function Dd(t,e,n,r,i,o,s,l,u,d,_){var p,v,E,T,N,F,B=r&&r.__k||Od,k=e.length;for(u=ov(n,e,B,u,k),p=0;p<k;p++)(E=n.__k[p])!=null&&(v=E.__i==-1?cc:B[E.__i]||cc,E.__i=p,F=Rd(t,E,v,i,o,s,l,u,d,_),T=E.__e,E.ref&&v.ref!=E.ref&&(v.ref&&pc(v.ref,null,E),_.push(E.ref,E.__c||T,E)),N==null&&T!=null&&(N=T),4&E.__u||v.__k===E.__k?u=Nd(E,u,t):typeof E.type=="function"&&F!==void 0?u=F:T&&(u=T.nextSibling),E.__u&=-7);return n.__e=N,u}function ov(t,e,n,r,i){var o,s,l,u,d,_=n.length,p=_,v=0;for(t.__k=new Array(i),o=0;o<i;o++)(s=e[o])!=null&&typeof s!="boolean"&&typeof s!="function"?(u=o+v,(s=t.__k[o]=typeof s=="string"||typeof s=="number"||typeof s=="bigint"||s.constructor==String?oc(null,s,null,null,null):Bo(s)?oc(dc,{children:s},null,null,null):s.constructor==null&&s.__b>0?oc(s.type,s.props,s.key,s.ref?s.ref:null,s.__v):s).__=t,s.__b=t.__b+1,l=null,(d=s.__i=sv(s,n,u,p))!=-1&&(p--,(l=n[d])&&(l.__u|=2)),l==null||l.__v==null?(d==-1&&(i>_?v--:i<_&&v++),typeof s.type!="function"&&(s.__u|=4)):d!=u&&(d==u-1?v--:d==u+1?v++:(d>u?v--:v++,s.__u|=4))):t.__k[o]=null;if(p)for(o=0;o<_;o++)(l=n[o])!=null&&(2&l.__u)==0&&(l.__e==r&&(r=hr(l)),Pd(l,l));return r}function Nd(t,e,n){var r,i;if(typeof t.type=="function"){for(r=t.__k,i=0;r&&i<r.length;i++)r[i]&&(r[i].__=t,e=Nd(r[i],e,n));return e}t.__e!=e&&(e&&t.type&&!n.contains(e)&&(e=hr(t)),n.insertBefore(t.__e,e||null),e=t.__e);do e=e&&e.nextSibling;while(e!=null&&e.nodeType==8);return e}function sv(t,e,n,r){var i,o,s=t.key,l=t.type,u=e[n];if(u===null&&t.key==null||u&&s==u.key&&l==u.type&&(2&u.__u)==0)return n;if(r>(u!=null&&(2&u.__u)==0?1:0))for(i=n-1,o=n+1;i>=0||o<e.length;){if(i>=0){if((u=e[i])&&(2&u.__u)==0&&s==u.key&&l==u.type)return i;i--}if(o<e.length){if((u=e[o])&&(2&u.__u)==0&&s==u.key&&l==u.type)return o;o++}}return-1}function bd(t,e,n){e[0]=="-"?t.setProperty(e,n??""):t[e]=n==null?"":typeof n!="number"||iv.test(e)?n:n+"px"}function Fo(t,e,n,r,i){var o,s;e:if(e=="style")if(typeof n=="string")t.style.cssText=n;else{if(typeof r=="string"&&(t.style.cssText=r=""),r)for(e in r)n&&e in n||bd(t.style,e,"");if(n)for(e in n)r&&n[e]==r[e]||bd(t.style,e,n[e])}else if(e[0]=="o"&&e[1]=="n")o=e!=(e=e.replace(xd,"$1")),s=e.toLowerCase(),e=s in t||e=="onFocusOut"||e=="onFocusIn"?s.slice(2):e.slice(2),t.l||(t.l={}),t.l[e+o]=n,n?r?n.u=r.u:(n.u=uc,t.addEventListener(e,o?ac:sc,o)):t.removeEventListener(e,o?ac:sc,o);else{if(i=="http://www.w3.org/2000/svg")e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(e!="width"&&e!="height"&&e!="href"&&e!="list"&&e!="form"&&e!="tabIndex"&&e!="download"&&e!="rowSpan"&&e!="colSpan"&&e!="role"&&e!="popover"&&e in t)try{t[e]=n??"";break e}catch{}typeof n=="function"||(n==null||n===!1&&e[4]!="-"?t.removeAttribute(e):t.setAttribute(e,e=="popover"&&n==1?"":n))}}function wd(t){return function(e){if(this.l){var n=this.l[e.type+t];if(e.t==null)e.t=uc++;else if(e.t<n.u)return;return n(fe.event?fe.event(e):e)}}}function Rd(t,e,n,r,i,o,s,l,u,d){var _,p,v,E,T,N,F,B,k,W,V,he,P,q,z,J,me,se=e.type;if(e.constructor!=null)return null;128&n.__u&&(u=!!(32&n.__u),o=[l=e.__e=n.__e]),(_=fe.__b)&&_(e);e:if(typeof se=="function")try{if(B=e.props,k="prototype"in se&&se.prototype.render,W=(_=se.contextType)&&r[_.__c],V=_?W?W.props.value:_.__:r,n.__c?F=(p=e.__c=n.__c).__=p.__E:(k?e.__c=p=new se(B,V):(e.__c=p=new pr(B,V),p.constructor=se,p.render=lv),W&&W.sub(p),p.props=B,p.state||(p.state={}),p.context=V,p.__n=r,v=p.__d=!0,p.__h=[],p._sb=[]),k&&p.__s==null&&(p.__s=p.state),k&&se.getDerivedStateFromProps!=null&&(p.__s==p.state&&(p.__s=sn({},p.__s)),sn(p.__s,se.getDerivedStateFromProps(B,p.__s))),E=p.props,T=p.state,p.__v=e,v)k&&se.getDerivedStateFromProps==null&&p.componentWillMount!=null&&p.componentWillMount(),k&&p.componentDidMount!=null&&p.__h.push(p.componentDidMount);else{if(k&&se.getDerivedStateFromProps==null&&B!==E&&p.componentWillReceiveProps!=null&&p.componentWillReceiveProps(B,V),!p.__e&&p.shouldComponentUpdate!=null&&p.shouldComponentUpdate(B,p.__s,V)===!1||e.__v==n.__v){for(e.__v!=n.__v&&(p.props=B,p.state=p.__s,p.__d=!1),e.__e=n.__e,e.__k=n.__k,e.__k.some(function(ge){ge&&(ge.__=e)}),he=0;he<p._sb.length;he++)p.__h.push(p._sb[he]);p._sb=[],p.__h.length&&s.push(p);break e}p.componentWillUpdate!=null&&p.componentWillUpdate(B,p.__s,V),k&&p.componentDidUpdate!=null&&p.__h.push(function(){p.componentDidUpdate(E,T,N)})}if(p.context=V,p.props=B,p.__P=t,p.__e=!1,P=fe.__r,q=0,k){for(p.state=p.__s,p.__d=!1,P&&P(e),_=p.render(p.props,p.state,p.context),z=0;z<p._sb.length;z++)p.__h.push(p._sb[z]);p._sb=[]}else do p.__d=!1,P&&P(e),_=p.render(p.props,p.state,p.context),p.state=p.__s;while(p.__d&&++q<25);p.state=p.__s,p.getChildContext!=null&&(r=sn(sn({},r),p.getChildContext())),k&&!v&&p.getSnapshotBeforeUpdate!=null&&(N=p.getSnapshotBeforeUpdate(E,T)),J=_,_!=null&&_.type===dc&&_.key==null&&(J=Md(_.props.children)),l=Dd(t,Bo(J)?J:[J],e,n,r,i,o,s,l,u,d),p.base=e.__e,e.__u&=-161,p.__h.length&&s.push(p),F&&(p.__E=p.__=null)}catch(ge){if(e.__v=null,u||o!=null)if(ge.then){for(e.__u|=u?160:128;l&&l.nodeType==8&&l.nextSibling;)l=l.nextSibling;o[o.indexOf(l)]=null,e.__e=l}else for(me=o.length;me--;)fc(o[me]);else e.__e=n.__e,e.__k=n.__k;fe.__e(ge,e,n)}else o==null&&e.__v==n.__v?(e.__k=n.__k,e.__e=n.__e):l=e.__e=cv(n.__e,e,n,r,i,o,s,u,d);return(_=fe.diffed)&&_(e),128&e.__u?void 0:l}function av(t,e,n){for(var r=0;r<n.length;r++)pc(n[r],n[++r],n[++r]);fe.__c&&fe.__c(e,t),t.some(function(i){try{t=i.__h,i.__h=[],t.some(function(o){o.call(i)})}catch(o){fe.__e(o,i.__v)}})}function Md(t){return typeof t!="object"||t==null||t.__b&&t.__b>0?t:Bo(t)?t.map(Md):sn({},t)}function cv(t,e,n,r,i,o,s,l,u){var d,_,p,v,E,T,N,F=n.props,B=e.props,k=e.type;if(k=="svg"?i="http://www.w3.org/2000/svg":k=="math"?i="http://www.w3.org/1998/Math/MathML":i||(i="http://www.w3.org/1999/xhtml"),o!=null){for(d=0;d<o.length;d++)if((E=o[d])&&"setAttribute"in E==!!k&&(k?E.localName==k:E.nodeType==3)){t=E,o[d]=null;break}}if(t==null){if(k==null)return document.createTextNode(B);t=document.createElementNS(i,k,B.is&&B),l&&(fe.__m&&fe.__m(e,o),l=!1),o=null}if(k==null)F===B||l&&t.data==B||(t.data=B);else{if(o=o&&Sd.call(t.childNodes),F=n.props||cc,!l&&o!=null)for(F={},d=0;d<t.attributes.length;d++)F[(E=t.attributes[d]).name]=E.value;for(d in F)if(E=F[d],d!="children"){if(d=="dangerouslySetInnerHTML")p=E;else if(!(d in B)){if(d=="value"&&"defaultValue"in B||d=="checked"&&"defaultChecked"in B)continue;Fo(t,d,null,E,i)}}for(d in B)E=B[d],d=="children"?v=E:d=="dangerouslySetInnerHTML"?_=E:d=="value"?T=E:d=="checked"?N=E:l&&typeof E!="function"||F[d]===E||Fo(t,d,E,F[d],i);if(_)l||p&&(_.__html==p.__html||_.__html==t.innerHTML)||(t.innerHTML=_.__html),e.__k=[];else if(p&&(t.innerHTML=""),Dd(e.type=="template"?t.content:t,Bo(v)?v:[v],e,n,r,k=="foreignObject"?"http://www.w3.org/1999/xhtml":i,o,s,o?o[0]:n.__k&&hr(n,0),l,u),o!=null)for(d=o.length;d--;)fc(o[d]);l||(d="value",k=="progress"&&T==null?t.removeAttribute("value"):T!=null&&(T!==t[d]||k=="progress"&&!T||k=="option"&&T!=F[d])&&Fo(t,d,T,F[d],i),d="checked",N!=null&&N!=t[d]&&Fo(t,d,N,F[d],i))}return t}function pc(t,e,n){try{if(typeof t=="function"){var r=typeof t.__u=="function";r&&t.__u(),r&&e==null||(t.__u=t(e))}else t.current=e}catch(i){fe.__e(i,n)}}function Pd(t,e,n){var r,i;if(fe.unmount&&fe.unmount(t),(r=t.ref)&&(r.current&&r.current!=t.__e||pc(r,null,e)),(r=t.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(o){fe.__e(o,e)}r.base=r.__P=null}if(r=t.__k)for(i=0;i<r.length;i++)r[i]&&Pd(r[i],e,n||typeof t.type!="function");n||fc(t.__e),t.__c=t.__=t.__e=void 0}function lv(t,e,n){return this.constructor(t,n)}Sd=Od.slice,fe={__e:function(t,e,n,r){for(var i,o,s;e=e.__;)if((i=e.__c)&&!i.__)try{if((o=i.constructor)&&o.getDerivedStateFromError!=null&&(i.setState(o.getDerivedStateFromError(t)),s=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(t,r||{}),s=i.__d),s)return i.__E=i}catch(l){t=l}throw t}},Cd=0,lc=function(t){return t!=null&&t.constructor==null},pr.prototype.setState=function(t,e){var n;n=this.__s!=null&&this.__s!=this.state?this.__s:this.__s=sn({},this.state),typeof t=="function"&&(t=t(sn({},n),this.props)),t&&sn(n,t),t!=null&&this.__v&&(e&&this._sb.push(e),Ed(this))},pr.prototype.forceUpdate=function(t){this.__v&&(this.__e=!0,t&&this.__h.push(t),Ed(this))},pr.prototype.render=dc,Bn=[],Id=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Td=function(t,e){return t.__v.__b-e.__v.__b},ko.__r=0,xd=/(PointerCapture)$|Capture$/i,uc=0,sc=wd(!1),ac=wd(!0),rv=0;var mc,ot,hc,Ld,Fd=0,Gd=[],Le=fe,kd=Le.__b,Bd=Le.__r,Vd=Le.diffed,Ud=Le.__c,Hd=Le.unmount,jd=Le.__;function uv(t,e){Le.__h&&Le.__h(ot,t,Fd||e),Fd=0;var n=ot.__H||(ot.__H={__:[],__h:[]});return t>=n.__.length&&n.__.push({}),n.__[t]}function _c(t,e){var n=uv(mc++,7);return pv(n.__H,e)&&(n.__=t(),n.__H=e,n.__h=t),n.__}function fv(){for(var t;t=Gd.shift();)if(t.__P&&t.__H)try{t.__H.__h.forEach(Vo),t.__H.__h.forEach(gc),t.__H.__h=[]}catch(e){t.__H.__h=[],Le.__e(e,t.__v)}}Le.__b=function(t){ot=null,kd&&kd(t)},Le.__=function(t,e){t&&e.__k&&e.__k.__m&&(t.__m=e.__k.__m),jd&&jd(t,e)},Le.__r=function(t){Bd&&Bd(t),mc=0;var e=(ot=t.__c).__H;e&&(hc===ot?(e.__h=[],ot.__h=[],e.__.forEach(function(n){n.__N&&(n.__=n.__N),n.u=n.__N=void 0})):(e.__h.forEach(Vo),e.__h.forEach(gc),e.__h=[],mc=0)),hc=ot},Le.diffed=function(t){Vd&&Vd(t);var e=t.__c;e&&e.__H&&(e.__H.__h.length&&(Gd.push(e)!==1&&Ld===Le.requestAnimationFrame||((Ld=Le.requestAnimationFrame)||dv)(fv)),e.__H.__.forEach(function(n){n.u&&(n.__H=n.u),n.u=void 0})),hc=ot=null},Le.__c=function(t,e){e.some(function(n){try{n.__h.forEach(Vo),n.__h=n.__h.filter(function(r){return!r.__||gc(r)})}catch(r){e.some(function(i){i.__h&&(i.__h=[])}),e=[],Le.__e(r,n.__v)}}),Ud&&Ud(t,e)},Le.unmount=function(t){Hd&&Hd(t);var e,n=t.__c;n&&n.__H&&(n.__H.__.forEach(function(r){try{Vo(r)}catch(i){e=i}}),n.__H=void 0,e&&Le.__e(e,n.__v))};var $d=typeof requestAnimationFrame=="function";function dv(t){var e,n=function(){clearTimeout(r),$d&&cancelAnimationFrame(e),setTimeout(t)},r=setTimeout(n,35);$d&&(e=requestAnimationFrame(n))}function Vo(t){var e=ot,n=t.__c;typeof n=="function"&&(t.__c=void 0,n()),ot=e}function gc(t){var e=ot;t.__c=t.__(),ot=e}function pv(t,e){return!t||t.length!==e.length||e.some(function(n,r){return n!==t[r]})}var hv=Symbol.for("preact-signals");function vc(){if(mr>1)mr--;else{for(var t,e=!1;fi!==void 0;){var n=fi;for(fi=void 0,yc++;n!==void 0;){var r=n.o;if(n.o=void 0,n.f&=-3,!(8&n.f)&&Yd(n))try{n.c()}catch(i){e||(t=i,e=!0)}n=r}}if(yc=0,mr--,e)throw t}}var de=void 0;var fi=void 0,mr=0,yc=0,Uo=0;function Wd(t){if(de!==void 0){var e=t.n;if(e===void 0||e.t!==de)return e={i:0,S:t,p:de.s,n:void 0,t:de,e:void 0,x:void 0,r:e},de.s!==void 0&&(de.s.n=e),de.s=e,t.n=e,32&de.f&&t.S(e),e;if(e.i===-1)return e.i=0,e.n!==void 0&&(e.n.p=e.p,e.p!==void 0&&(e.p.n=e.n),e.p=de.s,e.n=void 0,de.s.n=e,de.s=e),e}}function Ve(t){this.v=t,this.i=0,this.n=void 0,this.t=void 0}Ve.prototype.brand=hv;Ve.prototype.h=function(){return!0};Ve.prototype.S=function(t){this.t!==t&&t.e===void 0&&(t.x=this.t,this.t!==void 0&&(this.t.e=t),this.t=t)};Ve.prototype.U=function(t){if(this.t!==void 0){var e=t.e,n=t.x;e!==void 0&&(e.x=n,t.e=void 0),n!==void 0&&(n.e=e,t.x=void 0),t===this.t&&(this.t=n)}};Ve.prototype.subscribe=function(t){var e=this;return Ho(function(){var n=e.value,r=de;de=void 0;try{t(n)}finally{de=r}})};Ve.prototype.valueOf=function(){return this.value};Ve.prototype.toString=function(){return this.value+""};Ve.prototype.toJSON=function(){return this.value};Ve.prototype.peek=function(){var t=de;de=void 0;try{return this.value}finally{de=t}};Object.defineProperty(Ve.prototype,"value",{get:function(){var t=Wd(this);return t!==void 0&&(t.i=this.i),this.v},set:function(t){if(t!==this.v){if(yc>100)throw new Error("Cycle detected");this.v=t,this.i++,Uo++,mr++;try{for(var e=this.t;e!==void 0;e=e.x)e.t.N()}finally{vc()}}}});function di(t){return new Ve(t)}function Yd(t){for(var e=t.s;e!==void 0;e=e.n)if(e.S.i!==e.i||!e.S.h()||e.S.i!==e.i)return!0;return!1}function zd(t){for(var e=t.s;e!==void 0;e=e.n){var n=e.S.n;if(n!==void 0&&(e.r=n),e.S.n=e,e.i=-1,e.n===void 0){t.s=e;break}}}function Xd(t){for(var e=t.s,n=void 0;e!==void 0;){var r=e.p;e.i===-1?(e.S.U(e),r!==void 0&&(r.n=e.n),e.n!==void 0&&(e.n.p=r)):n=e,e.S.n=e.r,e.r!==void 0&&(e.r=void 0),e=r}t.s=n}function gr(t){Ve.call(this,void 0),this.x=t,this.s=void 0,this.g=Uo-1,this.f=4}(gr.prototype=new Ve).h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===Uo))return!0;if(this.g=Uo,this.f|=1,this.i>0&&!Yd(this))return this.f&=-2,!0;var t=de;try{zd(this),de=this;var e=this.x();(16&this.f||this.v!==e||this.i===0)&&(this.v=e,this.f&=-17,this.i++)}catch(n){this.v=n,this.f|=16,this.i++}return de=t,Xd(this),this.f&=-2,!0};gr.prototype.S=function(t){if(this.t===void 0){this.f|=36;for(var e=this.s;e!==void 0;e=e.n)e.S.S(e)}Ve.prototype.S.call(this,t)};gr.prototype.U=function(t){if(this.t!==void 0&&(Ve.prototype.U.call(this,t),this.t===void 0)){this.f&=-33;for(var e=this.s;e!==void 0;e=e.n)e.S.U(e)}};gr.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var t=this.t;t!==void 0;t=t.x)t.t.N()}};Object.defineProperty(gr.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var t=Wd(this);if(this.h(),t!==void 0&&(t.i=this.i),16&this.f)throw this.v;return this.v}});function qd(t){return new gr(t)}function Kd(t){var e=t.u;if(t.u=void 0,typeof e=="function"){mr++;var n=de;de=void 0;try{e()}catch(r){throw t.f&=-2,t.f|=8,Ec(t),r}finally{de=n,vc()}}}function Ec(t){for(var e=t.s;e!==void 0;e=e.n)e.S.U(e);t.x=void 0,t.s=void 0,Kd(t)}function mv(t){if(de!==this)throw new Error("Out-of-order effect");Xd(this),de=t,this.f&=-2,8&this.f&&Ec(this),vc()}function pi(t){this.x=t,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}pi.prototype.c=function(){var t=this.S();try{if(8&this.f||this.x===void 0)return;var e=this.x();typeof e=="function"&&(this.u=e)}finally{t()}};pi.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,Kd(this),zd(this),mr++;var t=de;return de=this,mv.bind(this,t)};pi.prototype.N=function(){2&this.f||(this.f|=2,this.o=fi,fi=this)};pi.prototype.d=function(){this.f|=8,1&this.f||Ec(this)};function Ho(t){var e=new pi(t);try{e.c()}catch(n){throw e.d(),n}return e.d.bind(e)}var wc,bc;function _r(t,e){fe[t]=e.bind(null,fe[t]||function(){})}function jo(t){bc&&bc(),bc=t&&t.S()}function Jd(t){var e=this,n=t.data,r=_v(n);r.value=n;var i=_c(function(){for(var o=e.__v;o=o.__;)if(o.__c){o.__c.__$f|=4;break}return e.__$u.c=function(){var s,l=e.__$u.S(),u=i.value;l(),lc(u)||((s=e.base)==null?void 0:s.nodeType)!==3?(e.__$f|=1,e.setState({})):e.base.data=u},qd(function(){var s=r.value.value;return s===0?0:s===!0?"":s||""})},[]);return i.value}Jd.displayName="_st";Object.defineProperties(Ve.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:Jd},props:{configurable:!0,get:function(){return{data:this}}},__b:{configurable:!0,value:1}});_r("__b",function(t,e){if(typeof e.type=="string"){var n,r=e.props;for(var i in r)if(i!=="children"){var o=r[i];o instanceof Ve&&(n||(e.__np=n={}),n[i]=o,r[i]=o.peek())}}t(e)});_r("__r",function(t,e){jo();var n,r=e.__c;r&&(r.__$f&=-2,(n=r.__$u)===void 0&&(r.__$u=n=(function(i){var o;return Ho(function(){o=this}),o.c=function(){r.__$f|=1,r.setState({})},o})())),wc=r,jo(n),t(e)});_r("__e",function(t,e,n,r){jo(),wc=void 0,t(e,n,r)});_r("diffed",function(t,e){jo(),wc=void 0;var n;if(typeof e.type=="string"&&(n=e.__e)){var r=e.__np,i=e.props;if(r){var o=n.U;if(o)for(var s in o){var l=o[s];l!==void 0&&!(s in r)&&(l.d(),o[s]=void 0)}else n.U=o={};for(var u in r){var d=o[u],_=r[u];d===void 0?(d=gv(n,u,_,i),o[u]=d):d.o(_,i)}}}t(e)});function gv(t,e,n,r){var i=e in t&&t.ownerSVGElement===void 0,o=di(n);return{o:function(s,l){o.value=s,r=l},d:Ho(function(){var s=o.value.value;r[e]!==s&&(r[e]=s,i?t[e]=s:s?t.setAttribute(e,s):t.removeAttribute(e))})}}_r("unmount",function(t,e){if(typeof e.type=="string"){var n=e.__e;if(n){var r=n.U;if(r){n.U=void 0;for(var i in r){var o=r[i];o&&o.d()}}}}else{var s=e.__c;if(s){var l=s.__$u;l&&(s.__$u=void 0,l.d())}}t(e)});_r("__h",function(t,e,n,r){(r<3||r===9)&&(e.__$f|=2),t(e,n,r)});pr.prototype.shouldComponentUpdate=function(t,e){var n=this.__$u,r=n&&n.s!==void 0;for(var i in e)return!0;if(this.__f||typeof this.u=="boolean"&&this.u===!0){if(!(r||2&this.__$f||4&this.__$f)||1&this.__$f)return!0}else if(!(r||4&this.__$f)||3&this.__$f)return!0;for(var o in t)if(o!=="__source"&&t[o]!==this.props[o])return!0;for(var s in this.props)if(!(s in t))return!0;return!1};function _v(t){return _c(function(){return di(t)},[])}var yv=(r=>(r.ON="ON",r.OFF="OFF",r.ON_HOVER="ON_HOVER",r))(yv||{}),vv=(r=>(r.FIRST_ITEM="FIRST_ITEM",r.CARD="CARD",r.NONE="NONE",r))(vv||{});var Ev=[[["swiper-slides"]]],bv=["swiper-slides"],wv=(t,e)=>({"--swiper-navigation-size":t,color:e}),Sv=t=>({color:t,bottom:0,top:"unset",position:"relative"});function Cv(t,e){if(t&1&&(Ue(0,"div",2),Yt(1,"span"),We(),Ue(2,"div",3),Yt(3,"span"),We()),t&2){let n,r,i=ne(),o=((n=i.navigationConfig())==null?null:n.size)??50,s=((r=i.navigationConfig())==null||r.color==null?null:r.color.rgba)??"white",l=Ci(4,wv,o+"px",s);Ei(l),$(2),Ei(l)}}function Iv(t,e){if(t&1&&(Ue(0,"div",4),Yt(1,"span"),We()),t&2){let n,r=((n=ne().paginationConfig())==null||n.color==null?null:n.color.rgba)??"white",i=Si(2,Sv,r);Ei(i)}}var Zd=class t{options=Ge.required();navigationConfig=Ge();paginationConfig=Ge();slideChange=fn();elementRef=U(ut);swiperInstance;initToken=0;resizeDebouncer=new tr(this.onResize.bind(this));constructor(){Kt(()=>{this.options()&&this.reInitSwiper()})}get swiper(){return this.swiperInstance}ngOnDestroy(){this.resizeDebouncer?.destroy(),this.swiperInstance?.destroy?.(),this.swiperInstance=void 0}async initSwiper(e=this.initToken){if(await El(),e!==this.initToken){Te.warn("Swiper token not matching");return}let n=this.elementRef.nativeElement,r={nextEl:n.querySelector(".swiper-button-next"),prevEl:n.querySelector(".swiper-button-prev"),enabled:this.navigationConfig()?.enabled},i=this.paginationConfig(),o={el:n.querySelector(".swiper-pagination"),enabled:this.paginationConfig()?.enabled,type:this.paginationConfig()?.type,clickable:!0,renderBullet:function(s,l){return`
|
|
22
|
+
<span class="${l}"
|
|
23
|
+
style="background-color: ${i?.color?.rgba};"></span>
|
|
24
|
+
`},renderProgressbar:s=>`
|
|
25
|
+
<span class="${s}"
|
|
26
|
+
style="background-color: ${i?.color?.rgba};">
|
|
27
|
+
</span>
|
|
28
|
+
`};this.swiperInstance=new window.CooeeSDK.Swiper(n,I({navigation:r,pagination:o},this.options())),this.swiperInstance.on("slideChange",s=>{this.slideChange.emit(s)})}onResize(){this.swiperInstance?(Te.verbose("Updating swiper"),this.swiperInstance.update()):(Te.verbose("Reinitialising swiper"),this.reInitSwiper())}reInitSwiper(){this.initToken++;let e=this.initToken;this.swiperInstance?.destroy?.(),this.swiperInstance=void 0,this.initSwiper(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=ve({type:t,selectors:[["cooee-swiper"]],hostAttrs:[1,"swiper"],inputs:{options:[1,"options"],navigationConfig:[1,"navigationConfig"],paginationConfig:[1,"paginationConfig"]},outputs:{slideChange:"slideChange"},ngContentSelectors:bv,decls:4,vars:2,consts:[[1,"swiper-wrapper"],[1,"swiper-pagination",3,"style"],[1,"swiper-button-prev"],[1,"swiper-button-next"],[1,"swiper-pagination"]],template:function(n,r){if(n&1&&(qc(Ev),Ue(0,"div",0),Kc(1),We(),Ee(2,Cv,4,7),Ee(3,Iv,2,4,"div",1)),n&2){let i,o;$(2),be((i=r.navigationConfig())!=null&&i.enabled?2:-1),$(),be((o=r.paginationConfig())!=null&&o.enabled?3:-1)}},styles:[`:host{display:block}.swiper-wrapper{scrollbar-width:none;display:flex}.swiper-wrapper::-webkit-scrollbar{display:none}.swiper .swiper-button-prev,.swiper .swiper-button-next{background:rgba(var(--lc-icon-button-bg-color));width:var(--lc-icon-button-size);height:var(--lc-icon-button-size);border-radius:100%}.swiper .swiper-button-prev:after,.swiper .swiper-button-next:after{font-size:20px;color:rgba(var(--lc-icon-button-color))}
|
|
29
|
+
`],encapsulation:2})};function Tv(t,e){if(t&1&&(Ue(0,"span",1),we(1),We()),t&2){ne();let n=Qe(0);$(),un(n.heading)}}function xv(t,e){if(t&1&&(Ue(0,"span",2),we(1),We()),t&2){ne();let n=Qe(0);$(),un(n.subHeading)}}var Qd=class t{card=Ge.required();linkClicked=fn();linkAfterSanity(){return this.card()?.buttonLink?.startsWith("https")?this.card().buttonLink:null}clickLink(e){e.stopPropagation(),this.linkClicked.emit()}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=ve({type:t,selectors:[["cooee-video-card"]],inputs:{card:[1,"card"]},outputs:{linkClicked:"linkClicked"},decls:6,vars:6,consts:[[1,"video-card-details"],[1,"heading"],[1,"subheading"],["rel","noopener noreferrer",1,"cta-button",3,"click","href","target"]],template:function(n,r){if(n&1){let i=Dt();Rt(0),Ue(1,"div",0),Ee(2,Tv,2,1,"span",1),Ee(3,xv,2,1,"span",2),Ue(4,"a",3),Or("click",function(s){return tt(i),nt(r.clickLink(s))}),we(5),We()()}if(n&2){let i=Mt(r.card());$(2),be(i!=null&&i.heading?2:-1),$(),be(i!=null&&i.subHeading?3:-1),$(),Nt("href",r.linkAfterSanity(),cn)("target",i.newTab?"_blank":"_self"),$(),Wn(" ",i==null?null:i.buttonTitle," ")}},styles:["[_nghost-%COMP%]{display:block}.video-card-details[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:3.75px;font-size:14px;line-height:normal}.video-card-details[_ngcontent-%COMP%] .cta-button[_ngcontent-%COMP%]{text-align:center;background-color:#fff;border-radius:var(--lc-button-radius);padding:7.5px 15px;font-weight:500;color:rgba(var(--lc-primary-button-bg-color));font-size:12px;border:0;text-decoration:none}.video-card-details[_ngcontent-%COMP%] .heading[_ngcontent-%COMP%], .video-card-details[_ngcontent-%COMP%] .subheading[_ngcontent-%COMP%]{text-align:start;color:#000;font-weight:600;overflow:hidden}.video-card-details[_ngcontent-%COMP%] .heading[_ngcontent-%COMP%]{font-size:18px}.video-card-details[_ngcontent-%COMP%] .subheading[_ngcontent-%COMP%]{font-size:16px}"],changeDetection:0})};function Ov(t,e){t&1&&ft(0,"cooee-icon",1)}function Av(t,e){t&1&&ft(0,"cooee-icon",2)}var ep=class t{muted=Nr.required();videoEl=Ge.required();toggled=fn();constructor(){Kt(()=>{this.videoEl().muted=this.muted(),this.muted()||this.videoEl().play()})}toggle(e){e.stopPropagation(),e.preventDefault(),this.muted.update(n=>!n),this.toggled.emit(this.muted())}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=ve({type:t,selectors:[["cooee-mute-toggle"]],inputs:{muted:[1,"muted"],videoEl:[1,"videoEl"]},outputs:{muted:"mutedChange",toggled:"toggled"},decls:3,vars:5,consts:[["type","button",3,"click"],["name","unmute"],["name","mute"]],template:function(n,r){n&1&&(ce(0,"button",0),bt("click",function(o){return r.toggle(o)}),Ee(1,Ov,1,0,"cooee-icon",1)(2,Av,1,0,"cooee-icon",2),ue()),n&2&&(Ar("unmute",!r.muted()),At("aria-label",r.muted()?"Unmute video":"Mute video")("aria-pressed",r.muted()),$(),be(r.muted()?1:2))},dependencies:[nr],styles:["button[_ngcontent-%COMP%]{width:var(--lc-icon-button-size, 44px);height:var(--lc-icon-button-size, 44px);display:flex;justify-content:center;align-items:center;border:none;border-radius:100%;background:#00000080;background:color-mix(in oklab,#000 50%,transparent)}"]})};function Dv(t,e){if(t&1&&(Yt(0,"span",6),wt(1,"cooeeCurrency"),wt(2,"safeHtml")),t&2){ne();let n=Qe(7);Nt("innerHTML",St(2,3,St(1,1,n.cmp)),Wt)}}function Nv(t,e){t&1&&we(0," Out of Stock ")}function Rv(t,e){t&1&&we(0," Add To Cart ")}var tp=class t{buttonClick=fn();item=Ge.required();isButtonDisabled=qt(()=>{let e=this.item();return e.hasVariants()?!e.vars.some(n=>n.isAvailable):!e.selectedOrFirstVariant.value.isAvailable});addToCartClicked(e){e.stopPropagation(),this.buttonClick.emit(this.item())}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=ve({type:t,selectors:[["cooee-item-card"]],inputs:{item:[1,"item"]},outputs:{buttonClick:"buttonClick"},decls:20,vars:14,consts:[[1,"card-body"],[1,"item-image",3,"alt","src"],[1,"item-info"],[1,"item-name"],[1,"prices"],[1,"item-price",3,"innerHTML"],[1,"item-cmp-price",3,"innerHTML"],["type","button",1,"shop-now-button",3,"click","href"],[1,"card-footer"],["type","button",1,"cta-button",3,"click","disabled"],["href","/cart","title","View Cart",1,"view-cart-button"],["width","32","height","32","src","https://img.icons8.com/material-sharp/48/shopping-cart.png","alt","shopping-cart"]],template:function(n,r){if(n&1){let i=Dt();Yc(0),Ue(1,"div",0),Yt(2,"img",1),Ue(3,"div",2)(4,"div",3),we(5),We(),Ue(6,"div",4),Rt(7),Yt(8,"span",5),wt(9,"cooeeCurrency"),wt(10,"safeHtml"),Ee(11,Dv,3,5,"span",6),We(),Ue(12,"a",7),Or("click",function(s){return tt(i),nt(s.stopPropagation())}),we(13," Shop now "),We()()(),Ue(14,"div",8)(15,"button",9),Or("click",function(s){return tt(i),nt(r.addToCartClicked(s))}),Ee(16,Nv,1,0)(17,Rv,1,0),We(),Ue(18,"a",10),Yt(19,"img",11),We()(),zc()}if(n&2){let i=r.item().selectedOrFirstVariant.value;$(2),Nt("alt",el(r.item().name))("src",r.item().firstImageURL,cn),$(3),Wn(" ",r.item().name," "),$(2);let o=Mt(i.price);$(),Nt("innerHTML",St(10,12,St(9,10,o.d)),Wt),$(3),be(o.cmp?11:-1),$(),Nt("href","/products/"+r.item().slug,cn),$(3),Nt("disabled",r.isButtonDisabled()),$(),be(r.isButtonDisabled()?16:17)}},dependencies:[dr,Ii],styles:["[_nghost-%COMP%]{max-width:100%;position:relative;display:flex;flex-direction:column;gap:8px;padding:8px}.card-body[_ngcontent-%COMP%]{display:flex;gap:8px;width:100%;align-items:flex-start}.item-image[_ngcontent-%COMP%]{width:70px;height:70px;object-fit:cover;box-sizing:border-box;border-radius:var(--lc-media-radius)}.item-info[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:3.5px;font-size:10.5px}.item-name[_ngcontent-%COMP%]{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.card-footer[_ngcontent-%COMP%]{display:flex;gap:6px;align-items:center}.cta-button[_ngcontent-%COMP%]{padding:10px;border:none;width:100%;text-align:center}.shop-now-button[_ngcontent-%COMP%]{display:none;background-color:rgba(var(--lc-primary-button-bg-color));color:rgba(var(--lc-primary-button-color));font-weight:var(--lc-primary-button-weight);text-transform:var(--lc-primary-button-transform);border-radius:var(--lc-button-radius);font-size:var(--lc-button-size);font-family:var(--lc-button-family),serif;height:var(--lc-button-height);letter-spacing:var(--lc-button-letter-spacing);transition:filter .12s ease,background-color .2s ease,color .2s ease;border-width:1px;border-style:solid;border-color:rgba(var(--lc-primary-button-border-color));display:flex;align-items:center;justify-content:center;font-size:12px;width:fit-content;height:auto;text-align:center;z-index:4;padding:4px 10px;text-decoration:none}.shop-now-button[_ngcontent-%COMP%]:hover{filter:brightness(.95)}.shop-now-button[_ngcontent-%COMP%]:active{filter:brightness(.9)}.shop-now-button[_ngcontent-%COMP%]:focus-visible{outline:2px solid rgba(var(--lc-primary-color, 0, 0, 0));outline-offset:2px}.view-cart-button[_ngcontent-%COMP%]{display:none}"]})};export{Te as a,jv as b,dn as c,El as d,bl as e,Ni as f,Zt as g,Bh as h,Hi as i,hn as j,tE as k,Uh as l,ji as m,$i as n,Cs as o,hd as p,Cy as q,rc as r,dr as s,Wr as t,dm as u,tw as v,wu as w,ks as x,tr as y,nr as z,_d as A,_t as B,yd as C,yv as D,vv as E,Zd as F,Qd as G,ep as H,tp as I};
|