1import{p as c,o as m}from"./forms-client.CbQX6UwZ.js";const t=document.getElementById("contact-form"),s=document.getElementById("form-status"),r=t?.dataset.webhook||"";document.getElementById("email-block")?.addEventListener("click",()=>{t&&(t.scrollIntoView({behavior:"smooth",block:"center"}),t.classList.remove("flash"),t.offsetWidth,t.classList.add("flash"),setTimeout(()=>{document.getElementById("cf-firstname")?.focus({preventScroll:!0})},500))});function l(a,i){s&&(s.textContent=a,s.classList.toggle("error",i),s.hidden=!1)}if(t){const a=t.querySelector('button[type="submit"]')?.textContent??"";t.addEventListener("submit",async i=>{if(i.preventDefault(),!t.reportValidity())return;const e=new FormData(t);if(e.get("website")?.length)return;const n={formType:"contact",submittedAt:new Date().toISOString(),page:window.location.pathname,prenom:String(e.get("firstname")||""),nom:String(e.get("lastname")||""),email:String(e.get("email")||""),sujet:String(e.get("subject")||""),message:String(e.get("message")||"")},o=t.querySelector('button[type="submit"]');r?(o&&(o.disabled=!0,o.textContent="Envoi en coursâ¦"),await c(r,n)?(t.reset(),l(t.dataset.success||"Message envoyé.",!1)):l(t.dataset.error||"L'envoi a échoué.",!0),o&&(o.disabled=!1,o.textContent=a)):m(t.dataset.email||"[email protected]",`[Site] ${n.sujet}`,`${n.prenom} ${n.nom} <${n.email}> 2 3${n.message}`)})}
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.