# gdg-vishnu/gdg-vitb architecture

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

- Interactive diagram: https://gitdiagram.com/gdg-vishnu/gdg-vitb
- Repository: https://github.com/gdg-vishnu/gdg-vitb

## Overview

This is the GDG On Campus VITB public community website. Visitors browse community information, events and gallery content; event detail pages support authenticated registration, while members can complete profiles and review registrations. Recruitment provides role listings and application submission. The graph follows documented routes and the sampled event, auth and recruitment implementations. Several README capabilities are represented from documentation/tree evidence because their source was not sampled; links for those are omitted where runtime wiring is not shown.

Main entry points: [`src/lib/firebase-admin.ts`](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/firebase-admin.ts) (Firebase Admin), [`src/lib/firebase-client.ts`](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/firebase-client.ts) (Firebase client), [`src/app/recruitment/[roleId]/page.tsx`](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/recruitment/%5BroleId%5D/page.tsx) (Application form), [`src/contexts/AuthContext.tsx`](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/contexts/AuthContext.tsx) (Auth context)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_public["Public experience"]
  node_home["Home<br/>[HomePage.tsx]"]
  node_about["About<br/>[AboutPage.tsx]"]
  node_contact["Contact<br/>[ContactUsPage.tsx]"]
  node_gallery["Gallery<br/>[GalleryPage.tsx]"]
  node_teams["Teams<br/>[TeamsPage.tsx]"]
end

subgraph group_events["Events and registration"]
  node_eventslist["Event listing<br/>[page.tsx]"]
  node_eventdetail["Event detail<br/>[page.tsx]"]
  node_eventapi["Event API<br/>[route.ts]"]
  node_eventdetailapi["Event detail API<br/>[route.ts]"]
  node_registration["Registration guard"]
  node_registrationsview["My registrations"]
end

subgraph group_members["Member identity"]
  node_auth["Auth context<br/>[AuthContext.tsx]"]
  node_authpages["Sign in and signup<br/>[SignupCard.tsx]"]
  node_profile["Profile setup"]
  node_userprofile["Profile pages<br/>[page.tsx]"]
end

subgraph group_recruit["Recruitment"]
  node_recruitlist["Role listings<br/>[page.tsx]"]
  node_application["Application form<br/>[page.tsx]"]
  node_recruithooks["Recruitment data hooks<br/>[hooks.ts]"]
  node_recruitsubmit["Application submission<br/>[submit.ts]"]
  node_recruitupload["Application uploads<br/>[upload.ts]"]
  node_recruitemail["Recruitment email<br/>[email.ts]"]
end

subgraph group_platform["Data and integrations"]
  node_firebaseclient["Firebase client<br/>[firebase-client.ts]"]
  node_firebaseadmin["Firebase Admin<br/>[firebase-admin.ts]"]
  node_firestore[("Cloud Firestore")]
  node_galleryapi["Gallery API<br/>[route.ts]"]
  node_teamsapi["Teams API<br/>[route.ts]"]
  node_emailapi["Contact email API<br/>[route.ts]"]
  node_uploadapi["Upload API<br/>[route.ts]"]
end

node_visitor(("Visitor"))
node_cloudinary["Image hosting"]

node_visitor -->|"browses"| node_home
node_visitor -->|"browses"| node_eventslist
node_visitor -->|"opens"| node_eventdetail
node_visitor -->|"browses"| node_about
node_visitor -->|"browses"| node_gallery
node_visitor -->|"browses"| node_teams
node_visitor -->|"contacts"| node_contact
node_eventslist -->|"fetches list"| node_eventapi
node_eventdetail -->|"fetches event"| node_eventdetailapi
node_eventapi -->|"queries"| node_firebaseadmin
node_eventdetailapi -->|"reads event"| node_firebaseadmin
node_firebaseadmin -.->|"reads"| node_firestore
node_eventdetail -->|"checks eligibility"| node_registration
node_registration -->|"reads profile"| node_firebaseclient
node_authpages -.->|"signs in"| node_auth
node_auth -->|"authenticates"| node_firebaseclient
node_auth -.->|"reads and writes"| node_firestore
node_profile -.->|"updates profile"| node_firebaseclient
node_registrationsview -->|"uses identity"| node_auth
node_registrationsview -->|"reads registrations"| node_firebaseclient
node_recruitlist -.->|"loads roles"| node_recruithooks
node_application -->|"loads role"| node_recruithooks
node_recruithooks -->|"queries roles"| node_firebaseclient
node_application -->|"submits application"| node_recruitsubmit
node_application -->|"uploads files"| node_recruitupload
node_application -->|"sends notice"| node_recruitemail
node_gallery -.->|"loads photos"| node_galleryapi
node_galleryapi -->|"queries"| node_firebaseadmin
node_teams -.->|"loads members"| node_teamsapi
node_teamsapi -->|"queries"| node_firebaseadmin
node_contact -.->|"sends message"| node_emailapi
node_emailapi -.->|"optional service"| node_cloudinary
node_uploadapi -.->|"stores images"| node_cloudinary

click node_home "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/features/home/components/HomePage.tsx"
click node_about "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/features/about/components/AboutPage.tsx"
click node_contact "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/features/contactus/components/ContactUsPage.tsx"
click node_gallery "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/features/gallery/components/GalleryPage.tsx"
click node_teams "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/features/teams/components/TeamsPage.tsx"
click node_eventslist "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/events/page.tsx"
click node_eventdetail "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/events/%5Bid%5D/page.tsx"
click node_eventapi "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/events/list/route.ts"
click node_eventdetailapi "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/events/%5Bid%5D/route.ts"
click node_registration "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/services/registration.service.ts"
click node_registrationsview "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/components/RegistrationCard.tsx"
click node_auth "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/contexts/AuthContext.tsx"
click node_authpages "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/components/auth/SignupCard.tsx"
click node_profile "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/components/profile/EditProfileForm.tsx"
click node_userprofile "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/profile/%5BuserId%5D/page.tsx"
click node_recruitlist "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/recruitment/page.tsx"
click node_application "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/recruitment/%5BroleId%5D/page.tsx"
click node_recruithooks "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/recruitment/hooks.ts"
click node_recruitsubmit "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/recruitment/submit.ts"
click node_recruitupload "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/recruitment/upload.ts"
click node_recruitemail "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/recruitment/email.ts"
click node_firebaseclient "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/firebase-client.ts"
click node_firebaseadmin "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/firebase-admin.ts"
click node_galleryapi "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/gallery/list/route.ts"
click node_teamsapi "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/teams/list/route.ts"
click node_emailapi "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/send-email/route.ts"
click node_uploadapi "https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/upload/route.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_home,node_about,node_contact,node_gallery,node_teams toneBlue
class node_eventslist,node_eventdetail,node_eventapi,node_eventdetailapi,node_registration,node_registrationsview toneAmber
class node_auth,node_authpages,node_profile,node_userprofile toneMint
class node_recruitlist,node_application,node_recruithooks,node_recruitsubmit,node_recruitupload,node_recruitemail toneRose
class node_firebaseclient,node_firebaseadmin,node_firestore,node_galleryapi,node_teamsapi,node_emailapi,node_uploadapi,node_visitor,node_cloudinary toneIndigo
```

## Components

### Public experience

- [Home](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/features/home/components/HomePage.tsx): `src/features/home/components/HomePage.tsx`
- [About](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/features/about/components/AboutPage.tsx): `src/features/about/components/AboutPage.tsx`
- [Contact](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/features/contactus/components/ContactUsPage.tsx): `src/features/contactus/components/ContactUsPage.tsx`
- [Gallery](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/features/gallery/components/GalleryPage.tsx): `src/features/gallery/components/GalleryPage.tsx`
- [Teams](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/features/teams/components/TeamsPage.tsx): `src/features/teams/components/TeamsPage.tsx`

### Events and registration

- [Event listing](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/events/page.tsx): `src/app/events/page.tsx`
- [Event detail](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/events/%5Bid%5D/page.tsx): `src/app/events/[id]/page.tsx`
- [Event API](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/events/list/route.ts): `src/app/api/events/list/route.ts`
- [Event detail API](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/events/%5Bid%5D/route.ts): `src/app/api/events/[id]/route.ts`
- [Registration guard](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/services/registration.service.ts): `src/services/registration.service.ts`
- [My registrations](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/components/RegistrationCard.tsx): `src/components/RegistrationCard.tsx`

### Member identity

- [Auth context](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/contexts/AuthContext.tsx): `src/contexts/AuthContext.tsx`
- [Sign in and signup](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/components/auth/SignupCard.tsx): `src/components/auth/SignupCard.tsx`
- [Profile setup](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/components/profile/EditProfileForm.tsx): `src/components/profile/EditProfileForm.tsx`
- [Profile pages](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/profile/%5BuserId%5D/page.tsx): `src/app/profile/[userId]/page.tsx`

### Recruitment

- [Role listings](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/recruitment/page.tsx): `src/app/recruitment/page.tsx`
- [Application form](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/recruitment/%5BroleId%5D/page.tsx): `src/app/recruitment/[roleId]/page.tsx`
- [Recruitment data hooks](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/recruitment/hooks.ts): `src/lib/recruitment/hooks.ts`
- [Application submission](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/recruitment/submit.ts): `src/lib/recruitment/submit.ts`
- [Application uploads](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/recruitment/upload.ts): `src/lib/recruitment/upload.ts`
- [Recruitment email](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/recruitment/email.ts): `src/lib/recruitment/email.ts`

### Data and integrations

- [Firebase client](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/firebase-client.ts): `src/lib/firebase-client.ts`
- [Firebase Admin](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/lib/firebase-admin.ts): `src/lib/firebase-admin.ts`
- **Cloud Firestore**
- [Gallery API](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/gallery/list/route.ts): `src/app/api/gallery/list/route.ts`
- [Teams API](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/teams/list/route.ts): `src/app/api/teams/list/route.ts`
- [Contact email API](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/send-email/route.ts): `src/app/api/send-email/route.ts`
- [Upload API](https://github.com/gdg-vishnu/gdg-vitb/blob/main/src/app/api/upload/route.ts): `src/app/api/upload/route.ts`

### Other components

- **Visitor**
- **Image hosting**

## Connections

- Visitor → Home: browses
- Visitor → Event listing: browses
- Visitor → Event detail: opens
- Visitor → About: browses
- Visitor → Gallery: browses
- Visitor → Teams: browses
- Visitor → Contact: contacts
- Event listing → Event API: fetches list (evidence: `src/app/events/page.tsx`)
- Event detail → Event detail API: fetches event (evidence: `src/app/events/[id]/page.tsx`)
- Event API → Firebase Admin: queries (evidence: `src/app/api/events/list/route.ts`)
- Event detail API → Firebase Admin: reads event (evidence: `src/app/api/events/[id]/route.ts`)
- Firebase Admin → Cloud Firestore: reads (evidence: `src/lib/firebase-admin.ts`)
- Event detail → Registration guard: checks eligibility (evidence: `src/app/events/[id]/page.tsx`)
- Registration guard → Firebase client: reads profile (evidence: `src/services/registration.service.ts`)
- Sign in and signup → Auth context: signs in
- Auth context → Firebase client: authenticates (evidence: `src/contexts/AuthContext.tsx`)
- Auth context → Cloud Firestore: reads and writes (evidence: `src/contexts/AuthContext.tsx`)
- Profile setup → Firebase client: updates profile
- My registrations → Auth context: uses identity (evidence: `src/components/RegistrationCard.tsx`)
- My registrations → Firebase client: reads registrations (evidence: `src/components/RegistrationCard.tsx`)
- Role listings → Recruitment data hooks: loads roles
- Application form → Recruitment data hooks: loads role (evidence: `src/app/recruitment/[roleId]/page.tsx`)
- Recruitment data hooks → Firebase client: queries roles (evidence: `src/lib/recruitment/hooks.ts`)
- Application form → Application submission: submits application (evidence: `src/app/recruitment/[roleId]/page.tsx`)
- Application form → Application uploads: uploads files (evidence: `src/app/recruitment/[roleId]/page.tsx`)
- Application form → Recruitment email: sends notice (evidence: `src/app/recruitment/[roleId]/page.tsx`)
- Gallery → Gallery API: loads photos
- Gallery API → Firebase Admin: queries (evidence: `src/app/api/gallery/list/route.ts`)
- Teams → Teams API: loads members
- Teams API → Firebase Admin: queries (evidence: `src/app/api/teams/list/route.ts`)
- Contact → Contact email API: sends message
- Contact email API → Image hosting: optional service
- Upload API → Image hosting: stores images
