# yomileonel/cvforyou architecture

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

- Interactive diagram: https://gitdiagram.com/yomileonel/cvforyou
- Repository: https://github.com/yomileonel/cvforyou

## Overview

CVforYou is a private resume builder. Users register or sign in, create or open a resume, edit its sections and design with a live preview, and export it as a PDF; they can also request an AI job match. Resume data and photos use Supabase, while matching uses OpenAI. The README also documents a 14-template gallery and multilingual UI. Some subsystem details are unsampled, so edges reflect only shown calls or README-documented capabilities.

Main entry points: [`app/(app)/editor/editor-client.tsx`](https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/editor-client.tsx) (Editor orchestration), [`app/(app)/dashboard/page.tsx`](https://github.com/yomileonel/cvforyou/blob/main/app/(app)/dashboard/page.tsx) (Resume dashboard), [`app/api/resumes/[id]/pdf/route.ts`](https://github.com/yomileonel/cvforyou/blob/main/app/api/resumes/%5Bid%5D/pdf/route.ts) (PDF export route), [`app/lib/templates.ts`](https://github.com/yomileonel/cvforyou/blob/main/app/lib/templates.ts) (Template catalogue)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Entry and access"]
  node_auth_pages["Login and registration<br/>[login-form.tsx]"]
  node_auth_actions["Authentication actions<br/>[auth-actions.ts]"]
  node_dashboard["Resume dashboard<br/>[page.tsx]"]
end

subgraph group_resume["Resume authoring"]
  node_editor["Editor orchestration<br/>[editor-client.tsx]"]
  node_section_form["Section editing<br/>[section-form.tsx]"]
  node_photo_upload["Photo upload<br/>[photo-upload.tsx]"]
  node_section_nav["Section navigation<br/>[section-nav.tsx]"]
  node_preview["Live resume preview<br/>[resume-preview.tsx]"]
  node_templates["Template catalogue<br/>[templates.ts]"]
end

subgraph group_services["Resume services"]
  node_resume_actions["Resume save actions<br/>[resume-actions.ts]"]
  node_resume_repo["Resume persistence<br/>[resumes.ts]"]
  node_supabase[("Supabase Auth, database, storage<br/>[server.ts]")]
  node_pdf_route["PDF export route<br/>[route.ts]"]
  node_html_renderer["Resume HTML renderer"]
  node_pdf_renderer["PDF renderer<br/>[render-pdf.ts]"]
  node_match_actions["Job-match actions<br/>[match-actions.ts]"]
  node_match_client["AI match client<br/>[openai-client.ts]"]
end

subgraph group_discovery["Public experience"]
  node_landing["Landing page<br/>[page.tsx]"]
  node_template_gallery["Template gallery"]
  node_i18n["Locale dictionaries<br/>[get-dictionary.ts]"]
end

node_visitor(("Visitor / user"))
node_openai["OpenAI API"]

node_visitor -->|"signs in"| node_auth_pages
node_auth_pages -->|"submits credentials"| node_auth_actions
node_auth_actions -->|"authenticates via"| node_supabase
node_visitor -->|"opens resumes"| node_dashboard
node_dashboard -->|"loads resumes"| node_resume_repo
node_dashboard -->|"offers templates"| node_templates
node_dashboard -->|"opens editor"| node_editor
node_editor -->|"renders editor form"| node_section_form
node_section_form -->|"renders uploader"| node_photo_upload
node_editor -->|"renders navigation"| node_section_nav
node_editor -->|"renders preview"| node_preview
node_editor -->|"selects design"| node_templates
node_editor -->|"auto-saves changes"| node_resume_actions
node_resume_actions -->|"writes resume"| node_supabase
node_resume_repo -->|"reads and writes"| node_supabase
node_editor -->|"requests PDF"| node_pdf_route
node_pdf_route -->|"loads resume"| node_resume_repo
node_pdf_route -->|"renders resume HTML"| node_html_renderer
node_pdf_route -->|"converts HTML to PDF"| node_pdf_renderer
node_html_renderer -->|"uses template definitions"| node_templates
node_editor -->|"requests job match"| node_match_actions
node_match_actions -->|"runs comparison"| node_match_client
node_match_actions -->|"checks user quota"| node_supabase
node_match_client -->|"sends match request"| node_openai
node_visitor -->|"discovers product"| node_landing
node_landing -->|"links to gallery"| node_template_gallery
node_template_gallery -->|"displays templates"| node_templates
node_landing -->|"loads localized content"| node_i18n
node_editor -->|"uses translated labels"| node_i18n

click node_auth_pages "https://github.com/yomileonel/cvforyou/blob/main/app/(auth)/login/login-form.tsx"
click node_auth_actions "https://github.com/yomileonel/cvforyou/blob/main/app/lib/auth-actions.ts"
click node_dashboard "https://github.com/yomileonel/cvforyou/blob/main/app/(app)/dashboard/page.tsx"
click node_editor "https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/editor-client.tsx"
click node_section_form "https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/section-form.tsx"
click node_photo_upload "https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/photo-upload.tsx"
click node_section_nav "https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/section-nav.tsx"
click node_preview "https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/resume-preview.tsx"
click node_templates "https://github.com/yomileonel/cvforyou/blob/main/app/lib/templates.ts"
click node_resume_actions "https://github.com/yomileonel/cvforyou/blob/main/app/lib/resume-actions.ts"
click node_resume_repo "https://github.com/yomileonel/cvforyou/blob/main/app/lib/resumes.ts"
click node_supabase "https://github.com/yomileonel/cvforyou/blob/main/app/lib/supabase/server.ts"
click node_pdf_route "https://github.com/yomileonel/cvforyou/blob/main/app/api/resumes/%5Bid%5D/pdf/route.ts"
click node_html_renderer "https://github.com/yomileonel/cvforyou/blob/main/app/lib/pdf/render-resume-html.ts"
click node_pdf_renderer "https://github.com/yomileonel/cvforyou/blob/main/app/lib/pdf/render-pdf.ts"
click node_match_actions "https://github.com/yomileonel/cvforyou/blob/main/app/lib/match-actions.ts"
click node_match_client "https://github.com/yomileonel/cvforyou/blob/main/app/lib/match/openai-client.ts"
click node_landing "https://github.com/yomileonel/cvforyou/blob/main/app/page.tsx"
click node_template_gallery "https://github.com/yomileonel/cvforyou/blob/main/app/vorlagen/template-gallery.tsx"
click node_i18n "https://github.com/yomileonel/cvforyou/blob/main/app/lib/i18n/get-dictionary.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_auth_pages,node_auth_actions,node_dashboard,node_visitor toneBlue
class node_editor,node_section_form,node_photo_upload,node_section_nav,node_preview,node_templates toneAmber
class node_resume_actions,node_resume_repo,node_supabase,node_pdf_route,node_html_renderer,node_pdf_renderer,node_match_actions,node_match_client,node_openai toneMint
class node_landing,node_template_gallery,node_i18n toneRose
```

## Components

### Entry and access

- [Login and registration](https://github.com/yomileonel/cvforyou/blob/main/app/(auth)/login/login-form.tsx): `app/(auth)/login/login-form.tsx`
- [Authentication actions](https://github.com/yomileonel/cvforyou/blob/main/app/lib/auth-actions.ts): `app/lib/auth-actions.ts`
- [Resume dashboard](https://github.com/yomileonel/cvforyou/blob/main/app/(app)/dashboard/page.tsx): `app/(app)/dashboard/page.tsx`

### Resume authoring

- [Editor orchestration](https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/editor-client.tsx): `app/(app)/editor/editor-client.tsx`
- [Section editing](https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/section-form.tsx): `app/(app)/editor/section-form.tsx`
- [Photo upload](https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/photo-upload.tsx): `app/(app)/editor/photo-upload.tsx`
- [Section navigation](https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/section-nav.tsx): `app/(app)/editor/section-nav.tsx`
- [Live resume preview](https://github.com/yomileonel/cvforyou/blob/main/app/(app)/editor/resume-preview.tsx): `app/(app)/editor/resume-preview.tsx`
- [Template catalogue](https://github.com/yomileonel/cvforyou/blob/main/app/lib/templates.ts): `app/lib/templates.ts`

### Resume services

- [Resume save actions](https://github.com/yomileonel/cvforyou/blob/main/app/lib/resume-actions.ts): `app/lib/resume-actions.ts`
- [Resume persistence](https://github.com/yomileonel/cvforyou/blob/main/app/lib/resumes.ts): `app/lib/resumes.ts`
- [Supabase Auth, database, storage](https://github.com/yomileonel/cvforyou/blob/main/app/lib/supabase/server.ts): `app/lib/supabase/server.ts`
- [PDF export route](https://github.com/yomileonel/cvforyou/blob/main/app/api/resumes/%5Bid%5D/pdf/route.ts): `app/api/resumes/[id]/pdf/route.ts`
- [Resume HTML renderer](https://github.com/yomileonel/cvforyou/blob/main/app/lib/pdf/render-resume-html.ts): `app/lib/pdf/render-resume-html.ts`
- [PDF renderer](https://github.com/yomileonel/cvforyou/blob/main/app/lib/pdf/render-pdf.ts): `app/lib/pdf/render-pdf.ts`
- [Job-match actions](https://github.com/yomileonel/cvforyou/blob/main/app/lib/match-actions.ts): `app/lib/match-actions.ts`
- [AI match client](https://github.com/yomileonel/cvforyou/blob/main/app/lib/match/openai-client.ts): `app/lib/match/openai-client.ts`

### Public experience

- [Landing page](https://github.com/yomileonel/cvforyou/blob/main/app/page.tsx): `app/page.tsx`
- [Template gallery](https://github.com/yomileonel/cvforyou/blob/main/app/vorlagen/template-gallery.tsx): `app/vorlagen/template-gallery.tsx`
- [Locale dictionaries](https://github.com/yomileonel/cvforyou/blob/main/app/lib/i18n/get-dictionary.ts): `app/lib/i18n/get-dictionary.ts`

### Other components

- **Visitor / user**
- **OpenAI API**

## Connections

- Visitor / user → Login and registration: signs in
- Login and registration → Authentication actions: submits credentials (evidence: `app/(auth)/login/login-form.tsx`)
- Authentication actions → Supabase Auth, database, storage: authenticates via (evidence: `app/lib/auth-actions.ts`)
- Visitor / user → Resume dashboard: opens resumes (evidence: `app/(app)/dashboard/page.tsx`)
- Resume dashboard → Resume persistence: loads resumes (evidence: `app/(app)/dashboard/page.tsx`)
- Resume dashboard → Template catalogue: offers templates (evidence: `app/(app)/dashboard/page.tsx`)
- Resume dashboard → Editor orchestration: opens editor
- Editor orchestration → Section editing: renders editor form (evidence: `app/(app)/editor/editor-client.tsx`)
- Section editing → Photo upload: renders uploader (evidence: `app/(app)/editor/section-form.tsx`)
- Editor orchestration → Section navigation: renders navigation (evidence: `app/(app)/editor/editor-client.tsx`)
- Editor orchestration → Live resume preview: renders preview (evidence: `app/(app)/editor/editor-client.tsx`)
- Editor orchestration → Template catalogue: selects design (evidence: `app/(app)/editor/editor-client.tsx`)
- Editor orchestration → Resume save actions: auto-saves changes (evidence: `app/(app)/editor/editor-client.tsx`)
- Resume save actions → Supabase Auth, database, storage: writes resume (evidence: `app/lib/resume-actions.ts`)
- Resume persistence → Supabase Auth, database, storage: reads and writes (evidence: `app/lib/resumes.ts`)
- Editor orchestration → PDF export route: requests PDF (evidence: `app/(app)/editor/editor-client.tsx`)
- PDF export route → Resume persistence: loads resume (evidence: `app/api/resumes/[id]/pdf/route.ts`)
- PDF export route → Resume HTML renderer: renders resume HTML (evidence: `app/api/resumes/[id]/pdf/route.ts`)
- PDF export route → PDF renderer: converts HTML to PDF (evidence: `app/api/resumes/[id]/pdf/route.ts`)
- Resume HTML renderer → Template catalogue: uses template definitions (evidence: `app/lib/pdf/render-resume-html.ts`)
- Editor orchestration → Job-match actions: requests job match (evidence: `app/(app)/editor/editor-client.tsx`)
- Job-match actions → AI match client: runs comparison (evidence: `app/lib/match-actions.ts`)
- Job-match actions → Supabase Auth, database, storage: checks user quota (evidence: `app/lib/match-actions.ts`)
- AI match client → OpenAI API: sends match request (evidence: `app/lib/match/openai-client.ts`)
- Visitor / user → Landing page: discovers product (evidence: `app/page.tsx`)
- Landing page → Template gallery: links to gallery (evidence: `app/page.tsx`)
- Template gallery → Template catalogue: displays templates (evidence: `app/vorlagen/template-gallery.tsx`)
- Landing page → Locale dictionaries: loads localized content
- Editor orchestration → Locale dictionaries: uses translated labels (evidence: `app/(app)/editor/editor-client.tsx`)
