diff --git a/apps/admin/public/logo.svg b/apps/admin/public/logo.svg new file mode 100644 index 0000000..d00ad98 --- /dev/null +++ b/apps/admin/public/logo.svg @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/admin/public/nextform-logo.png b/apps/admin/public/nextform-logo.png new file mode 100644 index 0000000..1d1c9b8 Binary files /dev/null and b/apps/admin/public/nextform-logo.png differ diff --git a/apps/admin/public/nextform-logo.svg b/apps/admin/public/nextform-logo.svg new file mode 100644 index 0000000..be91656 --- /dev/null +++ b/apps/admin/public/nextform-logo.svg @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/apps/admin/public/nextform.png b/apps/admin/public/nextform.png new file mode 100644 index 0000000..59b180d --- /dev/null +++ b/apps/admin/public/nextform.png @@ -0,0 +1 @@ +PNG - NextForm Logo \ No newline at end of file diff --git a/apps/admin/src/app/api/fitness-goals/[id]/complete/route.ts b/apps/admin/src/app/api/fitness-goals/[id]/complete/route.ts index 6f62465..28a8504 100644 --- a/apps/admin/src/app/api/fitness-goals/[id]/complete/route.ts +++ b/apps/admin/src/app/api/fitness-goals/[id]/complete/route.ts @@ -5,7 +5,7 @@ import { getDatabase } from '@/lib/database'; // POST - Mark goal as complete export async function POST( req: NextRequest, - { params }: { params: { id: string } } + { params }: { params: Promise<{ id: string }> } ) { try { const { userId } = await auth(); diff --git a/apps/admin/src/app/api/fitness-goals/[id]/route.ts b/apps/admin/src/app/api/fitness-goals/[id]/route.ts index dc31594..d0f6fb5 100644 --- a/apps/admin/src/app/api/fitness-goals/[id]/route.ts +++ b/apps/admin/src/app/api/fitness-goals/[id]/route.ts @@ -5,7 +5,7 @@ import { getDatabase } from '@/lib/database'; // GET - Get specific goal export async function GET( req: NextRequest, - { params }: { params: { id: string } } + { params }: { params: Promise<{ id: string }> } ) { try { const { userId } = await auth(); @@ -40,7 +40,7 @@ export async function GET( // PUT - Update goal export async function PUT( req: NextRequest, - { params }: { params: { id: string } } + { params }: { params: Promise<{ id: string }> } ) { try { const { userId } = await auth(); @@ -82,7 +82,7 @@ export async function PUT( // DELETE - Delete goal export async function DELETE( req: NextRequest, - { params }: { params: { id: string } } + { params }: { params: Promise<{ id: string }> } ) { try { const { userId } = await auth(); diff --git a/apps/admin/src/app/globals.css b/apps/admin/src/app/globals.css index b219a46..82fe513 100644 --- a/apps/admin/src/app/globals.css +++ b/apps/admin/src/app/globals.css @@ -32,7 +32,7 @@ --input: 214.3 31.8% 91.4%; --ring: 222.2 84% 4.9%; - --radius: 0.5rem; + --radius: 0.75rem; } .dark { diff --git a/apps/admin/src/app/layout.tsx b/apps/admin/src/app/layout.tsx index 8ae151c..82fe904 100644 --- a/apps/admin/src/app/layout.tsx +++ b/apps/admin/src/app/layout.tsx @@ -25,11 +25,34 @@ export default function RootLayout({ return ( - -
+ +
-
- {children} +
+
+
+
+

FitAI Pro

+
+
+ + + + + + +
+
+
+
+ {children} +
diff --git a/apps/admin/src/app/page.tsx b/apps/admin/src/app/page.tsx index a0d682a..614df46 100644 --- a/apps/admin/src/app/page.tsx +++ b/apps/admin/src/app/page.tsx @@ -46,56 +46,85 @@ export default function Home() { }; return ( -
-
-

Dashboard

-

Welcome back, here's what's happening today.

-
- -
- - - 0 ? "+" : ""}${stats.revenueGrowth}%`} - trend={stats.revenueGrowth >= 0 ? "up" : "down"} - icon={CreditCard} - color="purple" - /> - -
- -
-
-

Recent Activity

- +
+
+ {/* Hero Section */} +
+
+
+ NextForm +
+
+

+ NextForm +

+
+
+

Performance metrics & athlete insights

+
-
-

Quick Analytics

- + {/* Stats Grid */} +
+ + + 0 ? "+" : ""}${stats.revenueGrowth}%`} + trend={stats.revenueGrowth >= 0 ? "up" : "down"} + icon={CreditCard} + color="purple" + /> + +
+ + {/* Main Content Grid */} +
+ {/* User Management - Full Width */} +
+
+
+

Active Athletes

+

Manage and monitor your fitness clients

+
+ +
+
+ + {/* Analytics - 3 Columns Horizontal Layout */} +
+
+

Analytics

+

Performance metrics and insights

+
+ +
diff --git a/apps/admin/src/app/profile/page.tsx b/apps/admin/src/app/profile/page.tsx index 646ae54..43533e2 100644 --- a/apps/admin/src/app/profile/page.tsx +++ b/apps/admin/src/app/profile/page.tsx @@ -2,7 +2,7 @@ import { useEffect, useState } from "react"; import { useUser } from "@clerk/nextjs"; -import { Button } from "@/components/ui/Button"; +import { Button } from "@/components/ui/button"; import { Input } from "@/components/ui/input"; interface UserProfile { diff --git a/apps/admin/src/components/Navigation.tsx b/apps/admin/src/components/Navigation.tsx index 9faa549..9c8e91a 100644 --- a/apps/admin/src/components/Navigation.tsx +++ b/apps/admin/src/components/Navigation.tsx @@ -6,7 +6,7 @@ import { usePathname } from "next/navigation"; import { Home, Users, BarChart3, User, Brain } from "lucide-react"; import { SignedIn, UserButton } from "@clerk/nextjs"; import { cn } from "@/lib/utils"; -import { Button } from "@/components/ui/Button"; +import { Button } from "@/components/ui/button"; interface NavItem { href: string; @@ -52,9 +52,16 @@ export function Navigation(): ReactElement { {/* Logo */} - FitAI + NextForm + + NextForm + {/* Navigation Items */} diff --git a/apps/admin/src/components/analytics/AnalyticsDashboard.tsx b/apps/admin/src/components/analytics/AnalyticsDashboard.tsx index 8031fdc..9124325 100644 --- a/apps/admin/src/components/analytics/AnalyticsDashboard.tsx +++ b/apps/admin/src/components/analytics/AnalyticsDashboard.tsx @@ -67,74 +67,75 @@ export function AnalyticsDashboard() { if (loading) { return (
-
Loading analytics...
+
+
+

Loading analytics...

+
) } return ( -
-

Analytics Dashboard

+
+ {/* Key Metrics Cards - 3 columns */} +
+
+

Total Athletes

+
+
{totalUsers}
+ active +
+
- {/* Key Metrics */} -
- - -
-
{totalUsers}
-
Total Users
-
-
-
+
+

Total Revenue

+
+
${totalRevenue.toLocaleString()}
+ ytd +
+
- - -
-
${totalRevenue.toLocaleString()}
-
Total Revenue
-
-
-
- - - -
-
{activeMembers}
-
Active Members
-
-
-
+
+

Active Members

+
+
{activeMembers}
+ members +
+
- {/* Charts */} -
- - -

User Growth

-
- + {/* Charts - 3 Columns Horizontal */} +
+
+
+

User Growth Trend

+

Last 6 months performance

+
+
- - +
+
- - -

Membership Distribution

-
- +
+
+

Membership Mix

+

Distribution breakdown

+
+
- - -
+
+
- - -

Monthly Revenue

-
- - - -
+
+
+

Revenue Stream

+

Monthly earnings

+
+
+ +
+
+
) } \ No newline at end of file diff --git a/apps/admin/src/components/ui/Sidebar.tsx b/apps/admin/src/components/ui/Sidebar.tsx index 8332f86..b6ac2e1 100644 --- a/apps/admin/src/components/ui/Sidebar.tsx +++ b/apps/admin/src/components/ui/Sidebar.tsx @@ -65,14 +65,25 @@ export function Sidebar() { ]; return ( -