A modern, full-featured diabetes management application with AI assistance, glucose tracking, and comprehensive health analytics.
- Smart Glucose Tracking: Monitor blood sugar levels with visual trends and analytics
- AI Health Assistant: Chat with an AI-powered diabetes advisor for personalized guidance
- Health Dashboard: Real-time overview of glucose levels, trends, and health metrics
- Comprehensive Reports: Detailed analytics with downloadable PDF reports
- Emergency Assistance: Quick access to emergency resources and first aid information
- Profile Management: Track personal health information and preferences
- Mobile-Responsive: Fully optimized for both desktop and mobile devices
- React 18.3.1 - UI framework
- React Router 7 - Client-side routing
- TypeScript - Type safety
- Tailwind CSS v4 - Styling
- Recharts - Data visualization
- Radix UI - Accessible UI components
- Lucide React - Icon library
- Sonner - Toast notifications
- Vite - Build tool
Before you begin, ensure you have the following installed:
- Node.js (v18 or higher) - Download
- pnpm (v8 or higher) - Install pnpm
To check if you have these installed:
node --version
pnpm --version-
Navigate to the project directory:
cd /path/to/project -
Install dependencies:
pnpm install
This will install all required packages including React, React Router, Tailwind CSS, and UI components.
Start the development server:
pnpm run devThe application will be available at the preview URL provided by the Figma Make environment.
Note: In the Figma Make environment, the dev server is already running. Simply make changes to the code and they will hot-reload automatically.
To create a production build:
pnpm run buildsrc/
├── app/
│ ├── components/
│ │ ├── ui/ # Reusable UI components (buttons, cards, etc.)
│ │ ├── figma/ # Figma-specific components
│ │ └── MobileNav.tsx # Mobile bottom navigation
│ ├── pages/
│ │ ├── LandingPage.tsx # Home/landing page
│ │ ├── LoginPage.tsx # User login
│ │ ├── SignupPage.tsx # User registration with OTP
│ │ ├── DashboardLayout.tsx # Dashboard shell with sidebar
│ │ ├── DashboardHome.tsx # Main dashboard view
│ │ ├── TrackerPage.tsx # Glucose tracking
│ │ ├── ChatbotPage.tsx # AI assistant
│ │ ├── ProfilePage.tsx # User profile
│ │ ├── EmergencyPage.tsx # Emergency resources
│ │ ├── ReportsPage.tsx # Health analytics
│ │ └── NotFoundPage.tsx # 404 page
│ ├── routes.tsx # Route configuration
│ └── App.tsx # Root component
├── styles/
│ ├── theme.css # Theme variables and colors
│ └── fonts.css # Font imports
└── imports/ # Figma imports and assets
/- Landing page with features showcase/login- User login/signup- User registration with OTP verification
/dashboard- Main dashboard with glucose overview/dashboard/tracker- Glucose tracking and monitoring/dashboard/chatbot- AI health assistant/dashboard/profile- User profile management/dashboard/reports- Health analytics and reports/dashboard/emergency- Emergency assistance
The application is fully responsive with dedicated mobile features:
- Bottom Navigation: Easy thumb-reach navigation on mobile
- Responsive Layouts: Adapts to all screen sizes
- Touch-Optimized: Large touch targets for mobile interaction
- Mobile-First Charts: Optimized data visualizations
On screens smaller than 768px, the sidebar is hidden and replaced with a bottom navigation bar featuring:
- Home (Dashboard)
- Tracker
- Chatbot
- Profile
Primary Colors:
- Blue:
#2563EB - Cyan:
#06B6D4 - Emerald:
#10B981
Background:
- Light Gray:
#F8FAFC - White:
#FFFFFF
Status Colors:
- Error/Emergency:
#EF4444 - Warning:
#F59E0B - Success:
#22C55E
- Headings: Poppins (Bold)
- Body: Inter / Nunito Sans
The app uses a comprehensive UI component library including:
- Buttons, Cards, Badges
- Forms (Input, Select, Textarea)
- Data Display (Tables, Charts)
- Overlays (Dialogs, Tooltips, Popovers)
- Navigation (Tabs, Menus)
- Real-time glucose level display
- Weekly trend charts
- AI-generated health suggestions
- Recent readings history
- Manual glucose entry
- Time and meal status tracking
- Visual trend graphs
- Reading history with status indicators
- Intelligent responses to health questions
- Chat history management
- Quick question shortcuts
- Context-aware diabetes guidance
- Monthly glucose averages
- Reading distribution analytics
- Health score calculation
- Downloadable PDF reports
- Quick access to emergency services
- Symptom recognition guide
- First aid instructions
- Emergency contact management
The application currently uses mock data for demonstration purposes:
- Authentication: Any credentials will work for login/signup
- Glucose Readings: Pre-populated sample data
- AI Responses: Rule-based responses to common questions
- Charts: Sample data for visualization
- Real backend integration with authentication
- Database connection for data persistence
- CGM (Continuous Glucose Monitor) device integration
- NFC scanning support
- Geolocation for nearby hospitals
- Voice assistant integration
- Export to healthcare providers
- Medication reminders
- Meal logging with nutrition info
- Chrome (latest)
- Firefox (latest)
- Safari (latest)
- Edge (latest)
Issue: Brave Shields automatically blocks port-to-port connections on localhost (e.g., from Vite's frontend port 5173 to the Express backend port 5000), forcing the application into Offline Demo Mode.
- Solution:
- Open
http://localhost:5173in Brave. - Click the orange Lion head icon (Brave Shields) in the right side of the address bar.
- Toggle the Shields OFF for this site (the switch will change from purple to gray).
- Refresh the page to connect cleanly to the local backend.
- Open
If you get a port conflict error, the dev server may already be running. Check for existing processes.
Try clearing the pnpm cache:
pnpm store prune
pnpm installMake sure you're using the correct Node.js version:
node --version # Should be v18 or higher- This is a Figma Make project with a special build configuration
- Do NOT run
vite builddirectly - usepnpm run build - The entrypoint is auto-generated at runtime
- Use the preview surface instead of localhost URLs
This project is for demonstration purposes.
For issues or questions:
- Check the Figma Make documentation
- Review the design blueprint in
src/imports/pasted_text/diabeguide-design-blueprint.md
Built with ❤️ using Figma Make