(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6827],{7934:(e,s,t)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/send-password-reset-link",function(){return t(7569)}])},4179:(e,s,t)=>{"use strict";t.d(s,{A:()=>r});var a=t(4848);function r(e){let{message:s,className:t}=e;return(0,a.jsxs)("div",{className:"info green"+(t?" "+t:""),children:[(0,a.jsx)("img",{src:"/images/checkmark.svg",alt:"Warning Image Icon",width:22,className:"-my-2"}),(0,a.jsx)("span",{children:s})]})}t(6540)},9625:(e,s,t)=>{"use strict";t.d(s,{A:()=>n});var a=t(4848),r=t(6540);function n(e){let{pageTitle:s,pageDescription:t,pagePathname:n,aceEditor:l}=e;return(0,a.jsxs)(r.Fragment,{children:[(0,a.jsx)("link",{rel:"canonical",href:"http://localhost:7070"+n}),(0,a.jsx)("meta",{property:"og:url",content:"http://localhost:7070"+n}),(0,a.jsx)("meta",{itemProp:"url",content:"http://localhost:7070"+n}),(0,a.jsx)("meta",{name:"twitter:url",content:"http://localhost:7070"+n}),(0,a.jsx)("meta",{property:"og:title",content:s}),(0,a.jsx)("meta",{property:"og:description",content:t}),(0,a.jsx)("meta",{itemProp:"name",content:s}),(0,a.jsx)("meta",{itemProp:"description",content:t}),(0,a.jsx)("meta",{name:"twitter:title",content:s}),(0,a.jsx)("meta",{name:"twitter:description",content:t}),l&&(0,a.jsxs)(r.Fragment,{children:[(0,a.jsx)("script",{src:"https://cdnjs.cloudflare.com/ajax/libs/ace/1.22.0/ace.min.js",integrity:"sha512-q6CTB0jS+VuJnSct82rVcWlI06LGzNjaG3CWenHWVUncRvc4UQMFkA3a5Ip880xr+lBx38FcHDclOxPdSg+sBw==",crossOrigin:"anonymous",referrerPolicy:"no-referrer"}),(0,a.jsx)("script",{src:"https://cdnjs.cloudflare.com/ajax/libs/ace/1.22.0/ext-language_tools.min.js",integrity:"sha512-6g6cvocV7eT/J8L44lL8gJKqq9onqQeYGgJO0DmrsYFcCfRl6wYkYA/KHS768r4QVTB4JxsCcMQ9gIezxpTCZw==",crossOrigin:"anonymous",referrerPolicy:"no-referrer"})]})]})}},7569:(e,s,t)=>{"use strict";t.r(s),t.d(s,{SendPassResetContext:()=>h,__N_SSP:()=>u,default:()=>x});var a=t(4848),r=t(6540),n=t(4252),l=t(9625),i=t(1710),c=t(9020),o=t(4179);let d=(0,t(5737).A)("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);function m(e){let{message:s}=e;return(0,a.jsxs)("div",{className:"info gray",children:[(0,a.jsx)(d,{}),(0,a.jsx)("span",{className:"font-normal",children:s})]})}var u=!0;let h=r.createContext({});function x(e){var s;let t="Cloudbased SQL data management system | Datasquirel",d="Datasquirel is a fast and efficient cloud-based SQL data management system that takes away the entire hassle of dealing with data both locally and across different platforms.",u=(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("title",{children:t}),(0,a.jsx)("meta",{name:"description",content:d}),(0,a.jsx)(l.A,{pageTitle:t,pageDescription:d,pagePathname:"/"})]}),[x,p]=r.useState(!1),[j,f]=r.useState(!1);return(0,a.jsx)(n.A,{head:u,user:e.user,children:(0,a.jsx)(h.Provider,{value:{user:e.user},children:(0,a.jsx)("main",{children:(0,a.jsxs)("section",{children:[x&&(0,a.jsx)(i.A,{}),j?(0,a.jsx)(o.A,{message:"Email Sent. Please check your email address and follow the link provided",className:"whitespace-nowrap"}):(0,a.jsx)("div",{className:"paper",children:(0,a.jsxs)("div",{className:"max-w-xl flex-col items-stretch",children:[(0,a.jsx)("h1",{className:"m-0 text-4xl",children:"Send Password Reset Link"}),(0,a.jsx)("span",{children:"Please enter your email address to receive a password reset link"}),(0,a.jsxs)("form",{className:"w-full flex flex-col items-stretch gap-4",onSubmit:e=>{p(!0),e.preventDefault();let s=e.target["email-address"].value;(0,c.A)("/api/sendPasswordResetLink?email=".concat(s)).then(e=>{console.log(e),setTimeout(()=>{p(!1)},500),e.success&&f(!0)})},children:[(0,a.jsx)("input",{type:"text",autoComplete:"email",name:"email-address",id:"email-address",className:"w-full",placeholder:"Email Address",defaultValue:(null==e?void 0:null===(s=e.user)||void 0===s?void 0:s.logged_in_status)?e.user.email:"",required:!0}),(0,a.jsx)("button",{children:"Send password reset Email"}),(0,a.jsx)(m,{message:"Please note that this link will expire after 1 hour"})]})]})})]})})})})}}},e=>{var s=s=>e(e.s=s);e.O(0,[636,6593,8792],()=>s(7934)),_N_E=e.O()}]);