PageSourceSearch

https://alttextstudio.com/_nuxt/Cog_MYUv.js

js alttextstudio.com collected 2026-10-01 10:39:26 UTC 2,808 bytes, 1 lines download raw bytes

1import{d as y,L as w,k as l,e as _,a2 as h,c,a as t,N as k,f as S,v as q,y as E,z as N,n as C,D as m,E as V,G as B,$ as F,R as n,o as f,x as P}from"./D-uLEkMY.js";import{v as R}from"./DvPO6GVX.js";import{u as j}from"./BW-h8pph.js";const D={class:"text-foreground relative m-0 flex min-h-screen w-full flex-col items-center justify-center px-4 pt-24 pb-12 sm:px-6"},U={class:"border-border bg-surface w-full max-w-xl rounded-xl border p-8 shadow-sm"},z=["disabled"],H=y({name:"ForgotPasswordPage",__name:"index",setup(L){j({title:"Forgot Password"});const d=h(),p=F(),b=w(),s=l(""),r=l(!1),a=l(""),u=l("success"),i=_(()=>{const o=n.trim(s.value||"");return o?R.isEmail(o,{require_tld:!0,allow_utf8_local_part:!0,require_display_name:!1}):!1});typeof d.query.email=="string"&&(s.value=decodeURIComponent(d.query.email));const x=async()=>{if(i.value){r.value=!0,a.value="";try{await b.forgotPassword(n.trim(s.value)),await p.push({path:"/check-email",query:{type:"reset",email:n.trim(s.value)}})}catch(o){u.value="error",a.value=o?.data?.message||o?.message||"Failed to request password reset."}finally{r.value=!1}}};return(o,e)=>{const g=B;return f(),c("div",D,[t("div",U,[e[3]||(e[3]=t("h1",{class:"mb-2 text-3xl font-bold"},"Forgot password",-1)),e[4]||(e[4]=t("p",{class:"text-muted mb-6 text-sm"}," Enter your email address and we’ll send you a reset link. ",-1)),t("form",{class:"space-y-4",onSubmit:k(x,["prevent"])},[t("div",null,[e[1]||(e[1]=t("label",{for:"email",class:"mb-2 block text-sm font-medium text-foreground"}," Email address ",-1)),E(t("input",{id:"email","onUpdate:modelValue":e[0]||(e[0]=v=>s.value=v),autocomplete:"email",class:"border-border bg-surface-2 text-foreground placeholder:text-muted-2 focus:border-accent focus:ring-accent block w-full rounded-lg border px-3 py-2.5 text-sm shadow-xs",placeholder:"[email protected]",type:"email",maxlength:"254"},null,512),[[N,s.value]])]),a.value?(f(),c("div",{key:0,class:C(["rounded-base border p-4 text-sm shadow-xs",u.value==="success"?"border-emerald-300 bg-emerald-50 text-emerald-800":"border-red-300 bg-red-50 text-red-800"])},m(a.value),3)):S("",!0),t("button",{type:"submit",class:"bg-accent text-on-accent focus:ring-brand-blue/30 flex h-12 w-full items-center justify-center rounded-lg px-4 font-bold hover:opacity-95 focus:ring-4 focus:outline-none disabled:cursor-not-allowed disabled:opacity-60",disabled:!i.value||r.value},m(r.value?"Sending...":"Send reset link"),9,z),q(g,{to:"/sign-in",class:"border-border bg-surface-2 text-foreground hover:bg-surface-2/70 focus:ring-brand-blue/30 flex h-12 w-full items-center justify-center rounded-lg border px-4 text-sm font-semibold focus:ring-4 focus:outline-none"},{default:V(()=>e[2]||(e[2]=[P(" Back to sign in ",-1)])),_:1,__:[2]})],32)])])}}});export{H 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.