@wikicasa-dev/components 1.7.17 → 1.7.18

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.
@@ -1,4 +1,4 @@
1
- import { _ as f } from "./chunks/BaseTabView.vue_vue_type_script_setup_true_lang.DD-CKp6K.js";
1
+ import { _ as f } from "./chunks/BaseTabView.vue_vue_type_script_setup_true_lang.uQU5rdeC.js";
2
2
  export {
3
3
  f as default
4
4
  };
@@ -1,10 +1,10 @@
1
- import { defineComponent as E, mergeModels as L, useModel as N, ref as o, useSlots as U, computed as z, watch as R, nextTick as j, withDirectives as q, openBlock as r, createElementBlock as s, normalizeClass as p, createElementVNode as T, toDisplayString as g, Fragment as I, renderList as $, createBlock as h, resolveDynamicComponent as C, createCommentVNode as F, withCtx as G } from "vue";
1
+ import { defineComponent as L, mergeModels as N, useModel as U, ref as o, onMounted as x, useSlots as z, computed as R, watch as j, withDirectives as q, openBlock as r, createElementBlock as s, normalizeClass as p, createElementVNode as g, toDisplayString as T, Fragment as I, renderList as $, createBlock as h, resolveDynamicComponent as C, createCommentVNode as F, withCtx as G } from "vue";
2
2
  import { _ as H } from "./BaseTabPanel.vue_vue_type_script_setup_true_lang.DoZHWHt1.js";
3
3
  import { getUID as J } from "../utils.js";
4
- const K = ["id"], O = ["aria-labelledby"], Q = ["id", "aria-selected", "aria-controls", "tabindex", "onClick"], W = { key: 0 }, te = /* @__PURE__ */ E({
4
+ const K = ["id"], O = ["aria-labelledby"], Q = ["id", "aria-selected", "aria-controls", "tabindex", "onClick"], W = { key: 0 }, te = /* @__PURE__ */ L({
5
5
  inheritAttrs: !1,
6
6
  __name: "BaseTabView",
7
- props: /* @__PURE__ */ L({
7
+ props: /* @__PURE__ */ N({
8
8
  tabViewDescription: {},
9
9
  tabListClasses: { default: "" }
10
10
  }, {
@@ -13,15 +13,19 @@ const K = ["id"], O = ["aria-labelledby"], Q = ["id", "aria-selected", "aria-con
13
13
  }),
14
14
  emits: ["update:activeIdx"],
15
15
  setup(w) {
16
- const c = N(w, "activeIdx"), B = o(""), m = o(""), D = o(null), n = o(J()), f = U(), d = (e) => e.props ?? null, k = (e) => e.type.__name === "BaseTab", y = (e, a) => ({
16
+ const c = U(w, "activeIdx"), B = o(""), m = o(""), D = o(null), i = o("");
17
+ x(() => {
18
+ i.value = J();
19
+ });
20
+ const f = z(), d = (e) => e.props ?? null, k = (e) => e.type.__name === "BaseTab", y = (e, a) => ({
17
21
  renderFn: e,
18
22
  tabId: b(a),
19
23
  "active-tab-panel-idx": d(e)?.["active-tab-panel-idx"] ?? a,
20
24
  "header-title": d(e)?.["header-title"] || "",
21
25
  class: d(e)?.class || ""
22
- }), l = z(() => f.default ? f.default().reduce((e, a) => (a.children && Array.isArray(a.children) ? a.children.forEach((t) => {
26
+ }), l = R(() => f.default ? f.default().reduce((e, a) => (a.children && Array.isArray(a.children) ? a.children.forEach((t) => {
23
27
  k(t) && e.push(y(t, e.length));
24
- }) : k(a) && e.push(y(a, e.length)), e), []) : []), u = (e) => c.value === e, P = (e) => m.value === e, b = (e) => `base-tab-${e}-${n.value}`, v = (e) => `base-tab-panel-${e}-${n.value}`, A = (e) => l.value.find((a) => a["active-tab-panel-idx"] === e)?.tabId, S = (e) => {
28
+ }) : k(a) && e.push(y(a, e.length)), e), []) : []), u = (e) => c.value === e, P = (e) => m.value === e, b = (e) => `base-tab-${e}-${i.value}`, v = (e) => `base-tab-panel-${e}-${i.value}`, A = (e) => l.value.find((a) => a["active-tab-panel-idx"] === e)?.tabId, S = (e) => {
25
29
  B.value = b(e);
26
30
  }, V = (e) => {
27
31
  const a = l.value.at(e ?? -1), t = v(a?.["active-tab-panel-idx"] ?? -1);
@@ -29,18 +33,16 @@ const K = ["id"], O = ["aria-labelledby"], Q = ["id", "aria-selected", "aria-con
29
33
  }, M = (e) => {
30
34
  S(e), c.value = e;
31
35
  };
32
- R(
36
+ j(
33
37
  c,
34
38
  (e) => {
35
- j(() => {
36
- V(e ?? -1);
37
- });
39
+ V(e ?? -1);
38
40
  },
39
41
  {
40
42
  immediate: !0
41
43
  }
42
44
  );
43
- const _ = () => Date.now().toString(36) + Math.random().toString(36).substring(2), x = {
45
+ const _ = () => Date.now().toString(36) + Math.random().toString(36).substring(2), E = {
44
46
  created(e) {
45
47
  console.log("v-uid:directive", e.id), e.setAttribute("id", e.id || _());
46
48
  },
@@ -55,40 +57,40 @@ const K = ["id"], O = ["aria-labelledby"], Q = ["id", "aria-selected", "aria-con
55
57
  ref: D,
56
58
  class: p(e.$attrs.class)
57
59
  }, [
58
- T("span", {
59
- id: `tablist-${n.value}`,
60
+ g("span", {
61
+ id: `tablist-${i.value}`,
60
62
  class: "uikit-sr-only"
61
- }, g(e.tabViewDescription), 9, K),
62
- T("div", {
63
+ }, T(e.tabViewDescription), 9, K),
64
+ g("div", {
63
65
  role: "tablist",
64
- "aria-labelledby": `tablist-${n.value}`,
66
+ "aria-labelledby": `tablist-${i.value}`,
65
67
  class: p(e.tabListClasses)
66
68
  }, [
67
- (r(!0), s(I, null, $(l.value, (t, i) => (r(), s("button", {
68
- key: i,
69
- id: b(i),
69
+ (r(!0), s(I, null, $(l.value, (t, n) => (r(), s("button", {
70
+ key: n,
71
+ id: b(n),
70
72
  type: "button",
71
73
  role: "tab",
72
- "aria-selected": u(i),
73
- "aria-controls": `base-tab-panel-${i}-${n.value}`,
74
- tabindex: u(i) ? void 0 : -1,
74
+ "aria-selected": u(n),
75
+ "aria-controls": `base-tab-panel-${n}-${i.value}`,
76
+ tabindex: u(n) ? void 0 : -1,
75
77
  class: p([
76
78
  "uikit-bg-transparent uikit-p-5px",
77
79
  {
78
- "uikit-border-b-2 uikit-border-solid uikit-border-w-primary uikit-font-semibold": u(i)
80
+ "uikit-border-b-2 uikit-border-solid uikit-border-w-primary uikit-font-semibold": u(n)
79
81
  },
80
82
  t.class
81
83
  ]),
82
- onClick: (X) => M(i)
84
+ onClick: (X) => M(n)
83
85
  }, [
84
- t["header-title"] ? (r(), s("span", W, g(t["header-title"]), 1)) : t.renderFn.children && t.renderFn.children.header ? (r(), h(C(t.renderFn.children.header), { key: 1 })) : F("", !0)
86
+ t["header-title"] ? (r(), s("span", W, T(t["header-title"]), 1)) : t.renderFn.children && t.renderFn.children.header ? (r(), h(C(t.renderFn.children.header), { key: 1 })) : F("", !0)
85
87
  ], 10, Q))), 128))
86
88
  ], 10, O),
87
- (r(!0), s(I, null, $(l.value, (t, i) => (r(), h(H, {
88
- key: i,
89
- id: v(i),
90
- "labelled-by": A(i) || "",
91
- active: P(v(i))
89
+ (r(!0), s(I, null, $(l.value, (t, n) => (r(), h(H, {
90
+ key: n,
91
+ id: v(n),
92
+ "labelled-by": A(n) || "",
93
+ active: P(v(n))
92
94
  }, {
93
95
  default: G(() => [
94
96
  t.renderFn.children && t.renderFn.children.default ? (r(), h(C(t.renderFn.children.default), { key: 0 })) : F("", !0)
@@ -96,7 +98,7 @@ const K = ["id"], O = ["aria-labelledby"], Q = ["id", "aria-selected", "aria-con
96
98
  _: 2
97
99
  }, 1032, ["id", "labelled-by", "active"]))), 128))
98
100
  ], 2)), [
99
- [x]
101
+ [E]
100
102
  ]);
101
103
  }
102
104
  });
package/dist/index.js CHANGED
@@ -7,7 +7,7 @@ import { _ as l } from "./chunks/SelectItem.vue_vue_type_script_setup_true_lang.
7
7
  import { default as d } from "./CheckboxBtn.js";
8
8
  import { _ } from "./chunks/CheckboxGroup.vue_vue_type_script_setup_true_lang.DDtN9_Bg.js";
9
9
  import { _ as i } from "./chunks/BaseTab.vue_vue_type_script_setup_true_lang.BRubYI9e.js";
10
- import { _ as b } from "./chunks/BaseTabView.vue_vue_type_script_setup_true_lang.DD-CKp6K.js";
10
+ import { _ as b } from "./chunks/BaseTabView.vue_vue_type_script_setup_true_lang.uQU5rdeC.js";
11
11
  import { _ as C } from "./chunks/RadioButton.vue_vue_type_script_setup_true_lang.DR6a7QAi.js";
12
12
  import { _ as I } from "./chunks/RadioGroup.vue_vue_type_script_setup_true_lang.DTUA_Q5e.js";
13
13
  import { _ as T } from "./chunks/AccessibleSelect.vue_vue_type_script_setup_true_lang.5pqk7vlZ.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wikicasa-dev/components",
3
- "version": "1.7.17",
3
+ "version": "1.7.18",
4
4
  "description": "Wikicasa frontend components",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",