From 1dafc7d312bd0fb85a20412e4ebdb35d4f9344e4 Mon Sep 17 00:00:00 2001 From: hobokenchicken Date: Thu, 23 Apr 2026 09:23:52 -0400 Subject: [PATCH] feat: rustic dashboard redesign --- frontend/src/app/dashboard/page.tsx | 299 ++++++++++++++++++++-------- 1 file changed, 215 insertions(+), 84 deletions(-) diff --git a/frontend/src/app/dashboard/page.tsx b/frontend/src/app/dashboard/page.tsx index 42df376..f842b9f 100644 --- a/frontend/src/app/dashboard/page.tsx +++ b/frontend/src/app/dashboard/page.tsx @@ -1,7 +1,17 @@ "use client"; -import { useRouter } from "next/navigation"; import { useEffect, useState } from "react"; +import { useRouter } from "next/navigation"; +import { + ArrowRight, + BadgeDollarSign, + Bird, + Clock3, + Loader2, + PartyPopper, + RefreshCw, + ShieldCheck, +} from "lucide-react"; import { toast } from "sonner"; import { Button } from "@/components/ui/button"; import { @@ -27,6 +37,35 @@ interface WalletData { totalSpent: number; } +function StatTile({ + label, + value, + hint, + icon: Icon, +}: { + label: string; + value: string; + hint: string; + icon: any; +}) { + return ( +
+
+
+
+ {label} +
+
{value}
+
{hint}
+
+
+ +
+
+
+ ); +} + export default function DashboardPage() { const router = useRouter(); const { isAuthenticated, logout } = useStore(); @@ -79,100 +118,192 @@ export default function DashboardPage() { logout(); router.push("/login"); }; + const handleRefresh = () => { + loadWalletAndPending(); + syncPending(); + }; - if (isLoading) return
Loading...
; + if (isLoading) + return ( +
+ +
+ ); return ( -
-
- -
- - - Coop - DB-only credits - - -
-
-
Nest Egg
-
- {formatNumber(wallet?.balance || 0)} $COOP +
+
+
+
+
+
+
+ + Join flock +
+
+

+ Barnyard coop +

+

+ Keep nest full, request feed, track harvest. Warm barn light, + quick lookup, no fluff. +

+
+
+ + +
-
-
- Total Gathered +
+
+
+ + Nest Egg + + +
+
+ {formatNumber(wallet?.balance || 0)}{" "} + $COOP +
+
+ Ready to spend on requests. +
-
- {formatNumber(wallet?.totalEarned || 0)} -
-
-
-
Spent
-
- {formatNumber(wallet?.totalSpent || 0)} +
+
+
+ Gathered +
+
+ {formatNumber(wallet?.totalEarned || 0)} +
+
+
+
+ Spent +
+
+ {formatNumber(wallet?.totalSpent || 0)} +
+
-
- +
+
+ + + +
+
+ + + + Harvest board + + + Watch, requests, leaderboard. All feed, no smoke. + + + + + + History + Requests + Leaderboard + + + + + + + + + + + + + +
+ + + + Quick request + + Grab content fast. + + + + + + + + + + Recent activity + + Newest barn noise. + + + + +
- - -
- - - Pending requests - My requests waiting - - - {pendingRequests.length} - - - - - Movie cost - - - {requestCosts.movie} - - - - - TV cost - - - {requestCosts.tv} - - +
+
- - - History - Requests - Leaderboard - - - - - - - - - - - - -
); }