@molecule/app-maps-leaflet 1.0.3 → 1.0.4
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.
- package/dist/provider.d.ts.map +1 -1
- package/dist/provider.js +4 -2
- package/package.json +1 -1
package/dist/provider.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"provider.d.ts","sourceRoot":"","sources":["../src/provider.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAIH,OAAO,KAAK,EAOV,WAAW,EAMZ,MAAM,oBAAoB,CAAA;
|
|
1
|
+
{"version":3,"file":"provider.d.ts","sourceRoot":"","sources":["../src/provider.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAIH,OAAO,KAAK,EAOV,WAAW,EAMZ,MAAM,oBAAoB,CAAA;AAqN3B;;;;GAIG;AACH,eAAO,MAAM,cAAc,QAAO,WAqBhC,CAAA;AAEF,oFAAoF;AACpF,eAAO,MAAM,QAAQ,EAAE,WAA8B,CAAA"}
|
package/dist/provider.js
CHANGED
|
@@ -12,10 +12,12 @@ const OSM_ATTRIBUTION = '© OpenStreetMap contributors';
|
|
|
12
12
|
/**
|
|
13
13
|
* Default marker icon as an inline-SVG `divIcon`. Leaflet's PNG default icons
|
|
14
14
|
* 404 under most bundlers (they resolve relative to the CSS), so a self-contained
|
|
15
|
-
* SVG pin makes markers render out-of-the-box with zero asset wiring.
|
|
15
|
+
* SVG pin makes markers render out-of-the-box with zero asset wiring. The empty
|
|
16
|
+
* `className` replaces Leaflet's default `leaflet-div-icon` (a white box behind the
|
|
17
|
+
* pin) without adding a class of our own.
|
|
16
18
|
*/
|
|
17
19
|
const defaultIcon = (color = '#2563eb') => L.divIcon({
|
|
18
|
-
className: '
|
|
20
|
+
className: '',
|
|
19
21
|
html: `<svg width="26" height="38" viewBox="0 0 26 38" xmlns="http://www.w3.org/2000/svg">` +
|
|
20
22
|
`<path d="M13 0C5.8 0 0 5.8 0 13c0 9.2 13 25 13 25s13-15.8 13-25C26 5.8 20.2 0 13 0z" fill="${color}"/>` +
|
|
21
23
|
`<circle cx="13" cy="13" r="5" fill="#fff"/></svg>`,
|
package/package.json
CHANGED