From bcf3cac2bed39f984c8c3720ffb56d0e2b2f9a08 Mon Sep 17 00:00:00 2001 From: fe-dev Date: Thu, 28 Jul 2022 14:23:42 +0300 Subject: [PATCH] UI: Fixed custom marker size --- .../app/modules/home/components/widget/lib/maps/leaflet-map.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/maps/leaflet-map.ts b/ui-ngx/src/app/modules/home/components/widget/lib/maps/leaflet-map.ts index 73ff835b39..3ef89b5031 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/maps/leaflet-map.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/maps/leaflet-map.ts @@ -808,7 +808,8 @@ export default abstract class LeafletMap { const currentImage: MarkerImageInfo = this.options.useMarkerImageFunction ? safeExecute(this.options.parsedMarkerImageFunction, [data, this.options.markerImages, markersData, data.dsIndex]) : this.options.currentImage; - const style = currentImage ? 'background-image: url(' + currentImage.url + ');' : ''; + const imageSize = `height: ${this.options.markerImageSize || 34}px; width: ${this.options.markerImageSize || 34}px;`; + const style = currentImage ? 'background-image: url(' + currentImage.url + '); ' + imageSize : ''; this.options.icon = { icon: L.divIcon({ html: `