@wikicasa-dev/components 1.9.19 → 1.9.21
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/BaseTabView.js +1 -1
- package/dist/CheckboxGroup.js +1 -1
- package/dist/UIKit/Checkbox/CheckboxGroup.vue.d.ts +6 -5
- package/dist/UIKit/Tab/BaseTabView.vue.d.ts +10 -2
- package/dist/chunks/{BaseTabView.vue_vue_type_script_setup_true_lang.DSlvTOkB.js → BaseTabView.vue_vue_type_script_setup_true_lang.RbxW2M0Y.js} +31 -31
- package/dist/chunks/CheckboxGroup.vue_vue_type_script_setup_true_lang.LCtmdrsw.js +98 -0
- package/dist/index.js +2 -2
- package/package.json +1 -1
- package/dist/chunks/CheckboxGroup.vue_vue_type_script_setup_true_lang.hSeL05pn.js +0 -99
package/dist/BaseTabView.js
CHANGED
package/dist/CheckboxGroup.js
CHANGED
|
@@ -1,19 +1,20 @@
|
|
|
1
1
|
import { CheckboxButtonType, GetterIdType } from '@wikicasa-dev/types';
|
|
2
2
|
|
|
3
|
+
type CheckboxGroupData<T extends string | number = string> = Record<T, CheckboxButtonType>;
|
|
3
4
|
declare function __VLS_template(): {
|
|
4
5
|
default?(_: {
|
|
5
6
|
isActive: (elem: CheckboxButtonType) => boolean;
|
|
6
7
|
handleChange: (checkboxValue: CheckboxButtonType) => void;
|
|
7
|
-
checkboxesData:
|
|
8
|
+
checkboxesData: CheckboxGroupData<string>;
|
|
8
9
|
}): any;
|
|
9
10
|
checkbox_elements?(_: {
|
|
10
11
|
isActive: (elem: CheckboxButtonType) => boolean;
|
|
11
12
|
handleChange: (checkboxValue: CheckboxButtonType) => void;
|
|
12
|
-
checkboxesData:
|
|
13
|
+
checkboxesData: CheckboxGroupData<string>;
|
|
13
14
|
}): any;
|
|
14
15
|
};
|
|
15
16
|
declare const __VLS_component: import('vue').DefineComponent<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
16
|
-
valuesObj?:
|
|
17
|
+
valuesObj?: CheckboxGroupData;
|
|
17
18
|
formCheckInline?: boolean;
|
|
18
19
|
customClass?: string;
|
|
19
20
|
reset?: boolean;
|
|
@@ -38,7 +39,7 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
38
39
|
resetted: () => void;
|
|
39
40
|
checkedGroup: (args_0: string) => void;
|
|
40
41
|
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
41
|
-
valuesObj?:
|
|
42
|
+
valuesObj?: CheckboxGroupData;
|
|
42
43
|
formCheckInline?: boolean;
|
|
43
44
|
customClass?: string;
|
|
44
45
|
reset?: boolean;
|
|
@@ -64,7 +65,7 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
64
65
|
onCheckedGroup?: ((args_0: string) => any) | undefined;
|
|
65
66
|
}>, {
|
|
66
67
|
reset: boolean;
|
|
67
|
-
valuesObj:
|
|
68
|
+
valuesObj: CheckboxGroupData;
|
|
68
69
|
formCheckInline: boolean;
|
|
69
70
|
customClass: string;
|
|
70
71
|
autoCheckResetAll: boolean;
|
|
@@ -14,7 +14,11 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
14
14
|
type: import('vue').PropType<string>;
|
|
15
15
|
required: true;
|
|
16
16
|
};
|
|
17
|
-
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
17
|
+
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
18
|
+
tabClicked: (args_0: {
|
|
19
|
+
tabIdx: number;
|
|
20
|
+
}) => void;
|
|
21
|
+
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
18
22
|
activeIdx: import('vue').PropType<number | undefined>;
|
|
19
23
|
tabListClasses: {
|
|
20
24
|
type: import('vue').PropType<ClassType>;
|
|
@@ -28,7 +32,11 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
28
32
|
type: import('vue').PropType<string>;
|
|
29
33
|
required: true;
|
|
30
34
|
};
|
|
31
|
-
}>> & Readonly<{
|
|
35
|
+
}>> & Readonly<{
|
|
36
|
+
onTabClicked?: ((args_0: {
|
|
37
|
+
tabIdx: number;
|
|
38
|
+
}) => any) | undefined;
|
|
39
|
+
}>, {
|
|
32
40
|
tabListClasses: ClassType;
|
|
33
41
|
tabsPosition: "top" | "bottom";
|
|
34
42
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { _ as
|
|
3
|
-
import { _ } from "./BaseTabList.vue_vue_type_script_setup_true_lang.BEX0zH-7.js";
|
|
4
|
-
import { getUID as
|
|
5
|
-
const
|
|
1
|
+
import { defineComponent as D, mergeModels as T, useModel as L, ref as c, onMounted as M, useSlots as E, computed as N, provide as u, watch as x, openBlock as l, createElementBlock as k, normalizeClass as y, createElementVNode as S, toDisplayString as z, createBlock as r, createCommentVNode as b, Fragment as U, renderList as j, withCtx as q, resolveDynamicComponent as G } from "vue";
|
|
2
|
+
import { _ as H } from "./BaseTabPanel.vue_vue_type_script_setup_true_lang.DoZHWHt1.js";
|
|
3
|
+
import { _ as C } from "./BaseTabList.vue_vue_type_script_setup_true_lang.BEX0zH-7.js";
|
|
4
|
+
import { getUID as J } from "../utils.js";
|
|
5
|
+
const K = ["id"], Z = /* @__PURE__ */ D({
|
|
6
6
|
inheritAttrs: !1,
|
|
7
7
|
__name: "BaseTabView",
|
|
8
|
-
props: /* @__PURE__ */
|
|
8
|
+
props: /* @__PURE__ */ T({
|
|
9
9
|
tabsPosition: { default: "top" },
|
|
10
10
|
tabViewDescription: {},
|
|
11
11
|
tabListClasses: { default: "" }
|
|
@@ -13,66 +13,66 @@ const H = ["id"], X = /* @__PURE__ */ F({
|
|
|
13
13
|
activeIdx: { default: 0 },
|
|
14
14
|
activeIdxModifiers: {}
|
|
15
15
|
}),
|
|
16
|
-
emits: ["update:activeIdx"],
|
|
17
|
-
setup(
|
|
18
|
-
const d =
|
|
19
|
-
|
|
20
|
-
s.value =
|
|
16
|
+
emits: /* @__PURE__ */ T(["tabClicked"], ["update:activeIdx"]),
|
|
17
|
+
setup(_, { emit: I }) {
|
|
18
|
+
const g = I, d = L(_, "activeIdx"), P = c(""), v = c(null), B = c(null), s = c("");
|
|
19
|
+
M(() => {
|
|
20
|
+
s.value = J();
|
|
21
21
|
});
|
|
22
|
-
const p =
|
|
22
|
+
const p = E(), i = (e) => e.props ?? null, m = (e) => e.type.__name === "BaseTab", f = (e, a) => ({
|
|
23
23
|
renderFn: e,
|
|
24
24
|
tabId: h(a),
|
|
25
25
|
"active-tab-panel-idx": i(e)?.["active-tab-panel-idx"] ?? a,
|
|
26
26
|
"header-title": i(e)?.["header-title"] || "",
|
|
27
27
|
class: i(e)?.class || "",
|
|
28
28
|
"tab-panel-classes": i(e)?.["tab-panel-classes"] || ""
|
|
29
|
-
}), n =
|
|
29
|
+
}), n = N(() => p.default ? p.default().reduce((e, a) => (a.children && Array.isArray(a.children) ? a.children.forEach((t) => {
|
|
30
30
|
m(t) && e.push(f(t, e.length));
|
|
31
31
|
}) : m(a) && e.push(f(a, e.length)), e), []) : []);
|
|
32
32
|
u("tabs", n), u("isTabActive", (e) => d.value === e);
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
},
|
|
33
|
+
const $ = (e) => v.value === e, h = (e) => `base-tab-${e}-${s.value}`, A = (e) => `base-tab-panel-${e}-${s.value}`, F = (e) => n.value.find((a) => a["active-tab-panel-idx"] === e)?.tabId, V = (e) => {
|
|
34
|
+
P.value = h(e);
|
|
35
|
+
}, w = (e) => {
|
|
36
36
|
const a = n.value.at(e ?? -1);
|
|
37
37
|
v.value = a?.["active-tab-panel-idx"] ?? null;
|
|
38
38
|
};
|
|
39
39
|
return u("handleClick", (e) => {
|
|
40
|
-
|
|
40
|
+
V(e), d.value = e, g("tabClicked", { tabIdx: e });
|
|
41
41
|
}), x(
|
|
42
42
|
d,
|
|
43
43
|
(e) => {
|
|
44
|
-
|
|
44
|
+
w(e ?? -1);
|
|
45
45
|
},
|
|
46
46
|
{
|
|
47
47
|
immediate: !0
|
|
48
48
|
}
|
|
49
|
-
), (e, a) => (l(),
|
|
49
|
+
), (e, a) => (l(), k("div", {
|
|
50
50
|
ref_key: "root",
|
|
51
|
-
ref:
|
|
51
|
+
ref: B,
|
|
52
52
|
class: y(e.$attrs.class)
|
|
53
53
|
}, [
|
|
54
|
-
|
|
54
|
+
S("span", {
|
|
55
55
|
id: `tablist-${s.value}`,
|
|
56
56
|
class: "uikit-sr-only"
|
|
57
|
-
},
|
|
58
|
-
e.tabsPosition === "top" ? (l(),
|
|
57
|
+
}, z(e.tabViewDescription), 9, K),
|
|
58
|
+
e.tabsPosition === "top" ? (l(), r(C, {
|
|
59
59
|
key: 0,
|
|
60
60
|
uid: s.value,
|
|
61
61
|
"tab-list-classes": e.tabListClasses
|
|
62
62
|
}, null, 8, ["uid", "tab-list-classes"])) : b("", !0),
|
|
63
|
-
(l(!0),
|
|
63
|
+
(l(!0), k(U, null, j(n.value, (t, o) => (l(), r(H, {
|
|
64
64
|
key: o,
|
|
65
|
-
id:
|
|
66
|
-
"labelled-by":
|
|
67
|
-
active:
|
|
65
|
+
id: A(o),
|
|
66
|
+
"labelled-by": F(o) || "",
|
|
67
|
+
active: $(o),
|
|
68
68
|
class: y(t["tab-panel-classes"])
|
|
69
69
|
}, {
|
|
70
|
-
default:
|
|
71
|
-
t.renderFn.children && t.renderFn.children.default ? (l(),
|
|
70
|
+
default: q(() => [
|
|
71
|
+
t.renderFn.children && t.renderFn.children.default ? (l(), r(G(t.renderFn.children.default), { key: 0 })) : b("", !0)
|
|
72
72
|
]),
|
|
73
73
|
_: 2
|
|
74
74
|
}, 1032, ["id", "labelled-by", "active", "class"]))), 128)),
|
|
75
|
-
e.tabsPosition === "bottom" ? (l(),
|
|
75
|
+
e.tabsPosition === "bottom" ? (l(), r(C, {
|
|
76
76
|
key: 1,
|
|
77
77
|
uid: s.value,
|
|
78
78
|
"tab-list-classes": e.tabListClasses
|
|
@@ -81,5 +81,5 @@ const H = ["id"], X = /* @__PURE__ */ F({
|
|
|
81
81
|
}
|
|
82
82
|
});
|
|
83
83
|
export {
|
|
84
|
-
|
|
84
|
+
Z as _
|
|
85
85
|
};
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import { defineComponent as y, useAttrs as C, ref as j, computed as i, watch as O, renderSlot as p, createElementVNode as B, normalizeClass as E, openBlock as k, createElementBlock as $, Fragment as R, renderList as w, createBlock as A, unref as K, createCommentVNode as L } from "vue";
|
|
2
|
+
import "./types-B0dZ7OiV.D29wNgoj.js";
|
|
3
|
+
import { s as G } from "./ObjectUtils.BOUbloeg.js";
|
|
4
|
+
import D from "../CheckboxBtn.js";
|
|
5
|
+
const I = (l = "") => !l || !l.trim() ? "" : (l = l.trim(), l.replace(" ", "-").toLowerCase()), M = ["id", "data-cy"], q = /* @__PURE__ */ y({
|
|
6
|
+
inheritAttrs: !1,
|
|
7
|
+
__name: "CheckboxGroup",
|
|
8
|
+
props: {
|
|
9
|
+
valuesObj: { default() {
|
|
10
|
+
return {};
|
|
11
|
+
} },
|
|
12
|
+
formCheckInline: { type: Boolean, default: !1 },
|
|
13
|
+
customClass: { default: "" },
|
|
14
|
+
reset: { type: Boolean, default: !1 },
|
|
15
|
+
autoCheckResetAll: { type: Boolean, default: !1 },
|
|
16
|
+
autoCheckResetEmpty: { type: Boolean, default: !1 },
|
|
17
|
+
manualToggleResetButton: { type: Boolean, default: !1 },
|
|
18
|
+
getKey: { default() {
|
|
19
|
+
return (l) => l.id;
|
|
20
|
+
} }
|
|
21
|
+
},
|
|
22
|
+
emits: ["resetted", "update:modelValue", "checkedGroup"],
|
|
23
|
+
setup(l, { emit: m }) {
|
|
24
|
+
const v = C(), t = l, n = m, o = j(/* @__PURE__ */ new Map()), r = i(() => {
|
|
25
|
+
for (const e in t.valuesObj) {
|
|
26
|
+
const a = t.valuesObj[e];
|
|
27
|
+
if (a.reset) return a;
|
|
28
|
+
}
|
|
29
|
+
return null;
|
|
30
|
+
}), b = i(
|
|
31
|
+
() => Object.keys(t.valuesObj).length
|
|
32
|
+
), h = i(() => {
|
|
33
|
+
let e = 0;
|
|
34
|
+
return o.value.forEach((a) => {
|
|
35
|
+
a.checked && e++;
|
|
36
|
+
}), e;
|
|
37
|
+
});
|
|
38
|
+
O(
|
|
39
|
+
() => t.reset,
|
|
40
|
+
(e) => {
|
|
41
|
+
e && (f(), n("update:modelValue", []), n("resetted"));
|
|
42
|
+
}
|
|
43
|
+
), (() => {
|
|
44
|
+
for (const e in t.valuesObj) {
|
|
45
|
+
const a = t.valuesObj[e];
|
|
46
|
+
a.checked = !!a.checked, o.value.set(e, a);
|
|
47
|
+
}
|
|
48
|
+
})();
|
|
49
|
+
const c = (e, a) => {
|
|
50
|
+
const s = o.value.get(e);
|
|
51
|
+
s && o.value.set(e, { ...s, ...a });
|
|
52
|
+
}, f = () => {
|
|
53
|
+
o.value.forEach((e) => {
|
|
54
|
+
e.checked = !1;
|
|
55
|
+
});
|
|
56
|
+
}, u = (e) => o.value.get(t.getKey(e))?.checked ?? !1, d = (e) => {
|
|
57
|
+
if (!t.valuesObj || G(t.valuesObj)) return;
|
|
58
|
+
t.valuesObj[e.id].reset && e.checked ? f() : r.value && !t.valuesObj[e.id].reset && c(t.getKey(r.value), { checked: !1 }), c(e.id, { checked: !!e.checked }), t.autoCheckResetAll && r.value && h.value === b.value - 1 && o.value.forEach((s) => {
|
|
59
|
+
s.checked = !!s.reset;
|
|
60
|
+
}), t.autoCheckResetEmpty && r.value && !h.value && (!t.manualToggleResetButton || !t.valuesObj[e.id].reset) && c(t.getKey(r.value), { checked: !0 });
|
|
61
|
+
const a = [];
|
|
62
|
+
o.value.forEach((s) => {
|
|
63
|
+
s.checked && a.push(s);
|
|
64
|
+
}), n("update:modelValue", a), n("checkedGroup", v["group-id"] || "");
|
|
65
|
+
};
|
|
66
|
+
return (e, a) => p(e.$slots, "default", {
|
|
67
|
+
isActive: u,
|
|
68
|
+
handleChange: d,
|
|
69
|
+
checkboxesData: e.valuesObj
|
|
70
|
+
}, () => [
|
|
71
|
+
B("div", {
|
|
72
|
+
id: e.$attrs["group-id"] || "",
|
|
73
|
+
class: E(["checkbox-group-container", e.$attrs.class || ""]),
|
|
74
|
+
"data-cy": e.$attrs["data-cy"] || ""
|
|
75
|
+
}, [
|
|
76
|
+
p(e.$slots, "checkbox_elements", {
|
|
77
|
+
isActive: u,
|
|
78
|
+
handleChange: d,
|
|
79
|
+
checkboxesData: e.valuesObj
|
|
80
|
+
}, () => [
|
|
81
|
+
e.valuesObj ? (k(!0), $(R, { key: 0 }, w(e.valuesObj, (s, T, g) => (k(), A(D, {
|
|
82
|
+
id: e.getKey(s),
|
|
83
|
+
key: g,
|
|
84
|
+
"data-cy": `checkbox_${K(I)(`${s.label}`)}`,
|
|
85
|
+
label: s.label,
|
|
86
|
+
inline: e.formCheckInline,
|
|
87
|
+
"wrapper-margin-y": e.$attrs["checkbox-padding-y"],
|
|
88
|
+
"model-value": u(s),
|
|
89
|
+
onChange: d
|
|
90
|
+
}, null, 8, ["id", "data-cy", "label", "inline", "wrapper-margin-y", "model-value"]))), 128)) : L("", !0)
|
|
91
|
+
])
|
|
92
|
+
], 10, M)
|
|
93
|
+
]);
|
|
94
|
+
}
|
|
95
|
+
});
|
|
96
|
+
export {
|
|
97
|
+
q as _
|
|
98
|
+
};
|
package/dist/index.js
CHANGED
|
@@ -4,9 +4,9 @@ import { _ as f } from "./chunks/BaseAccordionContent.vue_vue_type_script_setup_
|
|
|
4
4
|
import { _ as m } from "./chunks/BaseAccordionItem.vue_vue_type_script_setup_true_lang.CR-nWss7.js";
|
|
5
5
|
import { _ as l } from "./chunks/SelectItem.vue_vue_type_script_setup_true_lang.GPFf7fjA.js";
|
|
6
6
|
import { default as d } from "./CheckboxBtn.js";
|
|
7
|
-
import { _ as i } from "./chunks/CheckboxGroup.vue_vue_type_script_setup_true_lang.
|
|
7
|
+
import { _ as i } from "./chunks/CheckboxGroup.vue_vue_type_script_setup_true_lang.LCtmdrsw.js";
|
|
8
8
|
import { _ } from "./chunks/BaseTab.vue_vue_type_script_setup_true_lang.Cu67jd8K.js";
|
|
9
|
-
import { _ as S } from "./chunks/BaseTabView.vue_vue_type_script_setup_true_lang.
|
|
9
|
+
import { _ as S } from "./chunks/BaseTabView.vue_vue_type_script_setup_true_lang.RbxW2M0Y.js";
|
|
10
10
|
import { _ as g } from "./chunks/RadioButton.vue_vue_type_script_setup_true_lang.DR6a7QAi.js";
|
|
11
11
|
import { _ as h } from "./chunks/RadioGroup.vue_vue_type_script_setup_true_lang.BYlMCUWP.js";
|
|
12
12
|
import { _ as I } from "./chunks/AccessibleSelect.vue_vue_type_script_setup_true_lang.BZJiuA9q.js";
|
package/package.json
CHANGED
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import { defineComponent as O, useAttrs as v, reactive as g, computed as d, watch as y, onBeforeMount as C, renderSlot as k, createElementVNode as V, normalizeClass as B, openBlock as b, createElementBlock as $, Fragment as R, renderList as A, createBlock as K, unref as w, createCommentVNode as E } from "vue";
|
|
2
|
-
import "./types-B0dZ7OiV.D29wNgoj.js";
|
|
3
|
-
import { s as L } from "./ObjectUtils.BOUbloeg.js";
|
|
4
|
-
import G from "../CheckboxBtn.js";
|
|
5
|
-
const D = (l = "") => !l || !l.trim() ? "" : (l = l.trim(), l.replace(" ", "-").toLowerCase()), I = ["id", "data-cy"], S = /* @__PURE__ */ O({
|
|
6
|
-
inheritAttrs: !1,
|
|
7
|
-
__name: "CheckboxGroup",
|
|
8
|
-
props: {
|
|
9
|
-
valuesObj: { default() {
|
|
10
|
-
return {};
|
|
11
|
-
} },
|
|
12
|
-
formCheckInline: { type: Boolean, default: !1 },
|
|
13
|
-
customClass: { default: "" },
|
|
14
|
-
reset: { type: Boolean, default: !1 },
|
|
15
|
-
autoCheckResetAll: { type: Boolean, default: !1 },
|
|
16
|
-
autoCheckResetEmpty: { type: Boolean, default: !1 },
|
|
17
|
-
manualToggleResetButton: { type: Boolean, default: !1 },
|
|
18
|
-
getKey: { default() {
|
|
19
|
-
return (l) => l.id;
|
|
20
|
-
} }
|
|
21
|
-
},
|
|
22
|
-
emits: ["resetted", "update:modelValue", "checkedGroup"],
|
|
23
|
-
setup(l, { emit: f }) {
|
|
24
|
-
const m = v(), t = l, o = f, s = g({
|
|
25
|
-
checkedValuesObj: {}
|
|
26
|
-
}), c = d(() => {
|
|
27
|
-
for (const e in t.valuesObj) {
|
|
28
|
-
const a = t.valuesObj[e];
|
|
29
|
-
if (a.reset) return a;
|
|
30
|
-
}
|
|
31
|
-
return null;
|
|
32
|
-
}), p = d(
|
|
33
|
-
() => Object.keys(t.valuesObj).length
|
|
34
|
-
), h = d(
|
|
35
|
-
() => Object.values(s.checkedValuesObj).reduce(
|
|
36
|
-
(e, a) => a.checked ? e + 1 : e,
|
|
37
|
-
0
|
|
38
|
-
)
|
|
39
|
-
);
|
|
40
|
-
y(
|
|
41
|
-
() => t.reset,
|
|
42
|
-
(e) => {
|
|
43
|
-
e && (i(), o("update:modelValue", []), o("resetted"));
|
|
44
|
-
}
|
|
45
|
-
), C(() => {
|
|
46
|
-
for (const e in t.valuesObj) {
|
|
47
|
-
const a = t.valuesObj[e];
|
|
48
|
-
a.checked = !!a.checked, s.checkedValuesObj[e] = a;
|
|
49
|
-
}
|
|
50
|
-
});
|
|
51
|
-
const i = () => {
|
|
52
|
-
for (const e in s.checkedValuesObj)
|
|
53
|
-
s.checkedValuesObj[e].checked = !1;
|
|
54
|
-
}, n = (e) => s.checkedValuesObj[t.getKey(e)].checked, u = (e) => {
|
|
55
|
-
if (!(!t.valuesObj || L(t.valuesObj))) {
|
|
56
|
-
if (t.valuesObj[e.id].reset && e.checked ? i() : c.value && !t.valuesObj[e.id].reset && (s.checkedValuesObj[t.getKey(c.value)].checked = !1), s.checkedValuesObj[e.id].checked = !!e.checked, t.autoCheckResetAll && c.value && h.value === p.value - 1)
|
|
57
|
-
for (const a in s.checkedValuesObj)
|
|
58
|
-
s.checkedValuesObj[a].checked = !!s.checkedValuesObj[a].reset;
|
|
59
|
-
t.autoCheckResetEmpty && c.value && !h.value && (!t.manualToggleResetButton || !t.valuesObj[e.id].reset) && (s.checkedValuesObj[t.getKey(c.value)].checked = !0), o(
|
|
60
|
-
"update:modelValue",
|
|
61
|
-
Object.values(s.checkedValuesObj).filter(
|
|
62
|
-
(a) => a.checked
|
|
63
|
-
)
|
|
64
|
-
), o("checkedGroup", m["group-id"] || "");
|
|
65
|
-
}
|
|
66
|
-
};
|
|
67
|
-
return (e, a) => k(e.$slots, "default", {
|
|
68
|
-
isActive: n,
|
|
69
|
-
handleChange: u,
|
|
70
|
-
checkboxesData: e.valuesObj
|
|
71
|
-
}, () => [
|
|
72
|
-
V("div", {
|
|
73
|
-
id: e.$attrs["group-id"] || "",
|
|
74
|
-
class: B(["checkbox-group-container", e.$attrs.class || ""]),
|
|
75
|
-
"data-cy": e.$attrs["data-cy"] || ""
|
|
76
|
-
}, [
|
|
77
|
-
k(e.$slots, "checkbox_elements", {
|
|
78
|
-
isActive: n,
|
|
79
|
-
handleChange: u,
|
|
80
|
-
checkboxesData: e.valuesObj
|
|
81
|
-
}, () => [
|
|
82
|
-
e.valuesObj ? (b(!0), $(R, { key: 0 }, A(e.valuesObj, (r, N, j) => (b(), K(G, {
|
|
83
|
-
id: e.getKey(r),
|
|
84
|
-
key: j,
|
|
85
|
-
"data-cy": `checkbox_${w(D)(`${r.label}`)}`,
|
|
86
|
-
label: r.label,
|
|
87
|
-
inline: e.formCheckInline,
|
|
88
|
-
"wrapper-margin-y": e.$attrs["checkbox-padding-y"],
|
|
89
|
-
"model-value": n(r),
|
|
90
|
-
onChange: u
|
|
91
|
-
}, null, 8, ["id", "data-cy", "label", "inline", "wrapper-margin-y", "model-value"]))), 128)) : E("", !0)
|
|
92
|
-
])
|
|
93
|
-
], 10, I)
|
|
94
|
-
]);
|
|
95
|
-
}
|
|
96
|
-
});
|
|
97
|
-
export {
|
|
98
|
-
S as _
|
|
99
|
-
};
|