9 Commits

Author SHA1 Message Date
Avery Felts
4a26c1ccdc Add dual substance tracking with dedicated pages and enhanced UI
- Add dropdown menu on profile icon with navigation options
- Create separate tracking pages for Nicotine and Marijuana
- Add interactive usage trend graphs using recharts
- Update Log Usage button to prompt for substance selection each time
- Update calendar to show different colors:
  - Gray: No usage
  - Red: Nicotine only
  - Green: Marijuana only
  - Split red/green: Both substances
- Add substance-specific stats cards on dashboard
- Add inspirational message "One day at a time..." on tracking pages
- Show both substance counts in calendar day cells

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-24 01:20:59 -07:00
Avery Felts
750c5af465 Switch from localStorage to SQLite database for persistent storage
- Add Prisma ORM with SQLite for server-side data persistence
- Create UserPreferences and UsageEntry models
- Add API routes for preferences and usage data CRUD operations
- Update storage.ts to use fetch API calls instead of localStorage
- Update components to use async data fetching
- Data now persists across devices for each user account

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-24 01:08:10 -07:00
Avery Felts
498b7b4dea Sync stats and calendar updates using shared refresh key
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 22:03:01 -07:00
Avery Felts
39a1e858fb Fix per-user data isolation by passing userId explicitly to all storage operations
- Pass user.id explicitly to all storage function calls instead of relying on global state
- Add userId prop to UsageCalendar and UsagePromptDialog components
- Fix UserHeader to use user.id when fetching preferences
- Add refreshKey to force calendar re-render after logging usage

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 22:01:16 -07:00
Avery Felts
a244e740c9 Store data per-user using unique account ID
- Add user ID prefix to all localStorage keys
- Each user now has isolated data storage
- New users see fresh setup wizard
- Switching accounts loads that user's specific data

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 21:52:00 -07:00
Avery Felts
cab5e5810a Add clear day option to calendar
- Add clearDayData function to remove specific day's usage
- Add "Clear This Day" button in calendar edit dialog
- Allows users to reset individual days without clearing all data

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 21:45:04 -07:00
Avery Felts
9918432686 Update UI and add user personalization features
- Rename app from QuitTrack to QuitTraq
- Add metallic dark gradient background
- Change header to light purple gradient
- Add name and age collection in setup wizard
- Display personalized "Welcome {name}, you got this!" message
- Hide username/email, show only profile picture
- Change calendar to red gradient for usage days
- Update logging prompt to "just took" instead of daily total
- Add floating "Log Puff" button for easy access
- Fix calendar editing to properly update values
- Add glass-morphism effect to cards

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 21:40:59 -07:00
Avery Felts
a812e6342c Implement QuitTrack smoking cessation tracking app
- Add WorkOS SSO authentication (Google and Apple sign-in)
- Add daily usage tracking with calendar view
- Add setup wizard for substance selection (nicotine/cannabis)
- Add daily check-in prompt on login
- Add statistics dashboard (daily avg, streak, etc.)
- Add quit plan generation after 7 days of tracking
- Apply custom theme from brief.md
- Add "stay logged in" preference

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 21:25:01 -07:00
Avery Felts
76a4b617b1 Initial commit from Create Next App 2026-01-23 21:13:15 -07:00