diff --git a/frontend/src/pages/Activate.tsx b/frontend/src/pages/Activate.tsx
index cad05d5..507a128 100644
--- a/frontend/src/pages/Activate.tsx
+++ b/frontend/src/pages/Activate.tsx
@@ -62,12 +62,16 @@ export default function Activate() {
Your identity is now verified and ready for timeless letters.
+
+
)}
diff --git a/frontend/src/pages/Login.tsx b/frontend/src/pages/Login.tsx
index 075fa3a..0c6d6a9 100644
--- a/frontend/src/pages/Login.tsx
+++ b/frontend/src/pages/Login.tsx
@@ -1,8 +1,9 @@
import { zodResolver } from "@hookform/resolvers/zod";
+import { ShieldCheckIcon, WarningIcon } from "@phosphor-icons/react";
import axios from "axios";
import { useState } from "react";
import { useForm } from "react-hook-form";
-import { useNavigate } from "react-router-dom";
+import { useLocation, useNavigate } from "react-router-dom";
import { z } from "zod";
import { api, publicApi } from "../api/apiClient";
import Logo from "../components/Logo";
@@ -13,7 +14,7 @@ import { useAuth } from "../hooks/useAuth";
import { CryptoUtils } from "../utils/crypto";
const loginSchema = z.object({
- email: z.string().email("Please enter a valid email"),
+ email: z.email("Please enter a valid email"),
password: z.string().min(1, "Password is required"),
});
@@ -21,9 +22,11 @@ type LoginInputs = z.infer;
export default function Login() {
const navigate = useNavigate();
+ const location = useLocation();
const [isLoading, setIsLoading] = useState(false);
const [apiError, setApiError] = useState(null);
const { setAuthStore } = useAuth();
+ const [showWelcome, setShowWelcome] = useState(!!location.state?.firstTime);
const {
register,
@@ -70,62 +73,116 @@ export default function Login() {
};
return (
-