PageSourceSearch

https://my.maxiblocks.com/_next/static/chunks/pages/redeem-ccea80d5ac91b811.js

js maxiblocks.com collected 2026-10-02 05:03:26 UTC 8,871 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[71],{6465:function(e,a,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/redeem",function(){return r(1543)}])},2187:function(e,a){"use strict";a.Z=function(e){console.log("Error text: ",JSON.stringify(e));var a=e;switch("string"!==typeof e&&(e=JSON.stringify(e)),!0){case e.includes("Invalid userId"):return"User not found. Please double-check the email for typos or use a different email.";case e.includes("Invalid credentials"):return"Login failed: Email or password is incorrect. Please verify your login details or reset your password if necessary.";case e.includes("Invalid password: Password must be at least 8 characters"):return"Password too short: It must be at least 8 characters. A strong password helps protect your account.";case e.includes("no available seats"):return"Please add seats to invite more members.";case e.includes("has been exceeded"):return"Request limit exceeded. Please wait 1 hour before retrying. This helps us manage traffic and maintain service quality.";case e.includes("has already been invited"):return"This email is already in use. To add a new user, please use a different email address.";case e.includes("session is prohibited when a session is active."):return"Already logged in! Redirecting...";default:return void 0!==(null===a||void 0===a?void 0:a.message)?a.message:e}}},2699:function(e,a){"use strict";a.Z=function(e){console.log("Success text: ",JSON.stringify(e));var a=e;switch("string"!==typeof e&&(a=JSON.stringify(e)),console.log("text: ",a),console.log("includes account has been created: ",a.includes("account has been created")),!0){case a.includes("Invalid userId"):return"User doesn't exist, please check the email spelling.";case a.includes("invitations sent"):return"Invitation sent";case a.includes("account has been created"):return"<br>Success!<br>Your account has been created successfully. Redirecting...";default:return"Success"}}},1543:function(e,a,r){"use strict";r.r(a);
1var s=r(7568),n=r(414),t=r(5893),o=r(2391),i=r(9008),l=r.n(i),d=r(1953),c=r(4288),u=r(9630),m=r(9837),h=r(9742),p=r(4412),x=r(1359),g=r(9072),f=r(72),y=r(9041),v=r(562),w=r(5084),Z=(r(8538),r(4129)),b=r(7294),j=r(2175),P=r(4231),B=r(2187),S=r(2699),T=r(2961),_=r(2450);a.default=function(){(0,Z.eY)().email;var e=(0,b.useState)(!1),a=e[0],r=e[1],i=(0,b.useState)(""),C=i[0],k=i[1],E=(0,b.useState)(!1),N=E[0],I=E[1],q=(0,b.useState)(""),A=q[0],O=q[1],M=(0,b.useState)(!1),R=M[0],W=M[1],J=(0,b.useState)(!1),D=J[0],L=J[1],H=(0,j.TA)({initialValues:{code:"",name:"",password:"",confirm:"",email:""},validationSchema:P.Ry({code:P.Z_().max(100).required("Redeem code is required").matches(/^[A-Z]{3}-\d{4}-[A-Z]{4}-\d{4}-[A-Z]{4}$/i,"Invalid code. Please check it again"),name:P.Z_().max(100).required("Space name is required"),email:P.Z_().max(100).required("Email is required"),password:P.Z_().max(100).required("Password is required").min(8,"Your password is too short, minimum 8 characters"),confirm:P.Z_().max(100).required("Password confirmation is required").oneOf([P.iH("password")],"Passwords must match")}),onSubmit:function(){var e=H.values.password,a=(H.values.confirm,H.values.code),t=H.values.email,i=H.values.name,l=JSON.stringify({code:a,email:t,password:e,spaceName:i});fetch("/validate-coupon-332sdaswev.php",{method:"POST",headers:{"Content-Type":"application/json"},body:l}).then(function(){var a=(0,s.Z)((function(a){var s,i,l,d,c;return(0,n.__generator)(this,(function(n){switch(n.label){case 0:return n.trys.push([0,8,,9]),[4,a.json()];case 1:if(s=n.sent(),!a.ok)return console.log("Error response:",s),r(!0),I(!1),k((0,B.Z)(s)),[2];if("ok"!==s.status)return[3,6];console.log("Success response:",s),r(!1),I(!0),O((0,S.Z)(s)),(i=new o.KU).setEndpoint("https://auth.maxiblocks.com/v1").setProject("maxi"),l=new o.mR(i),n.label=2;case 2:return n.trys.push([2,4,,5]),[4,l.createEmailSession(t,e)];case 3:return n.sent(),setTimeout((function(){null===window||void 0===window||window.location.replace("/?login")}),500),[3,5];case 4:return d=n.sent(),console.error("Session creation failed:",d),r(!0),I(!1),k("Account created but login failed. Please try logging in manually."),[3,5];case 5:return[3,7];case 6:console.log("Error response:",s),r(!0),I(!1),k((0,B.Z)(s)),n.label=7;case 7:return[3,9];case 8:return c=n.sent(),console.error("Failed to parse response:",c),r(!0),I(!1),k("An unexpected error occurred. Please try again."),[3,9];case 9:return[2]}}
1))}));return function(e){return a.apply(this,arguments)}}())}});return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(l(),{children:(0,t.jsx)("title",{children:"Create your MaxiBlocks Cloud account | Account MaxiBlocks"})}),(0,t.jsx)(d.Z,{component:"main",sx:{flexGrow:1,py:8},children:(0,t.jsxs)(c.Z,{maxWidth:"lg",className:"my_maxi-container coupon-activation",children:[(0,t.jsx)(u.Z,{sx:{mb:3},variant:"h2",className:"my_maxi-container-title",children:"Create your MaxiBlocks Cloud account"}),(0,t.jsx)(d.Z,{sx:{p:3,padding:0},children:(0,t.jsx)("form",{onSubmit:H.handleSubmit,children:(0,t.jsxs)(m.Z,{sx:{padding:"24px 38px",display:"table"},children:[(0,t.jsx)(h.Z,{subheader:"Enter the code you were provided with",title:"Redeem code*",subheaderTypographyProps:{variant:"subtitle1"},titleTypographyProps:{variant:"h4",marginBottom:"0"},style:{paddingBottom:"20px"}}),(0,t.jsx)(p.Z,{}),(0,t.jsx)(x.Z,{sx:{paddingBottom:"0"},children:(0,t.jsx)(g.ZP,{container:!0,spacing:12,children:(0,t.jsx)(g.ZP,{item:!0,md:12,xs:6,children:(0,t.jsx)(f.Z,{fullWidth:!0,helperText:"Please enter a valid redeem code",label:"Redeem code",name:"code",onBlur:H.handleBlur,onChange:H.handleChange,value:H.values.code,variant:"outlined",error:Boolean(H.touched.code&&H.errors.code)})})})}),(0,t.jsx)(h.Z,{subheader:"This will be your account email",title:"Email*",subheaderTypographyProps:{variant:"subtitle1"},titleTypographyProps:{variant:"h4",marginBottom:"0"},style:{paddingBottom:"20px"}}),(0,t.jsx)(p.Z,{}),(0,t.jsx)(x.Z,{sx:{paddingBottom:"0"},children:(0,t.jsx)(g.ZP,{container:!0,spacing:12,children:(0,t.jsx)(g.ZP,{item:!0,md:12,xs:6,sx:{paddingTop:"10px"},children:(0,t.jsx)(f.Z,{fullWidth:!0,name:"email",helperText:"Please enter a valid email address",label:"Email",onBlur:H.handleBlur,onChange:H.handleChange,value:H.values.email,variant:"outlined",error:Boolean(H.touched.email&&H.errors.email)})})})}),(0,t.jsx)(h.Z,{subheader:"Set up your password",title:"Password*",subheaderTypographyProps:{variant:"subtitle1"},titleTypographyProps:{variant:"h4",marginBottom:"0"},style:{paddingBottom:"20px"}}),(0,t.jsx)(p.Z,{}),(0,t.jsxs)(x.Z,{children:[(0,t.jsx)(f.Z,{fullWidth:!0,label:"Password",helperText:"Minimum 8 characters",margin:"normal",name:"password",onBlur:H.handleBlur,onChange:H.handleChange,type:R?"text":"password",value:H.values.password,variant:"outlined",InputProps:{endAdornment:(0,t.jsx)(y.Z,{position:"end",children:(0,t.jsx)(v.Z,{"aria-label":"toggle password visibility",onClick:function(){return W((function(e){return!e}))},onMouseDown:function(e){e.preventDefault()},style:{color:"#119da4"},children:R?(0,t.jsx)(_.Z,{}):(0,t.jsx)(T.Z,{})})})},error:Boolean(H.touched.password&&H.errors.password)}),(0,t.jsx)(f.Z,{fullWidth:!0,label:"Confirm password",margin:"normal",helperText:"Should match the password above",name:"confirm",onBlur:H.handleBlur,onChange:H.handleChange,type:D?"text":"password",value:H.values.confirm,variant:"outlined",InputProps:{endAdornment:(0,t.jsx)(y.Z,{position:"end",children:(0,t.jsx)(v.Z,{"aria-label":"toggle password visibility",onClick:function(){return L((function(e){return!e}))},onMouseDown:function(e){e.preventDefault()},style:{color:"#119da4"},children:D?(0,t.jsx)(_.Z,{}):(0,t.jsx)(T.Z,{})})})},error:Boolean(H.touched.confirm&&H.errors.confirm)})]}),(0,t.jsx)(h.Z,{subheader:"Give your workspace a name",title:"Space name*",subheaderTypographyProps:{variant:"subtitle1"},titleTypographyProps:{variant:"h4",marginBottom:"0"},style:{paddingBottom:"20px"}}),(0,t.jsx)(p.Z,{}),(0,t.jsx)(x.Z,{sx:{paddingBottom:"0"},children:(0,t.jsx)(g.ZP,{container:!0,spacing:12,children:(0,t.jsx)(g.ZP,{item:!0,md:12,xs:6,children:(0,t.jsx)(f.Z,{fullWidth:!0,helperText:"Please specify space name",label:"Space name",name:"name",onBlur:H.handleBlur,onChange:H.handleChange,value:H.values.name,variant:"outlined",error:Boolean(H.touched.name&&H.errors.name)})})})}),(0,t.jsxs)(d.Z,{sx:{display:"flex",justifyContent:"flex-end",p:3},children:[(0,t.jsx)(w.Z,{color:"primary",size:"extraLarge",variant:"contained",type:"submit",children:"Create account"}),a&&(0,t.jsx)(u.Z,{className:"maxi-form-error",dangerouslySetInnerHTML:{__html:C}}),N&&(0,t.jsx)(u.Z,{className:"maxi-form-success",dangerouslySetInnerHTML:{__html:A}})]})]})})})]})})]})}}},function(e){e.O(0,[753,267,92,719,62,72,921,271,538,774,888,179],(function(){return a=6465,e(e.s=a);var a}));var a=e.O();_N_E=a}]);

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.