clarity-js 0.8.38-beta → 0.8.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- !function(){"use strict";var t=Object.freeze({__proto__:null,get queue(){return Wt},get start(){return Bt},get stop(){return Zt},get track(){return Rt}}),n=Object.freeze({__proto__:null,get check(){return tn},get compute(){return en},get data(){return Lt},get start(){return $t},get stop(){return rn},get trigger(){return nn}}),e=Object.freeze({__proto__:null,get compute(){return dn},get data(){return an},get log(){return ln},get reset(){return pn},get start(){return cn},get stop(){return sn},get updates(){return on}}),r=Object.freeze({__proto__:null,get callback(){return Mn},get callbacks(){return hn},get clear(){return On},get consent(){return Sn},get consentv2(){return En},get data(){return fn},get electron(){return gn},get id(){return _n},get metadata(){return kn},get save(){return xn},get shortid(){return jn},get start(){return bn},get stop(){return wn}}),a=Object.freeze({__proto__:null,get data(){return Ln},get envelope(){return Xn},get start(){return Un},get stop(){return Hn}}),o={projectId:null,delay:1e3,lean:!1,lite:!1,track:!0,content:!0,drop:[],mask:[],unmask:[],regions:[],cookies:[],fraud:!0,checksum:[],report:null,upload:null,fallback:null,upgrade:null,action:null,dob:null,delayDom:!1,throttleDom:!0,conversions:!1,includeSubdomains:!0};function i(t){return window.Zone&&"__symbol__"in window.Zone?window.Zone.__symbol__(t):t}var u=0;function c(){return performance.now()+performance.timeOrigin}function s(t){void 0===t&&(t=null);var n=0===u?c():u,e=t&&t.timeStamp>0?t.timeStamp:performance.now(),r=t&&t.view?t.view.performance.timeOrigin:performance.timeOrigin;return Math.max(Math.round(e+r-n),0)}var l="0.8.38-beta";var d=/\S/gi,p=255,f=!0,h=null,g=null,v=null;function m(t,n,e,r,a){if(void 0===r&&(r=!1),t){if("input"==n&&("checkbox"===a||"radio"===a))return t;switch(e){case 0:return t;case 1:switch(n){case"*T":case"value":case"placeholder":case"click":return function(t){var n=-1,e=0,r=!1,a=!1,o=!1,i=null;S();for(var u=0;u<t.length;u++){var c=t.charCodeAt(u);if(r=r||c>=48&&c<=57,a=a||64===c,o=9===c||10===c||13===c||32===c,0===u||u===t.length-1||o){if(r||a){null===i&&(i=t.split(""));var s=t.substring(n+1,o?u:u+1);s=f&&null!==v?s.match(v)?s:k(s,"▪","▫"):w(s),i.splice(n+1-e,s.length,s),e+=s.length-1}o&&(r=!1,a=!1,n=u)}}return i?i.join(""):t}(t);case"input":case"change":return _(t)}return t;case 2:case 3:switch(n){case"*T":case"data-":return r?b(t):w(t);case"src":case"srcset":case"title":case"alt":return 3===e?"src"===n&&(null==t?void 0:t.startsWith("blob:"))?"blob:":"":t;case"value":case"click":case"input":case"change":return _(t);case"placeholder":return w(t)}break;case 4:switch(n){case"*T":case"data-":return r?b(t):w(t);case"value":case"input":case"click":case"change":return Array(5).join("•");case"checksum":return""}break;case 5:switch(n){case"*T":case"data-":return k(t,"▪","▫");case"value":case"input":case"click":case"change":return Array(5).join("•");case"checksum":case"src":case"srcset":case"alt":case"title":return""}}}return t}function y(t,n,e){void 0===n&&(n=!1),void 0===e&&(e=!1);var r=t;if(n)r="".concat("https://").concat("Electron");else{var a=o.drop;if(a&&a.length>0&&t&&t.indexOf("?")>0){var i=t.split("?"),u=i[0],c=i[1];r=u+"?"+c.split("&").map((function(t){return a.some((function(n){return 0===t.indexOf("".concat(n,"="))}))?"".concat(t.split("=")[0],"=").concat("*na*"):t})).join("&")}}return e&&(r=r.substring(0,p)),r}function b(t){var n=t.trim();if(n.length>0){var e=n[0],r=t.indexOf(e),a=t.substr(0,r),o=t.substr(r+n.length);return"".concat(a).concat(n.length.toString(36)).concat(o)}return t}function w(t){return t.replace(d,"•")}function k(t,n,e){return S(),t?t.replace(g,n).replace(h,e):t}function _(t){for(var n=5*(Math.floor(t.length/5)+1),e="",r=0;r<n;r++)e+=r>0&&r%5==0?" ":"•";return e}function S(){if(f&&null===h)try{h=new RegExp("\\p{N}","gu"),g=new RegExp("\\p{L}","gu"),v=new RegExp("\\p{Sc}","gu")}catch(t){f=!1}}var E=[],I=null;function T(){}var O=[];function M(){}function x(){}function C(){}function N(){}function j(){}var z=Object.freeze({__proto__:null,checkDocumentStyles:function(t){},compute:function(){},data:I,event:N,hashText:M,keys:O,log:T,observe:function(){},register:j,reset:function(){},sheetAdoptionState:[],sheetUpdateState:[],start:function(){},state:E,stop:function(){},track:C,trigger:x}),A=null,P=!0;function q(){var t,n=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics;if(null==n?void 0:n.getConsentState){var e=n.getConsentState("analytics_storage");En(function(t){var n={ad_Storage:1===t.ad_Storage?"granted":"denied",analytics_Storage:1===t.analytics_Storage?"granted":"denied"};return n}({ad_Storage:n.getConsentState("ad_storage"),analytics_Storage:e}),2)}}function D(t){L(t.analytics_Storage?1:0),A=t}function R(){L(2)}function L(t){ln(36,t.toString())}function U(t){A=t,Qt(47)}function H(){P&&(Qt(47),P=!1)}var X=Object.freeze({__proto__:null,compute:H,config:D,consent:R,get data(){return A},start:function(){var t,n;P=!0,(null===(n=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics)||void 0===n?void 0:n.addListener)&&window.google_tag_data.ics.addListener(["ad_storage","analytics_storage"],q)},stop:function(){P=!0},trackConsentv2:U}),V=null;function Y(t,n){pe()&&t&&"string"==typeof t&&t.length<255&&(V=n&&"string"==typeof n&&n.length<255?{key:t,value:n}:{value:t},Qt(24))}var B,W=null,Z=null;function J(t){t in W||(W[t]=0),t in Z||(Z[t]=0),W[t]++,Z[t]++}function G(t,n){null!==n&&(t in W||(W[t]=0),t in Z||(Z[t]=0),W[t]+=n,Z[t]+=n)}function F(t,n){null!==n&&!1===isNaN(n)&&(t in W||(W[t]=0),(n>W[t]||0===W[t])&&(Z[t]=n,W[t]=n))}function K(t,n,e){return window.setTimeout(Bn(t),n,e)}function Q(t){return window.clearTimeout(t)}var $=0,tt=0,nt=null;function et(){nt&&Q(nt),nt=K(rt,tt),$=s()}function rt(){var t=s();B={gap:t-$},Qt(25),B.gap<3e5?nt=K(rt,tt):se&&(Y("clarity","suspend"),Pe(),["mousemove","touchstart"].forEach((function(t){return Zn(document,t,fe)})),["resize","scroll","pageshow"].forEach((function(t){return Zn(window,t,fe)})))}var at=Object.freeze({__proto__:null,get data(){return B},reset:et,start:function(){tt=6e4,$=0},stop:function(){Q(nt),$=0,tt=0}}),ot=null;function it(t){pe()&&o.lean&&(o.lean=!1,ot={key:t},Mn(),xn(),o.upgrade&&o.upgrade(t),Qt(3),o.lite)}var ut=Object.freeze({__proto__:null,get data(){return ot},start:function(){!o.lean&&o.upgrade&&o.upgrade("Config"),ot=null},stop:function(){ot=null},upgrade:it});function ct(t,n,e,r){return new(e||(e=Promise))((function(a,o){function i(t){try{c(r.next(t))}catch(t){o(t)}}function u(t){try{c(r.throw(t))}catch(t){o(t)}}function c(t){var n;t.done?a(t.value):(n=t.value,n instanceof e?n:new e((function(t){t(n)}))).then(i,u)}c((r=r.apply(t,n||[])).next())}))}function st(t,n){var e,r,a,o,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return o={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(u){return function(c){return function(u){if(e)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(e=1,r&&(a=2&u[0]?r.return:u[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,u[1])).done)return a;switch(r=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,r=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=i.trys,(a=a.length>0&&a[a.length-1])||6!==u[0]&&2!==u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=n.call(t,i)}catch(t){u=[6,t],r=0}finally{e=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,c])}}}var lt=null;function dt(t,n){ft(t,"string"==typeof n?[n]:n)}function pt(t,n,e,r){return void 0===n&&(n=null),void 0===e&&(e=null),void 0===r&&(r=null),ct(this,void 0,void 0,(function(){var a,o;return st(this,(function(i){switch(i.label){case 0:return o={},[4,vt(t)];case 1:return o.userId=i.sent(),o.userHint=r||((u=t)&&u.length>=5?"".concat(u.substring(0,2)).concat(k(u.substring(2),"*","*")):k(u,"*","*")),ft("userId",[(a=o).userId]),ft("userHint",[a.userHint]),ft("userType",[mt(t)]),n&&(ft("sessionId",[n]),a.sessionId=n),e&&(ft("pageId",[e]),a.pageId=e),[2,a]}var u}))}))}function ft(t,n){if(pe()&&t&&n&&"string"==typeof t&&t.length<255){for(var e=(t in lt?lt[t]:[]),r=0;r<n.length;r++)"string"==typeof n[r]&&n[r].length<255&&e.push(n[r]);lt[t]=e}}function ht(){Qt(34)}function gt(){lt={}}function vt(t){return ct(this,void 0,void 0,(function(){var n;return st(this,(function(e){switch(e.label){case 0:return e.trys.push([0,4,,5]),crypto&&t?[4,crypto.subtle.digest("SHA-256",(new TextEncoder).encode(t))]:[3,2];case 1:return n=e.sent(),[2,Array.prototype.map.call(new Uint8Array(n),(function(t){return("00"+t.toString(16)).slice(-2)})).join("")];case 2:return[2,""];case 3:return[3,5];case 4:return e.sent(),[2,""];case 5:return[2]}}))}))}function mt(t){return t&&t.indexOf("@")>0?"email":"string"}var yt="CompressionStream"in window;function bt(t){return ct(this,void 0,void 0,(function(){var n,e;return st(this,(function(r){switch(r.label){case 0:return r.trys.push([0,3,,4]),yt?(n=new ReadableStream({start:function(n){return ct(this,void 0,void 0,(function(){return st(this,(function(e){return n.enqueue(t),n.close(),[2]}))}))}}).pipeThrough(new TextEncoderStream).pipeThrough(new window.CompressionStream("gzip")),e=Uint8Array.bind,[4,wt(n)]):[3,2];case 1:return[2,new(e.apply(Uint8Array,[void 0,r.sent()]))];case 2:return[3,4];case 3:return r.sent(),[3,4];case 4:return[2,null]}}))}))}function wt(t){return ct(this,void 0,void 0,(function(){var n,e,r,a,o;return st(this,(function(i){switch(i.label){case 0:n=t.getReader(),e=[],r=!1,a=[],i.label=1;case 1:return r?[3,3]:[4,n.read()];case 2:return o=i.sent(),r=o.done,a=o.value,r?[2,e]:(e.push.apply(e,a),[3,1]);case 3:return[2,e]}}))}))}var kt=null;function _t(t){try{if(!kt)return;var n=function(t){try{return JSON.parse(t)}catch(t){return[]}}(t);n.forEach((function(t){kt(t)}))}catch(t){}}var St=[z,e,Object.freeze({__proto__:null,compute:ht,get data(){return lt},identify:pt,reset:gt,set:dt,start:function(){gt()},stop:function(){gt()}}),n,z,X,r,a,t,at,ut,z];function Et(){W={},Z={},J(5),St.forEach((function(t){return Bn(t.start)()}))}function It(){St.slice().reverse().forEach((function(t){return Bn(t.stop)()})),W={},Z={}}function Tt(){ht(),dn(),Qt(0),en(),H()}function Ot(t,n,e){return"".concat(t,"=").concat(m(n,0===t.indexOf("data-")?"data-":t,e))}var Mt=[],xt=1,Ct=null;function Nt(){Mt=[],function(t){var n=[t];for(;n.length>0;){for(var e=null,r=null,a=null,o=n.shift(),i=o.firstChild,u=o.parentElement?o.parentElement:o.parentNode?o.parentNode:null;i;)n.push(i),i=i.nextSibling;switch(o.nodeType){case Node.DOCUMENT_TYPE_NODE:var c=o;r="*D",e={name:c.name,publicId:c.publicId,systemId:c.systemId};break;case Node.TEXT_NODE:a=o.nodeValue,r=Ct.get(u)?"*T":r;break;case Node.ELEMENT_NODE:var s=o;e=jt(s),r=["NOSCRIPT","SCRIPT","STYLE"].indexOf(s.tagName)<0?s.tagName:r}zt(o,u,{tag:r,attributes:e,value:a})}}(document),function(t){ct(this,void 0,void 0,(function(){var n,e,r,a,o,i,u,c,l,d,p,f,h;return st(this,(function(g){switch(n=s(),e=[n,t],t){case 8:r=I,e.push(r.width),e.push(r.height),r.width,r.height,Wt(e);break;case 43:if((a=Mt).length>0){for(o=0,i=a;o<i.length;o++)for(u=i[o],c=u.metadata.privacy,l=u.data,d=0,p=["tag","attributes","value"];d<p.length;d++)if(l[f=p[d]])switch(f){case"tag":e.push(u.id),u.parent&&e.push(u.parent),u.previous&&e.push(u.previous),e.push(l[f]);break;case"attributes":for(h in l[f])void 0!==l[f][h]&&e.push(Ot(h,l[f][h],c));break;case"value":e.push(m(l[f],l.tag,c))}Wt(function(t){for(var n=[],e={},r=0,a=null,o=0;o<t.length;o++)if("string"==typeof t[o]){var i=t[o],u=e[i]||-1;u>=0?a?a.push(u):(a=[u],n.push(a),r++):(a=null,n.push(i),e[i]=r++)}else a=null,n.push(t[o]),r++;return n}(e),!0)}}return[2]}))}))}(43)}function jt(t){var n={},e=t.attributes;if(e&&e.length>0)for(var r=0;r<e.length;r++)n[e[r].name]=e[r].value;return n}function zt(t,n,e){if(t&&e&&e.tag){var r=function(t){return null===t?null:Ct.has(t)?Ct.get(t):(Ct.set(t,xt),xt++)}(t),a=n?Ct.get(n):null,o=t.previousSibling?Ct.get(t.previousSibling):null;Mt.push({id:r,parent:a,previous:o,children:[],data:e,selector:null,hash:null,region:null,metadata:{active:!0,suspend:!1,privacy:5,position:null,fraud:null,size:null}})}}var At,Pt,qt,Dt,Rt,Lt,Ut=0,Ht=0,Xt=null,Vt=0,Yt=!1;function Bt(){Dt=!0,Ut=0,Ht=0,Yt=!1,Vt=0,At=[],Pt=[],qt={},Rt=null}function Wt(t,n){if(void 0===n&&(n=!0),Dt){var e=s(),r=t.length>1?t[1]:null,a=JSON.stringify(t);switch(o.lean?!Yt&&Ht+a.length>10485760&&(Yt=!0):Yt=!1,r){case 5:if(Yt)break;Ut+=a.length;case 37:case 6:case 43:case 45:case 46:case 44:case 51:if(Yt)break;Ht+=a.length,At.push(a);break;default:Pt.push(a)}J(25);var i=function(){var t=!1===o.lean&&Ut>0?100:Ln.sequence*o.delay;return"string"==typeof o.upload?Math.max(Math.min(t,3e4),100):o.delay}();e-Vt>2*i&&(Q(Xt),Xt=null),n&&null===Xt&&(25!==r&&et(),Xt=K(Jt,i),Vt=e,tn(Ht))}}function Zt(){Q(Xt),Jt(!0),Ut=0,Ht=0,Yt=!1,Vt=0,At=[],Pt=[],qt={},Rt=null,Dt=!1}function Jt(t){return void 0===t&&(t=!1),ct(this,void 0,void 0,(function(){var n,e,r,a,i,u,c,s;return st(this,(function(l){switch(l.label){case 0:return Dt?(Xt=null,(n=!1===o.lean&&Ht>0&&(Ht<1048576||Ln.sequence>0))&&F(1,1),Tt(),e=!0===t,Ln?(r=JSON.stringify(Xn(e)),a="[".concat(Pt.join(),"]"),i=n?"[".concat(At.join(),"]"):"",e&&i.length>0&&r.length+a.length+i.length>65536&&(i=""),u=function(t){return t.p.length>0?'{"e":'.concat(t.e,',"a":').concat(t.a,',"p":').concat(t.p,"}"):'{"e":'.concat(t.e,',"a":').concat(t.a,"}")}({e:r,a:a,p:i}),e?(s=null,[3,3]):[3,1]):[2]):[2];case 1:return[4,bt(u)];case 2:s=l.sent(),l.label=3;case 3:return G(2,(c=s)?c.length:u.length),Gt(u,c,Ln.sequence,e),Pt=[],n&&(At=[],Ht=0,Ut=0,Yt=!1),[2]}}))}))}function Gt(t,n,e,r){if(void 0===r&&(r=!1),"string"==typeof o.upload){var a=o.upload,i=!1;if(r&&navigator&&navigator.sendBeacon)try{(i=navigator.sendBeacon.bind(navigator)(a,t))&&Kt(e)}catch(t){}if(!1===i){e in qt?qt[e].attempts++:qt[e]={data:t,attempts:1};var u=new XMLHttpRequest;u.open("POST",a,!0),u.timeout=15e3,u.ontimeout=function(){Yn(new Error("".concat("Timeout"," : ").concat(a)))},null!==e&&(u.onreadystatechange=function(){Bn(Ft)(u,e)}),u.withCredentials=!0,n?(u.setRequestHeader("Accept","application/x-clarity-gzip"),u.send(n)):u.send(t)}}else if(o.upload){(0,o.upload)(t),Kt(e)}}function Ft(t,n){var e=qt[n];t&&4===t.readyState&&e&&((t.status<200||t.status>208)&&e.attempts<=1?t.status>=400&&t.status<500?nn(6):(0===t.status&&(o.upload=o.fallback?o.fallback:o.upload),Rt={sequence:n,attempts:e.attempts,status:t.status},Qt(2),Gt(e.data,null,n)):(Rt={sequence:n,attempts:e.attempts,status:t.status},e.attempts>1&&Qt(2),200===t.status&&t.responseText&&function(t){for(var n=t&&t.length>0?t.split("\n"):[],e=0,r=n;e<r.length;e++){var a=r[e],i=a&&a.length>0?a.split(/ (.*)/):[""];switch(i[0]){case"END":nn(6);break;case"UPGRADE":it("Auto");break;case"ACTION":o.action&&i.length>1&&o.action(i[1]);break;case"EXTRACT":case"MODULE":i.length>1&&i[1];break;case"SIGNAL":i.length>1&&_t(i[1]);break;case"SNAPSHOT":o.lean=!1,Nt()}}}(t.responseText),0===t.status&&(Gt(e.data,null,n,!0),nn(3)),t.status>=200&&t.status<=208&&Kt(n),delete qt[n]))}function Kt(t){1===t&&(xn(),Mn())}function Qt(t){var n=[s(),t];switch(t){case 4:var e=E;e&&e.data&&((n=[e.time,e.event]).push(e.data.visible),n.push(e.data.docWidth),n.push(e.data.docHeight),n.push(e.data.screenWidth),n.push(e.data.screenHeight),n.push(e.data.scrollX),n.push(e.data.scrollY),n.push(e.data.pointerX),n.push(e.data.pointerY),n.push(e.data.activityTime),n.push(e.data.scrollTime),n.push(e.data.pointerTime),n.push(e.data.moveX),n.push(e.data.moveY),n.push(e.data.moveTime),n.push(e.data.downX),n.push(e.data.downY),n.push(e.data.downTime),n.push(e.data.upX),n.push(e.data.upY),n.push(e.data.upTime),n.push(e.data.pointerPrevX),n.push(e.data.pointerPrevY),n.push(e.data.pointerPrevTime),n.push(e.data.modules),Wt(n,!1));break;case 25:n.push(B.gap),Wt(n);break;case 35:n.push(Lt.check),Wt(n,!1);break;case 3:n.push(ot.key),Wt(n);break;case 2:n.push(Rt.sequence),n.push(Rt.attempts),n.push(Rt.status),Wt(n,!1);break;case 24:V.key&&n.push(V.key),n.push(V.value),Wt(n);break;case 34:var r=Object.keys(lt);if(r.length>0){for(var a=0,o=r;a<o.length;a++){var i=o[a];n.push(i),n.push(lt[i])}gt(),Wt(n,!1)}break;case 0:var u=Object.keys(Z);if(u.length>0){for(var c=0,l=u;c<l.length;c++){var d=l[c],p=parseInt(d,10);n.push(p),n.push(Math.round(Z[d]))}Z={},Wt(n,!1)}break;case 1:var f=Object.keys(on);if(f.length>0){for(var h=0,g=f;h<g.length;h++){var v=g[h];p=parseInt(v,10);n.push(p),n.push(on[v])}pn(),Wt(n,!1)}break;case 36:var m=Object.keys(I);if(m.length>0){for(var y=0,b=m;y<b.length;y++){var w=b[y];p=parseInt(w,10);n.push(p),n.push([].concat.apply([],I[w]))}Wt(n,!1)}break;case 40:O.forEach((function(t){n.push(t);var e=[];for(var r in I[t]){var a=parseInt(r,10);e.push(a),e.push(I[t][r])}n.push(e)})),Wt(n,!1);break;case 47:n.push(A.source),n.push(A.ad_Storage),n.push(A.analytics_Storage),Wt(n,!1)}}function $t(){Lt={check:0}}function tn(t){if(0===Lt.check){var n=Lt.check;n=Ln.sequence>=128?1:n,n=Ln.pageNum>=128?7:n,n=s()>72e5?2:n,(n=t>10485760?2:n)!==Lt.check&&nn(n)}}function nn(t){Lt.check=t,5!==t&&(On(),Pe())}function en(){0!==Lt.check&&Qt(35)}function rn(){Lt=null}var an=null,on=null,un=!1;function cn(){an={},on={},un=!1}function sn(){an={},on={},un=!1}function ln(t,n){if(n&&(n="".concat(n),t in an||(an[t]=[]),an[t].indexOf(n)<0)){if(an[t].length>128)return void(un||(un=!0,nn(5)));an[t].push(n),t in on||(on[t]=[]),on[t].push(n)}}function dn(){Qt(1)}function pn(){on={},un=!1}var fn=null,hn=[],gn=0,vn=null,mn=null,yn={ad_Storage:"denied",analytics_Storage:"denied"};function bn(){var t,n,e;vn=null;var r=navigator&&"userAgent"in navigator?navigator.userAgent:"",a=null!==(e="undefined"!=typeof Intl&&(null===(n=null===(t=null===Intl||void 0===Intl?void 0:Intl.DateTimeFormat())||void 0===t?void 0:t.resolvedOptions())||void 0===n?void 0:n.timeZone))&&void 0!==e?e:"",i=(new Date).getTimezoneOffset().toString(),u=window.location.ancestorOrigins?Array.from(window.location.ancestorOrigins).toString():"",c=document&&document.title?document.title:"";gn=r.indexOf("Electron")>0?1:0;var s=function(){var t={session:jn(),ts:Math.round(Date.now()),count:1,upgrade:null,upload:""},n=Pn("_clsk",!o.includeSubdomains);if(n){var e=n.includes("^")?n.split("^"):n.split("|");e.length>=5&&t.ts-zn(e[1])<18e5&&(t.session=e[0],t.count=zn(e[2])+1,t.upgrade=zn(e[3]),t.upload=e.length>=6?"".concat("https://").concat(e[5],"/").concat(e[4]):"".concat("https://").concat(e[4]))}return t}(),l=An(),d=o.projectId||function(t,n){void 0===n&&(n=null);for(var e,r=5381,a=r,o=0;o<t.length;o+=2)r=(r<<5)+r^t.charCodeAt(o),o+1<t.length&&(a=(a<<5)+a^t.charCodeAt(o+1));return e=Math.abs(r+11579*a),(n?e%Math.pow(2,n):e).toString(36)}(location.host);fn={projectId:d,userId:l.id,sessionId:s.session,pageNum:s.count},o.lean=o.track&&null!==s.upgrade?0===s.upgrade:o.lean,o.upload=o.track&&"string"==typeof o.upload&&s.upload&&s.upload.length>"https://".length?s.upload:o.upload,ln(0,r),ln(3,c),ln(1,y(location.href,!!gn)),ln(2,document.referrer),ln(15,function(){var t=jn();if(o.track&&Cn(window,"sessionStorage")){var n=sessionStorage.getItem("_cltk");t=n||t,sessionStorage.setItem("_cltk",t)}return t}()),ln(16,document.documentElement.lang),ln(17,document.dir),ln(26,"".concat(window.devicePixelRatio)),ln(28,l.dob.toString()),ln(29,l.version.toString()),ln(33,u),ln(34,a),ln(35,i),F(0,s.ts),F(1,0),F(35,gn);var p,f=null===window||void 0===window?void 0:window.Zone;f&&"__symbol__"in f&&F(39,1),navigator&&(ln(9,navigator.language),F(33,navigator.hardwareConcurrency),F(32,navigator.maxTouchPoints),F(34,Math.round(navigator.deviceMemory)),(p=navigator.userAgentData)&&p.getHighEntropyValues?p.getHighEntropyValues(["model","platform","platformVersion","uaFullVersion"]).then((function(t){var n;ln(22,t.platform),ln(23,t.platformVersion),null===(n=t.brands)||void 0===n||n.forEach((function(t){ln(24,t.name+"~"+t.version)})),ln(25,t.model),F(27,t.mobile?1:0)})):ln(22,navigator.platform)),screen&&(F(14,Math.round(screen.width)),F(15,Math.round(screen.height)),F(16,Math.round(screen.colorDepth)));for(var h=0,g=o.cookies;h<g.length;h++){var v=g[h],m=Pn(v);m&&dt(v,m)}D(In(mn={ad_Storage:o.track?"granted":"denied",analytics_Storage:o.track?"granted":"denied"},0)),Nn(l)}function wn(){vn=null,fn=null,mn=null,hn.forEach((function(t){t.called=!1}))}function kn(t,n,e,r){void 0===n&&(n=!0),void 0===e&&(e=!1),void 0===r&&(r=!1);var a=o.lean?0:1,i=!1;fn&&(a||!1===n)&&(t(fn,!o.lean,r?mn:void 0),i=!0),!e&&i||hn.push({callback:t,wait:n,recall:e,called:i,consentInfo:r})}function _n(){return fn?[fn.userId,fn.sessionId,fn.pageNum].join("."):""}function Sn(t){void 0===t&&(t=!0),t?(En({ad_Storage:"granted",analytics_Storage:"granted"}),R()):En()}function En(t,n){void 0===t&&(t=yn),void 0===n&&(n=1),mn={ad_Storage:Tn(t.ad_Storage),analytics_Storage:Tn(t.analytics_Storage)},Mn(!0);var e=In(mn,n);if(!e.analytics_Storage)return o.track=!1,Dn("_clsk","",-Number.MAX_VALUE),Dn("_clck","",-Number.MAX_VALUE),Pe(),void window.setTimeout(Ae,250);pe()&&(o.track=!0,Nn(An(),1),xn(),U(e),R())}function In(t,n){return{source:n,ad_Storage:"granted"===t.ad_Storage?1:0,analytics_Storage:"granted"===t.analytics_Storage?1:0}}function Tn(t){return"string"==typeof t?t.toLowerCase():"denied"}function On(){Dn("_clsk","",0)}function Mn(t){void 0===t&&(t=!1),function(t,n){void 0===n&&(n=!1);if(hn.length>0)for(var e=0;e<hn.length;e++){var r=hn[e];r.callback&&(!r.called&&!n||r.consentInfo&&n)&&(!r.wait||t)&&(r.callback(fn,!o.lean,r.consentInfo?mn:void 0),r.called=!0,r.recall||(hn.splice(e,1),e--))}}(o.lean?0:1,t)}function xn(){if(fn&&o.track){var t=Math.round(Date.now()),n=o.upload&&"string"==typeof o.upload?o.upload.replace("https://",""):"",e=o.lean?0:1;Dn("_clsk",[fn.sessionId,t,fn.pageNum,e,n].join("^"),1)}}function Cn(t,n){try{return!!t[n]}catch(t){return!1}}function Nn(t,n){void 0===n&&(n=null),n=null===n?t.consent:n;var e=Math.ceil((Date.now()+31536e6)/864e5),r=0===t.dob?null===o.dob?0:o.dob:t.dob;(null===t.expiry||Math.abs(e-t.expiry)>=1||t.consent!==n||t.dob!==r)&&Dn("_clck",[fn.userId,2,e.toString(36),n,r].join("^"),365)}function jn(){var t=Math.floor(Math.random()*Math.pow(2,32));return window&&window.crypto&&window.crypto.getRandomValues&&Uint32Array&&(t=window.crypto.getRandomValues(new Uint32Array(1))[0]),t.toString(36)}function zn(t,n){return void 0===n&&(n=10),parseInt(t,n)}function An(){var t={id:jn(),version:0,expiry:null,consent:0,dob:0},n=Pn("_clck",!o.includeSubdomains);if(n&&n.length>0){var e=n.includes("^")?n.split("^"):n.split("|");e.length>1&&(t.version=zn(e[1])),e.length>2&&(t.expiry=zn(e[2],36)),e.length>3&&1===zn(e[3])&&(t.consent=1),e.length>4&&zn(e[1])>1&&(t.dob=zn(e[4])),o.track=o.track||1===t.consent,t.id=o.track?e[0]:t.id}return t}function Pn(t,n){var e;if(void 0===n&&(n=!1),Cn(document,"cookie")){var r=document.cookie.split(";");if(r)for(var a=0;a<r.length;a++){var o=r[a].split("=");if(o.length>1&&o[0]&&o[0].trim()===t){for(var i=qn(o[1]),u=i[0],c=i[1];u;)u=(e=qn(c))[0],c=e[1];return n?c.endsWith("".concat("~","1"))?c.substring(0,c.length-2):null:c}}}return null}function qn(t){try{var n=decodeURIComponent(t);return[n!=t,n]}catch(t){}return[!1,t]}function Dn(t,n,e){if((o.track||""==n)&&(navigator&&navigator.cookieEnabled||Cn(document,"cookie"))){var r=function(t){return encodeURIComponent(t)}(n),a=new Date;a.setDate(a.getDate()+e);var i=a?"expires="+a.toUTCString():"",u="".concat(t,"=").concat(r).concat(";").concat(i).concat(";path=/");try{if(null===vn){for(var c=location.hostname?location.hostname.split("."):[],s=c.length-1;s>=0;s--)if(vn=".".concat(c[s]).concat(vn||""),s<c.length-1&&(document.cookie="".concat(u).concat(";").concat("domain=").concat(vn),Pn(t)===n))return;vn=""}}catch(t){vn=""}document.cookie=vn?"".concat(u).concat(";").concat("domain=").concat(vn):u}}var Rn,Ln=null;function Un(){var t=fn;Ln={version:l,sequence:0,start:0,duration:0,projectId:t.projectId,userId:t.userId,sessionId:t.sessionId,pageNum:t.pageNum,upload:0,end:0,applicationPlatform:0,url:""}}function Hn(){Ln=null}function Xn(t){return Ln.start=Ln.start+Ln.duration,Ln.duration=s()-Ln.start,Ln.sequence++,Ln.upload=t&&"sendBeacon"in navigator?1:0,Ln.end=t?1:0,Ln.applicationPlatform=0,Ln.url=y(location.href,!1,!0),[Ln.version,Ln.sequence,Ln.start,Ln.duration,Ln.projectId,Ln.userId,Ln.sessionId,Ln.pageNum,Ln.upload,Ln.end,Ln.applicationPlatform,Ln.url]}function Vn(){Rn=[]}function Yn(t){if(Rn&&-1===Rn.indexOf(t.message)){var n=o.report;if(n&&n.length>0&&Ln){var e={v:Ln.version,p:Ln.projectId,u:Ln.userId,s:Ln.sessionId,n:Ln.pageNum};t.message&&(e.m=t.message),t.stack&&(e.e=t.stack);var r=new XMLHttpRequest;r.open("POST",n,!0),r.send(JSON.stringify(e)),Rn.push(t.message)}}return t}function Bn(t){return function(){var n=performance.now();try{t.apply(this,arguments)}catch(t){throw Yn(t)}var e=performance.now()-n;G(4,e),e>30&&(J(7),F(6,e),t.dn&&"".concat(t.dn,"-").concat(e))}}var Wn=new Map;function Zn(t,n,e,r,a){void 0===r&&(r=!1),void 0===a&&(a=!0),e=Bn(e);try{t[i("addEventListener")](n,e,{capture:r,passive:a}),function(t){return Wn.has(t)}(t)||Wn.set(t,[]),Wn.get(t).push({event:n,listener:e,options:{capture:r,passive:a}})}catch(t){}}function Jn(){Wn.forEach((function(t,n){!function(t,n){t.forEach((function(t){try{n[i("removeEventListener")](t.event,t.listener,{capture:t.options.capture,passive:t.options.passive})}catch(t){}})),Wn.delete(n)}(t,n)})),Wn=new Map}var Gn=null,Fn=null,Kn=null,Qn=0;function $n(){return!(Qn++>20)}function te(){Qn=0,Kn!==ee()&&(Pe(),window.setTimeout(ne,250))}function ne(){Ae(),F(29,1)}function ee(){return location.href?location.href.replace(location.hash,""):location.href}var re=[],ae=null,oe=null,ie=null;function ue(){re=[],ae=null,oe=null}function ce(){var t=re.shift();t&&(ae=t,t.task().then((function(){t.id===_n()&&(t.resolve(),ae=null,ce())})).catch((function(n){t.id===_n()&&(n&&(n.name,n.message,n.stack),ae=null,ce())})))}var se=!1;function le(){se=!0,u=c(),ue(),Jn(),Vn(),Kn=ee(),Qn=0,Zn(window,"popstate",te),null===Gn&&(Gn=history.pushState,history.pushState=function(){Gn.apply(this,arguments),pe()&&$n()&&te()}),null===Fn&&(Fn=history.replaceState,history.replaceState=function(){Fn.apply(this,arguments),pe()&&$n()&&te()})}function de(){Kn=null,Qn=0,Vn(),Jn(),ue(),u=0,se=!1}function pe(){return se}function fe(){Ae(),Y("clarity","restart")}var he=null;function ge(){he=null}function ve(t){he={fetchStart:Math.round(t.fetchStart),connectStart:Math.round(t.connectStart),connectEnd:Math.round(t.connectEnd),requestStart:Math.round(t.requestStart),responseStart:Math.round(t.responseStart),responseEnd:Math.round(t.responseEnd),domInteractive:Math.round(t.domInteractive),domComplete:Math.round(t.domComplete),loadEventStart:Math.round(t.loadEventStart),loadEventEnd:Math.round(t.loadEventEnd),redirectCount:Math.round(t.redirectCount),size:t.transferSize?t.transferSize:0,type:t.type,protocol:t.nextHopProtocol,encodedSize:t.encodedBodySize?t.encodedBodySize:0,decodedSize:t.decodedBodySize?t.decodedBodySize:0},function(t){ct(this,void 0,void 0,(function(){var n,e;return st(this,(function(r){return n=s(),e=[n,t],29===t&&(e.push(he.fetchStart),e.push(he.connectStart),e.push(he.connectEnd),e.push(he.requestStart),e.push(he.responseStart),e.push(he.responseEnd),e.push(he.domInteractive),e.push(he.domComplete),e.push(he.loadEventStart),e.push(he.loadEventEnd),e.push(he.redirectCount),e.push(he.size),e.push(he.type),e.push(he.protocol),e.push(he.encodedSize),e.push(he.decodedSize),ge(),Wt(e)),[2]}))}))}(29)}var me,ye=0,be=1/0,we=0,ke=0,_e=[],Se=new Map,Ee=function(){return ye||0},Ie=function(){if(!_e.length)return-1;var t=Math.min(_e.length-1,Math.floor((Ee()-ke)/50));return _e[t].latency},Te=function(){ke=Ee(),_e.length=0,Se.clear()},Oe=function(t){if(t.interactionId&&!(t.duration<40)){!function(t){"interactionCount"in performance?ye=performance.interactionCount:t.interactionId&&(be=Math.min(be,t.interactionId),we=Math.max(we,t.interactionId),ye=we?(we-be)/7+1:0)}(t);var n=_e[_e.length-1],e=Se.get(t.interactionId);if(e||_e.length<10||t.duration>(null==n?void 0:n.latency)){if(e)t.duration>e.latency&&(e.latency=t.duration);else{var r={id:t.interactionId,latency:t.duration};Se.set(r.id,r),_e.push(r)}_e.sort((function(t,n){return n.latency-t.latency})),_e.length>10&&_e.splice(10).forEach((function(t){return Se.delete(t.id)}))}}},Me=["navigation","resource","longtask","first-input","layout-shift","largest-contentful-paint","event"];function xe(){try{me&&me.disconnect(),me=new PerformanceObserver(Bn(Ce));for(var t=0,n=Me;t<n.length;t++){var e=n[t];PerformanceObserver.supportedEntryTypes.indexOf(e)>=0&&("layout-shift"===e&&G(9,0),me.observe({type:e,buffered:!0}))}}catch(t){}}function Ce(t){!function(t){for(var n=(!("visibilityState"in document)||"visible"===document.visibilityState),e=0;e<t.length;e++){var r=t[e];switch(r.entryType){case"navigation":ve(r);break;case"resource":var a=r.name;ln(4,je(a)),a!==o.upload&&a!==o.fallback||F(28,r.duration);break;case"longtask":J(7);break;case"first-input":n&&F(10,r.processingStart-r.startTime);break;case"event":n&&"PerformanceEventTiming"in window&&"interactionId"in PerformanceEventTiming.prototype&&(Oe(r),ln(37,Ie().toString()));break;case"layout-shift":n&&!r.hadRecentInput&&G(9,1e3*r.value);break;case"largest-contentful-paint":n&&F(8,r.startTime)}}}(t.getEntries())}var Ne=null;function je(t){return Ne||(Ne=document.createElement("a")),Ne.href=t,Ne.host}var ze=[z,z,z,Object.freeze({__proto__:null,start:function(){ge(),function(){navigator&&navigator.connection&&ln(27,navigator.connection.effectiveType),window.PerformanceObserver&&PerformanceObserver.supportedEntryTypes&&("complete"!==document.readyState?Zn(window,"load",K.bind(this,xe,0)):xe())}()},stop:function(){me&&me.disconnect(),me=null,Te(),Ne=null,ge()}}),z];function Ae(t){void 0===t&&(t=null),function(){try{var t=navigator&&"globalPrivacyControl"in navigator&&1==navigator.globalPrivacyControl;return!1===se&&"undefined"!=typeof Promise&&window.MutationObserver&&document.createTreeWalker&&"now"in Date&&"now"in performance&&"undefined"!=typeof WeakMap&&!t}catch(t){return!1}}()&&(!function(t){if(null===t||se)return!1;for(var n in t)n in o&&(o[n]=t[n])}(t),le(),Et(),ze.forEach((function(t){return Bn(t.start)()})),null===t&&Le())}function Pe(){pe()&&(ze.slice().reverse().forEach((function(t){return Bn(t.stop)()})),It(),de(),void 0!==De&&(De[Re]=function(){(De[Re].q=De[Re].q||[]).push(arguments),"start"===arguments[0]&&De[Re].q.unshift(De[Re].q.pop())&&Le()}))}var qe=Object.freeze({__proto__:null,consent:Sn,consentv2:En,dlog:ln,event:Y,hashText:M,identify:pt,maxMetric:F,measure:Bn,metadata:kn,pause:function(){pe()&&(Y("clarity","pause"),null===oe&&(oe=new Promise((function(t){ie=t}))))},queue:Wt,register:j,resume:function(){pe()&&(oe&&(ie(),oe=null,null===ae&&ce()),Y("clarity","resume"))},schedule:function(t,n){return void 0===n&&(n=0),ct(this,void 0,void 0,(function(){var e,r,a;return st(this,(function(o){for(e=0,r=re;e<r.length;e++)if(r[e].task===t)return[2];return a=new Promise((function(e){re[1===n?"unshift":"push"]({task:t,resolve:e,id:_n()})})),null===ae&&null===oe&&ce(),[2,a]}))}))},set:dt,signal:function(t){kt=t},start:Ae,stop:Pe,time:s,upgrade:it,version:l}),De=window,Re="clarity";function Le(){if(void 0!==De){if(De[Re]&&De[Re].v)return console.warn("Error CL001: Multiple Clarity tags detected.");var t=De[Re]&&De[Re].q||[];for(De[Re]=function(t){for(var n=[],e=1;e<arguments.length;e++)n[e-1]=arguments[e];return qe[t].apply(qe,n)},De[Re].v=l;t.length>0;)De[Re].apply(De,t.shift())}}Le()}();
1
+ !function(){"use strict";var t=Object.freeze({__proto__:null,get queue(){return Wt},get start(){return Bt},get stop(){return Zt},get track(){return Rt}}),n=Object.freeze({__proto__:null,get check(){return tn},get compute(){return en},get data(){return Lt},get start(){return $t},get stop(){return rn},get trigger(){return nn}}),e=Object.freeze({__proto__:null,get compute(){return dn},get data(){return an},get log(){return ln},get reset(){return pn},get start(){return cn},get stop(){return sn},get updates(){return on}}),r=Object.freeze({__proto__:null,get callback(){return Mn},get callbacks(){return hn},get clear(){return On},get consent(){return Sn},get consentv2(){return En},get data(){return fn},get electron(){return gn},get id(){return _n},get metadata(){return kn},get save(){return xn},get shortid(){return jn},get start(){return bn},get stop(){return wn}}),a=Object.freeze({__proto__:null,get data(){return Ln},get envelope(){return Xn},get start(){return Un},get stop(){return Hn}}),o={projectId:null,delay:1e3,lean:!1,lite:!1,track:!0,content:!0,drop:[],mask:[],unmask:[],regions:[],cookies:[],fraud:!0,checksum:[],report:null,upload:null,fallback:null,upgrade:null,action:null,dob:null,delayDom:!1,throttleDom:!0,conversions:!1,includeSubdomains:!0};function i(t){return window.Zone&&"__symbol__"in window.Zone?window.Zone.__symbol__(t):t}var u=0;function c(){return performance.now()+performance.timeOrigin}function s(t){void 0===t&&(t=null);var n=0===u?c():u,e=t&&t.timeStamp>0?t.timeStamp:performance.now(),r=t&&t.view?t.view.performance.timeOrigin:performance.timeOrigin;return Math.max(Math.round(e+r-n),0)}var l="0.8.39";var d=/\S/gi,p=255,f=!0,h=null,g=null,v=null;function m(t,n,e,r,a){if(void 0===r&&(r=!1),t){if("input"==n&&("checkbox"===a||"radio"===a))return t;switch(e){case 0:return t;case 1:switch(n){case"*T":case"value":case"placeholder":case"click":return function(t){var n=-1,e=0,r=!1,a=!1,o=!1,i=null;S();for(var u=0;u<t.length;u++){var c=t.charCodeAt(u);if(r=r||c>=48&&c<=57,a=a||64===c,o=9===c||10===c||13===c||32===c,0===u||u===t.length-1||o){if(r||a){null===i&&(i=t.split(""));var s=t.substring(n+1,o?u:u+1);s=f&&null!==v?s.match(v)?s:k(s,"▪","▫"):w(s),i.splice(n+1-e,s.length,s),e+=s.length-1}o&&(r=!1,a=!1,n=u)}}return i?i.join(""):t}(t);case"input":case"change":return _(t)}return t;case 2:case 3:switch(n){case"*T":case"data-":return r?b(t):w(t);case"src":case"srcset":case"title":case"alt":return 3===e?"src"===n&&(null==t?void 0:t.startsWith("blob:"))?"blob:":"":t;case"value":case"click":case"input":case"change":return _(t);case"placeholder":return w(t)}break;case 4:switch(n){case"*T":case"data-":return r?b(t):w(t);case"value":case"input":case"click":case"change":return Array(5).join("•");case"checksum":return""}break;case 5:switch(n){case"*T":case"data-":return k(t,"▪","▫");case"value":case"input":case"click":case"change":return Array(5).join("•");case"checksum":case"src":case"srcset":case"alt":case"title":return""}}}return t}function y(t,n,e){void 0===n&&(n=!1),void 0===e&&(e=!1);var r=t;if(n)r="".concat("https://").concat("Electron");else{var a=o.drop;if(a&&a.length>0&&t&&t.indexOf("?")>0){var i=t.split("?"),u=i[0],c=i[1];r=u+"?"+c.split("&").map((function(t){return a.some((function(n){return 0===t.indexOf("".concat(n,"="))}))?"".concat(t.split("=")[0],"=").concat("*na*"):t})).join("&")}}return e&&(r=r.substring(0,p)),r}function b(t){var n=t.trim();if(n.length>0){var e=n[0],r=t.indexOf(e),a=t.substr(0,r),o=t.substr(r+n.length);return"".concat(a).concat(n.length.toString(36)).concat(o)}return t}function w(t){return t.replace(d,"•")}function k(t,n,e){return S(),t?t.replace(g,n).replace(h,e):t}function _(t){for(var n=5*(Math.floor(t.length/5)+1),e="",r=0;r<n;r++)e+=r>0&&r%5==0?" ":"•";return e}function S(){if(f&&null===h)try{h=new RegExp("\\p{N}","gu"),g=new RegExp("\\p{L}","gu"),v=new RegExp("\\p{Sc}","gu")}catch(t){f=!1}}var E=[],I=null;function T(){}var O=[];function M(){}function x(){}function C(){}function N(){}function j(){}var z=Object.freeze({__proto__:null,checkDocumentStyles:function(t){},compute:function(){},data:I,event:N,hashText:M,keys:O,log:T,observe:function(){},register:j,reset:function(){},sheetAdoptionState:[],sheetUpdateState:[],start:function(){},state:E,stop:function(){},track:C,trigger:x}),A=null,P=!0;function q(){var t,n=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics;if(null==n?void 0:n.getConsentState){var e=n.getConsentState("analytics_storage");En(function(t){var n={ad_Storage:1===t.ad_Storage?"granted":"denied",analytics_Storage:1===t.analytics_Storage?"granted":"denied"};return n}({ad_Storage:n.getConsentState("ad_storage"),analytics_Storage:e}),2)}}function D(t){L(t.analytics_Storage?1:0),A=t}function R(){L(2)}function L(t){ln(36,t.toString())}function U(t){A=t,Qt(47)}function H(){var t;if(P){Qt(47),P=!1;var n=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics;(null==n?void 0:n.usedUpdate)&&q()}}var X=Object.freeze({__proto__:null,compute:H,config:D,consent:R,get data(){return A},start:function(){var t,n=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics;P=!0,(null==n?void 0:n.addListener)&&n.addListener(["ad_storage","analytics_storage"],q)},stop:function(){P=!0},trackConsentv2:U}),V=null;function Y(t,n){pe()&&t&&"string"==typeof t&&t.length<255&&(V=n&&"string"==typeof n&&n.length<255?{key:t,value:n}:{value:t},Qt(24))}var B,W=null,Z=null;function J(t){t in W||(W[t]=0),t in Z||(Z[t]=0),W[t]++,Z[t]++}function G(t,n){null!==n&&(t in W||(W[t]=0),t in Z||(Z[t]=0),W[t]+=n,Z[t]+=n)}function F(t,n){null!==n&&!1===isNaN(n)&&(t in W||(W[t]=0),(n>W[t]||0===W[t])&&(Z[t]=n,W[t]=n))}function K(t,n,e){return window.setTimeout(Bn(t),n,e)}function Q(t){return window.clearTimeout(t)}var $=0,tt=0,nt=null;function et(){nt&&Q(nt),nt=K(rt,tt),$=s()}function rt(){var t=s();B={gap:t-$},Qt(25),B.gap<3e5?nt=K(rt,tt):se&&(Y("clarity","suspend"),Pe(),["mousemove","touchstart"].forEach((function(t){return Zn(document,t,fe)})),["resize","scroll","pageshow"].forEach((function(t){return Zn(window,t,fe)})))}var at=Object.freeze({__proto__:null,get data(){return B},reset:et,start:function(){tt=6e4,$=0},stop:function(){Q(nt),$=0,tt=0}}),ot=null;function it(t){pe()&&o.lean&&(o.lean=!1,ot={key:t},Mn(),xn(),o.upgrade&&o.upgrade(t),Qt(3),o.lite)}var ut=Object.freeze({__proto__:null,get data(){return ot},start:function(){!o.lean&&o.upgrade&&o.upgrade("Config"),ot=null},stop:function(){ot=null},upgrade:it});function ct(t,n,e,r){return new(e||(e=Promise))((function(a,o){function i(t){try{c(r.next(t))}catch(t){o(t)}}function u(t){try{c(r.throw(t))}catch(t){o(t)}}function c(t){var n;t.done?a(t.value):(n=t.value,n instanceof e?n:new e((function(t){t(n)}))).then(i,u)}c((r=r.apply(t,n||[])).next())}))}function st(t,n){var e,r,a,o,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return o={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(u){return function(c){return function(u){if(e)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(e=1,r&&(a=2&u[0]?r.return:u[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,u[1])).done)return a;switch(r=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,r=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=i.trys,(a=a.length>0&&a[a.length-1])||6!==u[0]&&2!==u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=n.call(t,i)}catch(t){u=[6,t],r=0}finally{e=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,c])}}}var lt=null;function dt(t,n){ft(t,"string"==typeof n?[n]:n)}function pt(t,n,e,r){return void 0===n&&(n=null),void 0===e&&(e=null),void 0===r&&(r=null),ct(this,void 0,void 0,(function(){var a,o;return st(this,(function(i){switch(i.label){case 0:return o={},[4,vt(t)];case 1:return o.userId=i.sent(),o.userHint=r||((u=t)&&u.length>=5?"".concat(u.substring(0,2)).concat(k(u.substring(2),"*","*")):k(u,"*","*")),ft("userId",[(a=o).userId]),ft("userHint",[a.userHint]),ft("userType",[mt(t)]),n&&(ft("sessionId",[n]),a.sessionId=n),e&&(ft("pageId",[e]),a.pageId=e),[2,a]}var u}))}))}function ft(t,n){if(pe()&&t&&n&&"string"==typeof t&&t.length<255){for(var e=(t in lt?lt[t]:[]),r=0;r<n.length;r++)"string"==typeof n[r]&&n[r].length<255&&e.push(n[r]);lt[t]=e}}function ht(){Qt(34)}function gt(){lt={}}function vt(t){return ct(this,void 0,void 0,(function(){var n;return st(this,(function(e){switch(e.label){case 0:return e.trys.push([0,4,,5]),crypto&&t?[4,crypto.subtle.digest("SHA-256",(new TextEncoder).encode(t))]:[3,2];case 1:return n=e.sent(),[2,Array.prototype.map.call(new Uint8Array(n),(function(t){return("00"+t.toString(16)).slice(-2)})).join("")];case 2:return[2,""];case 3:return[3,5];case 4:return e.sent(),[2,""];case 5:return[2]}}))}))}function mt(t){return t&&t.indexOf("@")>0?"email":"string"}var yt="CompressionStream"in window;function bt(t){return ct(this,void 0,void 0,(function(){var n,e;return st(this,(function(r){switch(r.label){case 0:return r.trys.push([0,3,,4]),yt?(n=new ReadableStream({start:function(n){return ct(this,void 0,void 0,(function(){return st(this,(function(e){return n.enqueue(t),n.close(),[2]}))}))}}).pipeThrough(new TextEncoderStream).pipeThrough(new window.CompressionStream("gzip")),e=Uint8Array.bind,[4,wt(n)]):[3,2];case 1:return[2,new(e.apply(Uint8Array,[void 0,r.sent()]))];case 2:return[3,4];case 3:return r.sent(),[3,4];case 4:return[2,null]}}))}))}function wt(t){return ct(this,void 0,void 0,(function(){var n,e,r,a,o;return st(this,(function(i){switch(i.label){case 0:n=t.getReader(),e=[],r=!1,a=[],i.label=1;case 1:return r?[3,3]:[4,n.read()];case 2:return o=i.sent(),r=o.done,a=o.value,r?[2,e]:(e.push.apply(e,a),[3,1]);case 3:return[2,e]}}))}))}var kt=null;function _t(t){try{if(!kt)return;var n=function(t){try{return JSON.parse(t)}catch(t){return[]}}(t);n.forEach((function(t){kt(t)}))}catch(t){}}var St=[z,e,Object.freeze({__proto__:null,compute:ht,get data(){return lt},identify:pt,reset:gt,set:dt,start:function(){gt()},stop:function(){gt()}}),n,z,X,r,a,t,at,ut,z];function Et(){W={},Z={},J(5),St.forEach((function(t){return Bn(t.start)()}))}function It(){St.slice().reverse().forEach((function(t){return Bn(t.stop)()})),W={},Z={}}function Tt(){ht(),dn(),Qt(0),en(),H()}function Ot(t,n,e){return"".concat(t,"=").concat(m(n,0===t.indexOf("data-")?"data-":t,e))}var Mt=[],xt=1,Ct=null;function Nt(){Mt=[],function(t){var n=[t];for(;n.length>0;){for(var e=null,r=null,a=null,o=n.shift(),i=o.firstChild,u=o.parentElement?o.parentElement:o.parentNode?o.parentNode:null;i;)n.push(i),i=i.nextSibling;switch(o.nodeType){case Node.DOCUMENT_TYPE_NODE:var c=o;r="*D",e={name:c.name,publicId:c.publicId,systemId:c.systemId};break;case Node.TEXT_NODE:a=o.nodeValue,r=Ct.get(u)?"*T":r;break;case Node.ELEMENT_NODE:var s=o;e=jt(s),r=["NOSCRIPT","SCRIPT","STYLE"].indexOf(s.tagName)<0?s.tagName:r}zt(o,u,{tag:r,attributes:e,value:a})}}(document),function(t){ct(this,void 0,void 0,(function(){var n,e,r,a,o,i,u,c,l,d,p,f,h;return st(this,(function(g){switch(n=s(),e=[n,t],t){case 8:r=I,e.push(r.width),e.push(r.height),r.width,r.height,Wt(e);break;case 43:if((a=Mt).length>0){for(o=0,i=a;o<i.length;o++)for(u=i[o],c=u.metadata.privacy,l=u.data,d=0,p=["tag","attributes","value"];d<p.length;d++)if(l[f=p[d]])switch(f){case"tag":e.push(u.id),u.parent&&e.push(u.parent),u.previous&&e.push(u.previous),e.push(l[f]);break;case"attributes":for(h in l[f])void 0!==l[f][h]&&e.push(Ot(h,l[f][h],c));break;case"value":e.push(m(l[f],l.tag,c))}Wt(function(t){for(var n=[],e={},r=0,a=null,o=0;o<t.length;o++)if("string"==typeof t[o]){var i=t[o],u=e[i]||-1;u>=0?a?a.push(u):(a=[u],n.push(a),r++):(a=null,n.push(i),e[i]=r++)}else a=null,n.push(t[o]),r++;return n}(e),!0)}}return[2]}))}))}(43)}function jt(t){var n={},e=t.attributes;if(e&&e.length>0)for(var r=0;r<e.length;r++)n[e[r].name]=e[r].value;return n}function zt(t,n,e){if(t&&e&&e.tag){var r=function(t){return null===t?null:Ct.has(t)?Ct.get(t):(Ct.set(t,xt),xt++)}(t),a=n?Ct.get(n):null,o=t.previousSibling?Ct.get(t.previousSibling):null;Mt.push({id:r,parent:a,previous:o,children:[],data:e,selector:null,hash:null,region:null,metadata:{active:!0,suspend:!1,privacy:5,position:null,fraud:null,size:null}})}}var At,Pt,qt,Dt,Rt,Lt,Ut=0,Ht=0,Xt=null,Vt=0,Yt=!1;function Bt(){Dt=!0,Ut=0,Ht=0,Yt=!1,Vt=0,At=[],Pt=[],qt={},Rt=null}function Wt(t,n){if(void 0===n&&(n=!0),Dt){var e=s(),r=t.length>1?t[1]:null,a=JSON.stringify(t);switch(o.lean?!Yt&&Ht+a.length>10485760&&(Yt=!0):Yt=!1,r){case 5:if(Yt)break;Ut+=a.length;case 37:case 6:case 43:case 45:case 46:case 44:case 51:if(Yt)break;Ht+=a.length,At.push(a);break;default:Pt.push(a)}J(25);var i=function(){var t=!1===o.lean&&Ut>0?100:Ln.sequence*o.delay;return"string"==typeof o.upload?Math.max(Math.min(t,3e4),100):o.delay}();e-Vt>2*i&&(Q(Xt),Xt=null),n&&null===Xt&&(25!==r&&et(),Xt=K(Jt,i),Vt=e,tn(Ht))}}function Zt(){Q(Xt),Jt(!0),Ut=0,Ht=0,Yt=!1,Vt=0,At=[],Pt=[],qt={},Rt=null,Dt=!1}function Jt(t){return void 0===t&&(t=!1),ct(this,void 0,void 0,(function(){var n,e,r,a,i,u,c,s;return st(this,(function(l){switch(l.label){case 0:return Dt?(Xt=null,(n=!1===o.lean&&Ht>0&&(Ht<1048576||Ln.sequence>0))&&F(1,1),Tt(),e=!0===t,Ln?(r=JSON.stringify(Xn(e)),a="[".concat(Pt.join(),"]"),i=n?"[".concat(At.join(),"]"):"",e&&i.length>0&&r.length+a.length+i.length>65536&&(i=""),u=function(t){return t.p.length>0?'{"e":'.concat(t.e,',"a":').concat(t.a,',"p":').concat(t.p,"}"):'{"e":'.concat(t.e,',"a":').concat(t.a,"}")}({e:r,a:a,p:i}),e?(s=null,[3,3]):[3,1]):[2]):[2];case 1:return[4,bt(u)];case 2:s=l.sent(),l.label=3;case 3:return G(2,(c=s)?c.length:u.length),Gt(u,c,Ln.sequence,e),Pt=[],n&&(At=[],Ht=0,Ut=0,Yt=!1),[2]}}))}))}function Gt(t,n,e,r){if(void 0===r&&(r=!1),"string"==typeof o.upload){var a=o.upload,i=!1;if(r&&navigator&&navigator.sendBeacon)try{(i=navigator.sendBeacon.bind(navigator)(a,t))&&Kt(e)}catch(t){}if(!1===i){e in qt?qt[e].attempts++:qt[e]={data:t,attempts:1};var u=new XMLHttpRequest;u.open("POST",a,!0),u.timeout=15e3,u.ontimeout=function(){Yn(new Error("".concat("Timeout"," : ").concat(a)))},null!==e&&(u.onreadystatechange=function(){Bn(Ft)(u,e)}),u.withCredentials=!0,n?(u.setRequestHeader("Accept","application/x-clarity-gzip"),u.send(n)):u.send(t)}}else if(o.upload){(0,o.upload)(t),Kt(e)}}function Ft(t,n){var e=qt[n];t&&4===t.readyState&&e&&((t.status<200||t.status>208)&&e.attempts<=1?t.status>=400&&t.status<500?nn(6):(0===t.status&&(o.upload=o.fallback?o.fallback:o.upload),Rt={sequence:n,attempts:e.attempts,status:t.status},Qt(2),Gt(e.data,null,n)):(Rt={sequence:n,attempts:e.attempts,status:t.status},e.attempts>1&&Qt(2),200===t.status&&t.responseText&&function(t){for(var n=t&&t.length>0?t.split("\n"):[],e=0,r=n;e<r.length;e++){var a=r[e],i=a&&a.length>0?a.split(/ (.*)/):[""];switch(i[0]){case"END":nn(6);break;case"UPGRADE":it("Auto");break;case"ACTION":o.action&&i.length>1&&o.action(i[1]);break;case"EXTRACT":case"MODULE":i.length>1&&i[1];break;case"SIGNAL":i.length>1&&_t(i[1]);break;case"SNAPSHOT":o.lean=!1,Nt()}}}(t.responseText),0===t.status&&(Gt(e.data,null,n,!0),nn(3)),t.status>=200&&t.status<=208&&Kt(n),delete qt[n]))}function Kt(t){1===t&&(xn(),Mn())}function Qt(t){var n=[s(),t];switch(t){case 4:var e=E;e&&e.data&&((n=[e.time,e.event]).push(e.data.visible),n.push(e.data.docWidth),n.push(e.data.docHeight),n.push(e.data.screenWidth),n.push(e.data.screenHeight),n.push(e.data.scrollX),n.push(e.data.scrollY),n.push(e.data.pointerX),n.push(e.data.pointerY),n.push(e.data.activityTime),n.push(e.data.scrollTime),n.push(e.data.pointerTime),n.push(e.data.moveX),n.push(e.data.moveY),n.push(e.data.moveTime),n.push(e.data.downX),n.push(e.data.downY),n.push(e.data.downTime),n.push(e.data.upX),n.push(e.data.upY),n.push(e.data.upTime),n.push(e.data.pointerPrevX),n.push(e.data.pointerPrevY),n.push(e.data.pointerPrevTime),n.push(e.data.modules),Wt(n,!1));break;case 25:n.push(B.gap),Wt(n);break;case 35:n.push(Lt.check),Wt(n,!1);break;case 3:n.push(ot.key),Wt(n);break;case 2:n.push(Rt.sequence),n.push(Rt.attempts),n.push(Rt.status),Wt(n,!1);break;case 24:V.key&&n.push(V.key),n.push(V.value),Wt(n);break;case 34:var r=Object.keys(lt);if(r.length>0){for(var a=0,o=r;a<o.length;a++){var i=o[a];n.push(i),n.push(lt[i])}gt(),Wt(n,!1)}break;case 0:var u=Object.keys(Z);if(u.length>0){for(var c=0,l=u;c<l.length;c++){var d=l[c],p=parseInt(d,10);n.push(p),n.push(Math.round(Z[d]))}Z={},Wt(n,!1)}break;case 1:var f=Object.keys(on);if(f.length>0){for(var h=0,g=f;h<g.length;h++){var v=g[h];p=parseInt(v,10);n.push(p),n.push(on[v])}pn(),Wt(n,!1)}break;case 36:var m=Object.keys(I);if(m.length>0){for(var y=0,b=m;y<b.length;y++){var w=b[y];p=parseInt(w,10);n.push(p),n.push([].concat.apply([],I[w]))}Wt(n,!1)}break;case 40:O.forEach((function(t){n.push(t);var e=[];for(var r in I[t]){var a=parseInt(r,10);e.push(a),e.push(I[t][r])}n.push(e)})),Wt(n,!1);break;case 47:n.push(A.source),n.push(A.ad_Storage),n.push(A.analytics_Storage),Wt(n,!1)}}function $t(){Lt={check:0}}function tn(t){if(0===Lt.check){var n=Lt.check;n=Ln.sequence>=128?1:n,n=Ln.pageNum>=128?7:n,n=s()>72e5?2:n,(n=t>10485760?2:n)!==Lt.check&&nn(n)}}function nn(t){Lt.check=t,5!==t&&(On(),Pe())}function en(){0!==Lt.check&&Qt(35)}function rn(){Lt=null}var an=null,on=null,un=!1;function cn(){an={},on={},un=!1}function sn(){an={},on={},un=!1}function ln(t,n){if(n&&(n="".concat(n),t in an||(an[t]=[]),an[t].indexOf(n)<0)){if(an[t].length>128)return void(un||(un=!0,nn(5)));an[t].push(n),t in on||(on[t]=[]),on[t].push(n)}}function dn(){Qt(1)}function pn(){on={},un=!1}var fn=null,hn=[],gn=0,vn=null,mn=null,yn={ad_Storage:"denied",analytics_Storage:"denied"};function bn(){var t,n,e;vn=null;var r=navigator&&"userAgent"in navigator?navigator.userAgent:"",a=null!==(e="undefined"!=typeof Intl&&(null===(n=null===(t=null===Intl||void 0===Intl?void 0:Intl.DateTimeFormat())||void 0===t?void 0:t.resolvedOptions())||void 0===n?void 0:n.timeZone))&&void 0!==e?e:"",i=(new Date).getTimezoneOffset().toString(),u=window.location.ancestorOrigins?Array.from(window.location.ancestorOrigins).toString():"",c=document&&document.title?document.title:"";gn=r.indexOf("Electron")>0?1:0;var s=function(){var t={session:jn(),ts:Math.round(Date.now()),count:1,upgrade:null,upload:""},n=Pn("_clsk",!o.includeSubdomains);if(n){var e=n.includes("^")?n.split("^"):n.split("|");e.length>=5&&t.ts-zn(e[1])<18e5&&(t.session=e[0],t.count=zn(e[2])+1,t.upgrade=zn(e[3]),t.upload=e.length>=6?"".concat("https://").concat(e[5],"/").concat(e[4]):"".concat("https://").concat(e[4]))}return t}(),l=An(),d=o.projectId||function(t,n){void 0===n&&(n=null);for(var e,r=5381,a=r,o=0;o<t.length;o+=2)r=(r<<5)+r^t.charCodeAt(o),o+1<t.length&&(a=(a<<5)+a^t.charCodeAt(o+1));return e=Math.abs(r+11579*a),(n?e%Math.pow(2,n):e).toString(36)}(location.host);fn={projectId:d,userId:l.id,sessionId:s.session,pageNum:s.count},o.lean=o.track&&null!==s.upgrade?0===s.upgrade:o.lean,o.upload=o.track&&"string"==typeof o.upload&&s.upload&&s.upload.length>"https://".length?s.upload:o.upload,ln(0,r),ln(3,c),ln(1,y(location.href,!!gn)),ln(2,document.referrer),ln(15,function(){var t=jn();if(o.track&&Cn(window,"sessionStorage")){var n=sessionStorage.getItem("_cltk");t=n||t,sessionStorage.setItem("_cltk",t)}return t}()),ln(16,document.documentElement.lang),ln(17,document.dir),ln(26,"".concat(window.devicePixelRatio)),ln(28,l.dob.toString()),ln(29,l.version.toString()),ln(33,u),ln(34,a),ln(35,i),F(0,s.ts),F(1,0),F(35,gn);var p,f=null===window||void 0===window?void 0:window.Zone;f&&"__symbol__"in f&&F(39,1),navigator&&(ln(9,navigator.language),F(33,navigator.hardwareConcurrency),F(32,navigator.maxTouchPoints),F(34,Math.round(navigator.deviceMemory)),(p=navigator.userAgentData)&&p.getHighEntropyValues?p.getHighEntropyValues(["model","platform","platformVersion","uaFullVersion"]).then((function(t){var n;ln(22,t.platform),ln(23,t.platformVersion),null===(n=t.brands)||void 0===n||n.forEach((function(t){ln(24,t.name+"~"+t.version)})),ln(25,t.model),F(27,t.mobile?1:0)})):ln(22,navigator.platform)),screen&&(F(14,Math.round(screen.width)),F(15,Math.round(screen.height)),F(16,Math.round(screen.colorDepth)));for(var h=0,g=o.cookies;h<g.length;h++){var v=g[h],m=Pn(v);m&&dt(v,m)}null===mn&&(mn={ad_Storage:o.track?"granted":"denied",analytics_Storage:o.track?"granted":"denied"}),D(In(mn,0)),Nn(l)}function wn(){vn=null,fn=null,hn.forEach((function(t){t.called=!1}))}function kn(t,n,e,r){void 0===n&&(n=!0),void 0===e&&(e=!1),void 0===r&&(r=!1);var a=o.lean?0:1,i=!1;fn&&(a||!1===n)&&(t(fn,!o.lean,r?mn:void 0),i=!0),!e&&i||hn.push({callback:t,wait:n,recall:e,called:i,consentInfo:r})}function _n(){return fn?[fn.userId,fn.sessionId,fn.pageNum].join("."):""}function Sn(t){void 0===t&&(t=!0),t?(En({ad_Storage:"granted",analytics_Storage:"granted"}),R()):En()}function En(t,n){void 0===t&&(t=yn),void 0===n&&(n=1);var e={ad_Storage:Tn(t.ad_Storage),analytics_Storage:Tn(t.analytics_Storage)};if(!mn||e.ad_Storage!==mn.ad_Storage||e.analytics_Storage!==mn.analytics_Storage){mn=e,Mn(!0);var r=In(mn,n);if(!r.analytics_Storage&&o.track)return o.track=!1,Dn("_clsk","",-Number.MAX_VALUE),Dn("_clck","",-Number.MAX_VALUE),Pe(),void window.setTimeout(Ae,250);pe()&&r.analytics_Storage&&(o.track=!0,Nn(An(),1),xn()),U(r),R()}}function In(t,n){return{source:n,ad_Storage:"granted"===t.ad_Storage?1:0,analytics_Storage:"granted"===t.analytics_Storage?1:0}}function Tn(t){return"string"==typeof t?t.toLowerCase():"denied"}function On(){Dn("_clsk","",0)}function Mn(t){void 0===t&&(t=!1),function(t,n){void 0===n&&(n=!1);if(hn.length>0)for(var e=0;e<hn.length;e++){var r=hn[e];r.callback&&(!r.called&&!n||r.consentInfo&&n)&&(!r.wait||t)&&(r.callback(fn,!o.lean,r.consentInfo?mn:void 0),r.called=!0,r.recall||(hn.splice(e,1),e--))}}(o.lean?0:1,t)}function xn(){if(fn&&o.track){var t=Math.round(Date.now()),n=o.upload&&"string"==typeof o.upload?o.upload.replace("https://",""):"",e=o.lean?0:1;Dn("_clsk",[fn.sessionId,t,fn.pageNum,e,n].join("^"),1)}}function Cn(t,n){try{return!!t[n]}catch(t){return!1}}function Nn(t,n){void 0===n&&(n=null),n=null===n?t.consent:n;var e=Math.ceil((Date.now()+31536e6)/864e5),r=0===t.dob?null===o.dob?0:o.dob:t.dob;(null===t.expiry||Math.abs(e-t.expiry)>=1||t.consent!==n||t.dob!==r)&&Dn("_clck",[fn.userId,2,e.toString(36),n,r].join("^"),365)}function jn(){var t=Math.floor(Math.random()*Math.pow(2,32));return window&&window.crypto&&window.crypto.getRandomValues&&Uint32Array&&(t=window.crypto.getRandomValues(new Uint32Array(1))[0]),t.toString(36)}function zn(t,n){return void 0===n&&(n=10),parseInt(t,n)}function An(){var t={id:jn(),version:0,expiry:null,consent:0,dob:0},n=Pn("_clck",!o.includeSubdomains);if(n&&n.length>0){var e=n.includes("^")?n.split("^"):n.split("|");e.length>1&&(t.version=zn(e[1])),e.length>2&&(t.expiry=zn(e[2],36)),e.length>3&&1===zn(e[3])&&(t.consent=1),e.length>4&&zn(e[1])>1&&(t.dob=zn(e[4])),o.track=o.track||1===t.consent,t.id=o.track?e[0]:t.id}return t}function Pn(t,n){var e;if(void 0===n&&(n=!1),Cn(document,"cookie")){var r=document.cookie.split(";");if(r)for(var a=0;a<r.length;a++){var o=r[a].split("=");if(o.length>1&&o[0]&&o[0].trim()===t){for(var i=qn(o[1]),u=i[0],c=i[1];u;)u=(e=qn(c))[0],c=e[1];return n?c.endsWith("".concat("~","1"))?c.substring(0,c.length-2):null:c}}}return null}function qn(t){try{var n=decodeURIComponent(t);return[n!=t,n]}catch(t){}return[!1,t]}function Dn(t,n,e){if((o.track||""==n)&&(navigator&&navigator.cookieEnabled||Cn(document,"cookie"))){var r=function(t){return encodeURIComponent(t)}(n),a=new Date;a.setDate(a.getDate()+e);var i=a?"expires="+a.toUTCString():"",u="".concat(t,"=").concat(r).concat(";").concat(i).concat(";path=/");try{if(null===vn){for(var c=location.hostname?location.hostname.split("."):[],s=c.length-1;s>=0;s--)if(vn=".".concat(c[s]).concat(vn||""),s<c.length-1&&(document.cookie="".concat(u).concat(";").concat("domain=").concat(vn),Pn(t)===n))return;vn=""}}catch(t){vn=""}document.cookie=vn?"".concat(u).concat(";").concat("domain=").concat(vn):u}}var Rn,Ln=null;function Un(){var t=fn;Ln={version:l,sequence:0,start:0,duration:0,projectId:t.projectId,userId:t.userId,sessionId:t.sessionId,pageNum:t.pageNum,upload:0,end:0,applicationPlatform:0,url:""}}function Hn(){Ln=null}function Xn(t){return Ln.start=Ln.start+Ln.duration,Ln.duration=s()-Ln.start,Ln.sequence++,Ln.upload=t&&"sendBeacon"in navigator?1:0,Ln.end=t?1:0,Ln.applicationPlatform=0,Ln.url=y(location.href,!1,!0),[Ln.version,Ln.sequence,Ln.start,Ln.duration,Ln.projectId,Ln.userId,Ln.sessionId,Ln.pageNum,Ln.upload,Ln.end,Ln.applicationPlatform,Ln.url]}function Vn(){Rn=[]}function Yn(t){if(Rn&&-1===Rn.indexOf(t.message)){var n=o.report;if(n&&n.length>0&&Ln){var e={v:Ln.version,p:Ln.projectId,u:Ln.userId,s:Ln.sessionId,n:Ln.pageNum};t.message&&(e.m=t.message),t.stack&&(e.e=t.stack);var r=new XMLHttpRequest;r.open("POST",n,!0),r.send(JSON.stringify(e)),Rn.push(t.message)}}return t}function Bn(t){return function(){var n=performance.now();try{t.apply(this,arguments)}catch(t){throw Yn(t)}var e=performance.now()-n;G(4,e),e>30&&(J(7),F(6,e),t.dn&&"".concat(t.dn,"-").concat(e))}}var Wn=new Map;function Zn(t,n,e,r,a){void 0===r&&(r=!1),void 0===a&&(a=!0),e=Bn(e);try{t[i("addEventListener")](n,e,{capture:r,passive:a}),function(t){return Wn.has(t)}(t)||Wn.set(t,[]),Wn.get(t).push({event:n,listener:e,options:{capture:r,passive:a}})}catch(t){}}function Jn(){Wn.forEach((function(t,n){!function(t,n){t.forEach((function(t){try{n[i("removeEventListener")](t.event,t.listener,{capture:t.options.capture,passive:t.options.passive})}catch(t){}})),Wn.delete(n)}(t,n)})),Wn=new Map}var Gn=null,Fn=null,Kn=null,Qn=0;function $n(){return!(Qn++>20)}function te(){Qn=0,Kn!==ee()&&(Pe(),window.setTimeout(ne,250))}function ne(){Ae(),F(29,1)}function ee(){return location.href?location.href.replace(location.hash,""):location.href}var re=[],ae=null,oe=null,ie=null;function ue(){re=[],ae=null,oe=null}function ce(){var t=re.shift();t&&(ae=t,t.task().then((function(){t.id===_n()&&(t.resolve(),ae=null,ce())})).catch((function(n){t.id===_n()&&(n&&(n.name,n.message,n.stack),ae=null,ce())})))}var se=!1;function le(){se=!0,u=c(),ue(),Jn(),Vn(),Kn=ee(),Qn=0,Zn(window,"popstate",te),null===Gn&&(Gn=history.pushState,history.pushState=function(){Gn.apply(this,arguments),pe()&&$n()&&te()}),null===Fn&&(Fn=history.replaceState,history.replaceState=function(){Fn.apply(this,arguments),pe()&&$n()&&te()})}function de(){Kn=null,Qn=0,Vn(),Jn(),ue(),u=0,se=!1}function pe(){return se}function fe(){Ae(),Y("clarity","restart")}var he=null;function ge(){he=null}function ve(t){he={fetchStart:Math.round(t.fetchStart),connectStart:Math.round(t.connectStart),connectEnd:Math.round(t.connectEnd),requestStart:Math.round(t.requestStart),responseStart:Math.round(t.responseStart),responseEnd:Math.round(t.responseEnd),domInteractive:Math.round(t.domInteractive),domComplete:Math.round(t.domComplete),loadEventStart:Math.round(t.loadEventStart),loadEventEnd:Math.round(t.loadEventEnd),redirectCount:Math.round(t.redirectCount),size:t.transferSize?t.transferSize:0,type:t.type,protocol:t.nextHopProtocol,encodedSize:t.encodedBodySize?t.encodedBodySize:0,decodedSize:t.decodedBodySize?t.decodedBodySize:0},function(t){ct(this,void 0,void 0,(function(){var n,e;return st(this,(function(r){return n=s(),e=[n,t],29===t&&(e.push(he.fetchStart),e.push(he.connectStart),e.push(he.connectEnd),e.push(he.requestStart),e.push(he.responseStart),e.push(he.responseEnd),e.push(he.domInteractive),e.push(he.domComplete),e.push(he.loadEventStart),e.push(he.loadEventEnd),e.push(he.redirectCount),e.push(he.size),e.push(he.type),e.push(he.protocol),e.push(he.encodedSize),e.push(he.decodedSize),ge(),Wt(e)),[2]}))}))}(29)}var me,ye=0,be=1/0,we=0,ke=0,_e=[],Se=new Map,Ee=function(){return ye||0},Ie=function(){if(!_e.length)return-1;var t=Math.min(_e.length-1,Math.floor((Ee()-ke)/50));return _e[t].latency},Te=function(){ke=Ee(),_e.length=0,Se.clear()},Oe=function(t){if(t.interactionId&&!(t.duration<40)){!function(t){"interactionCount"in performance?ye=performance.interactionCount:t.interactionId&&(be=Math.min(be,t.interactionId),we=Math.max(we,t.interactionId),ye=we?(we-be)/7+1:0)}(t);var n=_e[_e.length-1],e=Se.get(t.interactionId);if(e||_e.length<10||t.duration>(null==n?void 0:n.latency)){if(e)t.duration>e.latency&&(e.latency=t.duration);else{var r={id:t.interactionId,latency:t.duration};Se.set(r.id,r),_e.push(r)}_e.sort((function(t,n){return n.latency-t.latency})),_e.length>10&&_e.splice(10).forEach((function(t){return Se.delete(t.id)}))}}},Me=["navigation","resource","longtask","first-input","layout-shift","largest-contentful-paint","event"];function xe(){try{me&&me.disconnect(),me=new PerformanceObserver(Bn(Ce));for(var t=0,n=Me;t<n.length;t++){var e=n[t];PerformanceObserver.supportedEntryTypes.indexOf(e)>=0&&("layout-shift"===e&&G(9,0),me.observe({type:e,buffered:!0}))}}catch(t){}}function Ce(t){!function(t){for(var n=(!("visibilityState"in document)||"visible"===document.visibilityState),e=0;e<t.length;e++){var r=t[e];switch(r.entryType){case"navigation":ve(r);break;case"resource":var a=r.name;ln(4,je(a)),a!==o.upload&&a!==o.fallback||F(28,r.duration);break;case"longtask":J(7);break;case"first-input":n&&F(10,r.processingStart-r.startTime);break;case"event":n&&"PerformanceEventTiming"in window&&"interactionId"in PerformanceEventTiming.prototype&&(Oe(r),ln(37,Ie().toString()));break;case"layout-shift":n&&!r.hadRecentInput&&G(9,1e3*r.value);break;case"largest-contentful-paint":n&&F(8,r.startTime)}}}(t.getEntries())}var Ne=null;function je(t){return Ne||(Ne=document.createElement("a")),Ne.href=t,Ne.host}var ze=[z,z,z,Object.freeze({__proto__:null,start:function(){ge(),function(){navigator&&navigator.connection&&ln(27,navigator.connection.effectiveType),window.PerformanceObserver&&PerformanceObserver.supportedEntryTypes&&("complete"!==document.readyState?Zn(window,"load",K.bind(this,xe,0)):xe())}()},stop:function(){me&&me.disconnect(),me=null,Te(),Ne=null,ge()}}),z];function Ae(t){void 0===t&&(t=null),function(){try{var t=navigator&&"globalPrivacyControl"in navigator&&1==navigator.globalPrivacyControl;return!1===se&&"undefined"!=typeof Promise&&window.MutationObserver&&document.createTreeWalker&&"now"in Date&&"now"in performance&&"undefined"!=typeof WeakMap&&!t}catch(t){return!1}}()&&(!function(t){if(null===t||se)return!1;for(var n in t)n in o&&(o[n]=t[n])}(t),le(),Et(),ze.forEach((function(t){return Bn(t.start)()})),null===t&&Le())}function Pe(){pe()&&(ze.slice().reverse().forEach((function(t){return Bn(t.stop)()})),It(),de(),void 0!==De&&(De[Re]=function(){(De[Re].q=De[Re].q||[]).push(arguments),"start"===arguments[0]&&De[Re].q.unshift(De[Re].q.pop())&&Le()}))}var qe=Object.freeze({__proto__:null,consent:Sn,consentv2:En,dlog:ln,event:Y,hashText:M,identify:pt,maxMetric:F,measure:Bn,metadata:kn,pause:function(){pe()&&(Y("clarity","pause"),null===oe&&(oe=new Promise((function(t){ie=t}))))},queue:Wt,register:j,resume:function(){pe()&&(oe&&(ie(),oe=null,null===ae&&ce()),Y("clarity","resume"))},schedule:function(t,n){return void 0===n&&(n=0),ct(this,void 0,void 0,(function(){var e,r,a;return st(this,(function(o){for(e=0,r=re;e<r.length;e++)if(r[e].task===t)return[2];return a=new Promise((function(e){re[1===n?"unshift":"push"]({task:t,resolve:e,id:_n()})})),null===ae&&null===oe&&ce(),[2,a]}))}))},set:dt,signal:function(t){kt=t},start:Ae,stop:Pe,time:s,upgrade:it,version:l}),De=window,Re="clarity";function Le(){if(void 0!==De){if(De[Re]&&De[Re].v)return console.warn("Error CL001: Multiple Clarity tags detected.");var t=De[Re]&&De[Re].q||[];for(De[Re]=function(t){for(var n=[],e=1;e<arguments.length;e++)n[e-1]=arguments[e];return qe[t].apply(qe,n)},De[Re].v=l;t.length>0;)De[Re].apply(De,t.shift())}}Le()}();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clarity-js",
3
- "version": "0.8.38-beta",
3
+ "version": "0.8.39",
4
4
  "description": "An analytics library that uses web page interactions to generate aggregated insights",
5
5
  "author": "Microsoft Corp.",
6
6
  "license": "MIT",
@@ -1,2 +1,2 @@
1
- let version = "0.8.38-beta";
1
+ let version = "0.8.39";
2
2
  export default version;
@@ -7,9 +7,10 @@ export let data: ConsentData = null;
7
7
  let updateConsent: boolean = true;
8
8
 
9
9
  export function start(): void {
10
+ const ics = window.google_tag_data?.ics;
10
11
  updateConsent = true;
11
- if (window.google_tag_data?.ics?.addListener) {
12
- window.google_tag_data.ics.addListener(
12
+ if (ics?.addListener) {
13
+ ics.addListener(
13
14
  [Constant.AdStorage, Constant.AnalyticsStorage],
14
15
  processConsent
15
16
  );
@@ -66,5 +67,9 @@ export function compute(): void {
66
67
  if (updateConsent) {
67
68
  encode(Event.Consent);
68
69
  updateConsent = false;
70
+ const ics = window.google_tag_data?.ics;
71
+ if (ics?.usedUpdate) {
72
+ processConsent();
73
+ }
69
74
  }
70
75
  }
@@ -16,7 +16,7 @@ export let callbacks: MetadataCallbackOptions[] = [];
16
16
  export let electron = BooleanFlag.False;
17
17
  let rootDomain = null;
18
18
  let consentStatus: ConsentState = null;
19
- let defaultStatus: ConsentState = {ad_Storage: Constant.Denied, analytics_Storage: Constant.Denied};
19
+ let defaultStatus: ConsentState = { ad_Storage: Constant.Denied, analytics_Storage: Constant.Denied };
20
20
 
21
21
  export function start(): void {
22
22
  rootDomain = null;
@@ -86,12 +86,14 @@ export function start(): void {
86
86
  }
87
87
 
88
88
  // Track consent config
89
- consentStatus = {
90
- ad_Storage: config.track ? Constant.Granted : Constant.Denied,
91
- analytics_Storage: config.track ? Constant.Granted : Constant.Denied,
92
- }
89
+ if (consentStatus === null) {
90
+ consentStatus = {
91
+ ad_Storage: config.track ? Constant.Granted : Constant.Denied,
92
+ analytics_Storage: config.track ? Constant.Granted : Constant.Denied,
93
+ };
94
+ }
93
95
  const consent = getConsentData(consentStatus, ConsentSource.Implicit);
94
- trackConsent.config(consent);
96
+ trackConsent.config(consent);
95
97
  // Track ids using a cookie if configuration allows it
96
98
  track(u);
97
99
  }
@@ -112,7 +114,6 @@ function userAgentData(): void {
112
114
  export function stop(): void {
113
115
  rootDomain = null;
114
116
  data = null;
115
- consentStatus = null;
116
117
  callbacks.forEach(cb => { cb.called = false; });
117
118
  }
118
119
 
@@ -124,7 +125,7 @@ export function metadata(cb: MetadataCallback, wait: boolean = true, recall: boo
124
125
  // we go through the upgrading flow.
125
126
  if (data && (upgraded || wait === false)) {
126
127
  // Immediately invoke the callback if the caller explicitly doesn't want to wait for the upgrade confirmation
127
- cb(data, !config.lean, consentInfo? consentStatus : undefined);
128
+ cb(data, !config.lean, consentInfo ? consentStatus : undefined);
128
129
  called = true;
129
130
  }
130
131
  if (recall || !called) {
@@ -142,21 +143,30 @@ export function consent(status = true): void {
142
143
  consentv2();
143
144
  return;
144
145
  }
145
-
146
+
146
147
  consentv2({ ad_Storage: Constant.Granted, analytics_Storage: Constant.Granted });
147
148
  trackConsent.consent();
148
149
  }
149
150
 
150
151
  export function consentv2(consentState: ConsentState = defaultStatus, source: number = ConsentSource.API): void {
151
- consentStatus = {
152
+ const updatedStatus = {
152
153
  ad_Storage: normalizeConsent(consentState.ad_Storage),
153
154
  analytics_Storage: normalizeConsent(consentState.analytics_Storage)
154
155
  };
155
156
 
157
+ if (
158
+ consentStatus &&
159
+ updatedStatus.ad_Storage === consentStatus.ad_Storage &&
160
+ updatedStatus.analytics_Storage === consentStatus.analytics_Storage
161
+ ) {
162
+ return;
163
+ }
164
+
165
+ consentStatus = updatedStatus;
156
166
  callback(true);
157
167
  const consentData = getConsentData(consentStatus, source);
158
-
159
- if (!consentData.analytics_Storage) {
168
+
169
+ if (!consentData.analytics_Storage && config.track) {
160
170
  config.track = false;
161
171
  setCookie(Constant.SessionKey, Constant.Empty, -Number.MAX_VALUE);
162
172
  setCookie(Constant.CookieKey, Constant.Empty, -Number.MAX_VALUE);
@@ -165,16 +175,17 @@ export function consentv2(consentState: ConsentState = defaultStatus, source: nu
165
175
  return;
166
176
  }
167
177
 
168
- if (core.active()) {
178
+ if (core.active() && consentData.analytics_Storage) {
169
179
  config.track = true;
170
180
  track(user(), BooleanFlag.True);
171
181
  save();
172
- trackConsent.trackConsentv2(consentData);
173
- trackConsent.consent();
174
182
  }
183
+
184
+ trackConsent.trackConsentv2(consentData);
185
+ trackConsent.consent();
175
186
  }
176
187
 
177
- function getConsentData(consentState: ConsentState, source : ConsentSource): ConsentData {
188
+ function getConsentData(consentState: ConsentState, source: ConsentSource): ConsentData {
178
189
  let consent: ConsentData = {
179
190
  source: source,
180
191
  ad_Storage: consentState.ad_Storage === Constant.Granted ? BooleanFlag.True : BooleanFlag.False,
@@ -203,7 +214,7 @@ function tab(): string {
203
214
  return id;
204
215
  }
205
216
 
206
- export function callback(consentUpdate:boolean = false): void {
217
+ export function callback(consentUpdate: boolean = false): void {
207
218
  let upgrade = config.lean ? BooleanFlag.False : BooleanFlag.True;
208
219
  processCallback(upgrade, consentUpdate);
209
220
  }
@@ -221,9 +232,9 @@ function processCallback(upgrade: BooleanFlag, consentUpdate: boolean = false):
221
232
  for (let i = 0; i < callbacks.length; i++) {
222
233
  const cb = callbacks[i];
223
234
  if (
224
- cb.callback &&
235
+ cb.callback &&
225
236
  ((!cb.called && !consentUpdate) || (cb.consentInfo && consentUpdate)) && //If consentUpdate is true, we only call the callback if it has consentInfo
226
- (!cb.wait || upgrade)
237
+ (!cb.wait || upgrade)
227
238
  ) {
228
239
  cb.callback(data, !config.lean, cb.consentInfo ? consentStatus : undefined);
229
240
  cb.called = true;
@@ -70,9 +70,8 @@ function handler(event: Event, root: Node, evt: MouseEvent): void {
70
70
  hash: null,
71
71
  trust: evt.isTrusted ? BooleanFlag.True : BooleanFlag.False,
72
72
  isFullText: textInfo.isFullText,
73
- tag: getElementAttribute(t, "tagName").substring(0, Setting.ClickTag),
74
- class: getElementAttribute(t, "className").substring(0, Setting.ClickClass),
75
- id: getElementAttribute(t, "id").substring(0, Setting.ClickId),
73
+ w: l ? l.w : 0,
74
+ h: l ? l.h : 0
76
75
  }
77
76
  });
78
77
  schedule(encode.bind(this, event));
@@ -112,21 +111,13 @@ function text(element: Node): TextInfo {
112
111
  }
113
112
 
114
113
  function reaction(element: Node): BooleanFlag {
115
- const tagName = getElementAttribute(element, "tagName");
116
-
117
- if (UserInputTags.indexOf(tagName) >= 0) {
118
- return BooleanFlag.False;
119
- }
120
- return BooleanFlag.True;
121
- }
122
-
123
- function getElementAttribute(element: Node, attribute: "tagName" | "className" | "id"): string {
124
114
  if (element.nodeType === Node.ELEMENT_NODE) {
125
- const attr = (element as HTMLElement)?.[attribute];
126
- const value = typeof attr === "string" ? attr?.toLowerCase() : "";
127
- return value;
115
+ let tag = (element as HTMLElement).tagName.toLowerCase();
116
+ if (UserInputTags.indexOf(tag) >= 0) {
117
+ return BooleanFlag.False;
118
+ }
128
119
  }
129
- return "";
120
+ return BooleanFlag.True;
130
121
  }
131
122
 
132
123
  function layout(element: Element): Box {
@@ -72,9 +72,8 @@ export default async function (type: Event, ts: number = null): Promise<void> {
72
72
  tokens.push(cHash);
73
73
  tokens.push(entry.data.trust);
74
74
  tokens.push(entry.data.isFullText);
75
- tokens.push(entry.data.tag);
76
- tokens.push(entry.data.class);
77
- tokens.push(entry.data.id);
75
+ tokens.push(entry.data.w);
76
+ tokens.push(entry.data.h);
78
77
  queue(tokens);
79
78
  timeline.track(entry.time, entry.event, cHash, entry.data.x, entry.data.y, entry.data.reaction, entry.data.context);
80
79
  }
package/types/data.d.ts CHANGED
@@ -253,9 +253,6 @@ export const enum Setting {
253
253
  PingTimeout = 5 * Time.Minute, // 5 Minutes
254
254
  SummaryInterval = 100, // Same events within 100ms will be collapsed into single summary
255
255
  ClickText = 25, // Maximum number of characters to send as part of Click event's text field
256
- ClickClass = 50, // Maximum number of characters to send as part of Click event's class name
257
- ClickTag = 10, // Maximum number of characters to send as part of Click event's tag
258
- ClickId = 25, // Maximum number of characters to send as part of Click event's id
259
256
  PayloadLimit = 128, // Do not allow more than specified payloads per page
260
257
  PageLimit = 128, // Do not allow more than 128 pages in a session
261
258
  ShutdownLimit = 2 * Time.Hour, // Shutdown instrumentation after specified time
package/types/global.d.ts CHANGED
@@ -5,6 +5,7 @@ declare global {
5
5
  ics: {
6
6
  addListener: (keys: string[], callback: () => void) => void;
7
7
  getConsentState: (key: string) => any;
8
+ usedUpdate: boolean;
8
9
  };
9
10
  };
10
11
  LiveChatWidget?: {
@@ -126,9 +126,8 @@ export interface ClickData {
126
126
  hash: string;
127
127
  trust: number;
128
128
  isFullText: BooleanFlag;
129
- tag: string;
130
- class: string;
131
- id: string;
129
+ w: number;
130
+ h: number;
132
131
  }
133
132
 
134
133
  export interface TextInfo {