# toomuhtsh/maquette-card architecture

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

- Interactive diagram: https://gitdiagram.com/toomuhtsh/maquette-card
- Repository: https://github.com/toomuhtsh/maquette-card

## Overview

Maquette is a Home Assistant Lovelace card and built-in floor-plan editor. Users draw or import a plan, link rooms and objects to Home Assistant entities, save it in dashboard configuration, then view live state and interact with the home. The graph preserves documented capabilities such as floors, ambience, replay, widgets, workshops, sharing, cleanup, and import safety. Relationships for unsampled feature modules are based on README statements; source excerpts do not expose most runtime wiring.

Main entry points: [`src/editeur/classe-coeur.js`](https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-coeur.js) (Plan editor), [`src/carte/classe-coeur.js`](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-coeur.js) (Maquette card), [`src/carte/classe-actions.js`](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-actions.js) (Action confirmation), [`src/carte/classe-ambiance.js`](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-ambiance.js) (Live ambience)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_card["Live card"]
  node_card["Maquette card<br/>[classe-coeur.js]"]
  node_render["Plan renderer"]
  node_ambience["Live ambience<br/>[classe-ambiance.js]"]
  node_light["Window lighting"]
  node_floors["Floor views<br/>[classe-etages.js]"]
  node_replay["Day replay<br/>[classe-replay.js]"]
  node_widgets["Widgets and fiches<br/>[classe-widgets.js]"]
  node_security["Action confirmation<br/>[classe-actions.js]"]
end

subgraph group_editor["Plan editing"]
  node_editor["Plan editor<br/>[classe-coeur.js]"]
  node_drawing["Plan drawing<br/>[classe-dessin.js]"]
  node_entitylink["Entity linking<br/>[classe-entites.js]"]
  node_dialogs["Element dialogs"]
  node_flooredit["Floor editing"]
end

subgraph group_tools["Plan extensions"]
  node_workshops["Object workshops<br/>[classe-atelier.js]"]
  node_catalogue["Widget library"]
  node_sharing["Sharing and templates<br/>[classe-partage.js]"]
  node_importexport["Plan import export"]
  node_cleanup["Plan cleanup"]
end

subgraph group_ha["Home Assistant"]
  node_ha["Home Assistant"]
  node_dashboard[("Dashboard configuration")]
end

node_resident(("Dashboard user"))

node_resident -->|"opens and uses"| node_card
node_resident -->|"edits plan"| node_editor
node_card -.->|"renders plan"| node_render
node_card -->|"shows live effects"| node_ambience
node_ambience -->|"includes window light"| node_light
node_card -->|"selects floor"| node_floors
node_card -->|"replays history"| node_replay
node_card -->|"shows widgets"| node_widgets
node_card -->|"confirms sensitive actions"| node_security
node_ha -->|"provides entity state"| node_card
node_security -->|"invokes services"| node_ha
node_editor -->|"provides drawing tools"| node_drawing
node_editor -->|"links areas and devices"| node_entitylink
node_editor -->|"edits elements"| node_dialogs
node_editor -->|"manages floors"| node_flooredit
node_editor -->|"saves plan"| node_dashboard
node_editor -->|"opens workshops"| node_workshops
node_editor -->|"selects widgets"| node_catalogue
node_editor -->|"shares templates"| node_sharing
node_editor -->|"imports plans"| node_importexport
node_importexport -->|"previews controls"| node_security
node_editor -->|"cleans plan"| node_cleanup

click node_card "https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-coeur.js"
click node_render "https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-rendu-plan.js"
click node_ambience "https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-ambiance.js"
click node_light "https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/ambiance-lumiere.js"
click node_floors "https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-etages.js"
click node_replay "https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-replay.js"
click node_widgets "https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-widgets.js"
click node_security "https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-actions.js"
click node_editor "https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-coeur.js"
click node_drawing "https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-dessin.js"
click node_entitylink "https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-entites.js"
click node_dialogs "https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-modale-edition.js"
click node_flooredit "https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-gestion-etages.js"
click node_workshops "https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-atelier.js"
click node_catalogue "https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-catalogue.js"
click node_sharing "https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-partage.js"
click node_importexport "https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-import-export.js"
click node_cleanup "https://github.com/toomuhtsh/maquette-card/blob/main/src/maquette-nettoyage.js"

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_card,node_render,node_ambience,node_light,node_floors,node_replay,node_widgets,node_security,node_resident toneBlue
class node_editor,node_drawing,node_entitylink,node_dialogs,node_flooredit toneAmber
class node_workshops,node_catalogue,node_sharing,node_importexport,node_cleanup toneMint
class node_ha,node_dashboard toneRose
```

## Components

### Live card

- [Maquette card](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-coeur.js): `src/carte/classe-coeur.js`
- [Plan renderer](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-rendu-plan.js): `src/carte/classe-rendu-plan.js`
- [Live ambience](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-ambiance.js): `src/carte/classe-ambiance.js`
- [Window lighting](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/ambiance-lumiere.js): `src/carte/ambiance-lumiere.js`
- [Floor views](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-etages.js): `src/carte/classe-etages.js`
- [Day replay](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-replay.js): `src/carte/classe-replay.js`
- [Widgets and fiches](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-widgets.js): `src/carte/classe-widgets.js`
- [Action confirmation](https://github.com/toomuhtsh/maquette-card/blob/main/src/carte/classe-actions.js): `src/carte/classe-actions.js`

### Plan editing

- [Plan editor](https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-coeur.js): `src/editeur/classe-coeur.js`
- [Plan drawing](https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-dessin.js): `src/editeur/classe-dessin.js`
- [Entity linking](https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-entites.js): `src/editeur/classe-entites.js`
- [Element dialogs](https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-modale-edition.js): `src/editeur/classe-modale-edition.js`
- [Floor editing](https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-gestion-etages.js): `src/editeur/classe-gestion-etages.js`

### Plan extensions

- [Object workshops](https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-atelier.js): `src/editeur/classe-atelier.js`
- [Widget library](https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-catalogue.js): `src/editeur/classe-catalogue.js`
- [Sharing and templates](https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-partage.js): `src/editeur/classe-partage.js`
- [Plan import export](https://github.com/toomuhtsh/maquette-card/blob/main/src/editeur/classe-import-export.js): `src/editeur/classe-import-export.js`
- [Plan cleanup](https://github.com/toomuhtsh/maquette-card/blob/main/src/maquette-nettoyage.js): `src/maquette-nettoyage.js`

### Home Assistant

- **Home Assistant**
- **Dashboard configuration**

### Other components

- **Dashboard user**

## Connections

- Dashboard user → Maquette card: opens and uses
- Dashboard user → Plan editor: edits plan
- Maquette card → Plan renderer: renders plan
- Maquette card → Live ambience: shows live effects
- Live ambience → Window lighting: includes window light
- Maquette card → Floor views: selects floor
- Maquette card → Day replay: replays history
- Maquette card → Widgets and fiches: shows widgets
- Maquette card → Action confirmation: confirms sensitive actions
- Home Assistant → Maquette card: provides entity state
- Action confirmation → Home Assistant: invokes services
- Plan editor → Plan drawing: provides drawing tools
- Plan editor → Entity linking: links areas and devices
- Plan editor → Element dialogs: edits elements
- Plan editor → Floor editing: manages floors
- Plan editor → Dashboard configuration: saves plan
- Plan editor → Object workshops: opens workshops
- Plan editor → Widget library: selects widgets
- Plan editor → Sharing and templates: shares templates
- Plan editor → Plan import export: imports plans
- Plan import export → Action confirmation: previews controls
- Plan editor → Plan cleanup: cleans plan
