UI/UX enhancements: refined footer layout, dashboard sidebar fixes, header tweaks, and theme alignment

This commit is contained in:
2026-08-05 13:07:36 +05:30
parent 6760a21a7e
commit 54f60d097e
13 changed files with 152 additions and 139 deletions

View File

@@ -149,7 +149,7 @@ export default function AICoachDashboard() {
{ label: "Mistakes Mastered", value: 38, color: "text-green-400", bg: "bg-green-400/5", border: "border-green-400/20", icon: <CheckCircle2 size={32} /> },
{ label: "AI Sessions", value: 124, color: "text-purple-400", bg: "bg-purple-400/5", border: "border-purple-400/20", icon: <Bot size={32} /> },
].map((stat) => (
<Card key={stat.label} className={`border ${stat.border} ${stat.bg} backdrop-blur-sm shadow-sm hover:shadow-[0_0_20px_rgba(0,240,255,0.2)] transition-all duration-300 transform hover:-translate-y-1 rounded-2xl`}>
<Card key={stat.label} className={`border ${stat.border} ${stat.bg} backdrop-blur-sm transition-all duration-300 transform hover:-translate-y-1 rounded-2xl`}>
<CardContent className="p-6 flex flex-col items-center justify-center text-center">
<div className="text-3xl mb-2 filter drop-shadow-md">{stat.icon}</div>
<div className={`text-4xl font-black ${stat.color} leading-none tracking-tight mb-2 filter drop-shadow-sm`}>{stat.value}</div>

View File

@@ -144,7 +144,7 @@ export default function CBTPage() {
type="date"
value={dateFilter}
onChange={(e) => setDateFilter(e.target.value)}
className="w-full px-4 py-2 bg-background border border-border rounded-xl text-sm focus:ring-2 focus:ring-[#00F0FF] outline-none text-foreground [color-scheme:dark]"
className="w-full px-4 py-2 bg-background border border-border rounded-xl text-sm focus:ring-2 focus:ring-[#00F0FF] outline-none text-foreground dark:[color-scheme:dark] [color-scheme:light]"
/>
</div>
<div className="relative w-full sm:w-64">
@@ -370,7 +370,7 @@ export default function CBTPage() {
</Button>
) : isAttempted ? (
<div className="flex gap-2">
<Link href={`/cbt/${exam.id}/result`} className="flex-1">
<Link href={`/dashboard/cbt/history/${attempt.id}`} className="flex-1">
<Button className="w-full gap-2 rounded-xl bg-secondary border border-border text-foreground hover:bg-secondary/80 font-bold">
<PlayCircle size={16} /> Result
</Button>

View File

@@ -50,7 +50,7 @@ export default function DashboardLayout({ children }: { children: ReactNode }) {
}, [])
const userInitials = user ? user.name.split(" ").filter(n => /^[a-zA-Z]/.test(n)).slice(0, 2).map(n => n[0]).join("").toUpperCase() : "DS"
const targetExamLabel = user?.target_exam === "JEE_Main" ? "JEE Main" : user?.target_exam === "JEE_Advanced" ? "JEE Advanced" : user?.target_exam === "NEET" ? "NEET" : "NEET/JEE"
const targetExamLabel = user?.target_exam === "JEE_Main" ? "JEE" : user?.target_exam === "JEE_Advanced" ? "JEE Advanced" : user?.target_exam === "NEET" ? "NEET" : "NEET/JEE"
// Trial logic removed as requested
@@ -76,7 +76,7 @@ export default function DashboardLayout({ children }: { children: ReactNode }) {
<div className="px-6 py-5">
<Logo href="/dashboard" className="w-full" imageClassName="object-contain object-left scale-110 origin-left" height={56} />
</div>
<nav className="flex-1 px-4 space-y-1.5 mt-4 overflow-y-auto">
<nav className="flex-1 min-h-0 px-4 pb-16 space-y-1.5 mt-4 overflow-y-auto custom-scrollbar">
{/* <div className="pt-2 pb-2">
<p className="px-3 text-xs font-bold uppercase tracking-widest text-muted-foreground flex items-center gap-2">
<span className="w-1.5 h-1.5 rounded-full bg-white"></span> Free Tier
@@ -84,10 +84,8 @@ export default function DashboardLayout({ children }: { children: ReactNode }) {
</div> */}
<div className="pt-3 pb-1">
<p className="px-3 text-[10px] font-black uppercase tracking-widest text-muted-foreground/60 flex items-center gap-2">
<span className="flex-1 h-px bg-border/60"></span>
<span className="flex items-center gap-1.5"><span className="w-1.5 h-1.5 rounded-full bg-yellow-500 shadow-[0_0_8px_-2px_rgba(234,179,8,0.8)]"></span>Pro Tier</span>
<span className="flex-1 h-px bg-border/60"></span>
<p className="px-4 text-[11px] font-bold uppercase tracking-widest text-muted-foreground flex items-center gap-2">
<span className="w-1.5 h-1.5 rounded-full bg-yellow-500"></span> Pro Tier
</p>
</div>
@@ -131,10 +129,8 @@ export default function DashboardLayout({ children }: { children: ReactNode }) {
/>
<div className="pt-4 pb-1">
<p className="px-3 text-[10px] font-black uppercase tracking-widest text-muted-foreground/60 flex items-center gap-2">
<span className="flex-1 h-px bg-border/60"></span>
<span className="flex items-center gap-1.5"><span className="w-1.5 h-1.5 rounded-full bg-[#00F0FF] shadow-[0_0_8px_-2px_#00F0FF]"></span>AI Coach</span>
<span className="flex-1 h-px bg-border/60"></span>
<p className="px-4 text-[11px] font-bold uppercase tracking-widest text-muted-foreground flex items-center gap-2">
<span className="w-1.5 h-1.5 rounded-full bg-cyan-500"></span> AI Coach
</p>
</div>
<NavItem
@@ -249,7 +245,7 @@ export default function DashboardLayout({ children }: { children: ReactNode }) {
className="w-full flex items-center justify-between p-2 rounded-xl bg-background/50 hover:bg-background transition-colors border border-border/50 shadow-sm mt-3"
>
<div className="flex items-center gap-3 text-left">
<div className="h-8 w-8 rounded-full bg-[#00F0FF]/25 text-[#00F0FF] flex items-center justify-center font-bold text-sm shadow-[0_0_10px_-2px_#00F0FF] shrink-0">
<div className="h-8 w-8 rounded-full bg-cyan-500/20 text-cyan-700 dark:bg-cyan-500/20 dark:text-cyan-400 flex items-center justify-center font-bold text-sm shadow-none dark:shadow-[0_0_10px_-2px_#00F0FF] shrink-0">
{userInitials}
</div>
<div className="flex-1 min-w-0">
@@ -272,7 +268,7 @@ export default function DashboardLayout({ children }: { children: ReactNode }) {
{user ? `Welcome back, ${user.name.split(" ")[0]}!` : "Welcome back!"}
</h2>
{user && (
<Badge variant="outline" className="bg-[#00F0FF]/10 text-[#00F0FF] border-[#00F0FF]/20 font-bold tracking-wide uppercase px-2.5 py-0.5 animate-pulse">
<Badge variant="outline" className="bg-cyan-500/10 text-cyan-700 dark:text-cyan-400 border-cyan-500/20 font-bold tracking-wide uppercase px-2.5 py-0.5 animate-pulse shadow-none dark:shadow-[0_0_10px_-2px_#00F0FF]">
{targetExamLabel} Target
</Badge>
)}