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

Zoomed out map is out of view if the container is too small #8570

Closed
gabimoncha opened this issue Jul 29, 2019 · 1 comment
Closed

Zoomed out map is out of view if the container is too small #8570

gabimoncha opened this issue Jul 29, 2019 · 1 comment

Comments

@gabimoncha
Copy link

gabimoncha commented Jul 29, 2019

Hello. I created a minimap in order to show the user where the current viewport is on the base map. The minimap's container's width and height weren't a problem, until now when I need to show the whole world. Is there something I'm missing or this wasn't intended? Is there anything to do that I can help / fix this?

mapbox-gl-js version: 1.1.1

browser: Chrome/75.0.3770.142

Steps to Trigger Behavior

  1. Create a project and display a map according to docs
  2. Change #map style to { width: 120px; height: 120px }
  3. Set zoom: 0

Link to Demonstration

https://jsbin.com/tusurut/1/edit?html,output

Expected Behavior

I would be nice if the map can show the whole world on zoom: 0, no matter the container dimensions.

Actual Behavior

It looks like minimum dimensions are aproximative width: 520px and height: 400px

@ryanhamley
Copy link
Contributor

This is a known issue #3055. We'd essentially need to handle negative zoom. I'm going to close this to focus discussion in the original ticket. Thanks!

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

No branches or pull requests

2 participants