@avakhula/ui 0.0.192 → 0.0.194

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -2123,6 +2123,9 @@ const ws = {
2123
2123
  value(t) {
2124
2124
  this.actualValue = t;
2125
2125
  },
2126
+ modelValue(t) {
2127
+ this.actualValue = t;
2128
+ },
2126
2129
  disabled(t) {
2127
2130
  this.$globalEvents.$emit(`label:disabled:${this.id}`, t);
2128
2131
  }
@@ -2240,7 +2243,7 @@ function Cs(t, n, e, i, o, r) {
2240
2243
  ], 2)
2241
2244
  ]);
2242
2245
  }
2243
- const Do = /* @__PURE__ */ Ae(ws, [["render", Cs], ["__scopeId", "data-v-c017a33c"]]);
2246
+ const Do = /* @__PURE__ */ Ae(ws, [["render", Cs], ["__scopeId", "data-v-06d0b572"]]);
2244
2247
  const Es = {
2245
2248
  name: "IbCheckbox",
2246
2249
  model: {
@@ -3542,16 +3545,21 @@ const eu = {
3542
3545
  checkIfOptionsChecked(t) {
3543
3546
  return t.every((n) => n.checked);
3544
3547
  },
3548
+ onCheck(t, n, e) {
3549
+ this.registerCheck(t, n, e);
3550
+ const i = Object.keys(this.selected);
3551
+ this.isMultiple ? (this.$emit("update:modelValue", i), this.$emit("input", i)) : (this.$emit("update:modelValue", i[0]), this.$emit("input", i[0]));
3552
+ },
3545
3553
  registerCheck(t, n, e) {
3546
3554
  if (n)
3547
3555
  if (t.checked = !0, this.isMultiple)
3548
- this.onlyEndNodes && t.children && t.children.length || (this.selected[t.id] = t, this.$emit("update:modelValue", Object.keys(this.selected)), this.$emit("input", Object.keys(this.selected)));
3556
+ this.onlyEndNodes && t.children && t.children.length || (this.selected[t.id] = t);
3549
3557
  else {
3550
3558
  const i = Object.keys(this.selected)[0];
3551
3559
  i && (this.selected[i].checked = !1), this.selected = { [t.id]: t }, this.change();
3552
3560
  }
3553
3561
  else
3554
- delete this.selected[t.id], t.checked = !1, this.$emit("update:modelValue", Object.keys(this.selected)), this.$emit("input", Object.keys(this.selected));
3562
+ delete this.selected[t.id], t.checked = !1;
3555
3563
  this.toggleDuplicateOptions(this.actualOptions, t.id, n), e && (this.allOptionsIsChecked = this.checkIfOptionsChecked(
3556
3564
  this.actualOptions
3557
3565
  ));
@@ -3563,7 +3571,7 @@ const eu = {
3563
3571
  manageAll() {
3564
3572
  this.allOptionsIsChecked = !this.allOptionsIsChecked, this.traverseTree(this.actualOptions, (t) => {
3565
3573
  this.registerCheck(t, this.allOptionsIsChecked, !1);
3566
- });
3574
+ }), this.$emit("update:modelValue", Object.keys(this.selected)), this.$emit("input", Object.keys(this.selected));
3567
3575
  },
3568
3576
  traverseTree(t, n) {
3569
3577
  t.forEach((e) => {
@@ -3705,7 +3713,7 @@ function ru(t, n, e, i, o, r) {
3705
3713
  "is-multiple": e.isMultiple,
3706
3714
  "is-bookmarkable": !0,
3707
3715
  "is-bookmarked": !0,
3708
- onCheck: r.registerCheck,
3716
+ onCheck: r.onCheck,
3709
3717
  onToggleBookmark: r.toggleBookmark,
3710
3718
  uid: o.uid,
3711
3719
  "only-end-nodes": e.onlyEndNodes,
@@ -3744,7 +3752,7 @@ function ru(t, n, e, i, o, r) {
3744
3752
  name: o.actualName,
3745
3753
  "parent-auto-check": e.parentAutoCheck,
3746
3754
  "is-multiple": e.isMultiple,
3747
- onCheck: r.registerCheck,
3755
+ onCheck: r.onCheck,
3748
3756
  onToggleBookmark: r.toggleBookmark,
3749
3757
  uid: o.uid,
3750
3758
  "only-end-nodes": e.onlyEndNodes,
@@ -3789,7 +3797,7 @@ function ru(t, n, e, i, o, r) {
3789
3797
  "parent-auto-check": e.parentAutoCheck,
3790
3798
  "is-multiple": e.isMultiple,
3791
3799
  "is-bookmarkable": e.isBookmarkable,
3792
- onCheck: r.registerCheck,
3800
+ onCheck: r.onCheck,
3793
3801
  onToggleBookmark: r.toggleBookmark,
3794
3802
  uid: o.uid,
3795
3803
  "only-end-nodes": e.onlyEndNodes,