# kwaaya/nonesi-lodge architecture

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

- Interactive diagram: https://gitdiagram.com/kwaaya/nonesi-lodge
- Repository: https://github.com/kwaaya/nonesi-lodge

## Overview

Nonesi Lodge combines a public accommodation website with a browser-based admin portal, plus a reusable hospitality-site template. The guest journey is to review lodge and room information, then use the site’s contact or booking options; the admin portal provides dashboard, room, gallery, inquiry, and settings areas. The demo data helper stores those records in localStorage. Supabase authentication and database support are documented as scaffolding, not active integration. Page-level implementation excerpts were not provided, so links involving page behavior are limited to documented relationships.

Main entry points: [`admin/js/demo-data.js`](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/js/demo-data.js) (Demo data CRUD), [`admin/js/admin-shell.js`](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/js/admin-shell.js) (Shared admin shell), [`admin/rooms.html`](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/rooms.html) (Room management), [`admin/gallery.html`](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/gallery.html) (Gallery management)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_public["Guest website"]
  node_lodge_site["Lodge website<br/>[index.html]"]
end

subgraph group_admin["Admin portal"]
  node_admin_login["Admin login<br/>[login.html]"]
  node_dashboard["Dashboard<br/>[index.html]"]
  node_room_admin["Room management<br/>[rooms.html]"]
  node_gallery_admin["Gallery management<br/>[gallery.html]"]
  node_inquiry_admin["Inquiry management<br/>[inquiries.html]"]
  node_settings_admin["Lodge settings<br/>[settings.html]"]
  node_shell["Shared admin shell<br/>[admin-shell.js]"]
end

subgraph group_data["Admin data and auth"]
  node_demo_data["Demo data CRUD<br/>[demo-data.js]"]
  node_supabase_auth["Supabase auth scaffold<br/>[supabase.js]"]
  node_local_storage[("Browser localStorage")]
end

subgraph group_template["Site template"]
  node_site_config["Lodge content<br/>[config.js]"]
  node_template_site["Template website<br/>[index.html]"]
end

node_guest(("Guest"))
node_admin_user(("Lodge administrator"))
node_supabase_service[("Supabase service")]

node_guest -->|"views"| node_lodge_site
node_lodge_site -.->|"uses content"| node_site_config
node_admin_user -->|"signs in"| node_admin_login
node_admin_user -->|"manages lodge"| node_dashboard
node_dashboard -->|"uses shared shell"| node_shell
node_room_admin -->|"uses shared shell"| node_shell
node_gallery_admin -->|"uses shared shell"| node_shell
node_inquiry_admin -->|"uses shared shell"| node_shell
node_settings_admin -->|"uses shared shell"| node_shell
node_room_admin -.->|"CRUD records"| node_demo_data
node_gallery_admin -.->|"CRUD records"| node_demo_data
node_inquiry_admin -.->|"CRUD records"| node_demo_data
node_settings_admin -.->|"CRUD records"| node_demo_data
node_demo_data -->|"reads and writes"| node_local_storage
node_admin_login -.->|"auth scaffold"| node_supabase_auth
node_supabase_auth -.->|"auth and data"| node_supabase_service
node_template_site -.->|"configured by"| node_site_config

click node_lodge_site "https://github.com/kwaaya/nonesi-lodge/blob/main/index.html"
click node_site_config "https://github.com/kwaaya/nonesi-lodge/blob/main/template/config.js"
click node_admin_login "https://github.com/kwaaya/nonesi-lodge/blob/main/admin/login.html"
click node_dashboard "https://github.com/kwaaya/nonesi-lodge/blob/main/admin/index.html"
click node_room_admin "https://github.com/kwaaya/nonesi-lodge/blob/main/admin/rooms.html"
click node_gallery_admin "https://github.com/kwaaya/nonesi-lodge/blob/main/admin/gallery.html"
click node_inquiry_admin "https://github.com/kwaaya/nonesi-lodge/blob/main/admin/inquiries.html"
click node_settings_admin "https://github.com/kwaaya/nonesi-lodge/blob/main/admin/settings.html"
click node_shell "https://github.com/kwaaya/nonesi-lodge/blob/main/admin/js/admin-shell.js"
click node_demo_data "https://github.com/kwaaya/nonesi-lodge/blob/main/admin/js/demo-data.js"
click node_supabase_auth "https://github.com/kwaaya/nonesi-lodge/blob/main/admin/js/supabase.js"
click node_template_site "https://github.com/kwaaya/nonesi-lodge/blob/main/template/index.html"

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_lodge_site toneBlue
class node_admin_login,node_dashboard,node_room_admin,node_gallery_admin,node_inquiry_admin,node_settings_admin,node_shell,node_supabase_service toneAmber
class node_demo_data,node_supabase_auth,node_local_storage toneMint
class node_site_config,node_template_site toneRose
class node_guest,node_admin_user toneIndigo
```

## Components

### Guest website

- [Lodge website](https://github.com/kwaaya/nonesi-lodge/blob/main/index.html): `index.html`

### Admin portal

- [Admin login](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/login.html): `admin/login.html`
- [Dashboard](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/index.html): `admin/index.html`
- [Room management](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/rooms.html): `admin/rooms.html`
- [Gallery management](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/gallery.html): `admin/gallery.html`
- [Inquiry management](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/inquiries.html): `admin/inquiries.html`
- [Lodge settings](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/settings.html): `admin/settings.html`
- [Shared admin shell](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/js/admin-shell.js): `admin/js/admin-shell.js`

### Admin data and auth

- [Demo data CRUD](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/js/demo-data.js): `admin/js/demo-data.js`
- [Supabase auth scaffold](https://github.com/kwaaya/nonesi-lodge/blob/main/admin/js/supabase.js): `admin/js/supabase.js`
- **Browser localStorage**

### Site template

- [Lodge content](https://github.com/kwaaya/nonesi-lodge/blob/main/template/config.js): `template/config.js`
- [Template website](https://github.com/kwaaya/nonesi-lodge/blob/main/template/index.html): `template/index.html`

### Other components

- **Guest**
- **Lodge administrator**
- **Supabase service**

## Connections

- Guest → Lodge website: views (evidence: `README.md`)
- Lodge website → Lodge content: uses content
- Lodge administrator → Admin login: signs in (evidence: `README.md`)
- Lodge administrator → Dashboard: manages lodge (evidence: `README.md`)
- Dashboard → Shared admin shell: uses shared shell (evidence: `README.md`)
- Room management → Shared admin shell: uses shared shell (evidence: `README.md`)
- Gallery management → Shared admin shell: uses shared shell (evidence: `README.md`)
- Inquiry management → Shared admin shell: uses shared shell (evidence: `README.md`)
- Lodge settings → Shared admin shell: uses shared shell (evidence: `README.md`)
- Room management → Demo data CRUD: CRUD records
- Gallery management → Demo data CRUD: CRUD records
- Inquiry management → Demo data CRUD: CRUD records
- Lodge settings → Demo data CRUD: CRUD records
- Demo data CRUD → Browser localStorage: reads and writes (evidence: `admin/js/demo-data.js`)
- Admin login → Supabase auth scaffold: auth scaffold
- Supabase auth scaffold → Supabase service: auth and data (evidence: `admin/js/supabase.js`)
- Template website → Lodge content: configured by
