Socket
Socket
Sign inDemoInstall

@uniformdev/context

Package Overview
Dependencies
Maintainers
10
Versions
591
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@uniformdev/context - npm Package Compare versions

Comparing version 16.0.1-alpha.221 to 16.0.1-nuxt.146

4

dist/api/api.js

@@ -1,2 +0,2 @@

var S=Object.defineProperty;var Q=Object.getOwnPropertyDescriptor;var H=Object.getOwnPropertyNames;var K=Object.prototype.hasOwnProperty;var q=(r,e,t)=>e in r?S(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t;var z=(r,e)=>{for(var t in e)S(r,t,{get:e[t],enumerable:!0})},B=(r,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of H(e))!K.call(r,n)&&n!==t&&S(r,n,{get:()=>e[n],enumerable:!(i=Q(e,n))||i.enumerable});return r};var Y=r=>B(S({},"__esModule",{value:!0}),r);var u=(r,e,t)=>(q(r,typeof e!="symbol"?e+"":e,t),t),F=(r,e,t)=>{if(!e.has(r))throw TypeError("Cannot "+t)};var s=(r,e,t)=>(F(r,e,"read from private field"),t?t.call(r):e.get(r)),p=(r,e,t)=>{if(e.has(r))throw TypeError("Cannot add the same private member more than once");e instanceof WeakSet?e.add(r):e.set(r,t)};var Z={};z(Z,{AggregateClient:()=>f,ApiClientError:()=>h,ContextClient:()=>$,DimensionClient:()=>d,EnrichmentClient:()=>g,ManifestClient:()=>E,QuirkClient:()=>j,SignalClient:()=>U,computeDimensionDefinitionDisplayData:()=>V,computeDimensionDisplayData:()=>W,computeDimensionDisplayName:()=>X,nullLimitPolicy:()=>L});module.exports=Y(Z);var L=async r=>await r(),h=class extends Error{constructor(t,i,n,a,c,m){super(`${t}
${a}${c?" "+c:""} (${i} ${n}${m?` Request ID: ${m}`:""})`);this.errorMessage=t;this.fetchMethod=i;this.fetchUri=n;this.statusCode=a;this.statusText=c;this.requestId=m;Object.setPrototypeOf(this,h.prototype)}};var o=class{constructor(e){u(this,"options");var t,i,n,a,c,m;if(!e.apiKey&&!e.bearerToken)throw new Error("You must provide an API key or a bearer token");this.options={...e,fetch:(t=e.fetch)!=null?t:fetch,apiHost:(i=e.apiHost)!=null?i:"https://uniform.app",apiKey:(n=e.apiKey)!=null?n:null,projectId:(a=e.projectId)!=null?a:null,bearerToken:(c=e.bearerToken)!=null?c:null,limitPolicy:(m=e.limitPolicy)!=null?m:L}}async apiClient(e,t){return this.options.limitPolicy(async()=>{var a;let i=this.options.apiKey?{"x-api-key":this.options.apiKey}:{Authorization:`Bearer ${this.options.bearerToken}`},n=await fetch(e.toString(),{...t,headers:{...t==null?void 0:t.headers,...i}});if(!n.ok){let c="";try{let m=await n.text();try{let I=JSON.parse(m);I.errorMessage?c=Array.isArray(I.errorMessage)?I.errorMessage.join(", "):I.errorMessage:c=m}catch(I){c=m}}catch(m){c="General error"}throw new h(c,(a=t==null?void 0:t.method)!=null?a:"GET",e.toString(),n.status,n.statusText,o.getRequestId(n))}return t!=null&&t.expectNoContent?null:await n.json()})}createUrl(e,t){let i=new URL(`${this.options.apiHost}${e}`);return Object.entries(t!=null?t:{}).forEach(([n,a])=>{var c;typeof a!="undefined"&&a!==null&&i.searchParams.append(n,(c=a==null?void 0:a.toString())!=null?c:"")}),i}static getRequestId(e){let t=e.headers.get("x-nf-request-id");if(t)return t}};var P,T=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(T,P),{...e,projectId:t});return await this.apiClient(i)}async upsert(e){let t=this.createUrl(s(T,P));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async remove(e){let t=this.createUrl(s(T,P));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}},f=T;P=new WeakMap,p(f,P,"/api/v2/aggregate");var A,v=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(v,A),{...e,projectId:t});return await this.apiClient(i)}},d=v;A=new WeakMap,p(d,A,"/api/v2/dimension");var x,O,y=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(y,x),{...e,projectId:t});return await this.apiClient(i)}async upsertCategory(e){let t=this.createUrl(s(y,x));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async removeCategory(e){let t=this.createUrl(s(y,x));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async upsertValue(e){let t=this.createUrl(s(y,O));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async removeValue(e){let t=this.createUrl(s(y,O));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}},g=y;x=new WeakMap,O=new WeakMap,p(g,x,"/api/v1/enrichments"),p(g,O,"/api/v1/enrichment-values");var k,J=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(J,k),{...e,projectId:t});return await this.apiClient(i)}},E=J;k=new WeakMap,p(E,k,"/api/v2/manifest");var C,G=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(G,C),{...e,projectId:t});return await this.apiClient(i)}async upsert(e){let t=this.createUrl(s(G,C));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async remove(e){let t=this.createUrl(s(G,C));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}},j=G;C=new WeakMap,p(j,C,"/api/v2/quirk");var D,w=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(w,D),{...e,projectId:t});return await this.apiClient(i)}async upsert(e){let t=this.createUrl(s(w,D));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async remove(e){let t=this.createUrl(s(w,D));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}},U=w;D=new WeakMap,p(U,D,"/api/v2/signal");var R,N=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(N,R),{...e,projectId:t});return await this.apiClient(i)}async upsert(e){let t=this.createUrl(s(N,R));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async remove(e){let t=this.createUrl(s(N,R));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}},b=N;R=new WeakMap,p(b,R,"/api/v2/test");var $=class{constructor(e){u(this,"enrichments");u(this,"aggregates");u(this,"dimensions");u(this,"manifest");u(this,"quirks");u(this,"signals");u(this,"tests");this.enrichments=new g(e),this.aggregates=new f(e),this.dimensions=new d(e),this.manifest=new E(e),this.quirks=new j(e),this.signals=new U(e),this.tests=new b(e)}};var M="_";function V(r){let e=r.category==="ENR"?"Enrichment":r.category==="SIG"?"Signal":r.subcategory==="1"?"Intent":r.subcategory==="0"?"Audience":"Aggregate";return{dim:r.dim,name:r.name,type:e,category:r.category==="ENR"?r.subcategory:void 0}}function W(r,e){var t,i,n,a;if((i=(t=e.project.pz)==null?void 0:t.agg)!=null&&i[r])return{dim:r,name:r,type:"Aggregate"};if((a=(n=e.project.pz)==null?void 0:n.sig)!=null&&a[r])return{dim:r,name:r,type:"Signal"};if(r.indexOf(M)>=0){let[c,m]=r.split(M);return{dim:r,name:m,type:"Enrichment",category:c}}}function X(r){let{type:e,name:t}=V(r);return`${e}: ${t}`}0&&(module.exports={AggregateClient,ApiClientError,ContextClient,DimensionClient,EnrichmentClient,ManifestClient,QuirkClient,SignalClient,computeDimensionDefinitionDisplayData,computeDimensionDisplayData,computeDimensionDisplayName,nullLimitPolicy});
"use strict";var N=Object.defineProperty;var V=Object.getOwnPropertyDescriptor;var Q=Object.getOwnPropertyNames;var H=Object.prototype.hasOwnProperty;var K=(r,e,t)=>e in r?N(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t;var q=(r,e)=>{for(var t in e)N(r,t,{get:e[t],enumerable:!0})},z=(r,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of Q(e))!H.call(r,n)&&n!==t&&N(r,n,{get:()=>e[n],enumerable:!(i=V(e,n))||i.enumerable});return r};var B=r=>z(N({},"__esModule",{value:!0}),r);var l=(r,e,t)=>(K(r,typeof e!="symbol"?e+"":e,t),t),Y=(r,e,t)=>{if(!e.has(r))throw TypeError("Cannot "+t)};var s=(r,e,t)=>(Y(r,e,"read from private field"),t?t.call(r):e.get(r)),p=(r,e,t)=>{if(e.has(r))throw TypeError("Cannot add the same private member more than once");e instanceof WeakSet?e.add(r):e.set(r,t)};var X={};q(X,{AggregateClient:()=>g,ApiClientError:()=>u,ContextClient:()=>J,DimensionClient:()=>P,EnrichmentClient:()=>y,ManifestClient:()=>x,QuirkClient:()=>E,SignalClient:()=>C,computeDimensionDefinitionDisplayData:()=>M,computeDimensionDisplayData:()=>F,computeDimensionDisplayName:()=>W,nullLimitPolicy:()=>k});module.exports=B(X);var k=async r=>await r(),u=class extends Error{constructor(t,i,n,a,c,m){super(`${t}
${a}${c?" "+c:""} (${i} ${n}${m?` Request ID: ${m}`:""})`);this.errorMessage=t;this.fetchMethod=i;this.fetchUri=n;this.statusCode=a;this.statusText=c;this.requestId=m;Object.setPrototypeOf(this,u.prototype)}};var o=class{constructor(e){l(this,"options");var t,i,n,a,c,m;if(!e.apiKey&&!e.bearerToken)throw new Error("You must provide an API key or a bearer token");this.options={...e,fetch:(t=e.fetch)!=null?t:fetch,apiHost:(i=e.apiHost)!=null?i:"https://uniform.app",apiKey:(n=e.apiKey)!=null?n:null,projectId:(a=e.projectId)!=null?a:null,bearerToken:(c=e.bearerToken)!=null?c:null,limitPolicy:(m=e.limitPolicy)!=null?m:k}}async apiClient(e,t){return this.options.limitPolicy(async()=>{var a;let i=this.options.apiKey?{"x-api-key":this.options.apiKey}:{Authorization:`Bearer ${this.options.bearerToken}`},n=await fetch(e.toString(),{...t,headers:{...t==null?void 0:t.headers,...i}});if(!n.ok){let c="";try{let m=await n.text();try{let R=JSON.parse(m);R.errorMessage?c=Array.isArray(R.errorMessage)?R.errorMessage.join(", "):R.errorMessage:c=m}catch(R){c=m}}catch(m){c="General error"}throw new u(c,(a=t==null?void 0:t.method)!=null?a:"GET",e.toString(),n.status,n.statusText,o.getRequestId(n))}return t!=null&&t.expectNoContent?null:await n.json()})}createUrl(e,t){let i=new URL(`${this.options.apiHost}${e}`);return Object.entries(t!=null?t:{}).forEach(([n,a])=>{var c;typeof a!="undefined"&&a!==null&&i.searchParams.append(n,(c=a==null?void 0:a.toString())!=null?c:"")}),i}static getRequestId(e){let t=e.headers.get("x-nf-request-id");if(t)return t}};var f,I=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(I,f),{...e,projectId:t});return await this.apiClient(i)}async upsert(e){let t=this.createUrl(s(I,f));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async remove(e){let t=this.createUrl(s(I,f));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}},g=I;f=new WeakMap,p(g,f,"/api/v2/aggregate");var S,L=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(L,S),{...e,projectId:t});return await this.apiClient(i)}},P=L;S=new WeakMap,p(P,S,"/api/v2/dimension");var d,T,h=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(h,d),{...e,projectId:t});return await this.apiClient(i)}async upsertCategory(e){let t=this.createUrl(s(h,d));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async removeCategory(e){let t=this.createUrl(s(h,d));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async upsertValue(e){let t=this.createUrl(s(h,T));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async removeValue(e){let t=this.createUrl(s(h,T));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}},y=h;d=new WeakMap,T=new WeakMap,p(y,d,"/api/v1/enrichments"),p(y,T,"/api/v1/enrichment-values");var A,v=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(v,A),{...e,projectId:t});return await this.apiClient(i)}},x=v;A=new WeakMap,p(x,A,"/api/v2/manifest");var j,O=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(O,j),{...e,projectId:t});return await this.apiClient(i)}async upsert(e){let t=this.createUrl(s(O,j));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async remove(e){let t=this.createUrl(s(O,j));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}},E=O;j=new WeakMap,p(E,j,"/api/v2/quirk");var U,G=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(G,U),{...e,projectId:t});return await this.apiClient(i)}async upsert(e){let t=this.createUrl(s(G,U));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async remove(e){let t=this.createUrl(s(G,U));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}},C=G;U=new WeakMap,p(C,U,"/api/v2/signal");var D,b=class extends o{constructor(e){super(e)}async get(e){let{projectId:t}=this.options,i=this.createUrl(s(b,D),{...e,projectId:t});return await this.apiClient(i)}async upsert(e){let t=this.createUrl(s(b,D));await this.apiClient(t,{method:"PUT",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}async remove(e){let t=this.createUrl(s(b,D));await this.apiClient(t,{method:"DELETE",body:JSON.stringify({...e,projectId:this.options.projectId}),expectNoContent:!0})}},w=b;D=new WeakMap,p(w,D,"/api/v2/test");var J=class{constructor(e){l(this,"enrichments");l(this,"aggregates");l(this,"dimensions");l(this,"manifest");l(this,"quirks");l(this,"signals");l(this,"tests");this.enrichments=new y(e),this.aggregates=new g(e),this.dimensions=new P(e),this.manifest=new x(e),this.quirks=new E(e),this.signals=new C(e),this.tests=new w(e)}};var $="_";function M(r){let e=r.category==="ENR"?"Enrichment":r.category==="SIG"?"Signal":r.subcategory==="1"?"Intent":r.subcategory==="0"?"Audience":"Aggregate";return{dim:r.dim,name:r.name,type:e,category:r.category==="ENR"?r.subcategory:void 0}}function F(r,e){var t,i,n,a;if((i=(t=e.project.pz)==null?void 0:t.agg)!=null&&i[r])return{dim:r,name:r,type:"Aggregate"};if((a=(n=e.project.pz)==null?void 0:n.sig)!=null&&a[r])return{dim:r,name:r,type:"Signal"};if(r.indexOf($)>=0){let[c,m]=r.split($);return{dim:r,name:m,type:"Enrichment",category:c}}}function W(r){let{type:e,name:t}=M(r);return`${e}: ${t}`}0&&(module.exports={AggregateClient,ApiClientError,ContextClient,DimensionClient,EnrichmentClient,ManifestClient,QuirkClient,SignalClient,computeDimensionDefinitionDisplayData,computeDimensionDisplayData,computeDimensionDisplayName,nullLimitPolicy});

@@ -1,3 +0,3 @@

var le=Object.defineProperty;var ce=(e,t,r)=>t in e?le(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var C=(e,t,r)=>(ce(e,typeof t!="symbol"?t+"":t,r),r),pt=(e,t,r)=>{if(!t.has(e))throw TypeError("Cannot "+r)};var a=(e,t,r)=>(pt(e,t,"read from private field"),r?r.call(e):t.get(e)),d=(e,t,r)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,r)},g=(e,t,r,i)=>(pt(e,t,"write to private field"),i?i.call(e,r):t.set(e,r),r);var D=(e,t,r)=>(pt(e,t,"access private method"),r);function Ot(e,t){let r={...e};for(let i in t){let n=Ut(e,i,t,new Set([i]));n!==0&&(r[i]=n)}return r}function Ut(e,t,r,i){var s;let n=0;for(let o of r[t].inputs){let u=(s=e[o.dim])!=null?s:0;if(!u&&r[o.dim]){if(i.has(o.dim))continue;let l=new Set(i);l.add(o.dim),u=Ut(e,o.dim,r,l)}if(u!==0)if(o.sign==="c"){n=0;break}else o.sign==="-"?n-=u:n+=u}return n}var L="_";var K,H,tt=class{constructor(t,r,i){d(this,K,void 0);d(this,H,void 0);C(this,"signal");this.signal=t,g(this,K,r),g(this,H,i)}computeSignal(t,r){if(t.scores[this.signal.id]>=this.signal.cap&&this.signal.dur!=="t")return;let n=a(this,K).evaluate(t,this.signal.crit,r,this.signal,a(this,H)),s=this.signal.dur==="s"||this.signal.dur==="t"?"modscoreS":"modscore";if(!!n.changed){if(n.result)r.push({type:s,data:{dimension:this.signal.id,delta:this.signal.str}});else if(this.signal.dur==="t"){let o=t.visitor.sessionScores[this.signal.id];o&&r.push({type:s,data:{dimension:this.signal.id,delta:-o}})}}}};K=new WeakMap,H=new WeakMap;var E,B,U,et=class{constructor({manifest:t,evaluator:r=new I({}),onLogMessage:i=()=>{}}){C(this,"data");d(this,E,void 0);d(this,B,void 0);d(this,U,void 0);var n,s,o;g(this,E,(n=t.project)!=null?n:{}),this.data=t,g(this,B,Object.entries((o=(s=a(this,E).pz)==null?void 0:s.sig)!=null?o:[]).map(([u,c])=>new tt({...c,id:u},r,i))),g(this,U,i)}rollForControlGroup(){var t,r;return Math.random()<((r=(t=a(this,E).pz)==null?void 0:t.control)!=null?r:0)}getTest(t){var r;return(r=a(this,E).test)==null?void 0:r[t]}computeSignals(t){let r=[];a(this,U).call(this,["debug",200,"GROUP"]);try{a(this,B).forEach(i=>{a(this,U).call(this,["debug",201,"GROUP",i.signal]);try{i.computeSignal(t,r)}finally{a(this,U).call(this,["debug",201,"ENDGROUP"])}})}finally{a(this,U).call(this,["debug",200,"ENDGROUP"])}return r}computeAggregateDimensions(t){var r,i;return Ot(t,(i=(r=a(this,E).pz)==null?void 0:r.agg)!=null?i:{})}getDimensionByKey(t){var i,n,s,o;let r=t.indexOf(L);return r<=0?(n=(i=a(this,E).pz)==null?void 0:i.sig)==null?void 0:n[t]:(o=(s=a(this,E).pz)==null?void 0:s.enr)==null?void 0:o[t.substring(0,r)]}};E=new WeakMap,B=new WeakMap,U=new WeakMap;import{dequal as de}from"dequal/lite";function T(e,t){var o,u,c,l,m,h;let r=(o=t==null?void 0:t.op)!=null?o:"=";if(t.op==="*")return e!==null&&typeof e!="undefined";if(t.op==="!*")return e===null||typeof e=="undefined";if(!("rhs"in t))throw new Error(`Match expression is required for match type ${r}`);let i=(u=t.cs)!=null?u:!1,n=(i?e!=null?e:"":$t(e)).toString(),s=(i?t.rhs:$t(t.rhs)).toString();switch(r){case"=":return n===s;case"!=":return n!==s;case"~":return(c=n.includes(s))!=null?c:!1;case"!~":return!((l=n.includes(s))==null||l);case"//":return new RegExp(t.rhs.toString(),i?"":"i").test((m=e==null?void 0:e.toString())!=null?m:"");case"!//":return!new RegExp(t.rhs.toString(),i?"":"i").test((h=e==null?void 0:e.toString())!=null?h:"");default:throw new Error(`Unknown match type ${r}.`)}}function $(e,t){return`'${("cs"in t?t.cs:!1)?e:e==null?void 0:e.toString().toUpperCase()}' ${mt(t)}`}function mt(e){return"rhs"in e?`${e.op} '${e.cs?e.rhs:e.rhs.toString().toUpperCase()}'`:`${e.op==="*"?"exists":"does not exist"}`}function $t(e){var t,r;return(r=(t=e==null?void 0:e.toString())==null?void 0:t.toUpperCase())!=null?r:""}var At=({update:e,criteria:t,onLogMessage:r})=>{var u,c;if(t.type!=="CK")return{result:!1,changed:!1};let i=!de(Nt(e.state.cookies),Nt((u=e.previousState)==null?void 0:u.cookies)),n=(c=e.state.cookies)==null?void 0:c[t.cookieName],o={result:T(n,t.match),changed:i};return r==null||r(["debug",203,{criteria:t,result:o,explanation:$(n,t.match)}]),o};function Nt(e){if(!e)return;if(!e.ufvd)return e;let{ufvd:t,...r}=e;return r}function Gt(e,t){var i;if(typeof e=="undefined"||e===null)return!1;let r=Number(e);if(isNaN(r))return!1;switch((i=t==null?void 0:t.op)!=null?i:"="){case"=":return r===t.rhs;case"!=":return r!==t.rhs;case">":return r>t.rhs;case"<":return r<t.rhs;default:return console.warn(`Unknown match type ${t.op} is false.`),!1}}function zt(e,t){return`${e} ${fe(t)}`}function fe(e){return`${e.op} ${e.rhs}`}function rt(e,t){return`${e}${L}${t}`}var ht=rt("$pvc","v"),gt=({update:e,criteria:t,commands:r,onLogMessage:i})=>{var l,m;if(t.type!=="PVC")return{result:!1,changed:!1};let n=Boolean(e.state.url&&(!e.previousState||((l=e.state.url)==null?void 0:l.toString())!==((m=e.previousState.url)==null?void 0:m.toString()))),o=(e.visitor.sessionScores[ht]||0)+1,u={result:!1,changed:n},c=r.some(h=>h.type==="modscoreS"&&h.data.dimension===ht);return n&&!c&&r.push({type:"modscoreS",data:{dimension:ht,delta:1}}),Gt(o,t.match)&&(u.result=!0),i==null||i(["debug",203,{criteria:t,result:u,explanation:zt(o,t.match)}]),u};gt.alwaysExecute=!0;var It=({update:e,criteria:t,onLogMessage:r})=>{var u,c,l,m,h;if(t.type!=="QS")return{result:!1,changed:!1};let i=!e.previousState||((c=(u=e.state.url)==null?void 0:u.searchParams)==null?void 0:c.toString())!==((m=(l=e.previousState.url)==null?void 0:l.searchParams)==null?void 0:m.toString()),n=(h=e.state.url)==null?void 0:h.searchParams.get(t.queryName),o={result:T(n,t.match),changed:i};return r==null||r(["debug",203,{criteria:t,result:o,explanation:$(n,t.match)}]),o};var qt=({update:e,criteria:t,signal:r,onLogMessage:i})=>{var m;if(t.type!=="QK")return{result:!1,changed:!1};if(typeof document=="undefined"&&r.dur==="t"&&e.scores[r.id]>0)return{result:!0,changed:!1};let n=e.visitor.quirks[t.key],s=(m=e.state.quirks)==null?void 0:m[t.key],o=s!=null?s:n,u=Boolean(s&&n!==s),l={result:T(o,t.match),changed:u};return i==null||i(["debug",203,{criteria:t,result:l,explanation:$(o,t.match)}]),l};var _t=({update:e,criteria:t,onLogMessage:r})=>{var s,o,u;if(t.type!=="EVT")return{result:!1,changed:!1};let i=(o=(s=e.state.events)==null?void 0:s.some(c=>T(c.event,t.event)))!=null?o:!1,n={result:i,changed:i};return r==null||r(["debug",203,{criteria:t,result:n,explanation:`'${(u=e.state.events)==null?void 0:u.join("', '")}' ${mt(t.event)}`}]),n};var jt=({update:e,criteria:t,onLogMessage:r})=>{var u,c,l;if(t.type!=="PV")return{result:!1,changed:!1};let i=(u=e.state.url)==null?void 0:u.pathname,n=!e.previousState||(i==null?void 0:i.toString())!==((l=(c=e.previousState.url)==null?void 0:c.pathname)==null?void 0:l.toString()),o={result:T(i,t.path),changed:n};return r==null||r(["debug",203,{criteria:t,result:o,explanation:$(i,t.path)}]),o};var J,I=class{constructor(t){d(this,J,void 0);g(this,J,t)}evaluate(t,r,i,n,s){let o=r.clauses.length>1;o&&(s==null||s(["debug",202,"GROUP",r]));try{let u=!(r.op==="&"||!r.op),c=null,l=!1;for(let h of r.clauses){let y;if(h.type==="G")y=this.evaluate(t,h,i,n,s);else{let x=a(this,J)[h.type];if(c&&!x.alwaysExecute)continue;if(!x)throw new Error(`${h.type} signal criteria not registered`);y=x({update:t,criteria:h,commands:i,signal:n,onLogMessage:s})}y.changed&&(l=!0),!c&&y.result===u&&(c={result:u,changed:l})}let m=c!=null?c:{result:!u,changed:l};return o&&(s==null||s(["debug",204,m])),m}finally{o&&(s==null||s(["debug",202,"ENDGROUP"]))}}};J=new WeakMap;var it=()=>({quirks:{},scores:{},sessionScores:{},tests:{},consent:!1,controlGroup:!1});import pe from"mitt";import{dequal as me}from"dequal/lite";var he="__UNIFORM_DATA__",N,q,_=class{constructor({initialData:t}){d(this,N,void 0);d(this,q,pe());C(this,"events",{on:a(this,q).on,off:a(this,q).off});t&&g(this,N,t)}get data(){return a(this,N)}updateData(t,r){return g(this,N,r),this.handleUpdateData(t,r)}async delete(t){g(this,N,void 0),await this.handleDelete(t)}signalAsyncDataUpdate(t){me(this.data,t)||(g(this,N,t),a(this,q).emit("dataUpdatedAsync",t))}getClientTransitionState(){if(typeof document=="undefined")return;let t=document.getElementById(he);return t!=null&&t.textContent?JSON.parse(t.textContent):void 0}};N=new WeakMap,q=new WeakMap;var vt="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Qt=vt.split(""),Ft=new Array(123);for(let e=0;e<vt.length;e++)Ft[vt.charCodeAt(e)]=e;var St=e=>{if(e<0)return`-${St(-e)}`;let t=e>>>0,r=e/4294967296>>>0,i="";for(;r>0;)i=Qt[63&t]+i,t>>>=6,t|=(63&r)<<26,r>>>=6;let n="";do n=Qt[63&t]+n,t>>>=6;while(t>0);return n+i},Kt=e=>{let t=0,r=e.charAt(0)==="-"?1:0;for(let i=r;i<e.length;i++)t=t*64+Ft[e.charCodeAt(i)];return r?-t:t};import yt from"js-cookie";var Dt=typeof document=="undefined",ge="ufvd",A,W,Ht=class extends _{constructor({serverCookieValue:r,cookieName:i=ge,cookieAttributes:n={sameSite:"lax"}}){super({initialData:Dt?ve(r):void 0});d(this,A,void 0);d(this,W,void 0);g(this,A,i),g(this,W,n)}handleDelete(){return Dt||yt.remove(a(this,A)),Promise.resolve()}async handleUpdateData(r,i){Dt||(i.consent?yt.set(a(this,A),Se(i),a(this,W)):yt.remove(a(this,A)))}};A=new WeakMap,W=new WeakMap;var Wt="~",Yt="!",Xt="-";function ve(e){if(!e)return;let t=e.split(Wt);if(t.length>3)return;let[r,i,n]=t;return{consent:!0,sessionScores:Bt(Ct(i)),scores:Bt(Ct(n)),tests:Ct(r)}}function Ct(e){return e.split(Yt).map(r=>r.split(Xt)).reduce((r,i)=>(i.length!==2||(r[i[0]]=i[1]),r),{})}function Bt(e){return Object.entries(e).reduce((t,[r,i])=>(t[r]=Kt(i),t),{})}function Se(e){return[xt(e.tests),xt(Jt(e.sessionScores)),xt(Jt(e.scores))].join(Wt)}function Jt(e){return Object.entries(e).reduce((t,[r,i])=>(t[r]=St(i),t),{})}function xt(e){return Object.entries(e).map(t=>t.join(Xt)).join(Yt)}var nt,Mt,Zt=class extends _{constructor({serverCookieValue:r,visitorIdCookieName:i="ufvi",...n}){super(n);d(this,nt);n.initialData||D(this,nt,Mt).call(this).catch(s=>{console.error(s)})}handleDelete(r){throw new Error("Method not implemented.")}async handleUpdateData(r){let i=await new Promise(n=>{setTimeout(()=>{n(void 0)},2e3)});i&&this.signalAsyncDataUpdate(i)}};nt=new WeakSet,Mt=async function(){let r=await new Promise(i=>{setTimeout(()=>{i(void 0)},2e3)});r&&this.signalAsyncDataUpdate(r)};function wr(e){let{gracePeriod:t=864e5,decayRate:r=1/30,decayCap:i=.95}=e!=null?e:{};return function({now:s,lastUpd:o,scores:u,sessionScores:c,onLogMessage:l}){if(typeof o!="number")return!1;let h=s-o-t;if(h<=0)return!1;let y=h/864e5,x=1-Math.min(i,y*r);return x<=0?!1:(Lt(u,x),Lt(c,x),l==null||l(["info",140,`linear decay factor ${x.toPrecision(6)}`]),!0)}}function Lt(e,t){for(let r in e)r.startsWith("$")||(e[r]*=t)}import Ce from"mitt";import{dequal as st}from"dequal/lite";var ot=class{constructor(){C(this,"inMemoryFallback",{});C(this,"hasLocalStorageObject",typeof localStorage!="undefined")}get(t){let r=this.inMemoryFallback[t];if(!this.hasLocalStorageObject||r)return r;try{let i=localStorage.getItem(t);return i?JSON.parse(i):void 0}catch(i){return r}}set(t,r,i){if(this.inMemoryFallback[t]=r,!(!this.hasLocalStorageObject||!i))try{localStorage.setItem(t,JSON.stringify(r))}catch(n){console.warn(n)}}delete(t,r){r||delete this.inMemoryFallback[t];try{localStorage.removeItem(t)}catch(i){}}};import ye from"rfdc";var De=ye();function te(e,t,r){let i=t?De(t):it();return e.forEach(n=>{var s,o;switch(n.type){case"consent":i.consent=n.data;break;case"setquirk":i.quirks[n.data.key]=n.data.value;break;case"settest":i.tests[n.data.test]=n.data.variant;break;case"modscore":if(r)break;let u=Number(n.data.delta);if(isNaN(u))throw new Error("Non-number delta received");let c=(s=i.scores[n.data.dimension])!=null?s:0;i.scores[n.data.dimension]=c+u;break;case"modscoreS":if(r)break;let l=Number(n.data.delta);if(isNaN(l))throw new Error("Non-number delta received");let m=(o=i.sessionScores[n.data.dimension])!=null?o:0;i.sessionScores[n.data.dimension]=m+l;break;case"identify":break;case"setcontrol":i.controlGroup=n.data;break;default:throw new Error("Unknown command")}}),i}var at="ufvisitor",k,z,j,S,V,w,R,G,lt,ee,ct,re,Y,bt,X,Vt,ut=class{constructor(t){d(this,V);d(this,R);d(this,lt);d(this,ct);d(this,Y);d(this,X);d(this,k,Ce());d(this,z,new ot);d(this,j,void 0);d(this,S,void 0);C(this,"events",{on:a(this,k).on,off:a(this,k).off});if(g(this,S,t),a(this,V,w)||D(this,R,G).call(this,D(this,X,Vt).call(this),!0),t.transitionStore){let r=t.transitionStore.getClientTransitionState();r&&t.onServerTransitionReceived&&t.onServerTransitionReceived(r),t.transitionStore.events.on("dataUpdatedAsync",n=>{D(this,R,G).call(this,{...a(this,V,w).visitorData,...n})});let i=t.transitionStore.data;i&&D(this,R,G).call(this,{...a(this,V,w).visitorData,...i},!0)}}get data(){var r,i;let t=a(this,V,w);if(D(this,ct,re).call(this,t)){let{sessionScores:n,...s}=t.visitorData;return D(this,R,G).call(this,{...s,sessionScores:{}}),(i=(r=a(this,S)).onLogMessage)==null||i.call(r,["info",120]),a(this,V,w).visitorData}return t.visitorData}get decayEnabled(){return!!a(this,S).decay}async updateData(t){var i,n,s,o;if(t.length===0)return;(n=(i=a(this,S)).onLogMessage)==null||n.call(i,["debug",101,t]);let r=te(t,this.data,(s=a(this,V,w))==null?void 0:s.visitorData.controlGroup);t.some(u=>u.type==="consent"&&!u.data)&&a(this,z).delete(at,!0),D(this,R,G).call(this,r),await((o=a(this,S).transitionStore)==null?void 0:o.updateData(t,a(this,V,w).visitorData))}async delete(t){var r,i,n,s,o;(i=(r=a(this,S)).onLogMessage)==null||i.call(r,["info",103,"GROUP",t]);try{a(this,z).delete(at,!1),await((n=a(this,S).transitionStore)==null?void 0:n.delete(t)),D(this,R,G).call(this,D(this,X,Vt).call(this))}finally{(o=(s=a(this,S)).onLogMessage)==null||o.call(s,["info",103,"ENDGROUP"])}}};k=new WeakMap,z=new WeakMap,j=new WeakMap,S=new WeakMap,V=new WeakSet,w=function(){return a(this,z).get(at)},R=new WeakSet,G=function(t,r=!1){var m,h,y,x,M,kt,Pt,wt,Rt;let i=a(this,V,w),n=Date.now();t.controlGroup?(t.scores={},t.sessionScores={}):(D(this,Y,bt).call(this,t.scores),D(this,Y,bt).call(this,t.sessionScores),(h=(m=a(this,S)).decay)==null||h.call(m,{now:n,lastUpd:i==null?void 0:i.updated,scores:t.scores,sessionScores:t.sessionScores,onLogMessage:a(this,S).onLogMessage}));let s=!st(i==null?void 0:i.visitorData.scores,t.scores),o=!st(i==null?void 0:i.visitorData.sessionScores,t.sessionScores),u=!st(i==null?void 0:i.visitorData.quirks,t.quirks),c=!st(i==null?void 0:i.visitorData.tests,t.tests),l={updated:n,visitorData:t};D(this,lt,ee).call(this),a(this,z).set(at,l,!!t.consent),(x=(y=a(this,S)).onLogMessage)==null||x.call(y,["debug",102,t]),r||((s||o)&&a(this,k).emit("scoresUpdated",t),u&&a(this,k).emit("quirksUpdated",t),c&&a(this,k).emit("testsUpdated",t),((M=i==null?void 0:i.visitorData)==null?void 0:M.consent)!==t.consent&&a(this,k).emit("consentUpdated",t),((kt=i==null?void 0:i.visitorData)==null?void 0:kt.controlGroup)!==t.controlGroup&&(a(this,k).emit("controlGroupUpdated",t),(Rt=(wt=a(this,S)).onLogMessage)==null||Rt.call(wt,["debug",104,(Pt=t.controlGroup)!=null?Pt:!1])))},lt=new WeakSet,ee=function(){typeof document=="undefined"||!a(this,S).visitLifespan||(a(this,j)&&window.clearTimeout(a(this,j)),g(this,j,window.setTimeout(()=>{this.data},a(this,S).visitLifespan+50)))},ct=new WeakSet,re=function(t){let r=a(this,S).visitLifespan;return r?t.updated+r<Date.now():!1},Y=new WeakSet,bt=function(t){var r,i;if(!!a(this,S).manifest)for(let n in t){let s=t[n],o=a(this,S).manifest.getDimensionByKey(n);!o||s>o.cap&&((i=(r=a(this,S)).onLogMessage)==null||i.call(r,["debug",110,{dim:n,score:s,cap:o.cap}]),t[n]=o.cap)}},X=new WeakSet,Vt=function(){var t,r,i;return{...it(),consent:(t=a(this,S).defaultConsent)!=null?t:!1,controlGroup:(i=(r=a(this,S).manifest)==null?void 0:r.rollForControlGroup())!=null?i:!1}};import be from"mitt";function ie({name:e,context:t,variations:r,take:i=1,onLogMessage:n}){var s,o,u;n==null||n(["info",300,"GROUP",{name:e,take:i}]);try{let c=(s=t.storage.data.controlGroup)!=null?s:!1,l=[],m=!1,h=t.scores;for(let y of r){if(l.length===i)break;if(!((o=y.pz)!=null&&o.crit.length)){n==null||n(["info",301,"GROUP",{id:y.id,op:(u=y.pz)==null?void 0:u.op}]),n==null||n(["info",302,{matched:!0,description:"default variation"}]),n==null||n(["info",303,!0]),n==null||n(["info",301,"ENDGROUP"]),l.push(y);continue}c||ne(y.id,y.pz,h,n)&&(m=!0,l.push(y))}return{personalized:m,variations:l}}finally{n==null||n(["info",300,"ENDGROUP"])}}function ne(e,t,r,i){i==null||i(["info",301,"GROUP",{id:e,op:t==null?void 0:t.op}]);let n;try{t!=null&&t.crit?!t.op||t.op==="&"?n=t.crit.every(s=>oe(s,r,i)):n=t.crit.some(s=>oe(s,r,i)):(i==null||i(["info",302,{matched:!0,description:"default variation"}]),n=!0),i==null||i(["info",303,n])}finally{i==null||i(["info",301,"ENDGROUP"])}return n}function oe(e,t,r){var u,c;let{op:i,l:n}=e,s=(u=t[n])!=null?u:0;if(i==="+"){let l=Math.max(...Object.values(t))===s&&s>0;return r==null||r(["info",302,{matched:l,description:`${e.l} has the highest score`}]),l}else if(i==="-"){let l=Math.min(...Object.values(t))===s&&s>0;return r==null||r(["info",302,{matched:l,description:`${e.l} has the lowest non-zero score`}]),l}let o=parseInt(e.rDim?t[e.rDim]:e.r,10);if(isNaN(o))return r==null||r(["info",302,{matched:!1,description:`${(c=e.rDim)!=null?c:e.r} has no score value`}]),!1;if(i===">"){let l=s>o;return Q(r,l,e,s,o),l}else if(i===">="){let l=s>=o;return Q(r,l,e,s,o),l}else if(i==="<"){let l=s<o;return Q(r,l,e,s,o),l}else if(i==="<="){let l=s<=o;return Q(r,l,e,s,o),l}else if(i==="="){let l=s===o;return Q(r,l,e,s,o),l}else if(i==="!="){let l=s!==o;return Q(r,l,e,s,o),l}else throw new Error(`Unknown op: ${i}`)}function Q(e,t,r,i,n){e==null||e(["info",302,{matched:t,description:`${r.l}[${i}] ${r.op} ${r.rDim?`${r.rDim}[${n}]`:r.r}`}])}var xe=e=>{let{values:t,total:r,missingDistribution:i}=e.reduce((n,s)=>(s.testDistribution?n.total+=s.testDistribution:++n.missingDistribution,n.values.push(s.testDistribution),n),{values:[],total:0,missingDistribution:0});if(r>100)throw new Error(`Total distribution ${r} is over the maximum 100.`);if(r<100){let s=(100-r)/i;t.forEach((o,u)=>{typeof o=="undefined"&&(t[u]=s)})}return t},Et=({name:e,context:t,variations:r,onLogMessage:i})=>{i==null||i(["info",400,"GROUP",e]);try{let n,s=t.getTestVariantId(e);if(s===null)return i==null||i(["error",401,e]),{result:void 0,variantAssigned:!1};if(s&&(n=r.find(o=>o.id===s),n||i==null||i(["warn",402,{missingVariant:s,variants:r.map(o=>o.id)}])),!n){let o=xe(r),u=Math.floor(Math.random()*100),c=0;n=r.find((l,m)=>{let h=o[m];if(u>c&&u<=c+h)return l;c+=h}),n&&(i==null||i(["info",403,n.id]),t.setTestVariantId(e,n.id))}return n&&(i==null||i(["info",404,n.id])),{result:n,variantAssigned:!s}}finally{i==null||i(["info",400,"ENDGROUP"])}};import{dequal as se}from"dequal/lite";var b,O,P,Z,v,F,dt,ae=class{constructor(t){d(this,F);C(this,"manifest");d(this,b,void 0);d(this,O,{});d(this,P,void 0);d(this,Z,{});d(this,v,be());C(this,"events",{on:a(this,v).on,off:a(this,v).off});C(this,"storage");var n,s;let{manifest:r,...i}=t;g(this,P,{}),(n=t.plugins)==null||n.forEach(o=>{!o.logDrain||a(this,v).on("log",o.logDrain)}),a(this,v).emit("log",["info",1,"GROUP"]);try{this.manifest=new et({onLogMessage:o=>a(this,v).emit("log",o),manifest:r,evaluator:new I({CK:At,QS:It,QK:qt,PVC:gt,EVT:_t,PV:jt})}),this.storage=new ut({...i,manifest:this.manifest,onServerTransitionReceived:o=>{g(this,b,o),o.ssv&&(g(this,O,o.ssv),a(this,v).emit("log",["debug",130,o.ssv]))},onLogMessage:o=>a(this,v).emit("log",o)}),this.storage.events.on("scoresUpdated",D(this,F,dt).bind(this)),a(this,b)||D(this,F,dt).call(this,this.storage.data),this.storage.events.on("quirksUpdated",o=>{let u=this.manifest.computeSignals({scores:a(this,O),state:a(this,P),previousState:a(this,P),visitor:this.storage.data});this.storage.updateData(u),a(this,v).emit("quirksUpdated",o.quirks),a(this,v).emit("log",["info",4,o.quirks])}),(s=t.plugins)==null||s.forEach(o=>{!o.init||o.init(this)})}finally{a(this,v).emit("log",["info",1,"ENDGROUP"])}}get scores(){return a(this,O)}get quirks(){var t,r;return(r=(t=a(this,b))==null?void 0:t.quirks)!=null?r:this.storage.data.quirks}async update(t){var i,n,s;let r=[];(i=a(this,b))!=null&&i.quirks&&(t={...t,quirks:{...a(this,b).quirks,...t.quirks||{}}}),(n=a(this,b))!=null&&n.tests&&r.push(...Object.entries(a(this,b).tests).map(([o,u])=>({type:"settest",data:{test:o,variant:u}})));try{a(this,v).emit("log",["info",2,"GROUP",{...t,url:(s=t.url)==null?void 0:s.toString()}]),t.quirks&&r.push(...Object.entries(t.quirks).map(([o,u])=>({type:"setquirk",data:{key:o,value:u}}))),t.enrichments&&t.enrichments.forEach(o=>{let u=rt(o.cat,o.key);this.manifest.getDimensionByKey(u)?r.push({type:"modscore",data:{dimension:u,delta:o.str}}):a(this,v).emit("log",["warn",5,o])}),r.push(...this.manifest.computeSignals({state:t,previousState:a(this,P),visitor:this.storage.data,scores:a(this,O)})),g(this,P,{...a(this,P),...t}),await this.storage.updateData(r),a(this,b)&&(D(this,F,dt).call(this,this.storage.data),g(this,b,void 0),a(this,v).emit("log",["debug",131]))}finally{a(this,v).emit("log",["info",2,"ENDGROUP"])}}getTestVariantId(t){var i;let r=this.manifest.getTest(t);return r?(i=r.wv)!=null?i:this.storage.data.tests[t]:(a(this,v).emit("log",["warn",401,t]),null)}setTestVariantId(t,r){this.storage.updateData([{type:"settest",data:{test:t,variant:r}}])}log(...t){a(this,v).emit("log",t)}test(t){var i,n;let r=Et({...t,context:this,onLogMessage:s=>a(this,v).emit("log",s)});return a(this,v).emit("testResult",{name:t.name,variantId:(n=(i=r.result)==null?void 0:i.id)!=null?n:void 0,variantAssigned:r.variantAssigned}),r}personalize(t){let r=ie({...t,context:this,onLogMessage:s=>a(this,v).emit("log",s)}),i=a(this,Z)[t.name],n={name:t.name,variantIds:r.variations.map(s=>{var o;return(o=s.id)!=null?o:"Unknown"}),control:this.storage.data.controlGroup,changed:!0};return i&&se(n.variantIds,i)&&(n.changed=!1),a(this,v).emit("personalizationResult",n),a(this,Z)[t.name]=n.variantIds,r}async forget(t){g(this,P,{}),await this.storage.delete(t)}};b=new WeakMap,O=new WeakMap,P=new WeakMap,Z=new WeakMap,v=new WeakMap,F=new WeakSet,dt=function(t){var n;let r={...t.scores};for(let s in t.sessionScores)r[s]=((n=r[s])!=null?n:0)+t.sessionScores[s];r=this.manifest.computeAggregateDimensions(r),!se(r,a(this,O))&&(g(this,O,r),a(this,v).emit("scoresUpdated",r),a(this,v).emit("log",["info",3,r]))};import Ve from"rfdc";function ft(e,t){if(e==="none")return!1;switch(t){case"debug":return e==="debug";case"info":return e==="info"||e==="debug";case"warn":return e==="warn"||e==="info"||e==="debug";case"error":return e==="debug"||"info";default:return!1}}var Ee=Ve();function Te(e){return([t,...r])=>{if(!ft(e,t))return;let[i,...n]=r;console[t](`\u{1F94B} [${t}] Uniform event ID ${i}
`,...n.map(Ee))}}function mi(e){return{logDrain:Te(e)}}var ue={1:()=>["context","initializing Uniform Context"],2:e=>["context","received update()",e],3:e=>["context","new score vector",e],4:e=>["context","updated quirks",e],5:e=>["context","ignored enrichment update for unknown enrichment category",e.cat],101:e=>["storage","received update commands",e],102:e=>["storage","data was updated",e],103:e=>["storage",`deleting visitor data ${e?"from all devices":"from this device"}`],104:e=>["context",e?"Visitor assigned to personalization control group":"Visitor assigned to personalization experiment group"],110:({dim:e,cap:t,score:r})=>["storage",`${e} score ${r} exceeded cap ${t}. Rounded down.`],120:()=>["storage","visitor data expired and was cleared"],130:e=>["storage","server to client transition score data was loaded; it will persist until the next update event occurs",e],131:()=>["storage","server to client transition data was discarded"],140:e=>["storage",`score decay was applied: ${e}`],200:()=>["signals","evaluating signals"],201:e=>["signals",`evaluating signal ${e.id} (${e.dur})`],202:e=>["signals",e.op==="|"?"OR":"AND"],203:({criteria:e,result:t,explanation:r})=>["signals",`${e.type}: ${r} is ${t.result} [${t.changed?"CHANGED":"unchanged"}]`],204:e=>["signals",`group result: ${e.result} [${e.changed?"CHANGED":"unchanged"}]`],300:e=>["personalization",`executing personalization '${e.name}'`],301:({id:e,op:t})=>["personalization",`testing variation ${e} (${t==="|"?"OR":"AND"})`],302:({matched:e,description:t})=>["personalization",`${t} is ${e}`],303:e=>["personalization",e?"selected variation":"did not select variation"],400:e=>["testing",`executing A/B test '${e}'`],401:e=>["testing",`${e} is not registered in the manifest; it will not be run.`],402:({missingVariant:e,variants:t})=>["testing",`test variation '${e}' previously assigned to the visitor for this test no longer exists as a variant. It will be removed. This may indicate changing test variations after publishing a test, which will make results invalid. Known variants: ${t.join(", ")}`],403:e=>["testing",`assigned new test variant '${e}'`],404:e=>["testing",`displaying variation '${e}'`],700:()=>["gtag","gtag is not defined, skipping analytics event emission. Ensure you have added the gtag script to your page."],701:()=>["gtag","enabled gtag event signal redirection"]};import ke from"rfdc";var Pe=ke();function we(e,t){let r=typeof document=="undefined",{enableOnServer:i=!1}=t!=null?t:{};return([n,...s])=>{if(!ft(e,n)||r&&!i)return;let[o,...u]=s,c=console[n];if(u[0]==="GROUP"&&(u.shift(),c=console.groupCollapsed),u[0]==="ENDGROUP"){console.groupEnd();return}let l=ue[o],m="";switch(n){case"debug":m="\u{1F41E}";break;case"info":m="\u{1F4AC}";break;case"warn":m="\u26A0\uFE0F";break;case"error":m="\u{1F4A5}";break}let h=m;if(!l){c(`${h} unknown event ID ${o}. Log messages data may be older than Uniform Context package.`,...u);return}let[y,x,...M]=l(...u);c(`${h}[${y}] ${x}
`,...M.map(Pe))}}function Di(e,t){return{logDrain:we(e,t)}}var Re=(u=>(u.ListStart="nesi-list-start",u.ListEnd="nesi-list-end",u.ListItem="nesi-list-item-html",u.ListItemSettings="nesi-list-item-settings",u.TestStart="nesi-test-start",u.TestEnd="nesi-test-end",u.Unknown="unknown",u))(Re||{}),xi="nesitag";var Tt=typeof top!="undefined";function Vi(){return{logDrain:e=>{!Tt||top==null||top.postMessage({type:"uniform:context:log",message:e},window.location.origin)},init:e=>{let t=[],r=[],i=()=>{!Tt||top==null||top.postMessage({type:"uniform:context:data",data:{scores:e.scores,data:e.storage.data,manifest:e.manifest.data,personalizations:t,tests:r}},window.location.origin)},n=o=>{!o.changed||(t.push(o),i())},s=o=>{!o.variantAssigned||(r.push(o),i())};if(Tt){window.__UNIFORM_DEVTOOLS_CONTEXT_INSTANCE__=e;try{top==null||top.addEventListener("message",async o=>{if(!o.data)return;let u=o.data;await Oe(u,e)})}catch(o){console.warn("Unable to initialize Uniform Context DevTools because it is in a cross-domain iframe.",o)}top==null||top.postMessage({type:"uniform:context:hello",uiVersion:2},window.location.origin),i()}return e.events.on("personalizationResult",n),e.events.on("testResult",s),e.events.on("scoresUpdated",i),e.storage.events.on("*",i),()=>{e.events.off("scoresUpdated",i),e.storage.events.off("*",i),e.events.off("personalizationResult",n),e.events.off("testResult",s)}}}}async function Oe(e,t){e.type==="uniform-in:context:update"&&e.newData&&await t.update(e.newData),e.type==="uniform-in:context:commands"&&e.commands&&Array.isArray(e.commands)&&await t.storage.updateData(e.commands),e.type==="uniform-in:context:forget"&&await t.forget(!1)}function Ti(e){return`${e.apiKey}|${e.projectId}${e.apiHost?`|${e.apiHost}`:""}`}function ki(e){let[t,r,i]=e.split("|");if(!t.startsWith("uf"))throw new Error("Invalid API key");if(!/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12})$/i.test(r))throw new Error("Invalid project ID");return{apiKey:t,projectId:r,apiHost:i||"https://uniform.app"}}export{ae as Context,Ht as CookieTransitionDataStore,xi as EdgeNodeTagName,Zt as EdgeTransitionDataStore,I as GroupCriteriaEvaluator,et as ManifestInstance,he as SERVER_STATE_ID,Re as ScriptType,_ as TransitionDataStore,ge as UNIFORM_DEFAULT_COOKIE_NAME,ut as VisitorDataStore,Ot as computeAggregateDimensions,At as cookieEvaluator,Te as createConsoleLogDrain,we as createDebugConsoleLogDrain,wr as createLinearDecay,jt as currentPageEvaluator,it as emptyVisitorData,mi as enableConsoleLogDrain,Vi as enableContextDevTools,Di as enableDebugConsoleLogDrain,ne as evaluateVariantMatch,_t as eventEvaluator,$ as explainStringMatch,mt as explainStringMatchCriteria,rt as getEnrichmentVectorKey,T as isStringMatch,ht as pageViewCountDimension,gt as pageViewCountEvaluator,ki as parseQuickConnect,ie as personalizeVariations,It as queryStringEvaluator,qt as quirkEvaluator,Ti as serializeQuickConnect,Et as testVariations};
"use strict";var ae=Object.defineProperty;var ue=(e,t,r)=>t in e?ae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var y=(e,t,r)=>(ue(e,typeof t!="symbol"?t+"":t,r),r),dt=(e,t,r)=>{if(!t.has(e))throw TypeError("Cannot "+r)};var a=(e,t,r)=>(dt(e,t,"read from private field"),r?r.call(e):t.get(e)),d=(e,t,r)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,r)},m=(e,t,r,i)=>(dt(e,t,"write to private field"),i?i.call(e,r):t.set(e,r),r);var S=(e,t,r)=>(dt(e,t,"access private method"),r);function wt(e,t){let r={...e};for(let i in t){let n=Rt(e,i,t,new Set([i]));n!==0&&(r[i]=n)}return r}function Rt(e,t,r,i){var s;let n=0;for(let o of r[t].inputs){let u=(s=e[o.dim])!=null?s:0;if(!u&&r[o.dim]){if(i.has(o.dim))continue;let l=new Set(i);l.add(o.dim),u=Rt(e,o.dim,r,l)}if(u!==0)if(o.sign==="c"){n=0;break}else o.sign==="-"?n-=u:n+=u}return n}var Z="_";var Q,F,M=class{constructor(t,r,i){d(this,Q,void 0);d(this,F,void 0);y(this,"signal");this.signal=t,m(this,Q,r),m(this,F,i)}computeSignal(t,r){if(t.scores[this.signal.id]>=this.signal.cap&&this.signal.dur!=="t")return;let n=a(this,Q).evaluate(t,this.signal.crit,r,this.signal,a(this,F)),s=this.signal.dur==="s"||this.signal.dur==="t"?"modscoreS":"modscore";if(!!n.changed){if(n.result)r.push({type:s,data:{dimension:this.signal.id,delta:this.signal.str}});else if(this.signal.dur==="t"){let o=t.visitor.sessionScores[this.signal.id];o&&r.push({type:s,data:{dimension:this.signal.id,delta:-o}})}}}};Q=new WeakMap,F=new WeakMap;var b,K,R,L=class{constructor({manifest:t,evaluator:r=new G({}),onLogMessage:i=()=>{}}){y(this,"data");d(this,b,void 0);d(this,K,void 0);d(this,R,void 0);var n,s,o;m(this,b,(n=t.project)!=null?n:{}),this.data=t,m(this,K,Object.entries((o=(s=a(this,b).pz)==null?void 0:s.sig)!=null?o:[]).map(([u,c])=>new M({...c,id:u},r,i))),m(this,R,i)}rollForControlGroup(){var t,r;return Math.random()<((r=(t=a(this,b).pz)==null?void 0:t.control)!=null?r:0)}getTest(t){var r;return(r=a(this,b).test)==null?void 0:r[t]}computeSignals(t){let r=[];a(this,R).call(this,["debug",200,"GROUP"]);try{a(this,K).forEach(i=>{a(this,R).call(this,["debug",201,"GROUP",i.signal]);try{i.computeSignal(t,r)}finally{a(this,R).call(this,["debug",201,"ENDGROUP"])}})}finally{a(this,R).call(this,["debug",200,"ENDGROUP"])}return r}computeAggregateDimensions(t){var r,i;return wt(t,(i=(r=a(this,b).pz)==null?void 0:r.agg)!=null?i:{})}getDimensionByKey(t){var i,n,s,o;let r=t.indexOf(Z);return r<=0?(n=(i=a(this,b).pz)==null?void 0:i.sig)==null?void 0:n[t]:(o=(s=a(this,b).pz)==null?void 0:s.enr)==null?void 0:o[t.substring(0,r)]}};b=new WeakMap,K=new WeakMap,R=new WeakMap;import{dequal as le}from"dequal/lite";function V(e,t){var o,u,c,l,f,p;let r=(o=t==null?void 0:t.op)!=null?o:"=";if(t.op==="*")return e!==null&&typeof e!="undefined";if(t.op==="!*")return e===null||typeof e=="undefined";if(!("rhs"in t))throw new Error(`Match expression is required for match type ${r}`);let i=(u=t.cs)!=null?u:!1,n=(i?e!=null?e:"":Ot(e)).toString(),s=(i?t.rhs:Ot(t.rhs)).toString();switch(r){case"=":return n===s;case"!=":return n!==s;case"~":return(c=n.includes(s))!=null?c:!1;case"!~":return!((l=n.includes(s))==null||l);case"//":return new RegExp(t.rhs.toString(),i?"":"i").test((f=e==null?void 0:e.toString())!=null?f:"");case"!//":return!new RegExp(t.rhs.toString(),i?"":"i").test((p=e==null?void 0:e.toString())!=null?p:"");default:throw new Error(`Unknown match type ${r}.`)}}function O(e,t){return`'${("cs"in t?t.cs:!1)?e:e==null?void 0:e.toString().toUpperCase()}' ${ft(t)}`}function ft(e){return"rhs"in e?`${e.op} '${e.cs?e.rhs:e.rhs.toString().toUpperCase()}'`:`${e.op==="*"?"exists":"does not exist"}`}function Ot(e){var t,r;return(r=(t=e==null?void 0:e.toString())==null?void 0:t.toUpperCase())!=null?r:""}var $t=({update:e,criteria:t,onLogMessage:r})=>{var u,c;if(t.type!=="CK")return{result:!1,changed:!1};let i=!le(Ut(e.state.cookies),Ut((u=e.previousState)==null?void 0:u.cookies)),n=(c=e.state.cookies)==null?void 0:c[t.cookieName],o={result:V(n,t.match),changed:i};return r==null||r(["debug",203,{criteria:t,result:o,explanation:O(n,t.match)}]),o};function Ut(e){if(!e)return;if(!e.ufvd)return e;let{ufvd:t,...r}=e;return r}function Nt(e,t){var i;if(typeof e=="undefined"||e===null)return!1;let r=Number(e);if(isNaN(r))return!1;switch((i=t==null?void 0:t.op)!=null?i:"="){case"=":return r===t.rhs;case"!=":return r!==t.rhs;case">":return r>t.rhs;case"<":return r<t.rhs;default:return console.warn(`Unknown match type ${t.op} is false.`),!1}}function At(e,t){return`${e} ${ce(t)}`}function ce(e){return`${e.op} ${e.rhs}`}function tt(e,t){return`${e}${Z}${t}`}var pt=tt("$pvc","v"),mt=({update:e,criteria:t,commands:r,onLogMessage:i})=>{var l,f;if(t.type!=="PVC")return{result:!1,changed:!1};let n=Boolean(e.state.url&&(!e.previousState||((l=e.state.url)==null?void 0:l.toString())!==((f=e.previousState.url)==null?void 0:f.toString()))),o=(e.visitor.sessionScores[pt]||0)+1,u={result:!1,changed:n},c=r.some(p=>p.type==="modscoreS"&&p.data.dimension===pt);return n&&!c&&r.push({type:"modscoreS",data:{dimension:pt,delta:1}}),Nt(o,t.match)&&(u.result=!0),i==null||i(["debug",203,{criteria:t,result:u,explanation:At(o,t.match)}]),u};mt.alwaysExecute=!0;var Gt=({update:e,criteria:t,onLogMessage:r})=>{var u,c,l,f,p;if(t.type!=="QS")return{result:!1,changed:!1};let i=!e.previousState||((c=(u=e.state.url)==null?void 0:u.searchParams)==null?void 0:c.toString())!==((f=(l=e.previousState.url)==null?void 0:l.searchParams)==null?void 0:f.toString()),n=(p=e.state.url)==null?void 0:p.searchParams.get(t.queryName),o={result:V(n,t.match),changed:i};return r==null||r(["debug",203,{criteria:t,result:o,explanation:O(n,t.match)}]),o};var zt=({update:e,criteria:t,signal:r,onLogMessage:i})=>{var f;if(t.type!=="QK")return{result:!1,changed:!1};if(typeof document=="undefined"&&r.dur==="t"&&e.scores[r.id]>0)return{result:!0,changed:!1};let n=e.visitor.quirks[t.key],s=(f=e.state.quirks)==null?void 0:f[t.key],o=s!=null?s:n,u=Boolean(s&&n!==s),l={result:V(o,t.match),changed:u};return i==null||i(["debug",203,{criteria:t,result:l,explanation:O(o,t.match)}]),l};var It=({update:e,criteria:t,onLogMessage:r})=>{var s,o,u;if(t.type!=="EVT")return{result:!1,changed:!1};let i=(o=(s=e.state.events)==null?void 0:s.some(c=>V(c.event,t.event)))!=null?o:!1,n={result:i,changed:i};return r==null||r(["debug",203,{criteria:t,result:n,explanation:`'${(u=e.state.events)==null?void 0:u.join("', '")}' ${ft(t.event)}`}]),n};var qt=({update:e,criteria:t,onLogMessage:r})=>{var u,c,l;if(t.type!=="PV")return{result:!1,changed:!1};let i=(u=e.state.url)==null?void 0:u.pathname,n=!e.previousState||(i==null?void 0:i.toString())!==((l=(c=e.previousState.url)==null?void 0:c.pathname)==null?void 0:l.toString()),o={result:V(i,t.path),changed:n};return r==null||r(["debug",203,{criteria:t,result:o,explanation:O(i,t.path)}]),o};var H,G=class{constructor(t){d(this,H,void 0);m(this,H,t)}evaluate(t,r,i,n,s){let o=r.clauses.length>1;o&&(s==null||s(["debug",202,"GROUP",r]));try{let u=!(r.op==="&"||!r.op),c=null,l=!1;for(let p of r.clauses){let v;if(p.type==="G")v=this.evaluate(t,p,i,n,s);else{let D=a(this,H)[p.type];if(c&&!D.alwaysExecute)continue;if(!D)throw new Error(`${p.type} signal criteria not registered`);v=D({update:t,criteria:p,commands:i,signal:n,onLogMessage:s})}v.changed&&(l=!0),!c&&v.result===u&&(c={result:u,changed:l})}let f=c!=null?c:{result:!u,changed:l};return o&&(s==null||s(["debug",204,f])),f}finally{o&&(s==null||s(["debug",202,"ENDGROUP"]))}}};H=new WeakMap;var et=()=>({quirks:{},scores:{},sessionScores:{},tests:{},consent:!1,controlGroup:!1});import de from"mitt";import{dequal as fe}from"dequal/lite";var pe="__UNIFORM_DATA__",U,z,I=class{constructor({initialData:t}){d(this,U,void 0);d(this,z,de());y(this,"events",{on:a(this,z).on,off:a(this,z).off});t&&m(this,U,t)}get data(){return a(this,U)}updateData(t,r){return m(this,U,r),this.handleUpdateData(t,r)}async delete(t){m(this,U,void 0),await this.handleDelete(t)}signalAsyncDataUpdate(t){fe(this.data,t)||(m(this,U,t),a(this,z).emit("dataUpdatedAsync",t))}getClientTransitionState(){if(typeof document=="undefined")return;let t=document.getElementById(pe);return t!=null&&t.textContent?JSON.parse(t.textContent):void 0}};U=new WeakMap,z=new WeakMap;var ht="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",_t=ht.split(""),jt=new Array(123);for(let e=0;e<ht.length;e++)jt[ht.charCodeAt(e)]=e;var gt=e=>{if(e<0)return`-${gt(-e)}`;let t=e>>>0,r=e/4294967296>>>0,i="";for(;r>0;)i=_t[63&t]+i,t>>>=6,t|=(63&r)<<26,r>>>=6;let n="";do n=_t[63&t]+n,t>>>=6;while(t>0);return n+i},Qt=e=>{let t=0,r=e.charAt(0)==="-"?1:0;for(let i=r;i<e.length;i++)t=t*64+jt[e.charCodeAt(i)];return r?-t:t};import vt from"js-cookie";var St=typeof document=="undefined",me="ufvd",$,B,Ft=class extends I{constructor({serverCookieValue:r,cookieName:i=me,cookieAttributes:n={sameSite:"lax"}}){super({initialData:St?he(r):void 0});d(this,$,void 0);d(this,B,void 0);m(this,$,i),m(this,B,n)}handleDelete(){return St||vt.remove(a(this,$)),Promise.resolve()}async handleUpdateData(r,i){St||(i.consent?vt.set(a(this,$),ge(i),a(this,B)):vt.remove(a(this,$)))}};$=new WeakMap,B=new WeakMap;var Bt="~",Jt="!",Wt="-";function he(e){if(!e)return;let t=e.split(Bt);if(t.length>3)return;let[r,i,n]=t;return{consent:!0,sessionScores:Kt(yt(i)),scores:Kt(yt(n)),tests:yt(r)}}function yt(e){return e.split(Jt).map(r=>r.split(Wt)).reduce((r,i)=>(i.length!==2||(r[i[0]]=i[1]),r),{})}function Kt(e){return Object.entries(e).reduce((t,[r,i])=>(t[r]=Qt(i),t),{})}function ge(e){return[Dt(e.tests),Dt(Ht(e.sessionScores)),Dt(Ht(e.scores))].join(Bt)}function Ht(e){return Object.entries(e).reduce((t,[r,i])=>(t[r]=gt(i),t),{})}function Dt(e){return Object.entries(e).map(t=>t.join(Wt)).join(Jt)}var rt,Xt,Yt=class extends I{constructor({serverCookieValue:r,visitorIdCookieName:i="ufvi",...n}){super(n);d(this,rt);n.initialData||S(this,rt,Xt).call(this).catch(s=>{console.error(s)})}handleDelete(r){throw new Error("Method not implemented.")}async handleUpdateData(r){let i=await new Promise(n=>{setTimeout(()=>{n(void 0)},2e3)});i&&this.signalAsyncDataUpdate(i)}};rt=new WeakSet,Xt=async function(){let r=await new Promise(i=>{setTimeout(()=>{i(void 0)},2e3)});r&&this.signalAsyncDataUpdate(r)};function kr(e){let{gracePeriod:t=864e5,decayRate:r=1/30,decayCap:i=.95}=e!=null?e:{};return function({now:s,lastUpd:o,scores:u,sessionScores:c,onLogMessage:l}){if(typeof o!="number")return!1;let p=s-o-t;if(p<=0)return!1;let v=p/864e5,D=1-Math.min(i,v*r);return D<=0?!1:(Zt(u,D),Zt(c,D),l==null||l(["info",140,`linear decay factor ${D.toPrecision(6)}`]),!0)}}function Zt(e,t){for(let r in e)r.startsWith("$")||(e[r]*=t)}import ye from"mitt";import{dequal as nt}from"dequal/lite";var it=class{constructor(){y(this,"inMemoryFallback",{});y(this,"hasLocalStorageObject",typeof localStorage!="undefined")}get(t){let r=this.inMemoryFallback[t];if(!this.hasLocalStorageObject||r)return r;try{let i=localStorage.getItem(t);return i?JSON.parse(i):void 0}catch(i){return r}}set(t,r,i){if(this.inMemoryFallback[t]=r,!(!this.hasLocalStorageObject||!i))try{localStorage.setItem(t,JSON.stringify(r))}catch(n){console.warn(n)}}delete(t,r){r||delete this.inMemoryFallback[t];try{localStorage.removeItem(t)}catch(i){}}};import ve from"rfdc";var Se=ve();function Mt(e,t,r){let i=t?Se(t):et();return e.forEach(n=>{var s,o;switch(n.type){case"consent":i.consent=n.data;break;case"setquirk":i.quirks[n.data.key]=n.data.value;break;case"settest":i.tests[n.data.test]=n.data.variant;break;case"modscore":if(r)break;let u=Number(n.data.delta);if(isNaN(u))throw new Error("Non-number delta received");let c=(s=i.scores[n.data.dimension])!=null?s:0;i.scores[n.data.dimension]=c+u;break;case"modscoreS":if(r)break;let l=Number(n.data.delta);if(isNaN(l))throw new Error("Non-number delta received");let f=(o=i.sessionScores[n.data.dimension])!=null?o:0;i.sessionScores[n.data.dimension]=f+l;break;case"identify":break;case"setcontrol":i.controlGroup=n.data;break;default:throw new Error("Unknown command")}}),i}var ot="ufvisitor",E,A,q,g,x,k,P,N,at,Lt,ut,te,J,Ct,W,xt,st=class{constructor(t){d(this,x);d(this,P);d(this,at);d(this,ut);d(this,J);d(this,W);d(this,E,ye());d(this,A,new it);d(this,q,void 0);d(this,g,void 0);y(this,"events",{on:a(this,E).on,off:a(this,E).off});if(m(this,g,t),a(this,x,k)||S(this,P,N).call(this,S(this,W,xt).call(this),!0),t.transitionStore){let r=t.transitionStore.getClientTransitionState();r&&t.onServerTransitionReceived&&t.onServerTransitionReceived(r),t.transitionStore.events.on("dataUpdatedAsync",n=>{S(this,P,N).call(this,{...a(this,x,k).visitorData,...n})});let i=t.transitionStore.data;i&&S(this,P,N).call(this,{...a(this,x,k).visitorData,...i},!0)}}get data(){var r,i;let t=a(this,x,k);if(S(this,ut,te).call(this,t)){let{sessionScores:n,...s}=t.visitorData;return S(this,P,N).call(this,{...s,sessionScores:{}}),(i=(r=a(this,g)).onLogMessage)==null||i.call(r,["info",120]),a(this,x,k).visitorData}return t.visitorData}get decayEnabled(){return!!a(this,g).decay}async updateData(t){var i,n,s,o;if(t.length===0)return;(n=(i=a(this,g)).onLogMessage)==null||n.call(i,["debug",101,t]);let r=Mt(t,this.data,(s=a(this,x,k))==null?void 0:s.visitorData.controlGroup);t.some(u=>u.type==="consent"&&!u.data)&&a(this,A).delete(ot,!0),S(this,P,N).call(this,r),await((o=a(this,g).transitionStore)==null?void 0:o.updateData(t,a(this,x,k).visitorData))}async delete(t){var r,i,n,s,o;(i=(r=a(this,g)).onLogMessage)==null||i.call(r,["info",103,"GROUP",t]);try{a(this,A).delete(ot,!1),await((n=a(this,g).transitionStore)==null?void 0:n.delete(t)),S(this,P,N).call(this,S(this,W,xt).call(this))}finally{(o=(s=a(this,g)).onLogMessage)==null||o.call(s,["info",103,"ENDGROUP"])}}};E=new WeakMap,A=new WeakMap,q=new WeakMap,g=new WeakMap,x=new WeakSet,k=function(){return a(this,A).get(ot)},P=new WeakSet,N=function(t,r=!1){var f,p,v,D,X,Et,Tt,kt,Pt;let i=a(this,x,k),n=Date.now();t.controlGroup?(t.scores={},t.sessionScores={}):(S(this,J,Ct).call(this,t.scores),S(this,J,Ct).call(this,t.sessionScores),(p=(f=a(this,g)).decay)==null||p.call(f,{now:n,lastUpd:i==null?void 0:i.updated,scores:t.scores,sessionScores:t.sessionScores,onLogMessage:a(this,g).onLogMessage}));let s=!nt(i==null?void 0:i.visitorData.scores,t.scores),o=!nt(i==null?void 0:i.visitorData.sessionScores,t.sessionScores),u=!nt(i==null?void 0:i.visitorData.quirks,t.quirks),c=!nt(i==null?void 0:i.visitorData.tests,t.tests),l={updated:n,visitorData:t};S(this,at,Lt).call(this),a(this,A).set(ot,l,!!t.consent),(D=(v=a(this,g)).onLogMessage)==null||D.call(v,["debug",102,t]),r||((s||o)&&a(this,E).emit("scoresUpdated",t),u&&a(this,E).emit("quirksUpdated",t),c&&a(this,E).emit("testsUpdated",t),((X=i==null?void 0:i.visitorData)==null?void 0:X.consent)!==t.consent&&a(this,E).emit("consentUpdated",t),((Et=i==null?void 0:i.visitorData)==null?void 0:Et.controlGroup)!==t.controlGroup&&(a(this,E).emit("controlGroupUpdated",t),(Pt=(kt=a(this,g)).onLogMessage)==null||Pt.call(kt,["debug",104,(Tt=t.controlGroup)!=null?Tt:!1])))},at=new WeakSet,Lt=function(){typeof document=="undefined"||!a(this,g).visitLifespan||(a(this,q)&&window.clearTimeout(a(this,q)),m(this,q,window.setTimeout(()=>{this.data},a(this,g).visitLifespan+50)))},ut=new WeakSet,te=function(t){let r=a(this,g).visitLifespan;return r?t.updated+r<Date.now():!1},J=new WeakSet,Ct=function(t){var r,i;if(!!a(this,g).manifest)for(let n in t){let s=t[n],o=a(this,g).manifest.getDimensionByKey(n);!o||s>o.cap&&((i=(r=a(this,g)).onLogMessage)==null||i.call(r,["debug",110,{dim:n,score:s,cap:o.cap}]),t[n]=o.cap)}},W=new WeakSet,xt=function(){var t,r,i;return{...et(),consent:(t=a(this,g).defaultConsent)!=null?t:!1,controlGroup:(i=(r=a(this,g).manifest)==null?void 0:r.rollForControlGroup())!=null?i:!1}};import Ce from"mitt";function ee({name:e,context:t,variations:r,take:i=1,onLogMessage:n}){var s,o,u;n==null||n(["info",300,"GROUP",{name:e,take:i}]);try{let c=(s=t.storage.data.controlGroup)!=null?s:!1,l=[],f=!1,p=t.scores;for(let v of r){if(l.length===i)break;if(!((o=v.pz)!=null&&o.crit.length)){n==null||n(["info",301,"GROUP",{id:v.id,op:(u=v.pz)==null?void 0:u.op}]),n==null||n(["info",302,{matched:!0,description:"default variation"}]),n==null||n(["info",303,!0]),n==null||n(["info",301,"ENDGROUP"]),l.push(v);continue}c||re(v.id,v.pz,p,n)&&(f=!0,l.push(v))}return{personalized:f,variations:l}}finally{n==null||n(["info",300,"ENDGROUP"])}}function re(e,t,r,i){i==null||i(["info",301,"GROUP",{id:e,op:t==null?void 0:t.op}]);let n;try{t!=null&&t.crit?!t.op||t.op==="&"?n=t.crit.every(s=>ie(s,r,i)):n=t.crit.some(s=>ie(s,r,i)):(i==null||i(["info",302,{matched:!0,description:"default variation"}]),n=!0),i==null||i(["info",303,n])}finally{i==null||i(["info",301,"ENDGROUP"])}return n}function ie(e,t,r){var u,c;let{op:i,l:n}=e,s=(u=t[n])!=null?u:0;if(i==="+"){let l=Math.max(...Object.values(t))===s&&s>0;return r==null||r(["info",302,{matched:l,description:`${e.l} has the highest score`}]),l}else if(i==="-"){let l=Math.min(...Object.values(t))===s&&s>0;return r==null||r(["info",302,{matched:l,description:`${e.l} has the lowest non-zero score`}]),l}let o=parseInt(e.rDim?t[e.rDim]:e.r,10);if(isNaN(o))return r==null||r(["info",302,{matched:!1,description:`${(c=e.rDim)!=null?c:e.r} has no score value`}]),!1;if(i===">"){let l=s>o;return _(r,l,e,s,o),l}else if(i===">="){let l=s>=o;return _(r,l,e,s,o),l}else if(i==="<"){let l=s<o;return _(r,l,e,s,o),l}else if(i==="<="){let l=s<=o;return _(r,l,e,s,o),l}else if(i==="="){let l=s===o;return _(r,l,e,s,o),l}else if(i==="!="){let l=s!==o;return _(r,l,e,s,o),l}else throw new Error(`Unknown op: ${i}`)}function _(e,t,r,i,n){e==null||e(["info",302,{matched:t,description:`${r.l}[${i}] ${r.op} ${r.rDim?`${r.rDim}[${n}]`:r.r}`}])}var De=e=>{let{values:t,total:r,missingDistribution:i}=e.reduce((n,s)=>(s.testDistribution?n.total+=s.testDistribution:++n.missingDistribution,n.values.push(s.testDistribution),n),{values:[],total:0,missingDistribution:0});if(r>100)throw new Error(`Total distribution ${r} is over the maximum 100.`);if(r<100){let s=(100-r)/i;t.forEach((o,u)=>{typeof o=="undefined"&&(t[u]=s)})}return t},bt=({name:e,context:t,variations:r,onLogMessage:i})=>{i==null||i(["info",400,"GROUP",e]);try{let n,s=t.getTestVariantId(e);if(s===null)return i==null||i(["error",401,e]),{result:void 0,variantAssigned:!1};if(s&&(n=r.find(o=>o.id===s),n||i==null||i(["warn",402,{missingVariant:s,variants:r.map(o=>o.id)}])),!n){let o=De(r),u=Math.floor(Math.random()*100),c=0;n=r.find((l,f)=>{let p=o[f];if(u>c&&u<=c+p)return l;c+=p}),n&&(i==null||i(["info",403,n.id]),t.setTestVariantId(e,n.id))}return n&&(i==null||i(["info",404,n.id])),{result:n,variantAssigned:!s}}finally{i==null||i(["info",400,"ENDGROUP"])}};import{dequal as ne}from"dequal/lite";var C,w,T,Y,h,j,lt,oe=class{constructor(t){d(this,j);y(this,"manifest");d(this,C,void 0);d(this,w,{});d(this,T,void 0);d(this,Y,{});d(this,h,Ce());y(this,"events",{on:a(this,h).on,off:a(this,h).off});y(this,"storage");var n,s;let{manifest:r,...i}=t;m(this,T,{}),(n=t.plugins)==null||n.forEach(o=>{!o.logDrain||a(this,h).on("log",o.logDrain)}),a(this,h).emit("log",["info",1,"GROUP"]);try{this.manifest=new L({onLogMessage:o=>a(this,h).emit("log",o),manifest:r,evaluator:new G({CK:$t,QS:Gt,QK:zt,PVC:mt,EVT:It,PV:qt})}),this.storage=new st({...i,manifest:this.manifest,onServerTransitionReceived:o=>{m(this,C,o),o.ssv&&(m(this,w,o.ssv),a(this,h).emit("log",["debug",130,o.ssv]))},onLogMessage:o=>a(this,h).emit("log",o)}),this.storage.events.on("scoresUpdated",S(this,j,lt).bind(this)),a(this,C)||S(this,j,lt).call(this,this.storage.data),this.storage.events.on("quirksUpdated",o=>{let u=this.manifest.computeSignals({scores:a(this,w),state:a(this,T),previousState:a(this,T),visitor:this.storage.data});this.storage.updateData(u),a(this,h).emit("quirksUpdated",o.quirks),a(this,h).emit("log",["info",4,o.quirks])}),(s=t.plugins)==null||s.forEach(o=>{!o.init||o.init(this)})}finally{a(this,h).emit("log",["info",1,"ENDGROUP"])}}get scores(){return a(this,w)}get quirks(){var t,r;return(r=(t=a(this,C))==null?void 0:t.quirks)!=null?r:this.storage.data.quirks}async update(t){var i,n,s;let r=[];(i=a(this,C))!=null&&i.quirks&&(t={...t,quirks:{...a(this,C).quirks,...t.quirks||{}}}),(n=a(this,C))!=null&&n.tests&&r.push(...Object.entries(a(this,C).tests).map(([o,u])=>({type:"settest",data:{test:o,variant:u}})));try{a(this,h).emit("log",["info",2,"GROUP",{...t,url:(s=t.url)==null?void 0:s.toString()}]),t.quirks&&r.push(...Object.entries(t.quirks).map(([o,u])=>({type:"setquirk",data:{key:o,value:u}}))),t.enrichments&&t.enrichments.forEach(o=>{let u=tt(o.cat,o.key);this.manifest.getDimensionByKey(u)?r.push({type:"modscore",data:{dimension:u,delta:o.str}}):a(this,h).emit("log",["warn",5,o])}),r.push(...this.manifest.computeSignals({state:t,previousState:a(this,T),visitor:this.storage.data,scores:a(this,w)})),m(this,T,{...a(this,T),...t}),await this.storage.updateData(r),a(this,C)&&(S(this,j,lt).call(this,this.storage.data),m(this,C,void 0),a(this,h).emit("log",["debug",131]))}finally{a(this,h).emit("log",["info",2,"ENDGROUP"])}}getTestVariantId(t){var i;let r=this.manifest.getTest(t);return r?(i=r.wv)!=null?i:this.storage.data.tests[t]:(a(this,h).emit("log",["warn",401,t]),null)}setTestVariantId(t,r){this.storage.updateData([{type:"settest",data:{test:t,variant:r}}])}log(...t){a(this,h).emit("log",t)}test(t){var i,n;let r=bt({...t,context:this,onLogMessage:s=>a(this,h).emit("log",s)});return a(this,h).emit("testResult",{name:t.name,variantId:(n=(i=r.result)==null?void 0:i.id)!=null?n:void 0,variantAssigned:r.variantAssigned}),r}personalize(t){let r=ee({...t,context:this,onLogMessage:s=>a(this,h).emit("log",s)}),i=a(this,Y)[t.name],n={name:t.name,variantIds:r.variations.map(s=>{var o;return(o=s.id)!=null?o:"Unknown"}),control:this.storage.data.controlGroup,changed:!0};return i&&ne(n.variantIds,i)&&(n.changed=!1),a(this,h).emit("personalizationResult",n),a(this,Y)[t.name]=n.variantIds,r}async forget(t){m(this,T,{}),await this.storage.delete(t)}};C=new WeakMap,w=new WeakMap,T=new WeakMap,Y=new WeakMap,h=new WeakMap,j=new WeakSet,lt=function(t){var n;let r={...t.scores};for(let s in t.sessionScores)r[s]=((n=r[s])!=null?n:0)+t.sessionScores[s];r=this.manifest.computeAggregateDimensions(r),!ne(r,a(this,w))&&(m(this,w,r),a(this,h).emit("scoresUpdated",r),a(this,h).emit("log",["info",3,r]))};import xe from"rfdc";function ct(e,t){if(e==="none")return!1;switch(t){case"debug":return e==="debug";case"info":return e==="info"||e==="debug";case"warn":return e==="warn"||e==="info"||e==="debug";case"error":return e==="debug"||"info";default:return!1}}var be=xe();function Ve(e){return([t,...r])=>{if(!ct(e,t))return;let[i,...n]=r;console[t](`\u{1F94B} [${t}] Uniform event ID ${i}
`,...n.map(be))}}function fi(e){return{logDrain:Ve(e)}}var se={1:()=>["context","initializing Uniform Context"],2:e=>["context","received update()",e],3:e=>["context","new score vector",e],4:e=>["context","updated quirks",e],5:e=>["context","ignored enrichment update for unknown enrichment category",e.cat],101:e=>["storage","received update commands",e],102:e=>["storage","data was updated",e],103:e=>["storage",`deleting visitor data ${e?"from all devices":"from this device"}`],104:e=>["context",e?"Visitor assigned to personalization control group":"Visitor assigned to personalization experiment group"],110:({dim:e,cap:t,score:r})=>["storage",`${e} score ${r} exceeded cap ${t}. Rounded down.`],120:()=>["storage","visitor data expired and was cleared"],130:e=>["storage","server to client transition score data was loaded; it will persist until the next update event occurs",e],131:()=>["storage","server to client transition data was discarded"],140:e=>["storage",`score decay was applied: ${e}`],200:()=>["signals","evaluating signals"],201:e=>["signals",`evaluating signal ${e.id} (${e.dur})`],202:e=>["signals",e.op==="|"?"OR":"AND"],203:({criteria:e,result:t,explanation:r})=>["signals",`${e.type}: ${r} is ${t.result} [${t.changed?"CHANGED":"unchanged"}]`],204:e=>["signals",`group result: ${e.result} [${e.changed?"CHANGED":"unchanged"}]`],300:e=>["personalization",`executing personalization '${e.name}'`],301:({id:e,op:t})=>["personalization",`testing variation ${e} (${t==="|"?"OR":"AND"})`],302:({matched:e,description:t})=>["personalization",`${t} is ${e}`],303:e=>["personalization",e?"selected variation":"did not select variation"],400:e=>["testing",`executing A/B test '${e}'`],401:e=>["testing",`${e} is not registered in the manifest; it will not be run.`],402:({missingVariant:e,variants:t})=>["testing",`test variation '${e}' previously assigned to the visitor for this test no longer exists as a variant. It will be removed. This may indicate changing test variations after publishing a test, which will make results invalid. Known variants: ${t.join(", ")}`],403:e=>["testing",`assigned new test variant '${e}'`],404:e=>["testing",`displaying variation '${e}'`],700:()=>["gtag","gtag is not defined, skipping analytics event emission. Ensure you have added the gtag script to your page."],701:()=>["gtag","enabled gtag event signal redirection"]};import Ee from"rfdc";var Te=Ee();function ke(e,t){let r=typeof document=="undefined",{enableOnServer:i=!1}=t!=null?t:{};return([n,...s])=>{if(!ct(e,n)||r&&!i)return;let[o,...u]=s,c=console[n];if(u[0]==="GROUP"&&(u.shift(),c=console.groupCollapsed),u[0]==="ENDGROUP"){console.groupEnd();return}let l=se[o],f="";switch(n){case"debug":f="\u{1F41E}";break;case"info":f="\u{1F4AC}";break;case"warn":f="\u26A0\uFE0F";break;case"error":f="\u{1F4A5}";break}let p=f;if(!l){c(`${p} unknown event ID ${o}. Log messages data may be older than Uniform Context package.`,...u);return}let[v,D,...X]=l(...u);c(`${p}[${v}] ${D}
`,...X.map(Te))}}function Si(e,t){return{logDrain:ke(e,t)}}var Pe=(u=>(u.ListStart="nesi-list-start",u.ListEnd="nesi-list-end",u.ListItem="nesi-list-item-html",u.ListItemSettings="nesi-list-item-settings",u.TestStart="nesi-test-start",u.TestEnd="nesi-test-end",u.Unknown="unknown",u))(Pe||{}),Di="nesitag";var Vt=typeof top!="undefined";function xi(){return{logDrain:e=>{!Vt||top==null||top.postMessage({type:"uniform:context:log",message:e},window.location.origin)},init:e=>{let t=[],r=[],i=()=>{!Vt||top==null||top.postMessage({type:"uniform:context:data",data:{scores:e.scores,data:e.storage.data,manifest:e.manifest.data,personalizations:t,tests:r}},window.location.origin)},n=o=>{!o.changed||(t.push(o),i())},s=o=>{!o.variantAssigned||(r.push(o),i())};if(Vt){window.__UNIFORM_DEVTOOLS_CONTEXT_INSTANCE__=e;try{top==null||top.addEventListener("message",async o=>{if(!o.data)return;let u=o.data;await we(u,e)})}catch(o){console.warn("Unable to initialize Uniform Context DevTools because it is in a cross-domain iframe.",o)}top==null||top.postMessage({type:"uniform:context:hello",uiVersion:2},window.location.origin),i()}return e.events.on("personalizationResult",n),e.events.on("testResult",s),e.events.on("scoresUpdated",i),e.storage.events.on("*",i),()=>{e.events.off("scoresUpdated",i),e.storage.events.off("*",i),e.events.off("personalizationResult",n),e.events.off("testResult",s)}}}}async function we(e,t){e.type==="uniform-in:context:update"&&e.newData&&await t.update(e.newData),e.type==="uniform-in:context:commands"&&e.commands&&Array.isArray(e.commands)&&await t.storage.updateData(e.commands),e.type==="uniform-in:context:forget"&&await t.forget(!1)}function Vi(e){return`${e.apiKey}|${e.projectId}${e.apiHost?`|${e.apiHost}`:""}`}function Ei(e){let[t,r,i]=e.split("|");if(!t.startsWith("uf"))throw new Error("Invalid API key");if(!/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12})$/i.test(r))throw new Error("Invalid project ID");return{apiKey:t,projectId:r,apiHost:i||"https://uniform.app"}}export{oe as Context,Ft as CookieTransitionDataStore,Di as EdgeNodeTagName,Yt as EdgeTransitionDataStore,G as GroupCriteriaEvaluator,L as ManifestInstance,pe as SERVER_STATE_ID,Pe as ScriptType,I as TransitionDataStore,me as UNIFORM_DEFAULT_COOKIE_NAME,st as VisitorDataStore,wt as computeAggregateDimensions,$t as cookieEvaluator,Ve as createConsoleLogDrain,ke as createDebugConsoleLogDrain,kr as createLinearDecay,qt as currentPageEvaluator,et as emptyVisitorData,fi as enableConsoleLogDrain,xi as enableContextDevTools,Si as enableDebugConsoleLogDrain,re as evaluateVariantMatch,It as eventEvaluator,O as explainStringMatch,ft as explainStringMatchCriteria,tt as getEnrichmentVectorKey,V as isStringMatch,pt as pageViewCountDimension,mt as pageViewCountEvaluator,Ei as parseQuickConnect,ee as personalizeVariations,Gt as queryStringEvaluator,zt as quirkEvaluator,Vi as serializeQuickConnect,bt as testVariations};

@@ -1,3 +0,3 @@

var Ve=Object.create;var K=Object.defineProperty;var Ee=Object.getOwnPropertyDescriptor;var Te=Object.getOwnPropertyNames;var ke=Object.getPrototypeOf,Pe=Object.prototype.hasOwnProperty;var we=(e,t,r)=>t in e?K(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var Re=(e,t)=>{for(var r in t)K(e,r,{get:t[r],enumerable:!0})},Kt=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Te(t))!Pe.call(e,n)&&n!==r&&K(e,n,{get:()=>t[n],enumerable:!(i=Ee(t,n))||i.enumerable});return e};var N=(e,t,r)=>(r=e!=null?Ve(ke(e)):{},Kt(t||!e||!e.__esModule?K(r,"default",{value:e,enumerable:!0}):r,e)),Oe=e=>Kt(K({},"__esModule",{value:!0}),e);var D=(e,t,r)=>(we(e,typeof t!="symbol"?t+"":t,r),r),yt=(e,t,r)=>{if(!t.has(e))throw TypeError("Cannot "+r)};var a=(e,t,r)=>(yt(e,t,"read from private field"),r?r.call(e):t.get(e)),d=(e,t,r)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,r)},h=(e,t,r,i)=>(yt(e,t,"write to private field"),i?i.call(e,r):t.set(e,r),r);var y=(e,t,r)=>(yt(e,t,"access private method"),r);var Je={};Re(Je,{Context:()=>It,CookieTransitionDataStore:()=>Ot,EdgeNodeTagName:()=>Qe,EdgeTransitionDataStore:()=>Ut,GroupCriteriaEvaluator:()=>A,ManifestInstance:()=>J,SERVER_STATE_ID:()=>Lt,ScriptType:()=>be,TransitionDataStore:()=>G,UNIFORM_DEFAULT_COOKIE_NAME:()=>oe,VisitorDataStore:()=>tt,computeAggregateDimensions:()=>Dt,cookieEvaluator:()=>Ct,createConsoleLogDrain:()=>ye,createDebugConsoleLogDrain:()=>xe,createLinearDecay:()=>Ae,currentPageEvaluator:()=>Et,emptyVisitorData:()=>Z,enableConsoleLogDrain:()=>qe,enableContextDevTools:()=>Fe,enableDebugConsoleLogDrain:()=>je,evaluateVariantMatch:()=>Gt,eventEvaluator:()=>Vt,explainStringMatch:()=>P,explainStringMatchCriteria:()=>at,getEnrichmentVectorKey:()=>Y,isStringMatch:()=>b,pageViewCountDimension:()=>ut,pageViewCountEvaluator:()=>lt,parseQuickConnect:()=>Be,personalizeVariations:()=>At,queryStringEvaluator:()=>xt,quirkEvaluator:()=>bt,serializeQuickConnect:()=>He,testVariations:()=>gt});module.exports=Oe(Je);function Dt(e,t){let r={...e};for(let i in t){let n=Ht(e,i,t,new Set([i]));n!==0&&(r[i]=n)}return r}function Ht(e,t,r,i){var s;let n=0;for(let o of r[t].inputs){let u=(s=e[o.dim])!=null?s:0;if(!u&&r[o.dim]){if(i.has(o.dim))continue;let l=new Set(i);l.add(o.dim),u=Ht(e,o.dim,r,l)}if(u!==0)if(o.sign==="c"){n=0;break}else o.sign==="-"?n-=u:n+=u}return n}var ot="_";var H,B,st=class{constructor(t,r,i){d(this,H,void 0);d(this,B,void 0);D(this,"signal");this.signal=t,h(this,H,r),h(this,B,i)}computeSignal(t,r){if(t.scores[this.signal.id]>=this.signal.cap&&this.signal.dur!=="t")return;let n=a(this,H).evaluate(t,this.signal.crit,r,this.signal,a(this,B)),s=this.signal.dur==="s"||this.signal.dur==="t"?"modscoreS":"modscore";if(!!n.changed){if(n.result)r.push({type:s,data:{dimension:this.signal.id,delta:this.signal.str}});else if(this.signal.dur==="t"){let o=t.visitor.sessionScores[this.signal.id];o&&r.push({type:s,data:{dimension:this.signal.id,delta:-o}})}}}};H=new WeakMap,B=new WeakMap;var E,W,U,J=class{constructor({manifest:t,evaluator:r=new A({}),onLogMessage:i=()=>{}}){D(this,"data");d(this,E,void 0);d(this,W,void 0);d(this,U,void 0);var n,s,o;h(this,E,(n=t.project)!=null?n:{}),this.data=t,h(this,W,Object.entries((o=(s=a(this,E).pz)==null?void 0:s.sig)!=null?o:[]).map(([u,c])=>new st({...c,id:u},r,i))),h(this,U,i)}rollForControlGroup(){var t,r;return Math.random()<((r=(t=a(this,E).pz)==null?void 0:t.control)!=null?r:0)}getTest(t){var r;return(r=a(this,E).test)==null?void 0:r[t]}computeSignals(t){let r=[];a(this,U).call(this,["debug",200,"GROUP"]);try{a(this,W).forEach(i=>{a(this,U).call(this,["debug",201,"GROUP",i.signal]);try{i.computeSignal(t,r)}finally{a(this,U).call(this,["debug",201,"ENDGROUP"])}})}finally{a(this,U).call(this,["debug",200,"ENDGROUP"])}return r}computeAggregateDimensions(t){var r,i;return Dt(t,(i=(r=a(this,E).pz)==null?void 0:r.agg)!=null?i:{})}getDimensionByKey(t){var i,n,s,o;let r=t.indexOf(ot);return r<=0?(n=(i=a(this,E).pz)==null?void 0:i.sig)==null?void 0:n[t]:(o=(s=a(this,E).pz)==null?void 0:s.enr)==null?void 0:o[t.substring(0,r)]}};E=new WeakMap,W=new WeakMap,U=new WeakMap;var Wt=require("dequal/lite");function b(e,t){var o,u,c,l,p,m;let r=(o=t==null?void 0:t.op)!=null?o:"=";if(t.op==="*")return e!==null&&typeof e!="undefined";if(t.op==="!*")return e===null||typeof e=="undefined";if(!("rhs"in t))throw new Error(`Match expression is required for match type ${r}`);let i=(u=t.cs)!=null?u:!1,n=(i?e!=null?e:"":Bt(e)).toString(),s=(i?t.rhs:Bt(t.rhs)).toString();switch(r){case"=":return n===s;case"!=":return n!==s;case"~":return(c=n.includes(s))!=null?c:!1;case"!~":return!((l=n.includes(s))==null||l);case"//":return new RegExp(t.rhs.toString(),i?"":"i").test((p=e==null?void 0:e.toString())!=null?p:"");case"!//":return!new RegExp(t.rhs.toString(),i?"":"i").test((m=e==null?void 0:e.toString())!=null?m:"");default:throw new Error(`Unknown match type ${r}.`)}}function P(e,t){return`'${("cs"in t?t.cs:!1)?e:e==null?void 0:e.toString().toUpperCase()}' ${at(t)}`}function at(e){return"rhs"in e?`${e.op} '${e.cs?e.rhs:e.rhs.toString().toUpperCase()}'`:`${e.op==="*"?"exists":"does not exist"}`}function Bt(e){var t,r;return(r=(t=e==null?void 0:e.toString())==null?void 0:t.toUpperCase())!=null?r:""}var Ct=({update:e,criteria:t,onLogMessage:r})=>{var u,c;if(t.type!=="CK")return{result:!1,changed:!1};let i=!(0,Wt.dequal)(Jt(e.state.cookies),Jt((u=e.previousState)==null?void 0:u.cookies)),n=(c=e.state.cookies)==null?void 0:c[t.cookieName],o={result:b(n,t.match),changed:i};return r==null||r(["debug",203,{criteria:t,result:o,explanation:P(n,t.match)}]),o};function Jt(e){if(!e)return;if(!e.ufvd)return e;let{ufvd:t,...r}=e;return r}function Yt(e,t){var i;if(typeof e=="undefined"||e===null)return!1;let r=Number(e);if(isNaN(r))return!1;switch((i=t==null?void 0:t.op)!=null?i:"="){case"=":return r===t.rhs;case"!=":return r!==t.rhs;case">":return r>t.rhs;case"<":return r<t.rhs;default:return console.warn(`Unknown match type ${t.op} is false.`),!1}}function Xt(e,t){return`${e} ${Ue(t)}`}function Ue(e){return`${e.op} ${e.rhs}`}function Y(e,t){return`${e}${ot}${t}`}var ut=Y("$pvc","v"),lt=({update:e,criteria:t,commands:r,onLogMessage:i})=>{var l,p;if(t.type!=="PVC")return{result:!1,changed:!1};let n=Boolean(e.state.url&&(!e.previousState||((l=e.state.url)==null?void 0:l.toString())!==((p=e.previousState.url)==null?void 0:p.toString()))),o=(e.visitor.sessionScores[ut]||0)+1,u={result:!1,changed:n},c=r.some(m=>m.type==="modscoreS"&&m.data.dimension===ut);return n&&!c&&r.push({type:"modscoreS",data:{dimension:ut,delta:1}}),Yt(o,t.match)&&(u.result=!0),i==null||i(["debug",203,{criteria:t,result:u,explanation:Xt(o,t.match)}]),u};lt.alwaysExecute=!0;var xt=({update:e,criteria:t,onLogMessage:r})=>{var u,c,l,p,m;if(t.type!=="QS")return{result:!1,changed:!1};let i=!e.previousState||((c=(u=e.state.url)==null?void 0:u.searchParams)==null?void 0:c.toString())!==((p=(l=e.previousState.url)==null?void 0:l.searchParams)==null?void 0:p.toString()),n=(m=e.state.url)==null?void 0:m.searchParams.get(t.queryName),o={result:b(n,t.match),changed:i};return r==null||r(["debug",203,{criteria:t,result:o,explanation:P(n,t.match)}]),o};var bt=({update:e,criteria:t,signal:r,onLogMessage:i})=>{var p;if(t.type!=="QK")return{result:!1,changed:!1};if(typeof document=="undefined"&&r.dur==="t"&&e.scores[r.id]>0)return{result:!0,changed:!1};let n=e.visitor.quirks[t.key],s=(p=e.state.quirks)==null?void 0:p[t.key],o=s!=null?s:n,u=Boolean(s&&n!==s),l={result:b(o,t.match),changed:u};return i==null||i(["debug",203,{criteria:t,result:l,explanation:P(o,t.match)}]),l};var Vt=({update:e,criteria:t,onLogMessage:r})=>{var s,o,u;if(t.type!=="EVT")return{result:!1,changed:!1};let i=(o=(s=e.state.events)==null?void 0:s.some(c=>b(c.event,t.event)))!=null?o:!1,n={result:i,changed:i};return r==null||r(["debug",203,{criteria:t,result:n,explanation:`'${(u=e.state.events)==null?void 0:u.join("', '")}' ${at(t.event)}`}]),n};var Et=({update:e,criteria:t,onLogMessage:r})=>{var u,c,l;if(t.type!=="PV")return{result:!1,changed:!1};let i=(u=e.state.url)==null?void 0:u.pathname,n=!e.previousState||(i==null?void 0:i.toString())!==((l=(c=e.previousState.url)==null?void 0:c.pathname)==null?void 0:l.toString()),o={result:b(i,t.path),changed:n};return r==null||r(["debug",203,{criteria:t,result:o,explanation:P(i,t.path)}]),o};var X,A=class{constructor(t){d(this,X,void 0);h(this,X,t)}evaluate(t,r,i,n,s){let o=r.clauses.length>1;o&&(s==null||s(["debug",202,"GROUP",r]));try{let u=!(r.op==="&"||!r.op),c=null,l=!1;for(let m of r.clauses){let S;if(m.type==="G")S=this.evaluate(t,m,i,n,s);else{let C=a(this,X)[m.type];if(c&&!C.alwaysExecute)continue;if(!C)throw new Error(`${m.type} signal criteria not registered`);S=C({update:t,criteria:m,commands:i,signal:n,onLogMessage:s})}S.changed&&(l=!0),!c&&S.result===u&&(c={result:u,changed:l})}let p=c!=null?c:{result:!u,changed:l};return o&&(s==null||s(["debug",204,p])),p}finally{o&&(s==null||s(["debug",202,"ENDGROUP"]))}}};X=new WeakMap;var Z=()=>({quirks:{},scores:{},sessionScores:{},tests:{},consent:!1,controlGroup:!1});var Zt=N(require("mitt")),Mt=require("dequal/lite"),Lt="__UNIFORM_DATA__",$,_,G=class{constructor({initialData:t}){d(this,$,void 0);d(this,_,(0,Zt.default)());D(this,"events",{on:a(this,_).on,off:a(this,_).off});t&&h(this,$,t)}get data(){return a(this,$)}updateData(t,r){return h(this,$,r),this.handleUpdateData(t,r)}async delete(t){h(this,$,void 0),await this.handleDelete(t)}signalAsyncDataUpdate(t){(0,Mt.dequal)(this.data,t)||(h(this,$,t),a(this,_).emit("dataUpdatedAsync",t))}getClientTransitionState(){if(typeof document=="undefined")return;let t=document.getElementById(Lt);return t!=null&&t.textContent?JSON.parse(t.textContent):void 0}};$=new WeakMap,_=new WeakMap;var Tt="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",te=Tt.split(""),ee=new Array(123);for(let e=0;e<Tt.length;e++)ee[Tt.charCodeAt(e)]=e;var kt=e=>{if(e<0)return`-${kt(-e)}`;let t=e>>>0,r=e/4294967296>>>0,i="";for(;r>0;)i=te[63&t]+i,t>>>=6,t|=(63&r)<<26,r>>>=6;let n="";do n=te[63&t]+n,t>>>=6;while(t>0);return n+i},re=e=>{let t=0,r=e.charAt(0)==="-"?1:0;for(let i=r;i<e.length;i++)t=t*64+ee[e.charCodeAt(i)];return r?-t:t};var ct=N(require("js-cookie")),Pt=typeof document=="undefined",oe="ufvd",z,M,Ot=class extends G{constructor({serverCookieValue:r,cookieName:i=oe,cookieAttributes:n={sameSite:"lax"}}){super({initialData:Pt?$e(r):void 0});d(this,z,void 0);d(this,M,void 0);h(this,z,i),h(this,M,n)}handleDelete(){return Pt||ct.default.remove(a(this,z)),Promise.resolve()}async handleUpdateData(r,i){Pt||(i.consent?ct.default.set(a(this,z),Ne(i),a(this,M)):ct.default.remove(a(this,z)))}};z=new WeakMap,M=new WeakMap;var se="~",ae="!",ue="-";function $e(e){if(!e)return;let t=e.split(se);if(t.length>3)return;let[r,i,n]=t;return{consent:!0,sessionScores:ie(wt(i)),scores:ie(wt(n)),tests:wt(r)}}function wt(e){return e.split(ae).map(r=>r.split(ue)).reduce((r,i)=>(i.length!==2||(r[i[0]]=i[1]),r),{})}function ie(e){return Object.entries(e).reduce((t,[r,i])=>(t[r]=re(i),t),{})}function Ne(e){return[Rt(e.tests),Rt(ne(e.sessionScores)),Rt(ne(e.scores))].join(se)}function ne(e){return Object.entries(e).reduce((t,[r,i])=>(t[r]=kt(i),t),{})}function Rt(e){return Object.entries(e).map(t=>t.join(ue)).join(ae)}var dt,le,Ut=class extends G{constructor({serverCookieValue:r,visitorIdCookieName:i="ufvi",...n}){super(n);d(this,dt);n.initialData||y(this,dt,le).call(this).catch(s=>{console.error(s)})}handleDelete(r){throw new Error("Method not implemented.")}async handleUpdateData(r){let i=await new Promise(n=>{setTimeout(()=>{n(void 0)},2e3)});i&&this.signalAsyncDataUpdate(i)}};dt=new WeakSet,le=async function(){let r=await new Promise(i=>{setTimeout(()=>{i(void 0)},2e3)});r&&this.signalAsyncDataUpdate(r)};function Ae(e){let{gracePeriod:t=864e5,decayRate:r=1/30,decayCap:i=.95}=e!=null?e:{};return function({now:s,lastUpd:o,scores:u,sessionScores:c,onLogMessage:l}){if(typeof o!="number")return!1;let m=s-o-t;if(m<=0)return!1;let S=m/864e5,C=1-Math.min(i,S*r);return C<=0?!1:(ce(u,C),ce(c,C),l==null||l(["info",140,`linear decay factor ${C.toPrecision(6)}`]),!0)}}function ce(e,t){for(let r in e)r.startsWith("$")||(e[r]*=t)}var pe=N(require("mitt")),L=require("dequal/lite");var ft=class{constructor(){D(this,"inMemoryFallback",{});D(this,"hasLocalStorageObject",typeof localStorage!="undefined")}get(t){let r=this.inMemoryFallback[t];if(!this.hasLocalStorageObject||r)return r;try{let i=localStorage.getItem(t);return i?JSON.parse(i):void 0}catch(i){return r}}set(t,r,i){if(this.inMemoryFallback[t]=r,!(!this.hasLocalStorageObject||!i))try{localStorage.setItem(t,JSON.stringify(r))}catch(n){console.warn(n)}}delete(t,r){r||delete this.inMemoryFallback[t];try{localStorage.removeItem(t)}catch(i){}}};var de=N(require("rfdc"));var Ge=(0,de.default)();function fe(e,t,r){let i=t?Ge(t):Z();return e.forEach(n=>{var s,o;switch(n.type){case"consent":i.consent=n.data;break;case"setquirk":i.quirks[n.data.key]=n.data.value;break;case"settest":i.tests[n.data.test]=n.data.variant;break;case"modscore":if(r)break;let u=Number(n.data.delta);if(isNaN(u))throw new Error("Non-number delta received");let c=(s=i.scores[n.data.dimension])!=null?s:0;i.scores[n.data.dimension]=c+u;break;case"modscoreS":if(r)break;let l=Number(n.data.delta);if(isNaN(l))throw new Error("Non-number delta received");let p=(o=i.sessionScores[n.data.dimension])!=null?o:0;i.sessionScores[n.data.dimension]=p+l;break;case"identify":break;case"setcontrol":i.controlGroup=n.data;break;default:throw new Error("Unknown command")}}),i}var pt="ufvisitor",T,q,j,v,V,w,R,I,mt,me,ht,he,et,$t,rt,Nt,tt=class{constructor(t){d(this,V);d(this,R);d(this,mt);d(this,ht);d(this,et);d(this,rt);d(this,T,(0,pe.default)());d(this,q,new ft);d(this,j,void 0);d(this,v,void 0);D(this,"events",{on:a(this,T).on,off:a(this,T).off});if(h(this,v,t),a(this,V,w)||y(this,R,I).call(this,y(this,rt,Nt).call(this),!0),t.transitionStore){let r=t.transitionStore.getClientTransitionState();r&&t.onServerTransitionReceived&&t.onServerTransitionReceived(r),t.transitionStore.events.on("dataUpdatedAsync",n=>{y(this,R,I).call(this,{...a(this,V,w).visitorData,...n})});let i=t.transitionStore.data;i&&y(this,R,I).call(this,{...a(this,V,w).visitorData,...i},!0)}}get data(){var r,i;let t=a(this,V,w);if(y(this,ht,he).call(this,t)){let{sessionScores:n,...s}=t.visitorData;return y(this,R,I).call(this,{...s,sessionScores:{}}),(i=(r=a(this,v)).onLogMessage)==null||i.call(r,["info",120]),a(this,V,w).visitorData}return t.visitorData}get decayEnabled(){return!!a(this,v).decay}async updateData(t){var i,n,s,o;if(t.length===0)return;(n=(i=a(this,v)).onLogMessage)==null||n.call(i,["debug",101,t]);let r=fe(t,this.data,(s=a(this,V,w))==null?void 0:s.visitorData.controlGroup);t.some(u=>u.type==="consent"&&!u.data)&&a(this,q).delete(pt,!0),y(this,R,I).call(this,r),await((o=a(this,v).transitionStore)==null?void 0:o.updateData(t,a(this,V,w).visitorData))}async delete(t){var r,i,n,s,o;(i=(r=a(this,v)).onLogMessage)==null||i.call(r,["info",103,"GROUP",t]);try{a(this,q).delete(pt,!1),await((n=a(this,v).transitionStore)==null?void 0:n.delete(t)),y(this,R,I).call(this,y(this,rt,Nt).call(this))}finally{(o=(s=a(this,v)).onLogMessage)==null||o.call(s,["info",103,"ENDGROUP"])}}};T=new WeakMap,q=new WeakMap,j=new WeakMap,v=new WeakMap,V=new WeakSet,w=function(){return a(this,q).get(pt)},R=new WeakSet,I=function(t,r=!1){var p,m,S,C,nt,_t,jt,Qt,Ft;let i=a(this,V,w),n=Date.now();t.controlGroup?(t.scores={},t.sessionScores={}):(y(this,et,$t).call(this,t.scores),y(this,et,$t).call(this,t.sessionScores),(m=(p=a(this,v)).decay)==null||m.call(p,{now:n,lastUpd:i==null?void 0:i.updated,scores:t.scores,sessionScores:t.sessionScores,onLogMessage:a(this,v).onLogMessage}));let s=!(0,L.dequal)(i==null?void 0:i.visitorData.scores,t.scores),o=!(0,L.dequal)(i==null?void 0:i.visitorData.sessionScores,t.sessionScores),u=!(0,L.dequal)(i==null?void 0:i.visitorData.quirks,t.quirks),c=!(0,L.dequal)(i==null?void 0:i.visitorData.tests,t.tests),l={updated:n,visitorData:t};y(this,mt,me).call(this),a(this,q).set(pt,l,!!t.consent),(C=(S=a(this,v)).onLogMessage)==null||C.call(S,["debug",102,t]),r||((s||o)&&a(this,T).emit("scoresUpdated",t),u&&a(this,T).emit("quirksUpdated",t),c&&a(this,T).emit("testsUpdated",t),((nt=i==null?void 0:i.visitorData)==null?void 0:nt.consent)!==t.consent&&a(this,T).emit("consentUpdated",t),((_t=i==null?void 0:i.visitorData)==null?void 0:_t.controlGroup)!==t.controlGroup&&(a(this,T).emit("controlGroupUpdated",t),(Ft=(Qt=a(this,v)).onLogMessage)==null||Ft.call(Qt,["debug",104,(jt=t.controlGroup)!=null?jt:!1])))},mt=new WeakSet,me=function(){typeof document=="undefined"||!a(this,v).visitLifespan||(a(this,j)&&window.clearTimeout(a(this,j)),h(this,j,window.setTimeout(()=>{this.data},a(this,v).visitLifespan+50)))},ht=new WeakSet,he=function(t){let r=a(this,v).visitLifespan;return r?t.updated+r<Date.now():!1},et=new WeakSet,$t=function(t){var r,i;if(!!a(this,v).manifest)for(let n in t){let s=t[n],o=a(this,v).manifest.getDimensionByKey(n);!o||s>o.cap&&((i=(r=a(this,v)).onLogMessage)==null||i.call(r,["debug",110,{dim:n,score:s,cap:o.cap}]),t[n]=o.cap)}},rt=new WeakSet,Nt=function(){var t,r,i;return{...Z(),consent:(t=a(this,v).defaultConsent)!=null?t:!1,controlGroup:(i=(r=a(this,v).manifest)==null?void 0:r.rollForControlGroup())!=null?i:!1}};var ve=N(require("mitt"));function At({name:e,context:t,variations:r,take:i=1,onLogMessage:n}){var s,o,u;n==null||n(["info",300,"GROUP",{name:e,take:i}]);try{let c=(s=t.storage.data.controlGroup)!=null?s:!1,l=[],p=!1,m=t.scores;for(let S of r){if(l.length===i)break;if(!((o=S.pz)!=null&&o.crit.length)){n==null||n(["info",301,"GROUP",{id:S.id,op:(u=S.pz)==null?void 0:u.op}]),n==null||n(["info",302,{matched:!0,description:"default variation"}]),n==null||n(["info",303,!0]),n==null||n(["info",301,"ENDGROUP"]),l.push(S);continue}c||Gt(S.id,S.pz,m,n)&&(p=!0,l.push(S))}return{personalized:p,variations:l}}finally{n==null||n(["info",300,"ENDGROUP"])}}function Gt(e,t,r,i){i==null||i(["info",301,"GROUP",{id:e,op:t==null?void 0:t.op}]);let n;try{t!=null&&t.crit?!t.op||t.op==="&"?n=t.crit.every(s=>ge(s,r,i)):n=t.crit.some(s=>ge(s,r,i)):(i==null||i(["info",302,{matched:!0,description:"default variation"}]),n=!0),i==null||i(["info",303,n])}finally{i==null||i(["info",301,"ENDGROUP"])}return n}function ge(e,t,r){var u,c;let{op:i,l:n}=e,s=(u=t[n])!=null?u:0;if(i==="+"){let l=Math.max(...Object.values(t))===s&&s>0;return r==null||r(["info",302,{matched:l,description:`${e.l} has the highest score`}]),l}else if(i==="-"){let l=Math.min(...Object.values(t))===s&&s>0;return r==null||r(["info",302,{matched:l,description:`${e.l} has the lowest non-zero score`}]),l}let o=parseInt(e.rDim?t[e.rDim]:e.r,10);if(isNaN(o))return r==null||r(["info",302,{matched:!1,description:`${(c=e.rDim)!=null?c:e.r} has no score value`}]),!1;if(i===">"){let l=s>o;return Q(r,l,e,s,o),l}else if(i===">="){let l=s>=o;return Q(r,l,e,s,o),l}else if(i==="<"){let l=s<o;return Q(r,l,e,s,o),l}else if(i==="<="){let l=s<=o;return Q(r,l,e,s,o),l}else if(i==="="){let l=s===o;return Q(r,l,e,s,o),l}else if(i==="!="){let l=s!==o;return Q(r,l,e,s,o),l}else throw new Error(`Unknown op: ${i}`)}function Q(e,t,r,i,n){e==null||e(["info",302,{matched:t,description:`${r.l}[${i}] ${r.op} ${r.rDim?`${r.rDim}[${n}]`:r.r}`}])}var ze=e=>{let{values:t,total:r,missingDistribution:i}=e.reduce((n,s)=>(s.testDistribution?n.total+=s.testDistribution:++n.missingDistribution,n.values.push(s.testDistribution),n),{values:[],total:0,missingDistribution:0});if(r>100)throw new Error(`Total distribution ${r} is over the maximum 100.`);if(r<100){let s=(100-r)/i;t.forEach((o,u)=>{typeof o=="undefined"&&(t[u]=s)})}return t},gt=({name:e,context:t,variations:r,onLogMessage:i})=>{i==null||i(["info",400,"GROUP",e]);try{let n,s=t.getTestVariantId(e);if(s===null)return i==null||i(["error",401,e]),{result:void 0,variantAssigned:!1};if(s&&(n=r.find(o=>o.id===s),n||i==null||i(["warn",402,{missingVariant:s,variants:r.map(o=>o.id)}])),!n){let o=ze(r),u=Math.floor(Math.random()*100),c=0;n=r.find((l,p)=>{let m=o[p];if(u>c&&u<=c+m)return l;c+=m}),n&&(i==null||i(["info",403,n.id]),t.setTestVariantId(e,n.id))}return n&&(i==null||i(["info",404,n.id])),{result:n,variantAssigned:!s}}finally{i==null||i(["info",400,"ENDGROUP"])}};var zt=require("dequal/lite"),x,O,k,it,g,F,vt,It=class{constructor(t){d(this,F);D(this,"manifest");d(this,x,void 0);d(this,O,{});d(this,k,void 0);d(this,it,{});d(this,g,(0,ve.default)());D(this,"events",{on:a(this,g).on,off:a(this,g).off});D(this,"storage");var n,s;let{manifest:r,...i}=t;h(this,k,{}),(n=t.plugins)==null||n.forEach(o=>{!o.logDrain||a(this,g).on("log",o.logDrain)}),a(this,g).emit("log",["info",1,"GROUP"]);try{this.manifest=new J({onLogMessage:o=>a(this,g).emit("log",o),manifest:r,evaluator:new A({CK:Ct,QS:xt,QK:bt,PVC:lt,EVT:Vt,PV:Et})}),this.storage=new tt({...i,manifest:this.manifest,onServerTransitionReceived:o=>{h(this,x,o),o.ssv&&(h(this,O,o.ssv),a(this,g).emit("log",["debug",130,o.ssv]))},onLogMessage:o=>a(this,g).emit("log",o)}),this.storage.events.on("scoresUpdated",y(this,F,vt).bind(this)),a(this,x)||y(this,F,vt).call(this,this.storage.data),this.storage.events.on("quirksUpdated",o=>{let u=this.manifest.computeSignals({scores:a(this,O),state:a(this,k),previousState:a(this,k),visitor:this.storage.data});this.storage.updateData(u),a(this,g).emit("quirksUpdated",o.quirks),a(this,g).emit("log",["info",4,o.quirks])}),(s=t.plugins)==null||s.forEach(o=>{!o.init||o.init(this)})}finally{a(this,g).emit("log",["info",1,"ENDGROUP"])}}get scores(){return a(this,O)}get quirks(){var t,r;return(r=(t=a(this,x))==null?void 0:t.quirks)!=null?r:this.storage.data.quirks}async update(t){var i,n,s;let r=[];(i=a(this,x))!=null&&i.quirks&&(t={...t,quirks:{...a(this,x).quirks,...t.quirks||{}}}),(n=a(this,x))!=null&&n.tests&&r.push(...Object.entries(a(this,x).tests).map(([o,u])=>({type:"settest",data:{test:o,variant:u}})));try{a(this,g).emit("log",["info",2,"GROUP",{...t,url:(s=t.url)==null?void 0:s.toString()}]),t.quirks&&r.push(...Object.entries(t.quirks).map(([o,u])=>({type:"setquirk",data:{key:o,value:u}}))),t.enrichments&&t.enrichments.forEach(o=>{let u=Y(o.cat,o.key);this.manifest.getDimensionByKey(u)?r.push({type:"modscore",data:{dimension:u,delta:o.str}}):a(this,g).emit("log",["warn",5,o])}),r.push(...this.manifest.computeSignals({state:t,previousState:a(this,k),visitor:this.storage.data,scores:a(this,O)})),h(this,k,{...a(this,k),...t}),await this.storage.updateData(r),a(this,x)&&(y(this,F,vt).call(this,this.storage.data),h(this,x,void 0),a(this,g).emit("log",["debug",131]))}finally{a(this,g).emit("log",["info",2,"ENDGROUP"])}}getTestVariantId(t){var i;let r=this.manifest.getTest(t);return r?(i=r.wv)!=null?i:this.storage.data.tests[t]:(a(this,g).emit("log",["warn",401,t]),null)}setTestVariantId(t,r){this.storage.updateData([{type:"settest",data:{test:t,variant:r}}])}log(...t){a(this,g).emit("log",t)}test(t){var i,n;let r=gt({...t,context:this,onLogMessage:s=>a(this,g).emit("log",s)});return a(this,g).emit("testResult",{name:t.name,variantId:(n=(i=r.result)==null?void 0:i.id)!=null?n:void 0,variantAssigned:r.variantAssigned}),r}personalize(t){let r=At({...t,context:this,onLogMessage:s=>a(this,g).emit("log",s)}),i=a(this,it)[t.name],n={name:t.name,variantIds:r.variations.map(s=>{var o;return(o=s.id)!=null?o:"Unknown"}),control:this.storage.data.controlGroup,changed:!0};return i&&(0,zt.dequal)(n.variantIds,i)&&(n.changed=!1),a(this,g).emit("personalizationResult",n),a(this,it)[t.name]=n.variantIds,r}async forget(t){h(this,k,{}),await this.storage.delete(t)}};x=new WeakMap,O=new WeakMap,k=new WeakMap,it=new WeakMap,g=new WeakMap,F=new WeakSet,vt=function(t){var n;let r={...t.scores};for(let s in t.sessionScores)r[s]=((n=r[s])!=null?n:0)+t.sessionScores[s];r=this.manifest.computeAggregateDimensions(r),!(0,zt.dequal)(r,a(this,O))&&(h(this,O,r),a(this,g).emit("scoresUpdated",r),a(this,g).emit("log",["info",3,r]))};var Se=N(require("rfdc"));function St(e,t){if(e==="none")return!1;switch(t){case"debug":return e==="debug";case"info":return e==="info"||e==="debug";case"warn":return e==="warn"||e==="info"||e==="debug";case"error":return e==="debug"||"info";default:return!1}}var Ie=(0,Se.default)();function ye(e){return([t,...r])=>{if(!St(e,t))return;let[i,...n]=r;console[t](`\u{1F94B} [${t}] Uniform event ID ${i}
`,...n.map(Ie))}}function qe(e){return{logDrain:ye(e)}}var De={1:()=>["context","initializing Uniform Context"],2:e=>["context","received update()",e],3:e=>["context","new score vector",e],4:e=>["context","updated quirks",e],5:e=>["context","ignored enrichment update for unknown enrichment category",e.cat],101:e=>["storage","received update commands",e],102:e=>["storage","data was updated",e],103:e=>["storage",`deleting visitor data ${e?"from all devices":"from this device"}`],104:e=>["context",e?"Visitor assigned to personalization control group":"Visitor assigned to personalization experiment group"],110:({dim:e,cap:t,score:r})=>["storage",`${e} score ${r} exceeded cap ${t}. Rounded down.`],120:()=>["storage","visitor data expired and was cleared"],130:e=>["storage","server to client transition score data was loaded; it will persist until the next update event occurs",e],131:()=>["storage","server to client transition data was discarded"],140:e=>["storage",`score decay was applied: ${e}`],200:()=>["signals","evaluating signals"],201:e=>["signals",`evaluating signal ${e.id} (${e.dur})`],202:e=>["signals",e.op==="|"?"OR":"AND"],203:({criteria:e,result:t,explanation:r})=>["signals",`${e.type}: ${r} is ${t.result} [${t.changed?"CHANGED":"unchanged"}]`],204:e=>["signals",`group result: ${e.result} [${e.changed?"CHANGED":"unchanged"}]`],300:e=>["personalization",`executing personalization '${e.name}'`],301:({id:e,op:t})=>["personalization",`testing variation ${e} (${t==="|"?"OR":"AND"})`],302:({matched:e,description:t})=>["personalization",`${t} is ${e}`],303:e=>["personalization",e?"selected variation":"did not select variation"],400:e=>["testing",`executing A/B test '${e}'`],401:e=>["testing",`${e} is not registered in the manifest; it will not be run.`],402:({missingVariant:e,variants:t})=>["testing",`test variation '${e}' previously assigned to the visitor for this test no longer exists as a variant. It will be removed. This may indicate changing test variations after publishing a test, which will make results invalid. Known variants: ${t.join(", ")}`],403:e=>["testing",`assigned new test variant '${e}'`],404:e=>["testing",`displaying variation '${e}'`],700:()=>["gtag","gtag is not defined, skipping analytics event emission. Ensure you have added the gtag script to your page."],701:()=>["gtag","enabled gtag event signal redirection"]};var Ce=N(require("rfdc")),_e=(0,Ce.default)();function xe(e,t){let r=typeof document=="undefined",{enableOnServer:i=!1}=t!=null?t:{};return([n,...s])=>{if(!St(e,n)||r&&!i)return;let[o,...u]=s,c=console[n];if(u[0]==="GROUP"&&(u.shift(),c=console.groupCollapsed),u[0]==="ENDGROUP"){console.groupEnd();return}let l=De[o],p="";switch(n){case"debug":p="\u{1F41E}";break;case"info":p="\u{1F4AC}";break;case"warn":p="\u26A0\uFE0F";break;case"error":p="\u{1F4A5}";break}let m=p;if(!l){c(`${m} unknown event ID ${o}. Log messages data may be older than Uniform Context package.`,...u);return}let[S,C,...nt]=l(...u);c(`${m}[${S}] ${C}
`,...nt.map(_e))}}function je(e,t){return{logDrain:xe(e,t)}}var be=(u=>(u.ListStart="nesi-list-start",u.ListEnd="nesi-list-end",u.ListItem="nesi-list-item-html",u.ListItemSettings="nesi-list-item-settings",u.TestStart="nesi-test-start",u.TestEnd="nesi-test-end",u.Unknown="unknown",u))(be||{}),Qe="nesitag";var qt=typeof top!="undefined";function Fe(){return{logDrain:e=>{!qt||top==null||top.postMessage({type:"uniform:context:log",message:e},window.location.origin)},init:e=>{let t=[],r=[],i=()=>{!qt||top==null||top.postMessage({type:"uniform:context:data",data:{scores:e.scores,data:e.storage.data,manifest:e.manifest.data,personalizations:t,tests:r}},window.location.origin)},n=o=>{!o.changed||(t.push(o),i())},s=o=>{!o.variantAssigned||(r.push(o),i())};if(qt){window.__UNIFORM_DEVTOOLS_CONTEXT_INSTANCE__=e;try{top==null||top.addEventListener("message",async o=>{if(!o.data)return;let u=o.data;await Ke(u,e)})}catch(o){console.warn("Unable to initialize Uniform Context DevTools because it is in a cross-domain iframe.",o)}top==null||top.postMessage({type:"uniform:context:hello",uiVersion:2},window.location.origin),i()}return e.events.on("personalizationResult",n),e.events.on("testResult",s),e.events.on("scoresUpdated",i),e.storage.events.on("*",i),()=>{e.events.off("scoresUpdated",i),e.storage.events.off("*",i),e.events.off("personalizationResult",n),e.events.off("testResult",s)}}}}async function Ke(e,t){e.type==="uniform-in:context:update"&&e.newData&&await t.update(e.newData),e.type==="uniform-in:context:commands"&&e.commands&&Array.isArray(e.commands)&&await t.storage.updateData(e.commands),e.type==="uniform-in:context:forget"&&await t.forget(!1)}function He(e){return`${e.apiKey}|${e.projectId}${e.apiHost?`|${e.apiHost}`:""}`}function Be(e){let[t,r,i]=e.split("|");if(!t.startsWith("uf"))throw new Error("Invalid API key");if(!/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12})$/i.test(r))throw new Error("Invalid project ID");return{apiKey:t,projectId:r,apiHost:i||"https://uniform.app"}}0&&(module.exports={Context,CookieTransitionDataStore,EdgeNodeTagName,EdgeTransitionDataStore,GroupCriteriaEvaluator,ManifestInstance,SERVER_STATE_ID,ScriptType,TransitionDataStore,UNIFORM_DEFAULT_COOKIE_NAME,VisitorDataStore,computeAggregateDimensions,cookieEvaluator,createConsoleLogDrain,createDebugConsoleLogDrain,createLinearDecay,currentPageEvaluator,emptyVisitorData,enableConsoleLogDrain,enableContextDevTools,enableDebugConsoleLogDrain,evaluateVariantMatch,eventEvaluator,explainStringMatch,explainStringMatchCriteria,getEnrichmentVectorKey,isStringMatch,pageViewCountDimension,pageViewCountEvaluator,parseQuickConnect,personalizeVariations,queryStringEvaluator,quirkEvaluator,serializeQuickConnect,testVariations});
"use strict";var be=Object.create;var F=Object.defineProperty;var Ve=Object.getOwnPropertyDescriptor;var Ee=Object.getOwnPropertyNames;var Te=Object.getPrototypeOf,ke=Object.prototype.hasOwnProperty;var Pe=(e,t,r)=>t in e?F(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var we=(e,t)=>{for(var r in t)F(e,r,{get:t[r],enumerable:!0})},Ft=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Ee(t))!ke.call(e,n)&&n!==r&&F(e,n,{get:()=>t[n],enumerable:!(i=Ve(t,n))||i.enumerable});return e};var $=(e,t,r)=>(r=e!=null?be(Te(e)):{},Ft(t||!e||!e.__esModule?F(r,"default",{value:e,enumerable:!0}):r,e)),Re=e=>Ft(F({},"__esModule",{value:!0}),e);var y=(e,t,r)=>(Pe(e,typeof t!="symbol"?t+"":t,r),r),St=(e,t,r)=>{if(!t.has(e))throw TypeError("Cannot "+r)};var a=(e,t,r)=>(St(e,t,"read from private field"),r?r.call(e):t.get(e)),d=(e,t,r)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,r)},m=(e,t,r,i)=>(St(e,t,"write to private field"),i?i.call(e,r):t.set(e,r),r);var S=(e,t,r)=>(St(e,t,"access private method"),r);var Be={};we(Be,{Context:()=>zt,CookieTransitionDataStore:()=>Rt,EdgeNodeTagName:()=>je,EdgeTransitionDataStore:()=>Ot,GroupCriteriaEvaluator:()=>N,ManifestInstance:()=>B,SERVER_STATE_ID:()=>Mt,ScriptType:()=>xe,TransitionDataStore:()=>A,UNIFORM_DEFAULT_COOKIE_NAME:()=>ne,VisitorDataStore:()=>L,computeAggregateDimensions:()=>yt,cookieEvaluator:()=>Dt,createConsoleLogDrain:()=>Se,createDebugConsoleLogDrain:()=>Ce,createLinearDecay:()=>Ne,currentPageEvaluator:()=>Vt,emptyVisitorData:()=>X,enableConsoleLogDrain:()=>Ie,enableContextDevTools:()=>Qe,enableDebugConsoleLogDrain:()=>_e,evaluateVariantMatch:()=>At,eventEvaluator:()=>bt,explainStringMatch:()=>k,explainStringMatchCriteria:()=>st,getEnrichmentVectorKey:()=>W,isStringMatch:()=>x,pageViewCountDimension:()=>at,pageViewCountEvaluator:()=>ut,parseQuickConnect:()=>He,personalizeVariations:()=>Nt,queryStringEvaluator:()=>Ct,quirkEvaluator:()=>xt,serializeQuickConnect:()=>Ke,testVariations:()=>ht});module.exports=Re(Be);function yt(e,t){let r={...e};for(let i in t){let n=Kt(e,i,t,new Set([i]));n!==0&&(r[i]=n)}return r}function Kt(e,t,r,i){var s;let n=0;for(let o of r[t].inputs){let u=(s=e[o.dim])!=null?s:0;if(!u&&r[o.dim]){if(i.has(o.dim))continue;let l=new Set(i);l.add(o.dim),u=Kt(e,o.dim,r,l)}if(u!==0)if(o.sign==="c"){n=0;break}else o.sign==="-"?n-=u:n+=u}return n}var nt="_";var K,H,ot=class{constructor(t,r,i){d(this,K,void 0);d(this,H,void 0);y(this,"signal");this.signal=t,m(this,K,r),m(this,H,i)}computeSignal(t,r){if(t.scores[this.signal.id]>=this.signal.cap&&this.signal.dur!=="t")return;let n=a(this,K).evaluate(t,this.signal.crit,r,this.signal,a(this,H)),s=this.signal.dur==="s"||this.signal.dur==="t"?"modscoreS":"modscore";if(!!n.changed){if(n.result)r.push({type:s,data:{dimension:this.signal.id,delta:this.signal.str}});else if(this.signal.dur==="t"){let o=t.visitor.sessionScores[this.signal.id];o&&r.push({type:s,data:{dimension:this.signal.id,delta:-o}})}}}};K=new WeakMap,H=new WeakMap;var V,J,O,B=class{constructor({manifest:t,evaluator:r=new N({}),onLogMessage:i=()=>{}}){y(this,"data");d(this,V,void 0);d(this,J,void 0);d(this,O,void 0);var n,s,o;m(this,V,(n=t.project)!=null?n:{}),this.data=t,m(this,J,Object.entries((o=(s=a(this,V).pz)==null?void 0:s.sig)!=null?o:[]).map(([u,c])=>new ot({...c,id:u},r,i))),m(this,O,i)}rollForControlGroup(){var t,r;return Math.random()<((r=(t=a(this,V).pz)==null?void 0:t.control)!=null?r:0)}getTest(t){var r;return(r=a(this,V).test)==null?void 0:r[t]}computeSignals(t){let r=[];a(this,O).call(this,["debug",200,"GROUP"]);try{a(this,J).forEach(i=>{a(this,O).call(this,["debug",201,"GROUP",i.signal]);try{i.computeSignal(t,r)}finally{a(this,O).call(this,["debug",201,"ENDGROUP"])}})}finally{a(this,O).call(this,["debug",200,"ENDGROUP"])}return r}computeAggregateDimensions(t){var r,i;return yt(t,(i=(r=a(this,V).pz)==null?void 0:r.agg)!=null?i:{})}getDimensionByKey(t){var i,n,s,o;let r=t.indexOf(nt);return r<=0?(n=(i=a(this,V).pz)==null?void 0:i.sig)==null?void 0:n[t]:(o=(s=a(this,V).pz)==null?void 0:s.enr)==null?void 0:o[t.substring(0,r)]}};V=new WeakMap,J=new WeakMap,O=new WeakMap;var Jt=require("dequal/lite");function x(e,t){var o,u,c,l,f,p;let r=(o=t==null?void 0:t.op)!=null?o:"=";if(t.op==="*")return e!==null&&typeof e!="undefined";if(t.op==="!*")return e===null||typeof e=="undefined";if(!("rhs"in t))throw new Error(`Match expression is required for match type ${r}`);let i=(u=t.cs)!=null?u:!1,n=(i?e!=null?e:"":Ht(e)).toString(),s=(i?t.rhs:Ht(t.rhs)).toString();switch(r){case"=":return n===s;case"!=":return n!==s;case"~":return(c=n.includes(s))!=null?c:!1;case"!~":return!((l=n.includes(s))==null||l);case"//":return new RegExp(t.rhs.toString(),i?"":"i").test((f=e==null?void 0:e.toString())!=null?f:"");case"!//":return!new RegExp(t.rhs.toString(),i?"":"i").test((p=e==null?void 0:e.toString())!=null?p:"");default:throw new Error(`Unknown match type ${r}.`)}}function k(e,t){return`'${("cs"in t?t.cs:!1)?e:e==null?void 0:e.toString().toUpperCase()}' ${st(t)}`}function st(e){return"rhs"in e?`${e.op} '${e.cs?e.rhs:e.rhs.toString().toUpperCase()}'`:`${e.op==="*"?"exists":"does not exist"}`}function Ht(e){var t,r;return(r=(t=e==null?void 0:e.toString())==null?void 0:t.toUpperCase())!=null?r:""}var Dt=({update:e,criteria:t,onLogMessage:r})=>{var u,c;if(t.type!=="CK")return{result:!1,changed:!1};let i=!(0,Jt.dequal)(Bt(e.state.cookies),Bt((u=e.previousState)==null?void 0:u.cookies)),n=(c=e.state.cookies)==null?void 0:c[t.cookieName],o={result:x(n,t.match),changed:i};return r==null||r(["debug",203,{criteria:t,result:o,explanation:k(n,t.match)}]),o};function Bt(e){if(!e)return;if(!e.ufvd)return e;let{ufvd:t,...r}=e;return r}function Wt(e,t){var i;if(typeof e=="undefined"||e===null)return!1;let r=Number(e);if(isNaN(r))return!1;switch((i=t==null?void 0:t.op)!=null?i:"="){case"=":return r===t.rhs;case"!=":return r!==t.rhs;case">":return r>t.rhs;case"<":return r<t.rhs;default:return console.warn(`Unknown match type ${t.op} is false.`),!1}}function Yt(e,t){return`${e} ${Oe(t)}`}function Oe(e){return`${e.op} ${e.rhs}`}function W(e,t){return`${e}${nt}${t}`}var at=W("$pvc","v"),ut=({update:e,criteria:t,commands:r,onLogMessage:i})=>{var l,f;if(t.type!=="PVC")return{result:!1,changed:!1};let n=Boolean(e.state.url&&(!e.previousState||((l=e.state.url)==null?void 0:l.toString())!==((f=e.previousState.url)==null?void 0:f.toString()))),o=(e.visitor.sessionScores[at]||0)+1,u={result:!1,changed:n},c=r.some(p=>p.type==="modscoreS"&&p.data.dimension===at);return n&&!c&&r.push({type:"modscoreS",data:{dimension:at,delta:1}}),Wt(o,t.match)&&(u.result=!0),i==null||i(["debug",203,{criteria:t,result:u,explanation:Yt(o,t.match)}]),u};ut.alwaysExecute=!0;var Ct=({update:e,criteria:t,onLogMessage:r})=>{var u,c,l,f,p;if(t.type!=="QS")return{result:!1,changed:!1};let i=!e.previousState||((c=(u=e.state.url)==null?void 0:u.searchParams)==null?void 0:c.toString())!==((f=(l=e.previousState.url)==null?void 0:l.searchParams)==null?void 0:f.toString()),n=(p=e.state.url)==null?void 0:p.searchParams.get(t.queryName),o={result:x(n,t.match),changed:i};return r==null||r(["debug",203,{criteria:t,result:o,explanation:k(n,t.match)}]),o};var xt=({update:e,criteria:t,signal:r,onLogMessage:i})=>{var f;if(t.type!=="QK")return{result:!1,changed:!1};if(typeof document=="undefined"&&r.dur==="t"&&e.scores[r.id]>0)return{result:!0,changed:!1};let n=e.visitor.quirks[t.key],s=(f=e.state.quirks)==null?void 0:f[t.key],o=s!=null?s:n,u=Boolean(s&&n!==s),l={result:x(o,t.match),changed:u};return i==null||i(["debug",203,{criteria:t,result:l,explanation:k(o,t.match)}]),l};var bt=({update:e,criteria:t,onLogMessage:r})=>{var s,o,u;if(t.type!=="EVT")return{result:!1,changed:!1};let i=(o=(s=e.state.events)==null?void 0:s.some(c=>x(c.event,t.event)))!=null?o:!1,n={result:i,changed:i};return r==null||r(["debug",203,{criteria:t,result:n,explanation:`'${(u=e.state.events)==null?void 0:u.join("', '")}' ${st(t.event)}`}]),n};var Vt=({update:e,criteria:t,onLogMessage:r})=>{var u,c,l;if(t.type!=="PV")return{result:!1,changed:!1};let i=(u=e.state.url)==null?void 0:u.pathname,n=!e.previousState||(i==null?void 0:i.toString())!==((l=(c=e.previousState.url)==null?void 0:c.pathname)==null?void 0:l.toString()),o={result:x(i,t.path),changed:n};return r==null||r(["debug",203,{criteria:t,result:o,explanation:k(i,t.path)}]),o};var Y,N=class{constructor(t){d(this,Y,void 0);m(this,Y,t)}evaluate(t,r,i,n,s){let o=r.clauses.length>1;o&&(s==null||s(["debug",202,"GROUP",r]));try{let u=!(r.op==="&"||!r.op),c=null,l=!1;for(let p of r.clauses){let v;if(p.type==="G")v=this.evaluate(t,p,i,n,s);else{let D=a(this,Y)[p.type];if(c&&!D.alwaysExecute)continue;if(!D)throw new Error(`${p.type} signal criteria not registered`);v=D({update:t,criteria:p,commands:i,signal:n,onLogMessage:s})}v.changed&&(l=!0),!c&&v.result===u&&(c={result:u,changed:l})}let f=c!=null?c:{result:!u,changed:l};return o&&(s==null||s(["debug",204,f])),f}finally{o&&(s==null||s(["debug",202,"ENDGROUP"]))}}};Y=new WeakMap;var X=()=>({quirks:{},scores:{},sessionScores:{},tests:{},consent:!1,controlGroup:!1});var Xt=$(require("mitt")),Zt=require("dequal/lite"),Mt="__UNIFORM_DATA__",U,q,A=class{constructor({initialData:t}){d(this,U,void 0);d(this,q,(0,Xt.default)());y(this,"events",{on:a(this,q).on,off:a(this,q).off});t&&m(this,U,t)}get data(){return a(this,U)}updateData(t,r){return m(this,U,r),this.handleUpdateData(t,r)}async delete(t){m(this,U,void 0),await this.handleDelete(t)}signalAsyncDataUpdate(t){(0,Zt.dequal)(this.data,t)||(m(this,U,t),a(this,q).emit("dataUpdatedAsync",t))}getClientTransitionState(){if(typeof document=="undefined")return;let t=document.getElementById(Mt);return t!=null&&t.textContent?JSON.parse(t.textContent):void 0}};U=new WeakMap,q=new WeakMap;var Et="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Lt=Et.split(""),te=new Array(123);for(let e=0;e<Et.length;e++)te[Et.charCodeAt(e)]=e;var Tt=e=>{if(e<0)return`-${Tt(-e)}`;let t=e>>>0,r=e/4294967296>>>0,i="";for(;r>0;)i=Lt[63&t]+i,t>>>=6,t|=(63&r)<<26,r>>>=6;let n="";do n=Lt[63&t]+n,t>>>=6;while(t>0);return n+i},ee=e=>{let t=0,r=e.charAt(0)==="-"?1:0;for(let i=r;i<e.length;i++)t=t*64+te[e.charCodeAt(i)];return r?-t:t};var lt=$(require("js-cookie")),kt=typeof document=="undefined",ne="ufvd",G,Z,Rt=class extends A{constructor({serverCookieValue:r,cookieName:i=ne,cookieAttributes:n={sameSite:"lax"}}){super({initialData:kt?Ue(r):void 0});d(this,G,void 0);d(this,Z,void 0);m(this,G,i),m(this,Z,n)}handleDelete(){return kt||lt.default.remove(a(this,G)),Promise.resolve()}async handleUpdateData(r,i){kt||(i.consent?lt.default.set(a(this,G),$e(i),a(this,Z)):lt.default.remove(a(this,G)))}};G=new WeakMap,Z=new WeakMap;var oe="~",se="!",ae="-";function Ue(e){if(!e)return;let t=e.split(oe);if(t.length>3)return;let[r,i,n]=t;return{consent:!0,sessionScores:re(Pt(i)),scores:re(Pt(n)),tests:Pt(r)}}function Pt(e){return e.split(se).map(r=>r.split(ae)).reduce((r,i)=>(i.length!==2||(r[i[0]]=i[1]),r),{})}function re(e){return Object.entries(e).reduce((t,[r,i])=>(t[r]=ee(i),t),{})}function $e(e){return[wt(e.tests),wt(ie(e.sessionScores)),wt(ie(e.scores))].join(oe)}function ie(e){return Object.entries(e).reduce((t,[r,i])=>(t[r]=Tt(i),t),{})}function wt(e){return Object.entries(e).map(t=>t.join(ae)).join(se)}var ct,ue,Ot=class extends A{constructor({serverCookieValue:r,visitorIdCookieName:i="ufvi",...n}){super(n);d(this,ct);n.initialData||S(this,ct,ue).call(this).catch(s=>{console.error(s)})}handleDelete(r){throw new Error("Method not implemented.")}async handleUpdateData(r){let i=await new Promise(n=>{setTimeout(()=>{n(void 0)},2e3)});i&&this.signalAsyncDataUpdate(i)}};ct=new WeakSet,ue=async function(){let r=await new Promise(i=>{setTimeout(()=>{i(void 0)},2e3)});r&&this.signalAsyncDataUpdate(r)};function Ne(e){let{gracePeriod:t=864e5,decayRate:r=1/30,decayCap:i=.95}=e!=null?e:{};return function({now:s,lastUpd:o,scores:u,sessionScores:c,onLogMessage:l}){if(typeof o!="number")return!1;let p=s-o-t;if(p<=0)return!1;let v=p/864e5,D=1-Math.min(i,v*r);return D<=0?!1:(le(u,D),le(c,D),l==null||l(["info",140,`linear decay factor ${D.toPrecision(6)}`]),!0)}}function le(e,t){for(let r in e)r.startsWith("$")||(e[r]*=t)}var fe=$(require("mitt")),M=require("dequal/lite");var dt=class{constructor(){y(this,"inMemoryFallback",{});y(this,"hasLocalStorageObject",typeof localStorage!="undefined")}get(t){let r=this.inMemoryFallback[t];if(!this.hasLocalStorageObject||r)return r;try{let i=localStorage.getItem(t);return i?JSON.parse(i):void 0}catch(i){return r}}set(t,r,i){if(this.inMemoryFallback[t]=r,!(!this.hasLocalStorageObject||!i))try{localStorage.setItem(t,JSON.stringify(r))}catch(n){console.warn(n)}}delete(t,r){r||delete this.inMemoryFallback[t];try{localStorage.removeItem(t)}catch(i){}}};var ce=$(require("rfdc"));var Ae=(0,ce.default)();function de(e,t,r){let i=t?Ae(t):X();return e.forEach(n=>{var s,o;switch(n.type){case"consent":i.consent=n.data;break;case"setquirk":i.quirks[n.data.key]=n.data.value;break;case"settest":i.tests[n.data.test]=n.data.variant;break;case"modscore":if(r)break;let u=Number(n.data.delta);if(isNaN(u))throw new Error("Non-number delta received");let c=(s=i.scores[n.data.dimension])!=null?s:0;i.scores[n.data.dimension]=c+u;break;case"modscoreS":if(r)break;let l=Number(n.data.delta);if(isNaN(l))throw new Error("Non-number delta received");let f=(o=i.sessionScores[n.data.dimension])!=null?o:0;i.sessionScores[n.data.dimension]=f+l;break;case"identify":break;case"setcontrol":i.controlGroup=n.data;break;default:throw new Error("Unknown command")}}),i}var ft="ufvisitor",E,I,_,g,b,P,w,z,pt,pe,mt,me,tt,Ut,et,$t,L=class{constructor(t){d(this,b);d(this,w);d(this,pt);d(this,mt);d(this,tt);d(this,et);d(this,E,(0,fe.default)());d(this,I,new dt);d(this,_,void 0);d(this,g,void 0);y(this,"events",{on:a(this,E).on,off:a(this,E).off});if(m(this,g,t),a(this,b,P)||S(this,w,z).call(this,S(this,et,$t).call(this),!0),t.transitionStore){let r=t.transitionStore.getClientTransitionState();r&&t.onServerTransitionReceived&&t.onServerTransitionReceived(r),t.transitionStore.events.on("dataUpdatedAsync",n=>{S(this,w,z).call(this,{...a(this,b,P).visitorData,...n})});let i=t.transitionStore.data;i&&S(this,w,z).call(this,{...a(this,b,P).visitorData,...i},!0)}}get data(){var r,i;let t=a(this,b,P);if(S(this,mt,me).call(this,t)){let{sessionScores:n,...s}=t.visitorData;return S(this,w,z).call(this,{...s,sessionScores:{}}),(i=(r=a(this,g)).onLogMessage)==null||i.call(r,["info",120]),a(this,b,P).visitorData}return t.visitorData}get decayEnabled(){return!!a(this,g).decay}async updateData(t){var i,n,s,o;if(t.length===0)return;(n=(i=a(this,g)).onLogMessage)==null||n.call(i,["debug",101,t]);let r=de(t,this.data,(s=a(this,b,P))==null?void 0:s.visitorData.controlGroup);t.some(u=>u.type==="consent"&&!u.data)&&a(this,I).delete(ft,!0),S(this,w,z).call(this,r),await((o=a(this,g).transitionStore)==null?void 0:o.updateData(t,a(this,b,P).visitorData))}async delete(t){var r,i,n,s,o;(i=(r=a(this,g)).onLogMessage)==null||i.call(r,["info",103,"GROUP",t]);try{a(this,I).delete(ft,!1),await((n=a(this,g).transitionStore)==null?void 0:n.delete(t)),S(this,w,z).call(this,S(this,et,$t).call(this))}finally{(o=(s=a(this,g)).onLogMessage)==null||o.call(s,["info",103,"ENDGROUP"])}}};E=new WeakMap,I=new WeakMap,_=new WeakMap,g=new WeakMap,b=new WeakSet,P=function(){return a(this,I).get(ft)},w=new WeakSet,z=function(t,r=!1){var f,p,v,D,it,qt,_t,jt,Qt;let i=a(this,b,P),n=Date.now();t.controlGroup?(t.scores={},t.sessionScores={}):(S(this,tt,Ut).call(this,t.scores),S(this,tt,Ut).call(this,t.sessionScores),(p=(f=a(this,g)).decay)==null||p.call(f,{now:n,lastUpd:i==null?void 0:i.updated,scores:t.scores,sessionScores:t.sessionScores,onLogMessage:a(this,g).onLogMessage}));let s=!(0,M.dequal)(i==null?void 0:i.visitorData.scores,t.scores),o=!(0,M.dequal)(i==null?void 0:i.visitorData.sessionScores,t.sessionScores),u=!(0,M.dequal)(i==null?void 0:i.visitorData.quirks,t.quirks),c=!(0,M.dequal)(i==null?void 0:i.visitorData.tests,t.tests),l={updated:n,visitorData:t};S(this,pt,pe).call(this),a(this,I).set(ft,l,!!t.consent),(D=(v=a(this,g)).onLogMessage)==null||D.call(v,["debug",102,t]),r||((s||o)&&a(this,E).emit("scoresUpdated",t),u&&a(this,E).emit("quirksUpdated",t),c&&a(this,E).emit("testsUpdated",t),((it=i==null?void 0:i.visitorData)==null?void 0:it.consent)!==t.consent&&a(this,E).emit("consentUpdated",t),((qt=i==null?void 0:i.visitorData)==null?void 0:qt.controlGroup)!==t.controlGroup&&(a(this,E).emit("controlGroupUpdated",t),(Qt=(jt=a(this,g)).onLogMessage)==null||Qt.call(jt,["debug",104,(_t=t.controlGroup)!=null?_t:!1])))},pt=new WeakSet,pe=function(){typeof document=="undefined"||!a(this,g).visitLifespan||(a(this,_)&&window.clearTimeout(a(this,_)),m(this,_,window.setTimeout(()=>{this.data},a(this,g).visitLifespan+50)))},mt=new WeakSet,me=function(t){let r=a(this,g).visitLifespan;return r?t.updated+r<Date.now():!1},tt=new WeakSet,Ut=function(t){var r,i;if(!!a(this,g).manifest)for(let n in t){let s=t[n],o=a(this,g).manifest.getDimensionByKey(n);!o||s>o.cap&&((i=(r=a(this,g)).onLogMessage)==null||i.call(r,["debug",110,{dim:n,score:s,cap:o.cap}]),t[n]=o.cap)}},et=new WeakSet,$t=function(){var t,r,i;return{...X(),consent:(t=a(this,g).defaultConsent)!=null?t:!1,controlGroup:(i=(r=a(this,g).manifest)==null?void 0:r.rollForControlGroup())!=null?i:!1}};var ge=$(require("mitt"));function Nt({name:e,context:t,variations:r,take:i=1,onLogMessage:n}){var s,o,u;n==null||n(["info",300,"GROUP",{name:e,take:i}]);try{let c=(s=t.storage.data.controlGroup)!=null?s:!1,l=[],f=!1,p=t.scores;for(let v of r){if(l.length===i)break;if(!((o=v.pz)!=null&&o.crit.length)){n==null||n(["info",301,"GROUP",{id:v.id,op:(u=v.pz)==null?void 0:u.op}]),n==null||n(["info",302,{matched:!0,description:"default variation"}]),n==null||n(["info",303,!0]),n==null||n(["info",301,"ENDGROUP"]),l.push(v);continue}c||At(v.id,v.pz,p,n)&&(f=!0,l.push(v))}return{personalized:f,variations:l}}finally{n==null||n(["info",300,"ENDGROUP"])}}function At(e,t,r,i){i==null||i(["info",301,"GROUP",{id:e,op:t==null?void 0:t.op}]);let n;try{t!=null&&t.crit?!t.op||t.op==="&"?n=t.crit.every(s=>he(s,r,i)):n=t.crit.some(s=>he(s,r,i)):(i==null||i(["info",302,{matched:!0,description:"default variation"}]),n=!0),i==null||i(["info",303,n])}finally{i==null||i(["info",301,"ENDGROUP"])}return n}function he(e,t,r){var u,c;let{op:i,l:n}=e,s=(u=t[n])!=null?u:0;if(i==="+"){let l=Math.max(...Object.values(t))===s&&s>0;return r==null||r(["info",302,{matched:l,description:`${e.l} has the highest score`}]),l}else if(i==="-"){let l=Math.min(...Object.values(t))===s&&s>0;return r==null||r(["info",302,{matched:l,description:`${e.l} has the lowest non-zero score`}]),l}let o=parseInt(e.rDim?t[e.rDim]:e.r,10);if(isNaN(o))return r==null||r(["info",302,{matched:!1,description:`${(c=e.rDim)!=null?c:e.r} has no score value`}]),!1;if(i===">"){let l=s>o;return j(r,l,e,s,o),l}else if(i===">="){let l=s>=o;return j(r,l,e,s,o),l}else if(i==="<"){let l=s<o;return j(r,l,e,s,o),l}else if(i==="<="){let l=s<=o;return j(r,l,e,s,o),l}else if(i==="="){let l=s===o;return j(r,l,e,s,o),l}else if(i==="!="){let l=s!==o;return j(r,l,e,s,o),l}else throw new Error(`Unknown op: ${i}`)}function j(e,t,r,i,n){e==null||e(["info",302,{matched:t,description:`${r.l}[${i}] ${r.op} ${r.rDim?`${r.rDim}[${n}]`:r.r}`}])}var Ge=e=>{let{values:t,total:r,missingDistribution:i}=e.reduce((n,s)=>(s.testDistribution?n.total+=s.testDistribution:++n.missingDistribution,n.values.push(s.testDistribution),n),{values:[],total:0,missingDistribution:0});if(r>100)throw new Error(`Total distribution ${r} is over the maximum 100.`);if(r<100){let s=(100-r)/i;t.forEach((o,u)=>{typeof o=="undefined"&&(t[u]=s)})}return t},ht=({name:e,context:t,variations:r,onLogMessage:i})=>{i==null||i(["info",400,"GROUP",e]);try{let n,s=t.getTestVariantId(e);if(s===null)return i==null||i(["error",401,e]),{result:void 0,variantAssigned:!1};if(s&&(n=r.find(o=>o.id===s),n||i==null||i(["warn",402,{missingVariant:s,variants:r.map(o=>o.id)}])),!n){let o=Ge(r),u=Math.floor(Math.random()*100),c=0;n=r.find((l,f)=>{let p=o[f];if(u>c&&u<=c+p)return l;c+=p}),n&&(i==null||i(["info",403,n.id]),t.setTestVariantId(e,n.id))}return n&&(i==null||i(["info",404,n.id])),{result:n,variantAssigned:!s}}finally{i==null||i(["info",400,"ENDGROUP"])}};var Gt=require("dequal/lite"),C,R,T,rt,h,Q,gt,zt=class{constructor(t){d(this,Q);y(this,"manifest");d(this,C,void 0);d(this,R,{});d(this,T,void 0);d(this,rt,{});d(this,h,(0,ge.default)());y(this,"events",{on:a(this,h).on,off:a(this,h).off});y(this,"storage");var n,s;let{manifest:r,...i}=t;m(this,T,{}),(n=t.plugins)==null||n.forEach(o=>{!o.logDrain||a(this,h).on("log",o.logDrain)}),a(this,h).emit("log",["info",1,"GROUP"]);try{this.manifest=new B({onLogMessage:o=>a(this,h).emit("log",o),manifest:r,evaluator:new N({CK:Dt,QS:Ct,QK:xt,PVC:ut,EVT:bt,PV:Vt})}),this.storage=new L({...i,manifest:this.manifest,onServerTransitionReceived:o=>{m(this,C,o),o.ssv&&(m(this,R,o.ssv),a(this,h).emit("log",["debug",130,o.ssv]))},onLogMessage:o=>a(this,h).emit("log",o)}),this.storage.events.on("scoresUpdated",S(this,Q,gt).bind(this)),a(this,C)||S(this,Q,gt).call(this,this.storage.data),this.storage.events.on("quirksUpdated",o=>{let u=this.manifest.computeSignals({scores:a(this,R),state:a(this,T),previousState:a(this,T),visitor:this.storage.data});this.storage.updateData(u),a(this,h).emit("quirksUpdated",o.quirks),a(this,h).emit("log",["info",4,o.quirks])}),(s=t.plugins)==null||s.forEach(o=>{!o.init||o.init(this)})}finally{a(this,h).emit("log",["info",1,"ENDGROUP"])}}get scores(){return a(this,R)}get quirks(){var t,r;return(r=(t=a(this,C))==null?void 0:t.quirks)!=null?r:this.storage.data.quirks}async update(t){var i,n,s;let r=[];(i=a(this,C))!=null&&i.quirks&&(t={...t,quirks:{...a(this,C).quirks,...t.quirks||{}}}),(n=a(this,C))!=null&&n.tests&&r.push(...Object.entries(a(this,C).tests).map(([o,u])=>({type:"settest",data:{test:o,variant:u}})));try{a(this,h).emit("log",["info",2,"GROUP",{...t,url:(s=t.url)==null?void 0:s.toString()}]),t.quirks&&r.push(...Object.entries(t.quirks).map(([o,u])=>({type:"setquirk",data:{key:o,value:u}}))),t.enrichments&&t.enrichments.forEach(o=>{let u=W(o.cat,o.key);this.manifest.getDimensionByKey(u)?r.push({type:"modscore",data:{dimension:u,delta:o.str}}):a(this,h).emit("log",["warn",5,o])}),r.push(...this.manifest.computeSignals({state:t,previousState:a(this,T),visitor:this.storage.data,scores:a(this,R)})),m(this,T,{...a(this,T),...t}),await this.storage.updateData(r),a(this,C)&&(S(this,Q,gt).call(this,this.storage.data),m(this,C,void 0),a(this,h).emit("log",["debug",131]))}finally{a(this,h).emit("log",["info",2,"ENDGROUP"])}}getTestVariantId(t){var i;let r=this.manifest.getTest(t);return r?(i=r.wv)!=null?i:this.storage.data.tests[t]:(a(this,h).emit("log",["warn",401,t]),null)}setTestVariantId(t,r){this.storage.updateData([{type:"settest",data:{test:t,variant:r}}])}log(...t){a(this,h).emit("log",t)}test(t){var i,n;let r=ht({...t,context:this,onLogMessage:s=>a(this,h).emit("log",s)});return a(this,h).emit("testResult",{name:t.name,variantId:(n=(i=r.result)==null?void 0:i.id)!=null?n:void 0,variantAssigned:r.variantAssigned}),r}personalize(t){let r=Nt({...t,context:this,onLogMessage:s=>a(this,h).emit("log",s)}),i=a(this,rt)[t.name],n={name:t.name,variantIds:r.variations.map(s=>{var o;return(o=s.id)!=null?o:"Unknown"}),control:this.storage.data.controlGroup,changed:!0};return i&&(0,Gt.dequal)(n.variantIds,i)&&(n.changed=!1),a(this,h).emit("personalizationResult",n),a(this,rt)[t.name]=n.variantIds,r}async forget(t){m(this,T,{}),await this.storage.delete(t)}};C=new WeakMap,R=new WeakMap,T=new WeakMap,rt=new WeakMap,h=new WeakMap,Q=new WeakSet,gt=function(t){var n;let r={...t.scores};for(let s in t.sessionScores)r[s]=((n=r[s])!=null?n:0)+t.sessionScores[s];r=this.manifest.computeAggregateDimensions(r),!(0,Gt.dequal)(r,a(this,R))&&(m(this,R,r),a(this,h).emit("scoresUpdated",r),a(this,h).emit("log",["info",3,r]))};var ve=$(require("rfdc"));function vt(e,t){if(e==="none")return!1;switch(t){case"debug":return e==="debug";case"info":return e==="info"||e==="debug";case"warn":return e==="warn"||e==="info"||e==="debug";case"error":return e==="debug"||"info";default:return!1}}var ze=(0,ve.default)();function Se(e){return([t,...r])=>{if(!vt(e,t))return;let[i,...n]=r;console[t](`\u{1F94B} [${t}] Uniform event ID ${i}
`,...n.map(ze))}}function Ie(e){return{logDrain:Se(e)}}var ye={1:()=>["context","initializing Uniform Context"],2:e=>["context","received update()",e],3:e=>["context","new score vector",e],4:e=>["context","updated quirks",e],5:e=>["context","ignored enrichment update for unknown enrichment category",e.cat],101:e=>["storage","received update commands",e],102:e=>["storage","data was updated",e],103:e=>["storage",`deleting visitor data ${e?"from all devices":"from this device"}`],104:e=>["context",e?"Visitor assigned to personalization control group":"Visitor assigned to personalization experiment group"],110:({dim:e,cap:t,score:r})=>["storage",`${e} score ${r} exceeded cap ${t}. Rounded down.`],120:()=>["storage","visitor data expired and was cleared"],130:e=>["storage","server to client transition score data was loaded; it will persist until the next update event occurs",e],131:()=>["storage","server to client transition data was discarded"],140:e=>["storage",`score decay was applied: ${e}`],200:()=>["signals","evaluating signals"],201:e=>["signals",`evaluating signal ${e.id} (${e.dur})`],202:e=>["signals",e.op==="|"?"OR":"AND"],203:({criteria:e,result:t,explanation:r})=>["signals",`${e.type}: ${r} is ${t.result} [${t.changed?"CHANGED":"unchanged"}]`],204:e=>["signals",`group result: ${e.result} [${e.changed?"CHANGED":"unchanged"}]`],300:e=>["personalization",`executing personalization '${e.name}'`],301:({id:e,op:t})=>["personalization",`testing variation ${e} (${t==="|"?"OR":"AND"})`],302:({matched:e,description:t})=>["personalization",`${t} is ${e}`],303:e=>["personalization",e?"selected variation":"did not select variation"],400:e=>["testing",`executing A/B test '${e}'`],401:e=>["testing",`${e} is not registered in the manifest; it will not be run.`],402:({missingVariant:e,variants:t})=>["testing",`test variation '${e}' previously assigned to the visitor for this test no longer exists as a variant. It will be removed. This may indicate changing test variations after publishing a test, which will make results invalid. Known variants: ${t.join(", ")}`],403:e=>["testing",`assigned new test variant '${e}'`],404:e=>["testing",`displaying variation '${e}'`],700:()=>["gtag","gtag is not defined, skipping analytics event emission. Ensure you have added the gtag script to your page."],701:()=>["gtag","enabled gtag event signal redirection"]};var De=$(require("rfdc")),qe=(0,De.default)();function Ce(e,t){let r=typeof document=="undefined",{enableOnServer:i=!1}=t!=null?t:{};return([n,...s])=>{if(!vt(e,n)||r&&!i)return;let[o,...u]=s,c=console[n];if(u[0]==="GROUP"&&(u.shift(),c=console.groupCollapsed),u[0]==="ENDGROUP"){console.groupEnd();return}let l=ye[o],f="";switch(n){case"debug":f="\u{1F41E}";break;case"info":f="\u{1F4AC}";break;case"warn":f="\u26A0\uFE0F";break;case"error":f="\u{1F4A5}";break}let p=f;if(!l){c(`${p} unknown event ID ${o}. Log messages data may be older than Uniform Context package.`,...u);return}let[v,D,...it]=l(...u);c(`${p}[${v}] ${D}
`,...it.map(qe))}}function _e(e,t){return{logDrain:Ce(e,t)}}var xe=(u=>(u.ListStart="nesi-list-start",u.ListEnd="nesi-list-end",u.ListItem="nesi-list-item-html",u.ListItemSettings="nesi-list-item-settings",u.TestStart="nesi-test-start",u.TestEnd="nesi-test-end",u.Unknown="unknown",u))(xe||{}),je="nesitag";var It=typeof top!="undefined";function Qe(){return{logDrain:e=>{!It||top==null||top.postMessage({type:"uniform:context:log",message:e},window.location.origin)},init:e=>{let t=[],r=[],i=()=>{!It||top==null||top.postMessage({type:"uniform:context:data",data:{scores:e.scores,data:e.storage.data,manifest:e.manifest.data,personalizations:t,tests:r}},window.location.origin)},n=o=>{!o.changed||(t.push(o),i())},s=o=>{!o.variantAssigned||(r.push(o),i())};if(It){window.__UNIFORM_DEVTOOLS_CONTEXT_INSTANCE__=e;try{top==null||top.addEventListener("message",async o=>{if(!o.data)return;let u=o.data;await Fe(u,e)})}catch(o){console.warn("Unable to initialize Uniform Context DevTools because it is in a cross-domain iframe.",o)}top==null||top.postMessage({type:"uniform:context:hello",uiVersion:2},window.location.origin),i()}return e.events.on("personalizationResult",n),e.events.on("testResult",s),e.events.on("scoresUpdated",i),e.storage.events.on("*",i),()=>{e.events.off("scoresUpdated",i),e.storage.events.off("*",i),e.events.off("personalizationResult",n),e.events.off("testResult",s)}}}}async function Fe(e,t){e.type==="uniform-in:context:update"&&e.newData&&await t.update(e.newData),e.type==="uniform-in:context:commands"&&e.commands&&Array.isArray(e.commands)&&await t.storage.updateData(e.commands),e.type==="uniform-in:context:forget"&&await t.forget(!1)}function Ke(e){return`${e.apiKey}|${e.projectId}${e.apiHost?`|${e.apiHost}`:""}`}function He(e){let[t,r,i]=e.split("|");if(!t.startsWith("uf"))throw new Error("Invalid API key");if(!/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12})$/i.test(r))throw new Error("Invalid project ID");return{apiKey:t,projectId:r,apiHost:i||"https://uniform.app"}}0&&(module.exports={Context,CookieTransitionDataStore,EdgeNodeTagName,EdgeTransitionDataStore,GroupCriteriaEvaluator,ManifestInstance,SERVER_STATE_ID,ScriptType,TransitionDataStore,UNIFORM_DEFAULT_COOKIE_NAME,VisitorDataStore,computeAggregateDimensions,cookieEvaluator,createConsoleLogDrain,createDebugConsoleLogDrain,createLinearDecay,currentPageEvaluator,emptyVisitorData,enableConsoleLogDrain,enableContextDevTools,enableDebugConsoleLogDrain,evaluateVariantMatch,eventEvaluator,explainStringMatch,explainStringMatchCriteria,getEnrichmentVectorKey,isStringMatch,pageViewCountDimension,pageViewCountEvaluator,parseQuickConnect,personalizeVariations,queryStringEvaluator,quirkEvaluator,serializeQuickConnect,testVariations});
{
"name": "@uniformdev/context",
"version": "16.0.1-alpha.221+a3ca75662",
"version": "16.0.1-nuxt.146+04197b8d4",
"description": "Uniform Context core package",

@@ -54,3 +54,3 @@ "license": "SEE LICENSE IN LICENSE.txt",

"@types/yargs": "17.0.10",
"@uniformdev/cli": "^16.0.1-alpha.221+a3ca75662",
"@uniformdev/cli": "^16.0.1-nuxt.146+04197b8d4",
"benny": "3.7.1",

@@ -73,3 +73,3 @@ "yargs": "17.5.1"

},
"gitHead": "a3ca7566254cda6539ae81923567cc06754241aa"
"gitHead": "04197b8d483707f49939875b690b902f48f1ccfe"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc