1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[847],{1499:()=>{},2526:(e,l,t)=>{"use strict";t.d(l,{K:()=>i,Q:()=>n});var r=t(4232);function n(e,l,t){return Object.freeze({instance:e,context:l,container:t})}function i(e,l){return null==l?function(l,t){let n=(0,r.useRef)(void 0);return n.current||(n.current=e(l,t)),n}:function(t,n){let i=(0,r.useRef)(void 0);i.current||(i.current=e(t,n));let a=(0,r.useRef)(t),{instance:s}=i.current;return(0,r.useEffect)(function(){a.current!==t&&(l(s,t,a.current),a.current=t)},[s,t,l]),i}}},3847:(e,l,t)=>{"use strict";t.r(l),t.d(l,{default:()=>k});var r=t(7876),n=t(6895);t(1499);var i=t(4587),a=t.n(i),s=t(8230),o=t.n(s),d=t(9099),c=t(4232),u=t(5073);function f(){return(0,u.U$)().map}var p=t(4027),m=t(6002),x=t(7152),h=t(5726),v=t(2526);let g=(0,h.wk)(function(e,l){let t=new n.Popup(e,l.overlayContainer);return(0,v.Q)(t,l)},function(e,l,{position:t},r){(0,c.useEffect)(function(){let{instance:n}=e;function i(e){e.popup===n&&(n.update(),r(!0))}function a(e){e.popup===n&&r(!1)}return l.map.on({popupopen:i,popupclose:a}),null==l.overlayContainer?(null!=t&&n.setLatLng(t),n.openOn(l.map)):l.overlayContainer.bindPopup(n),function(){l.map.off({popupopen:i,popupclose:a}),l.overlayContainer?.unbindPopup(),l.map.removeLayer(n)}},[e,l,r,t])});var b=t(7025),_=t(1247),y=t(5555),w=t(3349);function j(e){let{filteredLieux:l,selectedLieuId:t,onBoundsChange:r}=e,n=f(),i=(0,c.useRef)(null),a=e=>{r(l.filter(l=>{var r,n;return!!(null==(r=l.field_geolocalisation)?void 0:r.lat)&&!!(null==(n=l.field_geolocalisation)?void 0:n.lon)&&(!!t&&l.id===t||e.contains([l.field_geolocalisation.lat,l.field_geolocalisation.lon]))}))};return!function(e){let l=f();(0,c.useEffect)(function(){return l.on(e),function(){l.off(e)}},[l,e])}({moveend:()=>{let e=n.getBounds();i.current=e,a(e)},zoomend:()=>{let e=n.getBounds();i.current=e,a(e)}}),(0,c.useEffect)(()=>{let e=setTimeout(()=>{let e=n.getBounds();i.current=e,a(e)},100);return()=>clearTimeout(e)},[n,l,t]),null}delete n.Icon.Default.prototype._getIconUrl,n.Icon.Default.mergeOptions({iconRetinaUrl:"https://cdnjs.cloudflare.com/ajax/libs/leaflet/1.9.4/images/marker-icon-2x.png",iconUrl:"https://cdnjs.cloudflare.com/ajax/libs/leaflet/1.9.4/images/marker-icon.png",shadowUrl:"https://cdnjs.cloudflare.com/ajax/libs/leaflet/1.9.4/images/marker-shadow.png"});let N=e=>{if(!e)return[];let l=e.data||e,t=Array.isArray(l)?l:[l],r=[];return t.forEach(e=>{var l;e&&(e.id&&r.push(e.id.toString()),e.drupal_internal__tid&&r.push(e.drupal_internal__tid.toString()),(null==(l=e.attributes)?void 0:l.drupal_internal__tid)&&r.push(e.attributes.drupal_internal__tid.toString()),("string"==typeof e||"number"==typeof e)&&r.push(e.toString()))}),r};function k(e){var l,t,i,s;let{home:u=0,droite:f=0,initialLieux:h=[],initialVisiteTags:v=[],initialTypeLieuTags:k=[],initialLabels:C=[]}=e,E=(0,d.useRouter)(),[S,z]=(0,c.useState)(h),[A,I]=(0,c.useState)(v),[L,R]=(0,c.useState)(k),[B,O]=(0,c.useState)(C),[M,T]=(0,c.useState)(0===h.length),U=E.query.tag,[P,H]=(0,c.useState)(null);(0,c.useEffect)(()=>{if(U&&A.length>0){let l=decodeURIComponent(U),t=A.find(e=>(0,b.Ai)(e.name)===l);if(t){var e;H(t.id||(null==(e=t.drupal_internal__tid)?void 0:e.toString())||null)}else H(null)}else H(null)},[U,A]);let[D,W]=(0,c.useState)(null),[q,F]=(0,c.useState)([]),K=(0,c.useRef)(null),[Q,Z]=(0,c.useState)(!1),[$,V]=(0,c.useState)(!1),X=()=>{if(K.current){let{scrollTop:e,scrollHeight:l,clientHeight:t}=K.current;Z(e>0),V(e<l-t-1)}};(0,c.useEffect)(()=>{if(1===u&&0===f){let e=setTimeout(()=>{X()},100),l=K.current;return l?(l.addEventListener("scroll",X),()=>{clearTimeout(e),l.removeEventListener("scroll",X)}):()=>clearTimeout(e)}},[q,D,u,f]),(0,c.useEffect)(()=>{(async()=>{if(h.length>0)return T(!1);try{T(!0);let e=[fetch("/api/content/lieu?limit=1000"),fetch("/api/content/label")];1===u?e.push(fetch("/api/content/visite")):e.push(fetch("/api/content/type-lieu"));let[l,t,r]=await Promise.all(e);if(l.ok){let e=await l.json();z(Array.isArray(null==e?void 0:e.lieux)?e.lieux:[])}if(r.ok){let e=await r.json();1===u?I(Array.isArray(null==e?void 0:e.visite)?e.visite:[]):R(Array.isArray(null==e?void 0:e.type_lieu)?e.type_lieu:[])}if(t.ok){let e=await t.json();O(Array.isArray(null==e?void 0:e.labels)?e.labels:[])}}catch(e){console.error("Erreur lors du chargement des donn\xe9es:",e)}finally{T(!1)}})()},[u]);let G=1===u?A:L,J=(0,c.useMemo)(()=>
1{if(!P)return"Lieux visibles";let e=G.find(e=>{var l;return e.id===P||(null==(l=e.drupal_internal__tid)?void 0:l.toString())===P});return e?e.name:"Lieux visibles"},[P,G]),Y=(0,c.useMemo)(()=>{let e=new globalThis.Map;return G.forEach(l=>{l.id&&l.field_couleur&&(e.set(l.id,l.field_couleur),l.drupal_internal__tid&&e.set(l.drupal_internal__tid.toString(),l.field_couleur))}),e},[G]),ee=(0,c.useMemo)(()=>{let e=S;return 1===u?(e=S.filter(e=>N(e.field_tag_visite).length>0),P&&(e=e.filter(e=>N(e.field_tag_visite).includes(P)))):P&&(e=S.filter(e=>N(e.field_type_de_lieu).includes(P))),e},[S,P,u]),el=(0,c.useMemo)(()=>{let e=ee.filter(e=>{var l,t;return(null==(l=e.field_geolocalisation)?void 0:l.lat)&&(null==(t=e.field_geolocalisation)?void 0:t.lon)});if(0===e.length)return[49.055,4.003];let l=e.reduce((e,l)=>e+l.field_geolocalisation.lat,0),t=e.reduce((e,l)=>e+l.field_geolocalisation.lon,0);return[l/e.length,t/e.length]},[ee]),et=function(e){let l=arguments.length>1&&void 0!==arguments[1]&&arguments[1],t=e||"#121B60",r=l?26:20,i=l?4:2;return new n.Icon({iconUrl:"data:image/svg+xml;base64,".concat(btoa('\n <svg width="'.concat(r,'" height="').concat(r,'" viewBox="0 0 ').concat(r," ").concat(r,'" xmlns="http://www.w3.org/2000/svg">\n <circle cx="').concat(r/2,'" cy="').concat(r/2,'" r="').concat(r/2-i/2,'" fill="').concat(t,'" stroke="white" stroke-width="').concat(i,'"/>\n ').concat(l?'<circle cx="'.concat(r/2,'" cy="').concat(r/2,'" r="').concat(r/2+4,'" fill="none" stroke="').concat(t,'" stroke-width="2" opacity="0.5"/>'):"","\n </svg>\n "))),iconSize:[r,r],iconAnchor:[r/2,r/2],popupAnchor:[0,-r/2]})};return M?(0,r.jsx)("section",{className:"relative py-12",children:(0,r.jsx)("div",{className:"container px-4 mx-auto",children:(0,r.jsx)("div",{className:"h-[500px] flex items-center justify-center",children:(0,r.jsx)("p",{className:"text-gray-400",children:"Chargement de la carte..."})})})}):(0,r.jsxs)("section",{className:"container relative px-6 lg:px-0 mx-auto ".concat(1==u&&1==f?"py-12":"pb-12"),children:[(0,r.jsx)("style",{dangerouslySetInnerHTML:{__html:"\n .leaflet-container {\n border-radius: 1.5rem 0 0 1.5rem !important;\n overflow: hidden !important;\n }\n .leaflet-tile-container {\n border-radius: 1.5rem 0 0 1.5rem !important;\n }\n .scrollbar-hidden::-webkit-scrollbar {\n display: none;\n }\n .scrollbar-hidden {\n -ms-overflow-style: none;\n scrollbar-width: none;\n }\n"}}),1==u&&1==f&&(0,r.jsxs)("div",{className:" relative md:-mt-12 md:absolute md:-right-8 md:top-[15%] md:!w-[460px] lg:px-12 px-6 z-20 lg:pl-20 bg-secondary text-brand-navy rounded-3xl py-12 ",children:[(0,r.jsx)("div",{className:"flex gap-2 items-center",children:(0,r.jsx)(w._,{title:"TOURISME",subtitle:"TOURISME",iconClass:"ay-marker",dotClassName:"bg-[#FDEB19]"})}),(0,r.jsx)("h2",{className:"mb-4 text-[25px] font-bold text-primary",children:"D\xe9couvrir nos villages !"}),(0,r.jsx)("div",{className:"flex gap-4 mb-8",children:B.map(e=>{var l,t,n,i,s;let o=(null==(l=e.field_media)?void 0:l.data)||e.field_media,d=null==o||null==(n=o.field_media_image)||null==(t=n.uri)?void 0:t.url,c=(null==o||null==(s=o.field_media_image)||null==(i=s.uri)?void 0:i.alt)||e.title;return d?(0,r.jsx)("div",{className:"flex overflow-hidden relative justify-center items-center h-[100px] aspect-square",children:(0,r.jsx)(a(),{src:(0,b.rf)(d),alt:c,fill:!0,className:"object-contain p-2"})},e.id):null})}),(0,r.jsx)(y.A,{title:"D\xe9couvrir la carte interactive",icone:"ay-fleche",link:"/visiter",className:"text-primary border-primary hover:bg-primary hover:text-white z-[200]"})]}),(0,r.jsx)("div",{className:"hidden px-4 mx-auto mb-6 lg:block",children:(0,r.jsxs)("div",{className:"flex gap-4 pb-4 h-full",children:[(0,r.jsx)(y.A,{title:"Tous (".concat(S.length,")"),onClick:()=>{H(null),1===u&&0===f&&W(null)},className:"text-primary border-primary hover:bg-primary hover:text-white"}),G.map(e=>{var l;let t=e.id||(null==(l=e.drupal_internal__tid)?void 0:l.toString()),n=P===t,i=e.field_couleur||"#121B60";return(0,r.jsx)(y.A,{title:e.name,onClick:()=>{H(t||null),1===u&&0===f&&W(null)},className:"h-auto px-6 py-2 text-sm font-bold text-white whitespace-nowrap transition-all duration-500 hover:opacity-80 ".concat(n?"opacity-100":"opacity-100 hover:opacity-70"),style:{backgroundColor:i,...n&&{boxShadow:"0 0 0 4px ".concat(i,"60, 0 0 0 8px ").concat(i,"40")}}},e.id||e.drupal_internal__tid)})]})}),(0,r.jsxs)("div",{className:"relative h-[300px] lg:h-[500px] 2xl:h-[650px] rounded-3xl overflow-hidden z-0 ".concat(1==u&&1==f?"2xl:w-[75%] w-full z-0 xl:z-[1000]":"w-full"),children:[(0,r.jsx)("div",{className:"overflow-hidden relative w-full h-full rounded-3xl",children:(0,r.jsxs)(p.W,{center:el,zoom:13,style:{height:"100%",width:"100%",zIndex:0,borderRadius:"1.5rem"},scrollWheelZoom:!0,children:[(0,r.jsx)(m.e,{attribution:'\xa9 <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors',url:"https://osm.datagrandest.fr/mapcache/wmts/1.0.0/grey/default/webmercator/{z}/{y}/{x}.png"}),1===u&&0===f&&(0,r.jsx)(j,{filteredLieux:ee,selectedLieuId:(null==D?void 0:D.id)||null,onBoundsChange:e=>{F(e)}}),ee.filter(e=>{var l,t;return(null==(l=e.field_geolocalisation)?void 0:l.lat)&&(null==(t=e.field_geolocalisation)?void 0:t.lon)}).map(e=>{var l,t;let n=N(1===u?e.field_tag_visite:e.field_type_de_lieu)[0],i=n&&Y.get(n)||null,a=[e.field_geolocalisation.lat,e.field_geolocalisation.lon],s=(null==D?void 0:D.id)===e.id;return(0,r.jsx)(x.p,{position:a,icon:et(i,s),eventHandlers:{click:()=>{1===u&&0===f?W(e):0===u&&0===f&&W(e)}},children:(1!==u||0!==f)&&(0!==u||0!==f)&&(0,r.jsx)(g,{children:(0,r.jsxs)("div",{className:"p-2",children:[(0,r.jsx)("h3",{className:"mb-1 text-sm font-bold",children:e.title}),(null==(l=e.field_adresse)?void 0:l.address_line1)&&(0,r.jsxs)("p",{className:"mb-2 text-xs text-gray-600",children:[e.field_adresse.address_line1,e.field_adresse.locality&&", ".concat(e.field_adresse.locality)]}),(null==(t=e.path)?void 0:t.alias)&&(0,r.jsx)(o(),{href:e.path.alias,className:"text-xs text-primary hover:underline",children:"En savoir plus â"})]})})},e.id)})]})}),0===u&&0===f&&D&&(0,r.jsx)("div",{className:"absolute top-4 left-4 z-50 w-[90%] max-w-md lg:max-w-lg bg-white rounded-2xl shadow-2xl border border-primary/20 overflow-hidden max-h-[80vh] flex flex-col animate-in fade-in slide-in-from-right-5 duration-300",children:(0,r.jsx)("div",{className:"overflow-y-auto flex-1 px-6 pt-6 pb-6 scrollbar-thin scrollbar-thumb-primary/20 scrollbar-track-transparent",children:(0,r.jsxs)("div",{className:"flex flex-col pt-2 pb-2 h-full",children:[(0,r.jsxs)("button",{onClick:()=>W(null),className:"flex gap-2 items-center self-end mb-4 text-sm font-semibold cursor-pointer group text-primary hover:text-primary/80",children:[(0,r.jsx)("span",{className:"text-xl",children:"\xd7"}),(0,r.jsx)("span",{className:"transition-all duration-500 hover:pl-2",children:"Fermer"})]}),(0,r.jsxs)("div",{className:"flex-1",children:[(0,r.jsx)("h2",{className:"mb-4 text-2xl font-bold text-primary",children:D.title}),D.field_medias&&D.field_medias.length>0&&(0,r.jsx)("div",{className:"mb-4 space-y-3",children:D.field_medias.map((e,l)=>{var t,n,i,s,o;let d=e.data||e,c=null==d||null==(n=d.field_media_image)||null==(t=n.uri)?void 0:t.url,u=(null==d||null==(s=d.field_media_image)||null==(i=s.uri)?void 0:i.alt)||(null==d||null==(o=d.field_media_image)?void 0:o.alt)||D.title||"";return c?(0,r.jsx)("div",{className:"overflow-hidden relative w-full h-48 rounded-lg",children:(0,r.jsx)(a(),{src:(0,b.rf)(c),alt:u,fill:!0,className:"object-cover"})},l):null})}),D.field_description&&(0,r.jsx)(r.Fragment,{children:(0,r.jsx)(_.A,{value:"string"==typeof D.field_description?D.field_description:D.field_description.value||D.field_description.processed||"",className:"text-sm"})}),(null==(l=D.field_adresse)?void 0:l.address_line1)&&(0,r.jsxs)("div",{className:"mb-4",children:[(0,r.jsx)("p",{className:"mb-1 text-sm font-semibold text-fonce",children:"Adresse"}),(0,r.jsxs)("p",{className:"text-fonce",children:[D.field_adresse.address_line1,D.field_adresse.locality&&", ".concat(D.field_adresse.locality)]})]}),D.field_telephone&&(0,r.jsxs)("div",{className:"mb-4",children:[(0,r.jsx)("p",{className:"mb-1 text-sm font-semibold text-fonce",children:"T\xe9l\xe9phone"}),(0,r.jsx)("p",{className:"text-sm text-fonce",children:D.field_telephone})]}),(null==(t=D.path)?void 0:t.alias)&&(0,r.jsx)(o(),{href:D.path.alias,className:"inline-block px-6 py-2 mt-4 text-sm font-semibold text-white rounded-lg transition-colors bg-primary hover:bg-primary/90",children:"En savoir plus â"})]})]})})}),1===u&&0===f&&(0,r.jsxs)("div",{className:"flex lg:absolute lg:top-4 lg:right-4 lg:w-[90%] lg:max-w-md lg:max-h-[60vh] w-full max-h-[400px] mt-4 lg:mt-0 rounded-3xl overflow-hidden flex-col border border-primary/20 shadow-xl relative bg-white z-50 ".concat(D?"max-h-full":""),children:[!D&&(0,r.jsx)("div",{className:"sticky top-0 z-20 px-6 pt-6 pb-4 bg-white rounded-t-3xl border-b border-primary/10",children:(0,r.jsxs)("h3",{className:"text-xl font-bold uppercase text-primary",children:[J," (",ee.length,")",0===ee.length&&(0,r.jsxs)("span",{className:"block mt-2 text-sm font-normal text-red-500",children:["Aucun lieu trouv\xe9 avec ce filtre parmi les ",S.length," ","lieux charg\xe9s."]}),q.length!==ee.length&&ee.length>0&&(0,r.jsxs)("span",{className:"ml-2 text-sm font-normal text-fonce/70",children:["sur ",ee.length]})]})}),(0,r.jsxs)("div",{className:"flex absolute right-2 top-1/2 z-10 flex-col gap-2 -translate-y-1/2",children:[(0,r.jsx)("button",{onClick:()=>{K.current&&K.current.scrollBy({top:-200,behavior:"smooth"})},disabled:!Q,className:"p-2 rounded-full bg-white shadow-lg border border-primary/20 transition-all ".concat(Q?"text-primary hover:bg-primary hover:text-white cursor-pointer":"text-gray-300 cursor-not-allowed opacity-50"),"aria-label":"D\xe9filer vers le haut",children:(0,r.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:(0,r.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M5 15l7-7 7 7"})})}),(0,r.jsx)("button",{onClick:()=>{K.current&&K.current.scrollBy({top:200,behavior:"smooth"})},disabled:!$,className:"p-2 rounded-full bg-white shadow-lg border border-primary/20 transition-all ".concat($?"text-primary hover:bg-primary hover:text-white cursor-pointer":"text-gray-300 cursor-not-allowed opacity-50"),"aria-label":"D\xe9filer vers le bas",children:(0,r.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:(0,r.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 9l-7 7-7-7"})})})]}),(0,r.jsx)("div",{ref:K,className:"overflow-y-auto flex-1 px-6 pb-6 scrollbar-hidden ".concat(D?"pt-6":"pt-0"),children:D?(0,r.jsxs)("div",{className:"flex flex-col pt-2 pb-2 h-full",children:[(0,r.jsxs)("button",{onClick:()=>W(null),className:"flex gap-2 items-center mb-4 text-sm font-semibold cursor-pointer group text-primary hover:text-primary/80",children:[(0,r.jsx)("span",{className:"text-xl",children:"â"}),(0,r.jsx)("span",{className:"transition-all duration-500 hover:pl-2",children:"Retour \xe0 la liste"})]}),(0,r.jsxs)("div",{className:"flex-1",children:[(0,r.jsx)("h2",{className:"mb-4 text-2xl font-bold text-primary",children:D.title}),D.field_medias&&D.field_medias.length>0&&(0,r.jsx)("div",{className:"mb-4 space-y-3",children:D.field_medias.map((e,l)=>{var t,n,i,s,o;let d=e.data||e,c=null==d||null==(n=d.field_media_image)||null==(t=n.uri)?void 0:t.url,u=(null==d||null==(s=d.field_media_image)||null==(i=s.uri)?void 0:i.alt)||(null==d||null==(o=d.field_media_image)?void 0:o.alt)||D.title||"";return c?(0,r.jsx)("div",{className:"overflow-hidden relative w-full h-40 rounded-lg",children:(0,r.jsx)(a(),{src:(0,b.rf)(c),alt:u,fill:!0,className:"object-cover"})},l):null})}),D.field_description&&(0,r.jsx)(r.Fragment,{children:(0,r.jsx)(_.A,{value:"string"==typeof D.field_description?D.field_description:D.field_description.value||D.field_description.processed||"",className:"mb-4 text-sm"})}),(null==(i=D.field_adresse)?void 0:i.address_line1)&&(0,r.jsxs)("div",{className:"mb-4",children:[(0,r.jsx)("p",{className:"mb-1 text-sm font-semibold text-fonce",children:"Adresse"}),(0,r.jsxs)("p",{className:"text-fonce",children:[D.field_adresse.address_line1,D.field_adresse.locality&&", ".concat(D.field_adresse.locality)]})]}),D.field_telephone&&(0,r.jsxs)("div",{className:"mb-4",children:[(0,r.jsx)("p",{className:"mb-1 text-sm font-semibold text-fonce",children:"T\xe9l\xe9phone"}),(0,r.jsx)("p",{className:"text-sm text-fonce",children:D.field_telephone})]}),(0,r.jsxs)("div",{className:"flex gap-3 mt-4",children:[D.field_site_web&&(0,r.jsx)(o(),{href:D.field_site_web,target:"_blank",rel:"noreferrer",className:"inline-block px-6 py-2 text-sm font-semibold text-center text-white rounded-lg transition-colors w-fit bg-primary hover:bg-primary/90",children:"Visiter le site â"}),(null==(s=D.path)?void 0:s.alias)&&(0,r.jsx)(o(),{href:D.path.alias,className:"inline-block px-6 py-2 text-sm font-semibold text-center text-white rounded-lg transition-colors w-fit hover:text-white bg-secondary hover:bg-secondary/90",children:"Plus de d\xe9tails â"})]})]})]}):(0,r.jsx)("div",{className:"pt-2 pb-2",children:(0,r.jsx)("div",{className:"space-y-3",children:0===q.length?(0,r.jsx)("p",{className:"pb-2 text-sm text-fonce",children:0===ee.length?"Aucun lieu trouv\xe9 avec ce filtre.":"Aucun lieu visible dans cette zone. Zoomez ou d\xe9placez la carte."}):(0,r.jsxs)("div",{className:"grid grid-cols-1 gap-2 lg:grid-cols-2",children:[q.map(e=>{var l,t,n,i;
1let a=null!==D?D.id:null,s=1===u?(null==(l=e.field_tag_visite)?void 0:l.data)||e.field_tag_visite:(null==(t=e.field_type_de_lieu)?void 0:t.data)||e.field_type_de_lieu,o=(null==s?void 0:s.id)||(null==s||null==(n=s.drupal_internal__tid)?void 0:n.toString()),d=o&&Y.get(o)||"#121B60",c=a===e.id;return(0,r.jsxs)("button",{onClick:()=>W(e),className:"w-full text-left p-3 bg-white rounded-lg flex flex-col border-2 border-primary/20 items-start gap-2 hover:shadow-md transition-all opacity-50 hover:opacity-100 grayscale hover:grayscale-0 ".concat(c?"shadow-md ring-2 ring-primary/30":""),children:[(0,r.jsx)("div",{className:"hidden w-4 h-4 rounded-full",style:{backgroundColor:d}}),(0,r.jsxs)("h4",{className:"flex flex-col gap-2 w-full font-bold leading-tight text-primary",style:{color:d},children:[(0,r.jsx)("div",{className:"px-2 py-1 text-[10px] whitespace-nowrap h-fit text-white rounded-xl w-fit",style:{backgroundColor:d},children:null==s?void 0:s.name}),(0,r.jsxs)("div",{className:"flex flex-col gap-2",children:[e.title,(null==(i=e.field_adresse)?void 0:i.address_line1)&&(0,r.jsxs)("span",{className:"my-1 text-sm leading-tight text-fonce",children:[e.field_adresse.address_line1,e.field_adresse.locality&&", ".concat(e.field_adresse.locality)]})]})]})]},e.id)}),(0,r.jsx)("div",{className:"pb-2"})]})})})})]})]})]})}},4027:(e,l,t)=>{"use strict";t.d(l,{W:()=>a});var r=t(5073),n=t(6895),i=t(4232);let a=(0,i.forwardRef)(function({bounds:e,boundsOptions:l,center:t,children:a,className:s,id:o,placeholder:d,style:c,whenReady:u,zoom:f,...p},m){let[x]=(0,i.useState)({className:s,id:o,style:c}),[h,v]=(0,i.useState)(null),g=(0,i.useRef)(void 0);(0,i.useImperativeHandle)(m,()=>h?.map??null,[h]);let b=(0,i.useCallback)(i=>{if(null!==i&&!g.current){let a=new n.Map(i,p);g.current=a,null!=t&&null!=f?a.setView(t,f):null!=e&&a.fitBounds(e,l),null!=u&&a.whenReady(u),v((0,r.fB)(a))}},[]);(0,i.useEffect)(()=>()=>{h?.map.remove()},[h]);let _=h?i.createElement(r.dk,{value:h},a):d??null;return i.createElement("div",{...x,ref:b},_)})},5073:(e,l,t)=>{"use strict";t.d(l,{U$:()=>s,W4:()=>i,dk:()=>a,fB:()=>n});var r=t(4232);function n(e){return Object.freeze({__version:1,map:e})}function i(e,l){return Object.freeze({...e,...l})}let a=(0,r.createContext)(null);function s(){let e=(0,r.use)(a);if(null==e)throw Error("No context provided: useLeafletContext() can only be used in a descendant of <MapContainer>");return e}},5726:(e,l,t)=>{"use strict";t.d(l,{Nq:()=>u,wk:()=>f,X3:()=>p});var r=t(4232),n=t(8477),i=t(5073);function a(e,l){let t=(0,r.useRef)(l);(0,r.useEffect)(function(){l!==t.current&&null!=e.attributionControl&&(null!=t.current&&e.attributionControl.removeAttribution(t.current),null!=l&&e.attributionControl.addAttribution(l)),t.current=l},[e,l])}function s(e,l){let t=(0,r.useRef)(void 0);(0,r.useEffect)(function(){return null!=l&&e.instance.on(l),t.current=l,function(){null!=t.current&&e.instance.off(t.current),t.current=null}},[e,l])}var o=t(8420),d=t(2526);function c(e){return function(l){var t;let n=(0,i.U$)(),d=e((0,o.P)(l,n),n);return a(n.map,l.attribution),s(d.current,l.eventHandlers),t=d.current,(0,r.useEffect)(function(){return(n.layerContainer??n.map).addLayer(t.instance),function(){n.layerContainer?.removeLayer(t.instance),n.map.removeLayer(t.instance)}},[n,t]),d}}function u(e,l){var t;return t=c((0,d.K)(e,l)),(0,r.forwardRef)(function(e,l){let{instance:n,context:a}=t(e).current;(0,r.useImperativeHandle)(l,()=>n);let{children:s}=e;return null==s?null:r.createElement(i.dk,{value:a},s)})}function f(e,l){var t,c;return t=(0,d.K)(e),c=function(e,r){let n=(0,i.U$)(),d=t((0,o.P)(e,n),n);return a(n.map,e.attribution),s(d.current,e.eventHandlers),l(d.current,n,e,r),d},(0,r.forwardRef)(function(e,l){let[t,i]=(0,r.useState)(!1),{instance:a}=c(e,i).current;(0,r.useImperativeHandle)(l,()=>a),(0,r.useEffect)(function(){t&&a.update()},[a,t,e.children]);let s=a._contentNode;return s?(0,n.createPortal)(e.children,s):null})}function p(e,l){var t;return t=c((0,d.K)(e,l)),(0,r.forwardRef)(function(e,l){let{instance:n}=t(e).current;return(0,r.useImperativeHandle)(l,()=>n),null})}},6002:(e,l,t)=>{"use strict";t.d(l,{e:()=>s});var r=t(5726),n=t(8420),i=t(2526),a=t(6895);let s=(0,r.X3)(function({url:e,...l},t){let r=new a.TileLayer(e,(0,n.P)(l,t));return(0,i.Q)(r,t)},function(e,l,t){let{opacity:r,zIndex:n}=l;null!=r&&r!==t.opacity&&e.setOpacity(r),null!=n&&n!==t.zIndex&&e.setZIndex(n);let{url:i}=l;null!=i&&i!==t.url&&e.setUrl(i)})},7152:(e,l,t)=>{"use strict";t.d(l,{p:()=>s});var r=t(5726),n=t(2526),i=t(5073),a=t(6895);let s=(0,r.Nq)(function({position:e,...l},t){let r=new a.Marker(e,l);return(0,n.Q)(r,(0,i.W4)(t,{overlayContainer:r}))},function(e,l,t){l.position!==t.position&&e.setLatLng(l.position),null!=l.icon&&l.icon!==t.icon&&e.setIcon(l.icon),null!=l.zIndexOffset&&l.zIndexOffset!==t.zIndexOffset&&e.setZIndexOffset(l.zIndexOffset),null!=l.opacity&&l.opacity!==t.opacity&&e.setOpacity(l.opacity),null!=e.dragging&&l.draggable!==t.draggable&&(!0===l.draggable?e.dragging.enable():e.dragging.disable())})},8420:(e,l,t)=>{"use strict";function r(e,l){let t=e.pane??l.pane;return t?{...e,pane:t}:e}t.d(l,{P:()=>r})}}]);
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.