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

Remove Street View Control #418

Closed
brian-singer opened this issue Jun 11, 2016 · 7 comments
Closed

Remove Street View Control #418

brian-singer opened this issue Jun 11, 2016 · 7 comments

Comments

@brian-singer
Copy link
Contributor

Add somehow the option to remove the little streetViewControl 'Man'.
In my case, application is based on markers and since markers cannot be added in street view then it's an unnecessary feature.

@ruzicic
Copy link

ruzicic commented Feb 4, 2019

For anyone else looking for this..
Use [streetViewControl]="false" on <agm-map> element

@bbRLdev
Copy link

bbRLdev commented Aug 27, 2020

This does not work, there is no streetViewControl property mentioned in the official docs either

@ghost
Copy link

ghost commented Aug 28, 2020

correct, it changed. You must now disable defaultUI to remove defaults, and then add as necessary

@ilprima
Copy link

ilprima commented Sep 10, 2020

correct, it changed. You must now disable defaultUI to remove defaults, and then add as necessary

How to add as necessary? For example I would like the +- buttons but not the street view one

@ilprima
Copy link

ilprima commented Sep 10, 2020

Ok I found how to do it:

Put on agm-map tag:

<agm-map (mapReady)="onMapReady($event)"

And then:

onMapReady(map?: google.maps.Map ){
   if(map)
     map.setOptions({
       streetViewControl: false
     });
 }

@ghost
Copy link

ghost commented Sep 11, 2020

@ilprima no, that's not the right way even though it works.

The correct way is to disable defaultUi, and then add <agm-zoom-control>

@ilprima
Copy link

ilprima commented Sep 11, 2020

@ilprima no, that's not the right way even though it works.

The correct way is to disable defaultUi, and then add <agm-zoom-control>

Thank you. I think this library needs a better documentation, with more examples

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants