@quidgest/ui 0.16.21 → 0.16.22
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/ui.css +9 -1
- package/dist/ui.esm.js +3558 -3558
- package/dist/ui.js +10 -10
- package/dist/ui.min.css +1 -1
- package/dist/ui.min.js +768 -767
- package/dist/ui.scss +10 -2
- package/esm/components/QCombobox/QCombobox.d.ts +18 -68
- package/esm/components/QCombobox/QCombobox.d.ts.map +1 -1
- package/esm/components/QCombobox/index.d.ts +9 -34
- package/esm/components/QCombobox/index.d.ts.map +1 -1
- package/esm/components/QDropdownMenu/QDropdownMenuContent.d.ts +18 -68
- package/esm/components/QDropdownMenu/QDropdownMenuContent.d.ts.map +1 -1
- package/esm/components/QList/QList.d.ts +5 -10
- package/esm/components/QList/QList.d.ts.map +1 -1
- package/esm/components/QList/QList.vue.js +94 -96
- package/esm/components/QList/index.d.ts +10 -48
- package/esm/components/QList/index.d.ts.map +1 -1
- package/esm/components/QList/types.d.ts +5 -1
- package/esm/components/QList/types.d.ts.map +1 -1
- package/esm/components/QSelect/QSelect.d.ts +18 -68
- package/esm/components/QSelect/QSelect.d.ts.map +1 -1
- package/esm/components/QSelect/QSelect.vue.js +18 -18
- package/esm/components/QSelect/index.d.ts +9 -34
- package/esm/components/QSelect/index.d.ts.map +1 -1
- package/esm/components/QToggleGroup/types.d.ts +1 -1
- package/esm/composables/useGroup/index.d.ts +4 -2
- package/esm/composables/useGroup/index.d.ts.map +1 -1
- package/esm/composables/useGroup/index.js +26 -24
- package/package.json +1 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { defineComponent as H, mergeModels as R, useModel as X, ref as h, computed as k, watch as j, nextTick as G, createElementBlock as p, openBlock as t, Fragment as A, createVNode as g, unref as i, normalizeClass as J, createSlots as W, withCtx as s, withDirectives as Y, toDisplayString as F, createCommentVNode as _, createTextVNode as Z, createElementVNode as K, mergeProps as M, vModelText as ee, renderSlot as
|
|
1
|
+
import { defineComponent as H, mergeModels as R, useModel as X, ref as h, computed as k, watch as j, nextTick as G, createElementBlock as p, openBlock as t, Fragment as A, createVNode as g, unref as i, normalizeClass as J, createSlots as W, withCtx as s, withDirectives as Y, toDisplayString as F, createCommentVNode as _, createTextVNode as Z, createElementVNode as K, mergeProps as M, vModelText as ee, renderSlot as d, createBlock as w, normalizeProps as le, withModifiers as oe } from "vue";
|
|
2
2
|
import { DEFAULT_TEXTS as ae, DEFAULT_ICONS as te } from "./types.js";
|
|
3
3
|
import { QButton as ne } from "../QButton/index.js";
|
|
4
4
|
import { QField as ie } from "../QField/index.js";
|
|
5
5
|
import { QIcon as se } from "../QIcon/index.js";
|
|
6
|
-
import { QList as
|
|
7
|
-
import { QOverlay as
|
|
6
|
+
import { QList as re } from "../QList/index.js";
|
|
7
|
+
import { QOverlay as de } from "../QOverlay/index.js";
|
|
8
8
|
import { QSpinnerLoader as ue } from "../QSpinnerLoader/index.js";
|
|
9
9
|
import { QChevron as ce } from "../__internal__/QChevron/index.js";
|
|
10
10
|
import { QClearButton as fe } from "../__internal__/QClearButton/index.js";
|
|
@@ -46,13 +46,13 @@ const pe = {
|
|
|
46
46
|
}),
|
|
47
47
|
emits: /* @__PURE__ */ R(["before-show", "before-hide", "show", "hide"], ["update:modelValue"]),
|
|
48
48
|
setup(C, { emit: O }) {
|
|
49
|
-
const e = C, m = O, v = X(C, "modelValue"), a = h(!1), y = h(null), B = h(null), V = h(null), D = k(() =>
|
|
49
|
+
const e = C, m = O, v = X(C, "modelValue"), a = h(!1), y = h(null), B = h(null), V = h(null), D = k(() => r.value === void 0), r = k(
|
|
50
50
|
() => {
|
|
51
51
|
var l;
|
|
52
52
|
return (l = e.items) == null ? void 0 : l.find((o) => o[e.itemValue] === v.value);
|
|
53
53
|
}
|
|
54
54
|
), q = k(
|
|
55
|
-
() =>
|
|
55
|
+
() => r.value ? r.value[e.itemLabel] : ""
|
|
56
56
|
), u = k(
|
|
57
57
|
() => e.clearable && !e.readonly && !e.disabled && !e.loading
|
|
58
58
|
);
|
|
@@ -133,7 +133,7 @@ const pe = {
|
|
|
133
133
|
onKeydown: E
|
|
134
134
|
}, W({
|
|
135
135
|
append: s(() => [
|
|
136
|
-
|
|
136
|
+
d(l.$slots, "append"),
|
|
137
137
|
u.value && v.value ? (t(), w(i(fe), {
|
|
138
138
|
key: 0,
|
|
139
139
|
icons: e.icons,
|
|
@@ -201,15 +201,15 @@ const pe = {
|
|
|
201
201
|
_: 2
|
|
202
202
|
/* DYNAMIC */
|
|
203
203
|
}, [
|
|
204
|
-
(c =
|
|
204
|
+
(c = r.value) != null && c.icon || l.$slots.prepend ? {
|
|
205
205
|
name: "prepend",
|
|
206
206
|
fn: s(() => {
|
|
207
207
|
var n, z;
|
|
208
208
|
return [
|
|
209
|
-
|
|
210
|
-
(n =
|
|
209
|
+
d(l.$slots, "prepend"),
|
|
210
|
+
(n = r.value) != null && n.icon ? (t(), w(
|
|
211
211
|
i(se),
|
|
212
|
-
le(M({ key: 0 }, (z =
|
|
212
|
+
le(M({ key: 0 }, (z = r.value) == null ? void 0 : z.icon)),
|
|
213
213
|
null,
|
|
214
214
|
16
|
|
215
215
|
/* FULL_PROPS */
|
|
@@ -221,12 +221,12 @@ const pe = {
|
|
|
221
221
|
l.$slots.extras ? {
|
|
222
222
|
name: "extras",
|
|
223
223
|
fn: s(() => [
|
|
224
|
-
|
|
224
|
+
d(l.$slots, "extras")
|
|
225
225
|
]),
|
|
226
226
|
key: "1"
|
|
227
227
|
} : void 0
|
|
228
228
|
]), 1032, ["id", "label", "required", "class", "readonly", "disabled", "data-loading", "aria-expanded", "size", "invalid"]),
|
|
229
|
-
g(i(
|
|
229
|
+
g(i(de), {
|
|
230
230
|
modelValue: a.value,
|
|
231
231
|
"onUpdate:modelValue": o[1] || (o[1] = (n) => a.value = n),
|
|
232
232
|
spy: "",
|
|
@@ -251,16 +251,16 @@ const pe = {
|
|
|
251
251
|
onFocusout: U,
|
|
252
252
|
onKeydown: oe(E, ["stop"])
|
|
253
253
|
}, [
|
|
254
|
-
|
|
254
|
+
d(l.$slots, "body.prepend"),
|
|
255
255
|
e.loading ? (t(), p("div", be, [
|
|
256
256
|
g(i(ue), { size: 24 })
|
|
257
|
-
])) : (t(), w(i(
|
|
257
|
+
])) : (t(), w(i(re), {
|
|
258
258
|
key: 1,
|
|
259
259
|
ref_key: "listRef",
|
|
260
260
|
ref: B,
|
|
261
261
|
class: "q-select__items",
|
|
262
262
|
selectable: "",
|
|
263
|
-
required:
|
|
263
|
+
required: e.required,
|
|
264
264
|
"model-value": v.value,
|
|
265
265
|
items: e.items,
|
|
266
266
|
groups: l.groups,
|
|
@@ -269,12 +269,12 @@ const pe = {
|
|
|
269
269
|
"onUpdate:modelValue": L
|
|
270
270
|
}, {
|
|
271
271
|
item: s(({ item: n }) => [
|
|
272
|
-
|
|
272
|
+
d(l.$slots, "item", { item: n })
|
|
273
273
|
]),
|
|
274
274
|
_: 3
|
|
275
275
|
/* FORWARDED */
|
|
276
|
-
}, 8, ["model-value", "items", "groups", "item-label", "item-value"])),
|
|
277
|
-
|
|
276
|
+
}, 8, ["required", "model-value", "items", "groups", "item-label", "item-value"])),
|
|
277
|
+
d(l.$slots, "body.append")
|
|
278
278
|
], 40, ye)
|
|
279
279
|
]),
|
|
280
280
|
_: 3
|
|
@@ -116,9 +116,9 @@ declare const QSelect: {
|
|
|
116
116
|
$: import('vue').ComponentInternalInstance;
|
|
117
117
|
$data: {};
|
|
118
118
|
$props: {
|
|
119
|
-
readonly modelValue?: any;
|
|
120
119
|
readonly id?: string | undefined;
|
|
121
120
|
readonly class?: string | unknown[] | undefined;
|
|
121
|
+
readonly modelValue?: any;
|
|
122
122
|
readonly highlighted?: any;
|
|
123
123
|
readonly items?: import('../QList/types').Item[] | undefined;
|
|
124
124
|
readonly groups?: import('../QList/types').Group[] | undefined;
|
|
@@ -129,7 +129,7 @@ declare const QSelect: {
|
|
|
129
129
|
readonly multiple?: boolean | undefined;
|
|
130
130
|
readonly required?: boolean | undefined;
|
|
131
131
|
readonly onClick?: ((key: any) => any) | undefined;
|
|
132
|
-
readonly "onUpdate:modelValue"?: ((
|
|
132
|
+
readonly "onUpdate:modelValue"?: ((val: any) => any) | undefined;
|
|
133
133
|
readonly "onMouseenter:item"?: ((key: any) => any) | undefined;
|
|
134
134
|
} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps;
|
|
135
135
|
$attrs: {
|
|
@@ -221,23 +221,11 @@ declare const QSelect: {
|
|
|
221
221
|
$root: import('vue').ComponentPublicInstance | null;
|
|
222
222
|
$parent: import('vue').ComponentPublicInstance | null;
|
|
223
223
|
$host: Element | null;
|
|
224
|
-
$emit: ((event: "click", key: any) => void) & ((event: "update:modelValue",
|
|
224
|
+
$emit: ((event: "click", key: any) => void) & ((event: "update:modelValue", val: any) => void) & ((event: "mouseenter:item", key: any) => void);
|
|
225
225
|
$el: any;
|
|
226
|
-
$options: import('vue').ComponentOptionsBase<Readonly<{
|
|
227
|
-
modelValue?: any;
|
|
228
|
-
} & import('../../types/component').QBaseComponentProps & {
|
|
229
|
-
highlighted?: any;
|
|
230
|
-
items?: import('../QList/types').Item[];
|
|
231
|
-
groups?: import('../QList/types').Group[];
|
|
232
|
-
itemValue?: string;
|
|
233
|
-
itemLabel?: string;
|
|
234
|
-
disabled?: boolean;
|
|
235
|
-
selectable?: boolean;
|
|
236
|
-
multiple?: boolean;
|
|
237
|
-
required?: boolean;
|
|
238
|
-
}> & Readonly<{
|
|
226
|
+
$options: import('vue').ComponentOptionsBase<Readonly<import('..').QListProps> & Readonly<{
|
|
239
227
|
onClick?: ((key: any) => any) | undefined;
|
|
240
|
-
"onUpdate:modelValue"?: ((
|
|
228
|
+
"onUpdate:modelValue"?: ((val: any) => any) | undefined;
|
|
241
229
|
"onMouseenter:item"?: ((key: any) => any) | undefined;
|
|
242
230
|
}>, {
|
|
243
231
|
getItem: (idx: number) => HTMLElement | undefined;
|
|
@@ -245,10 +233,9 @@ declare const QSelect: {
|
|
|
245
233
|
getAdjacentItemIndex: (idx: number, direction: "next" | "prev") => number;
|
|
246
234
|
getFirstFocusableItemIndex: () => number;
|
|
247
235
|
getLastFocusableItemIndex: () => number;
|
|
248
|
-
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
249
|
-
"update:modelValue": (value: any) => any;
|
|
250
|
-
} & {
|
|
236
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
251
237
|
click: (key: any) => any;
|
|
238
|
+
"update:modelValue": (val: any) => any;
|
|
252
239
|
"mouseenter:item": (key: any) => any;
|
|
253
240
|
}, string, {
|
|
254
241
|
groups: import('../QList/types').Group[];
|
|
@@ -278,21 +265,9 @@ declare const QSelect: {
|
|
|
278
265
|
groups: import('../QList/types').Group[];
|
|
279
266
|
itemValue: string;
|
|
280
267
|
itemLabel: string;
|
|
281
|
-
}> & Omit<Readonly<{
|
|
282
|
-
modelValue?: any;
|
|
283
|
-
} & import('../../types/component').QBaseComponentProps & {
|
|
284
|
-
highlighted?: any;
|
|
285
|
-
items?: import('../QList/types').Item[];
|
|
286
|
-
groups?: import('../QList/types').Group[];
|
|
287
|
-
itemValue?: string;
|
|
288
|
-
itemLabel?: string;
|
|
289
|
-
disabled?: boolean;
|
|
290
|
-
selectable?: boolean;
|
|
291
|
-
multiple?: boolean;
|
|
292
|
-
required?: boolean;
|
|
293
|
-
}> & Readonly<{
|
|
268
|
+
}> & Omit<Readonly<import('..').QListProps> & Readonly<{
|
|
294
269
|
onClick?: ((key: any) => any) | undefined;
|
|
295
|
-
"onUpdate:modelValue"?: ((
|
|
270
|
+
"onUpdate:modelValue"?: ((val: any) => any) | undefined;
|
|
296
271
|
"onMouseenter:item"?: ((key: any) => any) | undefined;
|
|
297
272
|
}>, "getItem" | "getActiveItemIndex" | "getAdjacentItemIndex" | "getFirstFocusableItemIndex" | "getLastFocusableItemIndex" | ("groups" | "itemValue" | "itemLabel")> & import('vue').ShallowUnwrapRef<{
|
|
298
273
|
getItem: (idx: number) => HTMLElement | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/QSelect/index.ts"],"names":[],"mappings":"AAMA,QAAA,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCAIuwzB,GAAG,8CAA8C,GAAG,yBAAyB,GAAG,6DAAmC,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gDAAtH,GAAG,8CAA8C,GAAG,yBAAyB,GAAG,6DAAmC,GAAG
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/QSelect/index.ts"],"names":[],"mappings":"AAMA,QAAA,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCAIuwzB,GAAG,8CAA8C,GAAG,yBAAyB,GAAG,6DAAmC,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gDAAtH,GAAG,8CAA8C,GAAG,yBAAyB,GAAG,6DAAmC,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCAAtH,GAAG,8CAA8C,GAAG,yBAAyB,GAAG,6DAAmC,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAJj2zB,CAAA;AAGzC,OAAO,EAAE,OAAO,EAAE,CAAA"}
|
|
@@ -2,7 +2,7 @@ import { QButtonProps } from '../QButton';
|
|
|
2
2
|
import { QButtonGroupProps } from '../QButtonGroup/types';
|
|
3
3
|
export type QToggleGroupProps = QButtonGroupProps & {
|
|
4
4
|
/**
|
|
5
|
-
* Indicates
|
|
5
|
+
* Indicates whether multiple options can be selected.
|
|
6
6
|
*/
|
|
7
7
|
multiple?: boolean;
|
|
8
8
|
/**
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ComputedRef, InjectionKey, MaybeRef, Ref } from 'vue';
|
|
2
2
|
/** Symbol used for dependency injection of Group. */
|
|
3
3
|
export declare const GroupSymbol: InjectionKey<Group<unknown>>;
|
|
4
|
+
type Active<T> = T | T[] | undefined;
|
|
4
5
|
/**
|
|
5
6
|
* Props interface for creating a group component
|
|
6
7
|
* @template T The type of the active item(s)
|
|
@@ -11,7 +12,7 @@ export interface GroupProps<T> {
|
|
|
11
12
|
* - When multiple is false: A single active item of type T
|
|
12
13
|
* - When multiple is true: An array of active items of type T[]
|
|
13
14
|
*/
|
|
14
|
-
active
|
|
15
|
+
active?: MaybeRef<Active<T>>;
|
|
15
16
|
/**
|
|
16
17
|
* Whether multiple items can be active simultaneously
|
|
17
18
|
* - When true: active will be treated as T[]
|
|
@@ -34,7 +35,7 @@ export interface Group<T> {
|
|
|
34
35
|
* - When multiple is false: A single active item of type T or undefined
|
|
35
36
|
* - When multiple is true: An array of active items of type T[] or undefined
|
|
36
37
|
*/
|
|
37
|
-
active: Ref<T
|
|
38
|
+
active: Ref<Active<T>>;
|
|
38
39
|
/**
|
|
39
40
|
* Computed boolean indicating if multiple selection is enabled
|
|
40
41
|
*/
|
|
@@ -101,4 +102,5 @@ export declare function useGroup<T>(options: GroupProps<T>): Group<T>;
|
|
|
101
102
|
* - In multiple selection mode, multiple items can be active simultaneously
|
|
102
103
|
*/
|
|
103
104
|
export declare function useGroupItem(itemId: MaybeRef<string>): GroupProvide | undefined;
|
|
105
|
+
export {};
|
|
104
106
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/composables/useGroup/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,QAAQ,EAAE,GAAG,EAAE,MAAM,KAAK,CAAA;AAKnE,qDAAqD;AACrD,eAAO,MAAM,WAAW,EAAE,YAAY,CAAC,KAAK,CAAC,OAAO,CAAC,CAAyB,CAAA;AAE9E;;;GAGG;AACH,MAAM,WAAW,UAAU,CAAC,CAAC;IAC5B;;;;OAIG;IACH,MAAM,EAAE,QAAQ,CAAC,CAAC,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/composables/useGroup/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,QAAQ,EAAE,GAAG,EAAE,MAAM,KAAK,CAAA;AAKnE,qDAAqD;AACrD,eAAO,MAAM,WAAW,EAAE,YAAY,CAAC,KAAK,CAAC,OAAO,CAAC,CAAyB,CAAA;AAE9E,KAAK,MAAM,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,GAAG,SAAS,CAAA;AAEpC;;;GAGG;AACH,MAAM,WAAW,UAAU,CAAC,CAAC;IAC5B;;;;OAIG;IACH,MAAM,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAA;IAE5B;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,CAAA;IAE5B;;OAEG;IACH,QAAQ,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,CAAA;CAC5B;AAED;;;GAGG;AACH,MAAM,WAAW,KAAK,CAAC,CAAC;IACvB;;;;OAIG;IACH,MAAM,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAA;IAEtB;;OAEG;IACH,QAAQ,EAAE,WAAW,CAAC,OAAO,CAAC,CAAA;IAE9B;;OAEG;IACH,QAAQ,CAAC,EAAE,WAAW,CAAC,OAAO,CAAC,CAAA;CAC/B;AAED;;GAEG;AACH,MAAM,WAAW,YAAY;IAC5B;;OAEG;IACH,MAAM,EAAE,MAAM,IAAI,CAAA;IAElB;;OAEG;IACH,QAAQ,EAAE,WAAW,CAAC,OAAO,CAAC,CAAA;CAC9B;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,QAAQ,CAAC,CAAC,EAAE,OAAO,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC,CAAC,CAAC,CA2C5D;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,YAAY,CAAC,MAAM,EAAE,QAAQ,CAAC,MAAM,CAAC,GAAG,YAAY,GAAG,SAAS,CAyC/E"}
|
|
@@ -1,40 +1,42 @@
|
|
|
1
|
-
import { inject as
|
|
2
|
-
const
|
|
1
|
+
import { inject as o, computed as l, unref as u, ref as d, isRef as m, watch as n, provide as p } from "vue";
|
|
2
|
+
const f = Symbol.for("q-group");
|
|
3
3
|
function q(a) {
|
|
4
4
|
const e = {
|
|
5
|
-
active:
|
|
6
|
-
|
|
7
|
-
)
|
|
8
|
-
multiple: r(() => v(a.multiple) || !1),
|
|
9
|
-
required: r(() => v(a.required) || !1)
|
|
5
|
+
active: d(y(a)),
|
|
6
|
+
multiple: l(() => u(a.multiple) || !1),
|
|
7
|
+
required: l(() => u(a.required) || !1)
|
|
10
8
|
};
|
|
11
|
-
return m(a.active) &&
|
|
9
|
+
return m(a.active) && n(a.active, (i) => {
|
|
12
10
|
e.active.value = i;
|
|
13
|
-
}),
|
|
11
|
+
}), n(
|
|
14
12
|
() => e.multiple.value,
|
|
15
13
|
(i) => {
|
|
16
|
-
i
|
|
14
|
+
i ? e.active.value ? e.active.value = [e.active.value] : e.active.value = [] : Array.isArray(e.active.value) && e.active.value.length === 1 ? e.active.value = e.active.value[0] : e.active.value = void 0;
|
|
17
15
|
}
|
|
18
|
-
),
|
|
16
|
+
), p(f, e), e;
|
|
19
17
|
}
|
|
20
|
-
function
|
|
21
|
-
const e =
|
|
18
|
+
function G(a) {
|
|
19
|
+
const e = o(f, void 0);
|
|
22
20
|
if (!e) return;
|
|
23
|
-
const i =
|
|
24
|
-
var
|
|
25
|
-
const
|
|
26
|
-
return Array.isArray(e.active.value) ? (
|
|
21
|
+
const i = l(() => {
|
|
22
|
+
var t;
|
|
23
|
+
const r = u(a);
|
|
24
|
+
return Array.isArray(e.active.value) ? (t = e.active.value) == null ? void 0 : t.includes(r) : e.active.value === r;
|
|
27
25
|
});
|
|
28
26
|
return { isActive: i, toggle: () => {
|
|
29
|
-
var
|
|
30
|
-
const
|
|
31
|
-
Array.isArray(e.active.value) ? i.value ? (!((
|
|
32
|
-
(
|
|
33
|
-
)) : e.active.value.push(
|
|
27
|
+
var t, v, c;
|
|
28
|
+
const r = u(a);
|
|
29
|
+
Array.isArray(e.active.value) ? i.value ? (!((t = e.required) != null && t.value) || e.active.value.length > 1) && (e.active.value = (v = e.active.value) == null ? void 0 : v.filter(
|
|
30
|
+
(s) => s !== r
|
|
31
|
+
)) : e.active.value.push(r) : e.active.value !== r ? e.active.value = r : (c = e.required) != null && c.value || (e.active.value = void 0);
|
|
34
32
|
} };
|
|
35
33
|
}
|
|
34
|
+
function y(a) {
|
|
35
|
+
const e = u(a.multiple), i = u(a.active);
|
|
36
|
+
return e ? Array.isArray(i) ? i : i !== void 0 ? [i] : [] : Array.isArray(i) ? i.length === 1 ? i[0] : void 0 : i;
|
|
37
|
+
}
|
|
36
38
|
export {
|
|
37
|
-
|
|
39
|
+
f as GroupSymbol,
|
|
38
40
|
q as useGroup,
|
|
39
|
-
|
|
41
|
+
G as useGroupItem
|
|
40
42
|
};
|