I'll create a comprehensive interactive analytics dashboard for a GLP-1 medication clinic. Let me start by installing the necessary packages and then building the dashboard.
Now let me create the comprehensive analytics dashboard with all the requested features:
Let me fix the TypeScript errors:
Now let me build the project to confirm it works:
Let me update the HTML title:
Perfect! I've created a comprehensive interactive analytics dashboard for a GLP-1 medication clinic. Here's what I built:
Dashboard Features
📊 KPI Summary Cards
- Total Revenue (€671.5K) with 12.5% growth indicator
- Active Patients (2,847) with 8.2% growth
- Average Satisfaction (87%) with 3.1% improvement
- Total Prescriptions (4,523) with 5.7% increase
- Each card has gradient icons, trend indicators with up/down arrows, and hover effects
📈 Interactive Charts
- Area/Line Chart - Revenue trend with target comparison over 12 months
- Donut Chart - Medication distribution (Ozempic, Wegovy, Mounjaro, Saxenda, Victoza)
- Bar Chart - Weekly activity showing consultations, prescriptions, and follow-ups
- Horizontal Bar Chart - Patient demographics by age group
- All charts have custom hover tooltips, smooth animations, and legend support
📋 Sortable & Filterable Data Table
- 50 realistic patient records with ID, name, medication, segment, dates, spending, adherence, and status
- Clickable column headers for sorting (ascending/descending)
- Visual adherence progress bars with color coding (green/yellow/red)
- Status badges (Active/Inactive)
- Pagination indicator showing filtered results
🔍 Live Filters
- Date Range Selector - 1, 3, 6, or 12 months
- Segment Filter - Nuevo, Recurrencia, Premium, Estándar
- Medication Filter - All GLP-1 medications
- Search Bar - Real-time patient search by name or ID
- Refresh Button - Reset data view
- All filters update every view instantly
🎨 Design Features
- Dark Mode Toggle - Sun/Moon icon in header with smooth transitions
- Modern Gradient Styling - Purple-to-pink brand colors throughout
- Responsive Layout - Mobile-first design with grid breakpoints
- Clear Hierarchy - Header → Filters → KPIs → Charts → Table → Footer
- Smooth Transitions - Hover effects, color transitions, and animated progress bars
📱 Responsive Design
- Single column on mobile
- 2-column grid on tablets
- 4-column grid on desktop for KPIs
- Charts stack appropriately on smaller screens
- Table scrolls horizontally on mobile
The dashboard uses realistic sample data that makes every chart feel alive with meaningful metrics for a GLP-1 medication clinic serving patients.
Files built: src/App.tsx, index.html