PageSourceSearch

https://www.commonfate.io/_next/static/chunks/pages/contact-d6054d7191c368ab.js

js commonfate.io collected 2026-10-02 14:55:52 UTC 6,229 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[335],{919:function(e,t,l){(window.__NEXT_P=window.__NEXT_P||[]).push(["/contact",function(){return l(9699)}])},7097:function(e,t,l){"use strict";var s=l(1527);t.Z=e=>{let{field:t,errors:l,label:a,multiLine:r,countryOptions:n,placeholder:i,register:o,required:c,size:u="full",type:d}=e,p=l[t];return(0,s.jsxs)("div",{className:"col-span-2 space-y-2 ".concat("1/2"===u&&"lg:col-span-1"),children:[(0,s.jsxs)("label",{className:"block text-sm ".concat(p?"text-pink-100":"text-white"),children:[c&&"* ",a]}),"select"===d?(0,s.jsxs)("select",{className:"w-full rounded-md border-2 bg-neutral-700 p-3 text-neutral-300 selection:bg-blue-100 placeholder:text-neutral-400 focus:outline-none ".concat(p?"border-pink-100 focus:border-pink-100 focus:ring-pink-100":"border-neutral-400 focus:border-blue-100 focus:ring-blue-100"),...o(t,{required:"This field is required.",pattern:/[^{placeholder}]/}),defaultValue:"placeholder",children:[(0,s.jsx)("option",{value:"placeholder",disabled:!0,children:null!=i?i:""},"placeholder"),null==n?void 0:n.map(e=>(0,s.jsx)("option",{value:e.name,children:e.name},e.code))]}):r?(0,s.jsx)("textarea",{className:"h-72 w-full rounded-md border-2 bg-neutral-700 p-3 text-neutral-300 selection:bg-blue-100 placeholder:text-neutral-400 focus:outline-none ".concat(p?"border-pink-100 focus:border-pink-100 focus:ring-pink-100":"border-neutral-400 focus:border-blue-100 focus:ring-blue-100"),placeholder:null!=i?i:"",...o(t,{required:"This field is required."})}):(0,s.jsx)("input",{type:d,className:"w-full rounded-md border-2 bg-neutral-700 p-3 text-neutral-300 selection:bg-blue-100 placeholder:text-neutral-400 focus:outline-none ".concat(p?"border-pink-100 focus:border-pink-100 focus:ring-pink-100":"border-neutral-400 focus:border-blue-100 focus:ring-blue-100"),placeholder:null!=i?i:"",...o(t,{required:c&&"This field is required.",pattern:"email"===d?{value:/^[^@\s]+@[^@\s]+\.[^@\s]+$/,message:"Please enter a valid email address"}:void 0})})]})}},5687:function(e,t,l){"use strict";var s=l(1527);t.Z=e=>{let{category:t,body:l,heading:a,textAlign:r="center",accent:n="blue"}=e,i=(()=>{switch(n){case"blue":return"text-blue-300";case"pink":return"text-pink-300";case"green":return"text-green-300"}})();return(0,s.jsxs)("div",{className:"max-w-[800px] lg:mb-6 ".concat("left"===r?"lg:text-left":"mx-auto text-center "),children:[(0,s.jsx)("div",{className:"text-sm font-semibold leading-4 lg:text-base lg:leading-5 ".concat(i),children:t}),(0,s.jsx)("div",{className:"mt-2 text-[26px] font-light leading-8 lg:text-[40px] lg:leading-[48px]",children:a}),(0,s.jsx)("div",{className:"text-neutral-400 lg:left-6 lg:text-lg",children:l})]})}},9699:function(e,t,l){"use strict";l.r(t),l.d(t,{default:function(){return pages_contact}});var s=l(1527),a=l(7097),r=l(5086),n=l(959),i=l(8177);let o=[{field:"firstName",label:"First Name",type:"text",required:!0,size:"1/2"},{field:"lastName",label:"Last Name",type:"text",required:!0,size:"1/2"},{field:"email",label:"Email",type:"email",required:!0,size:"1/2"},{field:"company",label:"Company",type:"text",required:!1,size:"1/2"},{field:"message",label:"How can we help?",type:"text",required:!0,multiLine:!0,placeholder:"Type your message..."}];var contact_form=()=>{let{register:e,handleSubmit:t,reset:l,formState:{errors:c,isSubmitSuccessful:u}}
1=(0,i.cI)(),[d,p]=(0,n.useState)(!1),[x,m]=(0,n.useState)(!1),[f,g]=(0,n.useState)(!1);return(0,s.jsxs)("form",{onSubmit:t(e=>{console.log(e),p(!0),r.Z.post("/api/contact",e).then(e=>{200===e.status?(m(!0),g(!1)):(m(!1),g(!0))}).finally(()=>{p(!1),setTimeout(()=>{m(!1),g(!1)},3e3)})}),children:[(0,s.jsx)("div",{className:"grid w-full grid-cols-2 gap-4",children:o.map(t=>(0,s.jsx)(a.Z,{errors:c,register:e,...t},t.field))}),(0,s.jsxs)("button",{type:"submit",className:"mt-4 rounded-full bg-blue-300 py-[10px] px-6 text-xs leading-3 tracking-[-0.25px] text-white outline-none transition duration-100 hover:scale-105 focus:outline-blue-200",children:[d&&(0,s.jsxs)("svg",{role:"status",className:"mr-3 inline h-4 w-4 animate-spin text-white",viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,s.jsx)("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"#E5E7EB"}),(0,s.jsx)("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"currentColor"})]}),x&&"Success"||f&&"Error"||"Submit"]})]})},c=l(5687),u=l(74),d=l(7246),p=l(4722),x=l(7959),m=l.n(x),pages_contact=()=>(0,s.jsxs)("div",{className:"relative mx-auto grid gap-16 px-4 md:px-12 lg:grid-cols-2 lg:px-16 2xl:px-32",children:[(0,s.jsx)(p.Z,{pageTitle:"Contact | Common Fate"}),(0,s.jsxs)("div",{children:[(0,s.jsx)(c.Z,{textAlign:"left",category:"Contact",heading:"Get in touch with us",body:"If you've got any questions or feedback for us, please send us a message."}),(0,s.jsx)("div",{className:"mt-4 leading-5 text-white",children:"Stay connected with us"}),(0,s.jsx)("div",{className:"mt-4 mb-6 flex gap-4 ",children:d.t.socials.map(e=>(0,s.jsx)(u.Z,{className:"h-6",...e},e.href))})]}),(0,s.jsx)(contact_form,{}),(0,s.jsx)(m(),{className:"absolute left-[-12] -z-10 w-[100vw] object-cover object-center opacity-75",src:"/brands/bkg-galaxy-lights.jpg",alt:"Galaxy Lights",fill:!0,layout:"fill"})]})}},function(e){e.O(0,[959,86,774,888,179],function(){return e(e.s=919)}),_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.