# ahzpokes/fmp-dashboard architecture

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

- Interactive diagram: https://gitdiagram.com/ahzpokes/fmp-dashboard
- Repository: https://github.com/ahzpokes/fmp-dashboard

## Overview

Eurocontrol ACC Performance Dashboard presents traffic and ATFM-delay performance for European control centres. Users select an ACC through its URL or dashboard controls, then explore a global KPI summary and five views: annual summary, annual comparison, cause analysis, weekly focus, and a French-ACC network view. The frontend loads traffic data and uses shared helpers to derive chart series and KPIs. The README identifies a Python ETL; its detailed data handoffs are not shown in the sampled source, so those links are left unverified.

Main entry points: [`src/App.tsx`](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/App.tsx) (Dashboard application), [`src/utils/dataHelpers.ts`](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/utils/dataHelpers.ts) (Data calculations), [`src/components/View2.tsx`](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View2.tsx) (Annual comparison), [`src/components/View3.tsx`](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View3.tsx) (Cause analysis)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_ingest["Data ingestion"]
  node_fetch["Data fetch ETL<br/>[fetch_data.py]"]
  node_extract["Data extraction<br/>[extract.py]"]
end

subgraph group_dataset["Traffic data"]
  node_traffic[("Traffic dataset<br/>[traffic_data.json]")]
  node_reims["Reims CSV data<br/>[reims_annual.csv]"]
  node_daily["Daily CSV data<br/>[reims_daily.csv]"]
end

subgraph group_app["Dashboard experience"]
  node_app["Dashboard application<br/>[App.tsx]"]
  node_manifest["Dynamic PWA identity"]
  node_header["ACC and theme header<br/>[Header.tsx]"]
  node_tabs["View navigation<br/>[Tabs.tsx]"]
  node_footer["Dashboard footer<br/>[Footer.tsx]"]
end

subgraph group_analysis["Performance views"]
  node_kpi["Global KPIs<br/>[KPIGlobal.tsx]"]
  node_view1["Annual summary<br/>[View1.tsx]"]
  node_view2["Annual comparison<br/>[View2.tsx]"]
  node_view3["Cause analysis<br/>[View3.tsx]"]
  node_view4["Weekly focus<br/>[View4.tsx]"]
  node_view5["DSNA network view<br/>[View5.tsx]"]
end

subgraph group_shared["Shared presentation"]
  node_config["ACC configuration<br/>[config.ts]"]
  node_theme["Theme and ACC mapping<br/>[theme.ts]"]
  node_helpers["Data calculations<br/>[dataHelpers.ts]"]
  node_period["Period selector<br/>[PeriodToggle.tsx]"]
  node_legends["Chart legends<br/>[ChartLegends.tsx]"]
end

node_analyst(("Dashboard user"))
node_cdn[("jsDelivr data host")]

node_analyst -->|"selects ACC"| node_app
node_app -->|"sets identity"| node_manifest
node_app -->|"renders"| node_header
node_app -->|"renders"| node_kpi
node_app -->|"renders"| node_tabs
node_app -->|"renders"| node_view1
node_app -->|"renders"| node_view2
node_app -->|"renders"| node_view3
node_app -->|"renders"| node_view4
node_app -->|"renders"| node_view5
node_app -->|"renders"| node_footer
node_app -->|"computes week"| node_helpers
node_app -->|"maps ACC slug"| node_theme
node_app -->|"loads fallback"| node_traffic
node_cdn -.->|"serves data"| node_app
node_app -.->|"uses ACC settings"| node_config
node_kpi -->|"computes metrics"| node_helpers
node_view1 -->|"derives series"| node_helpers
node_view2 -->|"derives series"| node_helpers
node_view3 -->|"derives causes"| node_helpers
node_view4 -->|"derives weeks"| node_helpers
node_view5 -->|"derives network metrics"| node_helpers
node_view2 -->|"renders"| node_period
node_view3 -->|"renders"| node_period
node_view2 -->|"renders"| node_legends
node_view3 -->|"renders"| node_legends
node_view4 -->|"renders"| node_legends
node_header -->|"uses theme"| node_theme
node_fetch -.->|"produces data"| node_traffic
node_extract -.->|"processes data"| node_reims
node_extract -.->|"processes data"| node_daily

click node_fetch "https://github.com/ahzpokes/fmp-dashboard/blob/main/scripts/fetch_data.py"
click node_extract "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/data/extract.py"
click node_traffic "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/data/traffic_data.json"
click node_reims "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/data/reims_annual.csv"
click node_daily "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/data/reims_daily.csv"
click node_app "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/App.tsx"
click node_manifest "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/hooks/useDynamicManifest.ts"
click node_config "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/config.ts"
click node_theme "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/utils/theme.ts"
click node_helpers "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/utils/dataHelpers.ts"
click node_header "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/Header.tsx"
click node_kpi "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/KPIGlobal.tsx"
click node_tabs "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/Tabs.tsx"
click node_view1 "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View1.tsx"
click node_view2 "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View2.tsx"
click node_view3 "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View3.tsx"
click node_view4 "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View4.tsx"
click node_view5 "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View5.tsx"
click node_period "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/PeriodToggle.tsx"
click node_legends "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/ChartLegends.tsx"
click node_footer "https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/Footer.tsx"

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_fetch,node_extract,node_analyst toneBlue
class node_traffic,node_reims,node_daily,node_cdn toneAmber
class node_app,node_manifest,node_header,node_tabs,node_footer toneMint
class node_kpi,node_view1,node_view2,node_view3,node_view4,node_view5 toneRose
class node_config,node_theme,node_helpers,node_period,node_legends toneIndigo
```

## Components

### Data ingestion

- [Data fetch ETL](https://github.com/ahzpokes/fmp-dashboard/blob/main/scripts/fetch_data.py): `scripts/fetch_data.py`
- [Data extraction](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/data/extract.py): `src/data/extract.py`

### Traffic data

- [Traffic dataset](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/data/traffic_data.json): `src/data/traffic_data.json`
- [Reims CSV data](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/data/reims_annual.csv): `src/data/reims_annual.csv`
- [Daily CSV data](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/data/reims_daily.csv): `src/data/reims_daily.csv`

### Dashboard experience

- [Dashboard application](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/App.tsx): `src/App.tsx`
- [Dynamic PWA identity](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/hooks/useDynamicManifest.ts): `src/hooks/useDynamicManifest.ts`
- [ACC and theme header](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/Header.tsx): `src/components/Header.tsx`
- [View navigation](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/Tabs.tsx): `src/components/Tabs.tsx`
- [Dashboard footer](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/Footer.tsx): `src/components/Footer.tsx`

### Performance views

- [Global KPIs](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/KPIGlobal.tsx): `src/components/KPIGlobal.tsx`
- [Annual summary](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View1.tsx): `src/components/View1.tsx`
- [Annual comparison](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View2.tsx): `src/components/View2.tsx`
- [Cause analysis](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View3.tsx): `src/components/View3.tsx`
- [Weekly focus](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View4.tsx): `src/components/View4.tsx`
- [DSNA network view](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/View5.tsx): `src/components/View5.tsx`

### Shared presentation

- [ACC configuration](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/config.ts): `src/config.ts`
- [Theme and ACC mapping](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/utils/theme.ts): `src/utils/theme.ts`
- [Data calculations](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/utils/dataHelpers.ts): `src/utils/dataHelpers.ts`
- [Period selector](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/PeriodToggle.tsx): `src/components/PeriodToggle.tsx`
- [Chart legends](https://github.com/ahzpokes/fmp-dashboard/blob/main/src/components/ChartLegends.tsx): `src/components/ChartLegends.tsx`

### Other components

- **Dashboard user**
- **jsDelivr data host**

## Connections

- Dashboard user → Dashboard application: selects ACC (evidence: `README.md`)
- Dashboard application → Dynamic PWA identity: sets identity (evidence: `src/App.tsx`)
- Dashboard application → ACC and theme header: renders (evidence: `src/App.tsx`)
- Dashboard application → Global KPIs: renders (evidence: `src/App.tsx`)
- Dashboard application → View navigation: renders (evidence: `src/App.tsx`)
- Dashboard application → Annual summary: renders (evidence: `src/App.tsx`)
- Dashboard application → Annual comparison: renders (evidence: `src/App.tsx`)
- Dashboard application → Cause analysis: renders (evidence: `src/App.tsx`)
- Dashboard application → Weekly focus: renders (evidence: `src/App.tsx`)
- Dashboard application → DSNA network view: renders (evidence: `src/App.tsx`)
- Dashboard application → Dashboard footer: renders (evidence: `src/App.tsx`)
- Dashboard application → Data calculations: computes week (evidence: `src/App.tsx`)
- Dashboard application → Theme and ACC mapping: maps ACC slug (evidence: `src/App.tsx`)
- Dashboard application → Traffic dataset: loads fallback (evidence: `src/App.tsx`)
- jsDelivr data host → Dashboard application: serves data
- Dashboard application → ACC configuration: uses ACC settings (evidence: `src/App.tsx`)
- Global KPIs → Data calculations: computes metrics (evidence: `src/components/KPIGlobal.tsx`)
- Annual summary → Data calculations: derives series (evidence: `src/components/View1.tsx`)
- Annual comparison → Data calculations: derives series (evidence: `src/components/View2.tsx`)
- Cause analysis → Data calculations: derives causes (evidence: `src/components/View3.tsx`)
- Weekly focus → Data calculations: derives weeks (evidence: `src/components/View4.tsx`)
- DSNA network view → Data calculations: derives network metrics (evidence: `src/components/View5.tsx`)
- Annual comparison → Period selector: renders (evidence: `src/components/View2.tsx`)
- Cause analysis → Period selector: renders (evidence: `src/components/View3.tsx`)
- Annual comparison → Chart legends: renders (evidence: `src/components/View2.tsx`)
- Cause analysis → Chart legends: renders (evidence: `src/components/View3.tsx`)
- Weekly focus → Chart legends: renders (evidence: `src/components/View4.tsx`)
- ACC and theme header → Theme and ACC mapping: uses theme (evidence: `src/components/Header.tsx`)
- Data fetch ETL → Traffic dataset: produces data
- Data extraction → Reims CSV data: processes data
- Data extraction → Daily CSV data: processes data
