From 6ce6834acd5626db72ae145617e650a44ca94521 Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Tue, 28 Mar 2023 13:51:28 +0200 Subject: [PATCH] Adds scale line to map client --- templates/map/client/libs/netgis/Attribution.css | 2 +- templates/map/client/libs/netgis/MapOpenLayers.js | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/templates/map/client/libs/netgis/Attribution.css b/templates/map/client/libs/netgis/Attribution.css index 50ff42fd..c4cc9bad 100644 --- a/templates/map/client/libs/netgis/Attribution.css +++ b/templates/map/client/libs/netgis/Attribution.css @@ -1,7 +1,7 @@ .netgis-attribution { position: absolute; - left: 0mm; + right: 0mm; bottom: 0mm; padding: 1mm; background: rgba( 255, 255, 255, 0.5 ); diff --git a/templates/map/client/libs/netgis/MapOpenLayers.js b/templates/map/client/libs/netgis/MapOpenLayers.js index 4e20fea8..2ec152e8 100644 --- a/templates/map/client/libs/netgis/MapOpenLayers.js +++ b/templates/map/client/libs/netgis/MapOpenLayers.js @@ -133,7 +133,9 @@ netgis.MapOpenLayers.prototype.initMap = function() view: this.view, pixelRatio: 1.0, moveTolerance: 5, - controls: [] + controls: [ + new ol.control.ScaleLine(), + ] } );