How testsamp0606/campushub works
This is a Next.js school-management application backed by Firebase, with routes for student and staff records, academics, finance, operations, and communication. The principal user workflow is to open a school-management screen, view or change domain records, and use Firebase-backed data; the sampled calendar route demonstrates reads of classes, subjects, teachers, and timetables. Dashboard attendance-anomaly detection is a distinct AI capability. The README only identifies a Firebase Studio starter, so several capabilities and their connections are inferred from the route tree; those links are marked unverified where source evidence was not supplied.
Main entry points: app App routes · index.ts Firebase client setup · client-provider.tsx Authentication and profile gate · page.tsx Calendar and timetable
Components 26
App experience
- App routes
src/app - Navigation shell
src/components/layout - UI components
src/components/ui
Academic operations
- Attendance
src/app/attendance/page.tsx - Calendar and timetable
src/app/calendar/page.tsx - Assessments and exams
src/app/examinations - Results and reports
src/app/results - Learning management
src/app/lms
School administration
- Student records
src/app/students - People and classes
src/app/teachers - School operations
src/app/transport - Fees and payments
src/app/fees - Accounts and expenses
src/app/expenses/page.tsx - Messages and announcements
src/app/messages
Firebase platform
- Firebase client setup
src/firebase/index.ts - Authentication and profile gate
src/firebase/client-provider.tsx - Firebase context
src/firebase/provider.tsx - Firestore data hooks
src/firebase/firestore/use-collection.tsx - Nonblocking updates
src/firebase/non-blocking-updates.tsx - Firebase error handling
src/firebase/error-emitter.ts - Firestore
Insights and learning
- Dashboard
src/app/dashboard/main-dashboard.tsx - Anomaly detector
src/components/dashboard/anomaly-detector.tsx - Attendance anomaly analysis
src/ai/flows/detect-attendance-anomalies.ts - Genkit runtime
src/ai/genkit.ts
Other components
- School user
Connections 30
- School user → App routes: opens screens
- App routes → Navigation shell: uses shell
- App routes → UI components: renders controls
src/app/calendar/page.tsx - App routes → Student records: routes to
- App routes → People and classes: routes to
- App routes → School operations: routes to
- App routes → Attendance: routes to
- App routes → Calendar and timetable: routes to
- App routes → Assessments and exams: routes to
src/app/examinations/page.tsx - App routes → Results and reports: routes to
src/app/results/page.tsx - App routes → Learning management: routes to
- App routes → Fees and payments: routes to
- App routes → Accounts and expenses: routes to
- App routes → Messages and announcements: routes to
- App routes → Dashboard: routes to
- Authentication and profile gate → Firebase client setup: initializes services
src/firebase/client-provider.tsx - Authentication and profile gate → Firebase context: provides context
src/firebase/client-provider.tsx - Authentication and profile gate → Nonblocking updates: creates profile
src/firebase/client-provider.tsx - Authentication and profile gate → Firestore: reads and watches profile
src/firebase/client-provider.tsx - Calendar and timetable → Firebase client setup: loads data hooks
src/app/calendar/page.tsx - Firestore data hooks → Firebase error handling: emits errors
src/firebase/firestore/use-collection.tsx - Nonblocking updates → Firebase error handling: reports errors
src/firebase/non-blocking-updates.tsx - Anomaly detector → Attendance anomaly analysis: requests analysis
src/components/dashboard/anomaly-detector.tsx - Attendance anomaly analysis → Genkit runtime: uses runtime
src/ai/flows/detect-attendance-anomalies.ts - Anomaly detector → Firebase client setup: uses Firebase
src/components/dashboard/anomaly-detector.tsx - Assessments and exams → Firebase client setup: uses Firebase
src/app/examinations/page.tsx - Results and reports → Firebase client setup: uses Firebase
src/app/results/page.tsx - Accounts and expenses → Firebase client setup: uses Firebase
src/app/expenses/page.tsx - Attendance → Firebase client setup: uses Firebase
src/app/attendance/page.tsx - Calendar and timetable → Firestore data hooks: reads collections