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

fix: when proposing a new address, map should display at full width and lower zoom #3538

Merged
merged 1 commit into from
Aug 21, 2024

Conversation

jessicamcinchak
Copy link
Member

@jessicamcinchak jessicamcinchak commented Aug 20, 2024

Fixes issues raised by Tewkesbury & West Berks linked here: https://trello.com/c/TAY09Mpw/2980-diagnose-and-fix-map-center-zoom-issue-when-displaying-team-boundaries

Quick but key changes here:

  • FindProperty map gets a FullWidthWrapper similar to our other interactive maps (eg DrawBoundary) for more real-estate
  • Lowered zoom from 14 to 10 which seems to better accomodate more spacious rural councils while still working for London boroughs like Lambeth too
  • Removed drawGeojsonDataBuffer prop - we don't need this for initial render, and when coming "back" after having plotted a new address, the map defaults will still be smartly zoomed into & centered on your existing point

No changes necessary to how we store boundaries or calculate bounding-boxes - that's all correct, was purely a viewport / display issue here I believe!

The viewport is still "clipped" to the council boundary, and now that we're starting at a lower zoom, don't expect to be able to zoom out much from the starting location, but it should feel more "centered" on the full council now (rather than the center of the boundary like before).

Before & afters:

  • Tewkesbury
    Screenshot from 2024-08-20 15-22-02
    Screenshot from 2024-08-20 15-21-28

  • West Berks
    Screenshot from 2024-08-20 15-24-30
    Screenshot from 2024-08-20 15-26-20

  • Lambeth (did not report issue, but is quite a different scope boundary than above examples, so want to confirm it still displays reasonably too!)
    Screenshot from 2024-08-20 15-40-09
    Screenshot from 2024-08-20 15-27-21

@jessicamcinchak
Copy link
Member Author

@jessicamcinchak jessicamcinchak requested a review from a team August 20, 2024 13:42
Copy link

github-actions bot commented Aug 20, 2024

Removed vultr server and associated DNS entries

Copy link
Contributor

@DafyddLlyr DafyddLlyr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No changes necessary to how we store boundaries or calculate bounding-boxes - that's all correct, was purely a viewport / display issue here I believe!

Thanks for the clear explanation and investigation here, good to see that this is just a simple viewport issue 👍

Code reads as correct and all looks good - but having some issues with the Pizza. Maybe unrelated to changes here, can you verify?

When I load a map I get the error "Error: Unimplemented type: 3" which is caused when a 404 is returned by the vector tile provider.

image

Also getting an issue when loading up West Berks' LDC service - https://3538.planx.pizza/west-berkshire/apply-for-a-lawful-development-certificate/published?analytics=false

image

Copy link
Contributor

@DafyddLlyr DafyddLlyr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved - issues not consistently re-creatable, and have appeared independently of this PR in the past. Will re-test once merged to main 👍

@jessicamcinchak jessicamcinchak merged commit 7eb7c9d into main Aug 21, 2024
12 checks passed
@jessicamcinchak jessicamcinchak deleted the jess/fix-new-address-map-zoom branch August 21, 2024 07:59
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.

2 participants