@coveo/headless 3.23.2-pre.57bb336b29 → 3.23.2-pre.d35ebef42a
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/browser/case-assist/headless.esm.js +1 -1
- package/dist/browser/case-assist/headless.js +1 -1
- package/dist/browser/commerce/headless.esm.js +1 -1
- package/dist/browser/commerce/headless.js +1 -1
- package/dist/browser/headless.esm.js +1 -1
- package/dist/browser/headless.js +1 -1
- package/dist/browser/insight/headless.esm.js +1 -1
- package/dist/browser/insight/headless.js +1 -1
- package/dist/browser/recommendation/headless.esm.js +1 -1
- package/dist/browser/recommendation/headless.js +1 -1
- package/dist/browser/ssr/headless.esm.js +1 -1
- package/dist/browser/ssr/headless.js +1 -1
- package/dist/browser/ssr-commerce/headless.esm.js +1 -1
- package/dist/browser/ssr-commerce/headless.js +1 -1
- package/dist/case-assist/headless.cjs +1 -1
- package/dist/case-assist/headless.esm.js +1 -1
- package/dist/commerce/headless.cjs +1 -1
- package/dist/commerce/headless.esm.js +1 -1
- package/dist/headless.cjs +1 -1
- package/dist/headless.esm.js +1 -1
- package/dist/insight/headless.cjs +1 -1
- package/dist/insight/headless.esm.js +1 -1
- package/dist/quantic/case-assist/headless.js +1 -1
- package/dist/quantic/commerce/headless.js +1 -1
- package/dist/quantic/headless.js +1 -1
- package/dist/quantic/insight/headless.js +1 -1
- package/dist/quantic/recommendation/headless.js +1 -1
- package/dist/recommendation/headless.cjs +1 -1
- package/dist/recommendation/headless.esm.js +1 -1
- package/dist/ssr/headless.cjs +1 -1
- package/dist/ssr/headless.esm.js +1 -1
- package/dist/ssr-commerce/headless.cjs +1 -1
- package/dist/ssr-commerce/headless.esm.js +1 -1
- package/package.json +1 -1
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
* limitations under the License.
|
|
17
17
|
*/
|
|
18
18
|
var UF=Object.create;var al=Object.defineProperty;var jF=Object.getOwnPropertyDescriptor;var _F=Object.getOwnPropertyNames;var $F=Object.getPrototypeOf,zF=Object.prototype.hasOwnProperty;var WF=(e,t,r)=>t in e?al(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var Ae=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var KF=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of _F(t))!zF.call(e,n)&&n!==r&&al(e,n,{get:()=>t[n],enumerable:!(o=jF(t,n))||o.enumerable});return e};var It=(e,t,r)=>(r=e!=null?UF($F(e)):{},KF(t||!e||!e.__esModule?al(r,"default",{value:e,enumerable:!0}):r,e));var We=(e,t,r)=>WF(e,typeof t!="symbol"?t+"":t,r);var Up=Ae(xa=>{"use strict";var Li=xa&&xa.__assign||function(){return Li=Object.assign||function(e){for(var t,r=1,o=arguments.length;r<o;r++){t=arguments[r];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e},Li.apply(this,arguments)};Object.defineProperty(xa,"__esModule",{value:!0});var HF={delayFirstAttempt:!1,jitter:"none",maxDelay:1/0,numOfAttempts:10,retry:function(){return!0},startingDelay:100,timeMultiple:2};function YF(e){var t=Li(Li({},HF),e);return t.numOfAttempts<1&&(t.numOfAttempts=1),t}xa.getSanitizedOptions=YF});var jp=Ae(il=>{"use strict";Object.defineProperty(il,"__esModule",{value:!0});function JF(e){var t=Math.random()*e;return Math.round(t)}il.fullJitter=JF});var _p=Ae(sl=>{"use strict";Object.defineProperty(sl,"__esModule",{value:!0});function XF(e){return e}sl.noJitter=XF});var $p=Ae(cl=>{"use strict";Object.defineProperty(cl,"__esModule",{value:!0});var ZF=jp(),eP=_p();function tP(e){switch(e.jitter){case"full":return ZF.fullJitter;case"none":default:return eP.noJitter}}cl.JitterFactory=tP});var ll=Ae(ul=>{"use strict";Object.defineProperty(ul,"__esModule",{value:!0});var rP=$p(),oP=function(){function e(t){this.options=t,this.attempt=0}return e.prototype.apply=function(){var t=this;return new Promise(function(r){return setTimeout(r,t.jitteredDelay)})},e.prototype.setAttemptNumber=function(t){this.attempt=t},Object.defineProperty(e.prototype,"jitteredDelay",{get:function(){var t=rP.JitterFactory(this.options);return t(this.delay)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"delay",{get:function(){var t=this.options.startingDelay,r=this.options.timeMultiple,o=this.numOfDelayedAttempts,n=t*Math.pow(r,o);return Math.min(n,this.options.maxDelay)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"numOfDelayedAttempts",{get:function(){return this.attempt},enumerable:!0,configurable:!0}),e}();ul.Delay=oP});var zp=Ae(tr=>{"use strict";var nP=tr&&tr.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,n){o.__proto__=n}||function(o,n){for(var a in n)n.hasOwnProperty(a)&&(o[a]=n[a])},e(t,r)};return function(t,r){e(t,r);function o(){this.constructor=t}t.prototype=r===null?Object.create(r):(o.prototype=r.prototype,new o)}}(),aP=tr&&tr.__awaiter||function(e,t,r,o){function n(a){return a instanceof r?a:new r(function(i){i(a)})}return new(r||(r=Promise))(function(a,i){function s(l){try{c(o.next(l))}catch(d){i(d)}}function u(l){try{c(o.throw(l))}catch(d){i(d)}}function c(l){l.done?a(l.value):n(l.value).then(s,u)}c((o=o.apply(e,t||[])).next())})},iP=tr&&tr.__generator||function(e,t){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,n,a,i;return i={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(i[Symbol.iterator]=function(){return this}),i;function s(c){return function(l){return u([c,l])}}function u(c){if(o)throw new TypeError("Generator is already executing.");for(;r;)try{if(o=1,n&&(a=c[0]&2?n.return:c[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,c[1])).done)return a;switch(n=0,a&&(c=[c[0]&2,a.value]),c[0]){case 0:case 1:a=c;break;case 4:return r.label++,{value:c[1],done:!1};case 5:r.label++,n=c[1],c=[0];continue;case 7:c=r.ops.pop(),r.trys.pop();continue;default:if(a=r.trys,!(a=a.length>0&&a[a.length-1])&&(c[0]===6||c[0]===2)){r=0;continue}if(c[0]===3&&(!a||c[1]>a[0]&&c[1]<a[3])){r.label=c[1];break}if(c[0]===6&&r.label<a[1]){r.label=a[1],a=c;break}if(a&&r.label<a[2]){r.label=a[2],r.ops.push(c);break}a[2]&&r.ops.pop(),r.trys.pop();continue}c=t.call(e,r)}catch(l){c=[6,l],n=0}finally{o=a=0}if(c[0]&5)throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}};Object.defineProperty(tr,"__esModule",{value:!0});var sP=ll(),cP=function(e){nP(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.apply=function(){return aP(this,void 0,void 0,function(){return iP(this,function(r){return[2,this.isFirstAttempt?!0:e.prototype.apply.call(this)]})})},Object.defineProperty(t.prototype,"isFirstAttempt",{get:function(){return this.attempt===0},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"numOfDelayedAttempts",{get:function(){return this.attempt-1},enumerable:!0,configurable:!0}),t}(sP.Delay);tr.SkipFirstDelay=cP});var Wp=Ae(Ra=>{"use strict";var uP=Ra&&Ra.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,n){o.__proto__=n}||function(o,n){for(var a in n)n.hasOwnProperty(a)&&(o[a]=n[a])},e(t,r)};return function(t,r){e(t,r);function o(){this.constructor=t}t.prototype=r===null?Object.create(r):(o.prototype=r.prototype,new o)}}();Object.defineProperty(Ra,"__esModule",{value:!0});var lP=ll(),dP=function(e){uP(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t}(lP.Delay);Ra.AlwaysDelay=dP});var Kp=Ae(dl=>{"use strict";Object.defineProperty(dl,"__esModule",{value:!0});var mP=zp(),pP=Wp();function fP(e,t){var r=gP(e);return r.setAttemptNumber(t),r}dl.DelayFactory=fP;function gP(e){return e.delayFirstAttempt?new pP.AlwaysDelay(e):new mP.SkipFirstDelay(e)}});var Gp=Ae(co=>{"use strict";var ml=co&&co.__awaiter||function(e,t,r,o){function n(a){return a instanceof r?a:new r(function(i){i(a)})}return new(r||(r=Promise))(function(a,i){function s(l){try{c(o.next(l))}catch(d){i(d)}}function u(l){try{c(o.throw(l))}catch(d){i(d)}}function c(l){l.done?a(l.value):n(l.value).then(s,u)}c((o=o.apply(e,t||[])).next())})},pl=co&&co.__generator||function(e,t){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,n,a,i;return i={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(i[Symbol.iterator]=function(){return this}),i;function s(c){return function(l){return u([c,l])}}function u(c){if(o)throw new TypeError("Generator is already executing.");for(;r;)try{if(o=1,n&&(a=c[0]&2?n.return:c[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,c[1])).done)return a;switch(n=0,a&&(c=[c[0]&2,a.value]),c[0]){case 0:case 1:a=c;break;case 4:return r.label++,{value:c[1],done:!1};case 5:r.label++,n=c[1],c=[0];continue;case 7:c=r.ops.pop(),r.trys.pop();continue;default:if(a=r.trys,!(a=a.length>0&&a[a.length-1])&&(c[0]===6||c[0]===2)){r=0;continue}if(c[0]===3&&(!a||c[1]>a[0]&&c[1]<a[3])){r.label=c[1];break}if(c[0]===6&&r.label<a[1]){r.label=a[1],a=c;break}if(a&&r.label<a[2]){r.label=a[2],r.ops.push(c);break}a[2]&&r.ops.pop(),r.trys.pop();continue}c=t.call(e,r)}catch(l){c=[6,l],n=0}finally{o=a=0}if(c[0]&5)throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}};Object.defineProperty(co,"__esModule",{value:!0});var yP=Up(),SP=Kp();function hP(e,t){return t===void 0&&(t={}),ml(this,void 0,void 0,function(){var r,o;return pl(this,function(n){switch(n.label){case 0:return r=yP.getSanitizedOptions(t),o=new CP(e,r),[4,o.execute()];case 1:return[2,n.sent()]}})})}co.backOff=hP;var CP=function(){function e(t,r){this.request=t,this.options=r,this.attemptNumber=0}return e.prototype.execute=function(){return ml(this,void 0,void 0,function(){var t,r;return pl(this,function(o){switch(o.label){case 0:if(this.attemptLimitReached)return[3,7];o.label=1;case 1:return o.trys.push([1,4,,6]),[4,this.applyDelay()];case 2:return o.sent(),[4,this.request()];case 3:return[2,o.sent()];case 4:return t=o.sent(),this.attemptNumber++,[4,this.options.retry(t,this.attemptNumber)];case 5:if(r=o.sent(),!r||this.attemptLimitReached)throw t;return[3,6];case 6:return[3,0];case 7:throw new Error("Something went wrong.")}})})},Object.defineProperty(e.prototype,"attemptLimitReached",{get:function(){return this.attemptNumber>=this.options.numOfAttempts},enumerable:!0,configurable:!0}),e.prototype.applyDelay=function(){return ml(this,void 0,void 0,function(){var t;return pl(this,function(r){switch(r.label){case 0:return t=SP.DelayFactory(this.options,this.attemptNumber),[4,t.apply()];case 1:return r.sent(),[2]}})})},e}()});var Hs=Ae((Id,Td)=>{"use strict";(function(e,t){typeof Id=="object"&&typeof Td<"u"?Td.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs=t()})(Id,function(){"use strict";var e=1e3,t=6e4,r=36e5,o="millisecond",n="second",a="minute",i="hour",s="day",u="week",c="month",l="quarter",d="year",p="date",m="Invalid Date",f=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,h=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,C={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(V){var q=["th","st","nd","rd"],O=V%100;return"["+V+(q[(O-20)%10]||q[O]||q[0])+"]"}},S=function(V,q,O){var N=String(V);return!N||N.length>=q?V:""+Array(q+1-N.length).join(O)+V},A={s:S,z:function(V){var q=-V.utcOffset(),O=Math.abs(q),N=Math.floor(O/60),k=O%60;return(q<=0?"+":"-")+S(N,2,"0")+":"+S(k,2,"0")},m:function V(q,O){if(q.date()<O.date())return-V(O,q);var N=12*(O.year()-q.year())+(O.month()-q.month()),k=q.clone().add(N,c),L=O-k<0,B=q.clone().add(N+(L?-1:1),c);return+(-(N+(O-k)/(L?k-B:B-k))||0)},a:function(V){return V<0?Math.ceil(V)||0:Math.floor(V)},p:function(V){return{M:c,y:d,w:u,d:s,D:p,h:i,m:a,s:n,ms:o,Q:l}[V]||String(V||"").toLowerCase().replace(/s$/,"")},u:function(V){return V===void 0}},y="en",x={};x[y]=C;var I="$isDayjsObject",v=function(V){return V instanceof T||!(!V||!V[I])},R=function V(q,O,N){var k;if(!q)return y;if(typeof q=="string"){var L=q.toLowerCase();x[L]&&(k=L),O&&(x[L]=O,k=L);var B=q.split("-");if(!k&&B.length>1)return V(B[0])}else{var z=q.name;x[z]=q,k=z}return!N&&k&&(y=k),k||!N&&y},P=function(V,q){if(v(V))return V.clone();var O=typeof q=="object"?q:{};return O.date=V,O.args=arguments,new T(O)},b=A;b.l=R,b.i=v,b.w=function(V,q){return P(V,{locale:q.$L,utc:q.$u,x:q.$x,$offset:q.$offset})};var T=function(){function V(O){this.$L=R(O.locale,null,!0),this.parse(O),this.$x=this.$x||O.x||{},this[I]=!0}var q=V.prototype;return q.parse=function(O){this.$d=function(N){var k=N.date,L=N.utc;if(k===null)return new Date(NaN);if(b.u(k))return new Date;if(k instanceof Date)return new Date(k);if(typeof k=="string"&&!/Z$/i.test(k)){var B=k.match(f);if(B){var z=B[2]-1||0,Y=(B[7]||"0").substring(0,3);return L?new Date(Date.UTC(B[1],z,B[3]||1,B[4]||0,B[5]||0,B[6]||0,Y)):new Date(B[1],z,B[3]||1,B[4]||0,B[5]||0,B[6]||0,Y)}}return new Date(k)}(O),this.init()},q.init=function(){var O=this.$d;this.$y=O.getFullYear(),this.$M=O.getMonth(),this.$D=O.getDate(),this.$W=O.getDay(),this.$H=O.getHours(),this.$m=O.getMinutes(),this.$s=O.getSeconds(),this.$ms=O.getMilliseconds()},q.$utils=function(){return b},q.isValid=function(){return this.$d.toString()!==m},q.isSame=function(O,N){var k=P(O);return this.startOf(N)<=k&&k<=this.endOf(N)},q.isAfter=function(O,N){return P(O)<this.startOf(N)},q.isBefore=function(O,N){return this.endOf(N)<P(O)},q.$g=function(O,N,k){return b.u(O)?this[N]:this.set(k,O)},q.unix=function(){return Math.floor(this.valueOf()/1e3)},q.valueOf=function(){return this.$d.getTime()},q.startOf=function(O,N){var k=this,L=!!b.u(N)||N,B=b.p(O),z=function(re,se){var de=b.w(k.$u?Date.UTC(k.$y,se,re):new Date(k.$y,se,re),k);return L?de:de.endOf(s)},Y=function(re,se){return b.w(k.toDate()[re].apply(k.toDate("s"),(L?[0,0,0,0]:[23,59,59,999]).slice(se)),k)},te=this.$W,G=this.$M,J=this.$D,K="set"+(this.$u?"UTC":"");switch(B){case d:return L?z(1,0):z(31,11);case c:return L?z(1,G):z(0,G+1);case u:var Z=this.$locale().weekStart||0,ue=(te<Z?te+7:te)-Z;return z(L?J-ue:J+(6-ue),G);case s:case p:return Y(K+"Hours",0);case i:return Y(K+"Minutes",1);case a:return Y(K+"Seconds",2);case n:return Y(K+"Milliseconds",3);default:return this.clone()}},q.endOf=function(O){return this.startOf(O,!1)},q.$set=function(O,N){var k,L=b.p(O),B="set"+(this.$u?"UTC":""),z=(k={},k[s]=B+"Date",k[p]=B+"Date",k[c]=B+"Month",k[d]=B+"FullYear",k[i]=B+"Hours",k[a]=B+"Minutes",k[n]=B+"Seconds",k[o]=B+"Milliseconds",k)[L],Y=L===s?this.$D+(N-this.$W):N;if(L===c||L===d){var te=this.clone().set(p,1);te.$d[z](Y),te.init(),this.$d=te.set(p,Math.min(this.$D,te.daysInMonth())).$d}else z&&this.$d[z](Y);return this.init(),this},q.set=function(O,N){return this.clone().$set(O,N)},q.get=function(O){return this[b.p(O)]()},q.add=function(O,N){var k,L=this;O=Number(O);var B=b.p(N),z=function(G){var J=P(L);return b.w(J.date(J.date()+Math.round(G*O)),L)};if(B===c)return this.set(c,this.$M+O);if(B===d)return this.set(d,this.$y+O);if(B===s)return z(1);if(B===u)return z(7);var Y=(k={},k[a]=t,k[i]=r,k[n]=e,k)[B]||1,te=this.$d.getTime()+O*Y;return b.w(te,this)},q.subtract=function(O,N){return this.add(-1*O,N)},q.format=function(O){var N=this,k=this.$locale();if(!this.isValid())return k.invalidDate||m;var L=O||"YYYY-MM-DDTHH:mm:ssZ",B=b.z(this),z=this.$H,Y=this.$m,te=this.$M,G=k.weekdays,J=k.months,K=k.meridiem,Z=function(se,de,ze,st){return se&&(se[de]||se(N,L))||ze[de].slice(0,st)},ue=function(se){return b.s(z%12||12,se,"0")},re=K||function(se,de,ze){var st=se<12?"AM":"PM";return ze?st.toLowerCase():st};return L.replace(h,function(se,de){return de||function(ze){switch(ze){case"YY":return String(N.$y).slice(-2);case"YYYY":return b.s(N.$y,4,"0");case"M":return te+1;case"MM":return b.s(te+1,2,"0");case"MMM":return Z(k.monthsShort,te,J,3);case"MMMM":return Z(J,te);case"D":return N.$D;case"DD":return b.s(N.$D,2,"0");case"d":return String(N.$W);case"dd":return Z(k.weekdaysMin,N.$W,G,2);case"ddd":return Z(k.weekdaysShort,N.$W,G,3);case"dddd":return G[N.$W];case"H":return String(z);case"HH":return b.s(z,2,"0");case"h":return ue(1);case"hh":return ue(2);case"a":return re(z,Y,!0);case"A":return re(z,Y,!1);case"m":return String(Y);case"mm":return b.s(Y,2,"0");case"s":return String(N.$s);case"ss":return b.s(N.$s,2,"0");case"SSS":return b.s(N.$ms,3,"0");case"Z":return B}return null}(se)||B.replace(":","")})},q.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},q.diff=function(O,N,k){var L,B=this,z=b.p(N),Y=P(O),te=(Y.utcOffset()-this.utcOffset())*t,G=this-Y,J=function(){return b.m(B,Y)};switch(z){case d:L=J()/12;break;case c:L=J();break;case l:L=J()/3;break;case u:L=(G-te)/6048e5;break;case s:L=(G-te)/864e5;break;case i:L=G/r;break;case a:L=G/t;break;case n:L=G/e;break;default:L=G}return k?L:b.a(L)},q.daysInMonth=function(){return this.endOf(c).$D},q.$locale=function(){return x[this.$L]},q.locale=function(O,N){if(!O)return this.$L;var k=this.clone(),L=R(O,N,!0);return L&&(k.$L=L),k},q.clone=function(){return b.w(this.$d,this)},q.toDate=function(){return new Date(this.valueOf())},q.toJSON=function(){return this.isValid()?this.toISOString():null},q.toISOString=function(){return this.$d.toISOString()},q.toString=function(){return this.$d.toUTCString()},V}(),M=T.prototype;return P.prototype=M,[["$ms",o],["$s",n],["$m",a],["$H",i],["$W",s],["$M",c],["$y",d],["$D",p]].forEach(function(V){M[V[1]]=function(q){return this.$g(q,V[0],V[1])}}),P.extend=function(V,q){return V.$i||(V(q,T,P),V.$i=!0),P},P.locale=R,P.isDayjs=v,P.unix=function(V){return P(1e3*V)},P.en=x[y],P.Ls=x,P.p={},P})});var Qy=Ae((Od,qd)=>{"use strict";(function(e,t){typeof Od=="object"&&typeof qd<"u"?qd.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_quarterOfYear=t()})(Od,function(){"use strict";var e="month",t="quarter";return function(r,o){var n=o.prototype;n.quarter=function(s){return this.$utils().u(s)?Math.ceil((this.month()+1)/3):this.month(this.month()%3+3*(s-1))};var a=n.add;n.add=function(s,u){return s=Number(s),this.$utils().p(u)===t?this.add(3*s,e):a.bind(this)(s,u)};var i=n.startOf;n.startOf=function(s,u){var c=this.$utils(),l=!!c.u(u)||u;if(c.p(s)===t){var d=this.quarter()-1;return l?this.month(3*d).startOf(e).startOf("day"):this.month(3*d+2).endOf(e).endOf("day")}return i.bind(this)(s,u)}}})});var Ly=Ae((Dd,kd)=>{"use strict";(function(e,t){typeof Dd=="object"&&typeof kd<"u"?kd.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_customParseFormat=t()})(Dd,function(){"use strict";var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},t=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,r=/\d/,o=/\d\d/,n=/\d\d?/,a=/\d*[^-_:/,()\s\d]+/,i={},s=function(f){return(f=+f)+(f>68?1900:2e3)},u=function(f){return function(h){this[f]=+h}},c=[/[+-]\d\d:?(\d\d)?|Z/,function(f){(this.zone||(this.zone={})).offset=function(h){if(!h||h==="Z")return 0;var C=h.match(/([+-]|\d\d)/g),S=60*C[1]+(+C[2]||0);return S===0?0:C[0]==="+"?-S:S}(f)}],l=function(f){var h=i[f];return h&&(h.indexOf?h:h.s.concat(h.f))},d=function(f,h){var C,S=i.meridiem;if(S){for(var A=1;A<=24;A+=1)if(f.indexOf(S(A,0,h))>-1){C=A>12;break}}else C=f===(h?"pm":"PM");return C},p={A:[a,function(f){this.afternoon=d(f,!1)}],a:[a,function(f){this.afternoon=d(f,!0)}],Q:[r,function(f){this.month=3*(f-1)+1}],S:[r,function(f){this.milliseconds=100*+f}],SS:[o,function(f){this.milliseconds=10*+f}],SSS:[/\d{3}/,function(f){this.milliseconds=+f}],s:[n,u("seconds")],ss:[n,u("seconds")],m:[n,u("minutes")],mm:[n,u("minutes")],H:[n,u("hours")],h:[n,u("hours")],HH:[n,u("hours")],hh:[n,u("hours")],D:[n,u("day")],DD:[o,u("day")],Do:[a,function(f){var h=i.ordinal,C=f.match(/\d+/);if(this.day=C[0],h)for(var S=1;S<=31;S+=1)h(S).replace(/\[|\]/g,"")===f&&(this.day=S)}],w:[n,u("week")],ww:[o,u("week")],M:[n,u("month")],MM:[o,u("month")],MMM:[a,function(f){var h=l("months"),C=(l("monthsShort")||h.map(function(S){return S.slice(0,3)})).indexOf(f)+1;if(C<1)throw new Error;this.month=C%12||C}],MMMM:[a,function(f){var h=l("months").indexOf(f)+1;if(h<1)throw new Error;this.month=h%12||h}],Y:[/[+-]?\d+/,u("year")],YY:[o,function(f){this.year=s(f)}],YYYY:[/\d{4}/,u("year")],Z:c,ZZ:c};function m(f){var h,C;h=f,C=i&&i.formats;for(var S=(f=h.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(P,b,T){var M=T&&T.toUpperCase();return b||C[T]||e[T]||C[M].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(V,q,O){return q||O.slice(1)})})).match(t),A=S.length,y=0;y<A;y+=1){var x=S[y],I=p[x],v=I&&I[0],R=I&&I[1];S[y]=R?{regex:v,parser:R}:x.replace(/^\[|\]$/g,"")}return function(P){for(var b={},T=0,M=0;T<A;T+=1){var V=S[T];if(typeof V=="string")M+=V.length;else{var q=V.regex,O=V.parser,N=P.slice(M),k=q.exec(N)[0];O.call(b,k),P=P.replace(k,"")}}return function(L){var B=L.afternoon;if(B!==void 0){var z=L.hours;B?z<12&&(L.hours+=12):z===12&&(L.hours=0),delete L.afternoon}}(b),b}}return function(f,h,C){C.p.customParseFormat=!0,f&&f.parseTwoDigitYear&&(s=f.parseTwoDigitYear);var S=h.prototype,A=S.parse;S.parse=function(y){var x=y.date,I=y.utc,v=y.args;this.$u=I;var R=v[1];if(typeof R=="string"){var P=v[2]===!0,b=v[3]===!0,T=P||b,M=v[2];b&&(M=v[2]),i=this.$locale(),!P&&M&&(i=C.Ls[M]),this.$d=function(N,k,L,B){try{if(["x","X"].indexOf(k)>-1)return new Date((k==="X"?1e3:1)*N);var z=m(k)(N),Y=z.year,te=z.month,G=z.day,J=z.hours,K=z.minutes,Z=z.seconds,ue=z.milliseconds,re=z.zone,se=z.week,de=new Date,ze=G||(Y||te?1:de.getDate()),st=Y||de.getFullYear(),Cr=0;Y&&!te||(Cr=te>0?te-1:de.getMonth());var jo,_o=J||0,Ca=K||0,ol=Z||0,nl=ue||0;return re?new Date(Date.UTC(st,Cr,ze,_o,Ca,ol,nl+60*re.offset*1e3)):L?new Date(Date.UTC(st,Cr,ze,_o,Ca,ol,nl)):(jo=new Date(st,Cr,ze,_o,Ca,ol,nl),se&&(jo=B(jo).week(se).toDate()),jo)}catch{return new Date("")}}(x,R,I,C),this.init(),M&&M!==!0&&(this.$L=this.locale(M).$L),T&&x!=this.format(R)&&(this.$d=new Date("")),i={}}else if(R instanceof Array)for(var V=R.length,q=1;q<=V;q+=1){v[1]=R[q-1];var O=C.apply(this,v);if(O.isValid()){this.$d=O.$d,this.$L=O.$L,this.init();break}q===V&&(this.$d=new Date(""))}else A.call(this,y)}}})});var BC=Ae((e8,LC)=>{"use strict";var zT=/(^|; )Coveo-Pendragon=([^;]*)/;LC.exports=()=>zT.exec(document.cookie)?.pop()||null});var UC=Ae((Nm,Mm)=>{"use strict";(function(e,t){typeof Nm=="object"&&typeof Mm<"u"?Mm.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_timezone=t()})(Nm,function(){"use strict";var e={year:0,month:1,day:2,hour:3,minute:4,second:5},t={};return function(r,o,n){var a,i=function(l,d,p){p===void 0&&(p={});var m=new Date(l),f=function(h,C){C===void 0&&(C={});var S=C.timeZoneName||"short",A=h+"|"+S,y=t[A];return y||(y=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:h,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:S}),t[A]=y),y}(d,p);return f.formatToParts(m)},s=function(l,d){for(var p=i(l,d),m=[],f=0;f<p.length;f+=1){var h=p[f],C=h.type,S=h.value,A=e[C];A>=0&&(m[A]=parseInt(S,10))}var y=m[3],x=y===24?0:y,I=m[0]+"-"+m[1]+"-"+m[2]+" "+x+":"+m[4]+":"+m[5]+":000",v=+l;return(n.utc(I).valueOf()-(v-=v%1e3))/6e4},u=o.prototype;u.tz=function(l,d){l===void 0&&(l=a);var p,m=this.utcOffset(),f=this.toDate(),h=f.toLocaleString("en-US",{timeZone:l}),C=Math.round((f-new Date(h))/1e3/60),S=15*-Math.round(f.getTimezoneOffset()/15)-C;if(!Number(S))p=this.utcOffset(0,d);else if(p=n(h,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(S,!0),d){var A=p.utcOffset();p=p.add(m-A,"minute")}return p.$x.$timezone=l,p},u.offsetName=function(l){var d=this.$x.$timezone||n.tz.guess(),p=i(this.valueOf(),d,{timeZoneName:l}).find(function(m){return m.type.toLowerCase()==="timezonename"});return p&&p.value};var c=u.startOf;u.startOf=function(l,d){if(!this.$x||!this.$x.$timezone)return c.call(this,l,d);var p=n(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return c.call(p,l,d).tz(this.$x.$timezone,!0)},n.tz=function(l,d,p){var m=p&&d,f=p||d||a,h=s(+n(),f);if(typeof l!="string")return n(l).tz(f);var C=function(x,I,v){var R=x-60*I*1e3,P=s(R,v);if(I===P)return[R,I];var b=s(R-=60*(P-I)*1e3,v);return P===b?[R,P]:[x-60*Math.min(P,b)*1e3,Math.max(P,b)]}(n.utc(l,m).valueOf(),h,f),S=C[0],A=C[1],y=n(S).utcOffset(A);return y.$x.$timezone=f,y},n.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},n.tz.setDefault=function(l){a=l}}})});var jC=Ae((Qm,Lm)=>{"use strict";(function(e,t){typeof Qm=="object"&&typeof Lm<"u"?Lm.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_utc=t()})(Qm,function(){"use strict";var e="minute",t=/[+-]\d\d(?::?\d\d)?/g,r=/([+-]|\d\d)/g;return function(o,n,a){var i=n.prototype;a.utc=function(m){var f={date:m,utc:!0,args:arguments};return new n(f)},i.utc=function(m){var f=a(this.toDate(),{locale:this.$L,utc:!0});return m?f.add(this.utcOffset(),e):f},i.local=function(){return a(this.toDate(),{locale:this.$L,utc:!1})};var s=i.parse;i.parse=function(m){m.utc&&(this.$u=!0),this.$utils().u(m.$offset)||(this.$offset=m.$offset),s.call(this,m)};var u=i.init;i.init=function(){if(this.$u){var m=this.$d;this.$y=m.getUTCFullYear(),this.$M=m.getUTCMonth(),this.$D=m.getUTCDate(),this.$W=m.getUTCDay(),this.$H=m.getUTCHours(),this.$m=m.getUTCMinutes(),this.$s=m.getUTCSeconds(),this.$ms=m.getUTCMilliseconds()}else u.call(this)};var c=i.utcOffset;i.utcOffset=function(m,f){var h=this.$utils().u;if(h(m))return this.$u?0:h(this.$offset)?c.call(this):this.$offset;if(typeof m=="string"&&(m=function(y){y===void 0&&(y="");var x=y.match(t);if(!x)return null;var I=(""+x[0]).match(r)||["-",0,0],v=I[0],R=60*+I[1]+ +I[2];return R===0?0:v==="+"?R:-R}(m),m===null))return this;var C=Math.abs(m)<=16?60*m:m,S=this;if(f)return S.$offset=C,S.$u=m===0,S;if(m!==0){var A=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(S=this.local().add(C+A,e)).$offset=C,S.$x.$localOffset=A}else S=this.utc();return S};var l=i.format;i.format=function(m){var f=m||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return l.call(this,f)},i.valueOf=function(){var m=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*m},i.isUTC=function(){return!!this.$u},i.toISOString=function(){return this.toDate().toISOString()},i.toString=function(){return this.toDate().toUTCString()};var d=i.toDate;i.toDate=function(m){return m==="s"&&this.$offset?a(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():d.call(this)};var p=i.diff;i.diff=function(m,f,h){if(m&&this.$u===m.$u)return p.call(this,m,f,h);var C=this.local(),S=a(m).local();return p.call(C,S,f,h)}}})});var tx=Ae((l5,ex)=>{"use strict";function tO(e){try{return JSON.stringify(e)}catch{return'"[Circular]"'}}ex.exports=rO;function rO(e,t,r){var o=r&&r.stringify||tO,n=1;if(typeof e=="object"&&e!==null){var a=t.length+n;if(a===1)return e;var i=new Array(a);i[0]=o(e);for(var s=1;s<a;s++)i[s]=o(t[s]);return i.join(" ")}if(typeof e!="string")return e;var u=t.length;if(u===0)return e;for(var c="",l=1-n,d=-1,p=e&&e.length||0,m=0;m<p;){if(e.charCodeAt(m)===37&&m+1<p){switch(d=d>-1?d:0,e.charCodeAt(m+1)){case 100:case 102:if(l>=u||t[l]==null)break;d<m&&(c+=e.slice(d,m)),c+=Number(t[l]),d=m+2,m++;break;case 105:if(l>=u||t[l]==null)break;d<m&&(c+=e.slice(d,m)),c+=Math.floor(Number(t[l])),d=m+2,m++;break;case 79:case 111:case 106:if(l>=u||t[l]===void 0)break;d<m&&(c+=e.slice(d,m));var f=typeof t[l];if(f==="string"){c+="'"+t[l]+"'",d=m+2,m++;break}if(f==="function"){c+=t[l].name||"<anonymous>",d=m+2,m++;break}c+=o(t[l]),d=m+2,m++;break;case 115:if(l>=u)break;d<m&&(c+=e.slice(d,m)),c+=String(t[l]),d=m+2,m++;break;case 37:d<m&&(c+=e.slice(d,m)),c+="%",d=m+2,m++,l--;break}++l}++m}return d===-1?e:(d<p&&(c+=e.slice(d)),c)}});var sx=Ae((d5,uu)=>{"use strict";var rx=tx();uu.exports=gr;var Fi=SO().console||{},oO={mapHttpRequest:cu,mapHttpResponse:cu,wrapRequestSerializer:jm,wrapResponseSerializer:jm,wrapErrorSerializer:jm,req:cu,res:cu,err:nx,errWithCause:nx};function oo(e,t){return e==="silent"?1/0:t.levels.values[e]}var zm=Symbol("pino.logFuncs"),_m=Symbol("pino.hierarchy"),nO={error:"log",fatal:"error",warn:"error",info:"log",debug:"log",trace:"log"};function ox(e,t){let r={logger:t,parent:e[_m]};t[_m]=r}function aO(e,t,r){let o={};t.forEach(n=>{o[n]=r[n]?r[n]:Fi[n]||Fi[nO[n]||"log"]||oa}),e[zm]=o}function iO(e,t){return Array.isArray(e)?e.filter(function(o){return o!=="!stdSerializers.err"}):e===!0?Object.keys(t):!1}function gr(e){e=e||{},e.browser=e.browser||{};let t=e.browser.transmit;if(t&&typeof t.send!="function")throw Error("pino: transmit option must have a send function");let r=e.browser.write||Fi;e.browser.write&&(e.browser.asObject=!0);let o=e.serializers||{},n=iO(e.browser.serialize,o),a=e.browser.serialize;Array.isArray(e.browser.serialize)&&e.browser.serialize.indexOf("!stdSerializers.err")>-1&&(a=!1);let i=Object.keys(e.customLevels||{}),s=["error","fatal","warn","info","debug","trace"].concat(i);typeof r=="function"&&s.forEach(function(h){r[h]=r}),(e.enabled===!1||e.browser.disabled)&&(e.level="silent");let u=e.level||"info",c=Object.create(r);c.log||(c.log=oa),aO(c,s,r),ox({},c),Object.defineProperty(c,"levelVal",{get:d}),Object.defineProperty(c,"level",{get:p,set:m});let l={transmit:t,serialize:n,asObject:e.browser.asObject,formatters:e.browser.formatters,levels:s,timestamp:fO(e),messageKey:e.messageKey||"msg",onChild:e.onChild||oa};c.levels=sO(e),c.level=u,c.setMaxListeners=c.getMaxListeners=c.emit=c.addListener=c.on=c.prependListener=c.once=c.prependOnceListener=c.removeListener=c.removeAllListeners=c.listeners=c.listenerCount=c.eventNames=c.write=c.flush=oa,c.serializers=o,c._serialize=n,c._stdErrSerialize=a,c.child=function(...h){return f.call(this,l,...h)},t&&(c._logEvent=$m());function d(){return oo(this.level,this)}function p(){return this._level}function m(h){if(h!=="silent"&&!this.levels.values[h])throw Error("unknown level "+h);this._level=h,No(this,l,c,"error"),No(this,l,c,"fatal"),No(this,l,c,"warn"),No(this,l,c,"info"),No(this,l,c,"debug"),No(this,l,c,"trace"),i.forEach(C=>{No(this,l,c,C)})}function f(h,C,S){if(!C)throw new Error("missing bindings for child Pino");S=S||{},n&&C.serializers&&(S.serializers=C.serializers);let A=S.serializers;if(n&&A){var y=Object.assign({},o,A),x=e.browser.serialize===!0?Object.keys(y):n;delete C.serializers,Wm([C],x,y,this._stdErrSerialize)}function I(R){this._childLevel=(R._childLevel|0)+1,this.bindings=C,y&&(this.serializers=y,this._serialize=x),t&&(this._logEvent=$m([].concat(R._logEvent.bindings,C)))}I.prototype=this;let v=new I(this);return ox(this,v),v.child=function(...R){return f.call(this,h,...R)},v.level=S.level||this.level,h.onChild(v),v}return c}function sO(e){let t=e.customLevels||{},r=Object.assign({},gr.levels.values,t),o=Object.assign({},gr.levels.labels,cO(t));return{values:r,labels:o}}function cO(e){let t={};return Object.keys(e).forEach(function(r){t[e[r]]=r}),t}gr.levels={values:{fatal:60,error:50,warn:40,info:30,debug:20,trace:10},labels:{10:"trace",20:"debug",30:"info",40:"warn",50:"error",60:"fatal"}};gr.stdSerializers=oO;gr.stdTimeFunctions=Object.assign({},{nullTime:ax,epochTime:ix,unixTime:gO,isoTime:yO});function uO(e){let t=[];e.bindings&&t.push(e.bindings);let r=e[_m];for(;r.parent;)r=r.parent,r.logger.bindings&&t.push(r.logger.bindings);return t.reverse()}function No(e,t,r,o){if(Object.defineProperty(e,o,{value:oo(e.level,r)>oo(o,r)?oa:r[zm][o],writable:!0,enumerable:!0,configurable:!0}),e[o]===oa){if(!t.transmit)return;let a=t.transmit.level||e.level,i=oo(a,r);if(oo(o,r)<i)return}e[o]=dO(e,t,r,o);let n=uO(e);n.length!==0&&(e[o]=lO(n,e[o]))}function lO(e,t){return function(){return t.apply(this,[...e,...arguments])}}function dO(e,t,r,o){return function(n){return function(){let i=t.timestamp(),s=new Array(arguments.length),u=Object.getPrototypeOf&&Object.getPrototypeOf(this)===Fi?Fi:this;for(var c=0;c<s.length;c++)s[c]=arguments[c];var l=!1;if(t.serialize&&(Wm(s,this._serialize,this.serializers,this._stdErrSerialize),l=!0),t.asObject||t.formatters?n.call(u,mO(this,o,s,i,t)):n.apply(u,s),t.transmit){let d=t.transmit.level||e._level,p=oo(d,r),m=oo(o,r);if(m<p)return;pO(this,{ts:i,methodLevel:o,methodValue:m,transmitLevel:d,transmitValue:r.levels.values[t.transmit.level||e._level],send:t.transmit.send,val:oo(e._level,r)},s,l)}}}(e[zm][o])}function mO(e,t,r,o,n){let{level:a,log:i=p=>p}=n.formatters||{},s=r.slice(),u=s[0],c={};if(o&&(c.time=o),a){let p=a(t,e.levels.values[t]);Object.assign(c,p)}else c.level=e.levels.values[t];let l=(e._childLevel|0)+1;if(l<1&&(l=1),u!==null&&typeof u=="object"){for(;l--&&typeof s[0]=="object";)Object.assign(c,s.shift());u=s.length?rx(s.shift(),s):void 0}else typeof u=="string"&&(u=rx(s.shift(),s));return u!==void 0&&(c[n.messageKey]=u),i(c)}function Wm(e,t,r,o){for(let n in e)if(o&&e[n]instanceof Error)e[n]=gr.stdSerializers.err(e[n]);else if(typeof e[n]=="object"&&!Array.isArray(e[n])&&t)for(let a in e[n])t.indexOf(a)>-1&&a in r&&(e[n][a]=r[a](e[n][a]))}function pO(e,t,r,o=!1){let n=t.send,a=t.ts,i=t.methodLevel,s=t.methodValue,u=t.val,c=e._logEvent.bindings;o||Wm(r,e._serialize||Object.keys(e.serializers),e.serializers,e._stdErrSerialize===void 0?!0:e._stdErrSerialize),e._logEvent.ts=a,e._logEvent.messages=r.filter(function(l){return c.indexOf(l)===-1}),e._logEvent.level.label=i,e._logEvent.level.value=s,n(i,e._logEvent,u),e._logEvent=$m(c)}function $m(e){return{ts:0,messages:[],bindings:e||[],level:{label:"",value:0}}}function nx(e){let t={type:e.constructor.name,msg:e.message,stack:e.stack};for(let r in e)t[r]===void 0&&(t[r]=e[r]);return t}function fO(e){return typeof e.timestamp=="function"?e.timestamp:e.timestamp===!1?ax:ix}function cu(){return{}}function jm(e){return e}function oa(){}function ax(){return!1}function ix(){return Date.now()}function gO(){return Math.round(Date.now()/1e3)}function yO(){return new Date(Date.now()).toISOString()}function SO(){function e(t){return typeof t<"u"&&t}try{return typeof globalThis<"u"||Object.defineProperty(Object.prototype,"globalThis",{get:function(){return delete Object.prototype.globalThis,this.globalThis=this},configurable:!0}),globalThis}catch{return e(self)||e(window)||e(this)||{}}}uu.exports.default=gr;uu.exports.pino=gr});var Vp="coveo-headless-internal-state",U=Symbol.for(Vp),Np=e=>new Proxy(e,{ownKeys(t){return Reflect.ownKeys(t).filter(r=>r!==U)},get(t,r,o){return typeof r=="symbol"&&r.description===Vp&&r!==U&&e.logger.warn(`You might be loading Headless twice. Please check your setup.
|
|
19
|
-
If you are trying to access the inner state... Don't`),Reflect.get(t,r,o)}});var so=(e,t=5)=>e+Math.random().toString(36).substring(2,2+t);function Mp(e){return Array.isArray(e)}function $o(e){return e.trim()===""}function Qp(e){let t={};for(let[r,o]of e)t[r]=o;return t}function Ni(e,t){return Object.fromEntries(Object.entries(e).map(([r,o])=>[r,t(o,r)]))}function Mi(e,t){return Object.fromEntries(Object.entries(e).filter(([r,o])=>t(o,r)))}function er(e){if(typeof e!="object"||!e)return e;try{return JSON.parse(JSON.stringify(e))}catch{return e}}function Lp(){let e=null,t=null;return{promise:new Promise((o,n)=>{e=o,t=n}),resolve:e,reject:t}}function Qi(e){let{promise:t,resolve:r}=Lp();return{promise:t,middleware:()=>n=>a=>{n(a),e(a)&&r(a)}}}function GF(e){return e==null?!1:typeof e=="object"&&"meta"in e?e.meta?.arg?.slotId!==void 0:!1}function Bp(e,t){let{promise:r,resolve:o}=Lp(),n=!1,a=s=>t.has(s);return{promise:r,middleware:()=>s=>u=>{s(u),e(u)&&!n&&GF(u)&&!a(u.meta.arg.slotId)&&(n=!0,t.add(u.meta.arg.slotId),o(u))}}}var Xp=It(Gp(),1);var Te=(n=>(n.search="search",n.listing="listing",n.standalone="standalone",n.recommendation="recommendation",n))(Te||{}),xP="recommendation-internal-options",zo=Symbol.for(xP);var $=new Error("Failed to load reducers."),Wo=class extends Error{constructor(){super(),this.name="ExpiredToken",this.message="The token being used to perform the request is expired."}},Bi=class extends Error{constructor(){super(),this.name="InvalidControllerDefinition",this.message=`A controller must be defined for at least one solution type: ${Object.keys(Te).map(t=>t.toLowerCase()).join(", ")}`}},Ko=class extends Error{constructor(t){super(),this.name="MissingControllerProps",this.message=`${t} props are required but were undefined. Ensure they are included when calling \`fetchStaticState\` or \`hydrateStaticState\`.`}},Ui=class extends Error{constructor(t){super(),this.name="MultipleRecommendationError",this.message=`Multiple recommendation controllers found for the same slotId: ${t}. Only one recommendation controller per slotId is supported.`}},uo=class extends Error{constructor(r,o){super();We(this,"statusCode");this.name="Disconnected",this.message=`Client could not connect to the following URL: ${r}`,this.statusCode=o??0}};function Hp(e){let t=[];for(let r in e){let o=encodeURIComponent(r),n=encodeURIComponent(e[r]);t.push(`${o}=${n}`)}return t.join("&")}function Yp(e){return typeof e!="object"||!e?!1:Object.values(e).every(RP)}function RP(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"}function Jp(e){return e===429}var Go=class e{static async call(t){let r=FP(t),{logger:o}=t,n=await e.preprocessRequest(r,t);o.info(n,"Platform request");let{url:a,...i}=n,s=async()=>{let u=await fetch(a,i);if(Jp(u.status))throw u;return u};try{let u=await(0,Xp.backOff)(s,{retry:c=>{let l=c&&Jp(c.status);return l&&o.info("Platform retrying request"),l}});switch(u.status){case 419:case 401:throw o.info("Platform renewing token"),new Wo;case 404:throw new uo(a,u.status);default:return o.info({response:u,requestInfo:n},"Platform response"),u}}catch(u){return u.message==="Failed to fetch"?new uo(a):u}}static async preprocessRequest(t,r){let{origin:o,preprocessRequest:n,logger:a,requestMetadata:i}=r,{signal:s,...u}=t,c=er(u);try{let l=await n(t,o,i);return{...t,...l}}catch(l){a.error(l,"Platform request preprocessing failed. Returning default request options.")}return c}};function Oe(e,t="prod",r="platform"){let o=t==="prod"?"":t,n=r==="platform"?"":`.${r}`;return`https://${e}${n}.org${o}.coveo.com`}function Ke(e,t="prod"){return`${Oe(e,t)}/rest/search/v2`}function fl(e,t="prod"){return`${Oe(e,t,"analytics")}/rest/organizations/${e}/events/v1`}function FP(e){let{url:t,method:r,requestParams:o,contentType:n,accessToken:a,signal:i}=e,s=e.method==="POST"||e.method==="PUT",u=PP(o,n);return{url:t,method:r,headers:{"Content-Type":n,Authorization:`Bearer ${a}`,...e.headers},...s&&{body:u},signal:i}}function PP(e,t){return t==="application/x-www-form-urlencoded"?Yp(e)?Hp(e):"":JSON.stringify(e)}function AP(e){return{statusCode:e.statusCode,type:e.name,message:e.message}}function vP(e){return{statusCode:e.code,type:e.name,message:e.message,ignored:!0}}function gl(e,t){if(t&&e.name==="AbortError")return{error:vP(e)};if(e instanceof uo)return{error:AP(e)};throw e}var Ho=(e,t)=>({...Fa(e,t),requestParams:bP(e)}),bP=e=>{let{trackingId:t,clientId:r,context:o,language:n,country:a,currency:i,page:s,perPage:u,facets:c,sort:l}=e;return{trackingId:t,clientId:r,context:o,language:n,country:a,currency:i,page:s,perPage:u,facets:c,sort:l}},Fa=(e,t)=>{let{url:r,accessToken:o}=e,n=`${r}/${t}`;return{accessToken:o,method:"POST",contentType:"application/json",url:n,origin:"commerceApiFetch",requestMetadata:{method:t}}};var Zp=(e,t)=>({...Fa(e,t),requestParams:wP(e)}),wP=e=>{let{slotId:t,trackingId:r,clientId:o,context:n,language:a,country:i,currency:s,page:u,perPage:c}=e;return{slotId:t,trackingId:r,clientId:o,context:n,language:a,country:i,currency:s,page:u,perPage:c}};var ef=e=>({...Fa(e,"search/querySuggest"),requestParams:EP(e)}),EP=e=>{let{trackingId:t,query:r,clientId:o,context:n,language:a,country:i,currency:s}=e;return{trackingId:t,query:r,clientId:o,context:n,language:a,country:i,currency:s}};var qe=e=>e.error!==void 0,ji=class{constructor(t){this.options=t}async getProductListing(t){return this.query({...Ho(t,"listing"),...this.options})}async search(t){let r=Ho(t,"search");return this.query({...r,requestParams:{...r.requestParams,query:t?.query},...this.options})}async getRecommendations(t){return this.query({...Zp(t,"recommendations"),...this.options})}async productSuggestions(t){let r=Ho(t,"search/productSuggest");return this.query({...r,requestParams:{...r.requestParams,query:t?.query},...this.options})}async querySuggest(t){let r=ef(t);return this.query({...r,requestParams:{...r.requestParams,query:t?.query},...this.options})}async facetSearch(t,r){let o=Ho(t,"facet");return this.query({...o,url:`${o.url}?type=${r}`,requestParams:{...o.requestParams,facetId:t?.facetId,facetQuery:t?.facetQuery,query:t?.query},...this.options})}async plan(t){let r=Ho(t,"search");return this.query({...r,requestParams:{...r.requestParams,query:t?.query},...this.options})}async query(t){let r=await Go.call(t);if(r instanceof Error)return gl(r);let o=await r.json();return r.ok?{success:o}:{error:o}}};function yl(e,t="prod"){return`${Oe(e,t)}/rest/organizations/${e}/commerce/v2`}var _i=e=>e;import{StringValue as _f}from"@coveo/bueno";function ve(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var IP=typeof Symbol=="function"&&Symbol.observable||"@@observable",tf=IP,Sl=()=>Math.random().toString(36).substring(7).split("").join("."),TP={INIT:`@@redux/INIT${Sl()}`,REPLACE:`@@redux/REPLACE${Sl()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${Sl()}`},$i=TP;function Tt(e){if(typeof e!="object"||e===null)return!1;let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||Object.getPrototypeOf(e)===null}function hl(e,t,r){if(typeof e!="function")throw new Error(ve(2));if(typeof t=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(ve(0));if(typeof t=="function"&&typeof r>"u"&&(r=t,t=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(ve(1));return r(hl)(e,t)}let o=e,n=t,a=new Map,i=a,s=0,u=!1;function c(){i===a&&(i=new Map,a.forEach((C,S)=>{i.set(S,C)}))}function l(){if(u)throw new Error(ve(3));return n}function d(C){if(typeof C!="function")throw new Error(ve(4));if(u)throw new Error(ve(5));let S=!0;c();let A=s++;return i.set(A,C),function(){if(S){if(u)throw new Error(ve(6));S=!1,c(),i.delete(A),a=null}}}function p(C){if(!Tt(C))throw new Error(ve(7));if(typeof C.type>"u")throw new Error(ve(8));if(typeof C.type!="string")throw new Error(ve(17));if(u)throw new Error(ve(9));try{u=!0,n=o(n,C)}finally{u=!1}return(a=i).forEach(A=>{A()}),C}function m(C){if(typeof C!="function")throw new Error(ve(10));o=C,p({type:$i.REPLACE})}function f(){let C=d;return{subscribe(S){if(typeof S!="object"||S===null)throw new Error(ve(11));function A(){let x=S;x.next&&x.next(l())}return A(),{unsubscribe:C(A)}},[tf](){return this}}}return p({type:$i.INIT}),{dispatch:p,subscribe:d,getState:l,replaceReducer:m,[tf]:f}}function OP(e){Object.keys(e).forEach(t=>{let r=e[t];if(typeof r(void 0,{type:$i.INIT})>"u")throw new Error(ve(12));if(typeof r(void 0,{type:$i.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(ve(13))})}function Yo(e){let t=Object.keys(e),r={};for(let i=0;i<t.length;i++){let s=t[i];typeof e[s]=="function"&&(r[s]=e[s])}let o=Object.keys(r),n,a;try{OP(r)}catch(i){a=i}return function(s={},u){if(a)throw a;let c=!1,l={};for(let d=0;d<o.length;d++){let p=o[d],m=r[p],f=s[p],h=m(f,u);if(typeof h>"u"){let C=u&&u.type;throw new Error(ve(14))}l[p]=h,c=c||h!==f}return c=c||o.length!==Object.keys(s).length,c?l:s}}function Jo(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,r)=>(...o)=>t(r(...o)))}function rf(...e){return t=>(r,o)=>{let n=t(r,o),a=()=>{throw new Error(ve(15))},i={getState:n.getState,dispatch:(u,...c)=>a(u,...c)},s=e.map(u=>u(i));return a=Jo(...s)(n.dispatch),{...n,dispatch:a}}}function zi(e){return Tt(e)&&"type"in e&&typeof e.type=="string"}var El=Symbol.for("immer-nothing"),Pa=Symbol.for("immer-draftable"),Ge=Symbol.for("immer-state");function be(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var mo=Object.getPrototypeOf;function rt(e){return!!e&&!!e[Ge]}function He(e){return e?cf(e)||Array.isArray(e)||!!e[Pa]||!!e.constructor?.[Pa]||Ea(e)||Ia(e):!1}var qP=Object.prototype.constructor.toString();function cf(e){if(!e||typeof e!="object")return!1;let t=mo(e);if(t===null)return!0;let r=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return r===Object?!0:typeof r=="function"&&Function.toString.call(r)===qP}function Il(e){return rt(e)||be(15,e),e[Ge].base_}function Aa(e,t){po(e)===0?Reflect.ownKeys(e).forEach(r=>{t(r,e[r],e)}):e.forEach((r,o)=>t(o,r,e))}function po(e){let t=e[Ge];return t?t.type_:Array.isArray(e)?1:Ea(e)?2:Ia(e)?3:0}function va(e,t){return po(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Cl(e,t){return po(e)===2?e.get(t):e[t]}function uf(e,t,r){let o=po(e);o===2?e.set(t,r):o===3?e.add(r):e[t]=r}function DP(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function Ea(e){return e instanceof Map}function Ia(e){return e instanceof Set}function lo(e){return e.copy_||e.base_}function Fl(e,t){if(Ea(e))return new Map(e);if(Ia(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);let r=cf(e);if(t===!0||t==="class_only"&&!r){let o=Object.getOwnPropertyDescriptors(e);delete o[Ge];let n=Reflect.ownKeys(o);for(let a=0;a<n.length;a++){let i=n[a],s=o[i];s.writable===!1&&(s.writable=!0,s.configurable=!0),(s.get||s.set)&&(o[i]={configurable:!0,writable:!0,enumerable:s.enumerable,value:e[i]})}return Object.create(mo(e),o)}else{let o=mo(e);if(o!==null&&r)return{...e};let n=Object.create(o);return Object.assign(n,e)}}function Gi(e,t=!1){return Hi(e)||rt(e)||!He(e)||(po(e)>1&&(e.set=e.add=e.clear=e.delete=kP),Object.freeze(e),t&&Object.entries(e).forEach(([r,o])=>Gi(o,!0))),e}function kP(){be(2)}function Hi(e){return Object.isFrozen(e)}var Pl={};function fo(e){let t=Pl[e];return t||be(0,e),t}function VP(e,t){Pl[e]||(Pl[e]=t)}var ba;function lf(){return ba}function NP(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function of(e,t){t&&(fo("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Al(e){vl(e),e.drafts_.forEach(MP),e.drafts_=null}function vl(e){e===ba&&(ba=e.parent_)}function nf(e){return ba=NP(ba,e)}function MP(e){let t=e[Ge];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function af(e,t){t.unfinalizedDrafts_=t.drafts_.length;let r=t.drafts_[0];return e!==void 0&&e!==r?(r[Ge].modified_&&(Al(t),be(4)),He(e)&&(e=Wi(t,e),t.parent_||Ki(t,e)),t.patches_&&fo("Patches").generateReplacementPatches_(r[Ge].base_,e,t.patches_,t.inversePatches_)):e=Wi(t,r,[]),Al(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==El?e:void 0}function Wi(e,t,r){if(Hi(t))return t;let o=t[Ge];if(!o)return Aa(t,(n,a)=>sf(e,o,t,n,a,r)),t;if(o.scope_!==e)return t;if(!o.modified_)return Ki(e,o.base_,!0),o.base_;if(!o.finalized_){o.finalized_=!0,o.scope_.unfinalizedDrafts_--;let n=o.copy_,a=n,i=!1;o.type_===3&&(a=new Set(n),n.clear(),i=!0),Aa(a,(s,u)=>sf(e,o,n,s,u,r,i)),Ki(e,n,!1),r&&e.patches_&&fo("Patches").generatePatches_(o,r,e.patches_,e.inversePatches_)}return o.copy_}function sf(e,t,r,o,n,a,i){if(rt(n)){let s=a&&t&&t.type_!==3&&!va(t.assigned_,o)?a.concat(o):void 0,u=Wi(e,n,s);if(uf(r,o,u),rt(u))e.canAutoFreeze_=!1;else return}else i&&r.add(n);if(He(n)&&!Hi(n)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;Wi(e,n),(!t||!t.scope_.parent_)&&typeof o!="symbol"&&Object.prototype.propertyIsEnumerable.call(r,o)&&Ki(e,n)}}function Ki(e,t,r=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Gi(t,r)}function QP(e,t){let r=Array.isArray(e),o={type_:r?1:0,scope_:t?t.scope_:lf(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1},n=o,a=Tl;r&&(n=[o],a=wa);let{revoke:i,proxy:s}=Proxy.revocable(n,a);return o.draft_=s,o.revoke_=i,s}var Tl={get(e,t){if(t===Ge)return e;let r=lo(e);if(!va(r,t))return LP(e,r,t);let o=r[t];return e.finalized_||!He(o)?o:o===xl(e.base_,t)?(Rl(e),e.copy_[t]=wl(o,e)):o},has(e,t){return t in lo(e)},ownKeys(e){return Reflect.ownKeys(lo(e))},set(e,t,r){let o=df(lo(e),t);if(o?.set)return o.set.call(e.draft_,r),!0;if(!e.modified_){let n=xl(lo(e),t),a=n?.[Ge];if(a&&a.base_===r)return e.copy_[t]=r,e.assigned_[t]=!1,!0;if(DP(r,n)&&(r!==void 0||va(e.base_,t)))return!0;Rl(e),bl(e)}return e.copy_[t]===r&&(r!==void 0||t in e.copy_)||Number.isNaN(r)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=r,e.assigned_[t]=!0),!0},deleteProperty(e,t){return xl(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,Rl(e),bl(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){let r=lo(e),o=Reflect.getOwnPropertyDescriptor(r,t);return o&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:o.enumerable,value:r[t]}},defineProperty(){be(11)},getPrototypeOf(e){return mo(e.base_)},setPrototypeOf(){be(12)}},wa={};Aa(Tl,(e,t)=>{wa[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});wa.deleteProperty=function(e,t){return wa.set.call(this,e,t,void 0)};wa.set=function(e,t,r){return Tl.set.call(this,e[0],t,r,e[0])};function xl(e,t){let r=e[Ge];return(r?lo(r):e)[t]}function LP(e,t,r){let o=df(t,r);return o?"value"in o?o.value:o.get?.call(e.draft_):void 0}function df(e,t){if(!(t in e))return;let r=mo(e);for(;r;){let o=Object.getOwnPropertyDescriptor(r,t);if(o)return o;r=mo(r)}}function bl(e){e.modified_||(e.modified_=!0,e.parent_&&bl(e.parent_))}function Rl(e){e.copy_||(e.copy_=Fl(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var BP=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,r,o)=>{if(typeof t=="function"&&typeof r!="function"){let a=r;r=t;let i=this;return function(u=a,...c){return i.produce(u,l=>r.call(this,l,...c))}}typeof r!="function"&&be(6),o!==void 0&&typeof o!="function"&&be(7);let n;if(He(t)){let a=nf(this),i=wl(t,void 0),s=!0;try{n=r(i),s=!1}finally{s?Al(a):vl(a)}return of(a,o),af(n,a)}else if(!t||typeof t!="object"){if(n=r(t),n===void 0&&(n=t),n===El&&(n=void 0),this.autoFreeze_&&Gi(n,!0),o){let a=[],i=[];fo("Patches").generateReplacementPatches_(t,n,a,i),o(a,i)}return n}else be(1,t)},this.produceWithPatches=(t,r)=>{if(typeof t=="function")return(i,...s)=>this.produceWithPatches(i,u=>t(u,...s));let o,n;return[this.produce(t,r,(i,s)=>{o=i,n=s}),o,n]},typeof e?.autoFreeze=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof e?.useStrictShallowCopy=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){He(e)||be(8),rt(e)&&(e=mf(e));let t=nf(this),r=wl(e,void 0);return r[Ge].isManual_=!0,vl(t),r}finishDraft(e,t){let r=e&&e[Ge];(!r||!r.isManual_)&&be(9);let{scope_:o}=r;return of(o,t),af(void 0,o)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let r;for(r=t.length-1;r>=0;r--){let n=t[r];if(n.path.length===0&&n.op==="replace"){e=n.value;break}}r>-1&&(t=t.slice(r+1));let o=fo("Patches").applyPatches_;return rt(e)?o(e,t):this.produce(e,n=>o(n,t))}};function wl(e,t){let r=Ea(e)?fo("MapSet").proxyMap_(e,t):Ia(e)?fo("MapSet").proxySet_(e,t):QP(e,t);return(t?t.scope_:lf()).drafts_.push(r),r}function mf(e){return rt(e)||be(10,e),pf(e)}function pf(e){if(!He(e)||Hi(e))return e;let t=e[Ge],r;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,r=Fl(e,t.scope_.immer_.useStrictShallowCopy_)}else r=Fl(e,!0);return Aa(r,(o,n)=>{uf(r,o,pf(n))}),t&&(t.finalized_=!1),r}function ff(){let t="replace",r="add",o="remove";function n(p,m,f,h){switch(p.type_){case 0:case 2:return i(p,m,f,h);case 1:return a(p,m,f,h);case 3:return s(p,m,f,h)}}function a(p,m,f,h){let{base_:C,assigned_:S}=p,A=p.copy_;A.length<C.length&&([C,A]=[A,C],[f,h]=[h,f]);for(let y=0;y<C.length;y++)if(S[y]&&A[y]!==C[y]){let x=m.concat([y]);f.push({op:t,path:x,value:d(A[y])}),h.push({op:t,path:x,value:d(C[y])})}for(let y=C.length;y<A.length;y++){let x=m.concat([y]);f.push({op:r,path:x,value:d(A[y])})}for(let y=A.length-1;C.length<=y;--y){let x=m.concat([y]);h.push({op:o,path:x})}}function i(p,m,f,h){let{base_:C,copy_:S}=p;Aa(p.assigned_,(A,y)=>{let x=Cl(C,A),I=Cl(S,A),v=y?va(C,A)?t:r:o;if(x===I&&v===t)return;let R=m.concat(A);f.push(v===o?{op:v,path:R}:{op:v,path:R,value:I}),h.push(v===r?{op:o,path:R}:v===o?{op:r,path:R,value:d(x)}:{op:t,path:R,value:d(x)})})}function s(p,m,f,h){let{base_:C,copy_:S}=p,A=0;C.forEach(y=>{if(!S.has(y)){let x=m.concat([A]);f.push({op:o,path:x,value:y}),h.unshift({op:r,path:x,value:y})}A++}),A=0,S.forEach(y=>{if(!C.has(y)){let x=m.concat([A]);f.push({op:r,path:x,value:y}),h.unshift({op:o,path:x,value:y})}A++})}function u(p,m,f,h){f.push({op:t,path:[],value:m===El?void 0:m}),h.push({op:t,path:[],value:p})}function c(p,m){return m.forEach(f=>{let{path:h,op:C}=f,S=p;for(let I=0;I<h.length-1;I++){let v=po(S),R=h[I];typeof R!="string"&&typeof R!="number"&&(R=""+R),(v===0||v===1)&&(R==="__proto__"||R==="constructor")&&be(19),typeof S=="function"&&R==="prototype"&&be(19),S=Cl(S,R),typeof S!="object"&&be(18,h.join("/"))}let A=po(S),y=l(f.value),x=h[h.length-1];switch(C){case t:switch(A){case 2:return S.set(x,y);case 3:be(16);default:return S[x]=y}case r:switch(A){case 1:return x==="-"?S.push(y):S.splice(x,0,y);case 2:return S.set(x,y);case 3:return S.add(y);default:return S[x]=y}case o:switch(A){case 1:return S.splice(x,1);case 2:return S.delete(x);case 3:return S.delete(f.value);default:return delete S[x]}default:be(17,C)}}),p}function l(p){if(!He(p))return p;if(Array.isArray(p))return p.map(l);if(Ea(p))return new Map(Array.from(p.entries()).map(([f,h])=>[f,l(h)]));if(Ia(p))return new Set(Array.from(p).map(l));let m=Object.create(mo(p));for(let f in p)m[f]=l(p[f]);return va(p,Pa)&&(m[Pa]=p[Pa]),m}function d(p){return rt(p)?l(p):p}VP("Patches",{applyPatches_:c,generatePatches_:n,generateReplacementPatches_:u})}var ot=new BP,rr=ot.produce,Yi=ot.produceWithPatches.bind(ot),WN=ot.setAutoFreeze.bind(ot),KN=ot.setUseStrictShallowCopy.bind(ot),Ol=ot.applyPatches.bind(ot),GN=ot.createDraft.bind(ot),HN=ot.finishDraft.bind(ot);function UP(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function jP(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function _P(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(r=>typeof r=="function")){let r=e.map(o=>typeof o=="function"?`function ${o.name||"unnamed"}()`:typeof o).join(", ");throw new TypeError(`${t}[${r}]`)}}var gf=e=>Array.isArray(e)?e:[e];function $P(e){let t=Array.isArray(e[0])?e[0]:e;return _P(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function zP(e,t){let r=[],{length:o}=e;for(let n=0;n<o;n++)r.push(e[n].apply(null,t));return r}var XN=Symbol();var ZN=Object.getPrototypeOf({});var WP=class{constructor(e){this.value=e}deref(){return this.value}},KP=typeof WeakRef<"u"?WeakRef:WP,GP=0,yf=1;function Ji(){return{s:GP,v:void 0,o:null,p:null}}function Xo(e,t={}){let r=Ji(),{resultEqualityCheck:o}=t,n,a=0;function i(){let s=r,{length:u}=arguments;for(let d=0,p=u;d<p;d++){let m=arguments[d];if(typeof m=="function"||typeof m=="object"&&m!==null){let f=s.o;f===null&&(s.o=f=new WeakMap);let h=f.get(m);h===void 0?(s=Ji(),f.set(m,s)):s=h}else{let f=s.p;f===null&&(s.p=f=new Map);let h=f.get(m);h===void 0?(s=Ji(),f.set(m,s)):s=h}}let c=s,l;if(s.s===yf)l=s.v;else if(l=e.apply(null,arguments),a++,o){let d=n?.deref?.()??n;d!=null&&o(d,l)&&(l=d,a!==0&&a--),n=typeof l=="object"&&l!==null||typeof l=="function"?new KP(l):l}return c.s=yf,c.v=l,l}return i.clearCache=()=>{r=Ji(),i.resetResultsCount()},i.resultsCount=()=>a,i.resetResultsCount=()=>{a=0},i}function Sf(e,...t){let r=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,o=(...n)=>{let a=0,i=0,s,u={},c=n.pop();typeof c=="object"&&(u=c,c=n.pop()),UP(c,`createSelector expects an output function after the inputs, but received: [${typeof c}]`);let l={...r,...u},{memoize:d,memoizeOptions:p=[],argsMemoize:m=Xo,argsMemoizeOptions:f=[],devModeChecks:h={}}=l,C=gf(p),S=gf(f),A=$P(n),y=d(function(){return a++,c.apply(null,arguments)},...C),x=!0,I=m(function(){i++;let R=zP(A,arguments);return s=y.apply(null,R),s},...S);return Object.assign(I,{resultFunc:c,memoizedResultFunc:y,dependencies:A,dependencyRecomputations:()=>i,resetDependencyRecomputations:()=>{i=0},lastResult:()=>s,recomputations:()=>a,resetRecomputations:()=>{a=0},memoize:d,argsMemoize:m})};return Object.assign(o,{withTypes:()=>o}),o}var Q=Sf(Xo),HP=Object.assign((e,t=Q)=>{jP(e,`createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ${typeof e}`);let r=Object.keys(e),o=r.map(a=>e[a]);return t(o,(...a)=>a.reduce((i,s,u)=>(i[r[u]]=s,i),{}))},{withTypes:()=>HP});function hf(e){return({dispatch:r,getState:o})=>n=>a=>typeof a=="function"?a(r,o,e):n(a)}var Cf=hf(),xf=hf;var YP=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Jo:Jo.apply(null,arguments)},uM=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(e){return e}},JP=e=>e&&typeof e.match=="function";function g(e,t){function r(...o){if(t){let n=t(...o);if(!n)throw new Error(Ft(0));return{type:e,payload:n.payload,..."meta"in n&&{meta:n.meta},..."error"in n&&{error:n.error}}}return{type:e,payload:o[0]}}return r.toString=()=>`${e}`,r.type=e,r.match=o=>zi(o)&&o.type===e,r}var vf=class Ta extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,Ta.prototype)}static get[Symbol.species](){return Ta}concat(...t){return super.concat.apply(this,t)}prepend(...t){return t.length===1&&Array.isArray(t[0])?new Ta(...t[0].concat(this)):new Ta(...t.concat(this))}};function Rf(e){return He(e)?rr(e,()=>{}):e}function Ff(e,t,r){return e.has(t)?e.get(t):e.set(t,r(t)).get(t)}function XP(e){return typeof e=="boolean"}var ZP=()=>function(t){let{thunk:r=!0,immutableCheck:o=!0,serializableCheck:n=!0,actionCreatorCheck:a=!0}=t??{},i=new vf;return r&&(XP(r)?i.push(Cf):i.push(xf(r.extraArgument))),i},Oa="RTK_autoBatch",en=()=>e=>({payload:e,meta:{[Oa]:!0}}),Pf=e=>t=>{setTimeout(t,e)},eA=(e={type:"raf"})=>t=>(...r)=>{let o=t(...r),n=!0,a=!1,i=!1,s=new Set,u=e.type==="tick"?queueMicrotask:e.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Pf(10):e.type==="callback"?e.queueNotification:Pf(e.timeout),c=()=>{i=!1,a&&(a=!1,s.forEach(l=>l()))};return Object.assign({},o,{subscribe(l){let d=()=>n&&l(),p=o.subscribe(d);return s.add(l),()=>{p(),s.delete(l)}},dispatch(l){try{return n=!l?.meta?.[Oa],a=!n,a&&(i||(i=!0,u(c))),o.dispatch(l)}finally{n=!0}}})},tA=e=>function(r){let{autoBatch:o=!0}=r??{},n=new vf(e);return o&&n.push(eA(typeof o=="object"?o:void 0)),n};function bf(e){let t=ZP(),{reducer:r=void 0,middleware:o,devTools:n=!0,preloadedState:a=void 0,enhancers:i=void 0}=e||{},s;if(typeof r=="function")s=r;else if(Tt(r))s=Yo(r);else throw new Error(Ft(1));let u;typeof o=="function"?u=o(t):u=t();let c=Jo;n&&(c=YP({trace:!1,...typeof n=="object"&&n}));let l=rf(...u),d=tA(l),p=typeof i=="function"?i(d):d(),m=c(...p);return hl(s,a,m)}function wf(e){let t={},r=[],o,n={addCase(a,i){let s=typeof a=="string"?a:a.type;if(!s)throw new Error(Ft(28));if(s in t)throw new Error(Ft(29));return t[s]=i,n},addMatcher(a,i){return r.push({matcher:a,reducer:i}),n},addDefaultCase(a){return o=a,n}};return e(n),[t,r,o]}function rA(e){return typeof e=="function"}function j(e,t){let[r,o,n]=wf(t),a;if(rA(e))a=()=>Rf(e());else{let s=Rf(e);a=()=>s}function i(s=a(),u){let c=[r[u.type],...o.filter(({matcher:l})=>l(u)).map(({reducer:l})=>l)];return c.filter(l=>!!l).length===0&&(c=[n]),c.reduce((l,d)=>{if(d)if(rt(l)){let m=d(l,u);return m===void 0?l:m}else{if(He(l))return rr(l,p=>d(p,u));{let p=d(l,u);if(p===void 0){if(l===null)return l;throw Error("A case reducer on a non-draftable value must not return undefined")}return p}}return l},s)}return i.getInitialState=a,i}var Ef=(e,t)=>JP(e)?e.match(t):e(t);function Ot(...e){return t=>e.some(r=>Ef(r,t))}function Zo(...e){return t=>e.every(r=>Ef(r,t))}function Zi(e,t){if(!e||!e.meta)return!1;let r=typeof e.meta.requestId=="string",o=t.indexOf(e.meta.requestStatus)>-1;return r&&o}function qa(e){return typeof e[0]=="function"&&"pending"in e[0]&&"fulfilled"in e[0]&&"rejected"in e[0]}function es(...e){return e.length===0?t=>Zi(t,["pending"]):qa(e)?Ot(...e.map(t=>t.pending)):es()(e[0])}function go(...e){return e.length===0?t=>Zi(t,["rejected"]):qa(e)?Ot(...e.map(t=>t.rejected)):go()(e[0])}function Da(...e){let t=r=>r&&r.meta&&r.meta.rejectedWithValue;return e.length===0?Zo(go(...e),t):qa(e)?Zo(go(...e),t):Da()(e[0])}function or(...e){return e.length===0?t=>Zi(t,["fulfilled"]):qa(e)?Ot(...e.map(t=>t.fulfilled)):or()(e[0])}function ts(...e){return e.length===0?t=>Zi(t,["pending","fulfilled","rejected"]):qa(e)?Ot(...e.flatMap(t=>[t.pending,t.rejected,t.fulfilled])):ts()(e[0])}var oA="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",rs=(e=21)=>{let t="",r=e;for(;r--;)t+=oA[Math.random()*64|0];return t},nA=["name","message","stack","code"],ql=class{constructor(e,t){We(this,"_type");this.payload=e,this.meta=t}},Af=class{constructor(e,t){We(this,"_type");this.payload=e,this.meta=t}},aA=e=>{if(typeof e=="object"&&e!==null){let t={};for(let r of nA)typeof e[r]=="string"&&(t[r]=e[r]);return t}return{message:String(e)}},_=(()=>{function e(t,r,o){let n=g(t+"/fulfilled",(u,c,l,d)=>({payload:u,meta:{...d||{},arg:l,requestId:c,requestStatus:"fulfilled"}})),a=g(t+"/pending",(u,c,l)=>({payload:void 0,meta:{...l||{},arg:c,requestId:u,requestStatus:"pending"}})),i=g(t+"/rejected",(u,c,l,d,p)=>({payload:d,error:(o&&o.serializeError||aA)(u||"Rejected"),meta:{...p||{},arg:l,requestId:c,rejectedWithValue:!!d,requestStatus:"rejected",aborted:u?.name==="AbortError",condition:u?.name==="ConditionError"}}));function s(u){return(c,l,d)=>{let p=o?.idGenerator?o.idGenerator(u):rs(),m=new AbortController,f,h;function C(A){h=A,m.abort()}let S=async function(){let A;try{let x=o?.condition?.(u,{getState:l,extra:d});if(sA(x)&&(x=await x),x===!1||m.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};let I=new Promise((v,R)=>{f=()=>{R({name:"AbortError",message:h||"Aborted"})},m.signal.addEventListener("abort",f)});c(a(p,u,o?.getPendingMeta?.({requestId:p,arg:u},{getState:l,extra:d}))),A=await Promise.race([I,Promise.resolve(r(u,{dispatch:c,getState:l,extra:d,requestId:p,signal:m.signal,abort:C,rejectWithValue:(v,R)=>new ql(v,R),fulfillWithValue:(v,R)=>new Af(v,R)})).then(v=>{if(v instanceof ql)throw v;return v instanceof Af?n(v.payload,p,u,v.meta):n(v,p,u)})])}catch(x){A=x instanceof ql?i(null,p,u,x.payload,x.meta):i(x,p,u)}finally{f&&m.signal.removeEventListener("abort",f)}return o&&!o.dispatchConditionRejection&&i.match(A)&&A.meta.condition||c(A),A}();return Object.assign(S,{abort:C,requestId:p,arg:u,unwrap(){return S.then(iA)}})}}return Object.assign(s,{pending:a,rejected:i,fulfilled:n,settled:Ot(i,n),typePrefix:t})}return e.withTypes=()=>e,e})();function iA(e){if(e.meta&&e.meta.rejectedWithValue)throw e.payload;if(e.error)throw e.error;return e.payload}function sA(e){return e!==null&&typeof e=="object"&&typeof e.then=="function"}var If=Symbol.for("rtk-slice-createasyncthunk"),fM={[If]:_};function cA(e,t){return`${e}/${t}`}function uA({creators:e}={}){let t=e?.asyncThunk?.[If];return function(o){let{name:n,reducerPath:a=n}=o;if(!n)throw new Error(Ft(11));typeof process<"u";let i=(typeof o.reducers=="function"?o.reducers(dA()):o.reducers)||{},s=Object.keys(i),u={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},c={addCase(A,y){let x=typeof A=="string"?A:A.type;if(!x)throw new Error(Ft(12));if(x in u.sliceCaseReducersByType)throw new Error(Ft(13));return u.sliceCaseReducersByType[x]=y,c},addMatcher(A,y){return u.sliceMatchers.push({matcher:A,reducer:y}),c},exposeAction(A,y){return u.actionCreators[A]=y,c},exposeCaseReducer(A,y){return u.sliceCaseReducersByName[A]=y,c}};s.forEach(A=>{let y=i[A],x={reducerName:A,type:cA(n,A),createNotation:typeof o.reducers=="function"};pA(y)?gA(x,y,c,t):mA(x,y,c)});function l(){let[A={},y=[],x=void 0]=typeof o.extraReducers=="function"?wf(o.extraReducers):[o.extraReducers],I={...A,...u.sliceCaseReducersByType};return j(o.initialState,v=>{for(let R in I)v.addCase(R,I[R]);for(let R of u.sliceMatchers)v.addMatcher(R.matcher,R.reducer);for(let R of y)v.addMatcher(R.matcher,R.reducer);x&&v.addDefaultCase(x)})}let d=A=>A,p=new Map,m;function f(A,y){return m||(m=l()),m(A,y)}function h(){return m||(m=l()),m.getInitialState()}function C(A,y=!1){function x(v){let R=v[A];return typeof R>"u"&&y&&(R=h()),R}function I(v=d){let R=Ff(p,y,()=>new WeakMap);return Ff(R,v,()=>{let P={};for(let[b,T]of Object.entries(o.selectors??{}))P[b]=lA(T,v,h,y);return P})}return{reducerPath:A,getSelectors:I,get selectors(){return I(x)},selectSlice:x}}let S={name:n,reducer:f,actions:u.actionCreators,caseReducers:u.sliceCaseReducersByName,getInitialState:h,...C(a),injectInto(A,{reducerPath:y,...x}={}){let I=y??a;return A.inject({reducerPath:I,reducer:f},x),{...S,...C(I,!0)}}};return S}}function lA(e,t,r,o){function n(a,...i){let s=t(a);return typeof s>"u"&&o&&(s=r()),e(s,...i)}return n.unwrapped=e,n}var yo=uA();function dA(){function e(t,r){return{_reducerDefinitionType:"asyncThunk",payloadCreator:t,...r}}return e.withTypes=()=>e,{reducer(t){return Object.assign({[t.name](...r){return t(...r)}}[t.name],{_reducerDefinitionType:"reducer"})},preparedReducer(t,r){return{_reducerDefinitionType:"reducerWithPrepare",prepare:t,reducer:r}},asyncThunk:e}}function mA({type:e,reducerName:t,createNotation:r},o,n){let a,i;if("reducer"in o){if(r&&!fA(o))throw new Error(Ft(17));a=o.reducer,i=o.prepare}else a=o;n.addCase(e,a).exposeCaseReducer(t,a).exposeAction(t,i?g(e,i):g(e))}function pA(e){return e._reducerDefinitionType==="asyncThunk"}function fA(e){return e._reducerDefinitionType==="reducerWithPrepare"}function gA({type:e,reducerName:t},r,o,n){if(!n)throw new Error(Ft(18));let{payloadCreator:a,fulfilled:i,pending:s,rejected:u,settled:c,options:l}=r,d=n(e,a,l);o.exposeAction(t,d),i&&o.addCase(d.fulfilled,i),s&&o.addCase(d.pending,s),u&&o.addCase(d.rejected,u),c&&o.addMatcher(d.settled,c),o.exposeCaseReducer(t,{fulfilled:i||Xi,pending:s||Xi,rejected:u||Xi,settled:c||Xi})}function Xi(){}var Tf="listener",Of="completed",qf="cancelled",gM=`task-${qf}`,yM=`task-${Of}`,SM=`${Tf}-${qf}`,hM=`${Tf}-${Of}`;var{assign:Df}=Object;var Dl="listenerMiddleware";var yA=Df(g(`${Dl}/add`),{withTypes:()=>yA}),CM=g(`${Dl}/removeAll`),SA=Df(g(`${Dl}/remove`),{withTypes:()=>SA});var xM=Symbol.for("rtk-state-proxy-original");function Ft(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}import{Schema as hA,SchemaValidationError as CA,StringValue as ka,RecordValue as xA,ArrayValue as RA}from"@coveo/bueno";var D=new ka({required:!0,emptyAllowed:!1}),ne=new ka({required:!1,emptyAllowed:!1}),me=new ka({required:!0,emptyAllowed:!0}),kf=new ka({required:!1,emptyAllowed:!0}),os=new RA({each:D,required:!0}),Vf=new ka({required:!1,emptyAllowed:!1,regex:/^\d+\.\d+\.\d+$/}),je=({message:e,name:t,stack:r})=>({message:e,name:t,stack:r}),Se=(e,t)=>{if("required"in t)return{payload:new hA({value:t}).validate({value:e}).value};let n=new xA({options:{required:!0},values:t}).validate(e);if(n)throw new CA(n);return{payload:e}},F=(e,t)=>{try{return Se(e,t)}catch(r){return{payload:e,error:je(r)}}},Ye=(e,t,r,o)=>{let n=`Check the initialState of ${o}`;return Nf(e,t,r,n,"Controller initialization error")},_e=(e,t,r,o)=>{let n=`Check the options of ${o}`;return Nf(e,t,r,n,"Controller initialization error")},Nf=(e,t,r,o,n)=>{try{return t.validate(r,o)}catch(a){throw e.logger.error(a,n),a}};import{ArrayValue as FA,BooleanValue as Qf,RecordValue as PA,StringValue as Va,Value as AA}from"@coveo/bueno";var So="3.23.2-pre.57bb336b29",Mf=["@coveo/atomic","@coveo/quantic"];var kl=()=>ne,Lf=()=>D,ho=g("configuration/updateBasicConfiguration",e=>F(e,{accessToken:ne,environment:new Va({required:!1,constrainTo:["prod","hipaa","stg","dev"]}),organizationId:ne})),Bf=g("configuration/updateSearchConfiguration",e=>F(e,{proxyBaseUrl:new Va({required:!1,url:!0}),pipeline:new Va({required:!1,emptyAllowed:!0}),searchHub:ne,timezone:ne,locale:ne,authenticationProviders:new FA({required:!1,each:D})})),tn={enabled:new Qf({default:!0}),originContext:kl(),originLevel2:kl(),originLevel3:kl(),proxyBaseUrl:new Va({required:!1,url:!0}),runtimeEnvironment:new AA,anonymous:new Qf({default:!1}),deviceId:ne,userDisplayName:ne,documentLocation:ne,trackingId:ne,analyticsMode:new Va({constrainTo:["legacy","next"],required:!1,default:"next"}),source:new PA({options:{required:!1},values:Mf.reduce((e,t)=>(e[t]=Vf,e),{})})},Vl=g("configuration/updateAnalyticsConfiguration",e=>F(e,tn)),ns=g("configuration/analytics/disable"),as=g("configuration/analytics/enable"),Uf=g("configuration/analytics/originlevel2",e=>F(e,{originLevel2:Lf()})),jf=g("configuration/analytics/originlevel3",e=>F(e,{originLevel3:Lf()}));var rn=g("commerce/configuration/updateBasicConfiguration",e=>F(e,{accessToken:ne,environment:new _f({required:!1,constrainTo:["prod","hipaa","stg","dev"]}),organizationId:ne})),on=g("commerce/configuration/updateProxyBaseUrl",e=>F(e,{proxyBaseUrl:new _f({required:!1,url:!0})})),nn=g("commerce/configuration/updateAnalyticsConfiguration",e=>F(e,{enabled:tn.enabled,proxyBaseUrl:tn.proxyBaseUrl,source:tn.source,trackingId:tn.trackingId})),is=g("commerce/configuration/analytics/disable"),ss=g("commerce/configuration/analytics/enable");import{isNullOrUndefined as Co}from"@coveo/bueno";var $f=()=>({accessToken:"",environment:"prod",organizationId:"",analytics:{enabled:!0,trackingId:"",source:{}},commerce:{}});var Nl=j($f(),e=>e.addCase(rn,(t,r)=>{zf(t,r.payload)}).addCase(ho,(t,r)=>{zf(t,r.payload)}).addCase(on,(t,r)=>{vA(t,r.payload)}).addCase(nn,(t,r)=>{bA(t,r.payload)}).addCase(is,t=>{t.analytics.enabled=!1}).addCase(ss,t=>{t.analytics.enabled=!0}));function zf(e,t){Co(t.accessToken)||(e.accessToken=t.accessToken),e.environment=t.environment??"prod",Co(t.organizationId)||(e.organizationId=t.organizationId)}function vA(e,t){Co(t.proxyBaseUrl)||(e.commerce.apiBaseUrl=t.proxyBaseUrl)}function bA(e,t){Co(t.enabled)||(e.analytics.enabled=t.enabled),Co(t.proxyBaseUrl)||(e.analytics.apiBaseUrl=t.proxyBaseUrl),Co(t.source)||(e.analytics.source=t.source),Co(t.trackingId)||(e.analytics.trackingId=t.trackingId)}function an(e){return e.currency}var Wf=(e,t)=>({currency:an(t.commerceContext),products:wA(t.cart),transaction:e}),Kf=(e,t)=>({currency:an(t.commerceContext),...e}),xo=Q(e=>e.cart,e=>e.cartItems,(e,t)=>t.map(r=>e[r])),wA=Q(xo,e=>e.map(({quantity:t,...r})=>({quantity:t,product:r})));import{ArrayValue as EA,NumberValue as Gf,RecordValue as IA,Schema as TA,StringValue as OA}from"@coveo/bueno";var Ml={productId:D,quantity:new Gf({required:!0,min:0}),name:new OA({required:!1}),price:new Gf({required:!1,min:0})},Ql=new EA({each:new IA({values:{...Ml}})}),Ll={items:Ql},Hf=new TA(Ll);var xr=g("commerce/cart/setItems",e=>F(e,Ql)),sn=g("commerce/cart/updateItemQuantity",e=>F(e,Ml)),cn=g("commerce/cart/purchase"),cs=_("commerce/cart/emit/purchaseEvent",async(e,{extra:t,getState:r})=>{let o=Wf(e,r()),{relay:n}=t;n.emit("ec.purchase",o)}),us=_("commerce/cart/emit/cartActionEvent",async(e,{extra:t,getState:r})=>{let o=Kf(e,r()),{relay:n}=t;n.emit("ec.cartAction",o)});function W(e){let t,r=new Map,o=()=>r.size===0,n=a=>{try{let i=JSON.stringify(a),s=t!==i;return t=i,s}catch(i){return console.warn('Could not detect if state has changed, check the controller "get state method"',i),!0}};return{subscribe(a){a();let i=Symbol(),s;return o()&&(t=JSON.stringify(this.state),s=e.subscribe(()=>{n(this.state)&&r.forEach(u=>u())})),r.set(i,a),()=>{r.delete(i),o()&&s&&s()}},get state(){return{}}}}function Yf(e,t){return e.cart[Ro(t)]}var Jf=Q(xo,e=>e.reduce((t,r)=>t+r.quantity,0)),Xf=Q(xo,e=>e.reduce((t,r)=>t+r.price*r.quantity,0));function Zf(e,t={}){if(!qA(e))throw $;let{dispatch:r}=e,o=W(e),n=()=>e[U].cart,a={...t.initialState};Ye(e,Hf,a,"buildCart"),a.items!==void 0&&r(xr(a.items));function i(l,d){return d?d.quantity!==l.quantity:!0}function s(l,d){return!d||l.quantity>d.quantity?"add":"remove"}function u(l,d){return d?l.name===d.name&&l.price===d.price&&l.quantity===d.quantity:!1}function c(l,d){let{quantity:p,...m}=l,f=s(l,d),h=d?Math.abs(p-d.quantity):p;return{action:f,quantity:h,product:m}}return{...o,empty:function(){for(let l of xo(n()))this.updateItemQuantity({...l,quantity:0})},purchase(l){r(cs(l)),r(cn())},updateItemQuantity(l){let d=Yf(n(),l);!d&&l.quantity<=0||u(l,d)||(i(l,d)&&r(us(c(l,d))),r(sn(l)))},get state(){let l=n();return{items:xo(l),totalQuantity:Jf(l),totalPrice:Xf(l)}}}}function Ro(e){return`${e.productId},${e.name},${e.price}`}function qA(e){return e.addReducers({cart:un}),!0}var ls=()=>({cartItems:[],cart:{},purchasedItems:[],purchased:{}}),eg=e=>rg(e.cartItems,e.cart),tg=e=>rg(e.purchasedItems,e.purchased);function rg(e,t){let r=e.reduce((o,n)=>{let{productId:a,quantity:i}=t[n];return a in o||(o[a]={productId:a,quantity:0}),o[a].quantity+=i,o},{});return[...Object.values(r)]}var un=j(ls(),e=>{e.addCase(xr,(t,{payload:r})=>{let{cart:o,cartItems:n}=r.reduce((a,i)=>{let s=Ro(i);return{cartItems:[...a.cartItems,s],cart:{...a.cart,[s]:i},purchasedItems:[],purchased:{}}},ls());og(t,n,o)}).addCase(sn,(t,{payload:r})=>{let o=Ro(r);if(!(o in t.cart)){DA(r,t);return}if(r.quantity<=0){kA(r,t);return}t.cart[o]=r}).addCase(cn,t=>{VA(t);let{cart:r,cartItems:o}=ls();og(t,o,r)})});function og(e,t,r){e.cartItems=t,e.cart=r}function DA(e,t){if(e.quantity<=0)return;let r=Ro(e);t.cartItems=[...t.cartItems,r],t.cart[r]=e}function kA(e,t){let r=Ro(e);t.cartItems=t.cartItems.filter(o=>o!==r),delete t.cart[r]}function VA(e){for(let t of e.cartItems){if(t in e.purchased){e.purchased[t].quantity+=e.cart[t].quantity;continue}e.purchasedItems=[...e.purchasedItems,t],e.purchased[t]=e.cart[t]}}import{NumberValue as ng,RecordValue as ag,Schema as NA,StringValue as MA}from"@coveo/bueno";var QA=Intl.supportedValuesOf("currency"),LA=new MA({required:!0,emptyAllowed:!1,constrainTo:QA}),Bl={url:D},Ul={latitude:new ng({min:-90,max:90,required:!0}),longitude:new ng({min:-180,max:180,required:!0})},Na={language:D,country:D,currency:LA,view:new ag({options:{required:!0},values:Bl}),location:new ag({options:{required:!1},values:Ul})},ig=new NA(Na);var ce=g("commerce/context/set",e=>F(e,Na)),le=g("commerce/context/setView",e=>F(e,Bl)),ln=g("commerce/context/setLocation",e=>F(e,Ul));var sg=()=>({language:"",country:"",currency:"",view:{url:""}});var qt=j(sg(),e=>{e.addCase(ce,(t,{payload:r})=>r).addCase(le,(t,{payload:r})=>{t.view=r}).addCase(ln,(t,{payload:r})=>{t.location=r})});var ds=()=>({correctedQuery:"",corrections:[],originalQuery:""});import{BooleanValue as sv,RecordValue as cv,StringValue as Ig}from"@coveo/bueno";var ct=g("breadcrumb/deselectAll"),Rr=g("breadcrumb/deselectAllNonBreadcrumbs");var Fr=Q(e=>e.source,e=>Object.entries(e).map(([t,r])=>`${t}@${r}`).concat(`@coveo/headless@${So}`));var Pr=(e,t)=>{let{view:r,location:o,...n}=e.commerceContext;return{accessToken:e.configuration.accessToken,url:e.configuration.commerce.apiBaseUrl??yl(e.configuration.organizationId,e.configuration.environment),organizationId:e.configuration.organizationId,trackingId:e.configuration.analytics.trackingId,...n,...e.configuration.analytics.enabled?{clientId:t.clientId}:{},context:{user:{...o,...t.userAgent?{userAgent:t.userAgent}:{}},view:{...r,...t.referrer?{referrer:t.referrer}:{}},capture:t.capture??e.configuration.analytics.enabled,cart:eg(e.cart),source:Fr(e.configuration.analytics)}}};import{ArrayValue as jA,EnumValue as lg,StringValue as dg,RecordValue as mg}from"@coveo/bueno";import{ArrayValue as BA,EnumValue as cg,RecordValue as ug,StringValue as UA}from"@coveo/bueno";var Pt=(r=>(r.Relevance="relevance",r.Fields="fields",r))(Pt||{}),dn=(r=>(r.Ascending="asc",r.Descending="desc",r))(dn||{}),nr=()=>({by:"relevance"});var mQ=new ug({options:{required:!1},values:{by:new cg({enum:Pt,required:!0}),fields:new BA({each:new ug({values:{name:new UA,direction:new cg({enum:dn})}})})}});var jl=e=>({by:"fields",fields:e}),pg=new mg({options:{required:!1},values:{by:new lg({enum:Pt,required:!0}),fields:new jA({each:new mg({values:{field:new dg({required:!0}),direction:new lg({enum:dn}),displayName:new dg}})})}});var ms=(e,t,r)=>({...Pr(e,t),..._A(e,r)}),_A=(e,t)=>{let r=t?e.commercePagination?.recommendations[t]:e.commercePagination?.principal;return r&&{page:r.page,...r.perPage&&{perPage:r.perPage}}};var ut=(e,t)=>({...ms(e,t),facets:[...$A(e)],...e.commerceSort&&{sort:zA(e.commerceSort.appliedSort)}});function $A(e){return!e.facetOrder||!e.commerceFacetSet?[]:e.facetOrder.filter(t=>e.commerceFacetSet?.[t]).map(t=>e.manualNumericFacetSet?.[t]?.manualRange?{facetId:t,field:t,numberOfValues:1,isFieldExpanded:!1,preventAutoSelect:!0,type:"numericalRange",values:[e.manualNumericFacetSet[t].manualRange],initialNumberOfValues:1}:e.commerceFacetSet[t].request).filter(t=>t&&t.values.length>0)}function zA(e){return e.by==="relevance"?{sortCriteria:"relevance"}:{sortCriteria:"fields",fields:e.fields.map(({name:t,direction:r})=>({field:t,direction:r}))}}import{BooleanValue as _l,NumberValue as WA}from"@coveo/bueno";var Fo=g("commerce/facets/core/updateNumberOfValues",e=>F(e,{facetId:D,numberOfValues:new WA({required:!0,min:1})})),Po=g("commerce/facets/core/updateIsFieldExpanded",e=>F(e,{facetId:D,isFieldExpanded:new _l({required:!0})})),pe=g("commerce/facets/core/clearAll"),De=g("commerce/facets/core/deselectAllValues",e=>F(e,{facetId:D})),Ao=g("commerce/facets/core/updateFreezeCurrentValues",e=>F(e,{facetId:D,freezeCurrentValues:new _l({required:!0})})),mn=g("commerce/facets/core/updateAutoSelectionForAll",e=>F(e,{allow:new _l({required:!0})}));import{NumberValue as fg}from"@coveo/bueno";var ps={slotId:kf},KA={...ps,pageSize:new fg({required:!0,min:0})},ar=g("commerce/pagination/setPageSize",e=>F(e,KA)),GA={...ps,page:new fg({required:!0,min:0})},Dt=g("commerce/pagination/selectPage",e=>F(e,GA)),Ar=g("commerce/pagination/nextPage",e=>F(e,ps)),vr=g("commerce/pagination/previousPage",e=>F(e,ps)),pn=g("commerce/pagination/registerRecommendationsSlot",e=>F(e,{slotId:D}));var br=Q(e=>e.commercePagination?.principal.perPage||0,e=>e),fs=Q((e,t)=>e.commercePagination?.recommendations[t]?.perPage||0,e=>e),wr=Q(e=>e.commercePagination?.principal.totalEntries||0,e=>e),gs=Q((e,t)=>e.commercePagination?.recommendations[t]?.totalEntries||0,e=>e),ys=Q(e=>e.commercePagination?.principal.page||0,e=>e),gg=Q((e,t)=>e.commercePagination?.recommendations[t]?.page||0,e=>e);import{StringValue as HA}from"@coveo/bueno";var fe=g("commerce/query/update",e=>F(e,{query:new HA}));import{isNullOrUndefined as Eg}from"@coveo/bueno";import{RecordValue as YA,StringValue as JA}from"@coveo/bueno";var Er=g("commerce/triggers/query/updateIgnore",e=>F(e,{q:new JA({emptyAllowed:!0,required:!0})})),fn=g("commerce/triggers/query/applyModification",e=>F(e,new YA({values:{originalQuery:ne,modification:ne}})));import{isNullOrUndefined as xg}from"@coveo/bueno";function $l(e,t,r){if(e===void 0)return{};let o=t(e);return o!==r?{q:o}:{}}function zl(e,t,r){if(e===void 0)return{};let o=t(e);return o!==r?{sortCriteria:o}:{}}function kt(e,t,r,o){if(e===void 0)return{};let n=Object.entries(e).filter(([a])=>t(a)).map(([a,{request:i}])=>{let s=r(i);return s.length?{[a]:s}:{}}).reduce((a,i)=>({...a,...i}),{});return Object.keys(n).length?{[o]:n}:{}}function Vt(e){let{activeValue:t,ancestryMap:r}=XA(e);return t?ZA(t,r):[]}function XA(e){let t=[...e],r=new Map;for(;t.length>0;){let o=t.shift();if(o.state==="selected")return{activeValue:o,ancestryMap:r};if(r)for(let n of o.children)r.set(n,o);t.unshift(...o.children)}return{}}function ZA(e,t){let r=[];if(!e)return[];let o=e;do r.unshift(o),o=t.get(o);while(o);return r}function yg(){return{principal:Ir(),recommendations:{}}}function Ir(){return{page:0,perPage:0,totalEntries:0,totalPages:0}}function vo(){return{appliedSort:nr(),availableSorts:[nr()]}}function Ss(e){return{...ev(e?.commercePagination,t=>t.principal.page,Ir().page),...tv(e?.commercePagination,t=>t.principal.perPage,Ir().perPage),...zl(e?.commerceSort,t=>t.appliedSort,vo().appliedSort),...kt(e.commerceFacetSet,Tr(e,"regular"),rv,"f"),...kt(e.commerceFacetSet,Tr(e,"regular"),ov,"fExcluded"),...kt(e.commerceFacetSet,Tr(e,"location"),nv,"lf"),...kt(e.commerceFacetSet,Tr(e,"hierarchical"),av,"cf"),...kt(e.commerceFacetSet,Tr(e,"dateRange"),Sg,"df"),...kt(e.commerceFacetSet,Tr(e,"dateRange"),hg,"dfExcluded"),...kt(e.commerceFacetSet,Tr(e,"numericalRange"),Sg,"nf"),...kt(e.commerceFacetSet,Tr(e,"numericalRange"),hg,"nfExcluded"),...Cg("selected",e.manualNumericFacetSet),...Cg("excluded",e.manualNumericFacetSet)}}function ev(e,t,r){if(e===void 0)return{};let o=t(e);return o!==r?{page:o}:{}}function tv(e,t,r){if(e===void 0)return{};let o=t(e);return o!==r?{perPage:o}:{}}function rv(e){return e.values.filter(t=>t.state==="selected").map(t=>t.value)}function ov(e){return e.values.filter(t=>t.state==="excluded").map(t=>t.value)}function nv(e){return e.values.filter(t=>t.state==="selected").map(t=>t.value)}function Sg(e){return e.values.filter(t=>t.state==="selected")}function hg(e){return e.values.filter(t=>t.state==="excluded")}function Cg(e,t){if(!t||e==="idle")return{};let r=Object.entries(t).map(([o,n])=>{if(!(n.manualRange===void 0||n.manualRange.state!==e))return{[o]:[n.manualRange]}}).filter(o=>o!==void 0).reduce((o,n)=>({...o,...n}),{});return e==="selected"?{mnf:r}:{mnfExcluded:r}}function av(e){return Vt(e.values).map(r=>r.value)}function Tr(e,t){return r=>e.commerceFacetSet[r].request.type===t}var hs=()=>({query:""});var mL=Q(e=>e[U].commerceSearch.responseId,e=>e),Wl=Q(e=>e.commerceSearch.responseId,e=>e),Rg=Q(e=>e.commerceSearch.requestId,e=>e),Ma=Q(e=>e.commerceSearch?.products.length||0,e=>e),Fg=Q(e=>({total:wr(e),current:Ma(e)}),({current:e,total:t})=>e<t),Pg=Q(e=>e.commerceSearch?.isLoading,e=>xg(e)?!1:e),Ag=Q(e=>e.commerceSearch?.error,e=>e??null),Cs=Q(e=>e.commerceQuery?.query,e=>e??""),iv=Q(e=>e.commerceSearch?.queryExecuted,e=>e),vg=(e,t)=>xg(t.queryCorrection?.correctedQuery)?Cs(e):t.queryCorrection.correctedQuery,bg=e=>({...$l(e?.commerceQuery,t=>t.query,hs().query),...Ss(e)});function wg(e){return{query:iv(e)||""}}var Qa=class{constructor(t){this.config=t}async process(t){return this.processQueryErrorOrContinue(t)??await this.processQueryCorrectionsOrContinue(t)??await this.processQueryTriggersOrContinue(t)??this.processSuccessResponse(t)}async fetchFromAPI(t){let r=new Date().getTime(),o=await this.extra.apiClient.search(t),n=new Date().getTime()-r,a=this.getState().commerceQuery.query||"";return{response:o,duration:n,queryExecuted:a,requestExecuted:t}}processSuccessResponse(t){return{...t,response:this.getSuccessResponse(t),originalQuery:this.getCurrentQuery()}}processQueryErrorOrContinue(t){return qe(t.response)?this.rejectWithValue(t.response.error):null}async processQueryCorrectionsOrContinue(t){let r=this.getState(),o=this.getSuccessResponse(t);if(!o||!r.didYouMean)return null;let{queryCorrection:n}=o;if(!(!Eg(n)&&!Eg(n.correctedQuery)))return null;let{correctedQuery:i,originalQuery:s}=o.queryCorrection;return this.onUpdateQueryForCorrection(i??""),{...t,response:{...o},queryExecuted:vg(r,o),originalQuery:s??""}}async processQueryTriggersOrContinue(t){let r=this.getSuccessResponse(t);if(!r)return null;let o=r.triggers.find(s=>s.type==="query")?.content||"";if(!o)return null;if(this.getState().triggers?.queryModification.queryToIgnore===o)return this.dispatch(Er({q:""})),null;let a=this.getCurrentQuery(),i=await this.automaticallyRetryQueryWithTriggerModification(o);return qe(i.response)?this.rejectWithValue(i.response.error):{...i,response:{...i.response.success},originalQuery:a}}async automaticallyRetryQueryWithTriggerModification(t){return this.dispatch(fn({newQuery:t,originalQuery:this.getCurrentQuery()})),this.onUpdateQueryForCorrection(t),await this.fetchFromAPI({...ut(this.getState(),this.navigatorContext),query:t})}get dispatch(){return this.config.dispatch}get rejectWithValue(){return this.config.rejectWithValue}getState(){return this.config.getState()}get navigatorContext(){return this.config.extra.navigatorContext}getCurrentQuery(){let t=this.getState();return t.commerceQuery.query!==void 0?t.commerceQuery.query:""}getSuccessResponse(t){return qe(t.response)?null:t.response.success}get extra(){return this.config.extra}onUpdateQueryForCorrection(t){this.dispatch(fe({query:t}))}};var X=_("commerce/search/executeSearch",async(e,t)=>{let{getState:r}=t,o=r(),{navigatorContext:n}=t.extra,a=ut(o,n),i=Cs(o),s=new Qa(t),u=await s.fetchFromAPI({...a,query:i});return s.process(u)}),Or=_("commerce/search/fetchMoreProducts",async(e,t)=>{let{getState:r}=t,o=r(),{navigatorContext:n}=t.extra;if(!Fg(o))return null;let i=br(o),u=Ma(o)/i,c=Cs(o),l=ut(o,n),d=new Qa(t),p=await d.fetchFromAPI({...l,query:c,page:u});return d.process(p)}),gn=_("commerce/search/prepareForSearchWithQuery",(e,t)=>{let{dispatch:r}=t;F(e,{query:new Ig,clearFilters:new sv}),e.clearFilters&&(r(pe()),r(Rr())),r(mn({allow:!0})),r(fe({query:e.query})),r(Dt({page:0}))}),yn=_("commerce/search/fetchInstantProducts",async(e,{getState:t,rejectWithValue:r,extra:o})=>{let n=t(),{apiClient:a,navigatorContext:i}=o,{q:s}=e,u=await a.productSuggestions({...Pr(n,i),query:s});return qe(u)?r(u.error):{response:{...u.success,products:u.success.products}}}),uv={child:new cv({options:{required:!0},values:{permanentid:new Ig({required:!0})}})},Sn=g("commerce/search/promoteChildToParent",e=>F(e,uv));function Tg(){return{wasCorrectedTo:"",queryCorrection:ds(),originalQuery:""}}var xs=j(Tg(),e=>{e.addCase(X.pending,t=>{t.queryCorrection=ds(),t.wasCorrectedTo=""}).addCase(X.fulfilled,(t,r)=>{let{queryCorrection:o}=r.payload.response;t.originalQuery=r.payload.originalQuery,t.wasCorrectedTo=o?.correctedQuery??"",t.queryCorrection={correctedQuery:o?.correctedQuery??o?.corrections[0]?.correctedQuery??"",wordCorrections:o?.corrections[0]?.wordCorrections??[]}})});import{Value as Dg,BooleanValue as Og,ArrayValue as Fs,StringValue as Rs,NumberValue as qg,RecordValue as yv}from"@coveo/bueno";var H=D;import{Value as lv,NumberValue as dv,StringValue as mv,ArrayValue as pv,BooleanValue as fv}from"@coveo/bueno";var gv={state:new lv({required:!0}),numberOfResults:new dv({required:!0,min:0}),value:new mv({required:!0,emptyAllowed:!0}),path:new pv({required:!0,each:D}),moreValuesAvailable:new fv({required:!1})};function La(e){e.children.forEach(t=>{La(t)}),Se({state:e.state,numberOfResults:e.numberOfResults,value:e.value,path:e.path,moreValuesAvailable:e.moreValuesAvailable},gv)}var hn={facetId:H,field:D,tabs:new yv({options:{required:!1},values:{included:new Fs({each:new Rs}),excluded:new Fs({each:new Rs})}}),activeTab:new Rs({required:!1}),delimitingCharacter:new Rs({required:!1,emptyAllowed:!0}),filterFacetCount:new Og({required:!1}),injectionDepth:new qg({required:!1,min:0}),numberOfValues:new qg({required:!1,min:1}),sortCriteria:new Dg({required:!1}),basePath:new Fs({required:!1,each:D}),filterByBasePath:new Og({required:!1})},Cn=5,kg=g("categoryFacet/register",e=>F(e,hn)),Vg=g("categoryFacet/toggleSelectValue",e=>{try{return Se(e.facetId,D),La(e.selection),{payload:e,error:null}}catch(t){return{payload:e,error:je(t)}}}),Ng=g("categoryFacet/deselectAll",e=>F(e,hn.facetId)),nB=g("categoryFacet/updateNumberOfValues",e=>F(e,{facetId:hn.facetId,numberOfValues:hn.numberOfValues})),aB=g("categoryFacet/updateSortCriterion",e=>F(e,{facetId:hn.facetId,criterion:new Dg})),iB=g("categoryFacet/updateBasePath",e=>F(e,{facetId:hn.facetId,basePath:new Fs({each:D})}));import{NumberValue as xv,RecordValue as Rv,ArrayValue as Fv}from"@coveo/bueno";import{RecordValue as Sv,NumberValue as hv,StringValue as Cv}from"@coveo/bueno";var Ba={facetId:H,captions:new Sv({options:{required:!1}}),numberOfValues:new hv({required:!1,min:1}),query:new Cv({required:!1,emptyAllowed:!0})};var Pv={path:new Fv({required:!0,each:D}),displayValue:me,rawValue:me,count:new xv({required:!0,min:0})},Nt=g("categoryFacet/selectSearchResult",e=>F(e,{facetId:H,value:new Rv({values:Pv})})),Ps=g("categoryFacetSearch/register",e=>F(e,Ba));import{RecordValue as Av,NumberValue as vv}from"@coveo/bueno";var Mg={facetId:H,value:new Av({values:{displayValue:me,rawValue:me,count:new vv({required:!0,min:0})}})},As=g("facetSearch/register",e=>F(e,Ba)),qr=g("facetSearch/update",e=>F(e,Ba)),nt=g("facetSearch/toggleSelectValue",e=>F(e,Mg)),At=g("facetSearch/toggleExcludeValue",e=>F(e,Mg));import{BooleanValue as bv}from"@coveo/bueno";var ir=g("facetOptions/update",(e={freezeFacetOrder:!0})=>F(e,{freezeFacetOrder:new bv({required:!1})})),Kl=g("facetOptions/facet/enable",e=>F(e,H)),sr=g("facetOptions/facet/disable",e=>F(e,H));var wv=g("history/undo"),Ev=g("history/redo"),Mt=g("history/snapshot"),IB=_("history/back",async(e,{dispatch:t})=>{t(wv()),await t(xe())}),TB=_("history/forward",async(e,{dispatch:t})=>{t(Ev()),await t(xe())}),xe=_("history/change",async(e,{getState:t})=>t().history.present);import{BooleanValue as Qg,StringValue as Ua,NumberValue as Lg,RecordValue as Dr}from"@coveo/bueno";var vs={q:new Ua,enableQuerySyntax:new Qg,aq:new Ua,cq:new Ua,firstResult:new Lg({min:0}),numberOfResults:new Lg({min:0}),sortCriteria:new Ua,f:new Dr,fExcluded:new Dr,cf:new Dr,nf:new Dr,mnf:new Dr,df:new Dr,debug:new Qg,sf:new Dr,tab:new Ua,af:new Dr};var we=g("searchParameters/restore",e=>F(e,vs)),Iv=g("searchParameters/restoreTab",e=>F(e,D));import{BooleanValue as pS,NumberValue as fS,StringValue as ME}from"@coveo/bueno";function cr(e,t){var r={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(r[o]=e[o]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,o=Object.getOwnPropertySymbols(e);n<o.length;n++)t.indexOf(o[n])<0&&Object.prototype.propertyIsEnumerable.call(e,o[n])&&(r[o[n]]=e[o[n]]);return r}function w(e,t,r,o){function n(a){return a instanceof r?a:new r(function(i){i(a)})}return new(r||(r=Promise))(function(a,i){function s(l){try{c(o.next(l))}catch(d){i(d)}}function u(l){try{c(o.throw(l))}catch(d){i(d)}}function c(l){l.done?a(l.value):n(l.value).then(s,u)}c((o=o.apply(e,t||[])).next())})}var ee;(function(e){e.search="search",e.click="click",e.custom="custom",e.view="view",e.collect="collect"})(ee||(ee={}));function Yl(){return typeof window<"u"}function ud(){return typeof navigator<"u"}function xn(){return typeof document<"u"}function Jl(){try{return typeof localStorage<"u"}catch{return!1}}function Tv(){try{return typeof sessionStorage<"u"}catch{return!1}}function Zg(){return ud()&&navigator.cookieEnabled}var Ov=[ee.click,ee.custom,ee.search,ee.view],qv=(e,t)=>Ov.indexOf(e)!==-1?Object.assign({language:xn()?document.documentElement.lang:"unknown",userAgent:ud()?navigator.userAgent:"unknown"},t):t,$a=class e{static set(t,r,o){var n,a,i,s;o&&(a=new Date,a.setTime(a.getTime()+o)),s=window.location.hostname,s.indexOf(".")===-1?Bg(t,r,a):(i=s.split("."),n=i[i.length-2]+"."+i[i.length-1],Bg(t,r,a,n))}static get(t){for(var r=t+"=",o=document.cookie.split(";"),n=0;n<o.length;n++){var a=o[n];if(a=a.replace(/^\s+/,""),a.lastIndexOf(r,0)===0)return a.substring(r.length,a.length)}return null}static erase(t){e.set(t,"",-1)}};function Bg(e,t,r,o){document.cookie=`${e}=${t}`+(r?`;expires=${r.toUTCString()}`:"")+(o?`;domain=${o}`:"")+";path=/;SameSite=Lax"}function Dv(){return Jl()?localStorage:Zg()?new za:Tv()?sessionStorage:new Fn}var za=class e{getItem(t){return $a.get(`${e.prefix}${t}`)}removeItem(t){$a.erase(`${e.prefix}${t}`)}setItem(t,r,o){$a.set(`${e.prefix}${t}`,r,o)}};za.prefix="coveo_";var Xl=class{constructor(){this.cookieStorage=new za}getItem(t){return localStorage.getItem(t)||this.cookieStorage.getItem(t)}removeItem(t){this.cookieStorage.removeItem(t),localStorage.removeItem(t)}setItem(t,r){localStorage.setItem(t,r),this.cookieStorage.setItem(t,r,31556926e3)}},Fn=class{getItem(t){return null}removeItem(t){}setItem(t,r){}},ja="__coveo.analytics.history",ey=20,ty=1e3*60,ry=75,Pn=class{constructor(t){this.store=t||Dv()}addElement(t){t.internalTime=new Date().getTime(),t=this.cropQueryElement(this.stripEmptyQuery(t));let r=this.getHistoryWithInternalTime();r!=null?this.isValidEntry(t)&&this.setHistory([t].concat(r)):this.setHistory([t])}addElementAsync(t){return w(this,void 0,void 0,function*(){t.internalTime=new Date().getTime(),t=this.cropQueryElement(this.stripEmptyQuery(t));let r=yield this.getHistoryWithInternalTimeAsync();r!=null?this.isValidEntry(t)&&this.setHistory([t].concat(r)):this.setHistory([t])})}getHistory(){let t=this.getHistoryWithInternalTime();return this.stripEmptyQueries(this.stripInternalTime(t))}getHistoryAsync(){return w(this,void 0,void 0,function*(){let t=yield this.getHistoryWithInternalTimeAsync();return this.stripEmptyQueries(this.stripInternalTime(t))})}getHistoryWithInternalTime(){try{let t=this.store.getItem(ja);return t&&typeof t=="string"?JSON.parse(t):[]}catch{return[]}}getHistoryWithInternalTimeAsync(){return w(this,void 0,void 0,function*(){try{let t=yield this.store.getItem(ja);return t?JSON.parse(t):[]}catch{return[]}})}setHistory(t){try{this.store.setItem(ja,JSON.stringify(t.slice(0,ey)))}catch{}}clear(){try{this.store.removeItem(ja)}catch{}}getMostRecentElement(){let t=this.getHistoryWithInternalTime();return Array.isArray(t)?t.sort((o,n)=>(n.internalTime||0)-(o.internalTime||0))[0]:null}cropQueryElement(t){return t.name&&t.value&&t.name.toLowerCase()==="query"&&(t.value=t.value.slice(0,ry)),t}isValidEntry(t){let r=this.getMostRecentElement();return r&&r.value==t.value?(t.internalTime||0)-(r.internalTime||0)>ty:!0}stripInternalTime(t){return Array.isArray(t)?t.map(r=>{let{name:o,time:n,value:a}=r;return{name:o,time:n,value:a}}):[]}stripEmptyQuery(t){let{name:r,time:o,value:n}=t;return r&&typeof n=="string"&&r.toLowerCase()==="query"&&n.trim()===""?{name:r,time:o}:t}stripEmptyQueries(t){return t.map(r=>this.stripEmptyQuery(r))}},oy=Object.freeze({__proto__:null,HistoryStore:Pn,MAX_NUMBER_OF_HISTORY_ELEMENTS:ey,MAX_VALUE_SIZE:ry,MIN_THRESHOLD_FOR_DUPLICATE_VALUE:ty,STORE_KEY:ja,default:Pn}),kv=(e,t)=>w(void 0,void 0,void 0,function*(){return e===ee.view?(yield Vv(t.contentIdValue),Object.assign({location:window.location.toString(),referrer:document.referrer,title:document.title},t)):t}),Vv=e=>w(void 0,void 0,void 0,function*(){let t=new Pn,r={name:"PageView",value:e,time:new Date().toISOString()};yield t.addElementAsync(r)}),bs,Nv=new Uint8Array(16);function Mv(){if(!bs&&(bs=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!bs))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return bs(Nv)}var Qv=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;function Es(e){return typeof e=="string"&&Qv.test(e)}var Ee=[];for(let e=0;e<256;++e)Ee.push((e+256).toString(16).slice(1));function ny(e,t=0){return(Ee[e[t+0]]+Ee[e[t+1]]+Ee[e[t+2]]+Ee[e[t+3]]+"-"+Ee[e[t+4]]+Ee[e[t+5]]+"-"+Ee[e[t+6]]+Ee[e[t+7]]+"-"+Ee[e[t+8]]+Ee[e[t+9]]+"-"+Ee[e[t+10]]+Ee[e[t+11]]+Ee[e[t+12]]+Ee[e[t+13]]+Ee[e[t+14]]+Ee[e[t+15]]).toLowerCase()}function Lv(e){if(!Es(e))throw TypeError("Invalid UUID");let t,r=new Uint8Array(16);return r[0]=(t=parseInt(e.slice(0,8),16))>>>24,r[1]=t>>>16&255,r[2]=t>>>8&255,r[3]=t&255,r[4]=(t=parseInt(e.slice(9,13),16))>>>8,r[5]=t&255,r[6]=(t=parseInt(e.slice(14,18),16))>>>8,r[7]=t&255,r[8]=(t=parseInt(e.slice(19,23),16))>>>8,r[9]=t&255,r[10]=(t=parseInt(e.slice(24,36),16))/1099511627776&255,r[11]=t/4294967296&255,r[12]=t>>>24&255,r[13]=t>>>16&255,r[14]=t>>>8&255,r[15]=t&255,r}function Bv(e){e=unescape(encodeURIComponent(e));let t=[];for(let r=0;r<e.length;++r)t.push(e.charCodeAt(r));return t}var Uv="6ba7b810-9dad-11d1-80b4-00c04fd430c8",jv="6ba7b811-9dad-11d1-80b4-00c04fd430c8";function _v(e,t,r){function o(n,a,i,s){var u;if(typeof n=="string"&&(n=Bv(n)),typeof a=="string"&&(a=Lv(a)),((u=a)===null||u===void 0?void 0:u.length)!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let c=new Uint8Array(16+n.length);if(c.set(a),c.set(n,a.length),c=r(c),c[6]=c[6]&15|t,c[8]=c[8]&63|128,i){s=s||0;for(let l=0;l<16;++l)i[s+l]=c[l];return i}return ny(c)}try{o.name=e}catch{}return o.DNS=Uv,o.URL=jv,o}var $v=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),Ug={randomUUID:$v};function bo(e,t,r){if(Ug.randomUUID&&!t&&!e)return Ug.randomUUID();e=e||{};let o=e.random||(e.rng||Mv)();if(o[6]=o[6]&15|64,o[8]=o[8]&63|128,t){r=r||0;for(let n=0;n<16;++n)t[r+n]=o[n];return t}return ny(o)}function zv(e,t,r,o){switch(e){case 0:return t&r^~t&o;case 1:return t^r^o;case 2:return t&r^t&o^r&o;case 3:return t^r^o}}function Gl(e,t){return e<<t|e>>>32-t}function Wv(e){let t=[1518500249,1859775393,2400959708,3395469782],r=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof e=="string"){let i=unescape(encodeURIComponent(e));e=[];for(let s=0;s<i.length;++s)e.push(i.charCodeAt(s))}else Array.isArray(e)||(e=Array.prototype.slice.call(e));e.push(128);let o=e.length/4+2,n=Math.ceil(o/16),a=new Array(n);for(let i=0;i<n;++i){let s=new Uint32Array(16);for(let u=0;u<16;++u)s[u]=e[i*64+u*4]<<24|e[i*64+u*4+1]<<16|e[i*64+u*4+2]<<8|e[i*64+u*4+3];a[i]=s}a[n-1][14]=(e.length-1)*8/Math.pow(2,32),a[n-1][14]=Math.floor(a[n-1][14]),a[n-1][15]=(e.length-1)*8&4294967295;for(let i=0;i<n;++i){let s=new Uint32Array(80);for(let m=0;m<16;++m)s[m]=a[i][m];for(let m=16;m<80;++m)s[m]=Gl(s[m-3]^s[m-8]^s[m-14]^s[m-16],1);let u=r[0],c=r[1],l=r[2],d=r[3],p=r[4];for(let m=0;m<80;++m){let f=Math.floor(m/20),h=Gl(u,5)+zv(f,c,l,d)+p+t[f]+s[m]>>>0;p=d,d=l,l=Gl(c,30)>>>0,c=u,u=h}r[0]=r[0]+u>>>0,r[1]=r[1]+c>>>0,r[2]=r[2]+l>>>0,r[3]=r[3]+d>>>0,r[4]=r[4]+p>>>0}return[r[0]>>24&255,r[0]>>16&255,r[0]>>8&255,r[0]&255,r[1]>>24&255,r[1]>>16&255,r[1]>>8&255,r[1]&255,r[2]>>24&255,r[2]>>16&255,r[2]>>8&255,r[2]&255,r[3]>>24&255,r[3]>>16&255,r[3]>>8&255,r[3]&255,r[4]>>24&255,r[4]>>16&255,r[4]>>8&255,r[4]&255]}var Kv=_v("v5",80,Wv),jg=Kv,ay="2.30.45",_g=e=>`${e.protocol}//${e.hostname}${e.pathname.indexOf("/")===0?e.pathname:`/${e.pathname}`}${e.search}`,_a={pageview:"pageview",event:"event"},Is=class{constructor({client:t,uuidGenerator:r=bo}){this.client=t,this.uuidGenerator=r}},Zl=class extends Is{constructor({client:t,uuidGenerator:r=bo}){super({client:t,uuidGenerator:r}),this.actionData={},this.pageViewId=r(),this.nextPageViewId=this.pageViewId,this.currentLocation=_g(window.location),this.lastReferrer=xn()?document.referrer:"",this.addHooks()}getApi(t){switch(t){case"setAction":return this.setAction;default:return null}}setAction(t,r){this.action=t,this.actionData=r}clearData(){this.clearPluginData(),this.action=void 0,this.actionData={}}getLocationInformation(t,r){return Object.assign({hitType:t},this.getNextValues(t,r))}updateLocationInformation(t,r){this.updateLocationForNextPageView(t,r)}getDefaultContextInformation(t){let r={title:xn()?document.title:"",encoding:xn()?document.characterSet:"UTF-8"},o={screenResolution:`${screen.width}x${screen.height}`,screenColor:`${screen.colorDepth}-bit`},n={language:navigator.language,userAgent:navigator.userAgent},a={time:Date.now(),eventId:this.uuidGenerator()};return Object.assign(Object.assign(Object.assign(Object.assign({},a),o),n),r)}updateLocationForNextPageView(t,r){let{pageViewId:o,referrer:n,location:a}=this.getNextValues(t,r);this.lastReferrer=n,this.pageViewId=o,this.currentLocation=a,t===_a.pageview&&(this.nextPageViewId=this.uuidGenerator(),this.hasSentFirstPageView=!0)}getNextValues(t,r){return{pageViewId:t===_a.pageview?this.nextPageViewId:this.pageViewId,referrer:t===_a.pageview&&this.hasSentFirstPageView?this.currentLocation:this.lastReferrer,location:t===_a.pageview?this.getCurrentLocationFromPayload(r):this.currentLocation}}getCurrentLocationFromPayload(t){if(t.page){let r=n=>n.replace(/^\/?(.*)$/,"/$1");return`${(n=>n.split("/").slice(0,3).join("/"))(this.currentLocation)}${r(t.page)}`}else return _g(window.location)}},kr=class e{constructor(t,r){if(!Es(t))throw Error("Not a valid uuid");this.clientId=t,this.creationDate=Math.floor(r/1e3)}toString(){return this.clientId.replace(/-/g,"")+"."+this.creationDate.toString()}get expired(){let t=Math.floor(Date.now()/1e3)-this.creationDate;return t<0||t>e.expirationTime}validate(t,r){return!this.expired&&this.matchReferrer(t,r)}matchReferrer(t,r){try{let o=new URL(t);return r.some(n=>new RegExp(n.replace(/\\/g,"\\\\").replace(/\./g,"\\.").replace(/\*/g,".*")+"$").test(o.host))}catch{return!1}}static fromString(t){let r=t.split(".");if(r.length!==2)return null;let[o,n]=r;if(o.length!==32||isNaN(parseInt(n)))return null;let a=o.substring(0,8)+"-"+o.substring(8,12)+"-"+o.substring(12,16)+"-"+o.substring(16,20)+"-"+o.substring(20,32);return Es(a)?new e(a,Number.parseInt(n)*1e3):null}};kr.cvo_cid="cvo_cid";kr.expirationTime=120;var ed=class extends Is{constructor({client:t,uuidGenerator:r=bo}){super({client:t,uuidGenerator:r})}getApi(t){switch(t){case"decorate":return this.decorate;case"acceptFrom":return this.acceptFrom;default:return null}}decorate(t){return w(this,void 0,void 0,function*(){if(!this.client.getCurrentVisitorId)throw new Error("Could not retrieve current clientId");try{let r=new URL(t),o=yield this.client.getCurrentVisitorId();return r.searchParams.set(kr.cvo_cid,new kr(o,Date.now()).toString()),r.toString()}catch{throw new Error("Invalid URL provided")}})}acceptFrom(t){this.client.setAcceptedLinkReferrers(t)}};ed.Id="link";var dt=Object.keys;function ws(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}var Hl=128,iy=192,$g=224,zg=240;function Gv(e){return(e&248)===zg?4:(e&zg)===$g?3:(e&$g)===iy?2:1}function Hv(e,t){if(t<0||e.length<=t)return e;let r=e.indexOf("%",t-2);for(r<0||r>t?r=t:t=r;r>2&&e.charAt(r-3)=="%";){let o=Number.parseInt(e.substring(r-2,r),16);if((o&Hl)!=Hl)break;if(r-=3,(o&iy)!=Hl){t-r>=Gv(o)*3&&(r=t);break}}return e.substring(0,r)}var td={id:"svc_ticket_id",subject:"svc_ticket_subject",description:"svc_ticket_description",category:"svc_ticket_category",productId:"svc_ticket_product_id",custom:"svc_ticket_custom"},Yv=dt(td).map(e=>td[e]),Jv=[...Yv].join("|"),Xv=new RegExp(`^(${Jv}$)`),Zv={svcAction:"svc_action",svcActionData:"svc_action_data"},eb=e=>dt(e).filter(t=>e[t]!==void 0).reduce((t,r)=>{let o=td[r]||r;return Object.assign(Object.assign({},t),{[o]:e[r]})},{}),tb=e=>Xv.test(e),rb=[tb],Wg={id:"id",name:"nm",brand:"br",category:"ca",variant:"va",price:"pr",quantity:"qt",coupon:"cc",position:"ps",group:"group"},Kg={id:"id",name:"nm",brand:"br",category:"ca",variant:"va",position:"ps",price:"pr",group:"group"},ke={action:"pa",list:"pal",listSource:"pls"},Ts={id:"ti",revenue:"tr",tax:"tt",shipping:"ts",coupon:"tcc",affiliation:"ta",step:"cos",option:"col"},ob=["loyaltyCardId","loyaltyTier","thirdPartyPersona","companyName","favoriteStore","storeName","userIndustry","userRole","userDepartment","businessUnit"],rd={id:"quoteId",affiliation:"quoteAffiliation"},od={id:"reviewId",rating:"reviewRating",comment:"reviewComment"},nb={add:ke,bookmark_add:ke,bookmark_remove:ke,click:ke,checkout:ke,checkout_option:ke,detail:ke,impression:ke,remove:ke,refund:Object.assign(Object.assign({},ke),Ts),purchase:Object.assign(Object.assign({},ke),Ts),quickview:ke,quote:Object.assign(Object.assign({},ke),rd),review:Object.assign(Object.assign({},ke),od)},ab=dt(Wg).map(e=>Wg[e]),ib=dt(Kg).map(e=>Kg[e]),sb=dt(ke).map(e=>ke[e]),cb=dt(Ts).map(e=>Ts[e]),ub=dt(od).map(e=>od[e]),lb=dt(rd).map(e=>rd[e]),db=[...ab,"custom"].join("|"),mb=[...ib,"custom"].join("|"),sy="(pr[0-9]+)",cy="(il[0-9]+pi[0-9]+)",pb=new RegExp(`^${sy}(${db})$`),fb=new RegExp(`^(${cy}(${mb}))|(il[0-9]+nm)$`),gb=new RegExp(`^(${sb.join("|")})$`),yb=new RegExp(`^(${cb.join("|")})$`),Sb=new RegExp(`^${sy}custom$`),hb=new RegExp(`^${cy}custom$`),Cb=new RegExp(`^(${[...ob,...ub,...lb].join("|")})$`),xb=e=>pb.test(e),Rb=e=>fb.test(e),Fb=e=>gb.test(e),Pb=e=>yb.test(e),Ab=e=>Cb.test(e),vb=[Rb,xb,Fb,Pb,Ab],bb=[Sb,hb],wb={anonymizeIp:"aip"},Eb={eventCategory:"ec",eventAction:"ea",eventLabel:"el",eventValue:"ev",page:"dp",visitorId:"cid",clientId:"cid",userId:"uid",currencyCode:"cu"},Ib={hitType:"t",pageViewId:"pid",encoding:"de",location:"dl",referrer:"dr",screenColor:"sd",screenResolution:"sr",title:"dt",userAgent:"ua",language:"ul",eventId:"z",time:"tm"},Tb=["contentId","contentIdKey","contentType","searchHub","tab","searchUid","permanentId","contentLocale","trackingId"],Ob=Object.assign(Object.assign(Object.assign(Object.assign({},wb),Eb),Ib),Tb.reduce((e,t)=>Object.assign(Object.assign({},e),{[t]:t}),{})),nd=Object.assign(Object.assign({},Ob),Zv),qb=e=>{let t=!!e.action&&nb[e.action]||{};return dt(e).reduce((r,o)=>{let n=t[o]||nd[o]||o;return Object.assign(Object.assign({},r),{[n]:e[o]})},{})},Db=dt(nd).map(e=>nd[e]),kb=e=>Db.indexOf(e)!==-1,Vb=e=>e==="custom",Nb=e=>[...vb,...rb,kb,Vb].some(t=>t(e)),Mb=e=>dt(e).reduce((t,r)=>{let o=Qb(r);return o?Object.assign(Object.assign({},t),Lb(o,e[r])):Object.assign(Object.assign({},t),{[r]:e[r]})},{}),Qb=e=>{let t;return[...bb].every(r=>{var o;return t=(o=r.exec(e))===null||o===void 0?void 0:o[1],!t}),t},Lb=(e,t)=>dt(t).reduce((r,o)=>Object.assign(Object.assign({},r),{[`${e}${o}`]:t[o]}),{}),ad=class{constructor(t){this.opts=t}sendEvent(t,r){return w(this,void 0,void 0,function*(){if(!this.isAvailable())throw new Error('navigator.sendBeacon is not supported in this browser. Consider adding a polyfill like "sendbeacon-polyfill".');let{baseUrl:o,preprocessRequest:n}=this.opts,a=yield this.getQueryParamsForEventType(t),{url:i,payload:s}=yield this.preProcessRequestAsPotentialJSONString(`${o}/analytics/${t}?${a}`,r,n),u=this.encodeForEventType(t,s),c=new Blob([u],{type:"application/x-www-form-urlencoded"});navigator.sendBeacon(i,c)})}isAvailable(){return"sendBeacon"in navigator}deleteHttpCookieVisitorId(){return Promise.resolve()}preProcessRequestAsPotentialJSONString(t,r,o){return w(this,void 0,void 0,function*(){let n=t,a=r;if(o){let i=yield o({url:t,body:JSON.stringify(r)},"analyticsBeacon"),{url:s,body:u}=i;n=s||t;try{a=JSON.parse(u)}catch(c){console.error("Unable to process the request body as a JSON string",c)}}return{payload:a,url:n}})}encodeForEventType(t,r){return this.isEventTypeLegacy(t)?this.encodeEventToJson(t,r):this.encodeEventToJson(t,r,this.opts.token)}getQueryParamsForEventType(t){return w(this,void 0,void 0,function*(){let{token:r,visitorIdProvider:o}=this.opts,n=yield o.getCurrentVisitorId();return[r&&this.isEventTypeLegacy(t)?`access_token=${r}`:"",n?`visitorId=${n}`:"","discardVisitInfo=true"].filter(a=>!!a).join("&")})}isEventTypeLegacy(t){return[ee.click,ee.custom,ee.search,ee.view].indexOf(t)!==-1}encodeEventToJson(t,r,o){let n=`${t}Event=${encodeURIComponent(JSON.stringify(r))}`;return o&&(n=`access_token=${encodeURIComponent(o)}&${n}`),n}},id=class{sendEvent(t,r){return w(this,void 0,void 0,function*(){return Promise.resolve()})}deleteHttpCookieVisitorId(){return w(this,void 0,void 0,function*(){return Promise.resolve()})}},Gg=globalThis.fetch,Os=class{constructor(t){this.opts=t}sendEvent(t,r){return w(this,void 0,void 0,function*(){let{baseUrl:o,visitorIdProvider:n,preprocessRequest:a}=this.opts,i=this.shouldAppendVisitorId(t)?yield this.getVisitorIdParam():"",s={url:`${o}/analytics/${t}${i}`,credentials:"include",mode:"cors",headers:this.getHeaders(),method:"POST",body:JSON.stringify(r)},u=Object.assign(Object.assign({},s),a?yield a(s,"analyticsFetch"):{}),{url:c}=u,l=cr(u,["url"]),d;try{d=yield Gg(c,l)}catch(p){console.error("An error has occured when sending the event.",p);return}if(d.ok){let p=yield d.json();return p.visitorId&&n.setCurrentVisitorId(p.visitorId),p}else{try{d.json()}catch{}throw console.error(`An error has occured when sending the "${t}" event.`,d,r),new Error(`An error has occurred when sending the "${t}" event. Check the console logs for more details.`)}})}deleteHttpCookieVisitorId(){return w(this,void 0,void 0,function*(){let{baseUrl:t}=this.opts,r=`${t}/analytics/visit`;yield Gg(r,{headers:this.getHeaders(),method:"DELETE"})})}shouldAppendVisitorId(t){return[ee.click,ee.custom,ee.search,ee.view].indexOf(t)!==-1}getVisitorIdParam(){return w(this,void 0,void 0,function*(){let{visitorIdProvider:t}=this.opts,r=yield t.getCurrentVisitorId();return r?`?visitor=${r}`:""})}getHeaders(){let{token:t}=this.opts;return Object.assign(Object.assign({},t?{Authorization:`Bearer ${t}`}:{}),{"Content-Type":"application/json"})}},sd=class{constructor(t,r){Jl()&&Zg()?this.storage=new Xl:Jl()?this.storage=localStorage:(console.warn("BrowserRuntime detected no valid storage available.",this),this.storage=new Fn),this.client=new Os(t),this.beaconClient=new ad(t),window.addEventListener("beforeunload",()=>{let o=r();for(let{eventType:n,payload:a}of o)this.beaconClient.sendEvent(n,a)})}getClientDependingOnEventType(t){return t==="click"&&this.beaconClient.isAvailable()?this.beaconClient:this.client}},cd=class{constructor(t,r){this.storage=r||new Fn,this.client=new Os(t)}getClientDependingOnEventType(t){return this.client}},qs=class{constructor(){this.storage=new Fn,this.client=new id}getClientDependingOnEventType(t){return this.client}},Bb="xx",Ub=e=>e?.startsWith(Bb)||!1,jb=`
|
|
19
|
+
If you are trying to access the inner state... Don't`),Reflect.get(t,r,o)}});var so=(e,t=5)=>e+Math.random().toString(36).substring(2,2+t);function Mp(e){return Array.isArray(e)}function $o(e){return e.trim()===""}function Qp(e){let t={};for(let[r,o]of e)t[r]=o;return t}function Ni(e,t){return Object.fromEntries(Object.entries(e).map(([r,o])=>[r,t(o,r)]))}function Mi(e,t){return Object.fromEntries(Object.entries(e).filter(([r,o])=>t(o,r)))}function er(e){if(typeof e!="object"||!e)return e;try{return JSON.parse(JSON.stringify(e))}catch{return e}}function Lp(){let e=null,t=null;return{promise:new Promise((o,n)=>{e=o,t=n}),resolve:e,reject:t}}function Qi(e){let{promise:t,resolve:r}=Lp();return{promise:t,middleware:()=>n=>a=>{n(a),e(a)&&r(a)}}}function GF(e){return e==null?!1:typeof e=="object"&&"meta"in e?e.meta?.arg?.slotId!==void 0:!1}function Bp(e,t){let{promise:r,resolve:o}=Lp(),n=!1,a=s=>t.has(s);return{promise:r,middleware:()=>s=>u=>{s(u),e(u)&&!n&&GF(u)&&!a(u.meta.arg.slotId)&&(n=!0,t.add(u.meta.arg.slotId),o(u))}}}var Xp=It(Gp(),1);var Te=(n=>(n.search="search",n.listing="listing",n.standalone="standalone",n.recommendation="recommendation",n))(Te||{}),xP="recommendation-internal-options",zo=Symbol.for(xP);var $=new Error("Failed to load reducers."),Wo=class extends Error{constructor(){super(),this.name="ExpiredToken",this.message="The token being used to perform the request is expired."}},Bi=class extends Error{constructor(){super(),this.name="InvalidControllerDefinition",this.message=`A controller must be defined for at least one solution type: ${Object.keys(Te).map(t=>t.toLowerCase()).join(", ")}`}},Ko=class extends Error{constructor(t){super(),this.name="MissingControllerProps",this.message=`${t} props are required but were undefined. Ensure they are included when calling \`fetchStaticState\` or \`hydrateStaticState\`.`}},Ui=class extends Error{constructor(t){super(),this.name="MultipleRecommendationError",this.message=`Multiple recommendation controllers found for the same slotId: ${t}. Only one recommendation controller per slotId is supported.`}},uo=class extends Error{constructor(r,o){super();We(this,"statusCode");this.name="Disconnected",this.message=`Client could not connect to the following URL: ${r}`,this.statusCode=o??0}};function Hp(e){let t=[];for(let r in e){let o=encodeURIComponent(r),n=encodeURIComponent(e[r]);t.push(`${o}=${n}`)}return t.join("&")}function Yp(e){return typeof e!="object"||!e?!1:Object.values(e).every(RP)}function RP(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"}function Jp(e){return e===429}var Go=class e{static async call(t){let r=FP(t),{logger:o}=t,n=await e.preprocessRequest(r,t);o.info(n,"Platform request");let{url:a,...i}=n,s=async()=>{let u=await fetch(a,i);if(Jp(u.status))throw u;return u};try{let u=await(0,Xp.backOff)(s,{retry:c=>{let l=c&&Jp(c.status);return l&&o.info("Platform retrying request"),l}});switch(u.status){case 419:case 401:throw o.info("Platform renewing token"),new Wo;case 404:throw new uo(a,u.status);default:return o.info({response:u,requestInfo:n},"Platform response"),u}}catch(u){return u.message==="Failed to fetch"?new uo(a):u}}static async preprocessRequest(t,r){let{origin:o,preprocessRequest:n,logger:a,requestMetadata:i}=r,{signal:s,...u}=t,c=er(u);try{let l=await n(t,o,i);return{...t,...l}}catch(l){a.error(l,"Platform request preprocessing failed. Returning default request options.")}return c}};function Oe(e,t="prod",r="platform"){let o=t==="prod"?"":t,n=r==="platform"?"":`.${r}`;return`https://${e}${n}.org${o}.coveo.com`}function Ke(e,t="prod"){return`${Oe(e,t)}/rest/search/v2`}function fl(e,t="prod"){return`${Oe(e,t,"analytics")}/rest/organizations/${e}/events/v1`}function FP(e){let{url:t,method:r,requestParams:o,contentType:n,accessToken:a,signal:i}=e,s=e.method==="POST"||e.method==="PUT",u=PP(o,n);return{url:t,method:r,headers:{"Content-Type":n,Authorization:`Bearer ${a}`,...e.headers},...s&&{body:u},signal:i}}function PP(e,t){return t==="application/x-www-form-urlencoded"?Yp(e)?Hp(e):"":JSON.stringify(e)}function AP(e){return{statusCode:e.statusCode,type:e.name,message:e.message}}function vP(e){return{statusCode:e.code,type:e.name,message:e.message,ignored:!0}}function gl(e,t){if(t&&e.name==="AbortError")return{error:vP(e)};if(e instanceof uo)return{error:AP(e)};throw e}var Ho=(e,t)=>({...Fa(e,t),requestParams:bP(e)}),bP=e=>{let{trackingId:t,clientId:r,context:o,language:n,country:a,currency:i,page:s,perPage:u,facets:c,sort:l}=e;return{trackingId:t,clientId:r,context:o,language:n,country:a,currency:i,page:s,perPage:u,facets:c,sort:l}},Fa=(e,t)=>{let{url:r,accessToken:o}=e,n=`${r}/${t}`;return{accessToken:o,method:"POST",contentType:"application/json",url:n,origin:"commerceApiFetch",requestMetadata:{method:t}}};var Zp=(e,t)=>({...Fa(e,t),requestParams:wP(e)}),wP=e=>{let{slotId:t,trackingId:r,clientId:o,context:n,language:a,country:i,currency:s,page:u,perPage:c}=e;return{slotId:t,trackingId:r,clientId:o,context:n,language:a,country:i,currency:s,page:u,perPage:c}};var ef=e=>({...Fa(e,"search/querySuggest"),requestParams:EP(e)}),EP=e=>{let{trackingId:t,query:r,clientId:o,context:n,language:a,country:i,currency:s}=e;return{trackingId:t,query:r,clientId:o,context:n,language:a,country:i,currency:s}};var qe=e=>e.error!==void 0,ji=class{constructor(t){this.options=t}async getProductListing(t){return this.query({...Ho(t,"listing"),...this.options})}async search(t){let r=Ho(t,"search");return this.query({...r,requestParams:{...r.requestParams,query:t?.query},...this.options})}async getRecommendations(t){return this.query({...Zp(t,"recommendations"),...this.options})}async productSuggestions(t){let r=Ho(t,"search/productSuggest");return this.query({...r,requestParams:{...r.requestParams,query:t?.query},...this.options})}async querySuggest(t){let r=ef(t);return this.query({...r,requestParams:{...r.requestParams,query:t?.query},...this.options})}async facetSearch(t,r){let o=Ho(t,"facet");return this.query({...o,url:`${o.url}?type=${r}`,requestParams:{...o.requestParams,facetId:t?.facetId,facetQuery:t?.facetQuery,query:t?.query},...this.options})}async plan(t){let r=Ho(t,"search");return this.query({...r,requestParams:{...r.requestParams,query:t?.query},...this.options})}async query(t){let r=await Go.call(t);if(r instanceof Error)return gl(r);let o=await r.json();return r.ok?{success:o}:{error:o}}};function yl(e,t="prod"){return`${Oe(e,t)}/rest/organizations/${e}/commerce/v2`}var _i=e=>e;import{StringValue as _f}from"@coveo/bueno";function ve(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var IP=typeof Symbol=="function"&&Symbol.observable||"@@observable",tf=IP,Sl=()=>Math.random().toString(36).substring(7).split("").join("."),TP={INIT:`@@redux/INIT${Sl()}`,REPLACE:`@@redux/REPLACE${Sl()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${Sl()}`},$i=TP;function Tt(e){if(typeof e!="object"||e===null)return!1;let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||Object.getPrototypeOf(e)===null}function hl(e,t,r){if(typeof e!="function")throw new Error(ve(2));if(typeof t=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(ve(0));if(typeof t=="function"&&typeof r>"u"&&(r=t,t=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(ve(1));return r(hl)(e,t)}let o=e,n=t,a=new Map,i=a,s=0,u=!1;function c(){i===a&&(i=new Map,a.forEach((C,S)=>{i.set(S,C)}))}function l(){if(u)throw new Error(ve(3));return n}function d(C){if(typeof C!="function")throw new Error(ve(4));if(u)throw new Error(ve(5));let S=!0;c();let A=s++;return i.set(A,C),function(){if(S){if(u)throw new Error(ve(6));S=!1,c(),i.delete(A),a=null}}}function p(C){if(!Tt(C))throw new Error(ve(7));if(typeof C.type>"u")throw new Error(ve(8));if(typeof C.type!="string")throw new Error(ve(17));if(u)throw new Error(ve(9));try{u=!0,n=o(n,C)}finally{u=!1}return(a=i).forEach(A=>{A()}),C}function m(C){if(typeof C!="function")throw new Error(ve(10));o=C,p({type:$i.REPLACE})}function f(){let C=d;return{subscribe(S){if(typeof S!="object"||S===null)throw new Error(ve(11));function A(){let x=S;x.next&&x.next(l())}return A(),{unsubscribe:C(A)}},[tf](){return this}}}return p({type:$i.INIT}),{dispatch:p,subscribe:d,getState:l,replaceReducer:m,[tf]:f}}function OP(e){Object.keys(e).forEach(t=>{let r=e[t];if(typeof r(void 0,{type:$i.INIT})>"u")throw new Error(ve(12));if(typeof r(void 0,{type:$i.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(ve(13))})}function Yo(e){let t=Object.keys(e),r={};for(let i=0;i<t.length;i++){let s=t[i];typeof e[s]=="function"&&(r[s]=e[s])}let o=Object.keys(r),n,a;try{OP(r)}catch(i){a=i}return function(s={},u){if(a)throw a;let c=!1,l={};for(let d=0;d<o.length;d++){let p=o[d],m=r[p],f=s[p],h=m(f,u);if(typeof h>"u"){let C=u&&u.type;throw new Error(ve(14))}l[p]=h,c=c||h!==f}return c=c||o.length!==Object.keys(s).length,c?l:s}}function Jo(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,r)=>(...o)=>t(r(...o)))}function rf(...e){return t=>(r,o)=>{let n=t(r,o),a=()=>{throw new Error(ve(15))},i={getState:n.getState,dispatch:(u,...c)=>a(u,...c)},s=e.map(u=>u(i));return a=Jo(...s)(n.dispatch),{...n,dispatch:a}}}function zi(e){return Tt(e)&&"type"in e&&typeof e.type=="string"}var El=Symbol.for("immer-nothing"),Pa=Symbol.for("immer-draftable"),Ge=Symbol.for("immer-state");function be(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var mo=Object.getPrototypeOf;function rt(e){return!!e&&!!e[Ge]}function He(e){return e?cf(e)||Array.isArray(e)||!!e[Pa]||!!e.constructor?.[Pa]||Ea(e)||Ia(e):!1}var qP=Object.prototype.constructor.toString();function cf(e){if(!e||typeof e!="object")return!1;let t=mo(e);if(t===null)return!0;let r=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return r===Object?!0:typeof r=="function"&&Function.toString.call(r)===qP}function Il(e){return rt(e)||be(15,e),e[Ge].base_}function Aa(e,t){po(e)===0?Reflect.ownKeys(e).forEach(r=>{t(r,e[r],e)}):e.forEach((r,o)=>t(o,r,e))}function po(e){let t=e[Ge];return t?t.type_:Array.isArray(e)?1:Ea(e)?2:Ia(e)?3:0}function va(e,t){return po(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Cl(e,t){return po(e)===2?e.get(t):e[t]}function uf(e,t,r){let o=po(e);o===2?e.set(t,r):o===3?e.add(r):e[t]=r}function DP(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function Ea(e){return e instanceof Map}function Ia(e){return e instanceof Set}function lo(e){return e.copy_||e.base_}function Fl(e,t){if(Ea(e))return new Map(e);if(Ia(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);let r=cf(e);if(t===!0||t==="class_only"&&!r){let o=Object.getOwnPropertyDescriptors(e);delete o[Ge];let n=Reflect.ownKeys(o);for(let a=0;a<n.length;a++){let i=n[a],s=o[i];s.writable===!1&&(s.writable=!0,s.configurable=!0),(s.get||s.set)&&(o[i]={configurable:!0,writable:!0,enumerable:s.enumerable,value:e[i]})}return Object.create(mo(e),o)}else{let o=mo(e);if(o!==null&&r)return{...e};let n=Object.create(o);return Object.assign(n,e)}}function Gi(e,t=!1){return Hi(e)||rt(e)||!He(e)||(po(e)>1&&(e.set=e.add=e.clear=e.delete=kP),Object.freeze(e),t&&Object.entries(e).forEach(([r,o])=>Gi(o,!0))),e}function kP(){be(2)}function Hi(e){return Object.isFrozen(e)}var Pl={};function fo(e){let t=Pl[e];return t||be(0,e),t}function VP(e,t){Pl[e]||(Pl[e]=t)}var ba;function lf(){return ba}function NP(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function of(e,t){t&&(fo("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Al(e){vl(e),e.drafts_.forEach(MP),e.drafts_=null}function vl(e){e===ba&&(ba=e.parent_)}function nf(e){return ba=NP(ba,e)}function MP(e){let t=e[Ge];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function af(e,t){t.unfinalizedDrafts_=t.drafts_.length;let r=t.drafts_[0];return e!==void 0&&e!==r?(r[Ge].modified_&&(Al(t),be(4)),He(e)&&(e=Wi(t,e),t.parent_||Ki(t,e)),t.patches_&&fo("Patches").generateReplacementPatches_(r[Ge].base_,e,t.patches_,t.inversePatches_)):e=Wi(t,r,[]),Al(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==El?e:void 0}function Wi(e,t,r){if(Hi(t))return t;let o=t[Ge];if(!o)return Aa(t,(n,a)=>sf(e,o,t,n,a,r)),t;if(o.scope_!==e)return t;if(!o.modified_)return Ki(e,o.base_,!0),o.base_;if(!o.finalized_){o.finalized_=!0,o.scope_.unfinalizedDrafts_--;let n=o.copy_,a=n,i=!1;o.type_===3&&(a=new Set(n),n.clear(),i=!0),Aa(a,(s,u)=>sf(e,o,n,s,u,r,i)),Ki(e,n,!1),r&&e.patches_&&fo("Patches").generatePatches_(o,r,e.patches_,e.inversePatches_)}return o.copy_}function sf(e,t,r,o,n,a,i){if(rt(n)){let s=a&&t&&t.type_!==3&&!va(t.assigned_,o)?a.concat(o):void 0,u=Wi(e,n,s);if(uf(r,o,u),rt(u))e.canAutoFreeze_=!1;else return}else i&&r.add(n);if(He(n)&&!Hi(n)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;Wi(e,n),(!t||!t.scope_.parent_)&&typeof o!="symbol"&&Object.prototype.propertyIsEnumerable.call(r,o)&&Ki(e,n)}}function Ki(e,t,r=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Gi(t,r)}function QP(e,t){let r=Array.isArray(e),o={type_:r?1:0,scope_:t?t.scope_:lf(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1},n=o,a=Tl;r&&(n=[o],a=wa);let{revoke:i,proxy:s}=Proxy.revocable(n,a);return o.draft_=s,o.revoke_=i,s}var Tl={get(e,t){if(t===Ge)return e;let r=lo(e);if(!va(r,t))return LP(e,r,t);let o=r[t];return e.finalized_||!He(o)?o:o===xl(e.base_,t)?(Rl(e),e.copy_[t]=wl(o,e)):o},has(e,t){return t in lo(e)},ownKeys(e){return Reflect.ownKeys(lo(e))},set(e,t,r){let o=df(lo(e),t);if(o?.set)return o.set.call(e.draft_,r),!0;if(!e.modified_){let n=xl(lo(e),t),a=n?.[Ge];if(a&&a.base_===r)return e.copy_[t]=r,e.assigned_[t]=!1,!0;if(DP(r,n)&&(r!==void 0||va(e.base_,t)))return!0;Rl(e),bl(e)}return e.copy_[t]===r&&(r!==void 0||t in e.copy_)||Number.isNaN(r)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=r,e.assigned_[t]=!0),!0},deleteProperty(e,t){return xl(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,Rl(e),bl(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){let r=lo(e),o=Reflect.getOwnPropertyDescriptor(r,t);return o&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:o.enumerable,value:r[t]}},defineProperty(){be(11)},getPrototypeOf(e){return mo(e.base_)},setPrototypeOf(){be(12)}},wa={};Aa(Tl,(e,t)=>{wa[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});wa.deleteProperty=function(e,t){return wa.set.call(this,e,t,void 0)};wa.set=function(e,t,r){return Tl.set.call(this,e[0],t,r,e[0])};function xl(e,t){let r=e[Ge];return(r?lo(r):e)[t]}function LP(e,t,r){let o=df(t,r);return o?"value"in o?o.value:o.get?.call(e.draft_):void 0}function df(e,t){if(!(t in e))return;let r=mo(e);for(;r;){let o=Object.getOwnPropertyDescriptor(r,t);if(o)return o;r=mo(r)}}function bl(e){e.modified_||(e.modified_=!0,e.parent_&&bl(e.parent_))}function Rl(e){e.copy_||(e.copy_=Fl(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var BP=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,r,o)=>{if(typeof t=="function"&&typeof r!="function"){let a=r;r=t;let i=this;return function(u=a,...c){return i.produce(u,l=>r.call(this,l,...c))}}typeof r!="function"&&be(6),o!==void 0&&typeof o!="function"&&be(7);let n;if(He(t)){let a=nf(this),i=wl(t,void 0),s=!0;try{n=r(i),s=!1}finally{s?Al(a):vl(a)}return of(a,o),af(n,a)}else if(!t||typeof t!="object"){if(n=r(t),n===void 0&&(n=t),n===El&&(n=void 0),this.autoFreeze_&&Gi(n,!0),o){let a=[],i=[];fo("Patches").generateReplacementPatches_(t,n,a,i),o(a,i)}return n}else be(1,t)},this.produceWithPatches=(t,r)=>{if(typeof t=="function")return(i,...s)=>this.produceWithPatches(i,u=>t(u,...s));let o,n;return[this.produce(t,r,(i,s)=>{o=i,n=s}),o,n]},typeof e?.autoFreeze=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof e?.useStrictShallowCopy=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){He(e)||be(8),rt(e)&&(e=mf(e));let t=nf(this),r=wl(e,void 0);return r[Ge].isManual_=!0,vl(t),r}finishDraft(e,t){let r=e&&e[Ge];(!r||!r.isManual_)&&be(9);let{scope_:o}=r;return of(o,t),af(void 0,o)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let r;for(r=t.length-1;r>=0;r--){let n=t[r];if(n.path.length===0&&n.op==="replace"){e=n.value;break}}r>-1&&(t=t.slice(r+1));let o=fo("Patches").applyPatches_;return rt(e)?o(e,t):this.produce(e,n=>o(n,t))}};function wl(e,t){let r=Ea(e)?fo("MapSet").proxyMap_(e,t):Ia(e)?fo("MapSet").proxySet_(e,t):QP(e,t);return(t?t.scope_:lf()).drafts_.push(r),r}function mf(e){return rt(e)||be(10,e),pf(e)}function pf(e){if(!He(e)||Hi(e))return e;let t=e[Ge],r;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,r=Fl(e,t.scope_.immer_.useStrictShallowCopy_)}else r=Fl(e,!0);return Aa(r,(o,n)=>{uf(r,o,pf(n))}),t&&(t.finalized_=!1),r}function ff(){let t="replace",r="add",o="remove";function n(p,m,f,h){switch(p.type_){case 0:case 2:return i(p,m,f,h);case 1:return a(p,m,f,h);case 3:return s(p,m,f,h)}}function a(p,m,f,h){let{base_:C,assigned_:S}=p,A=p.copy_;A.length<C.length&&([C,A]=[A,C],[f,h]=[h,f]);for(let y=0;y<C.length;y++)if(S[y]&&A[y]!==C[y]){let x=m.concat([y]);f.push({op:t,path:x,value:d(A[y])}),h.push({op:t,path:x,value:d(C[y])})}for(let y=C.length;y<A.length;y++){let x=m.concat([y]);f.push({op:r,path:x,value:d(A[y])})}for(let y=A.length-1;C.length<=y;--y){let x=m.concat([y]);h.push({op:o,path:x})}}function i(p,m,f,h){let{base_:C,copy_:S}=p;Aa(p.assigned_,(A,y)=>{let x=Cl(C,A),I=Cl(S,A),v=y?va(C,A)?t:r:o;if(x===I&&v===t)return;let R=m.concat(A);f.push(v===o?{op:v,path:R}:{op:v,path:R,value:I}),h.push(v===r?{op:o,path:R}:v===o?{op:r,path:R,value:d(x)}:{op:t,path:R,value:d(x)})})}function s(p,m,f,h){let{base_:C,copy_:S}=p,A=0;C.forEach(y=>{if(!S.has(y)){let x=m.concat([A]);f.push({op:o,path:x,value:y}),h.unshift({op:r,path:x,value:y})}A++}),A=0,S.forEach(y=>{if(!C.has(y)){let x=m.concat([A]);f.push({op:r,path:x,value:y}),h.unshift({op:o,path:x,value:y})}A++})}function u(p,m,f,h){f.push({op:t,path:[],value:m===El?void 0:m}),h.push({op:t,path:[],value:p})}function c(p,m){return m.forEach(f=>{let{path:h,op:C}=f,S=p;for(let I=0;I<h.length-1;I++){let v=po(S),R=h[I];typeof R!="string"&&typeof R!="number"&&(R=""+R),(v===0||v===1)&&(R==="__proto__"||R==="constructor")&&be(19),typeof S=="function"&&R==="prototype"&&be(19),S=Cl(S,R),typeof S!="object"&&be(18,h.join("/"))}let A=po(S),y=l(f.value),x=h[h.length-1];switch(C){case t:switch(A){case 2:return S.set(x,y);case 3:be(16);default:return S[x]=y}case r:switch(A){case 1:return x==="-"?S.push(y):S.splice(x,0,y);case 2:return S.set(x,y);case 3:return S.add(y);default:return S[x]=y}case o:switch(A){case 1:return S.splice(x,1);case 2:return S.delete(x);case 3:return S.delete(f.value);default:return delete S[x]}default:be(17,C)}}),p}function l(p){if(!He(p))return p;if(Array.isArray(p))return p.map(l);if(Ea(p))return new Map(Array.from(p.entries()).map(([f,h])=>[f,l(h)]));if(Ia(p))return new Set(Array.from(p).map(l));let m=Object.create(mo(p));for(let f in p)m[f]=l(p[f]);return va(p,Pa)&&(m[Pa]=p[Pa]),m}function d(p){return rt(p)?l(p):p}VP("Patches",{applyPatches_:c,generatePatches_:n,generateReplacementPatches_:u})}var ot=new BP,rr=ot.produce,Yi=ot.produceWithPatches.bind(ot),WN=ot.setAutoFreeze.bind(ot),KN=ot.setUseStrictShallowCopy.bind(ot),Ol=ot.applyPatches.bind(ot),GN=ot.createDraft.bind(ot),HN=ot.finishDraft.bind(ot);function UP(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function jP(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function _P(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(r=>typeof r=="function")){let r=e.map(o=>typeof o=="function"?`function ${o.name||"unnamed"}()`:typeof o).join(", ");throw new TypeError(`${t}[${r}]`)}}var gf=e=>Array.isArray(e)?e:[e];function $P(e){let t=Array.isArray(e[0])?e[0]:e;return _P(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function zP(e,t){let r=[],{length:o}=e;for(let n=0;n<o;n++)r.push(e[n].apply(null,t));return r}var XN=Symbol();var ZN=Object.getPrototypeOf({});var WP=class{constructor(e){this.value=e}deref(){return this.value}},KP=typeof WeakRef<"u"?WeakRef:WP,GP=0,yf=1;function Ji(){return{s:GP,v:void 0,o:null,p:null}}function Xo(e,t={}){let r=Ji(),{resultEqualityCheck:o}=t,n,a=0;function i(){let s=r,{length:u}=arguments;for(let d=0,p=u;d<p;d++){let m=arguments[d];if(typeof m=="function"||typeof m=="object"&&m!==null){let f=s.o;f===null&&(s.o=f=new WeakMap);let h=f.get(m);h===void 0?(s=Ji(),f.set(m,s)):s=h}else{let f=s.p;f===null&&(s.p=f=new Map);let h=f.get(m);h===void 0?(s=Ji(),f.set(m,s)):s=h}}let c=s,l;if(s.s===yf)l=s.v;else if(l=e.apply(null,arguments),a++,o){let d=n?.deref?.()??n;d!=null&&o(d,l)&&(l=d,a!==0&&a--),n=typeof l=="object"&&l!==null||typeof l=="function"?new KP(l):l}return c.s=yf,c.v=l,l}return i.clearCache=()=>{r=Ji(),i.resetResultsCount()},i.resultsCount=()=>a,i.resetResultsCount=()=>{a=0},i}function Sf(e,...t){let r=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,o=(...n)=>{let a=0,i=0,s,u={},c=n.pop();typeof c=="object"&&(u=c,c=n.pop()),UP(c,`createSelector expects an output function after the inputs, but received: [${typeof c}]`);let l={...r,...u},{memoize:d,memoizeOptions:p=[],argsMemoize:m=Xo,argsMemoizeOptions:f=[],devModeChecks:h={}}=l,C=gf(p),S=gf(f),A=$P(n),y=d(function(){return a++,c.apply(null,arguments)},...C),x=!0,I=m(function(){i++;let R=zP(A,arguments);return s=y.apply(null,R),s},...S);return Object.assign(I,{resultFunc:c,memoizedResultFunc:y,dependencies:A,dependencyRecomputations:()=>i,resetDependencyRecomputations:()=>{i=0},lastResult:()=>s,recomputations:()=>a,resetRecomputations:()=>{a=0},memoize:d,argsMemoize:m})};return Object.assign(o,{withTypes:()=>o}),o}var Q=Sf(Xo),HP=Object.assign((e,t=Q)=>{jP(e,`createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ${typeof e}`);let r=Object.keys(e),o=r.map(a=>e[a]);return t(o,(...a)=>a.reduce((i,s,u)=>(i[r[u]]=s,i),{}))},{withTypes:()=>HP});function hf(e){return({dispatch:r,getState:o})=>n=>a=>typeof a=="function"?a(r,o,e):n(a)}var Cf=hf(),xf=hf;var YP=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Jo:Jo.apply(null,arguments)},uM=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(e){return e}},JP=e=>e&&typeof e.match=="function";function g(e,t){function r(...o){if(t){let n=t(...o);if(!n)throw new Error(Ft(0));return{type:e,payload:n.payload,..."meta"in n&&{meta:n.meta},..."error"in n&&{error:n.error}}}return{type:e,payload:o[0]}}return r.toString=()=>`${e}`,r.type=e,r.match=o=>zi(o)&&o.type===e,r}var vf=class Ta extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,Ta.prototype)}static get[Symbol.species](){return Ta}concat(...t){return super.concat.apply(this,t)}prepend(...t){return t.length===1&&Array.isArray(t[0])?new Ta(...t[0].concat(this)):new Ta(...t.concat(this))}};function Rf(e){return He(e)?rr(e,()=>{}):e}function Ff(e,t,r){return e.has(t)?e.get(t):e.set(t,r(t)).get(t)}function XP(e){return typeof e=="boolean"}var ZP=()=>function(t){let{thunk:r=!0,immutableCheck:o=!0,serializableCheck:n=!0,actionCreatorCheck:a=!0}=t??{},i=new vf;return r&&(XP(r)?i.push(Cf):i.push(xf(r.extraArgument))),i},Oa="RTK_autoBatch",en=()=>e=>({payload:e,meta:{[Oa]:!0}}),Pf=e=>t=>{setTimeout(t,e)},eA=(e={type:"raf"})=>t=>(...r)=>{let o=t(...r),n=!0,a=!1,i=!1,s=new Set,u=e.type==="tick"?queueMicrotask:e.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Pf(10):e.type==="callback"?e.queueNotification:Pf(e.timeout),c=()=>{i=!1,a&&(a=!1,s.forEach(l=>l()))};return Object.assign({},o,{subscribe(l){let d=()=>n&&l(),p=o.subscribe(d);return s.add(l),()=>{p(),s.delete(l)}},dispatch(l){try{return n=!l?.meta?.[Oa],a=!n,a&&(i||(i=!0,u(c))),o.dispatch(l)}finally{n=!0}}})},tA=e=>function(r){let{autoBatch:o=!0}=r??{},n=new vf(e);return o&&n.push(eA(typeof o=="object"?o:void 0)),n};function bf(e){let t=ZP(),{reducer:r=void 0,middleware:o,devTools:n=!0,preloadedState:a=void 0,enhancers:i=void 0}=e||{},s;if(typeof r=="function")s=r;else if(Tt(r))s=Yo(r);else throw new Error(Ft(1));let u;typeof o=="function"?u=o(t):u=t();let c=Jo;n&&(c=YP({trace:!1,...typeof n=="object"&&n}));let l=rf(...u),d=tA(l),p=typeof i=="function"?i(d):d(),m=c(...p);return hl(s,a,m)}function wf(e){let t={},r=[],o,n={addCase(a,i){let s=typeof a=="string"?a:a.type;if(!s)throw new Error(Ft(28));if(s in t)throw new Error(Ft(29));return t[s]=i,n},addMatcher(a,i){return r.push({matcher:a,reducer:i}),n},addDefaultCase(a){return o=a,n}};return e(n),[t,r,o]}function rA(e){return typeof e=="function"}function j(e,t){let[r,o,n]=wf(t),a;if(rA(e))a=()=>Rf(e());else{let s=Rf(e);a=()=>s}function i(s=a(),u){let c=[r[u.type],...o.filter(({matcher:l})=>l(u)).map(({reducer:l})=>l)];return c.filter(l=>!!l).length===0&&(c=[n]),c.reduce((l,d)=>{if(d)if(rt(l)){let m=d(l,u);return m===void 0?l:m}else{if(He(l))return rr(l,p=>d(p,u));{let p=d(l,u);if(p===void 0){if(l===null)return l;throw Error("A case reducer on a non-draftable value must not return undefined")}return p}}return l},s)}return i.getInitialState=a,i}var Ef=(e,t)=>JP(e)?e.match(t):e(t);function Ot(...e){return t=>e.some(r=>Ef(r,t))}function Zo(...e){return t=>e.every(r=>Ef(r,t))}function Zi(e,t){if(!e||!e.meta)return!1;let r=typeof e.meta.requestId=="string",o=t.indexOf(e.meta.requestStatus)>-1;return r&&o}function qa(e){return typeof e[0]=="function"&&"pending"in e[0]&&"fulfilled"in e[0]&&"rejected"in e[0]}function es(...e){return e.length===0?t=>Zi(t,["pending"]):qa(e)?Ot(...e.map(t=>t.pending)):es()(e[0])}function go(...e){return e.length===0?t=>Zi(t,["rejected"]):qa(e)?Ot(...e.map(t=>t.rejected)):go()(e[0])}function Da(...e){let t=r=>r&&r.meta&&r.meta.rejectedWithValue;return e.length===0?Zo(go(...e),t):qa(e)?Zo(go(...e),t):Da()(e[0])}function or(...e){return e.length===0?t=>Zi(t,["fulfilled"]):qa(e)?Ot(...e.map(t=>t.fulfilled)):or()(e[0])}function ts(...e){return e.length===0?t=>Zi(t,["pending","fulfilled","rejected"]):qa(e)?Ot(...e.flatMap(t=>[t.pending,t.rejected,t.fulfilled])):ts()(e[0])}var oA="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",rs=(e=21)=>{let t="",r=e;for(;r--;)t+=oA[Math.random()*64|0];return t},nA=["name","message","stack","code"],ql=class{constructor(e,t){We(this,"_type");this.payload=e,this.meta=t}},Af=class{constructor(e,t){We(this,"_type");this.payload=e,this.meta=t}},aA=e=>{if(typeof e=="object"&&e!==null){let t={};for(let r of nA)typeof e[r]=="string"&&(t[r]=e[r]);return t}return{message:String(e)}},_=(()=>{function e(t,r,o){let n=g(t+"/fulfilled",(u,c,l,d)=>({payload:u,meta:{...d||{},arg:l,requestId:c,requestStatus:"fulfilled"}})),a=g(t+"/pending",(u,c,l)=>({payload:void 0,meta:{...l||{},arg:c,requestId:u,requestStatus:"pending"}})),i=g(t+"/rejected",(u,c,l,d,p)=>({payload:d,error:(o&&o.serializeError||aA)(u||"Rejected"),meta:{...p||{},arg:l,requestId:c,rejectedWithValue:!!d,requestStatus:"rejected",aborted:u?.name==="AbortError",condition:u?.name==="ConditionError"}}));function s(u){return(c,l,d)=>{let p=o?.idGenerator?o.idGenerator(u):rs(),m=new AbortController,f,h;function C(A){h=A,m.abort()}let S=async function(){let A;try{let x=o?.condition?.(u,{getState:l,extra:d});if(sA(x)&&(x=await x),x===!1||m.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};let I=new Promise((v,R)=>{f=()=>{R({name:"AbortError",message:h||"Aborted"})},m.signal.addEventListener("abort",f)});c(a(p,u,o?.getPendingMeta?.({requestId:p,arg:u},{getState:l,extra:d}))),A=await Promise.race([I,Promise.resolve(r(u,{dispatch:c,getState:l,extra:d,requestId:p,signal:m.signal,abort:C,rejectWithValue:(v,R)=>new ql(v,R),fulfillWithValue:(v,R)=>new Af(v,R)})).then(v=>{if(v instanceof ql)throw v;return v instanceof Af?n(v.payload,p,u,v.meta):n(v,p,u)})])}catch(x){A=x instanceof ql?i(null,p,u,x.payload,x.meta):i(x,p,u)}finally{f&&m.signal.removeEventListener("abort",f)}return o&&!o.dispatchConditionRejection&&i.match(A)&&A.meta.condition||c(A),A}();return Object.assign(S,{abort:C,requestId:p,arg:u,unwrap(){return S.then(iA)}})}}return Object.assign(s,{pending:a,rejected:i,fulfilled:n,settled:Ot(i,n),typePrefix:t})}return e.withTypes=()=>e,e})();function iA(e){if(e.meta&&e.meta.rejectedWithValue)throw e.payload;if(e.error)throw e.error;return e.payload}function sA(e){return e!==null&&typeof e=="object"&&typeof e.then=="function"}var If=Symbol.for("rtk-slice-createasyncthunk"),fM={[If]:_};function cA(e,t){return`${e}/${t}`}function uA({creators:e}={}){let t=e?.asyncThunk?.[If];return function(o){let{name:n,reducerPath:a=n}=o;if(!n)throw new Error(Ft(11));typeof process<"u";let i=(typeof o.reducers=="function"?o.reducers(dA()):o.reducers)||{},s=Object.keys(i),u={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},c={addCase(A,y){let x=typeof A=="string"?A:A.type;if(!x)throw new Error(Ft(12));if(x in u.sliceCaseReducersByType)throw new Error(Ft(13));return u.sliceCaseReducersByType[x]=y,c},addMatcher(A,y){return u.sliceMatchers.push({matcher:A,reducer:y}),c},exposeAction(A,y){return u.actionCreators[A]=y,c},exposeCaseReducer(A,y){return u.sliceCaseReducersByName[A]=y,c}};s.forEach(A=>{let y=i[A],x={reducerName:A,type:cA(n,A),createNotation:typeof o.reducers=="function"};pA(y)?gA(x,y,c,t):mA(x,y,c)});function l(){let[A={},y=[],x=void 0]=typeof o.extraReducers=="function"?wf(o.extraReducers):[o.extraReducers],I={...A,...u.sliceCaseReducersByType};return j(o.initialState,v=>{for(let R in I)v.addCase(R,I[R]);for(let R of u.sliceMatchers)v.addMatcher(R.matcher,R.reducer);for(let R of y)v.addMatcher(R.matcher,R.reducer);x&&v.addDefaultCase(x)})}let d=A=>A,p=new Map,m;function f(A,y){return m||(m=l()),m(A,y)}function h(){return m||(m=l()),m.getInitialState()}function C(A,y=!1){function x(v){let R=v[A];return typeof R>"u"&&y&&(R=h()),R}function I(v=d){let R=Ff(p,y,()=>new WeakMap);return Ff(R,v,()=>{let P={};for(let[b,T]of Object.entries(o.selectors??{}))P[b]=lA(T,v,h,y);return P})}return{reducerPath:A,getSelectors:I,get selectors(){return I(x)},selectSlice:x}}let S={name:n,reducer:f,actions:u.actionCreators,caseReducers:u.sliceCaseReducersByName,getInitialState:h,...C(a),injectInto(A,{reducerPath:y,...x}={}){let I=y??a;return A.inject({reducerPath:I,reducer:f},x),{...S,...C(I,!0)}}};return S}}function lA(e,t,r,o){function n(a,...i){let s=t(a);return typeof s>"u"&&o&&(s=r()),e(s,...i)}return n.unwrapped=e,n}var yo=uA();function dA(){function e(t,r){return{_reducerDefinitionType:"asyncThunk",payloadCreator:t,...r}}return e.withTypes=()=>e,{reducer(t){return Object.assign({[t.name](...r){return t(...r)}}[t.name],{_reducerDefinitionType:"reducer"})},preparedReducer(t,r){return{_reducerDefinitionType:"reducerWithPrepare",prepare:t,reducer:r}},asyncThunk:e}}function mA({type:e,reducerName:t,createNotation:r},o,n){let a,i;if("reducer"in o){if(r&&!fA(o))throw new Error(Ft(17));a=o.reducer,i=o.prepare}else a=o;n.addCase(e,a).exposeCaseReducer(t,a).exposeAction(t,i?g(e,i):g(e))}function pA(e){return e._reducerDefinitionType==="asyncThunk"}function fA(e){return e._reducerDefinitionType==="reducerWithPrepare"}function gA({type:e,reducerName:t},r,o,n){if(!n)throw new Error(Ft(18));let{payloadCreator:a,fulfilled:i,pending:s,rejected:u,settled:c,options:l}=r,d=n(e,a,l);o.exposeAction(t,d),i&&o.addCase(d.fulfilled,i),s&&o.addCase(d.pending,s),u&&o.addCase(d.rejected,u),c&&o.addMatcher(d.settled,c),o.exposeCaseReducer(t,{fulfilled:i||Xi,pending:s||Xi,rejected:u||Xi,settled:c||Xi})}function Xi(){}var Tf="listener",Of="completed",qf="cancelled",gM=`task-${qf}`,yM=`task-${Of}`,SM=`${Tf}-${qf}`,hM=`${Tf}-${Of}`;var{assign:Df}=Object;var Dl="listenerMiddleware";var yA=Df(g(`${Dl}/add`),{withTypes:()=>yA}),CM=g(`${Dl}/removeAll`),SA=Df(g(`${Dl}/remove`),{withTypes:()=>SA});var xM=Symbol.for("rtk-state-proxy-original");function Ft(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}import{Schema as hA,SchemaValidationError as CA,StringValue as ka,RecordValue as xA,ArrayValue as RA}from"@coveo/bueno";var D=new ka({required:!0,emptyAllowed:!1}),ne=new ka({required:!1,emptyAllowed:!1}),me=new ka({required:!0,emptyAllowed:!0}),kf=new ka({required:!1,emptyAllowed:!0}),os=new RA({each:D,required:!0}),Vf=new ka({required:!1,emptyAllowed:!1,regex:/^\d+\.\d+\.\d+$/}),je=({message:e,name:t,stack:r})=>({message:e,name:t,stack:r}),Se=(e,t)=>{if("required"in t)return{payload:new hA({value:t}).validate({value:e}).value};let n=new xA({options:{required:!0},values:t}).validate(e);if(n)throw new CA(n);return{payload:e}},F=(e,t)=>{try{return Se(e,t)}catch(r){return{payload:e,error:je(r)}}},Ye=(e,t,r,o)=>{let n=`Check the initialState of ${o}`;return Nf(e,t,r,n,"Controller initialization error")},_e=(e,t,r,o)=>{let n=`Check the options of ${o}`;return Nf(e,t,r,n,"Controller initialization error")},Nf=(e,t,r,o,n)=>{try{return t.validate(r,o)}catch(a){throw e.logger.error(a,n),a}};import{ArrayValue as FA,BooleanValue as Qf,RecordValue as PA,StringValue as Va,Value as AA}from"@coveo/bueno";var So="3.23.2-pre.d35ebef42a",Mf=["@coveo/atomic","@coveo/quantic"];var kl=()=>ne,Lf=()=>D,ho=g("configuration/updateBasicConfiguration",e=>F(e,{accessToken:ne,environment:new Va({required:!1,constrainTo:["prod","hipaa","stg","dev"]}),organizationId:ne})),Bf=g("configuration/updateSearchConfiguration",e=>F(e,{proxyBaseUrl:new Va({required:!1,url:!0}),pipeline:new Va({required:!1,emptyAllowed:!0}),searchHub:ne,timezone:ne,locale:ne,authenticationProviders:new FA({required:!1,each:D})})),tn={enabled:new Qf({default:!0}),originContext:kl(),originLevel2:kl(),originLevel3:kl(),proxyBaseUrl:new Va({required:!1,url:!0}),runtimeEnvironment:new AA,anonymous:new Qf({default:!1}),deviceId:ne,userDisplayName:ne,documentLocation:ne,trackingId:ne,analyticsMode:new Va({constrainTo:["legacy","next"],required:!1,default:"next"}),source:new PA({options:{required:!1},values:Mf.reduce((e,t)=>(e[t]=Vf,e),{})})},Vl=g("configuration/updateAnalyticsConfiguration",e=>F(e,tn)),ns=g("configuration/analytics/disable"),as=g("configuration/analytics/enable"),Uf=g("configuration/analytics/originlevel2",e=>F(e,{originLevel2:Lf()})),jf=g("configuration/analytics/originlevel3",e=>F(e,{originLevel3:Lf()}));var rn=g("commerce/configuration/updateBasicConfiguration",e=>F(e,{accessToken:ne,environment:new _f({required:!1,constrainTo:["prod","hipaa","stg","dev"]}),organizationId:ne})),on=g("commerce/configuration/updateProxyBaseUrl",e=>F(e,{proxyBaseUrl:new _f({required:!1,url:!0})})),nn=g("commerce/configuration/updateAnalyticsConfiguration",e=>F(e,{enabled:tn.enabled,proxyBaseUrl:tn.proxyBaseUrl,source:tn.source,trackingId:tn.trackingId})),is=g("commerce/configuration/analytics/disable"),ss=g("commerce/configuration/analytics/enable");import{isNullOrUndefined as Co}from"@coveo/bueno";var $f=()=>({accessToken:"",environment:"prod",organizationId:"",analytics:{enabled:!0,trackingId:"",source:{}},commerce:{}});var Nl=j($f(),e=>e.addCase(rn,(t,r)=>{zf(t,r.payload)}).addCase(ho,(t,r)=>{zf(t,r.payload)}).addCase(on,(t,r)=>{vA(t,r.payload)}).addCase(nn,(t,r)=>{bA(t,r.payload)}).addCase(is,t=>{t.analytics.enabled=!1}).addCase(ss,t=>{t.analytics.enabled=!0}));function zf(e,t){Co(t.accessToken)||(e.accessToken=t.accessToken),e.environment=t.environment??"prod",Co(t.organizationId)||(e.organizationId=t.organizationId)}function vA(e,t){Co(t.proxyBaseUrl)||(e.commerce.apiBaseUrl=t.proxyBaseUrl)}function bA(e,t){Co(t.enabled)||(e.analytics.enabled=t.enabled),Co(t.proxyBaseUrl)||(e.analytics.apiBaseUrl=t.proxyBaseUrl),Co(t.source)||(e.analytics.source=t.source),Co(t.trackingId)||(e.analytics.trackingId=t.trackingId)}function an(e){return e.currency}var Wf=(e,t)=>({currency:an(t.commerceContext),products:wA(t.cart),transaction:e}),Kf=(e,t)=>({currency:an(t.commerceContext),...e}),xo=Q(e=>e.cart,e=>e.cartItems,(e,t)=>t.map(r=>e[r])),wA=Q(xo,e=>e.map(({quantity:t,...r})=>({quantity:t,product:r})));import{ArrayValue as EA,NumberValue as Gf,RecordValue as IA,Schema as TA,StringValue as OA}from"@coveo/bueno";var Ml={productId:D,quantity:new Gf({required:!0,min:0}),name:new OA({required:!1}),price:new Gf({required:!1,min:0})},Ql=new EA({each:new IA({values:{...Ml}})}),Ll={items:Ql},Hf=new TA(Ll);var xr=g("commerce/cart/setItems",e=>F(e,Ql)),sn=g("commerce/cart/updateItemQuantity",e=>F(e,Ml)),cn=g("commerce/cart/purchase"),cs=_("commerce/cart/emit/purchaseEvent",async(e,{extra:t,getState:r})=>{let o=Wf(e,r()),{relay:n}=t;n.emit("ec.purchase",o)}),us=_("commerce/cart/emit/cartActionEvent",async(e,{extra:t,getState:r})=>{let o=Kf(e,r()),{relay:n}=t;n.emit("ec.cartAction",o)});function W(e){let t,r=new Map,o=()=>r.size===0,n=a=>{try{let i=JSON.stringify(a),s=t!==i;return t=i,s}catch(i){return console.warn('Could not detect if state has changed, check the controller "get state method"',i),!0}};return{subscribe(a){a();let i=Symbol(),s;return o()&&(t=JSON.stringify(this.state),s=e.subscribe(()=>{n(this.state)&&r.forEach(u=>u())})),r.set(i,a),()=>{r.delete(i),o()&&s&&s()}},get state(){return{}}}}function Yf(e,t){return e.cart[Ro(t)]}var Jf=Q(xo,e=>e.reduce((t,r)=>t+r.quantity,0)),Xf=Q(xo,e=>e.reduce((t,r)=>t+r.price*r.quantity,0));function Zf(e,t={}){if(!qA(e))throw $;let{dispatch:r}=e,o=W(e),n=()=>e[U].cart,a={...t.initialState};Ye(e,Hf,a,"buildCart"),a.items!==void 0&&r(xr(a.items));function i(l,d){return d?d.quantity!==l.quantity:!0}function s(l,d){return!d||l.quantity>d.quantity?"add":"remove"}function u(l,d){return d?l.name===d.name&&l.price===d.price&&l.quantity===d.quantity:!1}function c(l,d){let{quantity:p,...m}=l,f=s(l,d),h=d?Math.abs(p-d.quantity):p;return{action:f,quantity:h,product:m}}return{...o,empty:function(){for(let l of xo(n()))this.updateItemQuantity({...l,quantity:0})},purchase(l){r(cs(l)),r(cn())},updateItemQuantity(l){let d=Yf(n(),l);!d&&l.quantity<=0||u(l,d)||(i(l,d)&&r(us(c(l,d))),r(sn(l)))},get state(){let l=n();return{items:xo(l),totalQuantity:Jf(l),totalPrice:Xf(l)}}}}function Ro(e){return`${e.productId},${e.name},${e.price}`}function qA(e){return e.addReducers({cart:un}),!0}var ls=()=>({cartItems:[],cart:{},purchasedItems:[],purchased:{}}),eg=e=>rg(e.cartItems,e.cart),tg=e=>rg(e.purchasedItems,e.purchased);function rg(e,t){let r=e.reduce((o,n)=>{let{productId:a,quantity:i}=t[n];return a in o||(o[a]={productId:a,quantity:0}),o[a].quantity+=i,o},{});return[...Object.values(r)]}var un=j(ls(),e=>{e.addCase(xr,(t,{payload:r})=>{let{cart:o,cartItems:n}=r.reduce((a,i)=>{let s=Ro(i);return{cartItems:[...a.cartItems,s],cart:{...a.cart,[s]:i},purchasedItems:[],purchased:{}}},ls());og(t,n,o)}).addCase(sn,(t,{payload:r})=>{let o=Ro(r);if(!(o in t.cart)){DA(r,t);return}if(r.quantity<=0){kA(r,t);return}t.cart[o]=r}).addCase(cn,t=>{VA(t);let{cart:r,cartItems:o}=ls();og(t,o,r)})});function og(e,t,r){e.cartItems=t,e.cart=r}function DA(e,t){if(e.quantity<=0)return;let r=Ro(e);t.cartItems=[...t.cartItems,r],t.cart[r]=e}function kA(e,t){let r=Ro(e);t.cartItems=t.cartItems.filter(o=>o!==r),delete t.cart[r]}function VA(e){for(let t of e.cartItems){if(t in e.purchased){e.purchased[t].quantity+=e.cart[t].quantity;continue}e.purchasedItems=[...e.purchasedItems,t],e.purchased[t]=e.cart[t]}}import{NumberValue as ng,RecordValue as ag,Schema as NA,StringValue as MA}from"@coveo/bueno";var QA=Intl.supportedValuesOf("currency"),LA=new MA({required:!0,emptyAllowed:!1,constrainTo:QA}),Bl={url:D},Ul={latitude:new ng({min:-90,max:90,required:!0}),longitude:new ng({min:-180,max:180,required:!0})},Na={language:D,country:D,currency:LA,view:new ag({options:{required:!0},values:Bl}),location:new ag({options:{required:!1},values:Ul})},ig=new NA(Na);var ce=g("commerce/context/set",e=>F(e,Na)),le=g("commerce/context/setView",e=>F(e,Bl)),ln=g("commerce/context/setLocation",e=>F(e,Ul));var sg=()=>({language:"",country:"",currency:"",view:{url:""}});var qt=j(sg(),e=>{e.addCase(ce,(t,{payload:r})=>r).addCase(le,(t,{payload:r})=>{t.view=r}).addCase(ln,(t,{payload:r})=>{t.location=r})});var ds=()=>({correctedQuery:"",corrections:[],originalQuery:""});import{BooleanValue as sv,RecordValue as cv,StringValue as Ig}from"@coveo/bueno";var ct=g("breadcrumb/deselectAll"),Rr=g("breadcrumb/deselectAllNonBreadcrumbs");var Fr=Q(e=>e.source,e=>Object.entries(e).map(([t,r])=>`${t}@${r}`).concat(`@coveo/headless@${So}`));var Pr=(e,t)=>{let{view:r,location:o,...n}=e.commerceContext;return{accessToken:e.configuration.accessToken,url:e.configuration.commerce.apiBaseUrl??yl(e.configuration.organizationId,e.configuration.environment),organizationId:e.configuration.organizationId,trackingId:e.configuration.analytics.trackingId,...n,...e.configuration.analytics.enabled?{clientId:t.clientId}:{},context:{user:{...o,...t.userAgent?{userAgent:t.userAgent}:{}},view:{...r,...t.referrer?{referrer:t.referrer}:{}},capture:t.capture??e.configuration.analytics.enabled,cart:eg(e.cart),source:Fr(e.configuration.analytics)}}};import{ArrayValue as jA,EnumValue as lg,StringValue as dg,RecordValue as mg}from"@coveo/bueno";import{ArrayValue as BA,EnumValue as cg,RecordValue as ug,StringValue as UA}from"@coveo/bueno";var Pt=(r=>(r.Relevance="relevance",r.Fields="fields",r))(Pt||{}),dn=(r=>(r.Ascending="asc",r.Descending="desc",r))(dn||{}),nr=()=>({by:"relevance"});var mQ=new ug({options:{required:!1},values:{by:new cg({enum:Pt,required:!0}),fields:new BA({each:new ug({values:{name:new UA,direction:new cg({enum:dn})}})})}});var jl=e=>({by:"fields",fields:e}),pg=new mg({options:{required:!1},values:{by:new lg({enum:Pt,required:!0}),fields:new jA({each:new mg({values:{field:new dg({required:!0}),direction:new lg({enum:dn}),displayName:new dg}})})}});var ms=(e,t,r)=>({...Pr(e,t),..._A(e,r)}),_A=(e,t)=>{let r=t?e.commercePagination?.recommendations[t]:e.commercePagination?.principal;return r&&{page:r.page,...r.perPage&&{perPage:r.perPage}}};var ut=(e,t)=>({...ms(e,t),facets:[...$A(e)],...e.commerceSort&&{sort:zA(e.commerceSort.appliedSort)}});function $A(e){return!e.facetOrder||!e.commerceFacetSet?[]:e.facetOrder.filter(t=>e.commerceFacetSet?.[t]).map(t=>e.manualNumericFacetSet?.[t]?.manualRange?{facetId:t,field:t,numberOfValues:1,isFieldExpanded:!1,preventAutoSelect:!0,type:"numericalRange",values:[e.manualNumericFacetSet[t].manualRange],initialNumberOfValues:1}:e.commerceFacetSet[t].request).filter(t=>t&&t.values.length>0)}function zA(e){return e.by==="relevance"?{sortCriteria:"relevance"}:{sortCriteria:"fields",fields:e.fields.map(({name:t,direction:r})=>({field:t,direction:r}))}}import{BooleanValue as _l,NumberValue as WA}from"@coveo/bueno";var Fo=g("commerce/facets/core/updateNumberOfValues",e=>F(e,{facetId:D,numberOfValues:new WA({required:!0,min:1})})),Po=g("commerce/facets/core/updateIsFieldExpanded",e=>F(e,{facetId:D,isFieldExpanded:new _l({required:!0})})),pe=g("commerce/facets/core/clearAll"),De=g("commerce/facets/core/deselectAllValues",e=>F(e,{facetId:D})),Ao=g("commerce/facets/core/updateFreezeCurrentValues",e=>F(e,{facetId:D,freezeCurrentValues:new _l({required:!0})})),mn=g("commerce/facets/core/updateAutoSelectionForAll",e=>F(e,{allow:new _l({required:!0})}));import{NumberValue as fg}from"@coveo/bueno";var ps={slotId:kf},KA={...ps,pageSize:new fg({required:!0,min:0})},ar=g("commerce/pagination/setPageSize",e=>F(e,KA)),GA={...ps,page:new fg({required:!0,min:0})},Dt=g("commerce/pagination/selectPage",e=>F(e,GA)),Ar=g("commerce/pagination/nextPage",e=>F(e,ps)),vr=g("commerce/pagination/previousPage",e=>F(e,ps)),pn=g("commerce/pagination/registerRecommendationsSlot",e=>F(e,{slotId:D}));var br=Q(e=>e.commercePagination?.principal.perPage||0,e=>e),fs=Q((e,t)=>e.commercePagination?.recommendations[t]?.perPage||0,e=>e),wr=Q(e=>e.commercePagination?.principal.totalEntries||0,e=>e),gs=Q((e,t)=>e.commercePagination?.recommendations[t]?.totalEntries||0,e=>e),ys=Q(e=>e.commercePagination?.principal.page||0,e=>e),gg=Q((e,t)=>e.commercePagination?.recommendations[t]?.page||0,e=>e);import{StringValue as HA}from"@coveo/bueno";var fe=g("commerce/query/update",e=>F(e,{query:new HA}));import{isNullOrUndefined as Eg}from"@coveo/bueno";import{RecordValue as YA,StringValue as JA}from"@coveo/bueno";var Er=g("commerce/triggers/query/updateIgnore",e=>F(e,{q:new JA({emptyAllowed:!0,required:!0})})),fn=g("commerce/triggers/query/applyModification",e=>F(e,new YA({values:{originalQuery:ne,modification:ne}})));import{isNullOrUndefined as xg}from"@coveo/bueno";function $l(e,t,r){if(e===void 0)return{};let o=t(e);return o!==r?{q:o}:{}}function zl(e,t,r){if(e===void 0)return{};let o=t(e);return o!==r?{sortCriteria:o}:{}}function kt(e,t,r,o){if(e===void 0)return{};let n=Object.entries(e).filter(([a])=>t(a)).map(([a,{request:i}])=>{let s=r(i);return s.length?{[a]:s}:{}}).reduce((a,i)=>({...a,...i}),{});return Object.keys(n).length?{[o]:n}:{}}function Vt(e){let{activeValue:t,ancestryMap:r}=XA(e);return t?ZA(t,r):[]}function XA(e){let t=[...e],r=new Map;for(;t.length>0;){let o=t.shift();if(o.state==="selected")return{activeValue:o,ancestryMap:r};if(r)for(let n of o.children)r.set(n,o);t.unshift(...o.children)}return{}}function ZA(e,t){let r=[];if(!e)return[];let o=e;do r.unshift(o),o=t.get(o);while(o);return r}function yg(){return{principal:Ir(),recommendations:{}}}function Ir(){return{page:0,perPage:0,totalEntries:0,totalPages:0}}function vo(){return{appliedSort:nr(),availableSorts:[nr()]}}function Ss(e){return{...ev(e?.commercePagination,t=>t.principal.page,Ir().page),...tv(e?.commercePagination,t=>t.principal.perPage,Ir().perPage),...zl(e?.commerceSort,t=>t.appliedSort,vo().appliedSort),...kt(e.commerceFacetSet,Tr(e,"regular"),rv,"f"),...kt(e.commerceFacetSet,Tr(e,"regular"),ov,"fExcluded"),...kt(e.commerceFacetSet,Tr(e,"location"),nv,"lf"),...kt(e.commerceFacetSet,Tr(e,"hierarchical"),av,"cf"),...kt(e.commerceFacetSet,Tr(e,"dateRange"),Sg,"df"),...kt(e.commerceFacetSet,Tr(e,"dateRange"),hg,"dfExcluded"),...kt(e.commerceFacetSet,Tr(e,"numericalRange"),Sg,"nf"),...kt(e.commerceFacetSet,Tr(e,"numericalRange"),hg,"nfExcluded"),...Cg("selected",e.manualNumericFacetSet),...Cg("excluded",e.manualNumericFacetSet)}}function ev(e,t,r){if(e===void 0)return{};let o=t(e);return o!==r?{page:o}:{}}function tv(e,t,r){if(e===void 0)return{};let o=t(e);return o!==r?{perPage:o}:{}}function rv(e){return e.values.filter(t=>t.state==="selected").map(t=>t.value)}function ov(e){return e.values.filter(t=>t.state==="excluded").map(t=>t.value)}function nv(e){return e.values.filter(t=>t.state==="selected").map(t=>t.value)}function Sg(e){return e.values.filter(t=>t.state==="selected")}function hg(e){return e.values.filter(t=>t.state==="excluded")}function Cg(e,t){if(!t||e==="idle")return{};let r=Object.entries(t).map(([o,n])=>{if(!(n.manualRange===void 0||n.manualRange.state!==e))return{[o]:[n.manualRange]}}).filter(o=>o!==void 0).reduce((o,n)=>({...o,...n}),{});return e==="selected"?{mnf:r}:{mnfExcluded:r}}function av(e){return Vt(e.values).map(r=>r.value)}function Tr(e,t){return r=>e.commerceFacetSet[r].request.type===t}var hs=()=>({query:""});var mL=Q(e=>e[U].commerceSearch.responseId,e=>e),Wl=Q(e=>e.commerceSearch.responseId,e=>e),Rg=Q(e=>e.commerceSearch.requestId,e=>e),Ma=Q(e=>e.commerceSearch?.products.length||0,e=>e),Fg=Q(e=>({total:wr(e),current:Ma(e)}),({current:e,total:t})=>e<t),Pg=Q(e=>e.commerceSearch?.isLoading,e=>xg(e)?!1:e),Ag=Q(e=>e.commerceSearch?.error,e=>e??null),Cs=Q(e=>e.commerceQuery?.query,e=>e??""),iv=Q(e=>e.commerceSearch?.queryExecuted,e=>e),vg=(e,t)=>xg(t.queryCorrection?.correctedQuery)?Cs(e):t.queryCorrection.correctedQuery,bg=e=>({...$l(e?.commerceQuery,t=>t.query,hs().query),...Ss(e)});function wg(e){return{query:iv(e)||""}}var Qa=class{constructor(t){this.config=t}async process(t){return this.processQueryErrorOrContinue(t)??await this.processQueryCorrectionsOrContinue(t)??await this.processQueryTriggersOrContinue(t)??this.processSuccessResponse(t)}async fetchFromAPI(t){let r=new Date().getTime(),o=await this.extra.apiClient.search(t),n=new Date().getTime()-r,a=this.getState().commerceQuery.query||"";return{response:o,duration:n,queryExecuted:a,requestExecuted:t}}processSuccessResponse(t){return{...t,response:this.getSuccessResponse(t),originalQuery:this.getCurrentQuery()}}processQueryErrorOrContinue(t){return qe(t.response)?this.rejectWithValue(t.response.error):null}async processQueryCorrectionsOrContinue(t){let r=this.getState(),o=this.getSuccessResponse(t);if(!o||!r.didYouMean)return null;let{queryCorrection:n}=o;if(!(!Eg(n)&&!Eg(n.correctedQuery)))return null;let{correctedQuery:i,originalQuery:s}=o.queryCorrection;return this.onUpdateQueryForCorrection(i??""),{...t,response:{...o},queryExecuted:vg(r,o),originalQuery:s??""}}async processQueryTriggersOrContinue(t){let r=this.getSuccessResponse(t);if(!r)return null;let o=r.triggers.find(s=>s.type==="query")?.content||"";if(!o)return null;if(this.getState().triggers?.queryModification.queryToIgnore===o)return this.dispatch(Er({q:""})),null;let a=this.getCurrentQuery(),i=await this.automaticallyRetryQueryWithTriggerModification(o);return qe(i.response)?this.rejectWithValue(i.response.error):{...i,response:{...i.response.success},originalQuery:a}}async automaticallyRetryQueryWithTriggerModification(t){return this.dispatch(fn({newQuery:t,originalQuery:this.getCurrentQuery()})),this.onUpdateQueryForCorrection(t),await this.fetchFromAPI({...ut(this.getState(),this.navigatorContext),query:t})}get dispatch(){return this.config.dispatch}get rejectWithValue(){return this.config.rejectWithValue}getState(){return this.config.getState()}get navigatorContext(){return this.config.extra.navigatorContext}getCurrentQuery(){let t=this.getState();return t.commerceQuery.query!==void 0?t.commerceQuery.query:""}getSuccessResponse(t){return qe(t.response)?null:t.response.success}get extra(){return this.config.extra}onUpdateQueryForCorrection(t){this.dispatch(fe({query:t}))}};var X=_("commerce/search/executeSearch",async(e,t)=>{let{getState:r}=t,o=r(),{navigatorContext:n}=t.extra,a=ut(o,n),i=Cs(o),s=new Qa(t),u=await s.fetchFromAPI({...a,query:i});return s.process(u)}),Or=_("commerce/search/fetchMoreProducts",async(e,t)=>{let{getState:r}=t,o=r(),{navigatorContext:n}=t.extra;if(!Fg(o))return null;let i=br(o),u=Ma(o)/i,c=Cs(o),l=ut(o,n),d=new Qa(t),p=await d.fetchFromAPI({...l,query:c,page:u});return d.process(p)}),gn=_("commerce/search/prepareForSearchWithQuery",(e,t)=>{let{dispatch:r}=t;F(e,{query:new Ig,clearFilters:new sv}),e.clearFilters&&(r(pe()),r(Rr())),r(mn({allow:!0})),r(fe({query:e.query})),r(Dt({page:0}))}),yn=_("commerce/search/fetchInstantProducts",async(e,{getState:t,rejectWithValue:r,extra:o})=>{let n=t(),{apiClient:a,navigatorContext:i}=o,{q:s}=e,u=await a.productSuggestions({...Pr(n,i),query:s});return qe(u)?r(u.error):{response:{...u.success,products:u.success.products}}}),uv={child:new cv({options:{required:!0},values:{permanentid:new Ig({required:!0})}})},Sn=g("commerce/search/promoteChildToParent",e=>F(e,uv));function Tg(){return{wasCorrectedTo:"",queryCorrection:ds(),originalQuery:""}}var xs=j(Tg(),e=>{e.addCase(X.pending,t=>{t.queryCorrection=ds(),t.wasCorrectedTo=""}).addCase(X.fulfilled,(t,r)=>{let{queryCorrection:o}=r.payload.response;t.originalQuery=r.payload.originalQuery,t.wasCorrectedTo=o?.correctedQuery??"",t.queryCorrection={correctedQuery:o?.correctedQuery??o?.corrections[0]?.correctedQuery??"",wordCorrections:o?.corrections[0]?.wordCorrections??[]}})});import{Value as Dg,BooleanValue as Og,ArrayValue as Fs,StringValue as Rs,NumberValue as qg,RecordValue as yv}from"@coveo/bueno";var H=D;import{Value as lv,NumberValue as dv,StringValue as mv,ArrayValue as pv,BooleanValue as fv}from"@coveo/bueno";var gv={state:new lv({required:!0}),numberOfResults:new dv({required:!0,min:0}),value:new mv({required:!0,emptyAllowed:!0}),path:new pv({required:!0,each:D}),moreValuesAvailable:new fv({required:!1})};function La(e){e.children.forEach(t=>{La(t)}),Se({state:e.state,numberOfResults:e.numberOfResults,value:e.value,path:e.path,moreValuesAvailable:e.moreValuesAvailable},gv)}var hn={facetId:H,field:D,tabs:new yv({options:{required:!1},values:{included:new Fs({each:new Rs}),excluded:new Fs({each:new Rs})}}),activeTab:new Rs({required:!1}),delimitingCharacter:new Rs({required:!1,emptyAllowed:!0}),filterFacetCount:new Og({required:!1}),injectionDepth:new qg({required:!1,min:0}),numberOfValues:new qg({required:!1,min:1}),sortCriteria:new Dg({required:!1}),basePath:new Fs({required:!1,each:D}),filterByBasePath:new Og({required:!1})},Cn=5,kg=g("categoryFacet/register",e=>F(e,hn)),Vg=g("categoryFacet/toggleSelectValue",e=>{try{return Se(e.facetId,D),La(e.selection),{payload:e,error:null}}catch(t){return{payload:e,error:je(t)}}}),Ng=g("categoryFacet/deselectAll",e=>F(e,hn.facetId)),nB=g("categoryFacet/updateNumberOfValues",e=>F(e,{facetId:hn.facetId,numberOfValues:hn.numberOfValues})),aB=g("categoryFacet/updateSortCriterion",e=>F(e,{facetId:hn.facetId,criterion:new Dg})),iB=g("categoryFacet/updateBasePath",e=>F(e,{facetId:hn.facetId,basePath:new Fs({each:D})}));import{NumberValue as xv,RecordValue as Rv,ArrayValue as Fv}from"@coveo/bueno";import{RecordValue as Sv,NumberValue as hv,StringValue as Cv}from"@coveo/bueno";var Ba={facetId:H,captions:new Sv({options:{required:!1}}),numberOfValues:new hv({required:!1,min:1}),query:new Cv({required:!1,emptyAllowed:!0})};var Pv={path:new Fv({required:!0,each:D}),displayValue:me,rawValue:me,count:new xv({required:!0,min:0})},Nt=g("categoryFacet/selectSearchResult",e=>F(e,{facetId:H,value:new Rv({values:Pv})})),Ps=g("categoryFacetSearch/register",e=>F(e,Ba));import{RecordValue as Av,NumberValue as vv}from"@coveo/bueno";var Mg={facetId:H,value:new Av({values:{displayValue:me,rawValue:me,count:new vv({required:!0,min:0})}})},As=g("facetSearch/register",e=>F(e,Ba)),qr=g("facetSearch/update",e=>F(e,Ba)),nt=g("facetSearch/toggleSelectValue",e=>F(e,Mg)),At=g("facetSearch/toggleExcludeValue",e=>F(e,Mg));import{BooleanValue as bv}from"@coveo/bueno";var ir=g("facetOptions/update",(e={freezeFacetOrder:!0})=>F(e,{freezeFacetOrder:new bv({required:!1})})),Kl=g("facetOptions/facet/enable",e=>F(e,H)),sr=g("facetOptions/facet/disable",e=>F(e,H));var wv=g("history/undo"),Ev=g("history/redo"),Mt=g("history/snapshot"),IB=_("history/back",async(e,{dispatch:t})=>{t(wv()),await t(xe())}),TB=_("history/forward",async(e,{dispatch:t})=>{t(Ev()),await t(xe())}),xe=_("history/change",async(e,{getState:t})=>t().history.present);import{BooleanValue as Qg,StringValue as Ua,NumberValue as Lg,RecordValue as Dr}from"@coveo/bueno";var vs={q:new Ua,enableQuerySyntax:new Qg,aq:new Ua,cq:new Ua,firstResult:new Lg({min:0}),numberOfResults:new Lg({min:0}),sortCriteria:new Ua,f:new Dr,fExcluded:new Dr,cf:new Dr,nf:new Dr,mnf:new Dr,df:new Dr,debug:new Qg,sf:new Dr,tab:new Ua,af:new Dr};var we=g("searchParameters/restore",e=>F(e,vs)),Iv=g("searchParameters/restoreTab",e=>F(e,D));import{BooleanValue as pS,NumberValue as fS,StringValue as ME}from"@coveo/bueno";function cr(e,t){var r={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(r[o]=e[o]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,o=Object.getOwnPropertySymbols(e);n<o.length;n++)t.indexOf(o[n])<0&&Object.prototype.propertyIsEnumerable.call(e,o[n])&&(r[o[n]]=e[o[n]]);return r}function w(e,t,r,o){function n(a){return a instanceof r?a:new r(function(i){i(a)})}return new(r||(r=Promise))(function(a,i){function s(l){try{c(o.next(l))}catch(d){i(d)}}function u(l){try{c(o.throw(l))}catch(d){i(d)}}function c(l){l.done?a(l.value):n(l.value).then(s,u)}c((o=o.apply(e,t||[])).next())})}var ee;(function(e){e.search="search",e.click="click",e.custom="custom",e.view="view",e.collect="collect"})(ee||(ee={}));function Yl(){return typeof window<"u"}function ud(){return typeof navigator<"u"}function xn(){return typeof document<"u"}function Jl(){try{return typeof localStorage<"u"}catch{return!1}}function Tv(){try{return typeof sessionStorage<"u"}catch{return!1}}function Zg(){return ud()&&navigator.cookieEnabled}var Ov=[ee.click,ee.custom,ee.search,ee.view],qv=(e,t)=>Ov.indexOf(e)!==-1?Object.assign({language:xn()?document.documentElement.lang:"unknown",userAgent:ud()?navigator.userAgent:"unknown"},t):t,$a=class e{static set(t,r,o){var n,a,i,s;o&&(a=new Date,a.setTime(a.getTime()+o)),s=window.location.hostname,s.indexOf(".")===-1?Bg(t,r,a):(i=s.split("."),n=i[i.length-2]+"."+i[i.length-1],Bg(t,r,a,n))}static get(t){for(var r=t+"=",o=document.cookie.split(";"),n=0;n<o.length;n++){var a=o[n];if(a=a.replace(/^\s+/,""),a.lastIndexOf(r,0)===0)return a.substring(r.length,a.length)}return null}static erase(t){e.set(t,"",-1)}};function Bg(e,t,r,o){document.cookie=`${e}=${t}`+(r?`;expires=${r.toUTCString()}`:"")+(o?`;domain=${o}`:"")+";path=/;SameSite=Lax"}function Dv(){return Jl()?localStorage:Zg()?new za:Tv()?sessionStorage:new Fn}var za=class e{getItem(t){return $a.get(`${e.prefix}${t}`)}removeItem(t){$a.erase(`${e.prefix}${t}`)}setItem(t,r,o){$a.set(`${e.prefix}${t}`,r,o)}};za.prefix="coveo_";var Xl=class{constructor(){this.cookieStorage=new za}getItem(t){return localStorage.getItem(t)||this.cookieStorage.getItem(t)}removeItem(t){this.cookieStorage.removeItem(t),localStorage.removeItem(t)}setItem(t,r){localStorage.setItem(t,r),this.cookieStorage.setItem(t,r,31556926e3)}},Fn=class{getItem(t){return null}removeItem(t){}setItem(t,r){}},ja="__coveo.analytics.history",ey=20,ty=1e3*60,ry=75,Pn=class{constructor(t){this.store=t||Dv()}addElement(t){t.internalTime=new Date().getTime(),t=this.cropQueryElement(this.stripEmptyQuery(t));let r=this.getHistoryWithInternalTime();r!=null?this.isValidEntry(t)&&this.setHistory([t].concat(r)):this.setHistory([t])}addElementAsync(t){return w(this,void 0,void 0,function*(){t.internalTime=new Date().getTime(),t=this.cropQueryElement(this.stripEmptyQuery(t));let r=yield this.getHistoryWithInternalTimeAsync();r!=null?this.isValidEntry(t)&&this.setHistory([t].concat(r)):this.setHistory([t])})}getHistory(){let t=this.getHistoryWithInternalTime();return this.stripEmptyQueries(this.stripInternalTime(t))}getHistoryAsync(){return w(this,void 0,void 0,function*(){let t=yield this.getHistoryWithInternalTimeAsync();return this.stripEmptyQueries(this.stripInternalTime(t))})}getHistoryWithInternalTime(){try{let t=this.store.getItem(ja);return t&&typeof t=="string"?JSON.parse(t):[]}catch{return[]}}getHistoryWithInternalTimeAsync(){return w(this,void 0,void 0,function*(){try{let t=yield this.store.getItem(ja);return t?JSON.parse(t):[]}catch{return[]}})}setHistory(t){try{this.store.setItem(ja,JSON.stringify(t.slice(0,ey)))}catch{}}clear(){try{this.store.removeItem(ja)}catch{}}getMostRecentElement(){let t=this.getHistoryWithInternalTime();return Array.isArray(t)?t.sort((o,n)=>(n.internalTime||0)-(o.internalTime||0))[0]:null}cropQueryElement(t){return t.name&&t.value&&t.name.toLowerCase()==="query"&&(t.value=t.value.slice(0,ry)),t}isValidEntry(t){let r=this.getMostRecentElement();return r&&r.value==t.value?(t.internalTime||0)-(r.internalTime||0)>ty:!0}stripInternalTime(t){return Array.isArray(t)?t.map(r=>{let{name:o,time:n,value:a}=r;return{name:o,time:n,value:a}}):[]}stripEmptyQuery(t){let{name:r,time:o,value:n}=t;return r&&typeof n=="string"&&r.toLowerCase()==="query"&&n.trim()===""?{name:r,time:o}:t}stripEmptyQueries(t){return t.map(r=>this.stripEmptyQuery(r))}},oy=Object.freeze({__proto__:null,HistoryStore:Pn,MAX_NUMBER_OF_HISTORY_ELEMENTS:ey,MAX_VALUE_SIZE:ry,MIN_THRESHOLD_FOR_DUPLICATE_VALUE:ty,STORE_KEY:ja,default:Pn}),kv=(e,t)=>w(void 0,void 0,void 0,function*(){return e===ee.view?(yield Vv(t.contentIdValue),Object.assign({location:window.location.toString(),referrer:document.referrer,title:document.title},t)):t}),Vv=e=>w(void 0,void 0,void 0,function*(){let t=new Pn,r={name:"PageView",value:e,time:new Date().toISOString()};yield t.addElementAsync(r)}),bs,Nv=new Uint8Array(16);function Mv(){if(!bs&&(bs=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!bs))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return bs(Nv)}var Qv=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;function Es(e){return typeof e=="string"&&Qv.test(e)}var Ee=[];for(let e=0;e<256;++e)Ee.push((e+256).toString(16).slice(1));function ny(e,t=0){return(Ee[e[t+0]]+Ee[e[t+1]]+Ee[e[t+2]]+Ee[e[t+3]]+"-"+Ee[e[t+4]]+Ee[e[t+5]]+"-"+Ee[e[t+6]]+Ee[e[t+7]]+"-"+Ee[e[t+8]]+Ee[e[t+9]]+"-"+Ee[e[t+10]]+Ee[e[t+11]]+Ee[e[t+12]]+Ee[e[t+13]]+Ee[e[t+14]]+Ee[e[t+15]]).toLowerCase()}function Lv(e){if(!Es(e))throw TypeError("Invalid UUID");let t,r=new Uint8Array(16);return r[0]=(t=parseInt(e.slice(0,8),16))>>>24,r[1]=t>>>16&255,r[2]=t>>>8&255,r[3]=t&255,r[4]=(t=parseInt(e.slice(9,13),16))>>>8,r[5]=t&255,r[6]=(t=parseInt(e.slice(14,18),16))>>>8,r[7]=t&255,r[8]=(t=parseInt(e.slice(19,23),16))>>>8,r[9]=t&255,r[10]=(t=parseInt(e.slice(24,36),16))/1099511627776&255,r[11]=t/4294967296&255,r[12]=t>>>24&255,r[13]=t>>>16&255,r[14]=t>>>8&255,r[15]=t&255,r}function Bv(e){e=unescape(encodeURIComponent(e));let t=[];for(let r=0;r<e.length;++r)t.push(e.charCodeAt(r));return t}var Uv="6ba7b810-9dad-11d1-80b4-00c04fd430c8",jv="6ba7b811-9dad-11d1-80b4-00c04fd430c8";function _v(e,t,r){function o(n,a,i,s){var u;if(typeof n=="string"&&(n=Bv(n)),typeof a=="string"&&(a=Lv(a)),((u=a)===null||u===void 0?void 0:u.length)!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let c=new Uint8Array(16+n.length);if(c.set(a),c.set(n,a.length),c=r(c),c[6]=c[6]&15|t,c[8]=c[8]&63|128,i){s=s||0;for(let l=0;l<16;++l)i[s+l]=c[l];return i}return ny(c)}try{o.name=e}catch{}return o.DNS=Uv,o.URL=jv,o}var $v=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),Ug={randomUUID:$v};function bo(e,t,r){if(Ug.randomUUID&&!t&&!e)return Ug.randomUUID();e=e||{};let o=e.random||(e.rng||Mv)();if(o[6]=o[6]&15|64,o[8]=o[8]&63|128,t){r=r||0;for(let n=0;n<16;++n)t[r+n]=o[n];return t}return ny(o)}function zv(e,t,r,o){switch(e){case 0:return t&r^~t&o;case 1:return t^r^o;case 2:return t&r^t&o^r&o;case 3:return t^r^o}}function Gl(e,t){return e<<t|e>>>32-t}function Wv(e){let t=[1518500249,1859775393,2400959708,3395469782],r=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof e=="string"){let i=unescape(encodeURIComponent(e));e=[];for(let s=0;s<i.length;++s)e.push(i.charCodeAt(s))}else Array.isArray(e)||(e=Array.prototype.slice.call(e));e.push(128);let o=e.length/4+2,n=Math.ceil(o/16),a=new Array(n);for(let i=0;i<n;++i){let s=new Uint32Array(16);for(let u=0;u<16;++u)s[u]=e[i*64+u*4]<<24|e[i*64+u*4+1]<<16|e[i*64+u*4+2]<<8|e[i*64+u*4+3];a[i]=s}a[n-1][14]=(e.length-1)*8/Math.pow(2,32),a[n-1][14]=Math.floor(a[n-1][14]),a[n-1][15]=(e.length-1)*8&4294967295;for(let i=0;i<n;++i){let s=new Uint32Array(80);for(let m=0;m<16;++m)s[m]=a[i][m];for(let m=16;m<80;++m)s[m]=Gl(s[m-3]^s[m-8]^s[m-14]^s[m-16],1);let u=r[0],c=r[1],l=r[2],d=r[3],p=r[4];for(let m=0;m<80;++m){let f=Math.floor(m/20),h=Gl(u,5)+zv(f,c,l,d)+p+t[f]+s[m]>>>0;p=d,d=l,l=Gl(c,30)>>>0,c=u,u=h}r[0]=r[0]+u>>>0,r[1]=r[1]+c>>>0,r[2]=r[2]+l>>>0,r[3]=r[3]+d>>>0,r[4]=r[4]+p>>>0}return[r[0]>>24&255,r[0]>>16&255,r[0]>>8&255,r[0]&255,r[1]>>24&255,r[1]>>16&255,r[1]>>8&255,r[1]&255,r[2]>>24&255,r[2]>>16&255,r[2]>>8&255,r[2]&255,r[3]>>24&255,r[3]>>16&255,r[3]>>8&255,r[3]&255,r[4]>>24&255,r[4]>>16&255,r[4]>>8&255,r[4]&255]}var Kv=_v("v5",80,Wv),jg=Kv,ay="2.30.45",_g=e=>`${e.protocol}//${e.hostname}${e.pathname.indexOf("/")===0?e.pathname:`/${e.pathname}`}${e.search}`,_a={pageview:"pageview",event:"event"},Is=class{constructor({client:t,uuidGenerator:r=bo}){this.client=t,this.uuidGenerator=r}},Zl=class extends Is{constructor({client:t,uuidGenerator:r=bo}){super({client:t,uuidGenerator:r}),this.actionData={},this.pageViewId=r(),this.nextPageViewId=this.pageViewId,this.currentLocation=_g(window.location),this.lastReferrer=xn()?document.referrer:"",this.addHooks()}getApi(t){switch(t){case"setAction":return this.setAction;default:return null}}setAction(t,r){this.action=t,this.actionData=r}clearData(){this.clearPluginData(),this.action=void 0,this.actionData={}}getLocationInformation(t,r){return Object.assign({hitType:t},this.getNextValues(t,r))}updateLocationInformation(t,r){this.updateLocationForNextPageView(t,r)}getDefaultContextInformation(t){let r={title:xn()?document.title:"",encoding:xn()?document.characterSet:"UTF-8"},o={screenResolution:`${screen.width}x${screen.height}`,screenColor:`${screen.colorDepth}-bit`},n={language:navigator.language,userAgent:navigator.userAgent},a={time:Date.now(),eventId:this.uuidGenerator()};return Object.assign(Object.assign(Object.assign(Object.assign({},a),o),n),r)}updateLocationForNextPageView(t,r){let{pageViewId:o,referrer:n,location:a}=this.getNextValues(t,r);this.lastReferrer=n,this.pageViewId=o,this.currentLocation=a,t===_a.pageview&&(this.nextPageViewId=this.uuidGenerator(),this.hasSentFirstPageView=!0)}getNextValues(t,r){return{pageViewId:t===_a.pageview?this.nextPageViewId:this.pageViewId,referrer:t===_a.pageview&&this.hasSentFirstPageView?this.currentLocation:this.lastReferrer,location:t===_a.pageview?this.getCurrentLocationFromPayload(r):this.currentLocation}}getCurrentLocationFromPayload(t){if(t.page){let r=n=>n.replace(/^\/?(.*)$/,"/$1");return`${(n=>n.split("/").slice(0,3).join("/"))(this.currentLocation)}${r(t.page)}`}else return _g(window.location)}},kr=class e{constructor(t,r){if(!Es(t))throw Error("Not a valid uuid");this.clientId=t,this.creationDate=Math.floor(r/1e3)}toString(){return this.clientId.replace(/-/g,"")+"."+this.creationDate.toString()}get expired(){let t=Math.floor(Date.now()/1e3)-this.creationDate;return t<0||t>e.expirationTime}validate(t,r){return!this.expired&&this.matchReferrer(t,r)}matchReferrer(t,r){try{let o=new URL(t);return r.some(n=>new RegExp(n.replace(/\\/g,"\\\\").replace(/\./g,"\\.").replace(/\*/g,".*")+"$").test(o.host))}catch{return!1}}static fromString(t){let r=t.split(".");if(r.length!==2)return null;let[o,n]=r;if(o.length!==32||isNaN(parseInt(n)))return null;let a=o.substring(0,8)+"-"+o.substring(8,12)+"-"+o.substring(12,16)+"-"+o.substring(16,20)+"-"+o.substring(20,32);return Es(a)?new e(a,Number.parseInt(n)*1e3):null}};kr.cvo_cid="cvo_cid";kr.expirationTime=120;var ed=class extends Is{constructor({client:t,uuidGenerator:r=bo}){super({client:t,uuidGenerator:r})}getApi(t){switch(t){case"decorate":return this.decorate;case"acceptFrom":return this.acceptFrom;default:return null}}decorate(t){return w(this,void 0,void 0,function*(){if(!this.client.getCurrentVisitorId)throw new Error("Could not retrieve current clientId");try{let r=new URL(t),o=yield this.client.getCurrentVisitorId();return r.searchParams.set(kr.cvo_cid,new kr(o,Date.now()).toString()),r.toString()}catch{throw new Error("Invalid URL provided")}})}acceptFrom(t){this.client.setAcceptedLinkReferrers(t)}};ed.Id="link";var dt=Object.keys;function ws(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}var Hl=128,iy=192,$g=224,zg=240;function Gv(e){return(e&248)===zg?4:(e&zg)===$g?3:(e&$g)===iy?2:1}function Hv(e,t){if(t<0||e.length<=t)return e;let r=e.indexOf("%",t-2);for(r<0||r>t?r=t:t=r;r>2&&e.charAt(r-3)=="%";){let o=Number.parseInt(e.substring(r-2,r),16);if((o&Hl)!=Hl)break;if(r-=3,(o&iy)!=Hl){t-r>=Gv(o)*3&&(r=t);break}}return e.substring(0,r)}var td={id:"svc_ticket_id",subject:"svc_ticket_subject",description:"svc_ticket_description",category:"svc_ticket_category",productId:"svc_ticket_product_id",custom:"svc_ticket_custom"},Yv=dt(td).map(e=>td[e]),Jv=[...Yv].join("|"),Xv=new RegExp(`^(${Jv}$)`),Zv={svcAction:"svc_action",svcActionData:"svc_action_data"},eb=e=>dt(e).filter(t=>e[t]!==void 0).reduce((t,r)=>{let o=td[r]||r;return Object.assign(Object.assign({},t),{[o]:e[r]})},{}),tb=e=>Xv.test(e),rb=[tb],Wg={id:"id",name:"nm",brand:"br",category:"ca",variant:"va",price:"pr",quantity:"qt",coupon:"cc",position:"ps",group:"group"},Kg={id:"id",name:"nm",brand:"br",category:"ca",variant:"va",position:"ps",price:"pr",group:"group"},ke={action:"pa",list:"pal",listSource:"pls"},Ts={id:"ti",revenue:"tr",tax:"tt",shipping:"ts",coupon:"tcc",affiliation:"ta",step:"cos",option:"col"},ob=["loyaltyCardId","loyaltyTier","thirdPartyPersona","companyName","favoriteStore","storeName","userIndustry","userRole","userDepartment","businessUnit"],rd={id:"quoteId",affiliation:"quoteAffiliation"},od={id:"reviewId",rating:"reviewRating",comment:"reviewComment"},nb={add:ke,bookmark_add:ke,bookmark_remove:ke,click:ke,checkout:ke,checkout_option:ke,detail:ke,impression:ke,remove:ke,refund:Object.assign(Object.assign({},ke),Ts),purchase:Object.assign(Object.assign({},ke),Ts),quickview:ke,quote:Object.assign(Object.assign({},ke),rd),review:Object.assign(Object.assign({},ke),od)},ab=dt(Wg).map(e=>Wg[e]),ib=dt(Kg).map(e=>Kg[e]),sb=dt(ke).map(e=>ke[e]),cb=dt(Ts).map(e=>Ts[e]),ub=dt(od).map(e=>od[e]),lb=dt(rd).map(e=>rd[e]),db=[...ab,"custom"].join("|"),mb=[...ib,"custom"].join("|"),sy="(pr[0-9]+)",cy="(il[0-9]+pi[0-9]+)",pb=new RegExp(`^${sy}(${db})$`),fb=new RegExp(`^(${cy}(${mb}))|(il[0-9]+nm)$`),gb=new RegExp(`^(${sb.join("|")})$`),yb=new RegExp(`^(${cb.join("|")})$`),Sb=new RegExp(`^${sy}custom$`),hb=new RegExp(`^${cy}custom$`),Cb=new RegExp(`^(${[...ob,...ub,...lb].join("|")})$`),xb=e=>pb.test(e),Rb=e=>fb.test(e),Fb=e=>gb.test(e),Pb=e=>yb.test(e),Ab=e=>Cb.test(e),vb=[Rb,xb,Fb,Pb,Ab],bb=[Sb,hb],wb={anonymizeIp:"aip"},Eb={eventCategory:"ec",eventAction:"ea",eventLabel:"el",eventValue:"ev",page:"dp",visitorId:"cid",clientId:"cid",userId:"uid",currencyCode:"cu"},Ib={hitType:"t",pageViewId:"pid",encoding:"de",location:"dl",referrer:"dr",screenColor:"sd",screenResolution:"sr",title:"dt",userAgent:"ua",language:"ul",eventId:"z",time:"tm"},Tb=["contentId","contentIdKey","contentType","searchHub","tab","searchUid","permanentId","contentLocale","trackingId"],Ob=Object.assign(Object.assign(Object.assign(Object.assign({},wb),Eb),Ib),Tb.reduce((e,t)=>Object.assign(Object.assign({},e),{[t]:t}),{})),nd=Object.assign(Object.assign({},Ob),Zv),qb=e=>{let t=!!e.action&&nb[e.action]||{};return dt(e).reduce((r,o)=>{let n=t[o]||nd[o]||o;return Object.assign(Object.assign({},r),{[n]:e[o]})},{})},Db=dt(nd).map(e=>nd[e]),kb=e=>Db.indexOf(e)!==-1,Vb=e=>e==="custom",Nb=e=>[...vb,...rb,kb,Vb].some(t=>t(e)),Mb=e=>dt(e).reduce((t,r)=>{let o=Qb(r);return o?Object.assign(Object.assign({},t),Lb(o,e[r])):Object.assign(Object.assign({},t),{[r]:e[r]})},{}),Qb=e=>{let t;return[...bb].every(r=>{var o;return t=(o=r.exec(e))===null||o===void 0?void 0:o[1],!t}),t},Lb=(e,t)=>dt(t).reduce((r,o)=>Object.assign(Object.assign({},r),{[`${e}${o}`]:t[o]}),{}),ad=class{constructor(t){this.opts=t}sendEvent(t,r){return w(this,void 0,void 0,function*(){if(!this.isAvailable())throw new Error('navigator.sendBeacon is not supported in this browser. Consider adding a polyfill like "sendbeacon-polyfill".');let{baseUrl:o,preprocessRequest:n}=this.opts,a=yield this.getQueryParamsForEventType(t),{url:i,payload:s}=yield this.preProcessRequestAsPotentialJSONString(`${o}/analytics/${t}?${a}`,r,n),u=this.encodeForEventType(t,s),c=new Blob([u],{type:"application/x-www-form-urlencoded"});navigator.sendBeacon(i,c)})}isAvailable(){return"sendBeacon"in navigator}deleteHttpCookieVisitorId(){return Promise.resolve()}preProcessRequestAsPotentialJSONString(t,r,o){return w(this,void 0,void 0,function*(){let n=t,a=r;if(o){let i=yield o({url:t,body:JSON.stringify(r)},"analyticsBeacon"),{url:s,body:u}=i;n=s||t;try{a=JSON.parse(u)}catch(c){console.error("Unable to process the request body as a JSON string",c)}}return{payload:a,url:n}})}encodeForEventType(t,r){return this.isEventTypeLegacy(t)?this.encodeEventToJson(t,r):this.encodeEventToJson(t,r,this.opts.token)}getQueryParamsForEventType(t){return w(this,void 0,void 0,function*(){let{token:r,visitorIdProvider:o}=this.opts,n=yield o.getCurrentVisitorId();return[r&&this.isEventTypeLegacy(t)?`access_token=${r}`:"",n?`visitorId=${n}`:"","discardVisitInfo=true"].filter(a=>!!a).join("&")})}isEventTypeLegacy(t){return[ee.click,ee.custom,ee.search,ee.view].indexOf(t)!==-1}encodeEventToJson(t,r,o){let n=`${t}Event=${encodeURIComponent(JSON.stringify(r))}`;return o&&(n=`access_token=${encodeURIComponent(o)}&${n}`),n}},id=class{sendEvent(t,r){return w(this,void 0,void 0,function*(){return Promise.resolve()})}deleteHttpCookieVisitorId(){return w(this,void 0,void 0,function*(){return Promise.resolve()})}},Gg=globalThis.fetch,Os=class{constructor(t){this.opts=t}sendEvent(t,r){return w(this,void 0,void 0,function*(){let{baseUrl:o,visitorIdProvider:n,preprocessRequest:a}=this.opts,i=this.shouldAppendVisitorId(t)?yield this.getVisitorIdParam():"",s={url:`${o}/analytics/${t}${i}`,credentials:"include",mode:"cors",headers:this.getHeaders(),method:"POST",body:JSON.stringify(r)},u=Object.assign(Object.assign({},s),a?yield a(s,"analyticsFetch"):{}),{url:c}=u,l=cr(u,["url"]),d;try{d=yield Gg(c,l)}catch(p){console.error("An error has occured when sending the event.",p);return}if(d.ok){let p=yield d.json();return p.visitorId&&n.setCurrentVisitorId(p.visitorId),p}else{try{d.json()}catch{}throw console.error(`An error has occured when sending the "${t}" event.`,d,r),new Error(`An error has occurred when sending the "${t}" event. Check the console logs for more details.`)}})}deleteHttpCookieVisitorId(){return w(this,void 0,void 0,function*(){let{baseUrl:t}=this.opts,r=`${t}/analytics/visit`;yield Gg(r,{headers:this.getHeaders(),method:"DELETE"})})}shouldAppendVisitorId(t){return[ee.click,ee.custom,ee.search,ee.view].indexOf(t)!==-1}getVisitorIdParam(){return w(this,void 0,void 0,function*(){let{visitorIdProvider:t}=this.opts,r=yield t.getCurrentVisitorId();return r?`?visitor=${r}`:""})}getHeaders(){let{token:t}=this.opts;return Object.assign(Object.assign({},t?{Authorization:`Bearer ${t}`}:{}),{"Content-Type":"application/json"})}},sd=class{constructor(t,r){Jl()&&Zg()?this.storage=new Xl:Jl()?this.storage=localStorage:(console.warn("BrowserRuntime detected no valid storage available.",this),this.storage=new Fn),this.client=new Os(t),this.beaconClient=new ad(t),window.addEventListener("beforeunload",()=>{let o=r();for(let{eventType:n,payload:a}of o)this.beaconClient.sendEvent(n,a)})}getClientDependingOnEventType(t){return t==="click"&&this.beaconClient.isAvailable()?this.beaconClient:this.client}},cd=class{constructor(t,r){this.storage=r||new Fn,this.client=new Os(t)}getClientDependingOnEventType(t){return this.client}},qs=class{constructor(){this.storage=new Fn,this.client=new id}getClientDependingOnEventType(t){return this.client}},Bb="xx",Ub=e=>e?.startsWith(Bb)||!1,jb=`
|
|
20
20
|
We've detected you're using React Native but have not provided the corresponding runtime,
|
|
21
21
|
for an optimal experience please use the "coveo.analytics/react-native" subpackage.
|
|
22
22
|
Follow the Readme on how to set it up: https://github.com/coveo/coveo.analytics.js#using-react-native
|