@mapsindoors/map-template 1.93.2 → 1.94.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.
- package/dist/{GoogleMapsMap-982405ad.mjs → GoogleMapsMap-BqYRaFgc.mjs} +51 -62
- package/dist/MapboxMap-CUYrfLHY.mjs +34732 -0
- package/dist/_commonjsHelpers-ba3f0406.js +21 -0
- package/dist/combo-box-item.entry.js +15 -0
- package/dist/icon-b8d01d6f.js +24 -0
- package/dist/index-7e9696f3.js +1678 -0
- package/dist/index.js +1 -0
- package/dist/loader.js +18 -0
- package/dist/mapsindoors-react.es.js +3 -5
- package/dist/mapsindoors-react.umd.js +197 -582
- package/dist/mapsindoors-webcomponent.es.js +58512 -75790
- package/dist/mi-card_2.entry.js +28 -0
- package/dist/mi-chip.entry.js +22 -0
- package/dist/mi-column.entry.js +28 -0
- package/dist/mi-combo-box.entry.js +416 -0
- package/dist/mi-components.js +18 -0
- package/dist/mi-data-table.entry.js +302 -0
- package/dist/mi-distance_2.entry.js +67 -0
- package/dist/mi-dropdown-item.entry.js +15 -0
- package/dist/mi-dropdown.entry.js +610 -0
- package/dist/mi-floor-selector.entry.js +202 -0
- package/dist/mi-keyboard.entry.js +238 -0
- package/dist/mi-list-item-category.entry.js +48 -0
- package/dist/mi-list-item-location.entry.js +171 -0
- package/dist/mi-list.entry.js +56 -0
- package/dist/mi-location-booking.entry.js +5193 -0
- package/dist/mi-location-info.entry.js +63 -0
- package/dist/mi-map-googlemaps.entry.js +750 -0
- package/dist/mi-map-mapbox.entry.js +467 -0
- package/dist/mi-metric-card.entry.js +48 -0
- package/dist/mi-my-position.entry.js +986 -0
- package/dist/mi-notification.entry.js +127 -0
- package/dist/mi-route-instructions-heading.entry.js +73 -0
- package/dist/mi-route-instructions-maneuver-legacy.entry.js +82 -0
- package/dist/mi-route-instructions-maneuver.entry.js +82 -0
- package/dist/mi-route-instructions-step-legacy.entry.js +308 -0
- package/dist/mi-route-instructions-step.entry.js +321 -0
- package/dist/mi-route-instructions.entry.js +157 -0
- package/dist/mi-scroll-buttons.entry.js +112 -0
- package/dist/mi-search.entry.js +376 -0
- package/dist/mi-share-sms.entry.js +80 -0
- package/dist/mi-step-switcher.entry.js +31 -0
- package/dist/mi-tab-panel.entry.js +25 -0
- package/dist/mi-tab.entry.js +12 -0
- package/dist/mi-tabs.entry.js +47 -0
- package/dist/mi-time.entry.js +57 -0
- package/dist/mi-variables-9a6c8d4d.js +6 -0
- package/dist/polyfills/core-js.js +11 -0
- package/dist/polyfills/css-shim.js +1 -0
- package/dist/polyfills/dom.js +79 -0
- package/dist/polyfills/es5-html-element.js +1 -0
- package/dist/polyfills/index.js +34 -0
- package/dist/polyfills/system.js +6 -0
- package/dist/{reactcomponent-7fbbd9b2.mjs → reactcomponent-DTepe7hB.mjs} +14121 -14626
- package/dist/route-travel-mode.enum-7f4ce9c7.js +9 -0
- package/dist/sort-order.enum-64ce8998.js +552 -0
- package/dist/unit-system.enum-eaefb53e.js +7 -0
- package/dist/utils-ae714467.js +61 -0
- package/package.json +10 -6
- package/dist/MapboxMap-06ef82a3.mjs +0 -37815
- package/dist/_commonjsHelpers-ba3f0406-b96e6d6a.mjs +0 -22
- package/dist/combo-box-item.entry-d35f3d51.mjs +0 -15
- package/dist/icon-b8d01d6f-ddfa2c17.mjs +0 -25
- package/dist/mapsindoors-webcomponent.umd.js +0 -3245
- package/dist/mi-card_2.entry-fc772c35.mjs +0 -26
- package/dist/mi-chip.entry-81c742a1.mjs +0 -19
- package/dist/mi-column.entry-3a083282.mjs +0 -21
- package/dist/mi-combo-box.entry-cae6401a.mjs +0 -263
- package/dist/mi-data-table.entry-d4c3f445.mjs +0 -224
- package/dist/mi-distance_2.entry-a33ed69a.mjs +0 -339
- package/dist/mi-dropdown-item.entry-974d1e4f.mjs +0 -15
- package/dist/mi-dropdown.entry-5317db65.mjs +0 -349
- package/dist/mi-floor-selector.entry-185fbd8b.mjs +0 -115
- package/dist/mi-keyboard.entry-eaf4b9ef.mjs +0 -3103
- package/dist/mi-list-item-category.entry-9c95008c.mjs +0 -39
- package/dist/mi-list-item-location.entry-8b41e8f0.mjs +0 -137
- package/dist/mi-list.entry-1218d29d.mjs +0 -42
- package/dist/mi-location-booking.entry-270aaf5a.mjs +0 -4866
- package/dist/mi-location-info.entry-e4f7fd04.mjs +0 -32
- package/dist/mi-map-googlemaps.entry-81fa28d2.mjs +0 -467
- package/dist/mi-map-mapbox.entry-31821da3.mjs +0 -301
- package/dist/mi-metric-card.entry-40407f04.mjs +0 -29
- package/dist/mi-my-position.entry-bc48fe6e.mjs +0 -703
- package/dist/mi-notification.entry-9a2bc53b.mjs +0 -84
- package/dist/mi-route-instructions-heading.entry-e5b1ff04.mjs +0 -75
- package/dist/mi-route-instructions-maneuver-legacy.entry-2c3d73ab.mjs +0 -76
- package/dist/mi-route-instructions-maneuver.entry-c6f01024.mjs +0 -76
- package/dist/mi-route-instructions-step-legacy.entry-80bcf097.mjs +0 -202
- package/dist/mi-route-instructions-step.entry-db802e13.mjs +0 -231
- package/dist/mi-route-instructions.entry-62416e29.mjs +0 -143
- package/dist/mi-scroll-buttons.entry-92b62b21.mjs +0 -83
- package/dist/mi-search.entry-87f1e64a.mjs +0 -251
- package/dist/mi-share-sms.entry-b6725edb.mjs +0 -56
- package/dist/mi-step-switcher.entry-f8f6c040.mjs +0 -27
- package/dist/mi-tab-panel.entry-a89213c2.mjs +0 -22
- package/dist/mi-tab.entry-a2fb3f8c.mjs +0 -14
- package/dist/mi-tabs.entry-cd638ea7.mjs +0 -37
- package/dist/mi-time.entry-0b02870d.mjs +0 -46
- package/dist/mi-variables-9a6c8d4d-e06eec88.mjs +0 -8
- package/dist/route-travel-mode.enum-7f4ce9c7-a9c95a83.mjs +0 -8
- package/dist/sort-order.enum-64ce8998-b75ac596.mjs +0 -318
- package/dist/unit-system.enum-eaefb53e-0f424da4.mjs +0 -8
- package/dist/utils-ae714467-b07fc3be.mjs +0 -37
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { useState as
|
|
3
|
-
|
|
4
|
-
function C(n, e, t, r) {
|
|
1
|
+
import { i as g, j as R, P as u } from "./reactcomponent-DTepe7hB.mjs";
|
|
2
|
+
import { useState as _, useEffect as j } from "react";
|
|
3
|
+
function A(n, e, t, r) {
|
|
5
4
|
function s(i) {
|
|
6
5
|
return i instanceof t ? i : new t(function(o) {
|
|
7
6
|
o(i);
|
|
@@ -10,62 +9,52 @@ function C(n, e, t, r) {
|
|
|
10
9
|
return new (t || (t = Promise))(function(i, o) {
|
|
11
10
|
function c(a) {
|
|
12
11
|
try {
|
|
13
|
-
|
|
12
|
+
p(r.next(a));
|
|
14
13
|
} catch (h) {
|
|
15
14
|
o(h);
|
|
16
15
|
}
|
|
17
16
|
}
|
|
18
17
|
function l(a) {
|
|
19
18
|
try {
|
|
20
|
-
|
|
19
|
+
p(r.throw(a));
|
|
21
20
|
} catch (h) {
|
|
22
21
|
o(h);
|
|
23
22
|
}
|
|
24
23
|
}
|
|
25
|
-
function
|
|
24
|
+
function p(a) {
|
|
26
25
|
a.done ? i(a.value) : s(a.value).then(c, l);
|
|
27
26
|
}
|
|
28
|
-
|
|
27
|
+
p((r = r.apply(n, [])).next());
|
|
29
28
|
});
|
|
30
29
|
}
|
|
31
|
-
function
|
|
30
|
+
function C(n) {
|
|
32
31
|
return n && n.__esModule && Object.prototype.hasOwnProperty.call(n, "default") ? n.default : n;
|
|
33
32
|
}
|
|
34
|
-
var
|
|
35
|
-
if (e === t)
|
|
36
|
-
return !0;
|
|
33
|
+
var $ = function n(e, t) {
|
|
34
|
+
if (e === t) return !0;
|
|
37
35
|
if (e && t && typeof e == "object" && typeof t == "object") {
|
|
38
|
-
if (e.constructor !== t.constructor)
|
|
39
|
-
return !1;
|
|
36
|
+
if (e.constructor !== t.constructor) return !1;
|
|
40
37
|
var r, s, i;
|
|
41
38
|
if (Array.isArray(e)) {
|
|
42
|
-
if (r = e.length, r != t.length)
|
|
43
|
-
return !1;
|
|
39
|
+
if (r = e.length, r != t.length) return !1;
|
|
44
40
|
for (s = r; s-- !== 0; )
|
|
45
|
-
if (!n(e[s], t[s]))
|
|
46
|
-
return !1;
|
|
41
|
+
if (!n(e[s], t[s])) return !1;
|
|
47
42
|
return !0;
|
|
48
43
|
}
|
|
49
|
-
if (e.constructor === RegExp)
|
|
50
|
-
|
|
51
|
-
if (e.
|
|
52
|
-
|
|
53
|
-
if (e.toString !== Object.prototype.toString)
|
|
54
|
-
return e.toString() === t.toString();
|
|
55
|
-
if (i = Object.keys(e), r = i.length, r !== Object.keys(t).length)
|
|
56
|
-
return !1;
|
|
44
|
+
if (e.constructor === RegExp) return e.source === t.source && e.flags === t.flags;
|
|
45
|
+
if (e.valueOf !== Object.prototype.valueOf) return e.valueOf() === t.valueOf();
|
|
46
|
+
if (e.toString !== Object.prototype.toString) return e.toString() === t.toString();
|
|
47
|
+
if (i = Object.keys(e), r = i.length, r !== Object.keys(t).length) return !1;
|
|
57
48
|
for (s = r; s-- !== 0; )
|
|
58
|
-
if (!Object.prototype.hasOwnProperty.call(t, i[s]))
|
|
59
|
-
return !1;
|
|
49
|
+
if (!Object.prototype.hasOwnProperty.call(t, i[s])) return !1;
|
|
60
50
|
for (s = r; s-- !== 0; ) {
|
|
61
51
|
var o = i[s];
|
|
62
|
-
if (!n(e[o], t[o]))
|
|
63
|
-
return !1;
|
|
52
|
+
if (!n(e[o], t[o])) return !1;
|
|
64
53
|
}
|
|
65
54
|
return !0;
|
|
66
55
|
}
|
|
67
56
|
return e !== e && t !== t;
|
|
68
|
-
},
|
|
57
|
+
}, D = /* @__PURE__ */ C($);
|
|
69
58
|
const k = "__googleMapsScriptId";
|
|
70
59
|
var y;
|
|
71
60
|
(function(n) {
|
|
@@ -81,9 +70,9 @@ class m {
|
|
|
81
70
|
* const loader = Loader({apiKey, version: 'weekly', libraries: ['places']});
|
|
82
71
|
* ```
|
|
83
72
|
*/
|
|
84
|
-
constructor({ apiKey: e, authReferrerPolicy: t, channel: r, client: s, id: i = k, language: o, libraries: c = [], mapIds: l, nonce:
|
|
85
|
-
if (this.callbacks = [], this.done = !1, this.loading = !1, this.errors = [], this.apiKey = e, this.authReferrerPolicy = t, this.channel = r, this.client = s, this.id = i || k, this.language = o, this.libraries = c, this.mapIds = l, this.nonce =
|
|
86
|
-
if (!
|
|
73
|
+
constructor({ apiKey: e, authReferrerPolicy: t, channel: r, client: s, id: i = k, language: o, libraries: c = [], mapIds: l, nonce: p, region: a, retries: h = 3, url: w = "https://maps.googleapis.com/maps/api/js", version: f }) {
|
|
74
|
+
if (this.callbacks = [], this.done = !1, this.loading = !1, this.errors = [], this.apiKey = e, this.authReferrerPolicy = t, this.channel = r, this.client = s, this.id = i || k, this.language = o, this.libraries = c, this.mapIds = l, this.nonce = p, this.region = a, this.retries = h, this.url = w, this.version = f, m.instance) {
|
|
75
|
+
if (!D(this.options, m.instance.options))
|
|
87
76
|
throw new Error(`Loader must not be called again with different options. ${JSON.stringify(this.options)} !== ${JSON.stringify(m.instance.options)}`);
|
|
88
77
|
return m.instance;
|
|
89
78
|
}
|
|
@@ -178,20 +167,20 @@ class m {
|
|
|
178
167
|
Object.keys(r).forEach(
|
|
179
168
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
180
169
|
(i) => !r[i] && delete r[i]
|
|
181
|
-
), !((t = (e = window
|
|
182
|
-
let o, c, l,
|
|
170
|
+
), !((t = (e = window?.google) === null || e === void 0 ? void 0 : e.maps) === null || t === void 0) && t.importLibrary || ((i) => {
|
|
171
|
+
let o, c, l, p = "The Google Maps JavaScript API", a = "google", h = "importLibrary", w = "__ib__", f = document, d = window;
|
|
183
172
|
d = d[a] || (d[a] = {});
|
|
184
|
-
const b = d.maps || (d.maps = {}),
|
|
173
|
+
const b = d.maps || (d.maps = {}), M = /* @__PURE__ */ new Set(), I = new URLSearchParams(), P = () => (
|
|
185
174
|
// @ts-ignore
|
|
186
|
-
o || (o = new Promise((v, E) =>
|
|
187
|
-
var
|
|
188
|
-
yield c = f.createElement("script"), c.id = this.id, I.set("libraries", [...
|
|
175
|
+
o || (o = new Promise((v, E) => A(this, void 0, void 0, function* () {
|
|
176
|
+
var S;
|
|
177
|
+
yield c = f.createElement("script"), c.id = this.id, I.set("libraries", [...M] + "");
|
|
189
178
|
for (l in i)
|
|
190
|
-
I.set(l.replace(/[A-Z]/g, (
|
|
191
|
-
I.set("callback", a + ".maps." + w), c.src = this.url + "?" + I, b[w] = v, c.onerror = () => o = E(Error(
|
|
179
|
+
I.set(l.replace(/[A-Z]/g, (O) => "_" + O[0].toLowerCase()), i[l]);
|
|
180
|
+
I.set("callback", a + ".maps." + w), c.src = this.url + "?" + I, b[w] = v, c.onerror = () => o = E(Error(p + " could not load.")), c.nonce = this.nonce || ((S = f.querySelector("script[nonce]")) === null || S === void 0 ? void 0 : S.nonce) || "", f.head.append(c);
|
|
192
181
|
})))
|
|
193
182
|
);
|
|
194
|
-
b[h] ? console.warn(
|
|
183
|
+
b[h] ? console.warn(p + " only loads once. Ignoring:", i) : b[h] = (v, ...E) => M.add(v) && P().then(() => b[h](v, ...E));
|
|
195
184
|
})(r);
|
|
196
185
|
const s = this.libraries.map((i) => this.importLibrary(i));
|
|
197
186
|
s.length || s.push(this.importLibrary("core")), Promise.all(s).then(() => this.callback(), (i) => {
|
|
@@ -235,22 +224,22 @@ class m {
|
|
|
235
224
|
}
|
|
236
225
|
}
|
|
237
226
|
}
|
|
238
|
-
|
|
239
|
-
apiKey:
|
|
240
|
-
onInitialized:
|
|
241
|
-
center:
|
|
242
|
-
zoom:
|
|
243
|
-
bounds:
|
|
244
|
-
heading:
|
|
245
|
-
tilt:
|
|
246
|
-
mapsIndoorsInstance:
|
|
247
|
-
mapOptions:
|
|
248
|
-
gmMapId:
|
|
227
|
+
U.propTypes = {
|
|
228
|
+
apiKey: u.string.isRequired,
|
|
229
|
+
onInitialized: u.func.isRequired,
|
|
230
|
+
center: u.object,
|
|
231
|
+
zoom: u.number,
|
|
232
|
+
bounds: u.object,
|
|
233
|
+
heading: u.number,
|
|
234
|
+
tilt: u.number,
|
|
235
|
+
mapsIndoorsInstance: u.object,
|
|
236
|
+
mapOptions: u.object,
|
|
237
|
+
gmMapId: u.string
|
|
249
238
|
};
|
|
250
|
-
function
|
|
251
|
-
const [a, h] =
|
|
239
|
+
function U({ apiKey: n, onInitialized: e, center: t, zoom: r, bounds: s, heading: i, tilt: o, mapsIndoorsInstance: c, mapOptions: l, gmMapId: p }) {
|
|
240
|
+
const [a, h] = _();
|
|
252
241
|
return j(() => {
|
|
253
|
-
a && (g(s) || c.getMapView().fitBounds(s, l
|
|
242
|
+
a && (g(s) || c.getMapView().fitBounds(s, l?.fitBoundsPadding), !g(t) && g(s) && a.getMap().setCenter(t), !g(r) && g(s) && a.getMap().setZoom(r), g(i) || a.getMap().setHeading(i), g(o) || a.getMap().setTilt(o));
|
|
254
243
|
}, [a, t, r, i, o, s, l]), j(() => {
|
|
255
244
|
new m({
|
|
256
245
|
apiKey: n,
|
|
@@ -266,17 +255,17 @@ function N({ apiKey: n, onInitialized: e, center: t, zoom: r, bounds: s, heading
|
|
|
266
255
|
zoom: r ?? 21,
|
|
267
256
|
heading: i ?? 0,
|
|
268
257
|
tilt: o ?? 0,
|
|
269
|
-
mapId:
|
|
258
|
+
mapId: p,
|
|
270
259
|
gestureHandling: "greedy",
|
|
271
260
|
...l
|
|
272
261
|
};
|
|
273
|
-
g(l
|
|
262
|
+
g(l?.showMapMarkers) || (f.showMapMarkers = l.showMapMarkers);
|
|
274
263
|
const d = new window.mapsindoors.mapView.GoogleMapsView(f);
|
|
275
264
|
h(d), e(d);
|
|
276
265
|
});
|
|
277
|
-
}, []), /* @__PURE__ */
|
|
266
|
+
}, []), /* @__PURE__ */ R.jsx("div", { className: "mapsindoors-map google-maps-map-container", id: "map" });
|
|
278
267
|
}
|
|
279
268
|
export {
|
|
280
|
-
|
|
269
|
+
U as default
|
|
281
270
|
};
|
|
282
|
-
//# sourceMappingURL=GoogleMapsMap-
|
|
271
|
+
//# sourceMappingURL=GoogleMapsMap-BqYRaFgc.mjs.map
|