PageSourceSearch

https://edtechhackai.com/assets/Register-BANL1Knx.js

js edtechhackai.com collected 2026-10-10 00:25:54 UTC 12,016 bytes, 6 lines download raw bytes

1import{d as U,o as u,j as e,w as h,X as q,x as K,y as G,B as S,C as J,b as _,c as Y,z as Z,a as $,v as w}from"./index-Blp889zD.js";import{u as Q,F as X,a as o,b as l,c,S as f,d,e as y,f as b,g as N,h as C,i as m,L as W,t as ee}from"./select-ZCyyovbj.js";import{g as ae}from"./errorHandling-DUTh5Q_K.js";import{S as se}from"./SEO-BIi4bd_y.js";import{N as te,F as re}from"./Footer-vJOXNAKI.js";import{I as g}from"./input-XCyysB3g.js";import{O as P,C as R,a as ne,T as k,D as E,R as ie,P as oe}from"./sheet-VLpb04Jz.js";import{C as le}from"./circle-check-big-BjRaodBs.js";import{o as ce,s as x,l as de}from"./types-4og3oiYD.js";import"./index-B-Meyd4d.js";import"./index-mhsy8lZS.js";import"./index-Dqsqqo5Q.js";import"./chevron-down-BMhHNUSo.js";/**
2 * @license lucide-react v0.462.0 - ISC
3 *
4 * This source code is licensed under the ISC license.
5 * See the LICENSE file in the root directory of this source tree.
6 */const I=U("UserPlus",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]]),me=ie,xe=oe,F=u.forwardRef(({className:t,...r},i)=>e.jsx(P,{ref:i,className:h("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",t),...r}));F.displayName=P.displayName;const B=u.forwardRef(({className:t,children:r,...i},p)=>e.jsxs(xe,{children:[e.jsx(F,{}),e.jsxs(R,{ref:p,className:h("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",t),...i,children:[r,e.jsxs(ne,{className:"absolute right-4 top-4 roun
6ded-sm opacity-70 ring-offset-background transition-opacity data-[state=open]:bg-accent data-[state=open]:text-muted-foreground hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none",children:[e.jsx(q,{className:"h-4 w-4"}),e.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));B.displayName=R.displayName;const D=({className:t,...r})=>e.jsx("div",{className:h("flex flex-col space-y-1.5 text-center sm:text-left",t),...r});D.displayName="DialogHeader";const z=u.forwardRef(({className:t,...r},i)=>e.jsx(k,{ref:i,className:h("text-lg font-semibold leading-none tracking-tight",t),...r}));z.displayName=k.displayName;const M=u.forwardRef(({className:t,...r},i)=>e.jsx(E,{ref:i,className:h("text-sm text-muted-foreground",t),...r}));M.displayName=E.displayName;const ue=ce({category:x().min(1,{message:"Please select a category"}),firstName:x().trim().min(1,{message:"First name is required"}).max(100),lastName:x().trim().min(1,{message:"Last name is required"}).max(100),email:x().trim().email({message:"Please enter a valid email"}).max(255),joiningMode:x().min(1,{message:"Please select a joining mode"}),paperId:x().trim().max(50).optional().or(de("")),phone:x().trim().min(1,{message:"Phone number is required"}).max(20),institution:x().trim().min(1,{message:"Institution is required"}).max(200),country:x().min(1,{message:"Please select a country"})}),ge=["Student - Paper Presentation","Regular - Paper Presentation","Committee Member - Organizing Committee","Committee Member - Technical Program Committee","Other - Participant/Delegate","Other - Virtual Attendee","Other - Industry/Sponsor"],he=[{value:"hybrid",label:"Hybrid"}],pe=["Afghanistan","Albania","Algeria","Argentina","Armenia","Australia","Austria","Azerbaijan","Bahrain","Bangladesh","Belarus","Belgium","Bhutan","Bolivia","Bosnia and Herzegovina","Botswana","Brazil","Brunei","Bulgaria","Cambodia","Cameroon","Canada","Chile","China","Colombia","Costa Rica","Croatia","Cyprus","Czech Republic","Denmark","Dominican Republic","Ecuador","Egypt","El Salvador","Estonia","Ethiopia","Finland","France","Georgia","Germany","Ghana","Greece","Guatemala","Honduras","Hong Kong","Hungary","Iceland","India","Indonesia","Iran","Iraq","Ireland","Israel","Italy","Jamaica","Japan","Jordan","Kazakhstan","Kenya","Kuwait","Kyrgyzstan","Latvia","Lebanon","Libya","Lithuania","Luxembourg","Malaysia","Maldives","Malta","Mexico","Moldova","Mongolia","Morocco","Myanmar","Nepal","Netherlands","New Zealand","Nigeria","North Macedonia","Norway","Oman","Pakistan","Palestine","Panama","Paraguay","Peru","Philippines","Poland","Portugal","Qatar","Romania","Russia","Rwanda","Saudi Arabia","Senegal","Serbia","Singapore","Slovakia","Slovenia","South Africa","South Korea","Spain","Sri Lanka","Sudan","Sweden","Switzerland","Syria","Taiwan","Tajikistan","Tanzania","Thailand","Tunisia","Turkey","Turkmenistan","Uganda","Ukraine","United Arab Emirates","United Kingdom","United States","Uruguay","Uzbekistan","Venezuela","Vietnam","Yemen","Zambia","Zimbabwe"],Fe=()=>{const[t,r]=u.useState(!1),[i,p]=u.useState(""),[T,j]=u.useState(!1),[A,L]=u.useState(""),{toast:v}=K(),H=G(),n=Q({resolver:ee(ue),defaultValues:{category:"",firstName:"",lastName:"",email:"",joiningMode:"",paperId:"",phone:"",institution:"",country:""}}),O=async a=>{if(i){v({title:"Registration Failed",description:"Invalid submission detected.",variant:"destructive"});return}r(!0);try{const{error:s}=await w.from("registrations").insert({category:a.category,first_name:a.firstName,last_name:a.lastName,email:a.email,joining_mode:a.joiningMode,paper_id:a.paperId||null,phone:a.phone,institution:a.institution,country:a.country});if(s)throw s;try{await w.functions.invoke("sync-registration",{body:{registration:a}})}catch{}L(`${a.firstName} ${a.lastName}`),j(!0),n.reset()}catch(s){v({title:"Registration Failed",description:ae(s),variant:"destructive"})}finally{r(!1)}},V=()=>{j(!1),H("/")};return e.jsxs("div",{className:"min-h-screen bg-background",children:[e.jsx(se,{title:"Register | ICEB 2026",description:"Register for the International Conference on Advances in Emerging Technologies 2025. Free registration for all participants.",keywords:"ICEB 2026 registration, conference registration, academic conference, free registration"}),e.jsx(te,{}),e.jsx(me,{open:T,onOpenChange:j,children:e.jsxs(B,{className:"sm:max-w-md",children:[e.jsxs(D,{className:"text-center",children:[e.jsx("div",{className:"mx-auto mb-4 flex h-16 w-16 items-center justify-center rounded-full bg-green-100",children:e.jsx(le,{className:"h-10 w-10 text-green-600"})}),e.jsx(z,{className:"text-2xl text-center",children:"Registration Successful!"}),e.jsxs(M,{className:"text-center space-y-2",children:[e.jsxs("p",{className:"text-base",children:["Thank you, ",e.jsx("span",{className:"font-semibold",children:A}),"!"]}),e.jsx("p",{children:"Your registration for ICEB 2026 has been completed successfully."}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"You will receive a confirmation email shortly with further details about the conference."})]})]}),e.jsx("div",{className:"flex justify-center mt-4",children:e.jsx(S,{onClick:V,className:"px-8",children:"Back to Home"})})]})}),e.jsx("main",{className:"container mx-auto px-4 py-16",children:e.jsxs("div",{className:"max-w-2xl mx-auto",children:[e.jsxs("div",{className:"text-center mb-8",children:[e.jsx("h1",{className:"text-3xl md:text-4xl font-bold text-foreground mb-4",children:"Conference Registration"}),e.jsx("p",{className:"text-muted-foreground text-lg",children:"Register for ICEB 2026 - Registration is FREE for all participants"})]}),e.jsxs(J,{className:"border-primary/20",children:[e.jsxs(_,{className:"bg-primary/5 border-b border-primary/10",children:[e.jsxs(Y,{className:"flex items-center gap-2 text-primary",children:[e.jsx(I,{className:"h-5 w-5"}),"Registration Form"]}),e.jsx(Z,{children:"Please fill in all required fields to complete your registration"})]}),e.jsx($,{className:"pt-6",children:e.jsx(X,{...n,children:e.jsxs("form",{onSubmit:n.handleSubmit(O),className:"space-y-6",children:[e.jsx("input",{type:"text",name:"website",value:i,onChange:a=>p(a.target.value),className:"hidden",tabIndex:-1,autoComplete:"off"}),e.jsxs("div",{className:"space-y-4",children:[e.jsx("h3",{className:"text-lg font-semibold text-foreground border-b pb-2",children:"Registration Details"}),e.jsx(o,{control:n.control,name:"category",render:({field:a})=>e.jsxs(l,{children:[e.jsx(c,{children:"Category *"}),e.jsxs(f,{onValueChange:a.onChange,defaultValue:a.value,children:[e.jsx(d,{children:e.jsx(y,{children:e.jsx(b,{placeholder:"Select your category"})})}),e.jsx(N,{children:ge.map(s=>e.jsx(C,{value:s,children:s},s))})]}),e.jsx(m,{})]})})]}),e.jsxs("div",{className:"space-y-4",children:[e.jsx("h3",{className:"text-lg font-semibold text-foreground border-b pb-2",children:"Personal Information"}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[e.jsx(o,{control:n.control,name:"firstName",render:({field:a})=>e.jsxs(l,{children:[e.jsx(c,{children:"First Name *"}),e.jsx(d,{children:e.jsx(g,{placeholder:"Enter your first name",...a})}),e.jsx(m,{})]})}),e.jsx(o,{control:n.control,name:"lastName",render:({field:a})=>e.jsxs(l,{children:[e.jsx(c,{children:"Last Name *"}),e.jsx(d,{children:e.jsx(g,{placeholder:"Enter your last name",...a})}),e.jsx(m,{})]})})]}),e.jsx(o,{control:n.control,name:"email",render:({field:a})=>e.jsxs(l,{children:[e.jsx(c,{children:"Email Address *"}),e.jsx(d,{children:e.jsx(g,{type:"email",placeholder:"Enter your email address",...a})}),e.jsx(m,{})]})}),e.jsx(o,{control:n.control,name:"phone",render:({field:a})=>e.jsxs(l,{children:[e.jsx(c,{children:"Phone Number *"}),e.jsx(d,{children:e.jsx(g,{type:"tel",placeholder:"Enter your phone number",...a})}),e.jsx(m,{})]})}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[e.jsx(o,{control:n.control,name:"joiningMode",render:({field:a})=>e.jsxs(l,{children:[e.jsx(c,{children:"Conference Joining Mode *"}),e.jsxs(f,{onValueChange:a.onChange,defaultValue:a.value,children:[e.jsx(d,{children:e.jsx(y,{children:e.jsx(b,{placeholder:"Select joining mode"})})}),e.jsx(N,{children:he.map(s=>e.jsx(C,{value:s.value,children:s.label},s.value))})]}),e.jsx(m,{})]})}),e.jsx(o,{control:n.control,name:"paperId",render:({field:a})=>e.jsxs(l,{children:[e.jsx(c,{children:"Paper ID (if applicable)"}),e.jsx(d,{children:e.jsx(g,{placeholder:"Enter your paper ID",...a})}),e.jsx(m,{})]})})]})]}),e.jsxs("div",{className:"space-y-4",children:[e.jsx("h3",{className:"text-lg font-semibold text-foreground border-b pb-2",children:"Institution Information"}),e.jsx(o,{control:n.control,name:"institution",render:({field:a})=>e.jsxs(l,{children:[e.jsx(c,{children:"Institution/Organization *"}),e.jsx(d,{children:e.jsx(g,{placeholder:"Enter your institution or organization name",...a})}),e.jsx(m,{})]})}),e.jsx(o,{control:n.control,name:"country",render:({field:a})=>e.jsxs(l,{children:[e.jsx(c,{children:"Country *"}),e.jsxs(f,{onValueChange:a.onChange,defaultValue:a.value,children:[e.jsx(d,{children:e.jsx(y,{children:e.jsx(b,{placeholder:"Select your country"})})}),e.jsx(N,{children:pe.map(s=>e.jsx(C,{value:s,children:s},s))})]}),e.jsx(m,{})]})})]}),e.jsx("div",{className:"pt-4",children:e.jsx(S,{type:"submit",className:"w-full",size:"lg",disabled:t,children:t?e.jsxs(e.Fragment,{children:[e.jsx(W,{className:"mr-2 h-4 w-4 animate-spin"}),"Submitting..."]}):e.jsxs(e.Fragment,{children:[e.jsx(I,{className:"mr-2 h-4 w-4"}),"Complete Registration"]})})}),e.jsx("p",{className:"text-xs text-muted-foreground text-center",children:"By registering, you agree to our terms and conditions. A confirmation email will be sent to your registered email address."})]})})})]})]})}),e.jsx(re,{})]})};export{Fe 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.