Skip to content

Saj8292008/Calendertask

Repository files navigation

Productivity Hub App

A comprehensive productivity application built with Next.js 16 that combines task management, Pomodoro timer, Google Calendar integration, AI-powered planning assistance, and gamification features.

Features

Core Productivity Tools

  • Task Management: Create, edit, and organize tasks with priority levels (p0-p4)
  • Pomodoro Timer: 25-minute focus sessions with break reminders
  • Priority Calculator: Smart priority assignment based on effort, impact, and dependencies
  • Google Calendar Integration: Two-way sync with Google Calendar
  • Task Dependencies: Track blocked/unblocking task relationships

AI Companion

  • Planner Mode: Smart daily task scheduling recommendations
  • Coach Mode: Real-time focus suggestions based on time of day
  • Reflector Mode: End-of-day insights and productivity analytics

Analytics & Learning

  • Focus Profile: Track peak productivity hours and patterns
  • Learning Engine: Analyzes your work habits to improve predictions
  • Weekly Recaps: Automated weekly productivity summaries
  • Burndown Charts: Visual progress tracking

Gamification

  • XP System: Earn experience points for completing tasks
  • Level Progression: Level up as you complete more work
  • Streaks: Track consecutive days of productivity
  • Achievements: Unlock achievements for milestones

Automation

  • Morning Auto-Planning: Automatic daily task planning
  • Evening Auto-Review: End-of-day reflection prompts
  • Weekly Digest: Automated weekly summary generation

Tech Stack

  • Framework: Next.js 16.0.0 (React 19.2.0)
  • Language: TypeScript 5
  • Styling: Tailwind CSS 4
  • Calendar API: Google Calendar API (googleapis)
  • Charts: Recharts 3.3.0
  • Date Utilities: date-fns 4.1.0

Getting Started

Prerequisites

  • Node.js 20 or higher
  • npm, yarn, pnpm, or bun
  • Google Cloud Platform account (for Calendar API)

Installation

  1. Clone the repository:
git clone <repository-url>
cd productivity-app
  1. Install dependencies:
npm install
  1. Set up environment variables:
cp .env.example .env.local
  1. Configure your Google Calendar API credentials (see Deployment Guide)

  2. Run the development server:

npm run dev
  1. Open http://localhost:3000 in your browser

Environment Variables

Required variables:

NEXT_PUBLIC_GOOGLE_CLIENT_ID=your_client_id_here.apps.googleusercontent.com
NEXT_PUBLIC_GOOGLE_API_KEY=your_api_key_here

See .env.example for all available configuration options.

Development

Available Scripts

  • npm run dev - Start development server
  • npm run build - Build for production
  • npm start - Start production server
  • npm run lint - Run ESLint

Project Structure

productivity-app/
├── app/
│   ├── calendar/          # Calendar integration page
│   ├── components/        # React components
│   │   ├── AIAssistant.tsx
│   │   ├── PomodoroTimer.tsx
│   │   ├── TaskList.tsx
│   │   └── ...
│   ├── context/           # React Context providers
│   │   └── TaskContext.tsx
│   ├── priority/          # Priority management page
│   ├── services/          # API services
│   │   ├── calendarService.ts
│   │   ├── companionService.ts
│   │   ├── learningEngine.ts
│   │   └── priorityCalculator.ts
│   ├── tasks/             # Task management page
│   ├── globals.css        # Global styles
│   ├── layout.tsx         # Root layout
│   └── page.tsx           # Home page
├── public/                # Static assets
├── .env.example           # Environment variable template
├── DEPLOYMENT.md          # Deployment guide
├── next.config.ts         # Next.js configuration
├── tailwind.config.ts     # Tailwind configuration
├── tsconfig.json          # TypeScript configuration
└── vercel.json            # Vercel deployment config

Deployment

This app is optimized for deployment on Vercel, but can be deployed to any platform that supports Next.js.

Quick Deploy to Vercel

Deploy with Vercel

Manual Deployment

For detailed deployment instructions, see DEPLOYMENT.md.

Important: Data Persistence

Current Limitation: This app uses browser localStorage for data storage. This means:

  • Data is stored only in the user's browser
  • No cross-device sync
  • Data is lost if browser storage is cleared

For Production: Consider implementing a backend database (Firebase, Supabase, PostgreSQL) and user authentication. See DEPLOYMENT.md for details.

Production Checklist

Before deploying to production:

  • Set up Google Cloud Project and enable Calendar API
  • Configure OAuth 2.0 credentials
  • Add environment variables to deployment platform
  • Update authorized domains in Google Cloud Console
  • Test Calendar integration
  • Verify all features work in production build
  • Consider adding backend database
  • Set up error monitoring (Sentry, LogRocket)
  • Configure analytics

Key Features Breakdown

Task Priority System

Tasks use a p0-p4 priority system:

  • p0: Highest priority (critical/urgent)
  • p1: High priority
  • p2: Medium priority
  • p3: Lower priority
  • p4: Lowest priority

The priority calculator automatically assigns priorities based on:

  • Due date urgency
  • Estimated effort
  • Impact assessment
  • Task dependencies

Pomodoro System

  • 25-minute work sessions
  • 5-minute breaks
  • Automatic notifications
  • Session history tracking
  • Task linking

Calendar Sync

  • OAuth 2.0 authentication
  • Two-way sync with Google Calendar
  • Export tasks as calendar events
  • Import calendar events
  • Manual and automatic sync

Browser Compatibility

  • Chrome/Edge: Full support
  • Firefox: Full support
  • Safari: Full support
  • Mobile browsers: Responsive design

Known Limitations

  1. No Backend: All data stored in localStorage
  2. Single User: No multi-user support
  3. No Offline Sync: Requires internet for Calendar API
  4. No Database: No data backup/recovery mechanism

See DEPLOYMENT.md for recommended improvements.

Contributing

Contributions are welcome! Please:

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Run npm run lint and npm run build
  5. Submit a pull request

Troubleshooting

Calendar not connecting

  • Verify Google API credentials are correct
  • Check authorized domains in Google Cloud Console
  • Ensure Calendar API is enabled
  • Check browser console for errors

Build errors

  • Verify Node.js version (20+)
  • Clear .next folder and rebuild
  • Check TypeScript errors with npm run lint

Data loss

  • Data is stored in localStorage
  • Clearing browser data will delete all tasks
  • Consider exporting data to Calendar before clearing

Learn More

Next.js Resources

Google Calendar API

License

This project is open source and available under the MIT License.

Support

For deployment help, see DEPLOYMENT.md.

For feature requests or bugs, please open an issue.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages