# veneziarestaurant/venezia architecture

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

- Interactive diagram: https://gitdiagram.com/veneziarestaurant/venezia
- Repository: https://github.com/veneziarestaurant/venezia

## Overview

Venezia is a multilingual static restaurant website and digital menu, maintained through a local Keystatic admin. The main visitor flow is browsing and filtering dishes, checking restaurant details, then reserving through WhatsApp; editors save menu/site data and images locally, publish them through the admin widget, and GitHub Pages rebuilds the site. The graph includes documented capabilities and the sampled content, publishing, and interaction layers. Several page/component implementations were not sampled, so their links rely on README statements rather than inspected calls.

Main entry points: [`src/pages`](https://github.com/veneziarestaurant/venezia/tree/main/src/pages) (Localized home pages), [`src/lib/content.ts`](https://github.com/veneziarestaurant/venezia/blob/main/src/lib/content.ts) (Content and images), [`src/scripts/app.ts`](https://github.com/veneziarestaurant/venezia/blob/main/src/scripts/app.ts) (Browser interactions), [`keystatic.config.ts`](https://github.com/veneziarestaurant/venezia/blob/main/keystatic.config.ts) (Keystatic admin)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_admin["Content Admin"]
  node_keystatic["Keystatic admin"]
  node_publish_widget["Publish widget<br/>[PublishButton.tsx]"]
end

subgraph group_content["Restaurant Content"]
  node_menu_data["Menu data"]
  node_site_data["Restaurant settings<br/>[site.json]"]
  node_images["Restaurant imagery"]
end

subgraph group_site["Public Website"]
  node_home["Localized home pages"]
  node_menu_view["Menu display<br/>[Menu.astro]"]
  node_dish_view["Dish cards<br/>[DishItem.astro]"]
  node_home_sections["Restaurant sections<br/>[Sections.astro]"]
  node_reservation["Reservation dialog"]
  node_legal["Legal pages<br/>[LegalPage.astro]"]
  node_qr["Printable QR code<br/>[qr.astro]"]
  node_layout["Shared layout<br/>[Layout.astro]"]
end

subgraph group_internal["Site Runtime"]
  node_interaction["Browser interactions<br/>[app.ts]"]
  node_content_lib["Content and images<br/>[content.ts]"]
  node_allergens["Allergen definitions<br/>[allergens.ts]"]
  node_translations["UI translations<br/>[ui.ts]"]
end

subgraph group_publish["Publishing"]
  node_publish_api["Local publish API<br/>[publish-plugin.mjs]"]
end

node_editor(("Restaurant editor"))
node_visitor(("Site visitor"))
node_git_remote[("GitHub repository")]
node_pages_host["GitHub Pages"]
node_whatsapp["WhatsApp"]

node_editor -->|"edits content"| node_keystatic
node_keystatic -->|"saves menu"| node_menu_data
node_keystatic -->|"saves settings"| node_site_data
node_keystatic -->|"uploads images"| node_images
node_keystatic -->|"mounts widget"| node_publish_widget
node_editor -->|"publishes changes"| node_publish_widget
node_publish_widget -->|"requests publish"| node_publish_api
node_publish_api -->|"commits and pushes"| node_git_remote
node_git_remote -->|"triggers site build"| node_pages_host
node_visitor -->|"opens site"| node_home
node_home -.->|"uses shared shell"| node_layout
node_home -->|"presents menu"| node_menu_view
node_home -->|"presents restaurant details"| node_home_sections
node_home -->|"offers legal pages"| node_legal
node_home -->|"offers printable code"| node_qr
node_menu_view -.->|"shows dishes"| node_dish_view
node_menu_view -->|"supports search and filters"| node_interaction
node_dish_view -.->|"opens allergen details"| node_interaction
node_home_sections -->|"updates open status"| node_interaction
node_reservation -->|"handles reservation form"| node_interaction
node_interaction -->|"opens message link"| node_whatsapp
node_menu_view -.->|"loads menu content"| node_content_lib
node_content_lib -->|"reads menu files"| node_menu_data
node_content_lib -->|"reads restaurant settings"| node_site_data
node_content_lib -->|"resolves dish images"| node_images
node_content_lib -->|"uses allergen types"| node_allergens
node_content_lib -->|"uses language type"| node_translations
node_interaction -.->|"uses reservation settings"| node_site_data

click node_keystatic "https://github.com/veneziarestaurant/venezia/blob/main/keystatic.config.ts"
click node_publish_widget "https://github.com/veneziarestaurant/venezia/blob/main/src/admin/PublishButton.tsx"
click node_menu_data "https://github.com/veneziarestaurant/venezia/tree/main/src/content/menu"
click node_site_data "https://github.com/veneziarestaurant/venezia/blob/main/src/content/site.json"
click node_images "https://github.com/veneziarestaurant/venezia/tree/main/src/assets/images"
click node_home "https://github.com/veneziarestaurant/venezia/tree/main/src/pages"
click node_menu_view "https://github.com/veneziarestaurant/venezia/blob/main/src/components/Menu.astro"
click node_dish_view "https://github.com/veneziarestaurant/venezia/blob/main/src/components/DishItem.astro"
click node_home_sections "https://github.com/veneziarestaurant/venezia/blob/main/src/components/Sections.astro"
click node_reservation "https://github.com/veneziarestaurant/venezia/blob/main/src/components/ReservationDialog.astro"
click node_legal "https://github.com/veneziarestaurant/venezia/blob/main/src/components/LegalPage.astro"
click node_qr "https://github.com/veneziarestaurant/venezia/blob/main/src/pages/qr.astro"
click node_interaction "https://github.com/veneziarestaurant/venezia/blob/main/src/scripts/app.ts"
click node_content_lib "https://github.com/veneziarestaurant/venezia/blob/main/src/lib/content.ts"
click node_allergens "https://github.com/veneziarestaurant/venezia/blob/main/src/lib/allergens.ts"
click node_translations "https://github.com/veneziarestaurant/venezia/blob/main/src/i18n/ui.ts"
click node_layout "https://github.com/veneziarestaurant/venezia/blob/main/src/layouts/Layout.astro"
click node_publish_api "https://github.com/veneziarestaurant/venezia/blob/main/scripts/publish-plugin.mjs"

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_keystatic,node_publish_widget toneBlue
class node_menu_data,node_site_data,node_images,node_git_remote toneAmber
class node_home,node_menu_view,node_dish_view,node_home_sections,node_reservation,node_legal,node_qr,node_layout toneMint
class node_interaction,node_content_lib,node_allergens,node_translations toneRose
class node_publish_api,node_editor,node_visitor,node_pages_host,node_whatsapp toneIndigo
```

## Components

### Content Admin

- [Keystatic admin](https://github.com/veneziarestaurant/venezia/blob/main/keystatic.config.ts): `keystatic.config.ts`
- [Publish widget](https://github.com/veneziarestaurant/venezia/blob/main/src/admin/PublishButton.tsx): `src/admin/PublishButton.tsx`

### Restaurant Content

- [Menu data](https://github.com/veneziarestaurant/venezia/tree/main/src/content/menu): `src/content/menu`
- [Restaurant settings](https://github.com/veneziarestaurant/venezia/blob/main/src/content/site.json): `src/content/site.json`
- [Restaurant imagery](https://github.com/veneziarestaurant/venezia/tree/main/src/assets/images): `src/assets/images`

### Public Website

- [Localized home pages](https://github.com/veneziarestaurant/venezia/tree/main/src/pages): `src/pages`
- [Menu display](https://github.com/veneziarestaurant/venezia/blob/main/src/components/Menu.astro): `src/components/Menu.astro`
- [Dish cards](https://github.com/veneziarestaurant/venezia/blob/main/src/components/DishItem.astro): `src/components/DishItem.astro`
- [Restaurant sections](https://github.com/veneziarestaurant/venezia/blob/main/src/components/Sections.astro): `src/components/Sections.astro`
- [Reservation dialog](https://github.com/veneziarestaurant/venezia/blob/main/src/components/ReservationDialog.astro): `src/components/ReservationDialog.astro`
- [Legal pages](https://github.com/veneziarestaurant/venezia/blob/main/src/components/LegalPage.astro): `src/components/LegalPage.astro`
- [Printable QR code](https://github.com/veneziarestaurant/venezia/blob/main/src/pages/qr.astro): `src/pages/qr.astro`
- [Shared layout](https://github.com/veneziarestaurant/venezia/blob/main/src/layouts/Layout.astro): `src/layouts/Layout.astro`

### Site Runtime

- [Browser interactions](https://github.com/veneziarestaurant/venezia/blob/main/src/scripts/app.ts): `src/scripts/app.ts`
- [Content and images](https://github.com/veneziarestaurant/venezia/blob/main/src/lib/content.ts): `src/lib/content.ts`
- [Allergen definitions](https://github.com/veneziarestaurant/venezia/blob/main/src/lib/allergens.ts): `src/lib/allergens.ts`
- [UI translations](https://github.com/veneziarestaurant/venezia/blob/main/src/i18n/ui.ts): `src/i18n/ui.ts`

### Publishing

- [Local publish API](https://github.com/veneziarestaurant/venezia/blob/main/scripts/publish-plugin.mjs): `scripts/publish-plugin.mjs`

### Other components

- **Restaurant editor**
- **Site visitor**
- **GitHub repository**
- **GitHub Pages**
- **WhatsApp**

## Connections

- Restaurant editor → Keystatic admin: edits content (evidence: `README.md`)
- Keystatic admin → Menu data: saves menu (evidence: `keystatic.config.ts`)
- Keystatic admin → Restaurant settings: saves settings (evidence: `keystatic.config.ts`)
- Keystatic admin → Restaurant imagery: uploads images (evidence: `keystatic.config.ts`)
- Keystatic admin → Publish widget: mounts widget (evidence: `keystatic.config.ts`)
- Restaurant editor → Publish widget: publishes changes (evidence: `README.md`)
- Publish widget → Local publish API: requests publish (evidence: `src/admin/PublishButton.tsx`)
- Local publish API → GitHub repository: commits and pushes (evidence: `scripts/publish-plugin.mjs`)
- GitHub repository → GitHub Pages: triggers site build (evidence: `README.md`)
- Site visitor → Localized home pages: opens site (evidence: `README.md`)
- Localized home pages → Shared layout: uses shared shell
- Localized home pages → Menu display: presents menu (evidence: `README.md`)
- Localized home pages → Restaurant sections: presents restaurant details (evidence: `README.md`)
- Localized home pages → Legal pages: offers legal pages (evidence: `README.md`)
- Localized home pages → Printable QR code: offers printable code (evidence: `README.md`)
- Menu display → Dish cards: shows dishes
- Menu display → Browser interactions: supports search and filters (evidence: `README.md`)
- Dish cards → Browser interactions: opens allergen details
- Restaurant sections → Browser interactions: updates open status (evidence: `README.md`)
- Reservation dialog → Browser interactions: handles reservation form (evidence: `src/scripts/app.ts`)
- Browser interactions → WhatsApp: opens message link (evidence: `src/scripts/app.ts`)
- Menu display → Content and images: loads menu content
- Content and images → Menu data: reads menu files (evidence: `src/lib/content.ts`)
- Content and images → Restaurant settings: reads restaurant settings (evidence: `src/lib/content.ts`)
- Content and images → Restaurant imagery: resolves dish images (evidence: `src/lib/content.ts`)
- Content and images → Allergen definitions: uses allergen types (evidence: `src/lib/content.ts`)
- Content and images → UI translations: uses language type (evidence: `src/lib/content.ts`)
- Browser interactions → Restaurant settings: uses reservation settings
