# celebrityleftback19/helsagrace architecture

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

- Interactive diagram: https://gitdiagram.com/celebrityleftback19/helsagrace
- Repository: https://github.com/celebrityleftback19/helsagrace

## Overview

HelsaGrace is a personal portfolio presenting design and full-stack product work, with a Supabase-backed content admin and a contact form. The main visitor flow loads live or default content, renders portfolio sections, and opens interactive case studies; enquiries post to an email route. The admin authenticates owners, edits content and media, and supports revision history and restore. Edges are limited to shown imports/calls or README-documented behavior; unsampled admin pages are represented by their documented subsystem, not inferred call chains.

Main entry points: [`app/page.tsx`](https://github.com/celebrityleftback19/helsagrace/blob/main/app/page.tsx) (Portfolio page), [`app/admin/actions.ts`](https://github.com/celebrityleftback19/helsagrace/blob/main/app/admin/actions.ts) (Admin actions), [`lib/cms.ts`](https://github.com/celebrityleftback19/helsagrace/blob/main/lib/cms.ts) (Content reader), [`components/admin/collection-editor.tsx`](https://github.com/celebrityleftback19/helsagrace/blob/main/components/admin/collection-editor.tsx) (Content editors)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_public["Public portfolio"]
  node_home["Portfolio page<br/>[page.tsx]"]
  node_hero["Hero<br/>[hero.tsx]"]
  node_work["Project work<br/>[work-section.tsx]"]
  node_capabilities["Capabilities"]
  node_process["Process"]
  node_stack["Technology stack<br/>[stack-section.tsx]"]
  node_about["About and stats<br/>[about-section.tsx]"]
  node_contactsection["Contact section"]
  node_caseimage["Case images<br/>[case-image.tsx]"]
  node_drawer["Case study drawer<br/>[project-drawer.tsx]"]
  node_tag["Project tags<br/>[tag.tsx]"]
  node_icons["Icon resolver<br/>[icons.ts]"]
end

subgraph group_content["Content services"]
  node_contentmodel["Content model and defaults<br/>[content.ts]"]
  node_cms["Content reader<br/>[cms.ts]"]
  node_supabase[("Supabase content store")]
  node_settings["Supabase configuration<br/>[env.ts]"]
end

subgraph group_admin["Content administration"]
  node_adminpages["Admin pages"]
  node_editors["Content editors"]
  node_controls["Editor controls<br/>[controls.tsx]"]
  node_adminactions["Admin actions<br/>[actions.ts]"]
  node_adminauth["Session and owner checks<br/>[server.ts]"]
  node_admindata["History, messages, media<br/>[admin-data.ts]"]
  node_adminui["Admin UI primitives<br/>[ui.tsx]"]
end

subgraph group_contact["Contact enquiries"]
  node_contactform["Contact form<br/>[contact-form.tsx]"]
  node_contactroute["Contact API route<br/>[route.ts]"]
  node_contactservice["Contact validation<br/>[contact.ts]"]
  node_resend["Resend email"]
end

subgraph group_motion["Motion and interaction"]
  node_intro["Intro experience<br/>[intro-provider.tsx]"]
  node_scroll["Smooth scrolling<br/>[smooth-scroll.tsx]"]
  node_reveal["Scroll reveal<br/>[reveal.tsx]"]
end

node_visitor(("Visitor"))
node_adminuser(("Portfolio owner"))

node_visitor -->|"visits"| node_home
node_home -->|"loads content"| node_cms
node_home -->|"wraps page"| node_intro
node_home -->|"renders"| node_hero
node_home -->|"renders"| node_work
node_home -->|"renders"| node_capabilities
node_home -->|"renders"| node_process
node_home -->|"renders"| node_stack
node_home -->|"renders"| node_about
node_home -->|"renders"| node_contactsection
node_cms -->|"merges defaults"| node_contentmodel
node_cms -->|"checks configuration"| node_settings
node_cms -->|"reads content"| node_supabase
node_work -->|"opens case study"| node_drawer
node_capabilities -->|"opens proof project"| node_drawer
node_drawer -->|"renders screenshots"| node_caseimage
node_drawer -->|"renders tags"| node_tag
node_hero -->|"uses scrolling"| node_scroll
node_intro -->|"uses scrolling"| node_scroll
node_capabilities -->|"resolves icons"| node_icons
node_adminuser -->|"manages content"| node_adminpages
node_adminpages -->|"uses editors"| node_editors
node_editors -->|"uses controls"| node_controls
node_editors -->|"uses primitives"| node_adminui
node_editors -->|"saves content"| node_adminactions
node_adminactions -->|"checks owner"| node_adminauth
node_adminactions -->|"reads content"| node_cms
node_adminactions -->|"writes content"| node_supabase
node_adminactions -->|"restores and lists"| node_admindata
node_adminauth -->|"checks session"| node_supabase
node_admindata -->|"reads admin data"| node_supabase
node_contactform -->|"posts enquiry"| node_contactroute
node_contactroute -->|"validates input"| node_contactservice
node_contactroute -->|"sends email"| node_resend

click node_home "https://github.com/celebrityleftback19/helsagrace/blob/main/app/page.tsx"
click node_hero "https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/hero.tsx"
click node_work "https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/work-section.tsx"
click node_capabilities "https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/capabilities-section.tsx"
click node_process "https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/process-section.tsx"
click node_stack "https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/stack-section.tsx"
click node_about "https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/about-section.tsx"
click node_contactsection "https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/contact-section.tsx"
click node_caseimage "https://github.com/celebrityleftback19/helsagrace/blob/main/components/case-image.tsx"
click node_drawer "https://github.com/celebrityleftback19/helsagrace/blob/main/components/project-drawer.tsx"
click node_contentmodel "https://github.com/celebrityleftback19/helsagrace/blob/main/lib/content.ts"
click node_cms "https://github.com/celebrityleftback19/helsagrace/blob/main/lib/cms.ts"
click node_settings "https://github.com/celebrityleftback19/helsagrace/blob/main/lib/supabase/env.ts"
click node_adminpages "https://github.com/celebrityleftback19/helsagrace/tree/main/app/admin/(dashboard)"
click node_editors "https://github.com/celebrityleftback19/helsagrace/blob/main/components/admin/collection-editor.tsx"
click node_controls "https://github.com/celebrityleftback19/helsagrace/blob/main/components/admin/controls.tsx"
click node_adminactions "https://github.com/celebrityleftback19/helsagrace/blob/main/app/admin/actions.ts"
click node_adminauth "https://github.com/celebrityleftback19/helsagrace/blob/main/lib/supabase/server.ts"
click node_admindata "https://github.com/celebrityleftback19/helsagrace/blob/main/lib/admin-data.ts"
click node_adminui "https://github.com/celebrityleftback19/helsagrace/blob/main/components/admin/ui.tsx"
click node_contactform "https://github.com/celebrityleftback19/helsagrace/blob/main/components/contact-form.tsx"
click node_contactroute "https://github.com/celebrityleftback19/helsagrace/blob/main/app/api/contact/route.ts"
click node_contactservice "https://github.com/celebrityleftback19/helsagrace/blob/main/lib/contact.ts"
click node_intro "https://github.com/celebrityleftback19/helsagrace/blob/main/components/intro/intro-provider.tsx"
click node_scroll "https://github.com/celebrityleftback19/helsagrace/blob/main/components/motion/smooth-scroll.tsx"
click node_reveal "https://github.com/celebrityleftback19/helsagrace/blob/main/components/reveal.tsx"
click node_tag "https://github.com/celebrityleftback19/helsagrace/blob/main/components/tag.tsx"
click node_icons "https://github.com/celebrityleftback19/helsagrace/blob/main/lib/icons.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_hero,node_work,node_capabilities,node_process,node_stack,node_about,node_contactsection,node_caseimage,node_drawer,node_tag,node_icons toneBlue
class node_contentmodel,node_cms,node_supabase,node_settings toneAmber
class node_adminpages,node_editors,node_controls,node_adminactions,node_adminauth,node_admindata,node_adminui toneMint
class node_contactform,node_contactroute,node_contactservice,node_resend toneRose
class node_intro,node_scroll,node_reveal,node_visitor,node_adminuser toneIndigo
```

## Components

### Public portfolio

- [Portfolio page](https://github.com/celebrityleftback19/helsagrace/blob/main/app/page.tsx): `app/page.tsx`
- [Hero](https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/hero.tsx): `components/sections/hero.tsx`
- [Project work](https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/work-section.tsx): `components/sections/work-section.tsx`
- [Capabilities](https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/capabilities-section.tsx): `components/sections/capabilities-section.tsx`
- [Process](https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/process-section.tsx): `components/sections/process-section.tsx`
- [Technology stack](https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/stack-section.tsx): `components/sections/stack-section.tsx`
- [About and stats](https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/about-section.tsx): `components/sections/about-section.tsx`
- [Contact section](https://github.com/celebrityleftback19/helsagrace/blob/main/components/sections/contact-section.tsx): `components/sections/contact-section.tsx`
- [Case images](https://github.com/celebrityleftback19/helsagrace/blob/main/components/case-image.tsx): `components/case-image.tsx`
- [Case study drawer](https://github.com/celebrityleftback19/helsagrace/blob/main/components/project-drawer.tsx): `components/project-drawer.tsx`
- [Project tags](https://github.com/celebrityleftback19/helsagrace/blob/main/components/tag.tsx): `components/tag.tsx`
- [Icon resolver](https://github.com/celebrityleftback19/helsagrace/blob/main/lib/icons.ts): `lib/icons.ts`

### Content services

- [Content model and defaults](https://github.com/celebrityleftback19/helsagrace/blob/main/lib/content.ts): `lib/content.ts`
- [Content reader](https://github.com/celebrityleftback19/helsagrace/blob/main/lib/cms.ts): `lib/cms.ts`
- **Supabase content store**
- [Supabase configuration](https://github.com/celebrityleftback19/helsagrace/blob/main/lib/supabase/env.ts): `lib/supabase/env.ts`

### Content administration

- [Admin pages](https://github.com/celebrityleftback19/helsagrace/tree/main/app/admin/(dashboard)): `app/admin/(dashboard)`
- [Content editors](https://github.com/celebrityleftback19/helsagrace/blob/main/components/admin/collection-editor.tsx): `components/admin/collection-editor.tsx`
- [Editor controls](https://github.com/celebrityleftback19/helsagrace/blob/main/components/admin/controls.tsx): `components/admin/controls.tsx`
- [Admin actions](https://github.com/celebrityleftback19/helsagrace/blob/main/app/admin/actions.ts): `app/admin/actions.ts`
- [Session and owner checks](https://github.com/celebrityleftback19/helsagrace/blob/main/lib/supabase/server.ts): `lib/supabase/server.ts`
- [History, messages, media](https://github.com/celebrityleftback19/helsagrace/blob/main/lib/admin-data.ts): `lib/admin-data.ts`
- [Admin UI primitives](https://github.com/celebrityleftback19/helsagrace/blob/main/components/admin/ui.tsx): `components/admin/ui.tsx`

### Contact enquiries

- [Contact form](https://github.com/celebrityleftback19/helsagrace/blob/main/components/contact-form.tsx): `components/contact-form.tsx`
- [Contact API route](https://github.com/celebrityleftback19/helsagrace/blob/main/app/api/contact/route.ts): `app/api/contact/route.ts`
- [Contact validation](https://github.com/celebrityleftback19/helsagrace/blob/main/lib/contact.ts): `lib/contact.ts`
- **Resend email**

### Motion and interaction

- [Intro experience](https://github.com/celebrityleftback19/helsagrace/blob/main/components/intro/intro-provider.tsx): `components/intro/intro-provider.tsx`
- [Smooth scrolling](https://github.com/celebrityleftback19/helsagrace/blob/main/components/motion/smooth-scroll.tsx): `components/motion/smooth-scroll.tsx`
- [Scroll reveal](https://github.com/celebrityleftback19/helsagrace/blob/main/components/reveal.tsx): `components/reveal.tsx`

### Other components

- **Visitor**
- **Portfolio owner**

## Connections

- Visitor → Portfolio page: visits (evidence: `README.md`)
- Portfolio page → Content reader: loads content (evidence: `app/page.tsx`)
- Portfolio page → Intro experience: wraps page (evidence: `app/page.tsx`)
- Portfolio page → Hero: renders (evidence: `app/page.tsx`)
- Portfolio page → Project work: renders (evidence: `app/page.tsx`)
- Portfolio page → Capabilities: renders (evidence: `app/page.tsx`)
- Portfolio page → Process: renders (evidence: `app/page.tsx`)
- Portfolio page → Technology stack: renders (evidence: `app/page.tsx`)
- Portfolio page → About and stats: renders (evidence: `app/page.tsx`)
- Portfolio page → Contact section: renders (evidence: `app/page.tsx`)
- Content reader → Content model and defaults: merges defaults (evidence: `lib/cms.ts`)
- Content reader → Supabase configuration: checks configuration (evidence: `lib/cms.ts`)
- Content reader → Supabase content store: reads content (evidence: `lib/cms.ts`)
- Project work → Case study drawer: opens case study (evidence: `components/sections/work-section.tsx`)
- Capabilities → Case study drawer: opens proof project (evidence: `components/sections/capabilities-section.tsx`)
- Case study drawer → Case images: renders screenshots (evidence: `components/project-drawer.tsx`)
- Case study drawer → Project tags: renders tags (evidence: `components/project-drawer.tsx`)
- Hero → Smooth scrolling: uses scrolling (evidence: `components/sections/hero.tsx`)
- Intro experience → Smooth scrolling: uses scrolling (evidence: `components/intro/intro-provider.tsx`)
- Capabilities → Icon resolver: resolves icons (evidence: `components/sections/capabilities-section.tsx`)
- Portfolio owner → Admin pages: manages content (evidence: `README.md`)
- Admin pages → Content editors: uses editors (evidence: `app/admin/(dashboard)/capabilities/page.tsx`)
- Content editors → Editor controls: uses controls (evidence: `components/admin/collection-editor.tsx`)
- Content editors → Admin UI primitives: uses primitives (evidence: `components/admin/collection-editor.tsx`)
- Content editors → Admin actions: saves content (evidence: `components/admin/collection-editor.tsx`)
- Admin actions → Session and owner checks: checks owner (evidence: `app/admin/actions.ts`)
- Admin actions → Content reader: reads content (evidence: `app/admin/actions.ts`)
- Admin actions → Supabase content store: writes content (evidence: `app/admin/actions.ts`)
- Admin actions → History, messages, media: restores and lists (evidence: `app/admin/actions.ts`)
- Session and owner checks → Supabase content store: checks session (evidence: `lib/supabase/server.ts`)
- History, messages, media → Supabase content store: reads admin data (evidence: `lib/admin-data.ts`)
- Contact form → Contact API route: posts enquiry (evidence: `README.md`)
- Contact API route → Contact validation: validates input (evidence: `app/api/contact/route.ts`)
- Contact API route → Resend email: sends email (evidence: `README.md`)
