# aless725/utp-services architecture

> Architecture diagram of the GitHub repository aless725/utp-services, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-18). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/aless725/utp-services
- Repository: https://github.com/aless725/utp-services

## Overview

UTP+ Service is a demo mobile-first student-services app: students enter through onboarding or sign-in, then use routed screens for academic information, payments, study groups, and space reservations. The app also provides profile and accessibility controls and adapts its layout to mobile, tablet, and dual-screen devices. Authentication and service data are simulated locally; the README describes Supabase and voice assistance as future work. Some domain screens were not sampled, so their internal calls are not inferred; the README and route excerpt support the broad capability branches.

Main entry points: [`src/App.tsx`](https://github.com/aless725/utp-services/blob/main/src/App.tsx) (Route dispatcher), [`src/features/auth/LoginPage.tsx`](https://github.com/aless725/utp-services/blob/main/src/features/auth/LoginPage.tsx) (Sign-in and recovery), [`src/features/auth/AuthContext.tsx`](https://github.com/aless725/utp-services/blob/main/src/features/auth/AuthContext.tsx) (Auth context), [`src/features/courses/detail/CourseDetailPage.tsx`](https://github.com/aless725/utp-services/blob/main/src/features/courses/detail/CourseDetailPage.tsx) (Course detail)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Access and navigation"]
  node_app_routes["Route dispatcher<br/>[App.tsx]"]
  node_onboarding["Onboarding<br/>[OnboardingPage.tsx]"]
  node_auth_ui["Sign-in and recovery<br/>[LoginPage.tsx]"]
  node_auth_state["Auth context<br/>[AuthContext.tsx]"]
  node_auth_service["Demo authentication<br/>[authService.ts]"]
end

subgraph group_academics["Academic services"]
  node_home["Home agenda<br/>[HomePage.tsx]"]
  node_calendar["Calendar<br/>[CalendarPage.tsx]"]
  node_courses["Course catalogue<br/>[CoursesPage.tsx]"]
  node_course_detail["Course detail"]
  node_course_content["Course content<br/>[courseContent.ts]"]
end

subgraph group_student_services["Student services"]
  node_payments["Payments<br/>[PaymentsPage.tsx]"]
  node_groups["Study groups<br/>[GroupsPage.tsx]"]
  node_group_creation["Create group"]
  node_reservations["Space reservations"]
  node_reservation_rules["Reservation rules<br/>[rules.ts]"]
  node_profile["Student profile<br/>[ProfilePage.tsx]"]
end

subgraph group_platform["App foundation"]
  node_accessibility["Accessibility settings"]
  node_responsive_layout["Responsive layout<br/>[DeviceContext.tsx]"]
  node_local_storage[("Browser persistence")]
  node_app_shell["App shell<br/>[AppLayout.tsx]"]
end

node_student(("Student"))

node_student -->|"opens"| node_app_routes
node_app_routes -->|"routes to"| node_onboarding
node_app_routes -->|"routes to"| node_auth_ui
node_auth_ui -->|"uses"| node_auth_state
node_auth_state -->|"delegates to"| node_auth_service
node_app_routes -->|"routes to"| node_home
node_app_routes -->|"routes to"| node_calendar
node_app_routes -->|"routes to"| node_courses
node_app_routes -->|"routes to"| node_course_detail
node_course_detail -->|"uses content"| node_course_content
node_app_routes -->|"routes to"| node_payments
node_app_routes -->|"routes to"| node_groups
node_app_routes -->|"routes to"| node_group_creation
node_app_routes -->|"routes to"| node_reservations
node_reservations -.->|"applies rules"| node_reservation_rules
node_app_routes -.->|"routes to"| node_profile
node_app_routes -->|"routes to"| node_accessibility
node_app_routes -->|"provides layout"| node_responsive_layout
node_app_routes -->|"renders within"| node_app_shell
node_groups -.->|"persists state"| node_local_storage
node_payments -->|"persists state"| node_local_storage

click node_app_routes "https://github.com/aless725/utp-services/blob/main/src/App.tsx"
click node_onboarding "https://github.com/aless725/utp-services/blob/main/src/features/onboarding/OnboardingPage.tsx"
click node_auth_ui "https://github.com/aless725/utp-services/blob/main/src/features/auth/LoginPage.tsx"
click node_auth_state "https://github.com/aless725/utp-services/blob/main/src/features/auth/AuthContext.tsx"
click node_auth_service "https://github.com/aless725/utp-services/blob/main/src/features/auth/authService.ts"
click node_home "https://github.com/aless725/utp-services/blob/main/src/features/home/HomePage.tsx"
click node_calendar "https://github.com/aless725/utp-services/blob/main/src/features/calendar/CalendarPage.tsx"
click node_courses "https://github.com/aless725/utp-services/blob/main/src/features/courses/CoursesPage.tsx"
click node_course_detail "https://github.com/aless725/utp-services/blob/main/src/features/courses/detail/CourseDetailPage.tsx"
click node_course_content "https://github.com/aless725/utp-services/blob/main/src/features/courses/detail/courseContent.ts"
click node_payments "https://github.com/aless725/utp-services/blob/main/src/features/payments/PaymentsPage.tsx"
click node_groups "https://github.com/aless725/utp-services/blob/main/src/features/groups/GroupsPage.tsx"
click node_group_creation "https://github.com/aless725/utp-services/blob/main/src/features/groups/CreateGroupPage.tsx"
click node_reservations "https://github.com/aless725/utp-services/blob/main/src/features/reservations/ReservationsHome.tsx"
click node_reservation_rules "https://github.com/aless725/utp-services/blob/main/src/features/reservations/rules.ts"
click node_profile "https://github.com/aless725/utp-services/blob/main/src/features/profile/ProfilePage.tsx"
click node_accessibility "https://github.com/aless725/utp-services/blob/main/src/features/accessibility/AccessibilityContext.tsx"
click node_responsive_layout "https://github.com/aless725/utp-services/blob/main/src/components/layout/DeviceContext.tsx"
click node_local_storage "https://github.com/aless725/utp-services/blob/main/src/hooks/useLocalStorageState.ts"
click node_app_shell "https://github.com/aless725/utp-services/blob/main/src/components/layout/AppLayout.tsx"

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_routes,node_onboarding,node_auth_ui,node_auth_state,node_auth_service toneBlue
class node_home,node_calendar,node_courses,node_course_detail,node_course_content toneAmber
class node_payments,node_groups,node_group_creation,node_reservations,node_reservation_rules,node_profile toneMint
class node_accessibility,node_responsive_layout,node_local_storage,node_app_shell toneRose
class node_student toneIndigo
```

## Components

### Access and navigation

- [Route dispatcher](https://github.com/aless725/utp-services/blob/main/src/App.tsx): `src/App.tsx`
- [Onboarding](https://github.com/aless725/utp-services/blob/main/src/features/onboarding/OnboardingPage.tsx): `src/features/onboarding/OnboardingPage.tsx`
- [Sign-in and recovery](https://github.com/aless725/utp-services/blob/main/src/features/auth/LoginPage.tsx): `src/features/auth/LoginPage.tsx`
- [Auth context](https://github.com/aless725/utp-services/blob/main/src/features/auth/AuthContext.tsx): `src/features/auth/AuthContext.tsx`
- [Demo authentication](https://github.com/aless725/utp-services/blob/main/src/features/auth/authService.ts): `src/features/auth/authService.ts`

### Academic services

- [Home agenda](https://github.com/aless725/utp-services/blob/main/src/features/home/HomePage.tsx): `src/features/home/HomePage.tsx`
- [Calendar](https://github.com/aless725/utp-services/blob/main/src/features/calendar/CalendarPage.tsx): `src/features/calendar/CalendarPage.tsx`
- [Course catalogue](https://github.com/aless725/utp-services/blob/main/src/features/courses/CoursesPage.tsx): `src/features/courses/CoursesPage.tsx`
- [Course detail](https://github.com/aless725/utp-services/blob/main/src/features/courses/detail/CourseDetailPage.tsx): `src/features/courses/detail/CourseDetailPage.tsx`
- [Course content](https://github.com/aless725/utp-services/blob/main/src/features/courses/detail/courseContent.ts): `src/features/courses/detail/courseContent.ts`

### Student services

- [Payments](https://github.com/aless725/utp-services/blob/main/src/features/payments/PaymentsPage.tsx): `src/features/payments/PaymentsPage.tsx`
- [Study groups](https://github.com/aless725/utp-services/blob/main/src/features/groups/GroupsPage.tsx): `src/features/groups/GroupsPage.tsx`
- [Create group](https://github.com/aless725/utp-services/blob/main/src/features/groups/CreateGroupPage.tsx): `src/features/groups/CreateGroupPage.tsx`
- [Space reservations](https://github.com/aless725/utp-services/blob/main/src/features/reservations/ReservationsHome.tsx): `src/features/reservations/ReservationsHome.tsx`
- [Reservation rules](https://github.com/aless725/utp-services/blob/main/src/features/reservations/rules.ts): `src/features/reservations/rules.ts`
- [Student profile](https://github.com/aless725/utp-services/blob/main/src/features/profile/ProfilePage.tsx): `src/features/profile/ProfilePage.tsx`

### App foundation

- [Accessibility settings](https://github.com/aless725/utp-services/blob/main/src/features/accessibility/AccessibilityContext.tsx): `src/features/accessibility/AccessibilityContext.tsx`
- [Responsive layout](https://github.com/aless725/utp-services/blob/main/src/components/layout/DeviceContext.tsx): `src/components/layout/DeviceContext.tsx`
- [Browser persistence](https://github.com/aless725/utp-services/blob/main/src/hooks/useLocalStorageState.ts): `src/hooks/useLocalStorageState.ts`
- [App shell](https://github.com/aless725/utp-services/blob/main/src/components/layout/AppLayout.tsx): `src/components/layout/AppLayout.tsx`

### Other components

- **Student**

## Connections

- Student → Route dispatcher: opens (evidence: `README.md`)
- Route dispatcher → Onboarding: routes to (evidence: `src/App.tsx`)
- Route dispatcher → Sign-in and recovery: routes to (evidence: `src/App.tsx`)
- Sign-in and recovery → Auth context: uses (evidence: `src/features/auth/AuthContext.tsx`)
- Auth context → Demo authentication: delegates to (evidence: `src/features/auth/AuthContext.tsx`)
- Route dispatcher → Home agenda: routes to (evidence: `src/App.tsx`)
- Route dispatcher → Calendar: routes to (evidence: `src/App.tsx`)
- Route dispatcher → Course catalogue: routes to (evidence: `src/App.tsx`)
- Route dispatcher → Course detail: routes to (evidence: `src/App.tsx`)
- Course detail → Course content: uses content
- Route dispatcher → Payments: routes to (evidence: `src/App.tsx`)
- Route dispatcher → Study groups: routes to (evidence: `src/App.tsx`)
- Route dispatcher → Create group: routes to (evidence: `src/App.tsx`)
- Route dispatcher → Space reservations: routes to (evidence: `src/App.tsx`)
- Space reservations → Reservation rules: applies rules (evidence: `README.md`)
- Route dispatcher → Student profile: routes to (evidence: `README.md`)
- Route dispatcher → Accessibility settings: routes to (evidence: `src/App.tsx`)
- Route dispatcher → Responsive layout: provides layout (evidence: `src/App.tsx`)
- Route dispatcher → App shell: renders within (evidence: `src/App.tsx`)
- Study groups → Browser persistence: persists state
- Payments → Browser persistence: persists state (evidence: `src/features/payments/PaymentsPage.tsx`)
