"use strict";(()=>{var Jo=Object.create;var cr=Object.defineProperty;var Xo=Object.getOwnPropertyDescriptor;var Zo=Object.getOwnPropertyNames;var ec=Object.getPrototypeOf,tc=Object.prototype.hasOwnProperty;var d=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var nc=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Zo(t))!tc.call(e,i)&&i!==n&&cr(e,i,{get:()=>t[i],enumerable:!(r=Xo(t,i))||r.enumerable});return e};var G=(e,t,n)=>(n=e!=null?Jo(ec(e)):{},nc(t||!e||!e.__esModule?cr(n,"default",{value:e,enumerable:!0}):n,e));var L=d((Lf,lr)=>{var rc=lr.exports=typeof window<"u"&&window.Math==Math?window:typeof self<"u"&&self.Math==Math?self:Function("return this")();typeof __g=="number"&&(__g=rc)});var O=d((Cf,ur)=>{var ic=ur.exports={version:"2.6.12"};typeof __e=="number"&&(__e=ic)});var $=d((Rf,dr)=>{dr.exports=function(e){return typeof e=="object"?e!==null:typeof e=="function"}});var U=d((wf,fr)=>{var sc=$();fr.exports=function(e){if(!sc(e))throw TypeError(e+" is not an object!");return e}});var We=d((Of,pr)=>{pr.exports=function(e){try{return!!e()}catch{return!0}}});var K=d((Mf,mr)=>{mr.exports=!We()(function(){return Object.defineProperty({},"a",{get:function(){return 7}}).a!=7})});var Ge=d((Df,hr)=>{var yr=$(),Dt=L().document,ac=yr(Dt)&&yr(Dt.createElement);hr.exports=function(e){return ac?Dt.createElement(e):{}}});var vr=d((Pf,gr)=>{gr.exports=!K()&&!We()(function(){return Object.defineProperty(Ge()("div"),"a",{get:function(){return 7}}).a!=7})});var Tr=d((kf,Ar)=>{var $e=$();Ar.exports=function(e,t){if(!$e(e))return e;var n,r;if(t&&typeof(n=e.toString)=="function"&&!$e(r=n.call(e))||typeof(n=e.valueOf)=="function"&&!$e(r=n.call(e))||!t&&typeof(n=e.toString)=="function"&&!$e(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")}});var Te=d(br=>{var Er=U(),oc=vr(),cc=Tr(),lc=Object.defineProperty;br.f=K()?Object.defineProperty:function(t,n,r){if(Er(t),n=cc(n,!0),Er(r),oc)try{return lc(t,n,r)}catch{}if("get"in r||"set"in r)throw TypeError("Accessors not supported!");return"value"in r&&(t[n]=r.value),t}});var Pt=d((jf,Ir)=>{Ir.exports=function(e,t){return{enumerable:!(e&1),configurable:!(e&2),writable:!(e&4),value:t}}});var z=d((Hf,xr)=>{var uc=Te(),dc=Pt();xr.exports=K()?function(e,t,n){return uc.f(e,t,dc(1,n))}:function(e,t,n){return e[t]=n,e}});var Ee=d((Nf,_r)=>{var fc={}.hasOwnProperty;_r.exports=function(e,t){return fc.call(e,t)}});var Ke=d((Uf,Sr)=>{var pc=0,mc=Math.random();Sr.exports=function(e){return"Symbol(".concat(e===void 0?"":e,")_",(++pc+mc).toString(36))}});var ze=d((Ff,Lr)=>{Lr.exports=!1});var Ye=d((Vf,Or)=>{var yc=O(),Cr=L(),Rr="__core-js_shared__",wr=Cr[Rr]||(Cr[Rr]={});(Or.exports=function(e,t){return wr[e]||(wr[e]=t!==void 0?t:{})})("versions",[]).push({version:yc.version,mode:ze()?"pure":"global",copyright:"\xA9 2020 Denis Pushkarev (zloirock.ru)"})});var Dr=d((Bf,Mr)=>{Mr.exports=Ye()("native-function-to-string",Function.toString)});var ie=d((Qf,qr)=>{var hc=L(),Je=z(),Pr=Ee(),kt=Ke()("src"),qt=Dr(),kr="toString",gc=(""+qt).split(kr);O().inspectSource=function(e){return qt.call(e)};(qr.exports=function(e,t,n,r){var i=typeof n=="function";i&&(Pr(n,"name")||Je(n,"name",t)),e[t]!==n&&(i&&(Pr(n,kt)||Je(n,kt,e[t]?""+e[t]:gc.join(String(t)))),e===hc?e[t]=n:r?e[t]?e[t]=n:Je(e,t,n):(delete e[t],Je(e,t,n)))})(Function.prototype,kr,function(){return typeof this=="function"&&this[kt]||qt.call(this)})});var be=d((Wf,jr)=>{jr.exports=function(e){if(typeof e!="function")throw TypeError(e+" is not a function!");return e}});var Ie=d((Gf,Hr)=>{var vc=be();Hr.exports=function(e,t,n){if(vc(e),t===void 0)return e;switch(n){case 1:return function(r){return e.call(t,r)};case 2:return function(r,i){return e.call(t,r,i)};case 3:return function(r,i,s){return e.call(t,r,i,s)}}return function(){return e.apply(t,arguments)}}});var F=d(($f,Ur)=>{var se=L(),Xe=O(),Ac=z(),Tc=ie(),Nr=Ie(),jt="prototype",S=function(e,t,n){var r=e&S.F,i=e&S.G,s=e&S.S,o=e&S.P,c=e&S.B,l=i?se:s?se[t]||(se[t]={}):(se[t]||{})[jt],u=i?Xe:Xe[t]||(Xe[t]={}),p=u[jt]||(u[jt]={}),f,m,A,q;i&&(n=t);for(f in n)m=!r&&l&&l[f]!==void 0,A=(m?l:n)[f],q=c&&m?Nr(A,se):o&&typeof A=="function"?Nr(Function.call,A):A,l&&Tc(l,f,A,e&S.U),u[f]!=A&&Ac(u,f,q),o&&p[f]!=A&&(p[f]=A)};se.core=Xe;S.F=1;S.G=2;S.S=4;S.P=8;S.B=16;S.W=32;S.U=64;S.R=128;Ur.exports=S});var ae=d((Kf,Fr)=>{var Ec={}.toString;Fr.exports=function(e){return Ec.call(e).slice(8,-1)}});var Ht=d((zf,Vr)=>{var bc=ae();Vr.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return bc(e)=="String"?e.split(""):Object(e)}});var xe=d((Yf,Br)=>{Br.exports=function(e){if(e==null)throw TypeError("Can't call method on  "+e);return e}});var Ze=d((Jf,Qr)=>{var Ic=Ht(),xc=xe();Qr.exports=function(e){return Ic(xc(e))}});var et=d((Xf,Wr)=>{var _c=Math.ceil,Sc=Math.floor;Wr.exports=function(e){return isNaN(e=+e)?0:(e>0?Sc:_c)(e)}});var Nt=d((Zf,Gr)=>{var Lc=et(),Cc=Math.min;Gr.exports=function(e){return e>0?Cc(Lc(e),9007199254740991):0}});var Kr=d((ep,$r)=>{var Rc=et(),wc=Math.max,Oc=Math.min;$r.exports=function(e,t){return e=Rc(e),e<0?wc(e+t,0):Oc(e,t)}});var Ut=d((tp,zr)=>{var Mc=Ze(),Dc=Nt(),Pc=Kr();zr.exports=function(e){return function(t,n,r){var i=Mc(t),s=Dc(i.length),o=Pc(r,s),c;if(e&&n!=n){for(;s>o;)if(c=i[o++],c!=c)return!0}else for(;s>o;o++)if((e||o in i)&&i[o]===n)return e||o||0;return!e&&-1}}});var I=d((np,Jr)=>{var Ft=Ye()("wks"),kc=Ke(),Vt=L().Symbol,Yr=typeof Vt=="function",qc=Jr.exports=function(e){return Ft[e]||(Ft[e]=Yr&&Vt[e]||(Yr?Vt:kc)("Symbol."+e))};qc.store=Ft});var Wt=d((rp,Xr)=>{var Bt=I()("unscopables"),Qt=Array.prototype;Qt[Bt]==null&&z()(Qt,Bt,{});Xr.exports=function(e){Qt[Bt][e]=!0}});var ei=d(()=>{"use strict";var Zr=F(),jc=Ut()(!0);Zr(Zr.P,"Array",{includes:function(t){return jc(this,t,arguments.length>1?arguments[1]:void 0)}});Wt()("includes")});var ni=d((ap,ti)=>{ei();ti.exports=O().Array.includes});var tt=d((op,ii)=>{var ri=Ye()("keys"),Hc=Ke();ii.exports=function(e){return ri[e]||(ri[e]=Hc(e))}});var oi=d((cp,ai)=>{var si=Ee(),Nc=Ze(),Uc=Ut()(!1),Fc=tt()("IE_PROTO");ai.exports=function(e,t){var n=Nc(e),r=0,i=[],s;for(s in n)s!=Fc&&si(n,s)&&i.push(s);for(;t.length>r;)si(n,s=t[r++])&&(~Uc(i,s)||i.push(s));return i}});var Gt=d((lp,ci)=>{ci.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")});var nt=d((up,li)=>{var Vc=oi(),Bc=Gt();li.exports=Object.keys||function(t){return Vc(t,Bc)}});var di=d(ui=>{ui.f=Object.getOwnPropertySymbols});var pi=d(fi=>{fi.f={}.propertyIsEnumerable});var $t=d((pp,mi)=>{var Qc=xe();mi.exports=function(e){return Object(Qc(e))}});var gi=d((mp,hi)=>{"use strict";var Wc=K(),yi=nt(),Gc=di(),$c=pi(),Kc=$t(),zc=Ht(),rt=Object.assign;hi.exports=!rt||We()(function(){var e={},t={},n=Symbol(),r="abcdefghijklmnopqrst";return e[n]=7,r.split("").forEach(function(i){t[i]=i}),rt({},e)[n]!=7||Object.keys(rt({},t)).join("")!=r})?function(t,n){for(var r=Kc(t),i=arguments.length,s=1,o=Gc.f,c=$c.f;i>s;)for(var l=zc(arguments[s++]),u=o?yi(l).concat(o(l)):yi(l),p=u.length,f=0,m;p>f;)m=u[f++],(!Wc||c.call(l,m))&&(r[m]=l[m]);return r}:rt});var vi=d(()=>{var Kt=F();Kt(Kt.S+Kt.F,"Object",{assign:gi()})});var Ti=d((gp,Ai)=>{vi();Ai.exports=O().Object.assign});var it=d((vp,Ei)=>{var zt=ae(),Yc=I()("toStringTag"),Jc=zt(function(){return arguments}())=="Arguments",Xc=function(e,t){try{return e[t]}catch{}};Ei.exports=function(e){var t,n,r;return e===void 0?"Undefined":e===null?"Null":typeof(n=Xc(t=Object(e),Yc))=="string"?n:Jc?zt(t):(r=zt(t))=="Object"&&typeof t.callee=="function"?"Arguments":r}});var Ii=d(()=>{"use strict";var Zc=it(),bi={};bi[I()("toStringTag")]="z";bi+""!="[object z]"&&ie()(Object.prototype,"toString",function(){return"[object "+Zc(this)+"]"},!0)});var _i=d((Ep,xi)=>{var el=et(),tl=xe();xi.exports=function(e){return function(t,n){var r=String(tl(t)),i=el(n),s=r.length,o,c;return i<0||i>=s?e?"":void 0:(o=r.charCodeAt(i),o<55296||o>56319||i+1===s||(c=r.charCodeAt(i+1))<56320||c>57343?e?r.charAt(i):o:e?r.slice(i,i+2):(o-55296<<10)+(c-56320)+65536)}}});var oe=d((bp,Si)=>{Si.exports={}});var Ci=d((Ip,Li)=>{var nl=Te(),rl=U(),il=nt();Li.exports=K()?Object.defineProperties:function(t,n){rl(t);for(var r=il(n),i=r.length,s=0,o;i>s;)nl.f(t,o=r[s++],n[o]);return t}});var Yt=d((xp,wi)=>{var Ri=L().document;wi.exports=Ri&&Ri.documentElement});var Di=d((_p,Mi)=>{var sl=U(),al=Ci(),Oi=Gt(),ol=tt()("IE_PROTO"),Jt=function(){},Xt="prototype",st=function(){var e=Ge()("iframe"),t=Oi.length,n="<",r=">",i;for(e.style.display="none",Yt().appendChild(e),e.src="javascript:",i=e.contentWindow.document,i.open(),i.write(n+"script"+r+"document.F=Object"+n+"/script"+r),i.close(),st=i.F;t--;)delete st[Xt][Oi[t]];return st()};Mi.exports=Object.create||function(t,n){var r;return t!==null?(Jt[Xt]=sl(t),r=new Jt,Jt[Xt]=null,r[ol]=t):r=st(),n===void 0?r:al(r,n)}});var at=d((Sp,ki)=>{var cl=Te().f,ll=Ee(),Pi=I()("toStringTag");ki.exports=function(e,t,n){e&&!ll(e=n?e:e.prototype,Pi)&&cl(e,Pi,{configurable:!0,value:t})}});var Hi=d((Lp,ji)=>{"use strict";var ul=Di(),dl=Pt(),fl=at(),qi={};z()(qi,I()("iterator"),function(){return this});ji.exports=function(e,t,n){e.prototype=ul(qi,{next:dl(1,n)}),fl(e,t+" Iterator")}});var Fi=d((Cp,Ui)=>{var pl=Ee(),ml=$t(),Ni=tt()("IE_PROTO"),yl=Object.prototype;Ui.exports=Object.getPrototypeOf||function(e){return e=ml(e),pl(e,Ni)?e[Ni]:typeof e.constructor=="function"&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?yl:null}});var tn=d((Rp,$i)=>{"use strict";var Vi=ze(),Zt=F(),hl=ie(),Bi=z(),Qi=oe(),gl=Hi(),vl=at(),Al=Fi(),_e=I()("iterator"),en=!([].keys&&"next"in[].keys()),Tl="@@iterator",Wi="keys",ot="values",Gi=function(){return this};$i.exports=function(e,t,n,r,i,s,o){gl(n,t,r);var c=function(W){if(!en&&W in f)return f[W];switch(W){case Wi:return function(){return new n(this,W)};case ot:return function(){return new n(this,W)}}return function(){return new n(this,W)}},l=t+" Iterator",u=i==ot,p=!1,f=e.prototype,m=f[_e]||f[Tl]||i&&f[i],A=m||c(i),q=i?u?c("entries"):A:void 0,Be=t=="Array"&&f.entries||m,y,Qe,re;if(Be&&(re=Al(Be.call(new e)),re!==Object.prototype&&re.next&&(vl(re,l,!0),!Vi&&typeof re[_e]!="function"&&Bi(re,_e,Gi))),u&&m&&m.name!==ot&&(p=!0,A=function(){return m.call(this)}),(!Vi||o)&&(en||p||!f[_e])&&Bi(f,_e,A),Qi[t]=A,Qi[l]=Gi,i)if(y={values:u?A:c(ot),keys:s?A:c(Wi),entries:q},o)for(Qe in y)Qe in f||hl(f,Qe,y[Qe]);else Zt(Zt.P+Zt.F*(en||p),t,y);return y}});var Ki=d(()=>{"use strict";var El=_i()(!0);tn()(String,"String",function(e){this._t=String(e),this._i=0},function(){var e=this._t,t=this._i,n;return t>=e.length?{value:void 0,done:!0}:(n=El(e,t),this._i+=n.length,{value:n,done:!1})})});var Yi=d((Mp,zi)=>{zi.exports=function(e,t){return{value:t,done:!!e}}});var Zi=d((Dp,Xi)=>{"use strict";var nn=Wt(),ct=Yi(),Ji=oe(),bl=Ze();Xi.exports=tn()(Array,"Array",function(e,t){this._t=bl(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,ct(1)):t=="keys"?ct(0,n):t=="values"?ct(0,e[n]):ct(0,[n,e[n]])},"values");Ji.Arguments=Ji.Array;nn("keys");nn("values");nn("entries")});var ls=d(()=>{var es=Zi(),Il=nt(),xl=ie(),_l=L(),ts=z(),os=oe(),cs=I(),ns=cs("iterator"),rs=cs("toStringTag"),is=os.Array,ss={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1};for(rn=Il(ss),lt=0;lt<rn.length;lt++)if(Se=rn[lt],as=ss[Se],sn=_l[Se],V=sn&&sn.prototype,V&&(V[ns]||ts(V,ns,is),V[rs]||ts(V,rs,Se),os[Se]=is,as))for(Le in es)V[Le]||xl(V,Le,es[Le],!0);var Se,as,sn,V,Le,rn,lt});var ds=d((qp,us)=>{us.exports=function(e,t,n,r){if(!(e instanceof t)||r!==void 0&&r in e)throw TypeError(n+": incorrect invocation!");return e}});var ms=d((jp,ps)=>{var fs=U();ps.exports=function(e,t,n,r){try{return r?t(fs(n)[0],n[1]):t(n)}catch(s){var i=e.return;throw i!==void 0&&fs(i.call(e)),s}}});var hs=d((Hp,ys)=>{var Sl=oe(),Ll=I()("iterator"),Cl=Array.prototype;ys.exports=function(e){return e!==void 0&&(Sl.Array===e||Cl[Ll]===e)}});var vs=d((Np,gs)=>{var Rl=it(),wl=I()("iterator"),Ol=oe();gs.exports=O().getIteratorMethod=function(e){if(e!=null)return e[wl]||e["@@iterator"]||Ol[Rl(e)]}});var Ts=d((ut,As)=>{var Ml=Ie(),Dl=ms(),Pl=hs(),kl=U(),ql=Nt(),jl=vs(),an={},on={},ut=As.exports=function(e,t,n,r,i){var s=i?function(){return e}:jl(e),o=Ml(n,r,t?2:1),c=0,l,u,p,f;if(typeof s!="function")throw TypeError(e+" is not iterable!");if(Pl(s)){for(l=ql(e.length);l>c;c++)if(f=t?o(kl(u=e[c])[0],u[1]):o(e[c]),f===an||f===on)return f}else for(p=s.call(e);!(u=p.next()).done;)if(f=Dl(p,o,u.value,t),f===an||f===on)return f};ut.BREAK=an;ut.RETURN=on});var cn=d((Up,bs)=>{var Es=U(),Hl=be(),Nl=I()("species");bs.exports=function(e,t){var n=Es(e).constructor,r;return n===void 0||(r=Es(n)[Nl])==null?t:Hl(r)}});var xs=d((Fp,Is)=>{Is.exports=function(e,t,n){var r=n===void 0;switch(t.length){case 0:return r?e():e.call(n);case 1:return r?e(t[0]):e.call(n,t[0]);case 2:return r?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}});var yn=d((Vp,Os)=>{var dt=Ie(),Ul=xs(),_s=Yt(),Ss=Ge(),j=L(),Ls=j.process,pn=j.setImmediate,mn=j.clearImmediate,Cs=j.MessageChannel,ln=j.Dispatch,un=0,Re={},Rs="onreadystatechange",Y,dn,fn,Ce=function(){var e=+this;if(Re.hasOwnProperty(e)){var t=Re[e];delete Re[e],t()}},ws=function(e){Ce.call(e.data)};(!pn||!mn)&&(pn=function(t){for(var n=[],r=1;arguments.length>r;)n.push(arguments[r++]);return Re[++un]=function(){Ul(typeof t=="function"?t:Function(t),n)},Y(un),un},mn=function(t){delete Re[t]},ae()(Ls)=="process"?Y=function(e){Ls.nextTick(dt(Ce,e,1))}:ln&&ln.now?Y=function(e){ln.now(dt(Ce,e,1))}:Cs?(dn=new Cs,fn=dn.port2,dn.port1.onmessage=ws,Y=dt(fn.postMessage,fn,1)):j.addEventListener&&typeof postMessage=="function"&&!j.importScripts?(Y=function(e){j.postMessage(e+"","*")},j.addEventListener("message",ws,!1)):Rs in Ss("script")?Y=function(e){_s.appendChild(Ss("script"))[Rs]=function(){_s.removeChild(this),Ce.call(e)}}:Y=function(e){setTimeout(dt(Ce,e,1),0)});Os.exports={set:pn,clear:mn}});var ks=d((Bp,Ps)=>{var J=L(),Fl=yn().set,Ms=J.MutationObserver||J.WebKitMutationObserver,gn=J.process,hn=J.Promise,Ds=ae()(gn)=="process";Ps.exports=function(){var e,t,n,r=function(){var c,l;for(Ds&&(c=gn.domain)&&c.exit();e;){l=e.fn,e=e.next;try{l()}catch(u){throw e?n():t=void 0,u}}t=void 0,c&&c.enter()};if(Ds)n=function(){gn.nextTick(r)};else if(Ms&&!(J.navigator&&J.navigator.standalone)){var i=!0,s=document.createTextNode("");new Ms(r).observe(s,{characterData:!0}),n=function(){s.data=i=!i}}else if(hn&&hn.resolve){var o=hn.resolve(void 0);n=function(){o.then(r)}}else n=function(){Fl.call(J,r)};return function(c){var l={fn:c,next:void 0};t&&(t.next=l),e||(e=l,n()),t=l}}});var ft=d((Qp,js)=>{"use strict";var qs=be();function Vl(e){var t,n;this.promise=new e(function(r,i){if(t!==void 0||n!==void 0)throw TypeError("Bad Promise constructor");t=r,n=i}),this.resolve=qs(t),this.reject=qs(n)}js.exports.f=function(e){return new Vl(e)}});var vn=d((Wp,Hs)=>{Hs.exports=function(e){try{return{e:!1,v:e()}}catch(t){return{e:!0,v:t}}}});var Fs=d((Gp,Us)=>{var Bl=L(),Ns=Bl.navigator;Us.exports=Ns&&Ns.userAgent||""});var An=d(($p,Vs)=>{var Ql=U(),Wl=$(),Gl=ft();Vs.exports=function(e,t){if(Ql(e),Wl(t)&&t.constructor===e)return t;var n=Gl.f(e),r=n.resolve;return r(t),n.promise}});var Qs=d((Kp,Bs)=>{var $l=ie();Bs.exports=function(e,t,n){for(var r in t)$l(e,r,t[r],n);return e}});var $s=d((zp,Gs)=>{"use strict";var Kl=L(),zl=Te(),Yl=K(),Ws=I()("species");Gs.exports=function(e){var t=Kl[e];Yl&&t&&!t[Ws]&&zl.f(t,Ws,{configurable:!0,get:function(){return this}})}});var Ys=d((Yp,zs)=>{var En=I()("iterator"),Ks=!1;try{Tn=[7][En](),Tn.return=function(){Ks=!0},Array.from(Tn,function(){throw 2})}catch{}var Tn;zs.exports=function(e,t){if(!t&&!Ks)return!1;var n=!1;try{var r=[7],i=r[En]();i.next=function(){return{done:n=!0}},r[En]=function(){return i},e(r)}catch{}return n}});var ca=d(()=>{"use strict";var Js=ze(),B=L(),ce=Ie(),Jl=it(),C=F(),Xl=$(),Zl=be(),eu=ds(),Xs=Ts(),tu=cn(),na=yn().set,ra=ks()(),ia=ft(),bn=vn(),nu=Fs(),ru=An(),Q="Promise",sa=B.TypeError,ue=B.process,Zs=ue&&ue.versions,iu=Zs&&Zs.v8||"",D=B[Q],we=Jl(ue)=="process",mt=function(){},pt,aa,ea,xn,Oe=aa=ia.f,Me=!!function(){try{var e=D.resolve(1),t=(e.constructor={})[I()("species")]=function(n){n(mt,mt)};return(we||typeof PromiseRejectionEvent=="function")&&e.then(mt)instanceof t&&iu.indexOf("6.6")!==0&&nu.indexOf("Chrome/66")===-1}catch{}}(),oa=function(e){var t;return Xl(e)&&typeof(t=e.then)=="function"?t:!1},_n=function(e,t){if(!e._n){e._n=!0;var n=e._c;ra(function(){for(var r=e._v,i=e._s==1,s=0,o=function(c){var l=i?c.ok:c.fail,u=c.resolve,p=c.reject,f=c.domain,m,A,q;try{l?(i||(e._h==2&&au(e),e._h=1),l===!0?m=r:(f&&f.enter(),m=l(r),f&&(f.exit(),q=!0)),m===c.promise?p(sa("Promise-chain cycle")):(A=oa(m))?A.call(m,u,p):u(m)):p(r)}catch(Be){f&&!q&&f.exit(),p(Be)}};n.length>s;)o(n[s++]);e._c=[],e._n=!1,t&&!e._h&&su(e)})}},su=function(e){na.call(B,function(){var t=e._v,n=ta(e),r,i,s;if(n&&(r=bn(function(){we?ue.emit("unhandledRejection",t,e):(i=B.onunhandledrejection)?i({promise:e,reason:t}):(s=B.console)&&s.error&&s.error("Unhandled promise rejection",t)}),e._h=we||ta(e)?2:1),e._a=void 0,n&&r.e)throw r.v})},ta=function(e){return e._h!==1&&(e._a||e._c).length===0},au=function(e){na.call(B,function(){var t;we?ue.emit("rejectionHandled",e):(t=B.onrejectionhandled)&&t({promise:e,reason:e._v})})},le=function(e){var t=this;t._d||(t._d=!0,t=t._w||t,t._v=e,t._s=2,t._a||(t._a=t._c.slice()),_n(t,!0))},In=function(e){var t=this,n;if(!t._d){t._d=!0,t=t._w||t;try{if(t===e)throw sa("Promise can't be resolved itself");(n=oa(e))?ra(function(){var r={_w:t,_d:!1};try{n.call(e,ce(In,r,1),ce(le,r,1))}catch(i){le.call(r,i)}}):(t._v=e,t._s=1,_n(t,!1))}catch(r){le.call({_w:t,_d:!1},r)}}};Me||(D=function(t){eu(this,D,Q,"_h"),Zl(t),pt.call(this);try{t(ce(In,this,1),ce(le,this,1))}catch(n){le.call(this,n)}},pt=function(t){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},pt.prototype=Qs()(D.prototype,{then:function(t,n){var r=Oe(tu(this,D));return r.ok=typeof t=="function"?t:!0,r.fail=typeof n=="function"&&n,r.domain=we?ue.domain:void 0,this._c.push(r),this._a&&this._a.push(r),this._s&&_n(this,!1),r.promise},catch:function(e){return this.then(void 0,e)}}),ea=function(){var e=new pt;this.promise=e,this.resolve=ce(In,e,1),this.reject=ce(le,e,1)},ia.f=Oe=function(e){return e===D||e===xn?new ea(e):aa(e)});C(C.G+C.W+C.F*!Me,{Promise:D});at()(D,Q);$s()(Q);xn=O()[Q];C(C.S+C.F*!Me,Q,{reject:function(t){var n=Oe(this),r=n.reject;return r(t),n.promise}});C(C.S+C.F*(Js||!Me),Q,{resolve:function(t){return ru(Js&&this===xn?D:this,t)}});C(C.S+C.F*!(Me&&Ys()(function(e){D.all(e).catch(mt)})),Q,{all:function(t){var n=this,r=Oe(n),i=r.resolve,s=r.reject,o=bn(function(){var c=[],l=0,u=1;Xs(t,!1,function(p){var f=l++,m=!1;c.push(void 0),u++,n.resolve(p).then(function(A){m||(m=!0,c[f]=A,--u||i(c))},s)}),--u||i(c)});return o.e&&s(o.v),r.promise},race:function(t){var n=this,r=Oe(n),i=r.reject,s=bn(function(){Xs(t,!1,function(o){n.resolve(o).then(r.resolve,i)})});return s.e&&i(s.v),r.promise}})});var ua=d(()=>{"use strict";var Sn=F(),ou=O(),cu=L(),lu=cn(),la=An();Sn(Sn.P+Sn.R,"Promise",{finally:function(e){var t=lu(this,ou.Promise||cu.Promise),n=typeof e=="function";return this.then(n?function(r){return la(t,e()).then(function(){return r})}:e,n?function(r){return la(t,e()).then(function(){throw r})}:e)}})});var fa=d(()=>{"use strict";var da=F(),uu=ft(),du=vn();da(da.S,"Promise",{try:function(e){var t=uu.f(this),n=du(e);return(n.e?t.reject:t.resolve)(n.v),t.promise}})});var ma=d((rm,pa)=>{Ii();Ki();ls();ca();ua();fa();pa.exports=O().Promise});var ha=d((im,ya)=>{var fu=$(),pu=ae(),mu=I()("match");ya.exports=function(e){var t;return fu(e)&&((t=e[mu])!==void 0?!!t:pu(e)=="RegExp")}});var va=d((sm,ga)=>{var yu=ha(),hu=xe();ga.exports=function(e,t,n){if(yu(t))throw TypeError("String#"+n+" doesn't accept regex!");return String(hu(e))}});var Ta=d((am,Aa)=>{var gu=I()("match");Aa.exports=function(e){var t=/./;try{"/./"[e](t)}catch{try{return t[gu]=!1,!"/./"[e](t)}catch{}}return!0}});var ba=d(()=>{"use strict";var Ln=F(),vu=va(),Ea="includes";Ln(Ln.P+Ln.F*Ta()(Ea),"String",{includes:function(t){return!!~vu(this,t,Ea).indexOf(t,arguments.length>1?arguments[1]:void 0)}})});var xa=d((lm,Ia)=>{ba();Ia.exports=O().String.includes});var Tt=d((Em,Na)=>{Na.exports=Ha;function Ha(e,t){if(!e)throw new Error(t||"Assertion failed")}Ha.equal=function(t,n,r){if(t!=n)throw new Error(r||"Assertion failed: "+t+" != "+n)}});var Ua=d((bm,Dn)=>{typeof Object.create=="function"?Dn.exports=function(t,n){n&&(t.super_=n,t.prototype=Object.create(n.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:Dn.exports=function(t,n){if(n){t.super_=n;var r=function(){};r.prototype=n.prototype,t.prototype=new r,t.prototype.constructor=t}}});var Et=d(g=>{"use strict";var bu=Tt(),Iu=Ua();g.inherits=Iu;function xu(e,t){return(e.charCodeAt(t)&64512)!==55296||t<0||t+1>=e.length?!1:(e.charCodeAt(t+1)&64512)===56320}function _u(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var n=[];if(typeof e=="string")if(t){if(t==="hex")for(e=e.replace(/[^a-z0-9]+/ig,""),e.length%2!==0&&(e="0"+e),i=0;i<e.length;i+=2)n.push(parseInt(e[i]+e[i+1],16))}else for(var r=0,i=0;i<e.length;i++){var s=e.charCodeAt(i);s<128?n[r++]=s:s<2048?(n[r++]=s>>6|192,n[r++]=s&63|128):xu(e,i)?(s=65536+((s&1023)<<10)+(e.charCodeAt(++i)&1023),n[r++]=s>>18|240,n[r++]=s>>12&63|128,n[r++]=s>>6&63|128,n[r++]=s&63|128):(n[r++]=s>>12|224,n[r++]=s>>6&63|128,n[r++]=s&63|128)}else for(i=0;i<e.length;i++)n[i]=e[i]|0;return n}g.toArray=_u;function Su(e){for(var t="",n=0;n<e.length;n++)t+=Va(e[n].toString(16));return t}g.toHex=Su;function Fa(e){var t=e>>>24|e>>>8&65280|e<<8&16711680|(e&255)<<24;return t>>>0}g.htonl=Fa;function Lu(e,t){for(var n="",r=0;r<e.length;r++){var i=e[r];t==="little"&&(i=Fa(i)),n+=Ba(i.toString(16))}return n}g.toHex32=Lu;function Va(e){return e.length===1?"0"+e:e}g.zero2=Va;function Ba(e){return e.length===7?"0"+e:e.length===6?"00"+e:e.length===5?"000"+e:e.length===4?"0000"+e:e.length===3?"00000"+e:e.length===2?"000000"+e:e.length===1?"0000000"+e:e}g.zero8=Ba;function Cu(e,t,n,r){var i=n-t;bu(i%4===0);for(var s=new Array(i/4),o=0,c=t;o<s.length;o++,c+=4){var l;r==="big"?l=e[c]<<24|e[c+1]<<16|e[c+2]<<8|e[c+3]:l=e[c+3]<<24|e[c+2]<<16|e[c+1]<<8|e[c],s[o]=l>>>0}return s}g.join32=Cu;function Ru(e,t){for(var n=new Array(e.length*4),r=0,i=0;r<e.length;r++,i+=4){var s=e[r];t==="big"?(n[i]=s>>>24,n[i+1]=s>>>16&255,n[i+2]=s>>>8&255,n[i+3]=s&255):(n[i+3]=s>>>24,n[i+2]=s>>>16&255,n[i+1]=s>>>8&255,n[i]=s&255)}return n}g.split32=Ru;function wu(e,t){return e>>>t|e<<32-t}g.rotr32=wu;function Ou(e,t){return e<<t|e>>>32-t}g.rotl32=Ou;function Mu(e,t){return e+t>>>0}g.sum32=Mu;function Du(e,t,n){return e+t+n>>>0}g.sum32_3=Du;function Pu(e,t,n,r){return e+t+n+r>>>0}g.sum32_4=Pu;function ku(e,t,n,r,i){return e+t+n+r+i>>>0}g.sum32_5=ku;function qu(e,t,n,r){var i=e[t],s=e[t+1],o=r+s>>>0,c=(o<r?1:0)+n+i;e[t]=c>>>0,e[t+1]=o}g.sum64=qu;function ju(e,t,n,r){var i=t+r>>>0,s=(i<t?1:0)+e+n;return s>>>0}g.sum64_hi=ju;function Hu(e,t,n,r){var i=t+r;return i>>>0}g.sum64_lo=Hu;function Nu(e,t,n,r,i,s,o,c){var l=0,u=t;u=u+r>>>0,l+=u<t?1:0,u=u+s>>>0,l+=u<s?1:0,u=u+c>>>0,l+=u<c?1:0;var p=e+n+i+o+l;return p>>>0}g.sum64_4_hi=Nu;function Uu(e,t,n,r,i,s,o,c){var l=t+r+s+c;return l>>>0}g.sum64_4_lo=Uu;function Fu(e,t,n,r,i,s,o,c,l,u){var p=0,f=t;f=f+r>>>0,p+=f<t?1:0,f=f+s>>>0,p+=f<s?1:0,f=f+c>>>0,p+=f<c?1:0,f=f+u>>>0,p+=f<u?1:0;var m=e+n+i+o+l+p;return m>>>0}g.sum64_5_hi=Fu;function Vu(e,t,n,r,i,s,o,c,l,u){var p=t+r+s+c+u;return p>>>0}g.sum64_5_lo=Vu;function Bu(e,t,n){var r=t<<32-n|e>>>n;return r>>>0}g.rotr64_hi=Bu;function Qu(e,t,n){var r=e<<32-n|t>>>n;return r>>>0}g.rotr64_lo=Qu;function Wu(e,t,n){return e>>>n}g.shr64_hi=Wu;function Gu(e,t,n){var r=e<<32-n|t>>>n;return r>>>0}g.shr64_lo=Gu});var Ga=d(Wa=>{"use strict";var Qa=Et(),$u=Tt();function bt(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}Wa.BlockHash=bt;bt.prototype.update=function(t,n){if(t=Qa.toArray(t,n),this.pending?this.pending=this.pending.concat(t):this.pending=t,this.pendingTotal+=t.length,this.pending.length>=this._delta8){t=this.pending;var r=t.length%this._delta8;this.pending=t.slice(t.length-r,t.length),this.pending.length===0&&(this.pending=null),t=Qa.join32(t,0,t.length-r,this.endian);for(var i=0;i<t.length;i+=this._delta32)this._update(t,i,i+this._delta32)}return this};bt.prototype.digest=function(t){return this.update(this._pad()),$u(this.pending===null),this._digest(t)};bt.prototype._pad=function(){var t=this.pendingTotal,n=this._delta8,r=n-(t+this.padLength)%n,i=new Array(r+this.padLength);i[0]=128;for(var s=1;s<r;s++)i[s]=0;if(t<<=3,this.endian==="big"){for(var o=8;o<this.padLength;o++)i[s++]=0;i[s++]=0,i[s++]=0,i[s++]=0,i[s++]=0,i[s++]=t>>>24&255,i[s++]=t>>>16&255,i[s++]=t>>>8&255,i[s++]=t&255}else for(i[s++]=t&255,i[s++]=t>>>8&255,i[s++]=t>>>16&255,i[s++]=t>>>24&255,i[s++]=0,i[s++]=0,i[s++]=0,i[s++]=0,o=8;o<this.padLength;o++)i[s++]=0;return i}});var Ya=d(H=>{"use strict";var Ku=Et(),P=Ku.rotr32;function zu(e,t,n,r){if(e===0)return $a(t,n,r);if(e===1||e===3)return za(t,n,r);if(e===2)return Ka(t,n,r)}H.ft_1=zu;function $a(e,t,n){return e&t^~e&n}H.ch32=$a;function Ka(e,t,n){return e&t^e&n^t&n}H.maj32=Ka;function za(e,t,n){return e^t^n}H.p32=za;function Yu(e){return P(e,2)^P(e,13)^P(e,22)}H.s0_256=Yu;function Ju(e){return P(e,6)^P(e,11)^P(e,25)}H.s1_256=Ju;function Xu(e){return P(e,7)^P(e,18)^e>>>3}H.g0_256=Xu;function Zu(e){return P(e,17)^P(e,19)^e>>>10}H.g1_256=Zu});var Za=d((Sm,Xa)=>{"use strict";var de=Et(),ed=Ga(),fe=Ya(),td=Tt(),M=de.sum32,nd=de.sum32_4,rd=de.sum32_5,id=fe.ch32,sd=fe.maj32,ad=fe.s0_256,od=fe.s1_256,cd=fe.g0_256,ld=fe.g1_256,Ja=ed.BlockHash,ud=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function k(){if(!(this instanceof k))return new k;Ja.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=ud,this.W=new Array(64)}de.inherits(k,Ja);Xa.exports=k;k.blockSize=512;k.outSize=256;k.hmacStrength=192;k.padLength=64;k.prototype._update=function(t,n){for(var r=this.W,i=0;i<16;i++)r[i]=t[n+i];for(;i<r.length;i++)r[i]=nd(ld(r[i-2]),r[i-7],cd(r[i-15]),r[i-16]);var s=this.h[0],o=this.h[1],c=this.h[2],l=this.h[3],u=this.h[4],p=this.h[5],f=this.h[6],m=this.h[7];for(td(this.k.length===r.length),i=0;i<r.length;i++){var A=rd(m,od(u),id(u,p,f),this.k[i],r[i]),q=M(ad(s),sd(s,o,c));m=f,f=p,p=u,u=M(l,A),l=c,c=o,o=s,s=M(A,q)}this.h[0]=M(this.h[0],s),this.h[1]=M(this.h[1],o),this.h[2]=M(this.h[2],c),this.h[3]=M(this.h[3],l),this.h[4]=M(this.h[4],u),this.h[5]=M(this.h[5],p),this.h[6]=M(this.h[6],f),this.h[7]=M(this.h[7],m)};k.prototype._digest=function(t){return t==="hex"?de.toHex32(this.h,"big"):de.split32(this.h,"big")}});var eo=d(qn=>{"use strict";Object.defineProperty(qn,"__esModule",{value:!0});var fd=function(){function e(){var t=this;this.locked=new Map,this.addToLocked=function(n,r){var i=t.locked.get(n);i===void 0?r===void 0?t.locked.set(n,[]):t.locked.set(n,[r]):r!==void 0&&(i.unshift(r),t.locked.set(n,i))},this.isLocked=function(n){return t.locked.has(n)},this.lock=function(n){return new Promise(function(r,i){t.isLocked(n)?t.addToLocked(n,r):(t.addToLocked(n),r())})},this.unlock=function(n){var r=t.locked.get(n);if(r===void 0||r.length===0){t.locked.delete(n);return}var i=r.pop();t.locked.set(n,r),i!==void 0&&setTimeout(i,0)}}return e.getInstance=function(){return e.instance===void 0&&(e.instance=new e),e.instance},e}();function pd(){return fd.getInstance()}qn.default=pd});var Un=d(ee=>{"use strict";var pe=ee&&ee.__awaiter||function(e,t,n,r){return new(n||(n=Promise))(function(i,s){function o(u){try{l(r.next(u))}catch(p){s(p)}}function c(u){try{l(r.throw(u))}catch(p){s(p)}}function l(u){u.done?i(u.value):new n(function(p){p(u.value)}).then(o,c)}l((r=r.apply(e,t||[])).next())})},me=ee&&ee.__generator||function(e,t){var n={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},r,i,s,o;return o={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function c(u){return function(p){return l([u,p])}}function l(u){if(r)throw new TypeError("Generator is already executing.");for(;n;)try{if(r=1,i&&(s=u[0]&2?i.return:u[0]?i.throw||((s=i.return)&&s.call(i),0):i.next)&&!(s=s.call(i,u[1])).done)return s;switch(i=0,s&&(u=[u[0]&2,s.value]),u[0]){case 0:case 1:s=u;break;case 4:return n.label++,{value:u[1],done:!1};case 5:n.label++,i=u[1],u=[0];continue;case 7:u=n.ops.pop(),n.trys.pop();continue;default:if(s=n.trys,!(s=s.length>0&&s[s.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!s||u[1]>s[0]&&u[1]<s[3])){n.label=u[1];break}if(u[0]===6&&n.label<s[1]){n.label=s[1],s=u;break}if(s&&n.label<s[2]){n.label=s[2],n.ops.push(u);break}s[2]&&n.ops.pop(),n.trys.pop();continue}u=t.call(e,n)}catch(p){u=[6,p],i=0}finally{r=s=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}};Object.defineProperty(ee,"__esModule",{value:!0});var ye=eo(),jn="browser-tabs-lock-key";function Hn(e){return new Promise(function(t){return setTimeout(t,e)})}function Nn(e){for(var t="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz",n="",r=0;r<e;r++){var i=Math.floor(Math.random()*t.length);n+=t[i]}return n}function md(){return Date.now().toString()+Nn(15)}var yd=function(){function e(){this.acquiredIatSet=new Set,this.id=md(),this.acquireLock=this.acquireLock.bind(this),this.releaseLock=this.releaseLock.bind(this),this.releaseLock__private__=this.releaseLock__private__.bind(this),this.waitForSomethingToChange=this.waitForSomethingToChange.bind(this),this.refreshLockWhileAcquired=this.refreshLockWhileAcquired.bind(this),e.waiters===void 0&&(e.waiters=[])}return e.prototype.acquireLock=function(t,n){return n===void 0&&(n=5e3),pe(this,void 0,void 0,function(){var r,i,s,o,c,l,u;return me(this,function(p){switch(p.label){case 0:r=Date.now()+Nn(4),i=Date.now()+n,s=jn+"-"+t,o=window.localStorage,p.label=1;case 1:return Date.now()<i?[4,Hn(30)]:[3,8];case 2:return p.sent(),c=o.getItem(s),c!==null?[3,5]:(l=this.id+"-"+t+"-"+r,[4,Hn(Math.floor(Math.random()*25))]);case 3:return p.sent(),o.setItem(s,JSON.stringify({id:this.id,iat:r,timeoutKey:l,timeAcquired:Date.now(),timeRefreshed:Date.now()})),[4,Hn(30)];case 4:return p.sent(),u=o.getItem(s),u!==null&&(u=JSON.parse(u),u.id===this.id&&u.iat===r)?(this.acquiredIatSet.add(r),this.refreshLockWhileAcquired(s,r),[2,!0]):[3,7];case 5:return e.lockCorrector(),[4,this.waitForSomethingToChange(i)];case 6:p.sent(),p.label=7;case 7:return r=Date.now()+Nn(4),[3,1];case 8:return[2,!1]}})})},e.prototype.refreshLockWhileAcquired=function(t,n){return pe(this,void 0,void 0,function(){var r=this;return me(this,function(i){return setTimeout(function(){return pe(r,void 0,void 0,function(){var s,o;return me(this,function(c){switch(c.label){case 0:return[4,ye.default().lock(n)];case 1:if(c.sent(),!this.acquiredIatSet.has(n))return ye.default().unlock(n),[2];if(s=window.localStorage,o=s.getItem(t),o!==null)o=JSON.parse(o),o.timeRefreshed=Date.now(),s.setItem(t,JSON.stringify(o)),ye.default().unlock(n);else return ye.default().unlock(n),[2];return this.refreshLockWhileAcquired(t,n),[2]}})})},1e3),[2]})})},e.prototype.waitForSomethingToChange=function(t){return pe(this,void 0,void 0,function(){return me(this,function(n){switch(n.label){case 0:return[4,new Promise(function(r){var i=!1,s=Date.now(),o=50,c=!1;function l(){if(c||(window.removeEventListener("storage",l),e.removeFromWaiting(l),clearTimeout(u),c=!0),!i){i=!0;var p=o-(Date.now()-s);p>0?setTimeout(r,p):r()}}window.addEventListener("storage",l),e.addToWaiting(l);var u=setTimeout(l,Math.max(0,t-Date.now()))})];case 1:return n.sent(),[2]}})})},e.addToWaiting=function(t){this.removeFromWaiting(t),e.waiters!==void 0&&e.waiters.push(t)},e.removeFromWaiting=function(t){e.waiters!==void 0&&(e.waiters=e.waiters.filter(function(n){return n!==t}))},e.notifyWaiters=function(){if(e.waiters!==void 0){var t=e.waiters.slice();t.forEach(function(n){return n()})}},e.prototype.releaseLock=function(t){return pe(this,void 0,void 0,function(){return me(this,function(n){switch(n.label){case 0:return[4,this.releaseLock__private__(t)];case 1:return[2,n.sent()]}})})},e.prototype.releaseLock__private__=function(t){return pe(this,void 0,void 0,function(){var n,r,i;return me(this,function(s){switch(s.label){case 0:return n=window.localStorage,r=jn+"-"+t,i=n.getItem(r),i===null?[2]:(i=JSON.parse(i),i.id!==this.id?[3,2]:[4,ye.default().lock(i.iat)]);case 1:s.sent(),this.acquiredIatSet.delete(i.iat),n.removeItem(r),ye.default().unlock(i.iat),e.notifyWaiters(),s.label=2;case 2:return[2]}})})},e.lockCorrector=function(){for(var t=Date.now()-5e3,n=window.localStorage,r=Object.keys(n),i=!1,s=0;s<r.length;s++){var o=r[s];if(o.includes(jn)){var c=n.getItem(o);c!==null&&(c=JSON.parse(c),(c.timeRefreshed===void 0&&c.timeAcquired<t||c.timeRefreshed!==void 0&&c.timeRefreshed<t)&&(n.removeItem(o),i=!0))}}i&&e.notifyWaiters()},e.waiters=void 0,e}();ee.default=yd});var Pg=G(ni()),kg=G(Ti()),qg=G(ma()),jg=G(xa());var yt,Au=new Uint8Array(16);function Cn(){if(!yt&&(yt=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!yt))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return yt(Au)}var b=[];for(let e=0;e<256;++e)b.push((e+256).toString(16).slice(1));function _a(e,t=0){return(b[e[t+0]]+b[e[t+1]]+b[e[t+2]]+b[e[t+3]]+"-"+b[e[t+4]]+b[e[t+5]]+"-"+b[e[t+6]]+b[e[t+7]]+"-"+b[e[t+8]]+b[e[t+9]]+"-"+b[e[t+10]]+b[e[t+11]]+b[e[t+12]]+b[e[t+13]]+b[e[t+14]]+b[e[t+15]]).toLowerCase()}var Tu=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),Rn={randomUUID:Tu};function Eu(e,t,n){if(Rn.randomUUID&&!t&&!e)return Rn.randomUUID();e=e||{};let r=e.random||(e.rng||Cn)();if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){n=n||0;for(let i=0;i<16;++i)t[n+i]=r[i];return t}return _a(r)}var De=Eu;var a;(c=>{let e;(y=>(y.Blog="Blog",y.Custom="Custom",y.CustomEvent="CustomEvent",y.Document="Document",y.Form="Form",y.ObjectEntry="ObjectEntry",y.Page="Page",y.WebContent="WebContent"))(e=c.ApplicationId||(c.ApplicationId={}));let t;(h=>(h.AssetClicked="assetClicked",h.AssetDepthReached="assetDepthReached",h.AssetDownloaded="assetDownloaded",h.AssetSubmitted="assetSubmitted",h.AssetViewed="assetViewed",h.BlogClicked="blogClicked",h.BlogDepthReached="blogDepthReached",h.BlogImpressionMade="blogImpressionMade",h.BlogViewed="blogViewed",h.DocumentDownloaded="documentDownloaded",h.DocumentImpressionMade="documentImpressionMade",h.DocumentPreviewed="documentPreviewed",h.FieldBlurred="fieldBlurred",h.FieldFocused="fieldFocused",h.FormSubmitted="formSubmitted",h.FormViewed="formViewed",h.ObjectEntryDownloaded="objectEntryDownloaded",h.ObjectEntryImpressionMade="objectEntryImpressionMade",h.ObjectEntryViewed="objectEntryViewed",h.PageDepthReached="pageDepthReached",h.PageLoaded="pageLoaded",h.PageRead="pageRead",h.PageUnloaded="pageUnloaded",h.PageViewed="pageViewed",h.TabBlurred="tabBlurred",h.TabFocused="tabFocused",h.WebContentClicked="webContentClicked",h.WebContentImpressionMade="webContentImpressionMade",h.WebContentViewed="webContentViewed"))(t=c.EventId||(c.EventId={}));let n;(f=>(f.View="view",f.Impression="impression",f.Download="download"))(n=c.ElementAction||(c.ElementAction={}));let r;(y=>(y.Blog="blog",y.BlogsEntry="com.liferay.blogs.model.BlogsEntry",y.Custom="custom",y.Document="document",y.FileEntry="com.liferay.portal.kernel.repository.model.FileEntry",y.JournalArticle="com.liferay.journal.model.JournalArticle",y.ObjectEntry="object-entry",y.WebContent="web-content"))(r=c.ElementType||(c.ElementType={}));let i;(_=>(_.AnalyticsAssetMimeType="analyticsAssetMimeType",_.AnalyticsAssetAction="analyticsAssetAction",_.AnalyticsAssetCategories="analyticsAssetCategories",_.AnalyticsAssetCategory="analyticsAssetCategory",_.AnalyticsAssetId="analyticsAssetId",_.AnalyticsAssetSubtype="analyticsAssetSubtype",_.AnalyticsAssetTags="analyticsAssetTags",_.AnalyticsAssetTitle="analyticsAssetTitle",_.AnalyticsAssetType="analyticsAssetType",_.AnalyticsAssetVersion="analyticsAssetVersion",_.AnalyticsAssetVocabularies="analyticsAssetVocabularies",_.AnalyticsExternalReferenceCode="analyticsExternalReferenceCode",_.AnalyticsObjectDefinitionName="analyticsObjectDefinitionName",_.AnalyticsObjectType="analyticsObjectType",_.AnalyticsWebContentResourcePk="analyticsWebContentResourcePk"))(i=c.DataSetList||(c.DataSetList={}));let s;(y=>(y.ChannelId="ac_client_channel_id",y.Contexts="ac_client_context",y.DemandbaseAccount="ac_client_demandbase_account",y.DisableTracking="ac_client_disable_tracking",y.Identity="ac_client_identity",y.PrevEmailAddressHash="ac_client_previous_email_address_hash",y.StorageVersion="ac_client_storage_version",y.UserId="ac_client_user_id"))(s=c.Keys||(c.Keys={}));let o;(m=>(m.AccountMessage="ac_message_queue_account",m.Events="ac_client_batch",m.IdentityMessage="ac_message_queue_identity",m.Messages="ac_message_queue"))(o=c.Queues||(c.Queues={}))})(a||(a={}));var Sa="1.3.4",ht="analyticsBatchSegmentExternalReferenceCodes";var gt="OSB-Asah-Project-ID";var Pe="loadEventStartSPA",X="navigationStartSPA",La="pageLoadTimeSPA",vt="viewDurationSPA",wn="p_p_id",Ca="com_liferay_portlet_configuration_web_portlet_PortletConfigurationPortlet",Ra="p_l_mode",wa="com_liferay_layout_content_page_editor_web_internal_portlet_ContentPageEditorPortlet",On="view";var Oa=new Set(["ja","ko","zh"]),At=75,Mn=.75,Ma=265,Da=108e5,Pa=2048,ka=25,qa=255,ja=1024;var Pn=G(Za());function kn(e){return typeof e!="object"||e===null?e:Array.isArray(e)?e.map(kn).sort():Object.keys(e).sort().reduce((t,n)=>(t[n]=kn(e[n]),t),{})}function dd(e){if(typeof e=="object"){let t=JSON.stringify(kn(e));return(0,Pn.default)().update(t).digest("hex")}return(0,Pn.default)().update(e).digest("hex")}var Z=dd;var to=G(Un()),Fn=()=>{let e=window.Liferay,t=e?.Util?.LocalStorage,n=e?.Util?.Cookie?.get?.("CONSENT_TYPE_PERFORMANCE");return t&&n==="true"},E=e=>{let t=window.Liferay,n;try{let r;Fn()?r=t?.Util?.LocalStorage?.getItem(e,t?.Util?.LocalStorage?.TYPES?.PERFORMANCE):r=localStorage.getItem(e),n=JSON.parse(r)}catch{return}return n},T=(e,t)=>{let n=window.Liferay;try{Fn()?n?.Util?.LocalStorage?.setItem(e,JSON.stringify(t),n?.Util?.LocalStorage?.TYPES?.PERFORMANCE):localStorage.setItem(e,JSON.stringify(t))}catch{return}},It=e=>{let t=window.Liferay;try{Fn()?t?.Util?.LocalStorage?.removeItem(e,t?.Util?.LocalStorage?.TYPES?.PERFORMANCE):localStorage.removeItem(e)}catch{return}},hd=e=>Number(JSON.stringify(e).length*2/1024),no=(e,t)=>{let n=E(e);if(!n?.length)return Promise.resolve();let r=new to.default;return r.acquireLock(e).then(i=>{if(i)return hd(n)>t&&T(e,n.slice(1)),r.releaseLock(e)})};var xt=class{constructor(t){this.analyticsInstance=t}waitForReadiness(t=5e3){try{let n=window.Demandbase?.IpApi?.CompanyProfile;if(n)return Promise.resolve(n)}catch{return Promise.resolve(null)}return new Promise(n=>{let r={},i=!1,s=o=>{i||(i=!0,r.pollId&&clearInterval(r.pollId),r.timeoutId&&clearTimeout(r.timeoutId),n(o))};try{window.Demandbase?.Utilities?.Callbacks?.registerCallback?.(()=>{try{s(window.Demandbase?.IpApi?.CompanyProfile??null)}catch{s(null)}})}catch{}r.pollId=setInterval(()=>{try{let o=window.Demandbase?.IpApi?.CompanyProfile;o&&s(o)}catch{s(null)}},500),r.timeoutId=setTimeout(()=>s(null),t)})}sendAccountMessage(t){this.waitForReadiness().then(n=>{if(this.analyticsInstance._disposed)return;if(!n){It(a.Keys.DemandbaseAccount),this.analyticsInstance[a.Queues.AccountMessage].reset();return}let{emailAddressHashed:r}=this.analyticsInstance.config.identity,i=Z({emailAddressHashed:r,userId:t,webSite:n.web_site}),s=E(a.Keys.DemandbaseAccount);i!==s&&(T(a.Keys.DemandbaseAccount,i),this.analyticsInstance[a.Queues.AccountMessage].addItem({...n,emailAddressHashed:r,id:i,userId:t}))})}};function ro(e=new Date){return new Date(e.getTime()-e.getTimezoneOffset()*60*1e3)}function io(e=new Date){let t=e.getTimezoneOffset()/60,n=t>0?"-":"+",r=Math.abs(t%1),i=`${n}${("00"+Math.abs(~~t)).slice(-2)}`;return r?`${i}:${60*r}`:`${i}:00`}function ke(e,t){return(document.querySelector(e)||{})[t]||""}function Ad(e){return Object.assign(e.context,{canonicalUrl:ke("link[rel=canonical]","href"),contentLanguageId:ke("html","lang"),description:ke('meta[name="description"]',"content"),keywords:ke('meta[name="keywords"]',"content"),languageId:navigator.language,referrer:document.referrer,timezoneOffset:io(),title:ke("title","textContent"),url:location.href,userAgent:navigator.userAgent}),e}var so=Ad;var Td=[/^og:.*/,/^music:/,/^video:/,/^article:/,/^book:/,/^profile:/,/^fb:/];function Ed(e){let t=!1;if(e&&e.getAttribute){let n=e.getAttribute("property");n&&(t=Td.some(r=>n.match(r)))}return t}function bd(e){let r=[].slice.call(document.querySelectorAll("meta")).filter(Ed).reduce((i,s)=>Object.assign(i,{[s.getAttribute("property")]:s.getAttribute("content")}),{});return Object.assign(e.context,r),e}var ao=bd;function Id(e){let t=window.devicePixelRatio||1,n=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight,r=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth;return Object.assign(e.context,{devicePixelRatio:t,screenHeight:n,screenWidth:r}),e}var oo=Id;var Vn=[so,ao,oo];function N(e,t=""){return typeof e=="object"?e.map(n=>`[data-analytics-asset-type="${n}"]${t}`).join(", "):`[data-analytics-asset-type="${e}"]${t}`}function te(e,t){return qe(e,N(t))}function qe(e,t){if(e.closest)return e.closest(t);if(!document.documentElement.contains(e))return null;do{if(e.matches(t))return e;e=e.parentElement||e.parentNode}while(e!==null&&e.nodeType===1);return null}function he({innerText:e}){let t=e.split(/\s+/).filter(Boolean);return e!==""?t.length:0}function v(e,t){let n=[a.DataSetList.AnalyticsAssetId,a.DataSetList.AnalyticsAssetTitle,a.DataSetList.AnalyticsAssetType];return!!(e&&(t||n).every(i=>i in e.dataset))}Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector);function R(e,t){return function n(){let r=arguments;xd(n),n.id=setTimeout(()=>{e.apply(null,r)},t)}}function xd(e){clearTimeout(e.id)}var x=e=>(document.readyState==="interactive"||document.readyState==="complete"?e():document.addEventListener("DOMContentLoaded",e),()=>document.removeEventListener("DOMContentLoaded",e)),_t=(e,t)=>(e.forEach(n=>document.addEventListener(n,t)),()=>{e.forEach(n=>{document.removeEventListener(n,t)})}),ge=({analytics:e,applicationId:t,eventType:n,getPayload:r,isTrackable:i,type:s})=>{let o=c=>{let l=c.target,u=te(l,s);if(!i(u)||l.control)return;let p=l.tagName.toLowerCase(),f=u?r(u):{};Object.assign(f,{tagName:p}),p==="a"?Object.assign(f,{href:l.href,text:l.innerText}):p==="img"&&Object.assign(f,{src:l.src}),e.send(n,t,f)};return document.addEventListener("click",o),()=>document.removeEventListener("click",o)};function co(e,t,n,r){let i=new Date,s=i.toISOString(),o=ro(i).toISOString();return{applicationId:t,contextHash:r,eventDate:s,eventId:e,eventLocalDate:o,properties:n}}var lo=(e,t)=>{let n=e.flatMap(({value:r})=>r.events);return t.filter(({contextHash:r,eventDate:i,eventId:s})=>!n.some(({contextHash:o,eventDate:c,eventId:l})=>r===o&&s===l&&i===c))};function _d(){return window.pageYOffset||document.documentElement.scrollTop}function Sd(){let e=[document.body.clientHeight,document.documentElement.clientHeight,document.documentElement.scrollHeight];return Math.max.apply(null,e)}function Ld(e){let t=Sd(),n=_d(),r={bottom:0,height:t,top:n};if(e){let i=e.getBoundingClientRect(),{bottom:s,height:o,top:c}=i;r={bottom:s,height:o,top:c}}return r}function St(e){let{bottom:t,left:n,right:r,top:i}=e.getBoundingClientRect(),s=window.innerHeight||document.documentElement.clientHeight,o=window.innerWidth||document.documentElement.clientWidth,c=i<=s&&t>=0,l=n<=o&&r>=0;return c&&l}var w=class{constructor(t=4){this.steps=t,this.stepsReached=[]}dispose(){this.steps=null,this.stepsReached=null}getDepthValue(t){let{bottom:n,height:r,top:i}=Ld(t),s=window.innerHeight,o=(s-i)/r;return i<=0&&n>=0?o=s/(r+i):t||(o=(i+s)/r),o}getDepth(t){let n=this.getDepthValue(t),r=Math.round(n*100);return Math.min(Math.max(r,0),100)}onDepthReached(t,n){let r=this.getDepth(n),i=Math.floor(100/this.steps),s=Math.floor(r/i);this.stepsReached?.every(o=>o<s)&&(this.stepsReached.push(s),s>0&&t(s*i))}};function Bn({dataset:e}){let t={entryId:e.analyticsAssetId.trim()};return e.analyticsAssetCategories&&Object.assign(t,{assetCategories:e.analyticsAssetCategories.trim()}),e.analyticsAssetMimeType&&Object.assign(t,{mimeType:e.analyticsAssetMimeType.trim()}),e.analyticsAssetSubtype&&Object.assign(t,{subtype:e.analyticsAssetSubtype.trim()}),e.analyticsAssetTags&&Object.assign(t,{assetTags:e.analyticsAssetTags.trim()}),e.analyticsAssetTitle&&Object.assign(t,{title:e.analyticsAssetTitle.trim()}),e.analyticsAssetType&&Object.assign(t,{type:e.analyticsAssetType.trim()}),e.analyticsAssetVocabularies&&Object.assign(t,{assetVocabularies:e.analyticsAssetVocabularies.trim()}),e.analyticsExternalReferenceCode&&Object.assign(t,{externalReferenceCode:e.analyticsExternalReferenceCode.trim()}),t}function Cd(e,t){let n=new Date().toISOString(),r=new w,i=R(()=>{t.forEach(s=>{r.onDepthReached(o=>{let c=Bn(s);Object.assign(c,{depth:o,sessionId:n}),e.send(a.EventId.BlogDepthReached,a.ApplicationId.Blog,c)},s)})},1500);return document.addEventListener("scroll",i),()=>{document.removeEventListener("scroll",i)}}function uo(e,{eventId:t,isTrackable:n}){let r=[],i=N([a.ElementType.Blog,a.ElementType.BlogsEntry]),s=x(()=>{Array.prototype.slice.call(document.querySelectorAll(i)).filter(n).forEach(c=>{let l=Bn(c);Object.assign(l,{numberOfWords:he(c)}),r.push(c),e.send(t,a.ApplicationId.Blog,l)})}),o=Cd(e,r);return()=>{o(),s()}}function Rd(e){return ge({analytics:e,applicationId:a.ApplicationId.Blog,eventType:a.EventId.BlogClicked,getPayload:Bn,isTrackable:v,type:a.ElementType.Blog})}function wd(e){let t=Rd(e),n=uo(e,{eventId:a.EventId.BlogImpressionMade,isTrackable:i=>v(i)&&i.dataset?.analyticsAssetAction===a.ElementAction.Impression}),r=uo(e,{eventId:a.EventId.BlogViewed,isTrackable:i=>v(i)&&(!i.dataset?.analyticsAssetAction||i.dataset?.analyticsAssetAction===a.ElementAction.View)});return()=>{t(),n(),r()}}var fo=wd;function je({dataset:e}){let t={assetId:e.analyticsAssetId.trim()};return e.analyticsAssetCategory&&Object.assign(t,{category:e.analyticsAssetCategory.trim()}),e.analyticsAssetCategories&&Object.assign(t,{assetCategories:e.analyticsAssetCategories.trim()}),e.analyticsAssetMimeType&&Object.assign(t,{mimeType:e.analyticsAssetMimeType.trim()}),e.analyticsAssetTags&&Object.assign(t,{assetTags:e.analyticsAssetTags.trim()}),e.analyticsAssetTitle&&Object.assign(t,{title:e.analyticsAssetTitle.trim()}),e.analyticsAssetVocabularies&&Object.assign(t,{assetVocabularies:e.analyticsAssetVocabularies.trim()}),t}function Od(e){let t=n=>{let r=n.target,i=qe(r,'[data-analytics-asset-action="download"]'),s=te(r,a.ElementType.Custom);i&&v(s,[a.DataSetList.AnalyticsAssetId,a.DataSetList.AnalyticsAssetType])&&e.send(a.EventId.AssetDownloaded,a.ApplicationId.Custom,je(s))};return document.addEventListener("click",t),()=>document.removeEventListener("click",t)}function Md(e,t){let n=new Date().toISOString(),r=new w,i=R(()=>{t.forEach(s=>{r.onDepthReached(o=>{let c=je(s);Object.assign(c,{depth:o,sessionId:n}),e.send(a.EventId.AssetDepthReached,a.ApplicationId.Custom,c)},s)})},1500);return document.addEventListener("scroll",i),()=>{document.removeEventListener("scroll",i)}}function Dd(e){let t=n=>{let r=n.target,i=te(r,a.ElementType.Custom),s=v(i,[a.DataSetList.AnalyticsAssetId,a.DataSetList.AnalyticsAssetType]);!s||s&&(r.tagName!=="FORM"||n.defaultPrevented)||e.send(a.EventId.AssetSubmitted,a.ApplicationId.Custom,je(i))};return document.addEventListener("submit",t),()=>document.removeEventListener("submit",t)}function Pd(e){let t=[],n=x(()=>{Array.prototype.slice.call(document.querySelectorAll('[data-analytics-asset-type="custom"]')).filter(i=>v(i,[a.DataSetList.AnalyticsAssetId,a.DataSetList.AnalyticsAssetType])).forEach(i=>{let s=!!i.getElementsByTagName("form").length,o=je(i);Object.assign(o,{formEnabled:s}),t.push(i),e.send(a.EventId.AssetViewed,a.ApplicationId.Custom,o)})}),r=Md(e,t);return()=>{r(),n()}}function kd(e){return ge({analytics:e,applicationId:a.ApplicationId.Custom,eventType:a.EventId.AssetClicked,getPayload:je,isTrackable:t=>v(t,[a.DataSetList.AnalyticsAssetId,a.DataSetList.AnalyticsAssetType]),type:a.ElementType.Custom})}function qd(e){let t=kd(e),n=Od(e),r=Dd(e),i=Pd(e);return()=>{t(),n(),r(),i()}}var po=qd;function mo({dataset:e}){let t={fileEntryId:e.analyticsAssetId.trim()};return e.analyticsAssetCategories&&Object.assign(t,{assetCategories:e.analyticsAssetCategories.trim()}),e.analyticsAssetMimeType&&Object.assign(t,{mimeType:e.analyticsAssetMimeType.trim()}),e.analyticsAssetTags&&Object.assign(t,{assetTags:e.analyticsAssetTags.trim()}),e.analyticsAssetTitle&&Object.assign(t,{title:e.analyticsAssetTitle.trim()}),e.analyticsAssetVersion&&Object.assign(t,{fileEntryVersion:e.analyticsAssetVersion.trim()}),e.analyticsAssetVocabularies&&Object.assign(t,{assetVocabularies:e.analyticsAssetVocabularies.trim()}),e.analyticsExternalReferenceCode&&Object.assign(t,{externalReferenceCode:e.analyticsExternalReferenceCode.trim()}),t}function jd(e){let t=n=>{let r=n.target,i=qe(r,'[data-analytics-asset-action="download"]'),s=te(r,a.ElementType.Document);i&&v(s)&&e.send(a.EventId.DocumentDownloaded,a.ApplicationId.Document,mo(s))};return document.addEventListener("click",t),()=>document.removeEventListener("click",t)}function Hd(e){let t=x(()=>{Array.prototype.slice.call(document.querySelectorAll('[data-analytics-asset-action="preview"]')).filter(n=>v(n)).forEach(n=>{let r=mo(n);e.send(a.EventId.DocumentPreviewed,a.ApplicationId.Document,r)})});return()=>t()}function Nd(e){let t=jd(e),n=Hd(e);return()=>{t(),n()}}var yo=Nd;function ho({dataset:e}){let t={fileEntryId:e.analyticsAssetId.trim()};return e.analyticsAssetCategories&&Object.assign(t,{assetCategories:e.analyticsAssetCategories.trim()}),e.analyticsAssetMimeType&&Object.assign(t,{mimeType:e.analyticsAssetMimeType.trim()}),e.analyticsAssetSubtype&&Object.assign(t,{subtype:e.analyticsAssetSubtype.trim()}),e.analyticsAssetTags&&Object.assign(t,{assetTags:e.analyticsAssetTags.trim()}),e.analyticsAssetTitle&&Object.assign(t,{title:e.analyticsAssetTitle.trim()}),e.analyticsAssetType&&Object.assign(t,{type:e.analyticsAssetType.trim()}),e.analyticsAssetVersion&&Object.assign(t,{fileEntryVersion:e.analyticsAssetVersion.trim()}),e.analyticsAssetVocabularies&&Object.assign(t,{assetVocabularies:e.analyticsAssetVocabularies.trim()}),e.analyticsExternalReferenceCode&&Object.assign(t,{externalReferenceCode:e.analyticsExternalReferenceCode.trim()}),t}function Ud(e){let t=n=>{let r=n.target,i=r.parentElement,s=[r,i].find(o=>o?.dataset.analyticsAssetAction==="download");s&&v(s)&&e.send(a.EventId.DocumentDownloaded,a.ApplicationId.Document,ho(s))};return document.addEventListener("click",t),()=>document.removeEventListener("click",t)}function Fd(e,{eventId:t,isTrackable:n}){let r=N(a.ElementType.FileEntry),i=x(()=>{Array.prototype.slice.call(document.querySelectorAll(r)).filter(s=>n(s)).forEach(s=>{let o=ho(s);e.send(t,a.ApplicationId.Document,o)})});return()=>i()}function Vd(e){let t=Ud(e),n=Fd(e,{eventId:a.EventId.DocumentImpressionMade,isTrackable:r=>v(r)&&r.dataset.analyticsAssetAction===a.ElementAction.Impression||v(r)&&r.dataset.analyticsAssetAction===a.ElementAction.Download});return()=>{t(),n()}}var go=Vd;function vo(){if(window.URLSearchParams)return new window.URLSearchParams(location.search);let e=new Map;return(location.search.startsWith("?")?location.search.slice(1):location.search).split("&").forEach(r=>{if(!r)return;let[i,s]=r.includes("=")?r.split("=").map(decodeURIComponent):[r,""];e.set(i,s)}),{get:r=>e.get(r)}}function He(e,t,n){window.performance.measure(e,t,n);let r=window.performance.getEntriesByName(e).pop();return r&&typeof r.duration=="number"?~~r.duration:0}function Lt(e){window.performance.clearMarks(e),window.performance.mark(e)}function Bd(e){let t=window.Liferay;function n(){e.send(a.EventId.PageUnloaded,a.ApplicationId.Page,{externalReferenceCode:e._getContext().layoutExternalReferenceCode,viewDuration:He(vt,X)})}function r(){e.send(a.EventId.PageLoaded,a.ApplicationId.Page,{externalReferenceCode:e._getContext().layoutExternalReferenceCode,pageLoadTime:He(La,Pe,X)})}function i(c){return c.get(wn)===Ca}function s(c){return c.get(wn)===wa}function o(c){return(c.get(Ra)||On)===On}if(t){let c=vo();if(i(c)||s(c)||!o(c))return e._disposeInternal();if(t.SPA){let l=window.performance.getEntriesByName(Pe);if(Lt(X),!l.length){let u=Lt.bind(null,Pe);Lt(Pe),t?.on?.("beforeNavigate",u)}document.readyState==="complete"&&r(),t?.once?.("beforeNavigate",n)}}}var Ao=Bd;function To(e){return e.dataset.analyticsAssetId||e.id||e.getAttribute("name")||e.action}function Eo({form:e,name:t}){return{fieldName:t,...Qn(e)}}function Qn(e){let t={formId:To(e).trim()};return e.dataset.analyticsAssetCategories&&Object.assign(t,{assetCategories:e.dataset.analyticsAssetCategories.trim()}),e.dataset.analyticsAssetMimeType&&Object.assign(t,{mimeType:e.dataset.analyticsAssetMimeType.trim()}),e.dataset.analyticsAssetTags&&Object.assign(t,{assetTags:e.dataset.analyticsAssetTags.trim()}),e.dataset.analyticsAssetTitle&&Object.assign(t,{title:e.dataset.analyticsAssetTitle.trim()}),e.dataset.analyticsAssetVocabularies&&Object.assign(t,{assetVocabularies:e.dataset.analyticsAssetVocabularies.trim()}),e.dataset.analyticsExternalReferenceCode&&Object.assign(t,{externalReferenceCode:e.dataset.analyticsExternalReferenceCode.trim()}),t}function Ne(e){return v(e)&&!!To(e)}function Qd(e){let t=n=>{let r=n.target,{form:i}=r;if(!i||!Ne(i))return;let s=Eo(r),o=`${s.formId}${s.fieldName}blurred`;performance.mark(o);let c=`${s.formId}${s.fieldName}focused`;performance.measure("focusDuration",c,o);let l=performance.getEntriesByName("focusDuration").pop(),u=l&&typeof l.duration=="number"?~~l.duration:0;Object.assign(s,{focusDuration:u}),e.send(a.EventId.FieldBlurred,a.ApplicationId.Form,s),performance.clearMarks("focusDuration")};return document.addEventListener("blur",t,!0),()=>document.removeEventListener("blur",t,!0)}function Wd(e){let t=n=>{let r=n.target,{form:i}=r;if(!i||!Ne(i))return;let s=Eo(r),o=`${s.formId}${s.fieldName}focused`;performance.mark(o),e.send(a.EventId.FieldFocused,a.ApplicationId.Form,s)};return document.addEventListener("focus",t,!0),()=>document.removeEventListener("focus",t,!0)}function Gd(e){let t=n=>{let r=n.target;!Ne(r)||Ne(r)&&n.defaultPrevented||e.send(a.EventId.FormSubmitted,a.ApplicationId.Form,Qn(r))};return document.addEventListener("submit",t,!0),()=>document.removeEventListener("submit",t,!0)}function $d(e){return x(()=>{Array.prototype.slice.call(document.querySelectorAll("form")).filter(t=>Ne(t)).forEach(t=>{let n=Qn(t);e.send(a.EventId.FormViewed,a.ApplicationId.Form,n)})})}function Kd(e){let t=Qd(e),n=Wd(e),r=Gd(e),i=$d(e);return()=>{t(),n(),r(),i()}}var bo=Kd;var Wn=[a.DataSetList.AnalyticsAssetAction,a.DataSetList.AnalyticsAssetType,a.DataSetList.AnalyticsExternalReferenceCode,a.DataSetList.AnalyticsObjectDefinitionName];function xo({dataset:e}){let t={externalReferenceCode:e.analyticsExternalReferenceCode.trim(),objectDefinitionName:e.analyticsObjectDefinitionName.trim()};return e.analyticsAssetCategories&&Object.assign(t,{assetCategories:e.analyticsAssetCategories.trim()}),e.analyticsAssetMimeType&&Object.assign(t,{mimeType:e.analyticsAssetMimeType.trim()}),e.analyticsAssetTags&&Object.assign(t,{assetTags:e.analyticsAssetTags.trim()}),e.analyticsAssetTitle&&Object.assign(t,{title:e.analyticsAssetTitle.trim()}),e.analyticsAssetVocabularies&&Object.assign(t,{assetVocabularies:e.analyticsAssetVocabularies.trim()}),e.analyticsObjectType&&Object.assign(t,{objectType:e.analyticsObjectType.trim()}),t}function zd(e){let t=n=>{let r=n.target;v(r,Wn)&&r.dataset.analyticsAssetAction==="download"&&e.send(a.EventId.ObjectEntryDownloaded,a.ApplicationId.ObjectEntry,xo(r))};return document.addEventListener("click",t),()=>document.removeEventListener("click",t)}function Io(e,{eventId:t,isTrackable:n}){let r=N(a.ElementType.ObjectEntry,':not([data-analytics-asset-viewed="true"])'),i=R(()=>{Array.prototype.slice.call(document.querySelectorAll(r)).filter(n).forEach(l=>{if(St(l)){let u=xo(l);l.dataset.analyticsAssetViewed=!0,e.send(t,a.ApplicationId.ObjectEntry,u)}})},250),s=x(i),o=_t(["scroll","resize"],i);return()=>{o(),s()}}function Yd(e){let t=zd(e),n=Io(e,{eventId:a.EventId.ObjectEntryImpressionMade,isTrackable:i=>v(i,Wn)&&i.dataset?.analyticsAssetAction===a.ElementAction.Impression}),r=Io(e,{eventId:a.EventId.ObjectEntryViewed,isTrackable:i=>v(i,Wn)&&(!i.dataset?.analyticsAssetAction||i.dataset?.analyticsAssetAction===a.ElementAction.View)});return()=>{t(),n(),r()}}var _o=Yd;function So(){let{clientHeight:e,scrollHeight:t}=document.documentElement;return e*100/t<=At}var Ct=class{constructor(){this.timeReached=!1,this.depthReached=!So()}dispose(){this.timeReached=!1,this.depthReached=!So(),this.timeoutId&&clearTimeout(this.timeoutId)}setExpectedViewDuration(t,n){n&&!this.timeoutId&&(this.timeoutId=setTimeout(()=>this.onTimeReached(t),~~n))}onDepthReached(t){this.depthReached||(this.depthReached=!0,this.checkIsRead(t))}onTimeReached(t){this.timeReached=!0,this.checkIsRead(t)}checkIsRead(t){this.timeReached&&this.depthReached&&t()}};var Lo=6e4;function Xd(){let e=document.getElementById("main-content"),t=document.querySelector("meta[name='data-analytics-readable-content']");return t&&t.getAttribute("content")==="true"&&e?e.innerText:""}function Zd(){return document.documentElement.lang}function ef(e){return e.replace(/\s+/gm,"").length/500*Lo*Mn}function tf(e){return he({innerText:e})/Ma*Lo*Mn}function nf(e){let t=Zd();return Oa.has(t)?ef(e):tf(e)}function rf(e){let t=new Ct,n=new w,r=x(()=>{let s=Xd();t.setExpectedViewDuration(()=>e.send(a.EventId.PageRead,a.ApplicationId.Page,{externalReferenceCode:e._getContext().layoutExternalReferenceCode}),nf(s))}),i=R(()=>{n.onDepthReached(s=>{s>=At&&t.onDepthReached(()=>{e.send(a.EventId.PageRead,a.ApplicationId.Page,{externalReferenceCode:e._getContext().layoutExternalReferenceCode})})})},1500);return document.addEventListener("scroll",i),()=>{r(),document.removeEventListener("scroll",i),t.dispose(),n=new w}}var Co=rf;function sf(e){let t=new w,n=R(()=>{t.onDepthReached(i=>{e.send(a.EventId.PageDepthReached,a.ApplicationId.Page,{depth:i,externalReferenceCode:e._getContext().layoutExternalReferenceCode})})},1500);document.addEventListener("scroll",n);let r=()=>{t.dispose(),t=new w};return window.addEventListener("load",r),()=>{document.removeEventListener("scroll",n),window.removeEventListener("load",r)}}var Ro=sf;function af(e){let t=window.performance.timing,n=t.loadEventStart-t.navigationStart,r={externalReferenceCode:e._getContext().layoutExternalReferenceCode,pageLoadTime:n};e.send(a.EventId.PageLoaded,a.ApplicationId.Page,r)}function of(e){let n=window.performance.getEntriesByName(X).length?X:"navigationStart",r=He(vt,n),i={externalReferenceCode:e._getContext().layoutExternalReferenceCode,viewDuration:r};e.send(a.EventId.PageUnloaded,a.ApplicationId.Page,i)}function cf(e){let t=af.bind(null,e);window.addEventListener("load",t);let n=of.bind(null,e);return window.addEventListener("unload",n),()=>{window.removeEventListener("load",t),window.removeEventListener("unload",n)}}var wo=cf;var Mo=!0;function Do(){let e,t,n=document;return typeof n.hidden<"u"?(e="hidden",t="visibilitychange"):typeof n.msHidden<"u"?(e="msHidden",t="msvisibilitychange"):typeof n.webkitHidden<"u"&&(e="webkitHidden",t="webkitvisibilitychange"),{hidden:e,visibilityChange:t}}function lf(e){let{hidden:t}=Do();Mo&&(document[t]?e.send(a.EventId.TabBlurred,a.ApplicationId.Page):e.send(a.EventId.TabFocused,a.ApplicationId.Page))}function uf(e){let{visibilityChange:t}=Do();if(t){let n=lf.bind(null,e);return window.addEventListener("beforeunload",Oo),document.addEventListener(t,n),()=>{window.removeEventListener("beforeunload",Oo),document.removeEventListener(t,n)}}}function Oo(){Mo=!1}var Po=uf;function qo({dataset:e}){let t={articleId:e.analyticsAssetId.trim()};return e.analyticsAssetCategories&&Object.assign(t,{assetCategories:e.analyticsAssetCategories.trim()}),e.analyticsAssetMimeType&&Object.assign(t,{mimeType:e.analyticsAssetMimeType.trim()}),e.analyticsAssetSubtype&&Object.assign(t,{subtype:e.analyticsAssetSubtype.trim()}),e.analyticsAssetTags&&Object.assign(t,{assetTags:e.analyticsAssetTags.trim()}),e.analyticsAssetTitle&&Object.assign(t,{title:e.analyticsAssetTitle.trim()}),e.analyticsAssetType&&Object.assign(t,{type:e.analyticsAssetType.trim()}),e.analyticsAssetVocabularies&&Object.assign(t,{assetVocabularies:e.analyticsAssetVocabularies.trim()}),e.analyticsWebContentResourcePk&&Object.assign(t,{webContentResourcePk:e.analyticsWebContentResourcePk.trim()}),e.analyticsExternalReferenceCode&&Object.assign(t,{externalReferenceCode:e.analyticsExternalReferenceCode.trim()}),t}function df(e){return ge({analytics:e,applicationId:a.ApplicationId.WebContent,eventType:a.EventId.WebContentClicked,getPayload:qo,isTrackable:v,type:[a.ElementType.WebContent,a.ElementType.JournalArticle]})}function ko(e,{eventId:t,isTrackable:n}){let r=N([a.ElementType.WebContent,a.ElementType.JournalArticle],':not([data-analytics-asset-viewed="true"])'),i=R(()=>{Array.prototype.slice.call(document.querySelectorAll(r)).filter(n).forEach(l=>{if(St(l)){let u=qo(l);Object.assign(u,{numberOfWords:he(l)}),l.dataset.analyticsAssetViewed=!0,e.send(t,a.ApplicationId.WebContent,u)}})},250),s=x(i),o=_t(["scroll","resize"],i);return()=>{o(),s()}}function ff(e){let t=df(e),n=ko(e,{eventId:a.EventId.WebContentImpressionMade,isTrackable:i=>v(i)&&i.dataset?.analyticsAssetAction===a.ElementAction.Impression}),r=ko(e,{eventId:a.EventId.WebContentViewed,isTrackable:i=>v(i)&&(!i.dataset?.analyticsAssetAction||i.dataset?.analyticsAssetAction===a.ElementAction.View)});return()=>{t(),n(),r()}}var jo=ff;var Ho=[Ao,fo,po,yo,go,bo,_o,Co,Ro,wo,Po,jo];function Gn(e){return e<=1?1:Gn(e-1)+Gn(e-2)}function $n(e,t){return Gn(Math.min(e,t))*1e3}var Kn=class{constructor(t){this.processInterval=null;this.attemptNumber=1,this.initialFlushInterval=t.flushInterval||2e3,this.processing=!1,this.queues=[],this.flushInterval=this.initialFlushInterval,this._startsFlushLoop()}addQueue(t,n={}){this.queues.push(Object.assign(n,{instance:t,name:t.name})),this.queues.sort(this._prioritize)}removeQueue(t){this.queues=this.queues.filter(({name:n})=>t!==n)}_prioritize({priority:t=1},{priority:n=1}){return n-t}_onFlushFail(){this.flushInterval=$n(++this.attemptNumber,7),this._startsFlushLoop()}_onFlushSuccess(){this.attemptNumber=1,this.flushInterval!==this.initialFlushInterval&&(this.flushInterval=this.initialFlushInterval,this._startsFlushLoop())}flush(){this.processing||this.queues.reduce((t,{instance:n})=>t.then(()=>!n.hasItems()||!n.shouldFlush()?Promise.resolve():n.acquireLock().then(r=>{if(!r)return Promise.resolve();this.processing=!0;let i=()=>n.releaseLock().then(()=>{this.processing=!1});return Promise.allSettled(n.onFlush()).then(s=>(this._onFlushSuccess(),n.onFlushSuccess(s),i(),Promise.resolve()))})).catch(()=>(this._onFlushFail(),n.onFlushFail(),Promise.reject())),Promise.resolve()).catch(()=>{})}_startsFlushLoop(){this.processInterval&&clearInterval(this.processInterval),this.processInterval=setInterval(()=>this.flush(),this.flushInterval)}dispose(){this.processInterval&&clearInterval(this.processInterval),this.flushInterval=this.initialFlushInterval,this.queues=[]}};var No=Kn;var Yn=class{constructor({endpointUrl:t,projectId:n,timeout:r}){this.projectId=n,this.timeout=r||5e3,this.url=t}_getRequestParameters(){let t={"Content-Type":"application/json"};return this.projectId&&Object.assign(t,{[gt]:this.projectId}),{cache:"default",credentials:"same-origin",headers:t,method:"POST",mode:"cors"}}_validateResponse(t){let n=t;return t.ok||(n=new Promise((r,i)=>i(t))),n}sendWithTimeout(t){return Promise.race([this.send(t),this._timeout()])}send(t){let n=this._getRequestParameters();return Object.assign(n,{body:JSON.stringify(t)}),fetch(this.url,n).then(this._validateResponse)}_timeout(){return new Promise((t,n)=>setTimeout(n,this.timeout))}};var Uo=Yn;var Fo=G(Un());var Jn=class{constructor({analyticsInstance:t,name:n}){this.maxSize=512,this.name=n,this.lock=new Fo.default,this.analyticsInstance=t,E(this.name)||T(this.name,[]),this.addItem=this.addItem.bind(this)}addItem(t){this._enqueue(t),no(this.name,this.maxSize)}_dequeue(t){let n=this.getItems();T(this.name,n.filter(({id:r,item:i})=>i?i.id!==t:t!==r))}_enqueue(t){let n=this.getItems();n.push(t),T(this.name,n)}getItems(){return E(this.name)||[]}hasItems(){return!!this.getItems().length}acquireLock(){return this.lock.acquireLock(this.name)}releaseLock(){return this.lock.releaseLock(this.name)}reset(){T(this.name,[])}shouldFlush(){return this.analyticsInstance._isTrackingDisabled()?(this.analyticsInstance._disposeInternal(),!1):!0}onFlush(){throw Error("onFlush should be implemented on the new class")}onFlushFail(){}onFlushSuccess(){}};var Rt=Jn;var Xn=class extends Rt{constructor({analyticsInstance:t,flushTo:n,name:r}){super({analyticsInstance:t,name:r}),this.clientAdapter=new Uo({endpointUrl:n,projectId:t.config.projectId})}onFlush(){return this.getItems().map(n=>this.clientAdapter.sendWithTimeout(n).then(()=>{this._dequeue(n.id)}).catch(r=>(r.status===400&&this._dequeue(n.id),Promise.reject(r))))}};var ve=Xn;var Zn=class extends ve{constructor({analyticsInstance:t,name:n=a.Queues.AccountMessage}){super({analyticsInstance:t,flushTo:t.config.demandbaseAccountEndpoint,name:n})}};var Vo=Zn;var er=class extends ve{constructor({analyticsInstance:t,name:n=a.Queues.Messages}){super({analyticsInstance:t,flushTo:t.config.endpointUrl,name:n})}};var Bo=er;function Qo(e){let t=[];return e.forEach((n,r)=>t.push([r,n])),t}var wt=(e=a.Keys.Contexts)=>{let t=E(e),n=new Map;return t&&t.forEach(([r,i])=>n.set(r,i)),n},Fe=(e,t=a.Keys.Contexts)=>{T(t,Qo(e))};var tr=class extends Rt{constructor({analyticsInstance:t,flushTo:n,name:r}){super({analyticsInstance:t,name:r}),this.analyticsInstance=t,this.flushTo=n}onFlush(){let t=this.getItems(),n=wt(),r=this._groupEventsByContextHash(t),i=this.analyticsInstance._getUserId(),s=[];return n.forEach((o,c)=>{let l=r[c];l&&s.push(this.analyticsInstance[this.flushTo].addItem(this._createMessage({context:o,events:l,userId:i})))}),s}onFlushSuccess(t){let n=this.getItems(),r=t?.filter(s=>s&&s.value&&s.value.events),i=lo(r,n);T(this.name,i),this.analyticsInstance.resetContext(),this.reset()}_createMessage({context:t,events:n,userId:r}){let{channelId:i,...s}=t,{dataSourceId:o,identity:{emailAddressHashed:c}}=this.analyticsInstance.config;return{channelId:i,context:{...s},dataSourceId:o,emailAddressHashed:c,events:n,id:De(),userId:r}}_groupEventsByContextHash(t){return t.reduce((n,r)=>(n[r.contextHash]?n[r.contextHash].push(r):n[r.contextHash]=[r],n),{})}};var Wo=tr;var nr=class extends Wo{constructor({analyticsInstance:t,name:n=a.Queues.Events}){super({analyticsInstance:t,flushTo:a.Queues.Messages,name:n})}};var Go=nr;var rr=class extends ve{constructor({analyticsInstance:t,name:n=a.Queues.IdentityMessage}){super({analyticsInstance:t,flushTo:t.config.identityEndpoint,name:n})}};var $o=rr;var Ot=class{constructor(t){this.instance=t}getBatchSegmentExternalReferenceCodes(){let t=this._getIndividualId(),n=E(ht);if(n&&n[t]){let r=new Date,i=n[t];if(r.getTime()-i.createDate<Da)return Promise.resolve(i.segmentExternalReferenceCodes)}return this._fetchSegmentExternalReferenceCodes(t,"batch-segment-external-reference-codes").then(r=>{try{let i=new Date,s=E(ht)||{};return T(ht,{...s,[t]:{createDate:i.getTime(),segmentExternalReferenceCodes:r}}),r}catch{return r}})}getRealTimeSegmentExternalReferenceCodes(){return this._fetchSegmentExternalReferenceCodes(this._getIndividualId(),"real-time-segment-external-reference-codes")}_getIndividualId(){let{config:t}=this.instance;return t.identity?.emailAddressHashed||this.instance._getUserId()}_fetchSegmentExternalReferenceCodes(t,n){let{config:r}=this.instance,i={"Content-Type":"application/json"};return r.projectId&&Object.assign(i,{[gt]:r.projectId}),fetch(`${r.faroBackendUrl}/api/1.0/segment-memberships/${t}/${n}`,{cache:"default",credentials:"same-origin",headers:i,method:"GET",mode:"cors"}).then(s=>s.json())}};var ir=1,hf=[[1,()=>{let e=E(a.Keys.Contexts);e&&!Array.isArray(e[0])&&Fe(new Map)}]];function gf(){let e=E(a.Keys.StorageVersion);return e?parseFloat(e):0}function vf(e=ir){return T(a.Keys.StorageVersion,e.toString())}function Ko(){let e=gf();return e===ir||(hf.forEach(([t,n])=>{t>e&&n()}),vf(ir)),!0}var Af=[a.ApplicationId.Blog,a.ApplicationId.Custom,a.ApplicationId,a.ApplicationId.Form,a.ApplicationId.Page,a.ApplicationId.WebContent],Mt=e=>t=>e.map(n=>{if(typeof n=="function")return n(t)}).filter(Boolean),Tf=e=>{let t="";return["string","number","boolean"].includes(typeof e)||(t="Attribute must be a String, Number, or Boolean."),t},zo=e=>t=>{let n="";return String(t).length||(n=`${e} is required.`),n},Ef=e=>t=>{let n="";return typeof t!="string"&&(n=`${e} must be a string.`),n},sr=(e=qa)=>t=>{let n="";return String(t).length>e&&(n=`${t} exceeds maximum length of ${e}`),n},bf=(e=ka)=>({eventId:t,eventProps:n={}})=>{let r="";return Object.keys(n).length>e&&(r=`The Event ${t} attributes list exceeds maximum length of ${e}`),r},If=e=>e.forEach(t=>console.error(new Error(t))),Yo=({applicationId:e,eventId:t,eventProps:n})=>{let r=Mt([Ef("eventId"),zo("eventId"),sr()]),i=Mt([bf()]),s=Mt([zo("eventPropKey"),sr()]),o=[];Af.includes(e)||(o=[Tf,sr(ja)]);let c=Mt(o),l=[];if(l=l.concat(r(t)),n){l=l.concat(i({eventId:t,eventProps:n}));for(let u in n)l=l.concat(s(u),c(n[u]))}return l.length?(If(l),!1):!0};var Ae=window||global,Ve=class Ve{constructor(t,n){this._disposed=!1;this._pluginDisposers=[];this.config={channelId:"",dataSourceId:"",demandbaseAccountEndpoint:"",endpointUrl:"",faroBackendUrl:"",flushInterval:0,identity:{emailAddressHashed:""},identityEndpoint:"",projectId:"",userId:""};this.middlewares=[];this.version="";if(this._isTrackingDisabled())return this;this._disposed=!1;let r=(t.endpointUrl||"").replace(/\/$/,""),i=(t.faroBackendUrl||"").replace(/\/$/,"");return this.config=Object.assign(t,{demandbaseAccountEndpoint:`${r}/demandbase-account`,endpointUrl:r,faroBackendUrl:i,flushInterval:t.flushInterval||2e3,identityEndpoint:`${r}/identity`}),this.version=Sa,n.forEach(s=>this.registerMiddleware(s)),this._queueFlushService=new No(this.config),this._initializeEventQueue(),this._initializeEventMessageQueue(),this._initializeIdentityMessageQueue(),this._initializeAccountMessageQueue(),this.demandbase=new xt(this),this.segment=new Ot(this),Ko(),this._pluginDisposers=Ho.map(s=>s(this)),this._ensureIntegrity(),this}static create(t,n=[]){let r=new Ve(t,n),i=window.Liferay;Ae.Analytics=r,Ae.Analytics.create=Ve.create,Ae.Analytics.dispose=Ve.dispose;let s="",o="";return i&&i.ThemeDisplay&&i.ThemeDisplay.getUserEmailAddress&&i.ThemeDisplay.getUserEmailAddress().length&&i.ThemeDisplay.getUserName&&i.ThemeDisplay.getUserName().length&&(s=i.ThemeDisplay.getUserEmailAddress(),o=i.ThemeDisplay.getUserName()),r.setIdentity({email:s,name:o}),r}static dispose(){let t=Ae.Analytics;t&&!t._isTrackingDisabled()&&t._disposeInternal()}getEvents(){return this[a.Queues.Events].getItems()}getBatchSegmentExternalReferenceCodes(){return this.segment.getBatchSegmentExternalReferenceCodes()}getRealTimeSegmentExternalReferenceCodes(){return this.segment.getRealTimeSegmentExternalReferenceCodes()}registerPlugin(t){typeof t=="function"&&t(this)}registerMiddleware(t){this._isTrackingDisabled()||typeof t=="function"&&Vn.push(t)}reset(){this._isTrackingDisabled()||(this[a.Queues.Events].reset(),this.resetContext())}resetContext(){let t=this._getContext(),n=new Map;n.set(Z(t),t),Fe(n)}track(t,n,r={}){let{assetType:i,...s}=n||{},o={applicationId:a.ApplicationId.CustomEvent,...r},c=i||o.applicationId;if(this._isTrackingDisabled()||this._disposed||!Yo({applicationId:c,eventId:t,eventProps:s}))return;let l=this._getCurrentContextHash();this[a.Queues.Events].addItem(co(t,c,s,l))}send(t,n,r){n&&this.track(t,r,{applicationId:n})}setIdentity(t){if(this._isTrackingDisabled())return;let n={emailAddressHashed:t.email?Z(t.email.toLowerCase()):""};this.config.identity=n;let r=this._getUserId();return this._sendIdentity(n,r),this.demandbase.sendAccountMessage(r),Promise.resolve(r)}_disposeInternal(){this._disposed=!0,this._queueFlushService&&this._queueFlushService.dispose(),this._pluginDisposers.length&&this._pluginDisposers.filter(t=>typeof t=="function").forEach(t=>t())}_ensureIntegrity(){let t=E(a.Keys.UserId);t&&this._setCookie(a.Keys.UserId,t)}_getCurrentContextHash(){let t=this._getContext(),n=Z(t),r=wt();return r.has(n)||(r.set(n,t),Fe(r)),n}_getContext(){let{context:t}=Vn.reduce((r,i)=>i(r),{context:{channelId:this.config.channelId}}),n={...t};for(let r in n)n[r]=String(n[r]).slice(0,Pa);return n}_getIdentityHash(t,n,r){return Z({dataSourceId:t,identity:n,userId:r})}_getUserId(){let t=E(a.Keys.UserId),{emailAddressHashed:n}=this.config.identity,r=E(a.Keys.PrevEmailAddressHash);return t||(t=this._generateUserId()),n&&n!==r&&(r&&(t=this._generateUserId()),T(a.Keys.PrevEmailAddressHash,n)),t}_generateUserId(){let t=De();return T(a.Keys.UserId,t),this._setCookie(a.Keys.UserId,t),It(a.Keys.Identity),t}_isTrackingDisabled(){return Ae[a.Keys.DisableTracking]||navigator.doNotTrack==="1"||navigator.doNotTrack==="yes"}_sendIdentity(t,n){let{dataSourceId:r}=this.config,{channelId:i}=this._getContext(),s=this._getIdentityHash(r,t,n),o=E(a.Keys.Identity),c=E(a.Keys.ChannelId);if(s!==o||i!==c){let{emailAddressHashed:l}=t;T(a.Keys.ChannelId,i),T(a.Keys.Identity,s),this[a.Queues.IdentityMessage].addItem({channelId:i,dataSourceId:r,emailAddressHashed:l,id:s,userId:n})}}_setCookie(t,n){let r=window.Liferay,i=new Date;if(i.setDate(i.getDate()+365),r?.Util?.Cookie)r.Util.Cookie.set?.(t,n,r?.Util?.Cookie?.TYPES?.PERSONALIZATION,{expires:i,secure:!0});else{let s=r?.ThemeDisplay?.getPathContext?.()||"/";document.cookie=`${t}=${n}; expires=${i.toUTCString()}; path=${s}; Secure`}}_initializeEventQueue(){let t=new Go({analyticsInstance:this});this[a.Queues.Events]=t,this._queueFlushService.addQueue(t,{priority:1})}_initializeEventMessageQueue(){let t=new Bo({analyticsInstance:this});this[a.Queues.Messages]=t,this._queueFlushService.addQueue(t,{priority:1})}_initializeIdentityMessageQueue(){let t=new $o({analyticsInstance:this});this[a.Queues.IdentityMessage]=t,this._queueFlushService.addQueue(t,{priority:10})}_initializeAccountMessageQueue(){let t=new Vo({analyticsInstance:this});this[a.Queues.AccountMessage]=t,this._queueFlushService.addQueue(t,{priority:10})}};a.Queues.AccountMessage,a.Queues.Events,a.Queues.Messages,a.Queues.IdentityMessage;var ar=Ve;Ae.Analytics={create:ar.create};})();
//# sourceMappingURL=analytics-all-min.js.map
