1import{r as a,j as t,b as e,u as h,m as f,E as w,L as x}from"./index-f6c41174.js";import{c as p,a as b,F as v,b as y,d as N}from"./FloatingInput-e2bf3495.js";import{F as S}from"./FormAppInfo-ed7c81c6.js";import"./_commonjsHelpers-725317a4.js";const k=a.forwardRef(({message:o},l)=>{const[n,r]=a.useState(!1);return a.useImperativeHandle(l,()=>({show(){r(!0),setTimeout(()=>{r(!1)},3e3)},hide(){r(!1)}})),t("div",{id:n?"show":"hide",className:"flex w-[90%] md:w-auto p-4 mb-4 bg-green-100 rounded-lg dark:bg-green-200 absolute top-20 left-1/2 transform -translate-x-1/2 -translate-y-1/2 z-50 ",role:"alert",children:[e("svg",{className:"flex-shrink-0 w-5 h-5 text-green-700 dark:text-green-800",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",children:e("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a1 1 0 000 2v3a1 1 0 001 1h1a1 1 0 100-2v-3a1 1 0 00-1-1H9z",clipRule:"evenodd"})}),e("div",{className:"ml-3 text-sm font-medium text-green-700 dark:text-green-800",children:o}),t("button",{onClick:()=>r(!1),type:"button",className:"ml-auto -mx-1.5 -my-1.5 bg-green-100 text-green-500 rounded-lg focus:ring-2 focus:ring-green-400 p-1.5 hover:bg-green-200 inline-flex h-8 w-8 dark:bg-green-200 dark:text-green-600 dark:hover:bg-green-300","data-collapse-toggle":"alert-2","aria-label":"Close",children:[e("span",{className:"sr-only",children:"Close"}),e("svg",{fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",children:e("path",{fillRule:"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",clipRule:"evenodd"})})]})]})}),R={email:""},M=p().shape({email:b().email("Invalid Email Address").required("Required")});function L(){const{forgotPassword:o}=h(),l=a.useRef(null),n=a.useRef(null),[r,c]=a.useState(null),[i,g]=a.useState(null);async function m(s){const{email:u}=s;try{await o(u),g("Email to change the password has been sent Successfully!"),n.current.show(),console.log("email has been sent successfully")}catch(d){c(d.message),l.current.show(),console.log(d)}}return t(f.div,{intial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0,transition:{duration:.2}},children:[e(w,{message:r,ref:l}),e(k,{message:i,ref:n}),t("div",{className:"grid grid-cols-1 lg:grid-cols-2 bg-black text-white",children:[t("div",{className:"w-full h-screen px-4 py-20 mx-auto xl:py-32 md:w-3/5 lg:w-4/5 xl:w-3/5",children:[e(x,{to:"/app",children:e("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-8 w-8 mb-10 text-white",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M10 19l-7-7m0 0l7-7m-7 7h18"})})}),e("h1",{className:"mb-8 -mt-3 text-2xl font-extrabold leading-snug text-left text-green-400 md:text-4xl font-title tracking-wide",children:"Forgot Password"}),e(v,{initialValues:R,onSubmit:m,validationSchema:M,validateOnMount:!0,children:s=>t(y,{autoComplete:"off",className:"divide-y divide-gray-200",children:[t("div",{className:" text-base leading-6 space-y-5 text-gray-700 sm:text-lg sm:leading-7",children:[e(N,{id:"email",name:"email",type:"email",placeholder:"Email address"}),t("p",{className:`font-medium text-[#1ed760] hover:text-[#1db954]\r 2 mt-4`,children:[" ",i," "]})]}),e("div",{className:"mt-8",children:e("button",{type:"submit",disabled:!s.isValid||s.isSubmitting,"aria-label":"create my account",className:`focus:ring-2 3 ${(!s.isValid||s.isSubmitting)&&"focus:ring-gray-700 bg-gray-700 border hover:bg-gray-600"} focus:ring-offset-2 focus:ring-green-600 text-sm font-semibold leading-none text-white focus:outline-none bg-green-600 border rounded hover:bg-green-600 py-4 w-full `,children:s.isSubmitting?"Sending You Email...":"Reset Password"})})]})})]}),e(S,{})]})]})}export{L 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.