# sailesh-heybyte/8am_schooladmin architecture

> Architecture diagram of the GitHub repository sailesh-heybyte/8am_schooladmin, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-10). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sailesh-heybyte/8am_schooladmin
- Repository: https://github.com/sailesh-heybyte/8am_schooladmin

## Overview

This is a school-administration frontend for managing transport operations and related school records. The principal workflow is an authenticated user opening a routed management screen, reviewing or changing records, and (where shown in sampled code) loading data through an API module. The graph groups the routed product areas, shared UI, and API boundary. Several screens and API modules are represented from the file tree and SOURCE INDEX; their internal behavior and connections were not sampled, so those links are omitted.

Main entry points: [`src/App.jsx`](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/App.jsx) (Authenticated router), [`src/api/client.js`](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/api/client.js) (API client), [`src/screens/Students/index.jsx`](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Students/index.jsx) (Students), [`src/components/DataTable.jsx`](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/components/DataTable.jsx) (Data table)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application access"]
  node_app["Authenticated router<br/>[App.jsx]"]
  node_login["Login<br/>[index.jsx]"]
  node_schooladmin["Admin shell<br/>[index.jsx]"]
end

subgraph group_operations["Transport operations"]
  node_buses["Buses<br/>[index.jsx]"]
  node_drivers["Drivers<br/>[index.jsx]"]
  node_routes["Routes<br/>[index.jsx]"]
  node_stops["Stops<br/>[index.jsx]"]
  node_trips["Trips<br/>[index.jsx]"]
end

subgraph group_records["School records"]
  node_roles["Roles<br/>[index.jsx]"]
  node_branchusers["Branch users<br/>[index.jsx]"]
  node_students["Students<br/>[index.jsx]"]
  node_parents["Parents<br/>[index.jsx]"]
  node_announcements["Announcements<br/>[index.jsx]"]
  node_complaints["Complaints<br/>[index.jsx]"]
  node_importfile["Student import<br/>[importFile.js]"]
end

subgraph group_shared["Shared interface"]
  node_table["Data table<br/>[DataTable.jsx]"]
  node_typeahead["Type-ahead<br/>[TypeAhead.jsx]"]
  node_map["Map picker<br/>[MapPicker.jsx]"]
  node_branches["Branch context"]
end

subgraph group_api["API boundary"]
  node_api_client["API client<br/>[client.js]"]
  node_students_api["Student API<br/>[students.js]"]
  node_routes_api["Routes API<br/>[routes.js]"]
end

node_user(("School administrator"))
node_backend{{"Backend API"}}

node_user -->|"opens"| node_app
node_app -->|"routes to"| node_login
node_app -->|"routes to"| node_schooladmin
node_app -->|"routes to"| node_roles
node_app -->|"routes to"| node_branchusers
node_app -->|"routes to"| node_buses
node_app -->|"routes to"| node_drivers
node_app -->|"routes to"| node_routes
node_app -->|"routes to"| node_stops
node_app -->|"routes to"| node_trips
node_app -->|"routes to"| node_students
node_app -->|"routes to"| node_parents
node_app -->|"routes to"| node_announcements
node_app -->|"routes to"| node_complaints
node_buses -->|"renders"| node_table
node_buses -->|"renders"| node_typeahead
node_drivers -->|"renders"| node_table
node_drivers -->|"renders"| node_typeahead
node_parents -->|"renders"| node_table
node_parents -->|"renders"| node_typeahead
node_students -->|"renders"| node_table
node_students -->|"renders"| node_typeahead
node_trips -->|"renders"| node_table
node_trips -->|"renders"| node_typeahead
node_students -->|"loads records"| node_students_api
node_students -->|"unassigns stops"| node_students_api
node_students_api -->|"calls"| node_api_client
node_buses -->|"loads buses"| node_api_client
node_drivers -->|"loads drivers"| node_api_client
node_parents -->|"loads parents"| node_api_client
node_trips -->|"loads trips"| node_api_client
node_routes_api -->|"calls"| node_api_client
node_api_client -.->|"sends requests"| node_backend
node_branches -.->|"loads branches"| node_api_client
node_map -.->|"geocodes locations"| node_backend
node_students -.->|"imports student file"| node_importfile

click node_app "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/App.jsx"
click node_login "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Login/index.jsx"
click node_schooladmin "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/SchoolAdmin/index.jsx"
click node_roles "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Roles/index.jsx"
click node_branchusers "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/BranchUsers/index.jsx"
click node_buses "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Buses/index.jsx"
click node_drivers "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Drivers/index.jsx"
click node_routes "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Routes/index.jsx"
click node_stops "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Stops/index.jsx"
click node_trips "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Trips/index.jsx"
click node_students "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Students/index.jsx"
click node_parents "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Parents/index.jsx"
click node_announcements "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Announcements/index.jsx"
click node_complaints "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Complaints/index.jsx"
click node_api_client "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/api/client.js"
click node_students_api "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/api/students.js"
click node_routes_api "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/api/routes.js"
click node_table "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/components/DataTable.jsx"
click node_typeahead "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/components/TypeAhead.jsx"
click node_map "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/components/MapPicker.jsx"
click node_branches "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/context/BranchesContext.jsx"
click node_importfile "https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/utils/importFile.js"

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_app,node_login,node_schooladmin toneBlue
class node_buses,node_drivers,node_routes,node_stops,node_trips toneAmber
class node_roles,node_branchusers,node_students,node_parents,node_announcements,node_complaints,node_importfile,node_backend toneMint
class node_table,node_typeahead,node_map,node_branches toneRose
class node_api_client,node_students_api,node_routes_api,node_user toneIndigo
```

## Components

### Application access

- [Authenticated router](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/App.jsx): `src/App.jsx`
- [Login](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Login/index.jsx): `src/screens/Login/index.jsx`
- [Admin shell](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/SchoolAdmin/index.jsx): `src/screens/SchoolAdmin/index.jsx`

### Transport operations

- [Buses](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Buses/index.jsx): `src/screens/Buses/index.jsx`
- [Drivers](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Drivers/index.jsx): `src/screens/Drivers/index.jsx`
- [Routes](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Routes/index.jsx): `src/screens/Routes/index.jsx`
- [Stops](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Stops/index.jsx): `src/screens/Stops/index.jsx`
- [Trips](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Trips/index.jsx): `src/screens/Trips/index.jsx`

### School records

- [Roles](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Roles/index.jsx): `src/screens/Roles/index.jsx`
- [Branch users](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/BranchUsers/index.jsx): `src/screens/BranchUsers/index.jsx`
- [Students](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Students/index.jsx): `src/screens/Students/index.jsx`
- [Parents](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Parents/index.jsx): `src/screens/Parents/index.jsx`
- [Announcements](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Announcements/index.jsx): `src/screens/Announcements/index.jsx`
- [Complaints](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/screens/Complaints/index.jsx): `src/screens/Complaints/index.jsx`
- [Student import](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/utils/importFile.js): `src/utils/importFile.js`

### Shared interface

- [Data table](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/components/DataTable.jsx): `src/components/DataTable.jsx`
- [Type-ahead](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/components/TypeAhead.jsx): `src/components/TypeAhead.jsx`
- [Map picker](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/components/MapPicker.jsx): `src/components/MapPicker.jsx`
- [Branch context](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/context/BranchesContext.jsx): `src/context/BranchesContext.jsx`

### API boundary

- [API client](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/api/client.js): `src/api/client.js`
- [Student API](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/api/students.js): `src/api/students.js`
- [Routes API](https://github.com/sailesh-heybyte/8am_schooladmin/blob/main/src/api/routes.js): `src/api/routes.js`

### Other components

- **School administrator**
- **Backend API**

## Connections

- School administrator → Authenticated router: opens (evidence: `src/App.jsx`)
- Authenticated router → Login: routes to (evidence: `src/App.jsx`)
- Authenticated router → Admin shell: routes to (evidence: `src/App.jsx`)
- Authenticated router → Roles: routes to (evidence: `src/App.jsx`)
- Authenticated router → Branch users: routes to (evidence: `src/App.jsx`)
- Authenticated router → Buses: routes to (evidence: `src/App.jsx`)
- Authenticated router → Drivers: routes to (evidence: `src/App.jsx`)
- Authenticated router → Routes: routes to (evidence: `src/App.jsx`)
- Authenticated router → Stops: routes to (evidence: `src/App.jsx`)
- Authenticated router → Trips: routes to (evidence: `src/App.jsx`)
- Authenticated router → Students: routes to (evidence: `src/App.jsx`)
- Authenticated router → Parents: routes to (evidence: `src/App.jsx`)
- Authenticated router → Announcements: routes to (evidence: `src/App.jsx`)
- Authenticated router → Complaints: routes to (evidence: `src/App.jsx`)
- Buses → Data table: renders (evidence: `src/screens/Buses/index.jsx`)
- Buses → Type-ahead: renders (evidence: `src/screens/Buses/index.jsx`)
- Drivers → Data table: renders (evidence: `src/screens/Drivers/index.jsx`)
- Drivers → Type-ahead: renders (evidence: `src/screens/Drivers/index.jsx`)
- Parents → Data table: renders (evidence: `src/screens/Parents/index.jsx`)
- Parents → Type-ahead: renders (evidence: `src/screens/Parents/index.jsx`)
- Students → Data table: renders (evidence: `src/screens/Students/index.jsx`)
- Students → Type-ahead: renders (evidence: `src/screens/Students/index.jsx`)
- Trips → Data table: renders (evidence: `src/screens/Trips/index.jsx`)
- Trips → Type-ahead: renders (evidence: `src/screens/Trips/index.jsx`)
- Students → Student API: loads records (evidence: `src/screens/Students/index.jsx`)
- Students → Student API: unassigns stops (evidence: `src/screens/Students/index.jsx`)
- Student API → API client: calls (evidence: `src/api/students.js`)
- Buses → API client: loads buses (evidence: `src/screens/Buses/index.jsx`)
- Drivers → API client: loads drivers (evidence: `src/screens/Drivers/index.jsx`)
- Parents → API client: loads parents (evidence: `src/screens/Parents/index.jsx`)
- Trips → API client: loads trips (evidence: `src/screens/Trips/index.jsx`)
- Routes API → API client: calls (evidence: `src/api/routes.js`)
- API client → Backend API: sends requests
- Branch context → API client: loads branches
- Map picker → Backend API: geocodes locations
- Students → Student import: imports student file
