# deaturibio/desmatamento-sp---s-rie-hist-rica architecture

> Architecture diagram of the GitHub repository deaturibio/desmatamento-sp---s-rie-hist-rica, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-16). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/deaturibio/desmatamento-sp---s-rie-hist-rica
- Repository: https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica

## Overview

This is a static web application for exploring PRODES deforestation in São Paulo’s Atlantic Forest. The user selects or animates a period, views filtered map layers and indicators, inspects polygon attributes, and explores municipal rankings and annual averages. The documented runtime centers on the browser application, with a local aggregate-data file and remote TerraBrasilis services. Source excerpts were unavailable, so relationships below rely on the README; implementation details beyond its descriptions are not inferred.

Main entry points: [`docs/assets/js/app.js`](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js) (Map application), [`docs/index.html`](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/index.html) (Web page), [`docs/assets/js/grafico.js`](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/grafico.js) (Annual averages), [`docs/dados/prodes_sp.json`](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/dados/prodes_sp.json) (SP time series)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_interface["Map interface"]
  node_page["Web page<br/>[index.html]"]
  node_app["Map application<br/>[app.js]"]
  node_period_map["Period map<br/>[app.js]"]
  node_context_layers["Context layers<br/>[app.js]"]
  node_polygon_query["Polygon query<br/>[app.js]"]
  node_permalink["Period permalink<br/>[app.js]"]
end

subgraph group_analysis["Period analysis"]
  node_timeline["Timeline playback<br/>[app.js]"]
  node_indicators["Indicators<br/>[app.js]"]
  node_municipal_ranking["Municipal ranking<br/>[app.js]"]
  node_history_chart["Annual averages<br/>[grafico.js]"]
end

subgraph group_data["Data sources"]
  node_series_data["SP time series<br/>[prodes_sp.json]"]
  node_terrasbrasilis["TerraBrasilis services"]
end

node_visitor(("Visitor"))

node_visitor -->|"opens"| node_page
node_page -->|"loads"| node_app
node_app -->|"controls"| node_period_map
node_app -->|"controls"| node_timeline
node_app -->|"updates"| node_indicators
node_app -->|"updates"| node_municipal_ranking
node_app -->|"updates"| node_history_chart
node_app -->|"stores period"| node_permalink
node_app -->|"fetches"| node_series_data
node_period_map -->|"requests WMS"| node_terrasbrasilis
node_polygon_query -->|"requests feature info"| node_terrasbrasilis
node_municipal_ranking -->|"requests WFS"| node_terrasbrasilis
node_context_layers -->|"loads map layers"| node_terrasbrasilis

click node_page "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/index.html"
click node_app "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js"
click node_period_map "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js"
click node_context_layers "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js"
click node_polygon_query "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js"
click node_timeline "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js"
click node_indicators "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js"
click node_municipal_ranking "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js"
click node_history_chart "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/grafico.js"
click node_permalink "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js"
click node_series_data "https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/dados/prodes_sp.json"

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_page,node_app,node_period_map,node_context_layers,node_polygon_query,node_permalink toneBlue
class node_timeline,node_indicators,node_municipal_ranking,node_history_chart toneAmber
class node_series_data,node_terrasbrasilis toneMint
class node_visitor toneIndigo
```

## Components

### Map interface

- [Web page](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/index.html): `docs/index.html`
- [Map application](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js): `docs/assets/js/app.js`
- [Period map](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js): `docs/assets/js/app.js`
- [Context layers](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js): `docs/assets/js/app.js`
- [Polygon query](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js): `docs/assets/js/app.js`
- [Period permalink](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js): `docs/assets/js/app.js`

### Period analysis

- [Timeline playback](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js): `docs/assets/js/app.js`
- [Indicators](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js): `docs/assets/js/app.js`
- [Municipal ranking](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/app.js): `docs/assets/js/app.js`
- [Annual averages](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/assets/js/grafico.js): `docs/assets/js/grafico.js`

### Data sources

- [SP time series](https://github.com/deaturibio/desmatamento-sp---s-rie-hist-rica/blob/main/docs/dados/prodes_sp.json): `docs/dados/prodes_sp.json`
- **TerraBrasilis services**

### Other components

- **Visitor**

## Connections

- Visitor → Web page: opens (evidence: `README.md`)
- Web page → Map application: loads (evidence: `README.md`)
- Map application → Period map: controls (evidence: `README.md`)
- Map application → Timeline playback: controls (evidence: `README.md`)
- Map application → Indicators: updates (evidence: `README.md`)
- Map application → Municipal ranking: updates (evidence: `README.md`)
- Map application → Annual averages: updates (evidence: `README.md`)
- Map application → Period permalink: stores period (evidence: `README.md`)
- Map application → SP time series: fetches (evidence: `README.md`)
- Period map → TerraBrasilis services: requests WMS (evidence: `README.md`)
- Polygon query → TerraBrasilis services: requests feature info (evidence: `README.md`)
- Municipal ranking → TerraBrasilis services: requests WFS (evidence: `README.md`)
- Context layers → TerraBrasilis services: loads map layers (evidence: `README.md`)
