@machinemetrics/mm-react-tools 4.0.4-0 → 4.0.4

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.
@@ -169,14 +169,14 @@ function yI() {
169
169
  }
170
170
  return null;
171
171
  }
172
- var Ie = Object.assign, ye = 0, ge, de, te, xe, Fe, Se, Ke;
172
+ var Ie = Object.assign, ye = 0, ge, de, te, Se, Fe, xe, Ke;
173
173
  function yt() {
174
174
  }
175
175
  yt.__reactDisabledLog = !0;
176
176
  function Rt() {
177
177
  {
178
178
  if (ye === 0) {
179
- ge = console.log, de = console.info, te = console.warn, xe = console.error, Fe = console.group, Se = console.groupCollapsed, Ke = console.groupEnd;
179
+ ge = console.log, de = console.info, te = console.warn, Se = console.error, Fe = console.group, xe = console.groupCollapsed, Ke = console.groupEnd;
180
180
  var N = {
181
181
  configurable: !0,
182
182
  enumerable: !0,
@@ -215,13 +215,13 @@ function yI() {
215
215
  value: te
216
216
  }),
217
217
  error: Ie({}, N, {
218
- value: xe
218
+ value: Se
219
219
  }),
220
220
  group: Ie({}, N, {
221
221
  value: Fe
222
222
  }),
223
223
  groupCollapsed: Ie({}, N, {
224
- value: Se
224
+ value: xe
225
225
  }),
226
226
  groupEnd: Ie({}, N, {
227
227
  value: Ke
@@ -6285,10 +6285,10 @@ var Wg = Vn(function() {
6285
6285
  fe.variables && !d && (fe.variables = jP(fe.variables, m.query));
6286
6286
  var oe;
6287
6287
  !X.signal && typeof AbortController < "u" && (oe = new AbortController(), X.signal = oe.signal);
6288
- var ke = function(xe) {
6289
- return xe.kind === "OperationDefinition" && xe.operation === "mutation";
6290
- }, me = function(xe) {
6291
- return xe.kind === "OperationDefinition" && xe.operation === "subscription";
6288
+ var ke = function(Se) {
6289
+ return Se.kind === "OperationDefinition" && Se.operation === "mutation";
6290
+ }, me = function(Se) {
6291
+ return Se.kind === "OperationDefinition" && Se.operation === "subscription";
6292
6292
  }, Pe = me(cs(m.query)), Ie = us(["defer"], m.query);
6293
6293
  if (f && !m.query.definitions.some(ke) && (X.method = "GET"), Ie || Pe) {
6294
6294
  X.headers = X.headers || {};
@@ -6303,22 +6303,22 @@ var Wg = Vn(function() {
6303
6303
  } else
6304
6304
  try {
6305
6305
  X.body = xc(fe, "Payload");
6306
- } catch (xe) {
6307
- return nc(xe);
6306
+ } catch (Se) {
6307
+ return nc(Se);
6308
6308
  }
6309
- return new Ct(function(xe) {
6309
+ return new Ct(function(Se) {
6310
6310
  var Fe = n || Vn(function() {
6311
6311
  return fetch;
6312
- }) || Wg, Se = xe.next.bind(xe);
6312
+ }) || Wg, xe = Se.next.bind(Se);
6313
6313
  return Fe(b, X).then(function(Ke) {
6314
6314
  var yt;
6315
6315
  m.setContext({ response: Ke });
6316
6316
  var Rt = (yt = Ke.headers) === null || yt === void 0 ? void 0 : yt.get("content-type");
6317
- return Rt !== null && /^multipart\/mixed/i.test(Rt) ? rR(Ke, Se) : Ew(m)(Ke).then(Se);
6317
+ return Rt !== null && /^multipart\/mixed/i.test(Rt) ? rR(Ke, xe) : Ew(m)(Ke).then(xe);
6318
6318
  }).then(function() {
6319
- oe = void 0, xe.complete();
6319
+ oe = void 0, Se.complete();
6320
6320
  }).catch(function(Ke) {
6321
- oe = void 0, iR(Ke, xe);
6321
+ oe = void 0, iR(Ke, Se);
6322
6322
  }), function() {
6323
6323
  oe && oe.abort();
6324
6324
  };
@@ -15573,7 +15573,7 @@ var Pc = { exports: {} };
15573
15573
  Pc.exports;
15574
15574
  (function(r, e) {
15575
15575
  (function() {
15576
- var t, n = "4.17.21", i = 200, a = "Unsupported core-js use. Try https://npms.io/search?q=ponyfill.", u = "Expected a function", c = "Invalid `variable` option passed into `_.template`", f = "__lodash_hash_undefined__", h = 500, d = "__lodash_placeholder__", y = 1, g = 2, m = 4, b = 1, I = 2, x = 1, _ = 2, A = 4, P = 8, M = 16, U = 32, W = 64, K = 128, X = 256, fe = 512, oe = 30, ke = "...", me = 800, Pe = 16, Ie = 1, ye = 2, ge = 3, de = 1 / 0, te = 9007199254740991, xe = 17976931348623157e292, Fe = NaN, Se = 4294967295, Ke = Se - 1, yt = Se >>> 1, Rt = [
15576
+ var t, n = "4.17.21", i = 200, a = "Unsupported core-js use. Try https://npms.io/search?q=ponyfill.", u = "Expected a function", c = "Invalid `variable` option passed into `_.template`", f = "__lodash_hash_undefined__", h = 500, d = "__lodash_placeholder__", y = 1, g = 2, m = 4, b = 1, I = 2, x = 1, _ = 2, A = 4, P = 8, M = 16, U = 32, W = 64, K = 128, X = 256, fe = 512, oe = 30, ke = "...", me = 800, Pe = 16, Ie = 1, ye = 2, ge = 3, de = 1 / 0, te = 9007199254740991, Se = 17976931348623157e292, Fe = NaN, xe = 4294967295, Ke = xe - 1, yt = xe >>> 1, Rt = [
15577
15577
  ["ary", K],
15578
15578
  ["bind", x],
15579
15579
  ["bindKey", _],
@@ -16202,7 +16202,7 @@ Pc.exports;
16202
16202
  }
16203
16203
  }, S.prototype = yu.prototype, S.prototype.constructor = S, Dn.prototype = Ks(yu.prototype), Dn.prototype.constructor = Dn;
16204
16204
  function wt(s) {
16205
- this.__wrapped__ = s, this.__actions__ = [], this.__dir__ = 1, this.__filtered__ = !1, this.__iteratees__ = [], this.__takeCount__ = Se, this.__views__ = [];
16205
+ this.__wrapped__ = s, this.__actions__ = [], this.__dir__ = 1, this.__filtered__ = !1, this.__iteratees__ = [], this.__takeCount__ = xe, this.__views__ = [];
16206
16206
  }
16207
16207
  function pE() {
16208
16208
  var s = new wt(this.__wrapped__);
@@ -18583,7 +18583,7 @@ Pc.exports;
18583
18583
  return s === 0 ? s : 0;
18584
18584
  if (s = jn(s), s === de || s === -de) {
18585
18585
  var o = s < 0 ? -1 : 1;
18586
- return o * xe;
18586
+ return o * Se;
18587
18587
  }
18588
18588
  return s === s ? s : 0;
18589
18589
  }
@@ -18592,7 +18592,7 @@ Pc.exports;
18592
18592
  return o === o ? l ? o - l : o : 0;
18593
18593
  }
18594
18594
  function sg(s) {
18595
- return s ? ws(ct(s), 0, Se) : 0;
18595
+ return s ? ws(ct(s), 0, xe) : 0;
18596
18596
  }
18597
18597
  function jn(s) {
18598
18598
  if (typeof s == "number")
@@ -18854,7 +18854,7 @@ Pc.exports;
18854
18854
  return s + (l ? "_" : "") + o.toLowerCase();
18855
18855
  });
18856
18856
  function ik(s, o, l) {
18857
- return l && typeof l != "number" && Kr(s, o, l) && (o = l = t), l = l === t ? Se : l >>> 0, l ? (s = Dt(s), s && (typeof o == "string" || o != null && !ff(o)) && (o = vn(o), !o && zs(s)) ? Wi(Jn(s), 0, l) : s.split(o, l)) : [];
18857
+ return l && typeof l != "number" && Kr(s, o, l) && (o = l = t), l = l === t ? xe : l >>> 0, l ? (s = Dt(s), s && (typeof o == "string" || o != null && !ff(o)) && (o = vn(o), !o && zs(s)) ? Wi(Jn(s), 0, l) : s.split(o, l)) : [];
18858
18858
  }
18859
18859
  var sk = Xs(function(s, o, l) {
18860
18860
  return s + (l ? " " : "") + pf(o);
@@ -19086,8 +19086,8 @@ function print() { __p += __j.call(arguments, '') }
19086
19086
  function Lk(s, o) {
19087
19087
  if (s = ct(s), s < 1 || s > te)
19088
19088
  return [];
19089
- var l = Se, p = Hr(s, Se);
19090
- o = Ge(o), s -= Se;
19089
+ var l = xe, p = Hr(s, xe);
19090
+ o = Ge(o), s -= xe;
19091
19091
  for (var v = Sl(p, o); ++l < s; )
19092
19092
  o(l);
19093
19093
  return v;
@@ -19145,7 +19145,7 @@ function print() { __p += __j.call(arguments, '') }
19145
19145
  l = l === t ? 1 : Pr(ct(l), 0);
19146
19146
  var p = this.__filtered__ && !o ? new wt(this) : this.clone();
19147
19147
  return p.__filtered__ ? p.__takeCount__ = Hr(l, p.__takeCount__) : p.__views__.push({
19148
- size: Hr(l, Se),
19148
+ size: Hr(l, xe),
19149
19149
  type: s + (p.__dir__ < 0 ? "Right" : "")
19150
19150
  }), p;
19151
19151
  }, wt.prototype[s + "Right"] = function(l) {
@@ -19189,7 +19189,7 @@ function print() { __p += __j.call(arguments, '') }
19189
19189
  }, wt.prototype.takeRightWhile = function(s) {
19190
19190
  return this.reverse().takeWhile(s).reverse();
19191
19191
  }, wt.prototype.toArray = function() {
19192
- return this.take(Se);
19192
+ return this.take(xe);
19193
19193
  }, oi(wt.prototype, function(s, o) {
19194
19194
  var l = /^(?:filter|find|map|reject)|While$/.test(o), p = /^(?:head|last)$/.test(o), v = S[p ? "take" + (o == "last" ? "Right" : "") : o], O = p || /^find/.test(o);
19195
19195
  v && (S.prototype[o] = function() {
@@ -19492,28 +19492,22 @@ const fi = /* @__PURE__ */ Ob(uD), ax = Ls.createContext(), ox = Ls.createContex
19492
19492
  }, [...t]);
19493
19493
  }, oq = (r, e = []) => {
19494
19494
  const { registerHandler: t } = Cn(ms);
19495
- Xt(() => {
19496
- t({
19497
- requestType: "custom-input-open",
19498
- func: r
19499
- });
19500
- }, [...e]);
19495
+ Xt(() => t({
19496
+ requestType: "custom-input-open",
19497
+ func: r
19498
+ }), [...e]);
19501
19499
  }, uq = (r, e = []) => {
19502
19500
  const { registerHandler: t } = Cn(ms);
19503
- Xt(() => {
19504
- t({
19505
- requestType: "custom-input-save",
19506
- func: r
19507
- });
19508
- }, [...e]);
19501
+ Xt(() => t({
19502
+ requestType: "custom-input-save",
19503
+ func: r
19504
+ }), [...e]);
19509
19505
  }, cq = (r, e = []) => {
19510
19506
  const { registerHandler: t } = Cn(ms), { setLoaded: n } = cx();
19511
- Xt(() => {
19512
- t({
19513
- requestType: "custom-input-label",
19514
- func: r
19515
- });
19516
- }, [...e]), Xt(() => {
19507
+ Xt(() => t({
19508
+ requestType: "custom-input-label",
19509
+ func: r
19510
+ }), [...e]), Xt(() => {
19517
19511
  n();
19518
19512
  }, []);
19519
19513
  }, lq = () => Cn(ax), fq = () => {
@@ -20109,14 +20103,14 @@ function qD(r) {
20109
20103
  const ye = /* @__PURE__ */ (() => {
20110
20104
  const de = {};
20111
20105
  return {
20112
- on(te, xe) {
20113
- return de[te] = xe, () => {
20106
+ on(te, Se) {
20107
+ return de[te] = Se, () => {
20114
20108
  delete de[te];
20115
20109
  };
20116
20110
  },
20117
20111
  emit(te) {
20118
- var xe;
20119
- "id" in te && ((xe = de[te.id]) === null || xe === void 0 || xe.call(de, te));
20112
+ var Se;
20113
+ "id" in te && ((Se = de[te.id]) === null || Se === void 0 || Se.call(de, te));
20120
20114
  }
20121
20115
  };
20122
20116
  })(), ge = {
@@ -20132,14 +20126,14 @@ function qD(r) {
20132
20126
  return {
20133
20127
  onMessage: ye.on,
20134
20128
  on(de, te) {
20135
- const xe = ge[de];
20136
- return xe.push(te), () => {
20137
- xe.splice(xe.indexOf(te), 1);
20129
+ const Se = ge[de];
20130
+ return Se.push(te), () => {
20131
+ Se.splice(Se.indexOf(te), 1);
20138
20132
  };
20139
20133
  },
20140
20134
  emit(de, ...te) {
20141
- for (const xe of [...ge[de]])
20142
- xe(...te);
20135
+ for (const Se of [...ge[de]])
20136
+ Se(...te);
20143
20137
  }
20144
20138
  };
20145
20139
  })();
@@ -20158,47 +20152,47 @@ function qD(r) {
20158
20152
  let W, K = 0, X, fe = !1, oe = 0, ke = !1;
20159
20153
  async function me() {
20160
20154
  clearTimeout(X);
20161
- const [ye, ge] = await (W ?? (W = new Promise((xe, Fe) => (async () => {
20155
+ const [ye, ge] = await (W ?? (W = new Promise((Se, Fe) => (async () => {
20162
20156
  if (fe) {
20163
20157
  if (await d(oe), !K)
20164
20158
  return W = void 0, Fe({ code: 1e3, reason: "All Subscriptions Gone" });
20165
20159
  oe++;
20166
20160
  }
20167
20161
  M.emit("connecting", fe);
20168
- const Se = new P(typeof e == "function" ? await e() : e, DD);
20162
+ const xe = new P(typeof e == "function" ? await e() : e, DD);
20169
20163
  let Ke, yt;
20170
20164
  function Rt() {
20171
20165
  isFinite(u) && u > 0 && (clearTimeout(yt), yt = setTimeout(() => {
20172
- Se.readyState === P.OPEN && (Se.send(lo({ type: vr.Ping })), M.emit("ping", !1, void 0));
20166
+ xe.readyState === P.OPEN && (xe.send(lo({ type: vr.Ping })), M.emit("ping", !1, void 0));
20173
20167
  }, u));
20174
20168
  }
20175
20169
  U((Ze) => {
20176
- W = void 0, clearTimeout(Ke), clearTimeout(yt), Fe(Ze), Ze instanceof i0 && (Se.close(4499, "Terminated"), Se.onerror = null, Se.onclose = null);
20177
- }), Se.onerror = (Ze) => M.emit("error", Ze), Se.onclose = (Ze) => M.emit("closed", Ze), Se.onopen = async () => {
20170
+ W = void 0, clearTimeout(Ke), clearTimeout(yt), Fe(Ze), Ze instanceof i0 && (xe.close(4499, "Terminated"), xe.onerror = null, xe.onclose = null);
20171
+ }), xe.onerror = (Ze) => M.emit("error", Ze), xe.onclose = (Ze) => M.emit("closed", Ze), xe.onopen = async () => {
20178
20172
  try {
20179
- M.emit("opened", Se);
20173
+ M.emit("opened", xe);
20180
20174
  const Ze = typeof t == "function" ? await t() : t;
20181
- if (Se.readyState !== P.OPEN)
20175
+ if (xe.readyState !== P.OPEN)
20182
20176
  return;
20183
- Se.send(lo(Ze ? {
20177
+ xe.send(lo(Ze ? {
20184
20178
  type: vr.ConnectionInit,
20185
20179
  payload: Ze
20186
20180
  } : {
20187
20181
  type: vr.ConnectionInit
20188
20182
  // payload is completely absent if not provided
20189
20183
  }, x)), isFinite(f) && f > 0 && (Ke = setTimeout(() => {
20190
- Se.close(xn.ConnectionAcknowledgementTimeout, "Connection acknowledgement timeout");
20184
+ xe.close(xn.ConnectionAcknowledgementTimeout, "Connection acknowledgement timeout");
20191
20185
  }, f)), Rt();
20192
20186
  } catch (Ze) {
20193
- M.emit("error", Ze), Se.close(xn.InternalClientError, n0(Ze instanceof Error ? Ze.message : new Error(Ze).message, "Internal client error"));
20187
+ M.emit("error", Ze), xe.close(xn.InternalClientError, n0(Ze instanceof Error ? Ze.message : new Error(Ze).message, "Internal client error"));
20194
20188
  }
20195
20189
  };
20196
20190
  let xt = !1;
20197
- Se.onmessage = ({ data: Ze }) => {
20191
+ xe.onmessage = ({ data: Ze }) => {
20198
20192
  try {
20199
20193
  const tt = FD(Ze, _);
20200
20194
  if (M.emit("message", tt), tt.type === "ping" || tt.type === "pong") {
20201
- M.emit(tt.type, !0, tt.payload), tt.type === "pong" ? Rt() : c || (Se.send(lo(tt.payload ? {
20195
+ M.emit(tt.type, !0, tt.payload), tt.type === "pong" ? Rt() : c || (xe.send(lo(tt.payload ? {
20202
20196
  type: vr.Pong,
20203
20197
  payload: tt.payload
20204
20198
  } : {
@@ -20211,19 +20205,19 @@ function qD(r) {
20211
20205
  return;
20212
20206
  if (tt.type !== vr.ConnectionAck)
20213
20207
  throw new Error(`First message cannot be of type ${tt.type}`);
20214
- clearTimeout(Ke), xt = !0, M.emit("connected", Se, tt.payload, fe), fe = !1, oe = 0, xe([
20215
- Se,
20208
+ clearTimeout(Ke), xt = !0, M.emit("connected", xe, tt.payload, fe), fe = !1, oe = 0, Se([
20209
+ xe,
20216
20210
  new Promise((St, Me) => U(Me))
20217
20211
  ]);
20218
20212
  } catch (tt) {
20219
- Se.onmessage = null, M.emit("error", tt), Se.close(xn.BadResponse, n0(tt instanceof Error ? tt.message : new Error(tt).message, "Bad response"));
20213
+ xe.onmessage = null, M.emit("error", tt), xe.close(xn.BadResponse, n0(tt instanceof Error ? tt.message : new Error(tt).message, "Bad response"));
20220
20214
  }
20221
20215
  };
20222
20216
  })())));
20223
20217
  ye.readyState === P.CLOSING && await ge;
20224
20218
  let de = () => {
20225
20219
  };
20226
- const te = new Promise((xe) => de = xe);
20220
+ const te = new Promise((Se) => de = Se);
20227
20221
  return [
20228
20222
  ye,
20229
20223
  de,
@@ -20231,10 +20225,10 @@ function qD(r) {
20231
20225
  // wait for
20232
20226
  te.then(() => {
20233
20227
  if (!K) {
20234
- const xe = () => ye.close(1e3, "Normal Closure");
20228
+ const Se = () => ye.close(1e3, "Normal Closure");
20235
20229
  isFinite(a) && a > 0 ? X = setTimeout(() => {
20236
- ye.readyState === P.OPEN && xe();
20237
- }, a) : xe();
20230
+ ye.readyState === P.OPEN && Se();
20231
+ }, a) : Se();
20238
20232
  }
20239
20233
  }),
20240
20234
  // or
@@ -20282,13 +20276,13 @@ function qD(r) {
20282
20276
  })();
20283
20277
  function Ie(ye, ge) {
20284
20278
  const de = I(ye);
20285
- let te = !1, xe = !1, Fe = () => {
20279
+ let te = !1, Se = !1, Fe = () => {
20286
20280
  K--, te = !0;
20287
20281
  };
20288
20282
  return (async () => {
20289
20283
  for (K++; ; )
20290
20284
  try {
20291
- const [Se, Ke, yt] = await me();
20285
+ const [xe, Ke, yt] = await me();
20292
20286
  if (te)
20293
20287
  return Ke();
20294
20288
  const Rt = M.onMessage(de, (xt) => {
@@ -20298,7 +20292,7 @@ function qD(r) {
20298
20292
  return;
20299
20293
  }
20300
20294
  case vr.Error: {
20301
- xe = !0, te = !0, ge.error(xt.payload), Fe();
20295
+ Se = !0, te = !0, ge.error(xt.payload), Fe();
20302
20296
  return;
20303
20297
  }
20304
20298
  case vr.Complete: {
@@ -20307,25 +20301,25 @@ function qD(r) {
20307
20301
  }
20308
20302
  }
20309
20303
  });
20310
- Se.send(lo({
20304
+ xe.send(lo({
20311
20305
  id: de,
20312
20306
  type: vr.Subscribe,
20313
20307
  payload: ye
20314
20308
  }, x)), Fe = () => {
20315
- !te && Se.readyState === P.OPEN && Se.send(lo({
20309
+ !te && xe.readyState === P.OPEN && xe.send(lo({
20316
20310
  id: de,
20317
20311
  type: vr.Complete
20318
20312
  }, x)), K--, te = !0, Ke();
20319
20313
  }, await yt.finally(Rt);
20320
20314
  return;
20321
- } catch (Se) {
20322
- if (!Pe(Se))
20315
+ } catch (xe) {
20316
+ if (!Pe(xe))
20323
20317
  return;
20324
20318
  }
20325
20319
  })().then(() => {
20326
- xe || ge.complete();
20327
- }).catch((Se) => {
20328
- ge.error(Se);
20320
+ Se || ge.complete();
20321
+ }).catch((xe) => {
20322
+ ge.error(xe);
20329
20323
  }), () => {
20330
20324
  te || Fe();
20331
20325
  };
@@ -20349,7 +20343,7 @@ function qD(r) {
20349
20343
  complete() {
20350
20344
  de.done = !0, de.resolve();
20351
20345
  }
20352
- }), xe = function() {
20346
+ }), Se = function() {
20353
20347
  return LD(this, arguments, function* () {
20354
20348
  for (; ; ) {
20355
20349
  for (ge.length || (yield ba(new Promise((Ke) => de.resolve = Ke))); ge.length; )
@@ -20361,7 +20355,7 @@ function qD(r) {
20361
20355
  }
20362
20356
  });
20363
20357
  }();
20364
- return xe.throw = async (Fe) => (de.done || (de.done = !0, de.error = Fe, de.resolve()), { done: !0, value: void 0 }), xe.return = async () => (te(), { done: !0, value: void 0 }), xe;
20358
+ return Se.throw = async (Fe) => (de.done || (de.done = !0, de.error = Fe, de.resolve()), { done: !0, value: void 0 }), Se.return = async () => (te(), { done: !0, value: void 0 }), Se;
20365
20359
  },
20366
20360
  async dispose() {
20367
20361
  if (ke = !0, W) {
@@ -20508,7 +20502,7 @@ function nl() {
20508
20502
  }
20509
20503
  return P.call(G, it, "$&_");
20510
20504
  }
20511
- var xe = zD, Fe = xe.custom, Se = q(Fe) ? Fe : null, Ke = {
20505
+ var Se = zD, Fe = Se.custom, xe = q(Fe) ? Fe : null, Ke = {
20512
20506
  __proto__: null,
20513
20507
  double: '"',
20514
20508
  single: "'"
@@ -20590,8 +20584,8 @@ function nl() {
20590
20584
  return !("cause" in Error.prototype) && "cause" in G && !ge.call(G, "cause") ? "{ [" + String(G) + "] " + X.call(K.call("[cause]: " + jt(G.cause), Ir), ", ") + " }" : Ir.length === 0 ? "[" + String(G) + "]" : "{ [" + String(G) + "] " + X.call(Ir, ", ") + " }";
20591
20585
  }
20592
20586
  if (typeof G == "object" && Yt) {
20593
- if (Se && typeof G[Se] == "function" && xe)
20594
- return xe(G, { depth: Wr - gt });
20587
+ if (xe && typeof G[xe] == "function" && Se)
20588
+ return Se(G, { depth: Wr - gt });
20595
20589
  if (Yt !== "symbol" && typeof G.inspect == "function")
20596
20590
  return G.inspect();
20597
20591
  }
@@ -21370,7 +21364,7 @@ function Up() {
21370
21364
  "%URIErrorPrototype%": ["URIError", "prototype"],
21371
21365
  "%WeakMapPrototype%": ["WeakMap", "prototype"],
21372
21366
  "%WeakSetPrototype%": ["WeakSet", "prototype"]
21373
- }, te = il(), xe = yF(), Fe = te.call(ke, Array.prototype.concat), Se = te.call(oe, Array.prototype.splice), Ke = te.call(ke, String.prototype.replace), yt = te.call(ke, String.prototype.slice), Rt = te.call(ke, RegExp.prototype.exec), xt = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g, Ze = /\\(\\)?/g, tt = function(ze) {
21367
+ }, te = il(), Se = yF(), Fe = te.call(ke, Array.prototype.concat), xe = te.call(oe, Array.prototype.splice), Ke = te.call(ke, String.prototype.replace), yt = te.call(ke, String.prototype.slice), Rt = te.call(ke, RegExp.prototype.exec), xt = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g, Ze = /\\(\\)?/g, tt = function(ze) {
21374
21368
  var B = yt(ze, 0, 1), Q = yt(ze, -1);
21375
21369
  if (B === "%" && Q !== "%")
21376
21370
  throw new u("invalid intrinsic syntax, expected closing `%`");
@@ -21382,7 +21376,7 @@ function Up() {
21382
21376
  }), q;
21383
21377
  }, St = function(ze, B) {
21384
21378
  var Q = ze, q;
21385
- if (xe(de, Q) && (q = de[Q], Q = "%" + q[0] + "%"), xe(Ie, Q)) {
21379
+ if (Se(de, Q) && (q = de[Q], Q = "%" + q[0] + "%"), Se(Ie, Q)) {
21386
21380
  var J = Ie[Q];
21387
21381
  if (J === me && (J = ge(Q)), typeof J > "u" && !B)
21388
21382
  throw new c("intrinsic " + ze + " exists, but is not available. Please file an issue!");
@@ -21402,12 +21396,12 @@ function Up() {
21402
21396
  if (Rt(/^%?[^%]*%?$/, ze) === null)
21403
21397
  throw new u("`%` may not be present anywhere but at the beginning and end of the intrinsic name");
21404
21398
  var Q = tt(ze), q = Q.length > 0 ? Q[0] : "", J = St("%" + q + "%", B), ee = J.name, V = J.value, _e = !1, Ve = J.alias;
21405
- Ve && (q = Ve[0], Se(Q, Fe([0, 1], Ve)));
21399
+ Ve && (q = Ve[0], xe(Q, Fe([0, 1], Ve)));
21406
21400
  for (var $e = 1, se = !0; $e < Q.length; $e += 1) {
21407
21401
  var be = Q[$e], He = yt(be, 0, 1), ht = yt(be, -1);
21408
21402
  if ((He === '"' || He === "'" || He === "`" || ht === '"' || ht === "'" || ht === "`") && He !== ht)
21409
21403
  throw new u("property names with quotes must have matching quotes");
21410
- if ((be === "constructor" || !se) && (_e = !0), q += "." + be, ee = "%" + q + "%", xe(Ie, ee))
21404
+ if ((be === "constructor" || !se) && (_e = !0), q += "." + be, ee = "%" + q + "%", Se(Ie, ee))
21411
21405
  V = Ie[ee];
21412
21406
  else if (V != null) {
21413
21407
  if (!(be in V)) {
@@ -21419,7 +21413,7 @@ function Up() {
21419
21413
  var dt = A(V, be);
21420
21414
  se = !!dt, se && "get" in dt && !("originalValue" in dt.get) ? V = dt.get : V = V[be];
21421
21415
  } else
21422
- se = xe(V, be), V = V[be];
21416
+ se = Se(V, be), V = V[be];
21423
21417
  se && !_e && (Ie[ee] = V);
21424
21418
  }
21425
21419
  }
@@ -21722,14 +21716,14 @@ function bF() {
21722
21716
  }, y = function(x) {
21723
21717
  return typeof x == "string" || typeof x == "number" || typeof x == "boolean" || typeof x == "symbol" || typeof x == "bigint";
21724
21718
  }, g = {}, m = function I(x, _, A, P, M, U, W, K, X, fe, oe, ke, me, Pe, Ie, ye, ge, de) {
21725
- for (var te = x, xe = de, Fe = 0, Se = !1; (xe = xe.get(g)) !== void 0 && !Se; ) {
21726
- var Ke = xe.get(x);
21719
+ for (var te = x, Se = de, Fe = 0, xe = !1; (Se = Se.get(g)) !== void 0 && !xe; ) {
21720
+ var Ke = Se.get(x);
21727
21721
  if (Fe += 1, typeof Ke < "u") {
21728
21722
  if (Ke === Fe)
21729
21723
  throw new RangeError("Cyclic object value");
21730
- Se = !0;
21724
+ xe = !0;
21731
21725
  }
21732
- typeof xe.get(g) > "u" && (Fe = 0);
21726
+ typeof Se.get(g) > "u" && (Fe = 0);
21733
21727
  }
21734
21728
  if (typeof fe == "function" ? te = fe(_, te) : te instanceof Date ? te = me(te) : A === "comma" && a(te) && (te = e.maybeMap(te, function(ee) {
21735
21729
  return ee instanceof Date ? me(ee) : ee;
@@ -22449,23 +22443,23 @@ function _F() {
22449
22443
  q.append(V, ee);
22450
22444
  })), q;
22451
22445
  }, new Headers());
22452
- }, xe = function(B, Q, q) {
22446
+ }, Se = function(B, Q, q) {
22453
22447
  var J = new Headers();
22454
22448
  return B.forEach(function(ee, V) {
22455
22449
  Q.indexOf(V) === -1 && J.append(V, ee);
22456
22450
  }), te(J, q || new Headers());
22457
22451
  }, Fe = function(B) {
22458
22452
  return function(Q, q) {
22459
- return xe(Q, B, q);
22453
+ return Se(Q, B, q);
22460
22454
  };
22461
- }, Se = ["GET", "POST", "PUT", "PATCH", "DELETE"], Ke = function(B, Q) {
22455
+ }, xe = ["GET", "POST", "PUT", "PATCH", "DELETE"], Ke = function(B, Q) {
22462
22456
  switch (Q) {
22463
22457
  case "query":
22464
- if (Se.indexOf(B.toUpperCase()) !== -1)
22458
+ if (xe.indexOf(B.toUpperCase()) !== -1)
22465
22459
  return;
22466
22460
  throw new Error('A "query" operation can only support "GET" requests but got "' + B + '".');
22467
22461
  case "mutation":
22468
- if (Se.indexOf(B.toUpperCase()) !== -1)
22462
+ if (xe.indexOf(B.toUpperCase()) !== -1)
22469
22463
  return;
22470
22464
  throw new Error('"mutation" operations do not support that HTTP-verb');
22471
22465
  case "subscription":
@@ -22680,11 +22674,11 @@ const sl = Ls.createContext(), SF = () => {
22680
22674
  window.close();
22681
22675
  return;
22682
22676
  } else {
22683
- const te = new URLSearchParams(c.search), xe = te.get("id"), Fe = te.get("origin");
22677
+ const te = new URLSearchParams(c.search), Se = te.get("id"), Fe = te.get("origin");
22684
22678
  a ? window.parent.postMessage(
22685
22679
  {
22686
22680
  type: "authorize-failed",
22687
- instanceId: xe,
22681
+ instanceId: Se,
22688
22682
  error: a,
22689
22683
  authUrl: window.location.href
22690
22684
  },
@@ -22692,7 +22686,7 @@ const sl = Ls.createContext(), SF = () => {
22692
22686
  ) : window.parent.postMessage(
22693
22687
  {
22694
22688
  type: "authorized",
22695
- instanceId: xe,
22689
+ instanceId: Se,
22696
22690
  authUrl: window.location.href
22697
22691
  },
22698
22692
  Fe
@@ -22702,14 +22696,14 @@ const sl = Ls.createContext(), SF = () => {
22702
22696
  r === !1 && e();
22703
22697
  }
22704
22698
  }, [c]), Xt(() => {
22705
- var xe, Fe;
22699
+ var Se, Fe;
22706
22700
  if (r === null || !c || c.pathname !== "/mm-embedded-interop")
22707
22701
  return;
22708
22702
  const ge = new URLSearchParams(c.search), de = ge.get("id"), te = ge.get("origin");
22709
22703
  if (te) {
22710
- const Se = (xe = new URL(te)) == null ? void 0 : xe.hostname;
22704
+ const xe = (Se = new URL(te)) == null ? void 0 : Se.hostname;
22711
22705
  if (/^(?:[\w-]+\.)*(?:machinemetrics\.com|machinemetrics-us-gov\.com|m12s\.com)$/.test(
22712
- Se
22706
+ xe
22713
22707
  ))
22714
22708
  y(te);
22715
22709
  else {
@@ -22719,7 +22713,7 @@ const sl = Ls.createContext(), SF = () => {
22719
22713
  }
22720
22714
  if (r === !1) {
22721
22715
  if (te) {
22722
- const Se = {
22716
+ const xe = {
22723
22717
  instanceId: de,
22724
22718
  authUrl: `${window.location.protocol}//${window.location.host}/mm-embedded-login?id=${de}&origin=${te}`,
22725
22719
  origin: te
@@ -22728,16 +22722,16 @@ const sl = Ls.createContext(), SF = () => {
22728
22722
  window.parent.postMessage(
22729
22723
  {
22730
22724
  type: "login",
22731
- ...Se
22725
+ ...xe
22732
22726
  },
22733
22727
  te
22734
22728
  );
22735
22729
  return;
22736
22730
  }
22737
22731
  e({
22738
- mm_instanceId: Se.instanceId,
22739
- mm_authUrl: encodeURIComponent(Se.authUrl),
22740
- mm_origin: Se.origin
22732
+ mm_instanceId: xe.instanceId,
22733
+ mm_authUrl: encodeURIComponent(xe.authUrl),
22734
+ mm_origin: xe.origin
22741
22735
  });
22742
22736
  return;
22743
22737
  }
@@ -22767,7 +22761,7 @@ const sl = Ls.createContext(), SF = () => {
22767
22761
  if (!n || !d)
22768
22762
  return;
22769
22763
  const ge = ({ origin: de, data: te }) => {
22770
- var xe, Fe, Se, Ke, yt, Rt, xt, Ze;
22764
+ var Se, Fe, xe, Ke, yt, Rt, xt, Ze;
22771
22765
  if (de === d)
22772
22766
  switch (te.type) {
22773
22767
  case "navigate":
@@ -22783,12 +22777,12 @@ const sl = Ls.createContext(), SF = () => {
22783
22777
  U(te.params);
22784
22778
  break;
22785
22779
  case "load-options":
22786
- (Fe = (xe = x.current)[`option-${te.name}`]) == null || Fe.call(xe, {
22780
+ (Fe = (Se = x.current)[`option-${te.name}`]) == null || Fe.call(Se, {
22787
22781
  filter: te.filter
22788
22782
  });
22789
22783
  break;
22790
22784
  case "validate":
22791
- (Ke = (Se = x.current)[`validate-${te.name}`]) == null || Ke.call(Se, {
22785
+ (Ke = (xe = x.current)[`validate-${te.name}`]) == null || Ke.call(xe, {
22792
22786
  value: te.value
22793
22787
  });
22794
22788
  break;
@@ -22849,11 +22843,11 @@ const sl = Ls.createContext(), SF = () => {
22849
22843
  );
22850
22844
  }, oe = () => {
22851
22845
  f && window.parent.postMessage({ type: "loaded", instanceId: g }, d);
22852
- }, ke = async ({ header: ge, body: de, choices: te }) => f ? new Promise((xe) => {
22853
- const Fe = bx(), Se = async (Ke) => {
22854
- delete x.current[Fe], xe(Ke);
22846
+ }, ke = async ({ header: ge, body: de, choices: te }) => f ? new Promise((Se) => {
22847
+ const Fe = bx(), xe = async (Ke) => {
22848
+ delete x.current[Fe], Se(Ke);
22855
22849
  };
22856
- x.current[Fe] = Se, window.parent.postMessage(
22850
+ x.current[Fe] = xe, window.parent.postMessage(
22857
22851
  {
22858
22852
  type: "confirm",
22859
22853
  instanceId: g,
@@ -22865,26 +22859,40 @@ const sl = Ls.createContext(), SF = () => {
22865
22859
  d
22866
22860
  );
22867
22861
  }) : Promise.reject(new Error("Not ready")), me = ({ requestType: ge, func: de }) => {
22868
- const te = async ({ callbackId: xe, data: Fe }) => {
22869
- const Se = await de(Fe);
22870
- window.parent.postMessage(
22871
- {
22872
- callbackId: xe,
22873
- type: "response",
22874
- instanceId: g,
22875
- response: Se
22876
- },
22877
- d
22878
- );
22862
+ const te = async ({ callbackId: Se, data: Fe }) => {
22863
+ try {
22864
+ const xe = await de(Fe);
22865
+ window.parent.postMessage(
22866
+ {
22867
+ callbackId: Se,
22868
+ type: "response",
22869
+ instanceId: g,
22870
+ response: xe
22871
+ },
22872
+ d
22873
+ );
22874
+ } catch (xe) {
22875
+ window.parent.postMessage(
22876
+ {
22877
+ callbackId: Se,
22878
+ type: "response",
22879
+ instanceId: g,
22880
+ error: xe.message
22881
+ },
22882
+ d
22883
+ );
22884
+ }
22885
+ };
22886
+ return _.current[ge] = te, () => {
22887
+ delete _.current[ge];
22879
22888
  };
22880
- _.current[ge] = te;
22881
22889
  }, Pe = ({
22882
22890
  callbackId: ge,
22883
22891
  func: de,
22884
22892
  responseType: te = "response",
22885
- responseKey: xe = "response",
22893
+ responseKey: Se = "response",
22886
22894
  props: Fe = {},
22887
- callOnRegister: Se = !1
22895
+ callOnRegister: xe = !1
22888
22896
  }) => {
22889
22897
  const Ke = async (Rt) => {
22890
22898
  const xt = await de(Rt);
@@ -22893,13 +22901,13 @@ const sl = Ls.createContext(), SF = () => {
22893
22901
  type: te,
22894
22902
  instanceId: g,
22895
22903
  ...Fe,
22896
- [xe]: xt,
22904
+ [Se]: xt,
22897
22905
  callbackId: ge
22898
22906
  },
22899
22907
  d
22900
22908
  );
22901
22909
  }, yt = x.current[ge];
22902
- x.current[ge] = Ke, yt && Se && Ke(Fe);
22910
+ x.current[ge] = Ke, yt && xe && Ke(Fe);
22903
22911
  }, Ie = (ge, de) => {
22904
22912
  if (f) {
22905
22913
  if (de.validate && typeof de.validate == "function" && Pe({
@@ -26191,7 +26199,7 @@ var Oe;
26191
26199
  for (Pe(w, 0, k, 0, T, C, D), ge(w, 16, w, 32, T - 32, w), $ = 0; $ < 16; $++) w[$] = 0;
26192
26200
  return 0;
26193
26201
  }
26194
- function xe(w, k, T, C, D) {
26202
+ function Se(w, k, T, C, D) {
26195
26203
  var $, ie = new Uint8Array(32);
26196
26204
  if (T < 32 || (me(ie, 0, 32, C, D), de(k, 16, k, 32, T - 32, ie) !== 0)) return -1;
26197
26205
  for (Pe(w, 0, k, 0, T, C, D), $ = 0; $ < 32; $++) w[$] = 0;
@@ -26201,7 +26209,7 @@ var Oe;
26201
26209
  var T;
26202
26210
  for (T = 0; T < 16; T++) w[T] = k[T] | 0;
26203
26211
  }
26204
- function Se(w) {
26212
+ function xe(w) {
26205
26213
  var k, T;
26206
26214
  for (T = 0; T < 16; T++)
26207
26215
  w[T] += 65536, k = Math.floor(w[T] / 65536), w[(T + 1) * (T < 15 ? 1 : 0)] += k - 1 + 37 * (k - 1) * (T === 15 ? 1 : 0), w[T] -= k * 65536;
@@ -26213,7 +26221,7 @@ var Oe;
26213
26221
  function yt(w, k) {
26214
26222
  var T, C, D, $ = t(), ie = t();
26215
26223
  for (T = 0; T < 16; T++) ie[T] = k[T];
26216
- for (Se(ie), Se(ie), Se(ie), C = 0; C < 2; C++) {
26224
+ for (xe(ie), xe(ie), xe(ie), C = 0; C < 2; C++) {
26217
26225
  for ($[0] = ie[0] - 65517, T = 1; T < 15; T++)
26218
26226
  $[T] = ie[T] - 65535 - ($[T - 1] >> 16 & 1), $[T - 1] &= 65535;
26219
26227
  $[15] = ie[15] - 32767 - ($[14] >> 16 & 1), D = $[15] >> 16 & 1, $[14] &= 65535, Ke(ie, $, 1 - D);
@@ -26251,7 +26259,7 @@ var Oe;
26251
26259
  for (C = 0; C < 15; C++)
26252
26260
  $[C] += 38 * $[C + 16];
26253
26261
  for (C = 0; C < 16; C++) w[C] = $[C];
26254
- Se(w), Se(w);
26262
+ xe(w), xe(w);
26255
26263
  }
26256
26264
  function ze(w, k) {
26257
26265
  Me(w, k, k);
@@ -26292,7 +26300,7 @@ var Oe;
26292
26300
  var C = new Uint8Array(32);
26293
26301
  return q(C, T, k), X(w, i, C, fe);
26294
26302
  }
26295
- var _e = te, Ve = xe;
26303
+ var _e = te, Ve = Se;
26296
26304
  function $e(w, k, T, C, D, $) {
26297
26305
  var ie = new Uint8Array(32);
26298
26306
  return V(ie, D, $), _e(w, k, T, C, ie);
@@ -26662,7 +26670,7 @@ var Oe;
26662
26670
  crypto_verify_16: M,
26663
26671
  crypto_verify_32: U,
26664
26672
  crypto_secretbox: te,
26665
- crypto_secretbox_open: xe,
26673
+ crypto_secretbox_open: Se,
26666
26674
  crypto_scalarmult: q,
26667
26675
  crypto_scalarmult_base: J,
26668
26676
  crypto_box_beforenm: V,
@@ -26732,7 +26740,7 @@ var Oe;
26732
26740
  }, r.secretbox.open = function(w, k, T) {
26733
26741
  et(w, k, T), Qe(T, k);
26734
26742
  for (var C = new Uint8Array(Nr + w.length), D = new Uint8Array(C.length), $ = 0; $ < w.length; $++) C[$ + Nr] = w[$];
26735
- return C.length < 32 || xe(D, C, C.length, k, T) !== 0 ? null : D.subarray(jr);
26743
+ return C.length < 32 || Se(D, C, C.length, k, T) !== 0 ? null : D.subarray(jr);
26736
26744
  }, r.secretbox.keyLength = jt, r.secretbox.nonceLength = _r, r.secretbox.overheadLength = Nr, r.scalarMult = function(w, k) {
26737
26745
  if (et(w, k), w.length !== zr) throw new Error("bad n size");
26738
26746
  if (k.length !== ir) throw new Error("bad p size");