From 89fffa17247d8bdb100da154ff21c50ec05e42e4 Mon Sep 17 00:00:00 2001 From: "Builder.io" Date: Tue, 5 Aug 2025 23:07:32 +0000 Subject: [PATCH] Create login page with dashboard redirect cgen-703b18b2afe6453480c6a4ea05a84d13 --- client/pages/Login.tsx | 203 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 203 insertions(+) create mode 100644 client/pages/Login.tsx diff --git a/client/pages/Login.tsx b/client/pages/Login.tsx new file mode 100644 index 00000000..4f3217d8 --- /dev/null +++ b/client/pages/Login.tsx @@ -0,0 +1,203 @@ +import { useState } from "react"; +import { useNavigate } from "react-router-dom"; +import Layout from "@/components/Layout"; +import { Button } from "@/components/ui/button"; +import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/components/ui/card"; +import { Input } from "@/components/ui/input"; +import { Label } from "@/components/ui/label"; +import { Badge } from "@/components/ui/badge"; +import LoadingScreen from "@/components/LoadingScreen"; +import { + LogIn, + ArrowRight, + Shield, + Sparkles, + Github, + Mail, + Lock, + User +} from "lucide-react"; + +export default function Login() { + const [isLoading, setIsLoading] = useState(false); + const [email, setEmail] = useState(""); + const [password, setPassword] = useState(""); + const navigate = useNavigate(); + + const handleLogin = async (e: React.FormEvent) => { + e.preventDefault(); + setIsLoading(true); + + // Simulate login process + setTimeout(() => { + setIsLoading(false); + navigate("/dashboard"); + }, 2000); + }; + + const handleSocialLogin = (provider: string) => { + setIsLoading(true); + // Simulate social login + setTimeout(() => { + setIsLoading(false); + navigate("/dashboard"); + }, 1500); + }; + + if (isLoading) { + return ; + } + + return ( + +
+
+ {/* Floating particles effect */} +
+ {[...Array(20)].map((_, i) => ( +
+ ))} +
+ + + +
+
+ +
+
+
+ Welcome Back + + Sign in to your AeThex account to access the dashboard + +
+ + + Secure Login + +
+ + + {/* Social Login Buttons */} +
+ + +
+ +
+
+
+
+
+ Or continue with email +
+
+ + {/* Email/Password Form */} +
+
+ +
+ + setEmail(e.target.value)} + placeholder="Enter your email" + className="pl-10 bg-background/50 border-border/50 focus:border-aethex-400" + required + /> +
+
+ +
+ +
+ + setPassword(e.target.value)} + placeholder="Enter your password" + className="pl-10 bg-background/50 border-border/50 focus:border-aethex-400" + required + /> +
+
+ +
+ + +
+ + +
+ +
+

+ Don't have an account?{" "} + +

+
+ + + + {/* Security Notice */} +
+

+ 🔒 Your data is protected with enterprise-grade security +

+
+
+
+ + ); +}