PageSourceSearch

https://bulx.ai/assets/PasswordResetPage-JwQ48-IM.js

js bulx.ai collected 2026-10-05 11:52:52 UTC 7,197 bytes, 1 lines download raw bytes

1import{c as r,e,f as m,w as f,u as S,F as k,d as N,h as u,g as U,p as _,q as V,s as Y,n as q,t as g,m as A,v as j,r as G,i as H,y as x,j as p,z as W,l as d,x as $}from"./index-CYYBaOTV.js";import{_ as J}from"./_plugin-vue_export-helper-DlAUqK2U.js";const K={class:"auth-root"},O={class:"auth-top"},Q=["src"],ss={style:{display:"flex","align-items":"center",gap:"16px"}},es={class:"auth-card"},ts={key:0,class:"state-block"},as={class:"field"},os={class:"field-wrap"},ls=["type"],ns={class:"sig-bar"},is={class:"field"},rs={class:"field-wrap"},ds=["type"],us={key:0,class:"err-msg"},vs=["disabled"],ps={class:"signin-row"},ms={key:0,class:"state-block"},fs={class:"form-sub"},gs={class:"field"},cs={class:"field-wrap"},ws={key:0,class:"err-msg"},ys=["disabled"],bs={class:"signin-row"},ks={__name:"PasswordResetPage",setup(xs){const z=W(),{logoSrc:L,toggleTheme:C}=H(),{requestPasswordReset:E,confirmPasswordReset:Z}=$(),B=x(()=>z.query.token||""),D=x(()=>!!B.value),c=p(""),R=p(!1),i=p(""),P=p(""),h=p(!1),T=p(!1),v=p(!1),o=p(""),w=x(()=>{const l=i.value;let s=0;return l.length>=8&&s++,l.length>=12&&s++,/[A-Z]/.test(l)&&s++,/[0-9]/.test(l)&&s++,/[^A-Za-z0-9]/.test(l)&&s++,s}),M=x(()=>w.value<=2?"weak":w.value<=3?"mid":"ok"),F=x(()=>i.value?w.value<=2?"Weak":w.value<=3?"Fair":"Strong signal":"");async function X(){var l,s,n,a,y;if(o.value="",!c.value){o.value="Enter your email address.";return}v.value=!0;try{await E(c.value),R.value=!0}
1catch(t){const b=(l=t==null?void 0:t.response)==null?void 0:l.status;o.value=b===429?"Too many requests. Please wait a moment and try again.":((n=(s=t==null?void 0:t.response)==null?void 0:s.data)==null?void 0:n.error)||((y=(a=t==null?void 0:t.response)==null?void 0:a.data)==null?void 0:y.message)||"Something went wrong. Try again."}finally{v.value=!1}}async function I(){var l,s,n,a,y;if(o.value="",i.value.length<8){o.value="Use an 8+ character password.";return}if(!/[A-Z]/.test(i.value)){o.value="Password must contain at least one uppercase letter.";return}if(!/[0-9]/.test(i.value)){o.value="Password must contain at least one number.";return}if(!/[^A-Za-z0-9]/.test(i.value)){o.value="Password must contain at least one special character.";return}if(i.value!==P.value){o.value="Passwords do not match.";return}v.value=!0;try{await Z(B.value,i.value),T.value=!0}catch(t){const b=(l=t==null?void 0:t.response)==null?void 0:l.status;o.value=b===400||b===410?"This reset link is invalid or has expired.":b===429?"Too many requests. Please wait a moment and try again.":((n=(s=t==null?void 0:t.response)==null?void 0:s.data)==null?void 0:n.error)||((y=(a=t==null?void 0:t.response)==null?void 0:a.data)==null?void 0:y.message)||"Something went wrong. Try again."}finally{v.value=!1}}return(l,s)=>{const n=G("router-link");return d(),r("div",K,[e("div",O,[m(n,{to:"/"},{default:f(()=>[e("img",{src:S(L),alt:"BULX",style:{height:"30px",display:"block"},class:"logo-img"},null,8,Q)]),_:1}),e("div",ss,[e("div",{class:"theme-toggle",title:"Toggle theme",onClick:s[0]||(s[0]=(...a)=>S(C)&&S(C)(...a))}),m(n,{to:"/login",class:"back-link"},{default:f(()=>[...s[5]||(s[5]=[e("svg",{viewBox:"0 0 16 16"},[e("path",{d:"M13 8H3M7 4l-4 4 4 4"})],-1),u(" Sign in ",-1)])]),_:1})])]),e("div",es,[D.value?(d(),r(k,{key:0},[T.value?(d(),r("div",ts,[s[7]||(s[7]=N('<div class="state-icon ok" data-v-a6780055><svg viewBox="0 0 24 24" data-v-a6780055><polyline points="4,12 10,18 20,6" data-v-a6780055></polyline></svg></div><div class="form-eyebrow" data-v-a6780055>Password updated</div><h1 class="form-title" data-v-a6780055>All set.</h1><p class="form-sub" data-v-a6780055>Your password has been changed. You can now sign in with your new credentials.</p>',4)),m(n,{to:"/login",class:"submit-link"},{default:f(()=>[...s[6]||(s[6]=[e("span",null,"Go to Sign in",-1)])]),_:1})])):(d(),r(k,{key:1},[s[13]||(s[13]=e("div",{class:"form-eyebrow"},"BULX Prediction Network",-1)),s[14]||(s[14]=e("h1",{class:"form-title"},[u("Set a new"),e("br"),e("em",null,"password.")],-1)),s[15]||(s[15]=e("p",{class:"form-sub"},"Choose a strong password to secure your account.",-1)),e("form",{onSubmit:U(I,["prevent"])},[e("div",as,[s[9]||(s[9]=e("label",{class:"field-label"},"New password",-1)),e("div",os,[_(e("input",{"onUpdate:modelValue":s[1]||(s[1]=a=>i.value=a),type:h.value?"text":"password",class:"field-input",placeholder:"Min. 8 characters",autocomplete:"new-password",style:{"padding-right":"38px"}},null,8,ls),[[V,i.value]]),e("button",{type:"button",class:"eye-btn",tabindex:"-1",onClick:s[2]||(s[2]=a=>h.value=!h.value)},[...s[8]||(s[8]=[e("svg",{viewBox:"0 0 24 24"},[e("path",{d:"M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"}),e("circle",{cx:"12",cy:"12",r:"3"})],-1)])])]),e("div",ns,[(d(),r(k,null,Y(5,a=>e("div",{key:a,class:q(["sig-seg",a<=w.value?M.value:""])},null,2)),64))]),e("div",{class:q(["sig-note",M.value])},g(F.value),3)]),e("div",is,[s[10]||(s[10]=e("label",{class:"field-label"},"Confirm password",-1)),e("div",rs,[_(e("input",{"onUpdate:modelValue":s[3]||(s[3]=a=>P.value=a),type:h.value?"text":"password",class:"field-input",placeholder:"Repeat password",autocomplete:"new-password"},null,8,ds),[[V,P.value]])])]),o.value?(d(),r("p",us,g(o.value),1)):A("",!0),e("button",{class:"submit",type:"submit",disabled:v.value},[e("span",null,g(v.value?"Updating…":"Update password"),1)],8,vs)],32),e("p",ps,[s[12]||(s[12]=u(" Remembered it? ",-1)),m(n,{to:"/login"},{default:f(()=>[...s[11]||(s[11]=[u("Sign in →",-1)])]),_:1})])],64))],64)):(d(),r(k,{key:1},[R.value?(d(),r("div",ms,[s[19]||(s[19]=N('<div class="state-icon ok" data-v-a6780055><svg viewBox="0 0 24 24" data-v-a6780055><path d="M3 6l9 6 9-6" data-v-a6780055></path><rect x="3" y="5" width="18" height="14" rx="2" data-v-a6780055></rect></svg></div><div class="form-eyebrow" data-v-a6780055>Check your email</div><h1 class="form-title" data-v-a6780055>Link sent.</h1>
1',3)),e("p",fs,[s[16]||(s[16]=u(" If an account exists for ",-1)),e("strong",null,g(c.value),1),s[17]||(s[17]=u(", we've sent a password reset link. Check your inbox and spam folder. ",-1))]),m(n,{to:"/login",class:"submit-link"},{default:f(()=>[...s[18]||(s[18]=[e("span",null,"Back to Sign in",-1)])]),_:1})])):(d(),r(k,{key:1},[s[23]||(s[23]=e("div",{class:"form-eyebrow"},"BULX Prediction Network",-1)),s[24]||(s[24]=e("h1",{class:"form-title"},[u("Reset your"),e("br"),e("em",null,"password.")],-1)),s[25]||(s[25]=e("p",{class:"form-sub"},"Enter your email and we'll send you a link to set a new password.",-1)),e("form",{onSubmit:U(X,["prevent"])},[e("div",gs,[s[20]||(s[20]=e("label",{class:"field-label"},"Email address",-1)),e("div",cs,[_(e("input",{"onUpdate:modelValue":s[4]||(s[4]=a=>c.value=a),type:"email",class:"field-input",placeholder:"[email protected]",autocomplete:"email"},null,512),[[j,c.value]])])]),o.value?(d(),r("p",ws,g(o.value),1)):A("",!0),e("button",{class:"submit",type:"submit",disabled:v.value},[e("span",null,g(v.value?"Sending…":"Send reset link"),1)],8,ys)],32),e("p",bs,[s[22]||(s[22]=u(" Remembered it? ",-1)),m(n,{to:"/login"},{default:f(()=>[...s[21]||(s[21]=[u("Sign in →",-1)])]),_:1})])],64))],64))])])}}},Ss=J(ks,[["__scopeId","data-v-a6780055"]]);export{Ss 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.