1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3610],{3637:function(e,t,s){(window.__NEXT_P=window.__NEXT_P||[]).push(["/en/captura-de-datos",function(){return s(6625)}])},717:function(e,t,s){"use strict";var r=s(5893),a=s(7294),n=s(7397),o=s(8666),l=s(6195),i=s(8154),c=s(1656),u=s(4362);let d=e=>e.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/\s+/g,"");t.Z=()=>{let{formID:e,formFields:t,formData:s,setFormData:h,initialFormData:p}=(0,a.useContext)(o.K),[f,m]=(0,a.useState)({}),[j,x]=(0,a.useState)(!1),[v,w]=(0,a.useState)(!1),[N,_]=(0,a.useState)({show:!1,status:"",message:""}),g=(e,t)=>{h(s=>({...s,[e]:v?"":t})),m(s=>{let r={...s};return t?delete r[e]:r[e]=!0,r})},E=()=>{let e=Object.keys(s).some(e=>!s[e]&&0!==s[e]);return e&&m(e=>{let t={...e};return Object.keys(s).forEach(e=>{s[e]||0===s[e]?delete t[e]:t[e]=!0}),t}),e},b=async t=>{if(t.preventDefault(),E())return;let r=new FormData;Object.entries(s).forEach(e=>{let[t,s]=e;r.append(t,s)});try{x(!0);let t=await fetch((0,l.O)(e),{method:"POST",body:r});if(t.ok)await t.json(),w(!0),h({...p}),m({});else throw Error("Error en la respuesta del servidor")}catch(e){_({show:!0,status:"error",message:"Se produjo un error al intentar enviar tu mensaje. Por favor, int\xe9ntelo de nuevo m\xe1s tarde."})}finally{x(!1)}};return(0,r.jsxs)(c.J,{"data-scroll-repeat":!0,"data-scroll":!0,"data-scroll-class":"in-view","data-scroll-offset":"25%",children:[(0,r.jsxs)("form",{onSubmit:b,children:[(0,r.jsxs)("div",{className:"group form-container",children:[(0,r.jsxs)("div",{className:"title",children:[(0,r.jsx)("h2",{children:"Captura de datos Club Experto Plycem"}),(0,r.jsx)("div",{className:"paragraph"})]}),(0,r.jsxs)("div",{className:"fields ".concat(s.tipo&&"recursoshumanos"===d(s.tipo)?"file-input":""," ").concat(s.tipo&&"asesoriatecnica"===d(s.tipo)?"file-input":""),children:[t.map((e,t)=>{let a=e.options.find(e=>e.startsWith("data-show-")),n=a?d(a.split(":")[1]):null;return!n||s.tipo&&d(s.tipo)===n?(0,r.jsx)(i.Y,{field:e,handleInputChange:g,index:t,errors:f},"contact-form-".concat(t,"-").concat(v)):null}),(0,r.jsx)("div",{className:"button-wrapper col-2",children:(0,r.jsxs)("button",{type:"submit",className:"",children:[(0,r.jsx)("span",{children:j?"Enviando":"Enviar"}),j?(0,r.jsx)("div",{className:"spinner"}):(0,r.jsx)(n.Q,{src:"/icons/long-arrow-right.svg"})]})})]})]}),N.show&&(0,r.jsx)("span",{className:"form-request-message ".concat(N.status),children:N.message})]}),v&&(0,r.jsx)(u.Z,{handleCloseModal:()=>{h({...p}),w(!1),m({})}})]})}},6625:function(e,t,s){"use strict";s.r(t),s.d(t,{__N_SSG:function(){return h}});var r=s(5893),a=s(9008),n=s.n(a),o=s(5935),l=s(5475),i=s(717),c=s(8666),u=s(1665),d=s(1412),h=!0;t.default=e=>{let{page:t,form:s,yoast:a}=e,h=(0,u.Z)(s);return(0,r.jsxs)(c.Xp.Provider,{value:{page:t,form:s},children:[(0,r.jsx)(n(),{children:(0,o.ZP)(a)}),t&&s&&(0,r.jsxs)(d.J,{children:[(0,r.jsx)(l.Z,{ctaTitle:"Go to the Form",showButton:!0}),(0,r.jsx)(c.K.Provider,{value:{...h},children:(0,r.jsx)(i.Z,{})})]})]})}}},function(e){e.O(0,[5935,6363,9774,2888,179],function(){return e(e.s=3637)}),_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.