Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/division maps #1667

Merged
merged 3 commits into from
Jan 19, 2023
Merged

Conversation

GeoWill
Copy link
Collaborator

@GeoWill GeoWill commented Nov 17, 2022

Don't merge before #1637 - I based this PR off of that branch as I couldn't get master working locally.

Why

Becasue maps. More seriously the specific itch is wanting to know that the data councils have sent for WDIV covers the election area. This provides a nice way of quickly seeing the area covered by an election, and downloading the geojson to drag and drop into QGIS is a couple of clicks away.

Screenshots

Initial view with the detail collapsed
Initial View

Expanded with the map open
Map Open

Clicking the link on the popup downloads the geojson
Popup open

@coveralls
Copy link

coveralls commented Nov 17, 2022

Coverage Status

Coverage: 69.117%. Remained the same when pulling 8e2dce8 on GeoWill:feature/division-maps into 45fec66 on DemocracyClub:master.

@symroe symroe marked this pull request as ready for review January 19, 2023 14:37
Only show it if there is a geography associated with an election object.
This means that election groups with an associated object (eg local
authorities /elections/local.aberdeen-city.2022-05-05/) will also show a
map.

To avoid cluttering the page, hide it in a details tag. Leaflet needs
the div with the target id to be added to the dom before it's
initialised. This is the reason for the eventListener on the detail.

Includes a not very informative popup that can be improved upon.
@symroe symroe merged commit 8adb913 into DemocracyClub:master Jan 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants