# pakagronglb/full-stack-school-management architecture

> Architecture diagram of the GitHub repository pakagronglb/full-stack-school-management, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/pakagronglb/full-stack-school-management
- Repository: https://github.com/pakagronglb/full-stack-school-management

## Overview

EduSphere is a role-based school management system. Users sign in through Clerk, then access dashboards and school-operation pages for people, classes, schedules, assessments, results, attendance, events, and announcements. List pages query paginated, searchable records; authorized users can access forms for changes. The sampled pages show Prisma reads, and the student form excerpt shows submission through server actions. README capabilities and the tree identify other product areas, but their internal wiring is not established by the excerpts.

Main entry points: [`src/app/(dashboard)/admin/page.tsx`](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/admin/page.tsx) (Role dashboards), [`src/lib/prisma.ts`](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/lib/prisma.ts) (Prisma client), [`src/app/[[...sign-in]]/page.tsx`](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/%5B%5B...sign-in%5D%5D/page.tsx) (Sign in), [`src/middleware.ts`](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/middleware.ts) (Role access)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_identity["Identity and access"]
  node_signin["Sign in<br/>[page.tsx]"]
  node_clerk["Clerk auth"]
  node_access["Role access<br/>[middleware.ts]"]
end

subgraph group_experience["Role dashboards"]
  node_dashboard["Dashboard layout<br/>[layout.tsx]"]
  node_rolepages["Role dashboards<br/>[page.tsx]"]
end

subgraph group_school["School records"]
  node_people["People records<br/>[page.tsx]"]
  node_teacherlist["Teacher records<br/>[page.tsx]"]
  node_curriculum["Class and subject lists<br/>[page.tsx]"]
  node_peopleforms["People forms<br/>[StudentForm.tsx]"]
end

subgraph group_learning["Learning operations"]
  node_schedule["Lessons and calendar"]
  node_assessments["Exam and assignment lists<br/>[page.tsx]"]
  node_results["Results<br/>[page.tsx]"]
  node_attendance["Attendance views"]
  node_events["Events and notices"]
end

subgraph group_platform["Data services"]
  node_actions["Server actions<br/>[actions.ts]"]
  node_prisma["Prisma client<br/>[prisma.ts]"]
  node_postgres[("PostgreSQL")]
end

node_user(("School user"))

node_user -->|"signs in"| node_signin
node_signin -->|"authenticates"| node_clerk
node_clerk -->|"returns identity"| node_signin
node_clerk -->|"provides claims"| node_access
node_access -->|"permits role"| node_dashboard
node_dashboard -->|"renders role page"| node_rolepages
node_rolepages -->|"opens records"| node_people
node_rolepages -->|"opens records"| node_teacherlist
node_rolepages -->|"opens records"| node_curriculum
node_rolepages -->|"shows schedule"| node_schedule
node_rolepages -->|"opens assessments"| node_assessments
node_rolepages -->|"opens results"| node_results
node_rolepages -->|"shows attendance"| node_attendance
node_rolepages -->|"shows events"| node_events
node_peopleforms -->|"submits changes"| node_actions
node_people -->|"queries records"| node_prisma
node_teacherlist -->|"queries records"| node_prisma
node_results -->|"queries results"| node_prisma
node_prisma -->|"reads and writes"| node_postgres

click node_signin "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/%5B%5B...sign-in%5D%5D/page.tsx"
click node_access "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/middleware.ts"
click node_dashboard "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/layout.tsx"
click node_rolepages "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/admin/page.tsx"
click node_people "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/list/students/page.tsx"
click node_teacherlist "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/list/teachers/page.tsx"
click node_curriculum "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/list/classes/page.tsx"
click node_peopleforms "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/components/forms/StudentForm.tsx"
click node_schedule "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/components/BigCalendarContainer.tsx"
click node_assessments "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/list/exams/page.tsx"
click node_results "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/list/results/page.tsx"
click node_attendance "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/components/AttendanceChartContainer.tsx"
click node_events "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/components/EventCalendarContainer.tsx"
click node_actions "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/lib/actions.ts"
click node_prisma "https://github.com/pakagronglb/full-stack-school-management/blob/main/src/lib/prisma.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_signin,node_clerk,node_access,node_user toneBlue
class node_dashboard,node_rolepages toneAmber
class node_people,node_teacherlist,node_curriculum,node_peopleforms toneMint
class node_schedule,node_assessments,node_results,node_attendance,node_events toneRose
class node_actions,node_prisma,node_postgres toneIndigo
```

## Components

### Identity and access

- [Sign in](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/%5B%5B...sign-in%5D%5D/page.tsx): `src/app/[[...sign-in]]/page.tsx`
- **Clerk auth**
- [Role access](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/middleware.ts): `src/middleware.ts`

### Role dashboards

- [Dashboard layout](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/layout.tsx): `src/app/(dashboard)/layout.tsx`
- [Role dashboards](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/admin/page.tsx): `src/app/(dashboard)/admin/page.tsx`

### School records

- [People records](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/list/students/page.tsx): `src/app/(dashboard)/list/students/page.tsx`
- [Teacher records](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/list/teachers/page.tsx): `src/app/(dashboard)/list/teachers/page.tsx`
- [Class and subject lists](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/list/classes/page.tsx): `src/app/(dashboard)/list/classes/page.tsx`
- [People forms](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/components/forms/StudentForm.tsx): `src/components/forms/StudentForm.tsx`

### Learning operations

- [Lessons and calendar](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/components/BigCalendarContainer.tsx): `src/components/BigCalendarContainer.tsx`
- [Exam and assignment lists](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/list/exams/page.tsx): `src/app/(dashboard)/list/exams/page.tsx`
- [Results](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/app/(dashboard)/list/results/page.tsx): `src/app/(dashboard)/list/results/page.tsx`
- [Attendance views](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/components/AttendanceChartContainer.tsx): `src/components/AttendanceChartContainer.tsx`
- [Events and notices](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/components/EventCalendarContainer.tsx): `src/components/EventCalendarContainer.tsx`

### Data services

- [Server actions](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/lib/actions.ts): `src/lib/actions.ts`
- [Prisma client](https://github.com/pakagronglb/full-stack-school-management/blob/main/src/lib/prisma.ts): `src/lib/prisma.ts`
- **PostgreSQL**

### Other components

- **School user**

## Connections

- School user → Sign in: signs in
- Sign in → Clerk auth: authenticates
- Clerk auth → Sign in: returns identity
- Clerk auth → Role access: provides claims
- Role access → Dashboard layout: permits role
- Dashboard layout → Role dashboards: renders role page
- Role dashboards → People records: opens records
- Role dashboards → Teacher records: opens records
- Role dashboards → Class and subject lists: opens records
- Role dashboards → Lessons and calendar: shows schedule
- Role dashboards → Exam and assignment lists: opens assessments
- Role dashboards → Results: opens results
- Role dashboards → Attendance views: shows attendance
- Role dashboards → Events and notices: shows events
- People forms → Server actions: submits changes
- People records → Prisma client: queries records
- Teacher records → Prisma client: queries records
- Results → Prisma client: queries results
- Prisma client → PostgreSQL: reads and writes
