vue-leaflet / vue-leaflet

vue-leaflet compatible with vue3
MIT License
708 stars 111 forks source link

Markers disappear during zoom animation with :zoom-animation="true" #201

Open ninrich opened 2 years ago

ninrich commented 2 years ago

Hello, I am using an LMap component with the following code:

  <LMap
      ref="IPMap"
      id="ip-map"

      @ready="fitPlacesToBounds"

      :options="mapOptions: {attributionControl: false,  zoomControl: false}"
      :zoom-animation="true"
  >
    <LControlZoom position="bottomleft"/>
    <LMarker
        v-for="place in filteredPlaces"
        :key="place.id"
        :lat-lng="[place.x, place.y]"
        @click="openPlaceDetailPopup(place)"
    >
      <LTooltip>
        {{place.name}}
      </LTooltip>
    </LMarker>
    <LTileLayer
        :url="'https://api.mapbox.com/[...]
    />
  </LMap>

however, whenever I zoom in or out, the markers disappear for the whole duration of the zoom animation, as can be seen in this gif:

Animation

Is this the intended behavior? Is there a mistake in my code? Is there a bug?

Thank you.

msslgomez commented 1 year ago

if you add :marker-zoom-animation="true" on l-map that doesn't happen.