# brynn1-png/snap-party architecture

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

- Interactive diagram: https://gitdiagram.com/brynn1-png/snap-party
- Repository: https://github.com/brynn1-png/snap-party

## Overview

SnapParty is a mobile-first event photo booth: organizers create and share events, guests capture photos in a browser, and organizers monitor and present uploads. The graph follows the documented guest stages, event management, live viewing, and offline upload support. The README supplies the broader product relationships; sampled source verifies selected upload, queue, dashboard, and Supabase interactions. Some pages and integrations were not sampled, so their internal calls are not inferred.

Main entry points: [`src/app/page.tsx`](https://github.com/brynn1-png/snap-party/blob/main/src/app/page.tsx) (Marketing homepage), [`src/app/e/[slug]/camera/page.tsx`](https://github.com/brynn1-png/snap-party/blob/main/src/app/e/%5Bslug%5D/camera/page.tsx) (Photo capture), [`src/components/ScrollReveal.tsx`](https://github.com/brynn1-png/snap-party/blob/main/src/components/ScrollReveal.tsx) (Scroll reveal), [`src/app/dashboard/events/[id]/page.tsx`](https://github.com/brynn1-png/snap-party/blob/main/src/app/dashboard/events/%5Bid%5D/page.tsx) (Gallery and controls)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_marketing["Product presentation"]
  node_homepage["Marketing homepage<br/>[page.tsx]"]
  node_hero["Hero<br/>[Hero.tsx]"]
  node_features["Features<br/>[Features.tsx]"]
  node_how_it_works["How it works<br/>[HowItWorks.tsx]"]
  node_live_experience["Live experience"]
  node_mobile_showcase["Mobile showcase<br/>[MobileShowcase.tsx]"]
  node_organizer_showcase["Organizer showcase"]
  node_cta["Call to action<br/>[CtaBanner.tsx]"]
  node_scroll_reveal["Scroll reveal<br/>[ScrollReveal.tsx]"]
end

subgraph group_guest["Guest experience"]
  node_guest_entry["Guest entry<br/>[page.tsx]"]
  node_guest_name["Guest naming<br/>[page.tsx]"]
  node_camera["Photo capture<br/>[page.tsx]"]
  node_shot_review["Shot review"]
  node_guest_done["Guest completion<br/>[page.tsx]"]
  node_live_view["Public live view<br/>[page.tsx]"]
end

subgraph group_organizer["Organizer tools"]
  node_event_setup["Event setup<br/>[page.tsx]"]
  node_event_dashboard["Event dashboard<br/>[page.tsx]"]
  node_event_detail["Gallery and controls<br/>[page.tsx]"]
  node_slideshow["Slideshow views<br/>[Slideshow.tsx]"]
end

subgraph group_runtime["Upload and services"]
  node_upload_api["Photo upload endpoint<br/>[route.ts]"]
  node_offline_queue[("Offline photo queue<br/>[offlineQueue.ts]")]
  node_sync_worker["Queue sync worker<br/>[syncWorker.ts]"]
  node_cover_api["Cover upload endpoint<br/>[route.ts]"]
  node_supabase_client["Supabase browser client<br/>[provider.tsx]"]
  node_token["Event token generator<br/>[generateToken.ts]"]
end

node_visitor(("Site visitor"))
node_guest(("Event guest"))
node_organizer_user(("Organizer"))
node_supabase[("Supabase services")]

node_visitor -->|"visits"| node_homepage
node_homepage -->|"presents"| node_hero
node_homepage -->|"presents"| node_features
node_homepage -->|"presents"| node_how_it_works
node_homepage -->|"presents"| node_live_experience
node_homepage -->|"presents"| node_mobile_showcase
node_homepage -->|"presents"| node_organizer_showcase
node_homepage -->|"presents"| node_cta
node_features -->|"uses"| node_scroll_reveal
node_how_it_works -->|"uses"| node_scroll_reveal
node_live_experience -->|"uses"| node_scroll_reveal
node_mobile_showcase -->|"uses"| node_scroll_reveal
node_organizer_showcase -->|"uses"| node_scroll_reveal
node_organizer_user -->|"creates event"| node_event_setup
node_organizer_user -->|"manages events"| node_event_dashboard
node_event_dashboard -->|"opens event"| node_event_detail
node_event_detail -->|"renders"| node_slideshow
node_organizer_user -->|"uploads cover"| node_cover_api
node_guest -->|"opens event"| node_guest_entry
node_guest_entry -->|"continues to"| node_guest_name
node_guest_name -->|"continues to"| node_camera
node_camera -->|"renders"| node_shot_review
node_camera -->|"enqueues photo"| node_offline_queue
node_camera -->|"starts sync"| node_sync_worker
node_sync_worker -->|"reads and removes"| node_offline_queue
node_sync_worker -->|"posts photo"| node_upload_api
node_camera -->|"uploads photo"| node_upload_api
node_camera -->|"continues to"| node_guest_done
node_guest -->|"views slideshow"| node_live_view
node_event_detail -->|"uses"| node_supabase_client
node_camera -->|"uses"| node_supabase_client
node_event_setup -->|"generates token"| node_token
node_event_detail -->|"generates token"| node_token
node_supabase_client -.->|"connects"| node_supabase
node_upload_api -.->|"stores uploads"| node_supabase
node_cover_api -.->|"stores cover"| node_supabase

click node_homepage "https://github.com/brynn1-png/snap-party/blob/main/src/app/page.tsx"
click node_hero "https://github.com/brynn1-png/snap-party/blob/main/src/components/Hero.tsx"
click node_features "https://github.com/brynn1-png/snap-party/blob/main/src/components/Features.tsx"
click node_how_it_works "https://github.com/brynn1-png/snap-party/blob/main/src/components/HowItWorks.tsx"
click node_live_experience "https://github.com/brynn1-png/snap-party/blob/main/src/components/LiveEventExperience.tsx"
click node_mobile_showcase "https://github.com/brynn1-png/snap-party/blob/main/src/components/MobileShowcase.tsx"
click node_organizer_showcase "https://github.com/brynn1-png/snap-party/blob/main/src/components/OrganizerDashboard.tsx"
click node_cta "https://github.com/brynn1-png/snap-party/blob/main/src/components/CtaBanner.tsx"
click node_scroll_reveal "https://github.com/brynn1-png/snap-party/blob/main/src/components/ScrollReveal.tsx"
click node_event_setup "https://github.com/brynn1-png/snap-party/blob/main/src/app/dashboard/create/page.tsx"
click node_event_dashboard "https://github.com/brynn1-png/snap-party/blob/main/src/app/dashboard/page.tsx"
click node_event_detail "https://github.com/brynn1-png/snap-party/blob/main/src/app/dashboard/events/%5Bid%5D/page.tsx"
click node_slideshow "https://github.com/brynn1-png/snap-party/blob/main/src/components/Slideshow.tsx"
click node_guest_entry "https://github.com/brynn1-png/snap-party/blob/main/src/app/e/%5Bslug%5D/page.tsx"
click node_guest_name "https://github.com/brynn1-png/snap-party/blob/main/src/app/e/%5Bslug%5D/name/page.tsx"
click node_camera "https://github.com/brynn1-png/snap-party/blob/main/src/app/e/%5Bslug%5D/camera/page.tsx"
click node_shot_review "https://github.com/brynn1-png/snap-party/blob/main/src/components/ShotReviewModal.tsx"
click node_guest_done "https://github.com/brynn1-png/snap-party/blob/main/src/app/e/%5Bslug%5D/done/page.tsx"
click node_live_view "https://github.com/brynn1-png/snap-party/blob/main/src/app/live/%5Bslug%5D/page.tsx"
click node_upload_api "https://github.com/brynn1-png/snap-party/blob/main/src/app/api/upload/route.ts"
click node_offline_queue "https://github.com/brynn1-png/snap-party/blob/main/src/lib/offlineQueue.ts"
click node_sync_worker "https://github.com/brynn1-png/snap-party/blob/main/src/lib/syncWorker.ts"
click node_cover_api "https://github.com/brynn1-png/snap-party/blob/main/src/app/api/upload-cover/route.ts"
click node_supabase_client "https://github.com/brynn1-png/snap-party/blob/main/src/lib/supabase/provider.tsx"
click node_token "https://github.com/brynn1-png/snap-party/blob/main/src/lib/generateToken.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_homepage,node_hero,node_features,node_how_it_works,node_live_experience,node_mobile_showcase,node_organizer_showcase,node_cta,node_scroll_reveal toneBlue
class node_guest_entry,node_guest_name,node_camera,node_shot_review,node_guest_done,node_live_view,node_supabase toneAmber
class node_event_setup,node_event_dashboard,node_event_detail,node_slideshow toneMint
class node_upload_api,node_offline_queue,node_sync_worker,node_cover_api,node_supabase_client,node_token toneRose
class node_visitor,node_guest,node_organizer_user toneIndigo
```

## Components

### Product presentation

- [Marketing homepage](https://github.com/brynn1-png/snap-party/blob/main/src/app/page.tsx): `src/app/page.tsx`
- [Hero](https://github.com/brynn1-png/snap-party/blob/main/src/components/Hero.tsx): `src/components/Hero.tsx`
- [Features](https://github.com/brynn1-png/snap-party/blob/main/src/components/Features.tsx): `src/components/Features.tsx`
- [How it works](https://github.com/brynn1-png/snap-party/blob/main/src/components/HowItWorks.tsx): `src/components/HowItWorks.tsx`
- [Live experience](https://github.com/brynn1-png/snap-party/blob/main/src/components/LiveEventExperience.tsx): `src/components/LiveEventExperience.tsx`
- [Mobile showcase](https://github.com/brynn1-png/snap-party/blob/main/src/components/MobileShowcase.tsx): `src/components/MobileShowcase.tsx`
- [Organizer showcase](https://github.com/brynn1-png/snap-party/blob/main/src/components/OrganizerDashboard.tsx): `src/components/OrganizerDashboard.tsx`
- [Call to action](https://github.com/brynn1-png/snap-party/blob/main/src/components/CtaBanner.tsx): `src/components/CtaBanner.tsx`
- [Scroll reveal](https://github.com/brynn1-png/snap-party/blob/main/src/components/ScrollReveal.tsx): `src/components/ScrollReveal.tsx`

### Guest experience

- [Guest entry](https://github.com/brynn1-png/snap-party/blob/main/src/app/e/%5Bslug%5D/page.tsx): `src/app/e/[slug]/page.tsx`
- [Guest naming](https://github.com/brynn1-png/snap-party/blob/main/src/app/e/%5Bslug%5D/name/page.tsx): `src/app/e/[slug]/name/page.tsx`
- [Photo capture](https://github.com/brynn1-png/snap-party/blob/main/src/app/e/%5Bslug%5D/camera/page.tsx): `src/app/e/[slug]/camera/page.tsx`
- [Shot review](https://github.com/brynn1-png/snap-party/blob/main/src/components/ShotReviewModal.tsx): `src/components/ShotReviewModal.tsx`
- [Guest completion](https://github.com/brynn1-png/snap-party/blob/main/src/app/e/%5Bslug%5D/done/page.tsx): `src/app/e/[slug]/done/page.tsx`
- [Public live view](https://github.com/brynn1-png/snap-party/blob/main/src/app/live/%5Bslug%5D/page.tsx): `src/app/live/[slug]/page.tsx`

### Organizer tools

- [Event setup](https://github.com/brynn1-png/snap-party/blob/main/src/app/dashboard/create/page.tsx): `src/app/dashboard/create/page.tsx`
- [Event dashboard](https://github.com/brynn1-png/snap-party/blob/main/src/app/dashboard/page.tsx): `src/app/dashboard/page.tsx`
- [Gallery and controls](https://github.com/brynn1-png/snap-party/blob/main/src/app/dashboard/events/%5Bid%5D/page.tsx): `src/app/dashboard/events/[id]/page.tsx`
- [Slideshow views](https://github.com/brynn1-png/snap-party/blob/main/src/components/Slideshow.tsx): `src/components/Slideshow.tsx`

### Upload and services

- [Photo upload endpoint](https://github.com/brynn1-png/snap-party/blob/main/src/app/api/upload/route.ts): `src/app/api/upload/route.ts`
- [Offline photo queue](https://github.com/brynn1-png/snap-party/blob/main/src/lib/offlineQueue.ts): `src/lib/offlineQueue.ts`
- [Queue sync worker](https://github.com/brynn1-png/snap-party/blob/main/src/lib/syncWorker.ts): `src/lib/syncWorker.ts`
- [Cover upload endpoint](https://github.com/brynn1-png/snap-party/blob/main/src/app/api/upload-cover/route.ts): `src/app/api/upload-cover/route.ts`
- [Supabase browser client](https://github.com/brynn1-png/snap-party/blob/main/src/lib/supabase/provider.tsx): `src/lib/supabase/provider.tsx`
- [Event token generator](https://github.com/brynn1-png/snap-party/blob/main/src/lib/generateToken.ts): `src/lib/generateToken.ts`

### Other components

- **Site visitor**
- **Event guest**
- **Organizer**
- **Supabase services**

## Connections

- Site visitor → Marketing homepage: visits (evidence: `README.md`)
- Marketing homepage → Hero: presents
- Marketing homepage → Features: presents
- Marketing homepage → How it works: presents
- Marketing homepage → Live experience: presents
- Marketing homepage → Mobile showcase: presents
- Marketing homepage → Organizer showcase: presents
- Marketing homepage → Call to action: presents
- Features → Scroll reveal: uses (evidence: `src/components/Features.tsx`)
- How it works → Scroll reveal: uses (evidence: `src/components/HowItWorks.tsx`)
- Live experience → Scroll reveal: uses (evidence: `src/components/LiveEventExperience.tsx`)
- Mobile showcase → Scroll reveal: uses (evidence: `src/components/MobileShowcase.tsx`)
- Organizer showcase → Scroll reveal: uses (evidence: `src/components/OrganizerDashboard.tsx`)
- Organizer → Event setup: creates event (evidence: `README.md`)
- Organizer → Event dashboard: manages events (evidence: `README.md`)
- Event dashboard → Gallery and controls: opens event (evidence: `README.md`)
- Gallery and controls → Slideshow views: renders (evidence: `src/app/dashboard/events/[id]/page.tsx`)
- Organizer → Cover upload endpoint: uploads cover (evidence: `README.md`)
- Event guest → Guest entry: opens event (evidence: `README.md`)
- Guest entry → Guest naming: continues to (evidence: `README.md`)
- Guest naming → Photo capture: continues to (evidence: `README.md`)
- Photo capture → Shot review: renders (evidence: `src/app/e/[slug]/camera/page.tsx`)
- Photo capture → Offline photo queue: enqueues photo (evidence: `src/app/e/[slug]/camera/page.tsx`)
- Photo capture → Queue sync worker: starts sync (evidence: `src/app/e/[slug]/camera/page.tsx`)
- Queue sync worker → Offline photo queue: reads and removes (evidence: `src/lib/syncWorker.ts`)
- Queue sync worker → Photo upload endpoint: posts photo (evidence: `src/lib/syncWorker.ts`)
- Photo capture → Photo upload endpoint: uploads photo (evidence: `README.md`)
- Photo capture → Guest completion: continues to (evidence: `README.md`)
- Event guest → Public live view: views slideshow (evidence: `README.md`)
- Gallery and controls → Supabase browser client: uses (evidence: `src/app/dashboard/events/[id]/page.tsx`)
- Photo capture → Supabase browser client: uses (evidence: `src/app/e/[slug]/camera/page.tsx`)
- Event setup → Event token generator: generates token (evidence: `src/app/dashboard/create/page.tsx`)
- Gallery and controls → Event token generator: generates token (evidence: `src/app/dashboard/events/[id]/page.tsx`)
- Supabase browser client → Supabase services: connects
- Photo upload endpoint → Supabase services: stores uploads
- Cover upload endpoint → Supabase services: stores cover
