ps-toolkit-ui 1.17.1 → 1.17.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2394,7 +2394,7 @@
2394
2394
  }
2395
2395
  }
2396
2396
  var setD = function (n, vl) {
2397
- var e_1, _b;
2397
+ var e_1, _c;
2398
2398
  if (d instanceof FormData) {
2399
2399
  if (vl instanceof Array) {
2400
2400
  try {
@@ -2406,7 +2406,7 @@
2406
2406
  catch (e_1_1) { e_1 = { error: e_1_1 }; }
2407
2407
  finally {
2408
2408
  try {
2409
- if (vl_1_1 && !vl_1_1.done && (_b = vl_1.return)) _b.call(vl_1);
2409
+ if (vl_1_1 && !vl_1_1.done && (_c = vl_1.return)) _c.call(vl_1);
2410
2410
  }
2411
2411
  finally { if (e_1) throw e_1.error; }
2412
2412
  }
@@ -2430,20 +2430,20 @@
2430
2430
  }
2431
2431
  };
2432
2432
  this.inputs.forEach(function (inp) {
2433
- var e_2, _b;
2433
+ var e_2, _c;
2434
2434
  var vl = inp.data();
2435
2435
  if (vl !== null) {
2436
2436
  if (typeof vl === 'object' && !(vl instanceof Array)) {
2437
2437
  try {
2438
- for (var _c = __values(Object.entries(vl)), _d = _c.next(); !_d.done; _d = _c.next()) {
2439
- var _e = __read(_d.value, 2), key = _e[0], value = _e[1];
2438
+ for (var _d = __values(Object.entries(vl)), _e = _d.next(); !_e.done; _e = _d.next()) {
2439
+ var _f = __read(_e.value, 2), key = _f[0], value = _f[1];
2440
2440
  setD(key, value);
2441
2441
  }
2442
2442
  }
2443
2443
  catch (e_2_1) { e_2 = { error: e_2_1 }; }
2444
2444
  finally {
2445
2445
  try {
2446
- if (_d && !_d.done && (_b = _c.return)) _b.call(_c);
2446
+ if (_e && !_e.done && (_c = _d.return)) _c.call(_d);
2447
2447
  }
2448
2448
  finally { if (e_2) throw e_2.error; }
2449
2449
  }
@@ -2461,7 +2461,7 @@
2461
2461
  d = {};
2462
2462
  }
2463
2463
  this.inputs.forEach(function (inp) {
2464
- var e_3, _b;
2464
+ var e_3, _c;
2465
2465
  var vl = inp.data();
2466
2466
  if (vl !== null && vl !== '') {
2467
2467
  if (vl instanceof Array) {
@@ -2474,7 +2474,7 @@
2474
2474
  catch (e_3_1) { e_3 = { error: e_3_1 }; }
2475
2475
  finally {
2476
2476
  try {
2477
- if (vl_2_1 && !vl_2_1.done && (_b = vl_2.return)) _b.call(vl_2);
2477
+ if (vl_2_1 && !vl_2_1.done && (_c = vl_2.return)) _c.call(vl_2);
2478
2478
  }
2479
2479
  finally { if (e_3) throw e_3.error; }
2480
2480
  }
@@ -2683,7 +2683,8 @@
2683
2683
  };
2684
2684
  InputClass.prototype.getSelectedOptionData = function () {
2685
2685
  var _this = this;
2686
- return this.options.find(function (x) { return x.value === _this.value; }).option;
2686
+ var _a, _b;
2687
+ return (_b = (_a = this.options.find(function (x) { return x.value === _this.value; })) === null || _a === void 0 ? void 0 : _a.option) !== null && _b !== void 0 ? _b : null;
2687
2688
  };
2688
2689
  InputClass.prototype.getOptions = function (r, p, tree) {
2689
2690
  var _this = this;
@@ -2725,7 +2726,7 @@
2725
2726
  return this.getSelectedOptions(opts).map(function (x) { return x.value; });
2726
2727
  };
2727
2728
  InputClass.prototype.getSelectedOptions = function (opts) {
2728
- var e_4, _b;
2729
+ var e_4, _c;
2729
2730
  if (opts === void 0) { opts = this.options; }
2730
2731
  var l = [];
2731
2732
  try {
@@ -2741,14 +2742,14 @@
2741
2742
  catch (e_4_1) { e_4 = { error: e_4_1 }; }
2742
2743
  finally {
2743
2744
  try {
2744
- if (opts_1_1 && !opts_1_1.done && (_b = opts_1.return)) _b.call(opts_1);
2745
+ if (opts_1_1 && !opts_1_1.done && (_c = opts_1.return)) _c.call(opts_1);
2745
2746
  }
2746
2747
  finally { if (e_4) throw e_4.error; }
2747
2748
  }
2748
2749
  return l;
2749
2750
  };
2750
2751
  InputClass.prototype.getSelectedRows = function (rows) {
2751
- var e_5, _b;
2752
+ var e_5, _c;
2752
2753
  if (rows === void 0) { rows = this.rows; }
2753
2754
  var l = [];
2754
2755
  try {
@@ -2764,14 +2765,14 @@
2764
2765
  catch (e_5_1) { e_5 = { error: e_5_1 }; }
2765
2766
  finally {
2766
2767
  try {
2767
- if (rows_1_1 && !rows_1_1.done && (_b = rows_1.return)) _b.call(rows_1);
2768
+ if (rows_1_1 && !rows_1_1.done && (_c = rows_1.return)) _c.call(rows_1);
2768
2769
  }
2769
2770
  finally { if (e_5) throw e_5.error; }
2770
2771
  }
2771
2772
  return l;
2772
2773
  };
2773
2774
  InputClass.prototype.getAllRows = function (rows) {
2774
- var e_6, _b;
2775
+ var e_6, _c;
2775
2776
  if (rows === void 0) { rows = this.rows; }
2776
2777
  var l = [];
2777
2778
  try {
@@ -2787,7 +2788,7 @@
2787
2788
  catch (e_6_1) { e_6 = { error: e_6_1 }; }
2788
2789
  finally {
2789
2790
  try {
2790
- if (rows_2_1 && !rows_2_1.done && (_b = rows_2.return)) _b.call(rows_2);
2791
+ if (rows_2_1 && !rows_2_1.done && (_c = rows_2.return)) _c.call(rows_2);
2791
2792
  }
2792
2793
  finally { if (e_6) throw e_6.error; }
2793
2794
  }
@@ -2847,10 +2848,10 @@
2847
2848
  this.rows = rows;
2848
2849
  }
2849
2850
  AccordionClass.prototype.check = function () {
2850
- var e_7, _b;
2851
+ var e_7, _c;
2851
2852
  try {
2852
- for (var _c = __values(this.rows), _d = _c.next(); !_d.done; _d = _c.next()) {
2853
- var row = _d.value;
2853
+ for (var _d = __values(this.rows), _e = _d.next(); !_e.done; _e = _d.next()) {
2854
+ var row = _e.value;
2854
2855
  if (!row.form.check()) {
2855
2856
  row.open();
2856
2857
  return false;
@@ -2860,7 +2861,7 @@
2860
2861
  catch (e_7_1) { e_7 = { error: e_7_1 }; }
2861
2862
  finally {
2862
2863
  try {
2863
- if (_d && !_d.done && (_b = _c.return)) _b.call(_c);
2864
+ if (_e && !_e.done && (_c = _d.return)) _c.call(_d);
2864
2865
  }
2865
2866
  finally { if (e_7) throw e_7.error; }
2866
2867
  }
@@ -9445,6 +9446,9 @@
9445
9446
  if (data.Id) {
9446
9447
  var i = _this.rows.findIndex(function (x) { return x.Data.Id === data.Id; });
9447
9448
  _this.rows[i].Data = data;
9449
+ if (_this.onLoad) {
9450
+ _this.onLoad(null);
9451
+ }
9448
9452
  }
9449
9453
  else {
9450
9454
  data.Id = parseInt(HelperClass.random(5, false, false), 10);