@coveo/headless 3.13.0-pre.ca85011e15 → 3.13.0-pre.dac09533fb

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.
Files changed (42) hide show
  1. package/dist/browser/case-assist/headless.esm.js +1 -1
  2. package/dist/browser/case-assist/headless.js +1 -1
  3. package/dist/browser/commerce/headless.esm.js +1 -1
  4. package/dist/browser/commerce/headless.js +1 -1
  5. package/dist/browser/headless.esm.js +1 -1
  6. package/dist/browser/headless.js +1 -1
  7. package/dist/browser/insight/headless.esm.js +1 -1
  8. package/dist/browser/insight/headless.js +1 -1
  9. package/dist/browser/recommendation/headless.esm.js +1 -1
  10. package/dist/browser/recommendation/headless.js +1 -1
  11. package/dist/browser/ssr/headless.esm.js +1 -1
  12. package/dist/browser/ssr/headless.js +1 -1
  13. package/dist/browser/ssr-commerce/headless.esm.js +1 -1
  14. package/dist/browser/ssr-commerce/headless.js +1 -1
  15. package/dist/case-assist/headless.cjs +8 -5
  16. package/dist/case-assist/headless.esm.js +1 -1
  17. package/dist/case-assist/node.cjs.stats.json +1 -1
  18. package/dist/commerce/headless.cjs +8 -5
  19. package/dist/commerce/headless.esm.js +1 -1
  20. package/dist/commerce/node.cjs.stats.json +1 -1
  21. package/dist/headless.cjs +8 -5
  22. package/dist/headless.esm.js +1 -1
  23. package/dist/insight/headless.cjs +8 -5
  24. package/dist/insight/headless.esm.js +1 -1
  25. package/dist/insight/node.cjs.stats.json +1 -1
  26. package/dist/node.cjs.stats.json +1 -1
  27. package/dist/parsed_doc.json +136 -136
  28. package/dist/quantic/case-assist/headless.js +1 -1
  29. package/dist/quantic/commerce/headless.js +1 -1
  30. package/dist/quantic/headless.js +1 -1
  31. package/dist/quantic/insight/headless.js +1 -1
  32. package/dist/quantic/recommendation/headless.js +1 -1
  33. package/dist/recommendation/headless.cjs +8 -5
  34. package/dist/recommendation/headless.esm.js +1 -1
  35. package/dist/recommendation/node.cjs.stats.json +1 -1
  36. package/dist/ssr/headless.cjs +8 -5
  37. package/dist/ssr/headless.esm.js +1 -1
  38. package/dist/ssr/node.cjs.stats.json +1 -1
  39. package/dist/ssr-commerce/headless.cjs +8 -5
  40. package/dist/ssr-commerce/headless.esm.js +1 -1
  41. package/dist/ssr-commerce/node.cjs.stats.json +1 -1
  42. package/package.json +3 -3
@@ -15,7 +15,7 @@
15
15
  * See the License for the specific language governing permissions and
16
16
  * limitations under the License.
17
17
  */
18
- var Hl=Object.create;var fo=Object.defineProperty;var zl=Object.getOwnPropertyDescriptor;var Gl=Object.getOwnPropertyNames;var Wl=Object.getPrototypeOf,Kl=Object.prototype.hasOwnProperty;var Yl=(e,t,r)=>t in e?fo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var re=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var Jl=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of Gl(t))!Kl.call(e,o)&&o!==r&&fo(e,o,{get:()=>t[o],enumerable:!(n=zl(t,o))||n.enumerable});return e};var Re=(e,t,r)=>(r=e!=null?Hl(Wl(e)):{},Jl(t||!e||!e.__esModule?fo(r,"default",{value:e,enumerable:!0}):r,e));var ee=(e,t,r)=>Yl(e,typeof t!="symbol"?t+"":t,r);var ps=re(Jt=>{"use strict";var Or=Jt&&Jt.__assign||function(){return Or=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},Or.apply(this,arguments)};Object.defineProperty(Jt,"__esModule",{value:!0});var Xl={delayFirstAttempt:!1,jitter:"none",maxDelay:1/0,numOfAttempts:10,retry:function(){return!0},startingDelay:100,timeMultiple:2};function Zl(e){var t=Or(Or({},Xl),e);return t.numOfAttempts<1&&(t.numOfAttempts=1),t}Jt.getSanitizedOptions=Zl});var fs=re(mo=>{"use strict";Object.defineProperty(mo,"__esModule",{value:!0});function ed(e){var t=Math.random()*e;return Math.round(t)}mo.fullJitter=ed});var ms=re(go=>{"use strict";Object.defineProperty(go,"__esModule",{value:!0});function td(e){return e}go.noJitter=td});var gs=re(ho=>{"use strict";Object.defineProperty(ho,"__esModule",{value:!0});var rd=fs(),nd=ms();function od(e){switch(e.jitter){case"full":return rd.fullJitter;case"none":default:return nd.noJitter}}ho.JitterFactory=od});var So=re(yo=>{"use strict";Object.defineProperty(yo,"__esModule",{value:!0});var id=gs(),sd=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=id.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,n=this.numOfDelayedAttempts,o=t*Math.pow(r,n);return Math.min(o,this.options.maxDelay)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"numOfDelayedAttempts",{get:function(){return this.attempt},enumerable:!0,configurable:!0}),e}();yo.Delay=sd});var hs=re(qe=>{"use strict";var ad=qe&&qe.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,o){n.__proto__=o}||function(n,o){for(var i in o)o.hasOwnProperty(i)&&(n[i]=o[i])},e(t,r)};return function(t,r){e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}(),cd=qe&&qe.__awaiter||function(e,t,r,n){function o(i){return i instanceof r?i:new r(function(s){s(i)})}return new(r||(r=Promise))(function(i,s){function c(d){try{a(n.next(d))}catch(f){s(f)}}function l(d){try{a(n.throw(d))}catch(f){s(f)}}function a(d){d.done?i(d.value):o(d.value).then(c,l)}a((n=n.apply(e,t||[])).next())})},ud=qe&&qe.__generator||function(e,t){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,o,i,s;return s={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function c(a){return function(d){return l([a,d])}}function l(a){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,o&&(i=a[0]&2?o.return:a[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,a[1])).done)return i;switch(o=0,i&&(a=[a[0]&2,i.value]),a[0]){case 0:case 1:i=a;break;case 4:return r.label++,{value:a[1],done:!1};case 5:r.label++,o=a[1],a=[0];continue;case 7:a=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(a[0]===6||a[0]===2)){r=0;continue}if(a[0]===3&&(!i||a[1]>i[0]&&a[1]<i[3])){r.label=a[1];break}if(a[0]===6&&r.label<i[1]){r.label=i[1],i=a;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(a);break}i[2]&&r.ops.pop(),r.trys.pop();continue}a=t.call(e,r)}catch(d){a=[6,d],o=0}finally{n=i=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}};Object.defineProperty(qe,"__esModule",{value:!0});var ld=So(),dd=function(e){ad(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.apply=function(){return cd(this,void 0,void 0,function(){return ud(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}(ld.Delay);qe.SkipFirstDelay=dd});var ys=re(Xt=>{"use strict";var pd=Xt&&Xt.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,o){n.__proto__=o}||function(n,o){for(var i in o)o.hasOwnProperty(i)&&(n[i]=o[i])},e(t,r)};return function(t,r){e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(Xt,"__esModule",{value:!0});var fd=So(),md=function(e){pd(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t}(fd.Delay);Xt.AlwaysDelay=md});var Ss=re(vo=>{"use strict";Object.defineProperty(vo,"__esModule",{value:!0});var gd=hs(),hd=ys();function yd(e,t){var r=Sd(e);return r.setAttemptNumber(t),r}vo.DelayFactory=yd;function Sd(e){return e.delayFirstAttempt?new hd.AlwaysDelay(e):new gd.SkipFirstDelay(e)}});var vs=re(pt=>{"use strict";var Co=pt&&pt.__awaiter||function(e,t,r,n){function o(i){return i instanceof r?i:new r(function(s){s(i)})}return new(r||(r=Promise))(function(i,s){function c(d){try{a(n.next(d))}catch(f){s(f)}}function l(d){try{a(n.throw(d))}catch(f){s(f)}}function a(d){d.done?i(d.value):o(d.value).then(c,l)}a((n=n.apply(e,t||[])).next())})},Ao=pt&&pt.__generator||function(e,t){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,o,i,s;return s={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function c(a){return function(d){return l([a,d])}}function l(a){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,o&&(i=a[0]&2?o.return:a[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,a[1])).done)return i;switch(o=0,i&&(a=[a[0]&2,i.value]),a[0]){case 0:case 1:i=a;break;case 4:return r.label++,{value:a[1],done:!1};case 5:r.label++,o=a[1],a=[0];continue;case 7:a=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(a[0]===6||a[0]===2)){r=0;continue}if(a[0]===3&&(!i||a[1]>i[0]&&a[1]<i[3])){r.label=a[1];break}if(a[0]===6&&r.label<i[1]){r.label=i[1],i=a;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(a);break}i[2]&&r.ops.pop(),r.trys.pop();continue}a=t.call(e,r)}catch(d){a=[6,d],o=0}finally{n=i=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}};Object.defineProperty(pt,"__esModule",{value:!0});var vd=ps(),Cd=Ss();function Ad(e,t){return t===void 0&&(t={}),Co(this,void 0,void 0,function(){var r,n;return Ao(this,function(o){switch(o.label){case 0:return r=vd.getSanitizedOptions(t),n=new bd(e,r),[4,n.execute()];case 1:return[2,o.sent()]}})})}pt.backOff=Ad;var bd=function(){function e(t,r){this.request=t,this.options=r,this.attemptNumber=0}return e.prototype.execute=function(){return Co(this,void 0,void 0,function(){var t,r;return Ao(this,function(n){switch(n.label){case 0:if(this.attemptLimitReached)return[3,7];n.label=1;case 1:return n.trys.push([1,4,,6]),[4,this.applyDelay()];case 2:return n.sent(),[4,this.request()];case 3:return[2,n.sent()];case 4:return t=n.sent(),this.attemptNumber++,[4,this.options.retry(t,this.attemptNumber)];case 5:if(r=n.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 Co(this,void 0,void 0,function(){var t;return Ao(this,function(r){switch(r.label){case 0:return t=Cd.DelayFactory(this.options,this.attemptNumber),[4,t.apply()];case 1:return r.sent(),[2]}})})},e}()});var Fn=re((wi,xi)=>{"use strict";(function(e,t){typeof wi=="object"&&typeof xi<"u"?xi.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs=t()})(wi,function(){"use strict";var e=1e3,t=6e4,r=36e5,n="millisecond",o="second",i="minute",s="hour",c="day",l="week",a="month",d="quarter",f="year",p="date",u="Invalid Date",g=/^(\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,S={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(T){var P=["th","st","nd","rd"],k=T%100;return"["+T+(P[(k-20)%10]||P[k]||P[0])+"]"}},C=function(T,P,k){var M=String(T);return!M||M.length>=P?T:""+Array(P+1-M.length).join(k)+T},m={s:C,z:function(T){var P=-T.utcOffset(),k=Math.abs(P),M=Math.floor(k/60),D=k%60;return(P<=0?"+":"-")+C(M,2,"0")+":"+C(D,2,"0")},m:function T(P,k){if(P.date()<k.date())return-T(k,P);var M=12*(k.year()-P.year())+(k.month()-P.month()),D=P.clone().add(M,a),_=k-D<0,N=P.clone().add(M+(_?-1:1),a);return+(-(M+(k-D)/(_?D-N:N-D))||0)},a:function(T){return T<0?Math.ceil(T)||0:Math.floor(T)},p:function(T){return{M:a,y:f,w:l,d:c,D:p,h:s,m:i,s:o,ms:n,Q:d}[T]||String(T||"").toLowerCase().replace(/s$/,"")},u:function(T){return T===void 0}},y="en",A={};A[y]=S;var E="$isDayjsObject",b=function(T){return T instanceof O||!(!T||!T[E])},v=function T(P,k,M){var D;if(!P)return y;if(typeof P=="string"){var _=P.toLowerCase();A[_]&&(D=_),k&&(A[_]=k,D=_);var N=P.split("-");if(!D&&N.length>1)return T(N[0])}else{var j=P.name;A[j]=P,D=j}return!M&&D&&(y=D),D||!M&&y},I=function(T,P){if(b(T))return T.clone();var k=typeof P=="object"?P:{};return k.date=T,k.args=arguments,new O(k)},x=m;x.l=v,x.i=b,x.w=function(T,P){return I(T,{locale:P.$L,utc:P.$u,x:P.$x,$offset:P.$offset})};var O=function(){function T(k){this.$L=v(k.locale,null,!0),this.parse(k),this.$x=this.$x||k.x||{},this[E]=!0}var P=T.prototype;return P.parse=function(k){this.$d=function(M){var D=M.date,_=M.utc;if(D===null)return new Date(NaN);if(x.u(D))return new Date;if(D instanceof Date)return new Date(D);if(typeof D=="string"&&!/Z$/i.test(D)){var N=D.match(g);if(N){var j=N[2]-1||0,B=(N[7]||"0").substring(0,3);return _?new Date(Date.UTC(N[1],j,N[3]||1,N[4]||0,N[5]||0,N[6]||0,B)):new Date(N[1],j,N[3]||1,N[4]||0,N[5]||0,N[6]||0,B)}}return new Date(D)}(k),this.init()},P.init=function(){var k=this.$d;this.$y=k.getFullYear(),this.$M=k.getMonth(),this.$D=k.getDate(),this.$W=k.getDay(),this.$H=k.getHours(),this.$m=k.getMinutes(),this.$s=k.getSeconds(),this.$ms=k.getMilliseconds()},P.$utils=function(){return x},P.isValid=function(){return this.$d.toString()!==u},P.isSame=function(k,M){var D=I(k);return this.startOf(M)<=D&&D<=this.endOf(M)},P.isAfter=function(k,M){return I(k)<this.startOf(M)},P.isBefore=function(k,M){return this.endOf(M)<I(k)},P.$g=function(k,M,D){return x.u(k)?this[M]:this.set(D,k)},P.unix=function(){return Math.floor(this.valueOf()/1e3)},P.valueOf=function(){return this.$d.getTime()},P.startOf=function(k,M){var D=this,_=!!x.u(M)||M,N=x.p(k),j=function(Ce,Z){var pe=x.w(D.$u?Date.UTC(D.$y,Z,Ce):new Date(D.$y,Z,Ce),D);return _?pe:pe.endOf(c)},B=function(Ce,Z){return x.w(D.toDate()[Ce].apply(D.toDate("s"),(_?[0,0,0,0]:[23,59,59,999]).slice(Z)),D)},$=this.$W,H=this.$M,z=this.$D,G="set"+(this.$u?"UTC":"");switch(N){case f:return _?j(1,0):j(31,11);case a:return _?j(1,H):j(0,H+1);case l:var X=this.$locale().weekStart||0,De=($<X?$+7:$)-X;return j(_?z-De:z+(6-De),H);case c:case p:return B(G+"Hours",0);case s:return B(G+"Minutes",1);case i:return B(G+"Seconds",2);case o:return B(G+"Milliseconds",3);default:return this.clone()}},P.endOf=function(k){return this.startOf(k,!1)},P.$set=function(k,M){var D,_=x.p(k),N="set"+(this.$u?"UTC":""),j=(D={},D[c]=N+"Date",D[p]=N+"Date",D[a]=N+"Month",D[f]=N+"FullYear",D[s]=N+"Hours",D[i]=N+"Minutes",D[o]=N+"Seconds",D[n]=N+"Milliseconds",D)[_],B=_===c?this.$D+(M-this.$W):M;if(_===a||_===f){var $=this.clone().set(p,1);$.$d[j](B),$.init(),this.$d=$.set(p,Math.min(this.$D,$.daysInMonth())).$d}else j&&this.$d[j](B);return this.init(),this},P.set=function(k,M){return this.clone().$set(k,M)},P.get=function(k){return this[x.p(k)]()},P.add=function(k,M){var D,_=this;k=Number(k);var N=x.p(M),j=function(H){var z=I(_);return x.w(z.date(z.date()+Math.round(H*k)),_)};if(N===a)return this.set(a,this.$M+k);if(N===f)return this.set(f,this.$y+k);if(N===c)return j(1);if(N===l)return j(7);var B=(D={},D[i]=t,D[s]=r,D[o]=e,D)[N]||1,$=this.$d.getTime()+k*B;return x.w($,this)},P.subtract=function(k,M){return this.add(-1*k,M)},P.format=function(k){var M=this,D=this.$locale();if(!this.isValid())return D.invalidDate||u;var _=k||"YYYY-MM-DDTHH:mm:ssZ",N=x.z(this),j=this.$H,B=this.$m,$=this.$M,H=D.weekdays,z=D.months,G=D.meridiem,X=function(Z,pe,Me,$e){return Z&&(Z[pe]||Z(M,_))||Me[pe].slice(0,$e)},De=function(Z){return x.s(j%12||12,Z,"0")},Ce=G||function(Z,pe,Me){var $e=Z<12?"AM":"PM";return Me?$e.toLowerCase():$e};return _.replace(h,function(Z,pe){return pe||function(Me){switch(Me){case"YY":return String(M.$y).slice(-2);case"YYYY":return x.s(M.$y,4,"0");case"M":return $+1;case"MM":return x.s($+1,2,"0");case"MMM":return X(D.monthsShort,$,z,3);case"MMMM":return X(z,$);case"D":return M.$D;case"DD":return x.s(M.$D,2,"0");case"d":return String(M.$W);case"dd":return X(D.weekdaysMin,M.$W,H,2);case"ddd":return X(D.weekdaysShort,M.$W,H,3);case"dddd":return H[M.$W];case"H":return String(j);case"HH":return x.s(j,2,"0");case"h":return De(1);case"hh":return De(2);case"a":return Ce(j,B,!0);case"A":return Ce(j,B,!1);case"m":return String(B);case"mm":return x.s(B,2,"0");case"s":return String(M.$s);case"ss":return x.s(M.$s,2,"0");case"SSS":return x.s(M.$ms,3,"0");case"Z":return N}return null}(Z)||N.replace(":","")})},P.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},P.diff=function(k,M,D){var _,N=this,j=x.p(M),B=I(k),$=(B.utcOffset()-this.utcOffset())*t,H=this-B,z=function(){return x.m(N,B)};switch(j){case f:_=z()/12;break;case a:_=z();break;case d:_=z()/3;break;case l:_=(H-$)/6048e5;break;case c:_=(H-$)/864e5;break;case s:_=H/r;break;case i:_=H/t;break;case o:_=H/e;break;default:_=H}return D?_:x.a(_)},P.daysInMonth=function(){return this.endOf(a).$D},P.$locale=function(){return A[this.$L]},P.locale=function(k,M){if(!k)return this.$L;var D=this.clone(),_=v(k,M,!0);return _&&(D.$L=_),D},P.clone=function(){return x.w(this.$d,this)},P.toDate=function(){return new Date(this.valueOf())},P.toJSON=function(){return this.isValid()?this.toISOString():null},P.toISOString=function(){return this.$d.toISOString()},P.toString=function(){return this.$d.toUTCString()},T}(),q=O.prototype;return I.prototype=q,[["$ms",n],["$s",o],["$m",i],["$H",s],["$W",c],["$M",a],["$y",f],["$D",p]].forEach(function(T){q[T[1]]=function(P){return this.$g(P,T[0],T[1])}}),I.extend=function(T,P){return T.$i||(T(P,O,I),T.$i=!0),I},I.locale=v,I.isDayjs=b,I.unix=function(T){return I(1e3*T)},I.en=A[y],I.Ls=A,I.p={},I})});var Nc=re((Ri,Ii)=>{"use strict";(function(e,t){typeof Ri=="object"&&typeof Ii<"u"?Ii.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_quarterOfYear=t()})(Ri,function(){"use strict";var e="month",t="quarter";return function(r,n){var o=n.prototype;o.quarter=function(c){return this.$utils().u(c)?Math.ceil((this.month()+1)/3):this.month(this.month()%3+3*(c-1))};var i=o.add;o.add=function(c,l){return c=Number(c),this.$utils().p(l)===t?this.add(3*c,e):i.bind(this)(c,l)};var s=o.startOf;o.startOf=function(c,l){var a=this.$utils(),d=!!a.u(l)||l;if(a.p(c)===t){var f=this.quarter()-1;return d?this.month(3*f).startOf(e).startOf("day"):this.month(3*f+2).endOf(e).endOf("day")}return s.bind(this)(c,l)}}})});var _c=re((Ei,ki)=>{"use strict";(function(e,t){typeof Ei=="object"&&typeof ki<"u"?ki.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_customParseFormat=t()})(Ei,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|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,r=/\d\d/,n=/\d\d?/,o=/\d*[^-_:/,()\s\d]+/,i={},s=function(u){return(u=+u)+(u>68?1900:2e3)},c=function(u){return function(g){this[u]=+g}},l=[/[+-]\d\d:?(\d\d)?|Z/,function(u){(this.zone||(this.zone={})).offset=function(g){if(!g||g==="Z")return 0;var h=g.match(/([+-]|\d\d)/g),S=60*h[1]+(+h[2]||0);return S===0?0:h[0]==="+"?-S:S}(u)}],a=function(u){var g=i[u];return g&&(g.indexOf?g:g.s.concat(g.f))},d=function(u,g){var h,S=i.meridiem;if(S){for(var C=1;C<=24;C+=1)if(u.indexOf(S(C,0,g))>-1){h=C>12;break}}else h=u===(g?"pm":"PM");return h},f={A:[o,function(u){this.afternoon=d(u,!1)}],a:[o,function(u){this.afternoon=d(u,!0)}],S:[/\d/,function(u){this.milliseconds=100*+u}],SS:[r,function(u){this.milliseconds=10*+u}],SSS:[/\d{3}/,function(u){this.milliseconds=+u}],s:[n,c("seconds")],ss:[n,c("seconds")],m:[n,c("minutes")],mm:[n,c("minutes")],H:[n,c("hours")],h:[n,c("hours")],HH:[n,c("hours")],hh:[n,c("hours")],D:[n,c("day")],DD:[r,c("day")],Do:[o,function(u){var g=i.ordinal,h=u.match(/\d+/);if(this.day=h[0],g)for(var S=1;S<=31;S+=1)g(S).replace(/\[|\]/g,"")===u&&(this.day=S)}],M:[n,c("month")],MM:[r,c("month")],MMM:[o,function(u){var g=a("months"),h=(a("monthsShort")||g.map(function(S){return S.slice(0,3)})).indexOf(u)+1;if(h<1)throw new Error;this.month=h%12||h}],MMMM:[o,function(u){var g=a("months").indexOf(u)+1;if(g<1)throw new Error;this.month=g%12||g}],Y:[/[+-]?\d+/,c("year")],YY:[r,function(u){this.year=s(u)}],YYYY:[/\d{4}/,c("year")],Z:l,ZZ:l};function p(u){var g,h;g=u,h=i&&i.formats;for(var S=(u=g.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(v,I,x){var O=x&&x.toUpperCase();return I||h[x]||e[x]||h[O].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(q,T,P){return T||P.slice(1)})})).match(t),C=S.length,m=0;m<C;m+=1){var y=S[m],A=f[y],E=A&&A[0],b=A&&A[1];S[m]=b?{regex:E,parser:b}:y.replace(/^\[|\]$/g,"")}return function(v){for(var I={},x=0,O=0;x<C;x+=1){var q=S[x];if(typeof q=="string")O+=q.length;else{var T=q.regex,P=q.parser,k=v.slice(O),M=T.exec(k)[0];P.call(I,M),v=v.replace(M,"")}}return function(D){var _=D.afternoon;if(_!==void 0){var N=D.hours;_?N<12&&(D.hours+=12):N===12&&(D.hours=0),delete D.afternoon}}(I),I}}return function(u,g,h){h.p.customParseFormat=!0,u&&u.parseTwoDigitYear&&(s=u.parseTwoDigitYear);var S=g.prototype,C=S.parse;S.parse=function(m){var y=m.date,A=m.utc,E=m.args;this.$u=A;var b=E[1];if(typeof b=="string"){var v=E[2]===!0,I=E[3]===!0,x=v||I,O=E[2];I&&(O=E[2]),i=this.$locale(),!v&&O&&(i=h.Ls[O]),this.$d=function(k,M,D){try{if(["x","X"].indexOf(M)>-1)return new Date((M==="X"?1e3:1)*k);var _=p(M)(k),N=_.year,j=_.month,B=_.day,$=_.hours,H=_.minutes,z=_.seconds,G=_.milliseconds,X=_.zone,De=new Date,Ce=B||(N||j?1:De.getDate()),Z=N||De.getFullYear(),pe=0;N&&!j||(pe=j>0?j-1:De.getMonth());var Me=$||0,$e=H||0,lo=z||0,po=G||0;return X?new Date(Date.UTC(Z,pe,Ce,Me,$e,lo,po+60*X.offset*1e3)):D?new Date(Date.UTC(Z,pe,Ce,Me,$e,lo,po)):new Date(Z,pe,Ce,Me,$e,lo,po)}catch{return new Date("")}}(y,b,A),this.init(),O&&O!==!0&&(this.$L=this.locale(O).$L),x&&y!=this.format(b)&&(this.$d=new Date("")),i={}}else if(b instanceof Array)for(var q=b.length,T=1;T<=q;T+=1){E[1]=b[T-1];var P=h.apply(this,E);if(P.isValid()){this.$d=P.$d,this.$L=P.$L,this.init();break}T===q&&(this.$d=new Date(""))}else C.call(this,m)}}})});var Cu=re((Wx,vu)=>{"use strict";var Th=/(^|; )Coveo-Pendragon=([^;]*)/;vu.exports=()=>Th.exec(document.cookie)?.pop()||null});var bu=re((Qi,$i)=>{"use strict";(function(e,t){typeof Qi=="object"&&typeof $i<"u"?$i.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_timezone=t()})(Qi,function(){"use strict";var e={year:0,month:1,day:2,hour:3,minute:4,second:5},t={};return function(r,n,o){var i,s=function(d,f,p){p===void 0&&(p={});var u=new Date(d),g=function(h,S){S===void 0&&(S={});var C=S.timeZoneName||"short",m=h+"|"+C,y=t[m];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:C}),t[m]=y),y}(f,p);return g.formatToParts(u)},c=function(d,f){for(var p=s(d,f),u=[],g=0;g<p.length;g+=1){var h=p[g],S=h.type,C=h.value,m=e[S];m>=0&&(u[m]=parseInt(C,10))}var y=u[3],A=y===24?0:y,E=u[0]+"-"+u[1]+"-"+u[2]+" "+A+":"+u[4]+":"+u[5]+":000",b=+d;return(o.utc(E).valueOf()-(b-=b%1e3))/6e4},l=n.prototype;l.tz=function(d,f){d===void 0&&(d=i);var p,u=this.utcOffset(),g=this.toDate(),h=g.toLocaleString("en-US",{timeZone:d}),S=Math.round((g-new Date(h))/1e3/60),C=15*-Math.round(g.getTimezoneOffset()/15)-S;if(!Number(C))p=this.utcOffset(0,f);else if(p=o(h,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(C,!0),f){var m=p.utcOffset();p=p.add(u-m,"minute")}return p.$x.$timezone=d,p},l.offsetName=function(d){var f=this.$x.$timezone||o.tz.guess(),p=s(this.valueOf(),f,{timeZoneName:d}).find(function(u){return u.type.toLowerCase()==="timezonename"});return p&&p.value};var a=l.startOf;l.startOf=function(d,f){if(!this.$x||!this.$x.$timezone)return a.call(this,d,f);var p=o(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return a.call(p,d,f).tz(this.$x.$timezone,!0)},o.tz=function(d,f,p){var u=p&&f,g=p||f||i,h=c(+o(),g);if(typeof d!="string")return o(d).tz(g);var S=function(A,E,b){var v=A-60*E*1e3,I=c(v,b);if(E===I)return[v,E];var x=c(v-=60*(I-E)*1e3,b);return I===x?[v,I]:[A-60*Math.min(I,x)*1e3,Math.max(I,x)]}(o.utc(d,u).valueOf(),h,g),C=S[0],m=S[1],y=o(C).utcOffset(m);return y.$x.$timezone=g,y},o.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},o.tz.setDefault=function(d){i=d}}})});var wu=re((Hi,zi)=>{"use strict";(function(e,t){typeof Hi=="object"&&typeof zi<"u"?zi.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_utc=t()})(Hi,function(){"use strict";var e="minute",t=/[+-]\d\d(?::?\d\d)?/g,r=/([+-]|\d\d)/g;return function(n,o,i){var s=o.prototype;i.utc=function(u){var g={date:u,utc:!0,args:arguments};return new o(g)},s.utc=function(u){var g=i(this.toDate(),{locale:this.$L,utc:!0});return u?g.add(this.utcOffset(),e):g},s.local=function(){return i(this.toDate(),{locale:this.$L,utc:!1})};var c=s.parse;s.parse=function(u){u.utc&&(this.$u=!0),this.$utils().u(u.$offset)||(this.$offset=u.$offset),c.call(this,u)};var l=s.init;s.init=function(){if(this.$u){var u=this.$d;this.$y=u.getUTCFullYear(),this.$M=u.getUTCMonth(),this.$D=u.getUTCDate(),this.$W=u.getUTCDay(),this.$H=u.getUTCHours(),this.$m=u.getUTCMinutes(),this.$s=u.getUTCSeconds(),this.$ms=u.getUTCMilliseconds()}else l.call(this)};var a=s.utcOffset;s.utcOffset=function(u,g){var h=this.$utils().u;if(h(u))return this.$u?0:h(this.$offset)?a.call(this):this.$offset;if(typeof u=="string"&&(u=function(y){y===void 0&&(y="");var A=y.match(t);if(!A)return null;var E=(""+A[0]).match(r)||["-",0,0],b=E[0],v=60*+E[1]+ +E[2];return v===0?0:b==="+"?v:-v}(u),u===null))return this;var S=Math.abs(u)<=16?60*u:u,C=this;if(g)return C.$offset=S,C.$u=u===0,C;if(u!==0){var m=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(C=this.local().add(S+m,e)).$offset=S,C.$x.$localOffset=m}else C=this.utc();return C};var d=s.format;s.format=function(u){var g=u||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return d.call(this,g)},s.valueOf=function(){var u=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*u},s.isUTC=function(){return!!this.$u},s.toISOString=function(){return this.toDate().toISOString()},s.toString=function(){return this.toDate().toUTCString()};var f=s.toDate;s.toDate=function(u){return u==="s"&&this.$offset?i(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():f.call(this)};var p=s.diff;s.diff=function(u,g,h){if(u&&this.$u===u.$u)return p.call(this,u,g,h);var S=this.local(),C=i(u).local();return p.call(S,C,g,h)}}})});var _u=re((nI,Nu)=>{"use strict";function Bh(e){try{return JSON.stringify(e)}catch{return'"[Circular]"'}}Nu.exports=Qh;function Qh(e,t,r){var n=r&&r.stringify||Bh,o=1;if(typeof e=="object"&&e!==null){var i=t.length+o;if(i===1)return e;var s=new Array(i);s[0]=n(e);for(var c=1;c<i;c++)s[c]=n(t[c]);return s.join(" ")}if(typeof e!="string")return e;var l=t.length;if(l===0)return e;for(var a="",d=1-o,f=-1,p=e&&e.length||0,u=0;u<p;){if(e.charCodeAt(u)===37&&u+1<p){switch(f=f>-1?f:0,e.charCodeAt(u+1)){case 100:case 102:if(d>=l||t[d]==null)break;f<u&&(a+=e.slice(f,u)),a+=Number(t[d]),f=u+2,u++;break;case 105:if(d>=l||t[d]==null)break;f<u&&(a+=e.slice(f,u)),a+=Math.floor(Number(t[d])),f=u+2,u++;break;case 79:case 111:case 106:if(d>=l||t[d]===void 0)break;f<u&&(a+=e.slice(f,u));var g=typeof t[d];if(g==="string"){a+="'"+t[d]+"'",f=u+2,u++;break}if(g==="function"){a+=t[d].name||"<anonymous>",f=u+2,u++;break}a+=n(t[d]),f=u+2,u++;break;case 115:if(d>=l)break;f<u&&(a+=e.slice(f,u)),a+=String(t[d]),f=u+2,u++;break;case 37:f<u&&(a+=e.slice(f,u)),a+="%",f=u+2,u++,d--;break}++d}++u}return f===-1?e:(f<p&&(a+=e.slice(f)),a)}});var Qu=re((oI,Vn)=>{"use strict";var Lu=_u();Vn.exports=Ve;var kr=oy().console||{},$h={mapHttpRequest:Un,mapHttpResponse:Un,wrapRequestSerializer:Yi,wrapResponseSerializer:Yi,wrapErrorSerializer:Yi,req:Un,res:Un,err:Uu,errWithCause:Uu};function nt(e,t){return e==="silent"?1/0:t.levels.values[e]}var Zi=Symbol("pino.logFuncs"),Ji=Symbol("pino.hierarchy"),Hh={error:"log",fatal:"error",warn:"error",info:"log",debug:"log",trace:"log"};function ju(e,t){let r={logger:t,parent:e[Ji]};t[Ji]=r}function zh(e,t,r){let n={};t.forEach(o=>{n[o]=r[o]?r[o]:kr[o]||kr[Hh[o]||"log"]||Ht}),e[Zi]=n}function Gh(e,t){return Array.isArray(e)?e.filter(function(n){return n!=="!stdSerializers.err"}):e===!0?Object.keys(t):!1}function Ve(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||kr;e.browser.write&&(e.browser.asObject=!0);let n=e.serializers||{},o=Gh(e.browser.serialize,n),i=e.browser.serialize;Array.isArray(e.browser.serialize)&&e.browser.serialize.indexOf("!stdSerializers.err")>-1&&(i=!1);let s=Object.keys(e.customLevels||{}),c=["error","fatal","warn","info","debug","trace"].concat(s);typeof r=="function"&&c.forEach(function(h){r[h]=r}),(e.enabled===!1||e.browser.disabled)&&(e.level="silent");let l=e.level||"info",a=Object.create(r);a.log||(a.log=Ht),zh(a,c,r),ju({},a),Object.defineProperty(a,"levelVal",{get:f}),Object.defineProperty(a,"level",{get:p,set:u});let d={transmit:t,serialize:o,asObject:e.browser.asObject,formatters:e.browser.formatters,levels:c,timestamp:ty(e),messageKey:e.messageKey||"msg",onChild:e.onChild||Ht};a.levels=Wh(e),a.level=l,a.setMaxListeners=a.getMaxListeners=a.emit=a.addListener=a.on=a.prependListener=a.once=a.prependOnceListener=a.removeListener=a.removeAllListeners=a.listeners=a.listenerCount=a.eventNames=a.write=a.flush=Ht,a.serializers=n,a._serialize=o,a._stdErrSerialize=i,a.child=function(...h){return g.call(this,d,...h)},t&&(a._logEvent=Xi());function f(){return nt(this.level,this)}function p(){return this._level}function u(h){if(h!=="silent"&&!this.levels.values[h])throw Error("unknown level "+h);this._level=h,At(this,d,a,"error"),At(this,d,a,"fatal"),At(this,d,a,"warn"),At(this,d,a,"info"),At(this,d,a,"debug"),At(this,d,a,"trace"),s.forEach(S=>{At(this,d,a,S)})}function g(h,S,C){if(!S)throw new Error("missing bindings for child Pino");C=C||{},o&&S.serializers&&(C.serializers=S.serializers);let m=C.serializers;if(o&&m){var y=Object.assign({},n,m),A=e.browser.serialize===!0?Object.keys(y):o;delete S.serializers,es([S],A,y,this._stdErrSerialize)}function E(v){this._childLevel=(v._childLevel|0)+1,this.bindings=S,y&&(this.serializers=y,this._serialize=A),t&&(this._logEvent=Xi([].concat(v._logEvent.bindings,S)))}E.prototype=this;let b=new E(this);return ju(this,b),b.child=function(...v){return g.call(this,h,...v)},b.level=C.level||this.level,h.onChild(b),b}return a}function Wh(e){let t=e.customLevels||{},r=Object.assign({},Ve.levels.values,t),n=Object.assign({},Ve.levels.labels,Kh(t));return{values:r,labels:n}}function Kh(e){let t={};return Object.keys(e).forEach(function(r){t[e[r]]=r}),t}Ve.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"}};Ve.stdSerializers=$h;Ve.stdTimeFunctions=Object.assign({},{nullTime:Vu,epochTime:Bu,unixTime:ry,isoTime:ny});function Yh(e){let t=[];e.bindings&&t.push(e.bindings);let r=e[Ji];for(;r.parent;)r=r.parent,r.logger.bindings&&t.push(r.logger.bindings);return t.reverse()}function At(e,t,r,n){if(Object.defineProperty(e,n,{value:nt(e.level,r)>nt(n,r)?Ht:r[Zi][n],writable:!0,enumerable:!0,configurable:!0}),e[n]===Ht){if(!t.transmit)return;let i=t.transmit.level||e.level,s=nt(i,r);if(nt(n,r)<s)return}e[n]=Xh(e,t,r,n);let o=Yh(e);o.length!==0&&(e[n]=Jh(o,e[n]))}function Jh(e,t){return function(){return t.apply(this,[...e,...arguments])}}function Xh(e,t,r,n){return function(o){return function(){let s=t.timestamp(),c=new Array(arguments.length),l=Object.getPrototypeOf&&Object.getPrototypeOf(this)===kr?kr:this;for(var a=0;a<c.length;a++)c[a]=arguments[a];var d=!1;if(t.serialize&&(es(c,this._serialize,this.serializers,this._stdErrSerialize),d=!0),t.asObject||t.formatters?o.call(l,Zh(this,n,c,s,t)):o.apply(l,c),t.transmit){let f=t.transmit.level||e._level,p=nt(f,r),u=nt(n,r);if(u<p)return;ey(this,{ts:s,methodLevel:n,methodValue:u,transmitLevel:f,transmitValue:r.levels.values[t.transmit.level||e._level],send:t.transmit.send,val:nt(e._level,r)},c,d)}}}(e[Zi][n])}function Zh(e,t,r,n,o){let{level:i,log:s=p=>p}=o.formatters||{},c=r.slice(),l=c[0],a={};if(n&&(a.time=n),i){let p=i(t,e.levels.values[t]);Object.assign(a,p)}else a.level=e.levels.values[t];let d=(e._childLevel|0)+1;if(d<1&&(d=1),l!==null&&typeof l=="object"){for(;d--&&typeof c[0]=="object";)Object.assign(a,c.shift());l=c.length?Lu(c.shift(),c):void 0}else typeof l=="string"&&(l=Lu(c.shift(),c));return l!==void 0&&(a[o.messageKey]=l),s(a)}function es(e,t,r,n){for(let o in e)if(n&&e[o]instanceof Error)e[o]=Ve.stdSerializers.err(e[o]);else if(typeof e[o]=="object"&&!Array.isArray(e[o])&&t)for(let i in e[o])t.indexOf(i)>-1&&i in r&&(e[o][i]=r[i](e[o][i]))}function ey(e,t,r,n=!1){let o=t.send,i=t.ts,s=t.methodLevel,c=t.methodValue,l=t.val,a=e._logEvent.bindings;n||es(r,e._serialize||Object.keys(e.serializers),e.serializers,e._stdErrSerialize===void 0?!0:e._stdErrSerialize),e._logEvent.ts=i,e._logEvent.messages=r.filter(function(d){return a.indexOf(d)===-1}),e._logEvent.level.label=s,e._logEvent.level.value=c,o(s,e._logEvent,l),e._logEvent=Xi(a)}function Xi(e){return{ts:0,messages:[],bindings:e||[],level:{label:"",value:0}}}function Uu(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 ty(e){return typeof e.timestamp=="function"?e.timestamp:e.timestamp===!1?Vu:Bu}function Un(){return{}}function Yi(e){return e}function Ht(){}function Vu(){return!1}function Bu(){return Date.now()}function ry(){return Math.round(Date.now()/1e3)}function ny(){return new Date(Date.now()).toISOString()}function oy(){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)||{}}}Vn.exports.default=Ve;Vn.exports.pino=Ve});import{isNullOrUndefined as ly}from"@coveo/bueno";var Tr=e=>e;var Es=Re(vs(),1);var wd="recommendation-internal-options",OS=Symbol.for(wd);var ye=new Error("Failed to load reducers."),xt=class extends Error{constructor(){super(),this.name="ExpiredToken",this.message="The token being used to perform the request is expired."}};var ft=class extends Error{constructor(r,n){super();ee(this,"statusCode");this.name="Disconnected",this.message=`Client could not connect to the following URL: ${r}`,this.statusCode=n??0}};function Cs(e){return Array.isArray(e)}function As(e,t){return[...e.reduce((r,n)=>{let o=t(n);return r.has(o)||r.set(o,n),r},new Map).values()]}var xd=new Set(["1",1,"yes",!0]);function bs(){if(typeof navigator>"u"||typeof window>"u")return!1;let e=navigator,t=window;return[e.globalPrivacyControl,e.doNotTrack,e.msDoNotTrack,t.doNotTrack].some(r=>xd.has(r))}function ws(e){let t={};for(let[r,n]of e)t[r]=n;return t}function Zt(e){if(typeof e!="object"||!e)return e;try{return JSON.parse(JSON.stringify(e))}catch{return e}}function xs(e){let t=[];for(let r in e){let n=encodeURIComponent(r),o=encodeURIComponent(e[r]);t.push(`${n}=${o}`)}return t.join("&")}function Rs(e){return typeof e!="object"||!e?!1:Object.values(e).every(Rd)}function Rd(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"}function Is(e){return e===429}var He=class e{static async call(t){let r=Id(t),{logger:n}=t,o=await e.preprocessRequest(r,t);n.info(o,"Platform request");let{url:i,...s}=o,c=async()=>{let l=await fetch(i,s);if(Is(l.status))throw l;return l};try{let l=await(0,Es.backOff)(c,{retry:a=>{let d=a&&Is(a.status);return d&&n.info("Platform retrying request"),d}});switch(l.status){case 419:case 401:throw n.info("Platform renewing token"),new xt;case 404:throw new ft(i,l.status);default:return n.info({response:l,requestInfo:o},"Platform response"),l}}catch(l){return l.message==="Failed to fetch"?new ft(i):l}}static async preprocessRequest(t,r){let{origin:n,preprocessRequest:o,logger:i,requestMetadata:s}=r,{signal:c,...l}=t,a=Zt(l);try{let d=await o(t,n,s);return{...t,...d}}catch(d){i.error(d,"Platform request preprocessing failed. Returning default request options.")}return a}};function te(e,t="prod",r="platform"){let n=t==="prod"?"":t,o=r==="platform"?"":`.${r}`;return`https://${e}${o}.org${n}.coveo.com`}function Rt(e,t="prod"){return`${te(e,t)}/rest/search/v2`}function bo(e,t="prod"){return`${te(e,t,"analytics")}/rest/organizations/${e}/events/v1`}function Id(e){let{url:t,method:r,requestParams:n,contentType:o,accessToken:i,signal:s}=e,c=e.method==="POST"||e.method==="PUT",l=Ed(n,o);return{url:t,method:r,headers:{"Content-Type":o,Authorization:`Bearer ${i}`,...e.headers},...c&&{body:l},signal:s}}function Ed(e,t){return t==="application/x-www-form-urlencoded"?Rs(e)?xs(e):"":JSON.stringify(e)}var It=class{constructor(t){ee(this,"_basePath");ee(this,"_params",{});this._basePath=t}addParam(t,r){this._params={...this.params,[t]:r}}get basePath(){return this._basePath}get params(){return this._params}get hasParams(){return Object.entries(this._params).length}get href(){return this.hasParams?`${this.basePath}?${Object.entries(this.params).map(([t,r])=>`${t}=${encodeURIComponent(r)}`).join("&")}`:this.basePath}};function wo(e){let{url:t,accessToken:r,organizationId:n,authentication:o,...i}=e;return i}var xo=e=>{let{response:t}=e;return t.body?kd(e):Pd(t)},kd=e=>Od(e)?Fd(e):Td(e)?e.body:{message:"unknown",statusCode:0,type:"unknown"},Pd=e=>{let t=JSON.parse(JSON.stringify(e,Object.getOwnPropertyNames(e)));return{...t,message:`Client side error: ${t.message||""}`,statusCode:400,type:"ClientError"}};function Td(e){return e.body.statusCode!==void 0}function Od(e){return e.body.exception!==void 0}var Fd=e=>({message:e.body.exception.code,statusCode:e.response.status,type:e.body.exception.code});function ks(e){return((e.headers.get("content-type")||"").split(";").find(n=>n.indexOf("charset=")!==-1)||"").split("=")[1]||"UTF-8"}var Ro=(e,t,r,n)=>{let o=new It(`${e.url}${n}`);return o.addParam("organizationId",e.organizationId),e.authentication&&o.addParam("authentication",e.authentication),{accessToken:e.accessToken,method:t,contentType:r,url:o.href,origin:"searchApiFetch"}};var Ps=(e,t)=>{let r=new It(`${e.url}${t}`);return r.addParam("access_token",e.accessToken),r.addParam("organizationId",e.organizationId),r.addParam("uniqueId",e.uniqueId),e.q!==void 0&&r.addParam("q",e.q),e.enableNavigation!==void 0&&r.addParam("enableNavigation",`${e.enableNavigation}`),e.requestedOutputSize!==void 0&&r.addParam("requestedOutputSize",`${e.requestedOutputSize}`),r.href},Io=async(e,t)=>{let r=await He.call({...Ro(e,"POST","application/x-www-form-urlencoded","/html"),requestParams:wo(e),requestMetadata:{method:"html"},...t});if(r instanceof Error)throw r;let n=ks(r),o=await r.arrayBuffer(),s=new TextDecoder(n).decode(o);return Dd(s)?{success:s}:{error:xo({response:r,body:s})}};function Dd(e){return typeof e=="string"}function Md(e){return{statusCode:e.statusCode,type:e.name,message:e.message}}function qd(e){return{statusCode:e.code,type:e.name,message:e.message,ignored:!0}}function Fr(e,t){if(t&&e.name==="AbortError")return{error:qd(e)};if(e instanceof ft)return{error:Md(e)};throw e}var Dr=(e,t,r,n,o={})=>{Nd(e);let i=`${e.url}/rest/organizations/${e.organizationId}/caseassists/${e.caseAssistId}${n}`,s=_d(o),c=s?`${i}?${s}`:i;return{accessToken:e.accessToken,method:t,contentType:r,url:c,origin:"caseAssistApiFetch"}},Mr=e=>Object.keys(e).filter(t=>e[t].value!=="").reduce((t,r)=>({...t,[r]:e[r]}),{}),qr=e=>Object.keys(e).filter(t=>e[t].value!=="").reduce((t,r)=>({...t,[r]:e[r].value}),{}),Nd=e=>{if(!e.url)throw new Error("The 'url' attribute must contain a valid platform URL.");if(!e.organizationId)throw new Error("The 'organizationId' attribute must contain a valid organization ID.");if(!e.accessToken)throw new Error("The 'accessToken' attribute must contain a valid platform access token.");if(!e.caseAssistId)throw new Error("The 'caseAssistId' attribute must contain a valid Case Assist configuration ID.")},_d=e=>Object.keys(e).map(t=>`${t}=${encodeURIComponent(e[t])}`).join("&");var Ts=e=>{let t=e.debug?{debug:"1"}:{};return{...Dr(e,"POST","application/json","/classify",t),requestParams:Ld(e)}},Ld=e=>({clientId:e.clientId,locale:e.locale,fields:Mr(e.fields)});var Os=e=>{let t={};return e.debug&&(t.debug="1"),e.numberOfResults&&(t.numberOfResults=e.numberOfResults.toString()),{...Dr(e,"POST","application/json","/documents/suggest",t),requestParams:jd(e)}},jd=e=>({clientId:e.clientId,locale:e.locale,fields:Mr(e.fields),context:e.context});var Nr=class{constructor(t){this.options=t}async getCaseClassifications(t){let r=await He.call({...Ts(t),...this.options});if(r instanceof Error)return Fr(r);let n=await r.json();return r.ok?{success:n}:{error:n}}async getDocumentSuggestions(t){let r=await He.call({...Os(t),...this.options});if(r instanceof Error)return Fr(r);let n=await r.json();return r.ok?{success:n}:{error:n}}async html(t){return Io(t,this.options)}};import{StringValue as qp}from"@coveo/bueno";function ne(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 Ud=typeof Symbol=="function"&&Symbol.observable||"@@observable",Fs=Ud,Eo=()=>Math.random().toString(36).substring(7).split("").join("."),Vd={INIT:`@@redux/INIT${Eo()}`,REPLACE:`@@redux/REPLACE${Eo()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${Eo()}`},_r=Vd;function Ie(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 ko(e,t,r){if(typeof e!="function")throw new Error(ne(2));if(typeof t=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(ne(0));if(typeof t=="function"&&typeof r>"u"&&(r=t,t=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(ne(1));return r(ko)(e,t)}let n=e,o=t,i=new Map,s=i,c=0,l=!1;function a(){s===i&&(s=new Map,i.forEach((S,C)=>{s.set(C,S)}))}function d(){if(l)throw new Error(ne(3));return o}function f(S){if(typeof S!="function")throw new Error(ne(4));if(l)throw new Error(ne(5));let C=!0;a();let m=c++;return s.set(m,S),function(){if(C){if(l)throw new Error(ne(6));C=!1,a(),s.delete(m),i=null}}}function p(S){if(!Ie(S))throw new Error(ne(7));if(typeof S.type>"u")throw new Error(ne(8));if(typeof S.type!="string")throw new Error(ne(17));if(l)throw new Error(ne(9));try{l=!0,o=n(o,S)}finally{l=!1}return(i=s).forEach(m=>{m()}),S}function u(S){if(typeof S!="function")throw new Error(ne(10));n=S,p({type:_r.REPLACE})}function g(){let S=f;return{subscribe(C){if(typeof C!="object"||C===null)throw new Error(ne(11));function m(){let A=C;A.next&&A.next(d())}return m(),{unsubscribe:S(m)}},[Fs](){return this}}}return p({type:_r.INIT}),{dispatch:p,subscribe:f,getState:d,replaceReducer:u,[Fs]:g}}function Bd(e){Object.keys(e).forEach(t=>{let r=e[t];if(typeof r(void 0,{type:_r.INIT})>"u")throw new Error(ne(12));if(typeof r(void 0,{type:_r.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(ne(13))})}function Et(e){let t=Object.keys(e),r={};for(let s=0;s<t.length;s++){let c=t[s];typeof e[c]=="function"&&(r[c]=e[c])}let n=Object.keys(r),o,i;try{Bd(r)}catch(s){i=s}return function(c={},l){if(i)throw i;let a=!1,d={};for(let f=0;f<n.length;f++){let p=n[f],u=r[p],g=c[p],h=u(g,l);if(typeof h>"u"){let S=l&&l.type;throw new Error(ne(14))}d[p]=h,a=a||h!==g}return a=a||n.length!==Object.keys(c).length,a?d:c}}function kt(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,r)=>(...n)=>t(r(...n)))}function Ds(...e){return t=>(r,n)=>{let o=t(r,n),i=()=>{throw new Error(ne(15))},s={getState:o.getState,dispatch:(l,...a)=>i(l,...a)},c=e.map(l=>l(s));return i=kt(...c)(o.dispatch),{...o,dispatch:i}}}function Lr(e){return Ie(e)&&"type"in e&&typeof e.type=="string"}var Lo=Symbol.for("immer-nothing"),er=Symbol.for("immer-draftable"),ce=Symbol.for("immer-state");function oe(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var gt=Object.getPrototypeOf;function fe(e){return!!e&&!!e[ce]}function ue(e){return e?Ls(e)||Array.isArray(e)||!!e[er]||!!e.constructor?.[er]||ir(e)||sr(e):!1}var Qd=Object.prototype.constructor.toString();function Ls(e){if(!e||typeof e!="object")return!1;let t=gt(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)===Qd}function jo(e){return fe(e)||oe(15,e),e[ce].base_}function tr(e,t){ht(e)===0?Reflect.ownKeys(e).forEach(r=>{t(r,e[r],e)}):e.forEach((r,n)=>t(n,r,e))}function ht(e){let t=e[ce];return t?t.type_:Array.isArray(e)?1:ir(e)?2:sr(e)?3:0}function rr(e,t){return ht(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Po(e,t){return ht(e)===2?e.get(t):e[t]}function js(e,t,r){let n=ht(e);n===2?e.set(t,r):n===3?e.add(r):e[t]=r}function $d(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function ir(e){return e instanceof Map}function sr(e){return e instanceof Set}function mt(e){return e.copy_||e.base_}function Fo(e,t){if(ir(e))return new Map(e);if(sr(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);let r=Ls(e);if(t===!0||t==="class_only"&&!r){let n=Object.getOwnPropertyDescriptors(e);delete n[ce];let o=Reflect.ownKeys(n);for(let i=0;i<o.length;i++){let s=o[i],c=n[s];c.writable===!1&&(c.writable=!0,c.configurable=!0),(c.get||c.set)&&(n[s]={configurable:!0,writable:!0,enumerable:c.enumerable,value:e[s]})}return Object.create(gt(e),n)}else{let n=gt(e);if(n!==null&&r)return{...e};let o=Object.create(n);return Object.assign(o,e)}}function Vr(e,t=!1){return Br(e)||fe(e)||!ue(e)||(ht(e)>1&&(e.set=e.add=e.clear=e.delete=Hd),Object.freeze(e),t&&Object.entries(e).forEach(([r,n])=>Vr(n,!0))),e}function Hd(){oe(2)}function Br(e){return Object.isFrozen(e)}var Do={};function yt(e){let t=Do[e];return t||oe(0,e),t}function zd(e,t){Do[e]||(Do[e]=t)}var nr;function Us(){return nr}function Gd(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function Ms(e,t){t&&(yt("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Mo(e){qo(e),e.drafts_.forEach(Wd),e.drafts_=null}function qo(e){e===nr&&(nr=e.parent_)}function qs(e){return nr=Gd(nr,e)}function Wd(e){let t=e[ce];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function Ns(e,t){t.unfinalizedDrafts_=t.drafts_.length;let r=t.drafts_[0];return e!==void 0&&e!==r?(r[ce].modified_&&(Mo(t),oe(4)),ue(e)&&(e=jr(t,e),t.parent_||Ur(t,e)),t.patches_&&yt("Patches").generateReplacementPatches_(r[ce].base_,e,t.patches_,t.inversePatches_)):e=jr(t,r,[]),Mo(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==Lo?e:void 0}function jr(e,t,r){if(Br(t))return t;let n=t[ce];if(!n)return tr(t,(o,i)=>_s(e,n,t,o,i,r)),t;if(n.scope_!==e)return t;if(!n.modified_)return Ur(e,n.base_,!0),n.base_;if(!n.finalized_){n.finalized_=!0,n.scope_.unfinalizedDrafts_--;let o=n.copy_,i=o,s=!1;n.type_===3&&(i=new Set(o),o.clear(),s=!0),tr(i,(c,l)=>_s(e,n,o,c,l,r,s)),Ur(e,o,!1),r&&e.patches_&&yt("Patches").generatePatches_(n,r,e.patches_,e.inversePatches_)}return n.copy_}function _s(e,t,r,n,o,i,s){if(fe(o)){let c=i&&t&&t.type_!==3&&!rr(t.assigned_,n)?i.concat(n):void 0,l=jr(e,o,c);if(js(r,n,l),fe(l))e.canAutoFreeze_=!1;else return}else s&&r.add(o);if(ue(o)&&!Br(o)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;jr(e,o),(!t||!t.scope_.parent_)&&typeof n!="symbol"&&Object.prototype.propertyIsEnumerable.call(r,n)&&Ur(e,o)}}function Ur(e,t,r=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Vr(t,r)}function Kd(e,t){let r=Array.isArray(e),n={type_:r?1:0,scope_:t?t.scope_:Us(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1},o=n,i=Uo;r&&(o=[n],i=or);let{revoke:s,proxy:c}=Proxy.revocable(o,i);return n.draft_=c,n.revoke_=s,c}var Uo={get(e,t){if(t===ce)return e;let r=mt(e);if(!rr(r,t))return Yd(e,r,t);let n=r[t];return e.finalized_||!ue(n)?n:n===To(e.base_,t)?(Oo(e),e.copy_[t]=_o(n,e)):n},has(e,t){return t in mt(e)},ownKeys(e){return Reflect.ownKeys(mt(e))},set(e,t,r){let n=Vs(mt(e),t);if(n?.set)return n.set.call(e.draft_,r),!0;if(!e.modified_){let o=To(mt(e),t),i=o?.[ce];if(i&&i.base_===r)return e.copy_[t]=r,e.assigned_[t]=!1,!0;if($d(r,o)&&(r!==void 0||rr(e.base_,t)))return!0;Oo(e),No(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 To(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,Oo(e),No(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){let r=mt(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:n.enumerable,value:r[t]}},defineProperty(){oe(11)},getPrototypeOf(e){return gt(e.base_)},setPrototypeOf(){oe(12)}},or={};tr(Uo,(e,t)=>{or[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});or.deleteProperty=function(e,t){return or.set.call(this,e,t,void 0)};or.set=function(e,t,r){return Uo.set.call(this,e[0],t,r,e[0])};function To(e,t){let r=e[ce];return(r?mt(r):e)[t]}function Yd(e,t,r){let n=Vs(t,r);return n?"value"in n?n.value:n.get?.call(e.draft_):void 0}function Vs(e,t){if(!(t in e))return;let r=gt(e);for(;r;){let n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=gt(r)}}function No(e){e.modified_||(e.modified_=!0,e.parent_&&No(e.parent_))}function Oo(e){e.copy_||(e.copy_=Fo(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var Jd=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,r,n)=>{if(typeof t=="function"&&typeof r!="function"){let i=r;r=t;let s=this;return function(l=i,...a){return s.produce(l,d=>r.call(this,d,...a))}}typeof r!="function"&&oe(6),n!==void 0&&typeof n!="function"&&oe(7);let o;if(ue(t)){let i=qs(this),s=_o(t,void 0),c=!0;try{o=r(s),c=!1}finally{c?Mo(i):qo(i)}return Ms(i,n),Ns(o,i)}else if(!t||typeof t!="object"){if(o=r(t),o===void 0&&(o=t),o===Lo&&(o=void 0),this.autoFreeze_&&Vr(o,!0),n){let i=[],s=[];yt("Patches").generateReplacementPatches_(t,o,i,s),n(i,s)}return o}else oe(1,t)},this.produceWithPatches=(t,r)=>{if(typeof t=="function")return(s,...c)=>this.produceWithPatches(s,l=>t(l,...c));let n,o;return[this.produce(t,r,(s,c)=>{n=s,o=c}),n,o]},typeof e?.autoFreeze=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof e?.useStrictShallowCopy=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){ue(e)||oe(8),fe(e)&&(e=Bs(e));let t=qs(this),r=_o(e,void 0);return r[ce].isManual_=!0,qo(t),r}finishDraft(e,t){let r=e&&e[ce];(!r||!r.isManual_)&&oe(9);let{scope_:n}=r;return Ms(n,t),Ns(void 0,n)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let r;for(r=t.length-1;r>=0;r--){let o=t[r];if(o.path.length===0&&o.op==="replace"){e=o.value;break}}r>-1&&(t=t.slice(r+1));let n=yt("Patches").applyPatches_;return fe(e)?n(e,t):this.produce(e,o=>n(o,t))}};function _o(e,t){let r=ir(e)?yt("MapSet").proxyMap_(e,t):sr(e)?yt("MapSet").proxySet_(e,t):Kd(e,t);return(t?t.scope_:Us()).drafts_.push(r),r}function Bs(e){return fe(e)||oe(10,e),Qs(e)}function Qs(e){if(!ue(e)||Br(e))return e;let t=e[ce],r;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,r=Fo(e,t.scope_.immer_.useStrictShallowCopy_)}else r=Fo(e,!0);return tr(r,(n,o)=>{js(r,n,Qs(o))}),t&&(t.finalized_=!1),r}function $s(){let t="replace",r="add",n="remove";function o(p,u,g,h){switch(p.type_){case 0:case 2:return s(p,u,g,h);case 1:return i(p,u,g,h);case 3:return c(p,u,g,h)}}function i(p,u,g,h){let{base_:S,assigned_:C}=p,m=p.copy_;m.length<S.length&&([S,m]=[m,S],[g,h]=[h,g]);for(let y=0;y<S.length;y++)if(C[y]&&m[y]!==S[y]){let A=u.concat([y]);g.push({op:t,path:A,value:f(m[y])}),h.push({op:t,path:A,value:f(S[y])})}for(let y=S.length;y<m.length;y++){let A=u.concat([y]);g.push({op:r,path:A,value:f(m[y])})}for(let y=m.length-1;S.length<=y;--y){let A=u.concat([y]);h.push({op:n,path:A})}}function s(p,u,g,h){let{base_:S,copy_:C}=p;tr(p.assigned_,(m,y)=>{let A=Po(S,m),E=Po(C,m),b=y?rr(S,m)?t:r:n;if(A===E&&b===t)return;let v=u.concat(m);g.push(b===n?{op:b,path:v}:{op:b,path:v,value:E}),h.push(b===r?{op:n,path:v}:b===n?{op:r,path:v,value:f(A)}:{op:t,path:v,value:f(A)})})}function c(p,u,g,h){let{base_:S,copy_:C}=p,m=0;S.forEach(y=>{if(!C.has(y)){let A=u.concat([m]);g.push({op:n,path:A,value:y}),h.unshift({op:r,path:A,value:y})}m++}),m=0,C.forEach(y=>{if(!S.has(y)){let A=u.concat([m]);g.push({op:r,path:A,value:y}),h.unshift({op:n,path:A,value:y})}m++})}function l(p,u,g,h){g.push({op:t,path:[],value:u===Lo?void 0:u}),h.push({op:t,path:[],value:p})}function a(p,u){return u.forEach(g=>{let{path:h,op:S}=g,C=p;for(let E=0;E<h.length-1;E++){let b=ht(C),v=h[E];typeof v!="string"&&typeof v!="number"&&(v=""+v),(b===0||b===1)&&(v==="__proto__"||v==="constructor")&&oe(19),typeof C=="function"&&v==="prototype"&&oe(19),C=Po(C,v),typeof C!="object"&&oe(18,h.join("/"))}let m=ht(C),y=d(g.value),A=h[h.length-1];switch(S){case t:switch(m){case 2:return C.set(A,y);case 3:oe(16);default:return C[A]=y}case r:switch(m){case 1:return A==="-"?C.push(y):C.splice(A,0,y);case 2:return C.set(A,y);case 3:return C.add(y);default:return C[A]=y}case n:switch(m){case 1:return C.splice(A,1);case 2:return C.delete(A);case 3:return C.delete(g.value);default:return delete C[A]}default:oe(17,S)}}),p}function d(p){if(!ue(p))return p;if(Array.isArray(p))return p.map(d);if(ir(p))return new Map(Array.from(p.entries()).map(([g,h])=>[g,d(h)]));if(sr(p))return new Set(Array.from(p).map(d));let u=Object.create(gt(p));for(let g in p)u[g]=d(p[g]);return rr(p,er)&&(u[er]=p[er]),u}function f(p){return fe(p)?d(p):p}zd("Patches",{applyPatches_:a,generatePatches_:o,generateReplacementPatches_:l})}var me=new Jd,Ne=me.produce,Qr=me.produceWithPatches.bind(me),bv=me.setAutoFreeze.bind(me),wv=me.setUseStrictShallowCopy.bind(me),Vo=me.applyPatches.bind(me),xv=me.createDraft.bind(me),Rv=me.finishDraft.bind(me);function Xd(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function Zd(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function ep(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(r=>typeof r=="function")){let r=e.map(n=>typeof n=="function"?`function ${n.name||"unnamed"}()`:typeof n).join(", ");throw new TypeError(`${t}[${r}]`)}}var Hs=e=>Array.isArray(e)?e:[e];function tp(e){let t=Array.isArray(e[0])?e[0]:e;return ep(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function rp(e,t){let r=[],{length:n}=e;for(let o=0;o<n;o++)r.push(e[o].apply(null,t));return r}var kv=Symbol();var Pv=Object.getPrototypeOf({});var np=class{constructor(e){this.value=e}deref(){return this.value}},op=typeof WeakRef<"u"?WeakRef:np,ip=0,zs=1;function $r(){return{s:ip,v:void 0,o:null,p:null}}function Pt(e,t={}){let r=$r(),{resultEqualityCheck:n}=t,o,i=0;function s(){let c=r,{length:l}=arguments;for(let f=0,p=l;f<p;f++){let u=arguments[f];if(typeof u=="function"||typeof u=="object"&&u!==null){let g=c.o;g===null&&(c.o=g=new WeakMap);let h=g.get(u);h===void 0?(c=$r(),g.set(u,c)):c=h}else{let g=c.p;g===null&&(c.p=g=new Map);let h=g.get(u);h===void 0?(c=$r(),g.set(u,c)):c=h}}let a=c,d;if(c.s===zs)d=c.v;else if(d=e.apply(null,arguments),i++,n){let f=o?.deref?.()??o;f!=null&&n(f,d)&&(d=f,i!==0&&i--),o=typeof d=="object"&&d!==null||typeof d=="function"?new op(d):d}return a.s=zs,a.v=d,d}return s.clearCache=()=>{r=$r(),s.resetResultsCount()},s.resultsCount=()=>i,s.resetResultsCount=()=>{i=0},s}function Gs(e,...t){let r=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,n=(...o)=>{let i=0,s=0,c,l={},a=o.pop();typeof a=="object"&&(l=a,a=o.pop()),Xd(a,`createSelector expects an output function after the inputs, but received: [${typeof a}]`);let d={...r,...l},{memoize:f,memoizeOptions:p=[],argsMemoize:u=Pt,argsMemoizeOptions:g=[],devModeChecks:h={}}=d,S=Hs(p),C=Hs(g),m=tp(o),y=f(function(){return i++,a.apply(null,arguments)},...S),A=!0,E=u(function(){s++;let v=rp(m,arguments);return c=y.apply(null,v),c},...C);return Object.assign(E,{resultFunc:a,memoizedResultFunc:y,dependencies:m,dependencyRecomputations:()=>s,resetDependencyRecomputations:()=>{s=0},lastResult:()=>c,recomputations:()=>i,resetRecomputations:()=>{i=0},memoize:f,argsMemoize:u})};return Object.assign(n,{withTypes:()=>n}),n}var K=Gs(Pt),sp=Object.assign((e,t=K)=>{Zd(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),n=r.map(i=>e[i]);return t(n,(...i)=>i.reduce((s,c,l)=>(s[r[l]]=c,s),{}))},{withTypes:()=>sp});function Ws(e){return({dispatch:r,getState:n})=>o=>i=>typeof i=="function"?i(r,n,e):o(i)}var Ks=Ws(),Ys=Ws;var ap=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?kt:kt.apply(null,arguments)},jv=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(e){return e}},cp=e=>e&&typeof e.match=="function";function F(e,t){function r(...n){if(t){let o=t(...n);if(!o)throw new Error(Ae(0));return{type:e,payload:o.payload,..."meta"in o&&{meta:o.meta},..."error"in o&&{error:o.error}}}return{type:e,payload:n[0]}}return r.toString=()=>`${e}`,r.type=e,r.match=n=>Lr(n)&&n.type===e,r}var ta=class ar extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,ar.prototype)}static get[Symbol.species](){return ar}concat(...t){return super.concat.apply(this,t)}prepend(...t){return t.length===1&&Array.isArray(t[0])?new ar(...t[0].concat(this)):new ar(...t.concat(this))}};function Js(e){return ue(e)?Ne(e,()=>{}):e}function Xs(e,t,r){return e.has(t)?e.get(t):e.set(t,r(t)).get(t)}function up(e){return typeof e=="boolean"}var lp=()=>function(t){let{thunk:r=!0,immutableCheck:n=!0,serializableCheck:o=!0,actionCreatorCheck:i=!0}=t??{},s=new ta;return r&&(up(r)?s.push(Ks):s.push(Ys(r.extraArgument))),s},ze="RTK_autoBatch",Ot=()=>e=>({payload:e,meta:{[ze]:!0}}),Zs=e=>t=>{setTimeout(t,e)},dp=(e={type:"raf"})=>t=>(...r)=>{let n=t(...r),o=!0,i=!1,s=!1,c=new Set,l=e.type==="tick"?queueMicrotask:e.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Zs(10):e.type==="callback"?e.queueNotification:Zs(e.timeout),a=()=>{s=!1,i&&(i=!1,c.forEach(d=>d()))};return Object.assign({},n,{subscribe(d){let f=()=>o&&d(),p=n.subscribe(f);return c.add(d),()=>{p(),c.delete(d)}},dispatch(d){try{return o=!d?.meta?.[ze],i=!o,i&&(s||(s=!0,l(a))),n.dispatch(d)}finally{o=!0}}})},pp=e=>function(r){let{autoBatch:n=!0}=r??{},o=new ta(e);return n&&o.push(dp(typeof n=="object"?n:void 0)),o};function ra(e){let t=lp(),{reducer:r=void 0,middleware:n,devTools:o=!0,preloadedState:i=void 0,enhancers:s=void 0}=e||{},c;if(typeof r=="function")c=r;else if(Ie(r))c=Et(r);else throw new Error(Ae(1));let l;typeof n=="function"?l=n(t):l=t();let a=kt;o&&(a=ap({trace:!1,...typeof o=="object"&&o}));let d=Ds(...l),f=pp(d),p=typeof s=="function"?s(f):f(),u=a(...p);return ko(c,i,u)}function na(e){let t={},r=[],n,o={addCase(i,s){let c=typeof i=="string"?i:i.type;if(!c)throw new Error(Ae(28));if(c in t)throw new Error(Ae(29));return t[c]=s,o},addMatcher(i,s){return r.push({matcher:i,reducer:s}),o},addDefaultCase(i){return n=i,o}};return e(o),[t,r,n]}function fp(e){return typeof e=="function"}function Y(e,t){let[r,n,o]=na(t),i;if(fp(e))i=()=>Js(e());else{let c=Js(e);i=()=>c}function s(c=i(),l){let a=[r[l.type],...n.filter(({matcher:d})=>d(l)).map(({reducer:d})=>d)];return a.filter(d=>!!d).length===0&&(a=[o]),a.reduce((d,f)=>{if(f)if(fe(d)){let u=f(d,l);return u===void 0?d:u}else{if(ue(d))return Ne(d,p=>f(p,l));{let p=f(d,l);if(p===void 0){if(d===null)return d;throw Error("A case reducer on a non-draftable value must not return undefined")}return p}}return d},c)}return s.getInitialState=i,s}var oa=(e,t)=>cp(e)?e.match(t):e(t);function Ee(...e){return t=>e.some(r=>oa(r,t))}function Tt(...e){return t=>e.every(r=>oa(r,t))}function zr(e,t){if(!e||!e.meta)return!1;let r=typeof e.meta.requestId=="string",n=t.indexOf(e.meta.requestStatus)>-1;return r&&n}function cr(e){return typeof e[0]=="function"&&"pending"in e[0]&&"fulfilled"in e[0]&&"rejected"in e[0]}function Gr(...e){return e.length===0?t=>zr(t,["pending"]):cr(e)?Ee(...e.map(t=>t.pending)):Gr()(e[0])}function St(...e){return e.length===0?t=>zr(t,["rejected"]):cr(e)?Ee(...e.map(t=>t.rejected)):St()(e[0])}function ur(...e){let t=r=>r&&r.meta&&r.meta.rejectedWithValue;return e.length===0?Tt(St(...e),t):cr(e)?Tt(St(...e),t):ur()(e[0])}function _e(...e){return e.length===0?t=>zr(t,["fulfilled"]):cr(e)?Ee(...e.map(t=>t.fulfilled)):_e()(e[0])}function Wr(...e){return e.length===0?t=>zr(t,["pending","fulfilled","rejected"]):cr(e)?Ee(...e.flatMap(t=>[t.pending,t.rejected,t.fulfilled])):Wr()(e[0])}var mp="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",Kr=(e=21)=>{let t="",r=e;for(;r--;)t+=mp[Math.random()*64|0];return t},gp=["name","message","stack","code"],Bo=class{constructor(e,t){ee(this,"_type");this.payload=e,this.meta=t}},ea=class{constructor(e,t){ee(this,"_type");this.payload=e,this.meta=t}},hp=e=>{if(typeof e=="object"&&e!==null){let t={};for(let r of gp)typeof e[r]=="string"&&(t[r]=e[r]);return t}return{message:String(e)}},Q=(()=>{function e(t,r,n){let o=F(t+"/fulfilled",(l,a,d,f)=>({payload:l,meta:{...f||{},arg:d,requestId:a,requestStatus:"fulfilled"}})),i=F(t+"/pending",(l,a,d)=>({payload:void 0,meta:{...d||{},arg:a,requestId:l,requestStatus:"pending"}})),s=F(t+"/rejected",(l,a,d,f,p)=>({payload:f,error:(n&&n.serializeError||hp)(l||"Rejected"),meta:{...p||{},arg:d,requestId:a,rejectedWithValue:!!f,requestStatus:"rejected",aborted:l?.name==="AbortError",condition:l?.name==="ConditionError"}}));function c(l){return(a,d,f)=>{let p=n?.idGenerator?n.idGenerator(l):Kr(),u=new AbortController,g,h;function S(m){h=m,u.abort()}let C=async function(){let m;try{let A=n?.condition?.(l,{getState:d,extra:f});if(Sp(A)&&(A=await A),A===!1||u.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};let E=new Promise((b,v)=>{g=()=>{v({name:"AbortError",message:h||"Aborted"})},u.signal.addEventListener("abort",g)});a(i(p,l,n?.getPendingMeta?.({requestId:p,arg:l},{getState:d,extra:f}))),m=await Promise.race([E,Promise.resolve(r(l,{dispatch:a,getState:d,extra:f,requestId:p,signal:u.signal,abort:S,rejectWithValue:(b,v)=>new Bo(b,v),fulfillWithValue:(b,v)=>new ea(b,v)})).then(b=>{if(b instanceof Bo)throw b;return b instanceof ea?o(b.payload,p,l,b.meta):o(b,p,l)})])}catch(A){m=A instanceof Bo?s(null,p,l,A.payload,A.meta):s(A,p,l)}finally{g&&u.signal.removeEventListener("abort",g)}return n&&!n.dispatchConditionRejection&&s.match(m)&&m.meta.condition||a(m),m}();return Object.assign(C,{abort:S,requestId:p,arg:l,unwrap(){return C.then(yp)}})}}return Object.assign(c,{pending:i,rejected:s,fulfilled:o,settled:Ee(s,o),typePrefix:t})}return e.withTypes=()=>e,e})();function yp(e){if(e.meta&&e.meta.rejectedWithValue)throw e.payload;if(e.error)throw e.error;return e.payload}function Sp(e){return e!==null&&typeof e=="object"&&typeof e.then=="function"}var ia=Symbol.for("rtk-slice-createasyncthunk"),$v={[ia]:Q};function vp(e,t){return`${e}/${t}`}function Cp({creators:e}={}){let t=e?.asyncThunk?.[ia];return function(n){let{name:o,reducerPath:i=o}=n;if(!o)throw new Error(Ae(11));typeof process<"u";let s=(typeof n.reducers=="function"?n.reducers(bp()):n.reducers)||{},c=Object.keys(s),l={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},a={addCase(m,y){let A=typeof m=="string"?m:m.type;if(!A)throw new Error(Ae(12));if(A in l.sliceCaseReducersByType)throw new Error(Ae(13));return l.sliceCaseReducersByType[A]=y,a},addMatcher(m,y){return l.sliceMatchers.push({matcher:m,reducer:y}),a},exposeAction(m,y){return l.actionCreators[m]=y,a},exposeCaseReducer(m,y){return l.sliceCaseReducersByName[m]=y,a}};c.forEach(m=>{let y=s[m],A={reducerName:m,type:vp(o,m),createNotation:typeof n.reducers=="function"};xp(y)?Ip(A,y,a,t):wp(A,y,a)});function d(){let[m={},y=[],A=void 0]=typeof n.extraReducers=="function"?na(n.extraReducers):[n.extraReducers],E={...m,...l.sliceCaseReducersByType};return Y(n.initialState,b=>{for(let v in E)b.addCase(v,E[v]);for(let v of l.sliceMatchers)b.addMatcher(v.matcher,v.reducer);for(let v of y)b.addMatcher(v.matcher,v.reducer);A&&b.addDefaultCase(A)})}let f=m=>m,p=new Map,u;function g(m,y){return u||(u=d()),u(m,y)}function h(){return u||(u=d()),u.getInitialState()}function S(m,y=!1){function A(b){let v=b[m];return typeof v>"u"&&y&&(v=h()),v}function E(b=f){let v=Xs(p,y,()=>new WeakMap);return Xs(v,b,()=>{let I={};for(let[x,O]of Object.entries(n.selectors??{}))I[x]=Ap(O,b,h,y);return I})}return{reducerPath:m,getSelectors:E,get selectors(){return E(A)},selectSlice:A}}let C={name:o,reducer:g,actions:l.actionCreators,caseReducers:l.sliceCaseReducersByName,getInitialState:h,...S(i),injectInto(m,{reducerPath:y,...A}={}){let E=y??i;return m.inject({reducerPath:E,reducer:g},A),{...C,...S(E,!0)}}};return C}}function Ap(e,t,r,n){function o(i,...s){let c=t(i);return typeof c>"u"&&n&&(c=r()),e(c,...s)}return o.unwrapped=e,o}var vt=Cp();function bp(){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 wp({type:e,reducerName:t,createNotation:r},n,o){let i,s;if("reducer"in n){if(r&&!Rp(n))throw new Error(Ae(17));i=n.reducer,s=n.prepare}else i=n;o.addCase(e,i).exposeCaseReducer(t,i).exposeAction(t,s?F(e,s):F(e))}function xp(e){return e._reducerDefinitionType==="asyncThunk"}function Rp(e){return e._reducerDefinitionType==="reducerWithPrepare"}function Ip({type:e,reducerName:t},r,n,o){if(!o)throw new Error(Ae(18));let{payloadCreator:i,fulfilled:s,pending:c,rejected:l,settled:a,options:d}=r,f=o(e,i,d);n.exposeAction(t,f),s&&n.addCase(f.fulfilled,s),c&&n.addCase(f.pending,c),l&&n.addCase(f.rejected,l),a&&n.addMatcher(f.settled,a),n.exposeCaseReducer(t,{fulfilled:s||Hr,pending:c||Hr,rejected:l||Hr,settled:a||Hr})}function Hr(){}var sa="listener",aa="completed",ca="cancelled",Hv=`task-${ca}`,zv=`task-${aa}`,Gv=`${sa}-${ca}`,Wv=`${sa}-${aa}`;var{assign:ua}=Object;var Qo="listenerMiddleware";var Ep=ua(F(`${Qo}/add`),{withTypes:()=>Ep}),Kv=F(`${Qo}/removeAll`),kp=ua(F(`${Qo}/remove`),{withTypes:()=>kp});var Yv=Symbol.for("rtk-state-proxy-original");function Ae(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 Pp,SchemaValidationError as Tp,StringValue as lr,RecordValue as Op,ArrayValue as Fp}from"@coveo/bueno";var U=new lr({required:!0,emptyAllowed:!1}),W=new lr({required:!1,emptyAllowed:!1}),be=new lr({required:!0,emptyAllowed:!0}),iC=new lr({required:!1,emptyAllowed:!0}),la=new Fp({each:U,required:!0}),da=new lr({required:!1,emptyAllowed:!1,regex:/^\d+\.\d+\.\d+$/}),Dp=({message:e,name:t,stack:r})=>({message:e,name:t,stack:r}),$o=(e,t)=>{if("required"in t)return{payload:new Pp({value:t}).validate({value:e}).value};let o=new Op({options:{required:!0},values:t}).validate(e);if(o)throw new Tp(o);return{payload:e}},L=(e,t)=>{try{return $o(e,t)}catch(r){return{payload:e,error:Dp(r)}}};var Yr=(e,t,r,n)=>{let o=`Check the options of ${n}`;return Mp(e,t,r,o,"Controller initialization error")},Mp=(e,t,r,n,o)=>{try{return t.validate(r,n)}catch(i){throw e.logger.error(i,o),i}};var Jr=F("caseAssistConfiguration/set",e=>L(e,{caseAssistId:U,locale:W,proxyBaseUrl:new qp({required:!1,url:!0})}));var pa=()=>({caseAssistId:"",locale:"en-US"});var Ge=Y(pa(),e=>{e.addCase(Jr,(t,r)=>{t.caseAssistId=r.payload.caseAssistId,t.locale=r.payload.locale,t.apiBaseUrl=r.payload.proxyBaseUrl})});import{BooleanValue as fa,StringValue as dr,NumberValue as ma,RecordValue as We}from"@coveo/bueno";var ga={q:new dr,enableQuerySyntax:new fa,aq:new dr,cq:new dr,firstResult:new ma({min:0}),numberOfResults:new ma({min:0}),sortCriteria:new dr,f:new We,fExcluded:new We,cf:new We,nf:new We,mnf:new We,df:new We,debug:new fa,sf:new We,tab:new dr,af:new We};var Xr=F("searchParameters/restore",e=>L(e,ga));var ha=F("debug/enable"),ya=F("debug/disable");var Zr=()=>!1;var Sa=Y(Zr(),e=>{e.addCase(ha,()=>!0).addCase(ya,()=>!1).addCase(Xr,(t,r)=>r.payload.debug??t)});import{StringValue as Np}from"@coveo/bueno";var en=F("searchHub/set",e=>L(e,new Np({required:!0,emptyAllowed:!0})));import{ArrayValue as _p,BooleanValue as Ca,RecordValue as Lp,StringValue as pr,Value as jp}from"@coveo/bueno";var Ft="3.13.0-pre.ca85011e15",va=["@coveo/atomic","@coveo/quantic"];var Ho=()=>W,Aa=()=>U,Dt=F("configuration/updateBasicConfiguration",e=>L(e,{accessToken:W,environment:new pr({required:!1,constrainTo:["prod","hipaa","stg","dev"]}),organizationId:W})),tn=F("configuration/updateSearchConfiguration",e=>L(e,{proxyBaseUrl:new pr({required:!1,url:!0}),pipeline:new pr({required:!1,emptyAllowed:!0}),searchHub:W,timezone:W,locale:W,authenticationProviders:new _p({required:!1,each:U})})),Up={enabled:new Ca({default:!0}),originContext:Ho(),originLevel2:Ho(),originLevel3:Ho(),proxyBaseUrl:new pr({required:!1,url:!0}),runtimeEnvironment:new jp,anonymous:new Ca({default:!1}),deviceId:W,userDisplayName:W,documentLocation:W,trackingId:W,analyticsMode:new pr({constrainTo:["legacy","next"],required:!1,default:"next"}),source:new Lp({options:{required:!1},values:va.reduce((e,t)=>(e[t]=da,e),{})})},rn=F("configuration/updateAnalyticsConfiguration",e=>L(e,Up)),nn=F("configuration/analytics/disable"),on=F("configuration/analytics/enable"),ba=F("configuration/analytics/originlevel2",e=>L(e,{originLevel2:Aa()})),wa=F("configuration/analytics/originlevel3",e=>L(e,{originLevel3:Aa()}));var Vp=F("history/undo"),Bp=F("history/redo"),ke=F("history/snapshot"),$C=Q("history/back",async(e,{dispatch:t})=>{t(Vp()),await t(sn())}),HC=Q("history/forward",async(e,{dispatch:t})=>{t(Bp()),await t(sn())}),sn=Q("history/change",async(e,{getState:t})=>t().history.present);var Ke=()=>"default";var xa=Y(Ke(),e=>{e.addCase(en,(t,r)=>r.payload).addCase(sn.fulfilled,(t,r)=>r.payload?.searchHub??t).addCase(tn,(t,r)=>r.payload.searchHub||t)});function Qp({config:e,environment:t,event:r,listenerManager:n}){let{url:o,token:i,mode:s}=e;s!=="disabled"&&(n.call(r),t.send(o,i,r))}var $p=/^(?:[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 Hp(e){return typeof e=="string"&&$p.test(e)}function zp(e){return{getClientId:()=>{let t="visitorId",r=e.get(),n=r.storage,o=n.getItem(t),i=o&&Hp(o)?o:r.generateUUID();return n.setItem(t,i),i}}}var Ia="0.7.10";function Gp(e){let{trackingId:t}=e;return{trackingId:t}}function Wp(e){return(e.source||[]).concat([`relay@${Ia}`])}function Ea(e,t,r,n){let{getReferrer:o,getLocation:i,getUserAgent:s}=r,c=Gp(t),l=n.getClientId();return Object.freeze({type:e,config:c,ts:Date.now(),source:Wp(t),clientId:l,userAgent:s(),referrer:o(),location:i()})}function Kp(e,t,r,n,o){return{...t,meta:Ea(e,r,n,o)}}var Yp="*";function Jp(){let e=[];function t({type:l,callback:a}){return e.findIndex(d=>d.type===l&&d.callback===a)}function r(l,a){return l.type==="*"||a===l.type}function n(l){return t(l)<0&&e.push(l),()=>c(l.type,l.callback)}function o(l){e.forEach(a=>{if(r(a,l.meta.type))try{a.callback(l)}catch(d){console.error(d)}})}function i(l){if(l===Yp)e.length=0;else for(let a=e.length-1;a>=0;a--)e[a].type===l&&e.splice(a,1)}function s(l){let a=t(l);a>=0&&e.splice(a,1)}function c(l,a){a?s({type:l,callback:a}):i(l)}return{add:n,call:o,remove:c}}function Ra({url:e,token:t,trackingId:r,...n}){return Object.freeze({url:e,token:t,trackingId:r,...!!n.mode&&{mode:n.mode},...!!n.source&&{source:n.source}})}function Xp(e){let t=Ra(e);return{get:()=>t,update:r=>{t=Ra({...t,...r})}}}function Zp(){let e=typeof window<"u";return{sendMessage(t){e&&window.postMessage(t,"*")}}}var zo=ef();function ef(){let e="coveo_",t=r=>{let n=r.split(".").slice(-2);return n.length==2?n.join("."):""};return{getItem(r){let n=`${e}${r}=`,o=document.cookie.split(";");for(let i of o){let s=i.replace(/^\s+/,"");if(s.lastIndexOf(n,0)===0)return s.substring(n.length,s.length)}return null},setItem(r,n,o){let i=t(window.location.hostname),s=`;expires=${new Date(new Date().getTime()+o).toUTCString()}`,c=i?`;domain=${i}`:"";document.cookie=`${e}${r}=${n}${s}${c};path=/;SameSite=Lax`},removeItem(r){this.setItem(r,"",-1)}}}function tf(){return{getItem(e){return zo.getItem(e)||localStorage.getItem(e)},removeItem(e){zo.removeItem(e),localStorage.removeItem(e)},setItem(e,t){localStorage.setItem(e,t),zo.setItem(e,t,31556952e3)}}}function rf(){let e=document.referrer;return e===""?null:e}function nf(){return{runtime:"browser",send:(e,t,r)=>{let n=navigator.sendBeacon(`${e}?access_token=${t}`,new Blob([JSON.stringify([r])],{type:"application/json"}));if(Zp().sendMessage({kind:"EVENT_PROTOCOL",event:r,url:e,token:t}),!n)throw new Error("Failed to send the event(s) because the payload size exceeded the maximum allowed size (32 KB). Please contact support if the problem persists.")},getReferrer:()=>rf(),getLocation:()=>window.location.href,getUserAgent:()=>navigator.userAgent,generateUUID:()=>crypto.randomUUID(),storage:tf()}}function of(){try{let e="__storage_test__";return localStorage.setItem(e,e),localStorage.removeItem(e),!0}catch(e){return e instanceof DOMException&&e.name==="QuotaExceededError"&&localStorage&&localStorage.length!==0}}function sf(){return{getItem(){return null},removeItem(){},setItem(){}}}function af(){return{runtime:"null",send:()=>{},getReferrer:()=>null,getLocation:()=>null,getUserAgent:()=>null,generateUUID:()=>"",storage:sf()}}function cf(e){return e.get().mode!=="disabled"&&uf()&&of()?nf():af()}function uf(){try{return typeof window=="object"}catch{return!1}}function lf(e){return{get:()=>Object.freeze(cf(e))}}function ka(e){let t=Xp(e),r=Jp(),n=lf(t),o=zp(n);return{emit:(i,s)=>{let c=t.get(),l=n.get(),a=Kp(i,s,c,l,o);return Qp({config:c,environment:l,event:a,listenerManager:r})},getMeta:i=>Ea(i,t.get(),n.get(),o),on:(i,s)=>r.add({type:i,callback:s}),off:(i,s)=>r.remove(i,s),updateConfig:i=>t.update(i),version:Ia}}var Mt=K(e=>e.source,e=>Object.entries(e).map(([t,r])=>`${t}@${r}`).concat(`@coveo/headless@${Ft}`));var qt=K(e=>e.configuration.organizationId,e=>e.configuration.environment,e=>e.configuration.accessToken,e=>e.configuration.analytics,e=>Mt(e.configuration.analytics),(e,t,r,{trackingId:n,apiBaseUrl:o,enabled:i},s)=>ka({mode:i?"emit":"disabled",url:o??bo(e,t),token:r,trackingId:n,source:s}));async function Ta(e,t){let r=e.getReader(),n;for(;!(n=await r.read()).done;)t(n.value)}function Oa(e){let t,r,n,o=!1;return function(s){t===void 0?(t=s,r=0,n=-1):t=df(t,s);let c=t.length,l=0;for(;r<c;){o&&(t[r]===10&&(l=++r),o=!1);let a=-1;for(;r<c&&a===-1;++r)switch(t[r]){case 58:n===-1&&(n=r-l);break;case 13:o=!0;case 10:a=r;break}if(a===-1)break;e(t.subarray(l,a),n),l=r,n=-1}l===c?t=void 0:l!==0&&(t=t.subarray(l),r-=l)}}function Fa(e,t,r){let n=Pa(),o=new TextDecoder;return function(s,c){if(s.length===0)r?.(n),n=Pa();else if(c>0){let l=o.decode(s.subarray(0,c)),a=c+(s[c+1]===32?2:1),d=o.decode(s.subarray(a));switch(l){case"data":n.data=n.data?n.data+`
18
+ var Hl=Object.create;var fo=Object.defineProperty;var zl=Object.getOwnPropertyDescriptor;var Gl=Object.getOwnPropertyNames;var Wl=Object.getPrototypeOf,Kl=Object.prototype.hasOwnProperty;var Yl=(e,t,r)=>t in e?fo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var re=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var Jl=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of Gl(t))!Kl.call(e,o)&&o!==r&&fo(e,o,{get:()=>t[o],enumerable:!(n=zl(t,o))||n.enumerable});return e};var Re=(e,t,r)=>(r=e!=null?Hl(Wl(e)):{},Jl(t||!e||!e.__esModule?fo(r,"default",{value:e,enumerable:!0}):r,e));var ee=(e,t,r)=>Yl(e,typeof t!="symbol"?t+"":t,r);var ps=re(Jt=>{"use strict";var Or=Jt&&Jt.__assign||function(){return Or=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},Or.apply(this,arguments)};Object.defineProperty(Jt,"__esModule",{value:!0});var Xl={delayFirstAttempt:!1,jitter:"none",maxDelay:1/0,numOfAttempts:10,retry:function(){return!0},startingDelay:100,timeMultiple:2};function Zl(e){var t=Or(Or({},Xl),e);return t.numOfAttempts<1&&(t.numOfAttempts=1),t}Jt.getSanitizedOptions=Zl});var fs=re(mo=>{"use strict";Object.defineProperty(mo,"__esModule",{value:!0});function ed(e){var t=Math.random()*e;return Math.round(t)}mo.fullJitter=ed});var ms=re(go=>{"use strict";Object.defineProperty(go,"__esModule",{value:!0});function td(e){return e}go.noJitter=td});var gs=re(ho=>{"use strict";Object.defineProperty(ho,"__esModule",{value:!0});var rd=fs(),nd=ms();function od(e){switch(e.jitter){case"full":return rd.fullJitter;case"none":default:return nd.noJitter}}ho.JitterFactory=od});var So=re(yo=>{"use strict";Object.defineProperty(yo,"__esModule",{value:!0});var id=gs(),sd=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=id.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,n=this.numOfDelayedAttempts,o=t*Math.pow(r,n);return Math.min(o,this.options.maxDelay)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"numOfDelayedAttempts",{get:function(){return this.attempt},enumerable:!0,configurable:!0}),e}();yo.Delay=sd});var hs=re(qe=>{"use strict";var ad=qe&&qe.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,o){n.__proto__=o}||function(n,o){for(var i in o)o.hasOwnProperty(i)&&(n[i]=o[i])},e(t,r)};return function(t,r){e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}(),cd=qe&&qe.__awaiter||function(e,t,r,n){function o(i){return i instanceof r?i:new r(function(s){s(i)})}return new(r||(r=Promise))(function(i,s){function c(d){try{a(n.next(d))}catch(f){s(f)}}function l(d){try{a(n.throw(d))}catch(f){s(f)}}function a(d){d.done?i(d.value):o(d.value).then(c,l)}a((n=n.apply(e,t||[])).next())})},ud=qe&&qe.__generator||function(e,t){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,o,i,s;return s={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function c(a){return function(d){return l([a,d])}}function l(a){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,o&&(i=a[0]&2?o.return:a[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,a[1])).done)return i;switch(o=0,i&&(a=[a[0]&2,i.value]),a[0]){case 0:case 1:i=a;break;case 4:return r.label++,{value:a[1],done:!1};case 5:r.label++,o=a[1],a=[0];continue;case 7:a=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(a[0]===6||a[0]===2)){r=0;continue}if(a[0]===3&&(!i||a[1]>i[0]&&a[1]<i[3])){r.label=a[1];break}if(a[0]===6&&r.label<i[1]){r.label=i[1],i=a;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(a);break}i[2]&&r.ops.pop(),r.trys.pop();continue}a=t.call(e,r)}catch(d){a=[6,d],o=0}finally{n=i=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}};Object.defineProperty(qe,"__esModule",{value:!0});var ld=So(),dd=function(e){ad(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.apply=function(){return cd(this,void 0,void 0,function(){return ud(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}(ld.Delay);qe.SkipFirstDelay=dd});var ys=re(Xt=>{"use strict";var pd=Xt&&Xt.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,o){n.__proto__=o}||function(n,o){for(var i in o)o.hasOwnProperty(i)&&(n[i]=o[i])},e(t,r)};return function(t,r){e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(Xt,"__esModule",{value:!0});var fd=So(),md=function(e){pd(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t}(fd.Delay);Xt.AlwaysDelay=md});var Ss=re(vo=>{"use strict";Object.defineProperty(vo,"__esModule",{value:!0});var gd=hs(),hd=ys();function yd(e,t){var r=Sd(e);return r.setAttemptNumber(t),r}vo.DelayFactory=yd;function Sd(e){return e.delayFirstAttempt?new hd.AlwaysDelay(e):new gd.SkipFirstDelay(e)}});var vs=re(pt=>{"use strict";var Co=pt&&pt.__awaiter||function(e,t,r,n){function o(i){return i instanceof r?i:new r(function(s){s(i)})}return new(r||(r=Promise))(function(i,s){function c(d){try{a(n.next(d))}catch(f){s(f)}}function l(d){try{a(n.throw(d))}catch(f){s(f)}}function a(d){d.done?i(d.value):o(d.value).then(c,l)}a((n=n.apply(e,t||[])).next())})},Ao=pt&&pt.__generator||function(e,t){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,o,i,s;return s={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function c(a){return function(d){return l([a,d])}}function l(a){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,o&&(i=a[0]&2?o.return:a[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,a[1])).done)return i;switch(o=0,i&&(a=[a[0]&2,i.value]),a[0]){case 0:case 1:i=a;break;case 4:return r.label++,{value:a[1],done:!1};case 5:r.label++,o=a[1],a=[0];continue;case 7:a=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(a[0]===6||a[0]===2)){r=0;continue}if(a[0]===3&&(!i||a[1]>i[0]&&a[1]<i[3])){r.label=a[1];break}if(a[0]===6&&r.label<i[1]){r.label=i[1],i=a;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(a);break}i[2]&&r.ops.pop(),r.trys.pop();continue}a=t.call(e,r)}catch(d){a=[6,d],o=0}finally{n=i=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}};Object.defineProperty(pt,"__esModule",{value:!0});var vd=ps(),Cd=Ss();function Ad(e,t){return t===void 0&&(t={}),Co(this,void 0,void 0,function(){var r,n;return Ao(this,function(o){switch(o.label){case 0:return r=vd.getSanitizedOptions(t),n=new bd(e,r),[4,n.execute()];case 1:return[2,o.sent()]}})})}pt.backOff=Ad;var bd=function(){function e(t,r){this.request=t,this.options=r,this.attemptNumber=0}return e.prototype.execute=function(){return Co(this,void 0,void 0,function(){var t,r;return Ao(this,function(n){switch(n.label){case 0:if(this.attemptLimitReached)return[3,7];n.label=1;case 1:return n.trys.push([1,4,,6]),[4,this.applyDelay()];case 2:return n.sent(),[4,this.request()];case 3:return[2,n.sent()];case 4:return t=n.sent(),this.attemptNumber++,[4,this.options.retry(t,this.attemptNumber)];case 5:if(r=n.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 Co(this,void 0,void 0,function(){var t;return Ao(this,function(r){switch(r.label){case 0:return t=Cd.DelayFactory(this.options,this.attemptNumber),[4,t.apply()];case 1:return r.sent(),[2]}})})},e}()});var Fn=re((wi,xi)=>{"use strict";(function(e,t){typeof wi=="object"&&typeof xi<"u"?xi.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs=t()})(wi,function(){"use strict";var e=1e3,t=6e4,r=36e5,n="millisecond",o="second",i="minute",s="hour",c="day",l="week",a="month",d="quarter",f="year",p="date",u="Invalid Date",g=/^(\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,S={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(T){var P=["th","st","nd","rd"],k=T%100;return"["+T+(P[(k-20)%10]||P[k]||P[0])+"]"}},C=function(T,P,k){var M=String(T);return!M||M.length>=P?T:""+Array(P+1-M.length).join(k)+T},m={s:C,z:function(T){var P=-T.utcOffset(),k=Math.abs(P),M=Math.floor(k/60),D=k%60;return(P<=0?"+":"-")+C(M,2,"0")+":"+C(D,2,"0")},m:function T(P,k){if(P.date()<k.date())return-T(k,P);var M=12*(k.year()-P.year())+(k.month()-P.month()),D=P.clone().add(M,a),_=k-D<0,N=P.clone().add(M+(_?-1:1),a);return+(-(M+(k-D)/(_?D-N:N-D))||0)},a:function(T){return T<0?Math.ceil(T)||0:Math.floor(T)},p:function(T){return{M:a,y:f,w:l,d:c,D:p,h:s,m:i,s:o,ms:n,Q:d}[T]||String(T||"").toLowerCase().replace(/s$/,"")},u:function(T){return T===void 0}},y="en",A={};A[y]=S;var E="$isDayjsObject",b=function(T){return T instanceof O||!(!T||!T[E])},v=function T(P,k,M){var D;if(!P)return y;if(typeof P=="string"){var _=P.toLowerCase();A[_]&&(D=_),k&&(A[_]=k,D=_);var N=P.split("-");if(!D&&N.length>1)return T(N[0])}else{var j=P.name;A[j]=P,D=j}return!M&&D&&(y=D),D||!M&&y},I=function(T,P){if(b(T))return T.clone();var k=typeof P=="object"?P:{};return k.date=T,k.args=arguments,new O(k)},x=m;x.l=v,x.i=b,x.w=function(T,P){return I(T,{locale:P.$L,utc:P.$u,x:P.$x,$offset:P.$offset})};var O=function(){function T(k){this.$L=v(k.locale,null,!0),this.parse(k),this.$x=this.$x||k.x||{},this[E]=!0}var P=T.prototype;return P.parse=function(k){this.$d=function(M){var D=M.date,_=M.utc;if(D===null)return new Date(NaN);if(x.u(D))return new Date;if(D instanceof Date)return new Date(D);if(typeof D=="string"&&!/Z$/i.test(D)){var N=D.match(g);if(N){var j=N[2]-1||0,B=(N[7]||"0").substring(0,3);return _?new Date(Date.UTC(N[1],j,N[3]||1,N[4]||0,N[5]||0,N[6]||0,B)):new Date(N[1],j,N[3]||1,N[4]||0,N[5]||0,N[6]||0,B)}}return new Date(D)}(k),this.init()},P.init=function(){var k=this.$d;this.$y=k.getFullYear(),this.$M=k.getMonth(),this.$D=k.getDate(),this.$W=k.getDay(),this.$H=k.getHours(),this.$m=k.getMinutes(),this.$s=k.getSeconds(),this.$ms=k.getMilliseconds()},P.$utils=function(){return x},P.isValid=function(){return this.$d.toString()!==u},P.isSame=function(k,M){var D=I(k);return this.startOf(M)<=D&&D<=this.endOf(M)},P.isAfter=function(k,M){return I(k)<this.startOf(M)},P.isBefore=function(k,M){return this.endOf(M)<I(k)},P.$g=function(k,M,D){return x.u(k)?this[M]:this.set(D,k)},P.unix=function(){return Math.floor(this.valueOf()/1e3)},P.valueOf=function(){return this.$d.getTime()},P.startOf=function(k,M){var D=this,_=!!x.u(M)||M,N=x.p(k),j=function(Ce,Z){var pe=x.w(D.$u?Date.UTC(D.$y,Z,Ce):new Date(D.$y,Z,Ce),D);return _?pe:pe.endOf(c)},B=function(Ce,Z){return x.w(D.toDate()[Ce].apply(D.toDate("s"),(_?[0,0,0,0]:[23,59,59,999]).slice(Z)),D)},$=this.$W,H=this.$M,z=this.$D,G="set"+(this.$u?"UTC":"");switch(N){case f:return _?j(1,0):j(31,11);case a:return _?j(1,H):j(0,H+1);case l:var X=this.$locale().weekStart||0,De=($<X?$+7:$)-X;return j(_?z-De:z+(6-De),H);case c:case p:return B(G+"Hours",0);case s:return B(G+"Minutes",1);case i:return B(G+"Seconds",2);case o:return B(G+"Milliseconds",3);default:return this.clone()}},P.endOf=function(k){return this.startOf(k,!1)},P.$set=function(k,M){var D,_=x.p(k),N="set"+(this.$u?"UTC":""),j=(D={},D[c]=N+"Date",D[p]=N+"Date",D[a]=N+"Month",D[f]=N+"FullYear",D[s]=N+"Hours",D[i]=N+"Minutes",D[o]=N+"Seconds",D[n]=N+"Milliseconds",D)[_],B=_===c?this.$D+(M-this.$W):M;if(_===a||_===f){var $=this.clone().set(p,1);$.$d[j](B),$.init(),this.$d=$.set(p,Math.min(this.$D,$.daysInMonth())).$d}else j&&this.$d[j](B);return this.init(),this},P.set=function(k,M){return this.clone().$set(k,M)},P.get=function(k){return this[x.p(k)]()},P.add=function(k,M){var D,_=this;k=Number(k);var N=x.p(M),j=function(H){var z=I(_);return x.w(z.date(z.date()+Math.round(H*k)),_)};if(N===a)return this.set(a,this.$M+k);if(N===f)return this.set(f,this.$y+k);if(N===c)return j(1);if(N===l)return j(7);var B=(D={},D[i]=t,D[s]=r,D[o]=e,D)[N]||1,$=this.$d.getTime()+k*B;return x.w($,this)},P.subtract=function(k,M){return this.add(-1*k,M)},P.format=function(k){var M=this,D=this.$locale();if(!this.isValid())return D.invalidDate||u;var _=k||"YYYY-MM-DDTHH:mm:ssZ",N=x.z(this),j=this.$H,B=this.$m,$=this.$M,H=D.weekdays,z=D.months,G=D.meridiem,X=function(Z,pe,Me,$e){return Z&&(Z[pe]||Z(M,_))||Me[pe].slice(0,$e)},De=function(Z){return x.s(j%12||12,Z,"0")},Ce=G||function(Z,pe,Me){var $e=Z<12?"AM":"PM";return Me?$e.toLowerCase():$e};return _.replace(h,function(Z,pe){return pe||function(Me){switch(Me){case"YY":return String(M.$y).slice(-2);case"YYYY":return x.s(M.$y,4,"0");case"M":return $+1;case"MM":return x.s($+1,2,"0");case"MMM":return X(D.monthsShort,$,z,3);case"MMMM":return X(z,$);case"D":return M.$D;case"DD":return x.s(M.$D,2,"0");case"d":return String(M.$W);case"dd":return X(D.weekdaysMin,M.$W,H,2);case"ddd":return X(D.weekdaysShort,M.$W,H,3);case"dddd":return H[M.$W];case"H":return String(j);case"HH":return x.s(j,2,"0");case"h":return De(1);case"hh":return De(2);case"a":return Ce(j,B,!0);case"A":return Ce(j,B,!1);case"m":return String(B);case"mm":return x.s(B,2,"0");case"s":return String(M.$s);case"ss":return x.s(M.$s,2,"0");case"SSS":return x.s(M.$ms,3,"0");case"Z":return N}return null}(Z)||N.replace(":","")})},P.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},P.diff=function(k,M,D){var _,N=this,j=x.p(M),B=I(k),$=(B.utcOffset()-this.utcOffset())*t,H=this-B,z=function(){return x.m(N,B)};switch(j){case f:_=z()/12;break;case a:_=z();break;case d:_=z()/3;break;case l:_=(H-$)/6048e5;break;case c:_=(H-$)/864e5;break;case s:_=H/r;break;case i:_=H/t;break;case o:_=H/e;break;default:_=H}return D?_:x.a(_)},P.daysInMonth=function(){return this.endOf(a).$D},P.$locale=function(){return A[this.$L]},P.locale=function(k,M){if(!k)return this.$L;var D=this.clone(),_=v(k,M,!0);return _&&(D.$L=_),D},P.clone=function(){return x.w(this.$d,this)},P.toDate=function(){return new Date(this.valueOf())},P.toJSON=function(){return this.isValid()?this.toISOString():null},P.toISOString=function(){return this.$d.toISOString()},P.toString=function(){return this.$d.toUTCString()},T}(),q=O.prototype;return I.prototype=q,[["$ms",n],["$s",o],["$m",i],["$H",s],["$W",c],["$M",a],["$y",f],["$D",p]].forEach(function(T){q[T[1]]=function(P){return this.$g(P,T[0],T[1])}}),I.extend=function(T,P){return T.$i||(T(P,O,I),T.$i=!0),I},I.locale=v,I.isDayjs=b,I.unix=function(T){return I(1e3*T)},I.en=A[y],I.Ls=A,I.p={},I})});var Nc=re((Ri,Ii)=>{"use strict";(function(e,t){typeof Ri=="object"&&typeof Ii<"u"?Ii.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_quarterOfYear=t()})(Ri,function(){"use strict";var e="month",t="quarter";return function(r,n){var o=n.prototype;o.quarter=function(c){return this.$utils().u(c)?Math.ceil((this.month()+1)/3):this.month(this.month()%3+3*(c-1))};var i=o.add;o.add=function(c,l){return c=Number(c),this.$utils().p(l)===t?this.add(3*c,e):i.bind(this)(c,l)};var s=o.startOf;o.startOf=function(c,l){var a=this.$utils(),d=!!a.u(l)||l;if(a.p(c)===t){var f=this.quarter()-1;return d?this.month(3*f).startOf(e).startOf("day"):this.month(3*f+2).endOf(e).endOf("day")}return s.bind(this)(c,l)}}})});var _c=re((Ei,ki)=>{"use strict";(function(e,t){typeof Ei=="object"&&typeof ki<"u"?ki.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_customParseFormat=t()})(Ei,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|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,r=/\d\d/,n=/\d\d?/,o=/\d*[^-_:/,()\s\d]+/,i={},s=function(u){return(u=+u)+(u>68?1900:2e3)},c=function(u){return function(g){this[u]=+g}},l=[/[+-]\d\d:?(\d\d)?|Z/,function(u){(this.zone||(this.zone={})).offset=function(g){if(!g||g==="Z")return 0;var h=g.match(/([+-]|\d\d)/g),S=60*h[1]+(+h[2]||0);return S===0?0:h[0]==="+"?-S:S}(u)}],a=function(u){var g=i[u];return g&&(g.indexOf?g:g.s.concat(g.f))},d=function(u,g){var h,S=i.meridiem;if(S){for(var C=1;C<=24;C+=1)if(u.indexOf(S(C,0,g))>-1){h=C>12;break}}else h=u===(g?"pm":"PM");return h},f={A:[o,function(u){this.afternoon=d(u,!1)}],a:[o,function(u){this.afternoon=d(u,!0)}],S:[/\d/,function(u){this.milliseconds=100*+u}],SS:[r,function(u){this.milliseconds=10*+u}],SSS:[/\d{3}/,function(u){this.milliseconds=+u}],s:[n,c("seconds")],ss:[n,c("seconds")],m:[n,c("minutes")],mm:[n,c("minutes")],H:[n,c("hours")],h:[n,c("hours")],HH:[n,c("hours")],hh:[n,c("hours")],D:[n,c("day")],DD:[r,c("day")],Do:[o,function(u){var g=i.ordinal,h=u.match(/\d+/);if(this.day=h[0],g)for(var S=1;S<=31;S+=1)g(S).replace(/\[|\]/g,"")===u&&(this.day=S)}],M:[n,c("month")],MM:[r,c("month")],MMM:[o,function(u){var g=a("months"),h=(a("monthsShort")||g.map(function(S){return S.slice(0,3)})).indexOf(u)+1;if(h<1)throw new Error;this.month=h%12||h}],MMMM:[o,function(u){var g=a("months").indexOf(u)+1;if(g<1)throw new Error;this.month=g%12||g}],Y:[/[+-]?\d+/,c("year")],YY:[r,function(u){this.year=s(u)}],YYYY:[/\d{4}/,c("year")],Z:l,ZZ:l};function p(u){var g,h;g=u,h=i&&i.formats;for(var S=(u=g.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(v,I,x){var O=x&&x.toUpperCase();return I||h[x]||e[x]||h[O].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(q,T,P){return T||P.slice(1)})})).match(t),C=S.length,m=0;m<C;m+=1){var y=S[m],A=f[y],E=A&&A[0],b=A&&A[1];S[m]=b?{regex:E,parser:b}:y.replace(/^\[|\]$/g,"")}return function(v){for(var I={},x=0,O=0;x<C;x+=1){var q=S[x];if(typeof q=="string")O+=q.length;else{var T=q.regex,P=q.parser,k=v.slice(O),M=T.exec(k)[0];P.call(I,M),v=v.replace(M,"")}}return function(D){var _=D.afternoon;if(_!==void 0){var N=D.hours;_?N<12&&(D.hours+=12):N===12&&(D.hours=0),delete D.afternoon}}(I),I}}return function(u,g,h){h.p.customParseFormat=!0,u&&u.parseTwoDigitYear&&(s=u.parseTwoDigitYear);var S=g.prototype,C=S.parse;S.parse=function(m){var y=m.date,A=m.utc,E=m.args;this.$u=A;var b=E[1];if(typeof b=="string"){var v=E[2]===!0,I=E[3]===!0,x=v||I,O=E[2];I&&(O=E[2]),i=this.$locale(),!v&&O&&(i=h.Ls[O]),this.$d=function(k,M,D){try{if(["x","X"].indexOf(M)>-1)return new Date((M==="X"?1e3:1)*k);var _=p(M)(k),N=_.year,j=_.month,B=_.day,$=_.hours,H=_.minutes,z=_.seconds,G=_.milliseconds,X=_.zone,De=new Date,Ce=B||(N||j?1:De.getDate()),Z=N||De.getFullYear(),pe=0;N&&!j||(pe=j>0?j-1:De.getMonth());var Me=$||0,$e=H||0,lo=z||0,po=G||0;return X?new Date(Date.UTC(Z,pe,Ce,Me,$e,lo,po+60*X.offset*1e3)):D?new Date(Date.UTC(Z,pe,Ce,Me,$e,lo,po)):new Date(Z,pe,Ce,Me,$e,lo,po)}catch{return new Date("")}}(y,b,A),this.init(),O&&O!==!0&&(this.$L=this.locale(O).$L),x&&y!=this.format(b)&&(this.$d=new Date("")),i={}}else if(b instanceof Array)for(var q=b.length,T=1;T<=q;T+=1){E[1]=b[T-1];var P=h.apply(this,E);if(P.isValid()){this.$d=P.$d,this.$L=P.$L,this.init();break}T===q&&(this.$d=new Date(""))}else C.call(this,m)}}})});var Cu=re((Wx,vu)=>{"use strict";var Th=/(^|; )Coveo-Pendragon=([^;]*)/;vu.exports=()=>Th.exec(document.cookie)?.pop()||null});var bu=re((Qi,$i)=>{"use strict";(function(e,t){typeof Qi=="object"&&typeof $i<"u"?$i.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_timezone=t()})(Qi,function(){"use strict";var e={year:0,month:1,day:2,hour:3,minute:4,second:5},t={};return function(r,n,o){var i,s=function(d,f,p){p===void 0&&(p={});var u=new Date(d),g=function(h,S){S===void 0&&(S={});var C=S.timeZoneName||"short",m=h+"|"+C,y=t[m];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:C}),t[m]=y),y}(f,p);return g.formatToParts(u)},c=function(d,f){for(var p=s(d,f),u=[],g=0;g<p.length;g+=1){var h=p[g],S=h.type,C=h.value,m=e[S];m>=0&&(u[m]=parseInt(C,10))}var y=u[3],A=y===24?0:y,E=u[0]+"-"+u[1]+"-"+u[2]+" "+A+":"+u[4]+":"+u[5]+":000",b=+d;return(o.utc(E).valueOf()-(b-=b%1e3))/6e4},l=n.prototype;l.tz=function(d,f){d===void 0&&(d=i);var p,u=this.utcOffset(),g=this.toDate(),h=g.toLocaleString("en-US",{timeZone:d}),S=Math.round((g-new Date(h))/1e3/60),C=15*-Math.round(g.getTimezoneOffset()/15)-S;if(!Number(C))p=this.utcOffset(0,f);else if(p=o(h,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(C,!0),f){var m=p.utcOffset();p=p.add(u-m,"minute")}return p.$x.$timezone=d,p},l.offsetName=function(d){var f=this.$x.$timezone||o.tz.guess(),p=s(this.valueOf(),f,{timeZoneName:d}).find(function(u){return u.type.toLowerCase()==="timezonename"});return p&&p.value};var a=l.startOf;l.startOf=function(d,f){if(!this.$x||!this.$x.$timezone)return a.call(this,d,f);var p=o(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return a.call(p,d,f).tz(this.$x.$timezone,!0)},o.tz=function(d,f,p){var u=p&&f,g=p||f||i,h=c(+o(),g);if(typeof d!="string")return o(d).tz(g);var S=function(A,E,b){var v=A-60*E*1e3,I=c(v,b);if(E===I)return[v,E];var x=c(v-=60*(I-E)*1e3,b);return I===x?[v,I]:[A-60*Math.min(I,x)*1e3,Math.max(I,x)]}(o.utc(d,u).valueOf(),h,g),C=S[0],m=S[1],y=o(C).utcOffset(m);return y.$x.$timezone=g,y},o.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},o.tz.setDefault=function(d){i=d}}})});var wu=re((Hi,zi)=>{"use strict";(function(e,t){typeof Hi=="object"&&typeof zi<"u"?zi.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_utc=t()})(Hi,function(){"use strict";var e="minute",t=/[+-]\d\d(?::?\d\d)?/g,r=/([+-]|\d\d)/g;return function(n,o,i){var s=o.prototype;i.utc=function(u){var g={date:u,utc:!0,args:arguments};return new o(g)},s.utc=function(u){var g=i(this.toDate(),{locale:this.$L,utc:!0});return u?g.add(this.utcOffset(),e):g},s.local=function(){return i(this.toDate(),{locale:this.$L,utc:!1})};var c=s.parse;s.parse=function(u){u.utc&&(this.$u=!0),this.$utils().u(u.$offset)||(this.$offset=u.$offset),c.call(this,u)};var l=s.init;s.init=function(){if(this.$u){var u=this.$d;this.$y=u.getUTCFullYear(),this.$M=u.getUTCMonth(),this.$D=u.getUTCDate(),this.$W=u.getUTCDay(),this.$H=u.getUTCHours(),this.$m=u.getUTCMinutes(),this.$s=u.getUTCSeconds(),this.$ms=u.getUTCMilliseconds()}else l.call(this)};var a=s.utcOffset;s.utcOffset=function(u,g){var h=this.$utils().u;if(h(u))return this.$u?0:h(this.$offset)?a.call(this):this.$offset;if(typeof u=="string"&&(u=function(y){y===void 0&&(y="");var A=y.match(t);if(!A)return null;var E=(""+A[0]).match(r)||["-",0,0],b=E[0],v=60*+E[1]+ +E[2];return v===0?0:b==="+"?v:-v}(u),u===null))return this;var S=Math.abs(u)<=16?60*u:u,C=this;if(g)return C.$offset=S,C.$u=u===0,C;if(u!==0){var m=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(C=this.local().add(S+m,e)).$offset=S,C.$x.$localOffset=m}else C=this.utc();return C};var d=s.format;s.format=function(u){var g=u||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return d.call(this,g)},s.valueOf=function(){var u=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*u},s.isUTC=function(){return!!this.$u},s.toISOString=function(){return this.toDate().toISOString()},s.toString=function(){return this.toDate().toUTCString()};var f=s.toDate;s.toDate=function(u){return u==="s"&&this.$offset?i(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():f.call(this)};var p=s.diff;s.diff=function(u,g,h){if(u&&this.$u===u.$u)return p.call(this,u,g,h);var S=this.local(),C=i(u).local();return p.call(S,C,g,h)}}})});var _u=re((nI,Nu)=>{"use strict";function Bh(e){try{return JSON.stringify(e)}catch{return'"[Circular]"'}}Nu.exports=Qh;function Qh(e,t,r){var n=r&&r.stringify||Bh,o=1;if(typeof e=="object"&&e!==null){var i=t.length+o;if(i===1)return e;var s=new Array(i);s[0]=n(e);for(var c=1;c<i;c++)s[c]=n(t[c]);return s.join(" ")}if(typeof e!="string")return e;var l=t.length;if(l===0)return e;for(var a="",d=1-o,f=-1,p=e&&e.length||0,u=0;u<p;){if(e.charCodeAt(u)===37&&u+1<p){switch(f=f>-1?f:0,e.charCodeAt(u+1)){case 100:case 102:if(d>=l||t[d]==null)break;f<u&&(a+=e.slice(f,u)),a+=Number(t[d]),f=u+2,u++;break;case 105:if(d>=l||t[d]==null)break;f<u&&(a+=e.slice(f,u)),a+=Math.floor(Number(t[d])),f=u+2,u++;break;case 79:case 111:case 106:if(d>=l||t[d]===void 0)break;f<u&&(a+=e.slice(f,u));var g=typeof t[d];if(g==="string"){a+="'"+t[d]+"'",f=u+2,u++;break}if(g==="function"){a+=t[d].name||"<anonymous>",f=u+2,u++;break}a+=n(t[d]),f=u+2,u++;break;case 115:if(d>=l)break;f<u&&(a+=e.slice(f,u)),a+=String(t[d]),f=u+2,u++;break;case 37:f<u&&(a+=e.slice(f,u)),a+="%",f=u+2,u++,d--;break}++d}++u}return f===-1?e:(f<p&&(a+=e.slice(f)),a)}});var Qu=re((oI,Vn)=>{"use strict";var Lu=_u();Vn.exports=Ve;var kr=oy().console||{},$h={mapHttpRequest:Un,mapHttpResponse:Un,wrapRequestSerializer:Yi,wrapResponseSerializer:Yi,wrapErrorSerializer:Yi,req:Un,res:Un,err:Uu,errWithCause:Uu};function nt(e,t){return e==="silent"?1/0:t.levels.values[e]}var Zi=Symbol("pino.logFuncs"),Ji=Symbol("pino.hierarchy"),Hh={error:"log",fatal:"error",warn:"error",info:"log",debug:"log",trace:"log"};function ju(e,t){let r={logger:t,parent:e[Ji]};t[Ji]=r}function zh(e,t,r){let n={};t.forEach(o=>{n[o]=r[o]?r[o]:kr[o]||kr[Hh[o]||"log"]||Ht}),e[Zi]=n}function Gh(e,t){return Array.isArray(e)?e.filter(function(n){return n!=="!stdSerializers.err"}):e===!0?Object.keys(t):!1}function Ve(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||kr;e.browser.write&&(e.browser.asObject=!0);let n=e.serializers||{},o=Gh(e.browser.serialize,n),i=e.browser.serialize;Array.isArray(e.browser.serialize)&&e.browser.serialize.indexOf("!stdSerializers.err")>-1&&(i=!1);let s=Object.keys(e.customLevels||{}),c=["error","fatal","warn","info","debug","trace"].concat(s);typeof r=="function"&&c.forEach(function(h){r[h]=r}),(e.enabled===!1||e.browser.disabled)&&(e.level="silent");let l=e.level||"info",a=Object.create(r);a.log||(a.log=Ht),zh(a,c,r),ju({},a),Object.defineProperty(a,"levelVal",{get:f}),Object.defineProperty(a,"level",{get:p,set:u});let d={transmit:t,serialize:o,asObject:e.browser.asObject,formatters:e.browser.formatters,levels:c,timestamp:ty(e),messageKey:e.messageKey||"msg",onChild:e.onChild||Ht};a.levels=Wh(e),a.level=l,a.setMaxListeners=a.getMaxListeners=a.emit=a.addListener=a.on=a.prependListener=a.once=a.prependOnceListener=a.removeListener=a.removeAllListeners=a.listeners=a.listenerCount=a.eventNames=a.write=a.flush=Ht,a.serializers=n,a._serialize=o,a._stdErrSerialize=i,a.child=function(...h){return g.call(this,d,...h)},t&&(a._logEvent=Xi());function f(){return nt(this.level,this)}function p(){return this._level}function u(h){if(h!=="silent"&&!this.levels.values[h])throw Error("unknown level "+h);this._level=h,At(this,d,a,"error"),At(this,d,a,"fatal"),At(this,d,a,"warn"),At(this,d,a,"info"),At(this,d,a,"debug"),At(this,d,a,"trace"),s.forEach(S=>{At(this,d,a,S)})}function g(h,S,C){if(!S)throw new Error("missing bindings for child Pino");C=C||{},o&&S.serializers&&(C.serializers=S.serializers);let m=C.serializers;if(o&&m){var y=Object.assign({},n,m),A=e.browser.serialize===!0?Object.keys(y):o;delete S.serializers,es([S],A,y,this._stdErrSerialize)}function E(v){this._childLevel=(v._childLevel|0)+1,this.bindings=S,y&&(this.serializers=y,this._serialize=A),t&&(this._logEvent=Xi([].concat(v._logEvent.bindings,S)))}E.prototype=this;let b=new E(this);return ju(this,b),b.child=function(...v){return g.call(this,h,...v)},b.level=C.level||this.level,h.onChild(b),b}return a}function Wh(e){let t=e.customLevels||{},r=Object.assign({},Ve.levels.values,t),n=Object.assign({},Ve.levels.labels,Kh(t));return{values:r,labels:n}}function Kh(e){let t={};return Object.keys(e).forEach(function(r){t[e[r]]=r}),t}Ve.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"}};Ve.stdSerializers=$h;Ve.stdTimeFunctions=Object.assign({},{nullTime:Vu,epochTime:Bu,unixTime:ry,isoTime:ny});function Yh(e){let t=[];e.bindings&&t.push(e.bindings);let r=e[Ji];for(;r.parent;)r=r.parent,r.logger.bindings&&t.push(r.logger.bindings);return t.reverse()}function At(e,t,r,n){if(Object.defineProperty(e,n,{value:nt(e.level,r)>nt(n,r)?Ht:r[Zi][n],writable:!0,enumerable:!0,configurable:!0}),e[n]===Ht){if(!t.transmit)return;let i=t.transmit.level||e.level,s=nt(i,r);if(nt(n,r)<s)return}e[n]=Xh(e,t,r,n);let o=Yh(e);o.length!==0&&(e[n]=Jh(o,e[n]))}function Jh(e,t){return function(){return t.apply(this,[...e,...arguments])}}function Xh(e,t,r,n){return function(o){return function(){let s=t.timestamp(),c=new Array(arguments.length),l=Object.getPrototypeOf&&Object.getPrototypeOf(this)===kr?kr:this;for(var a=0;a<c.length;a++)c[a]=arguments[a];var d=!1;if(t.serialize&&(es(c,this._serialize,this.serializers,this._stdErrSerialize),d=!0),t.asObject||t.formatters?o.call(l,Zh(this,n,c,s,t)):o.apply(l,c),t.transmit){let f=t.transmit.level||e._level,p=nt(f,r),u=nt(n,r);if(u<p)return;ey(this,{ts:s,methodLevel:n,methodValue:u,transmitLevel:f,transmitValue:r.levels.values[t.transmit.level||e._level],send:t.transmit.send,val:nt(e._level,r)},c,d)}}}(e[Zi][n])}function Zh(e,t,r,n,o){let{level:i,log:s=p=>p}=o.formatters||{},c=r.slice(),l=c[0],a={};if(n&&(a.time=n),i){let p=i(t,e.levels.values[t]);Object.assign(a,p)}else a.level=e.levels.values[t];let d=(e._childLevel|0)+1;if(d<1&&(d=1),l!==null&&typeof l=="object"){for(;d--&&typeof c[0]=="object";)Object.assign(a,c.shift());l=c.length?Lu(c.shift(),c):void 0}else typeof l=="string"&&(l=Lu(c.shift(),c));return l!==void 0&&(a[o.messageKey]=l),s(a)}function es(e,t,r,n){for(let o in e)if(n&&e[o]instanceof Error)e[o]=Ve.stdSerializers.err(e[o]);else if(typeof e[o]=="object"&&!Array.isArray(e[o])&&t)for(let i in e[o])t.indexOf(i)>-1&&i in r&&(e[o][i]=r[i](e[o][i]))}function ey(e,t,r,n=!1){let o=t.send,i=t.ts,s=t.methodLevel,c=t.methodValue,l=t.val,a=e._logEvent.bindings;n||es(r,e._serialize||Object.keys(e.serializers),e.serializers,e._stdErrSerialize===void 0?!0:e._stdErrSerialize),e._logEvent.ts=i,e._logEvent.messages=r.filter(function(d){return a.indexOf(d)===-1}),e._logEvent.level.label=s,e._logEvent.level.value=c,o(s,e._logEvent,l),e._logEvent=Xi(a)}function Xi(e){return{ts:0,messages:[],bindings:e||[],level:{label:"",value:0}}}function Uu(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 ty(e){return typeof e.timestamp=="function"?e.timestamp:e.timestamp===!1?Vu:Bu}function Un(){return{}}function Yi(e){return e}function Ht(){}function Vu(){return!1}function Bu(){return Date.now()}function ry(){return Math.round(Date.now()/1e3)}function ny(){return new Date(Date.now()).toISOString()}function oy(){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)||{}}}Vn.exports.default=Ve;Vn.exports.pino=Ve});import{isNullOrUndefined as ly}from"@coveo/bueno";var Tr=e=>e;var Es=Re(vs(),1);var wd="recommendation-internal-options",OS=Symbol.for(wd);var ye=new Error("Failed to load reducers."),xt=class extends Error{constructor(){super(),this.name="ExpiredToken",this.message="The token being used to perform the request is expired."}};var ft=class extends Error{constructor(r,n){super();ee(this,"statusCode");this.name="Disconnected",this.message=`Client could not connect to the following URL: ${r}`,this.statusCode=n??0}};function Cs(e){return Array.isArray(e)}function As(e,t){return[...e.reduce((r,n)=>{let o=t(n);return r.has(o)||r.set(o,n),r},new Map).values()]}var xd=new Set(["1",1,"yes",!0]);function bs(){if(typeof navigator>"u"||typeof window>"u")return!1;let e=navigator,t=window;return[e.globalPrivacyControl,e.doNotTrack,e.msDoNotTrack,t.doNotTrack].some(r=>xd.has(r))}function ws(e){let t={};for(let[r,n]of e)t[r]=n;return t}function Zt(e){if(typeof e!="object"||!e)return e;try{return JSON.parse(JSON.stringify(e))}catch{return e}}function xs(e){let t=[];for(let r in e){let n=encodeURIComponent(r),o=encodeURIComponent(e[r]);t.push(`${n}=${o}`)}return t.join("&")}function Rs(e){return typeof e!="object"||!e?!1:Object.values(e).every(Rd)}function Rd(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"}function Is(e){return e===429}var He=class e{static async call(t){let r=Id(t),{logger:n}=t,o=await e.preprocessRequest(r,t);n.info(o,"Platform request");let{url:i,...s}=o,c=async()=>{let l=await fetch(i,s);if(Is(l.status))throw l;return l};try{let l=await(0,Es.backOff)(c,{retry:a=>{let d=a&&Is(a.status);return d&&n.info("Platform retrying request"),d}});switch(l.status){case 419:case 401:throw n.info("Platform renewing token"),new xt;case 404:throw new ft(i,l.status);default:return n.info({response:l,requestInfo:o},"Platform response"),l}}catch(l){return l.message==="Failed to fetch"?new ft(i):l}}static async preprocessRequest(t,r){let{origin:n,preprocessRequest:o,logger:i,requestMetadata:s}=r,{signal:c,...l}=t,a=Zt(l);try{let d=await o(t,n,s);return{...t,...d}}catch(d){i.error(d,"Platform request preprocessing failed. Returning default request options.")}return a}};function te(e,t="prod",r="platform"){let n=t==="prod"?"":t,o=r==="platform"?"":`.${r}`;return`https://${e}${o}.org${n}.coveo.com`}function Rt(e,t="prod"){return`${te(e,t)}/rest/search/v2`}function bo(e,t="prod"){return`${te(e,t,"analytics")}/rest/organizations/${e}/events/v1`}function Id(e){let{url:t,method:r,requestParams:n,contentType:o,accessToken:i,signal:s}=e,c=e.method==="POST"||e.method==="PUT",l=Ed(n,o);return{url:t,method:r,headers:{"Content-Type":o,Authorization:`Bearer ${i}`,...e.headers},...c&&{body:l},signal:s}}function Ed(e,t){return t==="application/x-www-form-urlencoded"?Rs(e)?xs(e):"":JSON.stringify(e)}var It=class{constructor(t){ee(this,"_basePath");ee(this,"_params",{});this._basePath=t}addParam(t,r){this._params={...this.params,[t]:r}}get basePath(){return this._basePath}get params(){return this._params}get hasParams(){return Object.entries(this._params).length}get href(){return this.hasParams?`${this.basePath}?${Object.entries(this.params).map(([t,r])=>`${t}=${encodeURIComponent(r)}`).join("&")}`:this.basePath}};function wo(e){let{url:t,accessToken:r,organizationId:n,authentication:o,...i}=e;return i}var xo=e=>{let{response:t}=e;return t.body?kd(e):Pd(t)},kd=e=>Od(e)?Fd(e):Td(e)?e.body:{message:"unknown",statusCode:0,type:"unknown"},Pd=e=>{let t=JSON.parse(JSON.stringify(e,Object.getOwnPropertyNames(e)));return{...t,message:`Client side error: ${t.message||""}`,statusCode:400,type:"ClientError"}};function Td(e){return e.body.statusCode!==void 0}function Od(e){return e.body.exception!==void 0}var Fd=e=>({message:e.body.exception.code,statusCode:e.response.status,type:e.body.exception.code});function ks(e){return((e.headers.get("content-type")||"").split(";").find(n=>n.indexOf("charset=")!==-1)||"").split("=")[1]||"UTF-8"}var Ro=(e,t,r,n)=>{let o=new It(`${e.url}${n}`);return o.addParam("organizationId",e.organizationId),e.authentication&&o.addParam("authentication",e.authentication),{accessToken:e.accessToken,method:t,contentType:r,url:o.href,origin:"searchApiFetch"}};var Ps=(e,t)=>{let r=new It(`${e.url}${t}`);return r.addParam("access_token",e.accessToken),r.addParam("organizationId",e.organizationId),r.addParam("uniqueId",e.uniqueId),e.q!==void 0&&r.addParam("q",e.q),e.enableNavigation!==void 0&&r.addParam("enableNavigation",`${e.enableNavigation}`),e.requestedOutputSize!==void 0&&r.addParam("requestedOutputSize",`${e.requestedOutputSize}`),r.href},Io=async(e,t)=>{let r=await He.call({...Ro(e,"POST","application/x-www-form-urlencoded","/html"),requestParams:wo(e),requestMetadata:{method:"html"},...t});if(r instanceof Error)throw r;let n=ks(r),o=await r.arrayBuffer(),s=new TextDecoder(n).decode(o);return Dd(s)?{success:s}:{error:xo({response:r,body:s})}};function Dd(e){return typeof e=="string"}function Md(e){return{statusCode:e.statusCode,type:e.name,message:e.message}}function qd(e){return{statusCode:e.code,type:e.name,message:e.message,ignored:!0}}function Fr(e,t){if(t&&e.name==="AbortError")return{error:qd(e)};if(e instanceof ft)return{error:Md(e)};throw e}var Dr=(e,t,r,n,o={})=>{Nd(e);let i=`${e.url}/rest/organizations/${e.organizationId}/caseassists/${e.caseAssistId}${n}`,s=_d(o),c=s?`${i}?${s}`:i;return{accessToken:e.accessToken,method:t,contentType:r,url:c,origin:"caseAssistApiFetch"}},Mr=e=>Object.keys(e).filter(t=>e[t].value!=="").reduce((t,r)=>({...t,[r]:e[r]}),{}),qr=e=>Object.keys(e).filter(t=>e[t].value!=="").reduce((t,r)=>({...t,[r]:e[r].value}),{}),Nd=e=>{if(!e.url)throw new Error("The 'url' attribute must contain a valid platform URL.");if(!e.organizationId)throw new Error("The 'organizationId' attribute must contain a valid organization ID.");if(!e.accessToken)throw new Error("The 'accessToken' attribute must contain a valid platform access token.");if(!e.caseAssistId)throw new Error("The 'caseAssistId' attribute must contain a valid Case Assist configuration ID.")},_d=e=>Object.keys(e).map(t=>`${t}=${encodeURIComponent(e[t])}`).join("&");var Ts=e=>{let t=e.debug?{debug:"1"}:{};return{...Dr(e,"POST","application/json","/classify",t),requestParams:Ld(e)}},Ld=e=>({clientId:e.clientId,locale:e.locale,fields:Mr(e.fields)});var Os=e=>{let t={};return e.debug&&(t.debug="1"),e.numberOfResults&&(t.numberOfResults=e.numberOfResults.toString()),{...Dr(e,"POST","application/json","/documents/suggest",t),requestParams:jd(e)}},jd=e=>({clientId:e.clientId,locale:e.locale,fields:Mr(e.fields),context:e.context});var Nr=class{constructor(t){this.options=t}async getCaseClassifications(t){let r=await He.call({...Ts(t),...this.options});if(r instanceof Error)return Fr(r);let n=await r.json();return r.ok?{success:n}:{error:n}}async getDocumentSuggestions(t){let r=await He.call({...Os(t),...this.options});if(r instanceof Error)return Fr(r);let n=await r.json();return r.ok?{success:n}:{error:n}}async html(t){return Io(t,this.options)}};import{StringValue as qp}from"@coveo/bueno";function ne(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 Ud=typeof Symbol=="function"&&Symbol.observable||"@@observable",Fs=Ud,Eo=()=>Math.random().toString(36).substring(7).split("").join("."),Vd={INIT:`@@redux/INIT${Eo()}`,REPLACE:`@@redux/REPLACE${Eo()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${Eo()}`},_r=Vd;function Ie(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 ko(e,t,r){if(typeof e!="function")throw new Error(ne(2));if(typeof t=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(ne(0));if(typeof t=="function"&&typeof r>"u"&&(r=t,t=void 0),typeof r<"u"){if(typeof r!="function")throw new Error(ne(1));return r(ko)(e,t)}let n=e,o=t,i=new Map,s=i,c=0,l=!1;function a(){s===i&&(s=new Map,i.forEach((S,C)=>{s.set(C,S)}))}function d(){if(l)throw new Error(ne(3));return o}function f(S){if(typeof S!="function")throw new Error(ne(4));if(l)throw new Error(ne(5));let C=!0;a();let m=c++;return s.set(m,S),function(){if(C){if(l)throw new Error(ne(6));C=!1,a(),s.delete(m),i=null}}}function p(S){if(!Ie(S))throw new Error(ne(7));if(typeof S.type>"u")throw new Error(ne(8));if(typeof S.type!="string")throw new Error(ne(17));if(l)throw new Error(ne(9));try{l=!0,o=n(o,S)}finally{l=!1}return(i=s).forEach(m=>{m()}),S}function u(S){if(typeof S!="function")throw new Error(ne(10));n=S,p({type:_r.REPLACE})}function g(){let S=f;return{subscribe(C){if(typeof C!="object"||C===null)throw new Error(ne(11));function m(){let A=C;A.next&&A.next(d())}return m(),{unsubscribe:S(m)}},[Fs](){return this}}}return p({type:_r.INIT}),{dispatch:p,subscribe:f,getState:d,replaceReducer:u,[Fs]:g}}function Bd(e){Object.keys(e).forEach(t=>{let r=e[t];if(typeof r(void 0,{type:_r.INIT})>"u")throw new Error(ne(12));if(typeof r(void 0,{type:_r.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(ne(13))})}function Et(e){let t=Object.keys(e),r={};for(let s=0;s<t.length;s++){let c=t[s];typeof e[c]=="function"&&(r[c]=e[c])}let n=Object.keys(r),o,i;try{Bd(r)}catch(s){i=s}return function(c={},l){if(i)throw i;let a=!1,d={};for(let f=0;f<n.length;f++){let p=n[f],u=r[p],g=c[p],h=u(g,l);if(typeof h>"u"){let S=l&&l.type;throw new Error(ne(14))}d[p]=h,a=a||h!==g}return a=a||n.length!==Object.keys(c).length,a?d:c}}function kt(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,r)=>(...n)=>t(r(...n)))}function Ds(...e){return t=>(r,n)=>{let o=t(r,n),i=()=>{throw new Error(ne(15))},s={getState:o.getState,dispatch:(l,...a)=>i(l,...a)},c=e.map(l=>l(s));return i=kt(...c)(o.dispatch),{...o,dispatch:i}}}function Lr(e){return Ie(e)&&"type"in e&&typeof e.type=="string"}var Lo=Symbol.for("immer-nothing"),er=Symbol.for("immer-draftable"),ce=Symbol.for("immer-state");function oe(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var gt=Object.getPrototypeOf;function fe(e){return!!e&&!!e[ce]}function ue(e){return e?Ls(e)||Array.isArray(e)||!!e[er]||!!e.constructor?.[er]||ir(e)||sr(e):!1}var Qd=Object.prototype.constructor.toString();function Ls(e){if(!e||typeof e!="object")return!1;let t=gt(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)===Qd}function jo(e){return fe(e)||oe(15,e),e[ce].base_}function tr(e,t){ht(e)===0?Reflect.ownKeys(e).forEach(r=>{t(r,e[r],e)}):e.forEach((r,n)=>t(n,r,e))}function ht(e){let t=e[ce];return t?t.type_:Array.isArray(e)?1:ir(e)?2:sr(e)?3:0}function rr(e,t){return ht(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Po(e,t){return ht(e)===2?e.get(t):e[t]}function js(e,t,r){let n=ht(e);n===2?e.set(t,r):n===3?e.add(r):e[t]=r}function $d(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function ir(e){return e instanceof Map}function sr(e){return e instanceof Set}function mt(e){return e.copy_||e.base_}function Fo(e,t){if(ir(e))return new Map(e);if(sr(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);let r=Ls(e);if(t===!0||t==="class_only"&&!r){let n=Object.getOwnPropertyDescriptors(e);delete n[ce];let o=Reflect.ownKeys(n);for(let i=0;i<o.length;i++){let s=o[i],c=n[s];c.writable===!1&&(c.writable=!0,c.configurable=!0),(c.get||c.set)&&(n[s]={configurable:!0,writable:!0,enumerable:c.enumerable,value:e[s]})}return Object.create(gt(e),n)}else{let n=gt(e);if(n!==null&&r)return{...e};let o=Object.create(n);return Object.assign(o,e)}}function Vr(e,t=!1){return Br(e)||fe(e)||!ue(e)||(ht(e)>1&&(e.set=e.add=e.clear=e.delete=Hd),Object.freeze(e),t&&Object.entries(e).forEach(([r,n])=>Vr(n,!0))),e}function Hd(){oe(2)}function Br(e){return Object.isFrozen(e)}var Do={};function yt(e){let t=Do[e];return t||oe(0,e),t}function zd(e,t){Do[e]||(Do[e]=t)}var nr;function Us(){return nr}function Gd(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function Ms(e,t){t&&(yt("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Mo(e){qo(e),e.drafts_.forEach(Wd),e.drafts_=null}function qo(e){e===nr&&(nr=e.parent_)}function qs(e){return nr=Gd(nr,e)}function Wd(e){let t=e[ce];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function Ns(e,t){t.unfinalizedDrafts_=t.drafts_.length;let r=t.drafts_[0];return e!==void 0&&e!==r?(r[ce].modified_&&(Mo(t),oe(4)),ue(e)&&(e=jr(t,e),t.parent_||Ur(t,e)),t.patches_&&yt("Patches").generateReplacementPatches_(r[ce].base_,e,t.patches_,t.inversePatches_)):e=jr(t,r,[]),Mo(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==Lo?e:void 0}function jr(e,t,r){if(Br(t))return t;let n=t[ce];if(!n)return tr(t,(o,i)=>_s(e,n,t,o,i,r)),t;if(n.scope_!==e)return t;if(!n.modified_)return Ur(e,n.base_,!0),n.base_;if(!n.finalized_){n.finalized_=!0,n.scope_.unfinalizedDrafts_--;let o=n.copy_,i=o,s=!1;n.type_===3&&(i=new Set(o),o.clear(),s=!0),tr(i,(c,l)=>_s(e,n,o,c,l,r,s)),Ur(e,o,!1),r&&e.patches_&&yt("Patches").generatePatches_(n,r,e.patches_,e.inversePatches_)}return n.copy_}function _s(e,t,r,n,o,i,s){if(fe(o)){let c=i&&t&&t.type_!==3&&!rr(t.assigned_,n)?i.concat(n):void 0,l=jr(e,o,c);if(js(r,n,l),fe(l))e.canAutoFreeze_=!1;else return}else s&&r.add(o);if(ue(o)&&!Br(o)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;jr(e,o),(!t||!t.scope_.parent_)&&typeof n!="symbol"&&Object.prototype.propertyIsEnumerable.call(r,n)&&Ur(e,o)}}function Ur(e,t,r=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Vr(t,r)}function Kd(e,t){let r=Array.isArray(e),n={type_:r?1:0,scope_:t?t.scope_:Us(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1},o=n,i=Uo;r&&(o=[n],i=or);let{revoke:s,proxy:c}=Proxy.revocable(o,i);return n.draft_=c,n.revoke_=s,c}var Uo={get(e,t){if(t===ce)return e;let r=mt(e);if(!rr(r,t))return Yd(e,r,t);let n=r[t];return e.finalized_||!ue(n)?n:n===To(e.base_,t)?(Oo(e),e.copy_[t]=_o(n,e)):n},has(e,t){return t in mt(e)},ownKeys(e){return Reflect.ownKeys(mt(e))},set(e,t,r){let n=Vs(mt(e),t);if(n?.set)return n.set.call(e.draft_,r),!0;if(!e.modified_){let o=To(mt(e),t),i=o?.[ce];if(i&&i.base_===r)return e.copy_[t]=r,e.assigned_[t]=!1,!0;if($d(r,o)&&(r!==void 0||rr(e.base_,t)))return!0;Oo(e),No(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 To(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,Oo(e),No(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){let r=mt(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:n.enumerable,value:r[t]}},defineProperty(){oe(11)},getPrototypeOf(e){return gt(e.base_)},setPrototypeOf(){oe(12)}},or={};tr(Uo,(e,t)=>{or[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});or.deleteProperty=function(e,t){return or.set.call(this,e,t,void 0)};or.set=function(e,t,r){return Uo.set.call(this,e[0],t,r,e[0])};function To(e,t){let r=e[ce];return(r?mt(r):e)[t]}function Yd(e,t,r){let n=Vs(t,r);return n?"value"in n?n.value:n.get?.call(e.draft_):void 0}function Vs(e,t){if(!(t in e))return;let r=gt(e);for(;r;){let n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=gt(r)}}function No(e){e.modified_||(e.modified_=!0,e.parent_&&No(e.parent_))}function Oo(e){e.copy_||(e.copy_=Fo(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var Jd=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,r,n)=>{if(typeof t=="function"&&typeof r!="function"){let i=r;r=t;let s=this;return function(l=i,...a){return s.produce(l,d=>r.call(this,d,...a))}}typeof r!="function"&&oe(6),n!==void 0&&typeof n!="function"&&oe(7);let o;if(ue(t)){let i=qs(this),s=_o(t,void 0),c=!0;try{o=r(s),c=!1}finally{c?Mo(i):qo(i)}return Ms(i,n),Ns(o,i)}else if(!t||typeof t!="object"){if(o=r(t),o===void 0&&(o=t),o===Lo&&(o=void 0),this.autoFreeze_&&Vr(o,!0),n){let i=[],s=[];yt("Patches").generateReplacementPatches_(t,o,i,s),n(i,s)}return o}else oe(1,t)},this.produceWithPatches=(t,r)=>{if(typeof t=="function")return(s,...c)=>this.produceWithPatches(s,l=>t(l,...c));let n,o;return[this.produce(t,r,(s,c)=>{n=s,o=c}),n,o]},typeof e?.autoFreeze=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof e?.useStrictShallowCopy=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){ue(e)||oe(8),fe(e)&&(e=Bs(e));let t=qs(this),r=_o(e,void 0);return r[ce].isManual_=!0,qo(t),r}finishDraft(e,t){let r=e&&e[ce];(!r||!r.isManual_)&&oe(9);let{scope_:n}=r;return Ms(n,t),Ns(void 0,n)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let r;for(r=t.length-1;r>=0;r--){let o=t[r];if(o.path.length===0&&o.op==="replace"){e=o.value;break}}r>-1&&(t=t.slice(r+1));let n=yt("Patches").applyPatches_;return fe(e)?n(e,t):this.produce(e,o=>n(o,t))}};function _o(e,t){let r=ir(e)?yt("MapSet").proxyMap_(e,t):sr(e)?yt("MapSet").proxySet_(e,t):Kd(e,t);return(t?t.scope_:Us()).drafts_.push(r),r}function Bs(e){return fe(e)||oe(10,e),Qs(e)}function Qs(e){if(!ue(e)||Br(e))return e;let t=e[ce],r;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,r=Fo(e,t.scope_.immer_.useStrictShallowCopy_)}else r=Fo(e,!0);return tr(r,(n,o)=>{js(r,n,Qs(o))}),t&&(t.finalized_=!1),r}function $s(){let t="replace",r="add",n="remove";function o(p,u,g,h){switch(p.type_){case 0:case 2:return s(p,u,g,h);case 1:return i(p,u,g,h);case 3:return c(p,u,g,h)}}function i(p,u,g,h){let{base_:S,assigned_:C}=p,m=p.copy_;m.length<S.length&&([S,m]=[m,S],[g,h]=[h,g]);for(let y=0;y<S.length;y++)if(C[y]&&m[y]!==S[y]){let A=u.concat([y]);g.push({op:t,path:A,value:f(m[y])}),h.push({op:t,path:A,value:f(S[y])})}for(let y=S.length;y<m.length;y++){let A=u.concat([y]);g.push({op:r,path:A,value:f(m[y])})}for(let y=m.length-1;S.length<=y;--y){let A=u.concat([y]);h.push({op:n,path:A})}}function s(p,u,g,h){let{base_:S,copy_:C}=p;tr(p.assigned_,(m,y)=>{let A=Po(S,m),E=Po(C,m),b=y?rr(S,m)?t:r:n;if(A===E&&b===t)return;let v=u.concat(m);g.push(b===n?{op:b,path:v}:{op:b,path:v,value:E}),h.push(b===r?{op:n,path:v}:b===n?{op:r,path:v,value:f(A)}:{op:t,path:v,value:f(A)})})}function c(p,u,g,h){let{base_:S,copy_:C}=p,m=0;S.forEach(y=>{if(!C.has(y)){let A=u.concat([m]);g.push({op:n,path:A,value:y}),h.unshift({op:r,path:A,value:y})}m++}),m=0,C.forEach(y=>{if(!S.has(y)){let A=u.concat([m]);g.push({op:r,path:A,value:y}),h.unshift({op:n,path:A,value:y})}m++})}function l(p,u,g,h){g.push({op:t,path:[],value:u===Lo?void 0:u}),h.push({op:t,path:[],value:p})}function a(p,u){return u.forEach(g=>{let{path:h,op:S}=g,C=p;for(let E=0;E<h.length-1;E++){let b=ht(C),v=h[E];typeof v!="string"&&typeof v!="number"&&(v=""+v),(b===0||b===1)&&(v==="__proto__"||v==="constructor")&&oe(19),typeof C=="function"&&v==="prototype"&&oe(19),C=Po(C,v),typeof C!="object"&&oe(18,h.join("/"))}let m=ht(C),y=d(g.value),A=h[h.length-1];switch(S){case t:switch(m){case 2:return C.set(A,y);case 3:oe(16);default:return C[A]=y}case r:switch(m){case 1:return A==="-"?C.push(y):C.splice(A,0,y);case 2:return C.set(A,y);case 3:return C.add(y);default:return C[A]=y}case n:switch(m){case 1:return C.splice(A,1);case 2:return C.delete(A);case 3:return C.delete(g.value);default:return delete C[A]}default:oe(17,S)}}),p}function d(p){if(!ue(p))return p;if(Array.isArray(p))return p.map(d);if(ir(p))return new Map(Array.from(p.entries()).map(([g,h])=>[g,d(h)]));if(sr(p))return new Set(Array.from(p).map(d));let u=Object.create(gt(p));for(let g in p)u[g]=d(p[g]);return rr(p,er)&&(u[er]=p[er]),u}function f(p){return fe(p)?d(p):p}zd("Patches",{applyPatches_:a,generatePatches_:o,generateReplacementPatches_:l})}var me=new Jd,Ne=me.produce,Qr=me.produceWithPatches.bind(me),bv=me.setAutoFreeze.bind(me),wv=me.setUseStrictShallowCopy.bind(me),Vo=me.applyPatches.bind(me),xv=me.createDraft.bind(me),Rv=me.finishDraft.bind(me);function Xd(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function Zd(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function ep(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(r=>typeof r=="function")){let r=e.map(n=>typeof n=="function"?`function ${n.name||"unnamed"}()`:typeof n).join(", ");throw new TypeError(`${t}[${r}]`)}}var Hs=e=>Array.isArray(e)?e:[e];function tp(e){let t=Array.isArray(e[0])?e[0]:e;return ep(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function rp(e,t){let r=[],{length:n}=e;for(let o=0;o<n;o++)r.push(e[o].apply(null,t));return r}var kv=Symbol();var Pv=Object.getPrototypeOf({});var np=class{constructor(e){this.value=e}deref(){return this.value}},op=typeof WeakRef<"u"?WeakRef:np,ip=0,zs=1;function $r(){return{s:ip,v:void 0,o:null,p:null}}function Pt(e,t={}){let r=$r(),{resultEqualityCheck:n}=t,o,i=0;function s(){let c=r,{length:l}=arguments;for(let f=0,p=l;f<p;f++){let u=arguments[f];if(typeof u=="function"||typeof u=="object"&&u!==null){let g=c.o;g===null&&(c.o=g=new WeakMap);let h=g.get(u);h===void 0?(c=$r(),g.set(u,c)):c=h}else{let g=c.p;g===null&&(c.p=g=new Map);let h=g.get(u);h===void 0?(c=$r(),g.set(u,c)):c=h}}let a=c,d;if(c.s===zs)d=c.v;else if(d=e.apply(null,arguments),i++,n){let f=o?.deref?.()??o;f!=null&&n(f,d)&&(d=f,i!==0&&i--),o=typeof d=="object"&&d!==null||typeof d=="function"?new op(d):d}return a.s=zs,a.v=d,d}return s.clearCache=()=>{r=$r(),s.resetResultsCount()},s.resultsCount=()=>i,s.resetResultsCount=()=>{i=0},s}function Gs(e,...t){let r=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,n=(...o)=>{let i=0,s=0,c,l={},a=o.pop();typeof a=="object"&&(l=a,a=o.pop()),Xd(a,`createSelector expects an output function after the inputs, but received: [${typeof a}]`);let d={...r,...l},{memoize:f,memoizeOptions:p=[],argsMemoize:u=Pt,argsMemoizeOptions:g=[],devModeChecks:h={}}=d,S=Hs(p),C=Hs(g),m=tp(o),y=f(function(){return i++,a.apply(null,arguments)},...S),A=!0,E=u(function(){s++;let v=rp(m,arguments);return c=y.apply(null,v),c},...C);return Object.assign(E,{resultFunc:a,memoizedResultFunc:y,dependencies:m,dependencyRecomputations:()=>s,resetDependencyRecomputations:()=>{s=0},lastResult:()=>c,recomputations:()=>i,resetRecomputations:()=>{i=0},memoize:f,argsMemoize:u})};return Object.assign(n,{withTypes:()=>n}),n}var K=Gs(Pt),sp=Object.assign((e,t=K)=>{Zd(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),n=r.map(i=>e[i]);return t(n,(...i)=>i.reduce((s,c,l)=>(s[r[l]]=c,s),{}))},{withTypes:()=>sp});function Ws(e){return({dispatch:r,getState:n})=>o=>i=>typeof i=="function"?i(r,n,e):o(i)}var Ks=Ws(),Ys=Ws;var ap=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?kt:kt.apply(null,arguments)},jv=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__?window.__REDUX_DEVTOOLS_EXTENSION__:function(){return function(e){return e}},cp=e=>e&&typeof e.match=="function";function F(e,t){function r(...n){if(t){let o=t(...n);if(!o)throw new Error(Ae(0));return{type:e,payload:o.payload,..."meta"in o&&{meta:o.meta},..."error"in o&&{error:o.error}}}return{type:e,payload:n[0]}}return r.toString=()=>`${e}`,r.type=e,r.match=n=>Lr(n)&&n.type===e,r}var ta=class ar extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,ar.prototype)}static get[Symbol.species](){return ar}concat(...t){return super.concat.apply(this,t)}prepend(...t){return t.length===1&&Array.isArray(t[0])?new ar(...t[0].concat(this)):new ar(...t.concat(this))}};function Js(e){return ue(e)?Ne(e,()=>{}):e}function Xs(e,t,r){return e.has(t)?e.get(t):e.set(t,r(t)).get(t)}function up(e){return typeof e=="boolean"}var lp=()=>function(t){let{thunk:r=!0,immutableCheck:n=!0,serializableCheck:o=!0,actionCreatorCheck:i=!0}=t??{},s=new ta;return r&&(up(r)?s.push(Ks):s.push(Ys(r.extraArgument))),s},ze="RTK_autoBatch",Ot=()=>e=>({payload:e,meta:{[ze]:!0}}),Zs=e=>t=>{setTimeout(t,e)},dp=(e={type:"raf"})=>t=>(...r)=>{let n=t(...r),o=!0,i=!1,s=!1,c=new Set,l=e.type==="tick"?queueMicrotask:e.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Zs(10):e.type==="callback"?e.queueNotification:Zs(e.timeout),a=()=>{s=!1,i&&(i=!1,c.forEach(d=>d()))};return Object.assign({},n,{subscribe(d){let f=()=>o&&d(),p=n.subscribe(f);return c.add(d),()=>{p(),c.delete(d)}},dispatch(d){try{return o=!d?.meta?.[ze],i=!o,i&&(s||(s=!0,l(a))),n.dispatch(d)}finally{o=!0}}})},pp=e=>function(r){let{autoBatch:n=!0}=r??{},o=new ta(e);return n&&o.push(dp(typeof n=="object"?n:void 0)),o};function ra(e){let t=lp(),{reducer:r=void 0,middleware:n,devTools:o=!0,preloadedState:i=void 0,enhancers:s=void 0}=e||{},c;if(typeof r=="function")c=r;else if(Ie(r))c=Et(r);else throw new Error(Ae(1));let l;typeof n=="function"?l=n(t):l=t();let a=kt;o&&(a=ap({trace:!1,...typeof o=="object"&&o}));let d=Ds(...l),f=pp(d),p=typeof s=="function"?s(f):f(),u=a(...p);return ko(c,i,u)}function na(e){let t={},r=[],n,o={addCase(i,s){let c=typeof i=="string"?i:i.type;if(!c)throw new Error(Ae(28));if(c in t)throw new Error(Ae(29));return t[c]=s,o},addMatcher(i,s){return r.push({matcher:i,reducer:s}),o},addDefaultCase(i){return n=i,o}};return e(o),[t,r,n]}function fp(e){return typeof e=="function"}function Y(e,t){let[r,n,o]=na(t),i;if(fp(e))i=()=>Js(e());else{let c=Js(e);i=()=>c}function s(c=i(),l){let a=[r[l.type],...n.filter(({matcher:d})=>d(l)).map(({reducer:d})=>d)];return a.filter(d=>!!d).length===0&&(a=[o]),a.reduce((d,f)=>{if(f)if(fe(d)){let u=f(d,l);return u===void 0?d:u}else{if(ue(d))return Ne(d,p=>f(p,l));{let p=f(d,l);if(p===void 0){if(d===null)return d;throw Error("A case reducer on a non-draftable value must not return undefined")}return p}}return d},c)}return s.getInitialState=i,s}var oa=(e,t)=>cp(e)?e.match(t):e(t);function Ee(...e){return t=>e.some(r=>oa(r,t))}function Tt(...e){return t=>e.every(r=>oa(r,t))}function zr(e,t){if(!e||!e.meta)return!1;let r=typeof e.meta.requestId=="string",n=t.indexOf(e.meta.requestStatus)>-1;return r&&n}function cr(e){return typeof e[0]=="function"&&"pending"in e[0]&&"fulfilled"in e[0]&&"rejected"in e[0]}function Gr(...e){return e.length===0?t=>zr(t,["pending"]):cr(e)?Ee(...e.map(t=>t.pending)):Gr()(e[0])}function St(...e){return e.length===0?t=>zr(t,["rejected"]):cr(e)?Ee(...e.map(t=>t.rejected)):St()(e[0])}function ur(...e){let t=r=>r&&r.meta&&r.meta.rejectedWithValue;return e.length===0?Tt(St(...e),t):cr(e)?Tt(St(...e),t):ur()(e[0])}function _e(...e){return e.length===0?t=>zr(t,["fulfilled"]):cr(e)?Ee(...e.map(t=>t.fulfilled)):_e()(e[0])}function Wr(...e){return e.length===0?t=>zr(t,["pending","fulfilled","rejected"]):cr(e)?Ee(...e.flatMap(t=>[t.pending,t.rejected,t.fulfilled])):Wr()(e[0])}var mp="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",Kr=(e=21)=>{let t="",r=e;for(;r--;)t+=mp[Math.random()*64|0];return t},gp=["name","message","stack","code"],Bo=class{constructor(e,t){ee(this,"_type");this.payload=e,this.meta=t}},ea=class{constructor(e,t){ee(this,"_type");this.payload=e,this.meta=t}},hp=e=>{if(typeof e=="object"&&e!==null){let t={};for(let r of gp)typeof e[r]=="string"&&(t[r]=e[r]);return t}return{message:String(e)}},Q=(()=>{function e(t,r,n){let o=F(t+"/fulfilled",(l,a,d,f)=>({payload:l,meta:{...f||{},arg:d,requestId:a,requestStatus:"fulfilled"}})),i=F(t+"/pending",(l,a,d)=>({payload:void 0,meta:{...d||{},arg:a,requestId:l,requestStatus:"pending"}})),s=F(t+"/rejected",(l,a,d,f,p)=>({payload:f,error:(n&&n.serializeError||hp)(l||"Rejected"),meta:{...p||{},arg:d,requestId:a,rejectedWithValue:!!f,requestStatus:"rejected",aborted:l?.name==="AbortError",condition:l?.name==="ConditionError"}}));function c(l){return(a,d,f)=>{let p=n?.idGenerator?n.idGenerator(l):Kr(),u=new AbortController,g,h;function S(m){h=m,u.abort()}let C=async function(){let m;try{let A=n?.condition?.(l,{getState:d,extra:f});if(Sp(A)&&(A=await A),A===!1||u.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};let E=new Promise((b,v)=>{g=()=>{v({name:"AbortError",message:h||"Aborted"})},u.signal.addEventListener("abort",g)});a(i(p,l,n?.getPendingMeta?.({requestId:p,arg:l},{getState:d,extra:f}))),m=await Promise.race([E,Promise.resolve(r(l,{dispatch:a,getState:d,extra:f,requestId:p,signal:u.signal,abort:S,rejectWithValue:(b,v)=>new Bo(b,v),fulfillWithValue:(b,v)=>new ea(b,v)})).then(b=>{if(b instanceof Bo)throw b;return b instanceof ea?o(b.payload,p,l,b.meta):o(b,p,l)})])}catch(A){m=A instanceof Bo?s(null,p,l,A.payload,A.meta):s(A,p,l)}finally{g&&u.signal.removeEventListener("abort",g)}return n&&!n.dispatchConditionRejection&&s.match(m)&&m.meta.condition||a(m),m}();return Object.assign(C,{abort:S,requestId:p,arg:l,unwrap(){return C.then(yp)}})}}return Object.assign(c,{pending:i,rejected:s,fulfilled:o,settled:Ee(s,o),typePrefix:t})}return e.withTypes=()=>e,e})();function yp(e){if(e.meta&&e.meta.rejectedWithValue)throw e.payload;if(e.error)throw e.error;return e.payload}function Sp(e){return e!==null&&typeof e=="object"&&typeof e.then=="function"}var ia=Symbol.for("rtk-slice-createasyncthunk"),$v={[ia]:Q};function vp(e,t){return`${e}/${t}`}function Cp({creators:e}={}){let t=e?.asyncThunk?.[ia];return function(n){let{name:o,reducerPath:i=o}=n;if(!o)throw new Error(Ae(11));typeof process<"u";let s=(typeof n.reducers=="function"?n.reducers(bp()):n.reducers)||{},c=Object.keys(s),l={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},a={addCase(m,y){let A=typeof m=="string"?m:m.type;if(!A)throw new Error(Ae(12));if(A in l.sliceCaseReducersByType)throw new Error(Ae(13));return l.sliceCaseReducersByType[A]=y,a},addMatcher(m,y){return l.sliceMatchers.push({matcher:m,reducer:y}),a},exposeAction(m,y){return l.actionCreators[m]=y,a},exposeCaseReducer(m,y){return l.sliceCaseReducersByName[m]=y,a}};c.forEach(m=>{let y=s[m],A={reducerName:m,type:vp(o,m),createNotation:typeof n.reducers=="function"};xp(y)?Ip(A,y,a,t):wp(A,y,a)});function d(){let[m={},y=[],A=void 0]=typeof n.extraReducers=="function"?na(n.extraReducers):[n.extraReducers],E={...m,...l.sliceCaseReducersByType};return Y(n.initialState,b=>{for(let v in E)b.addCase(v,E[v]);for(let v of l.sliceMatchers)b.addMatcher(v.matcher,v.reducer);for(let v of y)b.addMatcher(v.matcher,v.reducer);A&&b.addDefaultCase(A)})}let f=m=>m,p=new Map,u;function g(m,y){return u||(u=d()),u(m,y)}function h(){return u||(u=d()),u.getInitialState()}function S(m,y=!1){function A(b){let v=b[m];return typeof v>"u"&&y&&(v=h()),v}function E(b=f){let v=Xs(p,y,()=>new WeakMap);return Xs(v,b,()=>{let I={};for(let[x,O]of Object.entries(n.selectors??{}))I[x]=Ap(O,b,h,y);return I})}return{reducerPath:m,getSelectors:E,get selectors(){return E(A)},selectSlice:A}}let C={name:o,reducer:g,actions:l.actionCreators,caseReducers:l.sliceCaseReducersByName,getInitialState:h,...S(i),injectInto(m,{reducerPath:y,...A}={}){let E=y??i;return m.inject({reducerPath:E,reducer:g},A),{...C,...S(E,!0)}}};return C}}function Ap(e,t,r,n){function o(i,...s){let c=t(i);return typeof c>"u"&&n&&(c=r()),e(c,...s)}return o.unwrapped=e,o}var vt=Cp();function bp(){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 wp({type:e,reducerName:t,createNotation:r},n,o){let i,s;if("reducer"in n){if(r&&!Rp(n))throw new Error(Ae(17));i=n.reducer,s=n.prepare}else i=n;o.addCase(e,i).exposeCaseReducer(t,i).exposeAction(t,s?F(e,s):F(e))}function xp(e){return e._reducerDefinitionType==="asyncThunk"}function Rp(e){return e._reducerDefinitionType==="reducerWithPrepare"}function Ip({type:e,reducerName:t},r,n,o){if(!o)throw new Error(Ae(18));let{payloadCreator:i,fulfilled:s,pending:c,rejected:l,settled:a,options:d}=r,f=o(e,i,d);n.exposeAction(t,f),s&&n.addCase(f.fulfilled,s),c&&n.addCase(f.pending,c),l&&n.addCase(f.rejected,l),a&&n.addMatcher(f.settled,a),n.exposeCaseReducer(t,{fulfilled:s||Hr,pending:c||Hr,rejected:l||Hr,settled:a||Hr})}function Hr(){}var sa="listener",aa="completed",ca="cancelled",Hv=`task-${ca}`,zv=`task-${aa}`,Gv=`${sa}-${ca}`,Wv=`${sa}-${aa}`;var{assign:ua}=Object;var Qo="listenerMiddleware";var Ep=ua(F(`${Qo}/add`),{withTypes:()=>Ep}),Kv=F(`${Qo}/removeAll`),kp=ua(F(`${Qo}/remove`),{withTypes:()=>kp});var Yv=Symbol.for("rtk-state-proxy-original");function Ae(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 Pp,SchemaValidationError as Tp,StringValue as lr,RecordValue as Op,ArrayValue as Fp}from"@coveo/bueno";var U=new lr({required:!0,emptyAllowed:!1}),W=new lr({required:!1,emptyAllowed:!1}),be=new lr({required:!0,emptyAllowed:!0}),iC=new lr({required:!1,emptyAllowed:!0}),la=new Fp({each:U,required:!0}),da=new lr({required:!1,emptyAllowed:!1,regex:/^\d+\.\d+\.\d+$/}),Dp=({message:e,name:t,stack:r})=>({message:e,name:t,stack:r}),$o=(e,t)=>{if("required"in t)return{payload:new Pp({value:t}).validate({value:e}).value};let o=new Op({options:{required:!0},values:t}).validate(e);if(o)throw new Tp(o);return{payload:e}},L=(e,t)=>{try{return $o(e,t)}catch(r){return{payload:e,error:Dp(r)}}};var Yr=(e,t,r,n)=>{let o=`Check the options of ${n}`;return Mp(e,t,r,o,"Controller initialization error")},Mp=(e,t,r,n,o)=>{try{return t.validate(r,n)}catch(i){throw e.logger.error(i,o),i}};var Jr=F("caseAssistConfiguration/set",e=>L(e,{caseAssistId:U,locale:W,proxyBaseUrl:new qp({required:!1,url:!0})}));var pa=()=>({caseAssistId:"",locale:"en-US"});var Ge=Y(pa(),e=>{e.addCase(Jr,(t,r)=>{t.caseAssistId=r.payload.caseAssistId,t.locale=r.payload.locale,t.apiBaseUrl=r.payload.proxyBaseUrl})});import{BooleanValue as fa,StringValue as dr,NumberValue as ma,RecordValue as We}from"@coveo/bueno";var ga={q:new dr,enableQuerySyntax:new fa,aq:new dr,cq:new dr,firstResult:new ma({min:0}),numberOfResults:new ma({min:0}),sortCriteria:new dr,f:new We,fExcluded:new We,cf:new We,nf:new We,mnf:new We,df:new We,debug:new fa,sf:new We,tab:new dr,af:new We};var Xr=F("searchParameters/restore",e=>L(e,ga));var ha=F("debug/enable"),ya=F("debug/disable");var Zr=()=>!1;var Sa=Y(Zr(),e=>{e.addCase(ha,()=>!0).addCase(ya,()=>!1).addCase(Xr,(t,r)=>r.payload.debug??t)});import{StringValue as Np}from"@coveo/bueno";var en=F("searchHub/set",e=>L(e,new Np({required:!0,emptyAllowed:!0})));import{ArrayValue as _p,BooleanValue as Ca,RecordValue as Lp,StringValue as pr,Value as jp}from"@coveo/bueno";var Ft="3.13.0-pre.dac09533fb",va=["@coveo/atomic","@coveo/quantic"];var Ho=()=>W,Aa=()=>U,Dt=F("configuration/updateBasicConfiguration",e=>L(e,{accessToken:W,environment:new pr({required:!1,constrainTo:["prod","hipaa","stg","dev"]}),organizationId:W})),tn=F("configuration/updateSearchConfiguration",e=>L(e,{proxyBaseUrl:new pr({required:!1,url:!0}),pipeline:new pr({required:!1,emptyAllowed:!0}),searchHub:W,timezone:W,locale:W,authenticationProviders:new _p({required:!1,each:U})})),Up={enabled:new Ca({default:!0}),originContext:Ho(),originLevel2:Ho(),originLevel3:Ho(),proxyBaseUrl:new pr({required:!1,url:!0}),runtimeEnvironment:new jp,anonymous:new Ca({default:!1}),deviceId:W,userDisplayName:W,documentLocation:W,trackingId:W,analyticsMode:new pr({constrainTo:["legacy","next"],required:!1,default:"next"}),source:new Lp({options:{required:!1},values:va.reduce((e,t)=>(e[t]=da,e),{})})},rn=F("configuration/updateAnalyticsConfiguration",e=>L(e,Up)),nn=F("configuration/analytics/disable"),on=F("configuration/analytics/enable"),ba=F("configuration/analytics/originlevel2",e=>L(e,{originLevel2:Aa()})),wa=F("configuration/analytics/originlevel3",e=>L(e,{originLevel3:Aa()}));var Vp=F("history/undo"),Bp=F("history/redo"),ke=F("history/snapshot"),$C=Q("history/back",async(e,{dispatch:t})=>{t(Vp()),await t(sn())}),HC=Q("history/forward",async(e,{dispatch:t})=>{t(Bp()),await t(sn())}),sn=Q("history/change",async(e,{getState:t})=>t().history.present);var Ke=()=>"default";var xa=Y(Ke(),e=>{e.addCase(en,(t,r)=>r.payload).addCase(sn.fulfilled,(t,r)=>r.payload?.searchHub??t).addCase(tn,(t,r)=>r.payload.searchHub||t)});function Qp({config:e,environment:t,event:r,listenerManager:n}){let{url:o,token:i,mode:s}=e;s!=="disabled"&&(n.call(r),t.send(o,i,r))}var $p=/^(?:[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 Hp(e){return typeof e=="string"&&$p.test(e)}function zp(e){return{getClientId:()=>{let t="visitorId",r=e.get(),n=r.storage,o=n.getItem(t),i=o&&Hp(o)?o:r.generateUUID();return n.setItem(t,i),i}}}var Ia="0.7.10";function Gp(e){let{trackingId:t}=e;return{trackingId:t}}function Wp(e){return(e.source||[]).concat([`relay@${Ia}`])}function Ea(e,t,r,n){let{getReferrer:o,getLocation:i,getUserAgent:s}=r,c=Gp(t),l=n.getClientId();return Object.freeze({type:e,config:c,ts:Date.now(),source:Wp(t),clientId:l,userAgent:s(),referrer:o(),location:i()})}function Kp(e,t,r,n,o){return{...t,meta:Ea(e,r,n,o)}}var Yp="*";function Jp(){let e=[];function t({type:l,callback:a}){return e.findIndex(d=>d.type===l&&d.callback===a)}function r(l,a){return l.type==="*"||a===l.type}function n(l){return t(l)<0&&e.push(l),()=>c(l.type,l.callback)}function o(l){e.forEach(a=>{if(r(a,l.meta.type))try{a.callback(l)}catch(d){console.error(d)}})}function i(l){if(l===Yp)e.length=0;else for(let a=e.length-1;a>=0;a--)e[a].type===l&&e.splice(a,1)}function s(l){let a=t(l);a>=0&&e.splice(a,1)}function c(l,a){a?s({type:l,callback:a}):i(l)}return{add:n,call:o,remove:c}}function Ra({url:e,token:t,trackingId:r,...n}){return Object.freeze({url:e,token:t,trackingId:r,...!!n.mode&&{mode:n.mode},...!!n.source&&{source:n.source}})}function Xp(e){let t=Ra(e);return{get:()=>t,update:r=>{t=Ra({...t,...r})}}}function Zp(){let e=typeof window<"u";return{sendMessage(t){e&&window.postMessage(t,"*")}}}var zo=ef();function ef(){let e="coveo_",t=r=>{let n=r.split(".").slice(-2);return n.length==2?n.join("."):""};return{getItem(r){let n=`${e}${r}=`,o=document.cookie.split(";");for(let i of o){let s=i.replace(/^\s+/,"");if(s.lastIndexOf(n,0)===0)return s.substring(n.length,s.length)}return null},setItem(r,n,o){let i=t(window.location.hostname),s=`;expires=${new Date(new Date().getTime()+o).toUTCString()}`,c=i?`;domain=${i}`:"";document.cookie=`${e}${r}=${n}${s}${c};path=/;SameSite=Lax`},removeItem(r){this.setItem(r,"",-1)}}}function tf(){return{getItem(e){return zo.getItem(e)||localStorage.getItem(e)},removeItem(e){zo.removeItem(e),localStorage.removeItem(e)},setItem(e,t){localStorage.setItem(e,t),zo.setItem(e,t,31556952e3)}}}function rf(){let e=document.referrer;return e===""?null:e}function nf(){return{runtime:"browser",send:(e,t,r)=>{let n=navigator.sendBeacon(`${e}?access_token=${t}`,new Blob([JSON.stringify([r])],{type:"application/json"}));if(Zp().sendMessage({kind:"EVENT_PROTOCOL",event:r,url:e,token:t}),!n)throw new Error("Failed to send the event(s) because the payload size exceeded the maximum allowed size (32 KB). Please contact support if the problem persists.")},getReferrer:()=>rf(),getLocation:()=>window.location.href,getUserAgent:()=>navigator.userAgent,generateUUID:()=>crypto.randomUUID(),storage:tf()}}function of(){try{let e="__storage_test__";return localStorage.setItem(e,e),localStorage.removeItem(e),!0}catch(e){return e instanceof DOMException&&e.name==="QuotaExceededError"&&localStorage&&localStorage.length!==0}}function sf(){return{getItem(){return null},removeItem(){},setItem(){}}}function af(){return{runtime:"null",send:()=>{},getReferrer:()=>null,getLocation:()=>null,getUserAgent:()=>null,generateUUID:()=>"",storage:sf()}}function cf(e){return e.get().mode!=="disabled"&&uf()&&of()?nf():af()}function uf(){try{return typeof window=="object"}catch{return!1}}function lf(e){return{get:()=>Object.freeze(cf(e))}}function ka(e){let t=Xp(e),r=Jp(),n=lf(t),o=zp(n);return{emit:(i,s)=>{let c=t.get(),l=n.get(),a=Kp(i,s,c,l,o);return Qp({config:c,environment:l,event:a,listenerManager:r})},getMeta:i=>Ea(i,t.get(),n.get(),o),on:(i,s)=>r.add({type:i,callback:s}),off:(i,s)=>r.remove(i,s),updateConfig:i=>t.update(i),version:Ia}}var Mt=K(e=>e.source,e=>Object.entries(e).map(([t,r])=>`${t}@${r}`).concat(`@coveo/headless@${Ft}`));var qt=K(e=>e.configuration.organizationId,e=>e.configuration.environment,e=>e.configuration.accessToken,e=>e.configuration.analytics,e=>Mt(e.configuration.analytics),(e,t,r,{trackingId:n,apiBaseUrl:o,enabled:i},s)=>ka({mode:i?"emit":"disabled",url:o??bo(e,t),token:r,trackingId:n,source:s}));async function Ta(e,t){let r=e.getReader(),n;for(;!(n=await r.read()).done;)t(n.value)}function Oa(e){let t,r,n,o=!1;return function(s){t===void 0?(t=s,r=0,n=-1):t=df(t,s);let c=t.length,l=0;for(;r<c;){o&&(t[r]===10&&(l=++r),o=!1);let a=-1;for(;r<c&&a===-1;++r)switch(t[r]){case 58:n===-1&&(n=r-l);break;case 13:o=!0;case 10:a=r;break}if(a===-1)break;e(t.subarray(l,a),n),l=r,n=-1}l===c?t=void 0:l!==0&&(t=t.subarray(l),r-=l)}}function Fa(e,t,r){let n=Pa(),o=new TextDecoder;return function(s,c){if(s.length===0)r?.(n),n=Pa();else if(c>0){let l=o.decode(s.subarray(0,c)),a=c+(s[c+1]===32?2:1),d=o.decode(s.subarray(a));switch(l){case"data":n.data=n.data?n.data+`
19
19
  `+d:d;break;case"event":n.event=d;break;case"id":e(n.id=d);break;case"retry":let f=parseInt(d,10);isNaN(f)||t(n.retry=f);break}}}}function df(e,t){let r=new Uint8Array(e.length+t.length);return r.set(e),r.set(t,e.length),r}function Pa(){return{data:"",event:"",id:"",retry:void 0}}var pf=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r},an="text/event-stream",ff=1e3,Da="last-event-id";function Ma(){typeof window<"u"}function Go(e,t){var{signal:r,headers:n,onopen:o,onmessage:i,onclose:s,onerror:c,openWhenHidden:l,fetch:a}=t,d=pf(t,["signal","headers","onopen","onmessage","onclose","onerror","openWhenHidden","fetch"]);return new Promise((f,p)=>{let u=Object.assign({},n);u.accept||(u.accept=an);let g;function h(){g?.abort(),document.hidden||E()}!l&&Ma()&&document.addEventListener("visibilitychange",h);let S=ff,C=0;function m(){Ma()&&document.removeEventListener("visibilitychange",h),clearTimeout(C),g?.abort()}r?.addEventListener("abort",()=>{m(),f()});let y=a??y,A=o??mf;async function E(){var b;g=typeof AbortController>"u"?null:new AbortController;try{let v=await y(e,Object.assign(Object.assign({},d),{headers:u,signal:g?.signal}));await A(v),await Ta(v.body,Oa(Fa(I=>{I?u[Da]=I:delete u[Da]},I=>{S=I},i))),s?.(),m(),f()}catch(v){if(!g?.signal.aborted)try{let I=(b=c?.(v))!==null&&b!==void 0?b:S;clearTimeout(C),C=setTimeout(E,I)}catch(I){m(),p(I)}}}E()})}function mf(e){let t=e.headers.get("content-type");if(!t?.startsWith(an))throw new Error(`Expected content-type to be ${an}, Actual: ${t}`)}import{ArrayValue as Oc,BooleanValue as Cg,NumberValue as Ag,RecordValue as bg,StringValue as On}from"@coveo/bueno";import{isNullOrUndefined as vc,RecordValue as eg,Schema as tg,StringValue as kn}from"@coveo/bueno";function Le(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r}function w(e,t,r,n){function o(i){return i instanceof r?i:new r(function(s){s(i)})}return new(r||(r=Promise))(function(i,s){function c(d){try{a(n.next(d))}catch(f){s(f)}}function l(d){try{a(n.throw(d))}catch(f){s(f)}}function a(d){d.done?i(d.value):o(d.value).then(c,l)}a((n=n.apply(e,t||[])).next())})}var V;(function(e){e.search="search",e.click="click",e.custom="custom",e.view="view",e.collect="collect"})(V||(V={}));function Yo(){return typeof window<"u"}function ui(){return typeof navigator<"u"}function Nt(){return typeof document<"u"}function Jo(){try{return typeof localStorage<"u"}catch{return!1}}function gf(){try{return typeof sessionStorage<"u"}catch{return!1}}function Wa(){return ui()&&navigator.cookieEnabled}var hf=[V.click,V.custom,V.search,V.view],yf=(e,t)=>hf.indexOf(e)!==-1?Object.assign({language:Nt()?document.documentElement.lang:"unknown",userAgent:ui()?navigator.userAgent:"unknown"},t):t,gr=class e{static set(t,r,n){var o,i,s,c;n&&(i=new Date,i.setTime(i.getTime()+n)),c=window.location.hostname,c.indexOf(".")===-1?qa(t,r,i):(s=c.split("."),o=s[s.length-2]+"."+s[s.length-1],qa(t,r,i,o))}static get(t){for(var r=t+"=",n=document.cookie.split(";"),o=0;o<n.length;o++){var i=n[o];if(i=i.replace(/^\s+/,""),i.lastIndexOf(r,0)===0)return i.substring(r.length,i.length)}return null}static erase(t){e.set(t,"",-1)}};function qa(e,t,r,n){document.cookie=`${e}=${t}`+(r?`;expires=${r.toUTCString()}`:"")+(n?`;domain=${n}`:"")+";path=/;SameSite=Lax"}function Sf(){return Jo()?localStorage:Wa()?new hr:gf()?sessionStorage:new Lt}var hr=class e{getItem(t){return gr.get(`${e.prefix}${t}`)}removeItem(t){gr.erase(`${e.prefix}${t}`)}setItem(t,r,n){gr.set(`${e.prefix}${t}`,r,n)}};hr.prefix="coveo_";var Xo=class{constructor(){this.cookieStorage=new hr}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)}},Lt=class{getItem(t){return null}removeItem(t){}setItem(t,r){}},fr="__coveo.analytics.history",Ka=20,Ya=1e3*60,Ja=75,jt=class{constructor(t){this.store=t||Sf()}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(fr);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(fr);return t?JSON.parse(t):[]}catch{return[]}})}setHistory(t){try{this.store.setItem(fr,JSON.stringify(t.slice(0,Ka)))}catch{}}clear(){try{this.store.removeItem(fr)}catch{}}getMostRecentElement(){let t=this.getHistoryWithInternalTime();return Array.isArray(t)?t.sort((n,o)=>(o.internalTime||0)-(n.internalTime||0))[0]:null}cropQueryElement(t){return t.name&&t.value&&t.name.toLowerCase()==="query"&&(t.value=t.value.slice(0,Ja)),t}isValidEntry(t){let r=this.getMostRecentElement();return r&&r.value==t.value?(t.internalTime||0)-(r.internalTime||0)>Ya:!0}stripInternalTime(t){return Array.isArray(t)?t.map(r=>{let{name:n,time:o,value:i}=r;return{name:n,time:o,value:i}}):[]}stripEmptyQuery(t){let{name:r,time:n,value:o}=t;return r&&typeof o=="string"&&r.toLowerCase()==="query"&&o.trim()===""?{name:r,time:n}:t}stripEmptyQueries(t){return t.map(r=>this.stripEmptyQuery(r))}},Xa=Object.freeze({__proto__:null,HistoryStore:jt,MAX_NUMBER_OF_HISTORY_ELEMENTS:Ka,MAX_VALUE_SIZE:Ja,MIN_THRESHOLD_FOR_DUPLICATE_VALUE:Ya,STORE_KEY:fr,default:jt}),vf=(e,t)=>w(void 0,void 0,void 0,function*(){return e===V.view?(yield Cf(t.contentIdValue),Object.assign({location:window.location.toString(),referrer:document.referrer,title:document.title},t)):t}),Cf=e=>w(void 0,void 0,void 0,function*(){let t=new jt,r={name:"PageView",value:e,time:new Date().toISOString()};yield t.addElementAsync(r)}),cn,Af=new Uint8Array(16);function bf(){if(!cn&&(cn=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!cn))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return cn(Af)}var wf=/^(?:[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 ln(e){return typeof e=="string"&&wf.test(e)}var ie=[];for(let e=0;e<256;++e)ie.push((e+256).toString(16).slice(1));function Za(e,t=0){return(ie[e[t+0]]+ie[e[t+1]]+ie[e[t+2]]+ie[e[t+3]]+"-"+ie[e[t+4]]+ie[e[t+5]]+"-"+ie[e[t+6]]+ie[e[t+7]]+"-"+ie[e[t+8]]+ie[e[t+9]]+"-"+ie[e[t+10]]+ie[e[t+11]]+ie[e[t+12]]+ie[e[t+13]]+ie[e[t+14]]+ie[e[t+15]]).toLowerCase()}function xf(e){if(!ln(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 Rf(e){e=unescape(encodeURIComponent(e));let t=[];for(let r=0;r<e.length;++r)t.push(e.charCodeAt(r));return t}var If="6ba7b810-9dad-11d1-80b4-00c04fd430c8",Ef="6ba7b811-9dad-11d1-80b4-00c04fd430c8";function kf(e,t,r){function n(o,i,s,c){var l;if(typeof o=="string"&&(o=Rf(o)),typeof i=="string"&&(i=xf(i)),((l=i)===null||l===void 0?void 0:l.length)!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let a=new Uint8Array(16+o.length);if(a.set(i),a.set(o,i.length),a=r(a),a[6]=a[6]&15|t,a[8]=a[8]&63|128,s){c=c||0;for(let d=0;d<16;++d)s[c+d]=a[d];return s}return Za(a)}try{n.name=e}catch{}return n.DNS=If,n.URL=Ef,n}var Pf=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),Na={randomUUID:Pf};function Ct(e,t,r){if(Na.randomUUID&&!t&&!e)return Na.randomUUID();e=e||{};let n=e.random||(e.rng||bf)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,t){r=r||0;for(let o=0;o<16;++o)t[r+o]=n[o];return t}return Za(n)}function Tf(e,t,r,n){switch(e){case 0:return t&r^~t&n;case 1:return t^r^n;case 2:return t&r^t&n^r&n;case 3:return t^r^n}}function Wo(e,t){return e<<t|e>>>32-t}function Of(e){let t=[1518500249,1859775393,2400959708,3395469782],r=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof e=="string"){let s=unescape(encodeURIComponent(e));e=[];for(let c=0;c<s.length;++c)e.push(s.charCodeAt(c))}else Array.isArray(e)||(e=Array.prototype.slice.call(e));e.push(128);let n=e.length/4+2,o=Math.ceil(n/16),i=new Array(o);for(let s=0;s<o;++s){let c=new Uint32Array(16);for(let l=0;l<16;++l)c[l]=e[s*64+l*4]<<24|e[s*64+l*4+1]<<16|e[s*64+l*4+2]<<8|e[s*64+l*4+3];i[s]=c}i[o-1][14]=(e.length-1)*8/Math.pow(2,32),i[o-1][14]=Math.floor(i[o-1][14]),i[o-1][15]=(e.length-1)*8&4294967295;for(let s=0;s<o;++s){let c=new Uint32Array(80);for(let u=0;u<16;++u)c[u]=i[s][u];for(let u=16;u<80;++u)c[u]=Wo(c[u-3]^c[u-8]^c[u-14]^c[u-16],1);let l=r[0],a=r[1],d=r[2],f=r[3],p=r[4];for(let u=0;u<80;++u){let g=Math.floor(u/20),h=Wo(l,5)+Tf(g,a,d,f)+p+t[g]+c[u]>>>0;p=f,f=d,d=Wo(a,30)>>>0,a=l,l=h}r[0]=r[0]+l>>>0,r[1]=r[1]+a>>>0,r[2]=r[2]+d>>>0,r[3]=r[3]+f>>>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 Ff=kf("v5",80,Of),_a=Ff,ec="2.30.42",La=e=>`${e.protocol}//${e.hostname}${e.pathname.indexOf("/")===0?e.pathname:`/${e.pathname}`}${e.search}`,mr={pageview:"pageview",event:"event"},dn=class{constructor({client:t,uuidGenerator:r=Ct}){this.client=t,this.uuidGenerator=r}},Zo=class extends dn{constructor({client:t,uuidGenerator:r=Ct}){super({client:t,uuidGenerator:r}),this.actionData={},this.pageViewId=r(),this.nextPageViewId=this.pageViewId,this.currentLocation=La(window.location),this.lastReferrer=Nt()?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:Nt()?document.title:"",encoding:Nt()?document.characterSet:"UTF-8"},n={screenResolution:`${screen.width}x${screen.height}`,screenColor:`${screen.colorDepth}-bit`},o={language:navigator.language,userAgent:navigator.userAgent},i={time:Date.now(),eventId:this.uuidGenerator()};return Object.assign(Object.assign(Object.assign(Object.assign({},i),n),o),r)}updateLocationForNextPageView(t,r){let{pageViewId:n,referrer:o,location:i}=this.getNextValues(t,r);this.lastReferrer=o,this.pageViewId=n,this.currentLocation=i,t===mr.pageview&&(this.nextPageViewId=this.uuidGenerator(),this.hasSentFirstPageView=!0)}getNextValues(t,r){return{pageViewId:t===mr.pageview?this.nextPageViewId:this.pageViewId,referrer:t===mr.pageview&&this.hasSentFirstPageView?this.currentLocation:this.lastReferrer,location:t===mr.pageview?this.getCurrentLocationFromPayload(r):this.currentLocation}}getCurrentLocationFromPayload(t){if(t.page){let r=o=>o.replace(/^\/?(.*)$/,"/$1");return`${(o=>o.split("/").slice(0,3).join("/"))(this.currentLocation)}${r(t.page)}`}else return La(window.location)}},Ye=class e{constructor(t,r){if(!ln(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 n=new URL(t);return r.some(o=>new RegExp(o.replace(/\\/g,"\\\\").replace(/\./g,"\\.").replace(/\*/g,".*")+"$").test(n.host))}catch{return!1}}static fromString(t){let r=t.split(".");if(r.length!==2)return null;let[n,o]=r;if(n.length!==32||isNaN(parseInt(o)))return null;let i=n.substring(0,8)+"-"+n.substring(8,12)+"-"+n.substring(12,16)+"-"+n.substring(16,20)+"-"+n.substring(20,32);return ln(i)?new e(i,Number.parseInt(o)*1e3):null}};Ye.cvo_cid="cvo_cid";Ye.expirationTime=120;var ei=class extends dn{constructor({client:t,uuidGenerator:r=Ct}){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),n=yield this.client.getCurrentVisitorId();return r.searchParams.set(Ye.cvo_cid,new Ye(n,Date.now()).toString()),r.toString()}catch{throw new Error("Invalid URL provided")}})}acceptFrom(t){this.client.setAcceptedLinkReferrers(t)}};ei.Id="link";var Se=Object.keys;function un(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}var Ko=128,tc=192,ja=224,Ua=240;function Df(e){return(e&248)===Ua?4:(e&Ua)===ja?3:(e&ja)===tc?2:1}function Mf(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 n=Number.parseInt(e.substring(r-2,r),16);if((n&Ko)!=Ko)break;if(r-=3,(n&tc)!=Ko){t-r>=Df(n)*3&&(r=t);break}}return e.substring(0,r)}var ti={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"},qf=Se(ti).map(e=>ti[e]),Nf=[...qf].join("|"),_f=new RegExp(`^(${Nf}$)`),Lf={svcAction:"svc_action",svcActionData:"svc_action_data"},jf=e=>Se(e).filter(t=>e[t]!==void 0).reduce((t,r)=>{let n=ti[r]||r;return Object.assign(Object.assign({},t),{[n]:e[r]})},{}),Uf=e=>_f.test(e),Vf=[Uf],Va={id:"id",name:"nm",brand:"br",category:"ca",variant:"va",price:"pr",quantity:"qt",coupon:"cc",position:"ps",group:"group"},Ba={id:"id",name:"nm",brand:"br",category:"ca",variant:"va",position:"ps",price:"pr",group:"group"},se={action:"pa",list:"pal",listSource:"pls"},pn={id:"ti",revenue:"tr",tax:"tt",shipping:"ts",coupon:"tcc",affiliation:"ta",step:"cos",option:"col"},Bf=["loyaltyCardId","loyaltyTier","thirdPartyPersona","companyName","favoriteStore","storeName","userIndustry","userRole","userDepartment","businessUnit"],ri={id:"quoteId",affiliation:"quoteAffiliation"},ni={id:"reviewId",rating:"reviewRating",comment:"reviewComment"},Qf={add:se,bookmark_add:se,bookmark_remove:se,click:se,checkout:se,checkout_option:se,detail:se,impression:se,remove:se,refund:Object.assign(Object.assign({},se),pn),purchase:Object.assign(Object.assign({},se),pn),quickview:se,quote:Object.assign(Object.assign({},se),ri),review:Object.assign(Object.assign({},se),ni)},$f=Se(Va).map(e=>Va[e]),Hf=Se(Ba).map(e=>Ba[e]),zf=Se(se).map(e=>se[e]),Gf=Se(pn).map(e=>pn[e]),Wf=Se(ni).map(e=>ni[e]),Kf=Se(ri).map(e=>ri[e]),Yf=[...$f,"custom"].join("|"),Jf=[...Hf,"custom"].join("|"),rc="(pr[0-9]+)",nc="(il[0-9]+pi[0-9]+)",Xf=new RegExp(`^${rc}(${Yf})$`),Zf=new RegExp(`^(${nc}(${Jf}))|(il[0-9]+nm)$`),em=new RegExp(`^(${zf.join("|")})$`),tm=new RegExp(`^(${Gf.join("|")})$`),rm=new RegExp(`^${rc}custom$`),nm=new RegExp(`^${nc}custom$`),om=new RegExp(`^(${[...Bf,...Wf,...Kf].join("|")})$`),im=e=>Xf.test(e),sm=e=>Zf.test(e),am=e=>em.test(e),cm=e=>tm.test(e),um=e=>om.test(e),lm=[sm,im,am,cm,um],dm=[rm,nm],pm={anonymizeIp:"aip"},fm={eventCategory:"ec",eventAction:"ea",eventLabel:"el",eventValue:"ev",page:"dp",visitorId:"cid",clientId:"cid",userId:"uid",currencyCode:"cu"},mm={hitType:"t",pageViewId:"pid",encoding:"de",location:"dl",referrer:"dr",screenColor:"sd",screenResolution:"sr",title:"dt",userAgent:"ua",language:"ul",eventId:"z",time:"tm"},gm=["contentId","contentIdKey","contentType","searchHub","tab","searchUid","permanentId","contentLocale","trackingId"],hm=Object.assign(Object.assign(Object.assign(Object.assign({},pm),fm),mm),gm.reduce((e,t)=>Object.assign(Object.assign({},e),{[t]:t}),{})),oi=Object.assign(Object.assign({},hm),Lf),ym=e=>{let t=!!e.action&&Qf[e.action]||{};return Se(e).reduce((r,n)=>{let o=t[n]||oi[n]||n;return Object.assign(Object.assign({},r),{[o]:e[n]})},{})},Sm=Se(oi).map(e=>oi[e]),vm=e=>Sm.indexOf(e)!==-1,Cm=e=>e==="custom",Am=e=>[...lm,...Vf,vm,Cm].some(t=>t(e)),bm=e=>Se(e).reduce((t,r)=>{let n=wm(r);return n?Object.assign(Object.assign({},t),xm(n,e[r])):Object.assign(Object.assign({},t),{[r]:e[r]})},{}),wm=e=>{let t;return[...dm].every(r=>{var n;return t=(n=r.exec(e))===null||n===void 0?void 0:n[1],!t}),t},xm=(e,t)=>Se(t).reduce((r,n)=>Object.assign(Object.assign({},r),{[`${e}${n}`]:t[n]}),{}),ii=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:n,preprocessRequest:o}=this.opts,i=yield this.getQueryParamsForEventType(t),{url:s,payload:c}=yield this.preProcessRequestAsPotentialJSONString(`${n}/analytics/${t}?${i}`,r,o),l=this.encodeForEventType(t,c),a=new Blob([l],{type:"application/x-www-form-urlencoded"});navigator.sendBeacon(s,a)})}isAvailable(){return"sendBeacon"in navigator}deleteHttpCookieVisitorId(){return Promise.resolve()}preProcessRequestAsPotentialJSONString(t,r,n){return w(this,void 0,void 0,function*(){let o=t,i=r;if(n){let s=yield n({url:t,body:JSON.stringify(r)},"analyticsBeacon"),{url:c,body:l}=s;o=c||t;try{i=JSON.parse(l)}catch(a){console.error("Unable to process the request body as a JSON string",a)}}return{payload:i,url:o}})}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:n}=this.opts,o=yield n.getCurrentVisitorId();return[r&&this.isEventTypeLegacy(t)?`access_token=${r}`:"",o?`visitorId=${o}`:"","discardVisitInfo=true"].filter(i=>!!i).join("&")})}isEventTypeLegacy(t){return[V.click,V.custom,V.search,V.view].indexOf(t)!==-1}encodeEventToJson(t,r,n){let o=`${t}Event=${encodeURIComponent(JSON.stringify(r))}`;return n&&(o=`access_token=${encodeURIComponent(n)}&${o}`),o}},si=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()})}},Qa=globalThis.fetch,fn=class{constructor(t){this.opts=t}sendEvent(t,r){return w(this,void 0,void 0,function*(){let{baseUrl:n,visitorIdProvider:o,preprocessRequest:i}=this.opts,s=this.shouldAppendVisitorId(t)?yield this.getVisitorIdParam():"",c={url:`${n}/analytics/${t}${s}`,credentials:"include",mode:"cors",headers:this.getHeaders(),method:"POST",body:JSON.stringify(r)},l=Object.assign(Object.assign({},c),i?yield i(c,"analyticsFetch"):{}),{url:a}=l,d=Le(l,["url"]),f;try{f=yield Qa(a,d)}catch(p){console.error("An error has occured when sending the event.",p);return}if(f.ok){let p=yield f.json();return p.visitorId&&o.setCurrentVisitorId(p.visitorId),p}else{try{f.json()}catch{}throw console.error(`An error has occured when sending the "${t}" event.`,f,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 Qa(r,{headers:this.getHeaders(),method:"DELETE"})})}shouldAppendVisitorId(t){return[V.click,V.custom,V.search,V.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"})}},ai=class{constructor(t,r){Jo()&&Wa()?this.storage=new Xo:Jo()?this.storage=localStorage:(console.warn("BrowserRuntime detected no valid storage available.",this),this.storage=new Lt),this.client=new fn(t),this.beaconClient=new ii(t),window.addEventListener("beforeunload",()=>{let n=r();for(let{eventType:o,payload:i}of n)this.beaconClient.sendEvent(o,i)})}getClientDependingOnEventType(t){return t==="click"&&this.beaconClient.isAvailable()?this.beaconClient:this.client}},ci=class{constructor(t,r){this.storage=r||new Lt,this.client=new fn(t)}getClientDependingOnEventType(t){return this.client}},mn=class{constructor(){this.storage=new Lt,this.client=new si}getClientDependingOnEventType(t){return this.client}},Rm="xx",Im=e=>e?.startsWith(Rm)||!1,Em=`
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.