How mghashim/teacher-assistant works
Teacher Assistant is an offline-first browser app for teachers. The main workflow runs from the dashboard or routed feature pages through class, student, timetable, assessment, and task management, with records stored locally in IndexedDB. Backup and restore protect that local data; settings cover academic-year and theme preferences. The graph preserves documented product areas, but most feature-to-storage calls were not excerpted, so those links are marked unverified rather than inferred as confirmed calls.
Main entry points: AppRouter.tsx Page routing · database.ts IndexedDB · GradesPage.tsx Assessments & grades · ClassesPage.tsx Classes
Components 27
App shell
- Page routing
src/router/AppRouter.tsx - App layout
src/components/layout/AppLayout.tsx
Teaching workflow
- Dashboard
src/features/dashboard/DashboardPage.tsx - Classes
src/features/classes/ClassesPage.tsx - Class details
src/features/classes/ClassDetailPage.tsx - Timetable
src/features/timetable/TimetablePage.tsx - Lesson progress
src/features/classes/lessons/LessonsProgressTab.tsx - Assessments & grades
src/features/grades/GradesPage.tsx - Grade calculations
src/lib/calculations.ts - Tasks
src/features/tasks/TasksPage.tsx
Student records
- Student directory
src/features/students/StudentsPage.tsx - Student profiles
src/features/students/StudentProfilePage.tsx - Student editor
src/features/students/StudentModal.tsx - Grade export
src/lib/excelExport.ts
Local data
- Settings
src/features/settings/SettingsPage.tsx - Backup & restore
src/db/backup/backup.service.ts - Backup reminders
src/components/layout/AutoBackupManager.tsx - IndexedDB
src/db/database.ts - Domain records
src/types/database.ts
Shared UI
- Button primitive
src/components/ui/Button.tsx - Badge primitive
src/components/ui/Badge.tsx - Card primitive
src/components/ui/Card.tsx - Confirmation dialog
src/components/ui/ConfirmationModal.tsx - Empty state
src/components/ui/EmptyState.tsx - Input primitive
src/components/ui/Input.tsx - Modal primitive
src/components/ui/Modal.tsx
Other components
- Teacher
Connections 32
- Teacher → Page routing: opens app
- Page routing → App layout: routes through
src/router/AppRouter.tsx - Page routing → Dashboard: routes to
src/router/AppRouter.tsx - Page routing → Classes: routes to
src/router/AppRouter.tsx - Page routing → Class details: routes to
src/router/AppRouter.tsx - Page routing → Student directory: routes to
src/router/AppRouter.tsx - Page routing → Student profiles: routes to
src/router/AppRouter.tsx - Page routing → Assessments & grades: routes to
src/router/AppRouter.tsx - Page routing → Tasks: routes to
src/router/AppRouter.tsx - Page routing → Timetable: routes to
src/router/AppRouter.tsx - Dashboard → Classes: opens quick actions
src/features/dashboard/DashboardPage.tsx - Classes → Class details: opens class
- Class details → Lesson progress: shows progress
src/features/classes/ClassDetailPage.tsx - Student directory → Student profiles: opens profile
- Student profiles → Student editor: edits student
- Assessments & grades → Grade calculations: calculates averages
- Assessments & grades → Grade export: exports marks
- App layout → Backup reminders: mounts manager
src/components/layout/AppLayout.tsx - Backup reminders → Backup & restore: triggers backup
src/components/layout/AutoBackupManager.tsx - Backup reminders → Settings: checks backup state
src/components/layout/AutoBackupManager.tsx - Settings → Backup & restore: exports or restores
src/features/settings/SettingsPage.tsx - Backup & restore → IndexedDB: reads and writes
src/db/backup/backup.service.ts - IndexedDB → Domain records: types tables
src/db/database.ts - Classes → IndexedDB: persists class data
- Class details → IndexedDB: reads class data
src/features/classes/ClassDetailPage.tsx - Timetable → IndexedDB: reads schedules
src/features/timetable/TimetablePage.tsx - Assessments & grades → IndexedDB: persists grade data
- Student directory → IndexedDB: persists pupil data
- Tasks → IndexedDB: persists tasks
src/features/tasks/TasksPage.tsx - Confirmation dialog → Modal primitive: renders in
src/components/ui/ConfirmationModal.tsx - Confirmation dialog → Input primitive: uses password input
src/components/ui/ConfirmationModal.tsx - Confirmation dialog → Button primitive: uses actions
src/components/ui/ConfirmationModal.tsx