PageSourceSearch

https://beloyar.net/build/assets/LoginPage-C8EMck7L.js

js beloyar.net collected 2026-10-06 12:09:06 UTC 2,238 bytes, 1 lines download raw bytes

1import{u as L,a as S,r as t,j as e,L as f}from"./vendor-react-OyOj6DeB.js";import{R as k}from"./RuEmailAuthNotice-DNm1nb4M.js";import{b as C}from"./app-DZKafuT-.js";import"./ruEmailSupport-CdDDTA-_.js";import"./vendor-axios-NIGUFBhG.js";import"./preload-helper-BfFHrpNk.js";function P(){var m;const N=L(),l=S(),v=C(),[r,b]=t.useState(""),[o,w]=t.useState(""),[i,n]=t.useState(!1),[c,u]=t.useState(""),y=!!((m=l.state)!=null&&m.passwordReset),E=async a=>{var d,h,p,x,j;a.preventDefault(),n(!0),u("");try{await v.login({email:r.trim(),password:o});const s=((d=l.state)==null?void 0:d.from)||"/profile";N(s)}catch(s){const g=(p=(h=s==null?void 0:s.response)==null?void 0:h.data)==null?void 0:p.errors;u(g?Object.values(g).flat().filter(Boolean).join(" "):((j=(x=s==null?void 0:s.response)==null?void 0:x.data)==null?void 0:j.message)||"Неверный email или пароль")}finally{n(!1)}};return e.jsx("div",{className:"auth-page dg-page",children:e.jsx("div",{className:"smk-shell",children:e.jsxs("div",{className:"auth-card",children:[e.jsx("h1",{className:"auth-card__title",children:"Вход"}),e.jsx(k,{}),y?e.jsx("p",{className:"auth-hint",style:{color:"#1a7f37",marginBottom:"1rem"},children:"Пароль обновлён — можно войти."}):null,e.jsxs("form",{onSubmit:E,className:"auth-form",children:[e.jsxs("label",{className:"auth-field",children:[e.jsx("span",{children:"E-mail"}),e.jsx("input",{type:"email",value:r,onChange:a=>b(a.target.value),required:!0,autoComplete:"email",placeholder:"[email protected]"})]}),e.jsxs("label",{className:"auth-field",children:[e.jsx("span",{children:"Пароль"}),e.jsx("input",{type:"password",value:o,onChange:a=>w(a.target.value),required:!0,autoComplete:"current-password",placeholder:"Пароль"})]}),c?e.jsx("p",{className:"auth-err",children:c}):null,e.jsx("button",{type:"submit",disabled:i,className:"auth-submit btn-hackett-solid",children:i?"Вход…":"Войти"}),e.jsx("p",{className:"auth-hint",children:e.jsx(f,{to:"/forgot-password",children:"Забыли пароль?"})}),e.jsxs("p",{className:"auth-hint",children:["Нет аккаунта? ",e.jsx(f,{to:"/register",children:"Регистрация"})]})]})]})})})}export{P 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.