1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["js/chunks/AuthModal-B-ic6S0L.js","js/chunks/react-CIdOxwLC.js","js/chunks/hydrateServerComponents-B9oKa6Kw.js","js/chunks/userPrefs-CmKfdyBa.js","css/hydrateServerComponents-D-xFXgU7.css","js/chunks/Alert-B-9FF1mB.js","css/Alert-XM4nDajw.css","js/chunks/TextInput-gxADkvDF.js","css/TextInput-B7FXM384.css","js/chunks/Divider-W54VxOKf.js","css/Divider-P5Te6d6g.css","js/chunks/feedRestoreBridge-MTsuutZe.js","js/chunks/relativeTime-C033wpEl.js","css/feedRestoreBridge-BM3in0iv.css","js/chunks/SearchField-DMuSubfb.js","css/SearchField-x30d16yW.css","js/chunks/Skeleton-JVIIi5Tu.js","css/Skeleton-DI9fr38N.css","js/chunks/Actualites-MA6YykHp.js","js/chunks/htmlText-DEssuVVd.js","js/chunks/dailymotionSdk-TpXrEajl.js","js/chunks/videoFeedTracking-CVAKQwFX.js","css/Actualites-BVNk7hG7.css","js/chunks/VideoFeed-Wxh7wL17.js","css/VideoFeed-Q71KunKW.css","js/chunks/NewsletterPage-DW93YGqc.js","js/chunks/NewsletterCard-kSQheRJs.js","css/NewsletterPage-DdRDKD0s.css","js/chunks/AccountPage-CH-AkqEJ.js","js/chunks/notificationPreferences-D8OUTzKO.js","js/chunks/platform-j5BDulKs.js","css/AccountPage-BZXc37rA.css","js/chunks/SearchResultsPage-DxKIHPtX.js","css/SearchResultsPage-C3vRV4aF.css"])))=>i.map(i=>d[i]); 2import{b3 as ct,I as B,i as dt,j as ut,r as $e,T as L,y as W,b4 as mt,e as Be,aJ as ft,b5 as pt,K as xt,b6 as ht,b7 as _t,b8 as gt,s as bt,g as _e,b9 as me,ba as jt,S as yt,bb as vt,Y as wt,bc as Nt,bd as ge,be as St,bf as Ct,bg as Et,bh as Me,bi as kt,bj as Tt,bk as It,bl as De,bm as Ft,m as Pt,c as At,bn as Rt,h as Lt,bo as Ot,bp as $t}from"./chunks/hydrateServerComponents-B9oKa6Kw.js";import{j as e,r as f,b as M}from"./chunks/react-CIdOxwLC.js";import{_ as q}from"./chunks/userPrefs-CmKfdyBa.js";import{A as Ve,a as ze,b as Bt,c as Mt}from"./chunks/Alert-B-9FF1mB.js";import{T as fe}from"./chunks/TextInput-gxADkvDF.js";import{D as pe}from"./chunks/Divider-W54VxOKf.js";import{T as Dt,a as Vt,b as be,f as zt,d as Ht,e as qt}from"./chunks/feedRestoreBridge-MTsuutZe.js";import{a as Gt,S as Ut}from"./chunks/SearchField-DMuSubfb.js";import{S as b}from"./chunks/Skeleton-JVIIi5Tu.js";import"./chunks/relativeTime-C033wpEl.js";function Wt(t){return t.reducedTransparency||t.saveData||t.cores<=2||t.deviceClass==="low"?"light":t.deviceClass==="medium"?"medium":"rich"}function Jt(){var s;if(typeof window>"u"||typeof navigator>"u")return"rich";const t=navigator,n=typeof window.matchMedia=="function"&&window.matchMedia("(prefers-reduced-transparency: reduce)").matches;return Wt({deviceClass:ct(),reducedTransparency:n,saveData:((s=t.connection)==null?void 0:s.saveData)===!0,cores:t.hardwareConcurrency??4})}function Yt(){typeof document>"u"||(document.documentElement.dataset.glassTier=Jt())}const Xt="benefits___DKkLi",Qt="benefitsNumerama___NWgCf",Zt="subtitle___A-BTz",Kt="list___ZbU9I",en="listItem___WcZY7",tn="featureTitle___FoEc9",nn="featureDescription___nr9j9",sn="headerContainer___iIcfo",rn="modalSubtitle___aHXwG",on="modalDe
2scription___tagyB",an="featureIcon___hfdgJ",ln="modalFeatureTitle___ELXsz",cn="modalFeatureDescription___mDEiN",dn="featuresContainer___a6VNw",un="featureRow___yfTI9",mn="featureTextContainer___QIFs5",fn="pageFeaturesContainer___DHK8j",pn="pageFeatureRow___yxC-i",xn="pageFeatureTextContainer___jnbOH",j={benefits:Xt,benefitsNumerama:Qt,subtitle:Zt,list:Kt,listItem:en,featureTitle:tn,featureDescription:nn,headerContainer:sn,modalSubtitle:rn,modalDescription:on,featureIcon:an,modalFeatureTitle:ln,modalFeatureDescription:cn,featuresContainer:dn,featureRow:un,featureTextContainer:mn,pageFeaturesContainer:fn,pageFeatureRow:pn,pageFeatureTextContainer:xn};function hn(){return typeof document<"u"&&document.body.dataset.site?document.body.dataset.site==="numerama":typeof window<"u"&&window.location.hostname.includes("numerama")}const Ho=({className:t,variant:n="modal"}={})=>hn()?e.jsx(He,{className:t}):e.jsx(qe,{className:t,variant:n}),He=({className:t}={})=>e.jsxs("div",{className:[j.benefitsNumerama,t].filter(Boolean).join(" "),children:[e.jsx("p",{className:j.subtitle,children:"Bénéficiez de nombreux avantages en devenant adhérent·e Numerama+"}),e.jsxs("ul",{className:j.list,children:[e.jsxs("li",{className:j.listItem,children:[e.jsx(B,{name:"megaphone-slash",size:36,variant:"solid",color:"primary"}),e.jsx("span",{children:"Suppression des publicités"})]}),e.jsxs("li",{className:j.listItem,children:[e.jsx(B,{name:"emoji",size:36,color:"primary"}),e.jsx("span",{children:"Accès au mode Zen"})]}),e.jsxs("li",{className:j.listItem,children:[e.jsx(B,{name:"email",size:36,color:"primary"}),e.jsx("span",{children:"Accès à la newsletter exclusive Toujours Plus"})]}),e.jsxs("li",{className:j.listItem,children:[e.jsx(B,{name:"plus",size:36,color:"primary"}),e.jsx("span",{children:"Et plus encore"})]})]})]}),qe=({titleId:t,descriptionId:n,className:s,variant:r="modal"}={})=>r==="page"?e.jsxs("div",{className:[j.benefits,s].filter(Boolean).join(" "),children:[e.jsx("p",{id:t,className:j.subtitle,children:"Soutenez un média de passionnés et profitez d'une expérience de lecture optimale."}),e.jsxs("div",{className:j.pageFeaturesContainer,children:[e.jsxs("div",{className:j.pageFeatureRow,children:[e.jsx(B,{name:"megaphone-slash",size:36,variant:"solid",color:"primary"}),e.jsxs("div",{className:j.pageFeatureTextContainer,children:[e.jsx("p",{className:j.featureTitle,children:"Navigation sans publicité"}),e.jsx("p",{className:j.featureDescription,children:"Profitez de tous nos tests, guides et actualités sans aucune interruption publicitaire."})]})]}),e.jsxs("div",{className:j.pageFeatureRow,children:[e.jsx(B,{name:"hand-heart",size:36,color:"primary"}),e.jsxs("div",{className:j.pageFeatureTextContainer,children:[e.jsx("p",{className:j.featureTitle,children:"Soutien à la rédaction"}),e.jsx("p",{className:j.featureDescription,children:"Permettez à notre équipe de continuer à produire des tests de qualité, des vidéos exclusives et des enquêtes indépendantes."})]})]})]})]}):e.jsxs("div",{className:[j.benefits,s].filter(Boolean).join(" "),children:[e.jsxs("div",{className:j.headerContainer,children:[e.jsx("p",{id:t,className:j.modalSubtitle,children:"Soutenez un média de passionnés"}),e.jsx("p",{id:n,className:j.modalDescription,children:"Profitez d'une expérience de lecture optimale"})]}),e.jsxs("div",{className:j.featuresContainer,children:[e.jsxs("div",{className:j.featureRow,children:[e.jsx("span",{className:j.featureIcon,children:e.jsx(B,{name:"megaphone-slash",size:44,variant:"solid",color:"white"})}),e.jsxs("div",{className:j.featureTextContainer,children:[e.jsx("p",{className:j.modalFeatureTitle,children:"Navigation sans publicité"}),e.jsx("p",{className:j.modalFeatureDescription,children:"Profitez de tous nos tests, guides et actualités sans aucune interruption publicitaire."})]})]}),e.jsxs("div",{className:j.featureRow,children:[e.jsx("span",{className:j.featureIcon,children:e.jsx(B,{name:"hand-heart",size:44,variant:"solid",color:"white"})}),e.jsxs("div",{className:j.featureTextContainer,children:[e.jsx("p",{className:j.modalFeatureTitle,children:"Soutien à la rédaction"}),e.jsx("p",{className:j.modalFeatureDescription,children:"Permettez à nos journalistes de continuer à produire des tests de qualité et des enquêtes indépendantes."})]})]})]})]});function _n({isOpen:t=!1,onClose:n,discoverLink:s="#",authLink:r="#",hideCloseButton:o=!1}){const a=f.useRef(null);return f.useEffect(()=>{const l=a.current;if(l)return t?(l.showModal(),document.documentElement.classList.add("no-scroll")):(l.close(),document.documentElement.classList.remove("no-scroll")),()=>{document.documentElement.classList.remove("no-scroll")}},[t]),f.useEffect(()=>{const l=a.current;if(!l)return;const i=p=>{p.key==="Escape"&&n&&n()},d=p=>{const u=l.getBoundingClientRect();(p.clientX<u.left||p.clientX>u.right||p.clientY<u.top||p.clientY>u.bottom)&&n&&n()};return t&&(document.addEventListener("keydown",i),l.addEventListener("click",d)),()=>{document.removeEventListener("keydown",i),l.removeEventListener("click",d)}},[t,n]),e.jsxs(e.Fragment,{children:[e.jsxs("dialog",{ref:a,className:"o-dialog o-premium-dialog",id:"premium-subscribe-modal","aria-modal":"true","aria-labelledby":"premium-subscribe-title",children:[!
2o&&e.jsx("button",{"aria-label":"Fermer la modale",autoFocus:!0,onClick:n,className:"o-dialog__close",children:e.jsx("span",{"aria-hidden":"true",className:"icon icon-plus"})}),e.jsx("div",{className:"justify-center align-center",children:e.jsx("p",{id:"premium-subscribe-title",className:"is-family-serif has-text-body is-size-card mb-3 has-text-centered px-5",children:"Fonction Numerama+"})}),e.jsxs("div",{className:"flex flex-col justify-center items-center",children:[e.jsx(He,{}),e.jsxs("a",{href:s,"data-gtm":s,className:"btn-premium btn-premium--primary",children:["Découvrir Numerama+ ",e.jsx("span",{"aria-hidden":"true",className:"icon icon-arrow-rotate"})]}),e.jsx("a",{href:r,className:"o-premium-auth-link",children:"Déjà abonné ? Connectez-vous"})]})]}),e.jsx("style",{children:` 3 /* --- BASE DIALOG (o-dialog) --- */ 4 .o-dialog { 5 --_o-dialog-inline-padding: 1rem; 6 --_o-dialog-top-padding: 1rem; 7 --_o-dialog-bottom-padding: 1rem; 8 9 overflow: hidden; 10 color: theme(colors.font.body); 11 background: theme(colors.background.page); 12 padding-inline: var(--_o-dialog-inline-padding); 13 padding-top: var(--_o-dialog-top-padding); 14 padding-bottom: var(--_o-dialog-bottom-padding); 15 } 16 17 .o-dialog[aria-modal="true"] { 18 border: 0; 19 max-height: 80vh; 20 width: 100vw; 21 max-width: none; 22 top: unset; 23 /* App mode: stand on the native tab bar, which covers the webview's 24 bottom edge. --app-bottom-inset only exists under body.is-app 25 (Header.integration.css); 0px keeps the web at the bottom edge. */ 26 bottom: var(--app-bottom-inset, 0px); 27 } 28 29 @media (min-width: 769px) { 30 .o-dialog[aria-modal="true"] { 31 top: revert; 32 width: var(--o-dialog-width, 37.5rem); 33 } 34 } 35 36 .o-dialog::backdrop { 37 background: var(--o-dialog-backdrop-background, rgb(0 0 0 / 40%)); 38 } 39 40 /* --- CLOSE BUTTON --- */ 41 .o-dialog__close { 42 background: transparent; 43 border: 0; 44 width: 3rem; 45 aspect-ratio: 1; 46 display: grid; 47 place-items: center; 48 position: absolute; 49 right: 1rem; 50 top: 1rem; 51 } 52 53 .o-dialog__close .icon-plus { 54 transform: rotate(45deg); 55 } 56 57 /* --- PREMIUM BORDER OVERRIDE --- */ 58 .o-premium-dialog[aria-modal="true"] { 59 border-bottom: .375rem solid var(--color-lemon); 60 border-left: .375rem solid var(--color-lemon); 61 border-top-left-radius: 20px; 62 border-top-right-radius: 20px; 63 } 64 65 @media (min-width: 769px) { 66 .o-premium-dialog[aria-modal="true"] { 67 border-radius: 8px; 68 } 69 } 70 71 /* --- PREMIUM CONTENT STYLES --- */ 72 .o-premium-reasons { 73 text-align: left; 74 font-size: 1.125rem; 75 font-weight: 650; 76 border-radius: 8px; 77 max-width: 22rem; 78 margin: 3rem 1rem; 79 } 80 81 .o-premium-reasons li { 82 display: flex; 83 align-items: center; 84 margin: 0; 85 position: relative; 86 width: 100%; 87 } 88 89 /* --- BACKGROUND GRAIN --- */ 90 .o-has-bg-premium-grain { 91 background-size: 800px 600px; 92 } 93 94 .o-premium-auth-link { 95 text-decoration: underline !important; 96 text-underline-offset: .3rem; 97 margin-top: 1.5rem !important; 98 } 99 `})]})}const gn="ctaButton___n5qk9",bn={ctaButton:gn},je="premium-teasing-title",ye="premium-teasing-description";function jn({isOpen:t=!1,onClose:n,discoverLink:s="/inscription",authLink:r="/connexion"}){return e.jsx(dt,{isOpen:t,onClose:n,titleId:je,descriptionId:ye,children:e.jsx(ut,{size:"large",children:e.jsxs("div",{className:"flex flex-col items-center gap-1200 py-1000 px-1200 lt-md:gap-600 lt-md:py-800 lt-md:px-800 lt-md:overflow-y-auto",children:[e.jsx(qe,{titleId:je,descriptionId:ye}),e.jsxs("div",{className:"flex flex-col items-center gap-300 w-full",children:[e.jsx("a",{href:s,className:`${bn.ctaButton} flex items-center justify-center w-full py-[0.5rem] px-400 text-button-text-button font-fontFamilySecondary font-semibold text-2xs leading-[1.5rem] rounded-default no-underline border-none cursor-pointer`,children:"Découvrir Frandroid+"}),e.jsxs("div",{className:"flex items-baseline gap-300 font-fontFamilySecondary font-semibold text-4xs leading-[1rem] tracking-[0.7px] text-font-body lt-md:justify-center",children:[e.jsx("span",{className:"lt-md:hidden",children:"Vous avez déjà un compte ?"}),e.jsx("a",{href:r,className:"text-font-body underline underline-offset-[0.1875rem]",children:"Se connecter"})]})]})]})})})}const yn=typeof window<"u"&&window.location.hostname.includes("numerama");function vn(){const[t,n]=f.useState(!1);f.useEffect(()=>{const r=()=>{n(!0)},o=a=>{a.target.closest("[data-premium-modal]")&&(a.preventDefault(),a.stopPropagation(),n(!0))};
99return window.addEventListener("openPremiumModal",r),document.addEventListener("click",o,!0),()=>{window.removeEventListener("openPremiumModal",r),document.removeEventListener("click",o,!0)}},[]);const s=()=>n(!1);return yn?e.jsx(_n,{isOpen:t,onClose:s,discoverLink:"/numeramaplus",authLink:"/connexion"}):e.jsx(jn,{isOpen:t,onClose:s})}const wn="subtitle___tth9U",oe={"auth-form":"auth-form___dAg3-","auth-form--loading":"auth-form--loading___53NfS",subtitle:wn},J=({title:t,subtitle:n,onSubmit:s,isLoading:r=!1,error:o,headingLevel:a=1,className:l,children:i})=>{const d=["w-full my-800",oe["auth-form"],r?oe["auth-form--loading"]:"",l].filter(Boolean).join(" "),p=["text-xs text-font-indicator mt-200 leading-body",oe.subtitle].filter(Boolean).join(" "),u=g=>{g.preventDefault(),!r&&s&&s(g)},c=`h${a}`;return e.jsxs("form",{className:d,onSubmit:u,noValidate:!0,children:[e.jsxs("header",{className:"mb-600 text-center",children:[e.jsx(c,{className:"text-xl font-heading font-fontFamilyPrimary leading-heading text-font-body m-0",children:t}),n&&e.jsx("p",{className:p,dangerouslySetInnerHTML:{__html:n}})]}),o&&e.jsx(Ve,{type:"error",closable:!1,className:"mb-400",children:e.jsx(ze,{children:o})}),e.jsx("div",{className:"flex flex-col gap-400",children:i})]})},Ge=({htmlFor:t,required:n=!1,optionalLabel:s="",disabled:r=!1,className:o,children:a,...l})=>{const i=["block font-fontFamilySecondary text-3xs font-semibold leading-label text-font-body",r&&"cursor-not-allowed",o].filter(Boolean).join(" ");return e.jsxs("label",{htmlFor:t,className:i,...l,children:[a,!n&&s&&e.jsxs("span",{className:"font-normal text-font-indicator",children:[" ",s]})]})},ve={"password-input-wrapper":"password-input-wrapper___tVE5D","password-input__toggle":"password-input__toggle___eAlNU"},Nn=({id:t,name:n,value:s,placeholder:r,disabled:o=!1,variant:a="default",showLockIcon:l=!0,glass:i,onChange:d,onBlur:p,className:u,...c})=>{const[g,h]=f.useState(!1),_=()=>{h(m=>!m)},w=["relative w-full",ve["password-input-wrapper"],u].filter(Boolean).join(" ");return e.jsxs("div",{className:w,children:[e.jsx(fe,{id:t,name:n,type:g?"text":"password",value:s,placeholder:r,disabled:o,variant:a,iconLeft:l?"lock":void 0,glass:i,onChange:d,onBlur:p,...c}),e.jsx("button",{type:"button",className:ve["password-input__toggle"],onClick:_,disabled:o,"aria-label":g?"Hide password":"Show password",children:e.jsx(B,{name:g?"eye":"eye-off",size:20,color:"inherit",ariaLabel:g?"Hide password":"Show password"})})]})},ae={"form-helper-text":"form-helper-text___R3g0d","form-helper-text--default":"form-helper-text--default___FcSgy","form-helper-text--error":"form-helper-text--error___ca5JT","form-helper-text--success":"form-helper-text--success___xr39L","form-helper-text--disabled":"form-helper-text--disabled___lyEn7"},Sn={default:"info",error:"alert-circle",success:"check"},Cn=({variant:t="default",disabled:n=!1,showIcon:s=!1,className:r,children:o,...a})=>{const l=["flex items-center gap-100 text-4xs font-semibold font-fontFamilySecondary",ae["form-helper-text"],ae[`form-helper-text--${t}`],n?ae["form-helper-text--disabled"]:"",r].filter(Boolean).join(" "),i=Sn[t],d=()=>e.jsx(B,{name:i,size:16,color:"inherit",className:"shrink-0"});return e.jsxs("span",{className:l,...a,children:[s&&i&&d(),o]})},G=({id:t,name:n,label:s,type:r="text",value:o,placeholder:a,disabled:l=!1,variant:i="default",required:d=!1,optionalLabel:p,helperText:u,iconLeft:c,iconRight:g,showLockIcon:h=!0,inline:_=!1,onChange:w,onBlur:m,className:x,...y})=>{const N=["flex w-full",_?"flex-row items-baseline gap-400":"flex-col gap-[0.375rem]",x].filter(Boolean).join(" "),S=["flex flex-col gap-[0.375rem]",_&&"flex-1 min-w-0"].filter(Boolean).join(" "),C=r==="password",F=i==="error"||i==="success"?i:"default";return e.jsxs("div",{className:N,children:[s&&e.jsx(Ge,{htmlFor:t,required:d,optionalLabel:p,disabled:l,className:_?"shrink-0 whitespace-nowrap":void 0,children:s}),e.jsxs("div",{className:S,children:[C?e.jsx(Nn,{id:t,name:n,value:o,placeholder:a,disabled:l,variant:i,showLockIcon:h,onChange:w,onBlur:m,...y}):e.jsx(fe,{id:t,name:n,type:r,value:o,placeholder:a,disabled:l,variant:i,iconLeft:c,iconRight:g,onChange:w,onBlur:m,...y}),u&&e.jsx(Cn,{variant:F,disabled:l,children:u})]})]})},we={"social-button":"social-button___jSf0k","social-button--disabled":"social-button--disabled___4gHMf"},En={google:{icon:"google",defaultText:"Google",iconColor:"none"}
99,apple:{icon:"apple",defaultText:"Apple",iconColor:"inherit"},x:{icon:"x-twitter",defaultText:"X",iconColor:"inherit"}},ie=({provider:t,href:n,disabled:s=!1,glass:r,className:o,children:a,...l})=>{const i=En[t],d=["flex items-center justify-center gap-200 w-full py-200 px-400 border-2 border-solid border-transparent rounded-default text-font-body font-fontFamilySecondary text-2xs font-bold leading-short no-underline cursor-pointer",we["social-button"],s?we["social-button--disabled"]:"",$e(r),o].filter(Boolean).join(" ");return e.jsxs("a",{className:d,href:s?void 0:n,onClick:s?p=>p.preventDefault():void 0,"aria-disabled":s?"true":void 0,tabIndex:s?-1:void 0,role:"button",...l,children:[e.jsx(B,{name:i.icon,size:20,color:i.iconColor,ariaLabel:`${t} icon`}),e.jsx("span",{className:"flex-none",children:a||i.defaultText})]})},xe=({googleAuthUrl:t,appleAuthUrl:n,xAuthUrl:s,disabled:r=!1,className:o})=>{const a=["flex gap-200 w-full [&>*]:flex-1 max-[375px]:flex-wrap max-[375px]:[&>*]:basis-full",o].filter(Boolean).join(" ");return e.jsxs("div",{className:a,children:[t&&e.jsx(ie,{provider:"google",href:t,disabled:r}),n&&e.jsx(ie,{provider:"apple",href:n,disabled:r}),s&&e.jsx(ie,{provider:"x",href:s,disabled:r})]})},Y=f.forwardRef(({siteKey:t,appearance:n="always",theme:s="auto",size:r="normal",language:o="auto",onVerify:a,onError:l,onExpire:i,className:d},p)=>{const u=f.useRef(null),c=f.useRef(null),g=f.useRef(a),h=f.useRef(l),_=f.useRef(i);g.current=a,h.current=l,_.current=i,f.useImperativeHandle(p,()=>({execute:()=>{c.current&&window.turnstile&&window.turnstile.execute(c.current)},reset:()=>{c.current&&window.turnstile&&window.turnstile.reset(c.current)},getResponse:()=>c.current&&window.turnstile?window.turnstile.getResponse(c.current):null}),[]),f.useEffect(()=>{if(!t||!u.current)return;const m=()=>{window.turnstile&&u.current&&!c.current&&(c.current=window.turnstile.render(u.current,{sitekey:t,callback:N=>{var S;return(S=g.current)==null?void 0:S.call(g,N)},"error-callback":()=>{var N;return(N=h.current)==null?void 0:N.call(h)},"expired-callback":()=>{var N;return(N=_.current)==null?void 0:N.call(_)},theme:s,size:r,language:o==="auto"?void 0:o,appearance:n}))};let x=null,y=null;if(window.turnstile)m();else if(document.querySelector('script[src*="challenges.cloudflare.com/turnstile"]'))x=setInterval(()=>{window.turnstile&&(x&&clearInterval(x),m())},50),y=setTimeout(()=>{x&&clearInterval(x)},1e4);else{const N=document.createElement("script");N.id="cf-turnstile-script",N.src="https://challenges.cloudflare.com/turnstile/v0/api.js?render=explicit",N.async=!0,N.defer=!0,N.onload=m,document.head.appendChild(N)}return()=>{x&&clearInterval(x),y&&clearTimeout(y),c.current&&window.turnstile&&(window.turnstile.remove(c.current),c.current=null)}},[t,n,s,r,o]);const w=["flex justify-center w-full",d].filter(Boolean).join(" ");return!t||t==="demo"?e.jsx("div",{className:w,children:e.jsxs("div",{className:"flex items-center gap-300 w-full max-w-[300px] min-h-[65px] py-300 px-400 bg-background-page border border-solid border-background-separator rounded-default box-border",children:[e.jsx("div",{className:"flex items-center justify-center shrink-0",children:e.jsxs("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:[e.jsx("circle",{cx:"12",cy:"12",r:"12",fill:"#22c55e"}),e.jsx("path",{d:"M7 12.5L10.5 16L17 9",stroke:"white",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]})}),e.jsxs("div",{className:"flex flex-col gap-[var(--hds-space-50)] flex-1 min-w-0",children:[e.jsx("span",{className:"font-fontFamilySecondary text-4xs font-medium text-font-body leading-body",children:"Captcha (démo)"}),e.jsxs("span",{className:"font-fontFamilySecondary text-5xs text-font-indicator",children:["Appearance: ",n]})]}),e.jsxs("div",{className:"flex flex-col items-end gap-[2px] shrink-0",children:[e.jsx("span",{className:"font-fontFamilySecondary text-[10px] font-bold text-font-body tracking-[0.5px]",children:"CLOUDFLARE"}),e.jsx("span",{className:"font-fontFamilySecondary text-[8px] text-font-item",children:"Confidentialité · Conditions"})]})]})}):e.jsx("div",{className:w,children:e.jsx("div",{ref:u,className:n==="execute"?"absolute overflow-hidden w-0 h-0":n==="interaction-only"?"":"min-h-[65px]"})})});Y.displayName="CloudflareCaptcha";
99const kn="link___8A-ez",Z={link:kn,"link--default":"link--default___AGIQV","link--underline":"link--underline___hy5id","link--subtle":"link--subtle___ZbSyY","link--primary":"link--primary___q4114","link--secondary":"link--secondary___D-eMb","link--inherit":"link--inherit___-H8ib","link--disabled":"link--disabled___3d0CO"},U=({href:t,variant:n="underline",color:s="primary",disabled:r=!1,external:o=!1,glass:a,className:l,children:i,...d})=>{const p=["cursor-pointer",Z.link,Z[`link--${n}`],Z[`link--${s}`],r?Z["link--disabled"]:"",$e(a),l].filter(Boolean).join(" "),u=o?{target:"_blank",rel:"noopener noreferrer"}:{};return e.jsx("a",{href:r?void 0:t,className:p,"aria-disabled":r?"true":void 0,tabIndex:r?-1:void 0,onClick:r?c=>c.preventDefault():void 0,...u,...d,children:i})},Tn="consent___uPwuy",Ne={consent:Tn,"consent-more":"consent-more___fK2--"},he=({text:t,summary:n,className:s})=>{if(!t)return null;const r=["mt-600 text-left text-5xs text-font-indicator",s??"leading-[0.875rem] font-fontFamilyTertiary max-w-[50.75rem]",Ne.consent].join(" ");return e.jsxs("div",{className:r,children:[e.jsx("p",{dangerouslySetInnerHTML:{__html:n??t}}),n&&e.jsxs("details",{className:Ne["consent-more"],children:[e.jsx("summary",{children:"En savoir plus"}),e.jsx("p",{dangerouslySetInnerHTML:{__html:t}})]})]})},In={"login-page":"login-page___wh3N-"},Fn=({googleAuthUrl:t,appleAuthUrl:n,xAuthUrl:s,onSubmit:r,forgotPasswordUrl:o,signupUrl:a,captchaSiteKey:l,captchaAppearance:i,isLoading:d=!1,error:p,consentText:u,consentSummary:c,onSwitchMode:g,headingLevel:h})=>{const[_,w]=f.useState(""),[m,x]=f.useState(""),[y,N]=f.useState(null),[S,C]=f.useState(null),F=t||n||s,D=()=>{if(!_.trim()){C("Veuillez saisir votre adresse email.");return}if(!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(_)){C("Veuillez saisir une adresse email valide.");return}C(null),r&&r({email:_,password:m,captchaToken:y})},I=E=>{N(E)},v=()=>{N(null)};return e.jsxs("div",{className:`flex flex-col items-center w-full p-600 ${In["login-page"]}`,children:[e.jsx(J,{title:"Se connecter en un clic",headingLevel:h,onSubmit:D,isLoading:d,error:S||p,children:e.jsxs("div",{className:"flex flex-col gap-600 items-center w-full",children:[F&&e.jsxs(e.Fragment,{children:[e.jsx(xe,{googleAuthUrl:t,appleAuthUrl:n,xAuthUrl:s,disabled:d}),e.jsx(pe,{text:"ou par email",color:"primary"})]}),e.jsxs("div",{className:"flex flex-col gap-700 items-center w-full",children:[e.jsxs("div",{className:"flex flex-col gap-400 w-full",children:[e.jsx(G,{id:"login-email",name:"email",label:"Email",type:"email",value:_,placeholder:"[email protected]",required:!0,disabled:d,onChange:E=>w(E.target.value)}),e.jsx(G,{id:"login-password",name:"password",label:"Mot de passe",type:"password",value:m,placeholder:"â¢â¢â¢â¢â¢â¢â¢â¢",required:!0,disabled:d,onChange:E=>x(E.target.value)}),o&&e.jsx(U,{href:o,variant:"default",color:"inherit",disabled:d,className:"self-start text-4xs font-semibold font-fontFamilyTertiary text-font-body tracking-[0.7px] underline leading-[1rem]",children:"Mot de passe oublié ?"})]}),l&&e.jsx(Y,{siteKey:l,appearance:i,onVerify:I,onError:v}),e.jsxs("div",{className:"flex flex-col gap-300 items-center w-full",children:[e.jsx(L,{type:"submit",variant:"contained",color:"primary",disabled:d,className:"w-full",children:d?"Connexion...":"Je me connecte"}),(g||a)&&e.jsxs("div",{className:"flex items-start gap-300 text-4xs font-semibold font-fontFamilyTertiary text-font-body tracking-[0.7px] leading-[1rem]",children:[e.jsx("span",{children:"Pas de compte ?"}),g?e.jsx(L,{as:"button",variant:"none",className:"underline",disabled:d,onClick:g,children:"Créer un compte"}):e.jsx(U,{href:a,variant:"underline",color:"inherit",disabled:d,children:"Créer un compte"})]})]})]})]})}),e.jsx(he,{text:u,summary:c})]})},Pn={"signup-page":"signup-page___FvnuD"},An=({googleAuthUrl:t,appleAuthUrl:n,xAuthUrl:s,onSubmit:r,loginUrl:o,captchaSiteKey:a,captchaAppearance:l,isLoading:i=!1,error:d,consentText:p,consentSummary:u,onSwitchMode:c,headingLevel:g})=>{const[h,_]=f.useState(""),[w,m]=f.useState(null),[x,y]=f.useState(null),N=t||n||s,S=I=>{_(I.target.value)},C=I=>{m(I)},F=()=>{m(null)},D=()=>
99{if(!h.trim()){y("Veuillez saisir votre adresse email.");return}if(!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(h)){y("Veuillez saisir une adresse email valide.");return}y(null),r&&r({email:h,captchaToken:w})};return e.jsxs("div",{className:`flex flex-col items-center w-full p-600 ${Pn["signup-page"]}`,children:[e.jsx(J,{title:"Créer un compte en un clic",headingLevel:g,onSubmit:D,isLoading:i,error:x||d,children:e.jsxs("div",{className:"flex flex-col gap-600 items-center w-full",children:[N&&e.jsxs(e.Fragment,{children:[e.jsx(xe,{googleAuthUrl:t,appleAuthUrl:n,xAuthUrl:s,disabled:i}),e.jsx(pe,{text:"ou par email",color:"primary"})]}),e.jsxs("div",{className:"flex flex-col gap-700 items-center w-full",children:[e.jsx("div",{className:"flex flex-col gap-400 w-full",children:e.jsx(G,{id:"signup-email",name:"email",type:"email",label:"Email",placeholder:"[email protected]",value:h,onChange:S,required:!0,disabled:i})}),e.jsx(Y,{siteKey:a,appearance:l,onVerify:C,onError:F}),e.jsxs("div",{className:"flex flex-col gap-300 items-center w-full",children:[e.jsx(L,{type:"submit",variant:"contained",color:"primary",disabled:i,className:"w-full",children:i?"Création...":"Je crée mon compte"}),e.jsxs("div",{className:"flex items-start gap-300 text-4xs font-semibold font-fontFamilyTertiary text-font-body tracking-[0.7px] leading-[1rem]",children:[e.jsx("span",{children:"Vous avez déjà un compte ?"}),c?e.jsx(L,{as:"button",variant:"none",className:"underline",onClick:c,children:"Se connecter"}):e.jsx(U,{href:o,variant:"underline",color:"inherit",children:"Se connecter"})]})]})]})]})}),e.jsx(he,{text:p,summary:u})]})},Rn=({onSubmit:t,loginUrl:n,captchaSiteKey:s,captchaAppearance:r,isLoading:o=!1,error:a,successMessage:l})=>{const[i,d]=f.useState(""),[p,u]=f.useState(null),[c,g]=f.useState(null),h=m=>{u(m)},_=()=>{u(null)},w=()=>
99{if(!i.trim()){g("Veuillez saisir votre adresse email.");return}if(!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(i)){g("Veuillez saisir une adresse email valide.");return}g(null),t&&t({email:i,captchaToken:p})};return l?e.jsx("div",{className:"flex flex-col items-center w-full p-600",children:e.jsxs("div",{className:"w-full max-w-[426px] py-800 px-600 text-center flex flex-col items-center gap-400",children:[e.jsx("h1",{className:"text-xl font-heading font-fontFamilyPrimary leading-heading text-font-body m-0",children:"Email envoyé"}),e.jsx("p",{className:"text-xs text-font-indicator m-0 leading-body",children:l}),e.jsx(U,{href:n,variant:"underline",color:"primary",children:"Retour à la connexion"})]})}):e.jsx("div",{className:"flex flex-col items-center w-full p-600 [&_[class*=auth-form\\_\\_header]]:text-left",children:e.jsxs(J,{title:"Mot de passe oublié",onSubmit:w,isLoading:o,error:c||a,children:[e.jsx(G,{id:"forgot-password-email",name:"email",type:"email",label:"Email",placeholder:"[email protected]",value:i,onChange:m=>d(m.target.value),required:!0,disabled:o}),e.jsx(Y,{siteKey:s,appearance:r,onVerify:h,onError:_}),e.jsx(L,{type:"submit",variant:"contained",color:"primary",disabled:o,className:"w-full",children:o?"Envoi...":"Générer un mot de passe"}),e.jsxs("div",{className:"text-center text-4xs font-semibold font-fontFamilySecondary tracking-[0.04375rem] text-font-body",children:["Vous avez déjà un compte ?"," ",e.jsx(U,{href:n,variant:"underline",color:"inherit",children:"Se connecter"})]})]})})},le={"password-strength__segment":"password-strength__segment___hCInH","password-strength__segment--weak":"password-strength__segment--weak___wO-gI","password-strength__segment--medium":"password-strength__segment--medium___42Lqf","password-strength__segment--good":"password-strength__segment--good___DcSlT","password-strength__segment--strong":"password-strength__segment--strong___aCfo7","password-strength__label--weak":"password-strength__label--weak___-i6D-","password-strength__label--medium":"password-strength__label--medium___5QEbp","password-strength__label--good":"password-strength__label--good___i4EGT","password-strength__label--strong":"password-strength__label--strong___kqnhu"},Ln=t=>{if(!t)return 0;if(t.length<6)return 1;const n=/[a-z]/.test(t),s=/[A-Z]/.test(t),r=/[0-9]/.test(t),o=/[^a-zA-Z0-9]/.test(t),a=[n,s,r,o].filter(Boolean).length;return t.length>=10&&a>=3?4:t.length>=8&&a>=2?3:2},On={1:{label:"Faible",className:"weak"},2:{label:"Moyen",className:"medium"},3:{label:"Bon",className:"good"},4:{label:"Fort",className:"strong"}},$n=async(t,n,s)=>(await fetch("/wp-json/humanoid/v1/account/password-strength",{method:"POST",headers:{"Content-Type":"application/json","X-WP-Nonce":n},body:JSON.stringify({password:t}),signal:s})).json(),Bn=({password:t,restNonce:n})=>{const s=Ln(t||""),[r,o]=f.useState(!1),[a,l]=f.useState(null);if(f.useEffect(()=>{if(o(!1),l(null),!n||!t||s<3)return;const u=new AbortController,c=setTimeout(()=>{$n(t,n,u.signal).then(g=>{g.valid||(o(!0),l(g.error||null))}).catch(()=>{})},300);return()=>{clearTimeout(c),u.abort()}},[t,n,s]),s===0)return null;const i=r?1:s,{label:d,className:p}=r?{label:a||"Faible",className:"weak"}:On[i];return e.jsxs("div",{className:"flex flex-col gap-100","aria-hidden":"true",children:[e.jsx("div",{className:"flex gap-100",children:[1,2,3,4].map(u=>e.jsx("div",{className:[le["password-strength__segment"],u<=i?le[`password-strength__segment--${p}`]:""].filter(Boolean).join(" ")},u))}),e.jsx("span",{className:["text-5xs font-fontFamilySecondary",le[`password-strength__label--${p}`]].join(" "),children:d})]})},Mn=({password:t,confirmPassword:n,onPasswordChange:s,onConfirmPasswordChange:r,passwordName:o="password",confirmPasswordName:a="confirmPassword",idPrefix:l="new-password",disabled:i=!1,restNonce:d})=>{const p=n.length>0&&t!==n;return e.jsxs("div",{className:"flex flex-col gap-400",children:[e.jsx(G,{id:`${l}`,name:o,type:"password",label:"Nouveau mot de passe",placeholder:"â¢â¢â¢â¢â¢â¢â¢â¢",autoComplete:"new-password",value:t,onChange:u=>s(u.target.value),required:!0,disabled:i}
99),e.jsx(Bn,{password:t,restNonce:d}),e.jsx(G,{id:`${l}-confirm`,name:a,type:"password",label:"Confirmer le nouveau mot de passe",placeholder:"â¢â¢â¢â¢â¢â¢â¢â¢",autoComplete:"new-password",value:n,onChange:u=>r(u.target.value),required:!0,disabled:i,variant:p?"error":"default",helperText:p?"Les mots de passe ne correspondent pas":void 0})]})},Dn="footer___e783W",Se={"reset-password-page":"reset-password-page___M0Ksk",footer:Dn},Vn=({onSubmit:t,loginUrl:n,subtitle:s=`Choisissez un mot de passe fort ! On vous conseille 10 caractères minimums et 4 mots du quotidien collés les uns aux autres : difficile à craquer, facile à retenir, <a href="#">c'est la meilleure méthode</a> !`,isLoading:r=!1,error:o,rpLogin:a="",rpKey:l=""})=>{const[i,d]=f.useState(""),[p,u]=f.useState(""),[c,g]=f.useState(null),h=()=>{if(i!==p){g("Les mots de passe ne correspondent pas.");return}g(null),t&&t({password:i,confirmPassword:p,login:a,key:l})},_=["flex flex-col items-center w-full p-600",Se["reset-password-page"]].filter(Boolean).join(" "),w=["text-center text-4xs font-semibold font-fontFamilySecondary text-font-body",Se.footer].filter(Boolean).join(" ");return e.jsx("div",{className:_,children:e.jsxs(J,{title:"Créer un nouveau mot de passe",subtitle:s,onSubmit:h,isLoading:r,error:c||o,children:[e.jsx(Mn,{password:i,confirmPassword:p,onPasswordChange:d,onConfirmPasswordChange:u,idPrefix:"reset-password",disabled:r}),e.jsx(L,{type:"submit",variant:"contained",color:"primary",disabled:r,className:"w-full",children:r?"Enregistrement...":"Enregistrer le mot de passe"}),e.jsxs("div",{className:w,children:["Vous avez déjà un compte ?"," ",e.jsx(U,{href:n,variant:"underline",color:"inherit",children:"Se connecter"})]})]})})},zn=({title:t="Vérifiez vos mails",content:n=e.jsxs(e.Fragment,{children:["Vérifiez vos mails pour le lien de confirmation puis rendez-vous sur la"," ",e.jsx("a",{href:"/connexion",children:"page de connexion"}),"."]}),headingLevel:s=1})=>{const r=`h${s}`;return e.jsx("div",{className:"flex flex-col items-center w-full p-600",children:e.jsxs("div",{className:"w-full max-w-[426px] flex flex-col gap-400 text-center",children:[e.jsx(r,{className:"text-xl font-heading font-fontFamilyPrimary leading-heading text-font-body m-0",children:t}),e.jsx("div",{className:"text-xs text-font-indicator m-0 leading-body font-fontFamilySecondary [&_a]:text-font-indicator [&_a]:underline [&_a:hover]:text-font-body",children:n})]})})},P={"subscription-box":"subscription-box___zeena","subscription-box__logo":"subscription-box__logo___3TtW1","subscription-box__pricing":"subscription-box__pricing___BUO06","subscription-box__price":"subscription-box__price___yuewO","subscription-box__subprice":"subscription-box__subprice___zsZwO","subscription-box__subprice-striked":"subscription-box__subprice-striked___rlBbe","subscription-box__gift-code":"subscription-box__gift-code___8rMyN","subscription-box__benefit":"subscription-box__benefit___ZRtrw","subscription-box__more-link":"subscription-box__more-link___Ait--"},Hn=[],qn=({logoSrc:t,logoAlt:n="Logo",logoName:s,logoVariant:r="default",price:o,priceUnit:a="/an",subPrice:l,benefits:i=Hn,moreLink:d,moreLinkLabel:p="Voir plus",giftCode:u,giftDiscount:c,className:g})=>{const h=u&&(c==null?void 0:c.percent_off)===100,_=u&&(c==null?void 0:c.percent_off)&&c.percent_off>0&&c.percent_off<100,w=()=>{if(!_||!(c!=null&&c.percent_off))return null;const S=parseFloat(o.replace(/[^\d,]/g,"").replace(",","."));return isNaN(S)?null:(S*(1-c.percent_off/100)).toFixed(2).replace(".",",")+" â¬"},m=()=>!_||!(c!=null&&c.percent_off)?null:`-${c.percent_off}%`,x=w(),y=m(),N=["gap-400 rounded-default w-full",P["subscription-box"],g].filter(Boolean).join(" ");return e.jsxs("div",{className:N,children:[e.jsxs("div",{className:"flex flex-col gap-200 justify-center",children:[s?e.jsx(W,{name:s,variant:r,height:14,className:["w-auto overflow-hidden",P["subscription-box__logo"]].join(" ")}):t?e.jsx("img",{src:t,alt:n,className:["w-auto overflow-hidden",P["subscription-box__logo"]].join(" ")}):null,e.jsx("div",{className:["flex flex-col",P["subscription-box__pricing"]].join(" "),children:h?e.jsxs(e.Fragment,{children:[e.jsx("span",{className:["font-fontFamilyPrimary text-xs font-bold text-font-body",P["subscription-box__price"]].join(" "),children:"Offert"}),e.jsxs("span",{className:["font-fontFamilySecondary text-4xs font-normal text-font-indicator line-through",P["subscription-box__subprice-striked"]].join(" "),children:[o," ",a]})]}):_&&x?e.jsxs(e.Fragment,{children:[e.jsxs("span",{className:["font-fontFamilyPrimary text-xs font-bold text-font-body",P["subscription-box__price"]].join(" "),children:[x," ",a]}),e.jsxs("span",{className:["font-fontFamilySecondary text-4xs font-normal text-font-indicator line-through",P["subscription-box__subprice-striked"]].join(" "),children:[o," ",a]})]}):e.jsxs(e.Fragment,{children:[e.jsxs("span",{className:["font-fontFamilyPrimary text-xs font-bold text-font-body",P["subscription-box__price"]].join(" "),children:[o," ",a]}),l&&e.jsx("span",{className:["font-fontFamilySecondary text-4xs font-normal text-font-body",P["subscription-box__subprice"]].join(" "),children:l})]})}),h&&e.jsx("span",{className:["font-fontFamilySecondary text-4xs font-semibold text-primary bg-transparency-primary-10 rounded-default p-100 px-300 text-center",P["subscription-box__gift-code"]].join(" "),children:"Code
99cadeau appliqué"}),y&&e.jsxs("span",{className:["font-fontFamilySecondary text-4xs font-semibold text-primary bg-transparency-primary-10 rounded-default p-100 px-300 text-center",P["subscription-box__gift-code"]].join(" "),children:[y," appliqué"]}),d&&e.jsx(U,{href:d,variant:"underline",className:["font-fontFamilySecondary text-4xs font-semibold text-font-body",P["subscription-box__more-link"]].join(" "),children:p})]}),i.length>0&&e.jsx("ul",{className:"flex flex-col justify-center list-disc pl-500 m-0",children:i.map((S,C)=>e.jsx("li",{className:["font-fontFamilySecondary text-4xs font-normal text-font-body",P["subscription-box__benefit"]].join(" "),children:S},C))})]})},Ce={"signup-subscription-page":"signup-subscription-page___49Z7H","forgot-password":"forgot-password___uflqa"},Ee="signup",ke="login",Te={numerama:["Zéro pub, zéro distraction.","Exclusivités et expérience sur-mesure.","Soutenez un média tech exigeant."],frandroid:["Navigation 100 % sans pub sur le web","Des tests indépendants et des vidéos de qualité","Soutenez la passion de la Tech"]},Gn=({site:t="numerama",subscriptionPrice:n="39,90 â¬",subscriptionPriceUnit:s="/an",subscriptionSubPrice:r="soit 3,30 â¬/mois",subscriptionBenefits:o,subscriptionMoreLink:a,subscriptionMoreLinkLabel:l="Voir plus",googleAuthUrl:i,appleAuthUrl:d,xAuthUrl:p,onSubmit:u,onTabChange:c,forgotPasswordUrl:g,captchaSiteKey:h,isLoading:_=!1,error:w,initialTab:m=Ee,giftCode:x=null,giftDiscount:y=null,consentText:N,consentSummary:S,consentSummaryLogin:C})=>{const[F,D]=f.useState(m),[I,v]=f.useState(""),[E,V]=f.useState(""),[se,re]=f.useState(null),[Ze,X]=f.useState(null),Ke=i||d||p,Q=F===ke,et=t==="numerama",tt=o??Te[t]??Te.numerama,nt=O=>{D(O),v(""),V(""),re(null),X(null),c&&c(O)},st=O=>{re(O)},rt=()=>{re(null)},ot=O=>{if(!I.trim()){X("Veuillez saisir votre adresse email.");return}if(!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(I)){X("Veuillez saisir une adresse email valide.");return}X(null),u&&u({mode:F,email:I,password:E,captchaToken:se})},at=()=>_?Q?"Connexion...":"Création...":Q?"Je me connecte":"Créer mon compte et payer",it=["flex flex-col items-center w-full",Ce["signup-subscription-page"],et?"has-premium-theme":""].filter(Boolean).join(" "),lt=["self-start text-4xs font-semibold font-fontFamilySecondary text-font-body",Ce["forgot-password"]].filter(Boolean).join(" ");return e.jsxs("div",{className:it,children:[e.jsxs(J,{title:"Je m'abonne",onSubmit:ot,isLoading:_,error:Ze||w,children:[e.jsx(qn,{logoName:t,logoVariant:"plus",price:n,priceUnit:s,subPrice:r,benefits:tt,moreLink:a,moreLinkLabel:l,giftCode:x,giftDiscount:y}),e.jsx(Dt,{value:F,onValueChange:O=>nt(O),corners:"default",animation:"bounce",className:"justify-items-center pt-600 pb-150",children:e.jsxs(Vt,{children:[e.jsx(be,{value:Ee,disabled:_,children:"Créer mon compte"}),e.jsx(be,{value:ke,disabled:_,children:"Me connecter"})]})}),e.jsxs("div",{className:"flex flex-col gap-300 w-full",children:[e.jsx("h2",{className:"font-fontFamilyPrimary text-s font-bold leading-heading text-font-body m-0",children:"En un clic"}),Ke&&e.jsxs(e.Fragment,{children:[e.jsx(xe,{googleAuthUrl:i,appleAuthUrl:d,xAuthUrl:p,disabled:_}),e.jsx(pe,{text:"ou par email",color:"primary"})]})]}),e.jsx(G,{id:"auth-email",name:"email",type:"email",label:"Email",placeholder:"[email protected]",value:I,onChange:O=>v(O.target.value),required:!0,disabled:_}),Q&&e.jsxs(e.Fragment,{children:[e.jsx(G,{id:"auth-password",name:"password",type:"password",label:"Mot de passe",placeholder:"â¢â¢â¢â¢â¢â¢â¢â¢",value:E,onChange:O=>V(O.target.value),required:!0,disabled:_}),g&&e.jsx(U,{href:g,variant:"default",color:"inherit",disabled:_,className:lt,children:"Mot de passe oublié ?"})]}),e.jsx(Y,{siteKey:h,onVerify:st,onError:rt}),e.jsx(L,{type:"submit",variant:"contained",color:"primary",disabled:_,className:"w-full",children:at()})]}),e.jsx(he,{text:N,summary:Q?C:S,className:"leading-body font-fontFamilySecondary max-w-[50.75rem]"})]})},Un={frandroid:"Frandroid",numerama:"Numerama"},Ue=({siteName:t="frandroid",onSubmit:n,isLoading:s=!1,error:r=null})=>{const[o,a]=f.useState(""),l=d=>{d.preventDefault(),n&&o.trim()&&n({giftCode:o.trim()})},i=Un[t]||t;return e.jsx("div",{className:"flex flex-col items-center w-full p-600",children:e.jsxs("form",{className:"w-full max-w-[26rem] flex flex-col items-center gap-1200",onSubmit:l,children:[e.jsx(W,{name:t,variant:"plus",height:28}),e.jsxs("h1",{className:"text-xl font-heading font-fontFamilyPrimary leading-heading text-font-body text-center m-0",children:["On vous a offert une adhésion à ",i,"+"]}),e.jsxs("div",{className:"flex flex-col items-center gap-600 w-full max-w-[20.75rem]",children:[e.jsxs("div",{className:"flex flex-col gap-[var(--hds-s
99pace-150)] w-full",children:[e.jsx(Ge,{htmlFor:"gift-code",children:"Insérez votre code cadeau"}),e.jsx(fe,{id:"gift-code",name:"giftCode",placeholder:"Code cadeau",value:o,onChange:d=>a(d.target.value),variant:r?"error":"default",disabled:s})]}),r&&e.jsx("p",{className:"text-system-error text-3xs font-fontFamilySecondary m-0",children:r}),e.jsx(L,{as:"button",type:"submit",color:"primary",variant:"contained",className:"w-full",disabled:s||!o.trim(),children:s?"Validation...":"Valider"})]})]})})},Wn=({siteName:t="frandroid",advantagesUrl:n="/"})=>e.jsx("div",{className:"flex flex-col items-center w-full p-600",children:e.jsxs("div",{className:"w-full max-w-[30rem] flex flex-col items-center gap-1200",children:[e.jsx(W,{name:t,variant:"plus",height:28}),e.jsxs("div",{className:"flex flex-col items-center gap-300 text-center text-font-body",children:[e.jsx("h1",{className:"text-xl font-heading font-fontFamilyPrimary leading-heading m-0",children:"Bienvenue !"}),e.jsx("p",{className:"text-2xs font-normal font-fontFamilySecondary leading-body m-0",children:"Vous avez reçu un mail de confirmation pour terminer la configuration de votre compte."})]}),e.jsx(L,{as:"a",href:n,color:"primary",variant:"contained",children:"Découvrir mes avantages"})]})}),Jn=({siteName:t="frandroid",redirectUrl:n="/"})=>e.jsx("div",{className:"flex flex-col items-center w-full p-600",children:e.jsxs("div",{className:"w-full max-w-[30rem] flex flex-col items-center gap-1200",children:[e.jsx(W,{name:t,variant:"plus",height:28}),e.jsxs("div",{className:"flex flex-col items-center gap-300 text-center text-font-body",children:[e.jsx("h1",{className:"text-xl font-heading font-fontFamilyPrimary leading-heading m-0",children:"Merci pour votre cadeau !"}),e.jsx("p",{className:"text-2xs font-normal font-fontFamilySecondary leading-body m-0",children:"Vous avez reçu un mail de confirmation et votre destinataire a reçu son cadeau."})]}),e.jsx(L,{as:"a",href:n,color:"primary",variant:"contained",children:"Retourner sur le site"})]})}),Yn=({siteName:t="frandroid",title:n="Oups",message:s="Une erreur est survenue. Veuillez réessayer plus tard.",contactUrl:r,buttonLabel:o="Retourner sur le site",buttonUrl:a="/"})=>e.jsx("div",{className:"flex flex-col items-center w-full p-600",children:e.jsxs("div",{className:"w-full max-w-[30rem] flex flex-col items-center gap-1200",children:[e.jsx(W,{name:t,variant:"plus",height:28}),e.jsxs("div",{className:"flex flex-col items-center gap-300 text-center text-font-body",children:[e.jsx("h1",{className:"text-xl font-heading font-fontFamilyPrimary leading-heading m-0",children:n}),e.jsx("p",{className:"text-2xs font-normal font-fontFamilySecondary leading-body m-0",children:s}),r&&e.jsxs("p",{className:"text-2xs font-normal font-fontFamilySecondary leading-body m-0",children:["Si le problème persiste, ",e.jsx("a",{href:r,children:"contactez l'équipe technique."})]})]}),e.jsx(L,{as:"a",href:a,color:"primary",variant:"contained",children:o})]})}),Xn="container___xZ6bq",Qn="wrapper___6-M32",Zn="bottomRight___GzOJY",Kn="bottomCenter___l7FUQ",es="bottomLeft___PiRll",ts="expanded___DVnHE",ns="topRight___eySve",ss="topCenter___R0KvQ",rs="topLeft___tx13b",os="enter___7BuDj",as="exit___3B2nQ",$={container:Xn,wrapper:Qn,bottomRight:Zn,bottomCenter:Kn,bottomLeft:es,expanded:ts,topRight:ns,topCenter:ss,topLeft:rs,enter:os,exit:as},is={"top-left":$.topLeft,"top-center":$.topCenter,"top-right":$.topRight,"bottom-left":$.bottomLeft,"bottom-center":$.bottomCenter,"bottom-right":$.bottomRight},ls=300,cs=200,ds=({position:t="bottom-right"})=>{const n=mt(),[s,r]=f.useState(new Set),[o,a]=f.useState(!1),l=f.useRef(null),i=f.useRef(new Set),d=f.useCallback(h=>{r(w=>new Set(w).add(h));const _=setTimeout(()=>{i.current.delete(_),r(w=>{const m=new Set(w);return m.delete(h),m}),Be.dismiss(h)},ls);i.current.add(_)},[]),p=f.useCallback(()=>{l.current&&(clearTimeout(l.current),l.current=null),a(!0)},[]),u=f.useCallback(()=>{l.current&&clearTimeout(l.current),l.current=setTimeout(()=>a(!1),cs)},[]);f.useEffect(()=>()=>{l.current&&clearTimeout(l.current),i.current.forEach(clearTimeout),i.current.clear()},[]);const c=f.useCallback(h=>{h==null||h.focus()},[]),g=is[t];return e.jsx("div",{className:`${$.container} ${g} ${o?$.expanded:""}`,role:"region","aria-label":"Notifications",onMouseEnter:p,onMouseLeave:u,children:n.map((h,_)=>e.jsx("div",{className:`${$.wrapper} ${s.has(h.id)?$.exit:$.enter}`,style:{"--index":n.length-1-_,"--z":_+1},onMouseEnter:p,onMouseLeave:u,children:e.jsxs(Ve,{type:h.type,ephemeral:!0,duration:h.duration,onClose:()=>d(h.id),children:[e.jsx(Bt,{children:h.message}),h.description&&e.jsx(ze,{children:h.description}),h.action&&e.jsx(Mt,{children:e.jsx(L,{ref:h.focusAction?c:void 0,variant:"ghost",color:"primary",onClick:h.action.onClick,children:h.action.label})})]})},h.id))})};function us({apiUrl:t,loginApiUrl:n,redirectTo:s,captchaSiteKey:r,initialError:o,onSuccess:a}){const[l,i]=f.useState(!1),[d,p]=f.useState(o??null),u=f.useRef(0);return{submit:async h=>{if(r&&!h.captchaToken){p("Veuillez compléter la vérification captcha.");return}const _=++u.current,w=()=>u.current===_;i(!0),p(null);try{const m=h.mode==="login"&&n?n:t,y=await(await fetch(m,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"same-origin",body:JSON.stringify({...h,redirectTo:s})})).json();if(y.success){ft(),pt(),a(y);return}w()&&p(y.error||"Une erreur est survenue.")}catch{w()&&p("Une erreur est survenue. Veuillez réessayer.")}w()&&i(!1)},isLoading:l,error:d,reset:()=>{u.current+=1,i(!1),p(null)}}}function ms(t,n){var o;if(n)return null;const s=(o=t.redirect)==null?void 0:o.url,r=s&&/^(https?:\/\/|\/(?!\/))/i.test(s)?s:void 0;return{message:t.subject??"Notification",options:{description:t.body??void 0,action:r?{label:"Voir",onClick:()=>{window.location.href=r}}:void 0}}}function fs(){const t=xt(!1);return f.useEffect(()=>{let n=!1,s;return ht().then(r=>{n||!r||(s=r.on("notifications.notification_received",({result:o})=>{const a=ms(o,_t());a&&Be.info(a.message,a.options)}))}),()=>{n=!0,s==null||s()}},[t]),null}const ps={LoginPage:Fn,SignupPage:An,ForgotPasswordPage:Rn,ResetPasswordPage:Vn,CheckEmailPage:zn,SignupSubscriptionPage:Gn,GiftCodePage:Ue,WelcomePage:Wn,GiftSuccessPage:Jn,ErrorPage:Yn},xs=["googleAuthUrl","appleAuthUrl","xAuthUrl"];function Ie(t){const{redirectTo:n}=t;
99if(typeof n!="string"||!n)return t;const s={...t};for(const r of xs){const o=t[r];typeof o=="string"&&(s[r]=`${o}${o.includes("?")?"&":"?"}redirect_to=${encodeURIComponent(n)}`)}return s}function hs({component:t,apiUrl:n,loginApiUrl:s,redirectTo:r,captchaSiteKey:o,error:a,...l}){const{submit:i,isLoading:d,error:p}=us({apiUrl:n,loginApiUrl:s,redirectTo:r,captchaSiteKey:o,initialError:a,onSuccess:c=>{window.location.href=c.redirectTo||r||"/"}}),u=ps[t];return u?e.jsx(u,{...l,captchaSiteKey:o,onSubmit:i,isLoading:d,error:p}):null}function _s({fieldName:t,...n}){const[s,r]=f.useState(!1),o=a=>{r(!0);const l=document.createElement("form");l.method="POST";const i=document.createElement("input");i.type="hidden",i.name=t,i.value=a.giftCode,l.appendChild(i),document.body.appendChild(l),l.submit()};return e.jsx(Ue,{...n,onSubmit:o,isLoading:s})}function gs({props:t}){const{isOpen:n}=f.useSyncExternalStore(bt,_e,_e),[s,r]=f.useState(null);if(f.useEffect(()=>{if(!n||s)return;let a=!1;return q(async()=>{const{default:l}=await import("./chunks/AuthModal-B-ic6S0L.js");return{default:l}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17])).then(({default:l})=>{a||r(()=>l)}),()=>{a=!0}},[n,s]),!s)return null;const o=s;return e.jsx(o,{props:t,onLoggedIn:()=>{}})}const bs=[{id:"react-premium-subscribe-modal-root",component:e.jsx(vn,{})},{id:"react-auth-root",getComponent:()=>{const t=document.getElementById("auth-props");if(!t)return null;const n=JSON.parse(t.textContent||"{}");return e.jsx(hs,{...Ie(n)})}},{id:"react-gift-code-root",getComponent:()=>{const t=document.getElementById("gift-code-props");if(!t)return null;const n=JSON.parse(t.textContent||"{}");return e.jsx(_s,{...n})}},{id:"react-auth-modal-root",getComponent:()=>{var n;const t=(n=document.getElementById("auth-modal-props"))==null?void 0:n.textContent;return t?e.jsx(gs,{props:Ie(JSON.parse(t))}):null}},{id:"react-alert-root",component:e.jsx(ds,{})},{id:"react-notification-toast",component:e.jsx(fs,{}),hydrate:!1},{id:"react-search-suggest",component:e.jsx(Gt,{})},{id:"react-search-field",getComponent:t=>{const{queryParam:n,action:s,initialValue:r,placeholder:o,postType:a,taxonomy:l,term:i}=t.dataset,d=a||l||i?{postType:a,taxonomy:l,term:i}:void 0;return e.jsx(Ut,{queryParam:n,action:s,initialValue:r,placeholder:o,restrictTo:d})}},{id:"google-follow-buttons-root",getComponent:t=>{const n=t.dataset.googleNewsUrl,s=t.dataset.googleSearchUrl;return!n||!s?null:e.jsx(gt,{googleNewsUrl:n,googleSearchUrl:s})}}];function js(){bs.forEach(({id:t,component:n,getComponent:s,hydrate:r})=>{const o=document.querySelectorAll(`#${t}`);o.length!==0&&o.forEach(a=>{const l=s?s(a):n;l&&(r!==!1&&me(a)?M.hydrateRoot(a,l):M.createRoot(a).render(l))})})}const Fe=t=>f.createElement(yt,{isNumerama:vt(location.host)},t),ys={"/pages/actualites":async()=>{const t=window.location.hostname.includes("numerama"),[n,s]=await Promise.allSettled([fetch(wt(t),{headers:{Accept:"application/json"}}),fetch(`${window.location.origin}/op-api/videos?page=1&per_page=10`,{headers:{Accept:"application/json"}})]),r=n.status==="fulfilled"&&n.value.ok?await n.value.json():{},o=s.status==="fulfilled"&&s.value.ok?await s.value.json():{};return{posts:r.json||[],lastPostDate:r.lastPostDate||"",nextPageUrl:r.nextPageUrl||"",nativeAd:r.nativeAd||{},post:r.post||{},ads:r.ads||"",isNumerama:r.isNumerama||t,isPremium:r.isPremium||!1,videos:o.videos||[]}}};function vs(t){if(!t)return null;try{const n=t.match(/[?&]component_name=([^&]+)/);if(n)return decodeURIComponent(n[1])}catch{}return t}function ws(){const t={"/pages/actualites":"Actualites"};document.querySelectorAll("optimus-island").forEach(n=>{(async()=>{try{if(n.dataset.reactRendered)return;const s=vs(n.getAttribute("endpoint")),r=t[s],o=jt[r];if(!r||!o)return;const a=n.getAttribute("params");if(a){let l={};try{l=Ns(a)}catch(d){console.error(`Erreur parsing ${r}:`,d.message);return}n.dataset.reactRendered="1";const i=await o(l);if(!i)return;M.createRoot(n).render(Fe(i))}else{const l=ys[s];if(!l)return;n.dataset.reactRendered="1";try{const i=await l(),d=await o(i);if(!d)return;M.createRoot(n).render(Fe(d))}catch(i){console.error(`Erreur fetching props for ${r}:`,i.message)}}}catch(s){console.error(`Erreur rendering ${n.getAttribute("endpoint")}:`,s.message)}})()})}function Ns(t){const n=atob(t),s=Uint8Array.from(n,o=>
99o.charCodeAt(0)),r=new TextDecoder("utf-8").decode(s);return JSON.parse(r)}const ue=t=>t==="true"||t==="1";function K(t){if(typeof t!="string"||t==="")return[];try{const n=JSON.parse(t);return Array.isArray(n)?n:[]}catch{return[]}}function We(t){return(t||"").split(",").map(n=>parseInt(n.trim(),10)).filter(n=>Number.isFinite(n)&&n>0)}function Ss(t,n){const s=We(n.product_ids).length===1?1:3;if(t.length!==s)return null;const r=K(n.card_titles),o=K(n.featured_flags),a=K(n.custom_strengths),l=K(n.custom_weaknesses),i=t.map((u,c)=>({...u,cardTitle:r[c]??null,featured:o[c]??!1,customStrengths:a[c]??u.customStrengths??null,customWeaknesses:l[c]??u.customWeaknesses??null})),d=n.pros_cons_mode??"",p=["collapsible","visible","hidden"].includes(d)?d:"collapsible";return{productCount:s,products:i,prosConsMode:p,showSubNotes:ue(n.show_sub_notes),showTestLink:n.show_test_link!=="false"&&n.show_test_link!=="0",headingLevel:n.heading_level==="h3"?"h3":"h2",title:n.title||"",variantOffers:ue(n.variant_offers)}}const Cs="google-css",Pe=5;function Es(t,n){return Nt(t,n)||+(ge(t)==="renewed")-+(ge(n)==="renewed")}function ks(t,n){const s=t[0];if(!s)return null;if(n.ref_site===Cs)return{product:{...s,offers:[...s.offers].sort(Es)},defaultVisible:Pe,defaultExpanded:!0,openOnCheapestCondition:!0,moduleProduit:n.module_produit,zone:n.zone};const r=parseInt(n.default_visible??"",10);return{product:s,defaultVisible:Number.isFinite(r)&&r>0?r:Pe,defaultExpanded:n.prices_list==="expanded",moduleProduit:n.module_produit,zone:n.zone}}function Ts(t){const n=atob(t.trim()),s=Uint8Array.from(n,r=>r.charCodeAt(0));return JSON.parse(new TextDecoder("utf-8").decode(s))}async function Is(t,n,s,r){const o=s?"&variant_offers=1":"",a=r?`&ref-site=${encodeURIComponent(r)}`:"",l=`${window.location.origin}/wp-json/humanoid/v1/products-detailed?ids=${t.join(",")}${o}${a}`,i=await fetch(l,{headers:{Accept:"application/json"}});return i.ok?(await i.json()).products??[]:(console.error(`${n} fallback: products-detailed fetch failed`,i.status),[])}function Ae({attribute:t,componentName:n,buildProps:s,render:r}){document.querySelectorAll(`[${t}]`).forEach(o=>{try{if(o.dataset.fallbackRendered||o.querySelector(`[data-react-component="${n}"]`))return;const a=o.dataset.propsId,l=a?document.getElementById(a):null;if(!l)return;const i=Ts(l.textContent||""),d=We(i.product_ids);if(d.length===0)return;o.dataset.fallbackRendered="1",Is(d,n,ue(i.variant_offers),i.ref_site??"").then(p=>{const u=s(p,i);u&&M.createRoot(o).render(r(u))}).catch(p=>{console.error(`${n} fallback failed:`,p==null?void 0:p.message)})}catch(a){console.error(`${n} fallback error:`,a==null?void 0:a.message)}})}function Fs(){Ae({attribute:"data-product-block-fallback",componentName:"ProductBlock",buildProps:Ss,render:t=>e.jsx(St,{...t})}),Ae({attribute:"data-product-offers-fallback",componentName:"ProductOffersSection",buildProps:ks,render:t=>e.jsx(Ct,{...t})})}const Ps="feed___jOOjH",As="card___gdOpb",Rs="thumbnail___8wAu1",Ls="content___GLozm",Os="category___sc2YB",$s="titleLine1___TIUSj",Bs="titleLine2___zJZDF",Ms="meta___p6mUO",z={feed:Ps,card:As,thumbnail:Rs,content:Ls,category:Os,titleLine1:$s,titleLine2:Bs,meta:Ms};function Ds(){return e.jsxs("div",{"data-slot":"skeleton-feed-card",className:z.card,children:[e.jsx(b,{shape:"rect",className:z.thumbnail}),e.jsxs("div",{className:z.content,children:[e.jsx(b,{shape:"text",width:"40%",className:z.category}),e.jsx(b,{shape:"text",className:z.titleLine1}),e.jsx(b,{shape:"text",width:"80%",className:z.titleLine2}),e.jsx(b,{shape:"text",width:"30%",className:z.meta})]})]})}function ee({count:t=5}){return e.jsx("div",{"data-slot":"skeleton-feed",className:z.feed,children:Array.from({length:t},(n,s)=>e.jsx(Ds,{},s))})}function Vs(t,n=document){const s=n.querySelector(`[data-react-component="${t}"]`);if(!s)return null;const r=s.dataset.propsId;if(!r)return null;const o=n.getElementById(r);if(!o)return null;let a;try{a=JSON.parse(o.textContent??"")}catch{return null}return a===null||typeof a!="object"||Array.isArray(a)?null:a}const zs="page___om8Gr",Hs="carousel___02-pk",qs="videoCard___pMoO-",Gs="tabs___8NlQK",Us="tab___VbbP-",Ws="feed___635Rn",Js="post___yWG4X",Ys="postImage___b2EGF",Xs="category___NWrYn",Qs="title___qH-1X",R={page:zs,carousel:Hs,videoCard:qs,tabs:Gs,tab:Us,feed:Ws,post:Js,postImage:Ys,category:Xs,title:Qs};function Zs(){return e.jsxs("div",{"data-slot":"skeleton-actualites-post",className:R.post,children:[e.jsx(b,{shape:"rect",className:R.postImage}),e.jsx(b,{shape:"text",width:"35%",className:R.category}),e.jsx(b,{shape:"text",className:R.title}),e.jsx(b,{shape:"text",width:"70%",className:R.title})]})}function Ks({videos:t=4,posts:n=3}){return e.jsxs("div",{"data-slot":"skeleton-actualites",className:R.page,children:[e.jsx("div",{className:R.carousel,children:Array.from({length:t},(s,r)=>e.jsx(b,{shape:"rect",className:R.videoCard},r))}),e.jsxs("div",{className:R.tabs,children:[e.jsx(b,{shape:"rect",className:R.tab}),e.jsx(b,{shape:"rect",className:R.tab})]}),e.jsx("div",{className:R.feed,children:Array.from({length:n},(s,r)=>e.jsx(Zs,{},r))})]})}const er="page___gp-M5",tr="header___23QAk",nr="pageTitle___cOYNb",sr="intro___1LHg5",rr="introLine___QpYDW",or="list___f4lIk",ar="card___xstEF",ir="image___1mn0M",lr="cardHead___skuVr",cr="title___w-j4R",dr="day___uN6-u",ur="descLine___POABJ",mr="button___gR3jQ",T={page:er,header:tr,pageTitle:nr,intro:sr,introLine:rr,list:or,card:ar,image:ir,cardHead:lr,title:cr,day:dr,descLine:ur,button:mr};function fr(){return e.jsxs("div",{"data-slot":"skeleton-newsletter-card",className:T.card,children:[e.jsx(b,{shape:"rect",className:T.image}),e.jsxs("div",{className:T.cardHead,children:[e.jsx(b,{shape:"text",width:"45%",className:T.title}),e.jsx(b,{shape:"text",width:"25%",className:T.day})]}),e.jsx(b,{shape:"text",className:T.descLine}),e.jsx(b,{shape:"text",width:"80%",className:T.descLine}),e.jsx(b,{shape:"rect",className:T.button})]})}function pr({count:t=4}){return e.jsxs("div",{"data-slot":"skeleton-newsletter",className:T.page,children:[e.jsxs("div",{className:T.header,children:[e.jsx(b,{shape:"text",width:"60%",className:T.pageTitle}),e.jsxs("div",{className:T.intro,children:[e.jsx(b,{shape:"text",className:T.introLine}),e.jsx(b,{shape:"text",className:T.introLine}),e.jsx(b,{shape:"text",width:"55%",className:T.introLine})]})]}),e.jsx("div",{className:T.list,children:Array.from({length:t},(n,s)=>e.jsx(fr,{},s))})]})}const xr="page___IkXQj",hr="sidebar___Xxy-l",_r="navItem___bBOGm",gr="main___owtcA",br="head___BNJyl",jr="pageTitle___BrDjW",yr="deleteAll___i4FKx",vr="dateHeader___1aO-y",wr="list___XqT9-",Nr="card___-tCaF",Sr="image___paqwu",Cr="category___4YS6m",Er="title___ZYhrr",kr="author___tFbkY",Tr="avatar___Cer3k",Ir="authorName___1X63w",k={page:xr,sidebar:hr,navItem:_r,main:gr,head:br,pageTitle:jr,deleteAll:yr,dateHeader:vr,list:wr,card:Nr,image:Sr,category:Cr,title:Er,author:kr,avatar:Tr,authorName:Ir};
99function Fr(){return e.jsxs("div",{"data-slot":"skeleton-signets-card",className:k.card,children:[e.jsx(b,{shape:"rect",className:k.image}),e.jsx(b,{shape:"text",width:"35%",className:k.category}),e.jsx(b,{shape:"text",className:k.title}),e.jsx(b,{shape:"text",width:"65%",className:k.title}),e.jsxs("div",{className:k.author,children:[e.jsx(b,{shape:"circle",className:k.avatar}),e.jsx(b,{shape:"text",width:"40%",className:k.authorName})]})]})}function Pr({count:t=4}){return e.jsxs("div",{"data-slot":"skeleton-signets",className:k.page,children:[e.jsx("div",{className:k.sidebar,"aria-hidden":"true",children:Array.from({length:6},(n,s)=>e.jsx(b,{shape:"rect",className:k.navItem},s))}),e.jsxs("div",{className:k.main,children:[e.jsxs("div",{className:k.head,children:[e.jsx(b,{shape:"text",width:"8rem",className:k.pageTitle}),e.jsx(b,{shape:"rect",className:k.deleteAll})]}),e.jsx(b,{shape:"text",width:"25%",className:k.dateHeader}),e.jsx("div",{className:k.list,children:Array.from({length:t},(n,s)=>e.jsx(Fr,{},s))})]})]})}const Ar="page___XekV3",Rr="column___uNQM-",Lr="header___uLW7X",Or="headerLeft___N-KQs",$r="headerRight___ijn6L",Br="button___SfmEm",Mr="footer___Uvekf",Dr="title___CeLuc",Vr="date___YoFvD",A={page:Ar,column:Rr,header:Lr,headerLeft:Or,headerRight:$r,button:Br,footer:Mr,title:Dr,date:Vr};function zr(){return e.jsx("div",{"data-slot":"skeleton-video",className:A.page,children:e.jsxs("div",{className:A.column,children:[e.jsxs("div",{className:A.header,children:[e.jsxs("div",{className:A.headerLeft,children:[e.jsx(b,{shape:"rect",className:A.button}),e.jsx(b,{shape:"rect",className:A.button})]}),e.jsx("div",{className:A.headerRight,children:e.jsx(b,{shape:"rect",className:A.button})})]}),e.jsxs("div",{className:A.footer,children:[e.jsx(b,{shape:"text",className:A.title}),e.jsx(b,{shape:"text",width:"60%",className:A.title}),e.jsx(b,{shape:"text",width:"30%",className:A.date})]})]})})}const Hr="Actualites",qr="VideoFeed",Gr="NewsletterPage",Ur="AccountPage",Wr="account-page-props";function te(t,n){let s=null,r=null;return{load(){return s?Promise.resolve():(r??(r=t().then(o=>{s=o.default}).catch(o=>{throw r=null,o})),r)},isReady:()=>
99s!==null,render:o=>s?n(s,o):null}}const Jr=592,Yr=1e3,Xr={actus:{componentName:Hr,...te(()=>q(()=>import("./chunks/Actualites-MA6YykHp.js"),__vite__mapDeps([18,1,2,3,4,19,11,12,13,20,21,22])),(t,n)=>e.jsx(t,{...n})),skeleton:()=>e.jsx(Ks,{}),contentMaxWidth:Jr,gutter:!0},videos:{componentName:qr,...te(()=>q(()=>import("./chunks/VideoFeed-Wxh7wL17.js"),__vite__mapDeps([23,1,19,2,3,4,20,21,24])),(t,n)=>e.jsx(t,{...n,onExit:()=>Et("/actualites/")})),skeleton:()=>e.jsx(zr,{}),stageBackground:"rgb(34 34 34)"},newsletters:{componentName:Gr,...te(()=>q(()=>import("./chunks/NewsletterPage-DW93YGqc.js"),__vite__mapDeps([25,1,2,3,4,26,7,8,9,10,5,6,27])),(t,n)=>e.jsx(t,{...n})),skeleton:()=>e.jsx(pr,{}),contentMaxWidth:Yr},signets:{componentName:Ur,...te(()=>q(()=>import("./chunks/AccountPage-CH-AkqEJ.js"),__vite__mapDeps([28,1,2,3,4,11,12,13,5,6,29,30,26,7,8,9,10,14,15,16,17,31])),(t,n)=>e.jsx(t,{...n})),skeleton:()=>e.jsx(Pr,{}),accountShell:!0,extractProps:t=>{const n=t.getElementById(Wr);if(!n)return null;try{const s=JSON.parse(n.textContent??"");return!s||typeof s!="object"||Array.isArray(s)?null:s}catch{return null}}}};function H(t){return Xr[t]??null}const Re=18,Qr="100dvh";function Zr({contentMaxWidth:t,gutter:n}){return{maxWidth:n?t+2*Re:t,marginInline:"auto",width:"100%",minHeight:Qr,...n?{paddingInline:Re,boxSizing:"border-box"}:{}}}const Kr=parseInt(Me.fast,10),eo=300;function to(){var t,n;return((n=(t=window.matchMedia)==null?void 0:t.call(window,"(prefers-reduced-motion: reduce)"))==null?void 0:n.matches)??!1}function no(){return to()?0:Kr}function so(t){return t<=0?Promise.resolve():new Promise(n=>setTimeout(n,t))}async function ro(t,n,s,r,o,a){var u;const l=s(n);let i=!1,d=null;l.then(c=>{i=!0,d=c}),r.setFadingOut(),await a(o);let p;if(i)p=d;else{const c=eo-o,g=Symbol("show-skeleton"),h=c>0?await Promise.race([l,a(c).then(()=>g)]):g;h===g?(r.setLoading(t),p=await l):p=h}if(!p){r.onFallback?r.onFallback(n):r.setError(t);return}r.setFadingIn(t,p),await a(o),r.setLoaded(t,p),(u=r.restoreScroll)==null||u.call(r)}function oo(t){var s;return((s=t.title)==null?void 0:s.trim())||null}function ao(t){var r;const n=t.querySelector('link[rel="canonical"]');return((r=n==null?void 0:n.getAttribute("href"))==null?void 0:r.trim())||null}const io=['meta[name="description"]','meta[name="robots"]','meta[property="og:title"]','meta[property="og:description"]','meta[property="og:url"]','meta[property="og:image"]','meta[property="og:type"]','meta[name="twitter:title"]','meta[name="twitter:description"]','meta[name="twitter:image"]','meta[name="twitter:card"]'],lo=/^meta\[(name|property)="(.+)"\]$/;function co(t,n,s=document){let r=s.querySelector(t);if(!r){const o=t.match(lo);if(!o)return;r=s.createElement("meta"),r.setAttribute(o[1],o[2]),s.head.appendChild(r)}r.setAttribute("content",n)}function Je(t){var s,r,o;const n={};for(const a of io){const l=(r=(s=t.querySelector(a))==null?void 0:s.getAttribute("content"))==null?void 0:r.trim();l&&(n[a]=l)}return{title:oo(t),canonical:ao(t),tags:n,bodyClass:((o=t.body)==null?void 0:o.className)??""}}function ce(t,n,s=!0){for(const[r,o]of Object.entries(t.tags))co(r,o);t.title&&(document.title=t.title),t.canonical&&fo(t.canonical),uo(t.bodyClass),s&&mo(n,t.title??document.title)}function uo(t){t&&document.body&&(document.body.className=t)}function mo(t,n){window.dataLayer=window.dataLayer??[],window.dataLayer.push({event:"pageview",page_path:t,page_title:n})}function fo(t){let n=document.querySelector('link[rel="canonical"]');n||(n=document.createElement("link"),n.rel="canonical",document.head.appendChild(n)),n.setAttribute("href",t)}function po(){var s;const t=(s=kt())==null?void 0:s.user_options;if(typeof t!="string"||t==="")return{};const n={};for(const r of t.split(",")){const[o,a]=r.split(":");o&&(a==="0"||a==="1")&&(n[o]=a==="1")}return n}const xo="fadingOut___UEVRR",ho="fadingIn___EdgJO",_o="loaded___9G3vk",ne={fadingOut:xo,fadingIn:ho,loaded:_o},Ye=zt({backing:"memory"});function go(t,n){if(!t)return;const s=Ht(t);s&&Ye.save(t,qt(s,n))}const de={"--spa-fade-duration":Me.fast,"--spa-fade-ease":It.standard},bo=18,jo=1e3,Le="100dvh";function Xe(t,n){const s=t.extractProps?t.extractProps(n):Vs(t.componentName,n);return s&&Qe(s)}
99function Qe(t){return{...t,cookies:po()}}const yo=3e4;function vo(t,n,s=yo){return n-t<s}function wo(t){let n=0;const s=requestAnimationFrame(()=>{n=requestAnimationFrame(t)});return()=>{cancelAnimationFrame(s),n&&cancelAnimationFrame(n)}}async function Oe(t,n){let s;try{const a=t.includes("?")?"&":"?",l=await fetch(`${t}${a}spa_props=1`,{credentials:"same-origin"});if(!l.ok)return null;s=await l.text()}catch{return null}try{const a=JSON.parse(s);if(a&&typeof a=="object"&&a.props)return{props:Qe(a.props),meta:{title:a.title??null,canonical:a.canonical??null,tags:{},bodyClass:""}}}catch{}const r=new DOMParser().parseFromString(s,"text/html"),o=Xe(n,r);return o?{props:o,meta:Je(r)}:null}function No(t=document){const n=De();if(!n)return{status:"idle"};const s=H(n.id);if(!s)return{status:"idle"};const r=Xe(s,t);return r?{status:"loaded",destId:n.id,props:r}:{status:"idle"}}function So(){var h,_,w;const[t,n]=f.useState(()=>No()),s=f.useRef(0),r=f.useRef(null),o=f.useRef(null),a=f.useRef(new Map),l=f.useRef(t.destId);l.current=t.destId,f.useEffect(()=>{t.status==="loaded"&&t.destId&&t.props&&a.current.set(t.destId,{props:t.props,meta:Je(document),fetchedAt:Date.now()})},[]),f.useEffect(()=>{const m=Tt(async x=>{if(x.id!=="videos"&&typeof document<"u"){document.querySelectorAll("[data-video-overlay-root]").forEach(v=>{v.style.display="none"});for(const v of[document.documentElement,document.body])for(const E of["overflow","overscroll-behavior","background","width","height","backdrop-filter"])v.style.removeProperty(E)}const y=H(x.id);if(!y)return;const N=++s.current,S=()=>s.current===N,C=l.current;C&&C!==x.id&&go(C,Date.now()),o.current&&(o.current(),o.current=null),r.current=x.scrollY??0;const F=Ye.load(x.id);F&&(r.current=F.scrollY);const D=v=>F?{...v,feedRestore:F}:v;typeof document<"u"&&(document.documentElement.dataset.spaTransitioning="");const I=a.current.get(x.id);if(I){if(ce(I.meta,x.path),o.current=wo(()=>{o.current=null,S()&&(n({status:"loaded",destId:x.id,props:D(I.props)}),typeof document<"u"&&delete document.documentElement.dataset.spaTransitioning)}),vo(I.fetchedAt,Date.now()))return;const v=await Oe(x.path,y);v&&(a.current.set(x.id,{...v,fetchedAt:Date.now()}),S()&&(ce(v.meta,x.path,!1),f.startTransition(()=>{n({status:"loaded",destId:x.id,props:v.props})})));return}await ro(x.id,x.path,async v=>{let E=!1;const[V]=await Promise.all([Oe(v,y),y.load().catch(se=>{E=!0,console.error(`[AppShell] failed to load chunk for destination "${x.id}":`,se)})]);return E?null:(V&&(S()&&ce(V.meta,v),a.current.set(x.id,{...V,fetchedAt:Date.now()})),(V==null?void 0:V.props)??null)},{setFadingOut:()=>{S()&&n(v=>({...v,status:"fading-out"}))},setLoading:v=>{S()&&n({status:"loading",destId:v})},setFadingIn:(v,E)=>{S()&&f.startTransition(()=>n({status:"fading-in",destId:v,props:D(E)}))},setLoaded:(v,E)=>{S()&&f.startTransition(()=>{n({status:"loaded",destId:v,props:D(E)}),typeof document<"u"&&delete document.documentElement.dataset.spaTransitioning})},setError:v=>{S()&&n({status:"error",destId:v})},onFallback:v=>{S()&&window.location.assign(v)}},no(),so)});return()=>{m(),o.current&&(o.current(),o.current=null)}},[]);const i=f.useRef(null);f.useLayoutEffect(()=>{if(r.current===null||t.status!=="fading-in"&&t.status!=="loaded")return;const m=r.current;i.current!==null&&(cancelAnimationFrame(i.current),i.current=null);const x=()=>{i.current!==null&&(cancelAnimationFrame(i.current),i.current=null)};if(m<=0){let S=8;const C=()=>{window.scrollTo({top:0,behavior:"instant"}),S-- >0?i.current=requestAnimationFrame(C):(i.current=null,t.status==="loaded"&&(r.current=null))};return C(),x}let y=30;const N=()=>{if(document.documentElement.scrollHeight-window.innerHeight>=m||y--<=0){window.scrollTo({top:m,behavior:"instant"}),i.current=null,t.status==="loaded"&&(r.current=null);return}i.current=requestAnimationFrame(N)};return i.current=requestAnimationFrame(N),x},[t.status,t.destId]),f.useLayoutEffect(()=>{if(typeof document>"u")return;const m=document.getElementById("react-spa-outlet");if(!m)return;const x=t.destId?H(t.destId):null,y=x==null?void 0:x.stageBackgroun
99d;return y&&t.status!=="idle"&&t.status!=="error"?m.style.background=y:m.style.removeProperty("background"),()=>{m.style.removeProperty("background")}},[t.status,t.destId]);const d=f.useRef(null),p=()=>{var m;return d.current===null&&(d.current=typeof document<"u"&&!!((m=document.getElementById("react-spa-outlet"))!=null&&m.closest(".account-settings-layout"))),d.current},u=(m,x)=>x?x.accountShell?p()?m:e.jsx("div",{className:"container account-settings-layout",style:{paddingInline:bo,boxSizing:"border-box",maxWidth:jo,marginInline:"auto",width:"100%"},children:e.jsx("div",{style:{gridColumn:"1 / -1",minHeight:Le},children:m})}):x.contentMaxWidth?e.jsx("div",{style:Zr({contentMaxWidth:x.contentMaxWidth,gutter:x.gutter}),children:m}):e.jsx("div",{style:{minHeight:Le},children:m}):m;if(t.status==="fading-out"){if(!t.destId||!t.props)return null;const m=H(t.destId);if(!m)return null;const x=m.render(t.props);return x?e.jsx("div",{className:ne.fadingOut,style:de,children:u(x,m)}):u(((h=m.skeleton)==null?void 0:h.call(m))??e.jsx(ee,{}),m)}if(t.status==="loading"){const m=t.destId?H(t.destId):null,x=m!=null&&m.skeleton?u(m.skeleton(),m):e.jsx(ee,{});return e.jsx("div",{className:ne.fadingIn,style:de,children:x})}if(t.status==="fading-in"){if(!t.destId||!t.props)return null;const m=H(t.destId);if(!m)return null;const x=m.render(t.props);return x?e.jsx("div",{className:ne.fadingIn,style:de,children:u(x,m)}):u(((_=m.skeleton)==null?void 0:_.call(m))??e.jsx(ee,{}),m)}if(t.status!=="loaded"||!t.destId||!t.props)return null;const c=H(t.destId);if(!c)return null;const g=c.render(t.props);return g?e.jsx("div",{className:ne.loaded,children:u(g,c)}):u(((w=c.skeleton)==null?void 0:w.call(c))??e.jsx(ee,{}),c)}const Co="react-spa-outlet";async function Eo(){const t=document.getElementById(Co);if(!t)return;const n=De(),s=n?H(n.id):null;if(s)try{await s.load()}catch(r){if(console.error("Failed to load SPA destination chunk:",r),me(t))return}M.createRoot(t).render(e.jsx(So,{}))}const ko="react-account-page-root";async function To(){const t=document.getElementById(ko);if(!t)return;const n=document.getElementById("account-page-props");if(!n)return;let s;try{s=JSON.parse(n.textContent||"{}")}catch(r){console.error("Failed to parse account page props:",r);return}try{const{default:r}=await q(async()=>{const{default:a}=await import("./chunks/AccountPage-CH-AkqEJ.js");return{default:a}},__vite__mapDeps([28,1,2,3,4,11,12,13,5,6,29,30,26,7,8,9,10,14,15,16,17,31])),o=r;me(t)?M.hydrateRoot(t,e.jsx(o,{...s})):M.createRoot(t).render(e.jsx(o,{...s}))}catch(r){console.error("Failed to load the account page chunk:",r)}}async function Io(){const t=document.getElementById("react-video-feed-root"),n=document.getElementById("video-feed-props");if(!t||!n)return;let s;try{const r=JSON.parse(n.textContent??"");if(!r||typeof r!="object")return;s=r}catch{return}try{const{default:r}=await q(async()=>{const{default:o}=await import("./chunks/VideoFeed-Wxh7wL17.js");return{default:o}},__vite__mapDeps([23,1,19,2,3,4,20,21,24]));M.createRoot(t).render(e.jsx(r,{...s}))}catch(r){console.error("mountStandaloneVideoPage failed:",r==null?void 0:r.message)}}async function Fo(){var n;const t=document.getElementById("react-search-results-page");if(t)try{const{default:s}=await q(async()=>{const{default:r}=await import("./chunks/SearchResultsPage-DxKIHPtX.js").then(o=>o.e);return{default:r}},__vite__mapDeps([32,3,1,2,4,14,7,8,15,19,12,33]));(n=document.querySelector("[data-search-fallback]"))==null||n.remove(),M.createRoot(t).render(e.jsx(s,{}))}catch(s){console.error("mountSearchResultsPage failed:",s==null?void 0:s.message)}}function Po(){return Ft(t=>{if(t.loggedIn){Pt(t.nonce),At();return}window.location.reload()})}typeof window<"u"&&(Yt(),Rt(),Po(),Lt(),js(),ws(),Fs(),Eo(),To(),Io(),Fo(),Ot(),$t());export{zn as C,G as F,Fn as L,Mn as N,Ho as P,An as S,us as u};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.