- Created native D1 database layer (src/lib/d1.ts) to bypass Prisma fs.readdir issues
- Updated all API routes to use direct D1 queries
- Added date-utils.ts with local date helpers to fix UTC timezone mismatch
- Calendar now correctly colors today's usage
- Data persists correctly across page refreshes
- Update prisma.ts to use getPrismaWithD1() with getCloudflareContext()
- Update all API routes to use async D1 connection
- Add open-next.config.ts for Cloudflare Workers deployment
- Add wrangler.jsonc with D1 binding and custom domain routes
- Fix TypeScript type errors in API routes and storage
- Add @workos-inc/authkit-nextjs dependency
- Remove incompatible prisma.config.ts
- Achievements system with 6 badges and confetti celebration animation
- Health recovery timeline showing 9 milestones from 20min to 1 year
- Money savings tracker with cost configuration and goal progress
- Daily reminder notifications with browser permission handling
- New Prisma models: Achievement, ReminderSettings, SavingsConfig
- API routes for all new features
- Full dashboard integration with staggered animations
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Implement theme context provider with localStorage persistence and add
toggle button to header. Update Dashboard, StatsCard, QuitPlanCard,
SubstanceTrackingPage, and UsageCalendar components with theme-aware
gradients and colors. Also add daily inspirational quotes to calendar
and fix usage prompt to only show once per day.
- Restore QuitPlanCard component under calendar on dashboard
- Yellow gradient during tracking phase (before 7 days of data)
- Pink gradient when quit plan is active
- Track unique days with logged data for countdown
- Generate 4-week plan with 25% weekly reduction
- White text throughout for readability
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- 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>
- 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>
- 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>
- 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>