@sarafapp/iron_core 1.0.48 → 1.0.49

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/IronCore.js CHANGED
@@ -1,9 +1,9 @@
1
- import x from "dayjs";
2
- import { toRaw as Ee, reactive as Be, ref as M, watch as et, computed as I, onBeforeUnmount as tt } from "vue";
3
- import { JsonConvert as st, JsonProperty as N, JsonObject as De } from "json2typescript";
4
- import { defineStore as Ue } from "pinia";
5
- var be = /* @__PURE__ */ ((t) => (t.BankCard = "####-####-####-####", t.Iban = "##-####-####-####-####-####-##", t))(be || {}), ee = /* @__PURE__ */ ((t) => (t.FullDate = "YYYY/M/D HH:mm", t.SimpleDate = "YYYY/M/D", t.CompactGregorianDate = "YYYYMMDD", t.ShortJalaliDate = "YYMM", t.JustHour = "HH:mm:ss", t))(ee || {});
6
- const rt = [
1
+ import P from "dayjs";
2
+ import { toRaw as Ge, reactive as ot, ref as M, watch as Dt, computed as S, onBeforeUnmount as At } from "vue";
3
+ import { JsonConvert as _t, JsonProperty as B, JsonObject as Ne } from "json2typescript";
4
+ import { defineStore as lt } from "pinia";
5
+ var Pe = /* @__PURE__ */ ((t) => (t.BankCard = "####-####-####-####", t.Iban = "##-####-####-####-####-####-##", t))(Pe || {}), re = /* @__PURE__ */ ((t) => (t.FullDate = "YYYY/M/D HH:mm", t.SimpleDate = "YYYY/M/D", t.CompactGregorianDate = "YYYYMMDD", t.ShortJalaliDate = "YYMM", t.JustHour = "HH:mm:ss", t))(re || {});
6
+ const Ct = [
7
7
  {
8
8
  62198619: {
9
9
  persian: "بلو",
@@ -250,7 +250,7 @@ const rt = [
250
250
  english: "agriculture"
251
251
  }
252
252
  }
253
- ], at = [
253
+ ], Mt = [
254
254
  {
255
255
  "010": {
256
256
  persian: "بانک مرکزی",
@@ -414,345 +414,345 @@ const rt = [
414
414
  }
415
415
  }
416
416
  ];
417
- var it = /* @__PURE__ */ ((t) => (t.Normal = "YYYY-MM-DD", t.ContainsHour = "YYYY-MM-DD HH:mm", t.OnlyHour = "HH:mm", t))(it || {});
418
- function pe(t) {
417
+ var Et = /* @__PURE__ */ ((t) => (t.Normal = "YYYY-MM-DD", t.ContainsHour = "YYYY-MM-DD HH:mm", t.OnlyHour = "HH:mm", t))(Et || {});
418
+ function _e(t) {
419
419
  return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
420
420
  }
421
- var ce = { exports: {} }, nt = ce.exports, ke;
422
- function ot() {
423
- return ke || (ke = 1, function(t, e) {
421
+ var ve = { exports: {} }, Ot = ve.exports, Ke;
422
+ function Pt() {
423
+ return Ke || (Ke = 1, function(t, e) {
424
424
  (function(s, r) {
425
425
  t.exports = r();
426
- })(nt, function() {
426
+ })(Ot, function() {
427
427
  return function(s, r) {
428
- r.prototype.weekday = function(a) {
429
- var i = this.$locale().weekStart || 0, n = this.$W, h = (n < i ? n + 7 : n) - i;
430
- return this.$utils().u(a) ? h : this.subtract(h, "day").add(a, "day");
428
+ r.prototype.weekday = function(n) {
429
+ var i = this.$locale().weekStart || 0, a = this.$W, l = (a < i ? a + 7 : a) - i;
430
+ return this.$utils().u(n) ? l : this.subtract(l, "day").add(n, "day");
431
431
  };
432
432
  };
433
433
  });
434
- }(ce)), ce.exports;
434
+ }(ve)), ve.exports;
435
435
  }
436
- var lt = ot();
437
- const ct = /* @__PURE__ */ pe(lt);
438
- var ue = { exports: {} }, ut = ue.exports, Te;
439
- function ht() {
440
- return Te || (Te = 1, function(t, e) {
436
+ var Lt = Pt();
437
+ const kt = /* @__PURE__ */ _e(Lt);
438
+ var ge = { exports: {} }, xt = ge.exports, Ze;
439
+ function Tt() {
440
+ return Ze || (Ze = 1, function(t, e) {
441
441
  (function(s, r) {
442
442
  t.exports = r();
443
- })(ut, function() {
443
+ })(xt, function() {
444
444
  var s = "week", r = "year";
445
- return function(a, i, n) {
446
- var h = i.prototype;
447
- h.week = function(c) {
448
- if (c === void 0 && (c = null), c !== null) return this.add(7 * (c - this.week()), "day");
449
- var g = this.$locale().yearStart || 1;
445
+ return function(n, i, a) {
446
+ var l = i.prototype;
447
+ l.week = function(o) {
448
+ if (o === void 0 && (o = null), o !== null) return this.add(7 * (o - this.week()), "day");
449
+ var c = this.$locale().yearStart || 1;
450
450
  if (this.month() === 11 && this.date() > 25) {
451
- var f = n(this).startOf(r).add(1, r).date(g), u = n(this).endOf(s);
452
- if (f.isBefore(u)) return 1;
451
+ var f = a(this).startOf(r).add(1, r).date(c), d = a(this).endOf(s);
452
+ if (f.isBefore(d)) return 1;
453
453
  }
454
- var m = n(this).startOf(r).date(g).startOf(s).subtract(1, "millisecond"), p = this.diff(m, s, !0);
455
- return p < 0 ? n(this).startOf("week").week() : Math.ceil(p);
456
- }, h.weeks = function(c) {
457
- return c === void 0 && (c = null), this.week(c);
454
+ var v = a(this).startOf(r).date(c).startOf(s).subtract(1, "millisecond"), m = this.diff(v, s, !0);
455
+ return m < 0 ? a(this).startOf("week").week() : Math.ceil(m);
456
+ }, l.weeks = function(o) {
457
+ return o === void 0 && (o = null), this.week(o);
458
458
  };
459
459
  };
460
460
  });
461
- }(ue)), ue.exports;
461
+ }(ge)), ge.exports;
462
462
  }
463
- var dt = ht();
464
- const ft = /* @__PURE__ */ pe(dt);
465
- var he = { exports: {} }, mt = he.exports, Pe;
466
- function vt() {
467
- return Pe || (Pe = 1, function(t, e) {
463
+ var $t = Tt();
464
+ const Vt = /* @__PURE__ */ _e($t);
465
+ var me = { exports: {} }, Nt = me.exports, Xe;
466
+ function jt() {
467
+ return Xe || (Xe = 1, function(t, e) {
468
468
  (function(s, r) {
469
469
  t.exports = r();
470
- })(mt, function() {
470
+ })(Nt, function() {
471
471
  return function(s, r) {
472
472
  r.prototype.weekYear = function() {
473
- var a = this.month(), i = this.week(), n = this.year();
474
- return i === 1 && a === 11 ? n + 1 : a === 0 && i >= 52 ? n - 1 : n;
473
+ var n = this.month(), i = this.week(), a = this.year();
474
+ return i === 1 && n === 11 ? a + 1 : n === 0 && i >= 52 ? a - 1 : a;
475
475
  };
476
476
  };
477
477
  });
478
- }(he)), he.exports;
478
+ }(me)), me.exports;
479
479
  }
480
- var gt = vt();
481
- const pt = /* @__PURE__ */ pe(gt);
482
- var de = { exports: {} }, yt = de.exports, $e;
483
- function St() {
484
- return $e || ($e = 1, function(t, e) {
480
+ var Ft = jt();
481
+ const Yt = /* @__PURE__ */ _e(Ft);
482
+ var ye = { exports: {} }, Ut = ye.exports, Qe;
483
+ function Bt() {
484
+ return Qe || (Qe = 1, function(t, e) {
485
485
  (function(s, r) {
486
- t.exports = r(x);
487
- })(yt, function(s) {
488
- function r(n) {
489
- return n && typeof n == "object" && "default" in n ? n : { default: n };
486
+ t.exports = r(P);
487
+ })(Ut, function(s) {
488
+ function r(a) {
489
+ return a && typeof a == "object" && "default" in a ? a : { default: a };
490
490
  }
491
- var a = r(s), i = { name: "fa", weekdays: "یک‌شنبه_دوشنبه_سه‌شنبه_چهارشنبه_پنج‌شنبه_جمعه_شنبه".split("_"), weekdaysShort: "یک‌شنبه_دوشنبه_سه‌شنبه_چهارشنبه_پنج‌شنبه_جمعه_شنبه".split("_"), weekdaysMin: "ی_د_س_چ_پ_ج_ش".split("_"), weekStart: 6, months: "ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"), monthsShort: "ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"), ordinal: function(n) {
492
- return n;
491
+ var n = r(s), i = { name: "fa", weekdays: "یک‌شنبه_دوشنبه_سه‌شنبه_چهارشنبه_پنج‌شنبه_جمعه_شنبه".split("_"), weekdaysShort: "یک‌شنبه_دوشنبه_سه‌شنبه_چهارشنبه_پنج‌شنبه_جمعه_شنبه".split("_"), weekdaysMin: "ی_د_س_چ_پ_ج_ش".split("_"), weekStart: 6, months: "ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"), monthsShort: "ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"), ordinal: function(a) {
492
+ return a;
493
493
  }, formats: { LT: "HH:mm", LTS: "HH:mm:ss", L: "DD/MM/YYYY", LL: "D MMMM YYYY", LLL: "D MMMM YYYY HH:mm", LLLL: "dddd, D MMMM YYYY HH:mm" }, relativeTime: { future: "در %s", past: "%s پیش", s: "چند ثانیه", m: "یک دقیقه", mm: "%d دقیقه", h: "یک ساعت", hh: "%d ساعت", d: "یک روز", dd: "%d روز", M: "یک ماه", MM: "%d ماه", y: "یک سال", yy: "%d سال" } };
494
- return a.default.locale(i, null, !0), i;
494
+ return n.default.locale(i, null, !0), i;
495
495
  });
496
- }(de)), de.exports;
496
+ }(ye)), ye.exports;
497
497
  }
498
- var It = St();
499
- const wt = /* @__PURE__ */ pe(It);
500
- function oe(t, e) {
501
- return bt(t) || At(t, e) || Dt();
498
+ var Ht = Bt();
499
+ const qt = /* @__PURE__ */ _e(Ht);
500
+ function he(t, e) {
501
+ return zt(t) || Wt(t, e) || Jt();
502
502
  }
503
- function bt(t) {
503
+ function zt(t) {
504
504
  if (Array.isArray(t)) return t;
505
505
  }
506
- function At(t, e) {
507
- var s = [], r = !0, a = !1, i = void 0;
506
+ function Wt(t, e) {
507
+ var s = [], r = !0, n = !1, i = void 0;
508
508
  try {
509
- for (var n = t[Symbol.iterator](), h; !(r = (h = n.next()).done) && (s.push(h.value), !(e && s.length === e)); r = !0)
509
+ for (var a = t[Symbol.iterator](), l; !(r = (l = a.next()).done) && (s.push(l.value), !(e && s.length === e)); r = !0)
510
510
  ;
511
- } catch (c) {
512
- a = !0, i = c;
511
+ } catch (o) {
512
+ n = !0, i = o;
513
513
  } finally {
514
514
  try {
515
- !r && n.return != null && n.return();
515
+ !r && a.return != null && a.return();
516
516
  } finally {
517
- if (a) throw i;
517
+ if (n) throw i;
518
518
  }
519
519
  }
520
520
  return s;
521
521
  }
522
- function Dt() {
522
+ function Jt() {
523
523
  throw new TypeError("Invalid attempt to destructure non-iterable instance");
524
524
  }
525
- function He(t, e, s) {
525
+ function ct(t, e, s) {
526
526
  e <= 2 && (t -= 1, e += 12);
527
- var r = Math.floor(t / 100), a = 2 - r + Math.floor(r / 4), i = Math.floor(365.25 * (t + 4716)) + Math.floor(30.6001 * (e + 1)) + s + a - 1524.5;
527
+ var r = Math.floor(t / 100), n = 2 - r + Math.floor(r / 4), i = Math.floor(365.25 * (t + 4716)) + Math.floor(30.6001 * (e + 1)) + s + n - 1524.5;
528
528
  return i;
529
529
  }
530
- function Rt(t) {
530
+ function Gt(t) {
531
531
  t = t + 0.5;
532
532
  var e = Math.floor(t), s = t - e, r = e;
533
533
  if (e >= 2299161) {
534
- var a = Math.floor((e - 186721625e-2) / 36524.25);
535
- r = e + 1 + a - Math.floor(a / 4);
534
+ var n = Math.floor((e - 186721625e-2) / 36524.25);
535
+ r = e + 1 + n - Math.floor(n / 4);
536
536
  }
537
- var i = r + 1524, n = Math.floor((i - 122.1) / 365.25), h = Math.floor(365.25 * n), c = Math.floor((i - h) / 30.6001), g = i - h - Math.floor(30.6001 * c) + s, f = c < 14 ? c - 1 : c - 13, u = f > 2 ? n - 4716 : n - 4715;
538
- return Ct(u, f, g);
537
+ var i = r + 1524, a = Math.floor((i - 122.1) / 365.25), l = Math.floor(365.25 * a), o = Math.floor((i - l) / 30.6001), c = i - l - Math.floor(30.6001 * o) + s, f = o < 14 ? o - 1 : o - 13, d = f > 2 ? a - 4716 : a - 4715;
538
+ return Xt(d, f, c);
539
539
  }
540
- function _t(t) {
540
+ function Kt(t) {
541
541
  t = t + 0.5;
542
542
  var e = Math.floor(t), s = t - e, r = e;
543
543
  if (e >= 2299161) {
544
- var a = Math.floor((e - 186721625e-2) / 36524.25);
545
- r = e + 1 + a - Math.floor(a / 4);
544
+ var n = Math.floor((e - 186721625e-2) / 36524.25);
545
+ r = e + 1 + n - Math.floor(n / 4);
546
546
  }
547
- var i = r + 1524, n = Math.floor((i - 122.1) / 365.25), h = Math.floor(365.25 * n), c = Math.floor((i - h) / 30.6001), g = i - h - Math.floor(30.6001 * c) + s, f = c < 14 ? c - 1 : c - 13, u = f > 2 ? n - 4716 : n - 4715;
548
- return [Math.floor(u), Math.floor(f), Math.floor(g)];
547
+ var i = r + 1524, a = Math.floor((i - 122.1) / 365.25), l = Math.floor(365.25 * a), o = Math.floor((i - l) / 30.6001), c = i - l - Math.floor(30.6001 * o) + s, f = o < 14 ? o - 1 : o - 13, d = f > 2 ? a - 4716 : a - 4715;
548
+ return [Math.floor(d), Math.floor(f), Math.floor(c)];
549
549
  }
550
- function Mt(t, e, s) {
551
- var r = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], a = [31, 31, 31, 31, 31, 31, 30, 30, 30, 30, 30, 29];
552
- function i(p, b) {
553
- return Math.floor(p / b);
550
+ function Zt(t, e, s) {
551
+ var r = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], n = [31, 31, 31, 31, 31, 31, 30, 30, 30, 30, 30, 29];
552
+ function i(m, b) {
553
+ return Math.floor(m / b);
554
554
  }
555
555
  t -= 979;
556
- for (var n = 365 * t + i(t, 33) * 8 + i(t % 33 + 3, 4), h = 0; h < e - 1; ++h)
557
- n += a[h];
558
- n += s - 1;
559
- var c = n + 79, g = 1600 + 400 * i(c, 146097);
560
- c = c % 146097;
556
+ for (var a = 365 * t + i(t, 33) * 8 + i(t % 33 + 3, 4), l = 0; l < e - 1; ++l)
557
+ a += n[l];
558
+ a += s - 1;
559
+ var o = a + 79, c = 1600 + 400 * i(o, 146097);
560
+ o = o % 146097;
561
561
  var f = !0;
562
- for (c >= 36525 && (c--, g += 100 * i(c, 36524), c = c % 36524, c >= 365 ? c++ : f = !1), g += 4 * i(c, 1461), c %= 1461, c >= 366 && (f = !1, c--, g += i(c, 365), c = c % 365), h = 0; c >= r[h] + (h == 1 && f); h++)
563
- c -= r[h] + (h == 1 && f);
564
- var u = h + 1, m = c + 1;
565
- return He(g, u, m);
566
- }
567
- function Ct(t, e, s) {
568
- var r = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], a = [31, 31, 31, 31, 31, 31, 30, 30, 30, 30, 30, 29];
569
- function i(H, q) {
570
- return Math.floor(H / q);
571
- }
572
- for (var n = t - 1600, h = e - 1, c = s - 1, g = 365 * n + i(n + 3, 4) - i(n + 99, 100) + i(n + 399, 400), f = 0; f < h; ++f)
573
- g += r[f];
574
- h > 1 && (t % 4 == 0 && t % 100 != 0 || t % 400 == 0) && g++, g += c;
575
- var u = g - 79, m = i(u, 12053);
576
- u %= 12053;
577
- var p = 979 + 33 * m + 4 * i(u, 1461);
578
- u %= 1461, u >= 366 && (p += i(u - 1, 365), u = (u - 1) % 365);
579
- for (var b = 0; b < 11 && u >= a[b]; ++b)
580
- u -= a[b];
581
- var B = b + 1, U = u + 1;
582
- return [p, B, U];
583
- }
584
- var le = {
562
+ for (o >= 36525 && (o--, c += 100 * i(o, 36524), o = o % 36524, o >= 365 ? o++ : f = !1), c += 4 * i(o, 1461), o %= 1461, o >= 366 && (f = !1, o--, c += i(o, 365), o = o % 365), l = 0; o >= r[l] + (l == 1 && f); l++)
563
+ o -= r[l] + (l == 1 && f);
564
+ var d = l + 1, v = o + 1;
565
+ return ct(c, d, v);
566
+ }
567
+ function Xt(t, e, s) {
568
+ var r = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], n = [31, 31, 31, 31, 31, 31, 30, 30, 30, 30, 30, 29];
569
+ function i(z, W) {
570
+ return Math.floor(z / W);
571
+ }
572
+ for (var a = t - 1600, l = e - 1, o = s - 1, c = 365 * a + i(a + 3, 4) - i(a + 99, 100) + i(a + 399, 400), f = 0; f < l; ++f)
573
+ c += r[f];
574
+ l > 1 && (t % 4 == 0 && t % 100 != 0 || t % 400 == 0) && c++, c += o;
575
+ var d = c - 79, v = i(d, 12053);
576
+ d %= 12053;
577
+ var m = 979 + 33 * v + 4 * i(d, 1461);
578
+ d %= 1461, d >= 366 && (m += i(d - 1, 365), d = (d - 1) % 365);
579
+ for (var b = 0; b < 11 && d >= n[b]; ++b)
580
+ d -= n[b];
581
+ var H = b + 1, q = d + 1;
582
+ return [m, H, q];
583
+ }
584
+ var de = {
585
585
  J: function(e, s, r) {
586
- return Rt(He(e, s, r));
586
+ return Gt(ct(e, s, r));
587
587
  },
588
588
  G: function(e, s, r) {
589
- return _t(Mt(e, s, r));
589
+ return Kt(Zt(e, s, r));
590
590
  }
591
- }, Lt = /^(\d{4})[-/]?(\d{1,2})[-/]?(\d{0,2})(.*)?$/, xt = /\[.*?\]|jY{2,4}|jM{1,4}|jD{1,2}|Y{2,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, we = "date", J = "day", T = "month", P = "year", Ve = "week", Ot = "YYYY-MM-DDTHH:mm:ssZ", Et = {
591
+ }, Qt = /^(\d{4})[-/]?(\d{1,2})[-/]?(\d{0,2})(.*)?$/, es = /\[.*?\]|jY{2,4}|jM{1,4}|jD{1,2}|Y{2,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, Oe = "date", K = "day", T = "month", $ = "year", et = "week", ts = "YYYY-MM-DDTHH:mm:ssZ", ss = {
592
592
  jmonths: "فروردین_اردیبهشت_خرداد_تیر_مرداد_شهریور_مهر_آبان_آذر_دی_بهمن_اسفند".split("_")
593
- }, kt = function(t, e, s) {
594
- var r = e.prototype, a = r.$utils(), i = function(l) {
595
- return l.$C === "jalali";
596
- }, n = a.prettyUnit || a.p, h = a.isUndefined || a.u, c = a.padStart || a.s, g = a.monthDiff || a.m, f = a.absFloor || a.a, u = function(l) {
593
+ }, rs = function(t, e, s) {
594
+ var r = e.prototype, n = r.$utils(), i = function(h) {
595
+ return h.$C === "jalali";
596
+ }, a = n.prettyUnit || n.p, l = n.isUndefined || n.u, o = n.padStart || n.s, c = n.monthDiff || n.m, f = n.absFloor || n.a, d = function(h) {
597
597
  return function() {
598
- var d = l.bind(this).apply(void 0, arguments);
599
- return d.$C = this.$C, d.isJalali() && d.InitJalali(), d;
598
+ var p = h.bind(this).apply(void 0, arguments);
599
+ return p.$C = this.$C, p.isJalali() && p.InitJalali(), p;
600
600
  };
601
601
  };
602
- r.startOf = u(r.startOf), r.endOf = u(r.endOf), r.add = u(r.add), r.subtract = u(r.subtract), r.set = u(r.set);
603
- var m = r.parse, p = r.init, b = r.startOf, B = r.$set, U = r.add, H = r.format, q = r.diff, ye = r.year, Se = r.month, re = r.date, Ie = r.daysInMonth, X = r.toArray;
604
- s.$C = "gregory", s.$fdow = 6, s.calendar = function(o) {
605
- return s.$C = o, s;
606
- }, r.calendar = function(o) {
607
- var l = this.clone();
608
- return l.$C = o, l.isJalali() && l.InitJalali(), l;
602
+ r.startOf = d(r.startOf), r.endOf = d(r.endOf), r.add = d(r.add), r.subtract = d(r.subtract), r.set = d(r.set);
603
+ var v = r.parse, m = r.init, b = r.startOf, H = r.$set, q = r.add, z = r.format, W = r.diff, Ce = r.year, Me = r.month, oe = r.date, Ee = r.daysInMonth, te = r.toArray;
604
+ s.$C = "gregory", s.$fdow = 6, s.calendar = function(u) {
605
+ return s.$C = u, s;
606
+ }, r.calendar = function(u) {
607
+ var h = this.clone();
608
+ return h.$C = u, h.isJalali() && h.InitJalali(), h;
609
609
  }, r.isJalali = function() {
610
610
  return i(this);
611
- }, s.en.jmonths = "Farvardin_Ordibehesht_Khordaad_Tir_Mordaad_Shahrivar_Mehr_Aabaan_Aazar_Dey_Bahman_Esfand".split("_"), s.locale("fa", Object.assign({}, wt, {}, Et), !0);
612
- var z = function(l, d) {
613
- return s(l, {
614
- locale: d.$L,
615
- utc: d.$u,
616
- calendar: d.$C
611
+ }, s.en.jmonths = "Farvardin_Ordibehesht_Khordaad_Tir_Mordaad_Shahrivar_Mehr_Aabaan_Aazar_Dey_Bahman_Esfand".split("_"), s.locale("fa", Object.assign({}, qt, {}, ss), !0);
612
+ var J = function(h, p) {
613
+ return s(h, {
614
+ locale: p.$L,
615
+ utc: p.$u,
616
+ calendar: p.$C
617
617
  });
618
618
  };
619
619
  r.init = function() {
620
- var o = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
621
- p.bind(this)(o), this.isJalali() && this.InitJalali();
622
- }, r.parse = function(o) {
623
- var l;
624
- if (this.$C = o.calendar || this.$C || s.$C, o.jalali && typeof o.date == "string" && /.*[^Z]$/i.test(o.date) && (l = o.date.match(Lt))) {
625
- var d = le.G(parseInt(l[1], 10), parseInt(l[2], 10), parseInt(l[3] || 1, 10)), S = oe(d, 3), w = S[0], y = S[1], A = S[2];
626
- o.date = "".concat(w, "-").concat(y, "-").concat(A).concat(l[4] || "");
627
- }
628
- return m.bind(this)(o);
620
+ var u = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
621
+ m.bind(this)(u), this.isJalali() && this.InitJalali();
622
+ }, r.parse = function(u) {
623
+ var h;
624
+ if (this.$C = u.calendar || this.$C || s.$C, u.jalali && typeof u.date == "string" && /.*[^Z]$/i.test(u.date) && (h = u.date.match(Qt))) {
625
+ var p = de.G(parseInt(h[1], 10), parseInt(h[2], 10), parseInt(h[3] || 1, 10)), w = he(p, 3), I = w[0], y = w[1], R = w[2];
626
+ u.date = "".concat(I, "-").concat(y, "-").concat(R).concat(h[4] || "");
627
+ }
628
+ return v.bind(this)(u);
629
629
  }, r.InitJalali = function() {
630
- var o = le.J(this.$y, this.$M + 1, this.$D), l = oe(o, 3), d = l[0], S = l[1], w = l[2];
631
- this.$jy = d, this.$jM = S - 1, this.$jD = w;
632
- }, r.startOf = function(o, l) {
633
- var d = this;
630
+ var u = de.J(this.$y, this.$M + 1, this.$D), h = he(u, 3), p = h[0], w = h[1], I = h[2];
631
+ this.$jy = p, this.$jM = w - 1, this.$jD = I;
632
+ }, r.startOf = function(u, h) {
633
+ var p = this;
634
634
  if (!i(this))
635
- return b.bind(this)(o, l);
636
- var S = h(l) ? !0 : l, w = n(o), y = function(G, E) {
637
- var L = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : d.$jy, ie = le.G(L, E + 1, G), k = oe(ie, 3), Q = k[0], ne = k[1], Qe = k[2], Oe = z(new Date(Q, ne - 1, Qe), d);
638
- return (S ? Oe : Oe.endOf(J)).$set("hour", 1);
639
- }, A = (this.$W + (7 - s.$fdow)) % 7;
640
- switch (w) {
641
- case P:
642
- return S ? y(1, 0) : y(0, 0, this.$jy + 1);
635
+ return b.bind(this)(u, h);
636
+ var w = l(h) ? !0 : h, I = a(u), y = function(G, k) {
637
+ var O = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : p.$jy, ce = de.G(O, k + 1, G), x = he(ce, 3), se = x[0], ue = x[1], Rt = x[2], Je = J(new Date(se, ue - 1, Rt), p);
638
+ return (w ? Je : Je.endOf(K)).$set("hour", 1);
639
+ }, R = (this.$W + (7 - s.$fdow)) % 7;
640
+ switch (I) {
641
+ case $:
642
+ return w ? y(1, 0) : y(0, 0, this.$jy + 1);
643
643
  case T:
644
- return S ? y(1, this.$jM) : y(0, (this.$jM + 1) % 12, this.$jy + parseInt((this.$jM + 1) / 12, 10));
645
- case Ve:
646
- return S ? y(this.$jD - A, this.$jM) : y(this.$jD + (6 - A), this.$jM);
644
+ return w ? y(1, this.$jM) : y(0, (this.$jM + 1) % 12, this.$jy + parseInt((this.$jM + 1) / 12, 10));
645
+ case et:
646
+ return w ? y(this.$jD - R, this.$jM) : y(this.$jD + (6 - R), this.$jM);
647
647
  default:
648
- return b.bind(this)(o, l);
648
+ return b.bind(this)(u, h);
649
649
  }
650
- }, r.$set = function(o, l) {
651
- var d = this;
650
+ }, r.$set = function(u, h) {
651
+ var p = this;
652
652
  if (!i(this))
653
- return B.bind(this)(o, l);
654
- var S = n(o), w = function(A, ae) {
655
- var G = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : d.$jy, E = le.G(G, ae + 1, A), L = oe(E, 3), ie = L[0], k = L[1], Q = L[2];
656
- return d.$d.setFullYear(ie), d.$d.setMonth(k - 1), d.$d.setDate(Q), d;
653
+ return H.bind(this)(u, h);
654
+ var w = a(u), I = function(R, le) {
655
+ var G = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : p.$jy, k = de.G(G, le + 1, R), O = he(k, 3), ce = O[0], x = O[1], se = O[2];
656
+ return p.$d.setFullYear(ce), p.$d.setMonth(x - 1), p.$d.setDate(se), p;
657
657
  };
658
- switch (S) {
659
- case we:
660
- case J:
661
- w(l, this.$jM);
658
+ switch (w) {
659
+ case Oe:
660
+ case K:
661
+ I(h, this.$jM);
662
662
  break;
663
663
  case T:
664
- w(this.$jD, l);
664
+ I(this.$jD, h);
665
665
  break;
666
- case P:
667
- w(this.$jD, this.$jM, l);
666
+ case $:
667
+ I(this.$jD, this.$jM, h);
668
668
  break;
669
669
  default:
670
- return B.bind(this)(o, l);
670
+ return H.bind(this)(u, h);
671
671
  }
672
672
  return this.init(), this;
673
- }, r.add = function(o, l) {
674
- var d = this;
673
+ }, r.add = function(u, h) {
674
+ var p = this;
675
675
  if (!i(this))
676
- return U.bind(this)(o, l);
677
- o = Number(o);
678
- var S = l && (l.length === 1 || l === "ms") ? l : n(l), w = function(k, Q) {
679
- var ne = d.set(we, 1).set(k, Q + o);
680
- return ne.set(we, Math.min(d.$jD, ne.daysInMonth()));
676
+ return q.bind(this)(u, h);
677
+ u = Number(u);
678
+ var w = h && (h.length === 1 || h === "ms") ? h : a(h), I = function(x, se) {
679
+ var ue = p.set(Oe, 1).set(x, se + u);
680
+ return ue.set(Oe, Math.min(p.$jD, ue.daysInMonth()));
681
681
  };
682
- if (["M", T].indexOf(S) > -1) {
683
- var y = this.$jM + o, A = y < 0 ? -Math.ceil(-y / 12) : Math.floor(y / 12), ae = this.$jD, G = this.set(J, 1).add(A, P).set(T, y - A * 12);
684
- return G.set(J, Math.min(G.daysInMonth(), ae));
685
- }
686
- if (["y", P].indexOf(S) > -1)
687
- return w(P, this.$jy);
688
- if (["d", J].indexOf(S) > -1) {
689
- var E = new Date(this.$d);
690
- return E.setDate(E.getDate() + o), z(E, this);
691
- }
692
- if (["w", Ve].indexOf(S) > -1) {
693
- var L = new Date(this.$d);
694
- return L.setDate(L.getDate() + o * 7), z(L, this);
695
- }
696
- return U.bind(this)(o, l);
697
- }, r.format = function(o, l) {
698
- var d = this;
682
+ if (["M", T].indexOf(w) > -1) {
683
+ var y = this.$jM + u, R = y < 0 ? -Math.ceil(-y / 12) : Math.floor(y / 12), le = this.$jD, G = this.set(K, 1).add(R, $).set(T, y - R * 12);
684
+ return G.set(K, Math.min(G.daysInMonth(), le));
685
+ }
686
+ if (["y", $].indexOf(w) > -1)
687
+ return I($, this.$jy);
688
+ if (["d", K].indexOf(w) > -1) {
689
+ var k = new Date(this.$d);
690
+ return k.setDate(k.getDate() + u), J(k, this);
691
+ }
692
+ if (["w", et].indexOf(w) > -1) {
693
+ var O = new Date(this.$d);
694
+ return O.setDate(O.getDate() + u * 7), J(O, this);
695
+ }
696
+ return q.bind(this)(u, h);
697
+ }, r.format = function(u, h) {
698
+ var p = this;
699
699
  if (!i(this))
700
- return H.bind(this)(o, l);
701
- var S = o || Ot, w = l || this.$locale(), y = w.jmonths;
702
- return S.replace(xt, function(A) {
703
- if (A.indexOf("[") > -1) return A.replace(/\[|\]/g, "");
704
- switch (A) {
700
+ return z.bind(this)(u, h);
701
+ var w = u || ts, I = h || this.$locale(), y = I.jmonths;
702
+ return w.replace(es, function(R) {
703
+ if (R.indexOf("[") > -1) return R.replace(/\[|\]/g, "");
704
+ switch (R) {
705
705
  case "YY":
706
- return String(d.$jy).slice(-2);
706
+ return String(p.$jy).slice(-2);
707
707
  case "YYYY":
708
- return String(d.$jy);
708
+ return String(p.$jy);
709
709
  case "M":
710
- return String(d.$jM + 1);
710
+ return String(p.$jM + 1);
711
711
  case "MM":
712
- return c(d.$jM + 1, 2, "0");
712
+ return o(p.$jM + 1, 2, "0");
713
713
  case "MMM":
714
- return y[d.$jM].slice(0, 3);
714
+ return y[p.$jM].slice(0, 3);
715
715
  case "MMMM":
716
- return y[d.$jM];
716
+ return y[p.$jM];
717
717
  case "D":
718
- return String(d.$jD);
718
+ return String(p.$jD);
719
719
  case "DD":
720
- return c(d.$jD, 2, "0");
720
+ return o(p.$jD, 2, "0");
721
721
  default:
722
- return H.bind(d)(A, l);
722
+ return z.bind(p)(R, h);
723
723
  }
724
724
  });
725
- }, r.diff = function(o, l, d) {
725
+ }, r.diff = function(u, h, p) {
726
726
  if (!i(this))
727
- return q.bind(this)(o, l, d);
728
- var S = n(l), w = s(o), y = g(this, w);
729
- switch (S) {
730
- case P:
727
+ return W.bind(this)(u, h, p);
728
+ var w = a(h), I = s(u), y = c(this, I);
729
+ switch (w) {
730
+ case $:
731
731
  y /= 12;
732
732
  break;
733
733
  case T:
734
734
  break;
735
735
  default:
736
- return q.bind(this)(o, l, d);
737
- }
738
- return d ? y : f(y);
739
- }, r.$g = function(o, l, d) {
740
- return h(o) ? this[l] : this.set(d, o);
741
- }, r.year = function(o) {
742
- return i(this) ? this.$g(o, "$jy", P) : ye.bind(this)(o);
743
- }, r.month = function(o) {
744
- return i(this) ? this.$g(o, "$jM", T) : Se.bind(this)(o);
745
- }, r.date = function(o) {
746
- return i(this) ? this.$g(o, "$jD", J) : re.bind(this)(o);
736
+ return W.bind(this)(u, h, p);
737
+ }
738
+ return p ? y : f(y);
739
+ }, r.$g = function(u, h, p) {
740
+ return l(u) ? this[h] : this.set(p, u);
741
+ }, r.year = function(u) {
742
+ return i(this) ? this.$g(u, "$jy", $) : Ce.bind(this)(u);
743
+ }, r.month = function(u) {
744
+ return i(this) ? this.$g(u, "$jM", T) : Me.bind(this)(u);
745
+ }, r.date = function(u) {
746
+ return i(this) ? this.$g(u, "$jD", K) : oe.bind(this)(u);
747
747
  }, r.daysInMonth = function() {
748
- return i(this) ? this.endOf(T).$jD : Ie.bind(this)();
749
- }, X && (r.toArray = function() {
750
- return i(this) ? [this.$jy, this.$jM, this.$jD, this.$H, this.$m, this.$s, this.$ms] : X.bind(this)();
748
+ return i(this) ? this.endOf(T).$jD : Ee.bind(this)();
749
+ }, te && (r.toArray = function() {
750
+ return i(this) ? [this.$jy, this.$jM, this.$jD, this.$H, this.$m, this.$s, this.$ms] : te.bind(this)();
751
751
  }), r.clone = function() {
752
- return z(this.toDate(), this);
752
+ return J(this.toDate(), this);
753
753
  };
754
754
  };
755
- const Tt = {
755
+ const ns = {
756
756
  ordinal(t) {
757
757
  },
758
758
  relativeTime: void 0,
@@ -774,20 +774,20 @@ const Tt = {
774
774
  LLLL: "dddd, D MMMM YYYY HH:mm"
775
775
  }
776
776
  };
777
- function Pt() {
778
- x.extend(kt), x.calendar("jalali"), x.extend(ct), x.extend(ft), x.extend(pt), x.locale(Tt, {}, !0);
777
+ function is() {
778
+ P.extend(rs), P.calendar("jalali"), P.extend(kt), P.extend(Vt), P.extend(Yt), P.locale(ns, {}, !0);
779
779
  }
780
- class ss {
780
+ class Gs {
781
781
  constructor(e, s) {
782
782
  this.start = e, this.end = s;
783
783
  }
784
784
  }
785
- class rs {
785
+ class Ks {
786
786
  constructor(e, s, r) {
787
787
  this.maxDate = e, this.minDate = s, this.disabledDates = r;
788
788
  }
789
789
  }
790
- class W {
790
+ class Z {
791
791
  static standardToUnix(e) {
792
792
  return Math.floor(new Date(e).getTime() / 1e3);
793
793
  }
@@ -795,79 +795,79 @@ class W {
795
795
  return new Date(e * 1e3).toString();
796
796
  }
797
797
  static getUnixEndOfDayInUnix(e) {
798
- return x.unix(e).endOf("day").unix();
798
+ return P.unix(e).endOf("day").unix();
799
799
  }
800
800
  }
801
- class fe {
801
+ class we {
802
802
  static isDateDisabled(e, s) {
803
803
  for (const r of e.disabledDates)
804
- if (fe.areUnixesInSameDate(r, s.unix())) return !0;
805
- return !!(e.maxDate && fe.isDateGraterOrSame(e.maxDate, s.unix()) || e.minDate && fe.isDateLowerOrSame(e.minDate, s.unix()));
804
+ if (we.areUnixesInSameDate(r, s.unix())) return !0;
805
+ return !!(e.maxDate && we.isDateGraterOrSame(e.maxDate, s.unix()) || e.minDate && we.isDateLowerOrSame(e.minDate, s.unix()));
806
806
  }
807
807
  static areUnixesInSameDate(e, s) {
808
- return W.getUnixEndOfDayInUnix(e) === W.getUnixEndOfDayInUnix(s);
808
+ return Z.getUnixEndOfDayInUnix(e) === Z.getUnixEndOfDayInUnix(s);
809
809
  }
810
810
  static isDateGraterOrSame(e, s) {
811
- return W.getUnixEndOfDayInUnix(s) >= W.getUnixEndOfDayInUnix(e);
811
+ return Z.getUnixEndOfDayInUnix(s) >= Z.getUnixEndOfDayInUnix(e);
812
812
  }
813
813
  static isDateLowerOrSame(e, s) {
814
- return W.getUnixEndOfDayInUnix(s) <= W.getUnixEndOfDayInUnix(e);
814
+ return Z.getUnixEndOfDayInUnix(s) <= Z.getUnixEndOfDayInUnix(e);
815
815
  }
816
816
  }
817
- Pt();
818
- class _ {
817
+ is();
818
+ class C {
819
819
  static toCurrency(e, s) {
820
820
  return e.toLocaleString("en-US", s);
821
821
  }
822
822
  static toCurrencyWithDotSeparator(e) {
823
- return _.toCurrency(e).replaceAll(",", ".");
823
+ return C.toCurrency(e).replaceAll(",", ".");
824
824
  }
825
825
  static applyMask(e, s) {
826
- let r = "", a = 0, i = 0;
827
- for (; a < e.length; ) {
828
- if (e[a] === "#") {
826
+ let r = "", n = 0, i = 0;
827
+ for (; n < e.length; ) {
828
+ if (e[n] === "#") {
829
829
  if (i >= s.length)
830
830
  throw new Error("Value length does not match the format.");
831
831
  r += s[i], i++;
832
832
  } else
833
- r += e[a];
834
- a++;
833
+ r += e[n];
834
+ n++;
835
835
  }
836
836
  if (i !== s.length)
837
837
  throw new Error("Value length does not match the format.");
838
838
  return r;
839
839
  }
840
840
  static applyBankCardMask(e) {
841
- return _.applyMask(be.BankCard, String(e));
841
+ return C.applyMask(Pe.BankCard, String(e));
842
842
  }
843
843
  static applyIbanMask(e) {
844
- return _.applyMask(be.Iban, String(e));
844
+ return C.applyMask(Pe.Iban, String(e));
845
845
  }
846
846
  static toEnglishDigits(e) {
847
- const s = ["۱", "۲", "۳", "۴", "۵", "۶", "۷", "۸", "۹", "۰"], r = ["١", "٢", "٣", "٤", "٥", "٦", "٧", "٨", "٩", "٠"], a = ["1", "2", "3", "4", "5", "6", "7", "8", "9", "0"];
847
+ const s = ["۱", "۲", "۳", "۴", "۵", "۶", "۷", "۸", "۹", "۰"], r = ["١", "٢", "٣", "٤", "٥", "٦", "٧", "٨", "٩", "٠"], n = ["1", "2", "3", "4", "5", "6", "7", "8", "9", "0"];
848
848
  return e.split("").map(
849
- (i) => a[s.indexOf(i)] || a[r.indexOf(i)] || i
849
+ (i) => n[s.indexOf(i)] || n[r.indexOf(i)] || i
850
850
  ).join("");
851
851
  }
852
852
  static mapUnixToDate(e, s) {
853
- return x(new Date(e)).subtract(1, "day").format(s);
853
+ return P(new Date(e)).subtract(1, "day").format(s);
854
854
  }
855
855
  }
856
- var v = /* @__PURE__ */ ((t) => (t.FetchList = "fetchList", t.AutoRefresh = "autoRefresh", t.FetchItem = "fetchItem", t.FetchLastItems = "fetchLastItems", t.FetchPreviousItems = "fetchPreviousItems", t.Create = "CREATE", t.Update = "UPDATE", t.Delete = "DELETE", t.Search = "SEARCH", t.Sort = "SORT", t.Success = "SUCCESS", t.Error = "ERROR", t.Idle = "IDLE", t))(v || {}), $ = /* @__PURE__ */ ((t) => (t.Width = "width", t.Height = "height", t[t.DefaultWidth = 500] = "DefaultWidth", t[t.DefaultHeight = 350] = "DefaultHeight", t[t.MinimalAvailableSize = 0] = "MinimalAvailableSize", t))($ || {}), O = /* @__PURE__ */ ((t) => (t.ASC = "ASC", t.DESC = "DESC", t))(O || {}), $t = /* @__PURE__ */ ((t) => (t.ASC = "ascend", t.DESC = "descend", t))($t || {}), Re = /* @__PURE__ */ ((t) => (t.Left = "left", t.Right = "right", t.Center = "center", t))(Re || {}), _e = /* @__PURE__ */ ((t) => (t.Text = "text", t))(_e || {}), Me = /* @__PURE__ */ ((t) => (t.Text = "text", t.ACTION = "action", t.Tag = "tag", t.Iban = "iban", t.BankCard = "bankCard", t.Symbol = "symbol", t.TradeDetail = "tradeDetail", t.SymbolPrice = "symbolPrice", t.TradeSymbol = "tradeSymbol", t.Price = "price", t.DynamicCurrencyPrice = "dynamicCurrencyPrice", t.TradeDate = "tradeDate", t.RequestResponseIdentity = "requestResponseIdentity", t.Image = "image", t))(Me || {}), qe = /* @__PURE__ */ ((t) => (t[t.MINIMAL_LOADABLE_HEADER_COUNT = 0] = "MINIMAL_LOADABLE_HEADER_COUNT", t[t.DEFAULT_ITEM_COUNT_PER_PAGE = 20] = "DEFAULT_ITEM_COUNT_PER_PAGE", t.PAGINATION_POSITION = "bottomCenter", t))(qe || {}), Ce = /* @__PURE__ */ ((t) => (t.FontFamily = "IRANSansX", t))(Ce || {}), te = /* @__PURE__ */ ((t) => (t.Open = "open", t.Close = "close", t))(te || {}), Vt = /* @__PURE__ */ ((t) => (t[t.NotFound = 404] = "NotFound", t[t.Unauthorized = 401] = "Unauthorized", t[t.ServerError = 500] = "ServerError", t))(Vt || {}), me = /* @__PURE__ */ ((t) => (t[t.Invalid = 0] = "Invalid", t[t.Valid = 1] = "Valid", t))(me || {}), Y = /* @__PURE__ */ ((t) => (t.Theme = "theme", t.AccessList = "accessList", t.Token = "token", t.SSO_ACCESS_LIST = "ssoAccessList", t))(Y || {}), Ce = /* @__PURE__ */ ((t) => (t.Light = "light", t.Dark = "dark", t))(Ce || {}), Le = /* @__PURE__ */ ((t) => (t.Dialog = "dialog", t.Drawer = "drawer", t.Module = "module", t.Toast = "toast", t))(Le || {}), Ft = /* @__PURE__ */ ((t) => (t.USDT = "USDT", t))(Ft || {});
857
- class Z {
856
+ var g = /* @__PURE__ */ ((t) => (t.FetchList = "fetchList", t.AutoRefresh = "autoRefresh", t.FetchItem = "fetchItem", t.FetchLastItems = "fetchLastItems", t.FetchPreviousItems = "fetchPreviousItems", t.Create = "CREATE", t.Update = "UPDATE", t.Delete = "DELETE", t.Search = "SEARCH", t.Sort = "SORT", t.Success = "SUCCESS", t.Error = "ERROR", t.Idle = "IDLE", t))(g || {}), V = /* @__PURE__ */ ((t) => (t.Width = "width", t.Height = "height", t[t.DefaultWidth = 500] = "DefaultWidth", t[t.DefaultHeight = 350] = "DefaultHeight", t[t.MinimalAvailableSize = 0] = "MinimalAvailableSize", t))(V || {}), L = /* @__PURE__ */ ((t) => (t.ASC = "ASC", t.DESC = "DESC", t))(L || {}), as = /* @__PURE__ */ ((t) => (t.ASC = "ascend", t.DESC = "descend", t))(as || {}), je = /* @__PURE__ */ ((t) => (t.Left = "left", t.Right = "right", t.Center = "center", t))(je || {}), Fe = /* @__PURE__ */ ((t) => (t.Text = "text", t))(Fe || {}), Ye = /* @__PURE__ */ ((t) => (t.Text = "text", t.ACTION = "action", t.Tag = "tag", t.Iban = "iban", t.BankCard = "bankCard", t.Symbol = "symbol", t.TradeDetail = "tradeDetail", t.SymbolPrice = "symbolPrice", t.TradeSymbol = "tradeSymbol", t.Price = "price", t.DynamicCurrencyPrice = "dynamicCurrencyPrice", t.TradeDate = "tradeDate", t.RequestResponseIdentity = "requestResponseIdentity", t.Image = "image", t))(Ye || {}), ut = /* @__PURE__ */ ((t) => (t[t.MINIMAL_LOADABLE_HEADER_COUNT = 0] = "MINIMAL_LOADABLE_HEADER_COUNT", t[t.DEFAULT_ITEM_COUNT_PER_PAGE = 20] = "DEFAULT_ITEM_COUNT_PER_PAGE", t.PAGINATION_POSITION = "bottomCenter", t))(ut || {}), Ue = /* @__PURE__ */ ((t) => (t.FontFamily = "IRANSansX", t))(Ue || {}), ne = /* @__PURE__ */ ((t) => (t.Open = "open", t.Close = "close", t))(ne || {}), os = /* @__PURE__ */ ((t) => (t[t.NotFound = 404] = "NotFound", t[t.Unauthorized = 401] = "Unauthorized", t[t.ServerError = 500] = "ServerError", t))(os || {}), Se = /* @__PURE__ */ ((t) => (t[t.Invalid = 0] = "Invalid", t[t.Valid = 1] = "Valid", t))(Se || {}), U = /* @__PURE__ */ ((t) => (t.Theme = "theme", t.AccessList = "accessList", t.Token = "token", t.SSO_ACCESS_LIST = "ssoAccessList", t))(U || {}), Ue = /* @__PURE__ */ ((t) => (t.Light = "light", t.Dark = "dark", t))(Ue || {}), Be = /* @__PURE__ */ ((t) => (t.Dialog = "dialog", t.Drawer = "drawer", t.Module = "module", t.Toast = "toast", t))(Be || {}), ls = /* @__PURE__ */ ((t) => (t.USDT = "USDT", t))(ls || {});
857
+ class Q {
858
858
  static getBankImageBaseOnCardInfo(e, s) {
859
- return e === void 0 ? "/img/banks/shetab.png" : s === "IBAN" ? (e = _.toEnglishDigits(
859
+ return e === void 0 ? "/img/banks/shetab.png" : s === "IBAN" ? (e = C.toEnglishDigits(
860
860
  e.replace(/IR/g, "").split(" ").join("")
861
- ), `/img/banks/${Z.iban(e).english}.png`) : (e = _.toEnglishDigits(
861
+ ), `/img/banks/${Q.iban(e).english}.png`) : (e = C.toEnglishDigits(
862
862
  e.replace(/ /g, "")
863
- ), `/img/banks/${Z.card(e).english}.png`);
863
+ ), `/img/banks/${Q.card(e).english}.png`);
864
864
  }
865
865
  static card(e) {
866
866
  const s = { persian: "نامشخص", english: "shetab" };
867
867
  if (e == null) return s;
868
868
  e = e.substring(0, 6);
869
869
  try {
870
- const r = rt.find((a) => Object.keys(a)[0] === e);
870
+ const r = Ct.find((n) => Object.keys(n)[0] === e);
871
871
  return r === void 0 ? s : Object.values(r)[0];
872
872
  } catch {
873
873
  return s;
@@ -880,7 +880,7 @@ class Z {
880
880
  if (e == null) return s;
881
881
  e = e.substring(2, 5);
882
882
  try {
883
- const r = at.find((a) => Object.keys(a)[0] === e);
883
+ const r = Mt.find((n) => Object.keys(n)[0] === e);
884
884
  return r === void 0 ? s : Object.values(r)[0];
885
885
  } catch {
886
886
  return s;
@@ -889,7 +889,7 @@ class Z {
889
889
  static async copyValueToClipboard(e) {
890
890
  await navigator.clipboard.writeText(String(e));
891
891
  }
892
- static downloadBlob(e, s = Z.extractFileNameFromHeader(e)) {
892
+ static downloadBlob(e, s = Q.extractFileNameFromHeader(e)) {
893
893
  const r = document.createElement("a");
894
894
  r.href = URL.createObjectURL(e.data), r.download = s, r.dispatchEvent(
895
895
  new MouseEvent("click", {
@@ -900,10 +900,10 @@ class Z {
900
900
  ), r.remove();
901
901
  }
902
902
  static extractFileNameFromHeader(e) {
903
- var r, a, i, n;
904
- return ((n = (r = e.headers["content-disposition"]) == null ? void 0 : r.split("filename=")[1]) == null ? void 0 : n.slice(
903
+ var r, n, i, a;
904
+ return ((a = (r = e.headers["content-disposition"]) == null ? void 0 : r.split("filename=")[1]) == null ? void 0 : a.slice(
905
905
  1,
906
- ((i = (a = e.headers["content-disposition"]) == null ? void 0 : a.split("filename=")) == null ? void 0 : i[1].length) - 1
906
+ ((i = (n = e.headers["content-disposition"]) == null ? void 0 : n.split("filename=")) == null ? void 0 : i[1].length) - 1
907
907
  )) || "Saraf-File";
908
908
  }
909
909
  static removeSpacesFromString(e) {
@@ -912,11 +912,11 @@ class Z {
912
912
  ""
913
913
  );
914
914
  }
915
- static isArraySorted(e, s = (a) => a, r = O.ASC) {
916
- return e.every((a, i) => e.length - 1 === i ? !0 : r === O.ASC ? s(a) <= s(e[i + 1]) : s(a) >= s(e[i + 1]));
915
+ static isArraySorted(e, s = (n) => n, r = L.ASC) {
916
+ return e.every((n, i) => e.length - 1 === i ? !0 : r === L.ASC ? s(n) <= s(e[i + 1]) : s(n) >= s(e[i + 1]));
917
917
  }
918
918
  }
919
- const V = class V {
919
+ const j = class j {
920
920
  constructor() {
921
921
  this.availableAccesses = /* @__PURE__ */ new Set();
922
922
  }
@@ -926,7 +926,7 @@ const V = class V {
926
926
  this.availableAccesses.add(s);
927
927
  }
928
928
  setAccessListToStorage(e) {
929
- localStorage.setItem(Y.AccessList, JSON.stringify(e));
929
+ localStorage.setItem(U.AccessList, JSON.stringify(e));
930
930
  }
931
931
  everyAccess(e) {
932
932
  return e.every((s) => this.availableAccesses.has(s));
@@ -935,19 +935,19 @@ const V = class V {
935
935
  return e.some((s) => this.availableAccesses.has(s));
936
936
  }
937
937
  clearAvailableAccesses() {
938
- this.availableAccesses.clear(), localStorage.removeItem(Y.AccessList);
938
+ this.availableAccesses.clear(), localStorage.removeItem(U.AccessList);
939
939
  }
940
940
  initialize() {
941
- const e = localStorage.getItem(Y.AccessList);
941
+ const e = localStorage.getItem(U.AccessList);
942
942
  e !== null && this.setAvailableAccesses(JSON.parse(e));
943
943
  }
944
944
  static GetInstance() {
945
- return V.Instance || (V.Instance = new V()), V.Instance;
945
+ return j.Instance || (j.Instance = new j()), j.Instance;
946
946
  }
947
947
  };
948
- V.Instance = null;
949
- let se = V;
950
- class ze {
948
+ j.Instance = null;
949
+ let ae = j;
950
+ class ht {
951
951
  constructor() {
952
952
  this.mounted = (e, s) => {
953
953
  this.checkAccess(e, s.value);
@@ -955,15 +955,15 @@ class ze {
955
955
  this.checkAccess(e, s.value);
956
956
  }, this.checkAccess = (e, s) => {
957
957
  this.hasAccess(s) || e.remove();
958
- }, this.accessService = se.GetInstance();
958
+ }, this.accessService = ae.GetInstance();
959
959
  }
960
960
  }
961
- class as extends ze {
961
+ class Zs extends ht {
962
962
  hasAccess(e) {
963
963
  return this.accessService.everyAccess(e);
964
964
  }
965
965
  }
966
- class is extends ze {
966
+ class Xs extends ht {
967
967
  hasAccess(e) {
968
968
  return this.accessService.someAccess(e);
969
969
  }
@@ -981,10 +981,10 @@ const F = class F {
981
981
  this.setAccessLevelsToStorage(e);
982
982
  }
983
983
  setAccessLevelsToStorage(e) {
984
- localStorage.setItem(Y.SSO_ACCESS_LIST, JSON.stringify(e));
984
+ localStorage.setItem(U.SSO_ACCESS_LIST, JSON.stringify(e));
985
985
  }
986
986
  getAccessLevelsFromStorage() {
987
- let e = localStorage.getItem(Y.SSO_ACCESS_LIST);
987
+ let e = localStorage.getItem(U.SSO_ACCESS_LIST);
988
988
  return e !== null ? JSON.parse(e) : e;
989
989
  }
990
990
  getAccessLevelsOfScope(e) {
@@ -998,27 +998,27 @@ const F = class F {
998
998
  }
999
999
  everyAccess(e, s) {
1000
1000
  const r = this.getAccessLevelsOfScope(e);
1001
- return r ? s.every((a) => r.has(a)) : !1;
1001
+ return r ? s.every((n) => r.has(n)) : !1;
1002
1002
  }
1003
1003
  someAccess(e, s) {
1004
1004
  const r = this.getAccessLevelsOfScope(e);
1005
- return r ? s.some((a) => r.has(a)) : !1;
1005
+ return r ? s.some((n) => r.has(n)) : !1;
1006
1006
  }
1007
1007
  hasScope(e) {
1008
1008
  return this._accessLevels.has(e);
1009
1009
  }
1010
1010
  clear() {
1011
- localStorage.removeItem(Y.SSO_ACCESS_LIST), this._accessLevels = /* @__PURE__ */ new Map();
1011
+ localStorage.removeItem(U.SSO_ACCESS_LIST), this._accessLevels = /* @__PURE__ */ new Map();
1012
1012
  }
1013
1013
  static GetInstance() {
1014
1014
  return F._instance || (F._instance = new F()), F._instance;
1015
1015
  }
1016
1016
  };
1017
1017
  F._instance = null;
1018
- let Ae = F;
1019
- class Ge {
1018
+ let Le = F;
1019
+ class dt {
1020
1020
  constructor() {
1021
- this._authorizationService = Ae.GetInstance(), this.mounted = this.mounted.bind(this), this.updated = this.updated.bind(this), this.hasAccess = this.hasAccess.bind(this), this.manageElement = this.manageElement.bind(this);
1021
+ this._authorizationService = Le.GetInstance(), this.mounted = this.mounted.bind(this), this.updated = this.updated.bind(this), this.hasAccess = this.hasAccess.bind(this), this.manageElement = this.manageElement.bind(this);
1022
1022
  }
1023
1023
  mounted(e, s, r) {
1024
1024
  this.manageElement(e, s.arg, s.modifiers);
@@ -1031,48 +1031,48 @@ class Ge {
1031
1031
  e.remove();
1032
1032
  return;
1033
1033
  }
1034
- const a = this.getAccessLevels(s, r);
1035
- this.hasAccess(s, a) || e.remove();
1034
+ const n = this.getAccessLevels(s, r);
1035
+ this.hasAccess(s, n) || e.remove();
1036
1036
  }
1037
1037
  getAccessLevels(e, s) {
1038
- var a;
1038
+ var n;
1039
1039
  let r = Object.keys(s);
1040
- return r.length || (r = Array.from(((a = this._authorizationService.getAccessLevelsOfScope(e)) == null ? void 0 : a.values()) ?? [])), r;
1040
+ return r.length || (r = Array.from(((n = this._authorizationService.getAccessLevelsOfScope(e)) == null ? void 0 : n.values()) ?? [])), r;
1041
1041
  }
1042
1042
  }
1043
- class ns extends Ge {
1043
+ class Qs extends dt {
1044
1044
  hasAccess(e, s) {
1045
1045
  return this._authorizationService.everyAccess(e, s);
1046
1046
  }
1047
1047
  }
1048
- class os extends Ge {
1048
+ class er extends dt {
1049
1049
  hasAccess(e, s) {
1050
1050
  return this._authorizationService.someAccess(e, s);
1051
1051
  }
1052
1052
  }
1053
- class jt {
1053
+ class cs {
1054
1054
  constructor() {
1055
1055
  this.value = null, this.initialValue = null, this.name = "", this.isValid = !1, this.isBlurSensitive = !1, this.isRequired = !1, this.isIncludeInRequestBody = !0, this.isChangeSensitive = !1, this.notValidMessage = "", this.isEmptySensitive = !0, this.hasCustomValidationCheck = !1, this.shouldRemoveValidationMessageOnInteract = !1;
1056
1056
  }
1057
1057
  }
1058
- function ls(t) {
1058
+ function tr(t) {
1059
1059
  return t === 1;
1060
1060
  }
1061
- function cs(t, e) {
1061
+ function sr(t, e) {
1062
1062
  return t - 1 === e;
1063
1063
  }
1064
- function Yt(t) {
1064
+ function us(t) {
1065
1065
  return String(t).length === 0 || t === null || t === void 0;
1066
1066
  }
1067
- function us(t) {
1067
+ function rr(t) {
1068
1068
  t();
1069
1069
  }
1070
- class hs {
1070
+ class nr {
1071
1071
  constructor(e, s) {
1072
- this.initialData = null, this.data = new jt(), this._validators = [], this._id = Math.random(), this.data.value = s, this.data.name = e, this.shouldRunValidation() && this.runValidation(!0);
1072
+ this.initialData = null, this.data = new cs(), this._validators = [], this._id = Math.random(), this.data.value = s, this.data.name = e, this.shouldRunValidation() && this.runValidation(!0);
1073
1073
  }
1074
1074
  shouldRunValidation() {
1075
- return this.data.hasCustomValidationCheck ? !1 : this.data.isRequired ? !0 : !Yt(this.data.value);
1075
+ return this.data.hasCustomValidationCheck ? !1 : this.data.isRequired ? !0 : !us(this.data.value);
1076
1076
  }
1077
1077
  async runValidation(e = !1) {
1078
1078
  for (const s of this._validators) {
@@ -1091,13 +1091,13 @@ class hs {
1091
1091
  this.data.isValid = !0, this.setNotValidMessage("");
1092
1092
  }
1093
1093
  reset() {
1094
- this.initialData ? this.data = structuredClone(Ee(this.initialData)) : console.warn(
1094
+ this.initialData ? this.data = structuredClone(Ge(this.initialData)) : console.warn(
1095
1095
  "The " + this.data.name + `input control has no initial data,
1096
1096
  the initial data will be available after calling the [markAsInitial] method on this instance`
1097
1097
  );
1098
1098
  }
1099
1099
  markAsInitial() {
1100
- this.initialData = structuredClone(Ee(this.data));
1100
+ this.initialData = structuredClone(Ge(this.data));
1101
1101
  }
1102
1102
  setValidators(e) {
1103
1103
  this._validators = e;
@@ -1179,7 +1179,7 @@ class hs {
1179
1179
  return this.data.value;
1180
1180
  }
1181
1181
  }
1182
- class ds {
1182
+ class ir {
1183
1183
  constructor(e) {
1184
1184
  this._inputControl = e;
1185
1185
  }
@@ -1214,7 +1214,7 @@ class ds {
1214
1214
  return this._inputControl;
1215
1215
  }
1216
1216
  }
1217
- class fs {
1217
+ class ar {
1218
1218
  constructor() {
1219
1219
  this.mounted = (e, s) => {
1220
1220
  s.value && s.value.getIsBlurSensitive() && (e.addEventListener("click", this.handleFocus.bind(this, s.value)), e.addEventListener(
@@ -1236,7 +1236,7 @@ class fs {
1236
1236
  e.value || e.getIsEmptySensitive() || e.setNotValidMessage("");
1237
1237
  }
1238
1238
  }
1239
- class ms {
1239
+ class or {
1240
1240
  constructor() {
1241
1241
  this._inputControls = /* @__PURE__ */ new Map(), this._isValid = !1, this._id = Math.random();
1242
1242
  }
@@ -1291,14 +1291,14 @@ class ms {
1291
1291
  return this._id;
1292
1292
  }
1293
1293
  }
1294
- function vs(t, e = !1) {
1295
- const s = Be(t), r = M(
1296
- me.Invalid
1294
+ function lr(t, e = !1) {
1295
+ const s = ot(t), r = M(
1296
+ Se.Invalid
1297
1297
  );
1298
- return et(
1298
+ return Dt(
1299
1299
  () => s.getInputControlsAsArray(),
1300
1300
  () => {
1301
- e || (s.runValidation(), s.getIsValid() ? r.value = me.Valid : r.value = me.Invalid);
1301
+ e || (s.runValidation(), s.getIsValid() ? r.value = Se.Valid : r.value = Se.Invalid);
1302
1302
  },
1303
1303
  {
1304
1304
  immediate: !0,
@@ -1309,7 +1309,7 @@ function vs(t, e = !1) {
1309
1309
  validationStatus: r
1310
1310
  };
1311
1311
  }
1312
- class Je {
1312
+ class ft {
1313
1313
  constructor(e) {
1314
1314
  this.timerId = null, this.setupInterval = this.setupInterval.bind(this), this.schedule = e;
1315
1315
  }
@@ -1325,64 +1325,64 @@ class Je {
1325
1325
  this.timerId && clearInterval(this.timerId);
1326
1326
  }
1327
1327
  }
1328
- const We = "150px", Ze = 2, gs = {
1328
+ const pt = "150px", vt = 2, cr = {
1329
1329
  path: "id",
1330
1330
  key: "id",
1331
1331
  title: "عملیات",
1332
- colspan: Ze,
1333
- width: We,
1334
- cellType: Me.ACTION,
1335
- align: Re.Center,
1336
- headerType: _e.Text,
1332
+ colspan: vt,
1333
+ width: pt,
1334
+ cellType: Ye.ACTION,
1335
+ align: je.Center,
1336
+ headerType: Fe.Text,
1337
1337
  accessLevel: null
1338
- }, Nt = {
1339
- width: We,
1340
- align: Re.Center,
1341
- headerType: _e.Text,
1342
- cellType: Me.Text,
1343
- colspan: Ze
1338
+ }, hs = {
1339
+ width: pt,
1340
+ align: je.Center,
1341
+ headerType: Fe.Text,
1342
+ cellType: Ye.Text,
1343
+ colspan: vt
1344
1344
  };
1345
- class xe {
1345
+ class He {
1346
1346
  constructor(e, s) {
1347
1347
  this.key = e, this.order = s;
1348
1348
  }
1349
1349
  }
1350
- class Fe {
1350
+ class tt {
1351
1351
  aSort(e, s) {
1352
- return e.sort((r, a) => {
1353
- const i = r[s] ?? r, n = a[s] ?? a;
1354
- if (typeof i == "string" && typeof n == "string")
1355
- return i.localeCompare(n);
1356
- if (typeof i == "number" && typeof n == "number")
1357
- return i - n;
1352
+ return e.sort((r, n) => {
1353
+ const i = r[s] ?? r, a = n[s] ?? n;
1354
+ if (typeof i == "string" && typeof a == "string")
1355
+ return i.localeCompare(a);
1356
+ if (typeof i == "number" && typeof a == "number")
1357
+ return i - a;
1358
1358
  throw new Error("Not supported data type");
1359
1359
  });
1360
1360
  }
1361
1361
  bSort(e, s) {
1362
- return e.sort((r, a) => {
1363
- const i = r[s] ?? r, n = a[s] ?? a;
1364
- if (typeof i == "string" && typeof n == "string")
1365
- return n.localeCompare(i);
1366
- if (typeof i == "number" && typeof n == "number")
1367
- return n - i;
1362
+ return e.sort((r, n) => {
1363
+ const i = r[s] ?? r, a = n[s] ?? n;
1364
+ if (typeof i == "string" && typeof a == "string")
1365
+ return a.localeCompare(i);
1366
+ if (typeof i == "number" && typeof a == "number")
1367
+ return a - i;
1368
1368
  throw new Error("Not supported data type");
1369
1369
  });
1370
1370
  }
1371
1371
  }
1372
- class ps {
1373
- arrayOfObjectSort(e, s, r, a = new Fe()) {
1374
- return r === O.ASC ? a.aSort(e, s) : a.bSort(e, s);
1372
+ class ur {
1373
+ arrayOfObjectSort(e, s, r, n = new tt()) {
1374
+ return r === L.ASC ? n.aSort(e, s) : n.bSort(e, s);
1375
1375
  }
1376
- arraySort(e, s, r = new Fe()) {
1377
- return s === O.ASC ? r.aSort(e) : r.bSort(e);
1376
+ arraySort(e, s, r = new tt()) {
1377
+ return s === L.ASC ? r.aSort(e) : r.bSort(e);
1378
1378
  }
1379
1379
  }
1380
- class Bt {
1380
+ class ds {
1381
1381
  constructor(e) {
1382
- this.currentPage = 1, this.currentPageSize = 20, this.currentSortDetail = new xe(
1382
+ this.currentPage = 1, this.currentPageSize = 20, this.currentSortDetail = new He(
1383
1383
  "id",
1384
- O.DESC
1385
- ), this.loadedRows = [], this.headerSchema = [], this.service = e, this.accessService = se.GetInstance();
1384
+ L.DESC
1385
+ ), this.loadedRows = [], this.headerSchema = [], this.service = e, this.accessService = ae.GetInstance();
1386
1386
  }
1387
1387
  addHeader(e) {
1388
1388
  this.headerSchema.push(e);
@@ -1420,11 +1420,11 @@ class Bt {
1420
1420
  return await this.service.paginate(e, s);
1421
1421
  }
1422
1422
  getItemCountPerPage() {
1423
- return qe.DEFAULT_ITEM_COUNT_PER_PAGE;
1423
+ return ut.DEFAULT_ITEM_COUNT_PER_PAGE;
1424
1424
  }
1425
1425
  isLoading() {
1426
1426
  const e = this.getLoadingStatuses();
1427
- return e.has(v.Search) || e.has(v.FetchList) || e.has(v.Sort) || e.has(v.FetchLastItems) || e.has(v.FetchPreviousItems);
1427
+ return e.has(g.Search) || e.has(g.FetchList) || e.has(g.Sort) || e.has(g.FetchLastItems) || e.has(g.FetchPreviousItems);
1428
1428
  }
1429
1429
  getLoadingStatuses() {
1430
1430
  return this.getData().loadingStatus;
@@ -1464,7 +1464,7 @@ class Bt {
1464
1464
  };
1465
1465
  }
1466
1466
  }
1467
- class D {
1467
+ class A {
1468
1468
  constructor(e) {
1469
1469
  this.observers = [], this.attach = this.attach.bind(this), this.detach = this.detach.bind(this), this.notify = this.notify.bind(this), this.notifyObject = this.notifyObject.bind(this), this.next = this.next.bind(this), this.getValue = this.getValue.bind(this), this.next(e);
1470
1470
  }
@@ -1488,9 +1488,9 @@ class D {
1488
1488
  return this._value;
1489
1489
  }
1490
1490
  }
1491
- class ys extends Bt {
1491
+ class hr extends ds {
1492
1492
  constructor(e) {
1493
- super(e), this.selectedRows = new D(/* @__PURE__ */ new Map()), this.rowSelect = this.rowSelect.bind(this), this.selectAll = this.selectAll.bind(this), this.isEveryRowSelected = this.isEveryRowSelected.bind(this), this.handlePagination = this.handlePagination.bind(this), this.clearAllSelectedItems = this.clearAllSelectedItems.bind(this), this.getSelectedRows = this.getSelectedRows.bind(this), this.getSelectedRowsAsArray = this.getSelectedRowsAsArray.bind(this), this.getSelectedRowIds = this.getSelectedRowIds.bind(this);
1493
+ super(e), this.selectedRows = new A(/* @__PURE__ */ new Map()), this.rowSelect = this.rowSelect.bind(this), this.selectAll = this.selectAll.bind(this), this.isEveryRowSelected = this.isEveryRowSelected.bind(this), this.handlePagination = this.handlePagination.bind(this), this.clearAllSelectedItems = this.clearAllSelectedItems.bind(this), this.getSelectedRows = this.getSelectedRows.bind(this), this.getSelectedRowsAsArray = this.getSelectedRowsAsArray.bind(this), this.getSelectedRowIds = this.getSelectedRowIds.bind(this);
1494
1494
  }
1495
1495
  rowSelect(e) {
1496
1496
  this.getSelectedRowsValue().has(e.id) ? (this.getSelectedRowsValue().delete(e.id), this.selectedRows.next(this.selectedRows.getValue())) : (this.selectedRows.getValue().set(e.id, e), this.selectedRows.next(this.selectedRows.getValue()));
@@ -1527,60 +1527,60 @@ class ys extends Bt {
1527
1527
  return this.selectedRows.getValue();
1528
1528
  }
1529
1529
  }
1530
- function Ss(t) {
1530
+ function dr(t) {
1531
1531
  return {
1532
- ...Nt,
1532
+ ...hs,
1533
1533
  ...t
1534
1534
  };
1535
1535
  }
1536
- function Is(t) {
1536
+ function fr(t) {
1537
1537
  return function(s, r) {
1538
1538
  s.constructor.prototype.headers || (s.constructor.prototype.headers = []), s.constructor.prototype.headers.push({ path: r, ...t });
1539
1539
  };
1540
1540
  }
1541
- function ws(t) {
1541
+ function pr(t) {
1542
1542
  return function(s) {
1543
1543
  async function r() {
1544
1544
  return s.prototype._table = this, s.prototype.headers;
1545
1545
  }
1546
- function a(h) {
1547
- const c = [], g = s.prototype.actions || [];
1548
- for (const f of g) {
1549
- if (!f.isAvailable(h)) continue;
1550
- const u = {
1551
- handler: f.handler.bind(h),
1546
+ function n(l) {
1547
+ const o = [], c = s.prototype.actions || [];
1548
+ for (const f of c) {
1549
+ if (!f.isAvailable(l)) continue;
1550
+ const d = {
1551
+ handler: f.handler.bind(l),
1552
1552
  accessLevel: f.accessLevel,
1553
1553
  actionName: f.actionName
1554
1554
  };
1555
- c.push(u);
1555
+ o.push(d);
1556
1556
  }
1557
- return c;
1557
+ return o;
1558
1558
  }
1559
- async function i(h) {
1560
- s.prototype.rowClick && await s.prototype.rowClick.call(h);
1559
+ async function i(l) {
1560
+ s.prototype.rowClick && await s.prototype.rowClick.call(l);
1561
1561
  }
1562
- async function n() {
1562
+ async function a() {
1563
1563
  s.prototype.tableDestroy && await s.prototype.tableDestroy();
1564
1564
  }
1565
- t.prototype.loadHeader = r, t.prototype.getActions = a, t.prototype.handleClick = i, t.prototype.onDestroy = n;
1565
+ t.prototype.loadHeader = r, t.prototype.getActions = n, t.prototype.handleClick = i, t.prototype.onDestroy = a;
1566
1566
  };
1567
1567
  }
1568
- function bs(t) {
1569
- return function(s, r, a) {
1570
- s.constructor.prototype.actions || (s.constructor.prototype.actions = []), t.handler = a.value, s.constructor.prototype.actions.push(t);
1568
+ function vr(t) {
1569
+ return function(s, r, n) {
1570
+ s.constructor.prototype.actions || (s.constructor.prototype.actions = []), t.handler = n.value, s.constructor.prototype.actions.push(t);
1571
1571
  };
1572
1572
  }
1573
- function As() {
1573
+ function gr() {
1574
1574
  return function(e, s, r) {
1575
1575
  e.constructor.prototype.tableDestroy = r.value;
1576
1576
  };
1577
1577
  }
1578
- function Ds() {
1578
+ function mr() {
1579
1579
  return function(e, s, r) {
1580
1580
  e.constructor.prototype.rowClick = r.value;
1581
1581
  };
1582
1582
  }
1583
- class Rs {
1583
+ class yr {
1584
1584
  constructor() {
1585
1585
  this.observers = [];
1586
1586
  }
@@ -1597,9 +1597,9 @@ class Rs {
1597
1597
  e.update(this);
1598
1598
  }
1599
1599
  }
1600
- class Ut {
1600
+ class fs {
1601
1601
  constructor(e) {
1602
- this.rows = new D([]), this.headerSchema = new D([]), this.currentPage = new D(1), this.currentPageSize = new D(20), this.totalItems = new D(0), this.currentSortDetail = new D(new xe("id", O.DESC)), this.scrollDetail = new D(null), this.isExpandable = new D(!1), this.tableSource = e, this.accessService = se.GetInstance();
1602
+ this.rows = new A([]), this.headerSchema = new A([]), this.currentPage = new A(1), this.currentPageSize = new A(20), this.totalItems = new A(0), this.currentSortDetail = new A(new He("id", L.DESC)), this.scrollDetail = new A(null), this.isExpandable = new A(!1), this.tableSource = e, this.accessService = ae.GetInstance();
1603
1603
  }
1604
1604
  async load() {
1605
1605
  this.rows.next(await this.tableSource.loadRows()), this.headerSchema.next(
@@ -1652,9 +1652,9 @@ class Ut {
1652
1652
  this.tableSource.onTableDestroy();
1653
1653
  }
1654
1654
  }
1655
- class _s extends Ut {
1655
+ class wr extends fs {
1656
1656
  constructor(e) {
1657
- super(e), this.selectedRows = new D(
1657
+ super(e), this.selectedRows = new A(
1658
1658
  /* @__PURE__ */ new Map()
1659
1659
  ), this.selectRow = this.selectRow.bind(this), this.selectAll = this.selectAll.bind(this), this.isEveryRowSelected = this.isEveryRowSelected.bind(this), this.clearAllSelectedItems = this.clearAllSelectedItems.bind(this), this.getSelectedRowsAsArray = this.getSelectedRowsAsArray.bind(this), this.getSelectedRowIds = this.getSelectedRowIds.bind(this);
1660
1660
  }
@@ -1685,7 +1685,7 @@ class _s extends Ut {
1685
1685
  return Array.from(this.selectedRows.getValue().keys());
1686
1686
  }
1687
1687
  }
1688
- class Ms {
1688
+ class Sr {
1689
1689
  constructor() {
1690
1690
  this.setCellComponentRegistry = this.setCellComponentRegistry.bind(this), this.getCellComponentRegistry = this.getCellComponentRegistry.bind(this);
1691
1691
  }
@@ -1696,7 +1696,7 @@ class Ms {
1696
1696
  return this.cellComponentRegistry;
1697
1697
  }
1698
1698
  }
1699
- class Cs {
1699
+ class Ir {
1700
1700
  constructor() {
1701
1701
  this.registeredComponents = /* @__PURE__ */ new Map();
1702
1702
  }
@@ -1707,12 +1707,12 @@ class Cs {
1707
1707
  return this.registeredComponents;
1708
1708
  }
1709
1709
  }
1710
- function Ls(t) {
1710
+ function br(t) {
1711
1711
  return function(s, r) {
1712
1712
  s.constructor.prototype.headers || (s.constructor.prototype.headers = []), s.constructor.prototype.headers.push({ path: r, ...t });
1713
1713
  };
1714
1714
  }
1715
- function xs(t) {
1715
+ function Rr(t) {
1716
1716
  return function(s) {
1717
1717
  async function r() {
1718
1718
  return s.prototype.headers || [];
@@ -1720,268 +1720,268 @@ function xs(t) {
1720
1720
  t.prototype.loadHeaderSchema = r;
1721
1721
  };
1722
1722
  }
1723
- function Ht() {
1723
+ function ps() {
1724
1724
  const t = M(
1725
1725
  /* @__PURE__ */ new Map()
1726
- ), e = M(0), s = M(null), r = I(() => Array.from(t.value.values()));
1727
- function a(m) {
1728
- e.value = m;
1726
+ ), e = M(0), s = M(null), r = S(() => Array.from(t.value.values()));
1727
+ function n(v) {
1728
+ e.value = v;
1729
1729
  }
1730
- function i(m) {
1731
- for (const p of m)
1732
- n(p);
1730
+ function i(v) {
1731
+ for (const m of v)
1732
+ a(m);
1733
1733
  }
1734
- function n(m) {
1735
- t.value.set(m.id, m);
1734
+ function a(v) {
1735
+ t.value.set(v.id, v);
1736
1736
  }
1737
- function h(m) {
1738
- return s.value = t.value.get(m) || null, s.value;
1737
+ function l(v) {
1738
+ return s.value = t.value.get(v) || null, s.value;
1739
1739
  }
1740
- function c(m) {
1741
- const p = h(m);
1742
- return p && t.value.delete(m), !!p;
1740
+ function o(v) {
1741
+ const m = l(v);
1742
+ return m && t.value.delete(v), !!m;
1743
1743
  }
1744
- function g() {
1744
+ function c() {
1745
1745
  t.value.clear();
1746
1746
  }
1747
- function f(m) {
1748
- s.value = m;
1747
+ function f(v) {
1748
+ s.value = v;
1749
1749
  }
1750
- function u() {
1750
+ function d() {
1751
1751
  s.value = null;
1752
1752
  }
1753
1753
  return {
1754
1754
  itemsAsArray: r,
1755
1755
  totalCount: e,
1756
1756
  currentItem: s,
1757
- setTotalCount: a,
1757
+ setTotalCount: n,
1758
1758
  addOrReplaceItems: i,
1759
- getById: h,
1760
- removeById: c,
1761
- clearItems: g,
1759
+ getById: l,
1760
+ removeById: o,
1761
+ clearItems: c,
1762
1762
  setCurrentItem: f,
1763
- clearCurrentItem: u
1763
+ clearCurrentItem: d
1764
1764
  };
1765
1765
  }
1766
- class qt {
1766
+ class vs {
1767
1767
  constructor() {
1768
- this.pageNumber = 1, this.itemCount = 20, this.sortDetail = new xe("id", O.DESC), this.filters = [];
1768
+ this.pageNumber = 1, this.itemCount = 20, this.sortDetail = new He("id", L.DESC), this.filters = [];
1769
1769
  }
1770
1770
  }
1771
- class Os {
1771
+ class Dr {
1772
1772
  constructor(e, s) {
1773
1773
  this.items = e, this.totalItems = s;
1774
1774
  }
1775
1775
  }
1776
- class Es {
1776
+ class Ar {
1777
1777
  constructor(e, s) {
1778
1778
  this.shouldKeepSync = e, this.intervalInMillisecond = s;
1779
1779
  }
1780
1780
  }
1781
- const je = new qt();
1782
- function zt() {
1783
- const t = M(structuredClone(je));
1781
+ const st = new vs();
1782
+ function gs() {
1783
+ const t = M(structuredClone(st));
1784
1784
  function e() {
1785
1785
  t.value.pageNumber = t.value.pageNumber + 1;
1786
1786
  }
1787
1787
  function s() {
1788
1788
  t.value.pageNumber = t.value.pageNumber - 1;
1789
1789
  }
1790
- function r(u) {
1791
- t.value.pageNumber = u;
1790
+ function r(d) {
1791
+ t.value.pageNumber = d;
1792
1792
  }
1793
- function a(u) {
1794
- t.value.itemCount = u;
1793
+ function n(d) {
1794
+ t.value.itemCount = d;
1795
1795
  }
1796
- function i(u) {
1797
- t.value.sortDetail.key = u.key, t.value.sortDetail.order = u.order;
1796
+ function i(d) {
1797
+ t.value.sortDetail.key = d.key, t.value.sortDetail.order = d.order;
1798
1798
  }
1799
- function n(u) {
1800
- for (const m in u)
1801
- h(m, u[m]);
1799
+ function a(d) {
1800
+ for (const v in d)
1801
+ l(v, d[v]);
1802
1802
  }
1803
- function h(u, m) {
1804
- const p = t.value.filters.findIndex(
1805
- (b) => b.key === u
1803
+ function l(d, v) {
1804
+ const m = t.value.filters.findIndex(
1805
+ (b) => b.key === d
1806
1806
  );
1807
- p > -1 ? t.value.filters[p].value = m : t.value.filters.push({ key: u, value: m });
1807
+ m > -1 ? t.value.filters[m].value = v : t.value.filters.push({ key: d, value: v });
1808
1808
  }
1809
- function c(u) {
1810
- let m = t.value.filters;
1811
- m = m.filter((p) => p.key !== u), t.value.filters = m;
1809
+ function o(d) {
1810
+ let v = t.value.filters;
1811
+ v = v.filter((m) => m.key !== d), t.value.filters = v;
1812
1812
  }
1813
- function g() {
1814
- const u = {
1813
+ function c() {
1814
+ const d = {
1815
1815
  page: t.value.pageNumber,
1816
1816
  count: t.value.itemCount
1817
1817
  };
1818
- t.value.sortDetail && (u.by = t.value.sortDetail.key, u.order = t.value.sortDetail.order);
1819
- for (const m of t.value.filters)
1820
- if (m.value)
1821
- if (typeof m.value == "string" || typeof m.value == "number")
1822
- u[m.key] = m.value;
1818
+ t.value.sortDetail && (d.by = t.value.sortDetail.key, d.order = t.value.sortDetail.order);
1819
+ for (const v of t.value.filters)
1820
+ if (v.value)
1821
+ if (typeof v.value == "string" || typeof v.value == "number")
1822
+ d[v.key] = v.value;
1823
1823
  else {
1824
- const p = JSON.stringify(m.value);
1825
- p !== "[]" && p !== "{}" && (u[m.key] = p);
1824
+ const m = JSON.stringify(v.value);
1825
+ m !== "[]" && m !== "{}" && (d[v.key] = m);
1826
1826
  }
1827
- return u;
1827
+ return d;
1828
1828
  }
1829
1829
  function f() {
1830
- t.value = structuredClone(je);
1830
+ t.value = structuredClone(st);
1831
1831
  }
1832
1832
  return {
1833
1833
  params: t,
1834
1834
  setNextPage: e,
1835
1835
  setPreventPage: s,
1836
1836
  setPageNumber: r,
1837
- setItemCount: a,
1837
+ setItemCount: n,
1838
1838
  setSortDetail: i,
1839
- setFilter: h,
1840
- removeFilter: c,
1841
- getRequestParams: g,
1839
+ setFilter: l,
1840
+ removeFilter: o,
1841
+ getRequestParams: c,
1842
1842
  clearParam: f,
1843
- setFiltersBaseOnRequestBody: n
1843
+ setFiltersBaseOnRequestBody: a
1844
1844
  };
1845
1845
  }
1846
- function Gt() {
1847
- const t = M(/* @__PURE__ */ new Set()), e = I(() => t.value.has(v.FetchList)), s = I(() => t.value.has(v.FetchItem)), r = I(() => t.value.has(v.FetchLastItems)), a = I(() => t.value.has(v.FetchPreviousItems)), i = I(() => t.value.has(v.Create)), n = I(() => t.value.has(v.Update)), h = I(() => t.value.has(v.Delete)), c = I(() => t.value.has(v.Search)), g = I(() => t.value.has(v.Sort));
1848
- function f(m) {
1849
- t.value.add(m);
1846
+ function ms() {
1847
+ const t = M(/* @__PURE__ */ new Set()), e = S(() => t.value.has(g.FetchList)), s = S(() => t.value.has(g.FetchItem)), r = S(() => t.value.has(g.FetchLastItems)), n = S(() => t.value.has(g.FetchPreviousItems)), i = S(() => t.value.has(g.Create)), a = S(() => t.value.has(g.Update)), l = S(() => t.value.has(g.Delete)), o = S(() => t.value.has(g.Search)), c = S(() => t.value.has(g.Sort));
1848
+ function f(v) {
1849
+ t.value.add(v);
1850
1850
  }
1851
- function u(m) {
1852
- t.value.delete(m);
1851
+ function d(v) {
1852
+ t.value.delete(v);
1853
1853
  }
1854
1854
  return {
1855
1855
  loadingStatus: t,
1856
1856
  isFetchingList: e,
1857
1857
  isFetchingItem: s,
1858
1858
  isFetchingLastItems: r,
1859
- isFetchingPreviousItems: a,
1859
+ isFetchingPreviousItems: n,
1860
1860
  isCreating: i,
1861
- isUpdating: n,
1862
- isDeleting: h,
1863
- isSearching: c,
1864
- isSorting: g,
1861
+ isUpdating: a,
1862
+ isDeleting: l,
1863
+ isSearching: o,
1864
+ isSorting: c,
1865
1865
  setStatus: f,
1866
- removeStatus: u
1866
+ removeStatus: d
1867
1867
  };
1868
1868
  }
1869
- function ks(t) {
1870
- const e = Ht(), s = zt(), r = Gt(), a = new Je({
1871
- runAction: async () => u(v.AutoRefresh)
1872
- }), i = I(() => {
1873
- const o = s.params.value.pageNumber, l = s.params.value.itemCount, d = o * l - l, S = o * l - 1, w = [];
1874
- for (let y = d; y <= S && e.itemsAsArray.value[y]; y++)
1875
- w.push(e.itemsAsArray.value[y]);
1876
- return w;
1877
- }), n = I(() => ({
1869
+ function _r(t) {
1870
+ const e = ps(), s = gs(), r = ms(), n = new ft({
1871
+ runAction: async () => d(g.AutoRefresh)
1872
+ }), i = S(() => {
1873
+ const u = s.params.value.pageNumber, h = s.params.value.itemCount, p = u * h - h, w = u * h - 1, I = [];
1874
+ for (let y = p; y <= w && e.itemsAsArray.value[y]; y++)
1875
+ I.push(e.itemsAsArray.value[y]);
1876
+ return I;
1877
+ }), a = S(() => ({
1878
1878
  totalItems: e.totalCount.value,
1879
1879
  currentPage: s.params.value.pageNumber,
1880
1880
  rows: e.itemsAsArray.value,
1881
1881
  loadingStatus: r.loadingStatus.value,
1882
1882
  currentPageItems: i.value
1883
- })), h = I(() => ({
1884
- getData: g,
1885
- sort: X,
1886
- paginate: re,
1887
- fetchRows: u
1888
- })), c = I(() => t.getSyncDetail());
1889
- function g() {
1890
- return n.value;
1891
- }
1892
- async function f(o) {
1893
- const l = await t.fetchList(o);
1894
- return e.clearItems(), e.addOrReplaceItems(l.items), e.setTotalCount(l.totalItems), l;
1895
- }
1896
- async function u(o = v.FetchList) {
1897
- r.setStatus(o);
1898
- const l = await f(s.getRequestParams());
1899
- return r.removeStatus(o), l;
1900
- }
1901
- async function m() {
1902
- p(), await u();
1903
- }
1904
- function p() {
1905
- if (!c.value.shouldKeepSync)
1883
+ })), l = S(() => ({
1884
+ getData: c,
1885
+ sort: te,
1886
+ paginate: oe,
1887
+ fetchRows: d
1888
+ })), o = S(() => t.getSyncDetail());
1889
+ function c() {
1890
+ return a.value;
1891
+ }
1892
+ async function f(u) {
1893
+ const h = await t.fetchList(u);
1894
+ return e.clearItems(), e.addOrReplaceItems(h.items), e.setTotalCount(h.totalItems), h;
1895
+ }
1896
+ async function d(u = g.FetchList) {
1897
+ r.setStatus(u);
1898
+ const h = await f(s.getRequestParams());
1899
+ return r.removeStatus(u), h;
1900
+ }
1901
+ async function v() {
1902
+ m(), await d();
1903
+ }
1904
+ function m() {
1905
+ if (!o.value.shouldKeepSync)
1906
1906
  throw new Error("The provided repository does not support auto refresh");
1907
- a.setupInterval(c.value.intervalInMillisecond);
1907
+ n.setupInterval(o.value.intervalInMillisecond);
1908
1908
  }
1909
1909
  function b() {
1910
- a.clearInterval();
1911
- }
1912
- async function B(o, l = !0) {
1913
- r.setStatus(v.FetchItem), l && e.clearCurrentItem();
1914
- const d = await t.fetchItemById(o);
1915
- return e.setCurrentItem(d), r.removeStatus(v.FetchItem), d;
1916
- }
1917
- async function U(o) {
1918
- r.setStatus(v.Create);
1919
- const l = await t.createItem(o);
1920
- return l && e.addOrReplaceItems([l]), r.removeStatus(v.Create), l;
1921
- }
1922
- async function H(o, l) {
1923
- r.setStatus(v.Update);
1924
- const d = await t.updateItem(o, l);
1925
- return d && e.addOrReplaceItems([d]), r.removeStatus(v.Update), d;
1926
- }
1927
- async function q(o) {
1928
- return r.setStatus(v.Delete), await t.deleteItem(o), r.removeStatus(v.Delete), e.removeById(o);
1929
- }
1930
- async function ye() {
1931
- s.setNextPage(), r.setStatus(v.FetchLastItems);
1932
- const o = await f(s.getRequestParams());
1933
- return r.removeStatus(v.FetchLastItems), o;
1934
- }
1935
- async function Se() {
1936
- s.setPreventPage(), r.setStatus(v.FetchPreviousItems);
1937
- const o = await f(s.getRequestParams());
1938
- return r.removeStatus(v.FetchPreviousItems), o;
1939
- }
1940
- async function re(o) {
1941
- s.setPageNumber(o), r.setStatus(v.FetchList);
1942
- const l = await f(s.getRequestParams());
1943
- return r.removeStatus(v.FetchList), l;
1944
- }
1945
- async function Ie(o) {
1946
- s.setFilter("search", o), r.setStatus(v.Search), e.clearItems();
1947
- const l = await f(s.getRequestParams());
1948
- return r.removeStatus(v.Search), l;
1949
- }
1950
- async function X(o) {
1951
- s.setSortDetail(o), r.setStatus(v.Sort), e.clearItems();
1952
- const l = await f(s.getRequestParams());
1953
- return r.removeStatus(v.Sort), l;
1954
- }
1955
- async function z() {
1956
- return s.clearParam(), await u();
1957
- }
1958
- return tt(() => {
1910
+ n.clearInterval();
1911
+ }
1912
+ async function H(u, h = !0) {
1913
+ r.setStatus(g.FetchItem), h && e.clearCurrentItem();
1914
+ const p = await t.fetchItemById(u);
1915
+ return e.setCurrentItem(p), r.removeStatus(g.FetchItem), p;
1916
+ }
1917
+ async function q(u) {
1918
+ r.setStatus(g.Create);
1919
+ const h = await t.createItem(u);
1920
+ return h && e.addOrReplaceItems([h]), r.removeStatus(g.Create), h;
1921
+ }
1922
+ async function z(u, h) {
1923
+ r.setStatus(g.Update);
1924
+ const p = await t.updateItem(u, h);
1925
+ return p && e.addOrReplaceItems([p]), r.removeStatus(g.Update), p;
1926
+ }
1927
+ async function W(u) {
1928
+ return r.setStatus(g.Delete), await t.deleteItem(u), r.removeStatus(g.Delete), e.removeById(u);
1929
+ }
1930
+ async function Ce() {
1931
+ s.setNextPage(), r.setStatus(g.FetchLastItems);
1932
+ const u = await f(s.getRequestParams());
1933
+ return r.removeStatus(g.FetchLastItems), u;
1934
+ }
1935
+ async function Me() {
1936
+ s.setPreventPage(), r.setStatus(g.FetchPreviousItems);
1937
+ const u = await f(s.getRequestParams());
1938
+ return r.removeStatus(g.FetchPreviousItems), u;
1939
+ }
1940
+ async function oe(u) {
1941
+ s.setPageNumber(u), r.setStatus(g.FetchList);
1942
+ const h = await f(s.getRequestParams());
1943
+ return r.removeStatus(g.FetchList), h;
1944
+ }
1945
+ async function Ee(u) {
1946
+ s.setFilter("search", u), r.setStatus(g.Search), e.clearItems();
1947
+ const h = await f(s.getRequestParams());
1948
+ return r.removeStatus(g.Search), h;
1949
+ }
1950
+ async function te(u) {
1951
+ s.setSortDetail(u), r.setStatus(g.Sort), e.clearItems();
1952
+ const h = await f(s.getRequestParams());
1953
+ return r.removeStatus(g.Sort), h;
1954
+ }
1955
+ async function J() {
1956
+ return s.clearParam(), await d();
1957
+ }
1958
+ return At(() => {
1959
1959
  b();
1960
1960
  }), {
1961
1961
  loadingStatusManager: r,
1962
1962
  dataManger: e,
1963
1963
  paramsManager: s,
1964
- tableRenderingData: n,
1965
- fetchList: u,
1966
- fetchWithAutoRefresh: m,
1967
- setupAutoRefresh: p,
1964
+ tableRenderingData: a,
1965
+ fetchList: d,
1966
+ fetchWithAutoRefresh: v,
1967
+ setupAutoRefresh: m,
1968
1968
  stopAutoRefresh: b,
1969
- fetchItemById: B,
1970
- createItem: U,
1971
- updateItem: H,
1972
- deleteItem: q,
1973
- fetchLastItems: ye,
1974
- fetchPreviousItems: Se,
1975
- fetchItemsByPageNumber: re,
1976
- search: Ie,
1977
- sort: X,
1978
- clearFilters: z,
1979
- tableService: h,
1969
+ fetchItemById: H,
1970
+ createItem: q,
1971
+ updateItem: z,
1972
+ deleteItem: W,
1973
+ fetchLastItems: Ce,
1974
+ fetchPreviousItems: Me,
1975
+ fetchItemsByPageNumber: oe,
1976
+ search: Ee,
1977
+ sort: te,
1978
+ clearFilters: J,
1979
+ tableService: l,
1980
1980
  currentPageItems: i
1981
1981
  };
1982
1982
  }
1983
- function Ts(t) {
1984
- const e = M(t), s = I(() => ({
1983
+ function Cr(t) {
1984
+ const e = M(t), s = S(() => ({
1985
1985
  getData() {
1986
1986
  return {
1987
1987
  totalItems: e.value.length,
@@ -2003,7 +2003,7 @@ function Ts(t) {
2003
2003
  items: e.value
2004
2004
  };
2005
2005
  },
2006
- async paginate(r, a) {
2006
+ async paginate(r, n) {
2007
2007
  return {
2008
2008
  totalItems: e.value.length,
2009
2009
  items: e.value
@@ -2015,39 +2015,39 @@ function Ts(t) {
2015
2015
  staticTableService: s
2016
2016
  };
2017
2017
  }
2018
- function Ps() {
2019
- const t = M(/* @__PURE__ */ new Map()), e = M(0), s = I(() => e.value), r = I(() => Array.from(t.value.values()));
2020
- function a(f) {
2018
+ function Mr() {
2019
+ const t = M(/* @__PURE__ */ new Map()), e = M(0), s = S(() => e.value), r = S(() => Array.from(t.value.values()));
2020
+ function n(f) {
2021
2021
  e.value = f;
2022
2022
  }
2023
2023
  function i(f) {
2024
- for (const u of f)
2025
- n(u);
2024
+ for (const d of f)
2025
+ a(d);
2026
2026
  }
2027
- function n(f) {
2027
+ function a(f) {
2028
2028
  t.value.set(String(f.id), f);
2029
2029
  }
2030
- function h(f) {
2031
- const u = c(f);
2032
- return t.value.delete(String(f)), u;
2030
+ function l(f) {
2031
+ const d = o(f);
2032
+ return t.value.delete(String(f)), d;
2033
2033
  }
2034
- function c(f) {
2034
+ function o(f) {
2035
2035
  return t.value.get(String(f)) || null;
2036
2036
  }
2037
- function g() {
2037
+ function c() {
2038
2038
  t.value.clear();
2039
2039
  }
2040
2040
  return {
2041
2041
  entityItemsAsArray: r,
2042
2042
  addOrReplaceItems: i,
2043
- removeById: h,
2044
- getItemById: c,
2045
- clearItems: g,
2046
- setTotalCount: a,
2043
+ removeById: l,
2044
+ getItemById: o,
2045
+ clearItems: c,
2046
+ setTotalCount: n,
2047
2047
  getTotalCount: s
2048
2048
  };
2049
2049
  }
2050
- class $s {
2050
+ class Er {
2051
2051
  constructor(e, s = 500) {
2052
2052
  this.timerId = null, this.debounceTimeout = s, this.action = e;
2053
2053
  }
@@ -2060,38 +2060,38 @@ class $s {
2060
2060
  this.timerId && clearTimeout(this.timerId);
2061
2061
  }
2062
2062
  }
2063
- function Vs(t) {
2063
+ function Or(t) {
2064
2064
  return function(e, s, r) {
2065
- const a = r.value;
2065
+ const n = r.value;
2066
2066
  r.value = async function(...i) {
2067
2067
  try {
2068
- return await a.apply(this, i);
2069
- } catch (n) {
2070
- for (const h of t)
2071
- await h.handleError(n);
2068
+ return await n.apply(this, i);
2069
+ } catch (a) {
2070
+ for (const l of t)
2071
+ await l.handleError(a);
2072
2072
  }
2073
2073
  };
2074
2074
  };
2075
2075
  }
2076
- function Fs(t) {
2076
+ function Pr(t) {
2077
2077
  return function(e, s, r) {
2078
- const a = r.value;
2078
+ const n = r.value;
2079
2079
  r.value = async function(...i) {
2080
2080
  try {
2081
- const n = await a.apply(this, i);
2082
- for (const h of t)
2083
- h.shouldResolveSuccess(n) && await h.handleSuccess(n);
2084
- return n;
2085
- } catch (n) {
2086
- for (const h of t)
2087
- h.shouldResolveFailure(n) && await h.handleFailure(n);
2081
+ const a = await n.apply(this, i);
2082
+ for (const l of t)
2083
+ l.shouldResolveSuccess(a) && await l.handleSuccess(a);
2084
+ return a;
2085
+ } catch (a) {
2086
+ for (const l of t)
2087
+ l.shouldResolveFailure(a) && await l.handleFailure(a);
2088
2088
  }
2089
2089
  };
2090
2090
  };
2091
2091
  }
2092
- class js {
2093
- constructor(e, s, r = () => !0, a = () => !0) {
2094
- this.successMessageResolver = e, this.failureMessageResolver = s, this.shouldResolveSuccess = r, this.shouldResolveFailure = a;
2092
+ class Lr {
2093
+ constructor(e, s, r = () => !0, n = () => !0) {
2094
+ this.successMessageResolver = e, this.failureMessageResolver = s, this.shouldResolveSuccess = r, this.shouldResolveFailure = n;
2095
2095
  }
2096
2096
  async handleSuccess(e) {
2097
2097
  }
@@ -2102,24 +2102,24 @@ class js {
2102
2102
  async handleWarning() {
2103
2103
  }
2104
2104
  }
2105
- const R = class R {
2105
+ const _ = class _ {
2106
2106
  constructor() {
2107
2107
  }
2108
2108
  static GetInstance() {
2109
- return R.instance || (R.instance = new R()), R.instance;
2109
+ return _.instance || (_.instance = new _()), _.instance;
2110
2110
  }
2111
2111
  static registerHandler(e, s) {
2112
- R.handlers.set(e, s);
2112
+ _.handlers.set(e, s);
2113
2113
  }
2114
2114
  handle(e) {
2115
- var a;
2116
- const s = ((a = e.response) == null ? void 0 : a.status) ?? 0, r = R.handlers.get(s);
2115
+ var n;
2116
+ const s = ((n = e.response) == null ? void 0 : n.status) ?? 0, r = _.handlers.get(s);
2117
2117
  r && r.handleError(e);
2118
2118
  }
2119
2119
  };
2120
- R.handlers = /* @__PURE__ */ new Map(), R.instance = null;
2121
- let Ye = R;
2122
- class Ys {
2120
+ _.handlers = /* @__PURE__ */ new Map(), _.instance = null;
2121
+ let rt = _;
2122
+ class kr {
2123
2123
  constructor(e) {
2124
2124
  this.axiosInstance = e;
2125
2125
  }
@@ -2154,7 +2154,7 @@ class Ys {
2154
2154
  return this.axiosInstance;
2155
2155
  }
2156
2156
  }
2157
- class Ns {
2157
+ class xr {
2158
2158
  constructor(e) {
2159
2159
  this.axiosInstance = e;
2160
2160
  }
@@ -2192,7 +2192,7 @@ class Ns {
2192
2192
  );
2193
2193
  }
2194
2194
  }
2195
- class Bs {
2195
+ class Tr {
2196
2196
  constructor() {
2197
2197
  this._initializer = [];
2198
2198
  }
@@ -2204,9 +2204,9 @@ class Bs {
2204
2204
  e.initialize();
2205
2205
  }
2206
2206
  }
2207
- const j = class j {
2207
+ const Y = class Y {
2208
2208
  constructor() {
2209
- this.jsonConverter = new st();
2209
+ this.jsonConverter = new _t();
2210
2210
  }
2211
2211
  serializeObject(e, s) {
2212
2212
  return this.jsonConverter.serializeObject(e, s);
@@ -2226,63 +2226,63 @@ const j = class j {
2226
2226
  throw new Error("Unable to deserialize object");
2227
2227
  }
2228
2228
  static GetInstance() {
2229
- return j.Instance || (j.Instance = new j()), j.Instance;
2229
+ return Y.Instance || (Y.Instance = new Y()), Y.Instance;
2230
2230
  }
2231
2231
  };
2232
- j.Instance = null;
2233
- let Ne = j;
2234
- var Jt = /* @__PURE__ */ ((t) => (t.Success = "success", t.Failure = "error", t.Info = "info", t.Warning = "warning", t))(Jt || {}), Ke = /* @__PURE__ */ ((t) => (t.BottomLeft = "bottomLeft", t.TopLeft = "topLeft", t))(Ke || {});
2235
- class Us {
2232
+ Y.Instance = null;
2233
+ let nt = Y;
2234
+ var ys = /* @__PURE__ */ ((t) => (t.Success = "success", t.Failure = "error", t.Info = "info", t.Warning = "warning", t))(ys || {}), gt = /* @__PURE__ */ ((t) => (t.BottomLeft = "bottomLeft", t.TopLeft = "topLeft", t))(gt || {});
2235
+ class $r {
2236
2236
  constructor(e, s, r) {
2237
- this.placement = Ke.BottomLeft, this.type = e, this.message = s, this.description = r;
2237
+ this.placement = gt.BottomLeft, this.type = e, this.message = s, this.description = r;
2238
2238
  }
2239
2239
  }
2240
- const Hs = Ue(Le.Dialog, () => {
2241
- const t = Be({
2240
+ const Vr = lt(Be.Dialog, () => {
2241
+ const t = ot({
2242
2242
  dialogComponent: null,
2243
- width: $.DefaultWidth,
2244
- height: $.DefaultHeight,
2243
+ width: V.DefaultWidth,
2244
+ height: V.DefaultHeight,
2245
2245
  props: null,
2246
2246
  header: ""
2247
- }), e = I(() => !!t.dialogComponent), s = I(() => !!t.header);
2248
- function r(c) {
2249
- t.dialogComponent = c;
2247
+ }), e = S(() => !!t.dialogComponent), s = S(() => !!t.header);
2248
+ function r(o) {
2249
+ t.dialogComponent = o;
2250
2250
  }
2251
- function a(c) {
2252
- t.header = c;
2251
+ function n(o) {
2252
+ t.header = o;
2253
2253
  }
2254
- function i(c) {
2254
+ function i(o) {
2255
2255
  if (!e.value)
2256
2256
  throw new Error("there is no dialog to set props on");
2257
- t.props = c;
2257
+ t.props = o;
2258
2258
  }
2259
- function n(c, g) {
2259
+ function a(o, c) {
2260
2260
  if (!e.value)
2261
2261
  throw new Error("there is no dialog to set size on");
2262
- if (c < $.MinimalAvailableSize)
2262
+ if (o < V.MinimalAvailableSize)
2263
2263
  throw new Error("negative size not supported");
2264
- g === $.Width ? t.width = c : t.height = c;
2264
+ c === V.Width ? t.width = o : t.height = o;
2265
2265
  }
2266
- function h() {
2267
- t.props = null, t.height = $.DefaultHeight, t.width = $.DefaultWidth, t.header = "", t.dialogComponent = null;
2266
+ function l() {
2267
+ t.props = null, t.height = V.DefaultHeight, t.width = V.DefaultWidth, t.header = "", t.dialogComponent = null;
2268
2268
  }
2269
2269
  return {
2270
2270
  dialogData: t,
2271
2271
  openDialog: r,
2272
- clearDialog: h,
2273
- setSize: n,
2274
- setDialogHeader: a,
2272
+ clearDialog: l,
2273
+ setSize: a,
2274
+ setDialogHeader: n,
2275
2275
  setProps: i,
2276
2276
  isDialogExists: e,
2277
2277
  hasDefaultHeader: s
2278
2278
  };
2279
- }), qs = Ue(Le.Drawer, () => {
2280
- const t = M(te.Close), e = I(() => t.value === te.Open);
2279
+ }), Nr = lt(Be.Drawer, () => {
2280
+ const t = M(ne.Close), e = S(() => t.value === ne.Open);
2281
2281
  function s() {
2282
- t.value = te.Close;
2282
+ t.value = ne.Close;
2283
2283
  }
2284
2284
  function r() {
2285
- t.value = te.Open;
2285
+ t.value = ne.Open;
2286
2286
  }
2287
2287
  return {
2288
2288
  closeDrawer: s,
@@ -2290,7 +2290,7 @@ const Hs = Ue(Le.Dialog, () => {
2290
2290
  isDrawerOpen: e
2291
2291
  };
2292
2292
  });
2293
- class zs {
2293
+ class jr {
2294
2294
  constructor(e) {
2295
2295
  this.mapProcesses = /* @__PURE__ */ new Map(), this.processes = e, this.assignProcessManager();
2296
2296
  }
@@ -2310,7 +2310,7 @@ class zs {
2310
2310
  await s.execute();
2311
2311
  }
2312
2312
  }
2313
- class Gs {
2313
+ class Fr {
2314
2314
  constructor(e, s) {
2315
2315
  this.next = null, this.name = e, this.next = s;
2316
2316
  }
@@ -2318,7 +2318,7 @@ class Gs {
2318
2318
  e.setProcessToMap(this), this.next && this.next.addToManager(e);
2319
2319
  }
2320
2320
  }
2321
- class Js {
2321
+ class Yr {
2322
2322
  constructor() {
2323
2323
  this.checkAccessibility = this.checkAccessibility.bind(this), this.isAccessible = this.isAccessible.bind(this), this.getDestinationRouteName = this.getDestinationRouteName.bind(this);
2324
2324
  }
@@ -2344,9 +2344,9 @@ class Js {
2344
2344
  return null;
2345
2345
  }
2346
2346
  }
2347
- class Ws {
2347
+ class Ur {
2348
2348
  constructor(e, s, r) {
2349
- this.scheduler = new Je({
2349
+ this.scheduler = new ft({
2350
2350
  runAction: async () => {
2351
2351
  await this.fetchList();
2352
2352
  }
@@ -2394,37 +2394,37 @@ class Ws {
2394
2394
  this.scheduler.clearInterval();
2395
2395
  }
2396
2396
  }
2397
- class Wt {
2397
+ class ws {
2398
2398
  }
2399
- class Zs extends Wt {
2399
+ class Br extends ws {
2400
2400
  search(e, s, r) {
2401
- const a = [];
2401
+ const n = [];
2402
2402
  e: for (const i of e)
2403
- for (const n of r(i))
2404
- if (Z.removeSpacesFromString(String(n).toLowerCase()).indexOf(Z.removeSpacesFromString(String(s).toLowerCase())) > -1) {
2405
- a.push(i);
2403
+ for (const a of r(i))
2404
+ if (Q.removeSpacesFromString(String(a).toLowerCase()).indexOf(Q.removeSpacesFromString(String(s).toLowerCase())) > -1) {
2405
+ n.push(i);
2406
2406
  continue e;
2407
2407
  }
2408
- return a;
2408
+ return n;
2409
2409
  }
2410
2410
  }
2411
- var Xe = /* @__PURE__ */ ((t) => (t.Hidden = "hidden", t.Visible = "visible", t))(Xe || {});
2412
- class Ks {
2411
+ var mt = /* @__PURE__ */ ((t) => (t.Hidden = "hidden", t.Visible = "visible", t))(mt || {});
2412
+ class Hr {
2413
2413
  constructor(e) {
2414
2414
  this._visibilityControl = e, this.mangeVisibilityEvent();
2415
2415
  }
2416
2416
  mangeVisibilityEvent() {
2417
2417
  document.addEventListener("visibilitychange", (e) => {
2418
- document.visibilityState === Xe.Hidden ? this._visibilityControl.screenInvisible(e) : this._visibilityControl.screenVisible(e);
2418
+ document.visibilityState === mt.Hidden ? this._visibilityControl.screenInvisible(e) : this._visibilityControl.screenVisible(e);
2419
2419
  });
2420
2420
  }
2421
2421
  }
2422
- var Zt = Object.defineProperty, Kt = Object.getOwnPropertyDescriptor, C = (t, e, s, r) => {
2423
- for (var a = r > 1 ? void 0 : r ? Kt(e, s) : e, i = t.length - 1, n; i >= 0; i--)
2424
- (n = t[i]) && (a = (r ? n(e, s, a) : n(a)) || a);
2425
- return r && a && Zt(e, s, a), a;
2422
+ var Ss = Object.defineProperty, Is = Object.getOwnPropertyDescriptor, E = (t, e, s, r) => {
2423
+ for (var n = r > 1 ? void 0 : r ? Is(e, s) : e, i = t.length - 1, a; i >= 0; i--)
2424
+ (a = t[i]) && (n = (r ? a(e, s, n) : a(n)) || n);
2425
+ return r && n && Ss(e, s, n), n;
2426
2426
  };
2427
- let ve = class {
2427
+ let Re = class {
2428
2428
  constructor() {
2429
2429
  this.value = "", this.symbol = "";
2430
2430
  }
@@ -2437,16 +2437,16 @@ let ve = class {
2437
2437
  });
2438
2438
  }
2439
2439
  };
2440
- C([
2441
- N("value", String, !0)
2442
- ], ve.prototype, "value", 2);
2443
- C([
2444
- N("symbol", String)
2445
- ], ve.prototype, "symbol", 2);
2446
- ve = C([
2447
- De("Amount")
2448
- ], ve);
2449
- let ge = class {
2440
+ E([
2441
+ B("value", String, !0)
2442
+ ], Re.prototype, "value", 2);
2443
+ E([
2444
+ B("symbol", String)
2445
+ ], Re.prototype, "symbol", 2);
2446
+ Re = E([
2447
+ Ne("Amount")
2448
+ ], Re);
2449
+ let De = class {
2450
2450
  getTable() {
2451
2451
  const t = Object.getPrototypeOf(this)._table;
2452
2452
  if (!t)
@@ -2456,54 +2456,54 @@ let ge = class {
2456
2456
  return t;
2457
2457
  }
2458
2458
  };
2459
- C([
2460
- N("id", Object)
2461
- ], ge.prototype, "id", 2);
2462
- ge = C([
2463
- De("BaseModel")
2464
- ], ge);
2465
- let K = class extends ge {
2459
+ E([
2460
+ B("id", Object)
2461
+ ], De.prototype, "id", 2);
2462
+ De = E([
2463
+ Ne("BaseModel")
2464
+ ], De);
2465
+ let ee = class extends De {
2466
2466
  };
2467
- C([
2468
- N("symbol", String)
2469
- ], K.prototype, "symbol", 2);
2470
- C([
2471
- N("enName", String)
2472
- ], K.prototype, "enName", 2);
2473
- C([
2474
- N("faName", String)
2475
- ], K.prototype, "faName", 2);
2476
- C([
2477
- N("image", String)
2478
- ], K.prototype, "image", 2);
2479
- K = C([
2480
- De("MinifiedSymbolModel")
2481
- ], K);
2482
- class Xs {
2467
+ E([
2468
+ B("symbol", String)
2469
+ ], ee.prototype, "symbol", 2);
2470
+ E([
2471
+ B("enName", String)
2472
+ ], ee.prototype, "enName", 2);
2473
+ E([
2474
+ B("faName", String)
2475
+ ], ee.prototype, "faName", 2);
2476
+ E([
2477
+ B("image", String)
2478
+ ], ee.prototype, "image", 2);
2479
+ ee = E([
2480
+ Ne("MinifiedSymbolModel")
2481
+ ], ee);
2482
+ class qr {
2483
2483
  constructor(e, s) {
2484
2484
  this.requestedDate = e, this.executedDate = s;
2485
2485
  }
2486
2486
  get requestedDateInJalali() {
2487
- return _.mapUnixToDate(this.requestedDate, ee.SimpleDate);
2487
+ return C.mapUnixToDate(this.requestedDate, re.SimpleDate);
2488
2488
  }
2489
2489
  get requestedTime() {
2490
- return _.mapUnixToDate(this.requestedDate, ee.JustHour);
2490
+ return C.mapUnixToDate(this.requestedDate, re.JustHour);
2491
2491
  }
2492
2492
  get executedDateInJalali() {
2493
- return _.mapUnixToDate(this.executedDate, ee.SimpleDate);
2493
+ return C.mapUnixToDate(this.executedDate, re.SimpleDate);
2494
2494
  }
2495
2495
  get executedDateTime() {
2496
- return _.mapUnixToDate(this.executedDate, ee.JustHour);
2496
+ return C.mapUnixToDate(this.executedDate, re.JustHour);
2497
2497
  }
2498
2498
  }
2499
- class Qs {
2499
+ class zr {
2500
2500
  constructor(e, s) {
2501
2501
  this.requestedAmount = e, this.executedAmount = s;
2502
2502
  }
2503
2503
  }
2504
- class er {
2505
- constructor(e, s, r, a, i) {
2506
- this.symbolPrice = e, this.USDTPrice = s, this.symobl = r, this.symbolImage = a, this.USDTImage = i;
2504
+ class Wr {
2505
+ constructor(e, s, r, n, i) {
2506
+ this.symbolPrice = e, this.USDTPrice = s, this.symobl = r, this.symbolImage = n, this.USDTImage = i;
2507
2507
  }
2508
2508
  get truncatedSymbolPrice() {
2509
2509
  return this.symbolPrice.toLocaleString("en-US", {
@@ -2516,117 +2516,824 @@ class er {
2516
2516
  });
2517
2517
  }
2518
2518
  }
2519
- class tr {
2519
+ class Jr {
2520
2520
  constructor(e, s) {
2521
2521
  this.soldSymbol = e, this.buySymbol = s;
2522
2522
  }
2523
2523
  }
2524
+ var ke;
2525
+ (function(t) {
2526
+ t[t.Transient = 0] = "Transient", t[t.Singleton = 1] = "Singleton", t[t.ResolutionScoped = 2] = "ResolutionScoped", t[t.ContainerScoped = 3] = "ContainerScoped";
2527
+ })(ke || (ke = {}));
2528
+ const D = ke;
2529
+ /*! *****************************************************************************
2530
+ Copyright (c) Microsoft Corporation.
2531
+
2532
+ Permission to use, copy, modify, and/or distribute this software for any
2533
+ purpose with or without fee is hereby granted.
2534
+
2535
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
2536
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
2537
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
2538
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
2539
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
2540
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
2541
+ PERFORMANCE OF THIS SOFTWARE.
2542
+ ***************************************************************************** */
2543
+ var xe = function(t, e) {
2544
+ return xe = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(s, r) {
2545
+ s.__proto__ = r;
2546
+ } || function(s, r) {
2547
+ for (var n in r) r.hasOwnProperty(n) && (s[n] = r[n]);
2548
+ }, xe(t, e);
2549
+ };
2550
+ function qe(t, e) {
2551
+ xe(t, e);
2552
+ function s() {
2553
+ this.constructor = t;
2554
+ }
2555
+ t.prototype = e === null ? Object.create(e) : (s.prototype = e.prototype, new s());
2556
+ }
2557
+ function bs(t, e, s, r) {
2558
+ function n(i) {
2559
+ return i instanceof s ? i : new s(function(a) {
2560
+ a(i);
2561
+ });
2562
+ }
2563
+ return new (s || (s = Promise))(function(i, a) {
2564
+ function l(f) {
2565
+ try {
2566
+ c(r.next(f));
2567
+ } catch (d) {
2568
+ a(d);
2569
+ }
2570
+ }
2571
+ function o(f) {
2572
+ try {
2573
+ c(r.throw(f));
2574
+ } catch (d) {
2575
+ a(d);
2576
+ }
2577
+ }
2578
+ function c(f) {
2579
+ f.done ? i(f.value) : n(f.value).then(l, o);
2580
+ }
2581
+ c((r = r.apply(t, [])).next());
2582
+ });
2583
+ }
2584
+ function Rs(t, e) {
2585
+ var s = { label: 0, sent: function() {
2586
+ if (i[0] & 1) throw i[1];
2587
+ return i[1];
2588
+ }, trys: [], ops: [] }, r, n, i, a;
2589
+ return a = { next: l(0), throw: l(1), return: l(2) }, typeof Symbol == "function" && (a[Symbol.iterator] = function() {
2590
+ return this;
2591
+ }), a;
2592
+ function l(c) {
2593
+ return function(f) {
2594
+ return o([c, f]);
2595
+ };
2596
+ }
2597
+ function o(c) {
2598
+ if (r) throw new TypeError("Generator is already executing.");
2599
+ for (; s; ) try {
2600
+ if (r = 1, n && (i = c[0] & 2 ? n.return : c[0] ? n.throw || ((i = n.return) && i.call(n), 0) : n.next) && !(i = i.call(n, c[1])).done) return i;
2601
+ switch (n = 0, i && (c = [c[0] & 2, i.value]), c[0]) {
2602
+ case 0:
2603
+ case 1:
2604
+ i = c;
2605
+ break;
2606
+ case 4:
2607
+ return s.label++, { value: c[1], done: !1 };
2608
+ case 5:
2609
+ s.label++, n = c[1], c = [0];
2610
+ continue;
2611
+ case 7:
2612
+ c = s.ops.pop(), s.trys.pop();
2613
+ continue;
2614
+ default:
2615
+ if (i = s.trys, !(i = i.length > 0 && i[i.length - 1]) && (c[0] === 6 || c[0] === 2)) {
2616
+ s = 0;
2617
+ continue;
2618
+ }
2619
+ if (c[0] === 3 && (!i || c[1] > i[0] && c[1] < i[3])) {
2620
+ s.label = c[1];
2621
+ break;
2622
+ }
2623
+ if (c[0] === 6 && s.label < i[1]) {
2624
+ s.label = i[1], i = c;
2625
+ break;
2626
+ }
2627
+ if (i && s.label < i[2]) {
2628
+ s.label = i[2], s.ops.push(c);
2629
+ break;
2630
+ }
2631
+ i[2] && s.ops.pop(), s.trys.pop();
2632
+ continue;
2633
+ }
2634
+ c = e.call(t, s);
2635
+ } catch (f) {
2636
+ c = [6, f], n = 0;
2637
+ } finally {
2638
+ r = i = 0;
2639
+ }
2640
+ if (c[0] & 5) throw c[1];
2641
+ return { value: c[0] ? c[1] : void 0, done: !0 };
2642
+ }
2643
+ }
2644
+ function fe(t) {
2645
+ var e = typeof Symbol == "function" && Symbol.iterator, s = e && t[e], r = 0;
2646
+ if (s) return s.call(t);
2647
+ if (t && typeof t.length == "number") return {
2648
+ next: function() {
2649
+ return t && r >= t.length && (t = void 0), { value: t && t[r++], done: !t };
2650
+ }
2651
+ };
2652
+ throw new TypeError(e ? "Object is not iterable." : "Symbol.iterator is not defined.");
2653
+ }
2654
+ function Ae(t, e) {
2655
+ var s = typeof Symbol == "function" && t[Symbol.iterator];
2656
+ if (!s) return t;
2657
+ var r = s.call(t), n, i = [], a;
2658
+ try {
2659
+ for (; (e === void 0 || e-- > 0) && !(n = r.next()).done; ) i.push(n.value);
2660
+ } catch (l) {
2661
+ a = { error: l };
2662
+ } finally {
2663
+ try {
2664
+ n && !n.done && (s = r.return) && s.call(r);
2665
+ } finally {
2666
+ if (a) throw a.error;
2667
+ }
2668
+ }
2669
+ return i;
2670
+ }
2671
+ function N() {
2672
+ for (var t = [], e = 0; e < arguments.length; e++)
2673
+ t = t.concat(Ae(arguments[e]));
2674
+ return t;
2675
+ }
2676
+ var Te = "injectionTokens";
2677
+ function Ds(t) {
2678
+ var e = Reflect.getMetadata("design:paramtypes", t) || [], s = Reflect.getOwnMetadata(Te, t) || {};
2679
+ return Object.keys(s).forEach(function(r) {
2680
+ e[+r] = s[r];
2681
+ }), e;
2682
+ }
2683
+ function As(t, e) {
2684
+ return function(s, r, n) {
2685
+ var i = Reflect.getOwnMetadata(Te, s) || {};
2686
+ i[n] = t, Reflect.defineMetadata(Te, i, s);
2687
+ };
2688
+ }
2689
+ function yt(t) {
2690
+ return !!t.useClass;
2691
+ }
2692
+ function $e(t) {
2693
+ return !!t.useFactory;
2694
+ }
2695
+ var wt = function() {
2696
+ function t(e) {
2697
+ this.wrap = e, this.reflectMethods = [
2698
+ "get",
2699
+ "getPrototypeOf",
2700
+ "setPrototypeOf",
2701
+ "getOwnPropertyDescriptor",
2702
+ "defineProperty",
2703
+ "has",
2704
+ "set",
2705
+ "deleteProperty",
2706
+ "apply",
2707
+ "construct",
2708
+ "ownKeys"
2709
+ ];
2710
+ }
2711
+ return t.prototype.createProxy = function(e) {
2712
+ var s = this, r = {}, n = !1, i, a = function() {
2713
+ return n || (i = e(s.wrap()), n = !0), i;
2714
+ };
2715
+ return new Proxy(r, this.createHandler(a));
2716
+ }, t.prototype.createHandler = function(e) {
2717
+ var s = {}, r = function(n) {
2718
+ s[n] = function() {
2719
+ for (var i = [], a = 0; a < arguments.length; a++)
2720
+ i[a] = arguments[a];
2721
+ i[0] = e();
2722
+ var l = Reflect[n];
2723
+ return l.apply(void 0, N(i));
2724
+ };
2725
+ };
2726
+ return this.reflectMethods.forEach(r), s;
2727
+ }, t;
2728
+ }();
2729
+ function X(t) {
2730
+ return typeof t == "string" || typeof t == "symbol";
2731
+ }
2732
+ function _s(t) {
2733
+ return typeof t == "object" && "token" in t && "multiple" in t;
2734
+ }
2735
+ function it(t) {
2736
+ return typeof t == "object" && "token" in t && "transform" in t;
2737
+ }
2738
+ function Cs(t) {
2739
+ return typeof t == "function" || t instanceof wt;
2740
+ }
2741
+ function Ie(t) {
2742
+ return !!t.useToken;
2743
+ }
2744
+ function be(t) {
2745
+ return t.useValue != null;
2746
+ }
2747
+ function Ms(t) {
2748
+ return yt(t) || be(t) || Ie(t) || $e(t);
2749
+ }
2750
+ var ze = function() {
2751
+ function t() {
2752
+ this._registryMap = /* @__PURE__ */ new Map();
2753
+ }
2754
+ return t.prototype.entries = function() {
2755
+ return this._registryMap.entries();
2756
+ }, t.prototype.getAll = function(e) {
2757
+ return this.ensure(e), this._registryMap.get(e);
2758
+ }, t.prototype.get = function(e) {
2759
+ this.ensure(e);
2760
+ var s = this._registryMap.get(e);
2761
+ return s[s.length - 1] || null;
2762
+ }, t.prototype.set = function(e, s) {
2763
+ this.ensure(e), this._registryMap.get(e).push(s);
2764
+ }, t.prototype.setAll = function(e, s) {
2765
+ this._registryMap.set(e, s);
2766
+ }, t.prototype.has = function(e) {
2767
+ return this.ensure(e), this._registryMap.get(e).length > 0;
2768
+ }, t.prototype.clear = function() {
2769
+ this._registryMap.clear();
2770
+ }, t.prototype.ensure = function(e) {
2771
+ this._registryMap.has(e) || this._registryMap.set(e, []);
2772
+ }, t;
2773
+ }(), Es = function(t) {
2774
+ qe(e, t);
2775
+ function e() {
2776
+ return t !== null && t.apply(this, arguments) || this;
2777
+ }
2778
+ return e;
2779
+ }(ze), pe = /* @__PURE__ */ function() {
2780
+ function t() {
2781
+ this.scopedResolutions = /* @__PURE__ */ new Map();
2782
+ }
2783
+ return t;
2784
+ }();
2785
+ function Os(t, e) {
2786
+ if (t === null)
2787
+ return "at position #" + e;
2788
+ var s = t.split(",")[e].trim();
2789
+ return '"' + s + '" at position #' + e;
2790
+ }
2791
+ function Ps(t, e, s) {
2792
+ return s === void 0 && (s = " "), N([t], e.message.split(`
2793
+ `).map(function(r) {
2794
+ return s + r;
2795
+ })).join(`
2796
+ `);
2797
+ }
2798
+ function Ls(t, e, s) {
2799
+ var r = Ae(t.toString().match(/constructor\(([\w, ]+)\)/) || [], 2), n = r[1], i = n === void 0 ? null : n, a = Os(i, e);
2800
+ return Ps("Cannot inject the dependency " + a + ' of "' + t.name + '" constructor. Reason:', s);
2801
+ }
2802
+ function ks(t) {
2803
+ if (typeof t.dispose != "function")
2804
+ return !1;
2805
+ var e = t.dispose;
2806
+ return !(e.length > 0);
2807
+ }
2808
+ var xs = function(t) {
2809
+ qe(e, t);
2810
+ function e() {
2811
+ return t !== null && t.apply(this, arguments) || this;
2812
+ }
2813
+ return e;
2814
+ }(ze), Ts = function(t) {
2815
+ qe(e, t);
2816
+ function e() {
2817
+ return t !== null && t.apply(this, arguments) || this;
2818
+ }
2819
+ return e;
2820
+ }(ze), $s = /* @__PURE__ */ function() {
2821
+ function t() {
2822
+ this.preResolution = new xs(), this.postResolution = new Ts();
2823
+ }
2824
+ return t;
2825
+ }(), St = /* @__PURE__ */ new Map(), Vs = function() {
2826
+ function t(e) {
2827
+ this.parent = e, this._registry = new Es(), this.interceptors = new $s(), this.disposed = !1, this.disposables = /* @__PURE__ */ new Set();
2828
+ }
2829
+ return t.prototype.register = function(e, s, r) {
2830
+ r === void 0 && (r = { lifecycle: D.Transient }), this.ensureNotDisposed();
2831
+ var n;
2832
+ if (Ms(s) ? n = s : n = { useClass: s }, Ie(n))
2833
+ for (var i = [e], a = n; a != null; ) {
2834
+ var l = a.useToken;
2835
+ if (i.includes(l))
2836
+ throw new Error("Token registration cycle detected! " + N(i, [l]).join(" -> "));
2837
+ i.push(l);
2838
+ var o = this._registry.get(l);
2839
+ o && Ie(o.provider) ? a = o.provider : a = null;
2840
+ }
2841
+ if ((r.lifecycle === D.Singleton || r.lifecycle == D.ContainerScoped || r.lifecycle == D.ResolutionScoped) && (be(n) || $e(n)))
2842
+ throw new Error('Cannot use lifecycle "' + D[r.lifecycle] + '" with ValueProviders or FactoryProviders');
2843
+ return this._registry.set(e, { provider: n, options: r }), this;
2844
+ }, t.prototype.registerType = function(e, s) {
2845
+ return this.ensureNotDisposed(), X(s) ? this.register(e, {
2846
+ useToken: s
2847
+ }) : this.register(e, {
2848
+ useClass: s
2849
+ });
2850
+ }, t.prototype.registerInstance = function(e, s) {
2851
+ return this.ensureNotDisposed(), this.register(e, {
2852
+ useValue: s
2853
+ });
2854
+ }, t.prototype.registerSingleton = function(e, s) {
2855
+ if (this.ensureNotDisposed(), X(e)) {
2856
+ if (X(s))
2857
+ return this.register(e, {
2858
+ useToken: s
2859
+ }, { lifecycle: D.Singleton });
2860
+ if (s)
2861
+ return this.register(e, {
2862
+ useClass: s
2863
+ }, { lifecycle: D.Singleton });
2864
+ throw new Error('Cannot register a type name as a singleton without a "to" token');
2865
+ }
2866
+ var r = e;
2867
+ return s && !X(s) && (r = s), this.register(e, {
2868
+ useClass: r
2869
+ }, { lifecycle: D.Singleton });
2870
+ }, t.prototype.resolve = function(e, s, r) {
2871
+ s === void 0 && (s = new pe()), r === void 0 && (r = !1), this.ensureNotDisposed();
2872
+ var n = this.getRegistration(e);
2873
+ if (!n && X(e)) {
2874
+ if (r)
2875
+ return;
2876
+ throw new Error('Attempted to resolve unregistered dependency token: "' + e.toString() + '"');
2877
+ }
2878
+ if (this.executePreResolutionInterceptor(e, "Single"), n) {
2879
+ var i = this.resolveRegistration(n, s);
2880
+ return this.executePostResolutionInterceptor(e, i, "Single"), i;
2881
+ }
2882
+ if (Cs(e)) {
2883
+ var i = this.construct(e, s);
2884
+ return this.executePostResolutionInterceptor(e, i, "Single"), i;
2885
+ }
2886
+ throw new Error("Attempted to construct an undefined constructor. Could mean a circular dependency problem. Try using `delay` function.");
2887
+ }, t.prototype.executePreResolutionInterceptor = function(e, s) {
2888
+ var r, n;
2889
+ if (this.interceptors.preResolution.has(e)) {
2890
+ var i = [];
2891
+ try {
2892
+ for (var a = fe(this.interceptors.preResolution.getAll(e)), l = a.next(); !l.done; l = a.next()) {
2893
+ var o = l.value;
2894
+ o.options.frequency != "Once" && i.push(o), o.callback(e, s);
2895
+ }
2896
+ } catch (c) {
2897
+ r = { error: c };
2898
+ } finally {
2899
+ try {
2900
+ l && !l.done && (n = a.return) && n.call(a);
2901
+ } finally {
2902
+ if (r) throw r.error;
2903
+ }
2904
+ }
2905
+ this.interceptors.preResolution.setAll(e, i);
2906
+ }
2907
+ }, t.prototype.executePostResolutionInterceptor = function(e, s, r) {
2908
+ var n, i;
2909
+ if (this.interceptors.postResolution.has(e)) {
2910
+ var a = [];
2911
+ try {
2912
+ for (var l = fe(this.interceptors.postResolution.getAll(e)), o = l.next(); !o.done; o = l.next()) {
2913
+ var c = o.value;
2914
+ c.options.frequency != "Once" && a.push(c), c.callback(e, s, r);
2915
+ }
2916
+ } catch (f) {
2917
+ n = { error: f };
2918
+ } finally {
2919
+ try {
2920
+ o && !o.done && (i = l.return) && i.call(l);
2921
+ } finally {
2922
+ if (n) throw n.error;
2923
+ }
2924
+ }
2925
+ this.interceptors.postResolution.setAll(e, a);
2926
+ }
2927
+ }, t.prototype.resolveRegistration = function(e, s) {
2928
+ if (this.ensureNotDisposed(), e.options.lifecycle === D.ResolutionScoped && s.scopedResolutions.has(e))
2929
+ return s.scopedResolutions.get(e);
2930
+ var r = e.options.lifecycle === D.Singleton, n = e.options.lifecycle === D.ContainerScoped, i = r || n, a;
2931
+ return be(e.provider) ? a = e.provider.useValue : Ie(e.provider) ? a = i ? e.instance || (e.instance = this.resolve(e.provider.useToken, s)) : this.resolve(e.provider.useToken, s) : yt(e.provider) ? a = i ? e.instance || (e.instance = this.construct(e.provider.useClass, s)) : this.construct(e.provider.useClass, s) : $e(e.provider) ? a = e.provider.useFactory(this) : a = this.construct(e.provider, s), e.options.lifecycle === D.ResolutionScoped && s.scopedResolutions.set(e, a), a;
2932
+ }, t.prototype.resolveAll = function(e, s, r) {
2933
+ var n = this;
2934
+ s === void 0 && (s = new pe()), r === void 0 && (r = !1), this.ensureNotDisposed();
2935
+ var i = this.getAllRegistrations(e);
2936
+ if (!i && X(e)) {
2937
+ if (r)
2938
+ return [];
2939
+ throw new Error('Attempted to resolve unregistered dependency token: "' + e.toString() + '"');
2940
+ }
2941
+ if (this.executePreResolutionInterceptor(e, "All"), i) {
2942
+ var a = i.map(function(o) {
2943
+ return n.resolveRegistration(o, s);
2944
+ });
2945
+ return this.executePostResolutionInterceptor(e, a, "All"), a;
2946
+ }
2947
+ var l = [this.construct(e, s)];
2948
+ return this.executePostResolutionInterceptor(e, l, "All"), l;
2949
+ }, t.prototype.isRegistered = function(e, s) {
2950
+ return s === void 0 && (s = !1), this.ensureNotDisposed(), this._registry.has(e) || s && (this.parent || !1) && this.parent.isRegistered(e, !0);
2951
+ }, t.prototype.reset = function() {
2952
+ this.ensureNotDisposed(), this._registry.clear(), this.interceptors.preResolution.clear(), this.interceptors.postResolution.clear();
2953
+ }, t.prototype.clearInstances = function() {
2954
+ var e, s;
2955
+ this.ensureNotDisposed();
2956
+ try {
2957
+ for (var r = fe(this._registry.entries()), n = r.next(); !n.done; n = r.next()) {
2958
+ var i = Ae(n.value, 2), a = i[0], l = i[1];
2959
+ this._registry.setAll(a, l.filter(function(o) {
2960
+ return !be(o.provider);
2961
+ }).map(function(o) {
2962
+ return o.instance = void 0, o;
2963
+ }));
2964
+ }
2965
+ } catch (o) {
2966
+ e = { error: o };
2967
+ } finally {
2968
+ try {
2969
+ n && !n.done && (s = r.return) && s.call(r);
2970
+ } finally {
2971
+ if (e) throw e.error;
2972
+ }
2973
+ }
2974
+ }, t.prototype.createChildContainer = function() {
2975
+ var e, s;
2976
+ this.ensureNotDisposed();
2977
+ var r = new t(this);
2978
+ try {
2979
+ for (var n = fe(this._registry.entries()), i = n.next(); !i.done; i = n.next()) {
2980
+ var a = Ae(i.value, 2), l = a[0], o = a[1];
2981
+ o.some(function(c) {
2982
+ var f = c.options;
2983
+ return f.lifecycle === D.ContainerScoped;
2984
+ }) && r._registry.setAll(l, o.map(function(c) {
2985
+ return c.options.lifecycle === D.ContainerScoped ? {
2986
+ provider: c.provider,
2987
+ options: c.options
2988
+ } : c;
2989
+ }));
2990
+ }
2991
+ } catch (c) {
2992
+ e = { error: c };
2993
+ } finally {
2994
+ try {
2995
+ i && !i.done && (s = n.return) && s.call(n);
2996
+ } finally {
2997
+ if (e) throw e.error;
2998
+ }
2999
+ }
3000
+ return r;
3001
+ }, t.prototype.beforeResolution = function(e, s, r) {
3002
+ r === void 0 && (r = { frequency: "Always" }), this.interceptors.preResolution.set(e, {
3003
+ callback: s,
3004
+ options: r
3005
+ });
3006
+ }, t.prototype.afterResolution = function(e, s, r) {
3007
+ r === void 0 && (r = { frequency: "Always" }), this.interceptors.postResolution.set(e, {
3008
+ callback: s,
3009
+ options: r
3010
+ });
3011
+ }, t.prototype.dispose = function() {
3012
+ return bs(this, void 0, void 0, function() {
3013
+ var e;
3014
+ return Rs(this, function(s) {
3015
+ switch (s.label) {
3016
+ case 0:
3017
+ return this.disposed = !0, e = [], this.disposables.forEach(function(r) {
3018
+ var n = r.dispose();
3019
+ n && e.push(n);
3020
+ }), [4, Promise.all(e)];
3021
+ case 1:
3022
+ return s.sent(), [2];
3023
+ }
3024
+ });
3025
+ });
3026
+ }, t.prototype.getRegistration = function(e) {
3027
+ return this.isRegistered(e) ? this._registry.get(e) : this.parent ? this.parent.getRegistration(e) : null;
3028
+ }, t.prototype.getAllRegistrations = function(e) {
3029
+ return this.isRegistered(e) ? this._registry.getAll(e) : this.parent ? this.parent.getAllRegistrations(e) : null;
3030
+ }, t.prototype.construct = function(e, s) {
3031
+ var r = this;
3032
+ if (e instanceof wt)
3033
+ return e.createProxy(function(i) {
3034
+ return r.resolve(i, s);
3035
+ });
3036
+ var n = function() {
3037
+ var i = St.get(e);
3038
+ if (!i || i.length === 0) {
3039
+ if (e.length === 0)
3040
+ return new e();
3041
+ throw new Error('TypeInfo not known for "' + e.name + '"');
3042
+ }
3043
+ var a = i.map(r.resolveParams(s, e));
3044
+ return new (e.bind.apply(e, N([void 0], a)))();
3045
+ }();
3046
+ return ks(n) && this.disposables.add(n), n;
3047
+ }, t.prototype.resolveParams = function(e, s) {
3048
+ var r = this;
3049
+ return function(n, i) {
3050
+ var a, l, o;
3051
+ try {
3052
+ return _s(n) ? it(n) ? n.multiple ? (a = r.resolve(n.transform)).transform.apply(a, N([r.resolveAll(n.token, new pe(), n.isOptional)], n.transformArgs)) : (l = r.resolve(n.transform)).transform.apply(l, N([r.resolve(n.token, e, n.isOptional)], n.transformArgs)) : n.multiple ? r.resolveAll(n.token, new pe(), n.isOptional) : r.resolve(n.token, e, n.isOptional) : it(n) ? (o = r.resolve(n.transform, e)).transform.apply(o, N([r.resolve(n.token, e)], n.transformArgs)) : r.resolve(n, e);
3053
+ } catch (c) {
3054
+ throw new Error(Ls(s, i, c));
3055
+ }
3056
+ };
3057
+ }, t.prototype.ensureNotDisposed = function() {
3058
+ if (this.disposed)
3059
+ throw new Error("This container has been disposed, you cannot interact with a disposed container");
3060
+ }, t;
3061
+ }(), It = new Vs();
3062
+ function Ns(t, e) {
3063
+ var s = {
3064
+ token: t,
3065
+ multiple: !1,
3066
+ isOptional: e
3067
+ };
3068
+ return As(s);
3069
+ }
3070
+ function js(t) {
3071
+ return function(e) {
3072
+ St.set(e, Ds(e));
3073
+ };
3074
+ }
3075
+ function bt() {
3076
+ return function(t) {
3077
+ js()(t), It.registerSingleton(t);
3078
+ };
3079
+ }
3080
+ if (typeof Reflect > "u" || !Reflect.getMetadata)
3081
+ throw new Error(`tsyringe requires a reflect polyfill. Please add 'import "reflect-metadata"' to the top of your entry point.`);
3082
+ var Fs = Object.getOwnPropertyDescriptor, Ys = (t, e, s, r) => {
3083
+ for (var n = r > 1 ? void 0 : r ? Fs(e, s) : e, i = t.length - 1, a; i >= 0; i--)
3084
+ (a = t[i]) && (n = a(n) || n);
3085
+ return n;
3086
+ };
3087
+ let Ve = class {
3088
+ dispatchOnWindow(t) {
3089
+ window.dispatchEvent(new CustomEvent(t));
3090
+ }
3091
+ dispatchWebSocketOnWindow(t) {
3092
+ window.dispatchEvent(t);
3093
+ }
3094
+ };
3095
+ Ve = Ys([
3096
+ bt()
3097
+ ], Ve);
3098
+ class We extends Event {
3099
+ constructor(e) {
3100
+ const s = We.ParseData(e.data);
3101
+ super(s.type), this.getMessageEvent = this.getMessageEvent.bind(this), this.getResult = this.getResult.bind(this), this.messageEvent = e, this.data = s;
3102
+ }
3103
+ getMessageEvent() {
3104
+ return this.messageEvent;
3105
+ }
3106
+ getResult() {
3107
+ return this.data;
3108
+ }
3109
+ static ParseData(e) {
3110
+ try {
3111
+ return JSON.parse(e);
3112
+ } catch {
3113
+ return e;
3114
+ }
3115
+ }
3116
+ }
3117
+ function Gr(t, e = !1) {
3118
+ return function(s, r, n) {
3119
+ function i(a) {
3120
+ const l = It.resolve(s.constructor);
3121
+ if (n.value.bind(l)(a), e)
3122
+ for (const o of t)
3123
+ window.removeEventListener(o, i);
3124
+ }
3125
+ for (const a of t)
3126
+ window.addEventListener(a, i);
3127
+ };
3128
+ }
3129
+ class Kr {
3130
+ constructor(e, s) {
3131
+ this.type = e, this.data = s;
3132
+ }
3133
+ getPayload() {
3134
+ return JSON.stringify({
3135
+ type: this.type,
3136
+ data: this.data
3137
+ });
3138
+ }
3139
+ }
3140
+ var ie = /* @__PURE__ */ ((t) => (t.CLOSE = "wsClose", t.OPEN = "wsOpen", t.ERROR = "wsError", t.TIMEOUT = "wsTimeout", t))(ie || {}), Us = Object.getOwnPropertyDescriptor, Bs = (t, e, s, r) => {
3141
+ for (var n = r > 1 ? void 0 : r ? Us(e, s) : e, i = t.length - 1, a; i >= 0; i--)
3142
+ (a = t[i]) && (n = a(n) || n);
3143
+ return n;
3144
+ }, Hs = (t, e) => (s, r) => e(s, r, t);
3145
+ let at = class {
3146
+ constructor(t) {
3147
+ this.customEventDispatcher = t, this.webSocket = null, this.retry = 3, this.url = "", this.protocols = [], this.delayTimeInMillieSeconds = 500, this.baseUrl = "", this.intervalId = null, this.onOpen = this.onOpen.bind(this), this.onMessage = this.onMessage.bind(this), this.onError = this.onError.bind(this), this.onClose = this.onClose.bind(this), this.checkHealth = this.checkHealth.bind(this), this.sendPing = this.sendPing.bind(this), this.reconnect = this.reconnect.bind(this), this.fakeWait = this.fakeWait.bind(this), this.isClosing = this.isClosing.bind(this), this.isClosed = this.isClosed.bind(this), this.connect = this.connect.bind(this), this.registerPingPontInterval = this.registerPingPontInterval.bind(this), this.closeConnection = this.closeConnection.bind(this), this.isConnectionOpen = this.isConnectionOpen.bind(this), this.isConnecting = this.isConnecting.bind(this), this.send = this.send.bind(this), this.setBaseUrl = this.setBaseUrl.bind(this);
3148
+ }
3149
+ connect(t, e = [], s = 3) {
3150
+ this.webSocket && (this.webSocket.removeEventListener("open", this.onOpen), this.webSocket.removeEventListener("close", this.onClose), this.webSocket.removeEventListener("error", this.onError)), this.webSocket = new WebSocket(this.baseUrl + t, e), this.retry = s, this.url = t, this.protocols = e, this.webSocket.addEventListener("error", this.onError), this.webSocket.addEventListener("close", this.onClose), this.webSocket.addEventListener("open", this.onOpen), this.checkHealth();
3151
+ }
3152
+ async checkHealth() {
3153
+ try {
3154
+ await this.fakeWait(this.delayTimeInMillieSeconds), !this.isClosed() && !this.isClosing() && !this.isConnectionOpen() && this.sendPing();
3155
+ } catch {
3156
+ this.reconnect();
3157
+ }
3158
+ }
3159
+ sendPing() {
3160
+ this.webSocket.send("PING");
3161
+ }
3162
+ reconnect() {
3163
+ this.retry === 0 && this.customEventDispatcher.dispatchOnWindow(ie.TIMEOUT), this.retry > 0 && (this.delayTimeInMillieSeconds = this.delayTimeInMillieSeconds * 2, this.connect(this.url, this.protocols, --this.retry));
3164
+ }
3165
+ fakeWait(t) {
3166
+ return new Promise((e) => {
3167
+ setTimeout(() => {
3168
+ e(null);
3169
+ }, t);
3170
+ });
3171
+ }
3172
+ onError() {
3173
+ this.customEventDispatcher.dispatchOnWindow(ie.ERROR), this.closeConnection();
3174
+ }
3175
+ onOpen() {
3176
+ this.webSocket.addEventListener("message", this.onMessage), this.customEventDispatcher.dispatchOnWindow(ie.OPEN), this.registerPingPontInterval();
3177
+ }
3178
+ registerPingPontInterval() {
3179
+ this.intervalId = setInterval(() => {
3180
+ this.sendPing();
3181
+ }, 1e4);
3182
+ }
3183
+ onMessage(t) {
3184
+ const e = new We(t);
3185
+ this.customEventDispatcher.dispatchWebSocketOnWindow(e);
3186
+ }
3187
+ onClose() {
3188
+ this.customEventDispatcher.dispatchOnWindow(ie.CLOSE), this.intervalId && clearInterval(this.intervalId);
3189
+ }
3190
+ closeConnection() {
3191
+ if (!this.webSocket) {
3192
+ console.warn("No connection to close");
3193
+ return;
3194
+ }
3195
+ this.webSocket.close();
3196
+ }
3197
+ isConnectionOpen() {
3198
+ var t;
3199
+ return ((t = this.webSocket) == null ? void 0 : t.readyState) === 1;
3200
+ }
3201
+ isConnecting() {
3202
+ var t;
3203
+ return ((t = this.webSocket) == null ? void 0 : t.readyState) === 0;
3204
+ }
3205
+ isClosing() {
3206
+ var t;
3207
+ return ((t = this.webSocket) == null ? void 0 : t.readyState) === 2;
3208
+ }
3209
+ isClosed() {
3210
+ var t;
3211
+ return ((t = this.webSocket) == null ? void 0 : t.readyState) === 3;
3212
+ }
3213
+ send(t) {
3214
+ if (!this.webSocket) throw new Error("NO webSocket to send data");
3215
+ this.webSocket.send(t.getPayload());
3216
+ }
3217
+ setBaseUrl(t) {
3218
+ this.baseUrl = t;
3219
+ }
3220
+ };
3221
+ at = Bs([
3222
+ bt(),
3223
+ Hs(0, Ns(Ve))
3224
+ ], at);
2524
3225
  export {
2525
- Ye as APIErrorHandlerRegistry,
2526
- Rs as AbstractSubject,
2527
- ze as AccessControl,
2528
- se as AccessLevel,
2529
- bs as Action,
2530
- ve as Amount,
2531
- Ys as ApiBuilder,
2532
- te as ApplicationDrawerStatus,
2533
- Bs as ApplicationInitializer,
2534
- Ce as ApplicationTheme,
2535
- Ge as AuthorizationDirective,
2536
- Ae as AuthorizationService,
2537
- ge as BaseModel,
2538
- Bt as BaseTable,
2539
- D as BehaviorSubject,
2540
- Me as CellType,
2541
- Zs as ClientArraySearch,
2542
- Wt as ClientSearch,
2543
- Is as Column,
2544
- be as CommonMaskFormats,
2545
- Ws as CrudService,
2546
- W as DateConverter,
2547
- rs as DateDisabledOptions,
2548
- ee as DateFormat,
2549
- it as DateFormats,
2550
- fe as DateTools,
2551
- $s as DebounceService,
2552
- $ as DialogDimensions,
2553
- as as EveryAccess,
2554
- ns as EveryLevelAuthorizationDirective,
2555
- js as Feedback,
2556
- Os as FetchListResponse,
2557
- ms as FormManager,
2558
- me as FormValidationStatus,
2559
- _ as Formatter,
2560
- Ls as GColumn,
2561
- xs as GTable,
2562
- Vs as HandleError,
2563
- Fs as HandleFeedback,
2564
- _e as HeaderType,
2565
- Ns as HttpClient,
2566
- hs as InputControl,
2567
- ds as InputControlBuilder,
2568
- jt as InputControlData,
2569
- Ne as JsonMapper,
2570
- v as LoadingStatus,
2571
- K as MinifiedSymbolModel,
2572
- qt as Params,
2573
- Gs as Process,
2574
- zs as ProcessManager,
2575
- ss as RangeValue,
2576
- Js as RouteGuard,
2577
- Je as Scheduler,
2578
- ys as SelectableTable,
2579
- _s as SelectableTableGenerator,
2580
- Fe as SimpleSort,
2581
- is as SomeAccess,
2582
- os as SomeLevelsAuthorizationDirective,
2583
- xe as SortDetail,
2584
- O as SortOrder,
2585
- $t as SortOrderTableHeader,
2586
- ps as Sorter,
2587
- Vt as StatusCode,
2588
- Y as StorageKeys,
2589
- Le as StoreNames,
2590
- tr as SymbolInTrade,
2591
- er as SymbolPriceInTrade,
2592
- Ft as Symbols,
2593
- Es as SyncDetail,
2594
- gs as TABLE_ACTION_COLUMN,
2595
- Ze as TABLE_COLUMN_DEFAULT_COLSPAN,
2596
- Nt as TABLE_COLUMN_DEFAULT_VALUES,
2597
- We as TABLE_COLUMN_DEFAULT_WIDTH,
2598
- ws as Table,
2599
- Cs as TableCellComponentRegistry,
2600
- Ms as TableConfig,
2601
- qe as TableConstants,
2602
- As as TableDestroy,
2603
- Ut as TableGenerator,
2604
- Re as TableHeaderAlign,
2605
- Ds as TableRowClick,
2606
- Ke as ToastLocation,
2607
- Us as ToastMessage,
2608
- Jt as ToastType,
2609
- fs as TouchSensitiveControl,
2610
- Qs as TradeAmount,
2611
- Xs as TradeDate,
2612
- Z as Util,
2613
- Ks as VisibilityManager,
2614
- Xe as VisibilityState,
2615
- rt as cards,
2616
- Ss as generateHeader,
2617
- at as ibans,
2618
- Yt as isEmpty,
2619
- cs as isLastItem,
2620
- ls as isOnlyOneItem,
2621
- Pt as setupJalaliDate,
2622
- us as setupStore,
2623
- Ps as useCrud,
2624
- Ht as useData,
2625
- Hs as useDialogService,
2626
- qs as useDrawerService,
2627
- vs as useForm,
2628
- Gt as useLoadingStatus,
2629
- zt as useParams,
2630
- ks as useRepository,
2631
- Ts as useStaticTableService
3226
+ rt as APIErrorHandlerRegistry,
3227
+ yr as AbstractSubject,
3228
+ ht as AccessControl,
3229
+ ae as AccessLevel,
3230
+ vr as Action,
3231
+ Re as Amount,
3232
+ kr as ApiBuilder,
3233
+ ne as ApplicationDrawerStatus,
3234
+ Tr as ApplicationInitializer,
3235
+ Ue as ApplicationTheme,
3236
+ dt as AuthorizationDirective,
3237
+ Le as AuthorizationService,
3238
+ De as BaseModel,
3239
+ ds as BaseTable,
3240
+ A as BehaviorSubject,
3241
+ Ye as CellType,
3242
+ Br as ClientArraySearch,
3243
+ ws as ClientSearch,
3244
+ fr as Column,
3245
+ Pe as CommonMaskFormats,
3246
+ Ur as CrudService,
3247
+ Ve as CustomEventDispatcher,
3248
+ Z as DateConverter,
3249
+ Ks as DateDisabledOptions,
3250
+ re as DateFormat,
3251
+ Et as DateFormats,
3252
+ we as DateTools,
3253
+ Er as DebounceService,
3254
+ V as DialogDimensions,
3255
+ Zs as EveryAccess,
3256
+ Qs as EveryLevelAuthorizationDirective,
3257
+ Lr as Feedback,
3258
+ Dr as FetchListResponse,
3259
+ or as FormManager,
3260
+ Se as FormValidationStatus,
3261
+ C as Formatter,
3262
+ br as GColumn,
3263
+ Rr as GTable,
3264
+ Or as HandleError,
3265
+ Pr as HandleFeedback,
3266
+ Fe as HeaderType,
3267
+ xr as HttpClient,
3268
+ nr as InputControl,
3269
+ ir as InputControlBuilder,
3270
+ cs as InputControlData,
3271
+ nt as JsonMapper,
3272
+ g as LoadingStatus,
3273
+ ee as MinifiedSymbolModel,
3274
+ Gr as OnEvent,
3275
+ vs as Params,
3276
+ Fr as Process,
3277
+ jr as ProcessManager,
3278
+ Gs as RangeValue,
3279
+ Yr as RouteGuard,
3280
+ ft as Scheduler,
3281
+ hr as SelectableTable,
3282
+ wr as SelectableTableGenerator,
3283
+ tt as SimpleSort,
3284
+ Xs as SomeAccess,
3285
+ er as SomeLevelsAuthorizationDirective,
3286
+ He as SortDetail,
3287
+ L as SortOrder,
3288
+ as as SortOrderTableHeader,
3289
+ ur as Sorter,
3290
+ os as StatusCode,
3291
+ U as StorageKeys,
3292
+ Be as StoreNames,
3293
+ Jr as SymbolInTrade,
3294
+ Wr as SymbolPriceInTrade,
3295
+ ls as Symbols,
3296
+ Ar as SyncDetail,
3297
+ cr as TABLE_ACTION_COLUMN,
3298
+ vt as TABLE_COLUMN_DEFAULT_COLSPAN,
3299
+ hs as TABLE_COLUMN_DEFAULT_VALUES,
3300
+ pt as TABLE_COLUMN_DEFAULT_WIDTH,
3301
+ pr as Table,
3302
+ Ir as TableCellComponentRegistry,
3303
+ Sr as TableConfig,
3304
+ ut as TableConstants,
3305
+ gr as TableDestroy,
3306
+ fs as TableGenerator,
3307
+ je as TableHeaderAlign,
3308
+ mr as TableRowClick,
3309
+ gt as ToastLocation,
3310
+ $r as ToastMessage,
3311
+ ys as ToastType,
3312
+ ar as TouchSensitiveControl,
3313
+ zr as TradeAmount,
3314
+ qr as TradeDate,
3315
+ Q as Util,
3316
+ Hr as VisibilityManager,
3317
+ mt as VisibilityState,
3318
+ We as WebSocketEvent,
3319
+ ie as WebSocketEvents,
3320
+ Kr as WebSocketPostMessage,
3321
+ at as WebSocketService,
3322
+ Ct as cards,
3323
+ dr as generateHeader,
3324
+ Mt as ibans,
3325
+ us as isEmpty,
3326
+ sr as isLastItem,
3327
+ tr as isOnlyOneItem,
3328
+ is as setupJalaliDate,
3329
+ rr as setupStore,
3330
+ Mr as useCrud,
3331
+ ps as useData,
3332
+ Vr as useDialogService,
3333
+ Nr as useDrawerService,
3334
+ lr as useForm,
3335
+ ms as useLoadingStatus,
3336
+ gs as useParams,
3337
+ _r as useRepository,
3338
+ Cr as useStaticTableService
2632
3339
  };