@expofp/floorplan 3.31.1 → 3.31.3

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 (76) hide show
  1. package/dist/browser/{Button-Zxrsl7_L.js → Button-BBN_kPGm.js} +5 -5
  2. package/dist/browser/{CookieConsent-BHPlLMdB.js → CookieConsent-CSm-J_is.js} +7 -7
  3. package/dist/browser/{Debug-CqHF7Ui7.js → Debug-CKWmoxug.js} +7 -7
  4. package/dist/browser/{DebugTools-DVIQiwOF.js → DebugTools-BLD3mXwj.js} +6 -6
  5. package/dist/browser/{Demo-CTPQwjin.js → Demo-70nqujku.js} +9 -9
  6. package/dist/browser/{Free-BN8DnixI.js → Free-CDOsdQzk.js} +9 -9
  7. package/dist/browser/{GalleryContainer-R9pRm1yT.js → GalleryContainer-LT-emSVp.js} +10 -10
  8. package/dist/browser/{GpsLoader-DY9QSSSB.js → GpsLoader-D2XDVEOe.js} +11 -11
  9. package/dist/browser/{KioskStore-uv260o-I.js → KioskStore-Dj_5h2h1.js} +22 -22
  10. package/dist/browser/{MaplibreAdapter-1WunjDYc.js → MaplibreAdapter-CjOxxksU.js} +14 -14
  11. package/dist/browser/{ModalContainer-Dpq2q9kp.js → ModalContainer-BIjQS8kR.js} +10 -10
  12. package/dist/browser/{PermissionNotice-BMglbCjv.js → PermissionNotice-COU4Zkmx.js} +6 -6
  13. package/dist/browser/{SetKioskMode-BqhffCFe.js → SetKioskMode-DRfhNTgl.js} +9 -9
  14. package/dist/browser/{ShowKiosk-CSzg-3PN.js → ShowKiosk-DMAVwRrH.js} +11 -11
  15. package/dist/browser/{ViewerMenuPanel-DYcOfmvC.js → ViewerMenuPanel-Cg7qHqR2.js} +9 -9
  16. package/dist/browser/{add-debug-secret-listener-Do7AJQ-B.js → add-debug-secret-listener-B77ESJTb.js} +1 -1
  17. package/dist/browser/{adopt-global-settings-CUq7CaWO.js → adopt-global-settings-DurGpZUV.js} +9 -9
  18. package/dist/browser/{boolean-editor-QNRg7mv9.js → boolean-editor-DOG7xvxI.js} +9 -9
  19. package/dist/browser/{bootIntercom-DNmECjIb.js → bootIntercom-D8Ze-qR8.js} +2 -2
  20. package/dist/browser/bundle.json +69 -69
  21. package/dist/browser/{camera-events-D-1cgSrw.js → camera-events-jSlinTa3.js} +1 -1
  22. package/dist/browser/{classnames-B_d2JNXt.js → classnames-YrD8m0I3.js} +2 -2
  23. package/dist/browser/{client-Bi66nh-4.js → client-aGqDjhVq.js} +5 -5
  24. package/dist/browser/{components-BWzDaly-.js → components-BKgyRL0m.js} +818 -818
  25. package/dist/browser/{debug-context-DcVFe_Lc.js → debug-context-CzdoCJ0c.js} +5 -5
  26. package/dist/browser/{debug-overlay-BRwTLlVL.js → debug-overlay-CNZvc0D4.js} +10 -10
  27. package/dist/browser/{debug-ui-C0sCYhBI.js → debug-ui-BxPGBJie.js} +6 -6
  28. package/dist/browser/{dimming-CoGADDvw.js → dimming-dnH6zZDj.js} +8 -8
  29. package/dist/browser/{dist-DXvqqBfz.js → dist-BiKYD85h.js} +3 -3
  30. package/dist/browser/{dist-CL4lGmQ7.js → dist-BrRFhCVZ.js} +6 -6
  31. package/dist/browser/{dist-DRk_kZKE.js → dist-DNK8o3qP.js} +5 -5
  32. package/dist/browser/{efp-debug-init-qLhKaNXN.js → efp-debug-init-Bht9K2EH.js} +3 -3
  33. package/dist/browser/{enum-editor-Ced7jQUo.js → enum-editor-DBZv2svz.js} +4 -4
  34. package/dist/browser/{es5-CtwPM82h.js → es5-TnYmPWjG.js} +2 -2
  35. package/dist/browser/{event-not-found-BJjV15mx.js → event-not-found-BPYTR01g.js} +1 -1
  36. package/dist/browser/{exports-B5pk0udX.js → exports-DjCuwk3r.js} +1 -1
  37. package/dist/browser/{favicon-RMbXtA1H.js → favicon-BUrOP4lf.js} +1 -1
  38. package/dist/browser/{fetch-retry.umd-ByYo1XFL.js → fetch-retry.umd-CbA-B9yF.js} +2 -2
  39. package/dist/browser/{flex-CQhKN_F2.js → flex-BEmPlamn.js} +5 -5
  40. package/dist/browser/{floorplan.loader-7eeXMIBw.js → floorplan.loader-rS9NLFQ8.js} +39 -39
  41. package/dist/browser/{floorplan.ready-DU8FaeTN.js → floorplan.ready-4huBhC9F.js} +331 -331
  42. package/dist/browser/{fuse-DIFfBV5K.js → fuse-CmNI9hVn.js} +2 -2
  43. package/dist/browser/{i18n-BhKie60p.js → i18n-DdUso7s5.js} +7 -7
  44. package/dist/browser/index.js +26 -26
  45. package/dist/browser/{index.module-Cfh6T1sl.js → index.module-BlTAPYK5.js} +4 -4
  46. package/dist/browser/{integrateKiosk-B6hctdem.js → integrateKiosk-BTu1crO1.js} +5 -5
  47. package/dist/browser/{is-webview-95gKBmNA.js → is-webview-CQDgCcW7.js} +1 -1
  48. package/dist/browser/{jsx-runtime-iavSqS3n.js → jsx-runtime-BJqWmmjS.js} +2 -2
  49. package/dist/browser/{kiosk-record-CfjEW7WB.js → kiosk-record-BrFhrJwB.js} +1 -1
  50. package/dist/browser/{lib-CIZx-v0G.js → lib-D-ObKimb.js} +3 -3
  51. package/dist/browser/{loadImage-DW14-NrZ.js → loadImage-BVo7mVU4.js} +5 -5
  52. package/dist/browser/{logDeviceInfo-C0H4zpF1.js → logDeviceInfo-C2J56LTZ.js} +9 -9
  53. package/dist/browser/mobx-aDG_Vyhy.js +43 -0
  54. package/dist/browser/{optional-boolean-editor-gLxb1EfH.js → optional-boolean-editor-jZOp2AFS.js} +3 -3
  55. package/dist/browser/{optional-enum-editor-Df_RvQ-w.js → optional-enum-editor-CSe-odwi.js} +4 -4
  56. package/dist/browser/{optional-string-editor-CZlXCy_b.js → optional-string-editor-qEGt4QJc.js} +4 -4
  57. package/dist/browser/{particles.min-BmhrldLm.js → particles.min-D-v8qxg4.js} +2 -2
  58. package/dist/browser/{react-Brvhg-xh.js → react-Cvc1qlOt.js} +2 -2
  59. package/dist/browser/{react-dom-6jF-UVR3.js → react-dom-Cd_XHqGm.js} +3 -3
  60. package/dist/browser/{rolldown-runtime-k8xrJES4.js → rolldown-runtime-ScD5F-7e.js} +1 -1
  61. package/dist/browser/{scheduler-C87k6FXk.js → scheduler-DwDWJkjq.js} +2 -2
  62. package/dist/browser/{select-EAJIc_L6.js → select-DSpc473R.js} +10 -10
  63. package/dist/browser/{settings-CR-KWdwH.js → settings-BYzcsyAh.js} +2 -2
  64. package/dist/browser/{settings-item-uJSoUoiz.js → settings-item-BctYdjJb.js} +6 -6
  65. package/dist/browser/{store-NHdnYbrz.js → store-vnozccTF.js} +2812 -2812
  66. package/dist/browser/{string-editor-gLsfuXuu.js → string-editor-DsXuNKrp.js} +4 -4
  67. package/dist/browser/{text-field-CFNebSVw.js → text-field-D2w8WygK.js} +5 -5
  68. package/dist/browser/{theme-DU1fheT_.js → theme-BlVoqah-.js} +8 -8
  69. package/dist/browser/{ui-DyeTcwQr.js → ui-Bltsyo3n.js} +8 -8
  70. package/dist/browser/{useRenderTarget-pX44x65X.js → useRenderTarget-GMlEC-iR.js} +4 -4
  71. package/dist/browser/{viewport-NsKO0_TX.js → viewport-BwzPH2y-.js} +2 -2
  72. package/dist/esm/components/Map/MapCamera.js +1 -1
  73. package/dist/esm/utils/mobx.d.ts +29 -0
  74. package/dist/esm/utils/mobx.js +1 -1
  75. package/package.json +10 -10
  76. package/dist/browser/mobx-D_lfMZGC.js +0 -24
@@ -1,14 +1,14 @@
1
1
  (function() {
2
2
  try {
3
3
  var e = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
4
- e.SENTRY_RELEASE = { id: "3.31.1" };
4
+ e.SENTRY_RELEASE = { id: "3.31.3" };
5
5
  var t = new e.Error().stack;
6
6
  t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "edf52ee9-f3a6-424f-a5ff-f0c8342333ab", e._sentryDebugIdIdentifier = "sentry-dbid-edf52ee9-f3a6-424f-a5ff-f0c8342333ab");
7
7
  } catch {}
8
8
  })();
9
- import { t as e } from "./jsx-runtime-iavSqS3n.js";
10
- import { t } from "./settings-item-uJSoUoiz.js";
11
- import { t as n } from "./text-field-CFNebSVw.js";
9
+ import { t as e } from "./jsx-runtime-BJqWmmjS.js";
10
+ import { t } from "./settings-item-BctYdjJb.js";
11
+ import { t as n } from "./text-field-D2w8WygK.js";
12
12
  //#region ../debug/src/lib/ui/string-editor.tsx
13
13
  var r = e(), i = (e) => {
14
14
  var i;
@@ -1,15 +1,15 @@
1
1
  (function() {
2
2
  try {
3
3
  var e = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
4
- e.SENTRY_RELEASE = { id: "3.31.1" };
4
+ e.SENTRY_RELEASE = { id: "3.31.3" };
5
5
  var t = new e.Error().stack;
6
6
  t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "b57a1337-f6ba-488a-8e6f-60f9358b45a2", e._sentryDebugIdIdentifier = "sentry-dbid-b57a1337-f6ba-488a-8e6f-60f9358b45a2");
7
7
  } catch {}
8
8
  })();
9
- import { r as e } from "./rolldown-runtime-k8xrJES4.js";
10
- import { t } from "./react-Brvhg-xh.js";
11
- import { D as n, i as r, l as i, n as a, s as o, u as s, y as c } from "./flex-CQhKN_F2.js";
12
- import { t as l } from "./classnames-B_d2JNXt.js";
9
+ import { r as e } from "./rolldown-runtime-ScD5F-7e.js";
10
+ import { t } from "./react-Cvc1qlOt.js";
11
+ import { D as n, i as r, l as i, n as a, s as o, u as s, y as c } from "./flex-BEmPlamn.js";
12
+ import { t as l } from "./classnames-YrD8m0I3.js";
13
13
  //#region ../../node_modules/.pnpm/@radix-ui+themes@3.3.0_@types+react-dom@19.2.3_@types+react@19.2.17__@types+react@19.2._5ea800d4e947acedb1fa1275f1697b17/node_modules/@radix-ui/themes/dist/esm/components/text-field.props.js
14
14
  var u = /* @__PURE__ */ e(t()), d = /* @__PURE__ */ e(l()), f = {
15
15
  size: {
@@ -1,18 +1,18 @@
1
1
  (function() {
2
2
  try {
3
3
  var e = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
4
- e.SENTRY_RELEASE = { id: "3.31.1" };
4
+ e.SENTRY_RELEASE = { id: "3.31.3" };
5
5
  var t = new e.Error().stack;
6
6
  t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "f5429b84-6f5b-4b20-898f-e5345902ef44", e._sentryDebugIdIdentifier = "sentry-dbid-f5429b84-6f5b-4b20-898f-e5345902ef44");
7
7
  } catch {}
8
8
  })();
9
- import { r as e } from "./rolldown-runtime-k8xrJES4.js";
10
- import { t } from "./react-Brvhg-xh.js";
11
- import { t as n } from "./jsx-runtime-iavSqS3n.js";
12
- import { t as r } from "./react-dom-6jF-UVR3.js";
13
- import { C as i, E as a, O as o, T as s, _ as c, o as l, v as u, w as d } from "./flex-CQhKN_F2.js";
14
- import { c as f, i as p, n as m, o as h, r as g, s as _, t as v } from "./dist-CL4lGmQ7.js";
15
- import { t as y } from "./classnames-B_d2JNXt.js";
9
+ import { r as e } from "./rolldown-runtime-ScD5F-7e.js";
10
+ import { t } from "./react-Cvc1qlOt.js";
11
+ import { t as n } from "./jsx-runtime-BJqWmmjS.js";
12
+ import { t as r } from "./react-dom-Cd_XHqGm.js";
13
+ import { C as i, E as a, O as o, T as s, _ as c, o as l, v as u, w as d } from "./flex-BEmPlamn.js";
14
+ import { c as f, i as p, n as m, o as h, r as g, s as _, t as v } from "./dist-BrRFhCVZ.js";
15
+ import { t as y } from "./classnames-YrD8m0I3.js";
16
16
  //#region ../../node_modules/.pnpm/@radix-ui+react-visually-hidden@1.2.3_@types+react-dom@19.2.3_@types+react@19.2.17__@ty_cffccd7838985066e8e1d993b5cb6017/node_modules/@radix-ui/react-visually-hidden/dist/index.mjs
17
17
  var b = /* @__PURE__ */ e(r(), 1), x = /* @__PURE__ */ e(t(), 1), S = n(), C = Object.freeze({
18
18
  position: "absolute",
@@ -1,17 +1,17 @@
1
1
  (function() {
2
2
  try {
3
3
  var e = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
4
- e.SENTRY_RELEASE = { id: "3.31.1" };
4
+ e.SENTRY_RELEASE = { id: "3.31.3" };
5
5
  var t = new e.Error().stack;
6
6
  t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "cbb5c555-77ff-4375-8420-80c8ae476dcf", e._sentryDebugIdIdentifier = "sentry-dbid-cbb5c555-77ff-4375-8420-80c8ae476dcf");
7
7
  } catch {}
8
8
  })();
9
- import { r as e } from "./rolldown-runtime-k8xrJES4.js";
10
- import { a as t, i as n, s as r } from "./efp-debug-init-qLhKaNXN.js";
11
- import { a as i, i as a } from "./adopt-global-settings-CUq7CaWO.js";
12
- import { t as o } from "./jsx-runtime-iavSqS3n.js";
13
- import "./settings-CR-KWdwH.js";
14
- import { t as s } from "./add-debug-secret-listener-Do7AJQ-B.js";
9
+ import { r as e } from "./rolldown-runtime-ScD5F-7e.js";
10
+ import { a as t, i as n, s as r } from "./efp-debug-init-Bht9K2EH.js";
11
+ import { a as i, i as a } from "./adopt-global-settings-DurGpZUV.js";
12
+ import { t as o } from "./jsx-runtime-BJqWmmjS.js";
13
+ import "./settings-BYzcsyAh.js";
14
+ import { t as s } from "./add-debug-secret-listener-B77ESJTb.js";
15
15
  //#region ../debug/src/lib/ui/render-debug-ui.tsx
16
16
  var c = /* @__PURE__ */ e(r(), 1), l = o(), u = !1;
17
17
  function d() {
@@ -26,7 +26,7 @@ function d() {
26
26
  }
27
27
  });
28
28
  let o = async (t) => {
29
- let { DebugUi: n } = await import("./debug-ui-C0sCYhBI.js"), { createRoot: i } = await import("./client-Bi66nh-4.js").then((t) => /* @__PURE__ */ e(t.t(), 1)), a = document.createElement("div");
29
+ let { DebugUi: n } = await import("./debug-ui-BxPGBJie.js"), { createRoot: i } = await import("./client-aGqDjhVq.js").then((t) => /* @__PURE__ */ e(t.t(), 1)), a = document.createElement("div");
30
30
  document.body.appendChild(a), i(a).render(/* @__PURE__ */ (0, l.jsx)(n, {
31
31
  useDebugButtonState: r.useState,
32
32
  open: t
@@ -1,14 +1,14 @@
1
1
  (function() {
2
2
  try {
3
3
  var e = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
4
- e.SENTRY_RELEASE = { id: "3.31.1" };
4
+ e.SENTRY_RELEASE = { id: "3.31.3" };
5
5
  var t = new e.Error().stack;
6
6
  t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "7407e64e-4c4e-4bfb-b2ef-80063ad22998", e._sentryDebugIdIdentifier = "sentry-dbid-7407e64e-4c4e-4bfb-b2ef-80063ad22998");
7
7
  } catch {}
8
8
  })();
9
- import { r as e } from "./rolldown-runtime-k8xrJES4.js";
10
- import { t } from "./react-Brvhg-xh.js";
11
- import { l as n } from "./store-NHdnYbrz.js";
9
+ import { r as e } from "./rolldown-runtime-ScD5F-7e.js";
10
+ import { t } from "./react-Cvc1qlOt.js";
11
+ import { l as n } from "./store-vnozccTF.js";
12
12
  //#region ../ui/src/shared/activeElement.ts
13
13
  var r = (e) => !!e && "activeElement" in e;
14
14
  function i(e) {
@@ -1,12 +1,12 @@
1
1
  (function() {
2
2
  try {
3
3
  var e = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
4
- e.SENTRY_RELEASE = { id: "3.31.1" };
4
+ e.SENTRY_RELEASE = { id: "3.31.3" };
5
5
  var t = new e.Error().stack;
6
6
  t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "30d5a1aa-2d79-4710-91d1-937109f43b1a", e._sentryDebugIdIdentifier = "sentry-dbid-30d5a1aa-2d79-4710-91d1-937109f43b1a");
7
7
  } catch {}
8
8
  })();
9
- import { c as e, vt as t } from "./store-NHdnYbrz.js";
9
+ import { c as e, vt as t } from "./store-vnozccTF.js";
10
10
  //#region src/components/Map/viewport.ts
11
11
  function n(e) {
12
12
  return {
@@ -1 +1 @@
1
- import{Box as s}from"@expofp/geometry";import{useCameraAPI as h,useCameraMoveStart as y,useCameraState as x}from"@expofp/renderer";import{useEffect as R,useLayoutEffect as T,useRef as B,useState as M}from"react";import{fpGeo as P}from"../../data/fpGeo";import{svgArea as S}from"../../data/svg";import p,{uiState as r}from"../../store";import{BoothBase as C}from"../../store/BoothStore";import d from"../../tools/logger";import F from"../../tools/settings";import{areLayersEnabled as w}from"../../utils/areLayersEnabled";import{parseNumberPair as l}from"../../utils/camera-map-settings";import{convertGpsToLocal as z}from"../../utils/gps";import{useReaction as f}from"../../utils/mobx";import{createMapCamera as E,setMapCamera as v}from"./camera";import{notifyCameraMoved as N}from"./camera-events";import{resetExternalOverlay as b}from"./pointer";export function MapCamera(){const o=h(),n=x(),t=B({api:o,state:n}),[a]=M(()=>E(t));return T(()=>{t.current={api:o,state:n}}),R(()=>(v(a),()=>v(void 0)),[a]),y(()=>{b(),N()}),f(()=>r.zoomBy,e=>{e&&(t.current.api.zoomBy(e),r.zoomBy=null)},void 0,[]),f(()=>r.rollReset,e=>{e&&(t.current.api.reset({roll:!0}),r.rollReset=!1)},void 0,[]),f(()=>r.centerMap,e=>{e&&(t.current.api.reset({zoom:!!(r.list.type==="search"&&r.list.text)}),r.centerMap=!1)},void 0,[]),f(()=>r.moveToRect,e=>{if(!e)return;const{width:m,height:i}=e.size;m>0&&i>0&&Number.isFinite(m)&&Number.isFinite(i)&&g(t.current.api,e,r.moveToRectPaddingPercent??void 0),r.moveToRect=null,r.moveToRectPaddingPercent=null},void 0,[]),f(()=>r.moveToBooths,e=>{if(!e)return;d.log("watched moveToBooths",e);const m=e.filter(i=>i.rect).map(i=>i.rect);m.length&&g(t.current.api,s.fromUnion(...m)),r.moveToBooths=null},void 0,[]),f(()=>r.mapSettings,({center:e,centerxy:m,bearing:i,z:c})=>{try{c&&p.fp.activateFloor({name:c});const u=A(e,m);u&&t.current.api.panTo(u),Number.isFinite(i)&&t.current.api.rollTo(i)}catch(u){d.error("Error in mapSettings reaction",u)}},void 0,[]),null}function g(o,n,t){o.zoomTo(L(n),{padding:t??G(n,S),maxZoom:Number.isFinite(F.maxZoom)?void 0:10,within:k()})}function k(){const o=r.canvasVisibleRectPx;return r.shouldShiftMapRect?s.fromMinMax({x:o.min.x+r.overlayWidthPx,y:o.min.y},o.max):o}function L(o){const n=r.kioskData;if(!n)return o;const t=r.selectedRoute?.from,a=t instanceof C?t.layer?.name:t?.layer;return(w()?a===p.routeStore.currentRouteLayer?.name:!0)?s.fromUnion(o,new s(n.x,n.y,1,1)):o}function G(o,n){return!o||!n?0:(o.area/n.area>.1?15:25)/100}function A(o,n){if(o){const a=l(o);if(!a)return;const e=P?.properties?.config;if(!e)throw new Error("Map center given in GPS, but the plan has no GPS config");return z({lat:a[0],lng:a[1]},e)??void 0}const t=l(n);if(t)return{x:t[0],y:t[1]}}
1
+ import{Box as u}from"@expofp/geometry";import{useCameraAPI as g,useCameraMoveStart as y,useCameraState as x}from"@expofp/renderer";import{useEffect as R,useLayoutEffect as T,useRef as B,useState as M}from"react";import{fpGeo as S}from"../../data/fpGeo";import{svgArea as P}from"../../data/svg";import p,{uiState as r}from"../../store";import{BoothBase as C}from"../../store/BoothStore";import l from"../../tools/logger";import F from"../../tools/settings";import{areLayersEnabled as w}from"../../utils/areLayersEnabled";import{parseNumberPair as d}from"../../utils/camera-map-settings";import{convertGpsToLocal as z}from"../../utils/gps";import{useOneShotReaction as f,useReaction as E}from"../../utils/mobx";import{createMapCamera as N,setMapCamera as v}from"./camera";import{notifyCameraMoved as b}from"./camera-events";import{resetExternalOverlay as k}from"./pointer";export function MapCamera(){const o=g(),n=x(),t=B({api:o,state:n}),[a]=M(()=>N(t));return T(()=>{t.current={api:o,state:n}}),R(()=>(v(a),()=>v(void 0)),[a]),y(()=>{k(),b()}),f(()=>r.zoomBy,e=>{e&&(t.current.api.zoomBy(e),r.zoomBy=null)},[]),f(()=>r.rollReset,e=>{e&&(t.current.api.reset({roll:!0}),r.rollReset=!1)},[]),f(()=>r.centerMap,e=>{e&&(t.current.api.reset({zoom:!!(r.list.type==="search"&&r.list.text)}),r.centerMap=!1)},[]),f(()=>r.moveToRect,e=>{if(!e)return;const{width:m,height:i}=e.size;m>0&&i>0&&Number.isFinite(m)&&Number.isFinite(i)&&h(t.current.api,e,r.moveToRectPaddingPercent??void 0),r.moveToRect=null,r.moveToRectPaddingPercent=null},[]),f(()=>r.moveToBooths,e=>{if(!e)return;l.log("watched moveToBooths",e);const m=e.filter(i=>i.rect).map(i=>i.rect);m.length&&h(t.current.api,u.fromUnion(...m)),r.moveToBooths=null},[]),E(()=>r.mapSettings,({center:e,centerxy:m,bearing:i,z:c})=>{try{c&&p.fp.activateFloor({name:c});const s=O(e,m);s&&t.current.api.panTo(s),Number.isFinite(i)&&t.current.api.rollTo(i)}catch(s){l.error("Error in mapSettings reaction",s)}},void 0,[]),null}function h(o,n,t){o.zoomTo(G(n),{padding:t??A(n,P),maxZoom:Number.isFinite(F.maxZoom)?void 0:10,within:L()})}function L(){const o=r.canvasVisibleRectPx;return r.shouldShiftMapRect?u.fromMinMax({x:o.min.x+r.overlayWidthPx,y:o.min.y},o.max):o}function G(o){const n=r.kioskData;if(!n)return o;const t=r.selectedRoute?.from,a=t instanceof C?t.layer?.name:t?.layer;return(w()?a===p.routeStore.currentRouteLayer?.name:!0)?u.fromUnion(o,new u(n.x,n.y,1,1)):o}function A(o,n){return!o||!n?0:(o.area/n.area>.1?15:25)/100}function O(o,n){if(o){const a=d(o);if(!a)return;const e=S?.properties?.config;if(!e)throw new Error("Map center given in GPS, but the plan has no GPS config");return z({lat:a[0],lng:a[1]},e)??void 0}const t=d(n);if(t)return{x:t[0],y:t[1]}}
@@ -2,5 +2,34 @@ import { IAutorunOptions, IReactionOptions, IReactionPublic } from 'mobx';
2
2
  import { DependencyList, EffectCallback } from 'react';
3
3
  export declare function useAutorun(view: (r: IReactionPublic) => any, opts?: IAutorunOptions): void;
4
4
  export declare function useReaction<T>(expression: (r: IReactionPublic) => T, effect: (arg: T, r: IReactionPublic) => void, opts?: IReactionOptions, deps?: DependencyList): void;
5
+ /**
6
+ * Watches a **one-shot store command** — a flag the store sets and the consumer clears — from the
7
+ * first moment the consumer can actually act on one.
8
+ *
9
+ * Both halves of that matter, and a plain `reaction` gets both wrong for these flags:
10
+ *
11
+ * - It cannot see a command set *before* it subscribed. A reaction adopts whatever the expression
12
+ * reads at subscribe time as its baseline, so such a command is never delivered and, since
13
+ * nothing re-sets it, sits unhandled forever.
14
+ * - It would act on one set *too early*. The scene fits its space to the canvas in an effect of its
15
+ * own, and React runs a parent's effects after its children's, so a consumer mounted under the
16
+ * scene has no usable camera until the next frame. A command spent there is consumed and lost.
17
+ *
18
+ * Both windows are real, and the plan opens them itself: it reports `ready` from the same
19
+ * synchronous block that hands React the scene, so `<MapCamera>` mounts a commit after a host can
20
+ * first call in, and its camera is only fitted the frame after that. A host that selects a booth on
21
+ * `ready` lands in one window or the other depending on how loaded the machine is — the booth
22
+ * highlighted, and the camera never moved.
23
+ *
24
+ * So the whole subscription waits for the end of the mounting commit, and drains whatever has piled
25
+ * up by then.
26
+ * @param read - Reads the command flag.
27
+ * @param handle - Acts on it and clears it. Also called with the flag's cleared value, which every
28
+ * handler already guards against — that is what makes each command land exactly once.
29
+ * @returns Disposes the watch.
30
+ */
31
+ export declare function watchOneShot<T>(read: () => T, handle: (value: T) => void): () => void;
32
+ /** {@link watchOneShot}, held for as long as the component is mounted. */
33
+ export declare function useOneShotReaction<T>(read: () => T, handle: (value: T) => void, deps?: DependencyList): void;
5
34
  export declare function useInit(effect: EffectCallback): void;
6
35
  //# sourceMappingURL=mobx.d.ts.map
@@ -1 +1 @@
1
- import{autorun as e,reaction as i}from"mobx";import{useEffect as n}from"react";export function useAutorun(t,r){return n(()=>e(t,r),[])}export function useReaction(t,r,o,u=[]){return n(()=>i(t,r,o),u)}export function useInit(t){return n(t,[])}
1
+ import{autorun as c,reaction as u,untracked as a}from"mobx";import{useEffect as o}from"react";export function useAutorun(t,e){return o(()=>c(t,e),[])}export function useReaction(t,e,n,r=[]){return o(()=>u(t,e,n),r)}function m(t){if(typeof requestAnimationFrame=="function"){const n=requestAnimationFrame(t);return()=>cancelAnimationFrame(n)}const e=setTimeout(t,0);return()=>clearTimeout(e)}export function watchOneShot(t,e){let n;const r=m(()=>{n=u(t,i=>e(i)),e(a(t))});return()=>{r(),n?.()}}export function useOneShotReaction(t,e,n=[]){return o(()=>watchOneShot(t,e),n)}export function useInit(t){return o(t,[])}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@expofp/floorplan",
3
- "version": "3.31.1",
3
+ "version": "3.31.3",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/expofp/efp-app.git",
@@ -69,15 +69,15 @@
69
69
  "tslib": "^2.3.0",
70
70
  "uuid": "^9.0.1",
71
71
  "zod": "4.4.3",
72
- "@expofp/config": "3.31.1",
73
- "@expofp/debug": "3.31.1",
74
- "@expofp/geometry": "3.31.1",
75
- "@expofp/renderer": "3.31.1",
76
- "@expofp/resolve": "3.31.1",
77
- "@expofp/schema": "3.31.1",
78
- "@expofp/ui": "3.31.1",
79
- "@expofp/utils": "3.31.1",
80
- "@expofp/wayfinding": "3.31.1"
72
+ "@expofp/config": "3.31.3",
73
+ "@expofp/debug": "3.31.3",
74
+ "@expofp/geometry": "3.31.3",
75
+ "@expofp/renderer": "3.31.3",
76
+ "@expofp/resolve": "3.31.3",
77
+ "@expofp/schema": "3.31.3",
78
+ "@expofp/ui": "3.31.3",
79
+ "@expofp/utils": "3.31.3",
80
+ "@expofp/wayfinding": "3.31.3"
81
81
  },
82
82
  "devDependencies": {
83
83
  "@babel/plugin-proposal-decorators": "^8.0.2",
@@ -1,24 +0,0 @@
1
- (function() {
2
- try {
3
- var e = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
4
- e.SENTRY_RELEASE = { id: "3.31.1" };
5
- var t = new e.Error().stack;
6
- t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "0b582490-601d-4ef4-92bb-5f520fa5717f", e._sentryDebugIdIdentifier = "sentry-dbid-0b582490-601d-4ef4-92bb-5f520fa5717f");
7
- } catch {}
8
- })();
9
- import { r as e } from "./rolldown-runtime-k8xrJES4.js";
10
- import { f as t, v as n } from "./i18n-BhKie60p.js";
11
- import { t as r } from "./react-Brvhg-xh.js";
12
- //#region src/utils/mobx.ts
13
- var i = /* @__PURE__ */ e(r(), 1);
14
- function a(e, n) {
15
- return (0, i.useEffect)(() => t(e, n), []);
16
- }
17
- function o(e, t, r, a = []) {
18
- return (0, i.useEffect)(() => n(e, t, r), a);
19
- }
20
- function s(e) {
21
- return (0, i.useEffect)(e, []);
22
- }
23
- //#endregion
24
- export { s as n, o as r, a as t };