@ssgc/alert-console 2.10.13 → 2.10.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.
package/dist/index.es.js CHANGED
@@ -306,35 +306,35 @@ function Sa() {
306
306
  (function(s, n) {
307
307
  t.exports = n();
308
308
  })(ga, (function() {
309
- var s = 1e3, n = 6e4, r = 36e5, i = "millisecond", a = "second", o = "minute", l = "hour", u = "day", m = "week", d = "month", y = "quarter", p = "year", v = "date", k = "Invalid Date", b = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, B = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, q = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(O) {
310
- var N = ["th", "st", "nd", "rd"], A = O % 100;
311
- return "[" + O + (N[(A - 20) % 10] || N[A] || N[0]) + "]";
312
- } }, Q = function(O, N, A) {
309
+ var s = 1e3, n = 6e4, r = 36e5, i = "millisecond", a = "second", o = "minute", l = "hour", u = "day", m = "week", d = "month", y = "quarter", p = "year", w = "date", k = "Invalid Date", b = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, B = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, q = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(O) {
310
+ var N = ["th", "st", "nd", "rd"], v = O % 100;
311
+ return "[" + O + (N[(v - 20) % 10] || N[v] || N[0]) + "]";
312
+ } }, Q = function(O, N, v) {
313
313
  var E = String(O);
314
- return !E || E.length >= N ? O : "" + Array(N + 1 - E.length).join(A) + O;
314
+ return !E || E.length >= N ? O : "" + Array(N + 1 - E.length).join(v) + O;
315
315
  }, x = { s: Q, z: function(O) {
316
- var N = -O.utcOffset(), A = Math.abs(N), E = Math.floor(A / 60), T = A % 60;
316
+ var N = -O.utcOffset(), v = Math.abs(N), E = Math.floor(v / 60), T = v % 60;
317
317
  return (N <= 0 ? "+" : "-") + Q(E, 2, "0") + ":" + Q(T, 2, "0");
318
- }, m: function O(N, A) {
319
- if (N.date() < A.date()) return -O(A, N);
320
- var E = 12 * (A.year() - N.year()) + (A.month() - N.month()), T = N.clone().add(E, d), D = A - T < 0, L = N.clone().add(E + (D ? -1 : 1), d);
321
- return +(-(E + (A - T) / (D ? T - L : L - T)) || 0);
318
+ }, m: function O(N, v) {
319
+ if (N.date() < v.date()) return -O(v, N);
320
+ var E = 12 * (v.year() - N.year()) + (v.month() - N.month()), T = N.clone().add(E, d), D = v - T < 0, L = N.clone().add(E + (D ? -1 : 1), d);
321
+ return +(-(E + (v - T) / (D ? T - L : L - T)) || 0);
322
322
  }, a: function(O) {
323
323
  return O < 0 ? Math.ceil(O) || 0 : Math.floor(O);
324
324
  }, p: function(O) {
325
- return { M: d, y: p, w: m, d: u, D: v, h: l, m: o, s: a, ms: i, Q: y }[O] || String(O || "").toLowerCase().replace(/s$/, "");
325
+ return { M: d, y: p, w: m, d: u, D: w, h: l, m: o, s: a, ms: i, Q: y }[O] || String(O || "").toLowerCase().replace(/s$/, "");
326
326
  }, u: function(O) {
327
327
  return O === void 0;
328
328
  } }, C = "en", Z = {};
329
329
  Z[C] = q;
330
330
  var R = "$isDayjsObject", G = function(O) {
331
331
  return O instanceof ie || !(!O || !O[R]);
332
- }, h = function O(N, A, E) {
332
+ }, h = function O(N, v, E) {
333
333
  var T;
334
334
  if (!N) return C;
335
335
  if (typeof N == "string") {
336
336
  var D = N.toLowerCase();
337
- Z[D] && (T = D), A && (Z[D] = A, T = D);
337
+ Z[D] && (T = D), v && (Z[D] = v, T = D);
338
338
  var L = N.split("-");
339
339
  if (!T && L.length > 1) return O(L[0]);
340
340
  } else {
@@ -344,18 +344,18 @@ function Sa() {
344
344
  return !E && T && (C = T), T || !E && C;
345
345
  }, g = function(O, N) {
346
346
  if (G(O)) return O.clone();
347
- var A = typeof N == "object" ? N : {};
348
- return A.date = O, A.args = arguments, new ie(A);
347
+ var v = typeof N == "object" ? N : {};
348
+ return v.date = O, v.args = arguments, new ie(v);
349
349
  }, M = x;
350
350
  M.l = h, M.i = G, M.w = function(O, N) {
351
351
  return g(O, { locale: N.$L, utc: N.$u, x: N.$x, $offset: N.$offset });
352
352
  };
353
353
  var ie = (function() {
354
- function O(A) {
355
- this.$L = h(A.locale, null, !0), this.parse(A), this.$x = this.$x || A.x || {}, this[R] = !0;
354
+ function O(v) {
355
+ this.$L = h(v.locale, null, !0), this.parse(v), this.$x = this.$x || v.x || {}, this[R] = !0;
356
356
  }
357
357
  var N = O.prototype;
358
- return N.parse = function(A) {
358
+ return N.parse = function(v) {
359
359
  this.$d = (function(E) {
360
360
  var T = E.date, D = E.utc;
361
361
  if (T === null) return /* @__PURE__ */ new Date(NaN);
@@ -369,29 +369,29 @@ function Sa() {
369
369
  }
370
370
  }
371
371
  return new Date(T);
372
- })(A), this.init();
372
+ })(v), this.init();
373
373
  }, N.init = function() {
374
- var A = this.$d;
375
- this.$y = A.getFullYear(), this.$M = A.getMonth(), this.$D = A.getDate(), this.$W = A.getDay(), this.$H = A.getHours(), this.$m = A.getMinutes(), this.$s = A.getSeconds(), this.$ms = A.getMilliseconds();
374
+ var v = this.$d;
375
+ this.$y = v.getFullYear(), this.$M = v.getMonth(), this.$D = v.getDate(), this.$W = v.getDay(), this.$H = v.getHours(), this.$m = v.getMinutes(), this.$s = v.getSeconds(), this.$ms = v.getMilliseconds();
376
376
  }, N.$utils = function() {
377
377
  return M;
378
378
  }, N.isValid = function() {
379
379
  return this.$d.toString() !== k;
380
- }, N.isSame = function(A, E) {
381
- var T = g(A);
380
+ }, N.isSame = function(v, E) {
381
+ var T = g(v);
382
382
  return this.startOf(E) <= T && T <= this.endOf(E);
383
- }, N.isAfter = function(A, E) {
384
- return g(A) < this.startOf(E);
385
- }, N.isBefore = function(A, E) {
386
- return this.endOf(E) < g(A);
387
- }, N.$g = function(A, E, T) {
388
- return M.u(A) ? this[E] : this.set(T, A);
383
+ }, N.isAfter = function(v, E) {
384
+ return g(v) < this.startOf(E);
385
+ }, N.isBefore = function(v, E) {
386
+ return this.endOf(E) < g(v);
387
+ }, N.$g = function(v, E, T) {
388
+ return M.u(v) ? this[E] : this.set(T, v);
389
389
  }, N.unix = function() {
390
390
  return Math.floor(this.valueOf() / 1e3);
391
391
  }, N.valueOf = function() {
392
392
  return this.$d.getTime();
393
- }, N.startOf = function(A, E) {
394
- var T = this, D = !!M.u(E) || E, L = M.p(A), _ = function(ke, pe) {
393
+ }, N.startOf = function(v, E) {
394
+ var T = this, D = !!M.u(E) || E, L = M.p(v), _ = function(ke, pe) {
395
395
  var P = M.w(T.$u ? Date.UTC(T.$y, pe, ke) : new Date(T.$y, pe, ke), T);
396
396
  return D ? P : P.endOf(u);
397
397
  }, Y = function(ke, pe) {
@@ -406,7 +406,7 @@ function Sa() {
406
406
  var te = this.$locale().weekStart || 0, Se = (j < te ? j + 7 : j) - te;
407
407
  return _(D ? me - Se : me + (6 - Se), ce);
408
408
  case u:
409
- case v:
409
+ case w:
410
410
  return Y(Oe + "Hours", 0);
411
411
  case l:
412
412
  return Y(Oe + "Minutes", 1);
@@ -417,38 +417,38 @@ function Sa() {
417
417
  default:
418
418
  return this.clone();
419
419
  }
420
- }, N.endOf = function(A) {
421
- return this.startOf(A, !1);
422
- }, N.$set = function(A, E) {
423
- var T, D = M.p(A), L = "set" + (this.$u ? "UTC" : ""), _ = (T = {}, T[u] = L + "Date", T[v] = L + "Date", T[d] = L + "Month", T[p] = L + "FullYear", T[l] = L + "Hours", T[o] = L + "Minutes", T[a] = L + "Seconds", T[i] = L + "Milliseconds", T)[D], Y = D === u ? this.$D + (E - this.$W) : E;
420
+ }, N.endOf = function(v) {
421
+ return this.startOf(v, !1);
422
+ }, N.$set = function(v, E) {
423
+ var T, D = M.p(v), L = "set" + (this.$u ? "UTC" : ""), _ = (T = {}, T[u] = L + "Date", T[w] = L + "Date", T[d] = L + "Month", T[p] = L + "FullYear", T[l] = L + "Hours", T[o] = L + "Minutes", T[a] = L + "Seconds", T[i] = L + "Milliseconds", T)[D], Y = D === u ? this.$D + (E - this.$W) : E;
424
424
  if (D === d || D === p) {
425
- var j = this.clone().set(v, 1);
426
- j.$d[_](Y), j.init(), this.$d = j.set(v, Math.min(this.$D, j.daysInMonth())).$d;
425
+ var j = this.clone().set(w, 1);
426
+ j.$d[_](Y), j.init(), this.$d = j.set(w, Math.min(this.$D, j.daysInMonth())).$d;
427
427
  } else _ && this.$d[_](Y);
428
428
  return this.init(), this;
429
- }, N.set = function(A, E) {
430
- return this.clone().$set(A, E);
431
- }, N.get = function(A) {
432
- return this[M.p(A)]();
433
- }, N.add = function(A, E) {
429
+ }, N.set = function(v, E) {
430
+ return this.clone().$set(v, E);
431
+ }, N.get = function(v) {
432
+ return this[M.p(v)]();
433
+ }, N.add = function(v, E) {
434
434
  var T, D = this;
435
- A = Number(A);
435
+ v = Number(v);
436
436
  var L = M.p(E), _ = function(ce) {
437
437
  var me = g(D);
438
- return M.w(me.date(me.date() + Math.round(ce * A)), D);
438
+ return M.w(me.date(me.date() + Math.round(ce * v)), D);
439
439
  };
440
- if (L === d) return this.set(d, this.$M + A);
441
- if (L === p) return this.set(p, this.$y + A);
440
+ if (L === d) return this.set(d, this.$M + v);
441
+ if (L === p) return this.set(p, this.$y + v);
442
442
  if (L === u) return _(1);
443
443
  if (L === m) return _(7);
444
- var Y = (T = {}, T[o] = n, T[l] = r, T[a] = s, T)[L] || 1, j = this.$d.getTime() + A * Y;
444
+ var Y = (T = {}, T[o] = n, T[l] = r, T[a] = s, T)[L] || 1, j = this.$d.getTime() + v * Y;
445
445
  return M.w(j, this);
446
- }, N.subtract = function(A, E) {
447
- return this.add(-1 * A, E);
448
- }, N.format = function(A) {
446
+ }, N.subtract = function(v, E) {
447
+ return this.add(-1 * v, E);
448
+ }, N.format = function(v) {
449
449
  var E = this, T = this.$locale();
450
450
  if (!this.isValid()) return T.invalidDate || k;
451
- var D = A || "YYYY-MM-DDTHH:mm:ssZ", L = M.z(this), _ = this.$H, Y = this.$m, j = this.$M, ce = T.weekdays, me = T.months, Oe = T.meridiem, te = function(pe, P, W, ge) {
451
+ var D = v || "YYYY-MM-DDTHH:mm:ssZ", L = M.z(this), _ = this.$H, Y = this.$m, j = this.$M, ce = T.weekdays, me = T.months, Oe = T.meridiem, te = function(pe, P, W, ge) {
452
452
  return pe && (pe[P] || pe(E, D)) || W[P].slice(0, ge);
453
453
  }, Se = function(pe) {
454
454
  return M.s(_ % 12 || 12, pe, "0");
@@ -513,8 +513,8 @@ function Sa() {
513
513
  }));
514
514
  }, N.utcOffset = function() {
515
515
  return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
516
- }, N.diff = function(A, E, T) {
517
- var D, L = this, _ = M.p(E), Y = g(A), j = (Y.utcOffset() - this.utcOffset()) * n, ce = this - Y, me = function() {
516
+ }, N.diff = function(v, E, T) {
517
+ var D, L = this, _ = M.p(E), Y = g(v), j = (Y.utcOffset() - this.utcOffset()) * n, ce = this - Y, me = function() {
518
518
  return M.m(L, Y);
519
519
  };
520
520
  switch (_) {
@@ -550,9 +550,9 @@ function Sa() {
550
550
  return this.endOf(d).$D;
551
551
  }, N.$locale = function() {
552
552
  return Z[this.$L];
553
- }, N.locale = function(A, E) {
554
- if (!A) return this.$L;
555
- var T = this.clone(), D = h(A, E, !0);
553
+ }, N.locale = function(v, E) {
554
+ if (!v) return this.$L;
555
+ var T = this.clone(), D = h(v, E, !0);
556
556
  return D && (T.$L = D), T;
557
557
  }, N.clone = function() {
558
558
  return M.w(this.$d, this);
@@ -566,7 +566,7 @@ function Sa() {
566
566
  return this.$d.toUTCString();
567
567
  }, O;
568
568
  })(), ye = ie.prototype;
569
- return g.prototype = ye, [["$ms", i], ["$s", a], ["$m", o], ["$H", l], ["$W", u], ["$M", d], ["$y", p], ["$D", v]].forEach((function(O) {
569
+ return g.prototype = ye, [["$ms", i], ["$s", a], ["$m", o], ["$H", l], ["$W", u], ["$M", d], ["$y", p], ["$D", w]].forEach((function(O) {
570
570
  ye[O[1]] = function(N) {
571
571
  return this.$g(N, O[0], O[1]);
572
572
  };
@@ -988,13 +988,13 @@ function ka(t) {
988
988
  if (h.status !== "fulfilled") return [];
989
989
  const g = h.value;
990
990
  return Array.isArray(g) ? g : Array.isArray(g?.Data) ? g.Data : Array.isArray(g?.data) ? g.data : [];
991
- }, p = y(a), v = y(o), k = y(l), b = y(u), B = y(m), q = d.status === "fulfilled" ? d.value : null;
991
+ }, p = y(a), w = y(o), k = y(l), b = y(u), B = y(m), q = d.status === "fulfilled" ? d.value : null;
992
992
  let Q = [];
993
993
  Array.isArray(q) ? Q = q : Array.isArray(q?.Data) ? Q = q.Data : Array.isArray(q?.data) && (Q = q.data);
994
994
  const x = p.map((h) => ({
995
995
  actionTypeId: Number(h?.ActionTypeId),
996
996
  name: h?.DisplayName ?? h?.Name ?? ""
997
- })), C = v.map((h) => ({
997
+ })), C = w.map((h) => ({
998
998
  AnomalyId: h?.AnomalyId,
999
999
  DisplayName: h?.DisplayName ?? h?.Name ?? ""
1000
1000
  })), Z = k.map((h) => ({
@@ -1111,13 +1111,13 @@ function Ea(t) {
1111
1111
  if (R.status !== "fulfilled") return [];
1112
1112
  const G = R.value;
1113
1113
  return Array.isArray(G) ? G : Array.isArray(G?.data) ? G.data : [];
1114
- }, y = d(a), p = d(o), v = d(l), k = d(u), b = m.status === "fulfilled" ? m.value : null, B = y.map((R) => ({
1114
+ }, y = d(a), p = d(o), w = d(l), k = d(u), b = m.status === "fulfilled" ? m.value : null, B = y.map((R) => ({
1115
1115
  actionTypeId: R?.ActionTypeUniqueId,
1116
1116
  name: R?.Name ?? ""
1117
1117
  })), q = p.map((R) => ({
1118
1118
  recordId: R?.AnomalyId,
1119
1119
  anomalyName: R?.DisplayName ?? R?.Name ?? ""
1120
- })), Q = v.map((R) => ({
1120
+ })), Q = w.map((R) => ({
1121
1121
  thirdPartyId: Number(R?.ThirdPartyId),
1122
1122
  thirdPartyName: R?.ThirdPartyName ?? R?.Name ?? ""
1123
1123
  }));
@@ -1137,7 +1137,7 @@ function Ea(t) {
1137
1137
  }))), C.length && (Z.userRoles = C), Z;
1138
1138
  },
1139
1139
  async updateRule(n, r) {
1140
- const i = new URL("/update-rule", t.baseUrl).toString(), { escalationSettings: a, ruleId: o, ruleName: l, ruleDesc: u, ...m } = r ?? {}, d = a ?? {}, y = (d.escalationSettingsActionTypeIds ?? []).filter((v) => v != null && !Number.isNaN(v)), p = {
1140
+ const i = new URL("/update-rule", t.baseUrl).toString(), { escalationSettings: a, ruleId: o, ruleName: l, ruleDesc: u, ...m } = r ?? {}, d = a ?? {}, y = (d.escalationSettingsActionTypeIds ?? []).filter((w) => w != null && !Number.isNaN(w)), p = {
1141
1141
  Level1UserRoleId: d.level1UserRoleId ?? 0,
1142
1142
  Level1PostAssistTime: d.level1PostAssistTime ?? 0,
1143
1143
  Level2UserRoleId: d.level2UserRoleId ?? 0,
@@ -1658,7 +1658,7 @@ const kr = ({
1658
1658
  ),
1659
1659
  [r, u]
1660
1660
  ), p = ve(
1661
- () => y.map((v) => ({ ...v, label: v.personName || "" })),
1661
+ () => y.map((w) => ({ ...w, label: w.personName || "" })),
1662
1662
  [y]
1663
1663
  );
1664
1664
  return oe(() => {
@@ -1675,15 +1675,15 @@ const kr = ({
1675
1675
  tabIndex: 0,
1676
1676
  "aria-label": "Close media preview",
1677
1677
  onClick: e,
1678
- onKeyDown: (v) => {
1679
- (v.key === "Enter" || v.key === " ") && (v.preventDefault(), e());
1678
+ onKeyDown: (w) => {
1679
+ (w.key === "Enter" || w.key === " ") && (w.preventDefault(), e());
1680
1680
  },
1681
1681
  onTouchStart: e,
1682
1682
  children: /* @__PURE__ */ c(
1683
1683
  "div",
1684
1684
  {
1685
1685
  className: "relative max-w-5xl max-h-[90vh] w-full flex items-center justify-center",
1686
- onClick: (v) => v.stopPropagation(),
1686
+ onClick: (w) => w.stopPropagation(),
1687
1687
  children: n === "image" ? /* @__PURE__ */ f("div", { style: { position: "relative", display: "inline-block" }, children: [
1688
1688
  /* @__PURE__ */ c(
1689
1689
  "img",
@@ -1888,7 +1888,7 @@ function Mr({
1888
1888
  onFilterChange: m,
1889
1889
  resetKey: d
1890
1890
  }) {
1891
- const [y, p] = S("All"), [v, k] = S("All"), [b, B] = S("All"), [q, Q] = S("All"), [x, C] = S(""), [Z, R] = S(r ?? 1);
1891
+ const [y, p] = S("All"), [w, k] = S("All"), [b, B] = S("All"), [q, Q] = S("All"), [x, C] = S(""), [Z, R] = S(r ?? 1);
1892
1892
  oe(() => {
1893
1893
  d !== void 0 && (p("All"), k("All"), B("All"), Q("All"), C(""), R(1));
1894
1894
  }, [d]), oe(() => {
@@ -1896,7 +1896,7 @@ function Mr({
1896
1896
  }, [r]);
1897
1897
  const [G, h] = S([
1898
1898
  { label: "All", value: "All" }
1899
- ]), [g, M] = S([]), [ie, ye] = S([]), [O, N] = S([]), [A, E] = S(/* @__PURE__ */ new Set()), { rules: T, alerts: D, config: L } = Ge(), _ = L.tenant === "schools", Y = L.tenant === "transit", j = so(x, 600), ce = _ && j.trim() ? 100 : s, me = {
1899
+ ]), [g, M] = S([]), [ie, ye] = S([]), [O, N] = S([]), [v, E] = S(/* @__PURE__ */ new Set()), { rules: T, alerts: D, config: L } = Ge(), _ = L.tenant === "schools", Y = L.tenant === "transit", j = so(x, 600), ce = _ && j.trim() ? 100 : s, me = {
1900
1900
  6: { title: "Email", kind: "icon", icon: /* @__PURE__ */ c(qi, {}) },
1901
1901
  7: { title: "SMS", kind: "icon", icon: /* @__PURE__ */ c(Gi, {}) }
1902
1902
  };
@@ -1943,7 +1943,7 @@ function Mr({
1943
1943
  }, [T]), oe(() => {
1944
1944
  if (!m) return;
1945
1945
  const P = O.find((ge) => ge.value === y), W = {
1946
- anomalyId: ie.length > 1 && v !== "All" ? v : void 0,
1946
+ anomalyId: ie.length > 1 && w !== "All" ? w : void 0,
1947
1947
  spaceId: !Y && g.length > 1 && b !== "All" ? b : void 0,
1948
1948
  spaceNumber: Y && g.length > 1 && b !== "All" ? b : void 0,
1949
1949
  severityId: O.length > 1 && y !== "All" ? y : void 0,
@@ -1953,7 +1953,7 @@ function Mr({
1953
1953
  };
1954
1954
  m(W), u?.(1);
1955
1955
  }, [
1956
- v,
1956
+ w,
1957
1957
  b,
1958
1958
  y,
1959
1959
  q,
@@ -2021,7 +2021,7 @@ function Mr({
2021
2021
  return It.delete(bt), It;
2022
2022
  });
2023
2023
  }
2024
- }, ue = cn, Ve = un, be = me[ue], Ke = me[Ve], Me = Un(ue, W, be?.title), we = Un(Ve, W, Ke?.title), Wt = Cs(W.id, !0), pt = Cs(W.id, !1), Nt = os(ue) && A.has(Wt), nt = os(Ve) && A.has(pt);
2024
+ }, ue = cn, Ve = un, be = me[ue], Ke = me[Ve], Me = Un(ue, W, be?.title), we = Un(Ve, W, Ke?.title), Wt = Cs(W.id, !0), pt = Cs(W.id, !1), Nt = os(ue) && v.has(Wt), nt = os(Ve) && v.has(pt);
2025
2025
  return /* @__PURE__ */ f(st, { size: "middle", children: [
2026
2026
  /* @__PURE__ */ c(In, { title: Me.tooltipTitle, children: /* @__PURE__ */ c(
2027
2027
  ze,
@@ -2140,7 +2140,7 @@ function Mr({
2140
2140
  /* @__PURE__ */ c(
2141
2141
  $a,
2142
2142
  {
2143
- value: v,
2143
+ value: w,
2144
2144
  onChange: k,
2145
2145
  options: Oe
2146
2146
  }
@@ -2632,8 +2632,8 @@ class lt extends Kt {
2632
2632
  millisecond: 0
2633
2633
  });
2634
2634
  let p = +s;
2635
- const v = p % 1e3;
2636
- return p -= v >= 0 ? v : 1e3 + v, (y - p) / (60 * 1e3);
2635
+ const w = p % 1e3;
2636
+ return p -= w >= 0 ? w : 1e3 + w, (y - p) / (60 * 1e3);
2637
2637
  }
2638
2638
  /**
2639
2639
  * Return whether this Zone is equal to another zone
@@ -3775,12 +3775,12 @@ class Ce {
3775
3775
  return s > 0 && (r.padTo = s), n && (r.signDisplay = n), this.loc.numberFormatter(r).format(e);
3776
3776
  }
3777
3777
  formatDateTimeFromString(e, s) {
3778
- const n = this.loc.listingMode() === "en", r = this.loc.outputCalendar && this.loc.outputCalendar !== "gregory", i = (p, v) => this.loc.extract(e, p, v), a = (p) => e.isOffsetFixed && e.offset === 0 && p.allowZ ? "Z" : e.isValid ? e.zone.formatOffset(e.ts, p.format) : "", o = () => n ? Ho(e) : i({ hour: "numeric", hourCycle: "h12" }, "dayperiod"), l = (p, v) => n ? qo(e, p) : i(v ? { month: p } : { month: p, day: "numeric" }, "month"), u = (p, v) => n ? Go(e, p) : i(
3779
- v ? { weekday: p } : { weekday: p, month: "long", day: "numeric" },
3778
+ const n = this.loc.listingMode() === "en", r = this.loc.outputCalendar && this.loc.outputCalendar !== "gregory", i = (p, w) => this.loc.extract(e, p, w), a = (p) => e.isOffsetFixed && e.offset === 0 && p.allowZ ? "Z" : e.isValid ? e.zone.formatOffset(e.ts, p.format) : "", o = () => n ? Ho(e) : i({ hour: "numeric", hourCycle: "h12" }, "dayperiod"), l = (p, w) => n ? qo(e, p) : i(w ? { month: p } : { month: p, day: "numeric" }, "month"), u = (p, w) => n ? Go(e, p) : i(
3779
+ w ? { weekday: p } : { weekday: p, month: "long", day: "numeric" },
3780
3780
  "weekday"
3781
3781
  ), m = (p) => {
3782
- const v = Ce.macroTokenToFormatOpts(p);
3783
- return v ? this.formatWithSystemDefault(e, v) : p;
3782
+ const w = Ce.macroTokenToFormatOpts(p);
3783
+ return w ? this.formatWithSystemDefault(e, w) : p;
3784
3784
  }, d = (p) => n ? Yo(e, p) : i({ era: p }, "era"), y = (p) => {
3785
3785
  switch (p) {
3786
3786
  // ms
@@ -3951,9 +3951,9 @@ class Ce {
3951
3951
  }, i = (m, d) => (y) => {
3952
3952
  const p = r(y);
3953
3953
  if (p) {
3954
- const v = d.isNegativeDuration && p !== d.largestUnit ? n : 1;
3954
+ const w = d.isNegativeDuration && p !== d.largestUnit ? n : 1;
3955
3955
  let k;
3956
- return this.opts.signMode === "negativeLargestOnly" && p !== d.largestUnit ? k = "never" : this.opts.signMode === "all" ? k = "always" : k = "auto", this.num(m.get(p) * v, y.length, k);
3956
+ return this.opts.signMode === "negativeLargestOnly" && p !== d.largestUnit ? k = "never" : this.opts.signMode === "all" ? k = "always" : k = "auto", this.num(m.get(p) * w, y.length, k);
3957
3957
  } else
3958
3958
  return y;
3959
3959
  }, a = Ce.parseFormat(s), o = a.reduce(
@@ -4033,7 +4033,7 @@ function es(t, e) {
4033
4033
  }
4034
4034
  const il = RegExp(`^T?${gn.source}$`), al = /^-?P(?:(?:(-?\d{1,20}(?:\.\d{1,20})?)Y)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20}(?:\.\d{1,20})?)W)?(?:(-?\d{1,20}(?:\.\d{1,20})?)D)?(?:T(?:(-?\d{1,20}(?:\.\d{1,20})?)H)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,20}))?S)?)?)$/;
4035
4035
  function ol(t) {
4036
- const [e, s, n, r, i, a, o, l, u] = t, m = e[0] === "-", d = l && l[0] === "-", y = (p, v = !1) => p !== void 0 && (v || p && m) ? -p : p;
4036
+ const [e, s, n, r, i, a, o, l, u] = t, m = e[0] === "-", d = l && l[0] === "-", y = (p, w = !1) => p !== void 0 && (w || p && m) ? -p : p;
4037
4037
  return [
4038
4038
  {
4039
4039
  years: y(gt(s)),
@@ -6300,14 +6300,14 @@ class F {
6300
6300
  const n = ht(s.zone, Ne.defaultZone);
6301
6301
  if (!n.isValid)
6302
6302
  return F.invalid(Gt(n));
6303
- const r = re.fromObject(s), i = As(e, ur), { minDaysInFirstWeek: a, startOfWeek: o } = Jn(i, r), l = Ne.now(), u = $(s.specificOffset) ? n.offset(l) : s.specificOffset, m = !$(i.ordinal), d = !$(i.year), y = !$(i.month) || !$(i.day), p = d || y, v = i.weekYear || i.weekNumber;
6304
- if ((p || m) && v)
6303
+ const r = re.fromObject(s), i = As(e, ur), { minDaysInFirstWeek: a, startOfWeek: o } = Jn(i, r), l = Ne.now(), u = $(s.specificOffset) ? n.offset(l) : s.specificOffset, m = !$(i.ordinal), d = !$(i.year), y = !$(i.month) || !$(i.day), p = d || y, w = i.weekYear || i.weekNumber;
6304
+ if ((p || m) && w)
6305
6305
  throw new Dt(
6306
6306
  "Can't mix weekYear/weekNumber units with year/month/day or ordinals"
6307
6307
  );
6308
6308
  if (y && m)
6309
6309
  throw new Dt("Can't mix ordinal dates with month/day");
6310
- const k = v || i.weekday && !p;
6310
+ const k = w || i.weekday && !p;
6311
6311
  let b, B, q = ds(l, u);
6312
6312
  k ? (b = ec, B = Ql, q = vs(q, a, o)) : m ? (b = tc, B = Xl, q = Fs(q)) : (b = ps, B = Ci);
6313
6313
  let Q = !1;
@@ -7857,14 +7857,14 @@ function lc({
7857
7857
  }
7858
7858
  )
7859
7859
  }
7860
- ], v = o ? t : (t || []).filter((k) => {
7860
+ ], w = o ? t : (t || []).filter((k) => {
7861
7861
  const b = On(k.statusType || "");
7862
7862
  return no.some((B) => b.includes(On(B)));
7863
7863
  });
7864
7864
  return /* @__PURE__ */ c(
7865
7865
  Mr,
7866
7866
  {
7867
- data: v,
7867
+ data: w,
7868
7868
  loading: e,
7869
7869
  pageSize: s,
7870
7870
  total: n,
@@ -7909,7 +7909,7 @@ function cc({
7909
7909
  "aria-label": "Analog Clock",
7910
7910
  children: [
7911
7911
  [...Array(12)].map((m, d) => {
7912
- const y = d * 30, p = 6, v = u - 4, k = v - p, b = (y - 90) * (Math.PI / 180), B = u + k * Math.cos(b), q = u + k * Math.sin(b), Q = u + v * Math.cos(b), x = u + v * Math.sin(b);
7912
+ const y = d * 30, p = 6, w = u - 4, k = w - p, b = (y - 90) * (Math.PI / 180), B = u + k * Math.cos(b), q = u + k * Math.sin(b), Q = u + w * Math.cos(b), x = u + w * Math.sin(b);
7913
7913
  return /* @__PURE__ */ c(
7914
7914
  "svg",
7915
7915
  {
@@ -8082,7 +8082,7 @@ function fc(t) {
8082
8082
  setL2mins: d,
8083
8083
  l2role: y,
8084
8084
  setL2role: p,
8085
- l3mins: v,
8085
+ l3mins: w,
8086
8086
  setL3mins: k,
8087
8087
  l3role: b,
8088
8088
  setL3role: B,
@@ -8098,7 +8098,7 @@ function fc(t) {
8098
8098
  onSave: M,
8099
8099
  saving: ie,
8100
8100
  onActionTypesLoaded: ye
8101
- } = t, { rules: O, config: N } = Ge(), A = N.tenant === "schools", [E, T] = S([]), [D, L] = S([]), [_, Y] = S(!1);
8101
+ } = t, { rules: O, config: N } = Ge(), v = N.tenant === "schools", [E, T] = S([]), [D, L] = S([]), [_, Y] = S(!1);
8102
8102
  oe(() => {
8103
8103
  let te = !1;
8104
8104
  return (async () => {
@@ -8119,7 +8119,7 @@ function fc(t) {
8119
8119
  te = !0;
8120
8120
  };
8121
8121
  }, []);
8122
- const j = typeof a == "number" || typeof l == "number", ce = typeof m == "number" || typeof y == "number", me = typeof a == "number" || typeof l == "number" || typeof m == "number" || typeof y == "number" || typeof v == "number" || typeof b == "number" || Array.isArray(q) && q.length > 0 || Array.isArray(x) && x.length > 0 || !!Z || !!G;
8122
+ const j = typeof a == "number" || typeof l == "number", ce = typeof m == "number" || typeof y == "number", me = typeof a == "number" || typeof l == "number" || typeof m == "number" || typeof y == "number" || typeof w == "number" || typeof b == "number" || Array.isArray(q) && q.length > 0 || Array.isArray(x) && x.length > 0 || !!Z || !!G;
8123
8123
  return /* @__PURE__ */ f(Ns, { spinning: !!ie || _, children: [
8124
8124
  /* @__PURE__ */ f(Ze, { gutter: [16, 16], align: "bottom", children: [
8125
8125
  /* @__PURE__ */ c(K, { xs: 24, sm: 12, md: 8, lg: 4, children: /* @__PURE__ */ f("div", { children: [
@@ -8202,7 +8202,7 @@ function fc(t) {
8202
8202
  {
8203
8203
  className: "w-full",
8204
8204
  placeholder: "Mins",
8205
- value: v,
8205
+ value: w,
8206
8206
  onChange: k,
8207
8207
  options: r
8208
8208
  }
@@ -8254,7 +8254,7 @@ function fc(t) {
8254
8254
  ] }),
8255
8255
  /* @__PURE__ */ f(Ze, { gutter: [16, 16], align: "bottom", className: "mt-4 items-center", children: [
8256
8256
  /* @__PURE__ */ c(K, { xs: 24, sm: 12, md: 8, lg: 7, children: /* @__PURE__ */ f("div", { className: "flex items-center h-full gap-8", children: [
8257
- !A && /* @__PURE__ */ c(Mt, { checked: Z, onChange: (te) => R(te.target.checked), className: "w-full", children: "Human-In-The-Loop" }),
8257
+ !v && /* @__PURE__ */ c(Mt, { checked: Z, onChange: (te) => R(te.target.checked), className: "w-full", children: "Human-In-The-Loop" }),
8258
8258
  /* @__PURE__ */ c(Mt, { checked: G, onChange: (te) => h(te.target.checked), className: "w-full", children: "Auto-expire in 5 minutes" })
8259
8259
  ] }) }),
8260
8260
  /* @__PURE__ */ c(K, { xs: 24, sm: 12, md: 8, children: /* @__PURE__ */ f("div", { className: "flex items-center gap-2", children: [
@@ -8334,7 +8334,7 @@ function hc({ entries: t, userRoles: e, onEdit: s, loading: n }) {
8334
8334
  }
8335
8335
  const { Title: yc, Text: Zs } = Jt;
8336
8336
  function pc({ userRoles: t, rules: e, rawRules: s }) {
8337
- const { rules: n } = Ge(), [r, i] = S(!1), [a, o] = S(!1), [l, u] = S(s), [m, d] = S(), [y, p] = S([]), v = ve(() => t.map((x) => ({ label: x.userRoleName, value: x.userRoleId })), [t]), k = ve(() => (e || []).map((x) => ({ label: x.Name || "-", value: x.RuleId || x.Name || "" })), [e]), b = ve(
8337
+ const { rules: n } = Ge(), [r, i] = S(!1), [a, o] = S(!1), [l, u] = S(s), [m, d] = S(), [y, p] = S([]), w = ve(() => t.map((x) => ({ label: x.userRoleName, value: x.userRoleId })), [t]), k = ve(() => (e || []).map((x) => ({ label: x.Name || "-", value: x.RuleId || x.Name || "" })), [e]), b = ve(
8338
8338
  () => (e || []).map((x, C) => ({
8339
8339
  key: x.RuleId || x.Name || String(C),
8340
8340
  ruleName: x.Name || "-",
@@ -8406,7 +8406,7 @@ function pc({ userRoles: t, rules: e, rawRules: s }) {
8406
8406
  className: "w-full",
8407
8407
  value: y,
8408
8408
  onChange: p,
8409
- options: v,
8409
+ options: w,
8410
8410
  maxTagCount: 1,
8411
8411
  maxTagPlaceholder: nn
8412
8412
  }
@@ -8511,7 +8511,7 @@ function zs(t) {
8511
8511
  };
8512
8512
  }
8513
8513
  function gc({ severities: t, rules: e, userRoles: s, rawRules: n, loadingRules: r, onSave: i }) {
8514
- const { rules: a, alerts: o } = Ge(), [l, u] = S("By Severity"), [m, d] = S("By severity"), [y, p] = S("By Severity"), [v, k] = S(!1), [b, B] = S(!1), [q, Q] = S(!1), [x, C] = S(null), [Z, R] = S("rules"), [G, h] = S(), [g, M] = S(), [ie, ye] = S(), [O, N] = S(), [A, E] = S(), [T, D] = S(), [L, _] = S(), [Y, j] = S(), [ce, me] = S([]), [Oe, te] = S([]), [Se, ke] = S(!1), [pe, P] = S(!1), [W, ge] = S({}), [ue, Ve] = S({}), [be, Ke] = S(s || []), [Me, we] = S([]), [Wt, pt] = S(!1), [Nt, nt] = S(!1), [Be, Tt] = S(n || []);
8514
+ const { rules: a, alerts: o } = Ge(), [l, u] = S("By Severity"), [m, d] = S("By severity"), [y, p] = S("By Severity"), [w, k] = S(!1), [b, B] = S(!1), [q, Q] = S(!1), [x, C] = S(null), [Z, R] = S("rules"), [G, h] = S(), [g, M] = S(), [ie, ye] = S(), [O, N] = S(), [v, E] = S(), [T, D] = S(), [L, _] = S(), [Y, j] = S(), [ce, me] = S([]), [Oe, te] = S([]), [Se, ke] = S(!1), [pe, P] = S(!1), [W, ge] = S({}), [ue, Ve] = S({}), [be, Ke] = S(s || []), [Me, we] = S([]), [Wt, pt] = S(!1), [Nt, nt] = S(!1), [Be, Tt] = S(n || []);
8515
8515
  oe(() => {
8516
8516
  n && n.length && Tt(n);
8517
8517
  }, [n]), oe(() => {
@@ -8589,13 +8589,13 @@ function gc({ severities: t, rules: e, userRoles: s, rawRules: n, loadingRules:
8589
8589
  const U = await a.getRules(), se = Array.isArray(U) ? U : Array.isArray(U?.data) ? U.data : [];
8590
8590
  Tt(se);
8591
8591
  const J = se.map((V, de) => {
8592
- const z = e.find((le) => le.RuleId === (V.ruleId || V.ruleName))?.Name || V.ruleName || V.Name || "-", ne = zs(V.escalationSettings ?? V.EscalationSettings), rt = typeof ne.level1UserRoleId == "number" && ne.level1UserRoleId > 0 ? [ne.level1UserRoleId] : [], ss = typeof ne.level2UserRoleId == "number" && ne.level2UserRoleId > 0 ? [ne.level2UserRoleId] : [], w = typeof ne.level3UserRoleId == "number" && ne.level3UserRoleId > 0 ? [ne.level3UserRoleId] : [], ae = (Array.isArray(ne.escalationSettingsActionTypeIds) ? ne.escalationSettingsActionTypeIds : []).map((le) => W[le] || String(le)), Re = (Array.isArray(ne.thirdPartyId) ? ne.thirdPartyId : []).map((le) => ue[le] || String(le)), fe = typeof ne.humanLoop == "boolean" ? ne.humanLoop : null;
8592
+ const z = e.find((le) => le.RuleId === (V.ruleId || V.ruleName))?.Name || V.ruleName || V.Name || "-", ne = zs(V.escalationSettings ?? V.EscalationSettings), rt = typeof ne.level1UserRoleId == "number" && ne.level1UserRoleId > 0 ? [ne.level1UserRoleId] : [], ss = typeof ne.level2UserRoleId == "number" && ne.level2UserRoleId > 0 ? [ne.level2UserRoleId] : [], A = typeof ne.level3UserRoleId == "number" && ne.level3UserRoleId > 0 ? [ne.level3UserRoleId] : [], ae = (Array.isArray(ne.escalationSettingsActionTypeIds) ? ne.escalationSettingsActionTypeIds : []).map((le) => W[le] || String(le)), Re = (Array.isArray(ne.thirdPartyId) ? ne.thirdPartyId : []).map((le) => ue[le] || String(le)), fe = typeof ne.humanLoop == "boolean" ? ne.humanLoop : null;
8593
8593
  return {
8594
8594
  id: String(V.ruleId || V.ruleName || de),
8595
8595
  ruleOrSeverityLabel: z,
8596
8596
  l1: { minutes: ne.level1PostAssistTime ?? void 0, roles: rt },
8597
8597
  l2: { minutes: ne.level2PostAssistTime ?? void 0, roles: ss },
8598
- l3: { minutes: ne.level3PostAssistTime ?? void 0, roles: w },
8598
+ l3: { minutes: ne.level3PostAssistTime ?? void 0, roles: A },
8599
8599
  actions: ae,
8600
8600
  notify: Re,
8601
8601
  humanLoop: fe
@@ -8648,7 +8648,7 @@ function gc({ severities: t, rules: e, userRoles: s, rawRules: n, loadingRules:
8648
8648
  onChange: (U) => {
8649
8649
  U.sortBy && (u(U.sortBy), k(!0)), U.groupBy && (d(U.groupBy), k(!0));
8650
8650
  },
8651
- showActions: v,
8651
+ showActions: w,
8652
8652
  onSave: async () => {
8653
8653
  B(!0);
8654
8654
  try {
@@ -8688,7 +8688,7 @@ function gc({ severities: t, rules: e, userRoles: s, rawRules: n, loadingRules:
8688
8688
  setL1mins: ye,
8689
8689
  l1role: O,
8690
8690
  setL1role: N,
8691
- l2mins: A,
8691
+ l2mins: v,
8692
8692
  setL2mins: E,
8693
8693
  l2role: T,
8694
8694
  setL2role: D,
@@ -8710,7 +8710,7 @@ function gc({ severities: t, rules: e, userRoles: s, rawRules: n, loadingRules:
8710
8710
  ruleId: g,
8711
8711
  levels: [
8712
8712
  { minutes: ie, role: O },
8713
- { minutes: A, role: T },
8713
+ { minutes: v, role: T },
8714
8714
  { minutes: L, role: Y }
8715
8715
  ],
8716
8716
  actions: ce,
@@ -8733,7 +8733,7 @@ function gc({ severities: t, rules: e, userRoles: s, rawRules: n, loadingRules:
8733
8733
  level1UserRoleId: O ?? 0,
8734
8734
  level1PostAssistTime: ie ?? 0,
8735
8735
  level2UserRoleId: T ?? 0,
8736
- level2PostAssistTime: A ?? 0,
8736
+ level2PostAssistTime: v ?? 0,
8737
8737
  level3UserRoleId: Y ?? 0,
8738
8738
  level3PostAssistTime: L ?? 0,
8739
8739
  escalationSettingsActionTypeIds: se,
@@ -8786,7 +8786,7 @@ function Bc({ severities: t, rules: e, onSave: s, onCancel: n }) {
8786
8786
  const { rules: r, alerts: i } = Ge(), a = [
8787
8787
  { label: "By Severity", value: "By Severity" },
8788
8788
  { label: "By Created Date", value: "By Created Date" }
8789
- ], [o, l] = S("By Severity"), [u, m] = S(/* @__PURE__ */ new Set()), [d, y] = S(null), [p, v] = S(null), [k, b] = S({ inApp: !1, sms: !1, email: !1 }), [B, q] = S([]), [Q, x] = S(!0), [C, Z] = S(!1);
8789
+ ], [o, l] = S("By Severity"), [u, m] = S(/* @__PURE__ */ new Set()), [d, y] = S(null), [p, w] = S(null), [k, b] = S({ inApp: !1, sms: !1, email: !1 }), [B, q] = S([]), [Q, x] = S(!0), [C, Z] = S(!1);
8790
8790
  oe(() => {
8791
8791
  let h = !1;
8792
8792
  return (async () => {
@@ -8800,7 +8800,7 @@ function Bc({ severities: t, rules: e, onSave: s, onCancel: n }) {
8800
8800
  email: !!g.email
8801
8801
  });
8802
8802
  const M = vr(g.sortBy);
8803
- l(M === "By Created Date" ? "By Created Date" : "By Severity"), y(Rn(g.doNotDisturbStart)), v(Rn(g.doNotDisturbEnd)), Array.isArray(g.anomalyIds) && m(new Set(g.anomalyIds.map((ie) => String(ie))));
8803
+ l(M === "By Created Date" ? "By Created Date" : "By Severity"), y(Rn(g.doNotDisturbStart)), w(Rn(g.doNotDisturbEnd)), Array.isArray(g.anomalyIds) && m(new Set(g.anomalyIds.map((ie) => String(ie))));
8804
8804
  } catch (g) {
8805
8805
  console.error("Error in loading my preferences: ", g);
8806
8806
  }
@@ -8881,7 +8881,7 @@ function Bc({ severities: t, rules: e, onSave: s, onCancel: n }) {
8881
8881
  ] }),
8882
8882
  /* @__PURE__ */ f(st, { direction: "horizontal", size: 8, className: "items-center", children: [
8883
8883
  /* @__PURE__ */ c(fs, { children: "To" }),
8884
- /* @__PURE__ */ c(kn, { value: p, onChange: (h) => v(h), format: "HH:mm" })
8884
+ /* @__PURE__ */ c(kn, { value: p, onChange: (h) => w(h), format: "HH:mm" })
8885
8885
  ] })
8886
8886
  ] })
8887
8887
  ] }) }) }),
@@ -9167,11 +9167,11 @@ const Tc = ({
9167
9167
  onAlertView: l,
9168
9168
  showAlertTimeline: u
9169
9169
  }) => {
9170
- const [m, d] = S(), [y, p] = S(""), [v, k] = S(!1), [b, B] = S([]), q = pr(null), [Q, x] = S("details"), [C, Z] = S(void 0), R = Dr(), { alerts: G, rules: h, config: g } = Ge(), { timeZoneDetails: M } = ts(), [ie, ye] = S(
9170
+ const [m, d] = S(), [y, p] = S(""), [w, k] = S(!1), [b, B] = S([]), q = pr(null), [Q, x] = S("details"), [C, Z] = S(void 0), R = Dr(), { alerts: G, rules: h, config: g } = Ge(), { timeZoneDetails: M } = ts(), [ie, ye] = S(
9171
9171
  null
9172
- ), [O, N] = S(!1), [A, E] = S(!1), [T, D] = S(void 0), [L, _] = S(void 0), [Y, j] = S({}), [ce, me] = S({}), Oe = (w, H, ae) => {
9173
- const Ie = ce[w];
9174
- return Y[w] === !1 && !Ie ? /* @__PURE__ */ f("div", { className: "w-full flex flex-col items-center justify-center min-h-[200px] bg-gray-100 rounded-lg gap-2 text-gray-400", children: [
9172
+ ), [O, N] = S(!1), [v, E] = S(!1), [T, D] = S(void 0), [L, _] = S(void 0), [Y, j] = S({}), [ce, me] = S({}), Oe = (A, H, ae) => {
9173
+ const Ie = ce[A];
9174
+ return Y[A] === !1 && !Ie ? /* @__PURE__ */ f("div", { className: "w-full flex flex-col items-center justify-center min-h-[200px] bg-gray-100 rounded-lg gap-2 text-gray-400", children: [
9175
9175
  /* @__PURE__ */ c(Er, { size: 40 }),
9176
9176
  /* @__PURE__ */ c("span", { className: "text-sm", children: "Media not available" })
9177
9177
  ] }) : /* @__PURE__ */ f("div", { className: "relative w-full flex justify-center items-center min-h-[200px]", children: [
@@ -9179,13 +9179,13 @@ const Tc = ({
9179
9179
  /* @__PURE__ */ c(
9180
9180
  bc,
9181
9181
  {
9182
- url: w,
9182
+ url: A,
9183
9183
  alt: H.caption || `media-${ae}`,
9184
9184
  isLoading: Ie,
9185
9185
  priority: be,
9186
9186
  detections: Be,
9187
- onLoadSuccess: () => me((Re) => ({ ...Re, [w]: !1 })),
9188
- onError: () => me((Re) => ({ ...Re, [w]: !1 }))
9187
+ onLoadSuccess: () => me((Re) => ({ ...Re, [A]: !1 })),
9188
+ onError: () => me((Re) => ({ ...Re, [A]: !1 }))
9189
9189
  }
9190
9190
  )
9191
9191
  ] });
@@ -9208,20 +9208,20 @@ const Tc = ({
9208
9208
  } = te, nt = te.bbox_xyxy, Be = ve(
9209
9209
  () => nt ? [{ bbox_xyxy: nt, personName: te.personName }] : [],
9210
9210
  [nt, te.personName]
9211
- ), Tt = g.tenant === "snl" ? ke || Se || "Alert Event" : Se || "Alert Event", bt = (w) => {
9212
- const H = String(w || "").toLowerCase();
9211
+ ), Tt = g.tenant === "snl" ? ke || Se || "Alert Event" : Se || "Alert Event", bt = (A) => {
9212
+ const H = String(A || "").toLowerCase();
9213
9213
  return H === "delivered" || H === "sent" ? "Delivered" : H === "failed" ? "Failed" : "Queued";
9214
- }, xe = (w) => ({
9215
- name: w?.receipientName || w?.recipientName || "-",
9216
- role: w?.receipientRoleName || "",
9217
- phone: w?.receipentPhoneNumber || w?.recipientPhoneNumber || w?.receipientEmail || w?.recipientEmail || "",
9218
- status: bt(w?.messageStatus),
9219
- notificationReceipientType: w?.notificationReceipientType || "",
9220
- sentAt: w?.sentAt || ""
9221
- }), It = (w, H) => {
9222
- const ae = H.map(xe), Ie = ae.filter((le) => le.status === "Delivered").length, Re = H.map((le) => le?.sentAt).filter(Boolean).sort((le, Tn) => new Date(le).getTime() - new Date(Tn).getTime())[0], fe = `${w} Notification`;
9214
+ }, xe = (A) => ({
9215
+ name: A?.receipientName || A?.recipientName || "-",
9216
+ role: A?.receipientRoleName || "",
9217
+ phone: A?.receipentPhoneNumber || A?.recipientPhoneNumber || A?.receipientEmail || A?.recipientEmail || "",
9218
+ status: bt(A?.messageStatus),
9219
+ notificationReceipientType: A?.notificationReceipientType || "",
9220
+ sentAt: A?.sentAt || ""
9221
+ }), It = (A, H) => {
9222
+ const ae = H.map(xe), Ie = ae.filter((le) => le.status === "Delivered").length, Re = H.map((le) => le?.sentAt).filter(Boolean).sort((le, Tn) => new Date(le).getTime() - new Date(Tn).getTime())[0], fe = `${A} Notification`;
9223
9223
  return {
9224
- channelLabel: `${w} Notification`,
9224
+ channelLabel: `${A} Notification`,
9225
9225
  sentAt: Re || "",
9226
9226
  messageTitle: fe,
9227
9227
  messageBody: "",
@@ -9229,17 +9229,17 @@ const Tc = ({
9229
9229
  delivered: Ie,
9230
9230
  recipients: ae
9231
9231
  };
9232
- }, Os = (w) => {
9232
+ }, Os = (A) => {
9233
9233
  const H = /* @__PURE__ */ new Map();
9234
- return (w || []).forEach((ae) => {
9234
+ return (A || []).forEach((ae) => {
9235
9235
  const Ie = String(ae?.notificationType || "Unknown"), Re = H.get(Ie) || [];
9236
9236
  Re.push(ae), H.set(Ie, Re);
9237
9237
  }), Array.from(H.entries()).map(
9238
9238
  ([ae, Ie]) => It(ae, Ie)
9239
9239
  );
9240
- }, Ms = async (w) => {
9240
+ }, Ms = async (A) => {
9241
9241
  try {
9242
- const H = await G.getAlertNotifications(w), ae = Os(H);
9242
+ const H = await G.getAlertNotifications(A), ae = Os(H);
9243
9243
  Z(ae);
9244
9244
  } catch {
9245
9245
  Z(void 0);
@@ -9247,11 +9247,11 @@ const Tc = ({
9247
9247
  };
9248
9248
  oe(() => {
9249
9249
  if (Q !== "track" || !Me) return;
9250
- let w = !1;
9250
+ let A = !1;
9251
9251
  return Ms(Me).then(() => {
9252
- w && Z(void 0);
9252
+ A && Z(void 0);
9253
9253
  }), () => {
9254
- w = !0;
9254
+ A = !0;
9255
9255
  };
9256
9256
  }, [Q, Me]), oe(() => {
9257
9257
  if (!P) {
@@ -9278,52 +9278,52 @@ const Tc = ({
9278
9278
  ]);
9279
9279
  }, [t]), oe(() => {
9280
9280
  if (!t || g.tenant !== "snl") return;
9281
- let w = !1;
9281
+ let A = !1;
9282
9282
  return N(!0), h.getLookups().then((H) => {
9283
- w || (ye(H.alertStatusTypes ?? []), N(!1));
9283
+ A || (ye(H.alertStatusTypes ?? []), N(!1));
9284
9284
  }).catch(() => {
9285
- w || (ye([]), N(!1));
9285
+ A || (ye([]), N(!1));
9286
9286
  }), () => {
9287
- w = !0;
9287
+ A = !0;
9288
9288
  };
9289
9289
  }, [t, g.tenant]);
9290
- const wn = o === "archived" || ["completed", "false positive"].includes(String(Ke || "").toLowerCase()), An = (w) => {
9291
- const H = String(w?.value || "").toLowerCase(), ae = String(w?.statusName || "").toLowerCase();
9290
+ const wn = o === "archived" || ["completed", "false positive"].includes(String(Ke || "").toLowerCase()), An = (A) => {
9291
+ const H = String(A?.value || "").toLowerCase(), ae = String(A?.statusName || "").toLowerCase();
9292
9292
  return H.includes("reopen") || ae.includes("reopen");
9293
- }, Nn = String(pe || "").trim().toLowerCase(), U = Ec[Nn] ?? "general", se = r.filter((w) => {
9294
- const H = An(w);
9293
+ }, Nn = String(pe || "").trim().toLowerCase(), U = Ec[Nn] ?? "general", se = r.filter((A) => {
9294
+ const H = An(A);
9295
9295
  return typeof o < "u" ? o === "archived" ? H : !H : wn ? H : !H;
9296
- }).map((w) => ({ value: w.value, label: w.statusName })), J = ie ?? [], V = (w) => !!w.isWatchListStatus, de = (w) => !!w.isWeapontStatus, z = J.filter((w) => {
9296
+ }).map((A) => ({ value: A.value, label: A.statusName })), J = ie ?? [], V = (A) => !!A.isWatchListStatus, de = (A) => !!A.isWeapontStatus, z = J.filter((A) => {
9297
9297
  switch (U) {
9298
9298
  case "elopement":
9299
- return w.isElopementStatus;
9299
+ return A.isElopementStatus;
9300
9300
  case "watchlist":
9301
- return V(w);
9301
+ return V(A);
9302
9302
  case "weapon":
9303
- return de(w);
9303
+ return de(A);
9304
9304
  default:
9305
- return !w.isElopementStatus && !V(w) && !de(w);
9305
+ return !A.isElopementStatus && !V(A) && !de(A);
9306
9306
  }
9307
- }).map((w) => ({ value: w.alertStatusTypeName, label: w.alertStatusTypeName })), ne = g.tenant === "snl" && ie !== null ? z : se, rt = ve(() => Nr(pt), [pt]);
9307
+ }).map((A) => ({ value: A.alertStatusTypeName, label: A.alertStatusTypeName })), ne = g.tenant === "snl" && ie !== null ? z : se, rt = ve(() => Nr(pt), [pt]);
9308
9308
  return oe(() => {
9309
- let w = !1;
9309
+ let A = !1;
9310
9310
  const H = new AbortController(), ae = async (fe) => {
9311
9311
  if (fe) {
9312
- w || j((le) => ({ ...le, [fe]: !1 }));
9312
+ A || j((le) => ({ ...le, [fe]: !1 }));
9313
9313
  try {
9314
9314
  const le = await fetch(fe, { method: "HEAD", signal: H.signal });
9315
9315
  if (le.ok) {
9316
- w || j((Vt) => ({ ...Vt, [fe]: !0 }));
9316
+ A || j((Vt) => ({ ...Vt, [fe]: !0 }));
9317
9317
  return;
9318
9318
  }
9319
9319
  if (le.status === 404) {
9320
- w || j((Vt) => ({ ...Vt, [fe]: !1 }));
9320
+ A || j((Vt) => ({ ...Vt, [fe]: !1 }));
9321
9321
  return;
9322
9322
  }
9323
9323
  if (!(await fetch(fe, { method: "GET", signal: H.signal })).ok) throw new Error("Media not available");
9324
- w || j((Vt) => ({ ...Vt, [fe]: !0 }));
9324
+ A || j((Vt) => ({ ...Vt, [fe]: !0 }));
9325
9325
  } catch {
9326
- w || j((le) => ({ ...le, [fe]: !1 }));
9326
+ A || j((le) => ({ ...le, [fe]: !1 }));
9327
9327
  }
9328
9328
  }
9329
9329
  };
@@ -9332,7 +9332,7 @@ const Tc = ({
9332
9332
  return Ie.forEach((fe) => {
9333
9333
  Re[fe] = !0;
9334
9334
  }), me(Re), Ie.forEach((fe) => ae(fe)), () => {
9335
- w = !0, H.abort();
9335
+ A = !0, H.abort();
9336
9336
  };
9337
9337
  }, [rt]), /* @__PURE__ */ c(
9338
9338
  zi,
@@ -9340,6 +9340,8 @@ const Tc = ({
9340
9340
  open: t,
9341
9341
  onCancel: e,
9342
9342
  width: 1e3,
9343
+ closable: !v,
9344
+ maskClosable: !v,
9343
9345
  footer: Q === "details" ? /* @__PURE__ */ f("div", { className: "flex flex-row gap-2 justify-start", children: [
9344
9346
  /* @__PURE__ */ c(
9345
9347
  ze,
@@ -9352,13 +9354,13 @@ const Tc = ({
9352
9354
  /* @__PURE__ */ c(ze, { type: "primary", onClick: async () => {
9353
9355
  try {
9354
9356
  k(!0);
9355
- const w = {
9357
+ const A = {
9356
9358
  alertUniqueId: P,
9357
9359
  alertId: Me,
9358
9360
  status: m ? String(m) : void 0,
9359
9361
  notes: y.trim(),
9360
9362
  modifiedBy: 0
9361
- }, H = await R.mutateAsync(w);
9363
+ }, H = await R.mutateAsync(A);
9362
9364
  if (H?.responseStatus || H?.Success) {
9363
9365
  const ae = H?.Message || H?.data || "Alert updated successfully.";
9364
9366
  Ee.success(ae, {
@@ -9371,18 +9373,18 @@ const Tc = ({
9371
9373
  const ae = H?.errorMessage || H?.Message || "Failed to update alert status";
9372
9374
  Ee.error(ae);
9373
9375
  }
9374
- } catch (w) {
9375
- console.error("Error updating alert status:", w), Ee.error("Failed to update alert status. Please try again.");
9376
+ } catch (A) {
9377
+ console.error("Error updating alert status:", A), Ee.error("Failed to update alert status. Please try again.");
9376
9378
  } finally {
9377
9379
  k(!1);
9378
9380
  }
9379
- }, loading: v, children: v ? "Saving..." : "Save Changes" })
9381
+ }, loading: w, children: w ? "Saving..." : "Save Changes" })
9380
9382
  ] }) : null,
9381
9383
  children: s && /* @__PURE__ */ c(
9382
9384
  on,
9383
9385
  {
9384
9386
  activeKey: Q,
9385
- onChange: (w) => x(w),
9387
+ onChange: (A) => x(A),
9386
9388
  items: [
9387
9389
  {
9388
9390
  key: "details",
@@ -9461,7 +9463,7 @@ const Tc = ({
9461
9463
  {
9462
9464
  placeholder: "Change Status",
9463
9465
  className: "w-full text-gray-500",
9464
- onChange: (w) => d(w),
9466
+ onChange: (A) => d(A),
9465
9467
  value: m,
9466
9468
  options: ne,
9467
9469
  loading: g.tenant === "snl" ? O : i
@@ -9483,7 +9485,7 @@ const Tc = ({
9483
9485
  placeholder: "Enter details...",
9484
9486
  className: "w-full text-gray-500 h-20 border border-grey-500 rounded-md p-2",
9485
9487
  value: y,
9486
- onChange: (w) => p(w.target.value)
9488
+ onChange: (A) => p(A.target.value)
9487
9489
  }
9488
9490
  )
9489
9491
  ] })
@@ -9516,8 +9518,8 @@ const Tc = ({
9516
9518
  )
9517
9519
  ] }) : null
9518
9520
  ] }),
9519
- rt.length ? /* @__PURE__ */ c("div", { className: "w-full", children: /* @__PURE__ */ c(Hi, { ref: q, dots: !0, className: "w-full", children: rt.map((w, H) => {
9520
- const ae = w.mediaUrl || w, Ie = Gs(w);
9521
+ rt.length ? /* @__PURE__ */ c("div", { className: "w-full", children: /* @__PURE__ */ c(Hi, { ref: q, dots: !0, className: "w-full", children: rt.map((A, H) => {
9522
+ const ae = A.mediaUrl || A, Ie = Gs(A);
9521
9523
  return /* @__PURE__ */ f(
9522
9524
  "div",
9523
9525
  {
@@ -9535,13 +9537,13 @@ const Tc = ({
9535
9537
  "Your browser does not support the video tag."
9536
9538
  ]
9537
9539
  }
9538
- ) : Oe(String(ae), w, H),
9539
- w.caption && /* @__PURE__ */ c("p", { className: "text-xs text-gray-500 mt-1", children: w.caption }),
9540
+ ) : Oe(String(ae), A, H),
9541
+ A.caption && /* @__PURE__ */ c("p", { className: "text-xs text-gray-500 mt-1", children: A.caption }),
9540
9542
  !Ie && Y[String(ae)] ? /* @__PURE__ */ c(
9541
9543
  "button",
9542
9544
  {
9543
9545
  onClick: () => {
9544
- E(!0), D(ae), _(w.type || "image");
9546
+ E(!0), D(ae), _(A.type || "image");
9545
9547
  },
9546
9548
  className: "absolute bottom-3 right-3 text-white bg-black/50 rounded-full p-2 hover:bg-black/70",
9547
9549
  children: /* @__PURE__ */ c(eo, { size: 20 })
@@ -9558,7 +9560,7 @@ const Tc = ({
9558
9560
  /* @__PURE__ */ c(
9559
9561
  kr,
9560
9562
  {
9561
- isOpen: A,
9563
+ isOpen: v,
9562
9564
  onClose: () => E(!1),
9563
9565
  src: T || "",
9564
9566
  type: L || "image",
@@ -9617,7 +9619,7 @@ function Ri({
9617
9619
  onAlertView: l,
9618
9620
  showAlertTimeline: u
9619
9621
  }) {
9620
- const [m, d] = S(!1), [y, p] = S(null), [v, k] = S("details"), { list: b, loading: B } = Mc(), { timeZoneDetails: q } = ts(), Q = q?.timeZoneName ?? "UTC", x = q?.ianaTimeZoneId ?? "UTC";
9622
+ const [m, d] = S(!1), [y, p] = S(null), [w, k] = S("details"), { list: b, loading: B } = Mc(), { timeZoneDetails: q } = ts(), Q = q?.timeZoneName ?? "UTC", x = q?.ianaTimeZoneId ?? "UTC";
9621
9623
  function C(ie, ye) {
9622
9624
  p(ie), k(ye?.tab ?? "details"), G(ye?.sourceTab ?? "active"), d(!0);
9623
9625
  }
@@ -9713,7 +9715,7 @@ function Ri({
9713
9715
  },
9714
9716
  alertStatusList: b,
9715
9717
  alertStatusLoading: B,
9716
- initialTab: v,
9718
+ initialTab: w,
9717
9719
  sourceTab: R,
9718
9720
  onAlertView: l,
9719
9721
  showAlertTimeline: u
@@ -9730,20 +9732,20 @@ function Dc() {
9730
9732
  const y = await m.getRules();
9731
9733
  if (!d) return;
9732
9734
  o(Array.isArray(y) ? y : []);
9733
- const p = (y || []).map((v, k) => ({
9734
- RuleId: v.ruleId || v.ruleName || String(k),
9735
- Name: v.ruleName || v.Name || "-",
9736
- Description: v.ruleDesc || v.Description || "",
9735
+ const p = (y || []).map((w, k) => ({
9736
+ RuleId: w.ruleId || w.ruleName || String(k),
9737
+ Name: w.ruleName || w.Name || "-",
9738
+ Description: w.ruleDesc || w.Description || "",
9737
9739
  SeverityId: 0
9738
9740
  }));
9739
9741
  e(p);
9740
9742
  try {
9741
- const v = await m.getLookups(), k = Array.isArray(v?.userRoles) ? v.userRoles.map((b) => ({
9743
+ const w = await m.getLookups(), k = Array.isArray(w?.userRoles) ? w.userRoles.map((b) => ({
9742
9744
  userRoleId: b.userRoleId ?? b.id,
9743
9745
  userRoleName: b.userRoleName ?? b.name
9744
9746
  })) : [];
9745
9747
  n(k), i(
9746
- Array.isArray(v?.severities) ? v.severities : []
9748
+ Array.isArray(w?.severities) ? w.severities : []
9747
9749
  );
9748
9750
  } catch {
9749
9751
  }
@@ -9827,9 +9829,9 @@ function Zc({
9827
9829
  () => new ea({
9828
9830
  defaultOptions: {
9829
9831
  queries: {
9830
- retry: (v, k) => {
9832
+ retry: (w, k) => {
9831
9833
  const b = k.response?.status ?? k?.status;
9832
- return b >= 400 && b <= 500 ? !1 : v < 2;
9834
+ return b >= 400 && b <= 500 ? !1 : w < 2;
9833
9835
  },
9834
9836
  refetchOnWindowFocus: !1
9835
9837
  }