@expofp/floorplan 3.0.0-alpha.13 → 3.0.0-alpha.15

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.
Files changed (47) hide show
  1. package/dist/browser/Debug-Bn7mmuWl.js +40 -0
  2. package/dist/browser/Demo-pwpeopeB.js +47 -0
  3. package/dist/browser/{Free-Cf7Raqrc.js → Free-CeZSHheC.js} +29 -20
  4. package/dist/browser/Gallery-BTasOfWx.js +288 -0
  5. package/dist/browser/GpsLoader-BS8b-Aif.js +140 -0
  6. package/dist/browser/{KioskStore-D241RDzb.js → KioskStore-_Zcv0Bc0.js} +57 -48
  7. package/dist/browser/Mapbox-Cl59-8BN.js +118 -0
  8. package/dist/browser/{SetKioskMode-2rlj74Xn.js → SetKioskMode-CjjAW8SI.js} +66 -57
  9. package/dist/browser/{ShowKiosk-CrsnQU04.js → ShowKiosk-DUcthTIK.js} +28 -19
  10. package/dist/browser/{ThreeComponent-ClnfXUj7.js → ThreeComponent-CdelmApV.js} +181 -172
  11. package/dist/browser/boolean-editor-HetrPeeC.js +157 -0
  12. package/dist/browser/bundle.json +32 -29
  13. package/dist/browser/{client-CkzDfd_U.js → client-BMgLu7eB.js} +590 -581
  14. package/dist/browser/compat-helper.js +5 -0
  15. package/dist/browser/{data-m8n9ATTo.js → data-eO9H1gMa.js} +276 -267
  16. package/dist/browser/{debug-overlay-2jzTw6KL.js → debug-overlay-DqIeCuHo.js} +98 -89
  17. package/dist/browser/debug-ui-6t_iunMd.js +67 -0
  18. package/dist/browser/{favicon-DalyEhbd.js → favicon-CoF9H4Pb.js} +11 -2
  19. package/dist/browser/fetch-retry.umd-GcX1W9qV.js +123 -0
  20. package/dist/browser/{flex-Cdkjkshz.js → flex-BC_JSvaB.js} +80 -71
  21. package/dist/browser/{floorplan.ready-D6FqQD8c.js → floorplan.ready-CZn5dvsU.js} +1011 -987
  22. package/dist/browser/index-C1Rwmp91.js +54 -0
  23. package/dist/browser/{index-DSgSq67u.js → index-CEVUHq8g.js} +96 -87
  24. package/dist/browser/{index-CEmjMySn.js → index-Dba8EyWF.js} +41 -32
  25. package/dist/browser/{index-4ImEhZsQ.js → index-DnV82MKb.js} +936 -923
  26. package/dist/browser/index-Dp-WygGH.js +57 -0
  27. package/dist/browser/index-sNwIhVDZ.js +92 -0
  28. package/dist/browser/{index-DBHasqQ8.js → index-uGr-_9rk.js} +258 -249
  29. package/dist/browser/index.js +11 -2
  30. package/dist/browser/jsx-runtime-BHfPvO9I.js +40 -0
  31. package/dist/browser/{main-CD9JioNt.js → main-DYasSc7U.js} +24 -15
  32. package/dist/browser/{particles.min-7sD7ioDi.js → particles.min-B6O6_M_h.js} +43 -34
  33. package/dist/esm/load.d.ts +2 -0
  34. package/dist/esm/load.js +3 -3
  35. package/package.json +4 -3
  36. package/dist/browser/Debug-2YRpxyzp.js +0 -31
  37. package/dist/browser/Demo-BhvcgT41.js +0 -38
  38. package/dist/browser/Gallery-Dq_GR98t.js +0 -279
  39. package/dist/browser/GpsLoader-ChfXQOsy.js +0 -131
  40. package/dist/browser/Mapbox-DFHRWdCq.js +0 -109
  41. package/dist/browser/boolean-editor-D8wja-hk.js +0 -148
  42. package/dist/browser/debug-ui-YhK0Mf0Y.js +0 -58
  43. package/dist/browser/fetch-retry.umd-dyC72RhE.js +0 -114
  44. package/dist/browser/index-BKeGOpor.js +0 -48
  45. package/dist/browser/index-D153Iyx8.js +0 -45
  46. package/dist/browser/index-d52BKaOl.js +0 -83
  47. package/dist/browser/jsx-runtime-jIxVPx5o.js +0 -31
@@ -1,21 +1,30 @@
1
- import { s as i, ao as h, ap as b, aq as v, ar as f, as as O, at as C, au as g, av as l, aw as d } from "./floorplan.ready-D6FqQD8c.js";
2
- import "./jsx-runtime-jIxVPx5o.js";
3
- import "./index-4ImEhZsQ.js";
4
- import "./index-D153Iyx8.js";
5
- function P(n) {
6
- const e = n.viewport.canvasToSvg({
1
+ import { s as o, ao as h, ap as b, aq as f, ar as v, as as D, at as O, au as d, av as l, aw as g } from "./floorplan.ready-CZn5dvsU.js";
2
+ import "./jsx-runtime-BHfPvO9I.js";
3
+ import "./index-DnV82MKb.js";
4
+ import "./index-C1Rwmp91.js";
5
+ (function() {
6
+ try {
7
+ var a = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
8
+ a.SENTRY_RELEASE = { id: "3.0.0-alpha.15" };
9
+ var e = new a.Error().stack;
10
+ e && (a._sentryDebugIds = a._sentryDebugIds || {}, a._sentryDebugIds[e] = "5dd7851e-d709-4d1a-97a9-d6c99cbd7942", a._sentryDebugIdIdentifier = "sentry-dbid-5dd7851e-d709-4d1a-97a9-d6c99cbd7942");
11
+ } catch {
12
+ }
13
+ })();
14
+ function w(a) {
15
+ const e = a.viewport.canvasToSvg({
7
16
  x: 0,
8
17
  y: 0
9
- }), r = n.viewport.canvasToSvg({
10
- x: n.canvas.clientWidth,
18
+ }), r = a.viewport.canvasToSvg({
19
+ x: a.canvas.clientWidth,
11
20
  y: 0
12
- }), a = n.viewport.canvasToSvg({
21
+ }), i = a.viewport.canvasToSvg({
13
22
  x: 0,
14
- y: n.canvas.clientHeight
15
- }), p = n.viewport.canvasToSvg({
16
- x: n.canvas.clientWidth,
17
- y: n.canvas.clientHeight
18
- }), s = Math.min(e.x, r.x, a.x, p.x), c = Math.max(e.x, r.x, a.x, p.x), u = Math.min(e.y, r.y, a.y, p.y), y = Math.max(e.y, r.y, a.y, p.y);
23
+ y: a.canvas.clientHeight
24
+ }), p = a.viewport.canvasToSvg({
25
+ x: a.canvas.clientWidth,
26
+ y: a.canvas.clientHeight
27
+ }), s = Math.min(e.x, r.x, i.x, p.x), c = Math.max(e.x, r.x, i.x, p.x), u = Math.min(e.y, r.y, i.y, p.y), y = Math.max(e.y, r.y, i.y, p.y);
19
28
  return {
20
29
  x: s,
21
30
  y: u,
@@ -31,37 +40,37 @@ function P(n) {
31
40
  }
32
41
  };
33
42
  }
34
- function D(n, e) {
35
- const r = P(n);
43
+ function C(a, e) {
44
+ const r = w(a);
36
45
  return e.x >= r.left && e.x <= r.right && e.y >= r.bottom && e.y <= r.top;
37
46
  }
38
47
  var t, S, m;
39
- function k(n, e, r, a) {
40
- r && Object.defineProperty(n, e, { enumerable: r.enumerable, configurable: r.configurable, writable: r.writable, value: r.initializer ? r.initializer.call(a) : void 0 });
48
+ function k(a, e, r, i) {
49
+ r && Object.defineProperty(a, e, { enumerable: r.enumerable, configurable: r.configurable, writable: r.writable, value: r.initializer ? r.initializer.call(i) : void 0 });
41
50
  }
42
- function o(n, e, r, a, p) {
51
+ function n(a, e, r, i, p) {
43
52
  var s = {};
44
- return Object.keys(a).forEach(function(c) {
45
- s[c] = a[c];
53
+ return Object.keys(i).forEach(function(c) {
54
+ s[c] = i[c];
46
55
  }), s.enumerable = !!s.enumerable, s.configurable = !!s.configurable, ("value" in s || s.initializer) && (s.writable = !0), s = r.slice().reverse().reduce(function(c, u) {
47
- return u(n, e, c) || c;
48
- }, s), p && s.initializer !== void 0 && (s.value = s.initializer ? s.initializer.call(p) : void 0, s.initializer = void 0), s.initializer === void 0 ? (Object.defineProperty(n, e, s), null) : s;
56
+ return u(a, e, c) || c;
57
+ }, s), p && s.initializer !== void 0 && (s.value = s.initializer ? s.initializer.call(p) : void 0, s.initializer = void 0), s.initializer === void 0 ? (Object.defineProperty(a, e, s), null) : s;
49
58
  }
50
- let w = (t = class {
59
+ let P = (t = class {
51
60
  constructor() {
52
61
  k(this, "savedKiosk", S, this), k(this, "statusMessages", m, this), this.statusMessageTimer = 0, this.initialPtScale = void 0;
53
62
  }
54
63
  get kiosk() {
55
- return i.uiState.kioskData;
64
+ return o.uiState.kioskData;
56
65
  }
57
66
  setKiosk(e) {
58
- i.uiState.setKioskData(e);
67
+ o.uiState.setKioskData(e);
59
68
  }
60
69
  get renderer() {
61
- return i.rendererService.renderer;
70
+ return o.rendererService.renderer;
62
71
  }
63
72
  getCameraState() {
64
- const e = i.rendererService.getCameraState();
73
+ const e = o.rendererService.getCameraState();
65
74
  return e ? {
66
75
  mapInitialPtScale: this.initialPtScale,
67
76
  mapPtScale: e.ptScale,
@@ -75,10 +84,10 @@ let w = (t = class {
75
84
  const e = this.savedKiosk, r = h(this.kiosk);
76
85
  if (!r || !e)
77
86
  return !!r != !!e;
78
- const a = Object.keys(e), p = Object.keys(r);
79
- if (a.length !== p.length)
87
+ const i = Object.keys(e), p = Object.keys(r);
88
+ if (i.length !== p.length)
80
89
  return !0;
81
- for (const s of a)
90
+ for (const s of i)
82
91
  if (!(s in r) || e[s] !== r[s])
83
92
  return !0;
84
93
  return !1;
@@ -99,7 +108,7 @@ let w = (t = class {
99
108
  const {
100
109
  z: e,
101
110
  mapRollDegrees: r,
102
- mapInitialPtScale: a,
111
+ mapInitialPtScale: i,
103
112
  mapPtScale: p,
104
113
  mapCenterX: s,
105
114
  mapCenterY: c
@@ -110,43 +119,43 @@ let w = (t = class {
110
119
  roll: !0,
111
120
  pitch: !0
112
121
  }, !0), b(() => {
113
- Number.isFinite(a) && Number.isFinite(p) && p > 0 && this.renderer.controls.zoomBy(a / p, !0), Number.isFinite(s) && Number.isFinite(c) && this.renderer.controls.panTo(s, c, !0), Number.isFinite(r) && this.renderer.controls.rollTo(r, !0), e && i.fp.activateFloor({
122
+ Number.isFinite(i) && Number.isFinite(p) && p > 0 && this.renderer.controls.zoomBy(i / p, !0), Number.isFinite(s) && Number.isFinite(c) && this.renderer.controls.panTo(s, c, !0), Number.isFinite(r) && this.renderer.controls.rollTo(r, !0), e && o.fp.activateFloor({
114
123
  name: e
115
124
  });
116
125
  });
117
126
  }
118
127
  restoreData() {
119
- const e = v();
120
- return e && (this.setKiosk(e), this.savedKiosk = e, i.uiState.kiosk = !0, this.resetCamera()), e;
128
+ const e = f();
129
+ return e && (this.setKiosk(e), this.savedKiosk = e, o.uiState.kiosk = !0, this.resetCamera()), e;
121
130
  }
122
131
  handleSetupReady() {
123
- this.restoreData(), i.uiState.kiosk = !0, i.uiState.hideFreeOrDemo = !0, i.uiState.setForceDimm(!0), i.searchStore.setSearchText(""), i.searchStore.setFocused(!1);
132
+ this.restoreData(), o.uiState.kiosk = !0, o.uiState.hideFreeOrDemo = !0, o.uiState.setForceDimm(!0), o.searchStore.setSearchText(""), o.searchStore.setFocused(!1);
124
133
  }
125
134
  handleClose() {
126
- this.setKiosk(null), i.uiState.setForceDimm(!1), i.uiState.enableSetKioskMode(!1), i.searchStore.closeSearch(), this.resetCamera();
135
+ this.setKiosk(null), o.uiState.setForceDimm(!1), o.uiState.enableSetKioskMode(!1), o.searchStore.closeSearch(), this.resetCamera();
127
136
  }
128
137
  handleDelete() {
129
- f(), this.setKiosk(null), i.uiState.resetMapSettings(), i.uiState.resetUIScale(), this.resetCamera(), this.addStatusMessage({
138
+ v(), this.setKiosk(null), o.uiState.resetMapSettings(), o.uiState.resetUIScale(), this.resetCamera(), this.addStatusMessage({
130
139
  variant: "success",
131
140
  title: "Deleted"
132
141
  });
133
142
  }
134
143
  handleSave() {
135
- const e = h(this.kiosk), r = this.getCameraState(), a = {
144
+ const e = h(this.kiosk), r = this.getCameraState(), i = {
136
145
  ...e,
137
146
  ...r
138
147
  };
139
- if (!D(this.renderer, a)) {
148
+ if (!C(this.renderer, i)) {
140
149
  this.addStatusMessage({
141
150
  variant: "error",
142
151
  title: "Kiosk not visible"
143
152
  });
144
153
  return;
145
154
  }
146
- this.setKiosk(a), O(a), i.uiState.setUIScale(a.uiScale, !0), this.addStatusMessage({
155
+ this.setKiosk(i), D(i), o.uiState.setUIScale(i.uiScale, !0), this.addStatusMessage({
147
156
  variant: "success",
148
157
  title: "Saved"
149
- }), this.savedKiosk = a;
158
+ }), this.savedKiosk = i;
150
159
  }
151
160
  delayChange(e) {
152
161
  requestAnimationFrame(() => e == null ? void 0 : e());
@@ -159,7 +168,7 @@ let w = (t = class {
159
168
  }), Number.isFinite(e.scale) && (this.setKiosk({
160
169
  ...r,
161
170
  uiScale: e.scale
162
- }), this.delayChange(() => i.uiState.setUIScale(e.scale, !1))), Number.isFinite(e.percent) && this.setKiosk({
171
+ }), this.delayChange(() => o.uiState.setUIScale(e.scale, !1))), Number.isFinite(e.percent) && this.setKiosk({
163
172
  ...r,
164
173
  iconSizePercent: e.percent
165
174
  }));
@@ -178,7 +187,7 @@ let w = (t = class {
178
187
  point: e
179
188
  }) {
180
189
  var c;
181
- const r = h(this.kiosk), a = i.fp.getFloors(), p = C() ? (c = a.find((u) => u.active)) == null ? void 0 : c.name : null, s = i.uiState.uiScale;
190
+ const r = h(this.kiosk), i = o.fp.getFloors(), p = O() ? (c = i.find((u) => u.active)) == null ? void 0 : c.name : null, s = o.uiState.uiScale;
182
191
  this.setKiosk({
183
192
  ...r,
184
193
  x: e.x,
@@ -197,20 +206,20 @@ let w = (t = class {
197
206
  ...this.getCameraState()
198
207
  });
199
208
  }
200
- }, o(t.prototype, "kiosk", [g], Object.getOwnPropertyDescriptor(t.prototype, "kiosk"), t.prototype), o(t.prototype, "setKiosk", [l], Object.getOwnPropertyDescriptor(t.prototype, "setKiosk"), t.prototype), o(t.prototype, "renderer", [g], Object.getOwnPropertyDescriptor(t.prototype, "renderer"), t.prototype), S = o(t.prototype, "savedKiosk", [d], {
209
+ }, n(t.prototype, "kiosk", [d], Object.getOwnPropertyDescriptor(t.prototype, "kiosk"), t.prototype), n(t.prototype, "setKiosk", [l], Object.getOwnPropertyDescriptor(t.prototype, "setKiosk"), t.prototype), n(t.prototype, "renderer", [d], Object.getOwnPropertyDescriptor(t.prototype, "renderer"), t.prototype), S = n(t.prototype, "savedKiosk", [g], {
201
210
  configurable: !0,
202
211
  enumerable: !0,
203
212
  writable: !0,
204
213
  initializer: null
205
- }), o(t.prototype, "hasUnsavedChanges", [g], Object.getOwnPropertyDescriptor(t.prototype, "hasUnsavedChanges"), t.prototype), m = o(t.prototype, "statusMessages", [d], {
214
+ }), n(t.prototype, "hasUnsavedChanges", [d], Object.getOwnPropertyDescriptor(t.prototype, "hasUnsavedChanges"), t.prototype), m = n(t.prototype, "statusMessages", [g], {
206
215
  configurable: !0,
207
216
  enumerable: !0,
208
217
  writable: !0,
209
218
  initializer: function() {
210
219
  return [];
211
220
  }
212
- }), o(t.prototype, "addStatusMessage", [l], Object.getOwnPropertyDescriptor(t.prototype, "addStatusMessage"), t.prototype), o(t.prototype, "clearStatusMessages", [l], Object.getOwnPropertyDescriptor(t.prototype, "clearStatusMessages"), t.prototype), o(t.prototype, "startCleanupMessages", [l], Object.getOwnPropertyDescriptor(t.prototype, "startCleanupMessages"), t.prototype), o(t.prototype, "resetCamera", [l], Object.getOwnPropertyDescriptor(t.prototype, "resetCamera"), t.prototype), o(t.prototype, "restoreData", [l], Object.getOwnPropertyDescriptor(t.prototype, "restoreData"), t.prototype), o(t.prototype, "handleSetupReady", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleSetupReady"), t.prototype), o(t.prototype, "handleClose", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleClose"), t.prototype), o(t.prototype, "handleDelete", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleDelete"), t.prototype), o(t.prototype, "handleSave", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleSave"), t.prototype), o(t.prototype, "handleChange", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleChange"), t.prototype), o(t.prototype, "setInitialPtScale", [l], Object.getOwnPropertyDescriptor(t.prototype, "setInitialPtScale"), t.prototype), o(t.prototype, "handleClick", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleClick"), t.prototype), o(t.prototype, "handleNavigationChange", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleNavigationChange"), t.prototype), t);
213
- const F = new w();
221
+ }), n(t.prototype, "addStatusMessage", [l], Object.getOwnPropertyDescriptor(t.prototype, "addStatusMessage"), t.prototype), n(t.prototype, "clearStatusMessages", [l], Object.getOwnPropertyDescriptor(t.prototype, "clearStatusMessages"), t.prototype), n(t.prototype, "startCleanupMessages", [l], Object.getOwnPropertyDescriptor(t.prototype, "startCleanupMessages"), t.prototype), n(t.prototype, "resetCamera", [l], Object.getOwnPropertyDescriptor(t.prototype, "resetCamera"), t.prototype), n(t.prototype, "restoreData", [l], Object.getOwnPropertyDescriptor(t.prototype, "restoreData"), t.prototype), n(t.prototype, "handleSetupReady", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleSetupReady"), t.prototype), n(t.prototype, "handleClose", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleClose"), t.prototype), n(t.prototype, "handleDelete", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleDelete"), t.prototype), n(t.prototype, "handleSave", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleSave"), t.prototype), n(t.prototype, "handleChange", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleChange"), t.prototype), n(t.prototype, "setInitialPtScale", [l], Object.getOwnPropertyDescriptor(t.prototype, "setInitialPtScale"), t.prototype), n(t.prototype, "handleClick", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleClick"), t.prototype), n(t.prototype, "handleNavigationChange", [l], Object.getOwnPropertyDescriptor(t.prototype, "handleNavigationChange"), t.prototype), t);
222
+ const F = new P();
214
223
  export {
215
224
  F as k
216
225
  };
@@ -0,0 +1,118 @@
1
+ import { j as B } from "./jsx-runtime-BHfPvO9I.js";
2
+ import { y as w } from "./index-C1Rwmp91.js";
3
+ import { p, m as z, s as P, a as y, l as E, b as k, c as b, d as C, u as T, e as D, f as M, g as F, h as I, i as _ } from "./data-eO9H1gMa.js";
4
+ import { u as j, s as e, a as t, R as x, d as N, e as n, f as O, c as A } from "./floorplan.ready-CZn5dvsU.js";
5
+ import { r as S } from "./index-DnV82MKb.js";
6
+ (function() {
7
+ try {
8
+ var i = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
9
+ i.SENTRY_RELEASE = { id: "3.0.0-alpha.15" };
10
+ var r = new i.Error().stack;
11
+ r && (i._sentryDebugIds = i._sentryDebugIds || {}, i._sentryDebugIds[r] = "e036be8a-c898-44d0-b384-49c8ddf8108a", i._sentryDebugIdIdentifier = "sentry-dbid-e036be8a-c898-44d0-b384-49c8ddf8108a");
12
+ } catch {
13
+ }
14
+ })();
15
+ function $() {
16
+ const i = S.useRef(null), r = S.useRef(null);
17
+ let c = null, d = [];
18
+ const u = j(() => ({
19
+ get initselected() {
20
+ return ![...t.selectedBooths].filter((o) => o.rect);
21
+ },
22
+ get actualCurrentPosition() {
23
+ const o = e.routeStore.currentPosition;
24
+ return !(o != null && o.z) || e.layerStore.visible.indexOf(e.layerStore.findLayer(o.z)) > -1 ? o : null;
25
+ },
26
+ get style() {
27
+ return {
28
+ left: 0
29
+ };
30
+ }
31
+ }));
32
+ return S.useEffect(() => {
33
+ if (!r.current) {
34
+ var {
35
+ cx: o,
36
+ cy: l
37
+ } = p.viewbox;
38
+ r.current = new z.Map({
39
+ container: i.current,
40
+ style: `mapbox://styles/mapbox/${p.style}`,
41
+ center: [o, l],
42
+ zoom: 15.5,
43
+ bearing: p.initBearing - 30,
44
+ pitch: p.initPitch + 30,
45
+ maxPitch: 70,
46
+ bearingSnap: 0,
47
+ accessToken: p.token
48
+ }), P(r.current), r.current.on("load", async () => {
49
+ var f;
50
+ setTimeout(() => y(u.initselected ? x.fromMultiple([...t.selectedBooths].filter((s) => s.rect).map((s) => s.rect)) : N, 15, 4e3), 1500), r.current.setLight({
51
+ anchor: "viewport",
52
+ color: "white",
53
+ intensity: 0
54
+ });
55
+ const a = await E(e.boothStore.booths);
56
+ k(e.boothStore.booths, a), b("yah", (f = e.routeStore.defaultFrom) != null && f.rect ? {
57
+ x: e.routeStore.defaultFrom.rect.cx,
58
+ y: e.routeStore.defaultFrom.rect.cy
59
+ } : null), b("cp", u.actualCurrentPosition), d = C(e.layerStore.layers);
60
+ const m = d.filter((s) => s.indexOf("--") === -1);
61
+ T(e.routeStore), D(), r.current.on("mouseenter", m, () => r.current.getCanvas().style.cursor = "pointer"), r.current.on("mouseleave", m, () => r.current.getCanvas().style.cursor = ""), r.current.on("click", (s) => {
62
+ const h = [[s.point.x - 5, s.point.y - 5], [s.point.x + 5, s.point.y + 5]], v = r.current.queryRenderedFeatures(h, {
63
+ layers: d
64
+ })[0], L = e.boothStore.booths.find((R) => {
65
+ var g;
66
+ return R.name === ((g = v == null ? void 0 : v.properties) == null ? void 0 : g.id);
67
+ });
68
+ e.clickBooth(L);
69
+ });
70
+ });
71
+ }
72
+ }), n(() => t.zoomBy, () => {
73
+ if (!t.zoomBy || !e.mapboxStore.showMapbox) return;
74
+ const o = t.zoomBy;
75
+ t.zoomBy = null, r.current.flyTo({
76
+ zoom: r.current.getZoom() + (o > 1 ? 0.5 : -0.5),
77
+ animate: !0,
78
+ duration: 500,
79
+ essential: !0
80
+ });
81
+ }), n(() => [e.layerStore.loaded, e.layerStore.visible, t.selectedRoute], () => {
82
+ var o, l, a;
83
+ d.forEach((m) => {
84
+ const f = m.split("--")[0], s = e.layerStore.layers.find((h) => h.name === f);
85
+ (s.visible || r.current.getLayoutProperty(m, "visibility") !== "none") && r.current.setLayoutProperty(m, "visibility", s.visible ? "visible" : "none");
86
+ }), M([...t.selectedBooths], e.boothStore.booths), b("yah", (o = e.routeStore.defaultFrom) != null && o.rect && ((a = (l = e.routeStore.defaultFrom) == null ? void 0 : l.layer) != null && a.visible) ? {
87
+ x: e.routeStore.defaultFrom.rect.cx,
88
+ y: e.routeStore.defaultFrom.rect.cy
89
+ } : null), b("cp", u.actualCurrentPosition);
90
+ }), n(() => t.hoveredBooths, () => {
91
+ c && (clearTimeout(c), c = null), c = setTimeout(() => {
92
+ c = null, F([...t.hoveredBooths].filter((o) => {
93
+ var l, a;
94
+ return (a = (l = o.layer) == null ? void 0 : l.visible) != null ? a : !0;
95
+ }), e.boothStore.booths);
96
+ }, 50);
97
+ }), n(() => [t.selectedBooths, t.listBooths], () => {
98
+ var o = [];
99
+ t.selectedBooths.size ? o = [...t.selectedBooths] : t.listBooths.size && (t.activeListIndex === 0 || t.list.type === "bookmarks" || t.list.type === "category") && (o = [...t.listBooths]), M(o, e.boothStore.booths);
100
+ }), n(() => e.mapboxStore.showMapbox, () => {
101
+ I(e.mapboxStore.showMapbox);
102
+ }), n(() => t.moveToBooths, () => {
103
+ if (!t.moveToBooths || !e.mapboxStore.showMapbox) return;
104
+ const o = t.moveToBooths.filter((a) => a.rect).map((a) => a.rect), l = x.fromMultiple(o);
105
+ o.length && y(l), t.moveToBooths = null;
106
+ }), n(() => t.moveToRect, () => {
107
+ !t.moveToRect || !e.mapboxStore.showMapbox || (y(t.moveToRect, 15), t.moveToRect = null);
108
+ }), n(() => t.moveToLocation, () => {
109
+ !t.moveToLocation || !e.mapboxStore.showMapbox || _();
110
+ }), n(() => t.centerMap, () => {
111
+ !t.centerMap || !e.mapboxStore.showMapbox || (y(x.fromMultiple(O.booths.map((o) => o.rect)), 15), t.centerMap = !1);
112
+ }), n(() => e.routeStore.routeLines, () => T(e.routeStore)), n(() => u.actualCurrentPosition, () => b("cp", u.actualCurrentPosition)), A(() => /* @__PURE__ */ B.jsx("div", { style: u.style, className: w("map-container", {
113
+ hidden: !e.mapboxStore.showMapbox
114
+ }), children: /* @__PURE__ */ B.jsx("div", { ref: i, className: w("map-wrapper", "mapboxgl-map") }) }));
115
+ }
116
+ export {
117
+ $ as default
118
+ };
@@ -1,27 +1,36 @@
1
- import { j as e } from "./jsx-runtime-jIxVPx5o.js";
2
- import { r as y, x as b } from "./index-4ImEhZsQ.js";
3
- import { aj as _, ak as L, al as C, b as D, s as N } from "./floorplan.ready-D6FqQD8c.js";
4
- import { k as a } from "./KioskStore-D241RDzb.js";
5
- import { y as E } from "./index-D153Iyx8.js";
1
+ import { j as e } from "./jsx-runtime-BHfPvO9I.js";
2
+ import { r as I, x as b } from "./index-DnV82MKb.js";
3
+ import { aj as _, ak as E, al as w, b as D, s as N } from "./floorplan.ready-CZn5dvsU.js";
4
+ import { k as a } from "./KioskStore-_Zcv0Bc0.js";
5
+ import { y as L } from "./index-C1Rwmp91.js";
6
+ (function() {
7
+ try {
8
+ var s = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
9
+ s.SENTRY_RELEASE = { id: "3.0.0-alpha.15" };
10
+ var t = new s.Error().stack;
11
+ t && (s._sentryDebugIds = s._sentryDebugIds || {}, s._sentryDebugIds[t] = "87059c36-5c82-4090-86d7-770869e796de", s._sentryDebugIdIdentifier = "sentry-dbid-87059c36-5c82-4090-86d7-770869e796de");
12
+ } catch {
13
+ }
14
+ })();
6
15
  function S({
7
16
  value: s,
8
- name: r,
17
+ name: t,
9
18
  min: n,
10
- max: i,
11
- step: t,
19
+ max: r,
20
+ step: i,
12
21
  onChange: l,
13
22
  isDisabled: o,
14
23
  symbol: c
15
24
  }) {
16
- const x = () => l(Math.min(s + t, i)), j = () => l(Math.max(s - t, n));
25
+ const x = () => l(Math.min(s + i, r)), j = () => l(Math.max(s - i, n));
17
26
  let d = 0;
18
- i !== n && (d = (s - n) / (i - n) * 100);
27
+ r !== n && (d = (s - n) / (r - n) * 100);
19
28
  let u = "-50%";
20
29
  return d === 0 ? u = "0" : d === 100 && (u = "-100%"), /* @__PURE__ */ e.jsxs("div", { className: "efp-range-input", children: [
21
30
  /* @__PURE__ */ e.jsxs("span", { className: "efp-range-input__header", children: [
22
31
  /* @__PURE__ */ e.jsx("button", { type: "button", className: "efp-range-input__control", draggable: "false", onClick: j, disabled: o, "aria-label": "Decrease", children: /* @__PURE__ */ e.jsx("i", { className: "icon-minus" }) }),
23
32
  /* @__PURE__ */ e.jsxs("span", { className: "efp-no-select", children: [
24
- r,
33
+ t,
25
34
  " ",
26
35
  /* @__PURE__ */ e.jsxs("strong", { children: [
27
36
  s,
@@ -31,7 +40,7 @@ function S({
31
40
  /* @__PURE__ */ e.jsx("button", { type: "button", className: "efp-range-input__control", draggable: "false", onClick: x, disabled: o, "aria-label": "Increase", children: /* @__PURE__ */ e.jsx("i", { className: "icon-plus" }) })
32
41
  ] }),
33
42
  /* @__PURE__ */ e.jsxs("label", { className: "efp-range-input__input-block", children: [
34
- /* @__PURE__ */ e.jsx("input", { className: "efp-range-input__input", name: r, type: "range", min: n, max: i, step: t, value: s, disabled: o, onChange: (f) => l(Number(f.target.value)) }),
43
+ /* @__PURE__ */ e.jsx("input", { className: "efp-range-input__input", name: t, type: "range", min: n, max: r, step: i, value: s, disabled: o, onChange: (f) => l(Number(f.target.value)) }),
35
44
  /* @__PURE__ */ e.jsxs("span", { className: "efp-range-input__custom-input", children: [
36
45
  /* @__PURE__ */ e.jsx("span", { className: "efp-range-input__progress", style: {
37
46
  width: `${d}%`
@@ -44,12 +53,12 @@ function S({
44
53
  ] })
45
54
  ] });
46
55
  }
47
- function w({
56
+ function C({
48
57
  onSave: s,
49
- onDelete: r,
58
+ onDelete: t,
50
59
  isSaveDisabled: n,
51
- isDeleteDisabled: i,
52
- areControlsDisabled: t,
60
+ isDeleteDisabled: r,
61
+ areControlsDisabled: i,
53
62
  angle: l,
54
63
  onRotateIcon: o,
55
64
  uiScale: c,
@@ -62,12 +71,12 @@ function w({
62
71
  }) {
63
72
  return /* @__PURE__ */ e.jsx("div", { className: "efp-set-kiosk-form", children: /* @__PURE__ */ e.jsxs("div", { className: "efp-set-kiosk-form__content", children: [
64
73
  /* @__PURE__ */ e.jsxs("div", { className: "efp-set-kiosk-form__inputs", children: [
65
- /* @__PURE__ */ e.jsx(S, { value: l, name: "Icon rotation", min: 0, max: 360, step: 1, symbol: "°", isDisabled: t, onChange: o }),
66
- /* @__PURE__ */ e.jsx(S, { value: f, name: "Icon size", min: 100, max: 300, step: 1, symbol: "%", isDisabled: t, onChange: k }),
67
- /* @__PURE__ */ e.jsx(S, { value: Math.round(c * 100), name: "UI scale", min: x * 100, max: j * 100, step: d * 100, symbol: "%", isDisabled: t, onChange: (v) => u(v / 100) })
74
+ /* @__PURE__ */ e.jsx(S, { value: l, name: "Icon rotation", min: 0, max: 360, step: 1, symbol: "°", isDisabled: i, onChange: o }),
75
+ /* @__PURE__ */ e.jsx(S, { value: f, name: "Icon size", min: 100, max: 300, step: 1, symbol: "%", isDisabled: i, onChange: k }),
76
+ /* @__PURE__ */ e.jsx(S, { value: Math.round(c * 100), name: "UI scale", min: x * 100, max: j * 100, step: d * 100, symbol: "%", isDisabled: i, onChange: (v) => u(v / 100) })
68
77
  ] }),
69
78
  /* @__PURE__ */ e.jsxs("div", { className: "efp-set-kiosk-form__controls", children: [
70
- /* @__PURE__ */ e.jsx(_, { size: "md", variant: "gray", text: "Delete kiosk", onClick: r, disabled: i }),
79
+ /* @__PURE__ */ e.jsx(_, { size: "md", variant: "gray", text: "Delete kiosk", onClick: t, disabled: r }),
71
80
  /* @__PURE__ */ e.jsx(_, { size: "md", variant: "primary", text: "Save", onClick: s, disabled: n })
72
81
  ] })
73
82
  ] }) });
@@ -76,29 +85,29 @@ function U({
76
85
  list: s
77
86
  }) {
78
87
  return s != null && s.length ? /* @__PURE__ */ e.jsx("div", { className: "efp-info-message", children: s.map(({
79
- id: r,
88
+ id: t,
80
89
  image: n,
81
- content: i
90
+ content: r
82
91
  }) => /* @__PURE__ */ e.jsxs("div", { className: "efp-info-message__item", children: [
83
92
  /* @__PURE__ */ e.jsx("img", { className: "efp-info-message__img", src: n.src, alt: n.alt, width: "30", height: "30" }),
84
- /* @__PURE__ */ e.jsx("span", { children: i })
85
- ] }, r)) }) : null;
93
+ /* @__PURE__ */ e.jsx("span", { children: r })
94
+ ] }, t)) }) : null;
86
95
  }
87
96
  function z({
88
97
  isDisabled: s,
89
- content: r,
98
+ content: t,
90
99
  confirmLabel: n,
91
- cancelLabel: i,
92
- onConfirm: t,
100
+ cancelLabel: r,
101
+ onConfirm: i,
93
102
  onCancel: l,
94
103
  confirmVariant: o,
95
104
  cancelVariant: c
96
105
  }) {
97
106
  return /* @__PURE__ */ e.jsxs("div", { className: "efp-confirm-dialog", children: [
98
- r && /* @__PURE__ */ e.jsx("div", { className: "efp-confirm-dialog__content", children: r }),
107
+ t && /* @__PURE__ */ e.jsx("div", { className: "efp-confirm-dialog__content", children: t }),
99
108
  /* @__PURE__ */ e.jsxs("div", { className: "efp-confirm-dialog__controls", children: [
100
- /* @__PURE__ */ e.jsx(_, { size: "md", text: n, onClick: t, disabled: s, variant: o }),
101
- l && /* @__PURE__ */ e.jsx(_, { size: "md", text: i, variant: c, onClick: l, disabled: s })
109
+ /* @__PURE__ */ e.jsx(_, { size: "md", text: n, onClick: i, disabled: s, variant: o }),
110
+ l && /* @__PURE__ */ e.jsx(_, { size: "md", text: r, variant: c, onClick: l, disabled: s })
102
111
  ] })
103
112
  ] });
104
113
  }
@@ -106,27 +115,27 @@ function M({
106
115
  messages: s
107
116
  }) {
108
117
  return s != null && s.length ? /* @__PURE__ */ e.jsx("div", { className: "efp-status-messages", children: s.map(({
109
- id: r,
118
+ id: t,
110
119
  variant: n,
111
- title: i
120
+ title: r
112
121
  }) => {
113
- const t = n === "success", l = n === "error";
114
- return /* @__PURE__ */ e.jsxs("div", { className: E("efp-status-messages__message", {
115
- "efp-status-messages__message--success": t,
122
+ const i = n === "success", l = n === "error";
123
+ return /* @__PURE__ */ e.jsxs("div", { className: L("efp-status-messages__message", {
124
+ "efp-status-messages__message--success": i,
116
125
  "efp-status-messages__message--error": l
117
126
  }), children: [
118
- t ? /* @__PURE__ */ e.jsx("i", { className: "icon-checkmark" }) : null,
127
+ i ? /* @__PURE__ */ e.jsx("i", { className: "icon-checkmark" }) : null,
119
128
  l ? /* @__PURE__ */ e.jsx("i", { className: "icon-warning-solid" }) : null,
120
- i
121
- ] }, r);
129
+ r
130
+ ] }, t);
122
131
  }) }) : null;
123
132
  }
124
133
  function K({
125
134
  isSaveDisabled: s,
126
- isDeleteDisabled: r,
135
+ isDeleteDisabled: t,
127
136
  areControlsDisabled: n,
128
- confirmOnClose: i,
129
- angle: t,
137
+ confirmOnClose: r,
138
+ angle: i,
130
139
  uiScale: l,
131
140
  minUiScale: o,
132
141
  maxUiScale: c,
@@ -139,8 +148,8 @@ function K({
139
148
  onSave: v,
140
149
  onChange: m
141
150
  }) {
142
- const [h, g] = y.useState(null);
143
- return /* @__PURE__ */ e.jsxs(L, { className: "efp-set-kiosk-mode", translate: {
151
+ const [h, g] = I.useState(null);
152
+ return /* @__PURE__ */ e.jsxs(E, { className: "efp-set-kiosk-mode", translate: {
144
153
  x: window.innerWidth / 2,
145
154
  y: 0
146
155
  }, children: [
@@ -150,10 +159,10 @@ function K({
150
159
  /* @__PURE__ */ e.jsx("button", { type: "button", draggable: "false", className: "efp-set-kiosk-mode__close", "aria-label": "Close", onClick: () => {
151
160
  const p = () => {
152
161
  g(null);
153
- }, I = () => {
162
+ }, y = () => {
154
163
  f == null || f(), g(null);
155
164
  };
156
- h ? p() : i ? g({
165
+ h ? p() : r ? g({
157
166
  title: "Leave without saving?",
158
167
  content: /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
159
168
  "You have changes that ",
@@ -161,11 +170,11 @@ function K({
161
170
  ] }),
162
171
  confirmLabel: "Keep editing",
163
172
  cancelLabel: "Leave",
164
- onCancel: I,
173
+ onCancel: y,
165
174
  onConfirm: p,
166
175
  confirmVariant: "primary",
167
176
  cancelVariant: "danger"
168
- }) : I();
177
+ }) : y();
169
178
  }, children: /* @__PURE__ */ e.jsx("i", { className: "icon-close" }) })
170
179
  ] }),
171
180
  !h && /* @__PURE__ */ e.jsx(M, { messages: u }),
@@ -190,7 +199,7 @@ function K({
190
199
  /* @__PURE__ */ e.jsx("strong", { children: "Zoom and rotate" }),
191
200
  " the map before saving."
192
201
  ] })
193
- }] }) : /* @__PURE__ */ e.jsx(e.Fragment, { children: h ? /* @__PURE__ */ e.jsx(z, { ...h }) : /* @__PURE__ */ e.jsx(w, { isSaveDisabled: s, isDeleteDisabled: r, areControlsDisabled: n, onSave: () => {
202
+ }] }) : /* @__PURE__ */ e.jsx(e.Fragment, { children: h ? /* @__PURE__ */ e.jsx(z, { ...h }) : /* @__PURE__ */ e.jsx(C, { isSaveDisabled: s, isDeleteDisabled: t, areControlsDisabled: n, onSave: () => {
194
203
  v == null || v(), g(null);
195
204
  }, onDelete: () => {
196
205
  g({
@@ -211,7 +220,7 @@ function K({
211
220
  confirmVariant: "gray",
212
221
  cancelVariant: "danger"
213
222
  });
214
- }, angle: t, onRotateIcon: (p) => m == null ? void 0 : m({
223
+ }, angle: i, onRotateIcon: (p) => m == null ? void 0 : m({
215
224
  angle: p
216
225
  }), uiScale: l, minUiScale: o, maxUiScale: c, uiScaleStep: x, onUiScaleChange: (p) => m == null ? void 0 : m({
217
226
  scale: p
@@ -220,21 +229,21 @@ function K({
220
229
  }) }) })
221
230
  ] });
222
231
  }
223
- const B = C(() => {
224
- var r, n, i;
225
- D(() => a.handleSetupReady()), y.useEffect(() => {
226
- const t = (c) => a.setInitialPtScale(c);
227
- a.renderer.events.addEventListener("viewport:ptscale", t);
232
+ const P = w(() => {
233
+ var t, n, r;
234
+ D(() => a.handleSetupReady()), I.useEffect(() => {
235
+ const i = (c) => a.setInitialPtScale(c);
236
+ a.renderer.events.addEventListener("viewport:ptscale", i);
228
237
  const l = (c) => a.handleClick(c);
229
238
  a.renderer.events.addEventListener("pointer:click", l);
230
239
  const o = () => a.handleNavigationChange();
231
240
  return a.renderer.events.addEventListener("navigation:change", o), () => {
232
- a.renderer.events.removeEventListener("viewport:ptscale", t), a.renderer.events.removeEventListener("pointer:click", l), a.renderer.events.removeEventListener("navigation:change", o);
241
+ a.renderer.events.removeEventListener("viewport:ptscale", i), a.renderer.events.removeEventListener("pointer:click", l), a.renderer.events.removeEventListener("navigation:change", o);
233
242
  };
234
243
  }, [a.renderer]);
235
244
  const s = !!a.kiosk;
236
- return /* @__PURE__ */ e.jsx(K, { isSaveDisabled: s ? !a.hasUnsavedChanges : !0, isDeleteDisabled: !s, areControlsDisabled: !s, confirmOnClose: s ? a.hasUnsavedChanges : !1, angle: ((r = a.kiosk) == null ? void 0 : r.heading) || 0, uiScale: ((n = a.kiosk) == null ? void 0 : n.uiScale) || N.uiState.uiScale, minUiScale: N.uiState.minUIScale, maxUiScale: N.uiState.maxUIScale, uiScaleStep: 0.01, iconSizePercent: ((i = a.kiosk) == null ? void 0 : i.iconSizePercent) || 100, isInfoVisible: !s, statusMessages: a.statusMessages, onClose: () => a.handleClose(), onDelete: () => a.handleDelete(), onSave: () => a.handleSave(), onChange: (t) => a.handleChange(t) });
245
+ return /* @__PURE__ */ e.jsx(K, { isSaveDisabled: s ? !a.hasUnsavedChanges : !0, isDeleteDisabled: !s, areControlsDisabled: !s, confirmOnClose: s ? a.hasUnsavedChanges : !1, angle: ((t = a.kiosk) == null ? void 0 : t.heading) || 0, uiScale: ((n = a.kiosk) == null ? void 0 : n.uiScale) || N.uiState.uiScale, minUiScale: N.uiState.minUIScale, maxUiScale: N.uiState.maxUIScale, uiScaleStep: 0.01, iconSizePercent: ((r = a.kiosk) == null ? void 0 : r.iconSizePercent) || 100, isInfoVisible: !s, statusMessages: a.statusMessages, onClose: () => a.handleClose(), onDelete: () => a.handleDelete(), onSave: () => a.handleSave(), onChange: (i) => a.handleChange(i) });
237
246
  });
238
247
  export {
239
- B as default
248
+ P as default
240
249
  };