1import{r as n,p as S,U as T,o,g as x,w as y,a as h,b as t,u as k,Z as I,c as d,C as N,t as g,i as b,E as B,J as M,a5 as P,G as V,a6 as R,N as $}from"./app-a180d900.js";import{D as L}from"./DemoProfilesSlideshow-e1535ebb.js";import{S as U}from"./SplitLayout-b75e0647.js";import"./_plugin-vue_export-helper-2c292c8f.js";import"./CookieConsentBanner-518afbb3.js";/* empty css */import"./Logo-35ced36a.js";(function(){try{var i=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};i.SENTRY_RELEASE={id:"4704f974a03beefd3c80292b0596914074059962"}}catch{}})();try{(function(){var i=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},r=new i.Error().stack;r&&(i._sentryDebugIds=i._sentryDebugIds||{},i._sentryDebugIds[r]="05cddffa-3415-4ccf-9949-217e71caee55",i._sentryDebugIdIdentifier="sentry-dbid-05cddffa-3415-4ccf-9949-217e71caee55")})()}catch{}const A={key:0},Y={class:"signup-form p-0"},q={key:1,class:"alert alert-danger"},z=["disabled"],F={key:0,class:"spinner-border spinner-border-sm",role:"status","aria-hidden":"true"},G={key:1},J=["disabled"],Z={key:0,class:"spinner-border spinner-border-sm",role:"status","aria-hidden":"true"},j={key:1},H={key:2},K={key:2,class:"alert alert-danger mt-2"},O={class:"text-center w-100 mt-8 text-sm"},ne={__name:"EnterVerificationCode",setup(i){const r=n(""),_=n(""),c=n(!1),f=n(!1),a=n(""),u=n(""),v=n(!0),p=n(10),m=n(null),C=n(!0),E=async()=>{var l,e;if(a.value="",!r.value.trim()){a.value="Please enter the verification code.",u.value="danger";return}try{f.value=!0;const s=await axios.post("/verify-code",{code:r.value});s.data.success?$.visit(s.data.redirect):(a.value=s.data.message||"Verification failed.",u.value="danger")}catch(s){a.value=((e=(l=s.response)==null?void 0:l.data)==null?void 0:e.message)||"Something went wrong. Try again later.",u.value="danger"}finally{f.value=!1}},D=async()=>{var l,e;a.value="",c.value=!0;try{const s=await axios.post("/resend-verification-code");s.data.success?(a.value="Verification code resent successfully.",u.value="success",w()):(a.value=s.data.message||"Failed to resend verification code.",u.value="danger")}catch(s){a.value=((e=(l=s.response)==null?void 0:l.data)==null?void 0:e.message)||"Something went wrong. Try again later.",u.value="danger"}finally{c.value=!1}},w=()=>{v.value=!0,p.value=30,m.value=setInterval(()=>{p.value>0?p.value-=1:(v.value=!1,clearInterval(m.value))},1e3)};return S(()=>{w()}),T(()=>{m.value&&clearInterval(m.value)}),(l,e)=>(o(),x(U,null,{rightcolumn:y(()=>[h(L)]),default:y(()=>[h(k(I),{title:"Login | Enter Verification Code"},{default:y(()=>e[2]||(e[2]=[t("link",{"head-key":"auth-stylesheet",rel:"stylesheet",href:"/template/allmyonline/assets/css/style-login.css"},null,-1)])),_:1,__:[2]}),C.value?(o(),d("div",A,[t("div",null,[t("div",Y,[e[6]||(e[6]=t("div",{class:"form-text"},[t("h2",null,"Verify Your Account"),t("p",{class:"subheading"}," Enter the verification code sent to your email. ")],-1)),a.value?(o(),d("div",{key:0,class:N(`alert alert-${u.value==="success"?"success":"danger"}`)},g(a.value),3)):b("",!0),l.$page.props.flash.message_error&&!a.value?(o(),d("div",q,g(l.$page.props.flash.message_error),1)):b("",!0),t("form",{onSubmit:B(E,["prevent"])},[e[3]||(e[3]=t("label",{for:"verification_code"},"Verification Code",-1)),M(t("input",{type:"text",id:"verification_code","onUpdate:modelValue":e[0]||(e[0]=s=>r.value=s),placeholder:"Enter verification code",required:"",onInput:e[1]||(e[1]=s=>_.value="")},null,544),[[P,r.value]]),t("button",{type:"submit",class:"amo-btn amo-btn--primary mt-4 w-full",disabled:f.value||!r.value},[f.value?(o(),d("span",F)):(o(),d("span",G,"Continue"))],8,z)],32),t("button",{class:"mt-4 amo-btn amo-btn--secondary amo-btn--sm w-full",onClick:D,disabled:c.value||v.value},[c.value?(o(),d("span",Z)):v.value?(o(),d("span",j,"Resend in "+g(p.value)+"s",1)):(o(),d("span",H,"Resend Verification Code"))],8,J),_.value?(o(),d("div",K,g(_.value),1)):b("",!0),t("p",O,[e[5]||
1(e[5]=V(" Don't have an account? ",-1)),h(k(R),{href:l.route("signup.details")},{default:y(()=>e[4]||(e[4]=[V(" Sign up.",-1)])),_:1,__:[4]},8,["href"])])])])])):b("",!0)]),_:1}))}};export{ne as default}; 2//# sourceMappingURL=EnterVerificationCode-c7e1849f.js.map
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.