@nextgis/ngw-leaflet 1.19.5 → 2.0.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,8 @@
1
- /** Bundle of @nextgis/ngw-leaflet; version: 1.19.5; author: NextGIS */
1
+ /** Bundle of @nextgis/ngw-leaflet; version: 2.0.0-alpha.0; author: NextGIS */
2
2
  import 'leaflet/dist/leaflet.css';
3
- import { Icon } from 'leaflet';
4
- import { NgwMap } from '@nextgis/ngw-map';
5
3
  import LeafletMapAdapter from '@nextgis/leaflet-map-adapter';
4
+ import { NgwMap } from '@nextgis/ngw-map';
5
+ import { Icon } from 'leaflet';
6
6
  import iconRetinaUrl from 'leaflet/dist/images/marker-icon-2x.png';
7
7
  import iconUrl from 'leaflet/dist/images/marker-icon.png';
8
8
  import shadowUrl from 'leaflet/dist/images/marker-shadow.png';
@@ -37,52 +37,65 @@ function styleInject(css, ref) {
37
37
  var css_248z = ".ngw-map-container.leaflet-container{background:#fff}.leaflet-pane .leaflet-popup-pane{z-index:9999999999}";
38
38
  styleInject(css_248z);
39
39
 
40
- /**
41
- * Single-file bundle for rapid deployment of {@link https://leafletjs.com/ | Leaflet }-based web-gis applications with NextGIS services
42
- *
43
- * @remarks
44
- * Styles images and other assets are already in bundle, you don't need to include anything except one JS file!
45
- *
46
- * @packageDocumentation
47
- * @module ngw-leaflet
48
- */
49
- // @ts-ignore
40
+ var __defProp = Object.defineProperty;
41
+ var __defProps = Object.defineProperties;
42
+ var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
43
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
44
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
45
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
46
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
47
+ var __spreadValues = (a, b) => {
48
+ for (var prop in b || (b = {}))
49
+ if (__hasOwnProp.call(b, prop))
50
+ __defNormalProp(a, prop, b[prop]);
51
+ if (__getOwnPropSymbols)
52
+ for (var prop of __getOwnPropSymbols(b)) {
53
+ if (__propIsEnum.call(b, prop))
54
+ __defNormalProp(a, prop, b[prop]);
55
+ }
56
+ return a;
57
+ };
58
+ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
59
+ var __async = (__this, __arguments, generator) => {
60
+ return new Promise((resolve, reject) => {
61
+ var fulfilled = (value) => {
62
+ try {
63
+ step(generator.next(value));
64
+ } catch (e) {
65
+ reject(e);
66
+ }
67
+ };
68
+ var rejected = (value) => {
69
+ try {
70
+ step(generator.throw(value));
71
+ } catch (e) {
72
+ reject(e);
73
+ }
74
+ };
75
+ var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
76
+ step((generator = generator.apply(__this, __arguments)).next());
77
+ });
78
+ };
50
79
  delete Icon.Default.prototype._getIconUrl;
51
80
  Icon.Default.mergeOptions({
52
- iconRetinaUrl: iconRetinaUrl,
53
- iconUrl: iconUrl,
54
- shadowUrl: shadowUrl,
81
+ iconRetinaUrl,
82
+ iconUrl,
83
+ shadowUrl
55
84
  });
56
- /**
57
- * Displaying the [NgwMap](ngw-map-api)
58
- * using the [LeafletMapAdapter](leaflet-map-adapter-api)
59
- *
60
- * @example
61
- * ```javascript
62
- * // Base initialization
63
- * // [live demo](http://code.nextgis.com/ngw-leaflet-examples-ngw-webmap)
64
- * import { NgwMap } from '@nextgis/ngw-leaflet';
65
- *
66
- * const ngwMap = new NgwMap({
67
- * target: 'map',
68
- * qmsId: 448,
69
- * baseUrl: 'https://demo.nextgis.com',
70
- * webmapId: 3985
71
- * });
72
- * ```
73
- */
74
85
  class NgwLeaflet extends NgwMap {
75
- constructor(options) {
76
- options = { ...options, mapAdapter: new LeafletMapAdapter() };
77
- super(options);
78
- }
79
- static async create(options) {
80
- const ngwMap = new NgwLeaflet(options);
81
- return ngwMap.onLoad();
82
- }
86
+ constructor(options) {
87
+ options = __spreadProps(__spreadValues({}, options), { mapAdapter: new LeafletMapAdapter() });
88
+ super(options);
89
+ }
90
+ static create(options) {
91
+ return __async(this, null, function* () {
92
+ const ngwMap = new NgwLeaflet(options);
93
+ return ngwMap.onLoad();
94
+ });
95
+ }
83
96
  }
84
97
  if (window && !window.NgwMap) {
85
- window.NgwMap = NgwLeaflet;
98
+ window.NgwMap = NgwLeaflet;
86
99
  }
87
100
 
88
101
  export { NgwLeaflet as default };
@@ -1 +1 @@
1
- {"version":3,"file":"ngw-leaflet.esm-bundler.js","sources":["../../../node_modules/style-inject/dist/style-inject.es.js","../src/index.ts"],"sourcesContent":["function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n","/**\n * Single-file bundle for rapid deployment of {@link https://leafletjs.com/ | Leaflet }-based web-gis applications with NextGIS services\n *\n * @remarks\n * Styles images and other assets are already in bundle, you don't need to include anything except one JS file!\n *\n * @packageDocumentation\n * @module ngw-leaflet\n */\nimport 'leaflet/dist/leaflet.css';\nimport './leaflet-style-override.css';\n\nimport { Icon } from 'leaflet';\nimport { NgwMap, NgwMapOptions } from '@nextgis/ngw-map';\nimport LeafletMapAdapter from '@nextgis/leaflet-map-adapter';\n\nimport iconRetinaUrl from 'leaflet/dist/images/marker-icon-2x.png';\nimport iconUrl from 'leaflet/dist/images/marker-icon.png';\nimport shadowUrl from 'leaflet/dist/images/marker-shadow.png';\n\nimport { Map } from 'leaflet';\n\n// @ts-ignore\ndelete Icon.Default.prototype._getIconUrl;\n\nIcon.Default.mergeOptions({\n iconRetinaUrl: iconRetinaUrl,\n iconUrl: iconUrl,\n shadowUrl: shadowUrl,\n});\n\n/**\n * Displaying the [NgwMap](ngw-map-api)\n * using the [LeafletMapAdapter](leaflet-map-adapter-api)\n *\n * @example\n * ```javascript\n * // Base initialization\n * // [live demo](http://code.nextgis.com/ngw-leaflet-examples-ngw-webmap)\n * import { NgwMap } from '@nextgis/ngw-leaflet';\n *\n * const ngwMap = new NgwMap({\n * target: 'map',\n * qmsId: 448,\n * baseUrl: 'https://demo.nextgis.com',\n * webmapId: 3985\n * });\n * ```\n */\nclass NgwLeaflet extends NgwMap<Map> {\n constructor(options: NgwMapOptions) {\n options = { ...options, mapAdapter: new LeafletMapAdapter() };\n super(options);\n }\n static async create(options: NgwMapOptions): Promise<NgwLeaflet> {\n const ngwMap = new NgwLeaflet(options);\n return ngwMap.onLoad();\n }\n}\n\nexport default NgwLeaflet;\n\nif ((window as any) && !(window as any).NgwMap) {\n (window as any).NgwMap = NgwLeaflet;\n}\n"],"names":[],"mappings":";;;;;;;;;AAAA,SAAS,WAAW,CAAC,GAAG,EAAE,GAAG,EAAE;AAC/B,EAAE,KAAK,GAAG,KAAK,KAAK,CAAC,GAAG,GAAG,GAAG,EAAE,CAAC;AACjC,EAAE,IAAI,QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAC;AAC9B;AACA,EAAE,IAAI,CAAC,GAAG,IAAI,OAAO,QAAQ,KAAK,WAAW,EAAE,EAAE,OAAO,EAAE;AAC1D;AACA,EAAE,IAAI,IAAI,GAAG,QAAQ,CAAC,IAAI,IAAI,QAAQ,CAAC,oBAAoB,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;AACvE,EAAE,IAAI,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;AAC9C,EAAE,KAAK,CAAC,IAAI,GAAG,UAAU,CAAC;AAC1B;AACA,EAAE,IAAI,QAAQ,KAAK,KAAK,EAAE;AAC1B,IAAI,IAAI,IAAI,CAAC,UAAU,EAAE;AACzB,MAAM,IAAI,CAAC,YAAY,CAAC,KAAK,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;AAChD,KAAK,MAAM;AACX,MAAM,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC9B,KAAK;AACL,GAAG,MAAM;AACT,IAAI,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC5B,GAAG;AACH;AACA,EAAE,IAAI,KAAK,CAAC,UAAU,EAAE;AACxB,IAAI,KAAK,CAAC,UAAU,CAAC,OAAO,GAAG,GAAG,CAAC;AACnC,GAAG,MAAM;AACT,IAAI,KAAK,CAAC,WAAW,CAAC,QAAQ,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAC;AACpD,GAAG;AACH;;;;;ACzBA;;;;;;;;AAQG;AAcH;AACA,OAAO,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,WAAW,CAAC;AAE1C,IAAI,CAAC,OAAO,CAAC,YAAY,CAAC;AACxB,IAAA,aAAa,EAAE,aAAa;AAC5B,IAAA,OAAO,EAAE,OAAO;AAChB,IAAA,SAAS,EAAE,SAAS;AACrB,CAAA,CAAC,CAAC;AAEH;;;;;;;;;;;;;;;;;AAiBG;AACH,MAAM,UAAW,SAAQ,MAAW,CAAA;AAClC,IAAA,WAAA,CAAY,OAAsB,EAAA;QAChC,OAAO,GAAG,EAAE,GAAG,OAAO,EAAE,UAAU,EAAE,IAAI,iBAAiB,EAAE,EAAE,CAAC;QAC9D,KAAK,CAAC,OAAO,CAAC,CAAC;KAChB;AACD,IAAA,aAAa,MAAM,CAAC,OAAsB,EAAA;AACxC,QAAA,MAAM,MAAM,GAAG,IAAI,UAAU,CAAC,OAAO,CAAC,CAAC;AACvC,QAAA,OAAO,MAAM,CAAC,MAAM,EAAE,CAAC;KACxB;AACF,CAAA;AAID,IAAK,MAAc,IAAI,CAAE,MAAc,CAAC,MAAM,EAAE;AAC7C,IAAA,MAAc,CAAC,MAAM,GAAG,UAAU,CAAC;AACrC;;;;"}
1
+ {"version":3,"file":"ngw-leaflet.esm-bundler.js","sources":["../../../node_modules/style-inject/dist/style-inject.es.js","../src/index.ts"],"sourcesContent":["function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n","import 'leaflet/dist/leaflet.css';\nimport './leaflet-style-override.css';\n\nimport LeafletMapAdapter from '@nextgis/leaflet-map-adapter';\nimport { NgwMap } from '@nextgis/ngw-map';\nimport { Icon } from 'leaflet';\nimport iconRetinaUrl from 'leaflet/dist/images/marker-icon-2x.png';\nimport iconUrl from 'leaflet/dist/images/marker-icon.png';\nimport shadowUrl from 'leaflet/dist/images/marker-shadow.png';\n\nimport type { NgwMapOptions } from '@nextgis/ngw-map';\nimport type { Map } from 'leaflet';\n\n// @ts-ignore\ndelete Icon.Default.prototype._getIconUrl;\n\nIcon.Default.mergeOptions({\n iconRetinaUrl: iconRetinaUrl,\n iconUrl: iconUrl,\n shadowUrl: shadowUrl,\n});\n\n/**\n * Displaying the [NgwMap](ngw-map-api)\n * using the [LeafletMapAdapter](leaflet-map-adapter-api)\n *\n * @example\n * ```javascript\n * // Base initialization\n * // [live demo](http://code.nextgis.com/ngw-leaflet-examples-ngw-webmap)\n * import { NgwMap } from '@nextgis/ngw-leaflet';\n *\n * const ngwMap = new NgwMap({\n * target: 'map',\n * qmsId: 448,\n * baseUrl: 'https://demo.nextgis.com',\n * webmapId: 3985\n * });\n * ```\n */\nclass NgwLeaflet extends NgwMap<Map> {\n constructor(options: NgwMapOptions) {\n options = { ...options, mapAdapter: new LeafletMapAdapter() };\n super(options);\n }\n static async create(options: NgwMapOptions): Promise<NgwLeaflet> {\n const ngwMap = new NgwLeaflet(options);\n return ngwMap.onLoad();\n }\n}\n\nexport default NgwLeaflet;\n\nif ((window as any) && !(window as any).NgwMap) {\n (window as any).NgwMap = NgwLeaflet;\n}\n"],"names":[],"mappings":";;;;;;;;;AAAA,SAAS,WAAW,CAAC,GAAG,EAAE,GAAG,EAAE;AAC/B,EAAE,KAAK,GAAG,KAAK,KAAK,CAAC,GAAG,GAAG,GAAG,EAAE,CAAC;AACjC,EAAE,IAAI,QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAC;AAC9B;AACA,EAAE,IAAI,CAAC,GAAG,IAAI,OAAO,QAAQ,KAAK,WAAW,EAAE,EAAE,OAAO,EAAE;AAC1D;AACA,EAAE,IAAI,IAAI,GAAG,QAAQ,CAAC,IAAI,IAAI,QAAQ,CAAC,oBAAoB,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;AACvE,EAAE,IAAI,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;AAC9C,EAAE,KAAK,CAAC,IAAI,GAAG,UAAU,CAAC;AAC1B;AACA,EAAE,IAAI,QAAQ,KAAK,KAAK,EAAE;AAC1B,IAAI,IAAI,IAAI,CAAC,UAAU,EAAE;AACzB,MAAM,IAAI,CAAC,YAAY,CAAC,KAAK,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;AAChD,KAAK,MAAM;AACX,MAAM,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC9B,KAAK;AACL,GAAG,MAAM;AACT,IAAI,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC5B,GAAG;AACH;AACA,EAAE,IAAI,KAAK,CAAC,UAAU,EAAE;AACxB,IAAI,KAAK,CAAC,UAAU,CAAC,OAAO,GAAG,GAAG,CAAC;AACnC,GAAG,MAAM;AACT,IAAI,KAAK,CAAC,WAAW,CAAC,QAAQ,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAC;AACpD,GAAG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACXA,OAAO,IAAA,CAAK,QAAQ,SAAU,CAAA,WAAA,CAAA;AAE9B,IAAA,CAAK,QAAQ,YAAa,CAAA;AAAA,EACxB,aAAA;AAAA,EACA,OAAA;AAAA,EACA,SAAA;AACF,CAAC,CAAA,CAAA;AAoBD,MAAM,mBAAmB,MAAY,CAAA;AAAA,EACnC,YAAY,OAAwB,EAAA;AAClC,IAAA,OAAA,GAAU,iCAAK,OAAL,CAAA,EAAA,EAAc,UAAY,EAAA,IAAI,mBAAoB,EAAA,CAAA,CAAA;AAC5D,IAAA,KAAA,CAAM,OAAO,CAAA,CAAA;AAAA,GACf;AAAA,EACA,OAAa,OAAO,OAA6C,EAAA;AAAA,IAAA,OAAA,OAAA,CAAA,IAAA,EAAA,IAAA,EAAA,aAAA;AAC/D,MAAM,MAAA,MAAA,GAAS,IAAI,UAAA,CAAW,OAAO,CAAA,CAAA;AACrC,MAAA,OAAO,OAAO,MAAO,EAAA,CAAA;AAAA,KACvB,CAAA,CAAA;AAAA,GAAA;AACF,CAAA;AAIA,IAAK,MAAA,IAAkB,CAAE,MAAA,CAAe,MAAQ,EAAA;AAC9C,EAAC,OAAe,MAAS,GAAA,UAAA,CAAA;AAC3B;;;;","x_google_ignoreList":[0]}
@@ -1,2 +1,2 @@
1
- import"leaflet/dist/leaflet.css";import{Icon as e}from"leaflet";import{NgwMap as t}from"@nextgis/ngw-map";import a from"@nextgis/leaflet-map-adapter";import n from"leaflet/dist/images/marker-icon-2x.png";import o from"leaflet/dist/images/marker-icon.png";import r from"leaflet/dist/images/marker-shadow.png";!function(e,t){void 0===t&&(t={});var a=t.insertAt;if(e&&"undefined"!=typeof document){var n=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css","top"===a&&n.firstChild?n.insertBefore(o,n.firstChild):n.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}(".ngw-map-container.leaflet-container{background:#fff}.leaflet-pane .leaflet-popup-pane{z-index:9999999999}"),delete e.Default.prototype._getIconUrl,e.Default.mergeOptions({iconRetinaUrl:n,iconUrl:o,shadowUrl:r});class i extends t{constructor(e){super(e={...e,mapAdapter:new a})}static async create(e){return new i(e).onLoad()}}window&&!window.NgwMap&&(window.NgwMap=i);export{i as default};
1
+ import"leaflet/dist/leaflet.css";import e from"@nextgis/leaflet-map-adapter";import{NgwMap as t}from"@nextgis/ngw-map";import{Icon as r}from"leaflet";import a from"leaflet/dist/images/marker-icon-2x.png";import o from"leaflet/dist/images/marker-icon.png";import n from"leaflet/dist/images/marker-shadow.png";!function(e,t){void 0===t&&(t={});var r=t.insertAt;if(e&&"undefined"!=typeof document){var a=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css","top"===r&&a.firstChild?a.insertBefore(o,a.firstChild):a.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}(".ngw-map-container.leaflet-container{background:#fff}.leaflet-pane .leaflet-popup-pane{z-index:9999999999}");var i=Object.defineProperty,l=Object.defineProperties,p=Object.getOwnPropertyDescriptors,s=Object.getOwnPropertySymbols,c=Object.prototype.hasOwnProperty,d=Object.prototype.propertyIsEnumerable,f=(e,t,r)=>t in e?i(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;delete r.Default.prototype._getIconUrl,r.Default.mergeOptions({iconRetinaUrl:a,iconUrl:o,shadowUrl:n});class m extends t{constructor(t){var r,a;r=((e,t)=>{for(var r in t||(t={}))c.call(t,r)&&f(e,r,t[r]);if(s)for(var r of s(t))d.call(t,r)&&f(e,r,t[r]);return e})({},t),a={mapAdapter:new e},super(t=l(r,p(a)))}static create(e){return t=this,r=null,a=function*(){return new m(e).onLoad()},new Promise(((e,o)=>{var n=e=>{try{l(a.next(e))}catch(t){o(t)}},i=e=>{try{l(a.throw(e))}catch(t){o(t)}},l=t=>t.done?e(t.value):Promise.resolve(t.value).then(n,i);l((a=a.apply(t,r)).next())}));var t,r,a}}window&&!window.NgwMap&&(window.NgwMap=m);export{m as default};
2
2
  //# sourceMappingURL=ngw-leaflet.esm-bundler.prod.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ngw-leaflet.esm-bundler.prod.js","sources":["../../../node_modules/style-inject/dist/style-inject.es.js","../src/index.ts"],"sourcesContent":["function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n","/**\n * Single-file bundle for rapid deployment of {@link https://leafletjs.com/ | Leaflet }-based web-gis applications with NextGIS services\n *\n * @remarks\n * Styles images and other assets are already in bundle, you don't need to include anything except one JS file!\n *\n * @packageDocumentation\n * @module ngw-leaflet\n */\nimport 'leaflet/dist/leaflet.css';\nimport './leaflet-style-override.css';\n\nimport { Icon } from 'leaflet';\nimport { NgwMap, NgwMapOptions } from '@nextgis/ngw-map';\nimport LeafletMapAdapter from '@nextgis/leaflet-map-adapter';\n\nimport iconRetinaUrl from 'leaflet/dist/images/marker-icon-2x.png';\nimport iconUrl from 'leaflet/dist/images/marker-icon.png';\nimport shadowUrl from 'leaflet/dist/images/marker-shadow.png';\n\nimport { Map } from 'leaflet';\n\n// @ts-ignore\ndelete Icon.Default.prototype._getIconUrl;\n\nIcon.Default.mergeOptions({\n iconRetinaUrl: iconRetinaUrl,\n iconUrl: iconUrl,\n shadowUrl: shadowUrl,\n});\n\n/**\n * Displaying the [NgwMap](ngw-map-api)\n * using the [LeafletMapAdapter](leaflet-map-adapter-api)\n *\n * @example\n * ```javascript\n * // Base initialization\n * // [live demo](http://code.nextgis.com/ngw-leaflet-examples-ngw-webmap)\n * import { NgwMap } from '@nextgis/ngw-leaflet';\n *\n * const ngwMap = new NgwMap({\n * target: 'map',\n * qmsId: 448,\n * baseUrl: 'https://demo.nextgis.com',\n * webmapId: 3985\n * });\n * ```\n */\nclass NgwLeaflet extends NgwMap<Map> {\n constructor(options: NgwMapOptions) {\n options = { ...options, mapAdapter: new LeafletMapAdapter() };\n super(options);\n }\n static async create(options: NgwMapOptions): Promise<NgwLeaflet> {\n const ngwMap = new NgwLeaflet(options);\n return ngwMap.onLoad();\n }\n}\n\nexport default NgwLeaflet;\n\nif ((window as any) && !(window as any).NgwMap) {\n (window as any).NgwMap = NgwLeaflet;\n}\n"],"names":["css","ref","insertAt","document","head","getElementsByTagName","style","createElement","type","firstChild","insertBefore","appendChild","styleSheet","cssText","createTextNode","Icon","Default","prototype","_getIconUrl","mergeOptions","iconRetinaUrl","iconUrl","shadowUrl","NgwLeaflet","NgwMap","constructor","options","super","mapAdapter","LeafletMapAdapter","create","onLoad","window"],"mappings":"qTAAA,SAAqBA,EAAKC,QACX,IAARA,IAAiBA,EAAM,CAAA,GAC5B,IAAIC,EAAWD,EAAIC,SAEnB,GAAKF,GAA2B,oBAAbG,SAAnB,CAEA,IAAIC,EAAOD,SAASC,MAAQD,SAASE,qBAAqB,QAAQ,GAC9DC,EAAQH,SAASI,cAAc,SACnCD,EAAME,KAAO,WAEI,QAAbN,GACEE,EAAKK,WACPL,EAAKM,aAAaJ,EAAOF,EAAKK,YAKhCL,EAAKO,YAAYL,GAGfA,EAAMM,WACRN,EAAMM,WAAWC,QAAUb,EAE3BM,EAAMK,YAAYR,SAASW,eAAed,GAnBY,CAqB1D,uHCFOe,EAAKC,QAAQC,UAAUC,YAE9BH,EAAKC,QAAQG,aAAa,CACxBC,cAAeA,EACfC,QAASA,EACTC,UAAWA,IAqBb,MAAMC,UAAmBC,EACvB,WAAAC,CAAYC,GAEVC,MADAD,EAAU,IAAKA,EAASE,WAAY,IAAIC,GAEzC,CACD,mBAAaC,CAAOJ,GAElB,OADe,IAAIH,EAAWG,GAChBK,QACf,EAKEC,SAAoBA,OAAeR,SACrCQ,OAAeR,OAASD"}
1
+ {"version":3,"file":"ngw-leaflet.esm-bundler.prod.js","sources":["../../../node_modules/style-inject/dist/style-inject.es.js","../src/index.ts"],"sourcesContent":["function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n","import 'leaflet/dist/leaflet.css';\nimport './leaflet-style-override.css';\n\nimport LeafletMapAdapter from '@nextgis/leaflet-map-adapter';\nimport { NgwMap } from '@nextgis/ngw-map';\nimport { Icon } from 'leaflet';\nimport iconRetinaUrl from 'leaflet/dist/images/marker-icon-2x.png';\nimport iconUrl from 'leaflet/dist/images/marker-icon.png';\nimport shadowUrl from 'leaflet/dist/images/marker-shadow.png';\n\nimport type { NgwMapOptions } from '@nextgis/ngw-map';\nimport type { Map } from 'leaflet';\n\n// @ts-ignore\ndelete Icon.Default.prototype._getIconUrl;\n\nIcon.Default.mergeOptions({\n iconRetinaUrl: iconRetinaUrl,\n iconUrl: iconUrl,\n shadowUrl: shadowUrl,\n});\n\n/**\n * Displaying the [NgwMap](ngw-map-api)\n * using the [LeafletMapAdapter](leaflet-map-adapter-api)\n *\n * @example\n * ```javascript\n * // Base initialization\n * // [live demo](http://code.nextgis.com/ngw-leaflet-examples-ngw-webmap)\n * import { NgwMap } from '@nextgis/ngw-leaflet';\n *\n * const ngwMap = new NgwMap({\n * target: 'map',\n * qmsId: 448,\n * baseUrl: 'https://demo.nextgis.com',\n * webmapId: 3985\n * });\n * ```\n */\nclass NgwLeaflet extends NgwMap<Map> {\n constructor(options: NgwMapOptions) {\n options = { ...options, mapAdapter: new LeafletMapAdapter() };\n super(options);\n }\n static async create(options: NgwMapOptions): Promise<NgwLeaflet> {\n const ngwMap = new NgwLeaflet(options);\n return ngwMap.onLoad();\n }\n}\n\nexport default NgwLeaflet;\n\nif ((window as any) && !(window as any).NgwMap) {\n (window as any).NgwMap = NgwLeaflet;\n}\n"],"names":["css","ref","insertAt","document","head","getElementsByTagName","style","createElement","type","firstChild","insertBefore","appendChild","styleSheet","cssText","createTextNode","Icon","Default","prototype","_getIconUrl","mergeOptions","iconRetinaUrl","iconUrl","shadowUrl","NgwLeaflet","NgwMap","constructor","options","mapAdapter","LeafletMapAdapter","super","create","this","onLoad","window"],"mappings":"qTAAA,SAAqBA,EAAKC,QACX,IAARA,IAAiBA,EAAM,CAAA,GAC5B,IAAIC,EAAWD,EAAIC,SAEnB,GAAKF,GAA2B,oBAAbG,SAAnB,CAEA,IAAIC,EAAOD,SAASC,MAAQD,SAASE,qBAAqB,QAAQ,GAC9DC,EAAQH,SAASI,cAAc,SACnCD,EAAME,KAAO,WAEI,QAAbN,GACEE,EAAKK,WACPL,EAAKM,aAAaJ,EAAOF,EAAKK,YAKhCL,EAAKO,YAAYL,GAGfA,EAAMM,WACRN,EAAMM,WAAWC,QAAUb,EAE3BM,EAAMK,YAAYR,SAASW,eAAed,GAnBY,CAqB1D,6YCXOe,EAAKC,QAAQC,UAAUC,YAE9BH,EAAKC,QAAQG,aAAa,CACxBC,gBACAC,UACAC,cAqBF,MAAMC,UAAmBC,EACvB,WAAAC,CAAYC,oIACKA,KAAL,CAAcC,WAAY,IAAIC,GACxCC,MADAH,YAEF,CACA,aAAaI,CAAOJ,GAA6C,SAAAK,OAAA,OAAA,YAE/D,OADe,IAAIR,EAAWG,GAChBM,QAAO,2MACvB,EAKGC,SAAoBA,OAAeT,SACrCS,OAAeT,OAASD","x_google_ignoreList":[0]}