Skip to content

Commit 2b20164

Browse files
Merge pull request #12 from Shitanshukumar607/add-style-to-auth-pages
add style to auth pages
2 parents eb54e3a + 6eba37d commit 2b20164

File tree

3 files changed

+181
-13
lines changed

3 files changed

+181
-13
lines changed

app/login/page.tsx

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -71,13 +71,21 @@ const Login = () => {
7171
};
7272

7373
return (
74-
<div className="bg-zinc-50 dark:bg-neutral-900/80 flex min-h-svh w-full items-center justify-center p-6 md:p-10">
75-
<div className="w-full max-w-sm">
74+
<section className="relative overflow-hidden bg-zinc-50 dark:bg-neutral-900/80 flex min-h-svh w-full items-center justify-center p-6 md:p-10">
75+
<div className="hidden sm:block absolute top-10 left-10 h-16 w-16 border-t-2 border-l-2 border-emerald-400 dark:border-violet-500 opacity-60 rounded-tl-lg" />
76+
<div className="hidden sm:block absolute bottom-10 right-10 h-20 w-20 border-b-2 border-r-2 border-emerald-400 dark:border-violet-500 opacity-60 rounded-br-lg" />
77+
78+
<div className="absolute top-1/3 -left-6 w-24 h-24 border border-emerald-300 dark:border-violet-400/40 rounded-full opacity-30" />
79+
<div className="absolute bottom-1/4 -right-8 w-20 h-20 border border-emerald-300 dark:border-violet-400/40 rotate-12 opacity-30" />
80+
81+
<div className="w-full max-w-sm relative z-10">
7682
<div className="flex flex-col gap-6">
77-
<Card>
83+
<Card className="border-emerald-200/50 dark:border-violet-500/30 shadow-lg">
7884
<CardHeader className="text-center">
79-
<CardTitle className="text-xl">Welcome back</CardTitle>
80-
<CardDescription>
85+
<CardTitle className="text-xl text-slate-900 dark:text-neutral-100">
86+
Welcome back
87+
</CardTitle>
88+
<CardDescription className="text-slate-600 dark:text-neutral-400">
8189
Login with your GitHub or Google account
8290
</CardDescription>
8391
</CardHeader>
@@ -89,6 +97,7 @@ const Login = () => {
8997
onClick={() => handleOAuthLogin("github")}
9098
variant="outline"
9199
type="button"
100+
className="border-emerald-200 text-slate-700 hover:bg-emerald-50 hover:border-emerald-300 dark:border-violet-400/40 dark:text-neutral-300 dark:hover:bg-violet-500/10 dark:hover:border-violet-400"
92101
>
93102
<Image
94103
width="24"
@@ -102,6 +111,7 @@ const Login = () => {
102111
onClick={() => handleOAuthLogin("google")}
103112
variant="outline"
104113
type="button"
114+
className="border-emerald-200 text-slate-700 hover:bg-emerald-50 hover:border-emerald-300 dark:border-violet-400/40 dark:text-neutral-300 dark:hover:bg-violet-500/10 dark:hover:border-violet-400"
105115
>
106116
<GoogleIcon className="size-8" />
107117
Login with Google
@@ -143,7 +153,7 @@ const Login = () => {
143153
<Field>
144154
<Button
145155
type="submit"
146-
className="w-full"
156+
className="w-full bg-emerald-600 text-white hover:bg-emerald-700 dark:bg-violet-600 dark:hover:bg-violet-700 transition-colors"
147157
disabled={isLoading}
148158
>
149159
{isLoading ? "Logging in..." : "Login"}
@@ -159,7 +169,7 @@ const Login = () => {
159169
</Card>
160170
</div>
161171
</div>
162-
</div>
172+
</section>
163173
);
164174
};
165175

app/not-found.tsx

Lines changed: 144 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,144 @@
1+
"use client";
2+
3+
import { Button } from "@/components/ui/button";
4+
import { motion, Variants } from "framer-motion";
5+
import { ArrowLeft, Home, SearchX } from "lucide-react";
6+
import Link from "next/link";
7+
8+
const container: Variants = {
9+
hidden: { opacity: 0 },
10+
show: {
11+
opacity: 1,
12+
transition: {
13+
staggerChildren: 0.1,
14+
delayChildren: 0.3,
15+
},
16+
},
17+
};
18+
19+
const item: Variants = {
20+
hidden: { opacity: 0, y: 20 },
21+
show: {
22+
opacity: 1,
23+
y: 0,
24+
transition: {
25+
type: "spring",
26+
stiffness: 100,
27+
damping: 15,
28+
},
29+
},
30+
};
31+
32+
const NotFound = () => {
33+
return (
34+
<section className="relative overflow-hidden bg-zinc-50 dark:bg-neutral-900/80 min-h-svh flex items-center justify-center p-6">
35+
{/* Accent Corner Lines */}
36+
<div className="hidden sm:block absolute top-10 left-10 h-16 w-16 border-t-2 border-l-2 border-emerald-400 dark:border-violet-500 opacity-60 rounded-tl-lg" />
37+
<div className="hidden sm:block absolute bottom-10 right-10 h-20 w-20 border-b-2 border-r-2 border-emerald-400 dark:border-violet-500 opacity-60 rounded-br-lg" />
38+
39+
{/* Geometric Shape Decorations */}
40+
<div className="absolute top-1/3 -left-6 w-24 h-24 border border-emerald-300 dark:border-violet-400/40 rounded-full opacity-30" />
41+
<div className="absolute bottom-1/4 -right-8 w-20 h-20 border border-emerald-300 dark:border-violet-400/40 rotate-12 opacity-30" />
42+
43+
{/* Additional geometric shapes for 404 */}
44+
<div className="absolute top-1/4 right-1/4 w-16 h-16 border-2 border-emerald-200 dark:border-violet-300/30 rotate-45 opacity-20" />
45+
<div className="absolute bottom-1/3 left-1/4 w-12 h-12 bg-emerald-100 dark:bg-violet-500/10 rounded-full opacity-40" />
46+
47+
<div className="max-w-2xl mx-auto text-center relative z-10">
48+
<motion.div initial="hidden" animate="show" variants={container}>
49+
{/* 404 Number with Icon */}
50+
<motion.div
51+
className="flex items-center justify-center gap-4 mb-8"
52+
variants={item}
53+
>
54+
<SearchX className="size-20 text-emerald-500 dark:text-violet-400" />
55+
<span className="text-8xl sm:text-9xl font-bold text-emerald-600 dark:text-violet-500 tracking-tight">
56+
404
57+
</span>
58+
</motion.div>
59+
60+
{/* Heading */}
61+
<motion.h1
62+
className="text-3xl sm:text-5xl font-bold tracking-tight mb-6 text-slate-900 dark:text-neutral-100"
63+
variants={item}
64+
>
65+
Oops! Page Not Found
66+
</motion.h1>
67+
68+
{/* Subtext */}
69+
<motion.p
70+
className="text-lg text-slate-600 dark:text-neutral-400 max-w-lg mx-auto mb-10"
71+
variants={item}
72+
>
73+
The page you&apos;re looking for seems to have wandered off into the
74+
digital void. Don&apos;t worry, it happens to the best of us!
75+
</motion.p>
76+
77+
{/* Action Buttons */}
78+
<motion.div
79+
className="flex flex-col sm:flex-row gap-4 justify-center"
80+
variants={{
81+
hidden: { opacity: 0, y: 20 },
82+
show: {
83+
opacity: 1,
84+
y: 0,
85+
transition: {
86+
staggerChildren: 0.1,
87+
delayChildren: 0.4,
88+
},
89+
},
90+
}}
91+
>
92+
<motion.div
93+
whileHover={{ scale: 1.05 }}
94+
whileTap={{ scale: 0.98 }}
95+
variants={item}
96+
>
97+
<Link href="/">
98+
<Button
99+
size="lg"
100+
className="gap-2 bg-emerald-600 text-white hover:bg-emerald-700 dark:bg-violet-600 dark:hover:bg-violet-700 transition-all duration-200"
101+
>
102+
<Home className="h-5 w-5" />
103+
Go Home
104+
</Button>
105+
</Link>
106+
</motion.div>
107+
108+
<motion.div
109+
whileHover={{ scale: 1.05 }}
110+
whileTap={{ scale: 0.98 }}
111+
variants={item}
112+
>
113+
<Button
114+
variant="outline"
115+
size="lg"
116+
onClick={() => window.history.back()}
117+
className="gap-2 border-emerald-200 text-slate-700 hover:bg-emerald-50 hover:border-emerald-300 dark:border-violet-400/40 dark:text-neutral-300 dark:hover:bg-violet-500/10 dark:hover:border-violet-400 transition-all duration-200"
118+
>
119+
<ArrowLeft className="h-5 w-5" />
120+
Go Back
121+
</Button>
122+
</motion.div>
123+
</motion.div>
124+
125+
{/* Additional Help Text */}
126+
<motion.div className="mt-12 text-center" variants={item}>
127+
<p className="text-sm text-slate-500 dark:text-neutral-500">
128+
Need help? Visit our{" "}
129+
<Link
130+
href="/"
131+
className="text-emerald-600 dark:text-violet-400 hover:text-emerald-700 dark:hover:text-violet-300 underline underline-offset-2 transition-colors"
132+
>
133+
homepage
134+
</Link>{" "}
135+
or try converting an image to SVG.
136+
</p>
137+
</motion.div>
138+
</motion.div>
139+
</div>
140+
</section>
141+
);
142+
};
143+
144+
export default NotFound;

app/signup/page.tsx

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -73,15 +73,23 @@ const Signup = () => {
7373
};
7474

7575
return (
76-
<section className="flex min-h-svh flex-col items-center justify-center p-6 md:p-10">
77-
<div className="w-full max-w-sm md:max-w-md flex flex-col gap-6">
78-
<Card className="overflow-hidden p-0">
76+
<section className="relative overflow-hidden bg-zinc-50 dark:bg-neutral-900/80 flex min-h-svh flex-col items-center justify-center p-6 md:p-10">
77+
<div className="hidden sm:block absolute top-10 left-10 h-16 w-16 border-t-2 border-l-2 border-emerald-400 dark:border-violet-500 opacity-60 rounded-tl-lg" />
78+
<div className="hidden sm:block absolute bottom-10 right-10 h-20 w-20 border-b-2 border-r-2 border-emerald-400 dark:border-violet-500 opacity-60 rounded-br-lg" />
79+
80+
<div className="absolute top-1/3 -left-6 w-24 h-24 border border-emerald-300 dark:border-violet-400/40 rounded-full opacity-30" />
81+
<div className="absolute bottom-1/4 -right-8 w-20 h-20 border border-emerald-300 dark:border-violet-400/40 rotate-12 opacity-30" />
82+
83+
<div className="w-full max-w-sm md:max-w-md flex flex-col gap-6 relative z-10">
84+
<Card className="overflow-hidden p-0 border-emerald-200/50 dark:border-violet-500/30 shadow-lg">
7985
<CardContent>
8086
<form className="px-2 py-6" onSubmit={handleSignup}>
8187
<FieldGroup>
8288
<div className="flex flex-col items-center gap-2 text-center">
83-
<h1 className="text-2xl font-bold">Create your account</h1>
84-
<p className="text-muted-foreground text-sm text-balance">
89+
<h1 className="text-2xl font-bold text-slate-900 dark:text-neutral-100">
90+
Create your account
91+
</h1>
92+
<p className="text-slate-600 dark:text-neutral-400 text-sm text-balance">
8593
Enter your email below to create your account
8694
</p>
8795
</div>
@@ -127,7 +135,11 @@ const Signup = () => {
127135
</Field>
128136
{error && <p className="text-sm text-red-500">{error}</p>}
129137
<Field>
130-
<Button type="submit" disabled={isLoading}>
138+
<Button
139+
type="submit"
140+
disabled={isLoading}
141+
className="w-full bg-emerald-600 text-white hover:bg-emerald-700 dark:bg-violet-600 dark:hover:bg-violet-700 transition-colors"
142+
>
131143
{isLoading ? "Creating Account..." : "Create Account"}
132144
</Button>
133145
</Field>
@@ -139,6 +151,7 @@ const Signup = () => {
139151
variant="outline"
140152
type="button"
141153
onClick={() => handleOAuthLogin("github")}
154+
className="border-emerald-200 text-slate-700 hover:bg-emerald-50 hover:border-emerald-300 dark:border-violet-400/40 dark:text-neutral-300 dark:hover:bg-violet-500/10 dark:hover:border-violet-400"
142155
>
143156
<Image
144157
width="24"
@@ -152,6 +165,7 @@ const Signup = () => {
152165
variant="outline"
153166
type="button"
154167
onClick={() => handleOAuthLogin("google")}
168+
className="border-emerald-200 text-slate-700 hover:bg-emerald-50 hover:border-emerald-300 dark:border-violet-400/40 dark:text-neutral-300 dark:hover:bg-violet-500/10 dark:hover:border-violet-400"
155169
>
156170
<GoogleIcon className="size-8" />
157171
<span className="sr-only">Sign up with Google</span>

0 commit comments

Comments
 (0)