javascript - Can I add custom icon to mapbox gl using Layers -
i need add custom icon/marker example https://www.mapbox.com/mapbox-gl-js/example/custom-marker-icons/ using layers in mapbox gl. found example https://www.mapbox.com/mapbox-gl-js/example/add-image/. can make image rounded in first example?
the rounded edges achieved in css not in javascript or in mapbox gl @ all.
.marker { display: block; border: none; border-radius: 50%; cursor: pointer; padding: 0; } the crucial 'border-radius: 50%'. need ensure class/id of div referenced. if image not dynamic or singular might more appropriate use transparent png achieve rather using client side resources.
Comments
Post a Comment