PageSourceSearch

https://staybright.ai/_nuxt/D1Q2xsOI.js

js staybright.ai collected 2026-10-04 14:31:17 UTC 3,427 bytes, 1 lines download raw bytes

1import{_ as $}from"./CZWZW85R.js";import{_ as N}from"./BGRz0kGJ.js";import{_ as P}from"./BHelCH0N.js";import{d as q,v as _,k as w,g as u,w as i,o as l,e as r,a as c,x as z,c as y,y as f,u as o,f as n,s as v,t as g,z as O}from"./BbWie7Ce.js";import{_ as x}from"./BMPkIzVd.js";import{_ as h}from"./B7mBZxE2.js";import{_ as b}from"./B5K7CM6-.js";import{u as T}from"./DbrUsWDX.js";import{u as U}from"./Dl4Gn6pn.js";import{E as D,a as F}from"./BvS0z0ke.js";import{L as I}from"./Z1u4Xffz.js";import"./ho-u98wB.js";import"./BDKVlhGF.js";import"./lgWYz7eS.js";import"./BEHD0UYf.js";import"./Cb41GzHZ.js";import"./DZ2Qr5Ia.js";import"./B_xCX-tf.js";import"./BT3pz5EI.js";import"./DTBO2sEn.js";import"./CAiOCVIE.js";import"./wvbZMDsL.js";import"./9Mzz7BA5.js";import"./DZSEF-0E.js";const J={class:"space-y-2"},M={key:0,class:"text-sm text-destructive"},j={class:"space-y-2"},G={class:"relative"},H={key:0,class:"text-sm text-destructive"},ve=q({__name:"register",setup(K){const{initSEO:k}=T({title:"Create Account",description:"Create your Stay Bright Academy account to start building your next SaaS application with our powerful starter kit.",noindex:!0,type:"website"});k();const{register:S}=U(),t=_({email:"",password:""}),s=_({email:"",password:""}),m=w(!1),d=w(!1),C=()=>{let a=!0;return s.email="",s.password="",t.email?/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t.email)||(s.email="Invalid email format",a=!1):(s.email="Email is required",a=!1),t.password?t.password.length<8&&(s.password="Password must be at least 8 characters",a=!1):(s.password="Password is required",a=!1),a},V=async()=>{if(C()){m.value=!0;try{await S(t.email,t.password),O("/dashboard")}catch(a){s.password=a.message}finally{m.value=!1}}},E=async a=>{};return(a,e)=>{const L=$,A=N,B=P;return l(),u(B,{title:"Create an account",description:"Choose your preferred sign up method",quote:"Join thousands of developers building the future of web applications with Stay Bright Academy."},{footer:i(()=>[e[7]||(e[7]=n(" Already have an account? ",-1)),r(A,{to:"/login",class:"text-primary hover:underline"},{default:i(()=>e[6]||(e[6]=[n("Sign in",-1)])),_:1,__:[6]})]),default:i(()=>[r(L,{onSocialLogin:E}),c("form",{onSubmit:z(V,["prevent"]),class:"space-y-4"},[c("div",J,[r(o(b),{for:"email"},{default:i(()=>e[3]||(e[3]=[n("Email",-1)])),_:1,__:[3]}),r(o(h),{id:"email",modelValue:t.email,"onUpdate:modelValue":e[0]||(e[0]=p=>t.email=p),type:"email",placeholder:"[email protected]",class:v({"border-destructive":s.email})},null,8,["modelValue","class"]),s.email?(l(),y("p",M,g(s.email),1)):f("",!0)]),c("div",j,[r(o(b),{for:"password"},{default:i(()=>e[4]||(e[4]=[n("Password",-1)])),_:1,__:[4]}),c("div",G,[r(o(h),{id:"password",modelValue:t.password,"onUpdate:modelValue":e[1]||(e[1]=p=>t.password=p),type:d.value?"text":"password",class:v({"border-destructive":s.password})},null,8,["modelValue","type","class"]),r(o(x),{type:"button",variant:"ghost",size:"sm",class:"absolute right-2 top-1/2 -translate-y-1/2",onClick:e[2]||(e[2]=p=>d.value=!d.value)},{default:i(()=>[d.value?(l(),u(o(F),{key:1,class:"h-4 w-4"})):(l(),u(o(D),{key:0,class:"h-4 w-4"}))]),_:1})]),s.password?(l(),y("p",H,g(s.password),1)):f("",!0)]),r(o(x),{type:"submit",class:"w-full",disabled:m.value},{default:i(()=>[m.value?(l(),u(o(I),{key:0,class:"mr-2 h-4 w-4 animate-spin"})):f("",!0),e[5]||(e[5]=n(" Create Account ",-1))]),_:1,__:[5]},8,["disabled"])],32)]),_:1})}}});
1export{ve 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.