1import{j as e,m as a,u,d as p,bg as h,a as w,ah as S,a8 as E}from"./vendor-ui-CCTMkLB_.js";import{r as l}from"./vendor-react-BaElq6v6.js";import{s as I}from"./index-CgIJMkZw.js";import{B as L}from"./BackButton-BwgRcJD1.js";import{J as T}from"./JustificatifInfo-BbjC3dcy.js";import{H as R}from"./vendor-utils-D2LWiAim.js";import{u as C}from"./usePageContent-cu2NeUiF.js";import"./vendor-supabase-BzBRK4Ua.js";import"./vendor-forms-Dpi1zlL9.js";const D=()=>{const[i,f]=l.useState("inscriptions"),[o,j]=l.useState({}),[b,v]=l.useState(!0),{content:t}=C("inscription-electorale"),c=l.useRef(null),m=l.useRef(null);l.useEffect(()=>{g()},[]);const g=async()=>{try{const{data:s,error:r}=await I.from("demarche_documents").select("*").in("module",["cerfa_liste_electorale_francais","cerfa_liste_electorale_municipal","cerfa_liste_electorale_europeen"]);if(r)throw r;if(s){const y=s.find(n=>n.module==="cerfa_liste_electorale_francais"),N=s.find(n=>n.module==="cerfa_liste_electorale_municipal"),_=s.find(n=>n.module==="cerfa_liste_electorale_europeen");j({cerfa_francais:y,cerfa_municipal:N,cerfa_europeen:_})}}catch(s){console.error("Error fetching documents:",s)}finally{v(!1)}},x=s=>{f(s);let r;switch(s){case"inscriptions":r=c;break;case"europeennes":r=m;break;default:r=c}r&&r.current&&r.current.scrollIntoView({behavior:"smooth",block:"start"})},d=(s,r)=>b?e.jsx("span",{className:"ml-2 text-gray-400",children:"(chargement...)"}):s?e.jsxs("a",{href:s.file_url,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 px-4 py-2 bg-blue-50 text-blue-700 rounded-lg hover:bg-blue-100 transition-colors text-sm mt-2",children:[e.jsx(E,{className:"w-4 h-4"}),r]}):e.jsx("span",{className:"text-gray-400 text-sm ml-2",children:"(formulaire bientôt disponible)"});return e.jsxs("div",{className:"min-h-screen bg-gray-50",children:[e.jsxs(R,{children:[e.jsx("title",{children:"Inscription electorale - Pollestres"}),e.jsx("meta",{name:"description",content:"Inscrivez-vous sur les listes electorales de la commune de Pollestres."})]}),e.jsxs(a.div,{className:"relative h-[400px] overflow-hidden",initial:{opacity:0}
1,animate:{opacity:1},children:[e.jsxs("div",{className:"absolute inset-0",children:[e.jsx("img",{src:"https://medias.pollestres.com/files/image-pour-le-site/bandeaux/image/2025/05/20250507-092937-3pp2ib-inscription-electorale.webp",alt:"Inscription électorale",className:"w-full h-full object-cover","aria-describedby":"desc-inscription-electorale-hero"}),e.jsx("p",{id:"desc-inscription-electorale-hero",className:"sr-only",children:"Photographie illustrant l'inscription sur les listes électorales avec une urne transparente et des bulletins de vote, représentant l'exercice du droit de vote à Pollestres."}),e.jsx("div",{className:"absolute inset-0 bg-gradient-to-r from-blue-900/80 to-transparent"})]}),e.jsx("div",{className:"relative container mx-auto px-4 h-full flex items-center",children:e.jsxs("div",{className:"max-w-2xl text-white",children:[e.jsx(a.h1,{className:"text-4xl md:text-5xl font-bold mb-4",initial:{opacity:0,y:20},animate:{opacity:1,y:0},children:"Inscription électorale"}),e.jsx(a.p,{className:"text-xl opacity-90",initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{delay:.2},children:"Exercez votre droit de vote"})]})})]}),e.jsxs("div",{className:"container mx-auto px-4 py-8",children:[e.jsx("div",{className:"mb-1",children:e.jsx(L,{to:"/services/demarches-administratives"})}),e.jsx(T,{}),e.jsxs("div",{className:"container mx-auto px-4 py-8 flex flex-col md:flex-row gap-8",children:[e.jsx(a.aside,{className:"md:w-64 flex-shrink-0",initial:{opacity:0,x:-20},animate:{opacity:1,x:0},transition:{duration:.6},children:e.jsx("div",{className:"sticky top-24 bg-white rounded-lg shadow-md p-4",children:e.jsx("nav",{children:e.jsxs("ul",{className:"space-y-2",children:[e.jsx("li",{children:e.jsxs("button",{onClick:()=>x("inscriptions"),className:`w-full text-left px-4 py-3 rounded-md transition-colors flex items-center justify-between ${i==="inscriptions"?"bg-blue-50 text-blue-700":"hover:bg-gray-50"}`,children:[e.jsxs("div",{className:"flex items-center",children:[e.jsx(u,{className:`w-5 h-5 mr-2 ${i==="inscriptions"?"text-blue-600":"text-gray-400"}`}),e.jsx("span",{children:"INSCRIPTIONS SUR LES LISTES ELECTORALES"})]}),e.jsx(p,{className:`w-4 h-4 transition-transform ${i==="inscriptions"?"rotate-90 text-blue-600":"text-gray-400"}`})]})}),e.jsx("li",{children:e.jsxs("button",{onClick:()=>x("europeennes"),className:`w-full text-left px-4 py-3 rounded-md transition-colors flex items-center justify-between ${i==="europeennes"?"bg-blue-50 text-blue-700":"hover:bg-gray-50"}`,children:[e.jsxs("div",{className:"flex items-center",children:[e.jsx(h,{className:`w-5 h-5 mr-2 ${i==="europeennes"?"text-blue-600":"text-gray-400"}`}),e.jsx("span",{children:"LE VOTE à POLLESTRES"})]}),e.jsx(p,{className:`w-4 h-4 transition-transform ${i==="europeennes"?"rotate-90 text-blue-600":"text-gray-400"}`})]})})]})})})}),e.jsx("div",{className:"flex-grow",children:e.jsxs("div",{className:"space-y-16",children:[e.jsx("section",{id:"inscriptions",ref:c,children:e.jsx(a.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},className:"bg-white rounded-lg shadow-lg overflow-hidden",children:e.jsxs("div",{className:"p-8",children:[e.jsxs("h2",{className:"text-2xl font-bold mb-6 flex items-center",children:[e.jsx(u,{className:"w-6 h-6 text-blue-600 mr-2"}),t.inscriptions?.title||"INSCRIPTIONS SUR LES LISTES ELECTORALES"]}),e.jsxs("div",{className:"prose max-w-none prose-a:text-blue-600 hover:prose-a:text-blue-800",children:[e.jsx("div",{dangerouslySetInnerHTML:{__html:t.inscriptions?.content||""}}),e.jsx("h3",{className:"text-xl font-semibold mt-8 mb-4",children:t.formulaires_pieces?.title||"Formulaire à remplir et pièces à fournir"}),e.jsx("div",{dangerouslySetInnerHTML:{__html:t.formulaires_pieces?.content||""}}),e.jsx("div",{className:"not-prose my-4",children:d(o.cerfa_francais,"Formulaire Cerfa de demande d'inscription sur les listes électorale à l'usage des citoyens français")}),e.jsx("h3",{className:"text-xl font-semibold mt-8 mb-4",children:t.ressortissants_europeens?.title||"Pour les ressortissants européens :"}),e.jsx("div",{dangerouslySetInnerHTML:{__html:t.ressortissants_europeens?.content||""}}),e.jsxs("div",{className:"not-prose flex flex-col gap-2 my-4",children:[d(o.cerfa_municipal,"Formulaire CERFA de demande d'inscription sur les listes électorales pour les élections municipales"),d(o.cerfa_europeen,"Formulaire CERFA de demande d'inscription sur les listes électorales pour l'élection des représentants français au Parlement Européen")]}),e.jsx("div",{className:"not-prose bg-yellow-50 rounded-lg p-6 my-6 border-l-4 border-yellow-500",children:e.jsxs("div",{className:"text-yellow-800 flex items-start gap-3",children:[e.jsx(w,{className:"w-6 h-6 text-yellow-600 flex-shrink-0"}),e.jsx("div",{dangerouslySetInnerHTML:{__html:t.avertissement?.content||""}})]})})]})]})})}),e.jsx("section",{id:"europeennes",ref:m,children:e.jsx(a.div,{initial:{opacity:0,y:20}
1,animate:{opacity:1,y:0},className:"bg-blue rounded-lg shadow-lg overflow-hidden",children:e.jsxs("div",{className:"p-8",children:[e.jsxs("h2",{className:"text-2xl font-bold mb-6 flex items-center",children:[e.jsx(h,{className:"w-6 h-6 text-blue-600 mr-2"}),t.bureaux_vote?.title||"BUREAUX DE VOTE à POLLESTRES"]}),e.jsx("div",{className:"prose max-w-none prose-a:text-blue-600 hover:prose-a:text-blue-800",children:e.jsx("div",{dangerouslySetInnerHTML:{__html:t.bureaux_vote?.content||""}})}),e.jsx("div",{className:"bg-green-50 rounded-lg p-6 my-8",children:e.jsxs("div",{className:"flex items-start gap-3",children:[e.jsx(S,{className:"w-6 h-6 text-green-600 flex-shrink-0 self-start",style:{marginTop:"2px"}}),e.jsxs("div",{children:[e.jsx("h3",{className:"text-lg font-semibold mb-2 text-green-800",children:t.bon_a_savoir?.title||"Bon à savoir"}),e.jsx("div",{className:"text-green-700 text-justify",children:e.jsx("div",{dangerouslySetInnerHTML:{__html:t.bon_a_savoir?.content||""}})})]})]})})]})})})]})})]})]})]})};export{D as default};
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.