@20minutes/tyr 2.41.9 → 2.42.0
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.
- package/dist/assets/thirdParties/cmp/firstPartyHandler.d.ts +1 -0
- package/dist/assets/thirdParties/cmp/items.d.ts +2 -0
- package/dist/helpers/cookie.d.ts +6 -0
- package/dist/index.es.js +1290 -1280
- package/dist/index.umd.js +37 -37
- package/dist/js/ads.min.js +1 -1
- package/dist/js/cmp.min.js +2 -2
- package/dist/js/edgee.min.js +1 -1
- package/dist/js/main.min.js +5 -5
- package/dist/js/piano.min.js +1 -1
- package/dist/types/EnvVariablesType.d.ts +2 -0
- package/dist/types/ThirdParties/Cmp/Didomi.d.ts +3 -2
- package/package.json +2 -1
package/dist/js/piano.min.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
!function(){"use strict";var e=(e=>(e.ARCHIVE_BY_DAY="archivebyday",e.ARCHIVE_BY_YEAR="archivebyyear",e.ARTICLE="article",e.ASTRO="astro",e.ASTRO_HOME="astrohome",e.CONTACT="contact",e.DIRECT="direct",e.ELECTIONS="elections",e.ELECTIONSHOME="electionshome",e.GAME="game",e.GAME_APP="gameapp",e.GAMEHOME="gamehome",e.HOME="home",e.JOB_DETAILS="jobdetails",e.JOBS="jobs",e.JOURNALIST="journalist",e.LA21E="la21e",e.LEGAL="legal",e.LEGALNOTICE="legalnotice",e.LEGALNOTICEHOME="legalnoticehome",e.LEGALNOTICEDEPARTMENT="legalnoticedepartment",e.LIVE="live",e.MOBILE_APPS="mobileapps",e.MOST_COMMENTED="mostcommented",e.MOST_READ="mostread",e.MOST_SHARED="mostshared",e.MOST_VIEWED="mostviewed",e.MOVIES="movies",e.NEWS="news",e.PARTNER="partner",e.REWIND="rewind",e.SEARCH="search",e.SECTION="section",e.SERVICE="service",e.SITEMAP="sitemap",e.SPORT="sport",e.STORY="story",e.TAG="tag",e.TRAFFIC="traffic",e.TV_HOME="tvhome",e.TV_LIVE="tvlive",e.TV_MOST_RECENT="tvmostrecent",e.TV_MOST_VIEWED="tvmostviewed",e.TV_SHOW="tvshow",e.TV_SHOWS="tvshows",e.TV_VIDEO="tvvideo",e.WEATHER="weather",e))(e||{});var t=(e=>(e.down="down",e.heart="heart",e.laughing="laughing",e.sad="sad",e.shock="shock",e.up="up",e))(t||{});t.up,t.down,t.sad,t.heart,t.laughing,t.shock;const n=(e,t)=>{let n=e.toLowerCase().replace(/[\s-]+/g,"-");return n=(e=>{let t=e;const n="ãàáäâẽèéëêìíïîõòóöôùúüûñç·/,:;";for(let e=0;e<30;e+=1)t=t.replace(new RegExp(n.charAt(e),"g"),"aaaaaeeeeeiiiiooooouuuunc-----".charAt(e));return t})(n),n.replace(/[^\w-]+/g,"").replace(/-*$/g,"")},a=()=>{const e=new URLSearchParams(window.location.search);return Object.fromEntries(e.entries())},o=["chapter1","chapter2","chapter3","chapter4"],r=()=>document.querySelectorAll(".c-content > p").length,i=()=>[...document.querySelectorAll(".c-content > p")].reduce((e,t)=>e+t.innerHTML.length,0),s=()=>{const e={},t=a();return("utm_source"in t||"utm_campaign"in t||"utm_medium"in t)&&("utm_source"in t||(e.utm_source=t.utm_medium??t.utm_campaign),"utm_campaign"in t||(e.utm_campaign=t.utm_source??t.utm_medium),"utm_medium"in t||(e.utm_medium=t.utm_source??t.utm_campaign)),e},c=()=>{const e=window.datalayerInfo,t={};e?.breadcrumb?.forEach((e,t)=>{let a=n(e);"diaporamas"===a&&(a="diaporama"),"actualite"===a&&(a="actu-generale"),"guide-dachat"===a&&(a="guide-achat");const r=o[t];r&&window.PianoPageInfo&&(window.PianoPageInfo[r]=a)});const a=Number(e?.contentId);Number.isFinite(a)&&(t["n:content_id"]=a),t.content_type=e?.pageName??"other",t["s:page_type"]="content",t["d:content_published_date"]=e?.modificationDate?new Date(e.modificationDate).toISOString():"",t["d:content_modified_date"]=e?.publicationDate?new Date(e.publicationDate).toISOString():"";const r=Number(e?.journalist?.id);return Number.isFinite(r)&&(t["n:content_id_journaliste"]=r),t["s:content_tags"]=e?.tagsSlug??"",t["s:content_signature"]=n(e?.signature??""),t["s:content_title"]=n(e?.contentTitle??""),t["n:content_title_characters_number"]=Number(e?.contentTitle?.length),t["s:content_subtype"]="texte",t["n:content_video_number"]=e?.videoCount??0,t["n:content_20min_video_number"]=e?.video20mnCount??0,t["n:content_embed_number"]=e?.embedCount??0,e?.podcastCount&&e?.podcastCount>0?t["s:content_subtype"]="podcast":t["n:content_video_number"]>0&&(t["s:content_subtype"]="video"),t},d=(e,t,n,a)=>(window.PianoPageInfo&&(t&&(window.PianoPageInfo.chapter1=t),n&&(window.PianoPageInfo.chapter2=n),a&&(window.PianoPageInfo.chapter3=a)),e?{"s:page_type":e}:{}),u=()=>{const e=window.datalayerInfo,t={};t["b:user_adblock"]=!window.adsapp,t.page_url=e?.pageUri??"",window.PianoPageInfo&&(window.PianoPageInfo.name=new URL(window.location.href).pathname,e?.pageUri&&(window.PianoPageInfo.name=new URL(e.pageUri).pathname)),e?.contentSource&&(t["s:content_source"]=e.contentSource),document.referrer&&(t["s:misc_referrer"]=document.referrer),t["s:page_type"]=e?.pageName||"other";const n=document.querySelector("link[rel='canonical']");if(n&&(t["s:page_canonical"]=n.getAttribute("href")??""),"/search"===e?.pageUri){const e=a();t["s:misc_search"]=e.q||""}return window.performance&&(t.navigation_method=window.performance.getEntriesByType?.("navigation")?.map(e=>e.type)?.pop()||null),{...t,...s()}},p=()=>{switch(window.datalayerInfo?.pageName||"other"){case e.ARCHIVE_BY_DAY:case e.ARCHIVE_BY_YEAR:return d("divers");case e.ARTICLE:return(()=>{const e=c();return e["n:content_characters_number"]=Number(i()),e["n:content_paragraphs_number"]=r(),e})();case e.ASTRO_HOME:return"numerology"===window.datalayerInfo?.pageKey?d("home_numerologie","services","numerologie"):d("home_horoscope","services","horoscope");case e.ASTRO:return["un","deux","trois","quatre","cinq","six","sept","huit","neuf"].includes(window.datalayerInfo?.pageKey||"")?d("numerologie","services","numerologie"):d("horoscope","services","horoscope");case e.DIRECT:return d("divers","le-direct");case e.ELECTIONS:case e.ELECTIONSHOME:return(()=>{const{national:e,region:t,department:n,constituency:a,town:o}=window.datalayerInfo?.elections||{};return window.PianoPageInfo&&(window.PianoPageInfo.chapter1="elections",window.PianoPageInfo.chapter2="resultats",o&&n?(window.PianoPageInfo.chapter3=n,window.PianoPageInfo.chapter4=o):a&&n?(window.PianoPageInfo.chapter3=n,window.PianoPageInfo.chapter4=a):n&&t?(window.PianoPageInfo.chapter3=t,window.PianoPageInfo.chapter4=n):t?(window.PianoPageInfo.chapter3="france",window.PianoPageInfo.chapter4=t):e&&(window.PianoPageInfo.chapter3=e)),{"s:page_type":"elections"}})();case e.HOME:return window.PianoPageInfo&&(window.PianoPageInfo.chapter1="accueil",window.PianoPageInfo.chapter2=""),{"s:page_type":"home","s:content_source":"20mn",content_type:null};case e.GAME:return d(void 0,"services","jeux",window.datalayerInfo?.pageKey);case e.GAME_APP:return(()=>{const e=c();return e["s:page_type"]="home_game",window.datalayerInfo?.pageKey&&(e["s:page_type"]="game"),e})();case e.GAMEHOME:return d("home_game","services","jeux");case e.JOB_DETAILS:return(()=>{const{pageKey:e,tagsSlug:t="",contentTitle:n="",embedCount:a=0,videoCount:o=0,video20mnCount:s=0}=window.datalayerInfo||{};return{"s:content_source":"labsense","s:page_type":"content",content_type:"card","s:content_tags":t,"s:content_signature":"","s:content_title":n,"s:content_subtype":"job","n:content_id":Number(e),"n:content_id_journaliste":0,"n:content_title_characters_number":Number(n.length),"n:content_video_number":o,"n:content_20min_video_number":s,"n:content_embed_number":a,"n:content_characters_number":Number(i()),"n:content_paragraphs_number":r(),"d:content_published_date":"","d:content_modified_date":""}})();case e.JOBS:return d("home_tag",window.datalayerInfo?.pageKey,"");case e.JOURNALIST:return(()=>{const{firstName:e,lastName:t}=window.datalayerInfo?.journalist||{};return e&&t&&window.PianoPageInfo&&(window.PianoPageInfo.chapter1=`journaliste--${e}-${t}`),{"s:page_type":"journalist"}})();case e.LA21E:return d("divers","focus--accueil");case e.LEGALNOTICE:return(()=>{const{contentTitle:e}=window.datalayerInfo||{};return e&&window.PianoPageInfo&&(window.PianoPageInfo.chapter1=`legal-announcement--${e}`),{"s:page_type":"legal_notice"}})();case e.LEGALNOTICEDEPARTMENT:return(()=>{const{contentTitle:e}=window.datalayerInfo||{};return window.PianoPageInfo&&(window.PianoPageInfo.chapter1=`legal-announcement-list--${e}`),{"s:page_type":"legal_notice_department"}})();case e.LEGALNOTICEHOME:return d("legal_notice_home","legal-announcement-list");case e.LEGAL:return(()=>{const{pageKey:e}=window.datalayerInfo||{};if(window.PianoPageInfo)switch(e){case"cookies":window.PianoPageInfo.chapter1="gestion-cookies";break;case"privacy":window.PianoPageInfo.chapter1="politique-protection-donnees-personnelles";break;default:window.PianoPageInfo.chapter1=e}return{"s:page_type":"divers"}})();case e.LIVE:return(()=>{const e=c();return e["n:content_paragraphs_number"]=window.datalayerInfo?.livePosts??0,e})();case e.MOBILE_APPS:return d("divers","mobile");case e.MOST_COMMENTED:return d("most_commented");case e.MOST_READ:return d("most_read");case e.MOST_SHARED:return d("most_shared");case e.MOST_VIEWED:return d("home_tag");case e.MOVIES:return d("divers","entertainment","cinema");case e.NEWS:return d("divers","a-la-une");case e.TAG:return d("home_tag",window.datalayerInfo?.pageKey,"");case e.SITEMAP:return d("divers","plan-site");case e.SPORT:return(()=>{const{breadcrumb:e=[]}=window.datalayerInfo||{};return window.PianoPageInfo&&(window.PianoPageInfo.chapter1=e.shift(),window.PianoPageInfo.chapter2=e.shift(),window.PianoPageInfo.chapter3=e.shift(),window.PianoPageInfo.chapter4=e.shift()),{"s:page_type":"divers"}})();case e.STORY:return(()=>{const e=c();return e["s:content_subtype"]=window.datalayerInfo?.subType??"",e})();case e.SERVICE:return d("divers","pratique");case e.TRAFFIC:return d("infos_trafic");case e.TV_HOME:return d("home_tv","tv");case e.TV_LIVE:return d("home_tv_live","tv");case e.TV_MOST_RECENT:return d("tv_divers","tv","videos-recentes");case e.TV_MOST_VIEWED:return d("tv_divers","tv","videos-plus-vues");case e.TV_SHOW:return d("home_tv_show","tv",window.datalayerInfo?.pageKey);case e.TV_SHOWS:return d("tv_divers","tv","emissions");case e.TV_VIDEO:return(()=>{window.PianoPageInfo&&(window.PianoPageInfo.chapter1="tv");const e=c();return e.content_type="page",e["s:content_subtype"]="video",e})();case e.WEATHER:return d("previsions-meteo-france");default:return{}}};let l=-1;const m=e=>{addEventListener("pageshow",t=>{t.persisted&&(l=t.timeStamp,e(t))},!0)},_=(e,t,n,a)=>{let o,r;return i=>{t.value>=0&&(i||a)&&(r=t.value-(o??0),(r||void 0===o)&&(o=t.value,t.delta=r,t.rating=((e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good")(t.value,n),e(t)))}},g=e=>{requestAnimationFrame(()=>requestAnimationFrame(e))},h=()=>{const e=performance.getEntriesByType("navigation")[0];if(e&&e.responseStart>0&&e.responseStart<performance.now())return e},w=()=>h()?.activationStart??0,f=(e,t=-1)=>{const n=h();let a="navigate";return l>=0?a="back-forward-cache":n&&(document.prerendering||w()>0?a="prerender":document.wasDiscarded?a="restore":n.type&&(a=n.type.replace(/_/g,"-"))),{name:e,value:t,rating:"good",delta:0,entries:[],id:`v5-${Date.now()}-${Math.floor(8999999999999*Math.random())+1e12}`,navigationType:a}},v=new WeakMap;function E(e,t){let n=v.get(t);return n||(n=new WeakMap,v.set(t,n)),n.get(e)||n.set(e,new t),n.get(e)}class P{t;i=0;o=[];h(e){if(e.hadRecentInput)return;const t=this.o[0],n=this.o.at(-1);this.i&&t&&n&&e.startTime-n.startTime<1e3&&e.startTime-t.startTime<5e3?(this.i+=e.value,this.o.push(e)):(this.i=e.value,this.o=[e]),this.t?.(e)}}const I=(e,t,n={})=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const a=new PerformanceObserver(e=>{queueMicrotask(()=>{t(e.getEntries())})});return a.observe({type:e,buffered:!0,...n}),a}}catch{}},T=e=>{let t=!1;return()=>{t||(e(),t=!0)}};let y=-1;const b=new Set,S=()=>"hidden"!==document.visibilityState||document.prerendering?1/0:0,A=e=>{if("hidden"===document.visibilityState){if("visibilitychange"===e.type)for(const e of b)e();isFinite(y)||(y="visibilitychange"===e.type?e.timeStamp:0,removeEventListener("prerenderingchange",A,!0))}},O=()=>{if(y<0){const e=w(),t=document.prerendering?void 0:globalThis.performance.getEntriesByType("visibility-state").find(t=>"hidden"===t.name&&t.startTime>=e)?.startTime;y=t??S(),addEventListener("visibilitychange",A,!0),addEventListener("prerenderingchange",A,!0),m(()=>{setTimeout(()=>{y=S()})})}return{get firstHiddenTime(){return y},onHidden(e){b.add(e)}}},L=e=>{document.prerendering?addEventListener("prerenderingchange",e,!0):e()},C=[1800,3e3],M=(e,t={})=>{L(()=>{const n=O();let a,o=f("FCP");const r=I("paint",e=>{for(const t of e)"first-contentful-paint"===t.name&&(r.disconnect(),t.startTime<n.firstHiddenTime&&(o.value=Math.max(t.startTime-w(),0),o.entries.push(t),a(!0)))});r&&(a=_(e,o,C,t.reportAllChanges),m(n=>{o=f("FCP"),a=_(e,o,C,t.reportAllChanges),g(()=>{o.value=performance.now()-n.timeStamp,a(!0)})}))})},N=[.1,.25];let R=0,k=1/0,D=0;const H=e=>{for(const t of e)t.interactionId&&(k=Math.min(k,t.interactionId),D=Math.max(D,t.interactionId),R=D?(D-k)/7+1:0)};let V;const q=()=>V?R:performance.interactionCount??0;let G=0;class j{l=[];u=new Map;m;p;v(){G=q(),this.l.length=0,this.u.clear()}T(){const e=Math.min(this.l.length-1,Math.floor((q()-G)/50));return this.l[e]}h(e){if(this.m?.(e),!e.interactionId&&"first-input"!==e.entryType)return;const t=this.l.at(-1);let n=this.u.get(e.interactionId);if(n||this.l.length<10||e.duration>t.L){if(n?e.duration>n.L?(n.entries=[e],n.L=e.duration):e.duration===n.L&&e.startTime===n.entries[0].startTime&&n.entries.push(e):(n={id:e.interactionId,entries:[e],L:e.duration},this.u.set(n.id,n),this.l.push(n)),this.l.sort((e,t)=>t.L-e.L),this.l.length>10){const e=this.l.splice(10);for(const t of e)this.u.delete(t.id)}this.p?.(n)}}}const x=e=>{const t=globalThis.requestIdleCallback||setTimeout,n=globalThis.cancelIdleCallback||clearTimeout;if("hidden"===document.visibilityState)e();else{const a=T(e);let o=-1;const r=()=>{n(o),a()};addEventListener("visibilitychange",r,{once:!0,capture:!0}),o=t(()=>{removeEventListener("visibilitychange",r,{capture:!0}),a()})}},W=[200,500],B=(e,t={})=>{if(!globalThis.PerformanceEventTiming||!("interactionId"in PerformanceEventTiming.prototype))return;const n=O();L(()=>{"interactionCount"in performance||V||(V=I("event",H,{durationThreshold:0}));let a,o=f("INP");const r=E(t,j),i=e=>{x(()=>{for(const t of e)r.h(t);const t=r.T();t&&t.L!==o.value&&(o.value=t.L,o.entries=t.entries,a())})},s=I("event",i,{durationThreshold:t.durationThreshold??40});a=_(e,o,W,t.reportAllChanges),s&&(s.observe({type:"first-input",buffered:!0}),n.onHidden(()=>{i(s.takeRecords()),a(!0)}),m(()=>{r.v(),o=f("INP"),a=_(e,o,W,t.reportAllChanges)}))})};class U{m;h(e){this.m?.(e)}}const $=[2500,4e3],F=e=>{const t={click:n(e.name),click_chapter1:e?.chapter1||null,click_chapter2:e?.chapter2||null,click_chapter3:e?.chapter3||null},a=`click.${e.type}`;if(window.pa?(e.customProps&&Object.keys(e.customProps).length>0&&window.pa.setProperties(e.customProps,{persistent:!1,events:[a]}),window.pa.sendEvent(a,t)):window._paq&&(e.customProps&&Object.keys(e.customProps).length>0&&window._paq.push(["setProperties",e.customProps,{persistent:!1,events:[a]}]),window._paq.push(["sendEvent",a,t])),!window.edgee?.track)return;const o=document.getElementById("__EDGEE_DATA_LAYER__");let r={};if(o)try{const e=JSON.parse(o.textContent||"");e.data_collection.context=e.data_collection.context||{},r=e.data_collection.context.page?.properties||{}}catch{r={}}window.edgee.track({name:a,properties:{...r,click:t.click,click_chapter1:t.click_chapter1,click_chapter2:t.click_chapter2,click_chapter3:t.click_chapter3,click_type:e?.type??"navigation",...e.customProps}},{"edgee/piano-analytics":!0})},Y=e=>{window._paq&&window._paq.push(["sendEvent","page.display",{page:e?.name??window.PianoPageInfo?.name,page_chapter1:e?.chapter1??window.PianoPageInfo?.chapter1,page_chapter2:e?.chapter2??window.PianoPageInfo?.chapter2,page_chapter3:e?.chapter3??window.PianoPageInfo?.chapter3,page_chapter4:e?.chapter4??window.PianoPageInfo?.chapter4}]),window.edgee?.page&&!1!==e?.enableEdgee&&window.edgee.page()},K=()=>{if(!(100*Math.random()<=15))return;const e=new Set;((e,t={})=>{const n=O();M(T(()=>{let a,o=f("CLS",0);const r=E(t,P),i=e=>{for(const t of e)r.h(t);r.i>o.value&&(o.value=r.i,o.entries=r.o,a())},s=I("layout-shift",i);s&&(a=_(e,o,N,t.reportAllChanges),n.onHidden(()=>{i(s.takeRecords()),a(!0)}),m(()=>{r.i=0,o=f("CLS",0),a=_(e,o,N,t.reportAllChanges),g(a)}),setTimeout(a))}))})(t=>{e.add(t)}),B(t=>{e.add(t)}),((e,t={})=>{L(()=>{const n=O();let a,o=f("LCP");const r=E(t,U),i=e=>{t.reportAllChanges||(e=e.slice(-1));for(const t of e)r.h(t),t.startTime<n.firstHiddenTime&&(o.value=Math.max(t.startTime-w(),0),o.entries=[t],a())},s=I("largest-contentful-paint",i);if(s){a=_(e,o,$,t.reportAllChanges);const n=T(()=>{i(s.takeRecords()),s.disconnect(),a(!0)}),r=e=>{e.isTrusted&&(x(n),removeEventListener(e.type,r,{capture:!0}))};for(const e of["keydown","click","visibilitychange"])addEventListener(e,r,{capture:!0});m(n=>{o=f("LCP"),a=_(e,o,$,t.reportAllChanges),g(()=>{o.value=performance.now()-n.timeStamp,a(!0)})})}})})(t=>{e.add(t)});window.addEventListener("visibilitychange",()=>{"hidden"===document.visibilityState&&(()=>{if(0!==e.size){if(window._paq){const t={};e.forEach(e=>{const n=e.name.toLowerCase();t[`name_${n}`]=e.name,t[`value_${n}`]=e.value,t[`rating_${n}`]=e.rating,t[`delta_${n}`]=e.delta}),window._paq.push(["sendEvent","technique.cwv",t])}e.clear()}})()})},J=()=>{const e={};if(e["b:user_darkmode"]="dark"===document.documentElement.getAttribute("data-theme"),e["b:user_status"]=!!document.cookie.match("(^|;)\\s*20mnUserInfo\\s*=\\s*([^;]+)"),!e["b:user_status"])return e;const t=(e=>{const t=document.cookie.split(";").filter(t=>-1!==t.indexOf(e))[0];return t?t.split("=")[1]:"{}"})("20mnUserDataLayer"),n=t?(()=>{try{return JSON.parse(decodeURIComponent(t))}catch{return null}})():null;return n&&(e["s:user_id"]=String(n.i),Number.isNaN(n.d)||(e["n:user_a"]=Number(n.d)),Number.isNaN(n.l)||(e["n:user_zip"]=Number(n.l)),Number.isNaN(n.g)||(e["n:user_g"]=Number(n.g))),e};window.sendPageTracking=Y,window.sendClickTracking=F,window._paq=window._paq||[],window._paq.push(["privacy.include.properties",["content_type","s:page_type","d:content_published_date","d:content_modified_date","n:content_id","n:content_id_journaliste","s:content_tags","s:content_signature","s:content_title","n:content_title_characters_number","s:content_subtype","n:content_video_number","n:content_20min_video_number","n:content_embed_number","s:content_subtype","s:content_subtype","n:content_characters_number","n:content_paragraphs_number","s:content_source","s:misc_referrer","s:page_canonical","s:misc_search","s:site_level2","b:user_darkmode","b:user_status","navigation_method","cta_context","cta_destination","cta_engagement","cta_type","name_lcp","value_lcp","rating_lcp","delta_lcp","name_inp","value_inp","rating_inp","delta_inp","name_cls","value_cls","rating_cls","delta_cls"]]),window.PianoPageInfo={name:"",chapter1:"",chapter2:""},window._paq.push(["setProperties",{...u(),...p(),...J(),"s:site_level2":window.location.hostname},{persistent:!0,events:["page.*","click.*"]}]),Y({enableEdgee:!1}),K()}();
|
|
1
|
+
!function(){"use strict";var e=(e=>(e.ARCHIVE_BY_DAY="archivebyday",e.ARCHIVE_BY_YEAR="archivebyyear",e.ARTICLE="article",e.ASTRO="astro",e.ASTRO_HOME="astrohome",e.CONTACT="contact",e.DIRECT="direct",e.ELECTIONS="elections",e.ELECTIONSHOME="electionshome",e.GAME="game",e.GAME_APP="gameapp",e.GAMEHOME="gamehome",e.HOME="home",e.JOB_DETAILS="jobdetails",e.JOBS="jobs",e.JOURNALIST="journalist",e.LA21E="la21e",e.LEGAL="legal",e.LEGALNOTICE="legalnotice",e.LEGALNOTICEHOME="legalnoticehome",e.LEGALNOTICEDEPARTMENT="legalnoticedepartment",e.LIVE="live",e.MOBILE_APPS="mobileapps",e.MOST_COMMENTED="mostcommented",e.MOST_READ="mostread",e.MOST_SHARED="mostshared",e.MOST_VIEWED="mostviewed",e.MOVIES="movies",e.NEWS="news",e.PARTNER="partner",e.REWIND="rewind",e.SEARCH="search",e.SECTION="section",e.SERVICE="service",e.SITEMAP="sitemap",e.SPORT="sport",e.STORY="story",e.TAG="tag",e.TRAFFIC="traffic",e.TV_HOME="tvhome",e.TV_LIVE="tvlive",e.TV_MOST_RECENT="tvmostrecent",e.TV_MOST_VIEWED="tvmostviewed",e.TV_SHOW="tvshow",e.TV_SHOWS="tvshows",e.TV_VIDEO="tvvideo",e.WEATHER="weather",e))(e||{});class t extends Error{}t.prototype.name="InvalidTokenError";var n=(e=>(e.down="down",e.heart="heart",e.laughing="laughing",e.sad="sad",e.shock="shock",e.up="up",e))(n||{});n.up,n.down,n.sad,n.heart,n.laughing,n.shock;const a=(e,t)=>{let n=e.toLowerCase().replace(/[\s-]+/g,"-");return n=(e=>{let t=e;const n="ãàáäâẽèéëêìíïîõòóöôùúüûñç·/,:;";for(let e=0;e<30;e+=1)t=t.replace(new RegExp(n.charAt(e),"g"),"aaaaaeeeeeiiiiooooouuuunc-----".charAt(e));return t})(n),n.replace(/[^\w-]+/g,"").replace(/-*$/g,"")},o=()=>{const e=new URLSearchParams(window.location.search);return Object.fromEntries(e.entries())},r=["chapter1","chapter2","chapter3","chapter4"],i=()=>document.querySelectorAll(".c-content > p").length,s=()=>[...document.querySelectorAll(".c-content > p")].reduce((e,t)=>e+t.innerHTML.length,0),c=()=>{const e={},t=o();return("utm_source"in t||"utm_campaign"in t||"utm_medium"in t)&&("utm_source"in t||(e.utm_source=t.utm_medium??t.utm_campaign),"utm_campaign"in t||(e.utm_campaign=t.utm_source??t.utm_medium),"utm_medium"in t||(e.utm_medium=t.utm_source??t.utm_campaign)),e},d=()=>{const e=window.datalayerInfo,t={};e?.breadcrumb?.forEach((e,t)=>{let n=a(e);"diaporamas"===n&&(n="diaporama"),"actualite"===n&&(n="actu-generale"),"guide-dachat"===n&&(n="guide-achat");const o=r[t];o&&window.PianoPageInfo&&(window.PianoPageInfo[o]=n)});const n=Number(e?.contentId);Number.isFinite(n)&&(t["n:content_id"]=n),t.content_type=e?.pageName??"other",t["s:page_type"]="content",t["d:content_published_date"]=e?.modificationDate?new Date(e.modificationDate).toISOString():"",t["d:content_modified_date"]=e?.publicationDate?new Date(e.publicationDate).toISOString():"";const o=Number(e?.journalist?.id);return Number.isFinite(o)&&(t["n:content_id_journaliste"]=o),t["s:content_tags"]=e?.tagsSlug??"",t["s:content_signature"]=a(e?.signature??""),t["s:content_title"]=a(e?.contentTitle??""),t["n:content_title_characters_number"]=Number(e?.contentTitle?.length),t["s:content_subtype"]="texte",t["n:content_video_number"]=e?.videoCount??0,t["n:content_20min_video_number"]=e?.video20mnCount??0,t["n:content_embed_number"]=e?.embedCount??0,e?.podcastCount&&e?.podcastCount>0?t["s:content_subtype"]="podcast":t["n:content_video_number"]>0&&(t["s:content_subtype"]="video"),t},u=(e,t,n,a)=>(window.PianoPageInfo&&(t&&(window.PianoPageInfo.chapter1=t),n&&(window.PianoPageInfo.chapter2=n),a&&(window.PianoPageInfo.chapter3=a)),e?{"s:page_type":e}:{}),p=()=>{const e=window.datalayerInfo,t={};t["b:user_adblock"]=!window.adsapp,t.page_url=e?.pageUri??"",window.PianoPageInfo&&(window.PianoPageInfo.name=new URL(window.location.href).pathname,e?.pageUri&&(window.PianoPageInfo.name=new URL(e.pageUri).pathname)),e?.contentSource&&(t["s:content_source"]=e.contentSource),document.referrer&&(t["s:misc_referrer"]=document.referrer),t["s:page_type"]=e?.pageName||"other";const n=document.querySelector("link[rel='canonical']");if(n&&(t["s:page_canonical"]=n.getAttribute("href")??""),"/search"===e?.pageUri){const e=o();t["s:misc_search"]=e.q||""}return window.performance&&(t.navigation_method=window.performance.getEntriesByType?.("navigation")?.map(e=>e.type)?.pop()||null),{...t,...c()}},l=()=>{switch(window.datalayerInfo?.pageName||"other"){case e.ARCHIVE_BY_DAY:case e.ARCHIVE_BY_YEAR:return u("divers");case e.ARTICLE:return(()=>{const e=d();return e["n:content_characters_number"]=Number(s()),e["n:content_paragraphs_number"]=i(),e})();case e.ASTRO_HOME:return"numerology"===window.datalayerInfo?.pageKey?u("home_numerologie","services","numerologie"):u("home_horoscope","services","horoscope");case e.ASTRO:return["un","deux","trois","quatre","cinq","six","sept","huit","neuf"].includes(window.datalayerInfo?.pageKey||"")?u("numerologie","services","numerologie"):u("horoscope","services","horoscope");case e.DIRECT:return u("divers","le-direct");case e.ELECTIONS:case e.ELECTIONSHOME:return(()=>{const{national:e,region:t,department:n,constituency:a,town:o}=window.datalayerInfo?.elections||{};return window.PianoPageInfo&&(window.PianoPageInfo.chapter1="elections",window.PianoPageInfo.chapter2="resultats",o&&n?(window.PianoPageInfo.chapter3=n,window.PianoPageInfo.chapter4=o):a&&n?(window.PianoPageInfo.chapter3=n,window.PianoPageInfo.chapter4=a):n&&t?(window.PianoPageInfo.chapter3=t,window.PianoPageInfo.chapter4=n):t?(window.PianoPageInfo.chapter3="france",window.PianoPageInfo.chapter4=t):e&&(window.PianoPageInfo.chapter3=e)),{"s:page_type":"elections"}})();case e.HOME:return window.PianoPageInfo&&(window.PianoPageInfo.chapter1="accueil",window.PianoPageInfo.chapter2=""),{"s:page_type":"home","s:content_source":"20mn",content_type:null};case e.GAME:return u(void 0,"services","jeux",window.datalayerInfo?.pageKey);case e.GAME_APP:return(()=>{const e=d();return e["s:page_type"]="home_game",window.datalayerInfo?.pageKey&&(e["s:page_type"]="game"),e})();case e.GAMEHOME:return u("home_game","services","jeux");case e.JOB_DETAILS:return(()=>{const{pageKey:e,tagsSlug:t="",contentTitle:n="",embedCount:a=0,videoCount:o=0,video20mnCount:r=0}=window.datalayerInfo||{};return{"s:content_source":"labsense","s:page_type":"content",content_type:"card","s:content_tags":t,"s:content_signature":"","s:content_title":n,"s:content_subtype":"job","n:content_id":Number(e),"n:content_id_journaliste":0,"n:content_title_characters_number":Number(n.length),"n:content_video_number":o,"n:content_20min_video_number":r,"n:content_embed_number":a,"n:content_characters_number":Number(s()),"n:content_paragraphs_number":i(),"d:content_published_date":"","d:content_modified_date":""}})();case e.JOBS:return u("home_tag",window.datalayerInfo?.pageKey,"");case e.JOURNALIST:return(()=>{const{firstName:e,lastName:t}=window.datalayerInfo?.journalist||{};return e&&t&&window.PianoPageInfo&&(window.PianoPageInfo.chapter1=`journaliste--${e}-${t}`),{"s:page_type":"journalist"}})();case e.LA21E:return u("divers","focus--accueil");case e.LEGALNOTICE:return(()=>{const{contentTitle:e}=window.datalayerInfo||{};return e&&window.PianoPageInfo&&(window.PianoPageInfo.chapter1=`legal-announcement--${e}`),{"s:page_type":"legal_notice"}})();case e.LEGALNOTICEDEPARTMENT:return(()=>{const{contentTitle:e}=window.datalayerInfo||{};return window.PianoPageInfo&&(window.PianoPageInfo.chapter1=`legal-announcement-list--${e}`),{"s:page_type":"legal_notice_department"}})();case e.LEGALNOTICEHOME:return u("legal_notice_home","legal-announcement-list");case e.LEGAL:return(()=>{const{pageKey:e}=window.datalayerInfo||{};if(window.PianoPageInfo)switch(e){case"cookies":window.PianoPageInfo.chapter1="gestion-cookies";break;case"privacy":window.PianoPageInfo.chapter1="politique-protection-donnees-personnelles";break;default:window.PianoPageInfo.chapter1=e}return{"s:page_type":"divers"}})();case e.LIVE:return(()=>{const e=d();return e["n:content_paragraphs_number"]=window.datalayerInfo?.livePosts??0,e})();case e.MOBILE_APPS:return u("divers","mobile");case e.MOST_COMMENTED:return u("most_commented");case e.MOST_READ:return u("most_read");case e.MOST_SHARED:return u("most_shared");case e.MOST_VIEWED:return u("home_tag");case e.MOVIES:return u("divers","entertainment","cinema");case e.NEWS:return u("divers","a-la-une");case e.TAG:return u("home_tag",window.datalayerInfo?.pageKey,"");case e.SITEMAP:return u("divers","plan-site");case e.SPORT:return(()=>{const{breadcrumb:e=[]}=window.datalayerInfo||{};return window.PianoPageInfo&&(window.PianoPageInfo.chapter1=e.shift(),window.PianoPageInfo.chapter2=e.shift(),window.PianoPageInfo.chapter3=e.shift(),window.PianoPageInfo.chapter4=e.shift()),{"s:page_type":"divers"}})();case e.STORY:return(()=>{const e=d();return e["s:content_subtype"]=window.datalayerInfo?.subType??"",e})();case e.SERVICE:return u("divers","pratique");case e.TRAFFIC:return u("infos_trafic");case e.TV_HOME:return u("home_tv","tv");case e.TV_LIVE:return u("home_tv_live","tv");case e.TV_MOST_RECENT:return u("tv_divers","tv","videos-recentes");case e.TV_MOST_VIEWED:return u("tv_divers","tv","videos-plus-vues");case e.TV_SHOW:return u("home_tv_show","tv",window.datalayerInfo?.pageKey);case e.TV_SHOWS:return u("tv_divers","tv","emissions");case e.TV_VIDEO:return(()=>{window.PianoPageInfo&&(window.PianoPageInfo.chapter1="tv");const e=d();return e.content_type="page",e["s:content_subtype"]="video",e})();case e.WEATHER:return u("previsions-meteo-france");default:return{}}};let m=-1;const _=e=>{addEventListener("pageshow",t=>{t.persisted&&(m=t.timeStamp,e(t))},!0)},g=(e,t,n,a)=>{let o,r;return i=>{t.value>=0&&(i||a)&&(r=t.value-(o??0),(r||void 0===o)&&(o=t.value,t.delta=r,t.rating=((e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good")(t.value,n),e(t)))}},h=e=>{requestAnimationFrame(()=>requestAnimationFrame(e))},w=()=>{const e=performance.getEntriesByType("navigation")[0];if(e&&e.responseStart>0&&e.responseStart<performance.now())return e},f=()=>w()?.activationStart??0,v=(e,t=-1)=>{const n=w();let a="navigate";return m>=0?a="back-forward-cache":n&&(document.prerendering||f()>0?a="prerender":document.wasDiscarded?a="restore":n.type&&(a=n.type.replace(/_/g,"-"))),{name:e,value:t,rating:"good",delta:0,entries:[],id:`v5-${Date.now()}-${Math.floor(8999999999999*Math.random())+1e12}`,navigationType:a}},E=new WeakMap;function P(e,t){let n=E.get(t);return n||(n=new WeakMap,E.set(t,n)),n.get(e)||n.set(e,new t),n.get(e)}class I{t;i=0;o=[];h(e){if(e.hadRecentInput)return;const t=this.o[0],n=this.o.at(-1);this.i&&t&&n&&e.startTime-n.startTime<1e3&&e.startTime-t.startTime<5e3?(this.i+=e.value,this.o.push(e)):(this.i=e.value,this.o=[e]),this.t?.(e)}}const T=(e,t,n={})=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const a=new PerformanceObserver(e=>{queueMicrotask(()=>{t(e.getEntries())})});return a.observe({type:e,buffered:!0,...n}),a}}catch{}},y=e=>{let t=!1;return()=>{t||(e(),t=!0)}};let b=-1;const S=new Set,A=()=>"hidden"!==document.visibilityState||document.prerendering?1/0:0,O=e=>{if("hidden"===document.visibilityState){if("visibilitychange"===e.type)for(const e of S)e();isFinite(b)||(b="visibilitychange"===e.type?e.timeStamp:0,removeEventListener("prerenderingchange",O,!0))}},L=()=>{if(b<0){const e=f(),t=document.prerendering?void 0:globalThis.performance.getEntriesByType("visibility-state").find(t=>"hidden"===t.name&&t.startTime>=e)?.startTime;b=t??A(),addEventListener("visibilitychange",O,!0),addEventListener("prerenderingchange",O,!0),_(()=>{setTimeout(()=>{b=A()})})}return{get firstHiddenTime(){return b},onHidden(e){S.add(e)}}},C=e=>{document.prerendering?addEventListener("prerenderingchange",e,!0):e()},M=[1800,3e3],N=(e,t={})=>{C(()=>{const n=L();let a,o=v("FCP");const r=T("paint",e=>{for(const t of e)"first-contentful-paint"===t.name&&(r.disconnect(),t.startTime<n.firstHiddenTime&&(o.value=Math.max(t.startTime-f(),0),o.entries.push(t),a(!0)))});r&&(a=g(e,o,M,t.reportAllChanges),_(n=>{o=v("FCP"),a=g(e,o,M,t.reportAllChanges),h(()=>{o.value=performance.now()-n.timeStamp,a(!0)})}))})},k=[.1,.25];let R=0,D=1/0,H=0;const V=e=>{for(const t of e)t.interactionId&&(D=Math.min(D,t.interactionId),H=Math.max(H,t.interactionId),R=H?(H-D)/7+1:0)};let q;const G=()=>q?R:performance.interactionCount??0;let j=0;class x{l=[];u=new Map;m;p;v(){j=G(),this.l.length=0,this.u.clear()}T(){const e=Math.min(this.l.length-1,Math.floor((G()-j)/50));return this.l[e]}h(e){if(this.m?.(e),!e.interactionId&&"first-input"!==e.entryType)return;const t=this.l.at(-1);let n=this.u.get(e.interactionId);if(n||this.l.length<10||e.duration>t.L){if(n?e.duration>n.L?(n.entries=[e],n.L=e.duration):e.duration===n.L&&e.startTime===n.entries[0].startTime&&n.entries.push(e):(n={id:e.interactionId,entries:[e],L:e.duration},this.u.set(n.id,n),this.l.push(n)),this.l.sort((e,t)=>t.L-e.L),this.l.length>10){const e=this.l.splice(10);for(const t of e)this.u.delete(t.id)}this.p?.(n)}}}const W=e=>{const t=globalThis.requestIdleCallback||setTimeout,n=globalThis.cancelIdleCallback||clearTimeout;if("hidden"===document.visibilityState)e();else{const a=y(e);let o=-1;const r=()=>{n(o),a()};addEventListener("visibilitychange",r,{once:!0,capture:!0}),o=t(()=>{removeEventListener("visibilitychange",r,{capture:!0}),a()})}},B=[200,500],U=(e,t={})=>{if(!globalThis.PerformanceEventTiming||!("interactionId"in PerformanceEventTiming.prototype))return;const n=L();C(()=>{"interactionCount"in performance||q||(q=T("event",V,{durationThreshold:0}));let a,o=v("INP");const r=P(t,x),i=e=>{W(()=>{for(const t of e)r.h(t);const t=r.T();t&&t.L!==o.value&&(o.value=t.L,o.entries=t.entries,a())})},s=T("event",i,{durationThreshold:t.durationThreshold??40});a=g(e,o,B,t.reportAllChanges),s&&(s.observe({type:"first-input",buffered:!0}),n.onHidden(()=>{i(s.takeRecords()),a(!0)}),_(()=>{r.v(),o=v("INP"),a=g(e,o,B,t.reportAllChanges)}))})};class ${m;h(e){this.m?.(e)}}const F=[2500,4e3],Y=e=>{const t={click:a(e.name),click_chapter1:e?.chapter1||null,click_chapter2:e?.chapter2||null,click_chapter3:e?.chapter3||null},n=`click.${e.type}`;if(window.pa?(e.customProps&&Object.keys(e.customProps).length>0&&window.pa.setProperties(e.customProps,{persistent:!1,events:[n]}),window.pa.sendEvent(n,t)):window._paq&&(e.customProps&&Object.keys(e.customProps).length>0&&window._paq.push(["setProperties",e.customProps,{persistent:!1,events:[n]}]),window._paq.push(["sendEvent",n,t])),!window.edgee?.track)return;const o=document.getElementById("__EDGEE_DATA_LAYER__");let r={};if(o)try{const e=JSON.parse(o.textContent||"");e.data_collection.context=e.data_collection.context||{},r=e.data_collection.context.page?.properties||{}}catch{r={}}window.edgee.track({name:n,properties:{...r,click:t.click,click_chapter1:t.click_chapter1,click_chapter2:t.click_chapter2,click_chapter3:t.click_chapter3,click_type:e?.type??"navigation",...e.customProps}},{"edgee/piano-analytics":!0})},K=e=>{window._paq&&window._paq.push(["sendEvent","page.display",{page:e?.name??window.PianoPageInfo?.name,page_chapter1:e?.chapter1??window.PianoPageInfo?.chapter1,page_chapter2:e?.chapter2??window.PianoPageInfo?.chapter2,page_chapter3:e?.chapter3??window.PianoPageInfo?.chapter3,page_chapter4:e?.chapter4??window.PianoPageInfo?.chapter4}]),window.edgee?.page&&!1!==e?.enableEdgee&&window.edgee.page()},J=()=>{if(!(100*Math.random()<=15))return;const e=new Set;((e,t={})=>{const n=L();N(y(()=>{let a,o=v("CLS",0);const r=P(t,I),i=e=>{for(const t of e)r.h(t);r.i>o.value&&(o.value=r.i,o.entries=r.o,a())},s=T("layout-shift",i);s&&(a=g(e,o,k,t.reportAllChanges),n.onHidden(()=>{i(s.takeRecords()),a(!0)}),_(()=>{r.i=0,o=v("CLS",0),a=g(e,o,k,t.reportAllChanges),h(a)}),setTimeout(a))}))})(t=>{e.add(t)}),U(t=>{e.add(t)}),((e,t={})=>{C(()=>{const n=L();let a,o=v("LCP");const r=P(t,$),i=e=>{t.reportAllChanges||(e=e.slice(-1));for(const t of e)r.h(t),t.startTime<n.firstHiddenTime&&(o.value=Math.max(t.startTime-f(),0),o.entries=[t],a())},s=T("largest-contentful-paint",i);if(s){a=g(e,o,F,t.reportAllChanges);const n=y(()=>{i(s.takeRecords()),s.disconnect(),a(!0)}),r=e=>{e.isTrusted&&(W(n),removeEventListener(e.type,r,{capture:!0}))};for(const e of["keydown","click","visibilitychange"])addEventListener(e,r,{capture:!0});_(n=>{o=v("LCP"),a=g(e,o,F,t.reportAllChanges),h(()=>{o.value=performance.now()-n.timeStamp,a(!0)})})}})})(t=>{e.add(t)});window.addEventListener("visibilitychange",()=>{"hidden"===document.visibilityState&&(()=>{if(0!==e.size){if(window._paq){const t={};e.forEach(e=>{const n=e.name.toLowerCase();t[`name_${n}`]=e.name,t[`value_${n}`]=e.value,t[`rating_${n}`]=e.rating,t[`delta_${n}`]=e.delta}),window._paq.push(["sendEvent","technique.cwv",t])}e.clear()}})()})},z=()=>{const e={};if(e["b:user_darkmode"]="dark"===document.documentElement.getAttribute("data-theme"),e["b:user_status"]=!!document.cookie.match("(^|;)\\s*20mnUserInfo\\s*=\\s*([^;]+)"),!e["b:user_status"])return e;const t=(e=>{const t=document.cookie.split(";").filter(t=>-1!==t.indexOf(e))[0];return t?t.split("=")[1]:"{}"})("20mnUserDataLayer"),n=t?(()=>{try{return JSON.parse(decodeURIComponent(t))}catch{return null}})():null;return n&&(e["s:user_id"]=String(n.i),Number.isNaN(n.d)||(e["n:user_a"]=Number(n.d)),Number.isNaN(n.l)||(e["n:user_zip"]=Number(n.l)),Number.isNaN(n.g)||(e["n:user_g"]=Number(n.g))),e};window.sendPageTracking=K,window.sendClickTracking=Y,window._paq=window._paq||[],window._paq.push(["privacy.include.properties",["content_type","s:page_type","d:content_published_date","d:content_modified_date","n:content_id","n:content_id_journaliste","s:content_tags","s:content_signature","s:content_title","n:content_title_characters_number","s:content_subtype","n:content_video_number","n:content_20min_video_number","n:content_embed_number","s:content_subtype","s:content_subtype","n:content_characters_number","n:content_paragraphs_number","s:content_source","s:misc_referrer","s:page_canonical","s:misc_search","s:site_level2","b:user_darkmode","b:user_status","navigation_method","cta_context","cta_destination","cta_engagement","cta_type","name_lcp","value_lcp","rating_lcp","delta_lcp","name_inp","value_inp","rating_inp","delta_inp","name_cls","value_cls","rating_cls","delta_cls"]]),window.PianoPageInfo={name:"",chapter1:"",chapter2:""},window._paq.push(["setProperties",{...p(),...l(),...z(),"s:site_level2":window.location.hostname},{persistent:!0,events:["page.*","click.*"]}]),K({enableEdgee:!1}),J()}();
|
|
2
2
|
//# sourceMappingURL=piano.min.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
type PurposesKeys = 'Cookies' | 'CookiesAnalytics' | 'CookiesSocial' | 'AdvertisingPersonalization' | 'CookiesMarketing' | 'Analytics' | 'ContentPersonalization' | 'AdDelivery' | 'DeviceAccess' | 'OfflineMatch' | 'LinkDevices' | 'PreciseGeo' | 'SelectBasicAds' | 'CreateAdsProfile' | 'SelectPersonalizedAds' | 'CreateContentProfile' | 'SelectPersonalizedContent' | 'MeasureAdPerformance' | 'MeasureContentPerformance' | 'MarketResearch' | 'ImproveProducts' | 'mesureda-6qyqaZXC' | 'publicite-9qedKJMX' | 'activation-gGierZpp';
|
|
2
|
-
type PurposesValues = 'cookies' | 'cookies_analytics' | 'cookies_social' | 'advertising_personalization' | 'cookies_marketing' | 'analytics' | 'content_personalization' | 'ad_delivery' | 'device_access' | 'offline_match' | 'link_devices' | 'precise_geo' | 'select_basic_ads' | 'create_ads_profile' | 'select_personalized_ads' | 'create_content_profile' | 'select_personalized_content' | 'measure_ad_performance' | 'measure_content_performance' | 'market_research' | 'improve_products' | 'mesureda-6qyqaZXC' | 'publicite-9qedKJMX' | 'activation-gGierZpp';
|
|
1
|
+
type PurposesKeys = 'Cookies' | 'CookiesAnalytics' | 'CookiesSocial' | 'AdvertisingPersonalization' | 'CookiesMarketing' | 'Analytics' | 'ContentPersonalization' | 'AdDelivery' | 'DeviceAccess' | 'OfflineMatch' | 'LinkDevices' | 'PreciseGeo' | 'SelectBasicAds' | 'CreateAdsProfile' | 'SelectPersonalizedAds' | 'CreateContentProfile' | 'SelectPersonalizedContent' | 'MeasureAdPerformance' | 'MeasureContentPerformance' | 'MarketResearch' | 'ImproveProducts' | 'DeviceCharacteristics' | 'GeolocationData' | 'UseLimitedDataToSelectContent' | 'mesureda-6qyqaZXC' | 'publicite-9qedKJMX' | 'activation-gGierZpp' | 'attributio-nChbC4e9' | 'activation-bVrTKmmw';
|
|
2
|
+
type PurposesValues = 'cookies' | 'cookies_analytics' | 'cookies_social' | 'advertising_personalization' | 'cookies_marketing' | 'analytics' | 'content_personalization' | 'ad_delivery' | 'device_access' | 'offline_match' | 'link_devices' | 'precise_geo' | 'select_basic_ads' | 'create_ads_profile' | 'select_personalized_ads' | 'create_content_profile' | 'select_personalized_content' | 'measure_ad_performance' | 'measure_content_performance' | 'market_research' | 'improve_products' | 'device_characteristics' | 'geolocation_data' | 'use_limited_data_to_select_content' | 'mesureda-6qyqaZXC' | 'publicite-9qedKJMX' | 'activation-gGierZpp' | 'attributio-nChbC4e9' | 'activation-bVrTKmmw';
|
|
3
3
|
type PurposesList = Record<PurposesKeys, PurposesValues>;
|
|
4
4
|
export interface PurposeDefinition {
|
|
5
5
|
id: string;
|
|
@@ -79,6 +79,7 @@ interface EventListener {
|
|
|
79
79
|
export type DidomiEventListeners = EventListener[];
|
|
80
80
|
export interface CmpType {
|
|
81
81
|
consentEventsCount: number;
|
|
82
|
+
isRedirectingToSubscription: boolean;
|
|
82
83
|
}
|
|
83
84
|
export interface TcData {
|
|
84
85
|
eventStatus: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@20minutes/tyr",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.42.0",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+ssh://git@github.com/20minutes/tyr.git"
|
|
@@ -60,6 +60,7 @@
|
|
|
60
60
|
"html-entities": "^2.6.0",
|
|
61
61
|
"html-react-parser": "^6.1.3",
|
|
62
62
|
"html-to-react": "^1.7.0",
|
|
63
|
+
"jwt-decode": "^4.0.0",
|
|
63
64
|
"node-html-parser": "^7.1.0",
|
|
64
65
|
"react": "^18.3.1",
|
|
65
66
|
"react-dom": "^18.3.1",
|