TP_JO2024/home/dist/analytics/analytics.nomodule.min.js

4 lines
94 KiB
JavaScript
Raw Permalink Normal View History

2024-03-27 17:19:37 +01:00
/*! DSFR v1.11.2 | SPDX-License-Identifier: MIT | License-Filename: LICENSE.md | restricted use (see terms and conditions) */
!function(){"use strict";var t=window.dsfr,e="a4e35ba2a938ba9d007689dbf3f46acbb9807869",n={MANUAL:"manual",LOAD:"load",FULL:"full",HASH:"hash"},i="_EA_",r=i+"disabled",o=i+"toggle",s=function(){this._configure()},a={isDisabled:{configurable:!0}};s.prototype._configure=function(){var t=this;window[r]=function(){return t.isDisabled},window[o]=this.toggle.bind(this)},a.isDisabled.get=function(){return localStorage.getItem(i)},s.prototype.toggle=function(){this.isDisabled?this.enable():this.disable()},s.prototype.enable=function(){localStorage.getItem(i)&&localStorage.removeItem(i)},s.prototype.disable=function(){localStorage.setItem(i,"1")},Object.defineProperties(s.prototype,a);var c=new s,l="EA_push",u=function(t){var e=this;this._domain=t,this._isLoaded=!1,this._promise=new Promise((function(t,n){e._resolve=t,e._reject=n}))},p={id:{configurable:!0},store:{configurable:!0}};p.id.get=function(){return this._id},p.store.get=function(){return this._store},u.prototype.configure=function(){return this.init(),this._promise},u.prototype.init=function(){for(var e=this,n=5381,i=this._domain.length-1;i>0;i--)n=33*n^this._domain.charCodeAt(i);n>>>=0,this._id="_EA_"+n,this._store=[],this._store.eah=this._domain,window[this._id]=this._store,window[l]||(window[l]=function(){for(var t=[],n=arguments.length;n--;)t[n]=arguments[n];return e.store.push(t)}),c.isDisabled?(t.inspector.warn("User opted out, eulerian is disabled"),this._reject("User opted out, eulerian is disabled")):this.load()},u.prototype.load=function(){var t=new Date/1e7|0,e=t%26,n=String.fromCharCode(97+e,122-e,65+e)+t%1e3;this._script=document.createElement("script"),this._script.ea=this.id,this._script.async=!0,this._script.addEventListener("load",this.loaded.bind(this)),this._script.addEventListener("error",this.error.bind(this)),this._script.src="//"+this._domain+"/"+n+".js?2";var i=document.getElementsByTagName("script")[0];i.parentNode.insertBefore(this._script,i)},u.prototype.error=function(){t.inspector.error("unable to load Eulerian script file. the domain declared in your configuration must match the domain provided by the Eulerian interface (tag creation)"),this._reject("eulerian script loading error")},u.prototype.loaded=function(){this._isLoaded||(this._isLoaded=!0,this._resolve())},Object.defineProperties(u.prototype,p);var h=-1,f=0,g=1,d=2,_=3,b=function(t){var e=this;this._config=t,this._state=h,this._promise=new Promise((function(t,n){e._resolve=t,e._reject=n}))};b.prototype.configure=function(){if(this._state>=g)return this._promise;this._state===h&&(t.inspector.info("analytics configures tarteaucitron"),this._state=f);var e=window.tarteaucitron;if(e&&e.services){this._state=g;var n={key:"eulerian",type:"analytic",name:"Eulerian Analytics",needConsent:!0,cookies:["etuix"],uri:"https://eulerian.com/vie-privee",js:this.init.bind(this),fallback:function(){e.services.eulerian.js()}};return e.services.eulerian=n,e.job||(e.job=[]),e.job.push("eulerian"),this._promise}window.requestAnimationFrame(this.configure.bind(this))},b.prototype.init=function(){if(!(this._state>=d)){this._state=d,window.__eaGenericCmpApi=this.integrate.bind(this);var t=this.update.bind(this);window.addEventListener("tac.close_alert",t),window.addEventListener("tac.close_panel",t)}},b.prototype.integrate=function(e){this._state>=_||(this._state=_,this._cmpApi=e,t.inspector.info("analytics has integrated tarteaucitron"),this._resolve(),this.update())},b.prototype.update=function(){this._state<_||this._cmpApi("tac",window.tarteaucitron,1)};var y=function(t){if(this._config=t,t&&"tarteaucitron"===t.id)this.integrateTarteAuCitron()};y.prototype.integrateTarteAuCitron=function(){return this._tac=new b(this._config),this._tac.configure()},y.prototype.optin=function(){};var m=function(e,n){"function"==typeof window.EA_push?(t.inspector.info("analytics",e,n),window.EA_push(e,n)):t.inspector.warn("Analytics datalayer not sent, Eulerian API isn't yet avalaible")},v={COLLECTOR:"collector",ACTION:"action",ACTION_PARAMETER:"actionparam"},N=function(){this._renderables=[],this._rendering=this.render.b
//# sourceMappingURL=analytics.nomodule.min.js.map