/*!! * Matomo - free/libre analytics platform * * JavaScript tracking client * * @link https://piwik.org * @source https://github.com/matomo-org/matomo/blob/master/js/piwik.js * @license https://piwik.org/free-software/bsd/ BSD-3 Clause (also in js/LICENSE.txt) * @license magnet:?xt=urn:btih:c80d50af7d3db9be66a4d0a86db0286e4fd33292&dn=bsd-3-clause.txt BSD-3-Clause */ ;if(typeof _paq!=="object"){_paq=[]}if(typeof window.Matomo!=="object"){window.Matomo=window.Piwik=(function(){var r,b={},z={},J=document,g=navigator,ab=screen,W=window,h=W.performance||W.mozPerformance||W.msPerformance||W.webkitPerformance,t=W.encodeURIComponent,V=W.decodeURIComponent,k=unescape,L=[],H,u,al=[],y=0,af=0,X=0,m=false;function p(at){try{return V(at)}catch(au){return unescape(at)}}function M(au){var at=typeof au;return at!=="undefined"}function C(at){return typeof at==="function"}function Z(at){return typeof at==="object"}function x(at){return typeof at==="string"||at instanceof String}function ak(at){return typeof at==="number"||at instanceof Number }function ac(at){return M(at)&&(ak(at)||(x(at)&&at.length))}function D(au){if(!au){return true}var at;var av=true;for(at in au){if(Object.prototype.hasOwnProperty.call(au,at)){av=false}}return av}function ao(at){var au=typeof console;if(au!=="undefined"&&console&&console.error){console.error(at)}}function aj(){var ay,ax,aA,au,at;for(ay=0;ay0;if(aw){az=aA.split("::");av=az[0];aA=az[1];if("object"===typeof u[av]&&"function"===typeof u[av][aA]){u[av][aA].apply(u[av],au)}else{if(at){al.push(at)}}}else{for(ax=0;ax0;if(aB){az=aA.split(".");if(av&&"object"===typeof av[az[0]]){av=av[az[0]];aA=az[1]}else{if(at){al.push(at);break}}}if(av[aA]){av[aA].apply(av,au)}else{var aC="The method '"+aA+'\' was not found in "_paq" variable. Please have a look at the Matomo tracker documentation: https://developer.matomo.org/api-reference/tracking-javascript'; ao(aC);if(!aB){throw new TypeError(aC)}}if(aA==="addTracker"){break}if(aA==="setTrackerUrl"||aA==="setSiteId"){break}}else{aA.apply(L[ax],au)}}}}}function ar(aw,av,au,at){if(aw.addEventListener){aw.addEventListener(av,au,at);return true}if(aw.attachEvent){return aw.attachEvent("on"+av,au)}aw["on"+av]=au}function n(at){if(J.readyState==="complete"){at()}else{if(W.addEventListener){W.addEventListener("load",at,false)}else{if(W.attachEvent){W.attachEvent("onload",at)}}}}function q(aw){var at=false;if(J.attachEvent){at=J.readyState==="complete"}else{at=J.readyState!=="loading"}if(at){aw();return}var av;if(J.addEventListener){ar(J,"DOMContentLoaded",function au(){J.removeEventListener("DOMContentLoaded",au,false);if(!at){at=true;aw()}})}else{if(J.attachEvent){J.attachEvent("onreadystatechange",function au(){if(J.readyState==="complete"){J.detachEvent("onreadystatechange",au);if(!at){at=true;aw()}}});if(J.documentElement.doScroll&&W===W.top){(function au(){if(!at){try{J.documentElement.doScroll("left") }catch(ax){setTimeout(au,0);return}at=true;aw()}}())}}}ar(W,"load",function(){if(!at){at=true;aw()}},false)}function ag(au,az,aA){if(!au){return""}var at="",aw,av,ax,ay;for(aw in b){if(Object.prototype.hasOwnProperty.call(b,aw)){ay=b[aw]&&"function"===typeof b[aw][au];if(ay){av=b[aw][au];ax=av(az||{},aA);if(ax){at+=ax}}}}return at}function am(au){var at;m=true;ag("unload");at=new Date();var av=at.getTimeAlias();if((r-av)>3000){r=av+3000}if(r){do{at=new Date()}while(at.getTimeAlias()=0;ay--){ax=az[ay].split("=")[0];if(ax===av){az.splice(ay,1)}}var aC=az.join("&");if(aC){aA=aA+"?"+aC}if(aB){aA+="#"+aB}}return aA}function e(av,au){var at="[\\?&#]"+au+"=([^&#]*)";var ax=new RegExp(at);var aw=ax.exec(av);return aw?p(aw[1]):""}function a(at){if(at&&String(at)===at){return at.replace(/^\s+|\s+$/g,"")}return at}function F(at){return unescape(t(at))}function aq(aI){var av=function(aO,aN){return(aO<>>(32-aN))},aJ=function(aQ){var aO="",aP,aN;for(aP=7;aP>=0;aP--){aN=(aQ>>>(aP*4))&15; aO+=aN.toString(16)}return aO},ay,aL,aK,au=[],aC=1732584193,aA=4023233417,az=2562383102,ax=271733878,aw=3285377520,aH,aG,aF,aE,aD,aM,at,aB=[];aI=F(aI);at=aI.length;for(aL=0;aL>>29);aB.push((at<<3)&4294967295);for(ay=0;ayay.offsetWidth+ay.scrollLeft||aA+aD-aEay.offsetHeight+ay.scrollTop||aF+aB-aEaB?-1:1});if(at.length<=1){return at}var au=0;var aw=0;var ax=[];var av;av=at[au++];while(av){if(av===at[au]){aw=ax.push(au)}av=at[au++]||null}while(aw--){at.splice(ax[aw],1)}return at},getAttributeValueFromNode:function(ax,av){if(!this.hasNodeAttribute(ax,av)){return}if(ax&&ax.getAttribute){return ax.getAttribute(av)}if(!ax||!ax.attributes){return}var aw=(typeof ax.attributes[av]);if("undefined"===aw){return}if(ax.attributes[av].value){return ax.attributes[av].value}if(ax.attributes[av].nodeValue){return ax.attributes[av].nodeValue}var au;var at=ax.attributes;if(!at){return}for(au=0;au1000){break}at++}},findPieceNode:function(au){var at; at=ai.findFirstNodeHavingAttribute(au,this.CONTENT_PIECE_ATTR);if(!at){at=ai.findFirstNodeHavingClass(au,this.CONTENT_PIECE_CLASS)}if(!at){at=ai.findFirstNodeHavingClass(au,this.LEGACY_CONTENT_PIECE_CLASS)}if(at){return at}return au},findTargetNodeNoDefault:function(at){if(!at){return}var au=ai.findFirstNodeHavingAttributeWithValue(at,this.CONTENT_TARGET_ATTR);if(au){return au}au=ai.findFirstNodeHavingAttribute(at,this.CONTENT_TARGET_ATTR);if(au){return au}au=ai.findFirstNodeHavingClass(at,this.CONTENT_TARGET_CLASS);if(au){return au}au=ai.findFirstNodeHavingClass(at,this.LEGACY_CONTENT_TARGET_CLASS);if(au){return au}},findTargetNode:function(at){var au=this.findTargetNodeNoDefault(at);if(au){return au}return at},findContentName:function(au){if(!au){return}var ax=ai.findFirstNodeHavingAttributeWithValue(au,this.CONTENT_NAME_ATTR);if(ax){return ai.getAttributeValueFromNode(ax,this.CONTENT_NAME_ATTR)}var at=this.findContentPiece(au);if(at){return this.removeDomainIfIsInLink(at)}if(ai.hasNodeAttributeWithValue(au,"title")){return ai.getAttributeValueFromNode(au,"title") }var av=this.findPieceNode(au);if(ai.hasNodeAttributeWithValue(av,"title")){return ai.getAttributeValueFromNode(av,"title")}var aw=this.findTargetNode(au);if(ai.hasNodeAttributeWithValue(aw,"title")){return ai.getAttributeValueFromNode(aw,"title")}},findContentPiece:function(au){if(!au){return}var aw=ai.findFirstNodeHavingAttributeWithValue(au,this.CONTENT_PIECE_ATTR);if(aw){return ai.getAttributeValueFromNode(aw,this.CONTENT_PIECE_ATTR)}var at=this.findPieceNode(au);var av=this.findMediaUrlInNode(at);if(av){return this.toAbsoluteUrl(av)}},findContentTarget:function(av){if(!av){return}var aw=this.findTargetNode(av);if(ai.hasNodeAttributeWithValue(aw,this.CONTENT_TARGET_ATTR)){return ai.getAttributeValueFromNode(aw,this.CONTENT_TARGET_ATTR)}var au;if(ai.hasNodeAttributeWithValue(aw,"href")){au=ai.getAttributeValueFromNode(aw,"href");return this.toAbsoluteUrl(au)}var at=this.findPieceNode(av);if(ai.hasNodeAttributeWithValue(at,"href")){au=ai.getAttributeValueFromNode(at,"href");return this.toAbsoluteUrl(au) }},isSameDomain:function(at){if(!at||!at.indexOf){return false}if(0===at.indexOf(this.getLocation().origin)){return true}var au=at.indexOf(this.getLocation().host);if(8>=au&&0<=au){return true}return false},removeDomainIfIsInLink:function(av){var au="^https?://[^/]+";var at="^.*//[^/]+";if(av&&av.search&&-1!==av.search(new RegExp(au))&&this.isSameDomain(av)){av=av.replace(new RegExp(at),"");if(!av){av="/"}}return av},findMediaUrlInNode:function(ax){if(!ax){return}var av=["img","embed","video","audio"];var at=ax.nodeName.toLowerCase();if(-1!==P(av,at)&&ai.findFirstNodeHavingAttributeWithValue(ax,"src")){var aw=ai.findFirstNodeHavingAttributeWithValue(ax,"src");return ai.getAttributeValueFromNode(aw,"src")}if(at==="object"&&ai.hasNodeAttributeWithValue(ax,"data")){return ai.getAttributeValueFromNode(ax,"data")}if(at==="object"){var ay=ai.findNodesByTagName(ax,"param");if(ay&&ay.length){var au;for(au=0;au0}var au=aw.clientWidth;if(W.innerWidth&&au>W.innerWidth){au=W.innerWidth}var at=aw.clientHeight;if(W.innerHeight&&at>W.innerHeight){at=W.innerHeight}return((ax.bottom>0||av)&&ax.right>0&&ax.left=0)&&aH(dx)!==String(dy)){var dt="There was an error setting cookie `"+dx+"`. Please check domain and path.";ao(dt)}}function b8(dt){var dv,du;dt=j(dt,az);for(du=0;du=0){dv=dv.slice(0,du)}du=dv.lastIndexOf("/");if(du!==dv.length-1){dv=dv.slice(0,du+1)}return dv+dt}function cP(dv,dt){var du;dv=String(dv).toLowerCase();dt=String(dt).toLowerCase(); if(dv===dt){return true}if(dt.slice(0,1)==="."){if(dv===dt.slice(1)){return true}du=dv.length-dt.length;if((du>0)&&(dv.slice(du)===dt)){return true}}return false}function cr(dt){var du=document.createElement("a");if(dt.indexOf("//")!==0&&dt.indexOf("http")!==0){if(dt.indexOf("*")===0){dt=dt.substr(1)}if(dt.indexOf(".")===0){dt=dt.substr(1)}dt="http://"+dt}du.href=w.toAbsoluteUrl(dt);if(du.pathname){return du.pathname}return""}function a9(du,dt){if(!an(dt,"/")){dt="/"+dt}if(!an(du,"/")){du="/"+du}var dv=(dt==="/"||dt==="/*");if(dv){return true}if(du===dt){return true}dt=String(dt).toLowerCase();du=String(du).toLowerCase();if(U(dt,"*")){dt=dt.slice(0,-1);dv=(!dt||dt==="/");if(dv){return true}if(du===dt){return true}return du.indexOf(dt)===0}if(!U(du,"/")){du+="/"}if(!U(dt,"/")){dt+="/"}return du.indexOf(dt)===0}function aw(dx,dz){var du,dt,dv,dw,dy;for(du=0;du0)&&(dw.slice(dv)===dt)){return true}}}return false}function cv(dt,dv){dt=dt.replace("send_image=0","send_image=1");var du=new Image(1,1);du.onload=function(){H=0;if(typeof dv==="function"){dv({request:dt,trackerUrl:aI,success:true})}};du.onerror=function(){if(typeof dv==="function"){dv({request:dt,trackerUrl:aI,success:false})}};du.src=aI+(aI.indexOf("?")<0?"?":"&")+dt}function cM(dt){if(dj==="POST"){return true}return dt&&(dt.length>2000||dt.indexOf('{"requests"')===0)}function aP(){return"object"===typeof g&&"function"===typeof g.sendBeacon&&"function"===typeof Blob}function bc(dx,dA,dz){var dv=aP();if(!dv){return false}var dw={type:"application/x-www-form-urlencoded; charset=UTF-8"};var dB=false;var du=aI;try{var dt=new Blob([dx],dw);if(dz&&!cM(dx)){dt=new Blob([],dw);du=du+(du.indexOf("?")<0?"?":"&")+dx}dB=g.sendBeacon(du,dt)}catch(dy){return false }if(dB&&typeof dA==="function"){dA({request:dx,trackerUrl:aI,success:true,isSendBeacon:true})}return dB}function de(du,dv,dt){if(!M(dt)||null===dt){dt=true}if(m&&bc(du,dv,dt)){return}setTimeout(function(){if(m&&bc(du,dv,dt)){return}var dy;try{var dx=W.XMLHttpRequest?new W.XMLHttpRequest():W.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):null;dx.open("POST",aI,true);dx.onreadystatechange=function(){if(this.readyState===4&&!(this.status>=200&&this.status<300)){var dz=m&&bc(du,dv,dt);if(!dz&&dt){cv(du,dv)}else{if(typeof dv==="function"){dv({request:du,trackerUrl:aI,success:false,xhr:this})}}}else{if(this.readyState===4&&(typeof dv==="function")){dv({request:du,trackerUrl:aI,success:true,xhr:this})}}};dx.setRequestHeader("Content-Type",cE);dx.withCredentials=true;dx.send(du)}catch(dw){dy=m&&bc(du,dv,dt);if(!dy&&dt){cv(du,dv)}else{if(typeof dv==="function"){dv({request:du,trackerUrl:aI,success:false})}}}},50)}function cl(du){var dt=new Date();var dv=dt.getTime()+du;if(!r||dv>r){r=dv}}function bg(){bi=true; cF=new Date().getTime()}function dm(){var dt=new Date().getTime();return !cF||(dt-cF)>bb}function aD(){if(dm()){bX()}}function a0(){if(J.visibilityState==="hidden"&&dm()){bX()}else{if(J.visibilityState==="visible"){cF=new Date().getTime()}}}function dq(){if(aS||!bb){return}aS=true;ar(W,"focus",bg);ar(W,"blur",aD);ar(W,"visibilitychange",a0);af++;u.addPlugin("HeartBeat"+af,{unload:function(){if(aS&&dm()){bX()}}})}function cK(dx){var du=new Date();var dt=du.getTime();c8=dt;if(cJ&&dt=dt.length){return[dt]}var du=0;var dv=dt.length;var dw=[]; for(du;du=du&&dt<=(du+a5)){return true}}return false}function dr(dt){if(!cV){return""}var dx=e(dt,az);if(!dx){return""}dx=String(dx);var dv=new RegExp("^[a-zA-Z0-9]+$");if(dx.length===32&&dv.test(dx)){var du=dx.substr(16,32);if(dc(du)){var dw=dx.substr(0,16);return dw}}return""}function cW(){if(!bU){bU=dr(bT)}var dv=new Date(),dt=Math.round(dv.getTime()/1000),du=aY("id"),dy=aH(du),dx,dw;if(dy){dx=dy.split(".");dx.unshift("0");if(bU.length){dx[1]=bU}return dx}if(bU.length){dw=bU}else{if("0"===cb()){dw=""}else{dw=cZ()}}dx=["1",dw,dt];return dx}function a4(){var dw=cW(),du=dw[0],dv=dw[1],dt=dw[2];return{newVisitor:du,uuid:dv,createTs:dt}}function aL(){var dw=new Date(),du=dw.getTime(),dx=a4().createTs;var dt=parseInt(dx,10);var dv=(dt*1000)+cS-du;return dv}function aR(dt){if(!cc){return}var dv=new Date(),du=Math.round(dv.getTime()/1000);if(!M(dt)){dt=a4()}var dw=dt.uuid+"."+dt.createTs+".";dn(aY("id"),dw,aL(),bw,c7,bY,aN) }function bS(){var dt=aH(aY("ref"));if(dt.length){try{dt=W.JSON.parse(dt);if(Z(dt)){return dt}}catch(du){}}return["","",0,""]}function bD(dv){var du=bq+"testcookie_domain";var dt="testvalue";dn(du,dt,10000,null,dv,bY,aN);if(aH(du)===dt){b5(du,null,dv);return true}return false}function aJ(){var du=bs;bs=false;var dt,dv;for(dt=0;dt0){dx=parseInt(dx,10);dA(dx)}})}var bK={enabled:true,requests:[],timeout:null,interval:2500,sendRequests:function(){var dt=this.requests;this.requests=[];if(dt.length===1){bM(dt[0],bQ)}else{dp(dt,bQ)}},canQueue:function(){return !m&&this.enabled},pushMultiple:function(du){if(!this.canQueue()){dp(du,bQ);return}var dt;for(dt=0;dt0){if(!M(du)){du=""}if(!x(du)){du=String(du)}bt[dt]=du}};this.getCustomDimension=function(dt){dt=parseInt(dt,10);if(dt>0&&Object.prototype.hasOwnProperty.call(bt,dt)){return bt[dt]}};this.deleteCustomDimension=function(dt){dt=parseInt(dt,10);if(dt>0){delete bt[dt]}};this.setCustomVariable=function(du,dt,dx,dv){var dw;if(!M(dv)){dv="visit"}if(!M(dt)){return}if(!M(dx)){dx=""}if(du>0){dt=!x(dt)?String(dt):dt;dx=!x(dx)?String(dx):dx;dw=[dt.slice(0,bA),dx.slice(0,bA)];if(dv==="visit"||dv===2){cN();aV[du]=dw}else{if(dv==="page"||dv===3){b2[du]=dw}else{if(dv==="event"){cs[du]=dw}}}}};this.getCustomVariable=function(du,dv){var dt;if(!M(dv)){dv="visit"}if(dv==="page"||dv===3){dt=b2[du]}else{if(dv==="event"){dt=cs[du]}else{if(dv==="visit"||dv===2){cN(); dt=aV[du]}}}if(!M(dt)||(dt&&dt[0]==="")){return false}return dt};this.deleteCustomVariable=function(dt,du){if(this.getCustomVariable(dt,du)){this.setCustomVariable(dt,"","",du)}};this.deleteCustomVariables=function(dt){if(dt==="page"||dt===3){b2={}}else{if(dt==="event"){cs={}}else{if(dt==="visit"||dt===2){aV={}}}}};this.storeCustomVariablesInCookie=function(){bW=true};this.setLinkTrackingTimer=function(dt){bQ=dt};this.getLinkTrackingTimer=function(){return bQ};this.setDownloadExtensions=function(dt){if(x(dt)){dt=dt.split("|")}dg=dt};this.addDownloadExtensions=function(du){var dt;if(x(du)){du=du.split("|")}for(dt=0;dt1&&au!=="addTracker"&&au!=="enableLinkTracking"){ao("The method "+au+' is registered more than once in "_paq" variable. Only the last call has an effect. Please have a look at the multiple Matomo trackers documentation: https://developer.matomo.org/guides/tracking-javascript-guide#multiple-piwik-trackers')}az[au]++}}}}return ay}var E=["addTracker","forgetCookieConsentGiven","requireCookieConsent","disableBrowserFeatureDetection","disableCookies","setTrackerUrl","setAPIUrl","enableCrossDomainLinking","setCrossDomainLinkingTimeout","setSessionCookieTimeout","setVisitorCookieTimeout","setCookieNamePrefix","setCookieSameSite","setSecureCookie","setCookiePath","setCookieDomain","setDomains","setUserId","setVisitorId","setSiteId","alwaysUseSendBeacon","disableAlwaysUseSendBeacon","enableLinkTracking","setCookieConsentGiven","requireConsent","setConsentGiven","disablePerformanceTracking","setPagePerformanceTiming","setExcludedQueryParams"]; function ah(av,au){var at=new T(av,au);L.push(at);_paq=c(_paq,E);for(H=0;H<_paq.length;H++){if(_paq[H]){aj(_paq[H])}}_paq=new K();u.trigger("TrackerAdded",[at]);return at}ar(W,"beforeunload",am,false);ar(W,"visibilitychange",function(){if(m){return}if(J.visibilityState==="hidden"){ag("unload")}},false);ar(W,"online",function(){if(M(g.serviceWorker)){g.serviceWorker.ready.then(function(at){if(at&&at.sync){return at.sync.register("matomoSync")}},function(){})}},false);ar(W,"message",function(ay){if(!ay||!ay.origin){return}var aA,aw,au;var aB=d(ay.origin);var ax=u.getAsyncTrackers();for(aw=0;aw