text: (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[495],{15861:function(e,a,r){"use strict";r.d(a,{Z:function(){return v}});var t=r(63366),n=r(87462),o=r(67294),i=(r(45697),r(86010)),l=r(39707),s=r(77463),h=r(11496),d=r(33616),u=r(98216),m=r(21420);function c(e){return(0,m.Z)("MuiTypography",e)}(0,r(11271).Z)("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);var p=r(85893);const g=["align","className","component","gutterBottom","noWrap","paragraph","variant","variantMapping"],x=(0,h.ZP)("span",{name:"MuiTypography",slot:"Root",overridesResolver:(e,a)=>{const{ownerState:r}=e;return[a.root,r.variant&&a[r.variant],"inherit"!==r.align&&a[`align${(0,u.Z)(r.align)}`],r.noWrap&&a.noWrap,r.gutterBottom&&a.gutterBottom,r.paragraph&&a.paragraph]}})((({theme:e,ownerState:a})=>(0,n.Z)({margin:0},a.variant&&e.typography[a.variant],"inherit"!==a.align&&{textAlign:a.align},a.noWrap&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},a.gutterBottom&&{marginBottom:"0.35em"},a.paragraph&&{marginBottom:16}))),f={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},y={primary:"primary.main",textPrimary:"text.primary",secondary:"secondary.main",textSecondary:"text.secondary",error:"error.main"};var v=o.forwardRef((function(e,a){const r=(0,d.Z)({props:e,name:"MuiTypography"}),o=(e=>y[e]||e)(r.color),h=(0,l.Z)((0,n.Z)({},r,{color:o})),{align:m="inherit",className:v,component:Z,gutterBottom:b=!1,noWrap:w=!1,paragraph:j=!1,variant:N="body1",variantMapping:B=f}=h,S=(0,t.Z)(h,g),_=(0,n.Z)({},h,{align:m,color:o,className:v,component:Z,gutterBottom:b,noWrap:w,paragraph:j,variant:N,variantMapping:B}),C=Z||(j?"p":B[N]||f[N])||"span",W=(e=>{const{align:a,gutterBottom:r,noWrap:t,paragraph:n,variant:o,classes:i}=e,l={root:["root",o,"inherit"!==e.align&&`align${(0,u.Z)(a)}`,r&&"gutterBottom",t&&"noWrap",n&&"paragraph"]};return(0,s.Z)(l,c,i)})(_);return(0,p.jsx)(x,(0,n.Z)({as:C,ref:a,ownerState:_,className:(0,i.Z)(W.root,v)},S))}))},58740:function(e,a,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/register",function(){return r(40297)}])},40297:function(e,a,r){"use strict";r.r(a);var t=r(85893),n=r(9008),o=r(41664),i=r(11163),l=r(82175),s=r(74231),h=r(87357),d=r(27948),u=r(11057),m=r(15861),c=r(50135),p=r(85071),g=r(50122),x=r(56815),f=r(21023);a.default=function(){var e=(0,i.useRouter)(),a=(0,l.TA)({initialValues:{email:"",firstName:"",lastName:"",password:"",policy:!1},validationSchema:s.Ry({email:s.Z_().email("Must be a valid email").max(255).required("Email is required"),firstName:s.Z_().max(255).required("First name is required"),lastName:s.Z_().max(255).required("Last name is required"),password:s.Z_().max(255).required("Password is required"),policy:s.O7().oneOf([!0],"This field must be checked")}),onSubmit:function(){e.push("/")}});return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(n.default,{children:(0,t.jsx)("title",{children:"Register | Material Kit"})}),(0,t.jsx)(h.Z,{component:"main",sx:{alignItems:"center",display:"flex",flexGrow:1,minHeight:"100%"},children:(0,t.jsxs)(d.Z,{maxWidth:"sm",children:[(0,t.jsx)(o.default,{href:"/",passHref:!0,children:(0,t.jsx)(u.Z,{component:"a",startIcon:(0,t.jsx)(f.Z,{fontSize:"small"}),children:"Dashboard"})}),(0,t.jsxs)("form",{onSubmit:a.handleSubmit,children:[(0,t.jsxs)(h.Z,{sx:{my:3},children:[(0,t.jsx)(m.Z,{color:"textPrimary",variant:"h4",children:"Create a new account"}),(0,t.jsx)(m.Z,{color:"textSecondary",gutterBottom:!0,variant:"body2",children:"Use your email to create a new account"})]}),(0,t.jsx)(c.Z,{error:Boolean(a.touched.firstName&&a.errors.firstName),fullWidth:!0,helperText:a.touched.firstName&&a.errors.firstName,label:"First Name",margin:"normal",name:"firstName",onBlur:a.handleBlur,onChange:a.handleChange,value:a.values.firstName,variant:"outlined"}),(0,t.jsx)(c.Z,{error:Boolean(a.touched.lastName&&a.errors.lastName),fullWidth:!0,helperText:a.touched.lastName&&a.errors.lastName,label:"Last Name",margin:"normal",name:"lastName",onBlur:a.handleBlur,onChange:a.handleChange,value:a.values.lastName,variant:"outlined"}),(0,t.jsx)(c.Z,{error:Boolean(a.touched.email&&a.errors.email),fullWidth:!0,helperText:a.touched.email&&a.errors.email,label:"Email Address",margin:"normal",name:"email",onBlur:a.handleBlur,onChange:a.handleChange,type:"email",value:a.values.email,variant:"outlined"}),(0,t.jsx)(c.Z,{error:Boolean(a.touched.password&&a.errors.password),fullWidth:!0,helperText:a.touched.password&&a.errors.password,label:"Password",margin:"normal",name:"password",onBlur:a.handleBlur,onChange:a.handleChange,type:"password",value:a.values.password,variant:"outlined"}),(0,t.jsxs)(h.Z,{sx:{alignItems:"center",display:"flex",ml:-1},children:[(0,t.jsx)(p.Z,{checked:a.values.policy,name:"policy",onChange:a.handleChange}),(0,t.jsxs)(m.Z,{color:"textSecondary",variant:"body2",children:["I have read the"," ",(0,t.jsx)(o.default,{href:"#",passHref:!0,children:(0,t.jsx)(g.Z,{color:"primary",underline:"always",variant:"subtitle2",children:"Terms and Conditions"})})]})]}),Boolean(a.touched.policy&&a.errors.policy)&&(0,t.jsx)(x.Z,{error:!0,children:a.errors.policy}),(0,t.jsx)(h.Z,{sx:{py:2},children:(0,t.jsx)(u.Z,{color:"primary",disabled:a.isSubmitting,fullWidth:!0,size:"large",type:"submit",variant:"contained",children:"Sign Up Now"})}),(0,t.jsxs)(m.Z,{color:"textSecondary",variant:"body2",children:["Have an account?"," ",(0,t.jsx)(o.default,{href:"/login",passHref:!0,children:(0,t.jsx)(g.Z,{variant:"subtitle2",underline:"hover",children:"Sign In"})})]})]})]})})]})}}},function(e){e.O(0,[9517,2785,6063,4473,1865,9774,2888,179],(function(){return a=58740,e(e.s=a);var a}));var a=e.O();_N_E=a}]);