import{s as D}from"../chunks/scheduler.aZRR5A_O.js";import{S as F,i as G,g,s as w,r as J,h as b,x as H,c as P,u as K,j as k,f,k as j,a as $,v as N,d as Q,t as R,w as V,A as W,m as A,n as I,y as m,o as q}from"../chunks/index.kYoizZ4A.js";import{e as M}from"../chunks/each.-oqiv04n.js";import{I as X}from"../chunks/Info.ITY44f4q.js";const Y=async({fetch:c})=>({articles:await(await c("/api/articles")).json()}),ne=Object.freeze(Object.defineProperty({__proto__:null,load:Y},Symbol.toStringTag,{value:"Module"}));function T(c,a,u){const s=c.slice();return s[1]=a[u],s}function U(c){let a,u,s,r=c[1].meta.title+"",v,h,y,o,i,C="Publié le :",p,l=c[1].meta.date+"",e,n,t,x=c[1].meta.author+"",z,S;return{c(){a=g("li"),u=g("h2"),s=g("a"),v=A(r),y=w(),o=g("p"),i=g("b"),i.textContent=C,p=w(),e=A(l),n=A(" par "),t=g("i"),z=A(x),S=w(),this.h()},l(d){a=b(d,"LI",{class:!0});var _=k(a);u=b(_,"H2",{});var L=k(u);s=b(L,"A",{href:!0});var O=k(s);v=I(O,r),O.forEach(f),L.forEach(f),y=P(_),o=b(_,"P",{class:!0});var E=k(o);i=b(E,"B",{"data-svelte-h":!0}),H(i)!=="svelte-1y3xx1s"&&(i.textContent=C),p=P(E),e=I(E,l),n=I(E," par "),t=b(E,"I",{});var B=k(t);z=I(B,x),B.forEach(f),E.forEach(f),S=P(_),_.forEach(f),this.h()},h(){j(s,"href",h=c[1].path),j(o,"class","pt-2"),j(a,"class","ml-0 list-none px-4 pb-4 my-4 rounded-lg border-1 border-color-base-100 bg-neutral-800 hover:bg-neutral-700")},m(d,_){$(d,a,_),m(a,u),m(u,s),m(s,v),m(a,y),m(a,o),m(o,i),m(o,p),m(o,e),m(o,n),m(o,t),m(t,z),m(a,S)},p(d,_){_&1&&r!==(r=d[1].meta.title+"")&&q(v,r),_&1&&h!==(h=d[1].path)&&j(s,"href",h),_&1&&l!==(l=d[1].meta.date+"")&&q(e,l),_&1&&x!==(x=d[1].meta.author+"")&&q(z,x)},d(d){d&&f(a)}}}function Z(c){let a,u="Articles",s,r,v,h,y="Articles publiés",o,i,C;r=new X({props:{info:`Cette section sert pour tout les articles généralistes qui ne peuvent
  pas réellement être considérés comme des guides. Publiez ce que vous voulez !`,markdown:"false"}});let p=M(c[0].articles),l=[];for(let e=0;e<p.length;e+=1)l[e]=U(T(c,p,e));return{c(){a=g("h1"),a.textContent=u,s=w(),J(r.$$.fragment),v=w(),h=g("h2"),h.textContent=y,o=w(),i=g("ul");for(let e=0;e<l.length;e+=1)l[e].c();this.h()},l(e){a=b(e,"H1",{"data-svelte-h":!0}),H(a)!=="svelte-a2vclf"&&(a.textContent=u),s=P(e),K(r.$$.fragment,e),v=P(e),h=b(e,"H2",{"data-svelte-h":!0}),H(h)!=="svelte-6efz5p"&&(h.textContent=y),o=P(e),i=b(e,"UL",{class:!0});var n=k(i);for(let t=0;t<l.length;t+=1)l[t].l(n);n.forEach(f),this.h()},h(){j(i,"class","")},m(e,n){$(e,a,n),$(e,s,n),N(r,e,n),$(e,v,n),$(e,h,n),$(e,o,n),$(e,i,n);for(let t=0;t<l.length;t+=1)l[t]&&l[t].m(i,null);C=!0},p(e,[n]){if(n&1){p=M(e[0].articles);let t;for(t=0;t<p.length;t+=1){const x=T(e,p,t);l[t]?l[t].p(x,n):(l[t]=U(x),l[t].c(),l[t].m(i,null))}for(;t<l.length;t+=1)l[t].d(1);l.length=p.length}},i(e){C||(Q(r.$$.fragment,e),C=!0)},o(e){R(r.$$.fragment,e),C=!1},d(e){e&&(f(a),f(s),f(v),f(h),f(o),f(i)),V(r,e),W(l,e)}}}function ee(c,a,u){let{data:s}=a;return c.$$set=r=>{"data"in r&&u(0,s=r.data)},[s]}class re extends F{constructor(a){super(),G(this,a,ee,Z,D,{data:0})}}export{re as component,ne as universal};
