ghettovoice / vuelayers

Web map Vue components with the power of OpenLayers
https://vuelayers.github.io/
MIT License
682 stars 230 forks source link

Displacement not applying #467

Closed MixMasterMot closed 2 years ago

MixMasterMot commented 2 years ago

Hello when using a style function like this the displacement is not applied to the element in this case the Circle does not get moved.

return new ol.style.Style({
    image: new ol.style.Circle({
        fill: new ol.style.Fill({ color: [228, 30, 147, .9] }),
        stroke: new ol.style.Stroke({ color: [228, 30, 147, 0.5], width: 10 }),
        radius: 12,
        displacement:[99999,99999]
    }),
    text: new ol.style.Text({
        text: String(feature.get('features').length),
        fill: new ol.style.Fill({ color: [255, 255, 255] }),
        scale: 1.2
    }),
})

Any assistance with this would be nice thanks

ghettovoice commented 2 years ago

Hello @MixMasterMot , which version of vuelayers do you use? If v0.11.x: it is based on openlayers v5 and doesn't implement displacement option

MixMasterMot commented 2 years ago

I was using v0.11.x thanks for the great component :)