# mengheapk/frontend-final-project architecture

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

- Interactive diagram: https://gitdiagram.com/mengheapk/frontend-final-project
- Repository: https://github.com/mengheapk/frontend-final-project

## Overview

Event Planning Portal is a browser-based event organizer: users sign in, browse or create events, then inspect event details to manage RSVPs and shared tasks. Calendar and dashboard views help track upcoming events, responses, and assigned work; sharing supports invitations, while profile and theme settings personalize the app. Event, account, and theme state persist in browser local storage, with sample users and events seeded locally. The README contains no capability details, so documented scope is inferred from the source index and excerpts; some page-to-component links are supported by indexed imports rather than inspected implementation.

Main entry points: [`src/App.jsx`](https://github.com/mengheapk/frontend-final-project/blob/main/src/App.jsx) (Route Map), [`src/context/EventsContext.jsx`](https://github.com/mengheapk/frontend-final-project/blob/main/src/context/EventsContext.jsx) (Event State), [`src/context/AuthContext.jsx`](https://github.com/mengheapk/frontend-final-project/blob/main/src/context/AuthContext.jsx) (Account State), [`src/pages/EventDetailPage.jsx`](https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/EventDetailPage.jsx) (Event Details)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application Shell"]
  node_main["App Bootstrap<br/>[main.jsx]"]
  node_routing["Route Map<br/>[App.jsx]"]
  node_layout["Layout and Navigation<br/>[Navbar.jsx]"]
  node_authgate["Protected Routes<br/>[ProtectedRoute.jsx]"]
  node_login["Sign-in Page<br/>[LoginPage.jsx]"]
  node_dashboard["Dashboard<br/>[DashboardPage.jsx]"]
  node_profile["Profile Settings<br/>[ProfilePage.jsx]"]
  node_titlehook["Document Title"]
end

subgraph group_events["Event Management"]
  node_eventlist["Event Listing<br/>[EventsPage.jsx]"]
  node_eventformpage["Event Form Page<br/>[EventFormPage.jsx]"]
  node_eventform["Event Editor<br/>[EventForm.jsx]"]
  node_eventdetail["Event Details"]
  node_eventcard["Event Card<br/>[EventCard.jsx]"]
  node_filters["Event Filters<br/>[EventFilters.jsx]"]
  node_calendar["Calendar View<br/>[CalendarPage.jsx]"]
  node_monthgrid["Month Grid<br/>[MonthGrid.jsx]"]
  node_daycell["Calendar Day<br/>[DayCell.jsx]"]
end

subgraph group_participation["Participation"]
  node_rsvppage["RSVP Page<br/>[RsvpPage.jsx]"]
  node_rsvpbuttons["RSVP Controls<br/>[RsvpButtons.jsx]"]
  node_guestlist["Guest List<br/>[GuestList.jsx]"]
  node_tasklist["Event Tasks<br/>[TaskList.jsx]"]
  node_sharebutton["Share Control<br/>[ShareButton.jsx]"]
  node_shareutil["Share Utilities<br/>[share.js]"]
end

subgraph group_state["Shared State"]
  node_auth["Account State<br/>[AuthContext.jsx]"]
  node_eventsstate["Event State<br/>[EventsContext.jsx]"]
  node_theme["Theme State<br/>[ThemeContext.jsx]"]
  node_storagehook["Persistence Hook<br/>[useLocalStorage.js]"]
  node_browserstorage[("Browser Storage")]
  node_seed["Demo Data<br/>[seed.js]"]
end

node_visitor(("Visitor"))

node_visitor -->|"uses routes"| node_routing
node_main -->|"renders"| node_routing
node_main -->|"provides"| node_auth
node_main -->|"provides"| node_eventsstate
node_main -->|"provides"| node_theme
node_routing -->|"wraps routes"| node_layout
node_routing -->|"guards pages"| node_authgate
node_routing -->|"routes to"| node_login
node_routing -->|"routes to"| node_dashboard
node_routing -->|"routes to"| node_eventlist
node_routing -->|"routes to"| node_eventformpage
node_routing -->|"routes to"| node_eventdetail
node_routing -->|"routes to"| node_rsvppage
node_routing -->|"routes to"| node_calendar
node_routing -->|"routes to"| node_profile
node_eventformpage -->|"renders"| node_eventform
node_eventlist -->|"renders"| node_eventcard
node_eventlist -->|"renders"| node_filters
node_dashboard -->|"renders"| node_eventcard
node_calendar -->|"renders"| node_monthgrid
node_monthgrid -->|"renders"| node_daycell
node_eventdetail -->|"renders"| node_guestlist
node_eventdetail -->|"renders"| node_tasklist
node_eventdetail -->|"renders"| node_sharebutton
node_sharebutton -->|"uses"| node_shareutil
node_rsvppage -->|"renders"| node_rsvpbuttons
node_rsvpbuttons -->|"updates RSVP"| node_eventsstate
node_eventformpage -->|"manages event"| node_eventsstate
node_eventdetail -->|"reads and deletes"| node_eventsstate
node_eventlist -->|"reads events"| node_eventsstate
node_calendar -->|"reads events"| node_eventsstate
node_dashboard -->|"reads and updates"| node_eventsstate
node_tasklist -->|"manages tasks"| node_eventsstate
node_guestlist -->|"reads guests"| node_eventsstate
node_login -->|"signs in"| node_auth
node_profile -->|"updates profile"| node_auth
node_layout -->|"logs out"| node_auth
node_layout -->|"toggles theme"| node_theme
node_eventsstate -->|"reads current user"| node_auth
node_auth -->|"persists account"| node_storagehook
node_eventsstate -->|"persists events"| node_storagehook
node_theme -->|"persists theme"| node_storagehook
node_storagehook -->|"reads and writes"| node_browserstorage
node_auth -->|"loads demo users"| node_seed
node_eventsstate -->|"creates sample events"| node_seed
node_dashboard -->|"sets title"| node_titlehook
node_eventdetail -->|"sets title"| node_titlehook
node_profile -->|"sets title"| node_titlehook

click node_main "https://github.com/mengheapk/frontend-final-project/blob/main/src/main.jsx"
click node_routing "https://github.com/mengheapk/frontend-final-project/blob/main/src/App.jsx"
click node_layout "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/layout/Navbar.jsx"
click node_authgate "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/layout/ProtectedRoute.jsx"
click node_login "https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/LoginPage.jsx"
click node_dashboard "https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/DashboardPage.jsx"
click node_profile "https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/ProfilePage.jsx"
click node_eventlist "https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/EventsPage.jsx"
click node_eventformpage "https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/EventFormPage.jsx"
click node_eventform "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/events/EventForm.jsx"
click node_eventdetail "https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/EventDetailPage.jsx"
click node_eventcard "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/events/EventCard.jsx"
click node_filters "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/events/EventFilters.jsx"
click node_calendar "https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/CalendarPage.jsx"
click node_monthgrid "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/calendar/MonthGrid.jsx"
click node_daycell "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/calendar/DayCell.jsx"
click node_rsvppage "https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/RsvpPage.jsx"
click node_rsvpbuttons "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/rsvp/RsvpButtons.jsx"
click node_guestlist "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/rsvp/GuestList.jsx"
click node_tasklist "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/tasks/TaskList.jsx"
click node_sharebutton "https://github.com/mengheapk/frontend-final-project/blob/main/src/components/share/ShareButton.jsx"
click node_shareutil "https://github.com/mengheapk/frontend-final-project/blob/main/src/utils/share.js"
click node_auth "https://github.com/mengheapk/frontend-final-project/blob/main/src/context/AuthContext.jsx"
click node_eventsstate "https://github.com/mengheapk/frontend-final-project/blob/main/src/context/EventsContext.jsx"
click node_theme "https://github.com/mengheapk/frontend-final-project/blob/main/src/context/ThemeContext.jsx"
click node_storagehook "https://github.com/mengheapk/frontend-final-project/blob/main/src/hooks/useLocalStorage.js"
click node_seed "https://github.com/mengheapk/frontend-final-project/blob/main/src/utils/seed.js"
click node_titlehook "https://github.com/mengheapk/frontend-final-project/blob/main/src/hooks/useDocumentTitle.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_main,node_routing,node_layout,node_authgate,node_login,node_dashboard,node_profile,node_titlehook toneBlue
class node_eventlist,node_eventformpage,node_eventform,node_eventdetail,node_eventcard,node_filters,node_calendar,node_monthgrid,node_daycell toneAmber
class node_rsvppage,node_rsvpbuttons,node_guestlist,node_tasklist,node_sharebutton,node_shareutil toneMint
class node_auth,node_eventsstate,node_theme,node_storagehook,node_browserstorage,node_seed toneRose
class node_visitor toneIndigo
```

## Components

### Application Shell

- [App Bootstrap](https://github.com/mengheapk/frontend-final-project/blob/main/src/main.jsx): `src/main.jsx`
- [Route Map](https://github.com/mengheapk/frontend-final-project/blob/main/src/App.jsx): `src/App.jsx`
- [Layout and Navigation](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/layout/Navbar.jsx): `src/components/layout/Navbar.jsx`
- [Protected Routes](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/layout/ProtectedRoute.jsx): `src/components/layout/ProtectedRoute.jsx`
- [Sign-in Page](https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/LoginPage.jsx): `src/pages/LoginPage.jsx`
- [Dashboard](https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/DashboardPage.jsx): `src/pages/DashboardPage.jsx`
- [Profile Settings](https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/ProfilePage.jsx): `src/pages/ProfilePage.jsx`
- [Document Title](https://github.com/mengheapk/frontend-final-project/blob/main/src/hooks/useDocumentTitle.js): `src/hooks/useDocumentTitle.js`

### Event Management

- [Event Listing](https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/EventsPage.jsx): `src/pages/EventsPage.jsx`
- [Event Form Page](https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/EventFormPage.jsx): `src/pages/EventFormPage.jsx`
- [Event Editor](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/events/EventForm.jsx): `src/components/events/EventForm.jsx`
- [Event Details](https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/EventDetailPage.jsx): `src/pages/EventDetailPage.jsx`
- [Event Card](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/events/EventCard.jsx): `src/components/events/EventCard.jsx`
- [Event Filters](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/events/EventFilters.jsx): `src/components/events/EventFilters.jsx`
- [Calendar View](https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/CalendarPage.jsx): `src/pages/CalendarPage.jsx`
- [Month Grid](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/calendar/MonthGrid.jsx): `src/components/calendar/MonthGrid.jsx`
- [Calendar Day](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/calendar/DayCell.jsx): `src/components/calendar/DayCell.jsx`

### Participation

- [RSVP Page](https://github.com/mengheapk/frontend-final-project/blob/main/src/pages/RsvpPage.jsx): `src/pages/RsvpPage.jsx`
- [RSVP Controls](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/rsvp/RsvpButtons.jsx): `src/components/rsvp/RsvpButtons.jsx`
- [Guest List](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/rsvp/GuestList.jsx): `src/components/rsvp/GuestList.jsx`
- [Event Tasks](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/tasks/TaskList.jsx): `src/components/tasks/TaskList.jsx`
- [Share Control](https://github.com/mengheapk/frontend-final-project/blob/main/src/components/share/ShareButton.jsx): `src/components/share/ShareButton.jsx`
- [Share Utilities](https://github.com/mengheapk/frontend-final-project/blob/main/src/utils/share.js): `src/utils/share.js`

### Shared State

- [Account State](https://github.com/mengheapk/frontend-final-project/blob/main/src/context/AuthContext.jsx): `src/context/AuthContext.jsx`
- [Event State](https://github.com/mengheapk/frontend-final-project/blob/main/src/context/EventsContext.jsx): `src/context/EventsContext.jsx`
- [Theme State](https://github.com/mengheapk/frontend-final-project/blob/main/src/context/ThemeContext.jsx): `src/context/ThemeContext.jsx`
- [Persistence Hook](https://github.com/mengheapk/frontend-final-project/blob/main/src/hooks/useLocalStorage.js): `src/hooks/useLocalStorage.js`
- **Browser Storage**
- [Demo Data](https://github.com/mengheapk/frontend-final-project/blob/main/src/utils/seed.js): `src/utils/seed.js`

### Other components

- **Visitor**

## Connections

- Visitor → Route Map: uses routes (evidence: `src/App.jsx`)
- App Bootstrap → Route Map: renders (evidence: `src/main.jsx`)
- App Bootstrap → Account State: provides (evidence: `src/main.jsx`)
- App Bootstrap → Event State: provides (evidence: `src/main.jsx`)
- App Bootstrap → Theme State: provides (evidence: `src/main.jsx`)
- Route Map → Layout and Navigation: wraps routes (evidence: `src/App.jsx`)
- Route Map → Protected Routes: guards pages (evidence: `src/App.jsx`)
- Route Map → Sign-in Page: routes to (evidence: `src/App.jsx`)
- Route Map → Dashboard: routes to (evidence: `src/App.jsx`)
- Route Map → Event Listing: routes to (evidence: `src/App.jsx`)
- Route Map → Event Form Page: routes to (evidence: `src/App.jsx`)
- Route Map → Event Details: routes to (evidence: `src/App.jsx`)
- Route Map → RSVP Page: routes to (evidence: `src/App.jsx`)
- Route Map → Calendar View: routes to (evidence: `src/App.jsx`)
- Route Map → Profile Settings: routes to (evidence: `src/App.jsx`)
- Event Form Page → Event Editor: renders (evidence: `src/pages/EventFormPage.jsx`)
- Event Listing → Event Card: renders (evidence: `src/pages/EventsPage.jsx`)
- Event Listing → Event Filters: renders (evidence: `src/pages/EventsPage.jsx`)
- Dashboard → Event Card: renders (evidence: `src/pages/DashboardPage.jsx`)
- Calendar View → Month Grid: renders (evidence: `src/pages/CalendarPage.jsx`)
- Month Grid → Calendar Day: renders (evidence: `src/components/calendar/MonthGrid.jsx`)
- Event Details → Guest List: renders (evidence: `src/pages/EventDetailPage.jsx`)
- Event Details → Event Tasks: renders (evidence: `src/pages/EventDetailPage.jsx`)
- Event Details → Share Control: renders (evidence: `src/pages/EventDetailPage.jsx`)
- Share Control → Share Utilities: uses (evidence: `src/components/share/ShareButton.jsx`)
- RSVP Page → RSVP Controls: renders (evidence: `src/pages/RsvpPage.jsx`)
- RSVP Controls → Event State: updates RSVP (evidence: `src/components/rsvp/RsvpButtons.jsx`)
- Event Form Page → Event State: manages event (evidence: `src/pages/EventFormPage.jsx`)
- Event Details → Event State: reads and deletes (evidence: `src/pages/EventDetailPage.jsx`)
- Event Listing → Event State: reads events (evidence: `src/pages/EventsPage.jsx`)
- Calendar View → Event State: reads events (evidence: `src/pages/CalendarPage.jsx`)
- Dashboard → Event State: reads and updates (evidence: `src/pages/DashboardPage.jsx`)
- Event Tasks → Event State: manages tasks (evidence: `src/components/tasks/TaskList.jsx`)
- Guest List → Event State: reads guests (evidence: `src/components/rsvp/GuestList.jsx`)
- Sign-in Page → Account State: signs in (evidence: `src/pages/LoginPage.jsx`)
- Profile Settings → Account State: updates profile (evidence: `src/pages/ProfilePage.jsx`)
- Layout and Navigation → Account State: logs out (evidence: `src/components/layout/Navbar.jsx`)
- Layout and Navigation → Theme State: toggles theme (evidence: `src/components/layout/Navbar.jsx`)
- Event State → Account State: reads current user (evidence: `src/context/EventsContext.jsx`)
- Account State → Persistence Hook: persists account (evidence: `src/context/AuthContext.jsx`)
- Event State → Persistence Hook: persists events (evidence: `src/context/EventsContext.jsx`)
- Theme State → Persistence Hook: persists theme (evidence: `src/context/ThemeContext.jsx`)
- Persistence Hook → Browser Storage: reads and writes (evidence: `src/hooks/useLocalStorage.js`)
- Account State → Demo Data: loads demo users (evidence: `src/context/AuthContext.jsx`)
- Event State → Demo Data: creates sample events (evidence: `src/context/EventsContext.jsx`)
- Dashboard → Document Title: sets title (evidence: `src/pages/DashboardPage.jsx`)
- Event Details → Document Title: sets title (evidence: `src/pages/EventDetailPage.jsx`)
- Profile Settings → Document Title: sets title (evidence: `src/pages/ProfilePage.jsx`)
