@micromag/element-map 0.3.480 → 0.3.482
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/es/index.js +9 -23
- package/lib/index.js +9 -23
- package/package.json +4 -3
package/es/index.js
CHANGED
|
@@ -383,7 +383,7 @@ var defaultProps$2 = {
|
|
|
383
383
|
children: null,
|
|
384
384
|
focusable: true
|
|
385
385
|
};
|
|
386
|
-
var Map$
|
|
386
|
+
var Map$2 = function Map(_ref) {
|
|
387
387
|
var center = _ref.center,
|
|
388
388
|
zoom = _ref.zoom,
|
|
389
389
|
maxZoom = _ref.maxZoom,
|
|
@@ -431,8 +431,9 @@ var Map$1 = function Map(_ref) {
|
|
|
431
431
|
});
|
|
432
432
|
}));
|
|
433
433
|
};
|
|
434
|
-
Map$
|
|
435
|
-
Map$
|
|
434
|
+
Map$2.propTypes = propTypes$2;
|
|
435
|
+
Map$2.defaultProps = defaultProps$2;
|
|
436
|
+
var GoogleMap = Map$2;
|
|
436
437
|
|
|
437
438
|
var eventMapping = {
|
|
438
439
|
onClick: 'click',
|
|
@@ -557,23 +558,7 @@ var Marker = function Marker(_ref) {
|
|
|
557
558
|
};
|
|
558
559
|
Marker.propTypes = propTypes$1;
|
|
559
560
|
Marker.defaultProps = defaultProps$1;
|
|
560
|
-
|
|
561
|
-
// import { useEffect } from 'react';
|
|
562
|
-
({
|
|
563
|
-
map: PropTypes.object,
|
|
564
|
-
// eslint-disable-line
|
|
565
|
-
coords: PropTypes.arrayOf(PropTypes.shape({
|
|
566
|
-
lat: PropTypes.number,
|
|
567
|
-
lng: PropTypes.number
|
|
568
|
-
})).isRequired,
|
|
569
|
-
events: PropTypes.object // eslint-disable-line
|
|
570
|
-
});
|
|
571
|
-
|
|
572
|
-
({
|
|
573
|
-
map: PropTypes.object,
|
|
574
|
-
// eslint-disable-line
|
|
575
|
-
enabled: PropTypes.bool
|
|
576
|
-
});
|
|
561
|
+
var Marker$1 = Marker;
|
|
577
562
|
|
|
578
563
|
var styles = {"container":"micromag-element-map-container"};
|
|
579
564
|
|
|
@@ -703,7 +688,7 @@ var Map = function Map(_ref) {
|
|
|
703
688
|
}, [onClick, onCenterChanged, onBoundsChanged, onDrag, onDragEnd, onTilesLoaded]);
|
|
704
689
|
return /*#__PURE__*/React.createElement("div", {
|
|
705
690
|
className: classNames([styles.container, _defineProperty({}, className, className !== null)])
|
|
706
|
-
}, /*#__PURE__*/React.createElement(
|
|
691
|
+
}, /*#__PURE__*/React.createElement(GoogleMap, {
|
|
707
692
|
center: center,
|
|
708
693
|
zoom: zoom,
|
|
709
694
|
withoutStyle: withoutStyle,
|
|
@@ -727,7 +712,7 @@ var Map = function Map(_ref) {
|
|
|
727
712
|
image = _ref5$image === void 0 ? null : _ref5$image,
|
|
728
713
|
_ref5$title = _ref5.title,
|
|
729
714
|
title = _ref5$title === void 0 ? null : _ref5$title;
|
|
730
|
-
return geoPosition !== null && (geoPosition.lat || null) !== null && (geoPosition.lng || null) !== null ? /*#__PURE__*/React.createElement(Marker, {
|
|
715
|
+
return geoPosition !== null && (geoPosition.lat || null) !== null && (geoPosition.lng || null) !== null ? /*#__PURE__*/React.createElement(Marker$1, {
|
|
731
716
|
key: "marker-".concat(index),
|
|
732
717
|
active: active,
|
|
733
718
|
title: title !== null && _typeof(title.body) ? title.body : null,
|
|
@@ -745,5 +730,6 @@ var Map = function Map(_ref) {
|
|
|
745
730
|
};
|
|
746
731
|
Map.propTypes = propTypes;
|
|
747
732
|
Map.defaultProps = defaultProps;
|
|
733
|
+
var Map$1 = Map;
|
|
748
734
|
|
|
749
|
-
export { Pin, Map as default };
|
|
735
|
+
export { Pin, Map$1 as default };
|
package/lib/index.js
CHANGED
|
@@ -387,7 +387,7 @@ var defaultProps$2 = {
|
|
|
387
387
|
children: null,
|
|
388
388
|
focusable: true
|
|
389
389
|
};
|
|
390
|
-
var Map$
|
|
390
|
+
var Map$2 = function Map(_ref) {
|
|
391
391
|
var center = _ref.center,
|
|
392
392
|
zoom = _ref.zoom,
|
|
393
393
|
maxZoom = _ref.maxZoom,
|
|
@@ -435,8 +435,9 @@ var Map$1 = function Map(_ref) {
|
|
|
435
435
|
});
|
|
436
436
|
}));
|
|
437
437
|
};
|
|
438
|
-
Map$
|
|
439
|
-
Map$
|
|
438
|
+
Map$2.propTypes = propTypes$2;
|
|
439
|
+
Map$2.defaultProps = defaultProps$2;
|
|
440
|
+
var GoogleMap = Map$2;
|
|
440
441
|
|
|
441
442
|
var eventMapping = {
|
|
442
443
|
onClick: 'click',
|
|
@@ -561,23 +562,7 @@ var Marker = function Marker(_ref) {
|
|
|
561
562
|
};
|
|
562
563
|
Marker.propTypes = propTypes$1;
|
|
563
564
|
Marker.defaultProps = defaultProps$1;
|
|
564
|
-
|
|
565
|
-
// import { useEffect } from 'react';
|
|
566
|
-
({
|
|
567
|
-
map: PropTypes.object,
|
|
568
|
-
// eslint-disable-line
|
|
569
|
-
coords: PropTypes.arrayOf(PropTypes.shape({
|
|
570
|
-
lat: PropTypes.number,
|
|
571
|
-
lng: PropTypes.number
|
|
572
|
-
})).isRequired,
|
|
573
|
-
events: PropTypes.object // eslint-disable-line
|
|
574
|
-
});
|
|
575
|
-
|
|
576
|
-
({
|
|
577
|
-
map: PropTypes.object,
|
|
578
|
-
// eslint-disable-line
|
|
579
|
-
enabled: PropTypes.bool
|
|
580
|
-
});
|
|
565
|
+
var Marker$1 = Marker;
|
|
581
566
|
|
|
582
567
|
var styles = {"container":"micromag-element-map-container"};
|
|
583
568
|
|
|
@@ -707,7 +692,7 @@ var Map = function Map(_ref) {
|
|
|
707
692
|
}, [onClick, onCenterChanged, onBoundsChanged, onDrag, onDragEnd, onTilesLoaded]);
|
|
708
693
|
return /*#__PURE__*/React.createElement("div", {
|
|
709
694
|
className: classNames([styles.container, _defineProperty({}, className, className !== null)])
|
|
710
|
-
}, /*#__PURE__*/React.createElement(
|
|
695
|
+
}, /*#__PURE__*/React.createElement(GoogleMap, {
|
|
711
696
|
center: center,
|
|
712
697
|
zoom: zoom,
|
|
713
698
|
withoutStyle: withoutStyle,
|
|
@@ -731,7 +716,7 @@ var Map = function Map(_ref) {
|
|
|
731
716
|
image = _ref5$image === void 0 ? null : _ref5$image,
|
|
732
717
|
_ref5$title = _ref5.title,
|
|
733
718
|
title = _ref5$title === void 0 ? null : _ref5$title;
|
|
734
|
-
return geoPosition !== null && (geoPosition.lat || null) !== null && (geoPosition.lng || null) !== null ? /*#__PURE__*/React.createElement(Marker, {
|
|
719
|
+
return geoPosition !== null && (geoPosition.lat || null) !== null && (geoPosition.lng || null) !== null ? /*#__PURE__*/React.createElement(Marker$1, {
|
|
735
720
|
key: "marker-".concat(index),
|
|
736
721
|
active: active,
|
|
737
722
|
title: title !== null && _typeof(title.body) ? title.body : null,
|
|
@@ -749,6 +734,7 @@ var Map = function Map(_ref) {
|
|
|
749
734
|
};
|
|
750
735
|
Map.propTypes = propTypes;
|
|
751
736
|
Map.defaultProps = defaultProps;
|
|
737
|
+
var Map$1 = Map;
|
|
752
738
|
|
|
753
739
|
exports.Pin = Pin;
|
|
754
|
-
exports.default = Map;
|
|
740
|
+
exports.default = Map$1;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@micromag/element-map",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.482",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "",
|
|
6
6
|
"keywords": [
|
|
@@ -46,6 +46,7 @@
|
|
|
46
46
|
"assets"
|
|
47
47
|
],
|
|
48
48
|
"scripts": {
|
|
49
|
+
"clean": "rm -rf es && rm -rf lib && rm -rf assets",
|
|
49
50
|
"prepare": "../../scripts/prepare-package.sh"
|
|
50
51
|
},
|
|
51
52
|
"devDependencies": {
|
|
@@ -58,7 +59,7 @@
|
|
|
58
59
|
},
|
|
59
60
|
"dependencies": {
|
|
60
61
|
"@babel/runtime": "^7.13.10",
|
|
61
|
-
"@micromag/core": "^0.3.
|
|
62
|
+
"@micromag/core": "^0.3.482",
|
|
62
63
|
"classnames": "^2.2.6",
|
|
63
64
|
"lodash": "^4.17.21",
|
|
64
65
|
"prop-types": "^15.7.2",
|
|
@@ -69,5 +70,5 @@
|
|
|
69
70
|
"access": "public",
|
|
70
71
|
"registry": "https://registry.npmjs.org/"
|
|
71
72
|
},
|
|
72
|
-
"gitHead": "
|
|
73
|
+
"gitHead": "931f86bb7dd77a05d196cadda88c8a170e665c3d"
|
|
73
74
|
}
|