@avakhula/ui 0.0.193 → 0.0.195

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/TODO ADDED
@@ -0,0 +1,12 @@
1
+ [ ] topLeft
2
+ [X] topCenter
3
+ [ ] topRight
4
+ [ ] rightTop
5
+ [X] rightCenter
6
+ [ ] rightBottom
7
+ [ ] bottomLeft
8
+ [X] bottomCenter
9
+ [ ] bottomRight
10
+ [ ] leftTop
11
+ [ ] leftCenter
12
+ [ ] leftBottom
package/dist/index.js CHANGED
@@ -577,7 +577,11 @@ const cn = /* @__PURE__ */ Ae(Ba, [["render", Ua], ["__scopeId", "data-v-dec06c4
577
577
  const Ka = {
578
578
  name: "IbAvatar",
579
579
  props: {
580
- name: {
580
+ firstName: {
581
+ type: String,
582
+ default: ""
583
+ },
584
+ lastName: {
581
585
  type: String,
582
586
  default: ""
583
587
  },
@@ -599,12 +603,11 @@ const Ka = {
599
603
  return ["avatar", `avatar-size-${this.size}`];
600
604
  },
601
605
  validateName() {
602
- var t;
603
- return ((t = this.name) == null ? void 0 : t.trim().split(" ").length) < 2;
606
+ var t, n;
607
+ return ((t = this.firstName) == null ? void 0 : t.trim().length) !== 0 && ((n = this.lastName) == null ? void 0 : n.trim().length) !== 0;
604
608
  },
605
609
  initials() {
606
- const t = this.name.split(" ");
607
- return t.length === 1 ? (t[0][0] + t[0][1]).toUpperCase() : (t[0][0] + t[1][0]).toUpperCase();
610
+ return this.firstName[0].toUpperCase() + this.lastName[0].toUpperCase();
608
611
  }
609
612
  },
610
613
  components: {
@@ -617,7 +620,7 @@ function Ya(t, n, e, i, o, r) {
617
620
  key: 0,
618
621
  class: ve(r.classList),
619
622
  src: e.src,
620
- alt: e.name
623
+ alt: e.firstName + "" + e.lastName
621
624
  }, null, 10, Ga)) : e.src && e.userAvatar ? (G(), ne("div", {
622
625
  key: 1,
623
626
  class: ve(["user-avatar", r.classList]),
@@ -625,16 +628,16 @@ function Ya(t, n, e, i, o, r) {
625
628
  backgroundImage: "url(" + e.src + ")"
626
629
  })
627
630
  }, null, 6)) : r.validateName ? (G(), ne("div", {
631
+ key: 3,
632
+ class: ve([r.classList, "default-avatar"])
633
+ }, we(r.initials), 3)) : (G(), ne("div", {
628
634
  key: 2,
629
635
  class: ve(["empty-avatar", r.classList])
630
636
  }, [
631
637
  ge(l, { name: "camera-outline" })
632
- ], 2)) : (G(), ne("div", {
633
- key: 3,
634
- class: ve([r.classList, "default-avatar"])
635
- }, we(r.initials), 3));
638
+ ], 2));
636
639
  }
637
- const Uh = /* @__PURE__ */ Ae(Ka, [["render", Ya], ["__scopeId", "data-v-39ebf93c"]]);
640
+ const Uh = /* @__PURE__ */ Ae(Ka, [["render", Ya], ["__scopeId", "data-v-8ba12d0f"]]);
638
641
  const Wa = {
639
642
  name: "IbBadge",
640
643
  props: {
@@ -2123,9 +2126,6 @@ const ws = {
2123
2126
  value(t) {
2124
2127
  this.actualValue = t;
2125
2128
  },
2126
- modelValue(t) {
2127
- this.actualValue = t;
2128
- },
2129
2129
  disabled(t) {
2130
2130
  this.$globalEvents.$emit(`label:disabled:${this.id}`, t);
2131
2131
  }
@@ -2243,7 +2243,7 @@ function Cs(t, n, e, i, o, r) {
2243
2243
  ], 2)
2244
2244
  ]);
2245
2245
  }
2246
- const Do = /* @__PURE__ */ Ae(ws, [["render", Cs], ["__scopeId", "data-v-06d0b572"]]);
2246
+ const Do = /* @__PURE__ */ Ae(ws, [["render", Cs], ["__scopeId", "data-v-c017a33c"]]);
2247
2247
  const Es = {
2248
2248
  name: "IbCheckbox",
2249
2249
  model: {
@@ -3545,19 +3545,16 @@ const eu = {
3545
3545
  checkIfOptionsChecked(t) {
3546
3546
  return t.every((n) => n.checked);
3547
3547
  },
3548
- onCheck(t, n, e) {
3549
- this.registerCheck(t, n, e), this.$emit("update:modelValue", Object.keys(this.selected)), this.$emit("input", Object.keys(this.selected));
3550
- },
3551
3548
  registerCheck(t, n, e) {
3552
3549
  if (n)
3553
3550
  if (t.checked = !0, this.isMultiple)
3554
- this.onlyEndNodes && t.children && t.children.length || (this.selected[t.id] = t);
3551
+ 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)));
3555
3552
  else {
3556
3553
  const i = Object.keys(this.selected)[0];
3557
3554
  i && (this.selected[i].checked = !1), this.selected = { [t.id]: t }, this.change();
3558
3555
  }
3559
3556
  else
3560
- delete this.selected[t.id], t.checked = !1;
3557
+ delete this.selected[t.id], t.checked = !1, this.$emit("update:modelValue", Object.keys(this.selected)), this.$emit("input", Object.keys(this.selected));
3561
3558
  this.toggleDuplicateOptions(this.actualOptions, t.id, n), e && (this.allOptionsIsChecked = this.checkIfOptionsChecked(
3562
3559
  this.actualOptions
3563
3560
  ));
@@ -3569,7 +3566,7 @@ const eu = {
3569
3566
  manageAll() {
3570
3567
  this.allOptionsIsChecked = !this.allOptionsIsChecked, this.traverseTree(this.actualOptions, (t) => {
3571
3568
  this.registerCheck(t, this.allOptionsIsChecked, !1);
3572
- }), this.$emit("update:modelValue", Object.keys(this.selected)), this.$emit("input", Object.keys(this.selected));
3569
+ });
3573
3570
  },
3574
3571
  traverseTree(t, n) {
3575
3572
  t.forEach((e) => {
@@ -3711,7 +3708,7 @@ function ru(t, n, e, i, o, r) {
3711
3708
  "is-multiple": e.isMultiple,
3712
3709
  "is-bookmarkable": !0,
3713
3710
  "is-bookmarked": !0,
3714
- onCheck: r.onCheck,
3711
+ onCheck: r.registerCheck,
3715
3712
  onToggleBookmark: r.toggleBookmark,
3716
3713
  uid: o.uid,
3717
3714
  "only-end-nodes": e.onlyEndNodes,
@@ -3750,7 +3747,7 @@ function ru(t, n, e, i, o, r) {
3750
3747
  name: o.actualName,
3751
3748
  "parent-auto-check": e.parentAutoCheck,
3752
3749
  "is-multiple": e.isMultiple,
3753
- onCheck: r.onCheck,
3750
+ onCheck: r.registerCheck,
3754
3751
  onToggleBookmark: r.toggleBookmark,
3755
3752
  uid: o.uid,
3756
3753
  "only-end-nodes": e.onlyEndNodes,
@@ -3795,7 +3792,7 @@ function ru(t, n, e, i, o, r) {
3795
3792
  "parent-auto-check": e.parentAutoCheck,
3796
3793
  "is-multiple": e.isMultiple,
3797
3794
  "is-bookmarkable": e.isBookmarkable,
3798
- onCheck: r.onCheck,
3795
+ onCheck: r.registerCheck,
3799
3796
  onToggleBookmark: r.toggleBookmark,
3800
3797
  uid: o.uid,
3801
3798
  "only-end-nodes": e.onlyEndNodes,