1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[459],{3236:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/login",function(){return n(1442)}])},6226:function(e,t,n){"use strict";var l=n(5893),o=n(7294),a=n(1163),s=n(7367),r=n(8433),i=n(136);let c=()=>{let[e,t]=(0,o.useState)(""),[n,c]=(0,o.useState)(""),[u,d]=(0,o.useState)(""),p=(0,a.useRouter)(),h=e=>{let{target:n}=e,{value:l}=n;t(l)},x=e=>{let{target:t}=e,{value:n}=t;c(n)},f=async t=>{t.preventDefault();try{let{data:t}=await r.Z.post("/api/login",{email:e,password:window.btoa(n)});localStorage.setItem("authToken",t.authToken),await p.push("/admin")}catch(t){let{response:e}=t;d(null==e?void 0:e.data.message)}};return(0,l.jsx)("div",{className:"w-full h-full flex justify-center items-center",children:(0,l.jsxs)("form",{className:"w-1/2 flex flex-col gap-y-5 items-center",onSubmit:f,children:[(0,l.jsx)("h2",{className:"font-montserrat font-bold text-70 text-blue3F98FF",children:"Login"}),(0,l.jsx)(s.Z,{value:e,placeholder:"Email",onChange:h}),(0,l.jsx)(s.Z,{type:"password",value:n,placeholder:"Password",onChange:x}),u.length>0&&(0,l.jsx)("p",{className:"font-poppins font-normal text-20 text-red-700",children:u}),(0,l.jsx)(i.Z,{type:"submit",children:"Send"})]})})};t.Z=c},136:function(e,t,n){"use strict";var l=n(5893);n(7294);let o=e=>{let{type:t="button",onClick:n,children:o,small:a=!1,id:s}=e;return(0,l.jsx)("button",{onClick:"button"===t?n:()=>{},className:"w-min bg-blue3F98FF font-poppins font-bold ".concat(a?"text-20":"text-23"," text-white ").concat(a?"px-24 py-7":"px-54 py-9"," rounded-5xl"),type:t,id:s,children:o})};t.Z=o},7367:function(e,t,n){"use strict";var l=n(5893);n(7294);let o=e=>{let{placeholder:t,value:n,onChange:o,type:a="text"}=e;return(0,l.jsx)("input",{placeholder:t,className:"border border-blue3F98FF rounded-[20px] outline-0 bg-transparent w-full h-45 md:h-84 font-poppins font-normal text-18 overflow-auto placeholder:font-poppins placeholder:font-light placeholder:text-18 placeholder:md:text-22 placeholder:lg:text-25 placeholder:text-grayA1A1A1 p-20",type:a,value:n,onChange:o})};t.Z=o},1442:function(e,t,n){"use strict";n.r(t);var l=n(5893),o=n(6226),a=n(9008),s=n.n(a);let r=()=>(0,l.jsxs)(l.Fragment,{children:[(0,l.jsxs)(s(),{children:[(0,l.jsx)("title",{children:"Login - Kidemy"}),(0,l.jsx)("meta",{name:"description",content:"Login to Kidemy platform"}),(0,l.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),(0,l.jsx)("link",{rel:"icon",href:"/favicon.ico"})]}),(0,l.jsx)(o.Z,{})]});t.default=r},9008:function(e,t,n){e.exports=n(3121)}},function(e){e.O(0,[433,774,888,179],function(){return e(e.s=3236)}),_N_E=e.O()}]);
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.