3daa00ef65
This fixes a bug caused by the recent react-leaflet update, where the URL prop of the TileLayer component is no longer mutable in v3, so map layers which depended on the layer reloading upon a URL change, needed to be adjusted. The solution was to add appropriate key props to the layers, to force recreating the layers. To simplify the management of layer reloading and to ensure some base layers don't re-appear above higher layers, the layer organisation was reworked using custom leaflet Panes. The file organisation was also changed to separate the logic for the different layers into their own components, rather than having everything in map.tsx |
||
---|---|---|
.github | ||
app | ||
docs | ||
etl | ||
html | ||
maintenance | ||
migrations | ||
provision | ||
.all-contributorsrc | ||
.gitignore | ||
.travis.yml | ||
ecosystem.config.dev-template.js | ||
ecosystem.config.template.js | ||
LICENSE | ||
README.md | ||
Vagrantfile |
Colouring London
How many buildings are there in London? What are their characteristics? Where are they located and how do they contribute to the city? How adaptable are they? How long will they last, and what are the environmental and socio-economic implications of demolition?
Colouring London is a web-based citizen social science project designed to help address these questions by crowdsourcing and visualising twelve categories of information on London’s buildings.
Structure
This repository will contain open-source code for the project which:
- stores building footprint polygons and source metadata
- allows site users to record building attribute data
- serves map tiles rendered from collected data
- allows site visitors to download the collected building attribute data
Building attribute data collected as part of the project will be made available for download under a liberal open data license (ODbL).
Setup and run
- Provision database (see
migrations
) - Load buildings and geometries to database (see
etl
) - Install app dependencies:
cd app && npm i
- Run tests:
npm test
- Run app:
npm start
In development, run with environment variables:
APP_COOKIE_SECRET=test_secret \
PGHOST=localhost \
PGUSER=dbuser \
PGDATABASE=dbname \
PGPASSWORD=dbpassword \
PGPORT=5432 \
TILECACHE_PATH=/path/to/tilecache/directory \
npm start
Acknowledgements
Colouring London was set up at the Centre for Advanced Spatial Analysis (CASA), University College London and is now based at The Alan Turing Institute. Ordnance Survey is providing building footprints required to collect the data, facilitated by the Greater London Authority (GLA), and giving access to its API and technical support.
License
Colouring London
Copyright (C) 2018 Tom Russell and Colouring London contributors
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
Contributors
Thanks goes to these wonderful people (emoji key):
polly64 🎨 🤔 🖋 🔍 |
Tom Russell 🎨 🤔 💻 📖 |
mz8i 💻 🤔 |
dominic 🤔 🖋 |
Adam Dennett 🤔 |
Duncan Smith 🤔 |
martin-dj 💻 |
MeldaS 💻 🤔 |
Tarn Hamilton 🎨 |
Louis Jobst 🎨 |
This project follows the all-contributors specification. Contributions of any kind welcome!
Even more thanks go to Colouring London contributors, funders, project partners, consultees, advisers, supporters and friends - everyone involved in the project.