-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Add a padding option to map.getBounds #9265
Comments
From what I gathered it seems like #8638 would fit your usecase. |
Any update here maybe? |
👍 to this |
#10386 aims to close the gap in this regard, so that getBounds are the inset of the global map padding For your described scenario, could you keep track of if you've just done a fitBounds with a padding? If you have then you know when you do getBounds() it's already got that padding factored in and subsequent fitBounds you'd not pass a padding as the bounds incorporate it? I might be missing something here though. |
Motivation
Scenario:
Problem:
Without knowing how the extra 20px padding is added on in fitBounds(), it would be difficult to adjust this logic to prevent any zoom and scroll between getBounds and fitBounds calls.
Design Alternatives
The text was updated successfully, but these errors were encountered: