PageSourceSearch

https://assets.corsematin.com/prod/_next/static/chunks/pages/kiosques/[[...slug]]-b15eeb114d06fc57.js

js corsematin.com collected 2026-09-24 08:49:18 UTC 17,720 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8043],{96023:function(e,t,r){var a;a=function(e){"use strict";var t={name:"fr",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),months:"janvier_f\xe9vrier_mars_avril_mai_juin_juillet_ao\xfbt_septembre_octobre_novembre_d\xe9cembre".split("_"),monthsShort:"janv._f\xe9vr._mars_avr._mai_juin_juil._ao\xfbt_sept._oct._nov._d\xe9c.".split("_"),weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(e){return""+e+(1===e?"er":"")}};return(e&&"object"==typeof e&&"default"in e?e:{default:e}).default.locale(t,null,!0),t},e.exports=a(r(27484))},10338:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/kiosques/[[...slug]]",function(){return r(21717)}])},87303:function(e,t,r){"use strict";var a=r(85893);r(67294);var n=r(41664),i=r.n(n);t.Z=e=>{let{label:t,className:r}=e;if("href"in e){let{href:n,external:s,handleClick:o}=e;return(0,a.jsx)(i(),{href:n,className:r,target:s?"_blank":"_self",rel:s?"noopener noreferrer":void 0,onClick:o,children:t})}return(0,a.jsx)("button",{onClick:e.onClick,className:r,children:t})}},99733:function(e,t,r){"use strict";r.d(t,{f:function(){return n}});let a="whitespace-nowrap text-[16px] font-bold leading-[22px] px-[16px] py-[10px] rounded-full transition-colors duration-200 shrink-0 no-underline",n=(e,t,r)=>t?e?"".concat(a," bg-neutral-main-cm text-neutral-0"):"".concat(a," bg-neutral-30-cm text-neutral-main-cm hover:!bg-neutral-40-cm hover:!text-neutral-main"):r?e?"".concat(a," bg-economie-150 text-neutral-0"):"".concat(a," bg-economie-main text-neutral-main hover:!bg-economie-150 hover:text-neutral-0"):e?"".concat(a," bg-primary-main text-neutral-0"):"".concat(a," bg-primary-30 text-neutral-main hover:!bg-primary-40 hover:text-neutral-main")},21717:function(e,t,r){"use strict";r.r(t),r.d(t,{__N_SSP:function(){return S},default:function(){return E}});var a=r(85893),n=r(24818),i=r(67294),s=r(73595);r(57317);var o=r(63985),l=r(5737),d=r(18427),u=r(11163),c=r(10535),m=r(27484),p=r.n(m);r(96023);let x=e=>{let{className:t,width:r,height:n}=e;return(0,a.jsxs)("svg",{width:r||24,height:n||24,viewBox:"0 0 26 26",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:t||"",children:[(0,a.jsx)("path",{d:"M19 4H5C3.89543 4 3 4.89543 3 6V20C3 21.1046 3.89543 22 5 22H19C20.1046 22 21 21.1046 21 20V6C21 4.89543 20.1046 4 19 4Z",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),(0,a.jsx)("path",{d:"M16 2V6",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),(0,a.jsx)("path",{d:"M8 2V6",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),(0,a.jsx)("path",{d:"M3 10H21",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]})};var h=r(25209);p().locale("fr");let f=()=>{var e,t;let r=(0,u.useRouter)(),n=r.query.startDate,s=r.query.endDate,o=p()(),[l,d]=(0,i.useState)(p()()),[c,m]=(0,i.useState)(()=>{let e=n&&!Array.isArray(n)?p()(n):void 0,t=s&&!Array.isArray(s)?p()(s):void 0;return{from:e&&e.isValid()&&!e.isAfter(o,"day")?e:void 0,to:t&&t.isValid()&&!t.isAfter(o,"day")?t:void 0}}),[f,v]=(0,i.useState)(!1),[g,b]=(0,i.useState)((null===(e=c.from)||void 0===e?void 0:e.format("DD/MM/YYYY"))||""),[y,j]=(0,i.useState)((null===(t=c.to)||void 0===t?void 0:t.format("DD/MM/YYYY"))||""),[_,w]=(0,i.useState)(""),Y=(0,i.useId)(),k=(0,i.useId)(),M=(0,i.useRef)(null),N=e=>{var t;return!!c.from&&(c.from.isSame(e,"day")?"start":(null===(t=c.to)||void 0===t?void 0:t.isSame(e,"day"))?"end":!!(c.to&&e.isAfter(c.from)&&e.isBefore(c.to))&&"middle")},D=e=>{if(e.isAfter(o,"day"))return;let t=c.from,a=c.to;!t||a?(m({from:e,to:void 0}),b(e.format("DD/MM/YYYY")),j("")):(e.isBefore(t)?(r.push({query:{...r.query,startDate:e.format("YYYY-MM-DD"),endDate:t.format("YYYY-MM-DD")}}),m({from:e,to:t}),b(e.format("DD/MM/YYYY")),j(t.format("DD/MM/YYYY"))):(r.push({query:{...r.query,startDate:t.format("YYYY-MM-DD"),endDate:e.format("YYYY-MM-DD")}}),m({from:t,to:e}),j(e.format("DD/MM/YYYY"))),v(!1))},L=(e,t)=>{w(""),"from"===t?b(e.target.value):j(e.target.value)};return(0,i.useEffect)(()=>{let e=e=>{M.current&&!M.current.contains(e.target)&&v(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[]),(0,a.jsxs)("div",{className:"relative w-fit text-[16px] flex flex-col gap-[4px]",ref:M,children:[(0,a.jsx)("label",{htmlFor:Y,className:"font-bold leading-snug",children:"Filtrez par date"}),(0,a.jsxs)("form",{onSubmit:e=>{let t,a;e.preventDefault(),w("");let n=g.split("/"),i=y.split("/"),s=p()("".concat(n[2],"-").concat(n[1],"-").concat(n[0])),l=p()("".concat(i[2],"-").concat(i[1],"-").concat(i[0]));if(!s.isValid()){w("La date de d\xe9but est invalide");return}if(!l.isValid()){w("La date de fin est invalide");return}if(s.isAfter(o,"day")){w("La date de d\xe9but ne peut pas \xeatre dans le futur");return}if(l.isAfter(o,"day")){w("La date de fin ne peut pas \xeatre dans le futur");return}s.isBefore(l)?(t=s.format("YYYY-MM-DD"),a=l.format("YYYY-MM-DD")):(t=l.format("YYYY-MM-DD"),a=s.format("YYYY-MM-DD")),r.push({query:{...r.query,startDate:t,endDate:a}})},className:"flex items-center border border-neutral-50 group-focus-within:border-primary-main rounded-[8px] w-full ps-[16px] pe-[10px] py-[10px] bg-white shadow-sm text-[12px]",children:[(0,a.jsx)("label",{htmlFor:Y,className:"sr-only",children:"Date de d\xe9but en format JJ/MM/AAAA"}),(0,a.jsx)("input",{pattern:"[0-9]{2}/[0-9]{2}/[0-9]{4}",id:Y,type:"text",className:"max-w-[12ch] leading-snug outline-none bg-transparent border-none text-[16px] text-neutral-70 p-0",placeholder:"JJ/MM/AAAA",value:g,onChange:e=>L(e,"from"),required:!0}),(0,a.jsx)("span",{className:"text-neutral-70 text-[16px] leading-snug me-[4px]",children:"-"}),(0,a.jsx)("label",{htmlFor:k,className:"sr-only",children:"Date de fin en format JJ/MM/AAAA"}),(0,a.jsx)("input",{pattern:"[0-9]{2}/[0-9]{2}/[0-9]{4}",id:k,type:"text",className:"max-w-[12ch] outline-none leading-snug bg-transparent border-none text-[16px] text-neutral-70 p-0",placeholder:"JJ/MM/AAAA",value:y,onChange:e=>L(e,"to"),required:!0}
1),(0,a.jsx)("button",{type:"submit",className:"sr-only focus:not-sr-only",children:"Rechercher"}),(g||y)&&(0,a.jsx)("button",{type:"button",onClick:()=>{m({}),b(""),j(""),w(""),v(!1);let e={...r.query};delete e.startDate,delete e.endDate,r.push({pathname:r.pathname,query:e})},className:"ml-auto text-neutral-70","aria-label":"R\xe9initialiser les dates",children:(0,a.jsx)(h.a,{width:20,height:20})}),(0,a.jsx)("button",{type:"button",onClick:()=>v(!f),className:g||y?"ms-[4px]":"ml-auto",children:(0,a.jsx)(x,{width:22,height:22})}),_&&(0,a.jsx)("p",{className:"text-[14px] absolute top-full left-0 right-0","aria-live":"polite",children:_})]}),f&&(0,a.jsxs)("div",{className:"absolute top-full left-0 mt-2 p-4 border rounded-lg shadow-md bg-white z-10 w-[280px]",children:[(0,a.jsxs)("div",{className:"flex justify-between items-center mb-4 text-[14px]",children:[(0,a.jsx)("button",{onClick:()=>d(l.subtract(1,"month")),className:"px-3 hover:bg-gray-200 rounded",children:"◀"}),(0,a.jsx)("p",{className:"text-[14px] capitalize",children:l.format("MMMM YYYY")}),(0,a.jsx)("button",{onClick:()=>d(l.add(1,"month")),className:"px-3 hover:bg-gray-200 rounded",children:"▶"})]}),(0,a.jsx)("div",{className:"grid grid-cols-7 text-center font-semibold mb-2",children:["Lun","Mar","Mer","Jeu","Ven","Sam","Dim"].map(e=>(0,a.jsx)("div",{className:"p-2 text-[12px]",children:e},e))}),(0,a.jsxs)("div",{className:"grid grid-cols-7 text-[12px]",children:[Array(0===l.startOf("month").day()?6:l.startOf("month").day()-1).fill(null).map((e,t)=>(0,a.jsx)("div",{className:"p-2"},"empty-".concat(t))),Array.from({length:l.daysInMonth()},(e,t)=>l.date(t+1)).map(e=>{let t=e.isAfter(o,"day"),r=N(e),n=["p-2","text-center","rounded-md","transition",!t&&"cursor-pointer hover:bg-gray-200",t&&"cursor-not-allowed text-gray-300","start"===r&&"bg-[#1F6AE0] text-white rounded-l-full","end"===r&&"bg-[#1F6AE0] text-white rounded-r-full","middle"===r&&"bg-[#F2F7FF]",e.month()!==l.month()&&"text-gray-400"].filter(Boolean).join(" ");return(0,a.jsx)("div",{className:n,onClick:()=>!t&&D(e),children:e.date()},e.toString())})]})]})]})};var v=r(25675),g=r.n(v),b=r(44886),y=r(4882);let j=e=>{let{issue:t,edition:r}=e,{theme:n}=(0,l.Z)(),s=n===d.hd.cm,o=(0,u.useRouter)(),[m,p]=(0,i.useState)(!1),x=async e=>{if(e.preventDefault(),!m){p(!0);try{let e=await fetch("/api/kiosk/ticket/open",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({issueMid:t.mid})}),r=await e.json(),a=(null==r?void 0:r.ticket)?"/kiosques/pdf/".concat(t.mid,"?ticket=").concat(r.ticket):"/kiosques/pdf/".concat(t.mid);o.push(a)}catch(e){console.error("Kiosk ticket open error:",e),p(!1)}}};return(0,a.jsxs)("div",{className:"grid grid-rows-[max-content_max-content_1fr] gap-[16px] justify-items-center justify-center relative rounded-[8px] px-[36px] py-[30px] max-w-[406px] bg-neutral-10",children:[(0,a.jsx)("div",{className:"text-[14px] first-letter:capitalize",children:new Intl.DateTimeFormat("fr-FR",{day:"numeric",weekday:"long",month:"long",year:"numeric"}).format(new Date(t.date))}),(0,a.jsx)("div",{className:"flex items-center justify-center",children:(0,a.jsx)(g(),{className:"border-[#DDE3EB] border-[1px] w-[345px] md:w-[238px] ".concat(s&&(o.asPath.startsWith("/kiosques/journal")||o.asPath.startsWith("/kiosques/supplements-gratuits")||o.asPath.startsWith("/kiosques/settimana"))?"h-[524px] md:h-[340px]":"h-[405px] md:h-[280px]"),src:"https://static.milibris.com/thumbnail/issue/".concat(t.mid,"/front/catalog-cover-large.png"),alt:"Couverture de l'\xe9dition du ".concat(t.date),width:392,height:590})}),(0,a.jsxs)("div",{className:"flex flex-col gap-[16px] w-full",children:[(0,a.jsx)(b.Z,{label:m?"Ouverture...":"Lire l'\xe9dition",theme:"primary",isRound:!0,size:"medium",href:"/kiosques/pdf/".concat(t.mid),handleClick:x,textColor:"neutral-0",additionalClassName:"after:absolute after:inset-0 after:cursor-pointer ".concat("cm"===c.VH?"!bg-neutral-main !border-neutral-main !text-neutral-0 hover:!bg-neutral-70 hover:!border-neutral-70":"group hover:text-neutral-0 [&_p]:transition-colors [&_p]:duration-300")}),t.preview?(0,a.jsx)(b.Z,{label:"Lire un extrait",theme:"secondary",isRound:!0,size:"medium",href:"/kiosques/pdf/preview/".concat(t.preview.mid),external:!0,textColor:s?"neutral-main":"primary-main",additionalClassName:"relative z-10 ".concat("cm"===c.VH?"!bg-transparent !border-neutral-main !text-neutral-main hover:!bg-neutral-40-cm hover:!border-neutral-main group [&_p]:transition-colors [&_p]:duration-300":"group hover:!text-primary-main hover:!bg-primary-40 [&_p]:transition-colors [&_p]:duration-300"),handleClick:e=>{e.stopPropagation(),(0,y.t)("click.exit",{click:"extrait",click_chapter1:"kiosques",click_chapter2:r.name,click_chapter3:t.date})}}):null]})]})};var _=r(33161),w=r(96278),Y=r(41664),k=r.n(Y);let M=e=>{let{editionList:t,currentEdition:r}=e,n=(0,i.useId)(),s=(0,i.useRef)(null);return(0,i.useEffect)(()=>{let e=e=>{if("Escape"===e.key){var t;null===(t=s.current)||void 0===t||t.close()}},t=e=>{let t=s.current;if(t&&t.open&&!t.contains(e.target)){var r;null===(r=s.current)||void 0===r||r.close(),e.stopPropagation()}};if(s.current)return document.addEventListener("keydown",e,!0),document.addEventListener("click",t,!0),()=>{document.removeEventListener("keydown",e,!0),document.removeEventListener("click",t,!0)}},[]),(0,a.jsxs)("div",{className:"relative group leading-snug text-[16px]",children:[(0,a.jsxs)("button",{className:"flex gap-[4px] flex-col items-start w-full",onClick:()=>{var e;return null===(e=s.current)||void 0===e?void 0:e.show()},"aria-controls":n,children:[(0,a.jsx)("div",{className:"font-bold",children:"S\xe9lectionnez votre \xe9dition"}),(0,a.jsxs)("div",{className:"w-full ps-[16px] pe-[10px] py-[10px] border border-neutral-50 group-focus-within:border-primary-main rounded-[8px] flex gap-[8px] justify-between items-center focus-within:border-primary-main aria-disabled:opacity-75 aria-disabled:bg-[#F4F6FA] transition-colors",children:[(0,a.jsx)("div",{className:"flex-1 text-left text-neutral-70",children:r.name}),(0,a.jsx)(w.Z,{additionalClassName:"rotate-90",width:22,height:22})]})]}),(0,a.jsx)("dialog",{ref:s,className:"bg-neutral-0 border w-full p-0 rounded-[8px] border-neutral-30 flex-col absolute top-[calc(100%_+_4px)] left-0 right-0 z-10 max-h-[min(300px,50vh)] overflow-y-auto mx-0",children:(0,a.jsx)("ul",{role:"list",children:t.map(e=>(0,a.jsx)("li",{children:(0,a.jsx)(k(),{className:"block p-[8px] hover:bg-primary-30 aria-curr-page:bg-primary-30",href:"/kiosques".concat(e.parent?"/".concat(e.parent):"","/").concat(e.slug),"aria-current":e.id===r.id?"page":void 0,scroll:!1,onClick:()=>{var e;return null==s?void 0:null===(e=s.current)||void 0===e?void 0:e.close()},children:e.name})},e.id))})})]})};var N=r(50167),D=r(87303),L=r(99733);let A=e=>{var t,r;let{initialIssueList:n,catalog:s,catalogBatchSize:o}=e,{user:m,theme:p}=(0,l.Z)(),x=p===d.hd.cm,h=(0,u.useRouter)(),v=h.query.startDate,g="string"==typeof v||"string"==typeof h.query.endDate,b=s.id,[y,w]=(0,i.useState)(n||[]),[Y,k]=(0,i.useState)(!1),[A,C]=(0,i.useState)(n&&n.length===o),q=null===(t=y.at(-1))||void 0===t?void 0:t.date,S=(0,i.useRef)(null),E="journal"===s.parent,P=[{name:"Journal",id:"journal",slug:"journal",number:0}].concat("lp"===c.VH?c.T8:c.ZR),F=E&&"lp"===c.VH?c.fB:[];return(0,i.useEffect)(()=>{let e=S.current;if(A&&e){let t=new IntersectionObserver(async r=>{if(r[0].isIntersecting&&!Y&&A){k(!0);let r=new URLSearchParams({limit:"".concat(o)});if("string"==typeof v&&r.append("startDate",v),s.hasPreviews&&r.append("withPreviews","true"),q&&(!v||"string"==typeof v&&q>v)){let e=new Date(q);e.setDate(e.getDate()-1),r.append("endDate",e.toISOString().split("T")[0])}let a=await fetch("/api/kiosk/catalog/".concat(b,"?").concat(r.toString())).then(e=>e.json()).catch(()=>null);a&&w(e=>e.concat(a)),(!a||a.length<o)&&(C(!1),t.unobserve(e)),k(!1)}},{rootMargin:"0px 0px 400px 0px"});return t.observe(e),()=>{t.unobserve(e)}}},[A,y.length,Y,v,b,q,o,s.hasPreviews]),(0,a.jsxs)("div",{className:"text-left mx-[16px]",children:[!(null==m?void 0:null===(r=m.app_metadata)||void 0===r?void 0:r.is_subscriber_pdf)&&(0,a.jsx)(N.r,{className:"my-[24px] md:my-[40px]"}),(0,a.jsx)(_.Z,{size:"heading-3xl",weight:"black",color:"neutral-150",semantic:"h1",additionalClassName:"leading-none",children:"Kiosque"}),(0,a.jsx)("ul",{className:"flex flex-row pb-[16px] mb-[32px] pt-[24px] gap-[16px] overflow-x-auto lg:flex-wrap",children:P.map((e,t)=>{let r=e.id===s.id||e.slug===s.parent;return(0,a.jsx)("li",{className:"shrink-0",children:(0,a.jsx)(D.Z,{href:"/kiosques/".concat(e.slug),label:e.name,className:(0,L.f)(r,x,!1)})},t)})}),(0,a.jsxs)("div",{className:"max-w-[620px] mx-auto",children:[(0,a.jsxs)("div",{className:"flex flex-wrap justify-center gap-[18px] [&>*]:flex-[1_1_275px] [&>*]:max-w-[400px] items-center",children:[0!==F.length&&(0,a.jsx)(M,{editionList:F,currentEdition:s}),(0,a.jsx)(f,{})]}),(0,a.jsx)("div",{className:"grid gap-[26px] md:gap-y-[40px] my-[42px] [grid-template-columns:repeat(auto-fill,minmax(290px,1fr))]",children:y?y.map((e,t)=>(0,a.jsx)(j,{issue:e,edition:s},t)):(0,a.jsx)("div",{className:"text-[16px] font-bold",children:n?"Aucun journal disponible":"Une erreur est survenue. Veuillez r\xe9essayer"})}),y&&(Y||!A)&&(0,a.jsx)("div",{className:"text-center text-[16px] font-bold my-[42px]",children:Y?"Chargement...":g?"Vous avez atteint la fin des r\xe9sultats pour cette p\xe9riode.":"Vous avez atteint la fin du catalogue."},"info-message")]}),(0,a.jsx)("div",{ref:S})]})};
1var C=r(56344),q=r(97029),S=!0;function E(e){let{headerLp:t,footerLp:r,burgerLp:c,headerCitiesLp:m,ActuLp:p,headerActualitesLp:x,headerServices:h,headerPartenaires:f,initialIssueList:v,catalog:g}=e,{userConsent:b,theme:y,user:j}=(0,l.Z)(),_=(0,u.useRouter)(),[w,Y]=(0,i.useState)(!1);return(0,i.useEffect)(()=>{if(void 0!==window.dataLayer&&!w){var e;let t=(0,C.z)({user:j,router:_});window.dataLayer.unshift(t),(0,q.sendPageDisplayEvent)({payload:{page:_.asPath,page_chapter1:"kiosque",page_chapter2:g.name,site_level2:y===d.hd.lp?"laprovence":"corsematin",page_type:"kiosque",user_type:j?(null===(e=j.app_metadata)||void 0===e?void 0:e.is_subscriber_pdf)?"subscriber":"user":"anonymous"},pageDataLayer:t}),Y(!0)}},[j,_.asPath,w]),(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(o.Z,{title:"Kiosque | ".concat(y===d.hd.lp?"La Provence":"Corse Matin"),description:y===d.hd.lp?"Toute l'actualit\xe9 Marseille, Aix, Avignon, Vaucluse et Alpes avec votre journal num\xe9rique La Provence":"Toute l'actualit\xe9 Corse Matin avec votre journal num\xe9rique Corse Matin"}),(0,a.jsx)(n.Z,{headerLp:t,footerLp:r,burgerLp:c,headerCitiesLp:m,ActuLp:p,headerActualitesLp:x,headerServices:h,headerPartenaires:f,displayAdTop:!1,displayAdBottom:!1,displaySurFooter:!0,userConsent:b,children:(0,a.jsx)(s.default,{className:"!max-w-[1042px] w-full",mainAriaLabel:"Catalogue de l'\xe9dition",main:[(0,a.jsx)(A,{catalog:g,initialIssueList:v,catalogBatchSize:14},"page-content")]})})]})}}},function(e){e.O(0,[3913,1870,1591,5109,1122,2888,9774,179],function(){return e(e.s=10338)}),_N_E=e.O()}]);

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.