@kosdev-code/kos-dispense-sdk 2.1.12 → 2.1.14

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.
@@ -139,7 +139,7 @@ const Ye = (e) => S({
139
139
  clearBrand: u
140
140
  };
141
141
  };
142
- class Ge {
142
+ class Ue {
143
143
  constructor() {
144
144
  J(this, "_data", /* @__PURE__ */ new Map());
145
145
  }
@@ -159,7 +159,7 @@ class Ge {
159
159
  const bt = T.createLogger({
160
160
  name: "HoldToPourStrategy",
161
161
  group: "kos-hooks"
162
- }), Ue = {
162
+ }), Ge = {
163
163
  name: "HoldToPourStrategy",
164
164
  async initiate(e) {
165
165
  if (!(e != null && e.canPour)) {
@@ -180,10 +180,10 @@ const bt = T.createLogger({
180
180
  onBeforePour: s,
181
181
  onBeforePourRejected: n,
182
182
  pourContext: r,
183
- strategy: a = Ue
183
+ strategy: a = Ge
184
184
  }) => {
185
185
  const { model: i } = _(), [d, v] = x(
186
- r || new Ge()
186
+ r || new Ue()
187
187
  ), f = c(async () => {
188
188
  (s ? await (s == null ? void 0 : s(d)) : !0) ? (ae.debug(
189
189
  `[${a == null ? void 0 : a.name}] - Pour initiated for nozzle ${i == null ? void 0 : i.id}.`
@@ -311,7 +311,7 @@ const bt = T.createLogger({
311
311
  ), o = c(async () => {
312
312
  const p = `/kos/dispense/${r == null ? void 0 : r.path}/pre/pour/rejected/`;
313
313
  g.publish(p, {});
314
- }, [r == null ? void 0 : r.path]), U = c(() => {
314
+ }, [r == null ? void 0 : r.path]), G = c(() => {
315
315
  const p = `/kos/dispense/${r == null ? void 0 : r.path}/pour/cancel/`;
316
316
  g.publish(p, {});
317
317
  }, [r == null ? void 0 : r.path]), { brands: B, selectBrand: C, selectedBrand: Q, clearBrand: O, brandCompanions: ue } = ft({
@@ -342,7 +342,7 @@ const bt = T.createLogger({
342
342
  W(() => p);
343
343
  }, []), X = vt({
344
344
  onPour: b,
345
- onPourCancel: U,
345
+ onPourCancel: G,
346
346
  onBeforePour: h,
347
347
  onBeforePourRejected: o
348
348
  });
@@ -648,7 +648,7 @@ const bt = T.createLogger({
648
648
  restart: $,
649
649
  pause: w
650
650
  };
651
- }, G = T.createLogger({ name: "useDefaultCuiKitLifecycle" }), Ft = ({
651
+ }, U = T.createLogger({ name: "useDefaultCuiKitLifecycle" }), Ft = ({
652
652
  kit: e,
653
653
  inactivity: t,
654
654
  pour: s,
@@ -657,19 +657,19 @@ const bt = T.createLogger({
657
657
  areYouThereRejectionPolicy: a = "pause"
658
658
  }) => {
659
659
  var I, Z, Ie, xe;
660
- const [i, d] = x(!1), [v, f] = x(!1), { model: u } = _(), [l, $] = x(!1), w = (t == null ? void 0 : t.idleTimeout) ?? 15, b = (t == null ? void 0 : t.areYouThereTimeoutOffset) ?? 10, h = (s == null ? void 0 : s.idleTimeout) ?? (t == null ? void 0 : t.idleTimeout) ?? 10, o = (s == null ? void 0 : s.areYouThereTimeoutOffset) ?? (t == null ? void 0 : t.areYouThereTimeoutOffset) ?? 5, U = n == null ? void 0 : n.ambientTimeoutOffset, B = n == null ? void 0 : n.attractTimeout, C = c(() => {
661
- if (G.info("handleIdleTimeout called - navigating home and publishing event"), V(!1), e == null || e.nav.home(), u) {
660
+ const [i, d] = x(!1), [v, f] = x(!1), { model: u } = _(), [l, $] = x(!1), w = (t == null ? void 0 : t.idleTimeout) ?? 15, b = (t == null ? void 0 : t.areYouThereTimeoutOffset) ?? 10, h = (s == null ? void 0 : s.idleTimeout) ?? (t == null ? void 0 : t.idleTimeout) ?? 10, o = (s == null ? void 0 : s.areYouThereTimeoutOffset) ?? (t == null ? void 0 : t.areYouThereTimeoutOffset) ?? 5, G = n == null ? void 0 : n.ambientTimeoutOffset, B = n == null ? void 0 : n.attractTimeout, C = c(() => {
661
+ if (U.info("handleIdleTimeout called - navigating home and publishing event"), V(!1), e == null || e.nav.home(), u) {
662
662
  const E = `/kos/dispense/${u.path}/idle/timeout/`;
663
663
  g.publish(E, {});
664
664
  }
665
665
  }, [(I = e == null ? void 0 : e.nav) == null ? void 0 : I.home, u]), Q = c(() => {
666
- G.info("handleResetIdleTimer called - resetting idle timer"), V(!1);
666
+ U.info("handleResetIdleTimer called - resetting idle timer"), V(!1);
667
667
  }, []), O = c(() => {
668
- if (U && (d(!0), f(!1), u)) {
668
+ if (G && (d(!0), f(!1), u)) {
669
669
  const E = `/kos/dispense/${u.path}/ambient/start/`;
670
670
  g.publish(E, {});
671
671
  }
672
- }, [U, u]), ue = c(() => {
672
+ }, [G, u]), ue = c(() => {
673
673
  if (B && (f(!0), d(!1), u)) {
674
674
  const E = `/kos/dispense/${u.path}/attract/start/`;
675
675
  g.publish(E, {});
@@ -684,7 +684,7 @@ const bt = T.createLogger({
684
684
  restart: y,
685
685
  attractTimer: H
686
686
  } = wt({
687
- defaultAmbientTime: U,
687
+ defaultAmbientTime: G,
688
688
  defaultAttractTime: B,
689
689
  onAmbientTimer: O,
690
690
  onAttractTimer: ue,
@@ -692,7 +692,7 @@ const bt = T.createLogger({
692
692
  });
693
693
  (Z = e == null ? void 0 : e.timers) == null || Z.add(H);
694
694
  const [me, V] = x(!1);
695
- G.info(
695
+ U.info(
696
696
  "Creating idle timer with timeout:",
697
697
  w,
698
698
  "seconds and callback:",
@@ -704,7 +704,7 @@ const bt = T.createLogger({
704
704
  onIdleTimer: C,
705
705
  onResetIdleTimer: Q
706
706
  });
707
- G.info(
707
+ U.info(
708
708
  `Creating pour timer with timeout: ${h} seconds and callback: ${!!C}`
709
709
  );
710
710
  const {
@@ -722,7 +722,7 @@ const bt = T.createLogger({
722
722
  try {
723
723
  E = await r();
724
724
  } catch (ve) {
725
- G.error(`onBeforeAreYouThereTimer callback failed: ${ve}`), E = !1;
725
+ U.error(`onBeforeAreYouThereTimer callback failed: ${ve}`), E = !1;
726
726
  }
727
727
  if (E) {
728
728
  if (u) {
@@ -758,9 +758,9 @@ const bt = T.createLogger({
758
758
  const he = c(() => {
759
759
  $(!1), k(), P(), R();
760
760
  }, [P, k]), pe = c(() => {
761
- $(!0), G.info("restarting pour timer"), D(), R(), P();
761
+ $(!0), U.info("restarting pour timer"), D(), R(), P();
762
762
  }, [P, D]), fe = c(() => {
763
- $(!1), G.info("restarting pour timer on before pour rejected"), k(), K();
763
+ $(!1), U.info("restarting pour timer on before pour rejected"), k(), K();
764
764
  }, []), be = c(() => {
765
765
  R(), f(!1), d(!1), K();
766
766
  }, [R, K]), Pe = c(() => {
@@ -811,7 +811,7 @@ const bt = T.createLogger({
811
811
  options: {}
812
812
  });
813
813
  };
814
- function Gt(e) {
814
+ function Ut(e) {
815
815
  return (t) => {
816
816
  const { model: s, status: n, KosModelLoader: r } = Ve();
817
817
  return /* @__PURE__ */ m(r, { ...n, children: /* @__PURE__ */ m(e, { ...t, deviceAssembly: s }) });
@@ -822,7 +822,7 @@ const je = (e) => S({
822
822
  modelType: mt.type,
823
823
  options: {}
824
824
  });
825
- function Ut(e, t) {
825
+ function Gt(e, t) {
826
826
  return (s) => {
827
827
  const { model: n, status: r, KosModelLoader: a } = je(e);
828
828
  return /* @__PURE__ */ m(a, { ...r, children: /* @__PURE__ */ m(t, { ...s, holder: n }) });
@@ -930,10 +930,10 @@ const te = T.createLogger({
930
930
  onPourAbort: n,
931
931
  pourTarget: r,
932
932
  pourContext: a,
933
- strategy: i = Ue
933
+ strategy: i = Ge
934
934
  }) => {
935
935
  const [d, v] = x(
936
- a || new Ge()
936
+ a || new Ue()
937
937
  ), f = c(async () => {
938
938
  te.debug(
939
939
  `[${i == null ? void 0 : i.name}] - calling before pour for pour target ${r == null ? void 0 : r.id}.`
@@ -1040,6 +1040,7 @@ const ce = T.createLogger({
1040
1040
  }, xt = (e, t, s) => S({
1041
1041
  modelId: e,
1042
1042
  modelType: ct.type,
1043
+ forceUpdate: !0,
1043
1044
  options: {
1044
1045
  servicePathFactory: t,
1045
1046
  selectedId: s
@@ -1252,9 +1253,9 @@ export {
1252
1253
  $s as P,
1253
1254
  $t as Q,
1254
1255
  Ve as R,
1255
- Gt as S,
1256
+ Ut as S,
1256
1257
  je as T,
1257
- Ut as U,
1258
+ Gt as U,
1258
1259
  We as V,
1259
1260
  Vt as W,
1260
1261
  qe as X,
@@ -1267,13 +1268,13 @@ export {
1267
1268
  vt as a2,
1268
1269
  Qt as a3,
1269
1270
  It as a4,
1270
- Ue as a5,
1271
+ Ge as a5,
1271
1272
  Xt as a6,
1272
1273
  Zt as a7,
1273
1274
  zt as a8,
1274
1275
  xt as a9,
1275
1276
  es as aa,
1276
- Ge as ab,
1277
+ Ue as ab,
1277
1278
  ns as b,
1278
1279
  as as c,
1279
1280
  os as d,
@@ -1300,4 +1301,4 @@ export {
1300
1301
  Yt as y,
1301
1302
  pt as z
1302
1303
  };
1303
- //# sourceMappingURL=pump-provider-DodZo0It.js.map
1304
+ //# sourceMappingURL=pump-provider-DSyiDoPF.js.map