@wikicasa-dev/components 2.2.9-alpha.52 → 2.2.9-alpha.54

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,5 +1,5 @@
1
1
  import { Autoplay as t } from "swiper/modules";
2
- import '../assets/swiper-keyboard.css';/* empty css */
2
+ import '../assets/swiper-thumbs.css';/* empty css */
3
3
  export {
4
4
  t as Autoplay
5
5
  };
@@ -1,5 +1,5 @@
1
1
  import { Controller as e } from "swiper/modules";
2
- import '../assets/swiper-keyboard.css';/* empty css */
2
+ import '../assets/swiper-thumbs.css';/* empty css */
3
3
  export {
4
4
  e as Controller
5
5
  };
@@ -1,5 +1,5 @@
1
1
  import { Keyboard as m } from "swiper/modules";
2
- import '../assets/swiper-keyboard.css';/* empty css */
2
+ import '../assets/swiper-thumbs.css';/* empty css */
3
3
  export {
4
4
  m as Keyboard
5
5
  };
@@ -1,5 +1,5 @@
1
1
  import { Thumbs as p } from "swiper/modules";
2
- import '../assets/swiper-keyboard.css';/* empty css */
2
+ import '../assets/swiper-thumbs.css';/* empty css */
3
3
  export {
4
4
  p as Thumbs
5
5
  };
@@ -33,14 +33,14 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<{
33
33
  open?: Optional<boolean>;
34
34
  refresh?: Optional<boolean>;
35
35
  } & SnackbarProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
36
- "update:open": (value: Optional<boolean>) => any;
37
36
  "update:refresh": (value: Optional<boolean>) => any;
37
+ "update:open": (value: Optional<boolean>) => any;
38
38
  }, string, import('vue').PublicProps, Readonly<{
39
39
  open?: Optional<boolean>;
40
40
  refresh?: Optional<boolean>;
41
41
  } & SnackbarProps> & Readonly<{
42
- "onUpdate:open"?: ((value: Optional<boolean>) => any) | undefined;
43
42
  "onUpdate:refresh"?: ((value: Optional<boolean>) => any) | undefined;
43
+ "onUpdate:open"?: ((value: Optional<boolean>) => any) | undefined;
44
44
  }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>, {
45
45
  trigger?(_: {
46
46
  open: () => boolean;
@@ -34,9 +34,12 @@ export type CheckboxGroupProps<TID = string | number, TLabel = string | number,
34
34
  declare const _default: <TID extends string | number, TLabel extends string | number, TPayload>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
35
35
  props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
36
36
  readonly "onUpdate:modelValue"?: ((args_0: CheckboxButtonType<TID, TLabel, TPayload>[]) => any) | undefined;
37
+ readonly "onUpdate:refresh"?: ((value: boolean) => any) | undefined;
37
38
  readonly onResetted?: (() => any) | undefined;
38
39
  readonly onCheckedGroup?: ((args_0: string) => any) | undefined;
39
- } & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onUpdate:modelValue" | "onResetted" | "onCheckedGroup"> & CheckboxGroupProps<TID, TLabel, TPayload> & Partial<{}>> & import('vue').PublicProps;
40
+ } & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onUpdate:modelValue" | "onUpdate:refresh" | "onResetted" | "onCheckedGroup"> & ({
41
+ refresh?: boolean;
42
+ } & CheckboxGroupProps<TID, TLabel, TPayload>) & Partial<{}>> & import('vue').PublicProps;
40
43
  expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
41
44
  attrs: any;
42
45
  slots: {
@@ -52,7 +55,7 @@ declare const _default: <TID extends string | number, TLabel extends string | nu
52
55
  reset: () => void;
53
56
  }): any;
54
57
  };
55
- emit: ((evt: "update:modelValue", args_0: CheckboxButtonType<TID, TLabel, TPayload>[]) => void) & ((evt: "resetted") => void) & ((evt: "checkedGroup", args_0: string) => void);
58
+ emit: (((evt: "update:modelValue", args_0: CheckboxButtonType<TID, TLabel, TPayload>[]) => void) & ((evt: "resetted") => void) & ((evt: "checkedGroup", args_0: string) => void)) & ((evt: "update:refresh", value: boolean) => void);
56
59
  }>) => import('vue').VNode & {
57
60
  __ctx?: Awaited<typeof __VLS_setup>;
58
61
  };
@@ -1,28 +1,32 @@
1
- import { Nullable } from '@wikicasa-dev/types';
2
1
  import { ClassTypeProp } from '../types';
3
- type __VLS_Props = {
4
- id?: Nullable<string | number>;
5
- name?: string;
6
- label: string;
7
- modelValue?: boolean;
8
- inputClasses?: ClassTypeProp;
9
- labelClasses?: ClassTypeProp;
10
- };
11
- declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
12
- "update:modelValue": (args_0: boolean) => any;
13
- change: (args_0: {
14
- id: string | number;
15
- label: string;
2
+ declare const _default: <TID extends string | number | null>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
3
+ props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
4
+ readonly "onUpdate:modelValue"?: ((args_0: boolean) => any) | undefined;
5
+ readonly onChange?: ((args_0: {
6
+ id: NonNullable<TID>;
7
+ label: string;
8
+ name?: string;
9
+ }) => any) | undefined;
10
+ } & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onUpdate:modelValue" | "onChange"> & {
11
+ id?: TID;
16
12
  name?: string;
17
- }) => any;
18
- }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
19
- "onUpdate:modelValue"?: ((args_0: boolean) => any) | undefined;
20
- onChange?: ((args_0: {
21
- id: string | number;
13
+ label: string;
14
+ modelValue?: boolean;
15
+ inputClasses?: ClassTypeProp;
16
+ labelClasses?: ClassTypeProp;
17
+ } & Partial<{}>> & import('vue').PublicProps;
18
+ expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
19
+ attrs: any;
20
+ slots: {};
21
+ emit: ((evt: "update:modelValue", args_0: boolean) => void) & ((evt: "change", args_0: {
22
+ id: NonNullable<TID>;
22
23
  label: string;
23
24
  name?: string;
24
- }) => any) | undefined;
25
- }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
26
- checkbox: HTMLInputElement;
27
- }, HTMLDivElement>;
25
+ }) => void);
26
+ }>) => import('vue').VNode & {
27
+ __ctx?: Awaited<typeof __VLS_setup>;
28
+ };
28
29
  export default _default;
30
+ type __VLS_PrettifyLocal<T> = {
31
+ [K in keyof T]: T[K];
32
+ } & {};
@@ -1,56 +1,55 @@
1
1
  import { Nullable, Optional } from '@wikicasa-dev/types';
2
2
  import { ClassTypeProp } from '../types';
3
- export type RadioButtonType<T = unknown> = {
4
- id?: string | number | null;
5
- label: string | number;
6
- payload?: T;
3
+ export type RadioButtonType<TID = string | number | null, TPayload = unknown> = {
4
+ id?: TID;
5
+ label: string;
6
+ payload?: TPayload;
7
7
  active?: boolean;
8
8
  };
9
- declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<{
10
- resetRadio?: Optional<boolean>;
11
- } & {
12
- radioValues?: RadioButtonType[];
13
- dataCy?: string;
14
- radioContainerClasses?: ClassTypeProp;
15
- }, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
16
- "update:modelValue": (args_0: Nullable<RadioButtonType<unknown>>) => any;
17
- "update:resetRadio": (value: Optional<boolean>) => any;
18
- }, string, import('vue').PublicProps, Readonly<{
19
- resetRadio?: Optional<boolean>;
20
- } & {
21
- radioValues?: RadioButtonType[];
22
- dataCy?: string;
23
- radioContainerClasses?: ClassTypeProp;
24
- }> & Readonly<{
25
- "onUpdate:modelValue"?: ((args_0: Nullable<RadioButtonType<unknown>>) => any) | undefined;
26
- "onUpdate:resetRadio"?: ((value: Optional<boolean>) => any) | undefined;
27
- }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>, {
28
- default?(_: {
29
- handleClick: (elem: RadioButtonType) => void;
30
- activeValue: {
31
- id?: string | number | null | undefined;
32
- label: string | number;
33
- payload?: unknown;
34
- active?: boolean | undefined;
35
- } | null;
36
- reset: () => void;
37
- isActive: (elem: RadioButtonType) => boolean;
38
- }): any;
39
- radio_elements?(_: {
40
- handleClick: (elem: RadioButtonType) => void;
41
- activeValue: {
42
- id?: string | number | null | undefined;
43
- label: string | number;
44
- payload?: unknown;
45
- active?: boolean | undefined;
46
- } | null;
47
- reset: () => void;
48
- isActive: (elem: RadioButtonType) => boolean;
49
- }): any;
50
- }>;
51
- export default _default;
52
- type __VLS_WithTemplateSlots<T, S> = T & {
53
- new (): {
54
- $slots: S;
9
+ declare const _default: <TID extends string | number | null, TPayload>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
10
+ props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
11
+ readonly "onUpdate:modelValue"?: ((args_0: Nullable<RadioButtonType<TID, TPayload>>) => any) | undefined;
12
+ readonly "onUpdate:refresh"?: ((value: boolean) => any) | undefined;
13
+ readonly "onUpdate:resetRadio"?: ((value: Optional<boolean>) => any) | undefined;
14
+ } & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onUpdate:modelValue" | "onUpdate:refresh" | "onUpdate:resetRadio"> & ({
15
+ resetRadio?: Optional<boolean>;
16
+ refresh?: boolean;
17
+ } & {
18
+ radioValues?: RadioButtonType<TID, TPayload>[];
19
+ dataCy?: string;
20
+ radioContainerClasses?: ClassTypeProp;
21
+ }) & Partial<{}>> & import('vue').PublicProps;
22
+ expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
23
+ attrs: any;
24
+ slots: {
25
+ default?(_: {
26
+ handleClick: (elem: RadioButtonType<TID, TPayload>) => void;
27
+ activeValue: {
28
+ id?: import('vue').UnwrapRef<TID> | undefined;
29
+ label: string;
30
+ payload?: import('vue').UnwrapRef<TPayload> | undefined;
31
+ active?: boolean | undefined;
32
+ } | null;
33
+ reset: () => void;
34
+ isActive: (elem: RadioButtonType<TID, TPayload>) => boolean;
35
+ }): any;
36
+ radio_elements?(_: {
37
+ handleClick: (elem: RadioButtonType<TID, TPayload>) => void;
38
+ activeValue: {
39
+ id?: import('vue').UnwrapRef<TID> | undefined;
40
+ label: string;
41
+ payload?: import('vue').UnwrapRef<TPayload> | undefined;
42
+ active?: boolean | undefined;
43
+ } | null;
44
+ reset: () => void;
45
+ isActive: (elem: RadioButtonType<TID, TPayload>) => boolean;
46
+ }): any;
55
47
  };
48
+ emit: ((evt: "update:modelValue", args_0: Nullable<RadioButtonType<TID, TPayload>>) => void) & (((evt: "update:refresh", value: boolean) => void) & ((evt: "update:resetRadio", value: Optional<boolean>) => void));
49
+ }>) => import('vue').VNode & {
50
+ __ctx?: Awaited<typeof __VLS_setup>;
56
51
  };
52
+ export default _default;
53
+ type __VLS_PrettifyLocal<T> = {
54
+ [K in keyof T]: T[K];
55
+ } & {};
@@ -1,11 +1,11 @@
1
- import { defineComponent as v, ref as D, computed as h, watch as E, renderSlot as b, createElementVNode as $, normalizeClass as g, createElementBlock as B, createCommentVNode as A, openBlock as C, Fragment as I, renderList as R, createBlock as K, unref as V } from "vue";
2
- import { stringToHyphened as L, isArrNullOrEmpty as G } from "@wikicasa-dev/utilities";
3
- import N from "./CheckboxBtn.vue.js";
1
+ import { defineComponent as B, mergeModels as y, useModel as A, ref as I, computed as i, watch as C, renderSlot as p, createElementVNode as M, normalizeClass as x, createElementBlock as R, createCommentVNode as K, openBlock as v, Fragment as V, renderList as w, createBlock as L, unref as G } from "vue";
2
+ import { stringToHyphened as N, isArrNullOrEmpty as T } from "@wikicasa-dev/utilities";
3
+ import F from "./CheckboxBtn.vue.js";
4
4
  import '../../../../../assets/CheckboxBtn.css';/* empty css */
5
- const T = ["id", "data-cy"], j = /* @__PURE__ */ v({
5
+ const O = ["id", "data-cy"], q = /* @__PURE__ */ B({
6
6
  inheritAttrs: !1,
7
7
  __name: "CheckboxGroup",
8
- props: {
8
+ props: /* @__PURE__ */ y({
9
9
  checkboxData: { default() {
10
10
  return [];
11
11
  } },
@@ -18,95 +18,100 @@ const T = ["id", "data-cy"], j = /* @__PURE__ */ v({
18
18
  getKey: { type: Function, default: (a) => typeof a == "string" || typeof a == "number" ? `${a}` : `${a.id}` },
19
19
  groupId: { default: "" },
20
20
  dataCy: { default: "" }
21
- },
22
- emits: ["resetted", "update:modelValue", "checkedGroup"],
23
- setup(a, { emit: y }) {
24
- const o = a, s = y, l = D(
21
+ }, {
22
+ refresh: { type: Boolean, default: !1 },
23
+ refreshModifiers: {}
24
+ }),
25
+ emits: /* @__PURE__ */ y(["resetted", "update:modelValue", "checkedGroup"], ["update:refresh"]),
26
+ setup(a, { emit: D }) {
27
+ const o = a, s = D, f = A(a, "refresh"), l = I(
25
28
  /* @__PURE__ */ new Map()
26
- ), r = h(() => {
29
+ ), r = i(() => {
27
30
  for (const e of o.checkboxData)
28
31
  if (e.reset) return e;
29
32
  return null;
30
- }), x = h(() => o.checkboxData.length), f = h(() => {
33
+ }), E = i(() => o.checkboxData.length), k = i(() => {
31
34
  let e = 0;
32
- return l.value.forEach((t) => {
33
- t.checked && e++;
35
+ return l.value.forEach((c) => {
36
+ c.checked && e++;
34
37
  }), e;
35
- });
36
- (() => {
37
- const e = [];
38
+ }), m = () => {
39
+ const e = [], c = /* @__PURE__ */ new Map();
38
40
  for (const t of o.checkboxData)
39
- l.value.set(`${t.id}`, {
41
+ c.set(`${t.id}`, {
40
42
  ...t,
41
43
  checked: !!t.checked
42
44
  }), t.checked && e.push(t);
43
- s("update:modelValue", e);
44
- })();
45
- const u = (e, t) => {
46
- const c = l.value.get(e);
47
- if (c) {
48
- if (t) {
49
- l.value.set(e, { ...c, ...t });
45
+ l.value = c, s("update:modelValue", e);
46
+ };
47
+ m();
48
+ const u = (e, c) => {
49
+ const t = l.value.get(e);
50
+ if (t) {
51
+ if (c) {
52
+ l.value.set(e, { ...t, ...c });
50
53
  return;
51
54
  }
52
- l.value.set(e, { ...c, checked: !c.checked });
55
+ l.value.set(e, { ...t, checked: !t.checked });
53
56
  }
54
- }, k = () => {
57
+ }, b = () => {
55
58
  l.value.forEach((e) => {
56
59
  e.checked = !1;
57
60
  });
58
- }, m = () => {
59
- k(), s("update:modelValue", []), s("resetted");
60
- }, d = (e) => l.value.get(o.getKey(e))?.checked ?? !1, i = (e) => {
61
- if (G(o.checkboxData)) return;
62
- const t = l.value.get(e.id);
63
- t?.reset && e.checked ? k() : r.value && !t?.reset && u(o.getKey(r.value), { checked: !1 }), u(`${e.id}`), o.autoCheckResetAll && r.value && f.value === x.value - 1 && l.value.forEach((n) => {
61
+ }, g = () => {
62
+ b(), s("update:modelValue", []), s("resetted");
63
+ }, d = (e) => l.value.get(o.getKey(e))?.checked ?? !1, h = (e) => {
64
+ if (T(o.checkboxData)) return;
65
+ const c = l.value.get(e.id);
66
+ c?.reset && e.checked ? b() : r.value && !c?.reset && u(o.getKey(r.value), { checked: !1 }), u(`${e.id}`), o.autoCheckResetAll && r.value && k.value === E.value - 1 && l.value.forEach((n) => {
64
67
  n.checked = !!n.reset;
65
- }), o.autoCheckResetEmpty && r.value && !f.value && (!o.manualToggleResetButton || !t?.reset) && u(o.getKey(r.value), { checked: !0 });
66
- const c = [];
68
+ }), o.autoCheckResetEmpty && r.value && !k.value && (!o.manualToggleResetButton || !c?.reset) && u(o.getKey(r.value), { checked: !0 });
69
+ const t = [];
67
70
  l.value.forEach((n) => {
68
- n.checked && c.push(n);
69
- }), s("update:modelValue", c), s("checkedGroup", o.groupId);
71
+ n.checked && t.push(n);
72
+ }), s("update:modelValue", t), s("checkedGroup", o.groupId);
70
73
  };
71
- return E(
74
+ return C(
72
75
  () => o.reset,
73
76
  (e) => {
74
- e && m();
77
+ e && g();
75
78
  }
76
- ), (e, t) => b(e.$slots, "default", {
79
+ ), C(f, (e) => {
80
+ e && (m(), f.value = !1);
81
+ }), (e, c) => p(e.$slots, "default", {
77
82
  isActive: d,
78
- handleChange: i,
83
+ handleChange: h,
79
84
  checkboxesData: a.checkboxData
80
85
  }, () => [
81
- $("div", {
86
+ M("div", {
82
87
  id: a.groupId,
83
- class: g(["checkbox-group-container", e.$attrs.class || ""]),
88
+ class: x(["checkbox-group-container", e.$attrs.class || ""]),
84
89
  "data-cy": a.dataCy
85
90
  }, [
86
- b(e.$slots, "checkbox_elements", {
91
+ p(e.$slots, "checkbox_elements", {
87
92
  isActive: d,
88
- handleChange: i,
93
+ handleChange: h,
89
94
  checkboxesData: a.checkboxData,
90
- reset: m
95
+ reset: g
91
96
  }, () => [
92
- a.checkboxData ? (C(!0), B(I, { key: 0 }, R(a.checkboxData, (c, n) => (C(), K(N, {
93
- id: a.getKey(c),
97
+ a.checkboxData ? (v(!0), R(V, { key: 0 }, w(a.checkboxData, (t, n) => (v(), L(F, {
98
+ id: a.getKey(t),
94
99
  key: n,
95
- "data-cy": c.dataCy ?? `checkbox_${V(L)(`${c.label}`)}`,
96
- label: c.label,
100
+ "data-cy": t.dataCy ?? `checkbox_${G(N)(`${t.label}`)}`,
101
+ label: t.label,
97
102
  inline: a.formCheckInline,
98
- "model-value": d(c),
99
- class: g([
103
+ "model-value": d(t),
104
+ class: x([
100
105
  a.formCheckInline ? "uikit-mr-10px" : "uikit-mb-10px",
101
106
  a.checkboxContainerClasses
102
107
  ]),
103
- onChange: t[0] || (t[0] = (p) => i(p))
104
- }, null, 8, ["id", "data-cy", "label", "inline", "model-value", "class"]))), 128)) : A("", !0)
108
+ onChange: c[0] || (c[0] = ($) => h($))
109
+ }, null, 8, ["id", "data-cy", "label", "inline", "model-value", "class"]))), 128)) : K("", !0)
105
110
  ])
106
- ], 10, T)
111
+ ], 10, O)
107
112
  ]);
108
113
  }
109
114
  });
110
115
  export {
111
- j as default
116
+ q as default
112
117
  };
@@ -1,60 +1,64 @@
1
- import { defineComponent as C, mergeModels as d, useModel as h, ref as $, watch as V, renderSlot as u, createElementVNode as p, normalizeClass as c, createElementBlock as k, openBlock as m, Fragment as y, renderList as R, createBlock as g } from "vue";
2
- import B from "./RadioButton.vue.js";
3
- const b = ["data-cy"], z = /* @__PURE__ */ C({
1
+ import { defineComponent as k, mergeModels as f, useModel as m, ref as R, watch as v, renderSlot as h, createElementVNode as g, normalizeClass as C, createElementBlock as B, openBlock as $, Fragment as M, renderList as b, createBlock as A } from "vue";
2
+ import E from "./RadioButton.vue.js";
3
+ const w = ["data-cy"], G = /* @__PURE__ */ k({
4
4
  inheritAttrs: !1,
5
5
  __name: "RadioGroup",
6
- props: /* @__PURE__ */ d({
6
+ props: /* @__PURE__ */ f({
7
7
  radioValues: { default: () => [] },
8
8
  dataCy: {},
9
9
  radioContainerClasses: {}
10
10
  }, {
11
11
  resetRadio: { type: Boolean, default: !1 },
12
- resetRadioModifiers: {}
12
+ resetRadioModifiers: {},
13
+ refresh: { type: Boolean, default: !1 },
14
+ refreshModifiers: {}
13
15
  }),
14
- emits: /* @__PURE__ */ d(["update:modelValue"], ["update:resetRadio"]),
15
- setup(t, { emit: f }) {
16
- const n = f, i = h(t, "resetRadio"), a = $(null), l = (e) => {
17
- a.value = e, n("update:modelValue", e);
16
+ emits: /* @__PURE__ */ f(["update:modelValue"], ["update:resetRadio", "update:refresh"]),
17
+ setup(l, { emit: V }) {
18
+ const o = V, n = m(l, "resetRadio"), i = m(l, "refresh"), a = R(null), t = (e) => {
19
+ a.value = e, o("update:modelValue", e);
18
20
  }, s = () => {
19
- a.value = null, i.value = !1, n("update:modelValue", null);
20
- }, r = (e) => a.value ? `${a.value.id}` == `${e.id}` : !1;
21
- return (() => {
22
- for (const e of t.radioValues)
21
+ a.value = null, n.value = !1, o("update:modelValue", null);
22
+ }, d = (e) => a.value ? `${a.value.id}` == `${e.id}` : !1, u = () => {
23
+ for (const e of l.radioValues)
23
24
  if (e.active) {
24
- l(e);
25
+ t(e);
25
26
  return;
26
27
  }
27
- })(), V(i, (e) => {
28
+ };
29
+ return u(), v(n, (e) => {
28
30
  e && s();
29
- }), (e, A) => u(e.$slots, "default", {
30
- handleClick: l,
31
+ }), v(i, (e) => {
32
+ e && (u(), i.value = !1);
33
+ }), (e, c) => h(e.$slots, "default", {
34
+ handleClick: t,
31
35
  activeValue: a.value,
32
36
  reset: s,
33
- isActive: r
37
+ isActive: d
34
38
  }, () => [
35
- p("div", {
36
- class: c(["radio-group-container", e.$attrs.class]),
37
- "data-cy": t.dataCy
39
+ g("div", {
40
+ class: C(["radio-group-container", e.$attrs.class]),
41
+ "data-cy": l.dataCy
38
42
  }, [
39
- u(e.$slots, "radio_elements", {
40
- handleClick: l,
43
+ h(e.$slots, "radio_elements", {
44
+ handleClick: t,
41
45
  activeValue: a.value,
42
46
  reset: s,
43
- isActive: r
47
+ isActive: d
44
48
  }, () => [
45
- (m(!0), k(y, null, R(t.radioValues, (o, v) => (m(), g(B, {
46
- id: o.id,
47
- key: v,
48
- class: c(t.radioContainerClasses),
49
- label: `${o.label}`,
50
- "model-value": `${o.id}` == `${a.value?.id}`,
51
- onChange: l
49
+ ($(!0), B(M, null, b(l.radioValues, (r, p) => ($(), A(E, {
50
+ id: r.id,
51
+ key: p,
52
+ class: C(l.radioContainerClasses),
53
+ label: `${r.label}`,
54
+ "model-value": `${r.id}` == `${a.value?.id}`,
55
+ onChange: c[0] || (c[0] = (y) => t(y))
52
56
  }, null, 8, ["id", "class", "label", "model-value"]))), 128))
53
57
  ])
54
- ], 10, b)
58
+ ], 10, w)
55
59
  ]);
56
60
  }
57
61
  });
58
62
  export {
59
- z as default
63
+ G as default
60
64
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wikicasa-dev/components",
3
- "version": "2.2.9-alpha.52",
3
+ "version": "2.2.9-alpha.54",
4
4
  "description": "Wikicasa frontend components",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -46,7 +46,7 @@
46
46
  "date-fns": "^4.0.0",
47
47
  "@wikicasa-dev/svg-icons": "^1.2.28-alpha.1",
48
48
  "@wikicasa-dev/vue-composables": "0.0.33-alpha.4",
49
- "@wikicasa-dev/types": "^2.4.0",
49
+ "@wikicasa-dev/types": "^2.5.0",
50
50
  "@wikicasa-dev/utilities": "^1.2.0"
51
51
  },
52
52
  "dependencies": {
@@ -67,7 +67,7 @@
67
67
  "@wikicasa-dev/svg-icons": "1.2.28-alpha.1",
68
68
  "@wikicasa-dev/vue-composables": "0.0.33-alpha.4",
69
69
  "@wikicasa-dev/tailwind-plugins": "^0.0.3",
70
- "@wikicasa-dev/types": "2.4.6",
70
+ "@wikicasa-dev/types": "2.5.0",
71
71
  "@wikicasa-dev/utilities": "1.2.0",
72
72
  "autoprefixer": "^10.4.22",
73
73
  "date-fns": "4.1.0",