1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9694,7193],{97:function(e,s,l){(window.__NEXT_P=window.__NEXT_P||[]).push(["/blog/tag/[slug]",function(){return l(1249)}])},7193:function(e,s,l){"use strict";l.r(s),l.d(s,{BlogWholePage:function(){return k}});var t=l(5893),a=l(521),c=l(578),r=l(5820),i=l(1456),n=l(9755),x=l.n(n),d=l(1664),o=l.n(d),h=l(5755),u=l(7294),m=l(9583),j=l(3750);let p=e=>{let{articles:s}=e,[[l,i],n]=(0,u.useState)([0,0]),d=(0,h.r)(0,s.length,l),{scrollY:o}=(0,a.v)(),j=(0,c.H)(o,[0,300],[0,100]),p=e=>{n([l+e,e])};return s.length?(0,t.jsxs)(t.Fragment,{children:[s[0].cover&&(0,t.jsx)("div",{className:"hidden",children:(0,t.jsx)(x(),{src:s[0].cover.img.src,blurDataURL:s[0].cover.base64,placeholder:"blur",alt:"",layout:"fill",objectFit:"cover",priority:!0})}),(0,t.jsxs)("section",{className:"h-[50vh] md:h-[66vh] min-h-[300px] flex flex-col justify-center items-end relative overflow-hidden bg-accent",children:[(0,t.jsx)(r.M,{initial:!1,custom:i,children:(0,t.jsx)(f,{article:s[d],y:j},s[d].slug)}),s.length>1&&(0,t.jsx)("div",{className:"max-w-3xl m-auto text-white w-full absolute bottom-12 left-[50%] -translate-x-[50%] p-4 z-40",children:(0,t.jsx)("nav",{children:(0,t.jsxs)("ul",{className:"flex space-x-2",children:[(0,t.jsx)("li",{className:"cursor-pointer",onClick:()=>p(-1),children:(0,t.jsx)(m.MZt,{className:"w-6 h-6"})}),(0,t.jsx)("li",{className:"cursor-pointer",onClick:()=>p(1),children:(0,t.jsx)(m.Wgy,{className:"w-6 h-6"})})]})})})]})]}):(0,t.jsx)("div",{className:"",children:"pas d'articles \xe0 la une"})},g={enter:e=>({x:e<0?1e3:-1e3,opacity:0}),center:{zIndex:1,x:0,opacity:1},exit:e=>({zIndex:0,x:e<0?-1e3:1e3,opacity:0})},f=e=>{let{article:s,y:l}=e,a=(0,c.H)(l,e=>-e);return(0,t.jsxs)(i.E.article,{variants:g,initial:"enter",animate:"center",exit:"exit",className:"h-full w-full grid grid-cols-1 absolute",transition:{x:{type:"spring",stiffness:300,damping:30},opacity:{duration:.2}},children:[s.cover&&(0,t.jsx)("div",{className:"overflow-hidden col-start-1 row-start-1",children:(0,t.jsx)(i.E.div,{className:"relative h-full w-full",style:{y:l},children:(0,t.jsx)(x(),{src:s.cover.img.src,blurDataURL:s.cover.base64,placeholder:"blur",alt:"",layout:"fill",objectFit:"cover"})})}),(0,t.jsx)("div",{className:"relative bg-accent bg-opacity-50 h-full w-full col-start-1 row-start-1 flex justify-end items-end pt-24 md:pt-12",children:(0,t.jsxs)(i.E.div,{className:"flex flex-1 flex-col text-white max-w-3xl h-full p-4 m-auto justify-end pb-32",style:{y:a},children:[(0,t.jsxs)("div",{className:"uppercase text-sm space-x-2 py-2",children:[(0,t.jsx)("span",{className:"underline",children:"Nouveau"}),s.categories.map(e=>(0,t.jsx)(o(),{href:e.href,children:e.title},e.slug))]}),(0,t.jsx)("h1",{className:"font-title text-5xl",children:s.title}),(0,t.jsxs)(o(),{href:s.href,className:"flex items-center text-lg mt-4",children:["Lire la suite",(0,t.jsx)(j.lzl,{className:"w-3 h-3 ml-2"})]})]})})]})},v=e=>{let{article:s}=e;return(0,t.jsx)(o(),{href:s.href,className:"group",children:(0,t.jsxs)("article",{className:"shadow",children:[(0,t.jsxs)("div",{className:"h-48 md:h-60 relative grid grid-cols-1 overflow-hidden",children:[(0,t.jsx)("div",{className:"bg-accent col-start-1 row-start-1 z-10 bg-opacity-30 group-hover:bg-opacity-10 transition-all"}),s.cover&&(0,t.jsx)("div",{className:"relative group-hover:scale-125 group-hover:rotate-12 transition-all z-0 col-start-1 row-start-1",children:(0,t.jsx)(x(),{src:s.cover.img.src,blurDataURL:s.cover.base64,placeholder:"blur",alt:"",layout:"fill",objectFit:"cover"})})]}),(0,t.jsxs)("div",{className:"p-4",children:[(0,t.jsx)("div",{className:"text-gray-500 text-xs tracking-tight",children:s.categories.map(e=>(0,t.jsx)("span",{className:"uppercase",children:e.title},"".concat(s.slug,"-").concat(e.slug)))}),(0,t.jsx)("h1",{className:"font-title text-accent text-xl",children:s.title}),(0,t.jsxs)("div",{className:"mt-4 flex items-center justify-end text-sm text-gray-500",children:["Lire la suite ",(0,t.jsx)(j.lzl,{className:"h-3 ml-1"})]})]})]})})},N=e=>{let{articles:s}=e,l=s.reduce((e,s)=>{let l=s.tags.reduce((e,s)=>({...e,[s.slug]:s}),{});return{...e,...l}},{});return(0,t.jsx)("nav",{className:"flex space-x-1 my-2",children:Object.keys(l).map(e=>(0,t.jsx)(o(),{href:l[e].href,children:(0,t.jsx)("div",{className:"text-xs bg-accent text-white rounded-xl p-1 px-2 tracking-wider",children:l[e].title})},e))})},b=e=>{let{title:s,articles:l,carousel:a,categories:c=[],tags:r=!1}=e;return(0,t.jsxs)("section",{className:"flex flex-col md:grid grid-cols-5 py-8",children:[(0,t.jsxs)("div",{className:"p-4",children:[(0,t.jsx)("h1",{className:"font-bold text-3xl font-title mb-8 capitalize",children:s}),c.length>0&&(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("h2",{className:"font-bold tracking-wide",children:"Cat\xe9gories"}),(0,t.jsx)("nav",{children:(0,t.jsx)("ul",{children:c.map(e=>(0,t.jsx)("li",{children:(0,t.jsx)(o(),{href:e.href,className:"uppercase text-sm",children:e.title})},e.slug))})})]}),r&&(0,t.jsx)(N,{articles:l})]}),a?(0,t.jsx)(y,{articles:l}):(0,t.jsx)(_,{articles:l})]})},w=e=>{let{children:s}=e;return(0,t.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-8 p-4 md:p-0",children:s})},y=e=>{let{articles:s}=e,[l,a]=(0,u.useState)(0),c=Math.ceil(s.length/3),n=()=>{a(e=>{let s=e+1;return s>=c?0:s})};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(r.M,{initial:!1,children:(0,t.jsx)("div",{className:"relative col-span-3 w-full",children:(0,t.jsx)(i.E.div,{className:"bg-backgroundWhite w-full",initial:{opacity:0,x:-1e3,zIndex:0}
1,animate:{opacity:1,x:0,zIndex:1},exit:{opacity:0,x:1e3,zIndex:0},children:(0,t.jsx)(w,{children:s.slice(3*l,3*l+3).map(e=>(0,t.jsx)(v,{article:e},e.slug))})},"carousel-page-blog-".concat(l))})}),s.length>3&&(0,t.jsx)("div",{className:"hidden md:flex justify-center items-center cursor-pointer",onClick:()=>n(),children:(0,t.jsx)(j.PxJ,{className:"w-8 h-8"})})]})},_=e=>{let{articles:s}=e,[l,a]=(0,u.useState)(0),c=Math.ceil(s.length/6);return(0,t.jsxs)("div",{className:"col-span-3",children:[(0,t.jsx)(w,{children:s.slice(6*l,6*l+6).map(e=>(0,t.jsx)(v,{article:e},e.slug))}),c>1&&(0,t.jsxs)("div",{onClick:()=>a(e=>{let s=e+1;return s>=c?0:s}),className:"flex justify-center items-center text-sm p-4 cursor-pointer",children:[(0,t.jsx)("span",{className:"font-bold text-accent px-1",children:l+1})," -",(0,t.jsxs)("span",{className:"uppercase px-1",children:[c," pages"]}),(0,t.jsx)(m.Dli,{className:"w-3 h-3 text-accent"})]})]})},k=e=>{let{articles:s,categories:l=[],premiere:a=!1,premiereArticles:c=[],category:r=null}=e;return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(p,{articles:a&&c?c:s}),(0,t.jsxs)("section",{className:"max-w-6xl m-auto",children:[a&&(0,t.jsx)(b,{title:"Articles \xe0 la une",articles:c,carousel:!0}),(0,t.jsx)(b,{title:r?r.title:"Tous nos articles",articles:s,carousel:!1,categories:l,tags:!0})]})]})}},1249:function(e,s,l){"use strict";l.r(s),l.d(s,{__N_SSG:function(){return r}});var t=l(5893),a=l(7193);let c=e=>{let{articles:s,content:l}=e;return(0,t.jsx)(a.BlogWholePage,{articles:s,category:l})};var r=!0;s.default=c}},function(e){e.O(0,[5445,2013,1456,2867,3748,6823,9774,2888,179],function(){return e(e.s=97)}),_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.