PageSourceSearch

https://metrics.lmh.org/main.js

js lmh.org collected 2026-09-24 09:47:14 UTC 129,406 bytes, 3 lines download raw bytes

1(function(){
2"use strict";function _toConsumableArray(r){return _arrayWithoutHoles(r)||_iterableToArray(r)||_unsupportedIterableToArray(r)||_nonIterableSpread()}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _iterableToArray(r){if("undefined"!=typeof Symbol&&null!=r[Symbol.iterator]||null!=r["@@iterator"])return Array.from(r)}function _arrayWithoutHoles(r){if(Array.isArray(r))return _arrayLikeToArray(r)}function _defineProperty(e,r,t){return(r=_toPropertyKey(r))in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}function _regenerator(){var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toStringTag||"@@toStringTag";function i(r,n,o,i){var c=n&&n.prototype instanceof Generator?n:Generator,u=Object.create(c.prototype);return _regeneratorDefine2(u,"_invoke",function(r,n,o){var i,c,u,f=0,p=o||[],y=!1,G={p:0,n:0,v:e,a:d,f:d.bind(e,4),d:function d(t,r){return i=t,c=0,u=e,G.n=r,a}};function d(r,n){for(c=r,u=n,t=0;!y&&f&&!o&&t<p.length;t++){var o,i=p[t],d=G.p,l=i[2];r>3?(o=l===n)&&(u=i[(c=i[4])?5:(c=3,3)],i[4]=i[5]=e):i[0]<=d&&((o=r<2&&d<i[1])?(c=0,G.v=n,G.n=i[1]):d<l&&(o=r<3||i[0]>n||n>l)&&(i[4]=r,i[5]=n,G.n=l,c=0))}if(o||r>1)return a;throw y=!0,n}return function(o,p,l){if(f>1)throw TypeError("Generator is already running");for(y&&1===p&&d(p,l),c=p,u=l;(t=c<2?e:u)||!y;){i||(c?c<3?(c>1&&(G.n=-1),d(c,u)):G.n=u:G.v=u);try{if(f=2,i){if(c||(o="next"),t=i[o]){if(!(t=t.call(i,u)))throw TypeError("iterator result is not an object");if(!t.done)return t;u=t.value,c<2&&(c=0)}else 1===c&&(t=i["return"])&&t.call(i),c<2&&(u=TypeError("The iterator does not provide a '"+o+"' method"),c=1);i=e}else if((t=(y=G.n<0)?u:r.call(n,G))!==a)break}catch(t){i=e,c=1,u=t}finally{f=1}}return{value:t,done:y}}}(r,o,i),!0),u}var a={};function Generator(){}function GeneratorFunction(){}function GeneratorFunctionPrototype(){}t=Object.getPrototypeOf;var c=[][n]?t(t([][n]())):(_regeneratorDefine2(t={},n,function(){return this}),t),u=GeneratorFunctionPrototype.prototype=Generator.prototype=Object.create(c);function f(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,GeneratorFunctionPrototype):(e.__proto__=GeneratorFunctionPrototype,_regeneratorDefine2(e,o,"GeneratorFunction")),e.prototype=Object.create(u),e}return GeneratorFunction.prototype=GeneratorFunctionPrototype,_regeneratorDefine2(u,"constructor",GeneratorFunctionPrototype),_regeneratorDefine2(GeneratorFunctionPrototype,"constructor",GeneratorFunction),GeneratorFunction.displayName="GeneratorFunction",_regeneratorDefine2(GeneratorFunctionPrototype,o,"GeneratorFunction"),_regeneratorDefine2(u),_regeneratorDefine2(u,o,"Generator"),_regeneratorDefine2(u,n,function(){return this}),_regeneratorDefine2(u,"toString",function(){return"[object Generator]"}),(_regenerator=function _regenerator(){return{w:i,m:f}})()}function _regeneratorDefine2(e,r,n,t){var i=Object.defineProperty;try{i({},"",{})}catch(e){i=0}_regeneratorDefine2=function _regeneratorDefine(e,r,n,t){function o(r,n){_regeneratorDefine2(e,r,function(e){return this._invoke(r,n,e)})}r?i?i(e,r,{value:n,enumerable:!t,configurable:!t,writable:!t}):e[r]=n:(o("next",0),o("throw",1),o("return",2))},_regeneratorDefine2(e,r,n,t)}function asyncGeneratorStep(n,t,e,r,o,a,c){try{var i=n[a](c),u=i.value}catch(n){return void e(n)}i.done?t(u):Promise.resolve(u).then(r,o)}function _asyncToGenerator(n){return function(){var t=this,e=arguments;return new Promise(function(r,o){var a=n.apply(t,e);function _next(n){asyncGeneratorStep(a,r,o,_next,_throw,"next",n)}function _throw(n){asyncGeneratorStep(a,r,o,_next,_throw,"throw",n)}_next(void 0)})}}function _slicedToArray(r,e){return _arrayWithHoles(r)||_iterableToArrayLimit(r,e)||_unsupportedIterableToArray(r,e)||_nonIterableRest()}function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _iterableToArrayLimit(r,l){var t=null==r?null:"undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(null!=t){var e,n,i,u,a=[],f=!0,o=!1;try{if(i=(t=t.call(r)).next,0===l){if(Object(t)!==t)return;f=!1}else for(;!(f=(e=i.call(t)).done)&&(a.push(e.value),a.length!==l);f=!0);}catch(r){o=!0,n=r}finally{try{if(!f&&null!=t["return"]&&(u=t["return"](),Object(u)!==u))return}finally{if(o)throw n}}return a}}function _arrayWithHoles(r){if(Array.isArray(r))return r}function _classCallCheck(a,n){if(!(a instanceof n))throw new TypeError("Cannot call a class as a function")}function _defineProperties(e,r){for(var t=0;t<r.length;t++){var o=r[t];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,_toPropertyKey(o.key),o)}}function _createClass(e,r,t){return r&&_defineProperties(e.prototype,r),t&&_defineProperties(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function _toPropertyKey(t){var i=_toPrimitive(t,"string");return"symbol"==_typeof(i)?i:i+""}function _toPrimitive(t,r){if("object"!=_typeof(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,r||"default");if("object"!=_typeof(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===r?String:Number)(t)}function _typeof(o){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o},_typeof(o)}function _createForOfIteratorHelper(r,e){var t="undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(!t){if(Array.isArray(r)||(t=_unsupportedIterableToArray(r))||e&&r&&"number"==typeof r.length){t&&(r=t);var _n7=0,F=function F(){};return{s:F,n:function n(){return _n7>=r.length?{done:!0}:{done:!1,value:r[_n7++]}},e:function e(r){throw r},f:F}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,u=!1;return{s:function s(){t=t.call(r)},n:function n(){var r=t.next();return a=r.done,r},e:function e(r){u=!0,o=r},f:function f(){try{a||null==t["return"]||t["return"]()}finally{if(u)throw o}}}}function _unsupportedIterableToArray(r,a){if(r){if("string"==typeof r)return _arrayLikeToArray(r,a);var t={}.toString.call(r).slice(8,-1);return"Object"===t&&r.constructor&&(t=r.constructor.name),"Map"===t||"Set"===t?Array.from(r):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?_arrayLikeToArray(r,a):void 0}}function _arrayLikeToArray(r,a){(null==a||a>r.length)&&(a=r.length);for(var e=0,n=Array(a);e<a;e++)n[e]=r[e];return n}(function(){var Ya=Object.create;var Et=Object.defineProperty,Qa=Object.defineProperties,Za=Object.getOwnPropertyDescriptor,Ja=Object.getOwnPropertyDescriptors,ec=Object.getOwnPropertyNames,xr=Object.getOwnPropertySymbols,tc=Object.getPrototypeOf,Pr=Object.prototype.hasOwnProperty,rc=Object.prototype.propertyIsEnumerable;var Ar=function Ar(t,e,r){return e in t?Et(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r},d=function d(t,e){for(var r in e||(e={}))Pr.call(e,r)&&Ar(t,r,e[r]);if(xr){var _iterator=_createForOfIteratorHelper(xr(e)),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var r=_step.value;rc.call(e,r)&&Ar(t,r,e[r])}}catch(err){_iterator.e(err)}finally{_iterator.f()}}return t},_=function _(t,e){return Qa(t,Ja(e))};var a=function a(t,e){return function(){try{return e||t((e={exports:{}}).exports,e),e.exports}catch(r){throw e=0,r}}};var nc=function nc(t,e,r,n){if(e&&_typeof(e)=="object"||typeof e=="function"){var _iterator2=_createForOfIteratorHelper(ec(e)),_step2;try{var _loop=function _loop(){var i=_step2.value;!Pr.call(t,i)&&i!==r&&Et(t,i,{get:function get(){return e[i]},enumerable:!(n=Za(e,i))||n.enumerable})};for(_iterator2.s();!(_step2=_iterator2.n()).done;){_loop()}}catch(err){_iterator2.e(err)}finally{_iterator2.f()}}return t};var St=function St(t,e,r){return r=t!=null?Ya(tc(t)):{}
2,nc(e||!t||!t.__esModule?Et(r,"default",{value:t,enumerable:!0}):r,t)};var G=a(function($v,Gr){function Ac(t){var e=_typeof(t);return t!=null&&(e=="object"||e=="function")}Gr.exports=Ac});var dn=a(function(Xb,un){function Uc(){this.__data__=[],this.size=0}un.exports=Uc});var $t=a(function(zb,mn){function jc(t,e){return t===e||t!==t&&e!==e}mn.exports=jc});var _e=a(function(Kb,pn){var Vc=$t();function Hc(t,e){for(var r=t.length;r--;)if(Vc(t[r][0],e))return r;return-1}pn.exports=Hc});var fn=a(function(Yb,gn){var Wc=_e(),$c=Array.prototype,Bc=$c.splice;function Gc(t){var e=this.__data__,r=Wc(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():Bc.call(e,r,1),--this.size,!0}gn.exports=Gc});var vn=a(function(Qb,hn){var Xc=_e();function zc(t){var e=this.__data__,r=Xc(e,t);return r<0?void 0:e[r][1]}hn.exports=zc});var _n=a(function(Zb,bn){var Kc=_e();function Yc(t){return Kc(this.__data__,t)>-1}bn.exports=Yc});var wn=a(function(Jb,yn){var Qc=_e();function Zc(t,e){var r=this.__data__,n=Qc(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}yn.exports=Zc});var ye=a(function(e_,En){var Jc=dn(),el=fn(),tl=vn(),rl=_n(),nl=wn();function J(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}J.prototype.clear=Jc;J.prototype["delete"]=el;J.prototype.get=tl;J.prototype.has=rl;J.prototype.set=nl;En.exports=J});var kn=a(function(t_,Sn){var il=ye();function ol(){this.__data__=new il,this.size=0}Sn.exports=ol});var Tn=a(function(r_,Cn){function sl(t){var e=this.__data__,r=e["delete"](t);return this.size=e.size,r}Cn.exports=sl});var An=a(function(n_,xn){function al(t){return this.__data__.get(t)}xn.exports=al});var In=a(function(i_,Pn){function cl(t){return this.__data__.has(t)}Pn.exports=cl});var Bt=a(function(o_,Dn){var ll=(typeof global==="undefined"?"undefined":_typeof(global))=="object"&&global&&global.Object===Object&&global;Dn.exports=ll});var D=a(function(s_,On){var ul=Bt(),dl=(typeof self==="undefined"?"undefined":_typeof(self))=="object"&&self&&self.Object===Object&&self,ml=ul||dl||Function("return this")();On.exports=ml});var Ge=a(function(a_,Rn){var pl=D(),gl=pl.Symbol;Rn.exports=gl});var Fn=a(function(c_,Nn){var Mn=Ge(),Ln=Object.prototype,fl=Ln.hasOwnProperty,hl=Ln.toString,we=Mn?Mn.toStringTag:void 0;function vl(t){var e=fl.call(t,we),r=t[we];try{t[we]=void 0;var n=!0}catch(o){}var i=hl.call(t);return n&&(e?t[we]=r:delete t[we]),i}Nn.exports=vl});var Un=a(function(l_,qn){var bl=Object.prototype,_l=bl.toString;function yl(t){return _l.call(t)}qn.exports=yl});var Ee=a(function(u_,Hn){var jn=Ge(),wl=Fn(),El=Un(),Sl="[object Null]",kl="[object Undefined]",Vn=jn?jn.toStringTag:void 0;function Cl(t){return t==null?t===void 0?kl:Sl:Vn&&Vn in Object(t)?wl(t):El(t)}Hn.exports=Cl});var Gt=a(function(d_,Wn){var Tl=Ee(),xl=G(),Al="[object AsyncFunction]",Pl="[object Function]",Il="[object GeneratorFunction]",Dl="[object Proxy]";function Ol(t){if(!xl(t))return!1;var e=Tl(t);return e==Pl||e==Il||e==Al||e==Dl}Wn.exports=Ol});var Bn=a(function(m_,$n){var Rl=D(),Ml=Rl["__core-js_shared__"];$n.exports=Ml});var zn=a(function(p_,Xn){var Xt=Bn(),Gn=function(){var t=/[^.]+$/.exec(Xt&&Xt.keys&&Xt.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function Ll(t){return!!Gn&&Gn in t}Xn.exports=Ll});var zt=a(function(g_,Kn){var Nl=Function.prototype,Fl=Nl.toString;function ql(t){if(t!=null){try{return Fl.call(t)}catch(e){}try{return t+""}catch(e){}}return""}Kn.exports=ql});var Qn=a(function(f_,Yn){var Ul=Gt(),jl=zn(),Vl=G(),Hl=zt(),Wl=/[\\^$.*+?()[\]{}|]/g,$l=/^\[object .+?Constructor\]$/,Bl=Function.prototype,Gl=Object.prototype,Xl=Bl.toString,zl=Gl.hasOwnProperty,Kl=RegExp("^"+Xl.call(zl).replace(Wl,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Yl(t){if(!Vl(t)||jl(t))return!1;var e=Ul(t)?Kl:$l;return e.test(Hl(t))}Yn.exports=Yl});var Jn=a(function(h_,Zn){function Ql(t,e){return t==null?void 0:t[e]}Zn.exports=Ql});var W=a(function(v_,ei){var Zl=Qn(),Jl=Jn();function eu(t,e){var r=Jl(t,e);return Zl(r)?r:void 0}ei.exports=eu});
2var Xe=a(function(b_,ti){var tu=W(),ru=D(),nu=tu(ru,"Map");ti.exports=nu});var Se=a(function(__,ri){var iu=W(),ou=iu(Object,"create");ri.exports=ou});var oi=a(function(y_,ii){var ni=Se();function su(){this.__data__=ni?ni(null):{},this.size=0}ii.exports=su});var ai=a(function(w_,si){function au(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}si.exports=au});var li=a(function(E_,ci){var cu=Se(),lu="__lodash_hash_undefined__",uu=Object.prototype,du=uu.hasOwnProperty;function mu(t){var e=this.__data__;if(cu){var r=e[t];return r===lu?void 0:r}return du.call(e,t)?e[t]:void 0}ci.exports=mu});var di=a(function(S_,ui){var pu=Se(),gu=Object.prototype,fu=gu.hasOwnProperty;function hu(t){var e=this.__data__;return pu?e[t]!==void 0:fu.call(e,t)}ui.exports=hu});var pi=a(function(k_,mi){var vu=Se(),bu="__lodash_hash_undefined__";function _u(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=vu&&e===void 0?bu:e,this}mi.exports=_u});var fi=a(function(C_,gi){var yu=oi(),wu=ai(),Eu=li(),Su=di(),ku=pi();function ee(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}ee.prototype.clear=yu;ee.prototype["delete"]=wu;ee.prototype.get=Eu;ee.prototype.has=Su;ee.prototype.set=ku;gi.exports=ee});var bi=a(function(T_,vi){var hi=fi(),Cu=ye(),Tu=Xe();function xu(){this.size=0,this.__data__={hash:new hi,map:new(Tu||Cu),string:new hi}}vi.exports=xu});var yi=a(function(x_,_i){function Au(t){var e=_typeof(t);return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}_i.exports=Au});var ke=a(function(A_,wi){var Pu=yi();function Iu(t,e){var r=t.__data__;return Pu(e)?r[typeof e=="string"?"string":"hash"]:r.map}wi.exports=Iu});var Si=a(function(P_,Ei){var Du=ke();function Ou(t){var e=Du(this,t)["delete"](t);return this.size-=e?1:0,e}Ei.exports=Ou});var Ci=a(function(I_,ki){var Ru=ke();function Mu(t){return Ru(this,t).get(t)}ki.exports=Mu});var xi=a(function(D_,Ti){var Lu=ke();function Nu(t){return Lu(this,t).has(t)}Ti.exports=Nu});var Pi=a(function(O_,Ai){var Fu=ke();function qu(t,e){var r=Fu(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}Ai.exports=qu});var Di=a(function(R_,Ii){var Uu=bi(),ju=Si(),Vu=Ci(),Hu=xi(),Wu=Pi();function te(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}te.prototype.clear=Uu;te.prototype["delete"]=ju;te.prototype.get=Vu;te.prototype.has=Hu;te.prototype.set=Wu;Ii.exports=te});var Ri=a(function(M_,Oi){var $u=ye(),Bu=Xe(),Gu=Di(),Xu=200;function zu(t,e){var r=this.__data__;if(r instanceof $u){var n=r.__data__;if(!Bu||n.length<Xu-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new Gu(n)}return r.set(t,e),this.size=r.size,this}Oi.exports=zu});var Li=a(function(L_,Mi){var Ku=ye(),Yu=kn(),Qu=Tn(),Zu=An(),Ju=In(),ed=Ri();function re(t){var e=this.__data__=new Ku(t);this.size=e.size}re.prototype.clear=Yu;re.prototype["delete"]=Qu;re.prototype.get=Zu;re.prototype.has=Ju;re.prototype.set=ed;Mi.exports=re});var Fi=a(function(N_,Ni){function td(t,e){for(var r=-1,n=t==null?0:t.length;++r<n&&e(t[r],r,t)!==!1;);return t}Ni.exports=td});var Ui=a(function(F_,qi){var rd=W(),nd=function(){try{var t=rd(Object,"defineProperty");return t({},"",{}),t}catch(e){}}();qi.exports=nd});var Kt=a(function(q_,Vi){var ji=Ui();function id(t,e,r){e=="__proto__"&&ji?ji(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}Vi.exports=id});var Yt=a(function(U_,Hi){var od=Kt(),sd=$t(),ad=Object.prototype,cd=ad.hasOwnProperty;function ld(t,e,r){var n=t[e];(!(cd.call(t,e)&&sd(n,r))||r===void 0&&!(e in t))&&od(t,e,r)}Hi.exports=ld});var Ce=a(function(j_,Wi){var ud=Yt(),dd=Kt();function md(t,e,r,n){var i=!r;r||(r={});for(var o=-1,s=e.length;++o<s;){var c=e[o],l=n?n(r[c],t[c],c,r,t):void 0;l===void 0&&(l=t[c]),i?dd(r,c,l):ud(r,c,l)}return r}Wi.exports=md});var Bi=a(function(V_,$i){function pd(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}$i.exports=pd});var ne=a(function(H_,Gi){function gd(t){return t!=null&&_typeof(t)=="object"}Gi.exports=gd});var zi=a(function(W_,Xi){var fd=Ee(),hd=ne(),vd="[object Arguments]";function bd(t){return hd(t)&&fd(t)==vd}Xi.exports=bd});var Zi=a(function($_,Qi){var Ki=zi(),_d=ne(),Yi=Object.prototype,yd=Yi.hasOwnProperty,wd=Yi.propertyIsEnumerable,Ed=Ki(function(){return arguments}())?Ki:function(t){return _d(t)&&yd.call(t,"callee")&&!wd.call(t,"callee")};Qi.exports=Ed});var ze=a(function(B_,Ji){var Sd=Array.isArray;Ji.exports=Sd});var to=a(function(G_,eo){function kd(){return!1}eo.exports=kd});var Qt=a(function(Te,ie){var Cd=D(),Td=to(),io=_typeof(Te)=="object"&&Te&&!Te.nodeType&&Te,ro=io&&_typeof(ie)=="object"&&ie&&!ie.nodeType&&ie,xd=ro&&ro.exports===io,no=xd?Cd.Buffer:void 0,Ad=no?no.isBuffer:void 0,Pd=Ad||Td;ie.exports=Pd});var so=a(function(X_,oo){var Id=9007199254740991,Dd=/^(?:0|[1-9]\d*)$/;function Od(t,e){var r=_typeof(t);return e=e==null?Id:e,!!e&&(r=="number"||r!="symbol"&&Dd.test(t))&&t>-1&&t%1==0&&t<e}oo.exports=Od});var Zt=a(function(z_,ao){var Rd=9007199254740991;function Md(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=Rd}ao.exports=Md});var lo=a(function(K_,co){var Ld=Ee(),Nd=Zt(),Fd=ne(),qd="[object Arguments]",Ud="[object Array]",jd="[object Boolean]",Vd="[object Date]",Hd="[object Error]",Wd="[object Function]",$d="[object Map]",Bd="[object Number]",Gd="[object Object]",Xd="[object RegExp]",zd="[object Set]",Kd="[object String]",Yd="[object WeakMap]",Qd="[object ArrayBuffer]",Zd="[object DataView]",Jd="[object Float32Array]",em="[object Float64Array
2]",tm="[object Int8Array]",rm="[object Int16Array]",nm="[object Int32Array]",im="[object Uint8Array]",om="[object Uint8ClampedArray]",sm="[object Uint16Array]",am="[object Uint32Array]",v={};v[Jd]=v[em]=v[tm]=v[rm]=v[nm]=v[im]=v[om]=v[sm]=v[am]=!0;v[qd]=v[Ud]=v[Qd]=v[jd]=v[Zd]=v[Vd]=v[Hd]=v[Wd]=v[$d]=v[Bd]=v[Gd]=v[Xd]=v[zd]=v[Kd]=v[Yd]=!1;function cm(t){return Fd(t)&&Nd(t.length)&&!!v[Ld(t)]}co.exports=cm});var Ke=a(function(Y_,uo){function lm(t){return function(e){return t(e)}}uo.exports=lm});var Ye=a(function(xe,oe){var um=Bt(),mo=_typeof(xe)=="object"&&xe&&!xe.nodeType&&xe,Ae=mo&&_typeof(oe)=="object"&&oe&&!oe.nodeType&&oe,dm=Ae&&Ae.exports===mo,Jt=dm&&um.process,mm=function(){try{var t=Ae&&Ae.require&&Ae.require("util").types;return t||Jt&&Jt.binding&&Jt.binding("util")}catch(e){}}();oe.exports=mm});var ho=a(function(Q_,fo){var pm=lo(),gm=Ke(),po=Ye(),go=po&&po.isTypedArray,fm=go?gm(go):pm;fo.exports=fm});var er=a(function(Z_,vo){var hm=Bi(),vm=Zi(),bm=ze(),_m=Qt(),ym=so(),wm=ho(),Em=Object.prototype,Sm=Em.hasOwnProperty;function km(t,e){var r=bm(t),n=!r&&vm(t),i=!r&&!n&&_m(t),o=!r&&!n&&!i&&wm(t),s=r||n||i||o,c=s?hm(t.length,String):[],l=c.length;for(var u in t)(e||Sm.call(t,u))&&!(s&&(u=="length"||i&&(u=="offset"||u=="parent")||o&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||ym(u,l)))&&c.push(u);return c}vo.exports=km});var Qe=a(function(J_,bo){var Cm=Object.prototype;function Tm(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||Cm;return t===r}bo.exports=Tm});var tr=a(function(ey,_o){function xm(t,e){return function(r){return t(e(r))}}_o.exports=xm});var wo=a(function(ty,yo){var Am=tr(),Pm=Am(Object.keys,Object);yo.exports=Pm});var So=a(function(ry,Eo){var Im=Qe(),Dm=wo(),Om=Object.prototype,Rm=Om.hasOwnProperty;function Mm(t){if(!Im(t))return Dm(t);var e=[];for(var r in Object(t))Rm.call(t,r)&&r!="constructor"&&e.push(r);return e}Eo.exports=Mm});var rr=a(function(ny,ko){var Lm=Gt(),Nm=Zt();function Fm(t){return t!=null&&Nm(t.length)&&!Lm(t)}ko.exports=Fm});var Ze=a(function(iy,Co){var qm=er(),Um=So(),jm=rr();function Vm(t){return jm(t)?qm(t):Um(t)}Co.exports=Vm});var xo=a(function(oy,To){var Hm=Ce(),Wm=Ze();function $m(t,e){return t&&Hm(e,Wm(e),t)}To.exports=$m});var Po=a(function(sy,Ao){function Bm(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}Ao.exports=Bm});var Do=a(function(ay,Io){var Gm=G(),Xm=Qe(),zm=Po(),Km=Object.prototype,Ym=Km.hasOwnProperty;function Qm(t){if(!Gm(t))return zm(t);var e=Xm(t),r=[];for(var n in t)n=="constructor"&&(e||!Ym.call(t,n))||r.push(n);return r}Io.exports=Qm});var Je=a(function(cy,Oo){var Zm=er(),Jm=Do(),ep=rr();function tp(t){return ep(t)?Zm(t,!0):Jm(t)}Oo.exports=tp});var Mo=a(function(ly,Ro){var rp=Ce(),np=Je();function ip(t,e){return t&&rp(e,np(e),t)}Ro.exports=ip});var Uo=a(function(Pe,se){var op=D(),qo=_typeof(Pe)=="object"&&Pe&&!Pe.nodeType&&Pe,Lo=qo&&_typeof(se)=="object"&&se&&!se.nodeType&&se,sp=Lo&&Lo.exports===qo,No=sp?op.Buffer:void 0,Fo=No?No.allocUnsafe:void 0;function ap(t,e){if(e)return t.slice();var r=t.length,n=Fo?Fo(r):new t.constructor(r);return t.copy(n),n}se.exports=ap});var Vo=a(function(uy,jo){function cp(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r<n;)e[r]=t[r];return e}jo.exports=cp});var Wo=a(function(dy,Ho){function lp(t,e){for(var r=-1,n=t==null?0:t.length,i=0,o=[];++r<n;){var s=t[r];e(s,r,t)&&(o[i++]=s)}return o}Ho.exports=lp});var nr=a(function(my,$o){function up(){return[]}$o.exports=up});var et=a(function(py,Go){var dp=Wo(),mp=nr(),pp=Object.prototype,gp=pp.propertyIsEnumerable,Bo=Object.getOwnPropertySymbols,fp=Bo?function(t){return t==null?[]:(t=Object(t),dp(Bo(t),function(e){return gp.call(t,e)}))}:mp;Go.exports=fp});var zo=a(function(gy,Xo){var hp=Ce(),vp=et();function bp(t,e){return hp(t,vp(t),e)}Xo.exports=bp});var ir=a(function(fy,Ko){function _p(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}Ko.exports=_p});var or=a(function(hy,Yo){var yp=tr(),wp=yp(Object.getPrototypeOf,Object);Yo.exports=wp});var sr=a(function(vy,Qo){var Ep=ir(),Sp=or(),kp=et(),Cp=nr(),Tp=Object.getOwnPropertySymbols,xp=Tp?function(t){for(var e=[];t;)Ep(e,kp(t)),t=Sp(t);return e}:Cp;Qo.exports=xp});var Jo=a(function(by,Zo){var Ap=Ce(),Pp=sr();function Ip(t,e){return Ap(t,Pp(t),e)}Zo.exports=Ip});var ar=a(function(_y,es){var Dp=ir(),Op=ze();function Rp(t,e,r){var n=e(t);return Op(t)?n:Dp(n,r(t))}es.exports=Rp});var rs=a(function(yy,ts){var Mp=ar(),Lp=et(),Np=Ze();function Fp(t){return Mp(t,Np,Lp)}ts.exports=Fp});var is=a(function(wy,ns){var qp=ar(),Up=sr(),jp=Je();function Vp(t){return qp(t,jp,Up)}ns.exports=Vp});var ss=a(function(Ey,os){var Hp=W(),Wp=D(),$p=Hp(Wp,"DataView");os.exports=$p});var cs=a(function(Sy,as){var Bp=W(),Gp=D(),Xp=Bp(Gp,"Promise");as.exports=Xp});var us=a(function(ky,ls){var zp=W(),Kp=D(),Yp=zp(Kp,"Set");ls.exports=Yp});var ms=a(function(Cy,ds){var Qp=W(),Zp=D(),Jp=Qp(Zp,"WeakMap");ds.exports=Jp});var tt=a(function(Ty,_s){var cr=ss(),lr=Xe(),ur=cs(),dr=us(),mr=ms(),bs=Ee(),ae=zt(),ps="[object Map]",eg="[object Object]",gs="[object Promise]",fs="[object Set]",hs="[object WeakMap]",vs="[object DataView]",tg=ae(cr),rg=ae(lr),ng=ae(ur),ig=ae(dr),og=ae(mr),X=bs;(cr&&X(new cr(new ArrayBuffer(1)))!=vs||lr&&X(new lr)!=ps||ur&&X(ur.resolve())!=gs||dr&&X(new dr)!=fs||mr&&X(new mr)!=hs)&&(X=function X(t){var e=bs(t),r=e==eg?t.constructor:void 0,n=r?ae(r):"";if(n)switch(n){case tg:return vs;case rg:return ps;case ng:return gs;case ig:return fs;case og:return hs}return e});_s.exports=X});var ws=a(function(xy,ys){var sg=Object.prototype,ag=sg.hasOwnProperty;function cg(t){var e=t.length,r=new t.constructor(e);return e&&typeof t[0]=="string"&&ag.call(t,"index")&&(r.index=t.index,r.input
2=t.input),r}ys.exports=cg});var Ss=a(function(Ay,Es){var lg=D(),ug=lg.Uint8Array;Es.exports=ug});var rt=a(function(Py,Cs){var ks=Ss();function dg(t){var e=new t.constructor(t.byteLength);return new ks(e).set(new ks(t)),e}Cs.exports=dg});var xs=a(function(Iy,Ts){var mg=rt();function pg(t,e){var r=e?mg(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}Ts.exports=pg});var Ps=a(function(Dy,As){var gg=/\w*$/;function fg(t){var e=new t.constructor(t.source,gg.exec(t));return e.lastIndex=t.lastIndex,e}As.exports=fg});var Ms=a(function(Oy,Rs){var Is=Ge(),Ds=Is?Is.prototype:void 0,Os=Ds?Ds.valueOf:void 0;function hg(t){return Os?Object(Os.call(t)):{}}Rs.exports=hg});var Ns=a(function(Ry,Ls){var vg=rt();function bg(t,e){var r=e?vg(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}Ls.exports=bg});var qs=a(function(My,Fs){var _g=rt(),yg=xs(),wg=Ps(),Eg=Ms(),Sg=Ns(),kg="[object Boolean]",Cg="[object Date]",Tg="[object Map]",xg="[object Number]",Ag="[object RegExp]",Pg="[object Set]",Ig="[object String]",Dg="[object Symbol]",Og="[object ArrayBuffer]",Rg="[object DataView]",Mg="[object Float32Array]",Lg="[object Float64Array]",Ng="[object Int8Array]",Fg="[object Int16Array]",qg="[object Int32Array]",Ug="[object Uint8Array]",jg="[object Uint8ClampedArray]",Vg="[object Uint16Array]",Hg="[object Uint32Array]";function Wg(t,e,r){var n=t.constructor;switch(e){case Og:return _g(t);case kg:case Cg:return new n(+t);case Rg:return yg(t,r);case Mg:case Lg:case Ng:case Fg:case qg:case Ug:case jg:case Vg:case Hg:return Sg(t,r);case Tg:return new n;case xg:case Ig:return new n(t);case Ag:return wg(t);case Pg:return new n;case Dg:return Eg(t)}}Fs.exports=Wg});var Vs=a(function(Ly,js){var $g=G(),Us=Object.create,Bg=function(){function t(){}return function(e){if(!$g(e))return{};if(Us)return Us(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}();js.exports=Bg});var Ws=a(function(Ny,Hs){var Gg=Vs(),Xg=or(),zg=Qe();function Kg(t){return typeof t.constructor=="function"&&!zg(t)?Gg(Xg(t)):{}}Hs.exports=Kg});var Bs=a(function(Fy,$s){var Yg=tt(),Qg=ne(),Zg="[object Map]";function Jg(t){return Qg(t)&&Yg(t)==Zg}$s.exports=Jg});var Ks=a(function(qy,zs){var ef=Bs(),tf=Ke(),Gs=Ye(),Xs=Gs&&Gs.isMap,rf=Xs?tf(Xs):ef;zs.exports=rf});var Qs=a(function(Uy,Ys){var nf=tt(),of=ne(),sf="[object Set]";function af(t){return of(t)&&nf(t)==sf}Ys.exports=af});var ta=a(function(jy,ea){var cf=Qs(),lf=Ke(),Zs=Ye(),Js=Zs&&Zs.isSet,uf=Js?lf(Js):cf;ea.exports=uf});var sa=a(function(Vy,oa){var df=Li(),mf=Fi(),pf=Yt(),gf=xo(),ff=Mo(),hf=Uo(),vf=Vo(),bf=zo(),_f=Jo(),yf=rs(),wf=is(),Ef=tt(),Sf=ws(),kf=qs(),Cf=Ws(),Tf=ze(),xf=Qt(),Af=Ks(),Pf=G(),If=ta(),Df=Ze(),Of=Je(),Rf=1,Mf=2,Lf=4,ra="[object Arguments]",Nf="[object Array]",Ff="[object Boolean]",qf="[object Date]",Uf="[object Error]",na="[object Function]",jf="[object GeneratorFunction]",Vf="[object Map]",Hf="[object Number]",ia="[object Object]",Wf="[object RegExp]",$f="[object Set]",Bf="[object String]",Gf="[object Symbol]",Xf="[object WeakMap]",zf="[object ArrayBuffer]",Kf="[object DataView]",Yf="[object Float32Array]",Qf="[object Float64Array]",Zf="[object Int8Array]",Jf="[object Int16Array]",eh="[object Int32Array]",th="[object Uint8Array]",rh="[object Uint8ClampedArray]",nh="[object Uint16Array]",ih="[object Uint32Array]",h={};h[ra]=h[Nf]=h[zf]=h[Kf]=h[Ff]=h[qf]=h[Yf]=h[Qf]=h[Zf]=h[Jf]=h[eh]=h[Vf]=h[Hf]=h[ia]=h[Wf]=h[$f]=h[Bf]=h[Gf]=h[th]=h[rh]=h[nh]=h[ih]=!0;h[Uf]=h[na]=h[Xf]=!1;function nt(t,e,r,n,i,o){var s,c=e&Rf,l=e&Mf,u=e&Lf;if(r&&(s=i?r(t,n,i,o):r(t)),s!==void 0)return s;if(!Pf(t))return t;var m=Tf(t);if(m){if(s=Sf(t),!c)return vf(t,s)}else{var f=Ef(t),w=f==na||f==jf;if(xf(t))return hf(t,c);if(f==ia||f==ra||w&&!i){if(s=l||w?{}:Cf(t),!c)return l?_f(t,ff(s,t)):bf(t,gf(s,t))}else{if(!h[f])return i?t:{};s=kf(t,f,c)}}o||(o=new df);var E=o.get(t);if(E)return E;o.set(t,s),If(t)?t.forEach(function(k){s.add(nt(k,e,r,k,t,o))}):Af(t)&&t.forEach(function(k,A){s.set(A,nt(k,e,r,A,t,o))});var M=u?l?wf:yf:l?Of:Df,x=m?void 0:M(t);return mf(x||t,function(k,A){x&&(A=k,k=t[A]),pf(s,A,nt(k,e,r,A,t,o))}),s}oa.exports=nt});var pr=a(function(Hy,aa){var oh=sa(),sh=1,ah=4;function ch(t){return oh(t,sh|ah)}aa.exports=ch});var Ir=function Ir(){window.ours_data||(window.ours_data={}),window.ours_data.sdk_initialized=!0},z={set:function set(t){window.ours_data||(window.ours_data={}),window.ours_data.has_processed_init=t},get:function get(){var t;return((t=window.ours_data)==null?void 0:t.has_processed_init)===!0}},Oe={set:function set(t){window.ours_data||(window.ours_data={}),window.ours_data.visitor_id=t},get:function get(){var t;return(t=window.ours_data)==null?void 0:t.visitor_id}},F={set:function set(t){window.ours_data||(window.ours_data={}),window.ours_data.is_manually_set_id=t},get:function get(){var t;return(t=window.ours_data)==null?void 0:t.is_manually_set_id}};var ic=function ic(){return["ou","rs","-priv","acy","-video-event"]};var Dr=function Dr(){return ic().join("")};var Or="$video_watch",Rr="$video_seek";var oc="$session_replay_init",sc="$session_replay_chunk",ac=[oc,sc],cc="$translation_widget_opened",lc="$translation_language_selected",uc=[cc,lc],dc="$video_lead_capture_displayed",mc="$video_lead_capture_submitted",pc="$video_cta_displayed",kt="$video_cta_clicked",gc=[dc,mc,pc,kt],fc=[Or,Rr],tv=["$identify","$identity_recovered","$reset","$consent_init","$first_consent","$consent_change","$consent_accept_all","$consent_accept_necessary","$consent_modal_dismissed","$consent_banner_rendered","$consent_preferences_opened","$preferences_save","$preferences_accept_all","$preferences_accept_necessary","$gpc_modal_visible","$heatmap_click","$heatmap_scroll","$dead_click","$rage_click","$experiment_impression"].concat(uc,ac,gc,fc);var de=function de(t){try{return sessionStorage.getItem(t)}catch(e){return null}},K=function K(t,e){try{sessionStorage.setItem(t,e)}catch(r){}};var me=function me(){try{var t=new URLSearchParams(window.location.search),e=t.get("gtm_debug"),r=t.get("ours_debug_mode"),i=(window.document.documentElement.getAttribute("data-tag-assistant-present")||"").length>2;return(e||r||i)&&K("ours_debug_view","true"),!!(r||e||i||de("ours_debug_view"))}catch(t){return!1}};var Re=me(),g={error:function error(t){if(Re)try{var _console;for(var _len=arguments.length,e=new Array(_len>1?_len-1:0),_key=1;_key<_len;_key++){e[_key-1]=arguments[_key]}(_console=console).error.apply(_console,[t].concat(e))}catch(r){}},warn:function warn(t){if(Re)try{var _console2;for(var _len2=arguments.length,e=new Array(_len2>1?_len2-1:0),_key2=1;_key2<_len2;_key2++){e[_key2-1]=arguments[_key2]}(_console2=console).warn.apply(_console2,[t].concat(e))}catch(r){}},info:function info(t){if(Re)try{var _console3;for(var _len3=arguments.length,e=new Array(_len3>1?_len3-1:0),_key3=1;_key3<_len3;_key3++){e[_key3-1]=arguments[_key3]}(_console3=console).info.apply(_console3,[t].concat(e))}catch(r){}},debug:function debug(t){if(Re)try{var _console4;for(var _len4=arguments.length,e=new Array(_len4>1?_len4-1:0),_key4=1;_key4<_len4;_key4++){e[_key4-1]=arguments[_key4]}(_console4=console).debug.apply(_console4,[t].concat(e))}catch(r){}}};var hc=new Set([kt]);function Me(t){return!!t&&_typeof(t)=="object"&&!Array.isArray(t)}function vc(t){try{var e=new URL(t,window.location.href);return(e.protocol==="https:"||e.protocol==="http:")&&/^\/embed\/(video|channel)\/[A-Za-z0-9_-]+$/.test(e.pathname)}catch(e){return!1}}function bc(t){return!t.source||!t.origin?!1:Array.from(document.querySelectorAll("iframe.ours_privacy_embed[name=\"ours_privacy_embed\"]")).some(function(e){var r=e.getAttribute("src")||"";return e.contentWindow===t.source&&vc(r)&&new URL(r,window.location.href).origin===t.origin})}var Le=function(){function Le(){_classCallCheck(this,Le);this.isListening=!1;this.messageHandler=this.handleMessage.bind(this)}return _createClass(Le,[{key:"initialize",value:function initialize(){this.isListening||(window.addEventListener("message",this.messageHandler),this.isListening=!0,g.debug("[sdk]Post message listener initialized"))}},{key:"cleanup",value:function cleanup(){this.isListening&&(window.removeEventListener("message",this.messageHandler),this.isListening=!1,g.debug("[sdk]Post message listener cleaned up"))}},{key:"handleMessage",value:function handleMessage(e){if(!bc(e)||!Me(e.data))return;var r=e.data;r.type!==Dr()||typeof r.eventName!="string"||(Me(r.eventProperties)?this.processVideoEvent(r.eventName,r.eventProperties,Me(r.userProperties)?r.userProperties:void 0):Me(r.data)&&this.processVideoEvent(r.eventName,r.data))}},{key:"processVideoEvent",value:function processVideoEvent(e,r,n){if(window.ours){if(!n&&hc.has(e)&&typeof window.ours.trackNow=="function"&&window.ours.trackNow(e,r))return;n?window.ours("track",e,r,n):window.ours("track",e,r)}else g.warn("[sdk]Ours SDK not initialized when processing video event")}}])}();var I=[],q=0,Ne=4,_c=0,S=function S(t){var e=[],r={get:function get(){return r.lc||r.listen(function(){})(),r.value},lc:0,listen:function listen(n){return r.lc=e.push(n),function(){for(var o=q+Ne;o<I.length;)I[o]===n?I.splice(o,Ne):o+=Ne;var i=e.indexOf(n);~i&&(e.splice(i,1),--r.lc||r.off())}},notify:function notify(n,i){_c++;var o=!I.length;for(var _i2=0,_e2=e;_i2<_e2.length;_i2++){var s=_e2[_i2];I.push(s,r.value,n,i)}if(o){for(q=0;q<I.length;q+=Ne)I[q](I[q+1],I[q+2],I[q+3]);I.length=0}},off:function off(){},set:function set(n){var i=r.value;i!==n&&(r.value=n,r.notify(i))},subscribe:function subscribe(n){var i=r.listen(n);return n(r.value),i},value:t};return r};var yc=function yc(){return["ou","rs","priv","acy",".com"]},Mr=function Mr(){return yc().join("")};var Lr=function Lr(t){var e=t==="production"?"":"".concat(t,"-");return"https://".concat(e,"cdn.").concat(Mr())},Nr=function Nr(t){var e=t==="production"?"":"".concat(t,"-");return"https://".concat(e,"ipv4-cdn.").concat(Mr())};
2var Ct=function Ct(t){var e=t.trim();return e.startsWith("http://")||e.startsWith("https://")?e.replace(/\/+$/,""):"https://".concat(e)};function wc(t){var e=t.split("*").map(function(r){return r.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}).join(".*");return new RegExp("^".concat(e,"$"),"i")}function Fr(t,e){return e.some(function(r){try{return wc(r).test(t)}catch(n){return!1}})}function Tt(t,e,r){return r&&r.length>0&&Fr(t,r)?!1:!e||e.length===0?!0:Fr(t,e)}function xt(){if((typeof window==="undefined"?"undefined":_typeof(window))>"u"||!window.location)return"/";var t=window.location.pathname||"/",e=window.location.hash||"";if(!e.startsWith("#/"))return t;var r=e.slice(1),n=r.search(/[?#]/);n!==-1&&(r=r.slice(0,n));var i="".concat(t).concat(r).replace(/\/{2,}/g,"/");return i.length>1?i.replace(/\/+$/,""):i}function At(t){return Array.isArray(t)?t.filter(function(e){return typeof e=="string"}).map(function(e){return e.trim()}).filter(function(e){return e.length>0}):[]}var Pt=S(!1),It=S(!1),Dt=S(!1),Ot=S(!1),Rt=S([]),pe=S({}),ge=S({}),fe=S({}),he=S(!1),U=S(null),Y=S(null),j=S(null),ve=S(null),Ur="production",Fe=Lr(Ur),qr=Nr(Ur),jr={setIsDebugMode:function setIsDebugMode(t){Pt.set(!!t)},getIsDebugMode:Pt.get,isDebugModeAtom:Pt,setTrackWebEvents:function setTrackWebEvents(t){It.set(!!t)},getTrackWebEvents:function getTrackWebEvents(){return It.get()},trackWebEventsAtom:It,setEnhancedWebEvents:function setEnhancedWebEvents(t){Dt.set(!!t)},getEnhancedWebEvents:Dt.get,enhancedWebEventsAtom:Dt,setBotDetection:function setBotDetection(t){Ot.set(!!t)},getBotDetection:Ot.get,botDetectionAtom:Ot,setUrlQueryParamsBlocklist:function setUrlQueryParamsBlocklist(t){if(!Array.isArray(t))throw new TypeError("URL query params blocklist must be an array");var e=t.filter(function(r){return typeof r=="string"}).map(function(r){return r.trim()}).filter(Boolean);Rt.set(e)},getUrlQueryParamsBlocklist:Rt.get,urlQueryParamsBlocklistAtom:Rt,setDefaultEventProperties:function setDefaultEventProperties(t){if(_typeof(t)!="object"||t===null)throw new TypeError("Default event properties must be an object");pe.set(t)},appendDefaultEventProperties:function appendDefaultEventProperties(t){if(_typeof(t)!="object"||t===null)throw new TypeError("Default event properties must be an object");pe.set(d(d({},pe.get()),t))},getDefaultEventProperties:pe.get,defaultEventPropertiesAtom:pe,setDefaultUserCustomProperties:function setDefaultUserCustomProperties(t){if(_typeof(t)!="object"||t===null)throw new TypeError("Default user custom properties must be an object");ge.set(t)},appendDefaultUserCustomProperties:function appendDefaultUserCustomProperties(t){if(_typeof(t)!="object"||t===null)throw new TypeError("Default user custom properties must be an object");ge.set(d(d({},ge.get()),t))},getDefaultUserCustomProperties:ge.get,defaultUserCustomPropertiesAtom:ge,setDefaultUserConsentProperties:function setDefaultUserConsentProperties(t){if(_typeof(t)!="object"||t===null)throw new TypeError("Default user consent properties must be an object");fe.set(t)},appendDefaultUserConsentProperties:function appendDefaultUserConsentProperties(t){if(_typeof(t)!="object"||t===null)throw new TypeError("Default user consent properties must be an object");fe.set(d(d({},fe.get()),t))},getDefaultUserConsentProperties:fe.get,defaultUserConsentPropertiesAtom:fe,setForceIpv4:function setForceIpv4(t){he.set(!!t)},getForceIpv4:he.get,forceIpv4Atom:he,setCustomDomain:function setCustomDomain(t){if(t===null){U.set(null);return}if(typeof t!="string"||t==="")throw new TypeError("Custom domain must be a non-empty string");U.set(Ct(t))},getCustomDomain:U.get,customDomainAtom:U,setCustomDomainIpv4:function setCustomDomainIpv4(t){if(t===null){Y.set(null);return}if(typeof t!="string"||t==="")throw new TypeError("Custom domain must be a non-empty string");Y.set(Ct(t))},getCustomDomainIpv4:Y.get,customDomainIpv4Atom:Y,setSessionReplay:function setSessionReplay(t){if(t===null){j.set(null);return}if(_typeof(t)!="object"||t===null)throw new TypeError("Session replay config must be an object");var e=d({},t);"recordOnPaths"in e&&(e.recordOnPaths=At(e.recordOnPaths)),"excludePaths"in e&&(e.excludePaths=At(e.excludePaths)),j.set(e)}
2,getSessionReplay:j.get,sessionReplayAtom:j,getSessionReplayToken:function getSessionReplayToken(){var e;var t=j.get();return(e=t==null?void 0:t.token)!=null?e:null},sessionReplayTokenAtom:{get:function get(){var e;var t=j.get();return(e=t==null?void 0:t.token)!=null?e:null},set:function set(t){var e=j.get();j.set(_(d({},e||{}),{token:t}))}},setExperimentation:function setExperimentation(t){if(t===null){ve.set(null);return}if(_typeof(t)!="object"||t===null)throw new TypeError("Experimentation config must be an object");ve.set(t)},getExperimentation:ve.get,experimentationAtom:ve,getExperimentationToken:function getExperimentationToken(){var e;var t=ve.get();return(e=t==null?void 0:t.token)!=null?e:null},getIngestEndpoints:function getIngestEndpoints(){if(!he.get())return[new URL(U.get()||Fe)];var t=U.get(),e=Y.get();if(e){var r=[new URL(e)];return t&&r.push(new URL(t)),r}return[new URL(qr),new URL(Fe)]},getIngestDomain:function getIngestDomain(){if(he.get()){var r=Y.get()||qr;return new URL(r)}var t=U.get()||Fe;return new URL(t)},getDomain:function getDomain(){var t=U.get()||Fe;return new URL(t)}};var p=d({},jr),Vr=function Vr(){window.ours_data=window.ours_data||{},window.ours_data.store=p,p.setIsDebugMode(me())};function qe(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)n!=="__proto__"&&(t[n]=r[n])}return t}var Ec={read:function read(t){return t[0]==="\""&&(t=t.slice(1,-1)),t.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function write(t){return encodeURIComponent(t).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}};function Mt(t,e){function r(i,o,s){if(!((typeof document==="undefined"?"undefined":_typeof(document))>"u")){s=qe({},e,s),typeof s.expires=="number"&&(s.expires=new Date(Date.now()+s.expires*864e5)),s.expires&&(s.expires=s.expires.toUTCString()),i=encodeURIComponent(i).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var c="";for(var l in s)s[l]&&(c+="; "+l,s[l]!==!0&&(c+="="+s[l].split(";")[0]));return document.cookie=i+"="+t.write(o,i)+c}}function n(i){if(!((typeof document==="undefined"?"undefined":_typeof(document))>"u"||arguments.length&&!i)){for(var o=document.cookie?document.cookie.split("; "):[],s={},c=0;c<o.length;c++){var l=o[c].split("="),u=l.slice(1).join("=");try{var m=decodeURIComponent(l[0]);if(m in s||(s[m]=t.read(u,m)),i===m)break}catch(f){}}return i?s[i]:s}}return Object.create({set:r,get:n,remove:function remove(i,o){r(i,"",qe({},o,{expires:-1}))},withAttributes:function withAttributes(i){return Mt(this.converter,qe({},this.attributes,i))},withConverter:function withConverter(i){return Mt(qe({},this.converter,i),this.attributes)}},{attributes:{value:Object.freeze(e)},converter:{value:Object.freeze(t)}})}var Lt=Mt(Ec,{path:"/"});var Hr=new Set(["vercel.app","netlify.app","github.io","herokuapp.com","firebaseapp.com","onrender.com","fly.dev","pages.dev","run.app","appspot.com","webflow.io","azurewebsites.net","digitaloceanspaces.com","framer.app","wpenginepowered.com","s3.amazonaws.com","elasticbeanstalk.com","cloudfront.net","surge.sh","railway.app","supabase.co","planetscale.com","upstash.com","turso.tech","neon.tech","cockroachlabs.cloud","blogspot.com","wordpress.com","medium.com","substack.com","ghost.io","ngrok.io","loca.lt","tunnelto.dev","codesandbox.io","replit.com","jsdelivr.net","unpkg.com","cdnjs.com","jsbin.com","codepen.io","workers.dev","edge.com","fastly.com","keycdn.com","bunnycdn.com"]),Wr=new Set(["co.uk","com.au","co.jp","co.in","co.za","co.nz","co.ca","com.br","com.mx","com.ar","com.co","com.pe","com.ve","com.uy","com.py","com.bo","com.ec","com.gt","com.hn","com.sv","com.ni","com.cr","com.pa","com.do","com.cu","com.pr","com.vi","com.ag","com.bb","com.bz","com.dm","com.gd","com.gy","com.jm","com.kn","com.lc","com.tt","com.vc","com.vg","com.ai","com.aw","com.bs","com.ky","com.ms","com.tc","com.tk","com.to","com.tv","com.vu","com.ws","com.ye","com.zw","com.af","com.al","com.dz","com.ao","com.bj","com.bw","com.bf","com.bi","com.cm","com.cv","com.cf","com.td","com.km","com.cg","com.cd","com.ci","com.dj","com.eg","com.gq","com.er","com.et","com.ga","com.gm","com.gh","com.gn","com.gw","com.ke","com.ls","com.lr","com.ly","com.mg","com.mw","com.ml","com.mr","com.mu","com.mz","com.n
2a","com.ne","com.ng","com.rw","com.st","com.sn","com.sc","com.sl","com.so","com.za","com.sd","com.sz","com.tz","com.tg","com.tn","com.ug","com.zm","com.zw","com.ad","com.ae","com.ag","com.ai","com.am","com.ao","com.ar","com.as","com.at","com.au","com.aw","com.az","com.ba","com.bb","com.bd","com.be","com.bf","com.bg","com.bh","com.bi","com.bj","com.bm","com.bn","com.bo","com.br","com.bs","com.bt","com.bw","com.by","com.bz","com.ca","com.cc","com.cd","com.cf","com.cg","com.ch","com.ci","com.ck","com.cl","com.cm","com.cn","com.co","com.cr","com.cu","com.cv","com.cw","com.cx","com.cy","com.cz","com.de","com.dj","com.dk","com.dm","com.do","com.dz","com.ec","com.ee","com.eg","com.er","com.es","com.et","com.eu","com.fi","com.fj","com.fk","com.fm","com.fr","com.ga","com.gb","com.gd","com.ge","com.gf","com.gg","com.gh","com.gi","com.gl","com.gm","com.gn","com.gp","com.gq","com.gr","com.gs","com.gt","com.gu","com.gw","com.gy","com.hk","com.hn","com.hr","com.ht","com.hu","com.id","com.ie","com.il","com.im","com.in","com.io","com.iq","com.ir","com.is","com.it","com.je","com.jm","com.jo","com.jp","com.ke","com.kg","com.kh","com.ki","com.km","com.kn","com.kp","com.kr","com.kw","com.ky","com.kz","com.la","com.lb","com.lc","com.li","com.lk","com.lr","com.ls","com.lt","com.lu","com.lv","com.ly","com.ma","com.mc","com.md","com.me","com.mg","com.mh","com.mk","com.ml","com.mm","com.mn","com.mo","com.mp","com.mq","com.mr","com.ms","com.mt","com.mu","com.mv","com.mw","com.mx","com.my","com.mz","com.na","com.nc","com.ne","com.nf","com.ng","com.ni","com.nl","com.no","com.np","com.nr","com.nu","com.nz","com.om","com.pa","com.pe","com.pf","com.pg","com.ph","com.pk","com.pl","com.pm","com.pn","com.pr","com.ps","com.pt","com.pw","com.py","com.qa","com.re","com.ro","com.rs","com.ru","com.rw","com.sa","com.sb","com.sc","com.sd","com.se","com.sg","com.sh","com.si","com.sk","com.sl","com.sm","com.sn","com.so","com.sr","com.st","com.sv","com.sy","com.sz","com.tc","com.td","com.tf","com.tg","com.th","com.tj","com.tk","com.tl","com.tm","com.tn","com.to","com.tr","com.tt","com.tv","com.tw","com.tz","com.ua","com.ug","com.uk","com.uy","com.uz","com.va","com.vc","com.ve","com.vg","com.vi","com.vn","com.vu","com.wf","com.ws","com.ye","com.yt","com.za","com.zm","com.zw"]),Sc=function Sc(t){var r=t.replace(/^https?:\/\//,"").split(":")[0],n=r==null?void 0:r.split("/")[0];return n||""},$r=function $r(t){if(!t)return!1;var e=Sc(t);if(/^\d+\.\d+\.\d+\.\d+$/.test(e)||e==="localhost"||e.includes("@")||!e.includes("."))return!1;if(Hr.has(e)||Wr.has(e))return!0;var _iterator3=_createForOfIteratorHelper(Hr),_step3;try{for(_iterator3.s();!(_step3=_iterator3.n()).done;){var r=_step3.value;if(e.endsWith("."+r))return!0}}catch(err){_iterator3.e(err)}finally{_iterator3.f()}var _iterator4=_createForOfIteratorHelper(Wr),_step4;try{for(_iterator4.s();!(_step4=_iterator4.n()).done;){var _r2=_step4.value;if(e.endsWith("."+_r2)&&!e.substring(0,e.length-_r2.length-1).includes("."))return!0}}catch(err){_iterator4.e(err)}finally{_iterator4.f()}return!1};var kc=["co.uk","gov.uk","ac.uk","com.au","co.nz","com.br"],Cc=function Cc(){var t=window.location.hostname.replace(/:\d+$/,""),e=t.split(".");return /^(\d{1,3}\.){3}\d{1,3}$/.test(t)||e.length<2||t==="localhost"},Tc=function Tc(){var t=window.location.hostname.replace(/:\d+$/,""),e=t.split(".");if(Cc())return;if($r(t))return window.location.hostname;var r=e.slice(-2).join(".");return kc.includes(r)?".".concat(e.slice(-3).join(".")):".".concat(e.slice(-2).join("."))},Ue=function Ue(t,e){var r=window.location.protocol.includes("https"),n={domain:r?Tc():void 0,expires:365,path:"/",sameSite:r?"None":"Lax",secure:r};try{Lt.set(t,e,n)}catch(i){console.debug("[sdk]Failed to set cookie",i)}},V=function V(t){try{return Lt.get(t)}catch(e){console.debug("[sdk]Failed to get cookie",e);return}};var je=function je(t,e){try{localStorage.setItem(t,e)}catch(r){}},C=function C(t){try{return localStorage.getItem(t)}catch(e){return}};var Nt="_cord_sdk_data",P={SESSION_ID:"ours_sid",SESSION_COUNT:"o_session_count",FB_INIT:"ours_initialized_value",FIRST_VISIT:"_ours_first_visit",ENGAGED_SESSION:"ours_engaged_session",MODAL_PAGE_COUNT:"ours_consent_modal_page_count"},Ft=function(){function Ft(){_classCallCheck(this,Ft);this.cookieName=Nt;this.data=null}
2return _createClass(Ft,[{key:"configure",value:function configure(e){this.cookieName!==e&&(this.cookieName!==Nt&&console.warn("[sdk] sdk_data cookie name is changing from \"".concat(this.cookieName,"\" to \"").concat(e,"\". Previously stored client data may be orphaned.")),this.cookieName=e,this.data=null)}},{key:"getClientData",value:function getClientData(){if(this.data!==null)return this.data;var e=V(this.cookieName);if(e)try{return this.data=JSON.parse(e),this.data}catch(n){}var r=C(this.cookieName);if(r)try{return this.data=JSON.parse(r),this.data}catch(n){}return this.data=this.buildFromLegacyKeys(),this.data}},{key:"setClientData",value:function setClientData(e){this.data=null;var r=JSON.stringify(e);Ue(this.cookieName,r),je(this.cookieName,r)}},{key:"getSessionId",value:function getSessionId(){var e=this.getClientData();return e.sid!==void 0?e.sid:V(P.SESSION_ID)}},{key:"getSessionLastActivity",value:function getSessionLastActivity(){var e=this.getClientData();if(e.session_last_activity!==void 0)return String(e.session_last_activity)}},{key:"getSessionCount",value:function getSessionCount(){var r;var e=this.getClientData();return e.session_count!==void 0?String(e.session_count):(r=C(P.SESSION_COUNT))!=null?r:void 0}},{key:"getFBInit",value:function getFBInit(){var r;var e=this.getClientData();return e.fb_init!==void 0?e.fb_init:(r=C(P.FB_INIT))!=null?r:void 0}},{key:"getFirstVisit",value:function getFirstVisit(){var r;var e=this.getClientData();return e.first_visit!==void 0?String(e.first_visit):(r=C(P.FIRST_VISIT))!=null?r:void 0}},{key:"getEngagedSession",value:function getEngagedSession(){var r;var e=this.getClientData();return e.engaged_session!==void 0?String(e.engaged_session):(r=C(P.ENGAGED_SESSION))!=null?r:void 0}},{key:"getModalPageCount",value:function getModalPageCount(){var r;var e=this.getClientData();return e.modal_page_count!==void 0?String(e.modal_page_count):(r=C(P.MODAL_PAGE_COUNT))!=null?r:void 0}},{key:"getConsentModalDismissedRevision",value:function getConsentModalDismissedRevision(){var e=this.getClientData();if(e.consent_modal_dismissed_revision!==void 0)return String(e.consent_modal_dismissed_revision)}},{key:"setSessionId",value:function setSessionId(e){var r=this.getClientData();this.setClientData(_(d({},r),{sid:e}))}},{key:"setSessionLastActivity",value:function setSessionLastActivity(e){var r=this.getClientData();this.setClientData(_(d({},r),{session_last_activity:e}))}},{key:"setSessionCount",value:function setSessionCount(e){var r=this.getClientData();this.setClientData(_(d({},r),{session_count:e}))}},{key:"setFBInit",value:function setFBInit(e){var r=this.getClientData();this.setClientData(_(d({},r),{fb_init:e}))}},{key:"setFirstVisit",value:function setFirstVisit(e){var r=this.getClientData();this.setClientData(_(d({},r),{first_visit:e}))}},{key:"setEngagedSession",value:function setEngagedSession(e){var r=e===!0||e==="true"||e==="TRUE"||e==="True"||e===1,n=this.getClientData();this.setClientData(_(d({},n),{engaged_session:r}))}},{key:"setModalPageCount",value:function setModalPageCount(e){var r=this.getClientData();this.setClientData(_(d({},r),{modal_page_count:e}))}},{key:"setConsentModalDismissedRevision",value:function setConsentModalDismissedRevision(e){var r=this.getClientData();this.setClientData(_(d({},r),{consent_modal_dismissed_revision:e}))}},{key:"clearConsentModalDismissedRevision",value:function clearConsentModalDismissedRevision(){var e=this.getClientData(),r=d({},e);delete r.consent_modal_dismissed_revision,this.setClientData(r)}},{key:"buildFromLegacyKeys",value:function buildFromLegacyKeys(){var e={},r=V(P.SESSION_ID);r&&(e.sid=r);var n=C(P.SESSION_COUNT);if(n){var l=parseInt(n,10);isNaN(l)||(e.session_count=l)}var i=C(P.FB_INIT);i&&(e.fb_init=i);var o=C(P.FIRST_VISIT);if(o){var _l2=parseInt(o,10);isNaN(_l2)||(e.first_visit=_l2)}C(P.ENGAGED_SESSION)==="true"&&(e.engaged_session=!0);var c=C(P.MODAL_PAGE_COUNT);if(c){var _l3=parseInt(c,10);isNaN(_l3)||(e.modal_page_count=_l3)}return e}},{key:"_clearCache",value:function _clearCache(){this.data=null}},{key:"_reset",value:function _reset(){this.cookieName=Nt,this.data=null}}])}(),b=new Ft;var xc=/[=;,"\\\s\x00-\x1f\x7f]/,B=function B(t){var e=t.trim();return!e||xc.test(e)?null:e};var Br="ours_device_id",be=Br,qt=function qt(){return be},Ve=function Ve(t){if(typeof t!="string")return;var e=B(t);if(e){if(be===e)return;
2be!==Br&&g.warn("[sdk] device_id cookie name is changing from \"".concat(be,"\" to \"").concat(e,"\". Previously stored identity may be orphaned.")),be=e}};var zr=St(G());var y=[];for(var t=0;t<256;++t)y.push((t+256).toString(16).slice(1));function Xr(t){var e=arguments.length>1&&arguments[1]!==undefined?arguments[1]:0;return(y[t[e+0]]+y[t[e+1]]+y[t[e+2]]+y[t[e+3]]+"-"+y[t[e+4]]+y[t[e+5]]+"-"+y[t[e+6]]+y[t[e+7]]+"-"+y[t[e+8]]+y[t[e+9]]+"-"+y[t[e+10]]+y[t[e+11]]+y[t[e+12]]+y[t[e+13]]+y[t[e+14]]+y[t[e+15]]).toLowerCase()}var Pc=new Uint8Array(16);function Ut(){return crypto.getRandomValues(Pc)}function Ic(t,e,r){return!e&&!t&&crypto.randomUUID?crypto.randomUUID():Dc(t,e,r)}function Dc(t,e,r){var i,o,s;t=t||{};var n=(s=(o=t.random)!=null?o:(i=t.rng)==null?void 0:i.call(t))!=null?s:Ut();if(n.length<16)throw new Error("Random bytes length must be >= 16");if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,e){if(r=r||0,r<0||r+16>e.length)throw new RangeError("UUID byte range ".concat(r,":").concat(r+15," is out of buffer bounds"));for(var c=0;c<16;++c)e[r+c]=n[c];return e}return Xr(n)}var R=Ic;var jt=_createClass(function jt(){_classCallCheck(this,jt);this.testToken=null;this.userId=null;this.sessionId=null;if((typeof window==="undefined"?"undefined":_typeof(window))>"u")return;var e=new URLSearchParams(window.location.search);this.testToken=e.get("ours_test_token"),this.userId=e.get("ours_visitor_id")||e.get("ours_user_id"),this.sessionId=e.get("ours_session_id")}),Q=new jt;var L=function L(t){var e=qt();Ue(e,t),je(e,t),Oe.set(t)},T=function T(){if(Oe.get())return Oe.get();var t=Q.userId;if(t)return F.set(!0),L(t),t;var e=qt(),r=V(e);if(r)return L(r),r;var n=C(e);if(n)return L(n),n;var i=R();return L(i),i},He=function He(t){var e=(0,zr["default"])(t)&&"user_id"in t?t.user_id:void 0;if(e){if(typeof e!="string"||e.length<3){g.warn("[sdk]The user_id passed into init is too short");return}return F.set(!0),L(e),e}};var Vt=function(){function Vt(){_classCallCheck(this,Vt);this.sid=null;this.wasReset=!1;this.lastActivityAt=null;this.hasPinnedQueryParamSessionId=!1;this.SESSION_IDLE_MS=1800*1e3;this.SESSION_MAX_AGE_MS=360*60*1e3;this.ACTIVITY_PERSIST_INTERVAL_MS=30*1e3;this.SESSION_PREFIX="sid_";this.wasInitialized=!1}return _createClass(Vt,[{key:"initializeSessionId",value:function initializeSessionId(){var e=Date.now(),r=Q.sessionId;if(r){this.hasPinnedQueryParamSessionId=!0,this.sid="".concat(this.SESSION_PREFIX).concat(r),b.setSessionId(this.sid),this.touchSessionActivity(e,!0);return}var n=b.getSessionId();if(!n){this.resetSessionId(e);return}if(this.sid=n,this.shouldResetSession(n,e)){this.resetSessionId(e);return}this.touchSessionActivity(e,!0)}},{key:"generateSessionId",value:function generateSessionId(){var e=Date.now();return"".concat(this.SESSION_PREFIX).concat(e)}},{key:"resetSessionId",value:function resetSessionId(e){this.sid=this.generateSessionId(),this.wasReset=!0,b.setSessionId(this.sid),this.touchSessionActivity(e,!0),this.syncReplaySessionId()}},{key:"getSessionEpoch",value:function getSessionEpoch(e){var r=parseInt(e.replace(this.SESSION_PREFIX,""),10);return isNaN(r)?null:r}},{key:"getStoredLastActivity",value:function getStoredLastActivity(){var e=b.getSessionLastActivity(),r=e?parseInt(e,10):NaN,n=isNaN(r)?null:r;return this.lastActivityAt===null?n:n===null?this.lastActivityAt:Math.max(this.lastActivityAt,n)}},{key:"shouldResetSession",value:function shouldResetSession(e,r){var o;var n=this.getSessionEpoch(e);if(n===null)return!0;var i=(o=this.getStoredLastActivity())!=null?o:n;return r-n>this.SESSION_MAX_AGE_MS||r-i>this.SESSION_IDLE_MS}},{key:"touchSessionActivity",value:function touchSessionActivity(e){var r=arguments.length>1&&arguments[1]!==undefined?arguments[1]:!1;var n=this.getStoredLastActivity();this.lastActivityAt=e,(r||n===null||e-n>=this.ACTIVITY_PERSIST_INTERVAL_MS)&&b.setSessionLastActivity(e)}},{key:"ensureActiveSession",value:function ensureActiveSession(e){if(!this.wasInitialized){this.initializeSessionId(),this.wasInitialized=!0;return}if(!this.sid){this.initializeSessionId();return}if(this.hasPinnedQueryParamSessionId){e&&this.touchSessionActivity(Date.now());return}var r=Date.now();if(this.shouldResetSession(this.sid,r)){this.resetSessionId(r);return}e&&this.touchSessionActivity(r)}},{key:"syncReplaySessionId",value:function syncReplaySessionId(){try{window.ours_replay&&typeof window.ours_replay.setSessionId=="function"&&this.sid&&window.ours_replay.setSessionId(this.sid.replace(this.SESSION_PREFIX,""))}catch(e){}}},{key:"getSessionId",value:function getSessionId(){return this.ensureActiveSession(!0),this.sid?this.sid.replace(this.SESSION_PREFIX,""):""}},{key:"wasSessionReset",value:function wasSessionReset(){this.ensureActiveSession(!1);var e=this.wasReset;return this.wasReset=!1,e}}])}(),Kr=new Vt,H=function H(){return Kr.getSessionId()},Yr=function Yr(){return Kr.wasSessionReset()};var Qr={isTestToken:function isTestToken(t){return t.startsWith("test_")},fromTestToken:function fromTestToken(t){return this.isTestToken(t)?t.replace("test_",""):t},toTestToken:function toTestToken(t){if(this.isTestToken(t))throw new Error("Token is already a test token");return"test_".concat(t)}};var Ht=function(){function Ht(){_classCallCheck(this,Ht);this.token=null;this.tokenSetFromParams=!1;var e=Q.testToken,r=de("ours_token_set_from_params"),n=e||r;n&&(this.token=n,this.tokenSetFromParams=!0,K("ours_token_set_from_params",n),g.warn("[sdk]A test token is being used. So, events will save in the dashboard but not be dispatched"))}return _createClass(Ht,[{key:"setToken",value:function setToken(e){if(!this.tokenSetFromParams){if(!e||e==="null"||e==="undefined"){g.warn("[sdk]Falsy token provided to setToken");return}e.length>=32&&g.warn("[sdk]Token length is gte 32. This seems unlikely. Please ensure you are including the correct token."),Qr.isTestToken(e)&&g.warn("[sdk]A test token is being used. So, events will save in the dashboard but not be dispatched"),this.token=e}}},{key:"reset",value:function reset(){this.token=null,this.tokenSetFromParams=!1,K("ours_token_set_from_params","")}}])}
2(),Zr=new Ht,N=function N(){return Zr.token},We=function We(t){Zr.setToken(t)};var Oc=function Oc(t){var e=new Set;var _iterator5=_createForOfIteratorHelper(t!=null?t:[]),_step5;try{for(_iterator5.s();!(_step5=_iterator5.n()).done;){var r=_step5.value;if(typeof r!="string")continue;var n=r.trim().toLowerCase();n&&e.add(n)}}catch(err){_iterator5.e(err)}finally{_iterator5.f()}return e},Jr=function Jr(t){return t.trim().toLowerCase().replace(/^(?:#?0?38;)+/,"")},Rc=function Rc(t){var e=t.indexOf("="),r=e===-1?t:t.slice(0,e);try{return Jr(decodeURIComponent(r))}catch(n){return Jr(r)}},Wt=function Wt(t,e,r){var n=t.split("&"),i=!1;return{rebuilt:n.filter(function(s){if(!s)return!0;var c=Rc(s);return!s.includes("=")&&!(r!=null&&r.matchValuelessSegments)?!0:e.has(c)?(i=!0,!1):!0}).join("&"),removedAny:i}},Mc=function Mc(t,e){var r=t.indexOf("?");if(r===-1)return{rebuilt:t,removedAny:!1};var n=t.slice(0,r),i=t.slice(r+1);if(!i)return{rebuilt:t,removedAny:!1};var o=Wt(i,e);return o.removedAny?o.rebuilt?{rebuilt:"".concat(n,"?").concat(o.rebuilt),removedAny:!0}:{rebuilt:n,removedAny:!0}:{rebuilt:t,removedAny:!1}},Lc=function Lc(t,e){if(!t)return{rebuilt:t,removedAny:!1};var r=t.indexOf("?"),n=t.indexOf("=");if(r!==-1&&(n===-1||r<n)){var o=t.slice(0,r),s=t.slice(r+1);if(!s)return{rebuilt:t,removedAny:!1};var c=Wt(s,e,{matchValuelessSegments:!0});return c.removedAny?c.rebuilt?{rebuilt:"".concat(o,"?").concat(c.rebuilt),removedAny:!0}:{rebuilt:o,removedAny:!0}:{rebuilt:t,removedAny:!1}}return t.includes("=")?Wt(t,e):{rebuilt:t,removedAny:!1}},en=function en(t,e){var r=Oc(e);if(r.size===0)return t;var n=t.indexOf("#"),i=n===-1?t:t.slice(0,n),o=n===-1?"":t.slice(n+1),s=Mc(i,r),c=n===-1?{rebuilt:"",removedAny:!1}:Lc(o,r);return!s.removedAny&&!c.removedAny?t:n===-1?s.rebuilt:c.removedAny?"".concat(s.rebuilt,"#").concat(c.rebuilt):"".concat(s.rebuilt,"#").concat(o)};var Z=function Z(t,e){return en(t,e)},Nc=function Nc(t){return Z(window.location.href,t)},$e=function $e(){return Nc(p.getUrlQueryParamsBlocklist())},Fc=function Fc(t){return Z(document.referrer,t)},tn=function tn(){return Fc(p.getUrlQueryParamsBlocklist())};var qc=function qc(){var n,i;var _p$getIngestEndpoints=p.getIngestEndpoints(),_p$getIngestEndpoints2=_slicedToArray(_p$getIngestEndpoints,2),t=_p$getIngestEndpoints2[0],e=_p$getIngestEndpoints2[1];return!t||!e?t:((i=(n=window.ours_data)==null?void 0:n.failed_primary_ingest_endpoint)!=null?i:null)===t.toString()?e:t},rn=function rn(t,e){var r,n;try{if(!z.get())return!1;var i=N();if(!i)return!1;var o=qc();if(!o)return!1;var s=new URL(o.toString());s.pathname="ingest";var c=s.toString(),l={defaultProperties:{current_url:$e(),host:window.location.host,pathname:window.location.pathname,sid:H(),user_agent:navigator.userAgent},distinct_id:R(),event:t,eventProperties:e!=null?e:{},userProperties:{},visitor_id:T()},u=JSON.stringify({data:[l],token:i,is_manually_set_id:F.get()});if((typeof navigator==="undefined"?"undefined":_typeof(navigator))<"u"&&typeof navigator.sendBeacon=="function"){var m=new Blob([u],{type:"text/plain;charset=UTF-8"});if(navigator.sendBeacon(c,m))return!0}return fetch(c,{body:u,credentials:"include",keepalive:!0,method:"POST"})["catch"](function(){}),!0}catch(i){return(n=(r=g).debug)==null||n.call(r,"[sdk]fireEventNow failed",i),!1}};var nn=function nn(t){var i,o;var e=t[1];if(typeof e!="string")return!1;var r=e.trim();if(!r||r==="187645735503476")return!1;var n=t[2];if(We(r),Ve((i=n==null?void 0:n.cookie_names)==null?void 0:i.device_id),typeof((o=n==null?void 0:n.cookie_names)==null?void 0:o.sdk_data)=="string"){var s=B(n.cookie_names.sdk_data);s&&b.configure(s)}return He(n),!0},on=function on(t){var n;var e=!1,_r3=function r(){for(var _len5=arguments.length,i=new Array(_len5),_key5=0;_key5<_len5;_key5++){i[_key5]=arguments[_key5]}i[0]==="init"&&nn(i)&&(e=!0),_r3.queue.push(i),t==null||t()};_r3.queue=((n=window.ours)==null?void 0:n.queue)||[],_r3.version="1.0";var _iterator6=_createForOfIteratorHelper(_r3.queue),_step6;try{for(_iterator6.s();!(_step6=_iterator6.n()).done;){var i=_step6.value;i[0]==="init"&&nn(i)&&(e=!0)}}catch(err){_iterator6.e(err)}finally{_iterator6.f()}return _r3.getVisitorId=function(){if(!e||!N())throw new Error("Ours SDK not initialized");return T()},_r3.getSessionId=function(){if(!e||!N())throw new Error("Ours SDK not initialized");return H()},_r3.trackNow=function(i,o){return rn(i,o)},window.ours=_r3,window.ours_data=window.ours_data||{},window.oursLayer=window.oursLayer||[],_r3};var sn=function sn(t){return t===null};var an=function an(t){return t===void 0};var cn=function cn(t){return sn(t)||an(t)};var Be=function Be(t){return!cn(t)};function ln(){var t;try{return(typeof window==="undefined"?"undefined":_typeof(window))>"u"||window.self===window.top||(t=window.top)==null||t.location.href,!1}catch(e){return!0}}var ca=St(pr());var O={PAGE_VIEW:"page_view",SCROLL:"scroll",USER_ENGAGEMENT:"user_engagement",VIEW_SEARCH_RESULTS:"view_search_results",CLICK:"click",LINK_CLICK:"$link_click",FILE_DOWNLOAD:"file_download",FORM_START:"form_start",FORM_SUBMIT:"form_submit",VIDEO_START:"video_start",VIDEO_PROGRESS:"video_progress",VIDEO_COMPLETE:"video_complete"},Wy=Object.values(O);var it=function(){function it(){_classCallCheck(this,it);this.activeStartTimestamp=Date.now();this.accumulatedActiveTime=0;this.lastActiveDuration=null;this.eventCount=0;document.addEventListener("visibilitychange",this.handleVisibilityChange.bind(this))}return _createClass(it,[{key:"handleVisibilityChange",value:function handleVisibilityChange(){document.hidden?this.accumulatedActiveTime+=Date.now()-this.activeStartTimestamp:this.activeStartTimestamp=Date.now()}},{key:"getCurrentDuration",value:function getCurrentDuration(){var e=this.accumulatedActiveTime;return document.hidden||(e+=Date.now()-this.activeStartTimestamp),e}},{key:"recordEvent",value:function recordEvent(){this.eventCount++,this.lastActiveDuration=this.getCurrentDuration()}}
2,{key:"getEventCount",value:function getEventCount(){return this.eventCount}},{key:"getTimeSinceLastEvent",value:function getTimeSinceLastEvent(){return this.lastActiveDuration===null?void 0:{_et:this.getCurrentDuration()-this.lastActiveDuration}}},{key:"isTimeSinceLastEventAtLeast",value:function isTimeSinceLastEventAtLeast(e){var r=this.getTimeSinceLastEvent();return r?r._et>=e:!1}}])}();var gr=function gr(t,e){return t.length>e?t.slice(0,e):t};var ot=function(){function ot(e){_classCallCheck(this,ot);this.currentPath="";this.hasFiredScroll=!1;this.hasFiredAPageView=!1;this.interactedForms=new Set;this.eventHandlers=[];this.eventQueue=[];this.MIN_ENGAGEMENT_TIME_MS=1e4;this.searchParams=e!=null?e:["q","s","search","query","keyword","term"],this.timeTracker=new it,this.init()}return _createClass(ot,[{key:"init",value:function init(){this.trackPageView(),this.listenForRouteChanges(),this.listenForScroll(),this.listenForOutboundClicks(),this.listenForLinkClicks(),this.listenForFileDownloads(),this.listenForFormEvents(),this.listenForUserEngagement()}},{key:"isFirstVisit",value:function isFirstVisit(){return b.getFirstVisit()?!1:(b.setFirstVisit(Date.now()),!0)}},{key:"trackPageView",value:function trackPageView(){var e=location.pathname+location.search;if(e!==this.currentPath){this.currentPath=e,this.hasFiredScroll=!1;var r={is_first_visit:this.isFirstVisit(),is_new_session:Yr(),has_fired_a_page_view:this.hasFiredAPageView,is_spa_navigation:this.hasFiredAPageView};if(this.hasFiredAPageView){var n=this.timeTracker.getTimeSinceLastEvent();n&&Object.assign(r,n)}this.track(O.PAGE_VIEW,r),this.hasFiredAPageView=!0,this.checkSearchParam()}}},{key:"checkSearchParam",value:function checkSearchParam(){var e=new URL(location.href);var _iterator7=_createForOfIteratorHelper(this.searchParams),_step7;try{for(_iterator7.s();!(_step7=_iterator7.n()).done;){var r=_step7.value;var n=e.searchParams.get(r);if(n){var i=d({search_term:n,search_parameter:r,page_location:e.href},this.getEngagementTimeSinceLastEvent());this.setEngagedSession(),this.track(O.VIEW_SEARCH_RESULTS,i);break}}}catch(err){_iterator7.e(err)}finally{_iterator7.f()}}},{key:"listenForRouteChanges",value:function listenForRouteChanges(){var _this=this;var e=function e(){return _this.trackPageView()},r=history.pushState;history.pushState=function(){for(var _len6=arguments.length,n=new Array(_len6),_key6=0;_key6<_len6;_key6++){n[_key6]=arguments[_key6]}r.apply(history,n),setTimeout(function(){return _this.trackPageView()},0)},window.addEventListener("popstate",e),this.eventHandlers.push(function(){return window.removeEventListener("popstate",e)})}},{key:"listenForScroll",value:function listenForScroll(){var _this2=this;var e=function e(){if(_this2.hasFiredScroll)return;var r=window.scrollY+window.innerHeight,n=document.documentElement.scrollHeight;if(r/n>=.9){_this2.hasFiredScroll=!0;var i=d({percent_scrolled:90},_this2.getEngagementTimeSinceLastEvent());_this2.setEngagedSession(),_this2.track(O.SCROLL,i)}};e(),window.addEventListener("scroll",e,{passive:!0}),this.eventHandlers.push(function(){return window.removeEventListener("scroll",e)})}},{key:"listenForOutboundClicks",value:function listenForOutboundClicks(){var _this3=this;var e=function e(r){var n=p.getEnhancedWebEvents(),i=r.target.closest("a");if(!i||!i.href)return;var o=new URL(i.href);if(!(o.hostname!==location.hostname||["mailto:","tel:"].includes(o.protocol)))return;var c=d(d({link_url:Z(o.href,p.getUrlQueryParamsBlocklist()),link_domain:o.hostname,outbound:!0,protocol:o.protocol.replace(":","")},n?{click_text:gr((i.textContent||"").trim(),1e3)}:{}),_this3.getEngagementTimeSinceLastEvent());_this3.setEngagedSession(),_this3.track(O.CLICK,c)};document.addEventListener("click",e),this.eventHandlers.push(function(){return document.removeEventListener("click",e)})}},{key:"listenForLinkClicks",value:function listenForLinkClicks(){var _this4=this;var e=function e(r){var n=p.getEnhancedWebEvents(),i=r.target.closest("a");if(!i||!i.href)return;var o=new URL(i.href),s=o.hostname!==location.hostname||["mailto:","tel:"].includes(o.protocol),c=d(d({link_url:Z(o.href,p.getUrlQueryParamsBlocklist()),link_domain:o.hostname,link_id:i.id||void 0,link_classes:i.className||void 0,outbound:s},n?{link_text:gr((i.textContent||"").trim(),1e3)}:{}),_this4.getEngagementTimeSinceLastEvent());_this4.setEngagedSession(),_this4.track(O.LINK_CLICK,c)};document.addEventListener("click",e),this.eventHandlers.push(function(){return document.removeEventListener("click",e)})}},{key:"listenForFileDownloads",value:function listenForFileDownloads(){var _this5=this;var e=["pdf","doc","docx","xls","xlsx","ppt","pptx","csv","zip","rar","7z","mp4","mov","avi","txt","json","xml","exe","apk","msi","dmg"],r=function r(n){var l;var i=n.target.closest("a");if(!i||!i.href)return;var o=new URL(i.href),s=(l=o.pathname.split(".").pop())==null?void 0:l.toLowerCase();if(!s||!e.includes(s))return;var c=d({file_name:o.pathname.split("/").pop(),file_extension:s,link_url:Z(o.href,p.getUrlQueryParamsBlocklist())},_this5.getEngagementTimeSinceLastEvent());_this5.setEngagedSession(),_this5.track(O.FILE_DOWNLOAD,c)};document.addEventListener("click",r),this.eventHandlers.push(function(){return document.removeEventListener("click",r)}
2)}},{key:"listenForFormEvents",value:function listenForFormEvents(){var _this6=this;var e=function e(n){if(!(n.target instanceof Element))return;var i=n.target.closest("form");if(!i)return;var o="".concat(i.action,"|").concat(i.id,"|").concat(i.getAttribute("name"));if(_this6.interactedForms.has(o))return;_this6.interactedForms.add(o);var s=d({form_id:i.id||void 0,form_name:i.getAttribute("name")||void 0,page_location:location.href},_this6.getEngagementTimeSinceLastEvent());_this6.setEngagedSession(),_this6.track(O.FORM_START,s)},r=function r(n){var i=n.target;if(!i)return;var o=d({form_id:i.id||void 0,form_name:i.getAttribute("name")||void 0,page_location:location.href},_this6.getEngagementTimeSinceLastEvent());_this6.setEngagedSession(),_this6.track(O.FORM_SUBMIT,o)};document.addEventListener("focusin",e),document.addEventListener("submit",r),this.eventHandlers.push(function(){return document.removeEventListener("focusin",e)}),this.eventHandlers.push(function(){return document.removeEventListener("submit",r)})}},{key:"listenForUserEngagement",value:function listenForUserEngagement(){var _this7=this;var e=function e(){(_this7.isEngagedSession()||_this7.timeTracker.getEventCount()===1&&_this7.timeTracker.isTimeSinceLastEventAtLeast(_this7.MIN_ENGAGEMENT_TIME_MS))&&_this7.track(O.USER_ENGAGEMENT,d({},_this7.timeTracker.getTimeSinceLastEvent()))};window.addEventListener("beforeunload",e),this.eventHandlers.push(function(){return window.removeEventListener("beforeunload",e)})}},{key:"resetScrollTracking",value:function resetScrollTracking(){this.hasFiredScroll=!1}},{key:"destroy",value:function destroy(){this.eventHandlers.forEach(function(e){return e()}),this.eventHandlers.length=0}},{key:"getEventQueue",value:function getEventQueue(){var e=(0,ca["default"])(this.eventQueue);return this.eventQueue.length=0,p.getIsDebugMode()&&e.forEach(function(_ref){var _ref2=_slicedToArray(_ref,2),n=_ref2[1];n.debug_mode="true"}),e}},{key:"getEngagementTimeSinceLastEvent",value:function getEngagementTimeSinceLastEvent(){return this.timeTracker.getTimeSinceLastEvent()}},{key:"setEngagedSession",value:function setEngagedSession(){b.setEngagedSession(!0)}},{key:"isEngagedSession",value:function isEngagedSession(){return b.getEngagedSession()==="true"}},{key:"track",value:function track(e,r){r.is_engaged_session=this.isEngagedSession()?1:0,this.timeTracker.recordEvent(),this.eventQueue.push([e,r])}}])}();var st=new Map,at=function(){function at(e){_classCallCheck(this,at);this.isLoaded=!1;this.token=e}return _createClass(at,[{key:"load",value:function(){var _load=_asyncToGenerator(_regenerator().m(function _callee(){var e,r,_t2;return _regenerator().w(function(_context){while(1)switch(_context.p=_context.n){case 0:if(!this.isLoaded){_context.n=1;break}g.debug("[sdk]Experimentation runtime already loaded");return _context.a(2);case 1:_context.p=1;e=T(),r=p.getIngestDomain();r.pathname="experiment-init";r.searchParams.append("token",this.token);r.searchParams.append("visitor_id",e);g.debug("[sdk]Loading experimentation script",{url:r.toString()});_context.n=2;return this.loadScript(r.toString());case 2:this.initRuntime(e);this.isLoaded=!0;g.debug("[sdk]Experimentation script loaded successfully");_context.n=4;break;case 3:_context.p=3;_t2=_context.v;throw g.error("[sdk]Error loading experimentation script",_t2),_t2;case 4:return _context.a(2)}},_callee,this,[[1,3]])}));function load(){return _load.apply(this,arguments)}return load}()},{key:"isRuntimeReady",value:function isRuntimeReady(){var e=window.ours_experiments;return typeof(e==null?void 0:e.init)=="function"}},{key:"loadScript",value:function loadScript(e){if(this.isRuntimeReady())return Promise.resolve();var r=st.get(e);if(r)return r;var n=Array.from(document.getElementsByTagName("script")).find(function(o){return o.src===e});n!=null&&n.parentNode&&n.parentNode.removeChild(n);var i=new Promise(function(o,s){var c=function c(){st["delete"](e),o()},l=function l(){st["delete"](e),s(new Error("Failed to load script: ".concat(e)))},u=document.createElement("script");u.src=e,u.async=!0,u.onload=function(){return c()},u.onerror=function(){return l()},document.head.appendChild(u)});return st.set(e,i),i}},{key:"initRuntime",value:function initRuntime(e){var i;var r=window.ours_experiments;if(!r||typeof r.init!="function")throw new Error("Experimentation script did not expose window.ours_experiments.init");var n=T();r.init(_(d({visitorId:n},e!==n?{discardPersonalization:!0}:{}),{cdpToken:(i=N())!=null?i:void 0,ingestDomain:p.getIngestDomain().origin}))}}])}();var lt=function(){function lt(e){_classCallCheck(this,lt);this.isLoaded=!1;this.loadPromise=null;this.token=e}return _createClass(lt,[{key:"initialize",value:function(){var _initialize=_asyncToGenerator(_regenerator().m(function _callee2(){var _this8=this;var e,_t3;return _regenerator().w(function(_context2){while(1)switch(_context2.p=_context2.n){case 0:if(!this.isLoaded){_context2.n=1;break}g.debug("[sdk]Session replay already loaded");return _context2.a(2);case 1:if(!this.loadPromise){_context2.n=3;break}_context2.n=2;return this.loadPromise;case 2:return _context2.a(2);case 3:_context2.p=3;e=p.getIngestDomain();e.pathname="replay-init";e.searchParams.append("token",this.token);g.debug("[sdk]Loading session replay script",{url:e.toString()});this.loadPromise=this.loadScript(e.toString()).then(function(){return _this8.waitForReplaySdk()}).then(function(){_this8.isLoaded=!0,g.debug("[sdk]Session replay script loaded successfully")})["finally"](function(){_this8.loadPromise=null});_context2.n=4;return this.loadPromise;case 4:_context2.n=6;break;case 5:_context2.p=5;_t3=_context2.v;g.debug("[sdk]Error loading session replay script",_t3);case 6:return _context2.a(2)}},_callee2,this,[[3,5]])}));function initialize(){return _initialize.apply(this,arguments)}return initialize}()}
2,{key:"start",value:function start(){if(!this.isLoaded){g.warn("[sdk]Session replay not loaded, cannot start");return}try{window.ours_replay&&typeof window.ours_replay.start=="function"?(window.ours_replay.start(),g.debug("[sdk]Session replay started")):g.warn("[sdk]Session replay not available on window.ours_replay")}catch(e){g.error("[sdk]Error starting session replay",e)}}},{key:"init",value:function init(e,r,n){if(!this.isLoaded){g.warn("[sdk]Session replay not loaded, cannot initialize");return}try{window.ours_replay&&typeof window.ours_replay.init=="function"?(window.ours_replay.init(d(d(d(d(d(d(d(d(d({visitor_id:e,session_id:r},(n==null?void 0:n.mask_all_text)!==void 0?{maskAllText:n.mask_all_text}:{}),(n==null?void 0:n.sampleRate)!==void 0?{sampleRate:n.sampleRate}:{}),(n==null?void 0:n.alwaysRecordEvents)!==void 0?{alwaysRecordEvents:n.alwaysRecordEvents}:{}),(n==null?void 0:n.sampledIn)!==void 0?{sampledIn:n.sampledIn}:{}),(n==null?void 0:n.block_selector)!==void 0?{blockSelector:n.block_selector}:{}),(n==null?void 0:n.ignore_selector)!==void 0?{ignoreSelector:n.ignore_selector}:{}),(n==null?void 0:n.mask_text_selector)!==void 0?{maskTextSelector:n.mask_text_selector}:{}),(n==null?void 0:n.recordOnPaths)!==void 0?{recordOnPaths:n.recordOnPaths}:{}),(n==null?void 0:n.excludePaths)!==void 0?{excludePaths:n.excludePaths}:{})),g.debug("[sdk]Session replay initialized",{visitorId:e,sessionId:r,mask_all_text:n==null?void 0:n.mask_all_text})):g.warn("[sdk]Session replay not available on window.ours_replay")}catch(i){g.error("[sdk]Error initializing session replay",i)}}},{key:"loadAndInit",value:function(){var _loadAndInit=_asyncToGenerator(_regenerator().m(function _callee3(e){var r,n,_t4;return _regenerator().w(function(_context3){while(1)switch(_context3.p=_context3.n){case 0:_context3.p=0;_context3.n=1;return this.initialize();case 1:r=T(),n=H();return _context3.a(2,r&&n?(this.init(r,n,{mask_all_text:e==null?void 0:e.mask_all_text,sampleRate:e==null?void 0:e.sampleRate,alwaysRecordEvents:e==null?void 0:e.alwaysRecordEvents,sampledIn:e==null?void 0:e.sampledIn,block_selector:e==null?void 0:e.block_selector,ignore_selector:e==null?void 0:e.ignore_selector,mask_text_selector:e==null?void 0:e.mask_text_selector,recordOnPaths:e==null?void 0:e.recordOnPaths,excludePaths:e==null?void 0:e.excludePaths}),!0):(g.warn("[sdk]Missing visitor_id or session_id for session replay initialization"),!1));case 2:_context3.p=2;_t4=_context3.v;return _context3.a(2,(g.debug("[sdk]Error in session replay loadAndInit",_t4),!1))}},_callee3,this,[[0,2]])}));function loadAndInit(_x){return _loadAndInit.apply(this,arguments)}return loadAndInit}()},{key:"loadScript",value:function loadScript(e){return new Promise(function(r,n){if(Array.from(document.getElementsByTagName("script")).find(function(s){return s.src===e})){r();return}var o=document.createElement("script");o.src=e,o.async=!0,o.onload=function(){return r()},o.onerror=function(){return n(new Error("Failed to load script: ".concat(e)))},document.head.appendChild(o)})}},{key:"waitForReplaySdk",value:function waitForReplaySdk(){return new Promise(function(e,r){var n=Date.now(),_i3=function i(){if(window.ours_replay&&typeof window.ours_replay.init=="function"){e();return}if(Date.now()-n>=lt.SDK_READY_TIMEOUT_MS){r(new Error("Session replay SDK did not initialize window.ours_replay"));return}window.setTimeout(_i3,25)};_i3()})}}])}();lt.SDK_READY_TIMEOUT_MS=1e4;var ct=lt;var ya=St(pr());var Ie={HEATMAP_CLICK:"$heatmap_click",HEATMAP_SCROLL:"$heatmap_scroll",RAGE_CLICK:"$rage_click",DEAD_CLICK:"$dead_click"};var De=function De(t){return t.map(function(e){var r=e+"=".repeat((4-e.length%4)%4);return atob(r)})};var lh=["dXRtX3NvdXJjZQ","dXRtX21lZGl1bQ","dXRtX2NhbXBhaWdu","dXRtX3Rlcm0","dXRtX2NvbnRlbnQ","dXRtX2lk","ZmJjbGlk","Z2NsaWQ","Z2Nsc3Jj","ZGNsaWQ","Z2JyYWlk","d2JyYWlk","bXNjbGtpZA","dHdjbGlk","bGlfZmF0X2lk","bWNfY2lk","bWNfZWlk","X2dh","X2ds","X2hzZW5j","X2hzbWk","aHNhX2NhbQ","aHNhX2dycA","aHNhX210","aHNhX3NyYw","aHNhX2Fk","aHNhX2FjYw","aHNhX25ldA","aHNhX3Zlcg","aHNhX2t3","aHNhX2xh","aHNhX29s","aHNhX3RndA","cmVm","cmVmXw","Z2FkX3NvdXJjZQ","Z2FkX2NhbXBhaWduaWQ"],uh=new Set(De([].concat(lh))),ut=function ut(t){try{var e=new URL(t);e.hash="",e.pathname.length>1&&e.pathname.endsWith("/")&&(e.pathname=e.pathname.slice(0,-1));var _iterator8=_createForOfIteratorHelper(uh),_step8;try{for(_iterator8.s();!(_step8=_iterator8.n()).done;){var n=_step8.value;e.searchParams["delete"](n)}}catch(err){_iterator8.e(err)}finally{_iterator8.f()}e.searchParams.sort();var r=e.searchParams.toString();return r?e.origin+e.pathname+"?"+r:e.origin+e.pathname}catch(e){return t}};var dt=function dt(t){return t<768?"mobile":t<1024?"tablet":"desktop"};var dh=/^[a-z][a-z0-9_-]{0,63}$/;function la(t){var r;var e=(r=t.getAttribute("data-cta"))==null?void 0:r.toLowerCase();return e&&dh.test(e)?e:null}var ua=function ua(t){var e;return t.id||t.getAttribute("data-heatmap-id")||la(t)?"high":t.getAttribute("role")||(e=t.parentElement)!=null&&e.id?"medium":"low"},mt=function mt(t){var e=[],r=t.tagName.toLowerCase();e.push(r);var n=t.getAttribute("role");n&&e.push("role=".concat(n));var i=t.id;i&&e.push("id=".concat(i));var o=t.getAttribute("data-heatmap-id");o&&e.push("hid=".concat(o));var s=la(t);s&&e.push("cta=".concat(s));var c=t.parentElement;if(c){var l=Array.from(c.children).filter(function(f){return f.tagName===t.tagName});if(l.length>1){var f=l.indexOf(t);e.push("nth=".concat(f+1))}var u=c.tagName.toLowerCase(),m=c.id;
2e.push("parent=".concat(u).concat(m?"#"+m:""))}return e.join(":")};var da=new Set(["A","BUTTON","INPUT","SELECT","TEXTAREA","SUMMARY","DETAILS"]),mh=new Set(["button","link","menuitem","tab","checkbox","radio","switch","option"]),ma=6,ph=[/tidio-chat/i,/intercom/i,/drift/i,/crisp/i,/zendesk/i],pa=function pa(t){if(t.parentElement)return t.parentElement;var e=t.getRootNode();return e instanceof ShadowRoot?e.host:null},gh=function gh(t){var e=t.tagName;if(e==="A"&&t.hasAttribute("href")||e==="INPUT"&&t.getAttribute("type")!=="hidden"||e==="LABEL"&&t.hasAttribute("for")||da.has(e)&&e!=="A"&&e!=="INPUT"&&e!=="LABEL")return"semantic";var r=t.getAttribute("role");if(r&&mh.has(r)&&t.getAttribute("aria-disabled")!=="true")return"semantic";var n=t.getAttribute("tabindex");return n&&n!=="-1"&&(r||da.has(e))&&t.getAttribute("aria-disabled")!=="true"?"semantic":t.hasAttribute("onclick")||t.hasAttribute("data-action")?"heuristic":null},ga=function ga(t){var e=t,r=0;for(;e&&r<=ma;){var n=gh(e);if(n)return{element:e,depth:r,kind:n,deadClickEligible:n==="semantic"};e=pa(e),r++}return null};var fa=function fa(t){if(fh(t))return!0;var e=t,r=0;for(;e&&r<=ma;){if(hh(e))return!0;var i=e.getAttribute("contenteditable");if(i!==null&&i!=="false"||e.getAttribute("data-heatmap-ignore-dead-click")==="true"||e.getAttribute("draggable")==="true")return!0;e=pa(e),r++}var n=window.getSelection();return!!(n&&n.toString().length>0)},fh=function fh(t){try{return t.ownerDocument!==document}catch(e){return!0}},hh=function hh(t){var e=[t.id];typeof t.className=="string"&&e.push(t.className);var r=e.filter(Boolean).join(" ");return ph.some(function(n){return n.test(r)})};var fr=function fr(t){return t==="touch"||t==="pen"},pt=function(){function pt(){_classCallCheck(this,pt);this.startX=0;this.startY=0;this.startTarget=null;this.activeSources=new Set;this.gestureMoved=!1;this.gestureEndedAt=0;this.lastMovementTimestamp=0;this.lastMovementTarget=null;this.cleanupHandlers=[]}return _createClass(pt,[{key:"attach",value:function attach(){var _this9=this;if(this.cleanupHandlers.length>0)return;var e=function e(u){var w;var f=(w=u.touches)==null?void 0:w[0];f&&_this9.beginGesture("touch",f.clientX,f.clientY,u.target)},r=function r(u){var w;if(!_this9.activeSources.has("touch"))return;var f=(w=u.touches)==null?void 0:w[0];f&&_this9.maybeRegisterMovement(f.clientX,f.clientY)},n=function n(){return _this9.endGesture("touch")},i=function i(){return _this9.endGesture("touch",!0)},o=function o(u){var m=u;fr(m.pointerType)&&m.isPrimary!==!1&&_this9.beginGesture("pointer",m.clientX,m.clientY,u.target)},s=function s(u){if(!_this9.activeSources.has("pointer"))return;var m=u;fr(m.pointerType)&&m.isPrimary!==!1&&_this9.maybeRegisterMovement(m.clientX,m.clientY)},c=function c(u){var m=u;!fr(m.pointerType)||m.isPrimary===!1||_this9.endGesture("pointer",u.type==="pointercancel")},l=[["touchstart",e],["touchmove",r],["touchend",n],["touchcancel",i],["pointerdown",o],["pointermove",s],["pointerup",c],["pointercancel",c]];var _loop2=function _loop2(){var _l4$_i=_slicedToArray(_l4[_i4],2),u=_l4$_i[0],m=_l4$_i[1];document.addEventListener(u,m,{capture:!0,passive:!0}),_this9.cleanupHandlers.push(function(){return document.removeEventListener(u,m,{capture:!0})})};for(var _i4=0,_l4=l;_i4<_l4.length;_i4++){_loop2()}}},{key:"detach",value:function detach(){var _iterator9=_createForOfIteratorHelper(this.cleanupHandlers),_step9;try{for(_iterator9.s();!(_step9=_iterator9.n()).done;){var e=_step9.value;e()}}catch(err){_iterator9.e(err)}finally{_iterator9.f()}this.cleanupHandlers=[],this.activeSources.clear(),this.gestureMoved=!1}},{key:"shouldSuppressClick",value:function shouldSuppressClick(e){var r=arguments.length>1&&arguments[1]!==undefined?arguments[1]:Date.now();var n=this.lastMovementTarget;return!this.gestureMoved||!n||r-Math.max(this.lastMovementTimestamp,this.gestureEndedAt)>=1500?!1:!!(e===n||n.contains(e)||e.contains(n))}},{key:"hasRecentMovement",value:function hasRecentMovement(){var e=arguments.length>0&&arguments[0]!==undefined?arguments[0]:Date.now();return e-this.lastMovementTimestamp<1500}},{key:"beginGesture",value:function beginGesture(e,r,n,i){this.activeSources.size===0&&(this.startX=r,this.startY=n,this.startTarget=i,this.gestureMoved=!1,this.gestureEndedAt=0),this.activeSources.add(e)}},{key:"endGesture",value:function endGesture(e){var r=arguments.length>1&&arguments[1]!==undefined?arguments[1]:!1;this.activeSources["delete"](e)&&(r&&(this.gestureMoved=!0,this.lastMovementTimestamp=Date.now(),this.lastMovementTarget=this.startTarget),this.activeSources.size===0&&(this.gestureEndedAt=Date.now()))}},{key:"maybeRegisterMovement",value:function maybeRegisterMovement(e,r){var n=e-this.startX,i=r-this.startY;Math.hypot(n,i)<=6||(this.gestureMoved=!0,this.lastMovementTimestamp=Date.now(),this.lastMovementTarget=this.startTarget)}}])}();var ha=64,va=800,vh=5,bh=10,ba=2e3,_h=5,yh=1e4,wh=350,Eh=3,_a=["input","change","toggle"],Sh=400,ce=function ce(t){return Math.min(.999999,Math.max(0,t))}
2,gt=function(){function gt(){_classCallCheck(this,gt);this.eventHandlers=[];this.eventQueue=[];this.gestureTracker=new pt;this.maxScrollY=0;this.maxElementScrollNorm=0;this.currentPageKey="";this.currentPathname="";this.currentSearch="";this.hasEmittedScrollForPage=!1;this.lastEmittedMaxScrollNorm=-1;this.clickBuffer=[];this.rageClickFired=!1;this.pendingMobileClickTimer=null;this.pendingMobileClickEvent=null;this.pendingMobileClickTarget=null;this.pendingMobileClickElementFingerprint="";this.pendingMobileClickBinX=0;this.pendingMobileClickBinY=0;this.pendingMobileClickMutationObserver=null;this.pendingMobileClickFocusHandler=null;this.pendingMobileClickScrollHandler=null;this.pendingMobileClickScrollX=0;this.pendingMobileClickScrollY=0;this.pendingMobileClickResponseObserved=!1;this.deadClickCount=0;this.deadClickDedupeMap=new Map;this.pendingDeadClickTimer=null;this.pendingDeadClickEvent=null;this.pendingDeadClickTarget=null;this.pendingFocusHandler=null;this.pendingScrollHandler=null;this.pendingNativeResponseHandler=null;this.pendingDeadClickScrollX=0;this.pendingDeadClickScrollY=0;this.deadClickMutationObserver=null;this.deadClickLocationHref="";this.lastNavigationTimestamp=0;this.historyChangedDuringWindow=!1;this.originalPushState=null;this.originalReplaceState=null;this.originalWindowOpen=null;this.init()}return _createClass(gt,[{key:"init",value:function init(){this.resetPageState(),this.gestureTracker.attach(),this.listenForClicks(),this.listenForScroll(),this.listenForRouteChanges(),this.listenForWindowOpen()}},{key:"resetPageState",value:function resetPageState(){this.flushScrollData(),this.maxScrollY=0,this.maxElementScrollNorm=0,this.hasEmittedScrollForPage=!1,this.lastEmittedMaxScrollNorm=-1,this.currentPageKey=ut(location.href),this.currentPathname=location.pathname,this.currentSearch=location.search,this.deadClickCount=0,this.deadClickDedupeMap.clear(),this.dropPendingMobileClick(),this.cancelPendingDeadClick()}},{key:"listenForClicks",value:function listenForClicks(){var _this0=this;var e=function e(r){var Sr,kr,Cr,Tr;if(!r.isTrusted||r.button!==0||r.metaKey||r.ctrlKey||r.shiftKey||r.altKey)return;var n=r.target;if(!(n!=null&&n.tagName))return;var i=window.innerWidth,o=window.innerHeight,s=document.documentElement.scrollHeight,c=window.scrollY,l=ga(n),u=(Sr=l==null?void 0:l.element)!=null?Sr:n,m=dt(i);if(m==="mobile"&&_this0.gestureTracker.shouldSuppressClick(n))return;var f=ce(r.clientX/i),w=ce(r.clientY/o),E=ce(r.clientX/i),M=ce((c+r.clientY)/Math.max(1,s)),x=Math.floor(E*ha),k=Math.floor(M*ha),A=ut(location.href),yt=location.pathname,Ha=dt(i),Wa=mt(n),$a=n.getAttribute("data-heatmap-id")||null,wt=mt(u),Ba=l!==null,Ga=l?mt(l.element):null,Xa=(l==null?void 0:l.element.getAttribute("data-heatmap-id"))||null,za=(kr=l==null?void 0:l.deadClickEligible)!=null?kr:!1,Ka=l&&l.element!==n?"interactive_ancestor":"target",Er={page_key:A,pathname:yt,breakpoint:Ha,viewport_w:i,viewport_h:o,doc_h:s,x_norm:f,y_norm:w,x_doc_norm:E,y_doc_norm:M,scroll_y:c,element_tag:u.tagName,element_fingerprint:wt,data_heatmap_id:u.getAttribute("data-heatmap-id")||null,raw_element_tag:n.tagName,raw_element_fingerprint:Wa,raw_data_heatmap_id:$a,interactive_element_tag:(l==null?void 0:l.element.tagName)||null,interactive_element_fingerprint:Ga,interactive_data_heatmap_id:Xa,element_attribution_mode:Ka,interactive_element_depth:(Cr=l==null?void 0:l.depth)!=null?Cr:null,interactive_kind:(Tr=l==null?void 0:l.kind)!=null?Tr:null,is_interactive:Ba,dead_click_eligible:za};if(m==="mobile"&&l===null){_this0.queuePendingMobileClick(n,Er,wt,x,k);return}_this0.emitHeatmapClick(u,Er,wt,x,k,r)};document.addEventListener("click",e,{capture:!0,passive:!0}),this.eventHandlers.push(function(){return document.removeEventListener("click",e,{capture:!0})})}},{key:"checkRageClick",value:function checkRageClick(e,r,n,i){var _this1=this;var o=Date.now();this.clickBuffer.push({timestamp:o,binX:e,binY:r,elementFingerprint:n}),this.clickBuffer.length>bh&&this.clickBuffer.shift();var s=this.clickBuffer.filter(function(c){return o-c.timestamp<=va&&c.binX===e&&c.binY===r&&c.elementFingerprint===n});s.length>=vh&&!this.rageClickFired&&(this.rageClickFired=!0,this.track(Ie.RAGE_CLICK,_(d({},i),{click_count:s.length})),this.clickBuffer.length=0,setTimeout(function(){_this1.rageClickFired=!1},va))}},{key:"emitHeatmapClick",value:function emitHeatmapClick(e,r,n,i,o,s){var _this10=this;if(this.track(Ie.HEATMAP_CLICK,d({},r)),this.checkRageClick(i,o,n,r),r.dead_click_eligible){if(s&&this.shouldDeferDeadClickForNewTabLink(e)){setTimeout(function(){s.defaultPrevented&&_this10.checkDeadClick(e,r)},0);return}this.checkDeadClick(e,r)}}},{key:"queuePendingMobileClick",value:function queuePendingMobileClick(e,r,n,i,o){var _this11=this;this.dropPendingMobileClick(),this.pendingMobileClickEvent=r,this.pendingMobileClickTarget=e,this.pendingMobileClickElementFingerprint=n,this.pendingMobileClickBinX=i,this.pendingMobileClickBinY=o,this.pendingMobileClickScrollX=window.scrollX,this.pendingMobileClickScrollY=window.scrollY,this.pendingMobileClickResponseObserved=!1,this.startPendingMobileClickMutationObserver(e),this.installPendingMobileClick
2FocusListener(),this.installPendingMobileClickScrollListener(),this.pendingMobileClickTimer=setTimeout(function(){_this11.dropPendingMobileClick()},Sh)}},{key:"promotePendingMobileClick",value:function promotePendingMobileClick(){if(!this.pendingMobileClickEvent||!this.pendingMobileClickTarget){this.cleanupPendingMobileClickObservers();return}if(!this.pendingMobileClickResponseObserved)return;var e=this.pendingMobileClickEvent,r=this.pendingMobileClickTarget,n=this.pendingMobileClickElementFingerprint,i=this.pendingMobileClickBinX,o=this.pendingMobileClickBinY;this.dropPendingMobileClick(),this.emitHeatmapClick(r,e,n,i,o)}},{key:"observePendingMobileClickResponse",value:function observePendingMobileClickResponse(){this.pendingMobileClickEvent&&(this.pendingMobileClickResponseObserved=!0,this.promotePendingMobileClick())}},{key:"observeQueuedPendingMobileClickMutation",value:function observeQueuedPendingMobileClickMutation(){var e=this.pendingMobileClickMutationObserver;!e||e.takeRecords().length===0||this.observePendingMobileClickResponse()}},{key:"startPendingMobileClickMutationObserver",value:function startPendingMobileClickMutationObserver(e){var _this12=this;var r;(r=this.pendingMobileClickMutationObserver)==null||r.disconnect();try{this.pendingMobileClickMutationObserver=new MutationObserver(function(){_this12.observePendingMobileClickResponse()});var _iterator0=_createForOfIteratorHelper(this.collectObservedMutationTargets(e)),_step0;try{for(_iterator0.s();!(_step0=_iterator0.n()).done;){var n=_step0.value;this.pendingMobileClickMutationObserver.observe(n,{childList:!0,subtree:!0,characterData:!0,attributes:!0,attributeFilter:["class","style","hidden","open","aria-expanded","aria-hidden","aria-modal","disabled"]})}}catch(err){_iterator0.e(err)}finally{_iterator0.f()}var _iterator1=_createForOfIteratorHelper(this.collectObservedShadowRoots(e)),_step1;try{for(_iterator1.s();!(_step1=_iterator1.n()).done;){var _n2=_step1.value;this.pendingMobileClickMutationObserver.observe(_n2,{childList:!0,subtree:!0,characterData:!0,attributes:!0,attributeFilter:["class","style","hidden","open","aria-expanded","aria-hidden","disabled"]})}}catch(err){_iterator1.e(err)}finally{_iterator1.f()}}catch(n){}}},{key:"installPendingMobileClickFocusListener",value:function installPendingMobileClickFocusListener(){var _this13=this;this.removePendingMobileClickFocusListener();var e=function e(){_this13.observePendingMobileClickResponse(),_this13.pendingMobileClickFocusHandler=null};this.pendingMobileClickFocusHandler=e,document.addEventListener("focusin",e,{once:!0})}},{key:"removePendingMobileClickFocusListener",value:function removePendingMobileClickFocusListener(){this.pendingMobileClickFocusHandler&&(document.removeEventListener("focusin",this.pendingMobileClickFocusHandler),this.pendingMobileClickFocusHandler=null)}},{key:"installPendingMobileClickScrollListener",value:function installPendingMobileClickScrollListener(){var _this14=this;this.removePendingMobileClickScrollListener();var e=function e(){if(window.scrollX!==_this14.pendingMobileClickScrollX||window.scrollY!==_this14.pendingMobileClickScrollY){if(_this14.gestureTracker.hasRecentMovement())return;_this14.observePendingMobileClickResponse(),_this14.pendingMobileClickScrollHandler=null}};this.pendingMobileClickScrollHandler=e,window.addEventListener("scroll",e,{passive:!0})}},{key:"removePendingMobileClickScrollListener",value:function removePendingMobileClickScrollListener(){this.pendingMobileClickScrollHandler&&(window.removeEventListener("scroll",this.pendingMobileClickScrollHandler),this.pendingMobileClickScrollHandler=null)}},{key:"dropPendingMobileClick",value:function dropPendingMobileClick(){this.pendingMobileClickTimer&&(clearTimeout(this.pendingMobileClickTimer),this.pendingMobileClickTimer=null),this.pendingMobileClickEvent=null,this.pendingMobileClickTarget=null,this.pendingMobileClickElementFingerprint="",this.pendingMobileClickBinX=0,this.pendingMobileClickBinY=0,this.pendingMobileClickResponseObserved=!1,this.cleanupPendingMobileClickObservers()}},{key:"cleanupPendingMobileClickObservers",value:function cleanupPendingMobileClickObservers(){var e;(e=this.pendingMobileClickMutationObserver)==null||e.disconnect(),this.pendingMobileClickMutationObserver=null,this.removePendingMobileClick
2FocusListener(),this.removePendingMobileClickScrollListener()}},{key:"shouldDeferDeadClickForNewTabLink",value:function shouldDeferDeadClickForNewTabLink(e){if(e.tagName!=="A"||!e.getAttribute("href"))return!1;var r=e.getAttribute("target");return(r==null?void 0:r.trim().toLowerCase())==="_blank"}},{key:"checkDeadClick",value:function checkDeadClick(e,r){var _this15=this;if(this.deadClickCount>=_h||Date.now()-this.lastNavigationTimestamp<wh||fa(e))return;var n=r.element_fingerprint,i=Date.now(),o=this.deadClickDedupeMap.get(n);o!==void 0&&i-o<yh||(this.cancelPendingDeadClick(),this.pendingDeadClickEvent=r,this.pendingDeadClickTarget=e,this.deadClickLocationHref=location.href,this.historyChangedDuringWindow=!1,this.pendingDeadClickScrollX=window.scrollX,this.pendingDeadClickScrollY=window.scrollY,this.startDeadClickMutationObserver(e),this.installFocusListener(),this.installScrollListener(),this.installNativeResponseListener(e),this.pendingDeadClickTimer=setTimeout(function(){_this15.emitDeadClickIfNoResponse(n)},ba))}},{key:"startDeadClickMutationObserver",value:function startDeadClickMutationObserver(e){var _this16=this;var r;(r=this.deadClickMutationObserver)==null||r.disconnect();try{this.deadClickMutationObserver=new MutationObserver(function(){_this16.cancelPendingDeadClick()});var _iterator10=_createForOfIteratorHelper(this.collectObservedMutationTargets(e)),_step10;try{for(_iterator10.s();!(_step10=_iterator10.n()).done;){var n=_step10.value;this.deadClickMutationObserver.observe(n,{childList:!0,subtree:!0,characterData:!0,attributes:!0,attributeFilter:["class","style","hidden","open","aria-expanded","aria-hidden","aria-modal","disabled"]})}}catch(err){_iterator10.e(err)}finally{_iterator10.f()}var _iterator11=_createForOfIteratorHelper(this.collectObservedShadowRoots(e)),_step11;try{for(_iterator11.s();!(_step11=_iterator11.n()).done;){var _n3=_step11.value;this.deadClickMutationObserver.observe(_n3,{childList:!0,subtree:!0,characterData:!0,attributes:!0,attributeFilter:["class","style","hidden","open","aria-expanded","aria-hidden","disabled"]})}}catch(err){_iterator11.e(err)}finally{_iterator11.f()}}catch(n){}}},{key:"collectObservedMutationTargets",value:function collectObservedMutationTargets(e){var r=new Set,n=e,i=0;for(;n&&i<=Eh&&(r.add(n),!(i>0&&this.isDeadClickMutationBoundary(n)));)n=this.getObservedParentElement(n),i++;return r.size===0&&r.add(document.body),Array.from(r)}},{key:"collectObservedShadowRoots",value:function collectObservedShadowRoots(e){var r=[],n=e,i=0;for(;n&&i<=6;)n.shadowRoot&&r.push(n.shadowRoot),n=this.getObservedParentElement(n),i++;return r}},{key:"getObservedParentElement",value:function getObservedParentElement(e){if(e.parentElement)return e.parentElement;var r=e.getRootNode();return r instanceof ShadowRoot?r.host:null}},{key:"isDeadClickMutationBoundary",value:function isDeadClickMutationBoundary(e){var r=e.getAttribute("role");return r==="dialog"||r==="alertdialog"||e.getAttribute("aria-modal")==="true"||e.getAttribute("data-heatmap-modal-root")==="true"}},{key:"installFocusListener",value:function installFocusListener(){var _this17=this;this.removePendingFocusListener();var e=function e(){_this17.cancelPendingDeadClick(),_this17.pendingFocusHandler=null};this.pendingFocusHandler=e,document.addEventListener("focusin",e,{once:!0})}},{key:"removePendingFocusListener",value:function removePendingFocusListener(){this.pendingFocusHandler&&(document.removeEventListener("focusin",this.pendingFocusHandler),this.pendingFocusHandler=null)}},{key:"installScrollListener",value:function installScrollListener(){var _this18=this;this.removePendingScrollListener();var e=function e(){(window.scrollX!==_this18.pendingDeadClickScrollX||window.scrollY!==_this18.pendingDeadClickScrollY)&&(_this18.cancelPendingDeadClick(),_this18.pendingScrollHandler=null)};this.pendingScrollHandler=e,window.addEventListener("scroll",e,{passive:!0})}},{key:"removePendingScrollListener",value:function removePendingScrollListener(){this.pendingScrollHandler&&(window.removeEventListener("scroll",this.pendingScrollHandler),this.pendingScrollHandler=null)}},{key:"installNativeResponseListener",value:function installNativeResponseListener(e){var _this19=this;this.removePendingNativeResponseListener();var r=function r(n){var i=n.target;i instanceof Element&&_this19.isNativeResponseForTarget(e,i)&&_this19.cancelPendingDeadClick()};this.pendingNativeResponseHandler=r;for(var _i5=0,_a2=_a;_i5<_a2.length;_i5++){var n=_a2[_i5];document.addEventListener(n,r,{capture:!0})}}},{key:"removePendingNativeResponseListener",value:function removePendingNativeResponseListener(){if
2(this.pendingNativeResponseHandler){for(var _i6=0,_a3=_a;_i6<_a3.length;_i6++){var e=_a3[_i6];document.removeEventListener(e,this.pendingNativeResponseHandler,{capture:!0})}this.pendingNativeResponseHandler=null}}},{key:"isNativeResponseForTarget",value:function isNativeResponseForTarget(e,r){return!!(e===r||e.contains(r)||r.contains(e)||e instanceof HTMLLabelElement&&e.control===r)}},{key:"emitDeadClickIfNoResponse",value:function emitDeadClickIfNoResponse(e){if(location.href!==this.deadClickLocationHref){this.cleanupDeadClickObservers();return}if(this.historyChangedDuringWindow){this.cleanupDeadClickObservers();return}if(!this.pendingDeadClickEvent){this.cleanupDeadClickObservers();return}this.deadClickDedupeMap.set(e,Date.now()),this.deadClickCount++,this.track(Ie.DEAD_CLICK,_(d({},this.pendingDeadClickEvent),{dead_click_reason:"no_interaction_response",response_window_ms:ba,fingerprint_confidence:this.pendingDeadClickTarget?ua(this.pendingDeadClickTarget):"low"})),this.cleanupDeadClickObservers(),this.pendingDeadClickEvent=null,this.pendingDeadClickTarget=null}},{key:"cancelPendingDeadClick",value:function cancelPendingDeadClick(){this.pendingDeadClickTimer&&(clearTimeout(this.pendingDeadClickTimer),this.pendingDeadClickTimer=null),this.pendingDeadClickEvent=null,this.pendingDeadClickTarget=null,this.cleanupDeadClickObservers()}},{key:"cleanupDeadClickObservers",value:function cleanupDeadClickObservers(){var e;(e=this.deadClickMutationObserver)==null||e.disconnect(),this.deadClickMutationObserver=null,this.removePendingFocusListener(),this.removePendingScrollListener(),this.removePendingNativeResponseListener()}},{key:"recordElementScrollDepth",value:function recordElementScrollDepth(e){if(!(e instanceof HTMLElement)||e.scrollHeight<=e.clientHeight)return;var r=ce((e.scrollTop+e.clientHeight)/Math.max(1,e.scrollHeight));r>this.maxElementScrollNorm&&(this.maxElementScrollNorm=r)}},{key:"listenForScroll",value:function listenForScroll(){var _this20=this;var e=function e(){var n=window.scrollY;n>_this20.maxScrollY&&(_this20.maxScrollY=n)},r=function r(n){_this20.recordElementScrollDepth(n.target)};e(),window.addEventListener("scroll",e,{passive:!0}),document.addEventListener("scroll",r,{capture:!0,passive:!0}),this.eventHandlers.push(function(){return window.removeEventListener("scroll",e)}),this.eventHandlers.push(function(){return document.removeEventListener("scroll",r,{capture:!0})})}},{key:"flushScrollData",value:function flushScrollData(){if(!this.currentPageKey)return;var e=window.innerHeight,r=Math.max(1,document.documentElement.scrollHeight),n=ce((this.maxScrollY+e)/r),i=Math.max(n,this.maxElementScrollNorm);this.hasEmittedScrollForPage&&i<=this.lastEmittedMaxScrollNorm||(this.hasEmittedScrollForPage=!0,this.lastEmittedMaxScrollNorm=i,this.track(Ie.HEATMAP_SCROLL,{page_key:this.currentPageKey,pathname:this.currentPathname,breakpoint:dt(window.innerWidth),viewport_h:e,doc_h:r,max_scroll_norm:i}))}},{key:"listenForRouteChanges",value:function listenForRouteChanges(){var _this21=this;var e=function e(){var o=location.pathname,s=location.search;if(o!==_this21.currentPathname){_this21.lastNavigationTimestamp=Date.now(),_this21.resetPageState();return}s!==_this21.currentSearch&&(_this21.currentSearch=s,_this21.currentPageKey=ut(location.href))},r=history.pushState.bind(history);this.originalPushState=r,history.pushState=function(){_this21.observePendingMobileClickResponse(),_this21.historyChangedDuringWindow=!0,_this21.cancelPendingDeadClick(),_this21.lastNavigationTimestamp=Date.now(),r.apply(void 0,arguments),setTimeout(e,0)};var n=history.replaceState.bind(history);this.originalReplaceState=n,history.replaceState=function(){_this21.observePendingMobileClickResponse(),_this21.historyChangedDuringWindow=!0,_this21.cancelPendingDeadClick(),_this21.lastNavigationTimestamp=Date.now(),n.apply(void 0,arguments),setTimeout(e,0)};var i=function i(){_this21.observePendingMobileClickResponse(),_this21.historyChangedDuringWindow=!0,_this21.cancelPendingDeadClick(),_this21.lastNavigationTimestamp=Date.now(),e()};window.addEventListener("popstate",i),this.eventHandlers.push(function(){return window.removeEventListener("popstate",i)})}},{key:"listenForWindowOpen",value:function listenForWindowOpen(){var _this22=this;var e=window.open.bind(window);this.originalWindowOpen=e,window.open=function(){var n=e.apply(void 0,arguments);return n&&_this22.cancelPendingDeadClick(),n}}},{key:"flushForTransport",value:function flushForTransport(){this.observeQueuedPendingMobileClickMutation(),this.promotePendingMobileClick(),this.flushScrollData()}},{key:"track",value:function track(e,r){this.eventQueue.push([e,r])}},{key:"getEventQueue",value:function getEventQueue(){var e=(0,ya["default"])(this.eventQueue);return this.eventQueue.length=0,p.getIsDebugMode()&&e.forEach(function(_ref3){var _ref4=_slicedToArray(_ref3,2),n=_ref4[1];n.debug_mode="true"}),e}},{key:"destroy",value:function destroy(){this.dropPendingMobileClick(),this.cancelPendingDeadClick(),this.gestureTracker.detach(),this.eventHandlers.forEac
2h(function(e){return e()}),this.eventHandlers.length=0,this.originalPushState&&(history.pushState=this.originalPushState),this.originalReplaceState&&(history.replaceState=this.originalReplaceState),this.originalWindowOpen&&(window.open=this.originalWindowOpen)}}])}();var wa=!1,Ea=function Ea(){if(!wa){wa=!0;try{if(!sessionStorage.isNewSession){var _t5=Number(b.getSessionCount())||0;b.setSessionCount(_t5+1),sessionStorage.isNewSession=!0}}catch(t){}}},Sa=function Sa(){return Number(b.getSessionCount())||0};var kh=function kh(t){var e,r;if(typeof(t==null?void 0:t.track_web_events)=="boolean"&&p.setTrackWebEvents(t.track_web_events),typeof(t==null?void 0:t.enhanced_web_events)=="boolean"&&p.setEnhancedWebEvents(t.enhanced_web_events),_typeof(t==null?void 0:t.default_event_properties)=="object"&&p.setDefaultEventProperties(t.default_event_properties),_typeof(t==null?void 0:t.default_user_custom_properties)=="object"&&p.setDefaultUserCustomProperties(t.default_user_custom_properties),_typeof(t==null?void 0:t.default_user_consent_properties)=="object"&&p.setDefaultUserConsentProperties(t.default_user_consent_properties),typeof(t==null?void 0:t.force_ipv4)=="boolean"&&p.setForceIpv4(t.force_ipv4),typeof(t==null?void 0:t.custom_domain)=="string"&&p.setCustomDomain(t.custom_domain),typeof(t==null?void 0:t.custom_domain_ipv4)=="string"&&p.setCustomDomainIpv4(t.custom_domain_ipv4),t!=null&&t.session_replay&&p.setSessionReplay(t.session_replay),typeof((e=t==null?void 0:t.cookie_names)==null?void 0:e.device_id)=="string"){var n=B(t.cookie_names.device_id);n&&Ve(n)}if(typeof((r=t==null?void 0:t.cookie_names)==null?void 0:r.sdk_data)=="string"){var _n4=B(t.cookie_names.sdk_data);_n4&&b.configure(_n4)}t!=null&&t.experimentation&&p.setExperimentation(t.experimentation),typeof(t==null?void 0:t.bot_detection)=="boolean"&&p.setBotDetection(t.bot_detection),Array.isArray(t==null?void 0:t.url_query_params_blocklist)&&p.setUrlQueryParamsBlocklist(t.url_query_params_blocklist)},Ch=function Ch(t){var _iterator12=_createForOfIteratorHelper(t),_step12;try{for(_iterator12.s();!(_step12=_iterator12.n()).done;){var e=_step12.value;var r=e[0],n=e[1];if(r!=="init")continue;if(typeof n!="string"){g.error("[sdk]Invalid init command: missing token",e);continue}var i=n.trim();if(!i){g.error("[sdk]Invalid init command: blank token",e);continue}i!=="187645735503476"&&(z.set(!0),We(i),kh(e[2]),Ea(),He(e[2]))}}catch(err){_iterator12.e(err)}finally{_iterator12.f()}},ka=function(){var _ref5=_asyncToGenerator(_regenerator().m(function _callee4(){var e,t;return _regenerator().w(function(_context4){while(1)switch(_context4.n){case 0:if(!((typeof window==="undefined"?"undefined":_typeof(window))>"u")){_context4.n=1;break}return _context4.a(2);case 1:t=((e=window.ours)==null?void 0:e.queue)||[];Ch(t);case 2:return _context4.a(2)}},_callee4)}));return function ka(){return _ref5.apply(this,arguments)}}();var ft=function(){function ft(){var _this23=this;_classCallCheck(this,ft);this.handleVisibilityChange=function(){document.visibilityState==="hidden"?(_this23.updateActiveDuration(),_this23.isActive=!1):(_this23.startTime=Date.now(),_this23.isActive=!0)};this.startTime=Date.now(),this.totalActiveDuration=0,this.isActive=!0,document.addEventListener("visibilitychange",this.handleVisibilityChange)}return _createClass(ft,[{key:"updateActiveDuration",value:function updateActiveDuration(){return this.isActive&&(this.totalActiveDuration+=Date.now()-this.startTime),this.startTime=Date.now(),this.totalActiveDuration}},{key:"resetCount",value:function resetCount(){this.startTime=Date.now(),this.totalActiveDuration=0,this.isActive=!0}},{key:"getActiveDuration",value:function getActiveDuration(){return this.updateActiveDuration()}},{key:"getCurrentDuration",value:function getCurrentDuration(){return Date.now()-this.startTime}},{key:"stopTracking",value:function stopTracking(){document.removeEventListener("visibilitychange",this.handleVisibilityChange)}}])}();function hr(t){if(t.length<2)return 0;var e=t.reduce(function(n,i){return n+i},0)/t.length;return t.map(function(n){return Math.pow(n-e,2)}).reduce(function(n,i){return n+i},0)/t.length}function Th(t){if(t.length<3)return 0;var e=t[0],r=t[t.length-1],n=Math.sqrt(Math.pow(r.x-e.x,2)+Math.pow(r.y-e.y,2));if(n===0)return 0;var i=0;for(var o=1;o<t.length;o++){var s=t[o].x-t[o-1].x,c=t[o].y-t[o-1].y;i+=Math.sqrt(s*s+c*c)}return i===0?0:n/i}var ht=function(){function ht(){var _this24=this;_classCallCheck(this,ht);this.abortController=new AbortController;this.pageLoadTime=Date.now();this.firstInteractionTime=null;this.mousePoints=[];this.mouseVelocities=[];this.lastMouseSampleTime=0;this.scrollTimestamps=[];this.scrollPositions=[];this.clickTimestamps=[];this.keyTimestamps=[];this.interactionSequence=[];this.recordFirstInteraction=function(){_this24.firstInteractionTime===null&&(_this24.firstInteractionTime=Date.now())};this.onMouseMove=function(e){var r=Date.now();if(r-_this24.lastMouseSampleTime<50)return;_this24.lastMouseSampleTime=r,_this24.recordFirstInteraction();var n={x:e.clientX,y:e.clientY,t:r};if(_this24.mousePoints.push(n),_this24.mousePoints.length>200&&_this24.mousePoints.shift(),_this24.mousePoints.length>=2){var i=_this24.mousePoints[_this24.mousePoints.length-2],o=n.t-i.t;if(o>
20){var c=Math.sqrt(Math.pow(n.x-i.x,2)+Math.pow(n.y-i.y,2))/o;_this24.mouseVelocities.push(c),_this24.mouseVelocities.length>50&&_this24.mouseVelocities.shift()}}(_this24.interactionSequence.length===0||_this24.interactionSequence.at(-1)!=="m")&&_this24.interactionSequence.push("m")};this.onScroll=function(){_this24.recordFirstInteraction(),_this24.scrollTimestamps.push(Date.now()),_this24.scrollPositions.push(window.scrollY),_this24.scrollTimestamps.length>200&&(_this24.scrollTimestamps.shift(),_this24.scrollPositions.shift()),(_this24.interactionSequence.length===0||_this24.interactionSequence.at(-1)!=="s")&&_this24.interactionSequence.push("s")};this.onClick=function(){_this24.recordFirstInteraction(),_this24.clickTimestamps.push(Date.now()),_this24.clickTimestamps.length>200&&_this24.clickTimestamps.shift(),(_this24.interactionSequence.length===0||_this24.interactionSequence.at(-1)!=="c")&&_this24.interactionSequence.push("c")};this.onKeyDown=function(){_this24.recordFirstInteraction(),_this24.keyTimestamps.push(Date.now()),_this24.keyTimestamps.length>200&&_this24.keyTimestamps.shift(),(_this24.interactionSequence.length===0||_this24.interactionSequence.at(-1)!=="k")&&_this24.interactionSequence.push("k")};this.onTouchStart=function(){_this24.recordFirstInteraction()}}return _createClass(ht,[{key:"initialize",value:function initialize(){var r={signal:this.abortController.signal,passive:!0};window.addEventListener("mousemove",this.onMouseMove,r),window.addEventListener("scroll",this.onScroll,r),window.addEventListener("click",this.onClick,r),window.addEventListener("keydown",this.onKeyDown,r),window.addEventListener("touchstart",this.onTouchStart,r)}},{key:"computeIntervals",value:function computeIntervals(e){var r=[];for(var n=1;n<e.length;n++)r.push(e[n]-e[n-1]);return r}},{key:"getSignals",value:function getSignals(){var s,c,l,u;var e=this.computeIntervals(this.clickTimestamps),r=this.computeIntervals(this.keyTimestamps),n=[];for(var m=1;m<this.scrollTimestamps.length;m++){var f=this.scrollTimestamps[m]-this.scrollTimestamps[m-1];if(f>0){var w=Math.abs(this.scrollPositions[m]-this.scrollPositions[m-1]);n.push(w/f)}}var i=e.length>0?e.reduce(function(m,f){return m+f},0)/e.length:0,o=r.length>0?r.reduce(function(m,f){return m+f},0)/r.length:0;return{mouse_move_count:this.mousePoints.length,mouse_velocity_variance:hr(this.mouseVelocities),mouse_path_linearity:Th(this.mousePoints),scroll_event_count:this.scrollTimestamps.length,scroll_velocity_variance:hr(n),click_count:this.clickTimestamps.length,avg_click_interval_ms:Math.round(i),click_interval_variance:hr(e),key_event_count:this.keyTimestamps.length,avg_keystroke_interval_ms:Math.round(o),time_to_first_interaction_ms:this.firstInteractionTime?this.firstInteractionTime-this.pageLoadTime:-1,has_webdriver:!!navigator.webdriver,plugins_length:(c=(s=navigator.plugins)==null?void 0:s.length)!=null?c:0,languages_length:(u=(l=navigator.languages)==null?void 0:l.length)!=null?u:0,has_touch_support:"ontouchstart"in window||navigator.maxTouchPoints>0,interaction_sequence:this.interactionSequence.slice(0,20).join(",")}}},{key:"destroy",value:function destroy(){this.abortController.abort(),this.abortController=new AbortController,this.pageLoadTime=Date.now(),this.firstInteractionTime=null,this.lastMouseSampleTime=0,this.mousePoints=[],this.mouseVelocities=[],this.scrollTimestamps=[],this.scrollPositions=[],this.clickTimestamps=[],this.keyTimestamps=[],this.interactionSequence=[]}}])}();var Ca=function Ca(t,e){if(!t)return;var r="fb",n=e.split(".").length-1;return"".concat(r,".").concat(n,".").concat(Date.now(),".").concat(t)};function Ta(){var t=navigator.userAgent||navigator.vendor,e=[/FBAN|FBAV/,/Instagram/,/Line/,/wv/,/Mobile.*Safari/],r=window.navigator.standalone===!0,n=e.some(function(o){return o.test(t)}),i=window.matchMedia("(display-mode: standalone)").matches||r;return n||i}var xh=function xh(t){try{var e=new URL(t);if(e.hostname!==window.location.hostname)return;var r=new URLSearchParams(e.search);return Array.from(r.entries()).reduce(function(n,i){return n[i[0].toLowerCase()]=i[1],n},{})}catch(e){return}},xa=function xa(t){var e=new URLSearchParams(window.location.search),r=Array.from(e.entries()).reduce(function(s,c){return s[c[0].toLowerCase()]=c[1],s},{}),n=t.map(function(s){var c=r[s.toLowerCase()];return c?{param:s,value:c}:void 0}
2).filter(Be),i=window.document.referrer,o=i?xh(i):void 0;if(o){var _iterator13=_createForOfIteratorHelper(t),_step13;try{var _loop3=function _loop3(){var s=_step13.value;if(n.some(function(l){return l.param===s}))return 1;var c=o[s.toLowerCase()];c&&n.push({param:s,value:c})};for(_iterator13.s();!(_step13=_iterator13.n()).done;){if(_loop3())continue}}catch(err){_iterator13.e(err)}finally{_iterator13.f()}}return i&&n.push({param:"referrer",value:i}),n.reduce(function(s,c){return s[c.param]=c.value,s},{})};function Ah(){return _Ah.apply(this,arguments)}function _Ah(){_Ah=_asyncToGenerator(_regenerator().m(function _callee13(){var _t29,_t30;return _regenerator().w(function(_context13){while(1)switch(_context13.n){case 0:if(!(window.navigator.userAgentData&&window.navigator.userAgentData.getHighEntropyValues)){_context13.n=2;break}_context13.n=1;return window.navigator.userAgentData.getHighEntropyValues(["fullVersionList"]);case 1:_t30=_context13.v.fullVersionList;_t29={fullVersionList:_t30};_context13.n=3;break;case 2:_t29={userAgent:navigator.userAgent};case 3:return _context13.a(2,_t29)}},_callee13)}));return _Ah.apply(this,arguments)}function Ph(t){if(t.fullVersionList)return t.fullVersionList.map(function(r){return"".concat(encodeURIComponent(r.brand),";").concat(r.version)}).join("|");if(t.userAgent){var e=t.userAgent,r=e.match(/(Chrome|Firefox|Safari|Edge|Opera|MSIE|Trident)[\s/]?([\d.]+)/i),n=e.match(/\(([^)]+)\)/),i=[];return r&&i.push("".concat(r[1],";").concat(r[2])),n&&i.push("OS;".concat(n[1])),i.join("|")}return""}function Aa(){return _Aa.apply(this,arguments)}function _Aa(){_Aa=_asyncToGenerator(_regenerator().m(function _callee14(){var t;return _regenerator().w(function(_context14){while(1)switch(_context14.n){case 0:if(!((typeof window==="undefined"?"undefined":_typeof(window))>"u")){_context14.n=1;break}return _context14.a(2,"");case 1:_context14.n=2;return Ah();case 2:t=_context14.v;return _context14.a(2,Ph(t))}},_callee14)}));return _Aa.apply(this,arguments)}var Pa=function Pa(t){try{return new URL(t).hostname}catch(e){return}};var vr=De(["ZmJjbGlk","Z2NsaWQ","bGlfZGlk"]),Ia=vr[0],Da=vr[1],Ih=vr[2],Dh=De(["dXRtX3NvdXJjZQ","dXRtX21lZGl1bQ","dXRtX2NhbXBhaWdu","dXRtX2NvbnRlbnQ","dXRtX25hbWU","dXRtX3Rlcm0","ZmJjbGlk","YWRfaWQ","YWRzZXRfaWQ","Y2FtcGFpZ25faWQ","YWxhcnQ","YWxlaWQ","Z2NsaWQ","bmRjbGlk","b3BwcmVm","ZGNsaWQ","cWNsaWQ","Z2FkX3NvdXJjZQ","Z2JyYWlk","d2JyYWlk","bXNjbGtpZA","bGlfZmF0X2lk","dHRjbGlk","dHdjbGlk","Y2xpY2tpZA","cmR0X2NpZA","c2NjaWQ","aXJjbGlja2lk","aW1fcmVm","Y2xpZA","ZXBpaw","c2FjaWQ","YmFzaXNfY2lk","YmVlc3dheF9hdWN0aW9uX2lk","bGlfZGlk","YWRtaXRhZF91aWQ","X2VmX3RyYW5zYWN0aW9uX2lk","dmlhbnRfY2xpY2tfaWQ","dmlhbnRfaW1wcmVzc2lvbl9pZA","b2JfY2xpY2tfaWQ"]);function Oh(t,e){if(!e)return t;for(var r in e){var n=e[r];if(n){var i=n.value,o=n.behavior;(o==="override"||o==="fallback"&&!t[r])&&(t[r]=i)}}return t}var Rh=Aa(),Mh=Date.now(),vt=function(){var _ref6=_asyncToGenerator(_regenerator().m(function _callee5(t,e){var _ref7;var r,n,i,o,s,_t6,_t7,_t8,_t9,_t0,_t1,_t10,_t11,_t12,_t13,_t14,_t15,_t16;return _regenerator().w(function(_context5){while(1)switch(_context5.n){case 0:r=xa(Dh);n=r[Ia];i=r[Da];o=V("_axwrt");_t6=_;_t7=d;_t8=d;_t9=navigator.language.toLowerCase()||document.documentElement.lang;_t0=document.characterSet;_context5.n=1;return Rh;case 1:_t1=_context5.v;_t10=Mh;_t11=$e();_t12=Ta();_t13=window.top!==window.self;_t14=Sa();_t15=t.getCurrentDuration();_t16=t.getActiveDuration();s=_t6(_t7(_t8({browser_language:_t9,encoding:_t0,uafvl:_t1,page_hash:_t10,current_url:_t11,webview:_t12,iframe:_t13,sessionCount:_t14,duration:_t15,activeDuration:_t16},r),o?{axwrt:o}:{}),(_ref7={clickid:r.clickid||r[Ih],sid:H(),fbc:n?Ca(n,window.location.host):void 0},_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_ref7,Ia,n),"fbp",Lh()),Da,i?Nh(i):void 0),"host",window.location.host),"pathname",window.location.pathname),"referrer",tn()),"referring_domain",Pa(document.referrer)),"screen_height",window.screen.height),"screen_width",window.screen.width),"title",document.title),_defineProperty(_defineProperty(_defineProperty(_ref7,"user_agent",navigator.userAgent),"version","1.0.0"),"sr","".concat(window.screen.width,"x").concat(window.screen.height))));return _context5.a(2,Oh(s,e))}}
2,_callee5)}));return function vt(_x2,_x3){return _ref6.apply(this,arguments)}}(),Lh=function Lh(){var t=b.getFBInit();if(t)return t;var e="fb",r=location.host.split(".").length-1,n="".concat(e,".").concat(r,".").concat(Date.now(),".").concat(Math.floor(Date.now()/1e3));return b.setFBInit(n),n},Nh=function Nh(t){if(t)return t};var Fh=function Fh(t){var e=p.getDefaultUserCustomProperties(),r=p.getDefaultUserConsentProperties(),n=e&&Object.keys(e).length>0,i=r&&Object.keys(r).length>0;if(!n&&!i)return t;var o=_(d({},t),{custom_properties:d(d({},e),t==null?void 0:t.custom_properties)});return(i||t!=null&&t.consent)&&(o.consent=d(d({},r),t==null?void 0:t.consent)),o},Oa=function(){var _ref8=_asyncToGenerator(_regenerator().m(function _callee6(t,e){var l,n,i,o,s,c,_args6=arguments;return _regenerator().w(function(_context6){while(1)switch(_context6.n){case 0:_context6.n=1;return vt(t,_args6.length<=6?undefined:_args6[6]);case 1:n=_context6.v;i=p.getDefaultEventProperties();o=d(d({},i),(l=_args6.length<=4?undefined:_args6[4])!=null?l:{});e&&p.getBotDetection()&&(o._bot_signals=e.getSignals());s=Fh(_args6.length<=5?undefined:_args6[5]),c=(o.$distinct_id||R()).toString();return _context6.a(2,{defaultProperties:n,distinct_id:c,event:_args6.length<=3?undefined:_args6[3],eventProperties:o,userProperties:s,visitor_id:T()})}},_callee6)}));return function Oa(_x4,_x5){return _ref8.apply(this,arguments)}}();var Ra=function Ra(t,e){return fetch(t,e)};var Ma=function Ma(t){var e=[];var _iterator14=_createForOfIteratorHelper(t),_step14;try{for(_iterator14.s();!(_step14=_iterator14.n()).done;){var r=_step14.value;var n=r[0];if(n==="updateDefaultEventProperties"){var i=r[1];p.appendDefaultEventProperties(i)}else if(n==="updateDefaultUserCustomProperties"){var _i7=r[1];p.appendDefaultUserCustomProperties(_i7)}else if(n==="updateDefaultUserConsentProperties"){var _i8=r[1];p.appendDefaultUserConsentProperties(_i8)}else e.push(r)}}catch(err){_iterator14.e(err)}finally{_iterator14.f()}return e};function La(t){var s,c,l;var e=typeof t.sampleRate=="number"&&Number.isFinite(t.sampleRate)?Math.max(0,Math.min(1,t.sampleRate)):1,r=(s=t.viewportWidth)!=null?s:0,n=(c=t.viewportHeight)!=null?c:0,i=r>0&&n>0,o=(l=t.randomValue)!=null?l:Math.random();return{sampledIn:i&&o<e,hasNonZeroViewport:i,normalizedSampleRate:e}}var _t,br,$,_r,le,bt,Na="",Fa=0,qh="$heatmap_scroll",Uh=250,jh=function jh(t){if(t&&t!==null)L(t);else{var e=R();L(e)}F.set(!0)},yr=function(){var _ref9=_asyncToGenerator(_regenerator().m(function _callee8(t){return _regenerator().w(function(_context8){while(1)switch(_context8.n){case 0:_context8.n=1;return Promise.all(t.map(function(){var _ref0=_asyncToGenerator(_regenerator().m(function _callee7(e){var n,i,r,o,_t17;return _regenerator().w(function(_context7){while(1)switch(_context7.n){case 0:r=e[0];if(!(r==="track")){_context7.n=2;break}o=e[1];if(typeof o=="string")try{(i=(n=window.ours_replay)==null?void 0:n.notifyEvent)==null||i.call(n,o)}catch(s){}_context7.n=1;return Oa.apply(void 0,[_t,bt].concat(_toConsumableArray(e)));case 1:return _context7.a(2,_context7.v);case 2:if(!(r==="identify")){_context7.n=4;break}_context7.n=3;return Hh.apply(void 0,_toConsumableArray(e));case 3:_t17=_context7.v;_context7.n=5;break;case 4:_t17=null;case 5:return _context7.a(2,_t17)}},_callee7)}));return function(_x7){return _ref0.apply(this,arguments)}}()));case 1:return _context8.a(2,_context8.v.filter(Be))}},_callee8)}));return function yr(_x6){return _ref9.apply(this,arguments)}}(),wr=function(){var _ref1=_asyncToGenerator(_regenerator().m(function _callee9(t,e,r){var i,o,n,_i$queue,_$h,_$h2,s,c,l,u,_u2,_o$queue,_t18,_t19,_t20;return _regenerator().w(function(_context9){while(1)switch(_context9.p=_context9.n){case 0:if(!(r.length===0)){_context9.n=1;break}return _context9.a(2);case 1:n=!1;_context9.p=2;_$h=$h(),_$h2=_slicedToArray(_$h,2),s=_$h2[0],c=_$h2[1];if(s){_context9.n=3;break}return _context9.a(2);case 3:_context9.p=3;_context9.n=4;return qa(s,t,r);case 4:u=_context9.v;if(!u){_context9.n=6;break}_context9.n=5;return Ua(u);case 5:return _context9.a(2);case 6:_context9.n=8;break;case 7:_context9.p=7;_t18=_context9.v;l=_t18;case 8:if(!c){_context9.n=14;break}_context9.p=9;_context9.n=10;return qa(c,t,r);case 10:_u2=_context9.v;if(!_u2){_context9.n=12;break}Gh(s.toString());_context9.n=11;return Ua(_u2);case 11:return _context9.a(2);case 12:_context9.n=14;break;case 13:_context9.p=13;_t19=_context9.v;l=_t19;case 14:if(!((i=window.ours)==null||(_i$queue=i.queue).push.apply(_i$queue,_toConsumableArray(e)),n=!0,!l)){_context9.n=15;break}return _context9.a(2);case 15:throw l;case 16:_context9.p=16;_t20=_context9.v;n||(o=window.ours)==null||(_o$queue=o.queue).push.apply(_o$queue,_toConsumableArray(e)),g.error("[sdk]Error sending events",_t20),setTimeout(function(){ue()},1e3);case 17:return _context9.a(2)}},_callee9,null,[[9,13],[3,7],[2,16]])}));return function wr(_x8,_x9,_x0){return _ref1.apply(this,arguments)}}(),Vh=function Vh(t){var r,n,i;if((typeof window==="undefined"?"undefined":_typeof(window))>"u"||!((r=window.ours)!=null&&r.queue))return[];var e=(n=window.ours)==null?void 0:n.queue.slice(0,t);return window.ours.queue=(i=window.ours)==null?void 0:i.queue.slice(t),e},Hh=function(){var _ref10=_asyncToGenerator(_regenerator().m(function _callee0(){var e,_args0=arguments,_t21,_t22,_t23,_t24;return _regenerator().w(function(_context0){while(1)switch(_context0.n){case 0:_context0.n=1;return vt(_t);case 1:_t21=_context0.v;_t22=(e=_args0.length<=1?undefined:_args0[1])!=null?e:{};_t23=T();_t24=R();return _context0.a(2,{defaultProperties:_t21,userProperties:_t22,visitor_id:_t23,event:"$identify",distinct_id:_t24})}}
2,_callee0)}));return function Hh(){return _ref10.apply(this,arguments)}}(),qa=function(){var _ref11=_asyncToGenerator(_regenerator().m(function _callee1(t,e,r){var n,i;return _regenerator().w(function(_context1){while(1)switch(_context1.n){case 0:n=new URL(t.toString());n.pathname="ingest";_context1.n=1;return Ra(n.toString(),{body:Wh(e,r),credentials:"include",keepalive:!0,method:"POST"});case 1:i=_context1.v;return _context1.a(2,i.ok?i:null)}},_callee1)}));return function qa(_x1,_x10,_x11){return _ref11.apply(this,arguments)}}(),Ua=function(){var _ref12=_asyncToGenerator(_regenerator().m(function _callee10(t){var e,r,n,i,o,_t25;return _regenerator().w(function(_context10){while(1)switch(_context10.p=_context10.n){case 0:_context10.p=0;_context10.n=1;return t.json();case 1:i=_context10.v;if(!(!i.success||!i.visitor_id)){_context10.n=2;break}return _context10.a(2);case 2:o=T();o&&o!==i.visitor_id&&((e=window.ours)==null||e.queue.push(["track","$identity_recovered",{previous_visitor_id:o,recovered_visitor_id:i.visitor_id}])),L(i.visitor_id);_context10.n=4;break;case 3:_context10.p=3;_t25=_context10.v;(n=(r=g).debug)==null||n.call(r,"[sdk]Failed to parse response JSON for visitor_id",_t25);case 4:return _context10.a(2)}},_callee10,null,[[0,3]])}));return function Ua(_x12){return _ref12.apply(this,arguments)}}(),Wh=function Wh(t,e){return JSON.stringify({data:e,token:t,is_manually_set_id:F.get()})},$h=function $h(){var _p$getIngestEndpoints3=p.getIngestEndpoints(),_p$getIngestEndpoints4=_slicedToArray(_p$getIngestEndpoints3,2),t=_p$getIngestEndpoints4[0],e=_p$getIngestEndpoints4[1];return!t||!e?[t,e]:Bh()!==t.toString()?[t,e]:[e,t]},Bh=function Bh(){var t,e;return(e=(t=window.ours_data)==null?void 0:t.failed_primary_ingest_endpoint)!=null?e:null},Gh=function Gh(t){window.ours_data=window.ours_data||{},window.ours_data.failed_primary_ingest_endpoint=t},Xh=function Xh(t,e){var r=[];var _iterator15=_createForOfIteratorHelper(t),_step15;try{for(_iterator15.s();!(_step15=_iterator15.n()).done;){var n=_step15.value;var _n5=_slicedToArray(n,2),i=_n5[0],o=_n5[1],s=["track",i,o];r.push(s)}}catch(err){_iterator15.e(err)}finally{_iterator15.f()}var _iterator16=_createForOfIteratorHelper(e),_step16;try{for(_iterator16.s();!(_step16=_iterator16.n()).done;){var _n6=_step16.value;r.push(_n6)}}catch(err){_iterator16.e(err)}finally{_iterator16.f()}return r},zh=function zh(t){return t.filter(function(e){var o,s,c,l,u;if(e[0]!=="track"||e[1]!==qh)return!0;var r=(o=e[2])!=null?o:{},n=JSON.stringify([(s=r.page_key)!=null?s:"",(c=r.pathname)!=null?c:"",(l=r.breakpoint)!=null?l:"",(u=r.max_scroll_norm)!=null?u:""]),i=Date.now();return n===Na&&i-Fa<=Uh?!1:(Na=n,Fa=i,!0)})},ja=function(){var _ref13=_asyncToGenerator(_regenerator().m(function _callee11(){return _regenerator().w(function(_context11){while(1)switch(_context11.n){case 0:$==null||$.flushForTransport();_context11.n=1;return ue();case 1:return _context11.a(2)}},_callee11)}));return function ja(){return _ref13.apply(this,arguments)}}(),ue=function(){var _ref14=_asyncToGenerator(_regenerator().m(function _callee12(){var w,t,e,r,n,i,_La,E,M,o,s,c,l,u,m,_E,_M,x,k,yt,A,f,_t26,_t27,_t28;return _regenerator().w(function(_context12){while(1)switch(_context12.n){case 0:if(!(ka(),!z.get())){_context12.n=1;break}return _context12.a(2);case 1:t=N();if(t){_context12.n=2;break}return _context12.a(2);case 2:e=p.getExperimentation(),r=!!(e!=null&&e.token),n=p.getSessionReplay(),i=!!(n!=null&&n.token);if(!_r&&r&&(_r=new at(e.token),_r.load()["catch"](function(E){g.error("[sdk]Error initializing experimentation",E)})),!le&&i){le=new ct(n.token);_La=La({sampleRate:n.sampleRate,viewportWidth:(typeof window==="undefined"?"undefined":_typeof(window))<"u"?window.innerWidth:0,viewportHeight:(typeof window==="undefined"?"undefined":_typeof(window))<"u"?window.innerHeight:0}),E=_La.sampledIn,M=Tt(xt(),n.recordOnPaths,n.excludePaths);E&&M&&p.appendDefaultEventProperties({has_session_replay:!0}),le.loadAndInit({mask_all_text:n.mask_all_text,sampleRate:n.sampleRate,alwaysRecordEvents:n.alwaysRecordEvents,sampledIn:E,block_selector:n.block_selector,ignore_selector:n.ignore_selector,mask_text_selector:n.mask_text_selector,recordOnPaths:n.recordOnPaths,excludePaths:n.excludePaths}).then(function(x){x&&(le==null||le.start())})["catch"](function(x){g.error("[sdk]Error initializing session replay",x)})}br||(br=new ot),_t||(_t=new ft),!bt&&p.getBotDetection()&&(bt=new ht,bt.initialize()),!$&&i&&!ln()&&($=new gt);o=p.getTrackWebEvents()?br.getEventQueue():[],s=(w=$==null?void 0:$.getEventQueue())!=null?w:[],c=Vh(200),l=Xh([].concat(_toConsumableArray(o),_toConsumableArray(s)),c),u=zh(Ma(l)),m=u.findIndex(function(E){return E[0]==="reset"});if(!(m!==-1)){_context12.n=8;break}_E=u.slice(0,m);_M=u[m];x=u.slice(m+1);_context12.n=3;return yr(_E);case 3:k=_context12.v;_t26=k.length>0;if(!_t26){_context12.n=4;break}_context12.n=4;return wr(t,_E,k);case 4:if(!_M){_context12.n=5;break}yt=_M[1];jh(yt),x.unshift(["track","$reset"]);case 5:_context12.n=6;return yr(x);case 6:A=_context12.v;_t27=A.length>0;if(!_t27){_context12.n=7;break}_context12.n=7;return wr(t,x,A);case 7:return _context12.a(2);case 8:_context12.n=9;return yr(u);case 9:f=_context12.v;_t28=f.length!==0;if(!_t28){_context12.n=10;break}_context12.n=10;return wr(t,u,f);case 10:return _context12.a(2)}},_callee12)}));return function ue(){return _ref14.apply(this,arguments)}}();var Kh=250,Va=function Va(){var s;if((s=window.ours_data)!=null&&s.sdk_initialized&&window.ours)return;Ir(),Vr(),new Le().initialize();var e=null,r=function r(){var m,f;var c=(m=window.ours_data)!=null?m:window.ours_data={};e&&(clearTimeout(e),e=null);var l=Date.now(),u=(f=c.last_lifecycle_send_at)!=null?f:0;l-u<=Kh||(c.last_lifecycle_send_at=l,ja())},n=function n(){setTimeout(function(){r()}
2,0)},i=function i(){e||(e=setTimeout(function(){e=null,ue()},5))};document.addEventListener("visibilitychange",n),window.addEventListener("beforeunload",r),window.addEventListener("popstate",n),window.addEventListener("pagehide",r),setInterval(ue,3e3);var o=on(i);return o("identify",{}),ue(),o};Va()})();
3})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.