1

If the question is not properly setup with right word sorry for that, I'll hope I could make you clear what I mean by showing you this:

<sebm-google-map-marker 
             *ngFor="let clustermarker of clusters" 
             (markerClick)="clustermarkerClicked()" 
             [latitude]="clustermarker.latitude" 
             [longitude]="clustermarker.longitude" 
             [iconUrl]="clustermarker.icon" 
             [visible]="true">
</sebm-google-map-marker>

As you see I have an input visible in the marker tag, and I have a zoomChange event on my google map named:

testFunction(e){
  console.log(e);

  if ( e === 17 || e === 18) {
   Here I want to set the variable of visible to false
 }
}

1 Answer 1

1
<sebm-google-map-marker 
             *ngFor="let clustermarker of clusters" 
             (markerClick)="clustermarkerClicked()" 
             [latitude]="clustermarker.latitude" 
             [longitude]="clustermarker.longitude" 
             [iconUrl]="clustermarker.icon" 
             [visible]="isVisible">
</sebm-google-map-marker>
isVisible:boolean = false;
testFunction(e){
  console.log(e);

  if ( e === 17 || e === 18) {
   this.isVisible = true;
 }
}
Sign up to request clarification or add additional context in comments.

1 Comment

Thank you so much forget that I could use an variable -.-"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.