forked from Snck3rs/contao-leaflet-libraries
Update LeafletExtraMarkers to 1.0.8.
This commit is contained in:
@@ -19,7 +19,7 @@ This package contains following packages:
|
|||||||
- [Leaflet.loading 0.1.24](https://github.com/ebrelsford/Leaflet.loading)
|
- [Leaflet.loading 0.1.24](https://github.com/ebrelsford/Leaflet.loading)
|
||||||
- [Leaflet.Control.FullScreen 1.4.5](https://github.com/brunob/leaflet.fullscreen)
|
- [Leaflet.Control.FullScreen 1.4.5](https://github.com/brunob/leaflet.fullscreen)
|
||||||
- [Leaflet Control Geocoder 1.6.0](https://github.com/perliedman/leaflet-control-geocoder)
|
- [Leaflet Control Geocoder 1.6.0](https://github.com/perliedman/leaflet-control-geocoder)
|
||||||
- [Leaflet.ExtraMarkers 1.0.6](https://github.com/coryasilva/Leaflet.ExtraMarkers)
|
- [Leaflet.ExtraMarkers 1.0.8](https://github.com/coryasilva/Leaflet.ExtraMarkers)
|
||||||
- [leaflet.pm 0.23.1](https://github.com/codeofsumit/leaflet.pm)
|
- [leaflet.pm 0.23.1](https://github.com/codeofsumit/leaflet.pm)
|
||||||
- [osmtogeojson 2.2.12](https://github.com/tyrasd/osmtogeojson)
|
- [osmtogeojson 2.2.12](https://github.com/tyrasd/osmtogeojson)
|
||||||
- [spin.js 2.3.2](http://fgnass.github.io/spin.js)
|
- [spin.js 2.3.2](http://fgnass.github.io/spin.js)
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -17,7 +17,7 @@ module.exports = function(grunt) {
|
|||||||
less: require('./build/grunt-config/less'), // Config to compile and autoprefix less files
|
less: require('./build/grunt-config/less'), // Config to compile and autoprefix less files
|
||||||
uglify: require('./build/grunt-config/uglify'),
|
uglify: require('./build/grunt-config/uglify'),
|
||||||
jshint: require('./build/grunt-config/jshint'), // Lint Javascript
|
jshint: require('./build/grunt-config/jshint'), // Lint Javascript
|
||||||
|
rollup: require('./build/grunt-config/rollup-config')
|
||||||
});
|
});
|
||||||
|
|
||||||
/*****************************************************
|
/*****************************************************
|
||||||
@@ -33,8 +33,9 @@ module.exports = function(grunt) {
|
|||||||
// Javascript Dev Build - Checks for Errors in Javascript
|
// Javascript Dev Build - Checks for Errors in Javascript
|
||||||
grunt.registerTask('js-dev', [], function(){
|
grunt.registerTask('js-dev', [], function(){
|
||||||
grunt.loadNpmTasks('grunt-contrib-jshint');
|
grunt.loadNpmTasks('grunt-contrib-jshint');
|
||||||
|
grunt.loadNpmTasks('grunt-rollup');
|
||||||
grunt.loadNpmTasks('grunt-contrib-uglify');
|
grunt.loadNpmTasks('grunt-contrib-uglify');
|
||||||
grunt.task.run('jshint:all', 'uglify:dev');
|
grunt.task.run('jshint:all', 'rollup', 'uglify:build');
|
||||||
});
|
});
|
||||||
|
|
||||||
/*****************************************************
|
/*****************************************************
|
||||||
@@ -50,8 +51,9 @@ module.exports = function(grunt) {
|
|||||||
// 'grunt js-build' compiles only javascript
|
// 'grunt js-build' compiles only javascript
|
||||||
grunt.registerTask('js-build', [], function(){
|
grunt.registerTask('js-build', [], function(){
|
||||||
grunt.loadNpmTasks('grunt-contrib-jshint');
|
grunt.loadNpmTasks('grunt-contrib-jshint');
|
||||||
|
grunt.loadNpmTasks('grunt-rollup');
|
||||||
grunt.loadNpmTasks('grunt-contrib-uglify');
|
grunt.loadNpmTasks('grunt-contrib-uglify');
|
||||||
grunt.task.run('jshint:all', 'uglify:build');
|
grunt.task.run('jshint:all', 'rollup', 'uglify:build');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
# Leaflet.extra-markers plugin v1.0.4
|
# Leaflet.extra-markers
|
||||||
<a href="https://github.com/lvoogdt/Leaflet.awesome-markers">Big Thanks to lvoogdt of Leaflet.awesome-markers</a>
|
<a href="https://github.com/lvoogdt/Leaflet.awesome-markers">Big Thanks to lvoogdt of Leaflet.awesome-markers</a>
|
||||||
|
|
||||||

|

|
||||||
@@ -48,7 +48,7 @@ Now use the plugin to create a marker like this:
|
|||||||
prefix: 'fa'
|
prefix: 'fa'
|
||||||
});
|
});
|
||||||
|
|
||||||
L.marker([51.941196,4.512291], {icon: redMarker,}).addTo(map);
|
L.marker([51.941196,4.512291], {icon: redMarker}).addTo(map);
|
||||||
````
|
````
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "Leaflet.extra-markers",
|
"name": "Leaflet.extra-markers",
|
||||||
"version": "1.0.6",
|
"version": "1.0.8",
|
||||||
"homepage": "https://github.com/coryasilva/Leaflet.ExtraMarkers",
|
"homepage": "https://github.com/coryasilva/Leaflet.ExtraMarkers",
|
||||||
"authors": [
|
"authors": [
|
||||||
"Cory Silva"
|
"Cory Silva"
|
||||||
|
|||||||
@@ -1 +1,8 @@
|
|||||||
.extra-marker{background:url("../img/markers_default.png") no-repeat 0 0;width:35px;height:46px;position:absolute;left:0;top:0;display:block;text-align:center}.extra-marker-shadow{background:url("../img/markers_shadow.png") no-repeat 0 0;width:36px;height:16px}@media (min--moz-device-pixel-ratio:1.5),(-webkit-min-device-pixel-ratio:1.5),(min-device-pixel-ratio:1.5),(min-resolution:1.5dppx){.extra-marker{background-image:url("../img/markers_default@2x.png");background-size:540px 184px}.extra-marker-shadow{background-image:url("../img/markers_shadow@2x.png");background-size:35px 16px}}.extra-marker i{color:#fff;margin-top:10px;display:inline-block;font-size:14px}.extra-marker i.icon{margin-right:0;opacity:1}.extra-marker-circle-red{background-position:0 0}.extra-marker-circle-orange-dark{background-position:-36px 0}.extra-marker-circle-orange{background-position:-72px 0}.extra-marker-circle-yellow{background-position:-108px 0}.extra-marker-circle-blue-dark{background-position:-144px 0}.extra-marker-circle-blue{background-position:-180px 0}.extra-marker-circle-cyan{background-position:-216px 0}.extra-marker-circle-purple{background-position:-252px 0}.extra-marker-circle-violet{background-position:-288px 0}.extra-marker-circle-pink{background-position:-324px 0}.extra-marker-circle-green-dark{background-position:-360px 0}.extra-marker-circle-green{background-position:-396px 0}.extra-marker-circle-green-light{background-position:-432px 0}.extra-marker-circle-black{background-position:-468px 0}.extra-marker-circle-white{background-position:-504px 0}.extra-marker-square-red{background-position:0 -46px}.extra-marker-square-orange-dark{background-position:-36px -46px}.extra-marker-square-orange{background-position:-72px -46px}.extra-marker-square-yellow{background-position:-108px -46px}.extra-marker-square-blue-dark{background-position:-144px -46px}.extra-marker-square-blue{background-position:-180px -46px}.extra-marker-square-cyan{background-position:-216px -46px}.extra-marker-square-purple{background-position:-252px -46px}.extra-marker-square-violet{background-position:-288px -46px}.extra-marker-square-pink{background-position:-324px -46px}.extra-marker-square-green-dark{background-position:-360px -46px}.extra-marker-square-green{background-position:-396px -46px}.extra-marker-square-green-light{background-position:-432px -46px}.extra-marker-square-black{background-position:-468px -46px}.extra-marker-square-white{background-position:-504px -46px}.extra-marker-star-red{background-position:0 -92px}.extra-marker-star-orange-dark{background-position:-36px -92px}.extra-marker-star-orange{background-position:-72px -92px}.extra-marker-star-yellow{background-position:-108px -92px}.extra-marker-star-blue-dark{background-position:-144px -92px}.extra-marker-star-blue{background-position:-180px -92px}.extra-marker-star-cyan{background-position:-216px -92px}.extra-marker-star-purple{background-position:-252px -92px}.extra-marker-star-violet{background-position:-288px -92px}.extra-marker-star-pink{background-position:-324px -92px}.extra-marker-star-green-dark{background-position:-360px -92px}.extra-marker-star-green{background-position:-396px -92px}.extra-marker-star-green-light{background-position:-432px -92px}.extra-marker-star-black{background-position:-468px -92px}.extra-marker-star-white{background-position:-504px -92px}.extra-marker-penta-red{background-position:0 -138px}.extra-marker-penta-orange-dark{background-position:-36px -138px}.extra-marker-penta-orange{background-position:-72px -138px}.extra-marker-penta-yellow{background-position:-108px -138px}.extra-marker-penta-blue-dark{background-position:-144px -138px}.extra-marker-penta-blue{background-position:-180px -138px}.extra-marker-penta-cyan{background-position:-216px -138px}.extra-marker-penta-purple{background-position:-252px -138px}.extra-marker-penta-violet{background-position:-288px -138px}.extra-marker-penta-pink{background-position:-324px -138px}.extra-marker-penta-green-dark{background-position:-360px -138px}.extra-marker-penta-green{background-position:-396px -138px}.extra-marker-penta-green-light{background-position:-432px -138px}.extra-marker-penta-black{background-position:-468px -138px}.extra-marker-penta-white{background-position:-504px -138px}.extra-marker .fa-number:before{content:attr(number)}
|
/*!
|
||||||
|
* Leaflet.extra-markers
|
||||||
|
* Custom Markers for Leaflet JS based on Awesome Markers
|
||||||
|
* Leaflet ExtraMarkers
|
||||||
|
* https://github.com/coryasilva/Leaflet.ExtraMarkers/
|
||||||
|
* @author coryasilva <https://github.com/coryasilva>
|
||||||
|
* @version 1.0.8
|
||||||
|
*/.extra-marker{background:url("../img/markers_default.png") no-repeat 0 0;width:35px;height:46px;position:absolute;left:0;top:0;display:block;text-align:center}.extra-marker-shadow{background:url("../img/markers_shadow.png") no-repeat 0 0;width:36px;height:16px}@media (min--moz-device-pixel-ratio:1.5),(-webkit-min-device-pixel-ratio:1.5),(min-device-pixel-ratio:1.5),(min-resolution:1.5dppx){.extra-marker{background-image:url("../img/markers_default@2x.png");background-size:540px 184px}.extra-marker-shadow{background-image:url("../img/markers_shadow@2x.png");background-size:35px 16px}}.extra-marker i{color:#fff;margin-top:7px;display:inline-block;font-size:14px}.extra-marker i.fa,.extra-marker i.glyphicon{margin-top:10px}.extra-marker i.icon{margin-right:0;opacity:1}.extra-marker-circle-red{background-position:0 0}.extra-marker-circle-orange-dark{background-position:-36px 0}.extra-marker-circle-orange{background-position:-72px 0}.extra-marker-circle-yellow{background-position:-108px 0}.extra-marker-circle-blue-dark{background-position:-144px 0}.extra-marker-circle-blue{background-position:-180px 0}.extra-marker-circle-cyan{background-position:-216px 0}.extra-marker-circle-purple{background-position:-252px 0}.extra-marker-circle-violet{background-position:-288px 0}.extra-marker-circle-pink{background-position:-324px 0}.extra-marker-circle-green-dark{background-position:-360px 0}.extra-marker-circle-green{background-position:-396px 0}.extra-marker-circle-green-light{background-position:-432px 0}.extra-marker-circle-black{background-position:-468px 0}.extra-marker-circle-white{background-position:-504px 0}.extra-marker-square-red{background-position:0 -46px}.extra-marker-square-orange-dark{background-position:-36px -46px}.extra-marker-square-orange{background-position:-72px -46px}.extra-marker-square-yellow{background-position:-108px -46px}.extra-marker-square-blue-dark{background-position:-144px -46px}.extra-marker-square-blue{background-position:-180px -46px}.extra-marker-square-cyan{background-position:-216px -46px}.extra-marker-square-purple{background-position:-252px -46px}.extra-marker-square-violet{background-position:-288px -46px}.extra-marker-square-pink{background-position:-324px -46px}.extra-marker-square-green-dark{background-position:-360px -46px}.extra-marker-square-green{background-position:-396px -46px}.extra-marker-square-green-light{background-position:-432px -46px}.extra-marker-square-black{background-position:-468px -46px}.extra-marker-square-white{background-position:-504px -46px}.extra-marker-star-red{background-position:0 -92px}.extra-marker-star-orange-dark{background-position:-36px -92px}.extra-marker-star-orange{background-position:-72px -92px}.extra-marker-star-yellow{background-position:-108px -92px}.extra-marker-star-blue-dark{background-position:-144px -92px}.extra-marker-star-blue{background-position:-180px -92px}.extra-marker-star-cyan{background-position:-216px -92px}.extra-marker-star-purple{background-position:-252px -92px}.extra-marker-star-violet{background-position:-288px -92px}.extra-marker-star-pink{background-position:-324px -92px}.extra-marker-star-green-dark{background-position:-360px -92px}.extra-marker-star-green{background-position:-396px -92px}.extra-marker-star-green-light{background-position:-432px -92px}.extra-marker-star-black{background-position:-468px -92px}.extra-marker-star-white{background-position:-504px -92px}.extra-marker-penta-red{background-position:0 -138px}.extra-marker-penta-orange-dark{background-position:-36px -138px}.extra-marker-penta-orange{background-position:-72px -138px}.extra-marker-penta-yellow{background-position:-108px -138px}.extra-marker-penta-blue-dark{background-position:-144px -138px}.extra-marker-penta-blue{background-position:-180px -138px}.extra-marker-penta-cyan{background-position:-216px -138px}.extra-marker-penta-purple{background-position:-252px -138px}.extra-marker-penta-violet{background-position:-288px -138px}.extra-marker-penta-pink{background-position:-324px -138px}.extra-marker-penta-green-dark{background-position:-360px -138px}.extra-marker-penta-green{background-position:-396px -138px}.extra-marker-penta-green-light{background-position:-432px -138px}.extra-marker-penta-black{background-position:-468px -138px}.extra-marker-penta-white{background-position:-504px -138px}.extra-marker .fa-number:before{content:attr(number)}
|
||||||
120
assets/leaflet-extra-markers/js/leaflet.extra-markers.js
Normal file
120
assets/leaflet-extra-markers/js/leaflet.extra-markers.js
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
/*!
|
||||||
|
* Leaflet.extra-markers
|
||||||
|
* Custom Markers for Leaflet JS based on Awesome Markers
|
||||||
|
* Leaflet ExtraMarkers
|
||||||
|
* https://github.com/coryasilva/Leaflet.ExtraMarkers/
|
||||||
|
* @author coryasilva <https://github.com/coryasilva>
|
||||||
|
* @version 1.0.8
|
||||||
|
*/
|
||||||
|
|
||||||
|
(function (global, factory) {
|
||||||
|
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
|
||||||
|
typeof define === 'function' && define.amd ? define(['exports'], factory) :
|
||||||
|
(factory((global.leaflet = global.leaflet || {}, global.leaflet['extra-markers'] = {})));
|
||||||
|
}(this, (function (exports) { 'use strict';
|
||||||
|
|
||||||
|
var ExtraMarkers = L.ExtraMarkers = {};
|
||||||
|
ExtraMarkers.version = L.ExtraMarkers.version = "1.0.8";
|
||||||
|
ExtraMarkers.Icon = L.ExtraMarkers.Icon = L.Icon.extend({
|
||||||
|
options: {
|
||||||
|
iconSize: [ 35, 45 ],
|
||||||
|
iconAnchor: [ 17, 42 ],
|
||||||
|
popupAnchor: [ 1, -32 ],
|
||||||
|
shadowAnchor: [ 10, 12 ],
|
||||||
|
shadowSize: [ 36, 16 ],
|
||||||
|
className: "",
|
||||||
|
prefix: "",
|
||||||
|
extraClasses: "",
|
||||||
|
shape: "circle",
|
||||||
|
icon: "",
|
||||||
|
innerHTML: "",
|
||||||
|
markerColor: "red",
|
||||||
|
svgBorderColor: "#fff",
|
||||||
|
svgOpacity: 1,
|
||||||
|
iconColor: "#fff",
|
||||||
|
number: "",
|
||||||
|
svg: false
|
||||||
|
},
|
||||||
|
initialize: function(options) {
|
||||||
|
options = L.Util.setOptions(this, options);
|
||||||
|
},
|
||||||
|
createIcon: function() {
|
||||||
|
var div = document.createElement("div"), options = this.options;
|
||||||
|
if (options.icon) {
|
||||||
|
div.innerHTML = this._createInner();
|
||||||
|
}
|
||||||
|
if (options.innerHTML) {
|
||||||
|
div.innerHTML = options.innerHTML;
|
||||||
|
}
|
||||||
|
if (options.bgPos) {
|
||||||
|
div.style.backgroundPosition = -options.bgPos.x + "px " + -options.bgPos.y + "px";
|
||||||
|
}
|
||||||
|
if (!options.svg) {
|
||||||
|
this._setIconStyles(div, options.shape + "-" + options.markerColor);
|
||||||
|
} else {
|
||||||
|
this._setIconStyles(div, "svg");
|
||||||
|
}
|
||||||
|
return div;
|
||||||
|
},
|
||||||
|
_createInner: function() {
|
||||||
|
var iconColorStyle = "", iconNumber = "", options = this.options;
|
||||||
|
if (options.iconColor) {
|
||||||
|
iconColorStyle = "style='color: " + options.iconColor + "' ";
|
||||||
|
}
|
||||||
|
if (options.number) {
|
||||||
|
iconNumber = "number='" + options.number + "' ";
|
||||||
|
}
|
||||||
|
if (options.svg) {
|
||||||
|
var svg = '<svg xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 69.529271 95.44922" style="fill:' + options.markerColor + ";stroke:" + options.svgBorderColor + ";fill-opacity:" + options.svgOpacity + ';" height="100%" width="100%" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/"><g transform="translate(-139.52 -173.21)"><path d="m174.28 173.21c-19.199 0.00035-34.764 15.355-34.764 34.297 0.007 6.7035 1.5591 12.813 5.7461 18.854l0.0234 0.0371 28.979 42.262 28.754-42.107c3.1982-5.8558 5.9163-11.544 6.0275-19.045-0.0001-18.942-15.565-34.298-34.766-34.297z"/></g></svg>';
|
||||||
|
if (options.shape === "square") {
|
||||||
|
svg = '<svg xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 69.457038 96.523441" style="fill:' + options.markerColor + ";stroke:" + options.svgBorderColor + ";fill-opacity:" + options.svgOpacity + ';" height="100%" width="100%" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/"><g transform="translate(-545.27 -658.39)"><path d="m545.27 658.39v65.301h22.248l12.48 31.223 12.676-31.223h22.053v-65.301h-69.457z"/></g></svg>';
|
||||||
|
}
|
||||||
|
if (options.shape === "star") {
|
||||||
|
svg = '<svg style="top:0; fill:' + options.markerColor + ";stroke:" + options.svgBorderColor + ";fill-opacity:" + options.svgOpacity + ';" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" height="100%" width="100%" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" viewBox="0 0 77.690999 101.4702"><g transform="translate(-101.15 -162.97)"><g transform="matrix(1 0 0 1.0165 -65.712 -150.28)"><path d="m205.97 308.16-11.561 11.561h-16.346v16.346l-11.197 11.197 11.197 11.197v15.83h15.744l11.615 33.693 11.467-33.568 0.125-0.125h16.346v-16.346l11.197-11.197-11.197-11.197v-15.83h-15.83l-11.561-11.561z"/></g></g></svg>';
|
||||||
|
}
|
||||||
|
if (options.shape === "penta") {
|
||||||
|
svg = '<svg style="fill:' + options.markerColor + ";stroke:" + options.svgBorderColor + ";fill-opacity:" + options.svgOpacity + ';" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 71.550368 96.362438" height="100%" width="100%" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/"><g transform="translate(-367.08 -289.9)"><path d="m367.08 322.5 17.236-32.604h36.151l18.164 32.25-35.665 64.112z"/></g></svg>';
|
||||||
|
}
|
||||||
|
return svg + "<i " + iconNumber + iconColorStyle + "class='" + options.extraClasses + " " + options.prefix + " " + options.icon + "'></i>";
|
||||||
|
}
|
||||||
|
return "<i " + iconNumber + iconColorStyle + "class='" + options.extraClasses + " " + options.prefix + " " + options.icon + "'></i>";
|
||||||
|
},
|
||||||
|
_setIconStyles: function(img, name) {
|
||||||
|
var options = this.options, size = L.point(options[name === "shadow" ? "shadowSize" : "iconSize"]), anchor, leafletName;
|
||||||
|
if (name === "shadow") {
|
||||||
|
anchor = L.point(options.shadowAnchor || options.iconAnchor);
|
||||||
|
leafletName = "shadow";
|
||||||
|
} else {
|
||||||
|
anchor = L.point(options.iconAnchor);
|
||||||
|
leafletName = "icon";
|
||||||
|
}
|
||||||
|
if (!anchor && size) {
|
||||||
|
anchor = size.divideBy(2, true);
|
||||||
|
}
|
||||||
|
img.className = "leaflet-marker-" + leafletName + " extra-marker extra-marker-" + name + " " + options.className;
|
||||||
|
if (anchor) {
|
||||||
|
img.style.marginLeft = -anchor.x + "px";
|
||||||
|
img.style.marginTop = -anchor.y + "px";
|
||||||
|
}
|
||||||
|
if (size) {
|
||||||
|
img.style.width = size.x + "px";
|
||||||
|
img.style.height = size.y + "px";
|
||||||
|
}
|
||||||
|
},
|
||||||
|
createShadow: function() {
|
||||||
|
var div = document.createElement("div");
|
||||||
|
this._setIconStyles(div, "shadow");
|
||||||
|
return div;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
ExtraMarkers.icon = L.ExtraMarkers.icon = function(options) {
|
||||||
|
return new L.ExtraMarkers.Icon(options);
|
||||||
|
};
|
||||||
|
|
||||||
|
exports.ExtraMarkers = ExtraMarkers;
|
||||||
|
|
||||||
|
Object.defineProperty(exports, '__esModule', { value: true });
|
||||||
|
|
||||||
|
})));
|
||||||
|
|
||||||
|
//# sourceMappingURL=leaflet.extra-markers.js.map
|
||||||
File diff suppressed because one or more lines are too long
@@ -1 +1,10 @@
|
|||||||
!function(a,b){"use strict";L.ExtraMarkers={},L.ExtraMarkers.version="1.0.1",L.ExtraMarkers.Icon=L.Icon.extend({options:{iconSize:[35,45],iconAnchor:[17,42],popupAnchor:[1,-32],shadowAnchor:[10,12],shadowSize:[36,16],className:"extra-marker",prefix:"",extraClasses:"",shape:"circle",icon:"",innerHTML:"",markerColor:"red",iconColor:"#fff",number:""},initialize:function(a){a=L.Util.setOptions(this,a)},createIcon:function(){var a=b.createElement("div"),c=this.options;return c.icon&&(a.innerHTML=this._createInner()),c.innerHTML&&(a.innerHTML=c.innerHTML),c.bgPos&&(a.style.backgroundPosition=-c.bgPos.x+"px "+-c.bgPos.y+"px"),this._setIconStyles(a,c.shape+"-"+c.markerColor),a},_createInner:function(){var a="",b="",c=this.options;return c.iconColor&&(a="style='color: "+c.iconColor+"' "),c.number&&(b="number='"+c.number+"' "),"<i "+b+a+"class='"+c.extraClasses+" "+c.prefix+" "+c.icon+"'></i>"},_setIconStyles:function(a,b){var c,d,e=this.options,f=L.point(e["shadow"===b?"shadowSize":"iconSize"]);"shadow"===b?(c=L.point(e.shadowAnchor||e.iconAnchor),d="shadow"):(c=L.point(e.iconAnchor),d="icon"),!c&&f&&(c=f.divideBy(2,!0)),a.className="leaflet-marker-"+d+" extra-marker-"+b+" "+e.className,c&&(a.style.marginLeft=-c.x+"px",a.style.marginTop=-c.y+"px"),f&&(a.style.width=f.x+"px",a.style.height=f.y+"px")},createShadow:function(){var a=b.createElement("div");return this._setIconStyles(a,"shadow"),a}}),L.ExtraMarkers.icon=function(a){return new L.ExtraMarkers.Icon(a)}}(window,document);
|
/*!
|
||||||
|
* Leaflet.extra-markers
|
||||||
|
* Custom Markers for Leaflet JS based on Awesome Markers
|
||||||
|
* Leaflet ExtraMarkers
|
||||||
|
* https://github.com/coryasilva/Leaflet.ExtraMarkers/
|
||||||
|
* @author coryasilva <https://github.com/coryasilva>
|
||||||
|
* @version 1.0.8
|
||||||
|
*/
|
||||||
|
|
||||||
|
!function(e,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports):"function"==typeof define&&define.amd?define(["exports"],r):r((e.leaflet=e.leaflet||{},e.leaflet["extra-markers"]={}))}(this,function(e){"use strict";var r=L.ExtraMarkers={};r.version=L.ExtraMarkers.version="1.0.8",r.Icon=L.ExtraMarkers.Icon=L.Icon.extend({options:{iconSize:[35,45],iconAnchor:[17,42],popupAnchor:[1,-32],shadowAnchor:[10,12],shadowSize:[36,16],className:"",prefix:"",extraClasses:"",shape:"circle",icon:"",innerHTML:"",markerColor:"red",svgBorderColor:"#fff",svgOpacity:1,iconColor:"#fff",number:"",svg:!1},initialize:function(e){e=L.Util.setOptions(this,e)},createIcon:function(){var e=document.createElement("div"),r=this.options;return r.icon&&(e.innerHTML=this._createInner()),r.innerHTML&&(e.innerHTML=r.innerHTML),r.bgPos&&(e.style.backgroundPosition=-r.bgPos.x+"px "+-r.bgPos.y+"px"),r.svg?this._setIconStyles(e,"svg"):this._setIconStyles(e,r.shape+"-"+r.markerColor),e},_createInner:function(){var e="",r="",t=this.options;if(t.iconColor&&(e="style='color: "+t.iconColor+"' "),t.number&&(r="number='"+t.number+"' "),t.svg){var s='<svg xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 69.529271 95.44922" style="fill:'+t.markerColor+";stroke:"+t.svgBorderColor+";fill-opacity:"+t.svgOpacity+';" height="100%" width="100%" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/"><g transform="translate(-139.52 -173.21)"><path d="m174.28 173.21c-19.199 0.00035-34.764 15.355-34.764 34.297 0.007 6.7035 1.5591 12.813 5.7461 18.854l0.0234 0.0371 28.979 42.262 28.754-42.107c3.1982-5.8558 5.9163-11.544 6.0275-19.045-0.0001-18.942-15.565-34.298-34.766-34.297z"/></g></svg>';return"square"===t.shape&&(s='<svg xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 69.457038 96.523441" style="fill:'+t.markerColor+";stroke:"+t.svgBorderColor+";fill-opacity:"+t.svgOpacity+';" height="100%" width="100%" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/"><g transform="translate(-545.27 -658.39)"><path d="m545.27 658.39v65.301h22.248l12.48 31.223 12.676-31.223h22.053v-65.301h-69.457z"/></g></svg>'),"star"===t.shape&&(s='<svg style="top:0; fill:'+t.markerColor+";stroke:"+t.svgBorderColor+";fill-opacity:"+t.svgOpacity+';" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" height="100%" width="100%" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" viewBox="0 0 77.690999 101.4702"><g transform="translate(-101.15 -162.97)"><g transform="matrix(1 0 0 1.0165 -65.712 -150.28)"><path d="m205.97 308.16-11.561 11.561h-16.346v16.346l-11.197 11.197 11.197 11.197v15.83h15.744l11.615 33.693 11.467-33.568 0.125-0.125h16.346v-16.346l11.197-11.197-11.197-11.197v-15.83h-15.83l-11.561-11.561z"/></g></g></svg>'),"penta"===t.shape&&(s='<svg style="fill:'+t.markerColor+";stroke:"+t.svgBorderColor+";fill-opacity:"+t.svgOpacity+';" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 71.550368 96.362438" height="100%" width="100%" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/"><g transform="translate(-367.08 -289.9)"><path d="m367.08 322.5 17.236-32.604h36.151l18.164 32.25-35.665 64.112z"/></g></svg>'),s+"<i "+r+e+"class='"+t.extraClasses+" "+t.prefix+" "+t.icon+"'></i>"}return"<i "+r+e+"class='"+t.extraClasses+" "+t.prefix+" "+t.icon+"'></i>"},_setIconStyles:function(e,r){var t,s,o=this.options,n=L.point(o["shadow"===r?"shadowSize":"iconSize"]);"shadow"===r?(t=L.point(o.shadowAnchor||o.iconAnchor),s="shadow"):(t=L.point(o.iconAnchor),s="icon"),!t&&n&&(t=n.divideBy(2,!0)),e.className="leaflet-marker-"+s+" extra-marker extra-marker-"+r+" "+o.className,t&&(e.style.marginLeft=-t.x+"px",e.style.marginTop=-t.y+"px"),n&&(e.style.width=n.x+"px",e.style.height=n.y+"px")},createShadow:function(){var e=document.createElement("div");return this._setIconStyles(e,"shadow"),e}}),r.icon=L.ExtraMarkers.icon=function(e){return new L.ExtraMarkers.Icon(e)},e.ExtraMarkers=r,Object.defineProperty(e,"__esModule",{value:!0})});
|
||||||
32
assets/leaflet-extra-markers/leaflet.extra-markers.d.ts
vendored
Normal file
32
assets/leaflet-extra-markers/leaflet.extra-markers.d.ts
vendored
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
import * as L from "leaflet";
|
||||||
|
|
||||||
|
declare module "leaflet" {
|
||||||
|
export namespace ExtraMarkers {
|
||||||
|
export interface IconOptions extends L.BaseIconOptions {
|
||||||
|
/** Additional classes in the created <i> tag. */
|
||||||
|
extraClasses?: string;
|
||||||
|
/** Name of the icon with prefix. */
|
||||||
|
icon?: string;
|
||||||
|
/** Color of the icon. Default value 'white'. */
|
||||||
|
iconColor?: string;
|
||||||
|
/** Custom HTML code. */
|
||||||
|
innerHTML?: string;
|
||||||
|
/** Color of the marker (css class). Default value 'blue'. */
|
||||||
|
markerColor?: "red" | "orange-dark" | "orange" | "yellow" | "blue" | "blue-dark" | "cyan" | "purple"
|
||||||
|
| "violet" | "pink" | "green-dark" | "green" | "green-light" | "black" | "white";
|
||||||
|
/** Instead of an icon, define a plain text. */
|
||||||
|
number?: string;
|
||||||
|
/** The icon library's base class. Default value 'glyphicon'. */
|
||||||
|
prefix?: string;
|
||||||
|
/** Shape of the marker (css class). Default value 'circle'. */
|
||||||
|
shape?: "circle" | "square" | "star" | "penta";
|
||||||
|
}
|
||||||
|
|
||||||
|
export class Icon extends L.Icon {
|
||||||
|
constructor(options: IconOptions)
|
||||||
|
}
|
||||||
|
|
||||||
|
export function icon(options: IconOptions): Icon;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@@ -2,20 +2,27 @@
|
|||||||
"name": "Leaflet.extra-markers",
|
"name": "Leaflet.extra-markers",
|
||||||
"title": "Leaflet ExtraMarkers",
|
"title": "Leaflet ExtraMarkers",
|
||||||
"url": "https://github.com/coryasilva/Leaflet.ExtraMarkers/",
|
"url": "https://github.com/coryasilva/Leaflet.ExtraMarkers/",
|
||||||
"version": "1.0.6",
|
"version": "1.0.8",
|
||||||
"description": "Custom Markers for Leaflet JS based on Awesome Markers",
|
"description": "Custom Markers for Leaflet JS based on Awesome Markers",
|
||||||
"author": "coryasilva <https://github.com/coryasilva>",
|
"author": "coryasilva <https://github.com/coryasilva>",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/coryasilva/Leaflet.ExtraMarkers"
|
"url": "https://github.com/coryasilva/Leaflet.ExtraMarkers"
|
||||||
},
|
},
|
||||||
"main": "src/assets/js/leaflet.extra-markers.js",
|
"main": "dist/js/leaflet.extra-markers.js",
|
||||||
|
"types": "dist/leaflet.extra-markers.d.ts",
|
||||||
|
"peerDependencies": {
|
||||||
|
"leaflet": ">= 0.5 < 2"
|
||||||
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"grunt": "^0.4.5",
|
"git-rev-sync": "^1.10.0",
|
||||||
"grunt-contrib-jshint": "^0.11.0",
|
"grunt": "^1.0.2",
|
||||||
"grunt-contrib-uglify": "^0.8.0",
|
"grunt-contrib-jshint": "^1.1.0",
|
||||||
"grunt-contrib-less": "^1.1.0",
|
"grunt-contrib-less": "^1.4.1",
|
||||||
|
"grunt-contrib-uglify": "^3.3.0",
|
||||||
|
"grunt-rollup": "^9.0.0",
|
||||||
"less-plugin-autoprefix": "^1.5.1",
|
"less-plugin-autoprefix": "^1.5.1",
|
||||||
"time-grunt": "^1.1.0"
|
"rollup-plugin-git-version": "^0.2.1",
|
||||||
|
"time-grunt": "^1.4.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -85,7 +85,7 @@ $GLOBALS['LEAFLET_LIBRARIES']['leaflet-control-geocoder'] = array
|
|||||||
$GLOBALS['LEAFLET_LIBRARIES']['leaflet-extra-markers'] = array
|
$GLOBALS['LEAFLET_LIBRARIES']['leaflet-extra-markers'] = array
|
||||||
(
|
(
|
||||||
'name' => 'Leaflet Extra Markers',
|
'name' => 'Leaflet Extra Markers',
|
||||||
'version' => '1.0.6',
|
'version' => '1.0.8',
|
||||||
'license' => '<a href="https://github.com/coryasilva/Leaflet.ExtraMarkers/blob/master/LICENSE" target="_blank">MIT</a>',
|
'license' => '<a href="https://github.com/coryasilva/Leaflet.ExtraMarkers/blob/master/LICENSE" target="_blank">MIT</a>',
|
||||||
'homepage' => 'https://github.com/coryasilva/Leaflet.ExtraMarkers',
|
'homepage' => 'https://github.com/coryasilva/Leaflet.ExtraMarkers',
|
||||||
'css' => 'assets/leaflet/libs/leaflet-extra-markers/css/leaflet.extra-markers.min.css',
|
'css' => 'assets/leaflet/libs/leaflet-extra-markers/css/leaflet.extra-markers.min.css',
|
||||||
|
|||||||
Reference in New Issue
Block a user