Skip to main content
Glama
Dinesh-Satram

Health & Fitness Coach MCP

sidebar.tsx3.94 kB
"use client" import { Activity, Utensils, MessageSquare, TrendingUp } from "lucide-react" import { Button } from "@/components/ui/button" import { cn } from "@/lib/utils" interface SidebarProps { activeTab: string setActiveTab: (tab: string) => void progressData: { workoutMinutes: number workoutProgress: number caloriesConsumed: number caloriesProgress: number stepsTaken: number stepsProgress: number } } export function Sidebar({ activeTab, setActiveTab, progressData }: SidebarProps) { const tabs = [ { name: "Workouts", icon: Activity, color: "text-orange-500" }, { name: "Nutrition", icon: Utensils, color: "text-green-500" }, { name: "Feedback", icon: MessageSquare, color: "text-blue-500" }, ] return ( <aside className="w-80 bg-white/80 backdrop-blur-sm border-r border-white/20 p-6 space-y-6"> {/* Quick Stats */} <div className="space-y-4"> <h2 className="text-lg font-semibold text-slate-800 flex items-center gap-2"> <TrendingUp className="w-5 h-5 text-lime-500" /> Today's Progress </h2> <div className="space-y-3"> <div className="bg-gradient-to-r from-lime-50 to-green-50 rounded-2xl p-4 border border-lime-200/50"> <div className="flex justify-between items-center"> <span className="text-slate-600 font-medium">Workout Minutes</span> <span className="text-2xl font-bold text-lime-600">{progressData.workoutMinutes}</span> </div> <div className="mt-2 bg-lime-200 rounded-full h-2"> <div className="bg-gradient-to-r from-lime-400 to-green-500 h-2 rounded-full" style={{width: `${progressData.workoutProgress}%`}}></div> </div> </div> <div className="bg-gradient-to-r from-orange-50 to-red-50 rounded-2xl p-4 border border-orange-200/50"> <div className="flex justify-between items-center"> <span className="text-slate-600 font-medium">Calories Consumed</span> <span className="text-2xl font-bold text-orange-500">{progressData.caloriesConsumed}</span> </div> <div className="mt-2 bg-orange-200 rounded-full h-2"> <div className="bg-gradient-to-r from-orange-400 to-red-500 h-2 rounded-full" style={{width: `${progressData.caloriesProgress}%`}}></div> </div> </div> <div className="bg-gradient-to-r from-blue-50 to-indigo-50 rounded-2xl p-4 border border-blue-200/50"> <div className="flex justify-between items-center"> <span className="text-slate-600 font-medium">Steps Taken</span> <span className="text-2xl font-bold text-blue-500">{progressData.stepsTaken}</span> </div> <div className="mt-2 bg-blue-200 rounded-full h-2"> <div className="bg-gradient-to-r from-blue-400 to-indigo-500 h-2 rounded-full" style={{width: `${progressData.stepsProgress}%`}}></div> </div> </div> </div> </div> {/* History Tabs */} <div className="space-y-4"> <h2 className="text-lg font-semibold text-slate-800">History</h2> <div className="space-y-2"> {tabs.map((tab) => ( <Button key={tab.name} variant="ghost" className={cn( "w-full justify-start gap-3 h-12 rounded-2xl transition-all duration-200", activeTab === tab.name ? "bg-gradient-to-r from-slate-100 to-slate-50 shadow-sm border border-slate-200" : "hover:bg-slate-50", )} onClick={() => setActiveTab(tab.name)} > <tab.icon className={cn("w-5 h-5", tab.color)} /> <span className="font-medium">{tab.name}</span> </Button> ))} </div> </div> </aside> ) }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Dinesh-Satram/fitness_coach_MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server