Skip to content

Latest commit

Β 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

ChoreSense 🏠

A fully functional React + TypeScript UI prototype for a roommate chore scheduling and fairness app, powered by mock data and interactive components.

Features

βœ… Dashboard - High-level view of your house with weekly overview, fairness balance, and AI insights βœ… Interactive Schedule - Weekly grid view with drag-and-drop-ready cards, "Why Me?" explanations βœ… Chore Swapping - Request fair swaps with AI-powered suggestions βœ… Roommate Profiles - View roommate details, reliability, stress levels, and swap history βœ… House Mood Selector - Set the vibe (Chill, Busy, Chaos, Drowning, Finals Mode) βœ… Notifications Demo - Generate contextualized reminder messages βœ… Fairness Visualization - Track effort distribution across roommates

Tech Stack

  • Frontend: React 19 + TypeScript
  • Styling: Tailwind CSS
  • Routing: React Router v7
  • Icons: Lucide React
  • State Management: React Context Hooks
  • Build Tool: Vite

Quick Start

# Install dependencies
npm install

# Start dev server
npm run dev

# Open in browser
# The app will be available at http://localhost:5173

Project Structure

src/
β”œβ”€β”€ components/              # 12 reusable UI components
β”‚   β”œβ”€β”€ AssignmentCard.tsx   # Draggable chore cards
β”‚   β”œβ”€β”€ AiInsightCard.tsx    # Smart recommendations
β”‚   β”œβ”€β”€ FairnessChart.tsx    # Effort distribution
β”‚   β”œβ”€β”€ Header.tsx           # Navigation bar
β”‚   β”œβ”€β”€ HouseMoodSelector.tsx# 5 mood buttons
β”‚   β”œβ”€β”€ HouseVibeCard.tsx    # Stress level indicator
β”‚   β”œβ”€β”€ RoommateCard.tsx     # Profile preview
β”‚   β”œβ”€β”€ ScheduleGrid.tsx     # Weekly grid layout
β”‚   β”œβ”€β”€ SwapSuggestionList.tsx
β”‚   β”œβ”€β”€ UpcomingChoresList.tsx
β”‚   β”œβ”€β”€ WeeklyChoreGrid.tsx  # Dashboard overview
β”‚   └── WhyMeModal.tsx       # Explanation popup
β”œβ”€β”€ pages/                   # 6 full pages
β”‚   β”œβ”€β”€ DashboardPage.tsx
β”‚   β”œβ”€β”€ SchedulePage.tsx
β”‚   β”œβ”€β”€ SwapPage.tsx
β”‚   β”œβ”€β”€ RoommatesPage.tsx
β”‚   β”œβ”€β”€ RoommateDetailPage.tsx
β”‚   └── NotificationsDemoPage.tsx
β”œβ”€β”€ context/                 # Global state
β”‚   └── HouseContext.tsx
β”œβ”€β”€ data/                    # Mock data
β”‚   └── mockData.ts
└── types/                   # TypeScript interfaces
    └── index.ts

Pages & Features

1. Dashboard (/)

  • πŸ“Š Weekly Chore Overview: Grid view of all assignments by day
  • 😊 House Vibe: Real-time stress indicator (Chill/Busy/Chaos/Drowning/Finals)
  • βš–οΈ Fairness Chart: Effort points per roommate with color-coded capacity
  • πŸ“‹ Upcoming Chores: Next 5 tasks with assignee and effort
  • πŸ’‘ AI Insights: Smart personalized recommendations
  • πŸŽ›οΈ Mood Selector: Set house vibe (affects all other pages)

2. Schedule (/schedule)

  • πŸ“… Interactive Grid: 7-column weekly layout
  • 🎴 Assignment Cards: Chore name, assignee avatar, effort level
  • ❓ "Why Me?" Modal: Click to see AI reasoning for assignment
  • βœ… Mark Complete: Hover to reveal "Done" button
  • πŸ€– Generate Schedule: Simulate AI schedule generation (with loading)
  • πŸ“Š Fairness Preview: Real-time effort distribution

3. Chore Swap (/swap)

  • πŸ‘€ Select Identity: Choose which roommate you are
  • 🧹 Pick Chore: Select from your assigned chores
  • πŸ’¬ Current Info: Display effort, day, assignee
  • ✨ AI Suggestions: Get 2 fair swap recommendations
  • πŸ”„ Apply Swap: One-click swap application
  • πŸ“ Reasoning: See why swaps are recommended

4. Roommates (/roommates)

  • 🎴 Roommate Grid: 3-column card layout
  • πŸ“ˆ Profile Stats: Reliability bar, stress dots, capacity
  • πŸ”— Click to Detail: Navigate to full profile

5. Roommate Detail (/roommates/:id)

  • πŸ–ΌοΈ Profile Header: Avatar, name, mood emoji
  • πŸ“Š Stats Dashboard: 4 key metrics in colored boxes
  • πŸ“ This Week: Current chores and effort
  • πŸ“ˆ Historical Graph: Last 4 weeks trend
  • πŸ’¬ Swap History: Recent swaps with dates
  • 🏷️ Preferences: Favorite chores and unavailable days

6. Notifications Demo (/notifications-demo)

  • βš™οΈ Configuration Panel: Roommate, chore, date, mood, reliability
  • 🎲 Generate Button: Simulate AI message generation
  • πŸ’¬ Live Preview: Styled notification bubble
  • πŸš€ Send Action: Trigger notification
  • 🎯 Mood Adaptation: Messages change based on house mood

Mock Data

3 Roommates:

  • Alex: High reliability (0.85), low stress, dishes expert
  • Sam: Very reliable (0.9), high stress (finals mode), light load
  • Jordan: Good reliability (0.7), medium stress, high capacity

6 Chores:

  • Dishes (5 pts)
  • Bathroom (7 pts, heavy)
  • Vacuuming (6 pts)
  • Trash (3 pts)
  • Kitchen (8 pts, heavy)
  • Laundry (4 pts)

Weekly Assignments: Pre-loaded for week of 2025-11-24

How It Works

State Management

Uses React Context to manage global state:

interface HouseContextType {
  assignments: Assignment[];          // Current week's chores
  houseMood: HouseMood;               // Chill/Busy/Chaos/Drowning/Finals
  setAssignments: (a: Assignment[]) => void;
  updateAssignment: (a: Assignment) => void;
  setHouseMood: (m: HouseMood) => void;
}

Data Types

// Roommate: Profile with reliability, stress, capacity
type Roommate = {
  id: string;
  name: string;
  reliability: number;      // 0–1
  stressLevel: number;      // 1–5
  weeklyCapacity: number;   // effort pts
  unavailableDays: string[];
};

// Chore: Task with effort and frequency
type Chore = {
  id: string;
  name: string;
  baseEffort: number;       // 1–10
  grossness: number;        // 1–5
  isHeavy?: boolean;        // >= 7 effort
};

// Assignment: Weekly task assignment
type Assignment = {
  week: string;             // ISO date
  choreId: string;
  assignedTo: string;       // roommate id
  day: string;              // Mon–Sun
  completed: boolean;
  reason?: string;          // AI explanation
};

Mocked AI Features

All "AI" features use simulated delays and predefined responses:

  1. Generate Schedule (1.5s delay)

    • Adds "[AI-Generated]" prefix to reasons
    • Demonstrates async workflow
  2. Swap Suggestions (1.5s delay)

    • Returns 2 mock suggestions with reasons
    • Shows fairness-based recommendations
  3. Reminder Text (1.2s delay)

    • Template-based message generation
    • Adapts tone based on house mood

Interactivity Demo

βœ… House Mood: Click buttons to change (affects recommendations) βœ… Mark Complete: Hover on cards, click "Done" βœ… View Reasons: Click "?" on any chore βœ… Schedule Generation: Click "Ask AI..." button (simulated) βœ… Swap Requests: Fill form and click "Ask AI for Suggestions" βœ… Profile Navigation: Click any roommate card βœ… Notification Preview: Select options and generate

Building & Deployment

# Development
npm run dev              # Start dev server

# Production
npm run build           # Build for production
npm run preview         # Preview production build
npm run lint            # Run ESLint

Browser Support

  • Chrome/Edge 90+
  • Firefox 88+
  • Safari 15+
  • iOS Safari 15+
  • Chrome Mobile 90+

UI/UX Highlights

🎨 Design System:

  • Color-coded effort levels (green/yellow/red)
  • Gradient backgrounds for visual hierarchy
  • Responsive grid layouts
  • Smooth hover and transition effects
  • Accessible button states
  • Dark/light border treatments

πŸ“± Responsive:

  • Mobile-first design
  • Flex/grid layouts
  • Touch-friendly buttons
  • Stack on small screens

✨ Interactivity:

  • Loading states with spinners
  • Modal popups for details
  • Hover effects and transitions
  • Click handlers for all actions
  • Real-time updates to state

Future Enhancement Ideas

To make this a production app:

  1. Backend API

    • Node.js/Express server
    • Real Claude API integration
    • PostgreSQL database
    • Authentication (JWT)
  2. Real Features

    • Photo uploads for chore proof
    • Push notifications
    • Recurring chore templates
    • Penalty/reward system
  3. Advanced UI

    • Dark mode toggle
    • Customizable themes
    • Analytics dashboard
    • Mobile app (React Native)

Built during hackathon. All data is mocked, no backend required.

If you are developing a production application, we recommend updating the configuration to enable type-aware lint rules:

export default defineConfig([
  globalIgnores(['dist']),
  {
    files: ['**/*.{ts,tsx}'],
    extends: [
      // Other configs...

      // Remove tseslint.configs.recommended and replace with this
      tseslint.configs.recommendedTypeChecked,
      // Alternatively, use this for stricter rules
      tseslint.configs.strictTypeChecked,
      // Optionally, add this for stylistic rules
      tseslint.configs.stylisticTypeChecked,

      // Other configs...
    ],
    languageOptions: {
      parserOptions: {
        project: ['./tsconfig.node.json', './tsconfig.app.json'],
        tsconfigRootDir: import.meta.dirname,
      },
      // other options...
    },
  },
])

You can also install eslint-plugin-react-x and eslint-plugin-react-dom for React-specific lint rules:

// eslint.config.js
import reactX from 'eslint-plugin-react-x'
import reactDom from 'eslint-plugin-react-dom'

export default defineConfig([
  globalIgnores(['dist']),
  {
    files: ['**/*.{ts,tsx}'],
    extends: [
      // Other configs...
      // Enable lint rules for React
      reactX.configs['recommended-typescript'],
      // Enable lint rules for React DOM
      reactDom.configs.recommended,
    ],
    languageOptions: {
      parserOptions: {
        project: ['./tsconfig.node.json', './tsconfig.app.json'],
        tsconfigRootDir: import.meta.dirname,
      },
      // other options...
    },
  },
])

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages