terra vidhal

Study Planner

Component

About

A weekly study planner with a day-by-slot grid, animated colour-coded subject blocks, arrow-key grid navigation, one-tap empty-cell creation, block editing with done state, completed and remaining hour lanes, per-day coverage, subject progress, exam reminders, delete with undo and reset.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Study Planner to your project and fits it to your theme.

Code

How Study Planner is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

"use client";

/**
 * PrequelUI Animate — MIT — https://prequeluianimate.terravidhal.me
 */

import {
  StudyPlanner,
  type StudyBlock,
  type StudyDay,
  type StudySlot,
  type StudySubject,
} from "@/components/ui/study-planner";

const SUBJECTS: StudySubject[] = [
  { id: "s1", name: "Statistics", color: "#0ea5e9", examIn: "in 6 days" },
  { id: "s2", name: "Biology", color: "#10b981", examIn: "in 9 days" },
  { id: "s3", name: "Literature", color: "#8b5cf6", examIn: "in 12 days" },
  { id: "s4", name: "Spanish", color: "#f59e0b", examIn: "in 15 days" },
];

const DAYS: StudyDay[] = [
  { id: "mon", label: "Mon", date: "09" },
  { id: "tue", label: "Tue", date: "10" },
  { id: "wed", label: "Wed", date: "11" },
  { id: "thu", label: "Thu", date: "12" },
  { id: "fri", label: "Fri", date: "13" },
];

const SLOTS: StudySlot[] = [
  { id: "m1", label: "09:00" },
  { id: "m2", label: "11:00" },
  { id: "m3", label: "14:00" },
  { id: "m4", label: "16:00" },
  { id: "m5", label: "18:00" },
];

const BLOCKS: StudyBlock[] = [
  { id: "b1", dayId: "mon", slotId: "m1", subjectId: "s1", topic: "Confidence intervals", done: true },
  { id: "b2", dayId: "mon", slotId: "m3", subjectId: "s3", topic: "Poetry close reading", done: false },
  { id: "b3", dayId: "tue", slotId: "m2", subjectId: "s2", topic: "Cell respiration", done: false },
  { id: "b4", dayId: "tue", slotId: "m4", subjectId: "s4", topic: "Past tense drills", done: true },
  { id: "b5", dayId: "wed", slotId: "m1", subjectId: "s1", topic: "Hypothesis testing", done: false },
  { id: "b6", dayId: "wed", slotId: "m5", subjectId: "s2", topic: "Genetics review", done: false },
  { id: "b7", dayId: "thu", slotId: "m3", subjectId: "s3", topic: "Essay outline", done: true },
  { id: "b8", dayId: "thu", slotId: "m4", subjectId: "s1", topic: "Practice set B", done: false },
  { id: "b9", dayId: "fri", slotId: "m2", subjectId: "s4", topic: "Listening practice", done: false },
  { id: "b10", dayId: "fri", slotId: "m5", subjectId: "s2", topic: "Lab diagrams", done: false },
];

export default function StudyPlannerDemo() {
  return (
    <main className="flex min-h-screen w-full items-start justify-center bg-gradient-to-b from-muted/40 via-background to-background px-4 py-8 sm:px-6">
      <StudyPlanner
        weekLabel="Week of 09 March"
        subjects={SUBJECTS}
        days={DAYS}
        slots={SLOTS}
        initialBlocks={BLOCKS}
        title="Exam week study plan"
      />
    </main>
  );
}

Dependencies

More by terra vidhal

View all
  • Project Timeline

    Project Timeline

    30
  • Kanban Board

    Kanban Board

    20
  • Gravity Stars Background

    Gravity Stars Background

    20
  • Booking Calendar

    Booking Calendar

    18
  • Notification Center

    Notification Center

    16
  • Audio Waveform

    Audio Waveform

    16
  • Kpi Counter

    Kpi Counter

    16
  • Topographic Lines

    Topographic Lines

    16

Explore more

Part of PrequelUI Animate — browse the full library on 21st.dev.