How tom-draper/uk-data-atlas works
UK Data Atlas is a web mapping platform for exploring UK geographic datasets. Users select a location and visualization, load the corresponding data and boundaries, and inspect the result as a map with chart and legend controls. The repository also contains a geography and data API, plus place and reference pages. The frontend excerpts show the Atlas-to-map handoff and map-layer management; the API excerpts show measure-coverage handling. Other API capabilities are represented from the source index, so their internal route wiring is not asserted.
Main entry points: AtlasClient.tsx Atlas client · MapInterface.tsx Map interface · routing.ts API routing · measureCoverageRoutes.ts Measure coverage route
Components 22
Atlas experience
- Atlas pages
app/atlas/page.tsx - Atlas client
components/AtlasClient.tsx
Map visualization
- Map interface
components/MapInterface.tsx - Map session
lib/hooks/useMapSession.ts - Map manager hook
lib/hooks/useMapManager.ts - Map manager
lib/helpers/mapManager/mapManager.ts - Layer manager
lib/helpers/mapManager/layerManager.ts - Chart panels
components/ChartSections.tsx - Map controls
components/MapOptions.tsx
Data and geography
- Chart dataset registry
lib/datasets/index.ts - Dataset catalogue
lib/data/catalog/index.ts - Dataset loading
lib/data/jsonDatasetClient.ts - Boundary data
lib/data/boundaries/worker.ts
Geography API
- API routing
services/api/src/routing.ts - Measure coverage route
services/api/src/measureCoverageRoutes.ts - API responses
services/api/src/routeResponse.ts - Area resources
services/api/src/areaResources.ts - Geography services
services/api/src - Data services
services/api/src
Places and reference
- Place profiles
lib/places/load.ts - Reference pages
components/reference/ReferencePage.tsx
Other components
- Atlas visitor
Connections 20
- Atlas visitor → Atlas pages: opens
- Atlas pages → Atlas client: renders
app/atlas/page.tsx - Atlas client → Map interface: renders
components/AtlasClient.tsx - Atlas client → Dataset loading: loads datasets
components/AtlasClient.tsx - Atlas client → Boundary data: reports boundary errors
- Map interface → Map session: configures
- Map session → Map manager hook: uses
lib/hooks/useMapSession.ts - Map manager hook → Map manager: creates
lib/hooks/useMapManager.ts - Map manager → Layer manager: delegates layers
lib/helpers/mapManager/mapManager.ts - Map interface → Chart panels: renders
- Map interface → Map controls: renders
- Chart dataset registry → Dataset loading: defines datasets
- Dataset catalogue → Dataset loading: catalogues data
- Atlas visitor → Reference pages: browses
- API routing → Measure coverage route: dispatches
services/api/src/measureCoverageRoutes.ts - Measure coverage route → API responses: formats response
services/api/src/measureCoverageRoutes.ts - Measure coverage route → Area resources: checks area
services/api/src/measureCoverageRoutes.ts - API routing → Geography services: routes geography requests
services/api/src/routing.ts - API routing → Data services: routes data requests
services/api/src/routing.ts - Atlas visitor → Place profiles: views place profiles