diff --git a/README.md b/README.md index 8022502..9a436a0 100644 --- a/README.md +++ b/README.md @@ -68,12 +68,12 @@ _For a working example see one of the following demos:_ ``` **Notes:** -- the plugin will identify and process both zipped (kmz) or unzipped (kml) files +- supported file formats: **.kmz**, **.kml** - to be able to use Google files (eg. through Google My Maps) you **MUST** use a valid third-party kml proxy server --- -**Compatibile with:** leaflet@1.3.4, jszip@3.1.5, togeojson@3.0.0, geojson-vt@3.0.0 +**Compatibile with:** leaflet@1.3.4, jszip@3.1.5, togeojson@3.0.0, geojson-vt@3.0.0, leaflet-pointable@0.0.3 --- diff --git a/libs/GridLayer.GeoJSON.js b/libs/GridLayer.GeoJSON.js index 0ecee6c..655e1c2 100644 --- a/libs/GridLayer.GeoJSON.js +++ b/libs/GridLayer.GeoJSON.js @@ -266,7 +266,7 @@ L.GridLayer.GeoJSON = L.GridLayer.extend({ var name = feature.properties.name || ""; if (name) { this._popup.setLatLng(e.latlng); - this._popup.setContent(name); + this._popup.setContent('' + name + ''); this._popup.openOn(this._map); } } else { diff --git a/libs/GridLayer.GeoJSON.min.js b/libs/GridLayer.GeoJSON.min.js index 8056afd..af31b27 100644 --- a/libs/GridLayer.GeoJSON.min.js +++ b/libs/GridLayer.GeoJSON.min.js @@ -9,4 +9,4 @@ for(var i=1;i<4;i+=1)sColorNew+=sColor.slice(i,i+1).concat(sColor.slice(i,i+1)); _getLatLngsPoly:function(feature,i){var o=[];var geometry=feature.geometry||feature;var coords=geometry.type=="Polygon"?geometry.coordinates[0]:geometry.coordinates;for(var j=i||0;j"+name+"");this._popup.openOn(this._map)}}else this._map.closePopup(this._popup)}});L.gridLayer.geoJson=function(geojson,options){return new L.GridLayer.GeoJSON(geojson,options)}; diff --git a/package.json b/package.json index 022ff02..dd6c907 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "leaflet-kmz", - "version": "0.0.9", + "version": "0.1.0", "description": "A KMZ file loader for Leaflet Maps", "main": "/libs/KMZParser.js", "scripts": { @@ -30,6 +30,7 @@ "geojson-vt": "^3.0.0", "jszip": "^3.1.5", "leaflet": "^1.3.4", - "togeojson": "^0.16.0" + "togeojson": "^0.16.0", + "leaflet-pointable": "^0.0.3" } }