-
Notifications
You must be signed in to change notification settings - Fork 817
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
auto-fitBounds - WIP #868
auto-fitBounds - WIP #868
Conversation
There were the following issues with your Pull Request
Contribution guidelines are available at https://github.com/SebastianM/angular2-google-maps/blob/master/CONTRIBUTING.md This message was auto-generated by https://gitcop.com |
@SebastianM any updates on this? Would love this feature :) |
this dead? |
@SebastianM Can we get this!! This would be extremely helpful on your map |
@Opticsponge no not dead but not finished yet :) |
Any update on this? |
having this would be amazing or an option so gmaps doesnt update position at all .. making me crazy updating my markers and google maps jumps around like crazy trying to fit bounds |
👍 |
@SebastianM any updates on this ? |
+1, This is a must have feature. |
Any update? |
+1 |
+1 on this |
+1 |
2 similar comments
+1 |
+1 |
any updates on this? Or maybe any alternative solutions? |
👍 |
What is the status of this merge? |
I'm closing this in favour of #1389 |
This is a WIP Pull request!
This adds a new service named FitBoundsService. For every
AgmMap
component, a new instance gets created. The service computes theLatLngBounds
for all given elements of the map.The idea is that all core and custom child components of
AgmMap
inject that service to add or remove itself from the bounds. The should also provide a new Input namedfitBounds
(is the name a good idea?) to give the user the option to remove the element from the bounds. The default value of these fitBounds inputs should be true.The LatLngBounds of the FitBoundsService are exposed as an Observable. The
AgmMap
component subscribes to this observable:To enable auto-fitBounds, you have to set the fitBounds input to true:
// cc @lazarljubenovic @jinder