How sankho1769/irl-xp works
IRL XP gamifies personal productivity through a user workflow of signing in, managing quests and focus sessions, and earning character progression and rewards. Protected pages present quest, character, story, focus, and shop experiences; DashboardContext coordinates server actions, while a presentation adapter shapes backend records for the UI. README documents additional profile, theme, achievement, boss, streak, and penalty capabilities. Some pages and actions were not sampled, so their internal call paths are not inferred.
Main entry points: DashboardContext.tsx Dashboard State · quests.ts Quest Actions · page.tsx Quest Log · server.ts Supabase Client
Components 30
Access & Shell
- Sign-in
app/login/page.tsx - Session Guard
middleware.ts - Dashboard
app/protected/page.tsx - Dashboard State
app/protected/DashboardContext.tsx
Quest & Focus
- Quest Log
app/protected/quests/page.tsx - Guild Board
components/dashboard/QuestBoardView.tsx - Board Quest Card
components/dashboard/QuestBoardCard.tsx - Quest Card
components/dashboard/QuestCard.tsx - Quest List
components/dashboard/QuestList.tsx - Quest Creation
components/dashboard/NewQuestModal.tsx - Focus Mode
app/protected/focus/page.tsx - Empty State
components/dashboard/EmptyState.tsx - Scribe Animation
components/dashboard/QuillScribeAnimation.tsx
Character & Rewards
- Character Sheet
app/protected/character/page.tsx - Character Status
components/dashboard/CharacterStatus.tsx - Story Chapters
app/protected/story/page.tsx - Shop
app/protected/shop/page.tsx - Shop Item Card
components/dashboard/ShopItemCard.tsx - Achievements
app/actions/achievements.ts - Achievement Overlay
components/dashboard/AchievementUnlockOverlay.tsx - Profile & Themes
app/actions/profile.ts - Number Animation
lib/hooks/useAnimatedNumber.ts
Actions & Data
- Quest Actions
app/actions/quests.ts - Character Actions
app/actions/character.ts - Shop Actions
app/actions/shop.ts - Data Adapter
lib/dashboard/character-adapter.ts - Dashboard Types
types/dashboard.ts - Supabase Client
lib/supabase/server.ts
Other components
- Player
- Supabase Database
Connections 41
- Player → Sign-in: signs in
README.md - Player → Dashboard: uses
README.md - Session Guard → Supabase Client: checks session
- Dashboard → Dashboard State: reads state
app/protected/page.tsx - Quest Log → Dashboard State: reads state
app/protected/quests/page.tsx - Quest Log → Guild Board: renders
app/protected/quests/page.tsx - Quest Log → Quest Card: renders
app/protected/quests/page.tsx - Quest Log → Quest List: renders
- Quest Log → Empty State: renders
app/protected/quests/page.tsx - Quest Log → Scribe Animation: uses
app/protected/quests/page.tsx - Guild Board → Board Quest Card: renders
components/dashboard/QuestBoardView.tsx - Guild Board → Quest Actions: calls
components/dashboard/QuestBoardView.tsx - Quest Card → Quest Actions: calls
components/dashboard/QuestCard.tsx - Quest Creation → Quest Actions: calls
components/dashboard/NewQuestModal.tsx - Focus Mode → Dashboard State: reads state
app/protected/focus/page.tsx - Focus Mode → Quest Actions: completes quest
- Dashboard State → Quest Actions: calls
app/protected/DashboardContext.tsx - Dashboard State → Character Actions: loads character
app/protected/DashboardContext.tsx - Dashboard State → Shop Actions: purchases item
app/protected/DashboardContext.tsx - Dashboard State → Profile & Themes: updates profile
app/protected/DashboardContext.tsx - Dashboard State → Achievements: loads achievements
app/protected/DashboardContext.tsx - Quest Actions → Achievements: imports type
app/actions/quests.ts - Quest Actions → Supabase Client: creates client
app/actions/quests.ts - Character Actions → Supabase Client: creates client
app/actions/character.ts - Profile & Themes → Supabase Client: creates client
app/actions/profile.ts - Shop Actions → Supabase Client: creates client
app/actions/shop.ts - Achievements → Supabase Client: creates client
app/actions/achievements.ts - Supabase Client → Supabase Database: queries data
- Dashboard State → Data Adapter: maps records
app/protected/DashboardContext.tsx - Data Adapter → Character Actions: maps character
lib/dashboard/character-adapter.ts - Data Adapter → Quest Actions: maps quests
lib/dashboard/character-adapter.ts - Data Adapter → Shop Actions: maps items
lib/dashboard/character-adapter.ts - Data Adapter → Dashboard Types: shapes data
lib/dashboard/character-adapter.ts - Character Sheet → Dashboard State: reads state
app/protected/character/page.tsx - Character Sheet → Character Status: renders
- Dashboard → Character Status: renders
app/protected/page.tsx - Character Status → Number Animation: animates values
components/dashboard/CharacterStatus.tsx - Shop → Dashboard State: reads state
app/protected/shop/page.tsx - Shop → Shop Item Card: renders
app/protected/shop/page.tsx - Achievement Overlay → Achievements: uses actions
components/dashboard/AchievementUnlockOverlay.tsx - Story Chapters → Dashboard State: reads state
app/protected/story/page.tsx