diff --git a/CHANGELOG.md b/CHANGELOG.md index 0552fde..774a899 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,6 @@ ### Change Log for Node-RED Worldmap + - v2.17.0 - More complete feedback on click, better popup image sizing. - v2.16.3 - Ensure polygons can be deleted. - v2.16.2 - better handling of unpacked gpz objects. - v2.16.0 - Allow specifying custom base map server. diff --git a/README.md b/README.md index d992a43..74269f1 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,7 @@ map web page for plotting "things" on. ### Updates +- v2.17.0 - More complete feedback on click, better popup image sizing. - v2.16.3 - Ensure polygons can be deleted. - v2.16.2 - better handling of unpacked gpz objects. - v2.16.0 - Allow specifying custom base map server. diff --git a/package.json b/package.json index 5d3b93a..1feb697 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "node-red-contrib-web-worldmap", - "version": "2.16.3", + "version": "2.17.0", "description": "A Node-RED node to provide a web page of a world map for plotting things on.", "dependencies": { "cgi": "0.3.1", diff --git a/worldmap/css/worldmap.css b/worldmap/css/worldmap.css index 3e22b06..8bd4085 100644 --- a/worldmap/css/worldmap.css +++ b/worldmap/css/worldmap.css @@ -23,6 +23,10 @@ a { text-decoration:none; } +.leaflet-interactive:hover { + filter: opacity(0.5); +} + .topbar { font-size:16px; vertical-align:middle; diff --git a/worldmap/worldmap.js b/worldmap/worldmap.js index 9d36a77..a68db03 100644 --- a/worldmap/worldmap.js +++ b/worldmap/worldmap.js @@ -697,8 +697,11 @@ var addThing = function() { var feedback = function(n,v,a,c) { if (v === "$form") { v = form; } if (markers[n]) { - var fp = markers[n]._latlng; - ws.send(JSON.stringify({action:a||"feedback", name:n, value:v, layer:markers[n].lay, lat:fp.lat, lon:fp.lng})); + //var fp = markers[n]._latlng; + // ws.send(JSON.stringify({action:a||"feedback", name:n, value:v, layer:markers[n].lay, lat:fp.lat, lon:fp.lng})); + var fb = allData[n]; + fb.action = a || "feedback"; + ws.send(JSON.stringify(fb)); } else { if (n === undefined) { n = "map"; } @@ -1214,7 +1217,7 @@ var rangerings = function(latlng, options) { ranges: [250,500,750,1000], pan: 0, fov: 60, - color: '#910000' + color: '#aaaa00' }, options); var rings = L.featureGroup(); if (typeof options.ranges === "number") { options.ranges = [ options.ranges ]; } @@ -1702,7 +1705,7 @@ function setMarker(data) { opts.size = opts.size || sz; opts.size = opts.size * (opts.scale || 1); // escape out any isocodes eg flag symbols - var optfields = ["additionalInformation","higherFormation","specialHeadquarters","staffComments","type","uniqueDesignation"]; + var optfields = ["additionalInformation","higherFormation","specialHeadquarters","staffComments","type","uniqueDesignation","speed"]; optfields.forEach(function (item) { if (opts.hasOwnProperty(item)) { opts[item] = unescape(encodeURIComponent(opts[item])); } }); @@ -1784,11 +1787,11 @@ function setMarker(data) { if (data.hasOwnProperty("icon")) { delete data.icon; } if (data.hasOwnProperty("iconColor")) { delete data.iconColor; } if (data.hasOwnProperty("photourl")) { - words += ""; + words += "
"; delete data.photourl; } if (data.hasOwnProperty("photoUrl")) { - words += ""; + words += "
"; delete data.photoUrl; } if (data.hasOwnProperty("videoUrl")) {