@gemx-dev/clarity-js 0.8.89 → 0.8.90

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 flush(){return Ln},get inject(){return qn},get queue(){return Rn},get start(){return Wn},get stop(){return Un},get track(){return jn}}),e=Object.freeze({__proto__:null,get data(){return Sr},get start(){return Or},get stop(){return Nr},get upgrade(){return Er}}),n=Object.freeze({__proto__:null,get check(){return Xr},get compute(){return Pr},get data(){return Tr},get start(){return Mr},get stop(){return Yr},get trigger(){return jr}}),r=Object.freeze({__proto__:null,get compute(){return Rr},get data(){return Cr},get log(){return Wr},get reset(){return Lr},get start(){return Dr},get stop(){return Ar},get updates(){return zr}}),a=Object.freeze({__proto__:null,get compute(){return Qr},get config(){return Jr},get consent(){return Br},get data(){return qr},get start(){return Fr},get stop(){return Gr},get trackConsentv2(){return Kr}}),o=Object.freeze({__proto__:null,get callback(){return va},get callbacks(){return ta},get clear(){return ha},get consent(){return la},get consentv2(){return da},get data(){return $r},get electron(){return ea},get id(){return sa},get metadata(){return ca},get save(){return ga},get shortid(){return wa},get start(){return oa},get stop(){return ua}}),i=Object.freeze({__proto__:null,get data(){return ka},get envelope(){return Sa},get start(){return Ta},get stop(){return xa}}),u={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,modules:[],diagnostics:!1,externalSession:!1,userId:null,sessionId:null,mode:"gemx"};function c(t){return window.Zone&&"__symbol__"in window.Zone?window.Zone.__symbol__(t):t}var s=0;function l(){return performance.now()+performance.timeOrigin}function d(t){void 0===t&&(t=null);var e=0===s?l():s,n=t&&t.timeStamp>0?t.timeStamp:performance.now(),r=t&&t.view?t.view.performance.timeOrigin:performance.timeOrigin;return Math.max(Math.round(n+r-e),0)}var f="0.8.89";function p(t,e){void 0===e&&(e=null);for(var n,r=5381,a=r,o=0;o<t.length;o+=2){if(r=(r<<5)+r^t.charCodeAt(o),o+1<t.length)a=(a<<5)+a^t.charCodeAt(o+1)}return n=Math.abs(r+11579*a),(e?n%Math.pow(2,e):n).toString(36)}var h=/\S/gi,v=255,g=!0,m=null,w=null,y=null;function b(t,e,n,r,a){if(void 0===r&&(r=!1),t){if("input"==e&&("checkbox"===a||"radio"===a))return t;switch(n){case 0:return t;case 1:switch(e){case"*T":case"value":case"placeholder":case"click":return function(t){var e=-1,n=0,r=!1,a=!1,o=!1,i=null;O();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(e+1,o?u:u+1);s=g&&null!==y?s.match(y)?s:x(s,"▪","▫"):T(s),i.splice(e+1-n,s.length,s),n+=s.length-1}o&&(r=!1,a=!1,e=u)}}return i?i.join(""):t}(t);case"input":case"change":return S(t)}return t;case 2:case 3:switch(e){case"*T":case"data-":return r?k(t):T(t);case"src":case"srcset":case"title":case"alt":case"href":case"xlink:href":return 3===n?(null==t?void 0:t.startsWith("blob:"))?"blob:":"":t;case"value":case"click":case"input":case"change":return S(t);case"placeholder":return T(t)}break;case 4:switch(e){case"*T":case"data-":return r?k(t):T(t);case"value":case"input":case"click":case"change":return Array(5).join("•");case"checksum":return""}break;case 5:switch(e){case"*T":case"data-":return x(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 _(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!1);var r=t;if(e)r="".concat("https://").concat("Electron");else{var a=u.drop;if(a&&a.length>0&&t&&t.indexOf("?")>0){var o=t.split("?"),i=o[0],c=o[1];r=i+"?"+c.split("&").map((function(t){return a.some((function(e){return 0===t.indexOf("".concat(e,"="))}))?"".concat(t.split("=")[0],"=").concat("*na*"):t})).join("&")}}return n&&(r=r.substring(0,v)),r}function k(t){var e=t.trim();if(e.length>0){var n=e[0],r=t.indexOf(n),a=t.substr(0,r),o=t.substr(r+e.length);return"".concat(a).concat(e.length.toString(36)).concat(o)}return t}function T(t){return t.replace(h,"•")}function x(t,e,n){return O(),t?t.replace(w,e).replace(m,n):t}function S(t){for(var e=5*(Math.floor(t.length/5)+1),n="",r=0;r<e;r++)n+=r>0&&r%5==0?" ":"•";return n}function O(){if(g&&null===m)try{m=new RegExp("\\p{N}","gu"),w=new RegExp("\\p{L}","gu"),y=new RegExp("\\p{Sc}","gu")}catch(t){g=!1}}var E=null,N=null,I=!1;function M(){I&&(E={time:d(),event:4,data:{visible:N.visible,docWidth:N.docWidth,docHeight:N.docHeight,screenWidth:N.screenWidth,screenHeight:N.screenHeight,scrollX:N.scrollX,scrollY:N.scrollY,pointerX:N.pointerX,pointerY:N.pointerY,activityTime:N.activityTime,scrollTime:N.scrollTime,pointerTime:N.pointerTime,moveX:N.moveX,moveY:N.moveY,moveTime:N.moveTime,downX:N.downX,downY:N.downY,downTime:N.downTime,upX:N.upX,upY:N.upY,upTime:N.upTime,pointerPrevX:N.pointerPrevX,pointerPrevY:N.pointerPrevY,pointerPrevTime:N.pointerPrevTime,modules:N.modules}}),N=N||{visible:1,docWidth:0,docHeight:0,screenWidth:0,screenHeight:0,scrollX:0,scrollY:0,pointerX:0,pointerY:0,activityTime:0,scrollTime:0,pointerTime:void 0,moveX:void 0,moveY:void 0,moveTime:void 0,downX:void 0,downY:void 0,downTime:void 0,upX:void 0,upY:void 0,upTime:void 0,pointerPrevX:void 0,pointerPrevY:void 0,pointerPrevTime:void 0,modules:null}}function X(t,e,n,r){switch(t){case 8:N.docWidth=e,N.docHeight=n;break;case 11:N.screenWidth=e,N.screenHeight=n;break;case 10:N.scrollX=e,N.scrollY=n,N.scrollTime=r;break;case 12:N.moveX=e,N.moveY=n,N.moveTime=r,N.pointerPrevX=N.pointerX,N.pointerPrevY=N.pointerY,N.pointerPrevTime=N.pointerTime,N.pointerX=e,N.pointerY=n,N.pointerTime=r;break;case 13:N.downX=e,N.downY=n,N.downTime=r,N.pointerPrevX=N.pointerX,N.pointerPrevY=N.pointerY,N.pointerPrevTime=N.pointerTime,N.pointerX=e,N.pointerY=n,N.pointerTime=r;break;case 14:N.upX=e,N.upY=n,N.upTime=r,N.pointerPrevX=N.pointerX,N.pointerPrevY=N.pointerY,N.pointerPrevTime=N.pointerTime,N.pointerX=e,N.pointerY=n,N.pointerTime=r;break;default:N.pointerPrevX=N.pointerX,N.pointerPrevY=N.pointerY,N.pointerPrevTime=N.pointerTime,N.pointerX=e,N.pointerY=n,N.pointerTime=r}I=!0}function j(t){N.activityTime=t}function P(t,e){N.visible=e,N.visible||j(t),I=!0}function Y(t){N.modules=Array.from(t),I=!0}function C(){I&&Ir(4)}var z=Object.freeze({__proto__:null,activity:j,compute:C,dynamic:Y,reset:M,start:function(){I=!1,M()},get state(){return E},stop:function(){M()},track:X,visibility:P}),H=null;function D(t,e){qa()&&t&&"string"==typeof t&&t.length<255&&(H=e&&"string"==typeof e&&e.length<255?{key:t,value:e}:{value:t},Ir(24))}var A,W=null,R=null;function L(t){t in W||(W[t]=0),t in R||(R[t]=0),W[t]++,R[t]++}function q(t,e){null!==e&&(t in W||(W[t]=0),t in R||(R[t]=0),W[t]+=e,R[t]+=e)}function U(t,e){null!==e&&!1===isNaN(e)&&(t in W||(W[t]=0),(e>W[t]||0===W[t])&&(R[t]=e,W[t]=e))}function F(t,e,n){return window.setTimeout(Na(t),e,n)}function G(t){return window.clearTimeout(t)}var V=0,J=0,B=null;function Z(){B&&G(B),B=F(K,J),V=d()}function K(){var t=d();A={gap:t-V},Ir(25),A.gap<3e5?B=F(K,J):Wa&&(D("clarityGemX","suspend"),Za(),["mousemove","touchstart"].forEach((function(t){return Ma(document,t,Ua)})),["resize","scroll","pageshow"].forEach((function(t){return Ma(window,t,Ua)})))}var Q=Object.freeze({__proto__:null,get data(){return A},reset:Z,start:function(){J=6e4,V=0},stop:function(){G(B),V=0,J=0}}),$=null;function tt(){Ir(36)}function et(){$={}}var nt=Object.freeze({__proto__:null,compute:tt,get data(){return $},reset:et,start:function(){$={}},stop:function(){$={}},track:function(t,e){if(t in $){var n=$[t],r=n[n.length-1];e-r[0]>100?$[t].push([e,0]):r[1]=e-r[0]}else $[t]=[[e,0]]}}),rt=function(){return rt=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var a in e=arguments[n])Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t},rt.apply(this,arguments)};function at(t,e,n,r){return new(n||(n=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 e;t.done?a(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(i,u)}c((r=r.apply(t,e||[])).next())}))}function ot(t,e){var n,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(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(n=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=e.call(t,i)}catch(t){u=[6,t],r=0}finally{n=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,c])}}}var it="CompressionStream"in window;function ut(t){return at(this,void 0,void 0,(function(){var e,n;return ot(this,(function(r){switch(r.label){case 0:return r.trys.push([0,3,,4]),it?(e=new ReadableStream({start:function(e){return at(this,void 0,void 0,(function(){return ot(this,(function(n){return e.enqueue(t),e.close(),[2]}))}))}}).pipeThrough(new TextEncoderStream).pipeThrough(new window.CompressionStream("gzip")),n=Uint8Array.bind,[4,ct(e)]):[3,2];case 1:return[2,new(n.apply(Uint8Array,[void 0,r.sent()]))];case 2:return[3,4];case 3:return r.sent(),[3,4];case 4:return[2,null]}}))}))}function ct(t){return at(this,void 0,void 0,(function(){var e,n,r,a,o;return ot(this,(function(i){switch(i.label){case 0:e=t.getReader(),n=[],r=!1,a=[],i.label=1;case 1:return r?[3,3]:[4,e.read()];case 2:return o=i.sent(),r=o.done,a=o.value,r?[2,n]:(n.push.apply(n,a),[3,1]);case 3:return[2,n]}}))}))}var st=null;function lt(t,e){ft(t,"string"==typeof e?[e]:e)}function dt(t,e,n,r){return void 0===e&&(e=null),void 0===n&&(n=null),void 0===r&&(r=null),at(this,void 0,void 0,(function(){var a,o;return ot(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(x(u.substring(2),"*","*")):x(u,"*","*")),ft("userId",[(a=o).userId]),ft("userHint",[a.userHint]),ft("userType",[gt(t)]),e&&(ft("sessionId",[e]),a.sessionId=e),n&&(ft("pageId",[n]),a.pageId=n),[2,a]}var u}))}))}function ft(t,e){if(qa()&&t&&e&&"string"==typeof t&&t.length<255){for(var n=(t in st?st[t]:[]),r=0;r<e.length;r++)"string"==typeof e[r]&&e[r].length<255&&n.push(e[r]);st[t]=n}}function pt(){Ir(34)}function ht(){st={}}function vt(t){return at(this,void 0,void 0,(function(){var e;return ot(this,(function(n){switch(n.label){case 0:return n.trys.push([0,4,,5]),crypto&&t?[4,crypto.subtle.digest("SHA-256",(new TextEncoder).encode(t))]:[3,2];case 1:return e=n.sent(),[2,Array.prototype.map.call(new Uint8Array(e),(function(t){return("00"+t.toString(16)).slice(-2)})).join("")];case 2:return[2,""];case 3:return[3,5];case 4:return n.sent(),[2,""];case 5:return[2]}}))}))}function gt(t){return t&&t.indexOf("@")>0?"email":"string"}var mt=Object.freeze({__proto__:null,compute:pt,get data(){return st},identify:dt,reset:ht,set:lt,start:function(){ht()},stop:function(){ht()}});var wt,yt={};function bt(t){var e=t.error||t;return e.message in yt||(yt[e.message]=0),yt[e.message]++>=5||e&&e.message&&(wt={message:e.message,line:t.lineno,column:t.colno,stack:e.stack,source:t.filename},_t(31)),!0}function _t(t){return at(this,void 0,void 0,(function(){var e;return ot(this,(function(n){switch(e=[d(),t],t){case 31:e.push(wt.message),e.push(wt.line),e.push(wt.column),e.push(wt.stack),e.push(_(wt.source)),Rn(e);break;case 33:kt&&(e.push(kt.code),e.push(kt.name),e.push(kt.message),e.push(kt.stack),e.push(kt.severity),Rn(e,!1))}return[2]}))}))}var kt,Tt={};function xt(t,e,n,r,a){void 0===n&&(n=null),void 0===r&&(r=null),void 0===a&&(a=null);var o=n?"".concat(n,"|").concat(r):"";t in Tt&&Tt[t].indexOf(o)>=0||(kt={code:t,name:n,message:r,stack:a,severity:e},t in Tt?Tt[t].push(o):Tt[t]=[o],_t(33))}var St={},Ot=new Set,Et={},Nt={},It={},Mt={};function Xt(t){try{var e=t&&t.length>0?t.split(/ (.*)/):[""],n=e[0].split(/\|(.*)/),r=parseInt(n[0]),a=n.length>1?n[1]:"",o=e.length>1?JSON.parse(e[1]):{};for(var i in Et[r]={},Nt[r]={},It[r]={},Mt[r]=a,o){var u=parseInt(i),c=o[i],s=2;switch(c.startsWith("~")?s=0:c.startsWith("!")&&(s=4),s){case 0:var l=c.slice(1);Et[r][u]=zt(l);break;case 2:Nt[r][u]=c;break;case 4:var d=c.slice(1);It[r][u]=d}}}catch(t){xt(8,1,t?t.name:null)}}function jt(t){return JSON.parse(JSON.stringify(t))}function Pt(){try{for(var t in Et){var e=parseInt(t);if(""==Mt[e]||document.querySelector(Mt[e])){var n=Et[e];for(var r in n){var a=parseInt(r),o=(m=Ht(jt(n[a])))?JSON.stringify(m).slice(0,1e4):m;o&&Ct(e,a,o)}var i=Nt[e];for(var u in i){var c=!1,s=parseInt(u),l=i[s];l.startsWith("@")&&(c=!0,l=l.slice(1));var d=document.querySelectorAll(l);if(d){var f=Array.from(d).map((function(t){return t.textContent})).join("<SEP>");Ct(e,s,(c?p(f).trim():f).slice(0,1e4))}}var h=It[e];for(var v in h){var g=parseInt(v);Ct(e,g,(void h[g]).trim().slice(0,1e4))}}}Ot.size>0&&Ir(40)}catch(t){xt(5,1,t?t.name:null)}var m}function Yt(){Ot.clear()}function Ct(t,e,n){var r,a=!1;t in St||(St[t]={},a=!0),r=It[t],0==Object.keys(r).length||e in St[t]&&St[t][e]==n||(a=!0),St[t][e]=n,a&&Ot.add(t)}function zt(t){for(var e=[],n=t.split(".");n.length>0;){var r=n.shift(),a=r.indexOf("["),o=r.indexOf("{"),i=r.indexOf("}");e.push({name:a>0?r.slice(0,a):o>0?r.slice(0,o):r,type:a>0?1:o>0?2:3,condition:o>0?r.slice(o+1,i):null})}return e}function Ht(t,e){if(void 0===e&&(e=window),0==t.length)return e;var n,r=t.shift();if(e&&e[r.name]){var a=e[r.name];if(1!==r.type&&Dt(a,r.condition))n=Ht(t,a);else if(Array.isArray(a)){for(var o=[],i=0,u=a;i<u.length;i++){var c=u[i];if(Dt(c,r.condition)){var s=Ht(t,c);s&&o.push(s)}}n=o}return n}return null}function Dt(t,e){if(e){var n=e.split(":");return n.length>1?t[n[0]]==n[1]:t[n[0]]}return!0}var At=Object.freeze({__proto__:null,clone:jt,compute:Pt,data:St,keys:Ot,reset:Yt,start:function(){Yt()},stop:function(){Yt()},trigger:Xt,update:Ct});function Wt(t,e){try{return!!t[e]}catch(t){return!1}}function Rt(t){try{var e=decodeURIComponent(t);return[e!=t,e]}catch(t){}return[!1,t]}var Lt=null,qt="^";function Ut(t,e){var n;if(void 0===e&&(e=!1),Wt(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=Rt(o[1]),u=i[0],c=i[1];u;)u=(n=Rt(c))[0],c=n[1];return e?c.endsWith("".concat("~","1"))?c.substring(0,c.length-2):null:c}}}return null}function Ft(t,e,n){if((u.track||""==e)&&(navigator&&navigator.cookieEnabled||Wt(document,"cookie"))){var r=function(t){return encodeURIComponent(t)}(e),a=new Date;a.setDate(a.getDate()+n);var o=a?"expires="+a.toUTCString():"",i="".concat(t,"=").concat(r).concat(";").concat(o).concat(";path=/");try{if(null===Lt){for(var c=location.hostname?location.hostname.split("."):[],s=c.length-1;s>=0;s--)if(Lt=".".concat(c[s]).concat(Lt||""),s<c.length-1&&(document.cookie="".concat(i).concat(";").concat("domain=").concat(Lt),Ut(t)===e))return;Lt=""}}catch(t){Lt=""}document.cookie=Lt?"".concat(i).concat(";").concat("domain=").concat(Lt):i}}var Gt=Object.freeze({__proto__:null,COOKIE_SEP:qt,getCookie:Ut,setCookie:Ft,start:function(){Lt=null},stop:function(){Lt=null}}),Vt={excludeClassNames:[],ignoreMutationClassNames:[],discoverTrigger:null},Jt=rt({},Vt);var Bt=Object.freeze({__proto__:null,get:function(){return Jt},set:function(t){Jt=rt(rt({},Jt),t)},start:function(){var t,e,n,r,a,o;Jt={excludeClassNames:null!==(e=null===(t=null===window||void 0===window?void 0:window.GemXHeatmap)||void 0===t?void 0:t.excludeClassNames)&&void 0!==e?e:[],ignoreMutationClassNames:null!==(r=null===(n=null===window||void 0===window?void 0:window.GemXHeatmap)||void 0===n?void 0:n.ignoreMutationClassNames)&&void 0!==r?r:[],discoverTrigger:null!==(o=null===(a=null===window||void 0===window?void 0:window.GemXHeatmap)||void 0===a?void 0:a.discoverTrigger)&&void 0!==o?o:null}},stop:function(){Jt=rt({},Vt)}}),Zt=[],Kt=0,Qt=!1,$t=0,te=null;function ee(){return Qt}function ne(t,e){Zt.push(t),Kt+=e,$t>0&&Kt>=$t&&te&&te()}var re=null;function ae(t){try{if(!re)return;var e=function(t){try{return JSON.parse(t)}catch(t){return[]}}(t);e.forEach((function(t){re(t)}))}catch(t){}}var oe=[Bt,Object.freeze({__proto__:null,config:function(t,e){return $t=null!=t?t:0,te=null!=e?e:null,!0},drain:function(){Qt=!1;var t=Zt;return Zt=[],Kt=0,t},getBytes:function(){return Kt},hold:ne,isActive:ee,start:function(){Zt=[],Kt=0,Qt=!0},stop:function(){Zt=[],Kt=0,Qt=!1,$t=0,te=null}}),z,r,mt,n,nt,Gt,a,o,i,t,Q,e,At];function ie(){W={},R={},L(5),oe.forEach((function(t){return Na(t.start)()}))}function ue(){oe.slice().reverse().forEach((function(t){return Na(t.stop)()})),W={},R={}}function ce(){C(),Pr(),Qr(),"gemx"!==u.mode&&(pt(),Rr(),Ir(0),tt(),Pt())}var se=[],le=null;var de=Object.freeze({__proto__:null,checkDocumentStyles:function(t){},compute:function(){},data:le,log:function(){},observe:function(){},reset:function(){},sheetAdoptionState:[],sheetUpdateState:[],start:function(){},state:se,stop:function(){}}),fe=[],pe=null,he=null,ve=null;function ge(){fe=[],pe=null,he=null}function me(t,e){return void 0===e&&(e=0),at(this,void 0,void 0,(function(){var n,r,a;return ot(this,(function(o){for(n=0,r=fe;n<r.length;n++)if(r[n].task===t)return[2];return a=new Promise((function(n){fe[1===e?"unshift":"push"]({task:t,resolve:n,id:sa()})})),null===pe&&null===he&&we(),[2,a]}))}))}function we(){var t=fe.shift();t&&(pe=t,t.task().then((function(){t.id===sa()&&(t.resolve(),pe=null,we())})).catch((function(e){t.id===sa()&&(e&&xt(0,1,e.name,e.message,e.stack),pe=null,we())})))}var ye=["input","textarea","radio","button","canvas","select"],be=/VM\d/,_e=[],ke=null;function Te(t,e,n){var r,a=document.documentElement,o="pageX"in n?Math.round(n.pageX):"clientX"in n?Math.round(n.clientX+a.scrollLeft):null,i="pageY"in n?Math.round(n.pageY):"clientY"in n?Math.round(n.clientY+a.scrollTop):null,c=gr(n),s=function(t){for(;t&&t!==document;){if(t.nodeType===Node.ELEMENT_NODE){var e=t;if("A"===e.tagName)return e}t=t.parentNode}return null}(c),l=Ee(c);0===n.detail&&l&&(o=Math.round(l.x+l.w/2),i=Math.round(l.y+l.h/2));var f=function(t,e,n,r){if(!r)return{eX:0,eY:0};var a=r,o=t,i=Math.max(Math.floor((e-a.x)/a.w*32767),0),u=Math.max(Math.floor((n-a.y)/a.h*32767),0),c=0;for(;(i>32767||u>32767)&&o.parentElement&&c<10;)c++,(a=Ee(o=o.parentElement))&&(i=Math.max(Math.floor((e-a.x)/a.w*32767),0),u=Math.max(Math.floor((n-a.y)/a.h*32767),0));return{eX:i,eY:u}}(c,o,i,l),p=f.eX,h=f.eY;if(null!==o&&null!==i){var v=function(t){var e=null,n=!1;if(t){var r=xe(t)||String(t.value||"")||t.alt;if(r){var a=r.replace(/\s+/g," ").trim();n=(e=a.substring(0,25)).length===a.length}}return{text:e,isFullText:n?1:0}}(c);if(u.diagnostics){var g=c;console.log("[clarity:click] text debug",{tag:null==g?void 0:g.tagName,id:(null==g?void 0:g.id)||null,class:(null==g?void 0:g.className)||null,rawTextContent:(null===(r=null==g?void 0:g.textContent)||void 0===r?void 0:r.replace(/\s+/g," ").trim().substring(0,100))||null,inputValue:(null==g?void 0:g.value)||null,altText:(null==g?void 0:g.alt)||null,resolvedText:v.text,isFullText:v.isFullText,x:o,y:i})}_e.push({time:d(n),event:t,data:{target:c,x:o,y:i,eX:p,eY:h,button:n.button,reaction:Se(c),context:Ne(s),text:v.text,link:s?s.href:null,hash:null,trust:n.isTrusted?1:0,isFullText:v.isFullText,w:l?l.w:0,h:l?l.h:0,tag:Oe(c,"tagName").substring(0,10),class:Oe(c,"className").substring(0,50),id:Oe(c,"id").substring(0,25),source:u.diagnostics&&!n.isTrusted?Ie():0}}),n.isTrusted&&ke&&ke(),me(gn.bind(this,t))}}function xe(t){if(t.nodeType!==Node.ELEMENT_NODE)return t.textContent||"";var e=t,n=e.tagName;if("SCRIPT"===n||"STYLE"===n||"NOSCRIPT"===n)return"";for(var r="",a=0;a<e.childNodes.length;a++)r+=xe(e.childNodes[a]);return r}function Se(t){var e=Oe(t,"tagName");return ye.indexOf(e)>=0?0:1}function Oe(t,e){if(t.nodeType===Node.ELEMENT_NODE){var n=null==t?void 0:t[e];return"string"==typeof n?null==n?void 0:n.toLowerCase():""}return""}function Ee(t){var e=null,n=t.ownerDocument||document,r=n.documentElement,a=n.defaultView||window;if("function"==typeof t.getBoundingClientRect){var o=t.getBoundingClientRect();if(o&&o.width>0&&o.height>0){var i="pageXOffset"in a?a.pageXOffset:r.scrollLeft,u="pageYOffset"in a?a.pageYOffset:r.scrollTop;e={x:Math.floor(o.left+i),y:Math.floor(o.top+u),w:Math.floor(o.width),h:Math.floor(o.height)}}}return e}function Ne(t){if(t&&t.hasAttribute("target"))switch(t.getAttribute("target")){case"_blank":return 1;case"_parent":return 2;case"_top":return 3}return 0}function Ie(){Ie.dn=1;try{for(var t=(new Error).stack||"",e=location.origin,n=4,r=0,a=t.split("\n");r<a.length;r++){var o=a[r];o.indexOf("://")>=0?n=o.indexOf("extension")<0&&o.indexOf(e)>=0?1:2:(o.indexOf("eval")>=0||o.indexOf("Function")>=0||o.indexOf("<a")>=0||be.test(o))&&(n=3)}return n}catch(t){return 4}}function Me(){_e=[]}var Xe,je=Object.freeze({__proto__:null,observe:function(t){Ma(t,"click",Te.bind(this,9,t),!0),Ma(t,"contextmenu",Te.bind(this,48,t),!0)},onTrustedClick:function(t){ke=t},reset:Me,start:function(){Me()},get state(){return _e},stop:function(){Me()}});function Pe(t,e){var n=0,r=null,a=null;function o(){for(var o=this,i=[],u=0;u<arguments.length;u++)i[u]=arguments[u];var c=performance.now(),s=c-n;if(0!==n&&s<e){if(a=i,r)return;r=setTimeout((function(){n=performance.now(),t.apply(o,a),a=null,r=null}),e-s)}else n=c,t.apply(this,i)}return o.cleanup=function(){r&&(clearTimeout(r),r=null,a=null)},o}var Ye=null,Ce=!1,ze=Pe(He,500);function He(){var t=document.documentElement;Xe={width:t&&"clientWidth"in t?Math.min(t.clientWidth,window.innerWidth):window.innerWidth,height:t&&"clientHeight"in t?Math.min(t.clientHeight,window.innerHeight):window.innerHeight},Ce?(G(Ye),Ye=F(De,500,11)):(gn(11),Ce=!0)}function De(t){me(gn.bind(this,t))}function Ae(){Xe=null,G(Ye),ze.cleanup()}var We=Object.freeze({__proto__:null,get data(){return Xe},reset:Ae,start:function(){Ce=!1,Ma(window,"resize",ze),He()},stop:function(){Ae()}}),Re=[],Le=null;var qe=null,Ue=null,Fe=null;function Ge(t){void 0===t&&(t=null);var e=window,n=document.documentElement,r=t?gr(t):n;if(r){if(r&&r.nodeType===Node.DOCUMENT_NODE){r=n=r.documentElement}var a=r===n&&"pageXOffset"in e?Math.round(e.pageXOffset):Math.round(r.scrollLeft),o=r===n&&"pageYOffset"in e?Math.round(e.pageYOffset):Math.round(r.scrollTop),i=window.innerWidth,u=window.innerHeight,c=i/3,s=i>u?.15*u:.2*u,l=u-s,f=Je(c,s),p=Je(c,l),h=t&&t.isTrusted?1:0;t&&t.isTrusted&&Le&&Le();var v={time:d(t),event:10,data:{target:r,x:a,y:o,top:f,bottom:p,trust:h}};if(null===t&&0===a&&0===o||null===a||null===o)return qe=f,void(Ue=p);var g=Re.length,m=g>1?Re[g-2]:null;m&&function(t,e){var n=t.data.x-e.data.x,r=t.data.y-e.data.y;return n*n+r*r<400&&e.time-t.time<50}(m,v)&&Re.pop(),Re.push(v),G(Fe),Fe=F(Ze,500,10)}}var Ve=Pe(Ge,25);function Je(t,e){var n,r,a;return"caretPositionFromPoint"in document?a=null===(n=document.caretPositionFromPoint(t,e))||void 0===n?void 0:n.offsetNode:"caretRangeFromPoint"in document&&(a=null===(r=document.caretRangeFromPoint(t,e))||void 0===r?void 0:r.startContainer),a||(a=document.elementFromPoint(t,e)),a&&a.nodeType===Node.TEXT_NODE&&(a=a.parentNode),a}function Be(){Re=[],qe=null,Ue=null}function Ze(t){me(gn.bind(this,t))}var Ke=Object.freeze({__proto__:null,compute:function(){var t,e;if(qe){var n=mr(qe);Wr(31,null===(t=null==n?void 0:n.hash)||void 0===t?void 0:t.join("."))}if(Ue){var r=mr(Ue);Wr(32,null===(e=null==r?void 0:r.hash)||void 0===e?void 0:e.join("."))}},observe:function(t){Ma(t===document?window:t,"scroll",Ve,!0)},onTrustedScroll:function(t){Le=t},reset:Be,start:function(){Re=[],Ge()},get state(){return Re},stop:function(){G(Fe),Ve.cleanup(),Re=[],qe=null,Ue=null}}),Qe=[];function $e(t){Qe.push({time:d(t),event:39,data:{target:gr(t)}}),me(gn.bind(this,39))}function tn(){Qe=[]}var en,nn=Object.freeze({__proto__:null,observe:function(t){Ma(t,"submit",$e,!0)},reset:tn,start:function(){tn()},get state(){return Qe},stop:function(){tn()}});function rn(){Ln("gemx-unload")}function an(t){en={name:t.type,persisted:t.persisted?1:0},gn(26,d(t)),Za()}function on(){en=null}var un,cn=Object.freeze({__proto__:null,get data(){return en},reset:on,start:function(){Ma(window,"pagehide",an),Ma(window,"beforeunload",rn)},stop:function(){on()}});function sn(t){if(void 0===t&&(t=null),"visibilityState"in document){var e="visible"===document.visibilityState?1:0;un={visible:e},gn(28,d(t))}}function ln(){un=null}var dn,fn=Object.freeze({__proto__:null,get data(){return un},reset:ln,start:function(){Ma(document,"visibilitychange",sn),sn()},stop:function(){ln()}});function pn(){dn=null}function hn(t){dn={focused:t},gn(50)}var vn=Object.freeze({__proto__:null,get data(){return dn},reset:pn,start:function(){Ma(window,"focus",(function(){return hn(1)})),Ma(window,"blur",(function(){return hn(0)}))},stop:function(){pn()}});function gn(t,e){return void 0===e&&(e=null),at(this,void 0,void 0,(function(){var n,r,a,o,i,u,c,s,l,f,p,h,v,g,m,w,y,k,T,x,S,O,E,N,I,M,j,Y,C,z,H,D,A,W,R,L;return ot(this,(function(q){switch(n=e||d(),r=[n,t],t){case 13:case 14:case 12:case 15:case 16:case 17:case 18:case 19:case 20:for(a=0,o=se;a<o.length;a++)W=o[a],(i=mr(W.data.target,W.event)).id>0&&((r=[W.time,W.event]).push(i.id),r.push(W.data.x),r.push(W.data.y),void 0!==W.data.id&&(r.push(W.data.id),void 0!==W.data.isPrimary&&r.push(W.data.isPrimary.toString())),Rn(r),(void 0===W.data.isPrimary||W.data.isPrimary)&&X(W.event,W.data.x,W.data.y,W.time));break;case 9:case 48:for(u=0,c=_e;u<c.length;u++)W=c[u],s=mr(W.data.target,W.event,W.data.text),r=[W.time,W.event],l=s.hash?s.hash.join("."):"",console.log("[GemX - Interaction - Encode]",{cHash:l,cTarget:s}),r.push(s.id),r.push(W.data.x),r.push(W.data.y),r.push(W.data.eX),r.push(W.data.eY),r.push(W.data.button),r.push(W.data.reaction),r.push(W.data.context),r.push(b(W.data.text,"click",s.privacy)),r.push(_(W.data.link)),r.push(l),r.push(W.data.trust),r.push(W.data.isFullText),r.push(W.data.w),r.push(W.data.h),r.push(W.data.tag),r.push(W.data.class),r.push(W.data.id),r.push(W.data.source),Rn(r),bn(W.time,W.event,l,W.data.x,W.data.y,W.data.reaction,W.data.context);Me();break;case 38:for(f=0,p=se;f<p.length;f++)W=p[f],r=[W.time,W.event],(H=mr(W.data.target,W.event)).id>0&&(r.push(H.id),r.push(W.data.action),Rn(r));break;case 11:h=Xe,r.push(h.width),r.push(h.height),X(t,h.width,h.height),Ae(),Rn(r);break;case 26:v=en,r.push(v.name),r.push(v.persisted),on(),Rn(r);break;case 27:for(g=0,m=se;g<m.length;g++)W=m[g],w=mr(W.data.target,W.event,W.data.value),(r=[W.time,W.event]).push(w.id),r.push(b(W.data.value,"input",w.privacy,!1,W.data.type)),r.push(W.data.trust),Rn(r);break;case 21:(y=le)&&(k=mr(y.start),T=mr(y.end),r.push(k.id),r.push(y.startOffset),r.push(T.id),r.push(y.endOffset),Rn(r));break;case 10:for(x=0,S=Re;x<S.length;x++)W=S[x],O=mr(W.data.target,W.event),E=mr(W.data.top,W.event),N=mr(W.data.bottom,W.event),I=(null==E?void 0:E.hash)?E.hash.join("."):"",M=(null==N?void 0:N.hash)?N.hash.join("."):"",O.id>0&&((r=[W.time,W.event]).push(O.id),r.push(W.data.x),r.push(W.data.y),r.push(I),r.push(M),r.push(W.data.trust),Rn(r),X(W.event,W.data.x,W.data.y,W.time));Be();break;case 42:for(j=0,Y=se;j<Y.length;j++)W=Y[j],r=[W.time,W.event],(H=mr(W.data.target,W.event)).id>0&&((r=[W.time,W.event]).push(H.id),r.push(W.data.type),r.push(b(W.data.value,"change",H.privacy)),r.push(b(W.data.checksum,"checksum",H.privacy)),Rn(r));break;case 39:for(C=0,z=Qe;C<z.length;C++)W=z[C],r=[W.time,W.event],(H=mr(W.data.target,W.event)).id>0&&(r.push(H.id),Rn(r));tn();break;case 22:for(D=0,A=wn;D<A.length;D++)W=A[D],(r=[W.time,W.event]).push(W.data.type),r.push(W.data.hash),r.push(W.data.x),r.push(W.data.y),r.push(W.data.reaction),r.push(W.data.context),Rn(r,!1);yn();break;case 28:R=un,r.push(R.visible),Rn(r),P(n,R.visible),ln();break;case 50:L=dn,r.push(L.focused),Rn(r,!1),pn()}return[2]}))}))}var mn=[],wn=[];function yn(){wn=[]}function bn(t,e,n,r,a,o,i){void 0===o&&(o=1),void 0===i&&(i=0),mn.push({time:t,event:22,data:{type:e,hash:n,x:r,y:a,reaction:o,context:i}}),X(e,r,a,t)}function _n(){if(ka){var t=[];wn=[];for(var e=(ka.start||0)+(ka.duration||0),n=Math.max(e-2e3,0),r=0,a=mn;r<a.length;r++){var o=a[r];o.time>=n&&(o.time<=e&&wn.push(o),t.push(o))}mn=t,gn(22)}}var kn=Object.freeze({__proto__:null,compute:_n,reset:yn,start:function(){mn=[],yn()},stop:function(){mn=[],yn()},track:bn,get updates(){return wn}}),Tn=[],xn=!1,Sn=null;function On(t){xn&&"function"==typeof t&&Tn.push(t)}function En(t){if(xn){var e=t?t.split(" "):[""],n=e.length>1?parseInt(e[1],10):null;n&&Sn.has(n)||function(t,e){try{var n=document.createElement("script");n.src=t,n.async=!0,n.onload=function(){e&&(Sn.add(e),Y(Sn))},n.onerror=function(){Ea(new Error("".concat("MODULE",": ").concat(t)))},document.head.appendChild(n)}catch(t){}}(e[0],n)}}var Nn,In,Mn,Xn,jn,Pn,Yn=Object.freeze({__proto__:null,event:En,register:On,start:function(){xn=!0,Sn=new Set,u.modules&&u.modules.length>0&&u.modules.forEach((function(t){En(t)}))},stop:function(){Tn.reverse().forEach((function(t){try{t()}catch(t){}})),Tn=[],xn=!1}}),Cn=0,zn=0,Hn=null,Dn=0,An=!1;function Wn(){Xn=!0,Cn=0,zn=0,An=!1,Dn=0,Nn=[],In=[],Mn={},jn=null}function Rn(t,e){if(void 0===e&&(e=!0),Xn){var n=d(),r=t.length>1?t[1]:null,a=JSON.stringify(t);switch(u.lean?!An&&zn+a.length>10485760&&(xt(10,0),An=!0):An=!1,r){case 5:if(An)break;if(ee()){ne(t,a.length);break}Cn+=a.length;case 37:case 6:case 43:case 45:case 46:case 44:case 51:if(An)break;ee()&&ne(t,a.length),zn+=a.length,Nn.push(a);break;default:In.push(a)}L(25);var o=function(){var t=!1===u.lean&&Cn>0?100:ka.sequence*u.delay;return"string"==typeof u.upload?Math.max(Math.min(t,3e4),100):u.delay}();n-Dn>2*o&&(G(Hn),Hn=null),e&&null===Hn&&(25!==r&&Z(),Hn=F(Fn,o),Dn=n,Xr(zn))}}function Ln(t){Xn&&(G(Hn),Hn=null,Fn(!1,t))}function qn(t){for(var e=0,n=t;e<n.length;e++){var r=n[e],a=JSON.stringify(r);Cn+=a.length,zn+=a.length,Nn.push(a)}}function Un(){G(Hn),Fn(!0),Cn=0,zn=0,An=!1,Dn=0,Nn=[],In=[],Mn={},jn=null,Xn=!1}function Fn(t,e){return void 0===t&&(t=!1),at(this,void 0,void 0,(function(){var n,r,a,o,i,c,s,l;return ot(this,(function(d){switch(d.label){case 0:return Xn?(Hn=null,(n=("gemx-snapshot"===e||!1===u.lean)&&zn>0&&(zn<1048576||ka.sequence>0))&&U(1,1),_n(),ce(),r=!0===t,ka?(a=JSON.stringify(Sa(r)),o="[".concat(In.join(),"]"),i=n?"[".concat(Nn.join(),"]"):"",r&&i.length>0&&a.length+o.length+i.length>65536&&(i=""),c=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:a,a:o,p:i}),r?(l=null,[3,3]):[3,1]):[2]):[2];case 1:return[4,ut(c)];case 2:l=d.sent(),d.label=3;case 3:return q(2,(s=l)?s.length:c.length),Gn(c,s,ka.sequence,r,e),In=[],n&&(Nn=[],zn=0,Cn=0,An=!1),[2]}}))}))}function Gn(t,e,n,r,a){if(void 0===r&&(r=!1),"string"==typeof u.upload){var o=u.upload,i=!1;if(r&&navigator&&navigator.sendBeacon)try{(i=navigator.sendBeacon.bind(navigator)(o,t))&&Jn(n)}catch(t){}if(!1===i){n in Mn?Mn[n].attempts++:Mn[n]={data:t,attempts:1};var c=new XMLHttpRequest;c.open("POST",o,!0),c.timeout=15e3,c.ontimeout=function(){Ea(new Error("".concat("Timeout"," : ").concat(o)))},null!==n&&(c.onreadystatechange=function(){Na(Vn)(c,n)}),c.withCredentials=!0,e?(c.setRequestHeader("Accept","application/x-clarity-gzip"),c.send(e)):c.send(t)}}else if(u.upload){(0,u.upload)(t,a),Jn(n)}}function Vn(t,e){var n=Mn[e];t&&4===t.readyState&&n&&((t.status<200||t.status>208)&&n.attempts<=1?t.status>=400&&t.status<500?jr(6):(0===t.status&&(u.upload=u.fallback?u.fallback:u.upload),jn={sequence:e,attempts:n.attempts,status:t.status},Ir(2),Gn(n.data,null,e)):(jn={sequence:e,attempts:n.attempts,status:t.status},n.attempts>1&&Ir(2),200===t.status&&t.responseText&&function(t){for(var e=t&&t.length>0?t.split("\n"):[],n=0,r=e;n<r.length;n++){var a=r[n],o=a&&a.length>0?a.split(/ (.*)/):[""];switch(o[0]){case"END":jr(6);break;case"UPGRADE":Er("Auto");break;case"ACTION":u.action&&o.length>1&&u.action(o[1]);break;case"EXTRACT":o.length>1&&Xt(o[1]);break;case"SIGNAL":o.length>1&&ae(o[1]);break;case"MODULE":o.length>1&&En(o[1]);break;case"SNAPSHOT":u.lean=!1,wr()}}}(t.responseText),0===t.status&&(Gn(n.data,null,e,!0),jr(3)),t.status>=200&&t.status<=208&&Jn(e),delete Mn[e]))}function Jn(t){1===t&&(ga(),va())}function Bn(t){return at(this,void 0,void 0,(function(){var e,n,r,a,o,i,u,c,s,l,f,p,h;return ot(this,(function(v){switch(e=d(),n=[e,t],t){case 8:r=Pn,n.push(r.width),n.push(r.height),X(t,r.width,r.height),Rn(n);break;case 43:if((a=sr).length>0){for(o=0,i=a;o<i.length;o++)for(u=i[o],c=u.metadata.privacy,s=u.data,l=0,f=["tag","attributes","value"];l<f.length;l++)if(s[p=f[l]])switch(p){case"tag":n.push(u.id),u.parent&&n.push(u.parent),u.previous&&n.push(u.previous),n.push(s[p]);break;case"attributes":for(h in s[p])void 0!==s[p][h]&&n.push(Zn(h,s[p][h],c,s.tag));break;case"value":n.push(b(s[p],s.tag,c))}Rn(function(t){for(var e=[],n={},r=0,a=null,o=0;o<t.length;o++)if("string"==typeof t[o]){var i=t[o],u=n[i]||-1;u>=0?a?a.push(u):(a=[u],e.push(a),r++):(a=null,e.push(i),n[i]=r++)}else a=null,e.push(t[o]),r++;return e}(n),!0)}}return[2]}))}))}function Zn(t,e,n,r){return"href"===t&&"LINK"===r?"".concat(t,"=").concat(e):"".concat(t,"=").concat(b(e,0===t.indexOf("data-")?"data-":t,n))}function Kn(){Pn=null}function Qn(){var t,e,n,r,a,o,i,u,c,s,l,d,f,p,h,v;Kn(),t=document.body,e=document.documentElement,n=t?t.clientWidth:null,r=t?t.scrollWidth:null,a=t?t.offsetWidth:null,o=e?e.clientWidth:null,i=e?e.scrollWidth:null,u=e?e.offsetWidth:null,c=Math.max(n,r,a,o,i,u),s=t?t.clientHeight:null,l=t?t.scrollHeight:null,d=t?t.offsetHeight:null,f=e?e.clientHeight:null,p=e?e.scrollHeight:null,h=e?e.offsetHeight:null,v=Math.max(s,l,d,f,p,h),null!==Pn&&c===Pn.width&&v===Pn.height||null===c||null===v||(Pn={width:c,height:v},Bn(8))}var $n=!1;function tr(t){t&&t.persisted&&(Ba(),xt(11,0))}var er=Object.freeze({__proto__:null,start:function(){if(!$n)try{window[c("addEventListener")]("pageshow",Na(tr),{capture:!1,passive:!0}),$n=!0}catch(t){}},stop:function(){}}),nr=[kn,je,We,fn,Ke,er,cn],rr=[kn,je,de,de,de,We,fn,vn,er,Ke,de,de,nn,cn],ar={allRoots:[Ke],documentOnly:[je]},or={allRoots:[Ke],documentOnly:[je,de,de,de,de,de,nn]},ir=rr;function ur(t){var e="gemx"===u.mode?ar:or;e.allRoots.forEach((function(e){return e.observe(t)})),t.nodeType===Node.DOCUMENT_NODE&&e.documentOnly.forEach((function(e){return e.observe(t)}))}var cr=Object.freeze({__proto__:null,observe:ur,start:function(){(ir="gemx"===u.mode?nr:rr).forEach((function(t){return t.start()}))},stop:function(){ir.forEach((function(t){return t.stop()}))}}),sr=[],lr=1,dr=null;function fr(){yr(),Qn(),_r(document.documentElement),ur(document)}function pr(){return!1}function hr(){return{x:0,y:0}}function vr(){}function gr(t){var e=t.composed&&t.composedPath?t.composedPath():null,n=e&&e.length>0?e[0]:t.target;return n.nodeType===Node.DOCUMENT_NODE?n.documentElement:n}function mr(t){var e={id:0,hash:null,privacy:u.conversions?1:5};return t&&(e.id=dr.has(t)?dr.get(t):_r(t)),e}function wr(){sr=[],function(t){var e=[t];for(;e.length>0;){for(var n=null,r=null,a=null,o=e.shift(),i=o.firstChild,u=o.parentElement?o.parentElement:o.parentNode?o.parentNode:null;i;)e.push(i),i=i.nextSibling;switch(o.nodeType){case Node.DOCUMENT_TYPE_NODE:var c=o;r="*D",n={name:c.name,publicId:c.publicId,systemId:c.systemId};break;case Node.TEXT_NODE:a=o.nodeValue,r=dr.get(u)?"*T":r;break;case Node.ELEMENT_NODE:var s=o;n=br(s),r=["NOSCRIPT","SCRIPT","STYLE"].indexOf(s.tagName)<0?s.tagName:r}kr(o,u,{tag:r,attributes:n,value:a})}}(document),Bn(43)}function yr(){dr=new WeakMap}function br(t){var e={},n=t.attributes;if(n&&n.length>0)for(var r=0;r<n.length;r++)e[n[r].name]=n[r].value;return e}function _r(t){return null===t?null:dr.has(t)?dr.get(t):(dr.set(t,lr),lr++)}function kr(t,e,n){if(t&&n&&n.tag){var r=_r(t),a=e?dr.get(e):null,o=t.previousSibling?dr.get(t.previousSibling):null;sr.push({id:r,parent:a,previous:o,children:[],data:n,selector:null,hash:null,region:null,metadata:{active:!0,suspend:!1,privacy:5,position:null,fraud:null,size:null}})}}var Tr,xr=Object.freeze({__proto__:null,compute:function(){},get:function(t){return null},hashText:vr,iframe:pr,metadata:mr,offset:hr,snapshot:wr,start:fr,stop:function(){yr(),Kn()},target:gr,get values(){return sr}}),Sr=null;function Or(){!u.lean&&u.upgrade&&u.upgrade("Config"),Sr=null}function Er(t){qa()&&u.lean&&(u.lean=!1,Sr={key:t},va(),ga(),u.upgrade&&u.upgrade(t),Ir(3),u.lite&&fr())}function Nr(){Sr=null}function Ir(t){var e=[d(),t];switch(t){case 4:var n=E;n&&n.data&&((e=[n.time,n.event]).push(n.data.visible),e.push(n.data.docWidth),e.push(n.data.docHeight),e.push(n.data.screenWidth),e.push(n.data.screenHeight),e.push(n.data.scrollX),e.push(n.data.scrollY),e.push(n.data.pointerX),e.push(n.data.pointerY),e.push(n.data.activityTime),e.push(n.data.scrollTime),e.push(n.data.pointerTime),e.push(n.data.moveX),e.push(n.data.moveY),e.push(n.data.moveTime),e.push(n.data.downX),e.push(n.data.downY),e.push(n.data.downTime),e.push(n.data.upX),e.push(n.data.upY),e.push(n.data.upTime),e.push(n.data.pointerPrevX),e.push(n.data.pointerPrevY),e.push(n.data.pointerPrevTime),e.push(n.data.modules),Rn(e,!1)),M();break;case 25:e.push(A.gap),Rn(e);break;case 35:e.push(Tr.check),Rn(e,!1);break;case 3:e.push(Sr.key),Rn(e);break;case 2:e.push(jn.sequence),e.push(jn.attempts),e.push(jn.status),Rn(e,!1);break;case 24:H.key&&e.push(H.key),e.push(H.value),Rn(e);break;case 34:var r=Object.keys(st);if(r.length>0){for(var a=0,o=r;a<o.length;a++){var i=o[a];e.push(i),e.push(st[i])}ht(),Rn(e,!1)}break;case 0:var u=Object.keys(R);if(u.length>0){for(var c=0,s=u;c<s.length;c++){var l=s[c],f=parseInt(l,10);e.push(f),e.push(Math.round(R[l]))}R={},Rn(e,!1)}break;case 1:var p=Object.keys(zr);if(p.length>0){for(var h=0,v=p;h<v.length;h++){var g=v[h];f=parseInt(g,10);e.push(f),e.push(zr[g])}Lr(),Rn(e,!1)}break;case 36:var m=Object.keys($);if(m.length>0){for(var w=0,y=m;w<y.length;w++){var b=y[w];f=parseInt(b,10);e.push(f),e.push([].concat.apply([],$[b]))}et(),Rn(e,!1)}break;case 40:Ot.forEach((function(t){e.push(t);var n=[];for(var r in St[t]){var a=parseInt(r,10);n.push(a),n.push(St[t][r])}e.push(n)})),Yt(),Rn(e,!1);break;case 47:e.push(qr.source),e.push(qr.ad_Storage),e.push(qr.analytics_Storage),Rn(e,!1)}}function Mr(){Tr={check:0}}function Xr(t){if(0===Tr.check){var e=Tr.check;e=ka.sequence>=128?1:e,e=ka.pageNum>=128?7:e,e=d()>72e5?2:e,(e=t>10485760?2:e)!==Tr.check&&jr(e)}}function jr(t){Tr.check=t,5!==t&&(ha(),Za())}function Pr(){0!==Tr.check&&Ir(35)}function Yr(){Tr=null}var Cr=null,zr=null,Hr=!1;function Dr(){Cr={},zr={},Hr=!1}function Ar(){Cr={},zr={},Hr=!1}function Wr(t,e){if(e&&(e="".concat(e),t in Cr||(Cr[t]=[]),Cr[t].indexOf(e)<0)){if(Cr[t].length>128)return void(Hr||(Hr=!0,jr(5)));Cr[t].push(e),t in zr||(zr[t]=[]),zr[t].push(e)}}function Rr(){Ir(1)}function Lr(){zr={},Hr=!1}var qr=null,Ur=!0;function Fr(){var t,e=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics;Ur=!0,(null==e?void 0:e.addListener)&&e.addListener(["ad_storage","analytics_storage"],Vr)}function Gr(){Ur=!0}function Vr(){var t,e=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics;if(null==e?void 0:e.getConsentState)try{var n=e.getConsentState("analytics_storage");da(function(t){var e={source:2,ad_Storage:1===t.ad_Storage?"granted":"denied",analytics_Storage:1===t.analytics_Storage?"granted":"denied"};return e}({ad_Storage:e.getConsentState("ad_storage"),analytics_Storage:n}))}catch(t){return}}function Jr(t){Zr(t.analytics_Storage?1:0),qr=t}function Br(){Zr(2)}function Zr(t){Wr(36,t.toString())}function Kr(t){qr=t,Ir(47)}function Qr(){var t;if(Ur&&(Ir(47),Ur=!1,!u.track)){var e=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics;(null==e?void 0:e.usedUpdate)&&Vr()}}var $r=null,ta=[],ea=0,na=null,ra=!1,aa={source:7,ad_Storage:"denied",analytics_Storage:"denied"};function oa(){var t,e,n,r=navigator&&"userAgent"in navigator?navigator.userAgent:"",a=null!==(n="undefined"!=typeof Intl&&(null===(e=null===(t=null===Intl||void 0===Intl?void 0:Intl.DateTimeFormat())||void 0===t?void 0:t.resolvedOptions())||void 0===e?void 0:e.timeZone))&&void 0!==n?n:"",o=(new Date).getTimezoneOffset().toString(),i=window.location.ancestorOrigins?Array.from(window.location.ancestorOrigins).toString():"",c=document&&document.title?document.title:"";ea=r.indexOf("Electron")>0?1:0;var s=function(){var t={session:wa(),ts:Math.round(Date.now()),count:1,upgrade:null,upload:""},e=Ut("_clsk",!u.includeSubdomains);if(e){var n=e.includes("^")?e.split("^"):e.split("|");n.length>=5&&t.ts-ya(n[1])<18e5&&(t.session=n[0],t.count=ya(n[2])+1,t.upgrade=ya(n[3]),t.upload=n.length>=6?"".concat("https://").concat(n[5],"/").concat(n[4]):"".concat("https://").concat(n[4]))}return t}(),l=ba(),d=u.projectId||p(location.host),f=u.externalSession&&u.userId?u.userId:l.id,h=u.externalSession&&u.sessionId?u.sessionId:s.session;$r={projectId:d,userId:f,sessionId:h,pageNum:s.count},u.lean=u.track&&null!==s.upgrade?0===s.upgrade:u.lean,u.upload=u.track&&"string"==typeof u.upload&&s.upload&&s.upload.length>"https://".length?s.upload:u.upload,Wr(0,r),Wr(3,c),Wr(1,_(location.href,!!ea)),Wr(2,document.referrer),Wr(15,function(){var t=wa();if(u.track&&Wt(window,"sessionStorage")){var e=sessionStorage.getItem("_cltk");t=e||t,sessionStorage.setItem("_cltk",t)}return t}()),Wr(16,document.documentElement.lang),Wr(17,document.dir),Wr(26,"".concat(window.devicePixelRatio)),Wr(28,l.dob.toString()),Wr(29,l.version.toString()),Wr(33,i),Wr(34,a),Wr(35,o),U(0,s.ts),U(1,0),U(35,ea);var v,g=null===window||void 0===window?void 0:window.Zone;g&&"__symbol__"in g&&U(39,1),navigator&&(Wr(9,navigator.language),U(33,navigator.hardwareConcurrency),U(32,navigator.maxTouchPoints),U(34,Math.round(navigator.deviceMemory)),(v=navigator.userAgentData)&&v.getHighEntropyValues?v.getHighEntropyValues(["model","platform","platformVersion","uaFullVersion"]).then((function(t){var e;Wr(22,t.platform),Wr(23,t.platformVersion),null===(e=t.brands)||void 0===e||e.forEach((function(t){Wr(24,t.name+"~"+t.version)})),Wr(25,t.model),U(27,t.mobile?1:0)})):Wr(22,navigator.platform)),screen&&(U(14,Math.round(screen.width)),U(15,Math.round(screen.height)),U(16,Math.round(screen.colorDepth))),null===na&&(na={source:l.consent?6:0,ad_Storage:u.track?"granted":"denied",analytics_Storage:u.track?"granted":"denied"}),ia(),Jr(fa(na)),u.externalSession||ma(l)}function ia(){if(!ra&&"granted"===(null==na?void 0:na.analytics_Storage)&&"granted"===(null==na?void 0:na.ad_Storage)){for(var t=0,e=u.cookies;t<e.length;t++){var n=e[t],r=Ut(n);r&&lt(n,r)}ra=!0}}function ua(){$r=null,ra=!1,ta.forEach((function(t){t.called=!1}))}function ca(t,e,n,r){void 0===e&&(e=!0),void 0===n&&(n=!1),void 0===r&&(r=!1);var a=u.lean?0:1,o=!1;$r&&(a||!1===e)&&(t($r,!u.lean,r?na:void 0),o=!0),!n&&o||ta.push({callback:t,wait:e,recall:n,called:o,consentInfo:r})}function sa(){return $r?[$r.userId,$r.sessionId,$r.pageNum].join("."):""}function la(t){void 0===t&&(t=!0),da(t?{source:4,ad_Storage:"granted",analytics_Storage:"granted"}:{source:4,ad_Storage:"denied",analytics_Storage:"denied"})}function da(t,e){var n;if(void 0===t&&(t=aa),void 0===e&&(e=5),qa()){var r={source:null!==(n=t.source)&&void 0!==n?n:e,ad_Storage:pa(t.ad_Storage,null==na?void 0:na.ad_Storage),analytics_Storage:pa(t.analytics_Storage,null==na?void 0:na.analytics_Storage)};if(na&&r.ad_Storage===na.ad_Storage&&r.analytics_Storage===na.analytics_Storage)return na.source=r.source,Kr(fa(na)),void Br();na=r,va(!0);var a=fa(na);if(!a.analytics_Storage&&u.track)return u.track=!1,ha(!0),Za(),void window.setTimeout(Ba,250);qa()&&a.analytics_Storage&&(u.track=!0,ma(ba(),1),ga()),ia(),Kr(a),Br()}}function fa(t){var e;return{source:null!==(e=t.source)&&void 0!==e?e:255,ad_Storage:"granted"===t.ad_Storage?1:0,analytics_Storage:"granted"===t.analytics_Storage?1:0}}function pa(t,e){return void 0===e&&(e="denied"),"string"==typeof t?t.toLowerCase():e}function ha(t){void 0===t&&(t=!1),Ft("_clsk","",0),t&&Ft("_clck","",0)}function va(t){void 0===t&&(t=!1),function(t,e){void 0===e&&(e=!1);if(ta.length>0)for(var n=0;n<ta.length;n++){var r=ta[n];r.callback&&(!r.called&&!e||r.consentInfo&&e)&&(!r.wait||t)&&(r.callback($r,!u.lean,r.consentInfo?na:void 0),r.called=!0,r.recall||(ta.splice(n,1),n--))}}(u.lean?0:1,t)}function ga(){if($r&&u.track&&!u.externalSession){var t=Math.round(Date.now()),e=u.upload&&"string"==typeof u.upload?u.upload.replace("https://",""):"",n=u.lean?0:1;Ft("_clsk",[$r.sessionId,t,$r.pageNum,n,e].join(qt),1)}}function ma(t,e){void 0===e&&(e=null),e=null===e?t.consent:e;var n=Math.ceil((Date.now()+31536e6)/864e5),r=0===t.dob?null===u.dob?0:u.dob:t.dob;(null===t.expiry||Math.abs(n-t.expiry)>=1||t.consent!==e||t.dob!==r)&&Ft("_clck",[$r.userId,2,n.toString(36),e,r].join(qt),365)}function wa(){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 ya(t,e){return void 0===e&&(e=10),parseInt(t,e)}function ba(){var t={id:wa(),version:0,expiry:null,consent:0,dob:0},e=Ut("_clck",!u.includeSubdomains);if(e&&e.length>0){var n=e.includes("^")?e.split("^"):e.split("|");n.length>1&&(t.version=ya(n[1])),n.length>2&&(t.expiry=ya(n[2],36)),n.length>3&&1===ya(n[3])&&(t.consent=1),n.length>4&&ya(n[1])>1&&(t.dob=ya(n[4])),u.track=u.track||1===t.consent,t.id=u.track?n[0]:t.id}return t}var _a,ka=null;function Ta(){var t=$r;ka={version:f,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 xa(){ka=null}function Sa(t){return ka.start=ka.start+ka.duration,ka.duration=d()-ka.start,ka.sequence++,ka.upload=t&&"sendBeacon"in navigator?1:0,ka.end=t?1:0,ka.applicationPlatform=0,ka.url=_(location.href,!1,!0),[ka.version,ka.sequence,ka.start,ka.duration,ka.projectId,ka.userId,ka.sessionId,ka.pageNum,ka.upload,ka.end,ka.applicationPlatform,ka.url]}function Oa(){_a=[]}function Ea(t){if(_a&&-1===_a.indexOf(t.message)){var e=u.report;if(e&&e.length>0&&ka){var n={v:ka.version,p:ka.projectId,u:ka.userId,s:ka.sessionId,n:ka.pageNum};t.message&&(n.m=t.message),t.stack&&(n.e=t.stack);var r=new XMLHttpRequest;r.open("POST",e,!0),r.send(JSON.stringify(n)),_a.push(t.message)}}return t}function Na(t){return function(){var e=performance.now();try{t.apply(this,arguments)}catch(t){throw Ea(t)}var n=performance.now()-e;q(4,n),n>30&&(L(7),U(6,n),t.dn&&xt(9,0,"".concat(t.dn,"-").concat(n)))}}var Ia=new Map;function Ma(t,e,n,r,a){void 0===r&&(r=!1),void 0===a&&(a=!0),n=Na(n);try{t[c("addEventListener")](e,n,{capture:r,passive:a}),function(t){return Ia.has(t)}(t)||Ia.set(t,[]),Ia.get(t).push({event:e,listener:n,options:{capture:r,passive:a}})}catch(t){}}function Xa(){Ia.forEach((function(t,e){!function(t,e){t.forEach((function(t){try{e[c("removeEventListener")](t.event,t.listener,{capture:t.options.capture,passive:t.options.passive})}catch(t){}})),Ia.delete(e)}(t,e)})),Ia=new Map}var ja=null,Pa=null,Ya=null,Ca=0;function za(){return!(Ca++>20)||(xt(4,0),!1)}function Ha(){Ca=0,Ya!==Aa()&&(Za(),window.setTimeout(Da,250))}function Da(){Ba(),U(29,1)}function Aa(){return location.href?location.href.replace(location.hash,""):location.href}var Wa=!1;function Ra(){Wa=!0,s=l(),ge(),Xa(),Oa(),function(){if(Ya=Aa(),Ca=0,Ma(window,"popstate",Ha),null===ja)try{ja=history.pushState,history.pushState=function(){ja.apply(this,arguments),qa()&&za()&&Ha()}}catch(t){ja=null}if(null===Pa)try{Pa=history.replaceState,history.replaceState=function(){Pa.apply(this,arguments),qa()&&za()&&Ha()}}catch(t){Pa=null}}()}function La(){Ya=null,Ca=0,Oa(),Xa(),ge(),s=0,Wa=!1}function qa(){return Wa}function Ua(){Ba(),D("clarityGemX","restart")}var Fa=Object.freeze({__proto__:null,start:function(){!function(){U(26,navigator.webdriver?1:0);try{U(31,window.top==window.self||window.top==window?1:2)}catch(t){U(31,0)}}(),Ma(window,"error",bt),yt={},Tt={}},stop:function(){Tt={}}}),Ga=[Fa,xr,cr],Va=[Fa,xr,cr,de,Yn],Ja=Va;function Ba(t){void 0===t&&(t=null),Ja="gemx"===t.mode?Ga:Va,function(){try{var t=navigator&&"globalPrivacyControl"in navigator&&1==navigator.globalPrivacyControl;return!1===Wa&&"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||Wa)return!1;for(var e in t)e in u&&(u[e]=t[e])}(t),Ra(),ie(),Ja.forEach((function(t){return Na(t.start)()})),null===t&&to())}function Za(){qa()&&(Ja.slice().reverse().forEach((function(t){return Na(t.stop)()})),ue(),La(),void 0!==Qa&&(Qa[$a]=function(){(Qa[$a].q=Qa[$a].q||[]).push(arguments),"start"===arguments[0]&&Qa[$a].q.unshift(Qa[$a].q.pop())&&to()}))}var Ka=Object.freeze({__proto__:null,consent:la,consentv2:da,dlog:Wr,event:D,hashText:vr,identify:dt,maxMetric:U,measure:Na,metadata:ca,pause:function(){qa()&&(D("clarityGemX","pause"),null===he&&(he=new Promise((function(t){ve=t}))))},queue:Rn,register:On,resume:function(){qa()&&(he&&(ve(),he=null,null===pe&&we()),D("clarityGemX","resume"))},schedule:me,set:lt,signal:function(t){re=t},start:Ba,stop:Za,time:d,upgrade:Er,version:f}),Qa=window,$a="clarityGemX";function to(){if(void 0!==Qa){if(Qa[$a]&&Qa[$a].v)return console.warn("Error CL001: Multiple Clarity tags detected.");var t=Qa[$a]&&Qa[$a].q||[];for(Qa[$a]=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];return Ka[t].apply(Ka,e)},Qa[$a].v=f;t.length>0;)Qa[$a].apply(Qa,t.shift())}}to()}();
1
+ !function(){"use strict";var t=Object.freeze({__proto__:null,get flush(){return qn},get inject(){return Un},get queue(){return Ln},get start(){return Rn},get stop(){return Fn},get track(){return Pn}}),e=Object.freeze({__proto__:null,get data(){return Or},get start(){return Er},get stop(){return Ir},get upgrade(){return Nr}}),n=Object.freeze({__proto__:null,get check(){return jr},get compute(){return Yr},get data(){return xr},get start(){return Xr},get stop(){return Cr},get trigger(){return Pr}}),r=Object.freeze({__proto__:null,get compute(){return Lr},get data(){return zr},get log(){return Rr},get reset(){return qr},get start(){return Ar},get stop(){return Wr},get updates(){return Hr}}),a=Object.freeze({__proto__:null,get compute(){return $r},get config(){return Br},get consent(){return Zr},get data(){return Ur},get start(){return Gr},get stop(){return Vr},get trackConsentv2(){return Qr}}),o=Object.freeze({__proto__:null,get callback(){return ga},get callbacks(){return ea},get clear(){return va},get consent(){return da},get consentv2(){return fa},get data(){return ta},get electron(){return na},get id(){return la},get metadata(){return sa},get save(){return ma},get shortid(){return ya},get start(){return ia},get stop(){return ca}}),i=Object.freeze({__proto__:null,get data(){return Ta},get envelope(){return Oa},get start(){return xa},get stop(){return Sa}}),u={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,modules:[],diagnostics:!1,externalSession:!1,userId:null,sessionId:null,mode:"gemx"};function c(t){return window.Zone&&"__symbol__"in window.Zone?window.Zone.__symbol__(t):t}var s=0;function l(){return performance.now()+performance.timeOrigin}function d(t){void 0===t&&(t=null);var e=0===s?l():s,n=t&&t.timeStamp>0?t.timeStamp:performance.now(),r=t&&t.view?t.view.performance.timeOrigin:performance.timeOrigin;return Math.max(Math.round(n+r-e),0)}var f="0.8.90";function p(t,e){void 0===e&&(e=null);for(var n,r=5381,a=r,o=0;o<t.length;o+=2){if(r=(r<<5)+r^t.charCodeAt(o),o+1<t.length)a=(a<<5)+a^t.charCodeAt(o+1)}return n=Math.abs(r+11579*a),(e?n%Math.pow(2,e):n).toString(36)}var h=/\S/gi,v=255,g=!0,m=null,w=null,y=null;function b(t,e,n,r,a){if(void 0===r&&(r=!1),t){if("input"==e&&("checkbox"===a||"radio"===a))return t;switch(n){case 0:return t;case 1:switch(e){case"*T":case"value":case"placeholder":case"click":return function(t){var e=-1,n=0,r=!1,a=!1,o=!1,i=null;O();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(e+1,o?u:u+1);s=g&&null!==y?s.match(y)?s:x(s,"▪","▫"):T(s),i.splice(e+1-n,s.length,s),n+=s.length-1}o&&(r=!1,a=!1,e=u)}}return i?i.join(""):t}(t);case"input":case"change":return S(t)}return t;case 2:case 3:switch(e){case"*T":case"data-":return r?k(t):T(t);case"src":case"srcset":case"title":case"alt":case"href":case"xlink:href":return 3===n?(null==t?void 0:t.startsWith("blob:"))?"blob:":"":t;case"value":case"click":case"input":case"change":return S(t);case"placeholder":return T(t)}break;case 4:switch(e){case"*T":case"data-":return r?k(t):T(t);case"value":case"input":case"click":case"change":return Array(5).join("•");case"checksum":return""}break;case 5:switch(e){case"*T":case"data-":return x(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 _(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!1);var r=t;if(e)r="".concat("https://").concat("Electron");else{var a=u.drop;if(a&&a.length>0&&t&&t.indexOf("?")>0){var o=t.split("?"),i=o[0],c=o[1];r=i+"?"+c.split("&").map((function(t){return a.some((function(e){return 0===t.indexOf("".concat(e,"="))}))?"".concat(t.split("=")[0],"=").concat("*na*"):t})).join("&")}}return n&&(r=r.substring(0,v)),r}function k(t){var e=t.trim();if(e.length>0){var n=e[0],r=t.indexOf(n),a=t.substr(0,r),o=t.substr(r+e.length);return"".concat(a).concat(e.length.toString(36)).concat(o)}return t}function T(t){return t.replace(h,"•")}function x(t,e,n){return O(),t?t.replace(w,e).replace(m,n):t}function S(t){for(var e=5*(Math.floor(t.length/5)+1),n="",r=0;r<e;r++)n+=r>0&&r%5==0?" ":"•";return n}function O(){if(g&&null===m)try{m=new RegExp("\\p{N}","gu"),w=new RegExp("\\p{L}","gu"),y=new RegExp("\\p{Sc}","gu")}catch(t){g=!1}}var E=null,N=null,I=!1;function M(){I&&(E={time:d(),event:4,data:{visible:N.visible,docWidth:N.docWidth,docHeight:N.docHeight,screenWidth:N.screenWidth,screenHeight:N.screenHeight,scrollX:N.scrollX,scrollY:N.scrollY,pointerX:N.pointerX,pointerY:N.pointerY,activityTime:N.activityTime,scrollTime:N.scrollTime,pointerTime:N.pointerTime,moveX:N.moveX,moveY:N.moveY,moveTime:N.moveTime,downX:N.downX,downY:N.downY,downTime:N.downTime,upX:N.upX,upY:N.upY,upTime:N.upTime,pointerPrevX:N.pointerPrevX,pointerPrevY:N.pointerPrevY,pointerPrevTime:N.pointerPrevTime,modules:N.modules}}),N=N||{visible:1,docWidth:0,docHeight:0,screenWidth:0,screenHeight:0,scrollX:0,scrollY:0,pointerX:0,pointerY:0,activityTime:0,scrollTime:0,pointerTime:void 0,moveX:void 0,moveY:void 0,moveTime:void 0,downX:void 0,downY:void 0,downTime:void 0,upX:void 0,upY:void 0,upTime:void 0,pointerPrevX:void 0,pointerPrevY:void 0,pointerPrevTime:void 0,modules:null}}function X(t,e,n,r){switch(t){case 8:N.docWidth=e,N.docHeight=n;break;case 11:N.screenWidth=e,N.screenHeight=n;break;case 10:N.scrollX=e,N.scrollY=n,N.scrollTime=r;break;case 12:N.moveX=e,N.moveY=n,N.moveTime=r,N.pointerPrevX=N.pointerX,N.pointerPrevY=N.pointerY,N.pointerPrevTime=N.pointerTime,N.pointerX=e,N.pointerY=n,N.pointerTime=r;break;case 13:N.downX=e,N.downY=n,N.downTime=r,N.pointerPrevX=N.pointerX,N.pointerPrevY=N.pointerY,N.pointerPrevTime=N.pointerTime,N.pointerX=e,N.pointerY=n,N.pointerTime=r;break;case 14:N.upX=e,N.upY=n,N.upTime=r,N.pointerPrevX=N.pointerX,N.pointerPrevY=N.pointerY,N.pointerPrevTime=N.pointerTime,N.pointerX=e,N.pointerY=n,N.pointerTime=r;break;default:N.pointerPrevX=N.pointerX,N.pointerPrevY=N.pointerY,N.pointerPrevTime=N.pointerTime,N.pointerX=e,N.pointerY=n,N.pointerTime=r}I=!0}function j(t){N.activityTime=t}function P(t,e){N.visible=e,N.visible||j(t),I=!0}function Y(t){N.modules=Array.from(t),I=!0}function C(){I&&Mr(4)}var z=Object.freeze({__proto__:null,activity:j,compute:C,dynamic:Y,reset:M,start:function(){I=!1,M()},get state(){return E},stop:function(){M()},track:X,visibility:P}),H=null;function D(t,e){Ua()&&t&&"string"==typeof t&&t.length<255&&(H=e&&"string"==typeof e&&e.length<255?{key:t,value:e}:{value:t},Mr(24))}var A,W=null,R=null;function L(t){t in W||(W[t]=0),t in R||(R[t]=0),W[t]++,R[t]++}function q(t,e){null!==e&&(t in W||(W[t]=0),t in R||(R[t]=0),W[t]+=e,R[t]+=e)}function U(t,e){null!==e&&!1===isNaN(e)&&(t in W||(W[t]=0),(e>W[t]||0===W[t])&&(R[t]=e,W[t]=e))}function F(t,e,n){return window.setTimeout(Ia(t),e,n)}function G(t){return window.clearTimeout(t)}var V=0,J=0,B=null;function Z(){B&&G(B),B=F(K,J),V=d()}function K(){var t=d();A={gap:t-V},Mr(25),A.gap<3e5?B=F(K,J):Ra&&(D("clarityGemX","suspend"),Ka(),["mousemove","touchstart"].forEach((function(t){return Xa(document,t,Fa)})),["resize","scroll","pageshow"].forEach((function(t){return Xa(window,t,Fa)})))}var Q=Object.freeze({__proto__:null,get data(){return A},reset:Z,start:function(){J=6e4,V=0},stop:function(){G(B),V=0,J=0}}),$=null;function tt(){Mr(36)}function et(){$={}}var nt=Object.freeze({__proto__:null,compute:tt,get data(){return $},reset:et,start:function(){$={}},stop:function(){$={}},track:function(t,e){if(t in $){var n=$[t],r=n[n.length-1];e-r[0]>100?$[t].push([e,0]):r[1]=e-r[0]}else $[t]=[[e,0]]}}),rt=function(){return rt=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var a in e=arguments[n])Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t},rt.apply(this,arguments)};function at(t,e,n,r){return new(n||(n=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 e;t.done?a(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(i,u)}c((r=r.apply(t,e||[])).next())}))}function ot(t,e){var n,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(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(n=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=e.call(t,i)}catch(t){u=[6,t],r=0}finally{n=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,c])}}}var it="CompressionStream"in window;function ut(t){return at(this,void 0,void 0,(function(){var e,n;return ot(this,(function(r){switch(r.label){case 0:return r.trys.push([0,3,,4]),it?(e=new ReadableStream({start:function(e){return at(this,void 0,void 0,(function(){return ot(this,(function(n){return e.enqueue(t),e.close(),[2]}))}))}}).pipeThrough(new TextEncoderStream).pipeThrough(new window.CompressionStream("gzip")),n=Uint8Array.bind,[4,ct(e)]):[3,2];case 1:return[2,new(n.apply(Uint8Array,[void 0,r.sent()]))];case 2:return[3,4];case 3:return r.sent(),[3,4];case 4:return[2,null]}}))}))}function ct(t){return at(this,void 0,void 0,(function(){var e,n,r,a,o;return ot(this,(function(i){switch(i.label){case 0:e=t.getReader(),n=[],r=!1,a=[],i.label=1;case 1:return r?[3,3]:[4,e.read()];case 2:return o=i.sent(),r=o.done,a=o.value,r?[2,n]:(n.push.apply(n,a),[3,1]);case 3:return[2,n]}}))}))}var st=null;function lt(t,e){ft(t,"string"==typeof e?[e]:e)}function dt(t,e,n,r){return void 0===e&&(e=null),void 0===n&&(n=null),void 0===r&&(r=null),at(this,void 0,void 0,(function(){var a,o;return ot(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(x(u.substring(2),"*","*")):x(u,"*","*")),ft("userId",[(a=o).userId]),ft("userHint",[a.userHint]),ft("userType",[gt(t)]),e&&(ft("sessionId",[e]),a.sessionId=e),n&&(ft("pageId",[n]),a.pageId=n),[2,a]}var u}))}))}function ft(t,e){if(Ua()&&t&&e&&"string"==typeof t&&t.length<255){for(var n=(t in st?st[t]:[]),r=0;r<e.length;r++)"string"==typeof e[r]&&e[r].length<255&&n.push(e[r]);st[t]=n}}function pt(){Mr(34)}function ht(){st={}}function vt(t){return at(this,void 0,void 0,(function(){var e;return ot(this,(function(n){switch(n.label){case 0:return n.trys.push([0,4,,5]),crypto&&t?[4,crypto.subtle.digest("SHA-256",(new TextEncoder).encode(t))]:[3,2];case 1:return e=n.sent(),[2,Array.prototype.map.call(new Uint8Array(e),(function(t){return("00"+t.toString(16)).slice(-2)})).join("")];case 2:return[2,""];case 3:return[3,5];case 4:return n.sent(),[2,""];case 5:return[2]}}))}))}function gt(t){return t&&t.indexOf("@")>0?"email":"string"}var mt=Object.freeze({__proto__:null,compute:pt,get data(){return st},identify:dt,reset:ht,set:lt,start:function(){ht()},stop:function(){ht()}});var wt,yt={};function bt(t){var e=t.error||t;return e.message in yt||(yt[e.message]=0),yt[e.message]++>=5||e&&e.message&&(wt={message:e.message,line:t.lineno,column:t.colno,stack:e.stack,source:t.filename},_t(31)),!0}function _t(t){return at(this,void 0,void 0,(function(){var e;return ot(this,(function(n){switch(e=[d(),t],t){case 31:e.push(wt.message),e.push(wt.line),e.push(wt.column),e.push(wt.stack),e.push(_(wt.source)),Ln(e);break;case 33:kt&&(e.push(kt.code),e.push(kt.name),e.push(kt.message),e.push(kt.stack),e.push(kt.severity),Ln(e,!1))}return[2]}))}))}var kt,Tt={};function xt(t,e,n,r,a){void 0===n&&(n=null),void 0===r&&(r=null),void 0===a&&(a=null);var o=n?"".concat(n,"|").concat(r):"";t in Tt&&Tt[t].indexOf(o)>=0||(kt={code:t,name:n,message:r,stack:a,severity:e},t in Tt?Tt[t].push(o):Tt[t]=[o],_t(33))}var St={},Ot=new Set,Et={},Nt={},It={},Mt={};function Xt(t){try{var e=t&&t.length>0?t.split(/ (.*)/):[""],n=e[0].split(/\|(.*)/),r=parseInt(n[0]),a=n.length>1?n[1]:"",o=e.length>1?JSON.parse(e[1]):{};for(var i in Et[r]={},Nt[r]={},It[r]={},Mt[r]=a,o){var u=parseInt(i),c=o[i],s=2;switch(c.startsWith("~")?s=0:c.startsWith("!")&&(s=4),s){case 0:var l=c.slice(1);Et[r][u]=zt(l);break;case 2:Nt[r][u]=c;break;case 4:var d=c.slice(1);It[r][u]=d}}}catch(t){xt(8,1,t?t.name:null)}}function jt(t){return JSON.parse(JSON.stringify(t))}function Pt(){try{for(var t in Et){var e=parseInt(t);if(""==Mt[e]||document.querySelector(Mt[e])){var n=Et[e];for(var r in n){var a=parseInt(r),o=(m=Ht(jt(n[a])))?JSON.stringify(m).slice(0,1e4):m;o&&Ct(e,a,o)}var i=Nt[e];for(var u in i){var c=!1,s=parseInt(u),l=i[s];l.startsWith("@")&&(c=!0,l=l.slice(1));var d=document.querySelectorAll(l);if(d){var f=Array.from(d).map((function(t){return t.textContent})).join("<SEP>");Ct(e,s,(c?p(f).trim():f).slice(0,1e4))}}var h=It[e];for(var v in h){var g=parseInt(v);Ct(e,g,(void h[g]).trim().slice(0,1e4))}}}Ot.size>0&&Mr(40)}catch(t){xt(5,1,t?t.name:null)}var m}function Yt(){Ot.clear()}function Ct(t,e,n){var r,a=!1;t in St||(St[t]={},a=!0),r=It[t],0==Object.keys(r).length||e in St[t]&&St[t][e]==n||(a=!0),St[t][e]=n,a&&Ot.add(t)}function zt(t){for(var e=[],n=t.split(".");n.length>0;){var r=n.shift(),a=r.indexOf("["),o=r.indexOf("{"),i=r.indexOf("}");e.push({name:a>0?r.slice(0,a):o>0?r.slice(0,o):r,type:a>0?1:o>0?2:3,condition:o>0?r.slice(o+1,i):null})}return e}function Ht(t,e){if(void 0===e&&(e=window),0==t.length)return e;var n,r=t.shift();if(e&&e[r.name]){var a=e[r.name];if(1!==r.type&&Dt(a,r.condition))n=Ht(t,a);else if(Array.isArray(a)){for(var o=[],i=0,u=a;i<u.length;i++){var c=u[i];if(Dt(c,r.condition)){var s=Ht(t,c);s&&o.push(s)}}n=o}return n}return null}function Dt(t,e){if(e){var n=e.split(":");return n.length>1?t[n[0]]==n[1]:t[n[0]]}return!0}var At=Object.freeze({__proto__:null,clone:jt,compute:Pt,data:St,keys:Ot,reset:Yt,start:function(){Yt()},stop:function(){Yt()},trigger:Xt,update:Ct});function Wt(t,e){try{return!!t[e]}catch(t){return!1}}function Rt(t){try{var e=decodeURIComponent(t);return[e!=t,e]}catch(t){}return[!1,t]}var Lt=null,qt="^";function Ut(t,e){var n;if(void 0===e&&(e=!1),Wt(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=Rt(o[1]),u=i[0],c=i[1];u;)u=(n=Rt(c))[0],c=n[1];return e?c.endsWith("".concat("~","1"))?c.substring(0,c.length-2):null:c}}}return null}function Ft(t,e,n){if((u.track||""==e)&&(navigator&&navigator.cookieEnabled||Wt(document,"cookie"))){var r=function(t){return encodeURIComponent(t)}(e),a=new Date;a.setDate(a.getDate()+n);var o=a?"expires="+a.toUTCString():"",i="".concat(t,"=").concat(r).concat(";").concat(o).concat(";path=/");try{if(null===Lt){for(var c=location.hostname?location.hostname.split("."):[],s=c.length-1;s>=0;s--)if(Lt=".".concat(c[s]).concat(Lt||""),s<c.length-1&&(document.cookie="".concat(i).concat(";").concat("domain=").concat(Lt),Ut(t)===e))return;Lt=""}}catch(t){Lt=""}document.cookie=Lt?"".concat(i).concat(";").concat("domain=").concat(Lt):i}}var Gt=Object.freeze({__proto__:null,COOKIE_SEP:qt,getCookie:Ut,setCookie:Ft,start:function(){Lt=null},stop:function(){Lt=null}}),Vt={debug:!1,excludeClassNames:[],ignoreMutationClassNames:[],discoverTrigger:null},Jt=rt({},Vt);function Bt(){return Jt.debug}var Zt=Object.freeze({__proto__:null,get:function(){return Jt},isDebug:Bt,set:function(t){Jt=rt(rt({},Jt),t)},start:function(){var t,e,n,r,a,o,i,u;Jt={debug:new URLSearchParams(window.location.search).has("gemx_debug")||null!==(e=null===(t=null===window||void 0===window?void 0:window.GemXHeatmap)||void 0===t?void 0:t.debug)&&void 0!==e&&e,excludeClassNames:null!==(r=null===(n=null===window||void 0===window?void 0:window.GemXHeatmap)||void 0===n?void 0:n.excludeClassNames)&&void 0!==r?r:[],ignoreMutationClassNames:null!==(o=null===(a=null===window||void 0===window?void 0:window.GemXHeatmap)||void 0===a?void 0:a.ignoreMutationClassNames)&&void 0!==o?o:[],discoverTrigger:null!==(u=null===(i=null===window||void 0===window?void 0:window.GemXHeatmap)||void 0===i?void 0:i.discoverTrigger)&&void 0!==u?u:null}},stop:function(){Jt=rt({},Vt)}}),Kt=[],Qt=0,$t=!1,te=0,ee=null;function ne(){return $t}function re(t,e){Kt.push(t),Qt+=e,te>0&&Qt>=te&&ee&&ee()}var ae=null;function oe(t){try{if(!ae)return;var e=function(t){try{return JSON.parse(t)}catch(t){return[]}}(t);e.forEach((function(t){ae(t)}))}catch(t){}}var ie=[Zt,Object.freeze({__proto__:null,config:function(t,e){return te=null!=t?t:0,ee=null!=e?e:null,!0},drain:function(){$t=!1;var t=Kt;return Kt=[],Qt=0,t},getBytes:function(){return Qt},hold:re,isActive:ne,start:function(){Kt=[],Qt=0,$t=!0},stop:function(){Kt=[],Qt=0,$t=!1,te=0,ee=null}}),z,r,mt,n,nt,Gt,a,o,i,t,Q,e,At];function ue(){W={},R={},L(5),ie.forEach((function(t){return Ia(t.start)()}))}function ce(){ie.slice().reverse().forEach((function(t){return Ia(t.stop)()})),W={},R={}}function se(){C(),Yr(),$r(),"gemx"!==u.mode&&(pt(),Lr(),Mr(0),tt(),Pt())}var le=[],de=null;var fe=Object.freeze({__proto__:null,checkDocumentStyles:function(t){},compute:function(){},data:de,log:function(){},observe:function(){},reset:function(){},sheetAdoptionState:[],sheetUpdateState:[],start:function(){},state:le,stop:function(){}}),pe=[],he=null,ve=null,ge=null;function me(){pe=[],he=null,ve=null}function we(t,e){return void 0===e&&(e=0),at(this,void 0,void 0,(function(){var n,r,a;return ot(this,(function(o){for(n=0,r=pe;n<r.length;n++)if(r[n].task===t)return[2];return a=new Promise((function(n){pe[1===e?"unshift":"push"]({task:t,resolve:n,id:la()})})),null===he&&null===ve&&ye(),[2,a]}))}))}function ye(){var t=pe.shift();t&&(he=t,t.task().then((function(){t.id===la()&&(t.resolve(),he=null,ye())})).catch((function(e){t.id===la()&&(e&&xt(0,1,e.name,e.message,e.stack),he=null,ye())})))}var be=["input","textarea","radio","button","canvas","select"],_e=/VM\d/,ke=[],Te=null;function xe(t,e,n){var r,a=document.documentElement,o="pageX"in n?Math.round(n.pageX):"clientX"in n?Math.round(n.clientX+a.scrollLeft):null,i="pageY"in n?Math.round(n.pageY):"clientY"in n?Math.round(n.clientY+a.scrollTop):null,c=mr(n),s=function(t){for(;t&&t!==document;){if(t.nodeType===Node.ELEMENT_NODE){var e=t;if("A"===e.tagName)return e}t=t.parentNode}return null}(c),l=Ne(c);0===n.detail&&l&&(o=Math.round(l.x+l.w/2),i=Math.round(l.y+l.h/2));var f=function(t,e,n,r){if(!r)return{eX:0,eY:0};var a=r,o=t,i=Math.max(Math.floor((e-a.x)/a.w*32767),0),u=Math.max(Math.floor((n-a.y)/a.h*32767),0),c=0;for(;(i>32767||u>32767)&&o.parentElement&&c<10;)c++,(a=Ne(o=o.parentElement))&&(i=Math.max(Math.floor((e-a.x)/a.w*32767),0),u=Math.max(Math.floor((n-a.y)/a.h*32767),0));return{eX:i,eY:u}}(c,o,i,l),p=f.eX,h=f.eY;if(null!==o&&null!==i){var v=function(t){var e=null,n=!1;if(t){var r=Se(t)||String(t.value||"")||t.alt;if(r){var a=r.replace(/\s+/g," ").trim();n=(e=a.substring(0,25)).length===a.length}}return{text:e,isFullText:n?1:0}}(c);if(u.diagnostics){var g=c;console.log("[clarity:click] text debug",{tag:null==g?void 0:g.tagName,id:(null==g?void 0:g.id)||null,class:(null==g?void 0:g.className)||null,rawTextContent:(null===(r=null==g?void 0:g.textContent)||void 0===r?void 0:r.replace(/\s+/g," ").trim().substring(0,100))||null,inputValue:(null==g?void 0:g.value)||null,altText:(null==g?void 0:g.alt)||null,resolvedText:v.text,isFullText:v.isFullText,x:o,y:i})}ke.push({time:d(n),event:t,data:{target:c,x:o,y:i,eX:p,eY:h,button:n.button,reaction:Oe(c),context:Ie(s),text:v.text,link:s?s.href:null,hash:null,trust:n.isTrusted?1:0,isFullText:v.isFullText,w:l?l.w:0,h:l?l.h:0,tag:Ee(c,"tagName").substring(0,10),class:Ee(c,"className").substring(0,50),id:Ee(c,"id").substring(0,25),source:u.diagnostics&&!n.isTrusted?Me():0}}),n.isTrusted&&Te&&Te(),we(mn.bind(this,t))}}function Se(t){if(t.nodeType!==Node.ELEMENT_NODE)return t.textContent||"";var e=t,n=e.tagName;if("SCRIPT"===n||"STYLE"===n||"NOSCRIPT"===n)return"";for(var r="",a=0;a<e.childNodes.length;a++)r+=Se(e.childNodes[a]);return r}function Oe(t){var e=Ee(t,"tagName");return be.indexOf(e)>=0?0:1}function Ee(t,e){if(t.nodeType===Node.ELEMENT_NODE){var n=null==t?void 0:t[e];return"string"==typeof n?null==n?void 0:n.toLowerCase():""}return""}function Ne(t){var e=null,n=t.ownerDocument||document,r=n.documentElement,a=n.defaultView||window;if("function"==typeof t.getBoundingClientRect){var o=t.getBoundingClientRect();if(o&&o.width>0&&o.height>0){var i="pageXOffset"in a?a.pageXOffset:r.scrollLeft,u="pageYOffset"in a?a.pageYOffset:r.scrollTop;e={x:Math.floor(o.left+i),y:Math.floor(o.top+u),w:Math.floor(o.width),h:Math.floor(o.height)}}}return e}function Ie(t){if(t&&t.hasAttribute("target"))switch(t.getAttribute("target")){case"_blank":return 1;case"_parent":return 2;case"_top":return 3}return 0}function Me(){Me.dn=1;try{for(var t=(new Error).stack||"",e=location.origin,n=4,r=0,a=t.split("\n");r<a.length;r++){var o=a[r];o.indexOf("://")>=0?n=o.indexOf("extension")<0&&o.indexOf(e)>=0?1:2:(o.indexOf("eval")>=0||o.indexOf("Function")>=0||o.indexOf("<a")>=0||_e.test(o))&&(n=3)}return n}catch(t){return 4}}function Xe(){ke=[]}var je,Pe=Object.freeze({__proto__:null,observe:function(t){Xa(t,"click",xe.bind(this,9,t),!0),Xa(t,"contextmenu",xe.bind(this,48,t),!0)},onTrustedClick:function(t){Te=t},reset:Xe,start:function(){Xe()},get state(){return ke},stop:function(){Xe()}});function Ye(t,e){var n=0,r=null,a=null;function o(){for(var o=this,i=[],u=0;u<arguments.length;u++)i[u]=arguments[u];var c=performance.now(),s=c-n;if(0!==n&&s<e){if(a=i,r)return;r=setTimeout((function(){n=performance.now(),t.apply(o,a),a=null,r=null}),e-s)}else n=c,t.apply(this,i)}return o.cleanup=function(){r&&(clearTimeout(r),r=null,a=null)},o}var Ce=null,ze=!1,He=Ye(De,500);function De(){var t=document.documentElement;je={width:t&&"clientWidth"in t?Math.min(t.clientWidth,window.innerWidth):window.innerWidth,height:t&&"clientHeight"in t?Math.min(t.clientHeight,window.innerHeight):window.innerHeight},ze?(G(Ce),Ce=F(Ae,500,11)):(mn(11),ze=!0)}function Ae(t){we(mn.bind(this,t))}function We(){je=null,G(Ce),He.cleanup()}var Re=Object.freeze({__proto__:null,get data(){return je},reset:We,start:function(){ze=!1,Xa(window,"resize",He),De()},stop:function(){We()}}),Le=[],qe=null;var Ue=null,Fe=null,Ge=null;function Ve(t){void 0===t&&(t=null);var e=window,n=document.documentElement,r=t?mr(t):n;if(r){if(r&&r.nodeType===Node.DOCUMENT_NODE){r=n=r.documentElement}var a=r===n&&"pageXOffset"in e?Math.round(e.pageXOffset):Math.round(r.scrollLeft),o=r===n&&"pageYOffset"in e?Math.round(e.pageYOffset):Math.round(r.scrollTop),i=window.innerWidth,u=window.innerHeight,c=i/3,s=i>u?.15*u:.2*u,l=u-s,f=Be(c,s),p=Be(c,l),h=t&&t.isTrusted?1:0;t&&t.isTrusted&&qe&&qe();var v={time:d(t),event:10,data:{target:r,x:a,y:o,top:f,bottom:p,trust:h}};if(null===t&&0===a&&0===o||null===a||null===o)return Ue=f,void(Fe=p);var g=Le.length,m=g>1?Le[g-2]:null;m&&function(t,e){var n=t.data.x-e.data.x,r=t.data.y-e.data.y;return n*n+r*r<400&&e.time-t.time<50}(m,v)&&Le.pop(),Le.push(v),G(Ge),Ge=F(Ke,500,10)}}var Je=Ye(Ve,25);function Be(t,e){var n,r,a;return"caretPositionFromPoint"in document?a=null===(n=document.caretPositionFromPoint(t,e))||void 0===n?void 0:n.offsetNode:"caretRangeFromPoint"in document&&(a=null===(r=document.caretRangeFromPoint(t,e))||void 0===r?void 0:r.startContainer),a||(a=document.elementFromPoint(t,e)),a&&a.nodeType===Node.TEXT_NODE&&(a=a.parentNode),a}function Ze(){Le=[],Ue=null,Fe=null}function Ke(t){we(mn.bind(this,t))}var Qe=Object.freeze({__proto__:null,compute:function(){var t,e;if(Ue){var n=wr(Ue);Rr(31,null===(t=null==n?void 0:n.hash)||void 0===t?void 0:t.join("."))}if(Fe){var r=wr(Fe);Rr(32,null===(e=null==r?void 0:r.hash)||void 0===e?void 0:e.join("."))}},observe:function(t){Xa(t===document?window:t,"scroll",Je,!0)},onTrustedScroll:function(t){qe=t},reset:Ze,start:function(){Le=[],Ve()},get state(){return Le},stop:function(){G(Ge),Je.cleanup(),Le=[],Ue=null,Fe=null}}),$e=[];function tn(t){$e.push({time:d(t),event:39,data:{target:mr(t)}}),we(mn.bind(this,39))}function en(){$e=[]}var nn,rn=Object.freeze({__proto__:null,observe:function(t){Xa(t,"submit",tn,!0)},reset:en,start:function(){en()},get state(){return $e},stop:function(){en()}});function an(){qn("gemx-unload")}function on(t){nn={name:t.type,persisted:t.persisted?1:0},mn(26,d(t)),Ka()}function un(){nn=null}var cn,sn=Object.freeze({__proto__:null,get data(){return nn},reset:un,start:function(){Xa(window,"pagehide",on),Xa(window,"beforeunload",an)},stop:function(){un()}});function ln(t){if(void 0===t&&(t=null),"visibilityState"in document){var e="visible"===document.visibilityState?1:0;cn={visible:e},mn(28,d(t))}}function dn(){cn=null}var fn,pn=Object.freeze({__proto__:null,get data(){return cn},reset:dn,start:function(){Xa(document,"visibilitychange",ln),ln()},stop:function(){dn()}});function hn(){fn=null}function vn(t){fn={focused:t},mn(50)}var gn=Object.freeze({__proto__:null,get data(){return fn},reset:hn,start:function(){Xa(window,"focus",(function(){return vn(1)})),Xa(window,"blur",(function(){return vn(0)}))},stop:function(){hn()}});function mn(t,e){return void 0===e&&(e=null),at(this,void 0,void 0,(function(){var n,r,a,o,i,u,c,s,l,f,p,h,v,g,m,w,y,k,T,x,S,O,E,N,I,M,j,Y,C,z,H,D,A,W,R,L;return ot(this,(function(q){switch(n=e||d(),r=[n,t],t){case 13:case 14:case 12:case 15:case 16:case 17:case 18:case 19:case 20:for(a=0,o=le;a<o.length;a++)W=o[a],(i=wr(W.data.target,W.event)).id>0&&((r=[W.time,W.event]).push(i.id),r.push(W.data.x),r.push(W.data.y),void 0!==W.data.id&&(r.push(W.data.id),void 0!==W.data.isPrimary&&r.push(W.data.isPrimary.toString())),Ln(r),(void 0===W.data.isPrimary||W.data.isPrimary)&&X(W.event,W.data.x,W.data.y,W.time));break;case 9:case 48:for(u=0,c=ke;u<c.length;u++)W=c[u],s=wr(W.data.target,W.event,W.data.text),r=[W.time,W.event],l=s.hash?s.hash.join("."):"",console.log("[GemX - Interaction - Encode]",{cHash:l,cTarget:s}),r.push(s.id),r.push(W.data.x),r.push(W.data.y),r.push(W.data.eX),r.push(W.data.eY),r.push(W.data.button),r.push(W.data.reaction),r.push(W.data.context),r.push(b(W.data.text,"click",s.privacy)),r.push(_(W.data.link)),r.push(l),r.push(W.data.trust),r.push(W.data.isFullText),r.push(W.data.w),r.push(W.data.h),r.push(W.data.tag),r.push(W.data.class),r.push(W.data.id),r.push(W.data.source),Ln(r),_n(W.time,W.event,l,W.data.x,W.data.y,W.data.reaction,W.data.context);Xe();break;case 38:for(f=0,p=le;f<p.length;f++)W=p[f],r=[W.time,W.event],(H=wr(W.data.target,W.event)).id>0&&(r.push(H.id),r.push(W.data.action),Ln(r));break;case 11:h=je,r.push(h.width),r.push(h.height),X(t,h.width,h.height),We(),Ln(r);break;case 26:v=nn,r.push(v.name),r.push(v.persisted),un(),Ln(r);break;case 27:for(g=0,m=le;g<m.length;g++)W=m[g],w=wr(W.data.target,W.event,W.data.value),(r=[W.time,W.event]).push(w.id),r.push(b(W.data.value,"input",w.privacy,!1,W.data.type)),r.push(W.data.trust),Ln(r);break;case 21:(y=de)&&(k=wr(y.start),T=wr(y.end),r.push(k.id),r.push(y.startOffset),r.push(T.id),r.push(y.endOffset),Ln(r));break;case 10:for(x=0,S=Le;x<S.length;x++)W=S[x],O=wr(W.data.target,W.event),E=wr(W.data.top,W.event),N=wr(W.data.bottom,W.event),I=(null==E?void 0:E.hash)?E.hash.join("."):"",M=(null==N?void 0:N.hash)?N.hash.join("."):"",O.id>0&&((r=[W.time,W.event]).push(O.id),r.push(W.data.x),r.push(W.data.y),r.push(I),r.push(M),r.push(W.data.trust),Ln(r),X(W.event,W.data.x,W.data.y,W.time));Ze();break;case 42:for(j=0,Y=le;j<Y.length;j++)W=Y[j],r=[W.time,W.event],(H=wr(W.data.target,W.event)).id>0&&((r=[W.time,W.event]).push(H.id),r.push(W.data.type),r.push(b(W.data.value,"change",H.privacy)),r.push(b(W.data.checksum,"checksum",H.privacy)),Ln(r));break;case 39:for(C=0,z=$e;C<z.length;C++)W=z[C],r=[W.time,W.event],(H=wr(W.data.target,W.event)).id>0&&(r.push(H.id),Ln(r));en();break;case 22:for(D=0,A=yn;D<A.length;D++)W=A[D],(r=[W.time,W.event]).push(W.data.type),r.push(W.data.hash),r.push(W.data.x),r.push(W.data.y),r.push(W.data.reaction),r.push(W.data.context),Ln(r,!1);bn();break;case 28:R=cn,r.push(R.visible),Ln(r),P(n,R.visible),dn();break;case 50:L=fn,r.push(L.focused),Ln(r,!1),hn()}return[2]}))}))}var wn=[],yn=[];function bn(){yn=[]}function _n(t,e,n,r,a,o,i){void 0===o&&(o=1),void 0===i&&(i=0),wn.push({time:t,event:22,data:{type:e,hash:n,x:r,y:a,reaction:o,context:i}}),X(e,r,a,t)}function kn(){if(Ta){var t=[];yn=[];for(var e=(Ta.start||0)+(Ta.duration||0),n=Math.max(e-2e3,0),r=0,a=wn;r<a.length;r++){var o=a[r];o.time>=n&&(o.time<=e&&yn.push(o),t.push(o))}wn=t,mn(22)}}var Tn=Object.freeze({__proto__:null,compute:kn,reset:bn,start:function(){wn=[],bn()},stop:function(){wn=[],bn()},track:_n,get updates(){return yn}}),xn=[],Sn=!1,On=null;function En(t){Sn&&"function"==typeof t&&xn.push(t)}function Nn(t){if(Sn){var e=t?t.split(" "):[""],n=e.length>1?parseInt(e[1],10):null;n&&On.has(n)||function(t,e){try{var n=document.createElement("script");n.src=t,n.async=!0,n.onload=function(){e&&(On.add(e),Y(On))},n.onerror=function(){Na(new Error("".concat("MODULE",": ").concat(t)))},document.head.appendChild(n)}catch(t){}}(e[0],n)}}var In,Mn,Xn,jn,Pn,Yn,Cn=Object.freeze({__proto__:null,event:Nn,register:En,start:function(){Sn=!0,On=new Set,u.modules&&u.modules.length>0&&u.modules.forEach((function(t){Nn(t)}))},stop:function(){xn.reverse().forEach((function(t){try{t()}catch(t){}})),xn=[],Sn=!1}}),zn=0,Hn=0,Dn=null,An=0,Wn=!1;function Rn(){jn=!0,zn=0,Hn=0,Wn=!1,An=0,In=[],Mn=[],Xn={},Pn=null}function Ln(t,e){if(void 0===e&&(e=!0),jn){var n=d(),r=t.length>1?t[1]:null,a=JSON.stringify(t);switch(u.lean?!Wn&&Hn+a.length>10485760&&(xt(10,0),Wn=!0):Wn=!1,r){case 5:if(Wn)break;if(ne()){re(t,a.length);break}zn+=a.length;case 37:case 6:case 43:case 45:case 46:case 44:case 51:if(Wn)break;ne()&&re(t,a.length),Hn+=a.length,In.push(a);break;default:Mn.push(a)}L(25);var o=function(){var t=!1===u.lean&&zn>0?100:Ta.sequence*u.delay;return"string"==typeof u.upload?Math.max(Math.min(t,3e4),100):u.delay}();n-An>2*o&&(G(Dn),Dn=null),e&&null===Dn&&(25!==r&&Z(),Dn=F(Gn,o),An=n,jr(Hn))}}function qn(t){jn&&(G(Dn),Dn=null,Gn(!1,t))}function Un(t){for(var e=0,n=t;e<n.length;e++){var r=n[e],a=JSON.stringify(r);zn+=a.length,Hn+=a.length,In.push(a)}}function Fn(){G(Dn),Gn(!0),zn=0,Hn=0,Wn=!1,An=0,In=[],Mn=[],Xn={},Pn=null,jn=!1}function Gn(t,e){return void 0===t&&(t=!1),at(this,void 0,void 0,(function(){var n,r,a,o,i,c,s,l,d,f,p,h,v,g,m,w,y;return ot(this,(function(b){switch(b.label){case 0:if(!jn)return[2];if(Dn=null,(n=("gemx-snapshot"===e||!1===u.lean)&&Hn>0&&(Hn<1048576||Ta.sequence>0))&&U(1,1),kn(),se(),r=!0===t,!Ta)return[2];if(a=Bt(),!e&&a){for(o=[[9,"click"],[10,"scroll"]],i=new Set(Mn.map((function(t){return JSON.parse(t)[1]}))),c=[],s=0,l=o;s<l.length;s++)f=(d=l[s])[0],p=d[1],i.has(f)&&c.push(p);e=c.length>0?c.join("-"):void 0}return h=JSON.stringify(Oa(r)),v="[".concat(Mn.join(),"]"),g=n?"[".concat(In.join(),"]"):"",r&&g.length>0&&h.length+v.length+g.length>65536&&(g=""),m=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:h,a:v,p:g}),r?(y=null,[3,3]):[3,1];case 1:return[4,ut(m)];case 2:y=b.sent(),b.label=3;case 3:return q(2,(w=y)?w.length:m.length),Vn(m,w,Ta.sequence,r,e),Mn=[],n&&(In=[],Hn=0,zn=0,Wn=!1),[2]}}))}))}function Vn(t,e,n,r,a){if(void 0===r&&(r=!1),"string"==typeof u.upload){var o=u.upload,i=!1;if(r&&navigator&&navigator.sendBeacon)try{(i=navigator.sendBeacon.bind(navigator)(o,t))&&Bn(n)}catch(t){}if(!1===i){n in Xn?Xn[n].attempts++:Xn[n]={data:t,attempts:1};var c=new XMLHttpRequest;c.open("POST",o,!0),c.timeout=15e3,c.ontimeout=function(){Na(new Error("".concat("Timeout"," : ").concat(o)))},null!==n&&(c.onreadystatechange=function(){Ia(Jn)(c,n)}),c.withCredentials=!0,e?(c.setRequestHeader("Accept","application/x-clarity-gzip"),c.send(e)):c.send(t)}}else if(u.upload){(0,u.upload)(t,a),Bn(n)}}function Jn(t,e){var n=Xn[e];t&&4===t.readyState&&n&&((t.status<200||t.status>208)&&n.attempts<=1?t.status>=400&&t.status<500?Pr(6):(0===t.status&&(u.upload=u.fallback?u.fallback:u.upload),Pn={sequence:e,attempts:n.attempts,status:t.status},Mr(2),Vn(n.data,null,e)):(Pn={sequence:e,attempts:n.attempts,status:t.status},n.attempts>1&&Mr(2),200===t.status&&t.responseText&&function(t){for(var e=t&&t.length>0?t.split("\n"):[],n=0,r=e;n<r.length;n++){var a=r[n],o=a&&a.length>0?a.split(/ (.*)/):[""];switch(o[0]){case"END":Pr(6);break;case"UPGRADE":Nr("Auto");break;case"ACTION":u.action&&o.length>1&&u.action(o[1]);break;case"EXTRACT":o.length>1&&Xt(o[1]);break;case"SIGNAL":o.length>1&&oe(o[1]);break;case"MODULE":o.length>1&&Nn(o[1]);break;case"SNAPSHOT":u.lean=!1,yr()}}}(t.responseText),0===t.status&&(Vn(n.data,null,e,!0),Pr(3)),t.status>=200&&t.status<=208&&Bn(e),delete Xn[e]))}function Bn(t){1===t&&(ma(),ga())}function Zn(t){return at(this,void 0,void 0,(function(){var e,n,r,a,o,i,u,c,s,l,f,p,h;return ot(this,(function(v){switch(e=d(),n=[e,t],t){case 8:r=Yn,n.push(r.width),n.push(r.height),X(t,r.width,r.height),Ln(n);break;case 43:if((a=lr).length>0){for(o=0,i=a;o<i.length;o++)for(u=i[o],c=u.metadata.privacy,s=u.data,l=0,f=["tag","attributes","value"];l<f.length;l++)if(s[p=f[l]])switch(p){case"tag":n.push(u.id),u.parent&&n.push(u.parent),u.previous&&n.push(u.previous),n.push(s[p]);break;case"attributes":for(h in s[p])void 0!==s[p][h]&&n.push(Kn(h,s[p][h],c,s.tag));break;case"value":n.push(b(s[p],s.tag,c))}Ln(function(t){for(var e=[],n={},r=0,a=null,o=0;o<t.length;o++)if("string"==typeof t[o]){var i=t[o],u=n[i]||-1;u>=0?a?a.push(u):(a=[u],e.push(a),r++):(a=null,e.push(i),n[i]=r++)}else a=null,e.push(t[o]),r++;return e}(n),!0)}}return[2]}))}))}function Kn(t,e,n,r){return"href"===t&&"LINK"===r?"".concat(t,"=").concat(e):"".concat(t,"=").concat(b(e,0===t.indexOf("data-")?"data-":t,n))}function Qn(){Yn=null}function $n(){var t,e,n,r,a,o,i,u,c,s,l,d,f,p,h,v;Qn(),t=document.body,e=document.documentElement,n=t?t.clientWidth:null,r=t?t.scrollWidth:null,a=t?t.offsetWidth:null,o=e?e.clientWidth:null,i=e?e.scrollWidth:null,u=e?e.offsetWidth:null,c=Math.max(n,r,a,o,i,u),s=t?t.clientHeight:null,l=t?t.scrollHeight:null,d=t?t.offsetHeight:null,f=e?e.clientHeight:null,p=e?e.scrollHeight:null,h=e?e.offsetHeight:null,v=Math.max(s,l,d,f,p,h),null!==Yn&&c===Yn.width&&v===Yn.height||null===c||null===v||(Yn={width:c,height:v},Zn(8))}var tr=!1;function er(t){t&&t.persisted&&(Za(),xt(11,0))}var nr=Object.freeze({__proto__:null,start:function(){if(!tr)try{window[c("addEventListener")]("pageshow",Ia(er),{capture:!1,passive:!0}),tr=!0}catch(t){}},stop:function(){}}),rr=[Tn,Pe,Re,pn,Qe,nr,sn],ar=[Tn,Pe,fe,fe,fe,Re,pn,gn,nr,Qe,fe,fe,rn,sn],or={allRoots:[Qe],documentOnly:[Pe]},ir={allRoots:[Qe],documentOnly:[Pe,fe,fe,fe,fe,fe,rn]},ur=ar;function cr(t){var e="gemx"===(null==u?void 0:u.mode)?or:ir;e.allRoots.forEach((function(e){return e.observe(t)})),t.nodeType===Node.DOCUMENT_NODE&&e.documentOnly.forEach((function(e){return e.observe(t)}))}var sr=Object.freeze({__proto__:null,observe:cr,start:function(){(ur="gemx"===(null==u?void 0:u.mode)?rr:ar).forEach((function(t){return t.start()}))},stop:function(){ur.forEach((function(t){return t.stop()}))}}),lr=[],dr=1,fr=null;function pr(){br(),$n(),kr(document.documentElement),cr(document)}function hr(){return!1}function vr(){return{x:0,y:0}}function gr(){}function mr(t){var e=t.composed&&t.composedPath?t.composedPath():null,n=e&&e.length>0?e[0]:t.target;return n.nodeType===Node.DOCUMENT_NODE?n.documentElement:n}function wr(t){var e={id:0,hash:null,privacy:u.conversions?1:5};return t&&(e.id=fr.has(t)?fr.get(t):kr(t)),e}function yr(){lr=[],function(t){var e=[t];for(;e.length>0;){for(var n=null,r=null,a=null,o=e.shift(),i=o.firstChild,u=o.parentElement?o.parentElement:o.parentNode?o.parentNode:null;i;)e.push(i),i=i.nextSibling;switch(o.nodeType){case Node.DOCUMENT_TYPE_NODE:var c=o;r="*D",n={name:c.name,publicId:c.publicId,systemId:c.systemId};break;case Node.TEXT_NODE:a=o.nodeValue,r=fr.get(u)?"*T":r;break;case Node.ELEMENT_NODE:var s=o;n=_r(s),r=["NOSCRIPT","SCRIPT","STYLE"].indexOf(s.tagName)<0?s.tagName:r}Tr(o,u,{tag:r,attributes:n,value:a})}}(document),Zn(43)}function br(){fr=new WeakMap}function _r(t){var e={},n=t.attributes;if(n&&n.length>0)for(var r=0;r<n.length;r++)e[n[r].name]=n[r].value;return e}function kr(t){return null===t?null:fr.has(t)?fr.get(t):(fr.set(t,dr),dr++)}function Tr(t,e,n){if(t&&n&&n.tag){var r=kr(t),a=e?fr.get(e):null,o=t.previousSibling?fr.get(t.previousSibling):null;lr.push({id:r,parent:a,previous:o,children:[],data:n,selector:null,hash:null,region:null,metadata:{active:!0,suspend:!1,privacy:5,position:null,fraud:null,size:null}})}}var xr,Sr=Object.freeze({__proto__:null,compute:function(){},get:function(t){return null},hashText:gr,iframe:hr,metadata:wr,offset:vr,snapshot:yr,start:pr,stop:function(){br(),Qn()},target:mr,get values(){return lr}}),Or=null;function Er(){!u.lean&&u.upgrade&&u.upgrade("Config"),Or=null}function Nr(t){Ua()&&u.lean&&(u.lean=!1,Or={key:t},ga(),ma(),u.upgrade&&u.upgrade(t),Mr(3),u.lite&&pr())}function Ir(){Or=null}function Mr(t){var e=[d(),t];switch(t){case 4:var n=E;n&&n.data&&((e=[n.time,n.event]).push(n.data.visible),e.push(n.data.docWidth),e.push(n.data.docHeight),e.push(n.data.screenWidth),e.push(n.data.screenHeight),e.push(n.data.scrollX),e.push(n.data.scrollY),e.push(n.data.pointerX),e.push(n.data.pointerY),e.push(n.data.activityTime),e.push(n.data.scrollTime),e.push(n.data.pointerTime),e.push(n.data.moveX),e.push(n.data.moveY),e.push(n.data.moveTime),e.push(n.data.downX),e.push(n.data.downY),e.push(n.data.downTime),e.push(n.data.upX),e.push(n.data.upY),e.push(n.data.upTime),e.push(n.data.pointerPrevX),e.push(n.data.pointerPrevY),e.push(n.data.pointerPrevTime),e.push(n.data.modules),Ln(e,!1)),M();break;case 25:e.push(A.gap),Ln(e);break;case 35:e.push(xr.check),Ln(e,!1);break;case 3:e.push(Or.key),Ln(e);break;case 2:e.push(Pn.sequence),e.push(Pn.attempts),e.push(Pn.status),Ln(e,!1);break;case 24:H.key&&e.push(H.key),e.push(H.value),Ln(e);break;case 34:var r=Object.keys(st);if(r.length>0){for(var a=0,o=r;a<o.length;a++){var i=o[a];e.push(i),e.push(st[i])}ht(),Ln(e,!1)}break;case 0:var u=Object.keys(R);if(u.length>0){for(var c=0,s=u;c<s.length;c++){var l=s[c],f=parseInt(l,10);e.push(f),e.push(Math.round(R[l]))}R={},Ln(e,!1)}break;case 1:var p=Object.keys(Hr);if(p.length>0){for(var h=0,v=p;h<v.length;h++){var g=v[h];f=parseInt(g,10);e.push(f),e.push(Hr[g])}qr(),Ln(e,!1)}break;case 36:var m=Object.keys($);if(m.length>0){for(var w=0,y=m;w<y.length;w++){var b=y[w];f=parseInt(b,10);e.push(f),e.push([].concat.apply([],$[b]))}et(),Ln(e,!1)}break;case 40:Ot.forEach((function(t){e.push(t);var n=[];for(var r in St[t]){var a=parseInt(r,10);n.push(a),n.push(St[t][r])}e.push(n)})),Yt(),Ln(e,!1);break;case 47:e.push(Ur.source),e.push(Ur.ad_Storage),e.push(Ur.analytics_Storage),Ln(e,!1)}}function Xr(){xr={check:0}}function jr(t){if(0===xr.check){var e=xr.check;e=Ta.sequence>=128?1:e,e=Ta.pageNum>=128?7:e,e=d()>72e5?2:e,(e=t>10485760?2:e)!==xr.check&&Pr(e)}}function Pr(t){xr.check=t,5!==t&&(va(),Ka())}function Yr(){0!==xr.check&&Mr(35)}function Cr(){xr=null}var zr=null,Hr=null,Dr=!1;function Ar(){zr={},Hr={},Dr=!1}function Wr(){zr={},Hr={},Dr=!1}function Rr(t,e){if(e&&(e="".concat(e),t in zr||(zr[t]=[]),zr[t].indexOf(e)<0)){if(zr[t].length>128)return void(Dr||(Dr=!0,Pr(5)));zr[t].push(e),t in Hr||(Hr[t]=[]),Hr[t].push(e)}}function Lr(){Mr(1)}function qr(){Hr={},Dr=!1}var Ur=null,Fr=!0;function Gr(){var t,e=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics;Fr=!0,(null==e?void 0:e.addListener)&&e.addListener(["ad_storage","analytics_storage"],Jr)}function Vr(){Fr=!0}function Jr(){var t,e=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics;if(null==e?void 0:e.getConsentState)try{var n=e.getConsentState("analytics_storage");fa(function(t){var e={source:2,ad_Storage:1===t.ad_Storage?"granted":"denied",analytics_Storage:1===t.analytics_Storage?"granted":"denied"};return e}({ad_Storage:e.getConsentState("ad_storage"),analytics_Storage:n}))}catch(t){return}}function Br(t){Kr(t.analytics_Storage?1:0),Ur=t}function Zr(){Kr(2)}function Kr(t){Rr(36,t.toString())}function Qr(t){Ur=t,Mr(47)}function $r(){var t;if(Fr&&(Mr(47),Fr=!1,!u.track)){var e=null===(t=window.google_tag_data)||void 0===t?void 0:t.ics;(null==e?void 0:e.usedUpdate)&&Jr()}}var ta=null,ea=[],na=0,ra=null,aa=!1,oa={source:7,ad_Storage:"denied",analytics_Storage:"denied"};function ia(){var t,e,n,r=navigator&&"userAgent"in navigator?navigator.userAgent:"",a=null!==(n="undefined"!=typeof Intl&&(null===(e=null===(t=null===Intl||void 0===Intl?void 0:Intl.DateTimeFormat())||void 0===t?void 0:t.resolvedOptions())||void 0===e?void 0:e.timeZone))&&void 0!==n?n:"",o=(new Date).getTimezoneOffset().toString(),i=window.location.ancestorOrigins?Array.from(window.location.ancestorOrigins).toString():"",c=document&&document.title?document.title:"";na=r.indexOf("Electron")>0?1:0;var s=function(){var t={session:ya(),ts:Math.round(Date.now()),count:1,upgrade:null,upload:""},e=Ut("_clsk",!u.includeSubdomains);if(e){var n=e.includes("^")?e.split("^"):e.split("|");n.length>=5&&t.ts-ba(n[1])<18e5&&(t.session=n[0],t.count=ba(n[2])+1,t.upgrade=ba(n[3]),t.upload=n.length>=6?"".concat("https://").concat(n[5],"/").concat(n[4]):"".concat("https://").concat(n[4]))}return t}(),l=_a(),d=u.projectId||p(location.host),f=u.externalSession&&u.userId?u.userId:l.id,h=u.externalSession&&u.sessionId?u.sessionId:s.session;ta={projectId:d,userId:f,sessionId:h,pageNum:s.count},u.lean=u.track&&null!==s.upgrade?0===s.upgrade:u.lean,u.upload=u.track&&"string"==typeof u.upload&&s.upload&&s.upload.length>"https://".length?s.upload:u.upload,Rr(0,r),Rr(3,c),Rr(1,_(location.href,!!na)),Rr(2,document.referrer),Rr(15,function(){var t=ya();if(u.track&&Wt(window,"sessionStorage")){var e=sessionStorage.getItem("_cltk");t=e||t,sessionStorage.setItem("_cltk",t)}return t}()),Rr(16,document.documentElement.lang),Rr(17,document.dir),Rr(26,"".concat(window.devicePixelRatio)),Rr(28,l.dob.toString()),Rr(29,l.version.toString()),Rr(33,i),Rr(34,a),Rr(35,o),U(0,s.ts),U(1,0),U(35,na);var v,g=null===window||void 0===window?void 0:window.Zone;g&&"__symbol__"in g&&U(39,1),navigator&&(Rr(9,navigator.language),U(33,navigator.hardwareConcurrency),U(32,navigator.maxTouchPoints),U(34,Math.round(navigator.deviceMemory)),(v=navigator.userAgentData)&&v.getHighEntropyValues?v.getHighEntropyValues(["model","platform","platformVersion","uaFullVersion"]).then((function(t){var e;Rr(22,t.platform),Rr(23,t.platformVersion),null===(e=t.brands)||void 0===e||e.forEach((function(t){Rr(24,t.name+"~"+t.version)})),Rr(25,t.model),U(27,t.mobile?1:0)})):Rr(22,navigator.platform)),screen&&(U(14,Math.round(screen.width)),U(15,Math.round(screen.height)),U(16,Math.round(screen.colorDepth))),null===ra&&(ra={source:l.consent?6:0,ad_Storage:u.track?"granted":"denied",analytics_Storage:u.track?"granted":"denied"}),ua(),Br(pa(ra)),u.externalSession||wa(l)}function ua(){if(!aa&&"granted"===(null==ra?void 0:ra.analytics_Storage)&&"granted"===(null==ra?void 0:ra.ad_Storage)){for(var t=0,e=u.cookies;t<e.length;t++){var n=e[t],r=Ut(n);r&&lt(n,r)}aa=!0}}function ca(){ta=null,aa=!1,ea.forEach((function(t){t.called=!1}))}function sa(t,e,n,r){void 0===e&&(e=!0),void 0===n&&(n=!1),void 0===r&&(r=!1);var a=u.lean?0:1,o=!1;ta&&(a||!1===e)&&(t(ta,!u.lean,r?ra:void 0),o=!0),!n&&o||ea.push({callback:t,wait:e,recall:n,called:o,consentInfo:r})}function la(){return ta?[ta.userId,ta.sessionId,ta.pageNum].join("."):""}function da(t){void 0===t&&(t=!0),fa(t?{source:4,ad_Storage:"granted",analytics_Storage:"granted"}:{source:4,ad_Storage:"denied",analytics_Storage:"denied"})}function fa(t,e){var n;if(void 0===t&&(t=oa),void 0===e&&(e=5),Ua()){var r={source:null!==(n=t.source)&&void 0!==n?n:e,ad_Storage:ha(t.ad_Storage,null==ra?void 0:ra.ad_Storage),analytics_Storage:ha(t.analytics_Storage,null==ra?void 0:ra.analytics_Storage)};if(ra&&r.ad_Storage===ra.ad_Storage&&r.analytics_Storage===ra.analytics_Storage)return ra.source=r.source,Qr(pa(ra)),void Zr();ra=r,ga(!0);var a=pa(ra);if(!a.analytics_Storage&&u.track)return u.track=!1,va(!0),Ka(),void window.setTimeout(Za,250);Ua()&&a.analytics_Storage&&(u.track=!0,wa(_a(),1),ma()),ua(),Qr(a),Zr()}}function pa(t){var e;return{source:null!==(e=t.source)&&void 0!==e?e:255,ad_Storage:"granted"===t.ad_Storage?1:0,analytics_Storage:"granted"===t.analytics_Storage?1:0}}function ha(t,e){return void 0===e&&(e="denied"),"string"==typeof t?t.toLowerCase():e}function va(t){void 0===t&&(t=!1),Ft("_clsk","",0),t&&Ft("_clck","",0)}function ga(t){void 0===t&&(t=!1),function(t,e){void 0===e&&(e=!1);if(ea.length>0)for(var n=0;n<ea.length;n++){var r=ea[n];r.callback&&(!r.called&&!e||r.consentInfo&&e)&&(!r.wait||t)&&(r.callback(ta,!u.lean,r.consentInfo?ra:void 0),r.called=!0,r.recall||(ea.splice(n,1),n--))}}(u.lean?0:1,t)}function ma(){if(ta&&u.track&&!u.externalSession){var t=Math.round(Date.now()),e=u.upload&&"string"==typeof u.upload?u.upload.replace("https://",""):"",n=u.lean?0:1;Ft("_clsk",[ta.sessionId,t,ta.pageNum,n,e].join(qt),1)}}function wa(t,e){void 0===e&&(e=null),e=null===e?t.consent:e;var n=Math.ceil((Date.now()+31536e6)/864e5),r=0===t.dob?null===u.dob?0:u.dob:t.dob;(null===t.expiry||Math.abs(n-t.expiry)>=1||t.consent!==e||t.dob!==r)&&Ft("_clck",[ta.userId,2,n.toString(36),e,r].join(qt),365)}function ya(){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 ba(t,e){return void 0===e&&(e=10),parseInt(t,e)}function _a(){var t={id:ya(),version:0,expiry:null,consent:0,dob:0},e=Ut("_clck",!u.includeSubdomains);if(e&&e.length>0){var n=e.includes("^")?e.split("^"):e.split("|");n.length>1&&(t.version=ba(n[1])),n.length>2&&(t.expiry=ba(n[2],36)),n.length>3&&1===ba(n[3])&&(t.consent=1),n.length>4&&ba(n[1])>1&&(t.dob=ba(n[4])),u.track=u.track||1===t.consent,t.id=u.track?n[0]:t.id}return t}var ka,Ta=null;function xa(){var t=ta;Ta={version:f,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 Sa(){Ta=null}function Oa(t){return Ta.start=Ta.start+Ta.duration,Ta.duration=d()-Ta.start,Ta.sequence++,Ta.upload=t&&"sendBeacon"in navigator?1:0,Ta.end=t?1:0,Ta.applicationPlatform=0,Ta.url=_(location.href,!1,!0),[Ta.version,Ta.sequence,Ta.start,Ta.duration,Ta.projectId,Ta.userId,Ta.sessionId,Ta.pageNum,Ta.upload,Ta.end,Ta.applicationPlatform,Ta.url]}function Ea(){ka=[]}function Na(t){if(ka&&-1===ka.indexOf(t.message)){var e=u.report;if(e&&e.length>0&&Ta){var n={v:Ta.version,p:Ta.projectId,u:Ta.userId,s:Ta.sessionId,n:Ta.pageNum};t.message&&(n.m=t.message),t.stack&&(n.e=t.stack);var r=new XMLHttpRequest;r.open("POST",e,!0),r.send(JSON.stringify(n)),ka.push(t.message)}}return t}function Ia(t){return function(){var e=performance.now();try{t.apply(this,arguments)}catch(t){throw Na(t)}var n=performance.now()-e;q(4,n),n>30&&(L(7),U(6,n),t.dn&&xt(9,0,"".concat(t.dn,"-").concat(n)))}}var Ma=new Map;function Xa(t,e,n,r,a){void 0===r&&(r=!1),void 0===a&&(a=!0),n=Ia(n);try{t[c("addEventListener")](e,n,{capture:r,passive:a}),function(t){return Ma.has(t)}(t)||Ma.set(t,[]),Ma.get(t).push({event:e,listener:n,options:{capture:r,passive:a}})}catch(t){}}function ja(){Ma.forEach((function(t,e){!function(t,e){t.forEach((function(t){try{e[c("removeEventListener")](t.event,t.listener,{capture:t.options.capture,passive:t.options.passive})}catch(t){}})),Ma.delete(e)}(t,e)})),Ma=new Map}var Pa=null,Ya=null,Ca=null,za=0;function Ha(){return!(za++>20)||(xt(4,0),!1)}function Da(){za=0,Ca!==Wa()&&(Ka(),window.setTimeout(Aa,250))}function Aa(){Za(),U(29,1)}function Wa(){return location.href?location.href.replace(location.hash,""):location.href}var Ra=!1;function La(){Ra=!0,s=l(),me(),ja(),Ea(),function(){if(Ca=Wa(),za=0,Xa(window,"popstate",Da),null===Pa)try{Pa=history.pushState,history.pushState=function(){Pa.apply(this,arguments),Ua()&&Ha()&&Da()}}catch(t){Pa=null}if(null===Ya)try{Ya=history.replaceState,history.replaceState=function(){Ya.apply(this,arguments),Ua()&&Ha()&&Da()}}catch(t){Ya=null}}()}function qa(){Ca=null,za=0,Ea(),ja(),me(),s=0,Ra=!1}function Ua(){return Ra}function Fa(){Za(),D("clarityGemX","restart")}var Ga=Object.freeze({__proto__:null,start:function(){!function(){U(26,navigator.webdriver?1:0);try{U(31,window.top==window.self||window.top==window?1:2)}catch(t){U(31,0)}}(),Xa(window,"error",bt),yt={},Tt={}},stop:function(){Tt={}}}),Va=[Ga,Sr,sr],Ja=[Ga,Sr,sr,fe,Cn],Ba=Ja;function Za(t){void 0===t&&(t=null),Ba="gemx"===(null==t?void 0:t.mode)?Va:Ja,function(){try{var t=navigator&&"globalPrivacyControl"in navigator&&1==navigator.globalPrivacyControl;return!1===Ra&&"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||Ra)return!1;for(var e in t)e in u&&(u[e]=t[e])}(t),La(),ue(),Ba.forEach((function(t){return Ia(t.start)()})),null===t&&eo())}function Ka(){Ua()&&(Ba.slice().reverse().forEach((function(t){return Ia(t.stop)()})),ce(),qa(),void 0!==$a&&($a[to]=function(){($a[to].q=$a[to].q||[]).push(arguments),"start"===arguments[0]&&$a[to].q.unshift($a[to].q.pop())&&eo()}))}var Qa=Object.freeze({__proto__:null,consent:da,consentv2:fa,dlog:Rr,event:D,hashText:gr,identify:dt,maxMetric:U,measure:Ia,metadata:sa,pause:function(){Ua()&&(D("clarityGemX","pause"),null===ve&&(ve=new Promise((function(t){ge=t}))))},queue:Ln,register:En,resume:function(){Ua()&&(ve&&(ge(),ve=null,null===he&&ye()),D("clarityGemX","resume"))},schedule:we,set:lt,signal:function(t){ae=t},start:Za,stop:Ka,time:d,upgrade:Nr,version:f}),$a=window,to="clarityGemX";function eo(){if(void 0!==$a){if($a[to]&&$a[to].v)return console.warn("Error CL001: Multiple Clarity tags detected.");var t=$a[to]&&$a[to].q||[];for($a[to]=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];return Qa[t].apply(Qa,e)},$a[to].v=f;t.length>0;)$a[to].apply($a,t.shift())}}eo()}();
package/build/clarity.js CHANGED
@@ -224,7 +224,7 @@ function stop$O() {
224
224
  startTime = 0;
225
225
  }
226
226
 
227
- var version$1 = "0.8.89";
227
+ var version$1 = "0.8.90";
228
228
 
229
229
  // tslint:disable: no-bitwise
230
230
  function hash (input, precision) {
@@ -1317,17 +1317,19 @@ var cookie = /*#__PURE__*/Object.freeze({
1317
1317
  });
1318
1318
 
1319
1319
  var defaultConfig = {
1320
+ debug: false,
1320
1321
  excludeClassNames: [],
1321
1322
  ignoreMutationClassNames: [],
1322
1323
  discoverTrigger: null,
1323
1324
  };
1324
1325
  var _config = __assign({}, defaultConfig);
1325
1326
  function start$J() {
1326
- var _a, _b, _c, _d, _e, _f;
1327
+ var _a, _b, _c, _d, _e, _f, _g, _h;
1327
1328
  _config = {
1328
- excludeClassNames: ((_b = (_a = window === null || window === void 0 ? void 0 : window.GemXHeatmap) === null || _a === void 0 ? void 0 : _a.excludeClassNames) !== null && _b !== void 0 ? _b : []),
1329
- ignoreMutationClassNames: ((_d = (_c = window === null || window === void 0 ? void 0 : window.GemXHeatmap) === null || _c === void 0 ? void 0 : _c.ignoreMutationClassNames) !== null && _d !== void 0 ? _d : []),
1330
- discoverTrigger: ((_f = (_e = window === null || window === void 0 ? void 0 : window.GemXHeatmap) === null || _e === void 0 ? void 0 : _e.discoverTrigger) !== null && _f !== void 0 ? _f : null),
1329
+ debug: new URLSearchParams(window.location.search).has("gemx_debug") || ((_b = (_a = window === null || window === void 0 ? void 0 : window.GemXHeatmap) === null || _a === void 0 ? void 0 : _a.debug) !== null && _b !== void 0 ? _b : false),
1330
+ excludeClassNames: ((_d = (_c = window === null || window === void 0 ? void 0 : window.GemXHeatmap) === null || _c === void 0 ? void 0 : _c.excludeClassNames) !== null && _d !== void 0 ? _d : []),
1331
+ ignoreMutationClassNames: ((_f = (_e = window === null || window === void 0 ? void 0 : window.GemXHeatmap) === null || _e === void 0 ? void 0 : _e.ignoreMutationClassNames) !== null && _f !== void 0 ? _f : []),
1332
+ discoverTrigger: ((_h = (_g = window === null || window === void 0 ? void 0 : window.GemXHeatmap) === null || _g === void 0 ? void 0 : _g.discoverTrigger) !== null && _h !== void 0 ? _h : null),
1331
1333
  };
1332
1334
  }
1333
1335
  function stop$G() {
@@ -1339,10 +1341,14 @@ function set(config) {
1339
1341
  function get$2() {
1340
1342
  return _config;
1341
1343
  }
1344
+ function isDebug() {
1345
+ return _config.debug;
1346
+ }
1342
1347
 
1343
1348
  var gemx = /*#__PURE__*/Object.freeze({
1344
1349
  __proto__: null,
1345
1350
  get: get$2,
1351
+ isDebug: isDebug,
1346
1352
  set: set,
1347
1353
  start: start$J,
1348
1354
  stop: stop$G
@@ -2452,14 +2458,14 @@ var GEMX_OBSERVE = { allRoots: [scroll], documentOnly: [click] };
2452
2458
  var ALL_OBSERVE = { allRoots: [scroll], documentOnly: [click, clipboard, pointer, input, selection, change, submit] };
2453
2459
  var modules$2 = ALL$1;
2454
2460
  function start$s() {
2455
- modules$2 = config$3.mode === "gemx" ? GEMX$1 : ALL$1;
2461
+ modules$2 = (config$3 === null || config$3 === void 0 ? void 0 : config$3.mode) === "gemx" ? GEMX$1 : ALL$1;
2456
2462
  modules$2.forEach(function (m) { return m.start(); });
2457
2463
  }
2458
2464
  function stop$q() {
2459
2465
  modules$2.forEach(function (m) { return m.stop(); });
2460
2466
  }
2461
2467
  function observe$4(root) {
2462
- var observeModules = config$3.mode === "gemx" ? GEMX_OBSERVE : ALL_OBSERVE;
2468
+ var observeModules = (config$3 === null || config$3 === void 0 ? void 0 : config$3.mode) === "gemx" ? GEMX_OBSERVE : ALL_OBSERVE;
2463
2469
  observeModules.allRoots.forEach(function (m) { return m.observe(root); });
2464
2470
  if (root.nodeType === Node.DOCUMENT_NODE) {
2465
2471
  observeModules.documentOnly.forEach(function (m) { return m.observe(root); });
@@ -3154,7 +3160,7 @@ function handle$1(m) {
3154
3160
  }
3155
3161
  function processMutation(timer, mutation, instance, timestamp) {
3156
3162
  return __awaiter(this, void 0, void 0, function () {
3157
- var state$1, target, ignoredClasses, el_1, type;
3163
+ var state$1, target, ignoredClasses, isSnapshotProcessed, el_1, type;
3158
3164
  return __generator(this, function (_a) {
3159
3165
  switch (_a.label) {
3160
3166
  case 0:
@@ -3170,7 +3176,8 @@ function processMutation(timer, mutation, instance, timestamp) {
3170
3176
  }
3171
3177
  target = mutation.target;
3172
3178
  ignoredClasses = get$2().ignoreMutationClassNames;
3173
- if (ignoredClasses.length > 0 && target instanceof Element) {
3179
+ isSnapshotProcessed = isActive();
3180
+ if (!isSnapshotProcessed && ignoredClasses.length > 0 && target instanceof Element) {
3174
3181
  el_1 = target;
3175
3182
  if (ignoredClasses.some(function (cls) { return el_1.classList.contains(cls); })) {
3176
3183
  return [2 /*return*/];
@@ -5167,9 +5174,9 @@ function stop$g() {
5167
5174
  function upload(final, type) {
5168
5175
  if (final === void 0) { final = false; }
5169
5176
  return __awaiter(this, void 0, void 0, function () {
5170
- var isGemxSnapshot, sendPlaybackBytes, last, e, a, p, encoded, payload, zipped, _a;
5171
- return __generator(this, function (_b) {
5172
- switch (_b.label) {
5177
+ var isGemxSnapshot, sendPlaybackBytes, last, isDebug$1, trackedEvents, eventSet, labels, _i, trackedEvents_1, _a, eventType, label, e, a, p, encoded, payload, zipped, _b;
5178
+ return __generator(this, function (_c) {
5179
+ switch (_c.label) {
5173
5180
  case 0:
5174
5181
  if (!active$1) {
5175
5182
  return [2 /*return*/];
@@ -5190,6 +5197,21 @@ function upload(final, type) {
5190
5197
  // In some cases envelope has null data because it's part of the shutdown process while there's one upload call queued which might introduce runtime error
5191
5198
  if (!data$1)
5192
5199
  return [2 /*return*/];
5200
+ isDebug$1 = isDebug();
5201
+ if (!type && isDebug$1) {
5202
+ trackedEvents = [
5203
+ [9 /* Event.Click */, "click"],
5204
+ [10 /* Event.Scroll */, "scroll"],
5205
+ ];
5206
+ eventSet = new Set(analysis.map(function (item) { return JSON.parse(item)[1]; }));
5207
+ labels = [];
5208
+ for (_i = 0, trackedEvents_1 = trackedEvents; _i < trackedEvents_1.length; _i++) {
5209
+ _a = trackedEvents_1[_i], eventType = _a[0], label = _a[1];
5210
+ if (eventSet.has(eventType))
5211
+ labels.push(label);
5212
+ }
5213
+ type = labels.length > 0 ? labels.join("-") : undefined;
5214
+ }
5193
5215
  e = JSON.stringify(envelope(last));
5194
5216
  a = "[".concat(analysis.join(), "]");
5195
5217
  p = sendPlaybackBytes ? "[".concat(playback.join(), "]") : "" /* Constant.Empty */;
@@ -5200,14 +5222,14 @@ function upload(final, type) {
5200
5222
  encoded = { e: e, a: a, p: p };
5201
5223
  payload = stringify(encoded);
5202
5224
  if (!last) return [3 /*break*/, 1];
5203
- _a = null;
5225
+ _b = null;
5204
5226
  return [3 /*break*/, 3];
5205
5227
  case 1: return [4 /*yield*/, compress(payload)];
5206
5228
  case 2:
5207
- _a = _b.sent();
5208
- _b.label = 3;
5229
+ _b = _c.sent();
5230
+ _c.label = 3;
5209
5231
  case 3:
5210
- zipped = _a;
5232
+ zipped = _b;
5211
5233
  sum(2 /* Metric.TotalBytes */, zipped ? zipped.length : payload.length);
5212
5234
  send(payload, zipped, data$1.sequence, last, type);
5213
5235
  // Clear out events now that payload has been dispatched
@@ -6690,28 +6712,46 @@ function fire() {
6690
6712
  }
6691
6713
  function schedule(trigger) {
6692
6714
  triggered = false;
6693
- var clickCount = 0;
6715
+ var windowExpired = false;
6716
+ var delayScheduled = false;
6717
+ var scheduleDelayedFire = function (type) {
6718
+ var _a;
6719
+ if (delayScheduled || windowExpired)
6720
+ return;
6721
+ delayScheduled = true;
6722
+ console.log("[GemX Snapshot] ".concat(type, " triggered:"));
6723
+ setTimeout(fire, (_a = trigger.delayMs) !== null && _a !== void 0 ? _a : 0);
6724
+ };
6725
+ if (trigger.activeTimeMs) {
6726
+ setTimeout(function () {
6727
+ windowExpired = true;
6728
+ onTrustedScroll(null);
6729
+ onTrustedClick(null);
6730
+ }, trigger.activeTimeMs);
6731
+ }
6694
6732
  if (trigger.scrollDepthPercent) {
6695
6733
  onTrustedScroll(function () {
6696
- var scrolled = window.scrollY + window.innerHeight;
6697
- var total = document.documentElement.scrollHeight;
6698
- if ((scrolled / total) * 100 >= trigger.scrollDepthPercent) {
6699
- fire();
6734
+ var docH = document.documentElement.scrollHeight;
6735
+ var vpH = window.innerHeight;
6736
+ var maxScrollY = docH - vpH;
6737
+ if (maxScrollY <= 0)
6738
+ return;
6739
+ var scrollY = "pageYOffset" in window ? Math.round(window.pageYOffset) : Math.round(document.documentElement.scrollTop);
6740
+ var pct = Math.min(100, Math.round(scrollY / maxScrollY * 100));
6741
+ if (pct >= trigger.scrollDepthPercent) {
6742
+ scheduleDelayedFire('scroll');
6700
6743
  }
6701
6744
  });
6702
6745
  }
6703
6746
  if (trigger.clickCount) {
6747
+ var clickCount_1 = 0;
6704
6748
  onTrustedClick(function () {
6705
- clickCount++;
6706
- if (clickCount >= trigger.clickCount) {
6707
- fire();
6749
+ clickCount_1++;
6750
+ if (clickCount_1 >= trigger.clickCount) {
6751
+ scheduleDelayedFire('click');
6708
6752
  }
6709
6753
  });
6710
6754
  }
6711
- if (trigger.activeTimeMs) {
6712
- setTimeout(fire, trigger.activeTimeMs);
6713
- }
6714
- // maxPlaybackBytes trigger is handled via gemxUpload.start() callback above
6715
6755
  }
6716
6756
  function flush() {
6717
6757
  inject(drain());
@@ -7048,7 +7088,7 @@ var ALL = [diagnostic, layout, interaction, performance$1, dynamic];
7048
7088
  var modules = ALL;
7049
7089
  function start(config$1) {
7050
7090
  if (config$1 === void 0) { config$1 = null; }
7051
- modules = config$1.mode === "gemx" ? GEMX : ALL;
7091
+ modules = (config$1 === null || config$1 === void 0 ? void 0 : config$1.mode) === "gemx" ? GEMX : ALL;
7052
7092
  // Check that browser supports required APIs and we do not attempt to start Clarity multiple times
7053
7093
  if (check()) {
7054
7094
  config(config$1);