Skip to content

harshjdhv/lms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

112 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Next.js React TypeScript Supabase Prisma Turborepo

ConnectX LMS

Knowledge, Beautifully Organized. β€” The AI-powered learning management system that feels less like a tool and more like a superpower.

ConnectX is a full-stack, production-ready LMS built with modern web technologies. It provides an intelligent, adaptive learning experience for students and a powerful course management platform for educators β€” all wrapped in a premium, Apple-inspired UI.


✨ Features

πŸŽ“ For Students

  • Course Enrollment & Progress Tracking β€” Browse available courses, enroll, and track completion across chapters
  • AI-Powered Smart Reflections β€” Adaptive quizzes generated from video transcripts that learn your strengths and weaknesses over time
  • Personalized Learning Memory β€” The system remembers your learning pace, preferred style, confidence level, and topic mastery
  • Assignment Submissions β€” Submit assignments with file attachments and receive teacher feedback
  • Real-time Chat β€” Direct messaging with teachers and peers with online presence tracking
  • Mentorship Program β€” Get paired with mentors for document reviews and academic guidance

πŸ‘©β€πŸ« For Teachers

  • Course Builder β€” Create courses with chapters, video content, attachments, and transcript-based quizzes
  • Drag & Drop Chapter Ordering β€” Reorder course content intuitively with DnD Kit
  • Assignment & Grading Management β€” Create assignments with deadlines, review submissions, and provide feedback
  • Announcements β€” Broadcast updates to enrolled students per course
  • Mentorship Dashboard β€” Manage mentees, set document requirements, and review submissions
  • Student Analytics β€” View enrollment data, submission rates, and course engagement

πŸ€– AI & Intelligence

  • Smart Reflection Engine β€” Generates context-aware quiz questions from video transcripts using AI
  • Adaptive Difficulty β€” Questions adjust based on your StudentReflectionMemory profile
  • Remediation Paths β€” AI suggests targeted review material when you struggle with a topic
  • Topic-Level Mastery Tracking β€” Per-topic accuracy, streak tracking, and confidence scoring

πŸ” Platform

  • Role-Based Access Control (RBAC) β€” Distinct experiences for STUDENT, TEACHER, and ADMIN roles
  • Supabase Authentication β€” Email/password auth with SSR cookie-based sessions
  • Onboarding Flow β€” New users are guided through profile setup and learning preference configuration
  • Global Command Menu β€” ⌘K quick-access navigation across the entire app
  • Dark/Light Mode β€” Full theme support via next-themes
  • Vercel Analytics β€” Built-in production analytics

πŸ—οΈ Architecture

This project is a Turborepo monorepo with the following structure:

connectx-lms/
β”œβ”€β”€ apps/
β”‚   └── web/                    # Next.js 16 application (App Router)
β”‚       β”œβ”€β”€ app/
β”‚       β”‚   β”œβ”€β”€ api/            # 30+ API routes
β”‚       β”‚   β”œβ”€β”€ auth/           # Authentication pages
β”‚       β”‚   β”œβ”€β”€ dashboard/      # Protected dashboard (role-based)
β”‚       β”‚   β”‚   β”œβ”€β”€ account/
β”‚       β”‚   β”‚   β”œβ”€β”€ assignments/
β”‚       β”‚   β”‚   β”œβ”€β”€ community/
β”‚       β”‚   β”‚   β”œβ”€β”€ courses/
β”‚       β”‚   β”‚   β”œβ”€β”€ grades/
β”‚       β”‚   β”‚   β”œβ”€β”€ mentorship/
β”‚       β”‚   β”‚   └── schedule/
β”‚       β”‚   β”œβ”€β”€ forgot-password/
β”‚       β”‚   β”œβ”€β”€ landing/
β”‚       β”‚   └── onboarding/
β”‚       β”œβ”€β”€ components/         # React components
β”‚       β”œβ”€β”€ hooks/              # Custom hooks & React Query keys
β”‚       β”œβ”€β”€ lib/                # Utilities (Supabase client, auth helpers)
β”‚       └── providers/          # Context providers (User store, React Query)
β”‚
β”œβ”€β”€ packages/
β”‚   β”œβ”€β”€ database/               # Prisma schema + client
β”‚   β”‚   └── prisma/
β”‚   β”‚       └── schema.prisma   # 18 models, PostgreSQL
β”‚   β”œβ”€β”€ ui/                     # Shared component library (55+ components)
β”‚   β”‚   └── src/components/     # shadcn/ui + custom components
β”‚   β”œβ”€β”€ eslint-config/          # Shared ESLint configuration
β”‚   └── typescript-config/      # Shared TypeScript configuration
β”‚
β”œβ”€β”€ turbo.json                  # Turborepo pipeline configuration
└── package.json                # Root workspace configuration

πŸ› οΈ Tech Stack

Layer Technology
Framework Next.js 16 (App Router, Turbopack)
Language TypeScript 5.7
UI Library React 19
Styling Tailwind CSS 4
Component Library shadcn/ui (55+ components)
Animations Framer Motion 12
State Management Zustand 5 + React Query 5
Forms React Hook Form 7 + Zod 4
Database PostgreSQL (via Supabase)
ORM Prisma 6
Authentication Supabase Auth (SSR)
Drag & Drop dnd-kit
Icons Lucide React
Monorepo Turborepo 2
Package Manager Bun 1.2
Analytics Vercel Analytics
Deployment Vercel

πŸš€ Getting Started

Prerequisites

1. Clone the Repository

git clone https://github.com/your-username/connectx-lms.git
cd connectx-lms

2. Install Dependencies

bun install

3. Configure Environment Variables

Create a .env file inside packages/database/:

DATABASE_URL="postgresql://..."
DIRECT_URL="postgresql://..."

Create a .env.local file inside apps/web/:

NEXT_PUBLIC_SUPABASE_URL="https://your-project.supabase.co"
NEXT_PUBLIC_SUPABASE_ANON_KEY="your-anon-key"

4. Generate Prisma Client & Push Schema

# Generate the Prisma client
bun run --filter @workspace/database db:generate

# Push schema to your database (first time only)
bun run --filter @workspace/database db:push

5. Start the Development Server

bun run dev

The app will be running at http://localhost:3000.


πŸ“‘ API Routes

The application exposes 30+ API routes under apps/web/app/api/:

Category Endpoint Description
Courses GET /api/courses List all courses
GET /api/courses/available Browse enrollable courses
GET /api/courses/my Get user's enrolled/taught courses
POST /api/courses/enroll Enroll in a course
PATCH /api/courses/[courseId] Update course details
Assignments GET /api/assignments List assignments
POST /api/assignments/submit Submit an assignment
PATCH /api/assignments/update Update assignment status
Announcements GET /api/announcements List announcements
Chat GET/POST /api/chat Direct messaging
Reflection (AI) POST /api/reflection/generate Generate quiz from transcript
POST /api/reflection/evaluate Evaluate student answers
POST /api/reflection/remediate Get remediation suggestions
POST /api/reflection/chat AI-powered reflection chat
POST /api/smart-reflection Smart adaptive quiz
Mentorship GET/POST /api/mentorship Manage mentorships
GET /api/mentorship/available-students Find unassigned students
Documents GET/POST /api/documents/requirements Document requirements
GET/POST /api/documents/submissions Document submissions
User GET/PATCH /api/user/profile User profile
POST /api/user/complete-onboarding Complete onboarding
GET /api/user/learning-memory Get learning memory

πŸ—„οΈ Database Schema

The PostgreSQL database consists of 18 models managed by Prisma:

User ─────────────┬───── Course ────── Chapter ────── UserProgress
  β”‚                β”‚        β”‚               β”‚
  β”‚                β”‚        β”‚               └── ReflectionPoint
  β”‚                β”‚        β”‚
  β”‚                β”‚        β”œβ”€β”€ Attachment
  β”‚                β”‚        β”œβ”€β”€ Announcement
  β”‚                β”‚        β”œβ”€β”€ Assignment ──── AssignmentSubmission
  β”‚                β”‚        └── Enrollment
  β”‚                β”‚
  β”œβ”€β”€ Chat ────────┴── Message
  β”œβ”€β”€ UserPresence
  β”œβ”€β”€ StudentReflectionMemory
  β”œβ”€β”€ Mentorship
  β”œβ”€β”€ DocumentRequirement ──── DocumentSubmission
  └── (Roles: STUDENT | TEACHER | ADMIN)

Key Enums

  • UserRole: STUDENT Β· TEACHER Β· ADMIN
  • AssignmentStatus: ACTIVE Β· REVIEW Β· STOPPED
  • SubmissionStatus: PENDING Β· APPROVED Β· REJECTED
  • MentorshipStatus: ACTIVE Β· INACTIVE Β· COMPLETED
  • DocumentStatus: PENDING Β· APPROVED Β· REJECTED Β· REVISION_REQUESTED

πŸ“¦ Workspace Packages

@workspace/ui

Shared component library with 55+ components built on shadcn/ui:

accordion Β· alert-dialog Β· avatar Β· badge Β· breadcrumb Β· button
calendar Β· card Β· carousel Β· chart Β· checkbox Β· collapsible
command Β· context-menu Β· dialog Β· drawer Β· dropdown-menu Β· empty
field Β· form Β· hover-card Β· input Β· input-group Β· input-otp
item Β· kbd Β· label Β· menubar Β· navigation-menu Β· pagination
popover Β· progress Β· radio-group Β· resizable Β· scroll-area
select Β· separator Β· sheet Β· sidebar Β· skeleton Β· slider
sonner Β· spinner Β· switch Β· table Β· tabs Β· textarea
toggle Β· toggle-group Β· tooltip  ... and more

Usage:

import { Button } from "@workspace/ui/components/button"
import { Card } from "@workspace/ui/components/card"

@workspace/database

Prisma client and schema package:

import { prisma } from "@workspace/database"

const users = await prisma.user.findMany()

πŸ§ͺ Scripts

Command Description
bun run dev Start all apps in development mode (Turbopack)
bun run build Build all apps and packages
bun run lint Lint all apps and packages
bun run format Format all files with Prettier
bun run --filter web dev Start only the web app
bun run --filter @workspace/database db:generate Generate Prisma client
bun run --filter @workspace/database db:push Push schema to database
bun run --filter @workspace/database db:studio Open Prisma Studio

🌐 Deployment

The app is designed for deployment on Vercel:

  1. Connect your GitHub repository to Vercel
  2. Set the root directory to apps/web
  3. Add environment variables (DATABASE_URL, DIRECT_URL, Supabase keys)
  4. Vercel will automatically detect the Turborepo setup

Production URL: https://lms.harshjdhv.com


🀝 Adding UI Components

To add new shadcn/ui components:

bunx shadcn@latest add <component-name> -c apps/web

Components are automatically placed in packages/ui/src/components/.


πŸ“ License

This project is private and proprietary.


Built with ❀️ by the ConnectX team · UI components from componentry.fun

About

the best lms out there

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages