diff --git a/src/components/auth/AcademyAuthLayout.tsx b/src/components/auth/AcademyAuthLayout.tsx new file mode 100644 index 0000000..b0da56c --- /dev/null +++ b/src/components/auth/AcademyAuthLayout.tsx @@ -0,0 +1,49 @@ +import type { ReactNode } from "react"; +import { BrandLogo } from "../brand/BrandLogo"; + +export function AcademyAuthLayout({ children }: { children: ReactNode }) { + return ( +
+
+ +

Welcome
back.

+
+ +
+

The beauty academy

+

Artistry starts here.

+
+

MAKEUP SCHOOL & STUDIO EST. FOR CREATIVITY

+
+ +
+
+
+ {children} + +
+
+
+ ); +} diff --git a/src/pages/auth/ForgotPasswordPage.tsx b/src/pages/auth/ForgotPasswordPage.tsx index 4e3c473..504116a 100644 --- a/src/pages/auth/ForgotPasswordPage.tsx +++ b/src/pages/auth/ForgotPasswordPage.tsx @@ -1,10 +1,9 @@ import { useState } from "react" import { Link } from "react-router-dom" -import { ArrowLeft } from "lucide-react" +import { ArrowLeft, ArrowRight, Check, LockKeyhole } from "lucide-react" import { toast } from "sonner" -import successSrc from "../../assets/success.svg" import { sendTeamPasswordReset } from "../../api/team.api" -import { BrandLogo } from "../../components/brand/BrandLogo" +import { AcademyAuthLayout } from "../../components/auth/AcademyAuthLayout" import { Button } from "../../components/ui/button" import { Input } from "../../components/ui/input" import { SpinnerIcon } from "../../components/ui/spinner-icon" @@ -41,128 +40,43 @@ export function ForgotPasswordPage() { } return ( -
-
-
-
-
-
-
+ + +
- -
-
-
- + ) : ( + <> +
+

+

Forgot password?

+

Enter your academy team email and we'll send you a link to reset your password.

- - - - Back to sign in - - - {submitted ? ( -
- -

- Check your email -

-

- We've sent a password reset link to{" "} - {email.trim()}. - The link expires in 5 minutes — open it promptly to set a new password. -

- +
+
+ + {setEmail(e.target.value);if (error) setError(null)}} required autoComplete="email" disabled={submitting} + className="academy-login-input" aria-describedby={error ? "reset-error" : undefined} />
- ) : ( - <> -
-

- Account Recovery -

-

- Forgot password? -

-

- Enter your team email and we'll send you a reset link. -

-
- - -
- - { - setEmail(e.target.value) - if (error) setError(null) - }} - required - autoComplete="email" - disabled={submitting} - className="h-11 rounded-xl" - /> -
- - {error ? ( -

- {error} -

- ) : null} - - -
- - )} - -

- © {new Date().getFullYear()} Rezina Academy · All rights reserved -

-
-
-
+ {error && } + + +

Need help accessing your academy account?
Contact your administrator.

+ + )} + ) } diff --git a/src/pages/auth/LoginPage.tsx b/src/pages/auth/LoginPage.tsx index f67e6f9..a8ffd9a 100644 --- a/src/pages/auth/LoginPage.tsx +++ b/src/pages/auth/LoginPage.tsx @@ -3,7 +3,7 @@ import { useCallback, useEffect, useState } from "react"; import { Link, Navigate, useNavigate, useSearchParams } from "react-router-dom"; import { getApiErrorMessage } from "../../lib/apiErrors"; -import { BrandLogo } from "../../components/brand/BrandLogo"; +import { AcademyAuthLayout } from "../../components/auth/AcademyAuthLayout"; import { Button } from "../../components/ui/button"; import { Input } from "../../components/ui/input"; import { Label } from "../../components/ui/label"; @@ -99,41 +99,7 @@ export function LoginPage() { }; return ( -
-
- -

Welcome
back.

-
- -
-

The beauty academy

-

Artistry starts here.

-
-

MAKEUP SCHOOL & STUDIO EST. FOR CREATIVITY

-
- -
-
-
+

Admin login

@@ -170,11 +136,6 @@ export function LoginPage() {

Access is reserved for academy team members.
Contact your administrator if you need an account.

- -
-
-
+ ); }