@micromag/element-map 0.4.25 → 0.4.26

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.d.ts CHANGED
@@ -27,6 +27,6 @@ interface MapProps {
27
27
  fullscreenControl?: boolean;
28
28
  focusable?: boolean;
29
29
  }
30
- declare function Map({ center, zoom, draggable, markers, onClickMap, onClickMarker, className, onReady, onCenterChanged, onBoundsChanged, onDrag, onDragEnd, withoutStyle, fitBounds, zoomControl, mapTypeControl, scaleControl, streetViewControl, rotateControl, fullscreenControl, focusable, }: MapProps): react_jsx_runtime.JSX.Element;
30
+ declare function Map({ center, zoom, draggable, markers: initialMarkers, onClickMap, onClickMarker, className, onReady, onCenterChanged, onBoundsChanged, onDrag, onDragEnd, withoutStyle, fitBounds, zoomControl, mapTypeControl, scaleControl, streetViewControl, rotateControl, fullscreenControl, focusable, }: MapProps): react_jsx_runtime.JSX.Element;
31
31
 
32
32
  export { Map as default };
package/es/index.js CHANGED
@@ -513,7 +513,7 @@ function Map(_ref) {
513
513
  _ref$draggable = _ref.draggable,
514
514
  draggable = _ref$draggable === void 0 ? true : _ref$draggable,
515
515
  _ref$markers = _ref.markers,
516
- markers = _ref$markers === void 0 ? [] : _ref$markers,
516
+ initialMarkers = _ref$markers === void 0 ? null : _ref$markers,
517
517
  _ref$onClickMap = _ref.onClickMap,
518
518
  onClickMap = _ref$onClickMap === void 0 ? null : _ref$onClickMap,
519
519
  _ref$onClickMarker = _ref.onClickMarker,
@@ -548,6 +548,7 @@ function Map(_ref) {
548
548
  fullscreenControl = _ref$fullscreenContro === void 0 ? false : _ref$fullscreenContro,
549
549
  _ref$focusable = _ref.focusable,
550
550
  focusable = _ref$focusable === void 0 ? true : _ref$focusable;
551
+ var markers = initialMarkers || [];
551
552
  var client = useGoogleMapsClient();
552
553
  var onClick = useCallback(function (position) {
553
554
  if (onClickMap !== null) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@micromag/element-map",
3
- "version": "0.4.25",
3
+ "version": "0.4.26",
4
4
  "private": false,
5
5
  "description": "",
6
6
  "keywords": [
@@ -60,7 +60,7 @@
60
60
  },
61
61
  "dependencies": {
62
62
  "@babel/runtime": "^7.28.6",
63
- "@micromag/core": "^0.4.25",
63
+ "@micromag/core": "^0.4.26",
64
64
  "classnames": "^2.2.6",
65
65
  "lodash": "^4.17.23",
66
66
  "react-intl": "^8.1.3",
@@ -70,6 +70,6 @@
70
70
  "access": "public",
71
71
  "registry": "https://registry.npmjs.org/"
72
72
  },
73
- "gitHead": "01f62fcaf9ea405d162fdc26e36479d9f307f640",
73
+ "gitHead": "dd4833b92d00633e4c6b85d3118bf5207811157e",
74
74
  "types": "es/index.d.ts"
75
75
  }