Open Infrastructure Map, a view of infrastructure data in OpenStreetMap
Infopopup tweaks
Russ Garrett3ad4d2ec958b
diff --git a/web/src/index.ts b/web/src/index.tsindex 25ac7c0..25a4500 100644--- a/web/src/index.ts+++ b/web/src/index.ts@@ -131,7 +131,7 @@ function init() {map.addControl(new EditButton(), 'bottom-right')new InfoPopup(oim_layers.map((layer: { [x: string]: any }) => layer['id']),- 9+ 6).add(map)}diff --git a/web/src/infopopup.ts b/web/src/infopopup.tsindex bb920fb..9095d65 100644--- a/web/src/infopopup.ts+++ b/web/src/infopopup.ts@@ -95,6 +95,12 @@ class InfoPopup {map.getCanvas().style.cursor = ''}})++ map.on('zoom', () => {+ if (this._map.getZoom() <= this.min_zoom) {+ this._map.getCanvas().style.cursor = ''+ }+ })}osmLink(id: number, is_node: boolean) {@@ -271,6 +277,7 @@ class InfoPopup {if (this.popup_obj && this.popup_obj.isOpen()) {this.popup_obj.remove()}+ this._map.getCanvas().style.cursor = ''if (e.features === undefined || e.features.length == 0) {return