@nnc-digital/nnc-design-system 1.0.0-alpha54 → 1.0.0-alpha55
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/build/index.js +9 -1
- package/build/index.js.map +1 -1
- package/build/index.mjs.js +9 -1
- package/build/index.mjs.js.map +1 -1
- package/package.json +1 -1
package/build/index.js
CHANGED
|
@@ -6691,8 +6691,16 @@ var MapMarker = function (options) {
|
|
|
6691
6691
|
anchor: new google.maps.Point(40, 60),
|
|
6692
6692
|
labelOrigin: new google.maps.Point(21, 25),
|
|
6693
6693
|
};
|
|
6694
|
+
// Handle label text safely
|
|
6695
|
+
var labelText = '';
|
|
6696
|
+
if (typeof options.label === 'string') {
|
|
6697
|
+
labelText = options.label;
|
|
6698
|
+
}
|
|
6699
|
+
else if (options.label && typeof options.label === 'object' && 'text' in options.label) {
|
|
6700
|
+
labelText = (_a = options.label.text) !== null && _a !== void 0 ? _a : '';
|
|
6701
|
+
}
|
|
6694
6702
|
var mergedOptions = __assign$2(__assign$2({}, options), { anchorPoint: new google.maps.Point(-5, -40), icon: icon, label: {
|
|
6695
|
-
text:
|
|
6703
|
+
text: labelText,
|
|
6696
6704
|
color: 'white',
|
|
6697
6705
|
}, position: options.position, title: options.title });
|
|
6698
6706
|
React__default.default.useEffect(function () {
|