@volverjs/ui-vue 0.0.2 → 0.0.3-beta.2
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/auto-imports.d.ts +289 -0
- package/dist/components/VvTextarea/VvTextarea.es.js +231 -275
- package/dist/components/VvTextarea/VvTextarea.umd.js +1 -1
- package/dist/components/VvTooltip/VvTooltip.es.js +28 -0
- package/dist/components/VvTooltip/VvTooltip.umd.js +1 -0
- package/dist/components/VvTooltip/VvTooltip.vue.d.ts +23 -0
- package/dist/components/VvTooltip/index.d.ts +18 -0
- package/dist/components/index.es.js +874 -874
- package/dist/components/index.umd.js +1 -1
- package/dist/icons.es.js +3 -3
- package/dist/icons.umd.js +1 -1
- package/dist/index.es.js +554 -554
- package/dist/index.umd.js +1 -1
- package/dist/stories/Tooltip/Tooltip.settings.d.ts +42 -0
- package/dist/stories/Tooltip/Tooltip.test.d.ts +2 -0
- package/package.json +27 -20
- package/src/assets/icons/detailed.json +1 -1
- package/src/assets/icons/normal.json +1 -1
- package/src/assets/icons/simple.json +1 -1
- package/src/components/VvTextarea/VvTextarea.vue +1 -15
- package/src/components/VvTooltip/VvTooltip.vue +17 -0
- package/src/components/VvTooltip/index.ts +21 -0
- package/src/stories/Accordion/Accordion.stories.mdx +1 -1
- package/src/stories/AccordionGroup/AccordionGroup.stories.mdx +1 -1
- package/src/stories/AccordionGroup/AccordionGroupSlots.stories.mdx +1 -1
- package/src/stories/Badge/Badge.stories.mdx +1 -1
- package/src/stories/Breadcrumb/Breadcrumb.stories.mdx +1 -1
- package/src/stories/Breadcrumb/BreadcrumbSlots.stories.mdx +1 -1
- package/src/stories/Button/Button.stories.mdx +1 -1
- package/src/stories/Button/ButtonModifiers.stories.mdx +2 -2
- package/src/stories/Button/ButtonSlots.stories.mdx +3 -3
- package/src/stories/ButtonGroup/ButtonGroup.stories.mdx +1 -1
- package/src/stories/ButtonGroup/ButtonGroupSlots.stories.mdx +1 -1
- package/src/stories/Card/Card.stories.mdx +1 -1
- package/src/stories/Card/CardSlots.stories.mdx +1 -1
- package/src/stories/Checkbox/Checkbox.stories.mdx +1 -1
- package/src/stories/CheckboxGroup/CheckboxGroup.stories.mdx +1 -1
- package/src/stories/CheckboxGroup/CheckboxGroupSlots.stories.mdx +1 -1
- package/src/stories/Combobox/Combobox.stories.mdx +1 -1
- package/src/stories/Dialog/Dialog.stories.mdx +1 -1
- package/src/stories/Dropdown/Dropdown.stories.mdx +1 -1
- package/src/stories/Icon/Icon.stories.mdx +1 -1
- package/src/stories/Icon/IconsCollection.stories.mdx +1 -1
- package/src/stories/InputText/InputText.stories.mdx +1 -1
- package/src/stories/Progress/Progress.stories.mdx +1 -1
- package/src/stories/Radio/Radio.stories.mdx +1 -1
- package/src/stories/RadioGroup/RadioGroup.stories.mdx +1 -1
- package/src/stories/RadioGroup/RadioGroupSlots.stories.mdx +1 -1
- package/src/stories/Select/Select.stories.mdx +1 -1
- package/src/stories/Textarea/Textarea.stories.mdx +1 -1
- package/src/stories/Tooltip/Tooltip.settings.ts +26 -0
- package/src/stories/Tooltip/Tooltip.stories.mdx +98 -0
- package/src/stories/Tooltip/Tooltip.test.ts +49 -0
package/dist/index.es.js
CHANGED
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { addCollection as
|
|
5
|
-
import { unref as a, computed as
|
|
6
|
-
import { useToggle as
|
|
7
|
-
import { nanoid as
|
|
1
|
+
var Ot = Object.defineProperty;
|
|
2
|
+
var Et = (l, t, e) => t in l ? Ot(l, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : l[t] = e;
|
|
3
|
+
var Ae = (l, t, e) => (Et(l, typeof t != "symbol" ? t + "" : t, e), e);
|
|
4
|
+
import { addCollection as Rt, addIcon as it, addAPIProvider as Lt, iconExists as De, Icon as Dt } from "@iconify/vue";
|
|
5
|
+
import { unref as a, computed as u, inject as ze, toRef as Tt, toRefs as W, defineComponent as D, useAttrs as ut, ref as j, openBlock as m, createElementBlock as _, normalizeClass as F, withModifiers as qe, createElementVNode as E, renderSlot as A, normalizeProps as K, guardReactiveProps as ee, createTextVNode as X, toDisplayString as L, isRef as $e, provide as Bt, watchEffect as Xe, Fragment as he, renderList as Ce, createBlock as T, mergeProps as R, withCtx as ke, resolveDynamicComponent as dt, createCommentVNode as I, useSlots as ge, h as Q, watch as we, onMounted as Nt, withDirectives as Se, vModelCheckbox as xt, createVNode as ae, vModelSelect as Ht, withKeys as at, vModelText as ct, Transition as Mt, toHandlers as Gt, vShow as Ut, vModelDynamic as jt, vModelRadio as Ft } from "vue";
|
|
6
|
+
import { useToggle as Kt, toReactive as Wt, useVModel as Ze, useFocus as zt, useElementVisibility as vt, refDebounced as qt, onClickOutside as pt } from "@vueuse/core";
|
|
7
|
+
import { nanoid as de } from "nanoid";
|
|
8
8
|
const Ne = "ds";
|
|
9
|
-
class
|
|
9
|
+
class Xt {
|
|
10
10
|
constructor({
|
|
11
11
|
fetchWithCredentials: t = !1,
|
|
12
12
|
fetchOptions: e = {},
|
|
13
13
|
iconsCollections: n = [],
|
|
14
14
|
nuxt: o = !1
|
|
15
15
|
} = {}) {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
16
|
+
Ae(this, "fetchOptions");
|
|
17
|
+
Ae(this, "iconsCollections");
|
|
18
|
+
Ae(this, "provider");
|
|
19
|
+
Ae(this, "nuxt");
|
|
20
20
|
t && (e = { ...e, credentials: "include" }), this.provider = Ne, this.fetchOptions = e, this.iconsCollections = n, this.iconsCollections.forEach((r) => {
|
|
21
21
|
this.addCollection(r, this.provider);
|
|
22
22
|
}), this.nuxt = o;
|
|
23
23
|
}
|
|
24
24
|
addCollection(t, e) {
|
|
25
|
-
return
|
|
25
|
+
return Rt(t, e);
|
|
26
26
|
}
|
|
27
27
|
addIcon(t, e) {
|
|
28
|
-
return
|
|
28
|
+
return it(t, e);
|
|
29
29
|
}
|
|
30
30
|
addAPIProvider(t, e) {
|
|
31
|
-
return
|
|
31
|
+
return Lt(t, e);
|
|
32
32
|
}
|
|
33
33
|
fetchIcon(t, e = { cache: "force-cache" }) {
|
|
34
34
|
return new Promise((n, o) => {
|
|
@@ -38,14 +38,14 @@ class Yt {
|
|
|
38
38
|
}
|
|
39
39
|
const so = {
|
|
40
40
|
install(l, t) {
|
|
41
|
-
const e = new
|
|
41
|
+
const e = new Xt(t);
|
|
42
42
|
l.config.globalProperties.$ds = e, l.provide(Ne, e);
|
|
43
43
|
}
|
|
44
44
|
};
|
|
45
|
-
function
|
|
46
|
-
return e ? Be(l, e) === Be(t, e) :
|
|
45
|
+
function be(l, t, e) {
|
|
46
|
+
return e ? Be(l, e) === Be(t, e) : We(l, t);
|
|
47
47
|
}
|
|
48
|
-
function
|
|
48
|
+
function We(l, t) {
|
|
49
49
|
if (l === t)
|
|
50
50
|
return !0;
|
|
51
51
|
if (l && t && typeof l == "object" && typeof t == "object") {
|
|
@@ -55,7 +55,7 @@ function qe(l, t) {
|
|
|
55
55
|
if (r = l.length, r != t.length)
|
|
56
56
|
return !1;
|
|
57
57
|
for (o = r; o-- !== 0; )
|
|
58
|
-
if (!
|
|
58
|
+
if (!We(l[o], t[o]))
|
|
59
59
|
return !1;
|
|
60
60
|
return !0;
|
|
61
61
|
}
|
|
@@ -66,10 +66,10 @@ function qe(l, t) {
|
|
|
66
66
|
return !1;
|
|
67
67
|
if (b && c)
|
|
68
68
|
return l.getTime() == t.getTime();
|
|
69
|
-
const d = l instanceof RegExp,
|
|
70
|
-
if (d !=
|
|
69
|
+
const d = l instanceof RegExp, i = t instanceof RegExp;
|
|
70
|
+
if (d != i)
|
|
71
71
|
return !1;
|
|
72
|
-
if (d &&
|
|
72
|
+
if (d && i)
|
|
73
73
|
return l.toString() == t.toString();
|
|
74
74
|
const p = Object.keys(l);
|
|
75
75
|
if (r = p.length, r !== Object.keys(t).length)
|
|
@@ -78,7 +78,7 @@ function qe(l, t) {
|
|
|
78
78
|
if (!Object.prototype.hasOwnProperty.call(t, p[o]))
|
|
79
79
|
return !1;
|
|
80
80
|
for (o = r; o-- !== 0; )
|
|
81
|
-
if (s = p[o], !
|
|
81
|
+
if (s = p[o], !We(l[s], t[s]))
|
|
82
82
|
return !1;
|
|
83
83
|
return !0;
|
|
84
84
|
}
|
|
@@ -101,46 +101,46 @@ function Be(l, t) {
|
|
|
101
101
|
} else
|
|
102
102
|
return null;
|
|
103
103
|
}
|
|
104
|
-
function
|
|
104
|
+
function Zt(l, t) {
|
|
105
105
|
let e = -1;
|
|
106
106
|
if (t) {
|
|
107
107
|
for (let n = 0; n < t.length; n++)
|
|
108
|
-
if (
|
|
108
|
+
if (be(t[n], l)) {
|
|
109
109
|
e = n;
|
|
110
110
|
break;
|
|
111
111
|
}
|
|
112
112
|
}
|
|
113
113
|
return e;
|
|
114
114
|
}
|
|
115
|
-
function
|
|
115
|
+
function pe(l, t) {
|
|
116
116
|
if (l != null && t && t.length) {
|
|
117
117
|
for (const e of t)
|
|
118
|
-
if (
|
|
118
|
+
if (be(l, e))
|
|
119
119
|
return !0;
|
|
120
120
|
}
|
|
121
121
|
return !1;
|
|
122
122
|
}
|
|
123
|
-
function
|
|
123
|
+
function fe(l) {
|
|
124
124
|
return ((t) => t == null || t === "" || Array.isArray(t) && t.length === 0 || !(t instanceof Date) && typeof t == "object" && Object.keys(t).length === 0)(a(l));
|
|
125
125
|
}
|
|
126
|
-
function
|
|
127
|
-
const e =
|
|
126
|
+
function Yt(l, t) {
|
|
127
|
+
const e = Zt(l, t);
|
|
128
128
|
return e > -1 ? t.filter((n, o) => o !== e) : t;
|
|
129
129
|
}
|
|
130
|
-
function
|
|
130
|
+
function Jt(l) {
|
|
131
131
|
return typeof l == "string" || l instanceof String;
|
|
132
132
|
}
|
|
133
|
-
function
|
|
133
|
+
function ot(l) {
|
|
134
134
|
var t, e;
|
|
135
135
|
if (l)
|
|
136
136
|
return (e = (t = l.match(
|
|
137
137
|
/[A-Z]{2,}(?=[A-Z][a-z]+[0-9]*|\b)|[A-Z]?[a-z]+[0-9]*|[A-Z]|[0-9]+/g
|
|
138
138
|
)) == null ? void 0 : t.join("-")) == null ? void 0 : e.toLowerCase();
|
|
139
139
|
}
|
|
140
|
-
function
|
|
140
|
+
function G(l, t) {
|
|
141
141
|
const e = { [`${l}`]: !0 };
|
|
142
142
|
return {
|
|
143
|
-
bemCssClasses:
|
|
143
|
+
bemCssClasses: u(() => Object.keys(t).reduce((o, r) => {
|
|
144
144
|
const s = a(t[r]) || !1;
|
|
145
145
|
if (!s)
|
|
146
146
|
return o;
|
|
@@ -151,7 +151,7 @@ function H(l, t) {
|
|
|
151
151
|
...b.reduce(
|
|
152
152
|
(c, d) => ({
|
|
153
153
|
...c,
|
|
154
|
-
[`${l}--${
|
|
154
|
+
[`${l}--${ot(d)}`]: !0
|
|
155
155
|
}),
|
|
156
156
|
{}
|
|
157
157
|
)
|
|
@@ -159,17 +159,17 @@ function H(l, t) {
|
|
|
159
159
|
} else
|
|
160
160
|
return {
|
|
161
161
|
...o,
|
|
162
|
-
[`${l}--${
|
|
162
|
+
[`${l}--${ot(r)}`]: s
|
|
163
163
|
};
|
|
164
164
|
}, e) || {})
|
|
165
165
|
};
|
|
166
166
|
}
|
|
167
167
|
function xe(l) {
|
|
168
|
-
const t =
|
|
168
|
+
const t = ze(l, void 0), e = u(() => !fe(t));
|
|
169
169
|
function n(o, r, s) {
|
|
170
170
|
if (t != null && t.value) {
|
|
171
171
|
const c = a(t.value)[o];
|
|
172
|
-
return
|
|
172
|
+
return u({
|
|
173
173
|
get() {
|
|
174
174
|
return c == null ? void 0 : c.value;
|
|
175
175
|
},
|
|
@@ -178,8 +178,8 @@ function xe(l) {
|
|
|
178
178
|
}
|
|
179
179
|
});
|
|
180
180
|
}
|
|
181
|
-
const b =
|
|
182
|
-
return
|
|
181
|
+
const b = Tt(r, o);
|
|
182
|
+
return u({
|
|
183
183
|
get() {
|
|
184
184
|
return b.value;
|
|
185
185
|
},
|
|
@@ -194,7 +194,7 @@ function xe(l) {
|
|
|
194
194
|
getGroupOrLocalRef: n
|
|
195
195
|
};
|
|
196
196
|
}
|
|
197
|
-
const ft = "VV_BUTTON_GROUP", mt = "VV_RADIO_GROUP", bt = "VV_CHECK_GROUP", ht = "VV_ACCORDION_GROUP",
|
|
197
|
+
const ft = "VV_BUTTON_GROUP", mt = "VV_RADIO_GROUP", bt = "VV_CHECK_GROUP", ht = "VV_ACCORDION_GROUP", Qt = {
|
|
198
198
|
name: String,
|
|
199
199
|
title: String,
|
|
200
200
|
content: String,
|
|
@@ -204,86 +204,86 @@ const ft = "VV_BUTTON_GROUP", mt = "VV_RADIO_GROUP", bt = "VV_CHECK_GROUP", ht =
|
|
|
204
204
|
},
|
|
205
205
|
modifiers: [String, Array],
|
|
206
206
|
disabled: Boolean
|
|
207
|
-
},
|
|
208
|
-
function
|
|
209
|
-
const { group: e, isInGroup: n, getGroupOrLocalRef: o } = xe(ht), { title: r, content: s } =
|
|
207
|
+
}, el = ["update:modelValue"];
|
|
208
|
+
function tl(l, t) {
|
|
209
|
+
const { group: e, isInGroup: n, getGroupOrLocalRef: o } = xe(ht), { title: r, content: s } = W(l), b = o("modelValue", l, t), c = o("disabled", l), d = o("collapse", l), i = o("modifiers", l);
|
|
210
210
|
return {
|
|
211
211
|
modelValue: b,
|
|
212
212
|
disabled: c,
|
|
213
213
|
isInGroup: n,
|
|
214
214
|
group: e,
|
|
215
215
|
collapse: d,
|
|
216
|
-
modifiers:
|
|
216
|
+
modifiers: i,
|
|
217
217
|
title: r,
|
|
218
218
|
content: s
|
|
219
219
|
};
|
|
220
220
|
}
|
|
221
|
-
const
|
|
221
|
+
const ll = ["id", "open"], al = ["aria-controls", "aria-expanded"], ol = ["aria-hidden"], nl = {
|
|
222
222
|
name: "VvAccordion"
|
|
223
|
-
},
|
|
224
|
-
...
|
|
225
|
-
props:
|
|
226
|
-
emits:
|
|
223
|
+
}, sl = /* @__PURE__ */ D({
|
|
224
|
+
...nl,
|
|
225
|
+
props: Qt,
|
|
226
|
+
emits: el,
|
|
227
227
|
setup(l, { emit: t }) {
|
|
228
|
-
const e = l, n =
|
|
228
|
+
const e = l, n = ut(), o = e.name || (n == null ? void 0 : n.id) || de(), {
|
|
229
229
|
modifiers: r,
|
|
230
230
|
title: s,
|
|
231
231
|
content: b,
|
|
232
232
|
disabled: c,
|
|
233
233
|
collapse: d,
|
|
234
|
-
modelValue:
|
|
234
|
+
modelValue: i,
|
|
235
235
|
isInGroup: p
|
|
236
|
-
} =
|
|
237
|
-
get: () => p.value ? d.value && Array.isArray(
|
|
236
|
+
} = tl(e, t), v = j(!1), h = u({
|
|
237
|
+
get: () => p.value ? d.value && Array.isArray(i.value) ? i.value.includes(o) : i.value === o : i.value === void 0 ? v.value : i.value,
|
|
238
238
|
set: (f) => {
|
|
239
239
|
if (p.value) {
|
|
240
|
-
if (d.value && Array.isArray(
|
|
240
|
+
if (d.value && Array.isArray(i.value)) {
|
|
241
241
|
if (f) {
|
|
242
|
-
|
|
242
|
+
i.value.push(o);
|
|
243
243
|
return;
|
|
244
244
|
}
|
|
245
|
-
|
|
245
|
+
i.value = i.value.filter(
|
|
246
246
|
(V) => V !== o
|
|
247
247
|
);
|
|
248
248
|
return;
|
|
249
249
|
}
|
|
250
|
-
|
|
250
|
+
i.value = f ? o : null;
|
|
251
251
|
return;
|
|
252
252
|
}
|
|
253
|
-
if (
|
|
253
|
+
if (i.value === void 0 && typeof f == "boolean") {
|
|
254
254
|
v.value = f;
|
|
255
255
|
return;
|
|
256
256
|
}
|
|
257
|
-
|
|
257
|
+
i.value = f;
|
|
258
258
|
}
|
|
259
|
-
}), { bemCssClasses: g } =
|
|
259
|
+
}), { bemCssClasses: g } = G("vv-accordion", {
|
|
260
260
|
modifiers: r,
|
|
261
261
|
disabled: c
|
|
262
|
-
}), y =
|
|
262
|
+
}), y = Kt(h);
|
|
263
263
|
return (f, V) => (m(), _("details", {
|
|
264
264
|
id: a(o),
|
|
265
|
-
class:
|
|
265
|
+
class: F(a(g)),
|
|
266
266
|
open: a(h),
|
|
267
|
-
onClick: V[0] || (V[0] =
|
|
267
|
+
onClick: V[0] || (V[0] = qe((P) => a(y)(), ["prevent"]))
|
|
268
268
|
}, [
|
|
269
269
|
E("summary", {
|
|
270
270
|
"aria-controls": a(o),
|
|
271
271
|
"aria-expanded": a(h),
|
|
272
272
|
class: "vv-collapse__summary"
|
|
273
273
|
}, [
|
|
274
|
-
A(f.$slots, "summary",
|
|
274
|
+
A(f.$slots, "summary", K(ee({ open: a(h) })), () => [
|
|
275
275
|
X(L(a(s)), 1)
|
|
276
276
|
])
|
|
277
|
-
], 8,
|
|
277
|
+
], 8, al),
|
|
278
278
|
E("div", {
|
|
279
279
|
"aria-hidden": !a(h),
|
|
280
280
|
class: "vv-collapse__content"
|
|
281
281
|
}, [
|
|
282
|
-
A(f.$slots, "details",
|
|
282
|
+
A(f.$slots, "details", K(ee({ open: a(h) })), () => [
|
|
283
283
|
X(L(a(b)), 1)
|
|
284
284
|
])
|
|
285
|
-
], 8,
|
|
286
|
-
], 10,
|
|
285
|
+
], 8, ol)
|
|
286
|
+
], 10, ll));
|
|
287
287
|
}
|
|
288
288
|
});
|
|
289
289
|
function He(l) {
|
|
@@ -291,12 +291,12 @@ function He(l) {
|
|
|
291
291
|
(t) => t !== "key" && !$e(l[t])
|
|
292
292
|
))
|
|
293
293
|
throw Error("One or more groupState props aren't ref.");
|
|
294
|
-
|
|
294
|
+
Bt(
|
|
295
295
|
l.key,
|
|
296
|
-
|
|
296
|
+
u(() => l)
|
|
297
297
|
);
|
|
298
298
|
}
|
|
299
|
-
const
|
|
299
|
+
const rl = {
|
|
300
300
|
modelValue: [String, Array],
|
|
301
301
|
items: { type: Array, default: () => [] },
|
|
302
302
|
collapse: Boolean,
|
|
@@ -306,20 +306,20 @@ const ul = {
|
|
|
306
306
|
default: ""
|
|
307
307
|
},
|
|
308
308
|
disabled: Boolean
|
|
309
|
-
},
|
|
309
|
+
}, il = ["update:modelValue"], ul = {
|
|
310
310
|
name: "VvAccordionGroup"
|
|
311
311
|
}, ro = /* @__PURE__ */ D({
|
|
312
|
-
...
|
|
313
|
-
props:
|
|
314
|
-
emits:
|
|
312
|
+
...ul,
|
|
313
|
+
props: rl,
|
|
314
|
+
emits: il,
|
|
315
315
|
setup(l, { emit: t }) {
|
|
316
|
-
const e = l, { disabled: n, collapse: o, modifiers: r, itemModifiers: s, items: b } =
|
|
317
|
-
|
|
316
|
+
const e = l, { disabled: n, collapse: o, modifiers: r, itemModifiers: s, items: b } = W(e);
|
|
317
|
+
Xe(() => {
|
|
318
318
|
typeof e.modelValue == "string" && o.value && console.warn(
|
|
319
319
|
"[VvAccordionGroup]: modelValue is a string but collapse is true."
|
|
320
320
|
);
|
|
321
321
|
});
|
|
322
|
-
const c =
|
|
322
|
+
const c = j([]), d = u({
|
|
323
323
|
get: () => {
|
|
324
324
|
var v;
|
|
325
325
|
return e.modelValue !== void 0 ? o.value ? e.modelValue : Array.isArray(e.modelValue) ? e.modelValue[0] : e.modelValue : o.value ? c.value : (v = c.value) == null ? void 0 : v[0];
|
|
@@ -337,26 +337,26 @@ const ul = {
|
|
|
337
337
|
collapse: o,
|
|
338
338
|
modifiers: s
|
|
339
339
|
});
|
|
340
|
-
const { bemCssClasses: p } =
|
|
340
|
+
const { bemCssClasses: p } = G("vv-accordion-group", {
|
|
341
341
|
modifiers: r,
|
|
342
342
|
disabled: n
|
|
343
343
|
});
|
|
344
344
|
return (v, h) => (m(), _("div", {
|
|
345
|
-
class:
|
|
345
|
+
class: F(a(p))
|
|
346
346
|
}, [
|
|
347
347
|
A(v.$slots, "default", {}, () => [
|
|
348
|
-
(m(!0), _(
|
|
348
|
+
(m(!0), _(he, null, Ce(a(b), (g) => (m(), T(sl, R({
|
|
349
349
|
key: g.title
|
|
350
350
|
}, {
|
|
351
351
|
name: g.name,
|
|
352
352
|
title: g.title,
|
|
353
353
|
content: g.content
|
|
354
354
|
}), {
|
|
355
|
-
header:
|
|
356
|
-
A(v.$slots, `header::${g.name}`,
|
|
355
|
+
header: ke((y) => [
|
|
356
|
+
A(v.$slots, `header::${g.name}`, K(ee(y)))
|
|
357
357
|
]),
|
|
358
|
-
details:
|
|
359
|
-
A(v.$slots, `details::${g.name}`,
|
|
358
|
+
details: ke((y) => [
|
|
359
|
+
A(v.$slots, `details::${g.name}`, K(ee(y)))
|
|
360
360
|
]),
|
|
361
361
|
_: 2
|
|
362
362
|
}, 1040))), 128))
|
|
@@ -369,14 +369,14 @@ const ul = {
|
|
|
369
369
|
}, Ie = {
|
|
370
370
|
invalid: Boolean,
|
|
371
371
|
invalidLabel: [String, Array]
|
|
372
|
-
},
|
|
372
|
+
}, Ye = {
|
|
373
373
|
loading: Boolean,
|
|
374
374
|
loadingLabel: String
|
|
375
375
|
}, ye = {
|
|
376
376
|
disabled: Boolean
|
|
377
377
|
}, Oe = {
|
|
378
378
|
readonly: Boolean
|
|
379
|
-
},
|
|
379
|
+
}, ce = {
|
|
380
380
|
modifiers: [String, Array]
|
|
381
381
|
}, Ee = {
|
|
382
382
|
hintLabel: { type: String, default: "" }
|
|
@@ -387,27 +387,27 @@ const ul = {
|
|
|
387
387
|
},
|
|
388
388
|
labelKey: { type: [String, Function], default: "label" },
|
|
389
389
|
valueKey: { type: [String, Function], default: "value" }
|
|
390
|
-
},
|
|
390
|
+
}, dl = {
|
|
391
391
|
count: {
|
|
392
392
|
type: [Boolean, String],
|
|
393
393
|
default: !1,
|
|
394
394
|
validator: (l) => [!0, !1, "limit", "countdown"].includes(l)
|
|
395
395
|
}
|
|
396
|
-
},
|
|
396
|
+
}, cl = {
|
|
397
397
|
debounce: [Number, String]
|
|
398
|
-
},
|
|
398
|
+
}, nt = {
|
|
399
399
|
LEFT: "left",
|
|
400
400
|
RIGHT: "right"
|
|
401
|
-
},
|
|
401
|
+
}, Je = {
|
|
402
402
|
icon: { type: [String, Object] },
|
|
403
403
|
iconPosition: {
|
|
404
404
|
type: String,
|
|
405
|
-
validation: (l) => Object.values(
|
|
406
|
-
default:
|
|
405
|
+
validation: (l) => Object.values(nt).includes(l),
|
|
406
|
+
default: nt.RIGHT
|
|
407
407
|
}
|
|
408
408
|
}, Ge = {
|
|
409
409
|
tabindex: { type: [String, Number], default: 0 }
|
|
410
|
-
},
|
|
410
|
+
}, Qe = {
|
|
411
411
|
floating: Boolean
|
|
412
412
|
}, Ue = {
|
|
413
413
|
unselectable: { type: Boolean, default: !0 }
|
|
@@ -428,12 +428,12 @@ const ul = {
|
|
|
428
428
|
...Pe,
|
|
429
429
|
...Ie,
|
|
430
430
|
...Ee,
|
|
431
|
-
...
|
|
432
|
-
...
|
|
433
|
-
...
|
|
434
|
-
...
|
|
435
|
-
...
|
|
436
|
-
...
|
|
431
|
+
...Ye,
|
|
432
|
+
...ce,
|
|
433
|
+
...dl,
|
|
434
|
+
...cl,
|
|
435
|
+
...Je,
|
|
436
|
+
...Qe,
|
|
437
437
|
minlength: Number,
|
|
438
438
|
maxlength: Number,
|
|
439
439
|
placeholder: String,
|
|
@@ -461,20 +461,20 @@ const ul = {
|
|
|
461
461
|
label: String,
|
|
462
462
|
name: { type: String, required: !0 },
|
|
463
463
|
vertical: Boolean
|
|
464
|
-
},
|
|
465
|
-
...
|
|
464
|
+
}, vl = {
|
|
465
|
+
...ce,
|
|
466
466
|
value: [String, Number]
|
|
467
|
-
},
|
|
467
|
+
}, pl = {
|
|
468
468
|
name: "VvBadge"
|
|
469
469
|
}, io = /* @__PURE__ */ D({
|
|
470
|
-
...
|
|
471
|
-
props:
|
|
470
|
+
...pl,
|
|
471
|
+
props: vl,
|
|
472
472
|
setup(l) {
|
|
473
|
-
const t = l, { bemCssClasses: e } =
|
|
473
|
+
const t = l, { bemCssClasses: e } = G("vv-badge", {
|
|
474
474
|
modifiers: t.modifiers
|
|
475
475
|
});
|
|
476
476
|
return (n, o) => (m(), _("span", {
|
|
477
|
-
class:
|
|
477
|
+
class: F(a(e)),
|
|
478
478
|
role: "status"
|
|
479
479
|
}, [
|
|
480
480
|
A(n.$slots, "default", {}, () => [
|
|
@@ -482,28 +482,28 @@ const ul = {
|
|
|
482
482
|
])
|
|
483
483
|
], 2));
|
|
484
484
|
}
|
|
485
|
-
}),
|
|
486
|
-
...
|
|
485
|
+
}), fl = {
|
|
486
|
+
...ce,
|
|
487
487
|
routes: Array
|
|
488
|
-
},
|
|
488
|
+
}, ml = { class: "vv-breadcrumb__list" }, bl = ["content"], hl = {
|
|
489
489
|
name: "VvBreadcrumb"
|
|
490
490
|
}, uo = /* @__PURE__ */ D({
|
|
491
|
-
...
|
|
492
|
-
props:
|
|
491
|
+
...hl,
|
|
492
|
+
props: fl,
|
|
493
493
|
setup(l) {
|
|
494
|
-
const t = l, { bemCssClasses: e } =
|
|
494
|
+
const t = l, { bemCssClasses: e } = G("vv-breadcrumb", {
|
|
495
495
|
modifiers: t.modifiers
|
|
496
496
|
});
|
|
497
497
|
return (n, o) => (m(), _("nav", {
|
|
498
|
-
class:
|
|
498
|
+
class: F(a(e)),
|
|
499
499
|
"aria-label": "breadcrumbs"
|
|
500
500
|
}, [
|
|
501
|
-
E("ol",
|
|
502
|
-
(m(!0), _(
|
|
503
|
-
var b, c, d,
|
|
501
|
+
E("ol", ml, [
|
|
502
|
+
(m(!0), _(he, null, Ce(n.routes, (r, s) => {
|
|
503
|
+
var b, c, d, i;
|
|
504
504
|
return m(), _("li", {
|
|
505
505
|
key: `${r.label}-${s}`,
|
|
506
|
-
class:
|
|
506
|
+
class: F({
|
|
507
507
|
"vv-breadcrumb__item": s < Number((b = n.routes) == null ? void 0 : b.length) - 1,
|
|
508
508
|
"vv-breadcrumb__item-active": s === Number((c = n.routes) == null ? void 0 : c.length) - 1
|
|
509
509
|
}),
|
|
@@ -511,15 +511,15 @@ const ul = {
|
|
|
511
511
|
itemtype: "https://schema.org/ListItem",
|
|
512
512
|
itemscope: ""
|
|
513
513
|
}, [
|
|
514
|
-
(m(), T(
|
|
514
|
+
(m(), T(dt(r.to ? "router-link" : r.href ? "a" : "span"), R(r, {
|
|
515
515
|
class: {
|
|
516
516
|
"vv-breadcrumb__link": s < Number((d = n.routes) == null ? void 0 : d.length) - 1
|
|
517
517
|
},
|
|
518
|
-
"aria-current": s === Number((
|
|
518
|
+
"aria-current": s === Number((i = n.routes) == null ? void 0 : i.length) - 1 ? "page" : void 0,
|
|
519
519
|
itemprop: "item"
|
|
520
520
|
}), {
|
|
521
|
-
default:
|
|
522
|
-
A(n.$slots, "label",
|
|
521
|
+
default: ke(() => [
|
|
522
|
+
A(n.$slots, "label", K(ee({ route: r, index: s })), () => [
|
|
523
523
|
X(L(r.label), 1)
|
|
524
524
|
])
|
|
525
525
|
]),
|
|
@@ -528,13 +528,13 @@ const ul = {
|
|
|
528
528
|
E("meta", {
|
|
529
529
|
itemprop: "position",
|
|
530
530
|
content: `${s + 1}`
|
|
531
|
-
}, null, 8,
|
|
531
|
+
}, null, 8, bl)
|
|
532
532
|
], 2);
|
|
533
533
|
}), 128))
|
|
534
534
|
])
|
|
535
535
|
], 2));
|
|
536
536
|
}
|
|
537
|
-
}),
|
|
537
|
+
}), gl = {
|
|
538
538
|
color: String,
|
|
539
539
|
width: {
|
|
540
540
|
type: [String, Number]
|
|
@@ -565,62 +565,62 @@ const ul = {
|
|
|
565
565
|
modifiers: {
|
|
566
566
|
type: [String, Array]
|
|
567
567
|
}
|
|
568
|
-
},
|
|
568
|
+
}, yl = {
|
|
569
569
|
name: "VvIcon"
|
|
570
|
-
},
|
|
571
|
-
...
|
|
572
|
-
props:
|
|
570
|
+
}, M = /* @__PURE__ */ D({
|
|
571
|
+
...yl,
|
|
572
|
+
props: gl,
|
|
573
573
|
setup(l) {
|
|
574
|
-
const t = l, e =
|
|
574
|
+
const t = l, e = j(!0), { modifiers: n } = W(t), o = ze(Ne), { bemCssClasses: r } = G("vv-icon", {
|
|
575
575
|
modifiers: n
|
|
576
|
-
}), s =
|
|
577
|
-
const
|
|
578
|
-
return De(
|
|
579
|
-
const h = `@${s.value}:${v.prefix}:${
|
|
576
|
+
}), s = u(() => t.provider || (o == null ? void 0 : o.provider)), b = u(() => {
|
|
577
|
+
const i = t.name ?? "", p = `@${s.value}:${t.prefix}:${t.name}`;
|
|
578
|
+
return De(i) ? i : De(p) ? p : (o == null ? void 0 : o.iconsCollections.find((v) => {
|
|
579
|
+
const h = `@${s.value}:${v.prefix}:${i}`;
|
|
580
580
|
if (De(h))
|
|
581
581
|
return h;
|
|
582
|
-
})) ||
|
|
582
|
+
})) || i;
|
|
583
583
|
});
|
|
584
|
-
function c(
|
|
584
|
+
function c(i) {
|
|
585
585
|
let p = null;
|
|
586
586
|
if (typeof window > "u") {
|
|
587
587
|
const { JSDOM: y } = require("jsdom");
|
|
588
588
|
p = new y().window;
|
|
589
589
|
}
|
|
590
|
-
return (p ? new p.DOMParser() : new window.DOMParser()).parseFromString(
|
|
590
|
+
return (p ? new p.DOMParser() : new window.DOMParser()).parseFromString(i, "text/html").querySelector("svg");
|
|
591
591
|
}
|
|
592
|
-
function d(
|
|
593
|
-
const p = c(
|
|
594
|
-
p && v &&
|
|
592
|
+
function d(i) {
|
|
593
|
+
const p = c(i), v = (p == null ? void 0 : p.innerHTML.trim()) || "";
|
|
594
|
+
p && v && it(`@${s.value}:${t.prefix}:${t.name}`, {
|
|
595
595
|
body: v,
|
|
596
596
|
height: p.viewBox.baseVal.height,
|
|
597
597
|
width: p.viewBox.baseVal.width
|
|
598
598
|
});
|
|
599
599
|
}
|
|
600
|
-
return o && (t.src && !De(`@${s.value}:${t.prefix}:${t.name}`) ? (e.value = !1, o.fetchIcon(t.src).then((
|
|
601
|
-
|
|
602
|
-
}).catch((
|
|
603
|
-
throw new Error(`During fetch icon: ${
|
|
604
|
-
})) : t.svg && d(t.svg)), (
|
|
600
|
+
return o && (t.src && !De(`@${s.value}:${t.prefix}:${t.name}`) ? (e.value = !1, o.fetchIcon(t.src).then((i) => {
|
|
601
|
+
i && (d(i), e.value = !0);
|
|
602
|
+
}).catch((i) => {
|
|
603
|
+
throw new Error(`During fetch icon: ${i == null ? void 0 : i.message}`);
|
|
604
|
+
})) : t.svg && d(t.svg)), (i, p) => e.value ? (m(), T(a(Dt), R({
|
|
605
605
|
key: 0,
|
|
606
606
|
class: a(r)
|
|
607
607
|
}, {
|
|
608
|
-
inline:
|
|
609
|
-
width:
|
|
610
|
-
height:
|
|
611
|
-
horizontalFlip:
|
|
612
|
-
verticalFlip:
|
|
613
|
-
flip:
|
|
614
|
-
rotate:
|
|
615
|
-
color:
|
|
616
|
-
onLoad:
|
|
608
|
+
inline: i.inline,
|
|
609
|
+
width: i.width,
|
|
610
|
+
height: i.height,
|
|
611
|
+
horizontalFlip: i.horizontalFlip,
|
|
612
|
+
verticalFlip: i.verticalFlip,
|
|
613
|
+
flip: i.flip,
|
|
614
|
+
rotate: i.rotate,
|
|
615
|
+
color: i.color,
|
|
616
|
+
onLoad: i.onLoad,
|
|
617
617
|
icon: a(b)
|
|
618
618
|
}), null, 16, ["class"])) : I("", !0);
|
|
619
619
|
}
|
|
620
620
|
});
|
|
621
|
-
var Ve = /* @__PURE__ */ ((l) => (l.left = "left", l.right = "right", l.top = "top", l.bottom = "bottom", l))(Ve || {}), $t = /* @__PURE__ */ ((l) => (l.button = "button", l.submit = "submit", l.reset = "reset", l))($t || {}),
|
|
622
|
-
const
|
|
623
|
-
...
|
|
621
|
+
var Ve = /* @__PURE__ */ ((l) => (l.left = "left", l.right = "right", l.top = "top", l.bottom = "bottom", l))(Ve || {}), $t = /* @__PURE__ */ ((l) => (l.button = "button", l.submit = "submit", l.reset = "reset", l))($t || {}), ue = /* @__PURE__ */ ((l) => (l.nuxtLink = "nuxt-link", l.routerLink = "router-link", l.a = "a", l.button = "button", l))(ue || {}), Ct = /* @__PURE__ */ ((l) => (l._blank = "_blank", l._self = "_self", l._parent = "_parent", l._top = "_top", l))(Ct || {});
|
|
622
|
+
const _l = ["update:modelValue"], Sl = {
|
|
623
|
+
...ce,
|
|
624
624
|
...ye,
|
|
625
625
|
...Ue,
|
|
626
626
|
icon: {
|
|
@@ -664,7 +664,7 @@ const Vl = ["update:modelValue"], $l = {
|
|
|
664
664
|
},
|
|
665
665
|
modelValue: String
|
|
666
666
|
};
|
|
667
|
-
function
|
|
667
|
+
function Vl(l, t) {
|
|
668
668
|
var f;
|
|
669
669
|
const { group: e, isInGroup: n, getGroupOrLocalRef: o } = xe(ft), {
|
|
670
670
|
iconPosition: r,
|
|
@@ -672,10 +672,10 @@ function Cl(l, t) {
|
|
|
672
672
|
label: b,
|
|
673
673
|
pressed: c,
|
|
674
674
|
modifiers: d
|
|
675
|
-
} =
|
|
675
|
+
} = W(l), i = o("modelValue", l, t), p = o("disabled", l), v = o("toggle", l), h = o(
|
|
676
676
|
"unselectable",
|
|
677
677
|
l
|
|
678
|
-
), g = ((f = e == null ? void 0 : e.value) == null ? void 0 : f.multiple) ??
|
|
678
|
+
), g = ((f = e == null ? void 0 : e.value) == null ? void 0 : f.multiple) ?? j(!1), y = u(() => {
|
|
679
679
|
var $;
|
|
680
680
|
const V = d != null && d.value ? Array.isArray(d.value) ? d.value : [d.value] : [], P = ($ = e == null ? void 0 : e.value.itemModifiers) != null && $.value ? Array.isArray(e.value.itemModifiers.value) ? e.value.itemModifiers.value : [e.value.itemModifiers.value] : [];
|
|
681
681
|
return [...V, ...P];
|
|
@@ -683,7 +683,7 @@ function Cl(l, t) {
|
|
|
683
683
|
return {
|
|
684
684
|
group: e,
|
|
685
685
|
isInGroup: n,
|
|
686
|
-
modelValue:
|
|
686
|
+
modelValue: i,
|
|
687
687
|
disabled: p,
|
|
688
688
|
toggle: v,
|
|
689
689
|
unselectable: h,
|
|
@@ -695,66 +695,66 @@ function Cl(l, t) {
|
|
|
695
695
|
label: b
|
|
696
696
|
};
|
|
697
697
|
}
|
|
698
|
-
const
|
|
698
|
+
const $l = {
|
|
699
699
|
key: 1,
|
|
700
700
|
class: "vv-button__label"
|
|
701
|
-
},
|
|
701
|
+
}, Cl = {
|
|
702
702
|
key: 1,
|
|
703
703
|
class: "vv-button__label"
|
|
704
|
-
},
|
|
704
|
+
}, Al = {
|
|
705
705
|
name: "VvButton"
|
|
706
706
|
}, co = /* @__PURE__ */ D({
|
|
707
|
-
...
|
|
708
|
-
props:
|
|
709
|
-
emits:
|
|
707
|
+
...Al,
|
|
708
|
+
props: Sl,
|
|
709
|
+
emits: _l,
|
|
710
710
|
setup(l, { emit: t }) {
|
|
711
|
-
const e = l, n =
|
|
711
|
+
const e = l, n = ut(), o = ge(), r = (n == null ? void 0 : n.name) || de(), {
|
|
712
712
|
modifiers: s,
|
|
713
713
|
iconPosition: b,
|
|
714
714
|
icon: c,
|
|
715
715
|
label: d,
|
|
716
|
-
modelValue:
|
|
716
|
+
modelValue: i,
|
|
717
717
|
disabled: p,
|
|
718
718
|
toggle: v,
|
|
719
719
|
unselectable: h
|
|
720
|
-
} =
|
|
720
|
+
} = Vl(e, t), g = ze(Ne), y = u(() => {
|
|
721
721
|
switch (!0) {
|
|
722
722
|
case p.value:
|
|
723
|
-
return
|
|
723
|
+
return ue.button;
|
|
724
724
|
case e.to !== void 0:
|
|
725
|
-
return g != null && g.nuxt ?
|
|
725
|
+
return g != null && g.nuxt ? ue.nuxtLink : ue.routerLink;
|
|
726
726
|
case e.href !== void 0:
|
|
727
|
-
return
|
|
727
|
+
return ue.a;
|
|
728
728
|
default:
|
|
729
|
-
return
|
|
729
|
+
return ue.button;
|
|
730
730
|
}
|
|
731
|
-
}), f =
|
|
731
|
+
}), f = u(() => v.value ? Array.isArray(i.value) ? pe(r, i.value) : be(r, i.value) : e.pressed), { bemCssClasses: V } = G("vv-button", {
|
|
732
732
|
modifiers: s,
|
|
733
733
|
active: e.active,
|
|
734
734
|
pressed: f,
|
|
735
735
|
disabled: p,
|
|
736
|
-
reverse:
|
|
736
|
+
reverse: u(
|
|
737
737
|
() => [Ve.right, Ve.bottom].includes(
|
|
738
738
|
b.value
|
|
739
739
|
)
|
|
740
740
|
),
|
|
741
|
-
column:
|
|
741
|
+
column: u(
|
|
742
742
|
() => [Ve.top, Ve.bottom].includes(
|
|
743
743
|
b.value
|
|
744
744
|
)
|
|
745
745
|
),
|
|
746
|
-
iconOnly:
|
|
746
|
+
iconOnly: u(
|
|
747
747
|
() => (c == null ? void 0 : c.value) && !(d != null && d.value) && !o.default
|
|
748
748
|
)
|
|
749
|
-
}), P =
|
|
749
|
+
}), P = u(
|
|
750
750
|
() => typeof (c == null ? void 0 : c.value) == "string" ? { name: c == null ? void 0 : c.value } : c == null ? void 0 : c.value
|
|
751
|
-
), $ =
|
|
751
|
+
), $ = u(() => {
|
|
752
752
|
const C = {
|
|
753
753
|
class: V.value,
|
|
754
754
|
"aria-pressed": f.value ? !0 : void 0
|
|
755
755
|
};
|
|
756
756
|
switch (y.value) {
|
|
757
|
-
case
|
|
757
|
+
case ue.a:
|
|
758
758
|
return {
|
|
759
759
|
...C,
|
|
760
760
|
role: "button",
|
|
@@ -762,8 +762,8 @@ const Al = {
|
|
|
762
762
|
target: e.target,
|
|
763
763
|
rel: e.rel
|
|
764
764
|
};
|
|
765
|
-
case
|
|
766
|
-
case
|
|
765
|
+
case ue.routerLink:
|
|
766
|
+
case ue.nuxtLink:
|
|
767
767
|
return {
|
|
768
768
|
...C,
|
|
769
769
|
role: "button",
|
|
@@ -779,40 +779,40 @@ const Al = {
|
|
|
779
779
|
}
|
|
780
780
|
}), x = () => {
|
|
781
781
|
if (v.value) {
|
|
782
|
-
if (Array.isArray(
|
|
783
|
-
if (
|
|
784
|
-
h.value && (
|
|
782
|
+
if (Array.isArray(i.value)) {
|
|
783
|
+
if (pe(r, i.value)) {
|
|
784
|
+
h.value && (i.value = i.value.filter(
|
|
785
785
|
(C) => C !== r
|
|
786
786
|
));
|
|
787
787
|
return;
|
|
788
788
|
}
|
|
789
|
-
|
|
789
|
+
i.value.push(r);
|
|
790
790
|
return;
|
|
791
791
|
}
|
|
792
|
-
if (
|
|
793
|
-
|
|
792
|
+
if (be(r, i.value) && h.value) {
|
|
793
|
+
i.value = void 0;
|
|
794
794
|
return;
|
|
795
795
|
}
|
|
796
|
-
|
|
796
|
+
i.value = r;
|
|
797
797
|
}
|
|
798
798
|
};
|
|
799
|
-
return (C,
|
|
800
|
-
default:
|
|
799
|
+
return (C, H) => (m(), T(dt(a(y)), R(a($), { onClickPassive: x }), {
|
|
800
|
+
default: ke(() => [
|
|
801
801
|
A(C.$slots, "default", {}, () => [
|
|
802
802
|
C.loading ? A(C.$slots, "loading", { key: 0 }, () => [
|
|
803
|
-
C.loadingIcon ? (m(), T(
|
|
803
|
+
C.loadingIcon ? (m(), T(M, {
|
|
804
804
|
key: 0,
|
|
805
805
|
class: "vv-button__loading-icon",
|
|
806
806
|
name: C.loadingIcon
|
|
807
807
|
}, null, 8, ["name"])) : I("", !0),
|
|
808
|
-
C.loadingLabel ? (m(), _("span",
|
|
809
|
-
]) : (m(), _(
|
|
808
|
+
C.loadingLabel ? (m(), _("span", $l, L(C.loadingLabel), 1)) : I("", !0)
|
|
809
|
+
]) : (m(), _(he, { key: 1 }, [
|
|
810
810
|
A(C.$slots, "before"),
|
|
811
|
-
a(c) ? (m(), T(
|
|
811
|
+
a(c) ? (m(), T(M, R({
|
|
812
812
|
key: 0,
|
|
813
813
|
class: "vv-button__icon"
|
|
814
814
|
}, a(P)), null, 16)) : I("", !0),
|
|
815
|
-
a(d) ? (m(), _("span",
|
|
815
|
+
a(d) ? (m(), _("span", Cl, [
|
|
816
816
|
A(C.$slots, "label", {}, () => [
|
|
817
817
|
X(L(a(d)), 1)
|
|
818
818
|
])
|
|
@@ -824,20 +824,20 @@ const Al = {
|
|
|
824
824
|
_: 3
|
|
825
825
|
}, 16));
|
|
826
826
|
}
|
|
827
|
-
}),
|
|
828
|
-
...
|
|
827
|
+
}), kl = {
|
|
828
|
+
...ce,
|
|
829
829
|
...ye,
|
|
830
830
|
...Ue,
|
|
831
831
|
itemModifiers: { type: [String, Array], default: void 0 },
|
|
832
832
|
toggle: { type: Boolean, default: !1 },
|
|
833
833
|
multiple: { type: Boolean, default: !1 },
|
|
834
834
|
modelValue: { type: [String, Array], default: void 0 }
|
|
835
|
-
},
|
|
835
|
+
}, wl = ["update:modelValue"], Pl = {
|
|
836
836
|
name: "VvButtonGroup"
|
|
837
837
|
}, vo = /* @__PURE__ */ D({
|
|
838
|
-
...
|
|
839
|
-
props:
|
|
840
|
-
emits:
|
|
838
|
+
...Pl,
|
|
839
|
+
props: kl,
|
|
840
|
+
emits: wl,
|
|
841
841
|
setup(l, { emit: t }) {
|
|
842
842
|
const e = l, {
|
|
843
843
|
disabled: n,
|
|
@@ -846,13 +846,13 @@ const Al = {
|
|
|
846
846
|
multiple: s,
|
|
847
847
|
unselectable: b,
|
|
848
848
|
itemModifiers: c
|
|
849
|
-
} =
|
|
850
|
-
|
|
849
|
+
} = W(e);
|
|
850
|
+
Xe(() => {
|
|
851
851
|
typeof e.modelValue == "string" && s.value && console.warn(
|
|
852
852
|
"[VvButtonGroup]: modelValue is a string but multiple is true."
|
|
853
853
|
);
|
|
854
854
|
});
|
|
855
|
-
const d =
|
|
855
|
+
const d = u({
|
|
856
856
|
get: () => s.value ? e.modelValue : Array.isArray(e.modelValue) ? e.modelValue[0] : e.modelValue,
|
|
857
857
|
set: (v) => (v !== void 0 && (Array.isArray(e.modelValue) || s.value) && !Array.isArray(v) && (v = [v]), t("update:modelValue", v))
|
|
858
858
|
});
|
|
@@ -865,62 +865,62 @@ const Al = {
|
|
|
865
865
|
unselectable: b,
|
|
866
866
|
itemModifiers: c
|
|
867
867
|
});
|
|
868
|
-
const { bemCssClasses: p } =
|
|
868
|
+
const { bemCssClasses: p } = G("vv-button-group", {
|
|
869
869
|
modifiers: r
|
|
870
870
|
});
|
|
871
871
|
return (v, h) => (m(), _("div", {
|
|
872
|
-
class:
|
|
872
|
+
class: F(a(p)),
|
|
873
873
|
role: "group"
|
|
874
874
|
}, [
|
|
875
875
|
A(v.$slots, "default")
|
|
876
876
|
], 2));
|
|
877
877
|
}
|
|
878
|
-
}),
|
|
878
|
+
}), Il = {
|
|
879
879
|
title: String,
|
|
880
880
|
modifiers: [String, Array]
|
|
881
|
-
},
|
|
881
|
+
}, Ol = {
|
|
882
882
|
key: 0,
|
|
883
883
|
class: "vv-card__header"
|
|
884
|
-
},
|
|
884
|
+
}, El = {
|
|
885
885
|
key: 1,
|
|
886
886
|
class: "vv-card__content"
|
|
887
|
-
},
|
|
887
|
+
}, Rl = {
|
|
888
888
|
key: 2,
|
|
889
889
|
class: "vv-card__footer"
|
|
890
|
-
},
|
|
890
|
+
}, Ll = {
|
|
891
891
|
name: "VvCard"
|
|
892
892
|
}, po = /* @__PURE__ */ D({
|
|
893
|
-
...
|
|
894
|
-
props:
|
|
893
|
+
...Ll,
|
|
894
|
+
props: Il,
|
|
895
895
|
setup(l) {
|
|
896
|
-
const t = l, { bemCssClasses: e } =
|
|
896
|
+
const t = l, { bemCssClasses: e } = G("vv-card", {
|
|
897
897
|
modifiers: t.modifiers
|
|
898
898
|
});
|
|
899
899
|
return (n, o) => (m(), _("article", {
|
|
900
|
-
class:
|
|
900
|
+
class: F(a(e))
|
|
901
901
|
}, [
|
|
902
|
-
n.$slots.header || n.title ? (m(), _("header",
|
|
902
|
+
n.$slots.header || n.title ? (m(), _("header", Ol, [
|
|
903
903
|
A(n.$slots, "header", {}, () => [
|
|
904
904
|
X(L(n.title), 1)
|
|
905
905
|
])
|
|
906
906
|
])) : I("", !0),
|
|
907
907
|
A(n.$slots, "default"),
|
|
908
|
-
n.$slots.content ? (m(), _("div",
|
|
908
|
+
n.$slots.content ? (m(), _("div", El, [
|
|
909
909
|
A(n.$slots, "content")
|
|
910
910
|
])) : I("", !0),
|
|
911
|
-
n.$slots.footer ? (m(), _("footer",
|
|
911
|
+
n.$slots.footer ? (m(), _("footer", Rl, [
|
|
912
912
|
A(n.$slots, "footer")
|
|
913
913
|
])) : I("", !0)
|
|
914
914
|
], 2));
|
|
915
915
|
}
|
|
916
|
-
}),
|
|
916
|
+
}), Dl = {
|
|
917
917
|
...St,
|
|
918
918
|
indeterminate: Boolean,
|
|
919
919
|
uncheckedValue: [String, Number, Boolean],
|
|
920
920
|
switch: Boolean
|
|
921
|
-
},
|
|
922
|
-
function
|
|
923
|
-
const { group: e, isInGroup: n, getGroupOrLocalRef: o } = xe(bt), { switch: r, indeterminate: s } =
|
|
921
|
+
}, Tl = ["click", "update:modelValue", "change", "blur"];
|
|
922
|
+
function Bl(l, t) {
|
|
923
|
+
const { group: e, isInGroup: n, getGroupOrLocalRef: o } = xe(bt), { switch: r, indeterminate: s } = W(l), b = o("modelValue", l, t), c = o("readonly", l), d = o("disabled", l), i = o("valid", l), p = o("invalid", l);
|
|
924
924
|
return {
|
|
925
925
|
propsSwitch: r,
|
|
926
926
|
indeterminate: s,
|
|
@@ -929,12 +929,12 @@ function xl(l, t) {
|
|
|
929
929
|
modelValue: b,
|
|
930
930
|
readonly: c,
|
|
931
931
|
disabled: d,
|
|
932
|
-
valid:
|
|
932
|
+
valid: i,
|
|
933
933
|
invalid: p
|
|
934
934
|
};
|
|
935
935
|
}
|
|
936
936
|
function Te(l) {
|
|
937
|
-
return Array.isArray(l) ? l.filter((t) =>
|
|
937
|
+
return Array.isArray(l) ? l.filter((t) => Jt(t)).join(" ") : l;
|
|
938
938
|
}
|
|
939
939
|
function _e(l, t) {
|
|
940
940
|
const {
|
|
@@ -947,16 +947,16 @@ function _e(l, t) {
|
|
|
947
947
|
modelValue: b,
|
|
948
948
|
valid: c,
|
|
949
949
|
validLabel: d,
|
|
950
|
-
invalid:
|
|
950
|
+
invalid: i,
|
|
951
951
|
invalidLabel: p,
|
|
952
952
|
...v
|
|
953
|
-
} =
|
|
953
|
+
} = W(l), h = Be(v, "loading"), g = Be(v, "loadingLabel"), y = u(() => i.value ? !!(i.value && e || p != null && p.value && Array.isArray(p.value) && p.value.length > 0 || p != null && p.value && !fe(p)) : !1), f = u(
|
|
954
954
|
() => !!(s && s.value || o)
|
|
955
|
-
), V =
|
|
955
|
+
), V = u(
|
|
956
956
|
() => !!(d && d.value || n)
|
|
957
|
-
), P =
|
|
957
|
+
), P = u(
|
|
958
958
|
() => !!(h != null && h.value && r || h != null && h.value && (g != null && g.value))
|
|
959
|
-
), $ =
|
|
959
|
+
), $ = u(
|
|
960
960
|
() => f.value || V.value || y.value || P.value
|
|
961
961
|
);
|
|
962
962
|
return {
|
|
@@ -973,19 +973,19 @@ function _e(l, t) {
|
|
|
973
973
|
}
|
|
974
974
|
},
|
|
975
975
|
setup(x) {
|
|
976
|
-
const C =
|
|
977
|
-
const
|
|
976
|
+
const C = u(() => {
|
|
977
|
+
const H = Wt({
|
|
978
978
|
hintLabel: s,
|
|
979
979
|
modelValue: b,
|
|
980
980
|
valid: c,
|
|
981
981
|
validLabel: d,
|
|
982
|
-
invalid:
|
|
982
|
+
invalid: i,
|
|
983
983
|
invalidLabel: p,
|
|
984
984
|
loading: h,
|
|
985
985
|
loadingLabel: g,
|
|
986
986
|
...x.params
|
|
987
987
|
});
|
|
988
|
-
return
|
|
988
|
+
return i != null && i.value ? (e == null ? void 0 : e(H)) || Te(p == null ? void 0 : p.value) || (s == null ? void 0 : s.value) : c != null && c.value ? (n == null ? void 0 : n(H)) || Te(d == null ? void 0 : d.value) || (s == null ? void 0 : s.value) : h != null && h.value ? (r == null ? void 0 : r(H)) || Te(g == null ? void 0 : g.value) || (s == null ? void 0 : s.value) : (o == null ? void 0 : o(H)) || Te(s == null ? void 0 : s.value) || (s == null ? void 0 : s.value);
|
|
989
989
|
});
|
|
990
990
|
return {
|
|
991
991
|
isVisible: $,
|
|
@@ -1007,33 +1007,33 @@ function _e(l, t) {
|
|
|
1007
1007
|
}
|
|
1008
1008
|
};
|
|
1009
1009
|
}
|
|
1010
|
-
const
|
|
1010
|
+
const Nl = ["for"], xl = ["id", "name", "disabled", "value", "tabindex", "aria-invalid"], Hl = {
|
|
1011
1011
|
name: "VvCheckbox"
|
|
1012
|
-
},
|
|
1013
|
-
...
|
|
1014
|
-
props:
|
|
1015
|
-
emits:
|
|
1012
|
+
}, Ml = /* @__PURE__ */ D({
|
|
1013
|
+
...Hl,
|
|
1014
|
+
props: Dl,
|
|
1015
|
+
emits: Tl,
|
|
1016
1016
|
setup(l, { emit: t }) {
|
|
1017
|
-
const e = l, n =
|
|
1017
|
+
const e = l, n = ge(), {
|
|
1018
1018
|
disabled: o,
|
|
1019
1019
|
readonly: r,
|
|
1020
1020
|
valid: s,
|
|
1021
1021
|
invalid: b,
|
|
1022
1022
|
propsSwitch: c,
|
|
1023
1023
|
modelValue: d,
|
|
1024
|
-
indeterminate:
|
|
1024
|
+
indeterminate: i,
|
|
1025
1025
|
isInGroup: p
|
|
1026
|
-
} =
|
|
1026
|
+
} = Bl(e, t), v = u(() => String(e.id || de())), h = u(() => f.value ? -1 : e.tabindex), g = j(), y = u(
|
|
1027
1027
|
() => e.uncheckedValue !== void 0 && !p.value
|
|
1028
|
-
), f =
|
|
1028
|
+
), f = u(() => o.value || r.value), V = u(() => {
|
|
1029
1029
|
if (b.value === !0)
|
|
1030
1030
|
return !0;
|
|
1031
1031
|
if (s.value === !0)
|
|
1032
1032
|
return !1;
|
|
1033
|
-
}), P =
|
|
1033
|
+
}), P = u(() => y.value ? d.value === e.value : Array.isArray(d.value) ? pe(e.value, d.value) : be(e.value, d.value)), $ = u(() => !!(i.value || !P.value && y.value && e.uncheckedValue !== d.value)), x = u(() => {
|
|
1034
1034
|
if (!y.value)
|
|
1035
1035
|
return ["string", "number", "boolean"].includes(typeof e.value) ? e.value : !0;
|
|
1036
|
-
}), C =
|
|
1036
|
+
}), C = u({
|
|
1037
1037
|
get() {
|
|
1038
1038
|
return P.value;
|
|
1039
1039
|
},
|
|
@@ -1041,44 +1041,44 @@ const Hl = ["for"], Ml = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
1041
1041
|
if (y.value)
|
|
1042
1042
|
d.value = B ? e.value : e.uncheckedValue;
|
|
1043
1043
|
else if (Array.isArray(d.value) || p.value) {
|
|
1044
|
-
const
|
|
1044
|
+
const U = new Set(
|
|
1045
1045
|
Array.isArray(d.value) ? d.value : d.value !== void 0 ? [d.value] : []
|
|
1046
1046
|
);
|
|
1047
|
-
B ?
|
|
1047
|
+
B ? U.add(e.value) : U.delete(e.value), d.value = [...U];
|
|
1048
1048
|
} else
|
|
1049
1049
|
d.value = B ? e.value : void 0;
|
|
1050
1050
|
t("change", B);
|
|
1051
1051
|
}
|
|
1052
|
-
}), { bemCssClasses:
|
|
1052
|
+
}), { bemCssClasses: H } = G("vv-checkbox", {
|
|
1053
1053
|
switch: c,
|
|
1054
1054
|
valid: s,
|
|
1055
1055
|
invalid: b,
|
|
1056
1056
|
disabled: o,
|
|
1057
1057
|
readonly: r,
|
|
1058
|
-
indeterminate:
|
|
1058
|
+
indeterminate: i
|
|
1059
1059
|
});
|
|
1060
|
-
|
|
1060
|
+
Xe(() => {
|
|
1061
1061
|
y.value && Array.isArray(d.value) && console.warn(
|
|
1062
1062
|
"[VvCheckbox] The model value is an array but the component is in binary mode."
|
|
1063
1063
|
);
|
|
1064
|
-
}),
|
|
1064
|
+
}), we(
|
|
1065
1065
|
() => $.value,
|
|
1066
1066
|
(B) => {
|
|
1067
1067
|
B ? g.value.indeterminate = !0 : g.value.indeterminate = !1;
|
|
1068
1068
|
}
|
|
1069
|
-
),
|
|
1069
|
+
), Nt(() => {
|
|
1070
1070
|
$.value && (g.value.indeterminate = !0);
|
|
1071
1071
|
});
|
|
1072
1072
|
const { HintSlot: J } = _e(e, n);
|
|
1073
|
-
return (B,
|
|
1074
|
-
class:
|
|
1073
|
+
return (B, U) => (m(), _("label", {
|
|
1074
|
+
class: F(a(H)),
|
|
1075
1075
|
for: a(v)
|
|
1076
1076
|
}, [
|
|
1077
1077
|
Se(E("input", {
|
|
1078
1078
|
id: a(v),
|
|
1079
1079
|
ref_key: "input",
|
|
1080
1080
|
ref: g,
|
|
1081
|
-
"onUpdate:modelValue":
|
|
1081
|
+
"onUpdate:modelValue": U[0] || (U[0] = (te) => $e(C) ? C.value = te : null),
|
|
1082
1082
|
type: "checkbox",
|
|
1083
1083
|
class: "vv-checkbox__input",
|
|
1084
1084
|
name: B.name,
|
|
@@ -1086,35 +1086,35 @@ const Hl = ["for"], Ml = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
1086
1086
|
value: a(x),
|
|
1087
1087
|
tabindex: a(h),
|
|
1088
1088
|
"aria-invalid": a(V)
|
|
1089
|
-
}, null, 8,
|
|
1090
|
-
[
|
|
1089
|
+
}, null, 8, xl), [
|
|
1090
|
+
[xt, a(C)]
|
|
1091
1091
|
]),
|
|
1092
1092
|
A(B.$slots, "default", { value: a(d) }, () => [
|
|
1093
1093
|
X(L(B.label), 1)
|
|
1094
1094
|
]),
|
|
1095
|
-
|
|
1095
|
+
ae(a(J), {
|
|
1096
1096
|
class: "vv-checkbox__hint",
|
|
1097
1097
|
params: { value: a(d) }
|
|
1098
1098
|
}, null, 8, ["params"])
|
|
1099
|
-
], 10,
|
|
1099
|
+
], 10, Nl));
|
|
1100
1100
|
}
|
|
1101
1101
|
});
|
|
1102
1102
|
function Le(l) {
|
|
1103
|
-
const { options: t, labelKey: e, valueKey: n } =
|
|
1103
|
+
const { options: t, labelKey: e, valueKey: n } = W(l);
|
|
1104
1104
|
return {
|
|
1105
1105
|
options: t,
|
|
1106
1106
|
getOptionLabel: (s) => typeof s != "object" && s !== null ? s : typeof e.value == "function" ? e.value(s) : s[e.value],
|
|
1107
1107
|
getOptionValue: (s) => typeof s != "object" && s !== null ? s : typeof n.value == "function" ? n.value(s) : s[n.value]
|
|
1108
1108
|
};
|
|
1109
1109
|
}
|
|
1110
|
-
const
|
|
1110
|
+
const Gl = Vt, Ul = ["update:modelValue", "change"], jl = ["textContent"], Fl = { class: "vv-checkbox-group__wrapper" }, Kl = {
|
|
1111
1111
|
name: "VvCheckboxGroup"
|
|
1112
1112
|
}, fo = /* @__PURE__ */ D({
|
|
1113
|
-
...
|
|
1114
|
-
props:
|
|
1115
|
-
emits:
|
|
1113
|
+
...Kl,
|
|
1114
|
+
props: Gl,
|
|
1115
|
+
emits: Ul,
|
|
1116
1116
|
setup(l, { emit: t }) {
|
|
1117
|
-
const e = l, n =
|
|
1117
|
+
const e = l, n = ge(), o = Ze(e, "modelValue", t), { disabled: r, readonly: s, vertical: b, valid: c, invalid: d } = W(e);
|
|
1118
1118
|
He({
|
|
1119
1119
|
key: bt,
|
|
1120
1120
|
modelValue: o,
|
|
@@ -1123,10 +1123,10 @@ const jl = Vt, Kl = ["update:modelValue", "change"], Fl = ["textContent"], Wl =
|
|
|
1123
1123
|
valid: c,
|
|
1124
1124
|
invalid: d
|
|
1125
1125
|
});
|
|
1126
|
-
const { getOptionLabel: p, getOptionValue: v } = Le(e), { bemCssClasses: h } =
|
|
1126
|
+
const { getOptionLabel: p, getOptionValue: v } = Le(e), { bemCssClasses: h } = G("vv-checkbox-group", {
|
|
1127
1127
|
disabled: r,
|
|
1128
1128
|
readonly: s,
|
|
1129
|
-
horizontal:
|
|
1129
|
+
horizontal: u(() => !b.value),
|
|
1130
1130
|
valid: c,
|
|
1131
1131
|
invalid: d
|
|
1132
1132
|
}), g = (f, V) => ({
|
|
@@ -1136,50 +1136,50 @@ const jl = Vt, Kl = ["update:modelValue", "change"], Fl = ["textContent"], Wl =
|
|
|
1136
1136
|
value: v(f)
|
|
1137
1137
|
}), { HintSlot: y } = _e(e, n);
|
|
1138
1138
|
return (f, V) => (m(), _("fieldset", {
|
|
1139
|
-
class:
|
|
1139
|
+
class: F(a(h))
|
|
1140
1140
|
}, [
|
|
1141
1141
|
f.label ? (m(), _("legend", {
|
|
1142
1142
|
key: 0,
|
|
1143
1143
|
textContent: L(f.label)
|
|
1144
|
-
}, null, 8,
|
|
1145
|
-
E("div",
|
|
1146
|
-
f.options.length > 0 ? (m(!0), _(
|
|
1144
|
+
}, null, 8, jl)) : I("", !0),
|
|
1145
|
+
E("div", Fl, [
|
|
1146
|
+
f.options.length > 0 ? (m(!0), _(he, { key: 0 }, Ce(f.options, (P, $) => (m(), T(Ml, R({ key: $ }, g(P, $)), null, 16))), 128)) : A(f.$slots, "default", { key: 1 })
|
|
1147
1147
|
]),
|
|
1148
|
-
|
|
1148
|
+
ae(a(y), { class: "vv-checkbox-group__hint" })
|
|
1149
1149
|
], 2));
|
|
1150
1150
|
}
|
|
1151
1151
|
});
|
|
1152
|
-
function
|
|
1153
|
-
const n =
|
|
1152
|
+
function et(l, t, e) {
|
|
1153
|
+
const n = u(
|
|
1154
1154
|
() => !!(l != null && l.value && t.value === "left" || e != null && e.iconLeft)
|
|
1155
|
-
), o =
|
|
1155
|
+
), o = u(
|
|
1156
1156
|
() => !!(l != null && l.value && t.value === "right" || e != null && e.iconRight)
|
|
1157
|
-
), r =
|
|
1157
|
+
), r = u(
|
|
1158
1158
|
() => !!(l != null && l.value && t.value === "top" || e != null && e.iconTop)
|
|
1159
|
-
), s =
|
|
1159
|
+
), s = u(
|
|
1160
1160
|
() => !!(l != null && l.value && t.value === "bottom" || e != null && e.iconBottom)
|
|
1161
1161
|
);
|
|
1162
1162
|
return {
|
|
1163
|
-
hasIcon:
|
|
1163
|
+
hasIcon: u(() => typeof (l == null ? void 0 : l.value) == "string" ? { name: l == null ? void 0 : l.value } : l == null ? void 0 : l.value),
|
|
1164
1164
|
hasIconLeft: n,
|
|
1165
1165
|
hasIconRight: o,
|
|
1166
1166
|
hasIconTop: r,
|
|
1167
1167
|
hasIconBottom: s
|
|
1168
1168
|
};
|
|
1169
1169
|
}
|
|
1170
|
-
function
|
|
1171
|
-
const { focused: e } =
|
|
1172
|
-
return
|
|
1170
|
+
function tt(l, t) {
|
|
1171
|
+
const { focused: e } = zt(l);
|
|
1172
|
+
return we(e, (n) => {
|
|
1173
1173
|
t(n ? "focus" : "blur", a(l));
|
|
1174
1174
|
}), {
|
|
1175
1175
|
focused: e
|
|
1176
1176
|
};
|
|
1177
1177
|
}
|
|
1178
|
-
const
|
|
1178
|
+
const Wl = {
|
|
1179
1179
|
...Re,
|
|
1180
1180
|
...Me,
|
|
1181
1181
|
...ye,
|
|
1182
|
-
...
|
|
1182
|
+
...ce,
|
|
1183
1183
|
modelValue: {
|
|
1184
1184
|
type: [String, Number, Boolean, Object, Array]
|
|
1185
1185
|
},
|
|
@@ -1187,24 +1187,24 @@ const ql = {
|
|
|
1187
1187
|
multiple: Boolean,
|
|
1188
1188
|
maxValues: [Number, String],
|
|
1189
1189
|
unselectable: { type: Boolean, default: !0 }
|
|
1190
|
-
},
|
|
1190
|
+
}, zl = ["id"], ql = {
|
|
1191
1191
|
key: 0,
|
|
1192
1192
|
role: "option"
|
|
1193
|
-
},
|
|
1193
|
+
}, Xl = ["aria-selected"], Zl = ["for", "onClick"], Yl = ["id", "type", "value", "checked", "disabled", "name"], Jl = {
|
|
1194
1194
|
name: "VvDropdown"
|
|
1195
|
-
},
|
|
1196
|
-
...
|
|
1197
|
-
props:
|
|
1195
|
+
}, Ql = /* @__PURE__ */ D({
|
|
1196
|
+
...Jl,
|
|
1197
|
+
props: Wl,
|
|
1198
1198
|
emits: ["update:modelValue"],
|
|
1199
1199
|
setup(l, { emit: t }) {
|
|
1200
|
-
const e = l, n =
|
|
1200
|
+
const e = l, n = u(() => String(e.id || de())), { modifiers: o, disabled: r } = W(e), { getOptionLabel: s, getOptionValue: b } = Le(e), { bemCssClasses: c } = G("vv-dropdown", {
|
|
1201
1201
|
modifiers: o,
|
|
1202
1202
|
disabled: r
|
|
1203
1203
|
});
|
|
1204
1204
|
function d(v) {
|
|
1205
|
-
return Array.isArray(e.modelValue) ?
|
|
1205
|
+
return Array.isArray(e.modelValue) ? pe(v, e.modelValue) || pe(b(v), e.modelValue) : be(v, e.modelValue) || be(b(v), e.modelValue);
|
|
1206
1206
|
}
|
|
1207
|
-
function
|
|
1207
|
+
function i(v) {
|
|
1208
1208
|
return typeof v == "string" || v.disabled === void 0 ? r.value : v.disabled;
|
|
1209
1209
|
}
|
|
1210
1210
|
function p(v) {
|
|
@@ -1214,9 +1214,9 @@ const ql = {
|
|
|
1214
1214
|
let h = v;
|
|
1215
1215
|
if (e.multiple)
|
|
1216
1216
|
if (Array.isArray(e.modelValue)) {
|
|
1217
|
-
if (e.maxValues !== void 0 && e.maxValues >= 0 && ((g = e.modelValue) == null ? void 0 : g.length) >= e.maxValues && !
|
|
1217
|
+
if (e.maxValues !== void 0 && e.maxValues >= 0 && ((g = e.modelValue) == null ? void 0 : g.length) >= e.maxValues && !pe(v, e.modelValue))
|
|
1218
1218
|
return;
|
|
1219
|
-
h =
|
|
1219
|
+
h = pe(v, e.modelValue) ? Yt(v, e.modelValue) : [...e.modelValue, v];
|
|
1220
1220
|
} else
|
|
1221
1221
|
h = [v];
|
|
1222
1222
|
else
|
|
@@ -1227,38 +1227,38 @@ const ql = {
|
|
|
1227
1227
|
var g;
|
|
1228
1228
|
return m(), _("ul", {
|
|
1229
1229
|
id: a(n),
|
|
1230
|
-
class:
|
|
1230
|
+
class: F(a(c)),
|
|
1231
1231
|
role: "listbox"
|
|
1232
1232
|
}, [
|
|
1233
|
-
(g = v.options) != null && g.length ? I("", !0) : (m(), _("li",
|
|
1233
|
+
(g = v.options) != null && g.length ? I("", !0) : (m(), _("li", ql, [
|
|
1234
1234
|
E("label", null, L(v.labelNoResults), 1)
|
|
1235
1235
|
])),
|
|
1236
|
-
(m(!0), _(
|
|
1236
|
+
(m(!0), _(he, null, Ce(v.options, (y, f) => (m(), _("li", {
|
|
1237
1237
|
key: f,
|
|
1238
1238
|
role: "option",
|
|
1239
1239
|
"aria-selected": d(y)
|
|
1240
1240
|
}, [
|
|
1241
1241
|
E("label", {
|
|
1242
1242
|
for: `dropdown-${f}-${a(n)}`,
|
|
1243
|
-
onClick:
|
|
1243
|
+
onClick: qe((V) => p(a(b)(y)), ["prevent"])
|
|
1244
1244
|
}, [
|
|
1245
1245
|
E("input", {
|
|
1246
1246
|
id: `dropdown-${f}-${a(n)}`,
|
|
1247
1247
|
type: v.multiple ? "checkbox" : "radio",
|
|
1248
1248
|
value: a(b)(y),
|
|
1249
1249
|
checked: d(y),
|
|
1250
|
-
disabled:
|
|
1250
|
+
disabled: i(y),
|
|
1251
1251
|
name: v.name,
|
|
1252
1252
|
tabindex: "-1",
|
|
1253
1253
|
"aria-hidden": "true"
|
|
1254
|
-
}, null, 8,
|
|
1254
|
+
}, null, 8, Yl),
|
|
1255
1255
|
X(" " + L(a(s)(y)), 1)
|
|
1256
|
-
], 8,
|
|
1257
|
-
], 8,
|
|
1258
|
-
], 10,
|
|
1256
|
+
], 8, Zl)
|
|
1257
|
+
], 8, Xl))), 128))
|
|
1258
|
+
], 10, zl);
|
|
1259
1259
|
};
|
|
1260
1260
|
}
|
|
1261
|
-
}),
|
|
1261
|
+
}), ea = {
|
|
1262
1262
|
...Re,
|
|
1263
1263
|
...gt,
|
|
1264
1264
|
...yt,
|
|
@@ -1266,13 +1266,13 @@ const ql = {
|
|
|
1266
1266
|
...Pe,
|
|
1267
1267
|
...Ie,
|
|
1268
1268
|
...Ee,
|
|
1269
|
-
...
|
|
1269
|
+
...Ye,
|
|
1270
1270
|
...ye,
|
|
1271
1271
|
...Oe,
|
|
1272
|
-
...
|
|
1272
|
+
...ce,
|
|
1273
1273
|
...Me,
|
|
1274
|
-
...
|
|
1275
|
-
...
|
|
1274
|
+
...Je,
|
|
1275
|
+
...Qe,
|
|
1276
1276
|
...Ue,
|
|
1277
1277
|
multiple: Boolean,
|
|
1278
1278
|
required: Boolean,
|
|
@@ -1283,17 +1283,17 @@ const ql = {
|
|
|
1283
1283
|
},
|
|
1284
1284
|
label: String,
|
|
1285
1285
|
placeholder: String
|
|
1286
|
-
},
|
|
1286
|
+
}, ta = ["update:modelValue", "focus", "blur"], la = ["for"], aa = { class: "vv-select__wrapper" }, oa = ["id"], na = ["disabled", "hidden"], sa = ["disabled", "value"], ra = {
|
|
1287
1287
|
name: "VvSelect"
|
|
1288
|
-
},
|
|
1289
|
-
...
|
|
1290
|
-
props:
|
|
1291
|
-
emits:
|
|
1288
|
+
}, ia = /* @__PURE__ */ D({
|
|
1289
|
+
...ra,
|
|
1290
|
+
props: ea,
|
|
1291
|
+
emits: ta,
|
|
1292
1292
|
setup(l, { emit: t }) {
|
|
1293
|
-
const e = l, n =
|
|
1293
|
+
const e = l, n = ge(), o = j(), { HintSlot: r, hasHint: s, hasInvalid: b } = _e(e, n), {
|
|
1294
1294
|
modifiers: c,
|
|
1295
1295
|
disabled: d,
|
|
1296
|
-
readonly:
|
|
1296
|
+
readonly: i,
|
|
1297
1297
|
loading: p,
|
|
1298
1298
|
icon: v,
|
|
1299
1299
|
iconPosition: h,
|
|
@@ -1301,111 +1301,111 @@ const ql = {
|
|
|
1301
1301
|
valid: y,
|
|
1302
1302
|
floating: f,
|
|
1303
1303
|
multiple: V
|
|
1304
|
-
} =
|
|
1305
|
-
|
|
1304
|
+
} = W(e), P = u(() => String(e.id || de())), $ = u(() => `${P.value}-hint`), { focused: x } = tt(o, t), C = vt(o);
|
|
1305
|
+
we(C, (w) => {
|
|
1306
1306
|
w && e.autofocus && (x.value = !0);
|
|
1307
1307
|
});
|
|
1308
|
-
const { hasIcon:
|
|
1308
|
+
const { hasIcon: H, hasIconLeft: J, hasIconRight: B } = et(
|
|
1309
1309
|
v,
|
|
1310
1310
|
h
|
|
1311
|
-
),
|
|
1311
|
+
), U = u(() => !fe(e.modelValue)), te = u(() => e.disabled || e.readonly), oe = u(() => te.value ? -1 : e.tabindex), ne = u(() => {
|
|
1312
1312
|
if (e.invalid === !0)
|
|
1313
1313
|
return !0;
|
|
1314
1314
|
if (e.valid === !0)
|
|
1315
1315
|
return !1;
|
|
1316
|
-
}), { bemCssClasses:
|
|
1316
|
+
}), { bemCssClasses: le } = G("vv-select", {
|
|
1317
1317
|
modifiers: c,
|
|
1318
1318
|
valid: y,
|
|
1319
1319
|
invalid: g,
|
|
1320
1320
|
loading: p,
|
|
1321
1321
|
disabled: d,
|
|
1322
|
-
readonly:
|
|
1322
|
+
readonly: i,
|
|
1323
1323
|
iconLeft: J,
|
|
1324
1324
|
iconRight: B,
|
|
1325
|
-
dirty:
|
|
1325
|
+
dirty: U,
|
|
1326
1326
|
focus: x,
|
|
1327
1327
|
floating: f,
|
|
1328
1328
|
multiple: V
|
|
1329
|
-
}),
|
|
1329
|
+
}), ve = u(() => ({
|
|
1330
1330
|
name: e.name,
|
|
1331
|
-
tabindex:
|
|
1332
|
-
disabled:
|
|
1331
|
+
tabindex: oe.value,
|
|
1332
|
+
disabled: te.value,
|
|
1333
1333
|
required: e.required,
|
|
1334
1334
|
size: e.size,
|
|
1335
1335
|
autocomplete: e.autocomplete,
|
|
1336
1336
|
multiple: e.multiple,
|
|
1337
|
-
"aria-invalid":
|
|
1337
|
+
"aria-invalid": ne.value,
|
|
1338
1338
|
"aria-describedby": !b.value && s.value ? $.value : void 0,
|
|
1339
1339
|
"aria-errormessage": b.value ? $.value : void 0
|
|
1340
|
-
})), { getOptionLabel:
|
|
1341
|
-
function
|
|
1340
|
+
})), { getOptionLabel: se, getOptionValue: re } = Le(e);
|
|
1341
|
+
function ie(w) {
|
|
1342
1342
|
return typeof w == "string" || w.disabled === void 0 ? d.value : w.disabled;
|
|
1343
1343
|
}
|
|
1344
|
-
const q =
|
|
1344
|
+
const q = u({
|
|
1345
1345
|
get: () => e.modelValue,
|
|
1346
1346
|
set: (w) => {
|
|
1347
1347
|
Array.isArray(w) && (w = w.filter((Z) => Z !== void 0)), t("update:modelValue", w);
|
|
1348
1348
|
}
|
|
1349
1349
|
});
|
|
1350
1350
|
return (w, Z) => (m(), _("div", {
|
|
1351
|
-
class:
|
|
1351
|
+
class: F(a(le))
|
|
1352
1352
|
}, [
|
|
1353
1353
|
w.label ? (m(), _("label", {
|
|
1354
1354
|
key: 0,
|
|
1355
1355
|
for: a(P)
|
|
1356
|
-
}, L(w.label), 9,
|
|
1357
|
-
E("div",
|
|
1356
|
+
}, L(w.label), 9, la)) : I("", !0),
|
|
1357
|
+
E("div", aa, [
|
|
1358
1358
|
A(w.$slots, "before", {}, () => [
|
|
1359
|
-
a(J) ? (m(), T(
|
|
1359
|
+
a(J) ? (m(), T(M, K(R({ key: 0 }, a(H))), null, 16)) : I("", !0)
|
|
1360
1360
|
]),
|
|
1361
1361
|
Se(E("select", R({
|
|
1362
1362
|
id: a(P),
|
|
1363
1363
|
ref_key: "select",
|
|
1364
1364
|
ref: o,
|
|
1365
1365
|
"onUpdate:modelValue": Z[0] || (Z[0] = (k) => $e(q) ? q.value = k : null)
|
|
1366
|
-
}, a(
|
|
1366
|
+
}, a(ve)), [
|
|
1367
1367
|
w.placeholder ? (m(), _("option", {
|
|
1368
1368
|
key: 0,
|
|
1369
1369
|
value: void 0,
|
|
1370
1370
|
disabled: !w.unselectable,
|
|
1371
1371
|
hidden: !w.unselectable
|
|
1372
|
-
}, L(w.placeholder), 9,
|
|
1373
|
-
(m(!0), _(
|
|
1372
|
+
}, L(w.placeholder), 9, na)) : I("", !0),
|
|
1373
|
+
(m(!0), _(he, null, Ce(w.options, (k, N) => (m(), _("option", {
|
|
1374
1374
|
key: N,
|
|
1375
|
-
disabled:
|
|
1376
|
-
value: a(
|
|
1377
|
-
}, L(a(
|
|
1378
|
-
], 16,
|
|
1379
|
-
[
|
|
1375
|
+
disabled: ie(k),
|
|
1376
|
+
value: a(re)(k)
|
|
1377
|
+
}, L(a(se)(k)), 9, sa))), 128))
|
|
1378
|
+
], 16, oa), [
|
|
1379
|
+
[Ht, a(q)]
|
|
1380
1380
|
]),
|
|
1381
1381
|
A(w.$slots, "after", {}, () => [
|
|
1382
|
-
a(B) ? (m(), T(
|
|
1382
|
+
a(B) ? (m(), T(M, K(R({ key: 0 }, a(H))), null, 16)) : I("", !0)
|
|
1383
1383
|
])
|
|
1384
1384
|
]),
|
|
1385
|
-
|
|
1385
|
+
ae(a(r), {
|
|
1386
1386
|
id: a($),
|
|
1387
1387
|
class: "vv-select__hint"
|
|
1388
1388
|
}, null, 8, ["id"])
|
|
1389
1389
|
], 2));
|
|
1390
1390
|
}
|
|
1391
|
-
}),
|
|
1391
|
+
}), ua = [
|
|
1392
1392
|
"update:modelValue",
|
|
1393
1393
|
"change:search",
|
|
1394
1394
|
"focus",
|
|
1395
1395
|
"blur"
|
|
1396
|
-
],
|
|
1396
|
+
], da = {
|
|
1397
1397
|
...Re,
|
|
1398
1398
|
...Ge,
|
|
1399
1399
|
...Pe,
|
|
1400
1400
|
...Ie,
|
|
1401
1401
|
...Ee,
|
|
1402
|
-
...
|
|
1402
|
+
...Ye,
|
|
1403
1403
|
...ye,
|
|
1404
1404
|
...Oe,
|
|
1405
|
-
...
|
|
1405
|
+
...ce,
|
|
1406
1406
|
...Me,
|
|
1407
|
-
...
|
|
1408
|
-
...
|
|
1407
|
+
...Je,
|
|
1408
|
+
...Qe,
|
|
1409
1409
|
...Ue,
|
|
1410
1410
|
modelValue: {
|
|
1411
1411
|
type: [String, Number, Boolean, Object, Array],
|
|
@@ -1424,17 +1424,17 @@ const ql = {
|
|
|
1424
1424
|
maxValues: [Number, String],
|
|
1425
1425
|
separator: { type: String, default: ", " },
|
|
1426
1426
|
native: Boolean
|
|
1427
|
-
},
|
|
1427
|
+
}, ca = ["id"], va = ["id", "for"], pa = ["tabindex"], fa = ["id", "placeholder"], ma = {
|
|
1428
1428
|
name: "VvCombobox"
|
|
1429
1429
|
}, mo = /* @__PURE__ */ D({
|
|
1430
|
-
...
|
|
1431
|
-
props:
|
|
1432
|
-
emits:
|
|
1430
|
+
...ma,
|
|
1431
|
+
props: da,
|
|
1432
|
+
emits: ua,
|
|
1433
1433
|
setup(l, { emit: t }) {
|
|
1434
|
-
const e = l, n =
|
|
1434
|
+
const e = l, n = ge(), { HintSlot: o } = _e(e, n), r = j(), s = j(), { focused: b } = tt(r, t), c = u(() => String(e.id || de())), d = j(""), i = qt(
|
|
1435
1435
|
d,
|
|
1436
1436
|
Number(e.debounceSearch)
|
|
1437
|
-
), p =
|
|
1437
|
+
), p = j(!1), {
|
|
1438
1438
|
icon: v,
|
|
1439
1439
|
iconPosition: h,
|
|
1440
1440
|
modifiers: g,
|
|
@@ -1444,50 +1444,50 @@ const ql = {
|
|
|
1444
1444
|
valid: P,
|
|
1445
1445
|
invalid: $,
|
|
1446
1446
|
floating: x
|
|
1447
|
-
} =
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
() => t("change:search",
|
|
1447
|
+
} = W(e);
|
|
1448
|
+
we(
|
|
1449
|
+
i,
|
|
1450
|
+
() => t("change:search", i.value)
|
|
1451
1451
|
);
|
|
1452
|
-
const { hasIcon: C, hasIconLeft:
|
|
1452
|
+
const { hasIcon: C, hasIconLeft: H, hasIconRight: J } = et(
|
|
1453
1453
|
v,
|
|
1454
1454
|
h
|
|
1455
|
-
), B =
|
|
1455
|
+
), B = u(() => !fe(e.modelValue)), U = u(() => y.value || f.value ? -1 : e.tabindex), { bemCssClasses: te } = G("vv-select", {
|
|
1456
1456
|
modifiers: g,
|
|
1457
1457
|
disabled: y,
|
|
1458
1458
|
loading: V,
|
|
1459
1459
|
readonly: f,
|
|
1460
|
-
iconLeft:
|
|
1460
|
+
iconLeft: H,
|
|
1461
1461
|
iconRight: J,
|
|
1462
1462
|
valid: P,
|
|
1463
1463
|
invalid: $,
|
|
1464
1464
|
dirty: B,
|
|
1465
1465
|
focus: b,
|
|
1466
1466
|
floating: x
|
|
1467
|
-
}),
|
|
1468
|
-
() => e.searchable ?
|
|
1469
|
-
), { getOptionLabel:
|
|
1467
|
+
}), oe = u(
|
|
1468
|
+
() => e.searchable ? ve.value : e.options
|
|
1469
|
+
), { getOptionLabel: ne, getOptionValue: le } = Le(e), ve = u(() => {
|
|
1470
1470
|
var k;
|
|
1471
|
-
return (k = e.options) == null ? void 0 : k.filter((N) =>
|
|
1472
|
-
}),
|
|
1471
|
+
return (k = e.options) == null ? void 0 : k.filter((N) => ne(N).toLowerCase().includes(i.value.toLowerCase().trim()));
|
|
1472
|
+
}), se = u(() => {
|
|
1473
1473
|
let k = [];
|
|
1474
1474
|
return Array.isArray(e.modelValue) ? k = e.modelValue : e.modelValue && (k = [e.modelValue]), e.options.filter(
|
|
1475
|
-
(N) => k.includes(
|
|
1475
|
+
(N) => k.includes(le(N))
|
|
1476
1476
|
);
|
|
1477
|
-
}),
|
|
1477
|
+
}), re = u(() => se.value.map((k) => ne(k)).join(e.separator));
|
|
1478
1478
|
pt(r, () => {
|
|
1479
1479
|
r.value.open = !1;
|
|
1480
1480
|
});
|
|
1481
|
-
function
|
|
1481
|
+
function ie(k) {
|
|
1482
1482
|
const N = k.target;
|
|
1483
1483
|
p.value = N.open;
|
|
1484
1484
|
}
|
|
1485
1485
|
function q(k) {
|
|
1486
1486
|
r.value && !e.multiple && (r.value.open = !1), t("update:modelValue", k);
|
|
1487
1487
|
}
|
|
1488
|
-
const w =
|
|
1488
|
+
const w = u(() => ({
|
|
1489
1489
|
name: e.name,
|
|
1490
|
-
options:
|
|
1490
|
+
options: oe.value,
|
|
1491
1491
|
labelKey: e.labelKey,
|
|
1492
1492
|
valueKey: e.valueKey,
|
|
1493
1493
|
disabled: e.disabled,
|
|
@@ -1496,10 +1496,10 @@ const ql = {
|
|
|
1496
1496
|
maxValues: e.maxValues,
|
|
1497
1497
|
modelValue: e.modelValue,
|
|
1498
1498
|
unselectable: e.unselectable
|
|
1499
|
-
})), Z =
|
|
1499
|
+
})), Z = u(() => ({
|
|
1500
1500
|
id: c.value,
|
|
1501
1501
|
name: e.name,
|
|
1502
|
-
tabindex:
|
|
1502
|
+
tabindex: U.value,
|
|
1503
1503
|
valid: P.value,
|
|
1504
1504
|
validLabel: e.validLabel,
|
|
1505
1505
|
invalid: $.value,
|
|
@@ -1510,7 +1510,7 @@ const ql = {
|
|
|
1510
1510
|
disabled: y.value,
|
|
1511
1511
|
readonly: f.value,
|
|
1512
1512
|
modifiers: e.modifiers,
|
|
1513
|
-
options:
|
|
1513
|
+
options: oe.value,
|
|
1514
1514
|
labelKey: e.labelKey,
|
|
1515
1515
|
valueKey: e.valueKey,
|
|
1516
1516
|
icon: e.icon,
|
|
@@ -1522,33 +1522,33 @@ const ql = {
|
|
|
1522
1522
|
placeholder: e.placeholder,
|
|
1523
1523
|
modelValue: e.modelValue
|
|
1524
1524
|
}));
|
|
1525
|
-
return (k, N) => k.native ? (m(), T(
|
|
1525
|
+
return (k, N) => k.native ? (m(), T(ia, R({ key: 1 }, a(Z), {
|
|
1526
1526
|
"onUpdate:modelValue": N[4] || (N[4] = (Y) => t("update:modelValue", Y))
|
|
1527
1527
|
}), null, 16)) : (m(), _("div", {
|
|
1528
1528
|
key: 0,
|
|
1529
1529
|
id: a(c),
|
|
1530
|
-
class:
|
|
1530
|
+
class: F(a(te))
|
|
1531
1531
|
}, [
|
|
1532
1532
|
k.label ? (m(), _("label", {
|
|
1533
1533
|
key: 0,
|
|
1534
1534
|
id: `${a(c)}-label`,
|
|
1535
1535
|
for: k.searchable && p.value ? `${a(c)}-input` : void 0
|
|
1536
|
-
}, L(k.label), 9,
|
|
1536
|
+
}, L(k.label), 9, va)) : I("", !0),
|
|
1537
1537
|
E("details", {
|
|
1538
1538
|
ref_key: "dropdown",
|
|
1539
1539
|
ref: r,
|
|
1540
1540
|
class: "vv-select__wrapper",
|
|
1541
1541
|
onClick: N[2] || (N[2] = (Y) => a(y) || a(f) ? Y.preventDefault() : null),
|
|
1542
|
-
onKeyup: N[3] || (N[3] =
|
|
1543
|
-
onToggle:
|
|
1542
|
+
onKeyup: N[3] || (N[3] = at((Y) => r.value.open = !1, ["esc"])),
|
|
1543
|
+
onToggle: ie
|
|
1544
1544
|
}, [
|
|
1545
1545
|
E("summary", {
|
|
1546
1546
|
class: "vv-select__input",
|
|
1547
|
-
tabindex: a(
|
|
1548
|
-
onKeyup: N[1] || (N[1] =
|
|
1547
|
+
tabindex: a(U),
|
|
1548
|
+
onKeyup: N[1] || (N[1] = at((Y) => k.searchable ? Y.preventDefault() : null, ["space"]))
|
|
1549
1549
|
}, [
|
|
1550
1550
|
A(k.$slots, "before", {}, () => [
|
|
1551
|
-
a(
|
|
1551
|
+
a(H) ? (m(), T(M, R({
|
|
1552
1552
|
key: 0,
|
|
1553
1553
|
class: "vv-select__icon-left"
|
|
1554
1554
|
}, a(C)), null, 16)) : I("", !0)
|
|
@@ -1562,52 +1562,52 @@ const ql = {
|
|
|
1562
1562
|
role: "combobox",
|
|
1563
1563
|
type: "search",
|
|
1564
1564
|
placeholder: k.searchPlaceholder
|
|
1565
|
-
}, null, 8,
|
|
1566
|
-
[
|
|
1567
|
-
]) : (m(), _(
|
|
1568
|
-
X(L(a(
|
|
1565
|
+
}, null, 8, fa)), [
|
|
1566
|
+
[ct, d.value]
|
|
1567
|
+
]) : (m(), _(he, { key: 1 }, [
|
|
1568
|
+
X(L(a(re) || k.placeholder), 1)
|
|
1569
1569
|
], 64)),
|
|
1570
1570
|
A(k.$slots, "after", {}, () => [
|
|
1571
|
-
a(J) ? (m(), T(
|
|
1571
|
+
a(J) ? (m(), T(M, R({
|
|
1572
1572
|
key: 0,
|
|
1573
1573
|
class: "vv-select__icon-right"
|
|
1574
1574
|
}, a(C)), null, 16)) : I("", !0)
|
|
1575
1575
|
])
|
|
1576
|
-
], 40,
|
|
1577
|
-
|
|
1576
|
+
], 40, pa),
|
|
1577
|
+
ae(Ql, R({
|
|
1578
1578
|
id: `${a(c)}-dropdown`
|
|
1579
1579
|
}, a(w), { "onUpdate:modelValue": q }), null, 16, ["id"])
|
|
1580
1580
|
], 544),
|
|
1581
|
-
|
|
1582
|
-
], 10,
|
|
1581
|
+
ae(a(o), { class: "vv-select__hint" })
|
|
1582
|
+
], 10, ca));
|
|
1583
1583
|
}
|
|
1584
|
-
}),
|
|
1584
|
+
}), ba = ["open", "close", "update:modelValue"], ha = {
|
|
1585
1585
|
id: { type: String, required: !0 },
|
|
1586
1586
|
title: String,
|
|
1587
1587
|
modelValue: Boolean,
|
|
1588
1588
|
transition: { type: String, default: "fade-block" },
|
|
1589
1589
|
size: String,
|
|
1590
1590
|
autoClose: { type: Boolean, default: !0 }
|
|
1591
|
-
},
|
|
1591
|
+
}, ga = {
|
|
1592
1592
|
key: 0,
|
|
1593
1593
|
class: "vv-dialog__header"
|
|
1594
|
-
},
|
|
1594
|
+
}, ya = ["onClick"], _a = { class: "vv-dialog__content" }, Sa = {
|
|
1595
1595
|
key: 1,
|
|
1596
1596
|
class: "vv-dialog__footer"
|
|
1597
|
-
},
|
|
1597
|
+
}, Va = {
|
|
1598
1598
|
name: "VvDialog"
|
|
1599
1599
|
}, bo = /* @__PURE__ */ D({
|
|
1600
|
-
...
|
|
1601
|
-
props:
|
|
1602
|
-
emits:
|
|
1600
|
+
...Va,
|
|
1601
|
+
props: ha,
|
|
1602
|
+
emits: ba,
|
|
1603
1603
|
setup(l, { emit: t }) {
|
|
1604
|
-
const e = l, n =
|
|
1604
|
+
const e = l, n = Ze(e, "modelValue", t), o = j(!0), r = j(null), s = u(() => {
|
|
1605
1605
|
const { id: p } = e;
|
|
1606
1606
|
return {
|
|
1607
1607
|
id: p,
|
|
1608
1608
|
open: o.value
|
|
1609
1609
|
};
|
|
1610
|
-
}), b =
|
|
1610
|
+
}), b = u(() => e.size ? ["vv-dialog", `vv-dialog--${e.size}`] : "vv-dialog"), c = u(() => `vv-dialog--${e.transition}`), d = {
|
|
1611
1611
|
"before-enter": () => {
|
|
1612
1612
|
o.value = !0, t("open");
|
|
1613
1613
|
},
|
|
@@ -1618,48 +1618,48 @@ const ql = {
|
|
|
1618
1618
|
pt(r, () => {
|
|
1619
1619
|
e.autoClose && (n.value = !1);
|
|
1620
1620
|
});
|
|
1621
|
-
function
|
|
1621
|
+
function i() {
|
|
1622
1622
|
n.value = !1;
|
|
1623
1623
|
}
|
|
1624
|
-
return (p, v) => (m(), T(
|
|
1625
|
-
default:
|
|
1624
|
+
return (p, v) => (m(), T(Mt, R({ name: a(c) }, Gt(d)), {
|
|
1625
|
+
default: ke(() => [
|
|
1626
1626
|
Se(E("dialog", R(a(s), { class: a(b) }), [
|
|
1627
1627
|
E("article", {
|
|
1628
1628
|
ref_key: "modalWrapper",
|
|
1629
1629
|
ref: r,
|
|
1630
1630
|
class: "vv-dialog__wrapper"
|
|
1631
1631
|
}, [
|
|
1632
|
-
p.$slots.header || p.title ? (m(), _("header",
|
|
1632
|
+
p.$slots.header || p.title ? (m(), _("header", ga, [
|
|
1633
1633
|
A(p.$slots, "header", {}, () => [
|
|
1634
1634
|
X(L(p.title) + " ", 1),
|
|
1635
1635
|
E("button", {
|
|
1636
1636
|
type: "button",
|
|
1637
1637
|
"aria-label": "Close",
|
|
1638
1638
|
class: "vv-dialog__close",
|
|
1639
|
-
onClick:
|
|
1639
|
+
onClick: qe(i, ["prevent"])
|
|
1640
1640
|
}, [
|
|
1641
|
-
|
|
1642
|
-
], 8,
|
|
1641
|
+
ae(M, { name: "close" })
|
|
1642
|
+
], 8, ya)
|
|
1643
1643
|
])
|
|
1644
1644
|
])) : I("", !0),
|
|
1645
|
-
E("div",
|
|
1645
|
+
E("div", _a, [
|
|
1646
1646
|
A(p.$slots, "default")
|
|
1647
1647
|
]),
|
|
1648
|
-
p.$slots.footer ? (m(), _("footer",
|
|
1648
|
+
p.$slots.footer ? (m(), _("footer", Sa, [
|
|
1649
1649
|
A(p.$slots, "footer")
|
|
1650
1650
|
])) : I("", !0)
|
|
1651
1651
|
], 512)
|
|
1652
1652
|
], 16), [
|
|
1653
|
-
[
|
|
1653
|
+
[Ut, a(n)]
|
|
1654
1654
|
])
|
|
1655
1655
|
]),
|
|
1656
1656
|
_: 3
|
|
1657
1657
|
}, 16, ["name"]));
|
|
1658
1658
|
}
|
|
1659
1659
|
});
|
|
1660
|
-
function
|
|
1660
|
+
function $a(l, t, e = 0) {
|
|
1661
1661
|
let n;
|
|
1662
|
-
return typeof e == "string" && (e = parseInt(e)),
|
|
1662
|
+
return typeof e == "string" && (e = parseInt(e)), u({
|
|
1663
1663
|
get: () => l == null ? void 0 : l.value,
|
|
1664
1664
|
set: (o) => {
|
|
1665
1665
|
n && clearTimeout(n), n = setTimeout(() => {
|
|
@@ -1668,8 +1668,8 @@ function At(l, t, e = 0) {
|
|
|
1668
1668
|
}
|
|
1669
1669
|
});
|
|
1670
1670
|
}
|
|
1671
|
-
function
|
|
1672
|
-
const e =
|
|
1671
|
+
function Ca(l, t) {
|
|
1672
|
+
const e = u(() => (a(l) ?? "").length), n = u(() => (t == null ? void 0 : t.lowerLimit) !== void 0 && e.value < (t == null ? void 0 : t.lowerLimit) ? e.value - t.lowerLimit : (t == null ? void 0 : t.upperLimit) !== void 0 && e.value < (t == null ? void 0 : t.upperLimit) ? t.upperLimit - e.value : 0), o = u(() => (t == null ? void 0 : t.mode) === !1 ? "" : (t == null ? void 0 : t.mode) === "limit" && (t != null && t.upperLimit) ? `${e.value} / ${t.lowerLimit ? `${t.lowerLimit}-` : ""}${t.upperLimit}` : (t == null ? void 0 : t.mode) === "countdown" ? n.value === 0 ? void 0 : n : e.value);
|
|
1673
1673
|
return {
|
|
1674
1674
|
length: e,
|
|
1675
1675
|
gap: n,
|
|
@@ -1690,7 +1690,7 @@ const S = {
|
|
|
1690
1690
|
DATETIME_LOCAL: "datetime-local",
|
|
1691
1691
|
MONTH: "month",
|
|
1692
1692
|
WEEK: "week"
|
|
1693
|
-
},
|
|
1693
|
+
}, me = {
|
|
1694
1694
|
PASSWORD_SHOW: "eye-on",
|
|
1695
1695
|
PASSWORD_HIDE: "eye-off",
|
|
1696
1696
|
DATE: "calendar",
|
|
@@ -1712,15 +1712,15 @@ const S = {
|
|
|
1712
1712
|
multiple: Boolean,
|
|
1713
1713
|
iconShowPassword: {
|
|
1714
1714
|
type: String,
|
|
1715
|
-
default:
|
|
1715
|
+
default: me.PASSWORD_SHOW
|
|
1716
1716
|
},
|
|
1717
1717
|
iconHidePassword: {
|
|
1718
1718
|
type: String,
|
|
1719
|
-
default:
|
|
1719
|
+
default: me.PASSWORD_HIDE
|
|
1720
1720
|
},
|
|
1721
1721
|
iconClear: {
|
|
1722
1722
|
type: String,
|
|
1723
|
-
default:
|
|
1723
|
+
default: me.SEARCH
|
|
1724
1724
|
},
|
|
1725
1725
|
labelStepUp: {
|
|
1726
1726
|
type: String,
|
|
@@ -1742,9 +1742,9 @@ const S = {
|
|
|
1742
1742
|
type: String,
|
|
1743
1743
|
default: "Clear"
|
|
1744
1744
|
}
|
|
1745
|
-
},
|
|
1745
|
+
}, st = D({
|
|
1746
1746
|
components: {
|
|
1747
|
-
VvIcon:
|
|
1747
|
+
VvIcon: M
|
|
1748
1748
|
},
|
|
1749
1749
|
props: {
|
|
1750
1750
|
disabled: {
|
|
@@ -1761,16 +1761,16 @@ const S = {
|
|
|
1761
1761
|
},
|
|
1762
1762
|
iconShow: {
|
|
1763
1763
|
type: String,
|
|
1764
|
-
default:
|
|
1764
|
+
default: me.PASSWORD_SHOW
|
|
1765
1765
|
},
|
|
1766
1766
|
iconHide: {
|
|
1767
1767
|
type: String,
|
|
1768
|
-
default:
|
|
1768
|
+
default: me.PASSWORD_HIDE
|
|
1769
1769
|
}
|
|
1770
1770
|
},
|
|
1771
1771
|
emits: ["toggle-password"],
|
|
1772
1772
|
setup(l, { emit: t }) {
|
|
1773
|
-
const e =
|
|
1773
|
+
const e = j(!1), n = u(
|
|
1774
1774
|
() => e.value ? l.iconHide : l.iconShow
|
|
1775
1775
|
);
|
|
1776
1776
|
function o(r) {
|
|
@@ -1783,7 +1783,7 @@ const S = {
|
|
|
1783
1783
|
};
|
|
1784
1784
|
},
|
|
1785
1785
|
render() {
|
|
1786
|
-
const l = Q(
|
|
1786
|
+
const l = Q(M, {
|
|
1787
1787
|
name: this.activeIcon,
|
|
1788
1788
|
class: "vv-input-text__action-icon"
|
|
1789
1789
|
});
|
|
@@ -1799,9 +1799,9 @@ const S = {
|
|
|
1799
1799
|
l
|
|
1800
1800
|
);
|
|
1801
1801
|
}
|
|
1802
|
-
}),
|
|
1802
|
+
}), Fe = D({
|
|
1803
1803
|
components: {
|
|
1804
|
-
VvIcon:
|
|
1804
|
+
VvIcon: M
|
|
1805
1805
|
},
|
|
1806
1806
|
props: {
|
|
1807
1807
|
disabled: {
|
|
@@ -1819,7 +1819,7 @@ const S = {
|
|
|
1819
1819
|
},
|
|
1820
1820
|
emits: ["step-up", "step-down"],
|
|
1821
1821
|
setup(l, { emit: t }) {
|
|
1822
|
-
const e =
|
|
1822
|
+
const e = u(() => l.mode === "up");
|
|
1823
1823
|
return {
|
|
1824
1824
|
isUp: e,
|
|
1825
1825
|
onClick: (o) => {
|
|
@@ -1838,9 +1838,9 @@ const S = {
|
|
|
1838
1838
|
onClick: this.onClick
|
|
1839
1839
|
});
|
|
1840
1840
|
}
|
|
1841
|
-
}),
|
|
1841
|
+
}), rt = D({
|
|
1842
1842
|
components: {
|
|
1843
|
-
VvIcon:
|
|
1843
|
+
VvIcon: M
|
|
1844
1844
|
},
|
|
1845
1845
|
props: {
|
|
1846
1846
|
disabled: {
|
|
@@ -1866,7 +1866,7 @@ const S = {
|
|
|
1866
1866
|
};
|
|
1867
1867
|
},
|
|
1868
1868
|
render() {
|
|
1869
|
-
const l = Q(
|
|
1869
|
+
const l = Q(M, {
|
|
1870
1870
|
name: this.icon,
|
|
1871
1871
|
class: "vv-input-text__action-icon"
|
|
1872
1872
|
});
|
|
@@ -1883,18 +1883,18 @@ const S = {
|
|
|
1883
1883
|
);
|
|
1884
1884
|
}
|
|
1885
1885
|
});
|
|
1886
|
-
function
|
|
1886
|
+
function Ke(l, t) {
|
|
1887
1887
|
return {
|
|
1888
1888
|
name: "VvInputTextActions",
|
|
1889
1889
|
components: {
|
|
1890
|
-
VvIcon:
|
|
1891
|
-
VvInputPasswordAction:
|
|
1892
|
-
VvInputStepAction:
|
|
1893
|
-
VvInputClearAction:
|
|
1890
|
+
VvIcon: M,
|
|
1891
|
+
VvInputPasswordAction: st,
|
|
1892
|
+
VvInputStepAction: Fe,
|
|
1893
|
+
VvInputClearAction: rt
|
|
1894
1894
|
},
|
|
1895
1895
|
setup() {
|
|
1896
1896
|
return {
|
|
1897
|
-
isDisabled:
|
|
1897
|
+
isDisabled: u(() => t.disabled || t.readonly),
|
|
1898
1898
|
labelStepUp: t.labelStepUp,
|
|
1899
1899
|
labelStepDown: t.labelStepDown,
|
|
1900
1900
|
labelShowPassword: t.labelShowPassword,
|
|
@@ -1910,7 +1910,7 @@ function ze(l, t) {
|
|
|
1910
1910
|
case S.SEARCH: {
|
|
1911
1911
|
const { onClear: n } = this.$attrs;
|
|
1912
1912
|
e = [
|
|
1913
|
-
Q(
|
|
1913
|
+
Q(rt, {
|
|
1914
1914
|
disabled: this.isDisabled,
|
|
1915
1915
|
label: this.labelShowPassword,
|
|
1916
1916
|
onClear: n
|
|
@@ -1921,7 +1921,7 @@ function ze(l, t) {
|
|
|
1921
1921
|
case S.PASSWORD: {
|
|
1922
1922
|
const { onTogglePassword: n } = this.$attrs;
|
|
1923
1923
|
e = [
|
|
1924
|
-
Q(
|
|
1924
|
+
Q(st, {
|
|
1925
1925
|
disabled: this.isDisabled,
|
|
1926
1926
|
onTogglePassword: n,
|
|
1927
1927
|
labelShow: this.labelShowPassword,
|
|
@@ -1935,14 +1935,14 @@ function ze(l, t) {
|
|
|
1935
1935
|
case S.NUMBER: {
|
|
1936
1936
|
const { onStepUp: n, onStepDown: o } = this.$attrs;
|
|
1937
1937
|
e = [
|
|
1938
|
-
Q(
|
|
1938
|
+
Q(Fe, {
|
|
1939
1939
|
mode: "up",
|
|
1940
1940
|
disabled: this.isDisabled || t.max !== void 0 && t.modelValue === t.max,
|
|
1941
1941
|
label: this.labelStepUp,
|
|
1942
1942
|
onStepUp: n,
|
|
1943
1943
|
onStepDown: o
|
|
1944
1944
|
}),
|
|
1945
|
-
Q(
|
|
1945
|
+
Q(Fe, {
|
|
1946
1946
|
mode: "down",
|
|
1947
1947
|
disabled: this.isDisabled || t.min !== void 0 && t.modelValue === t.min,
|
|
1948
1948
|
label: this.labelStepDown,
|
|
@@ -1967,73 +1967,73 @@ const wa = ["for"], Pa = { class: "vv-input-text__wrapper" }, Ia = ["id"], Oa =
|
|
|
1967
1967
|
props: ka,
|
|
1968
1968
|
emits: Aa,
|
|
1969
1969
|
setup(l, { emit: t }) {
|
|
1970
|
-
const e = l, n =
|
|
1970
|
+
const e = l, n = ge(), o = j(), {
|
|
1971
1971
|
icon: r,
|
|
1972
1972
|
iconPosition: s,
|
|
1973
1973
|
label: b,
|
|
1974
1974
|
modelValue: c,
|
|
1975
1975
|
count: d,
|
|
1976
|
-
valid:
|
|
1976
|
+
valid: i,
|
|
1977
1977
|
invalid: p,
|
|
1978
1978
|
loading: v
|
|
1979
|
-
} =
|
|
1980
|
-
() => e.floating &&
|
|
1981
|
-
), f =
|
|
1982
|
-
|
|
1979
|
+
} = W(e), h = u(() => String(e.id || de())), g = u(() => `${h.value}-hint`), y = u(
|
|
1980
|
+
() => e.floating && fe(e.placeholder) ? " " : e.placeholder
|
|
1981
|
+
), f = $a(c, t, e.debounce), { focused: V } = tt(o, t), P = vt(o);
|
|
1982
|
+
we(P, (O) => {
|
|
1983
1983
|
O && e.autofocus && (V.value = !0);
|
|
1984
1984
|
});
|
|
1985
|
-
const $ =
|
|
1985
|
+
const $ = j(!1), x = u(() => e.type === S.PASSWORD), C = () => {
|
|
1986
1986
|
$.value = !$.value;
|
|
1987
|
-
},
|
|
1987
|
+
}, H = u(
|
|
1988
1988
|
() => e.type === S.TIME || e.type === S.DATETIME_LOCAL || e.type === S.DATE || e.type === S.WEEK || e.type === S.MONTH
|
|
1989
|
-
), J =
|
|
1990
|
-
|
|
1991
|
-
},
|
|
1992
|
-
|
|
1993
|
-
},
|
|
1989
|
+
), J = u(() => e.type === S.NUMBER), B = () => {
|
|
1990
|
+
ie.value && (o.value.stepUp(), f.value = a(o).value);
|
|
1991
|
+
}, U = () => {
|
|
1992
|
+
ie.value && (o.value.stepDown(), f.value = a(o).value);
|
|
1993
|
+
}, te = u(() => e.type === S.SEARCH), oe = () => {
|
|
1994
1994
|
f.value = void 0;
|
|
1995
|
-
}, { hasIconLeft:
|
|
1995
|
+
}, { hasIconLeft: ne, hasIconRight: le, hasIcon: ve } = et(
|
|
1996
1996
|
r,
|
|
1997
1997
|
s
|
|
1998
|
-
),
|
|
1998
|
+
), se = u(() => {
|
|
1999
1999
|
switch (e.type) {
|
|
2000
2000
|
case S.COLOR:
|
|
2001
|
-
return { name:
|
|
2001
|
+
return { name: me.COLOR };
|
|
2002
2002
|
case S.DATE:
|
|
2003
2003
|
case S.DATETIME_LOCAL:
|
|
2004
2004
|
case S.WEEK:
|
|
2005
2005
|
case S.MONTH:
|
|
2006
|
-
return { name:
|
|
2006
|
+
return { name: me.DATE };
|
|
2007
2007
|
case S.TIME:
|
|
2008
|
-
return { name:
|
|
2008
|
+
return { name: me.TIME };
|
|
2009
2009
|
default:
|
|
2010
2010
|
return "";
|
|
2011
2011
|
}
|
|
2012
|
-
}), { formatted:
|
|
2012
|
+
}), { formatted: re } = Ca(f, {
|
|
2013
2013
|
mode: e.count,
|
|
2014
2014
|
upperLimit: e.maxlength,
|
|
2015
2015
|
lowerLimit: e.minlength
|
|
2016
|
-
}),
|
|
2017
|
-
() =>
|
|
2018
|
-
), w =
|
|
2016
|
+
}), ie = u(() => !e.disabled && !e.readonly), q = u(
|
|
2017
|
+
() => ie.value ? e.tabindex : -1
|
|
2018
|
+
), w = u(() => !fe(c)), Z = u(() => {
|
|
2019
2019
|
if (p.value === !0)
|
|
2020
2020
|
return !0;
|
|
2021
|
-
if (
|
|
2021
|
+
if (i.value === !0)
|
|
2022
2022
|
return !1;
|
|
2023
|
-
}), { bemCssClasses: k } =
|
|
2023
|
+
}), { bemCssClasses: k } = G("vv-input-text", {
|
|
2024
2024
|
modifiers: e.modifiers,
|
|
2025
|
-
valid:
|
|
2025
|
+
valid: i,
|
|
2026
2026
|
invalid: p,
|
|
2027
2027
|
loading: v,
|
|
2028
2028
|
disabled: e.disabled,
|
|
2029
2029
|
readonly: e.readonly,
|
|
2030
|
-
iconLeft:
|
|
2031
|
-
iconRight:
|
|
2032
|
-
floating: e.floating && !
|
|
2030
|
+
iconLeft: ne,
|
|
2031
|
+
iconRight: le.value || !fe(se),
|
|
2032
|
+
floating: e.floating && !fe(e.label),
|
|
2033
2033
|
dirty: w,
|
|
2034
2034
|
focus: V
|
|
2035
|
-
}), N =
|
|
2036
|
-
const O = (() => x.value && $.value ||
|
|
2035
|
+
}), N = u(() => {
|
|
2036
|
+
const O = (() => x.value && $.value || H.value && !w.value && !V.value ? S.TEXT : e.type)(), z = {
|
|
2037
2037
|
type: O,
|
|
2038
2038
|
name: e.name,
|
|
2039
2039
|
tabindex: q.value,
|
|
@@ -2042,30 +2042,30 @@ const wa = ["for"], Pa = { class: "vv-input-text__wrapper" }, Ia = ["id"], Oa =
|
|
|
2042
2042
|
required: e.required,
|
|
2043
2043
|
autocomplete: e.autocomplete,
|
|
2044
2044
|
"aria-invalid": Z.value,
|
|
2045
|
-
"aria-describedby": !
|
|
2046
|
-
"aria-errormessage":
|
|
2045
|
+
"aria-describedby": !lt.value && kt.value ? g.value : void 0,
|
|
2046
|
+
"aria-errormessage": lt.value ? g.value : void 0
|
|
2047
2047
|
};
|
|
2048
2048
|
return (O === S.DATE || O === S.MONTH || O === S.WEEK || O === S.TIME || O === S.DATETIME_LOCAL || O === S.NUMBER) && (z.step = e.step, z.max = String(e.max), z.min = String(e.min)), (O === S.TEXT || O === S.SEARCH || O === S.URL || O === S.TEL || O === S.EMAIL || O === S.PASSWORD || O === S.NUMBER) && (z.placeholder = y.value), (O === S.TEXT || O === S.SEARCH || O === S.URL || O === S.TEL || O === S.EMAIL || O === S.PASSWORD) && (z.minlength = e.minlength, z.maxlength = e.maxlength, z.pattern = e.pattern), O === S.EMAIL && (z.multiple = e.multiple), z;
|
|
2049
|
-
}), Y =
|
|
2049
|
+
}), Y = u(() => ({
|
|
2050
2050
|
valid: e.valid,
|
|
2051
2051
|
invalid: e.invalid,
|
|
2052
2052
|
modelValue: e.modelValue,
|
|
2053
2053
|
togglePassword: C,
|
|
2054
2054
|
stepUp: B,
|
|
2055
|
-
stepDown:
|
|
2056
|
-
clear:
|
|
2057
|
-
})), { HintSlot:
|
|
2055
|
+
stepDown: U,
|
|
2056
|
+
clear: oe
|
|
2057
|
+
})), { HintSlot: At, hasHint: kt, hasInvalid: lt } = _e(e, n), wt = Ke(
|
|
2058
2058
|
S.PASSWORD,
|
|
2059
2059
|
e
|
|
2060
|
-
),
|
|
2060
|
+
), Pt = Ke(
|
|
2061
2061
|
S.NUMBER,
|
|
2062
2062
|
e
|
|
2063
|
-
),
|
|
2063
|
+
), It = Ke(
|
|
2064
2064
|
S.SEARCH,
|
|
2065
2065
|
e
|
|
2066
2066
|
);
|
|
2067
2067
|
return (O, z) => (m(), _("div", {
|
|
2068
|
-
class:
|
|
2068
|
+
class: F(a(k))
|
|
2069
2069
|
}, [
|
|
2070
2070
|
a(b) ? (m(), _("label", {
|
|
2071
2071
|
key: 0,
|
|
@@ -2073,49 +2073,49 @@ const wa = ["for"], Pa = { class: "vv-input-text__wrapper" }, Ia = ["id"], Oa =
|
|
|
2073
2073
|
class: "vv-input-text__label"
|
|
2074
2074
|
}, L(a(b)), 9, wa)) : I("", !0),
|
|
2075
2075
|
E("div", Pa, [
|
|
2076
|
-
A(O.$slots, "before",
|
|
2077
|
-
a(
|
|
2076
|
+
A(O.$slots, "before", K(ee(a(Y))), () => [
|
|
2077
|
+
a(ne) ? (m(), T(M, R({
|
|
2078
2078
|
key: 0,
|
|
2079
2079
|
class: "vv-input-text__icon-left"
|
|
2080
|
-
}, a(
|
|
2080
|
+
}, a(ve)), null, 16)) : I("", !0)
|
|
2081
2081
|
]),
|
|
2082
2082
|
Se(E("input", R({
|
|
2083
2083
|
id: a(h),
|
|
2084
2084
|
ref_key: "input",
|
|
2085
2085
|
ref: o,
|
|
2086
|
-
"onUpdate:modelValue": z[0] || (z[0] = (
|
|
2086
|
+
"onUpdate:modelValue": z[0] || (z[0] = (je) => $e(f) ? f.value = je : null)
|
|
2087
2087
|
}, a(N), {
|
|
2088
|
-
onKeyup: z[1] || (z[1] = (
|
|
2088
|
+
onKeyup: z[1] || (z[1] = (je) => t("keyup", je))
|
|
2089
2089
|
}), null, 16, Ia), [
|
|
2090
|
-
[
|
|
2090
|
+
[jt, a(f)]
|
|
2091
2091
|
]),
|
|
2092
|
-
A(O.$slots, "after",
|
|
2093
|
-
a(
|
|
2092
|
+
A(O.$slots, "after", K(ee(a(Y))), () => [
|
|
2093
|
+
a(le) || a(se) ? (m(), T(M, K(R({ key: 0 }, a(le) ? a(ve) : a(se))), null, 16)) : a(x) ? (m(), T(a(wt), {
|
|
2094
2094
|
key: 1,
|
|
2095
2095
|
onTogglePassword: C
|
|
2096
|
-
})) : a(J) ? (m(), T(a(
|
|
2096
|
+
})) : a(J) ? (m(), T(a(Pt), {
|
|
2097
2097
|
key: 2,
|
|
2098
2098
|
onStepUp: B,
|
|
2099
|
-
onStepDown:
|
|
2100
|
-
})) : a(
|
|
2099
|
+
onStepDown: U
|
|
2100
|
+
})) : a(te) ? (m(), T(a(It), {
|
|
2101
2101
|
key: 3,
|
|
2102
|
-
onClear:
|
|
2102
|
+
onClear: oe
|
|
2103
2103
|
})) : I("", !0)
|
|
2104
2104
|
]),
|
|
2105
2105
|
a(d) ? (m(), _("span", Oa, [
|
|
2106
|
-
A(O.$slots, "count",
|
|
2107
|
-
X(L(a(
|
|
2106
|
+
A(O.$slots, "count", K(ee(a(Y))), () => [
|
|
2107
|
+
X(L(a(re)), 1)
|
|
2108
2108
|
])
|
|
2109
2109
|
])) : I("", !0)
|
|
2110
2110
|
]),
|
|
2111
|
-
|
|
2111
|
+
ae(a(At), {
|
|
2112
2112
|
id: a(g),
|
|
2113
2113
|
class: "vv-input-text__hint"
|
|
2114
2114
|
}, null, 8, ["id"])
|
|
2115
2115
|
], 2));
|
|
2116
2116
|
}
|
|
2117
2117
|
}), Ra = {
|
|
2118
|
-
...
|
|
2118
|
+
...ce,
|
|
2119
2119
|
value: {
|
|
2120
2120
|
type: [Number, String],
|
|
2121
2121
|
default: void 0
|
|
@@ -2133,7 +2133,7 @@ const wa = ["for"], Pa = { class: "vv-input-text__wrapper" }, Ia = ["id"], Oa =
|
|
|
2133
2133
|
...La,
|
|
2134
2134
|
props: Ra,
|
|
2135
2135
|
setup(l) {
|
|
2136
|
-
const t = l, { value: e, max: n, label: o } =
|
|
2136
|
+
const t = l, { value: e, max: n, label: o } = W(t), r = u(() => t.value === void 0), { bemCssClasses: s } = G("vv-progress", {
|
|
2137
2137
|
modifiers: t.modifiers,
|
|
2138
2138
|
indeterminate: r
|
|
2139
2139
|
});
|
|
@@ -2164,33 +2164,33 @@ const Na = ["for"], xa = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
2164
2164
|
props: Da,
|
|
2165
2165
|
emits: Ta,
|
|
2166
2166
|
setup(l, { emit: t }) {
|
|
2167
|
-
const e = l, n =
|
|
2167
|
+
const e = l, n = ge(), { disabled: o, readonly: r, modelValue: s, valid: b, invalid: c } = Ba(
|
|
2168
2168
|
e,
|
|
2169
2169
|
t
|
|
2170
|
-
), d =
|
|
2170
|
+
), d = u(() => String(e.id || de())), i = u(() => v.value ? -1 : e.tabindex), p = j(), v = u(() => o.value || r.value), h = u(() => {
|
|
2171
2171
|
if (c.value === !0)
|
|
2172
2172
|
return !0;
|
|
2173
2173
|
if (b.value === !0)
|
|
2174
2174
|
return !1;
|
|
2175
|
-
}), g =
|
|
2176
|
-
() => Array.isArray(s.value) ?
|
|
2177
|
-
), y =
|
|
2175
|
+
}), g = u(
|
|
2176
|
+
() => Array.isArray(s.value) ? pe(e.value, s.value) : be(e.value, s.value)
|
|
2177
|
+
), y = u(
|
|
2178
2178
|
() => ["string", "number", "boolean"].includes(typeof e.value) ? e.value : !0
|
|
2179
|
-
), f =
|
|
2179
|
+
), f = u({
|
|
2180
2180
|
get() {
|
|
2181
2181
|
return g.value ? y.value : null;
|
|
2182
2182
|
},
|
|
2183
2183
|
set($) {
|
|
2184
2184
|
Array.isArray(s.value) ? s.value = [e.value] : s.value = e.value, t("change", $);
|
|
2185
2185
|
}
|
|
2186
|
-
}), { bemCssClasses: V } =
|
|
2186
|
+
}), { bemCssClasses: V } = G("vv-radio", {
|
|
2187
2187
|
valid: b,
|
|
2188
2188
|
invalid: c,
|
|
2189
2189
|
disabled: o,
|
|
2190
2190
|
readonly: r
|
|
2191
2191
|
}), { HintSlot: P } = _e(e, n);
|
|
2192
2192
|
return ($, x) => (m(), _("label", {
|
|
2193
|
-
class:
|
|
2193
|
+
class: F(a(V)),
|
|
2194
2194
|
for: a(d)
|
|
2195
2195
|
}, [
|
|
2196
2196
|
Se(E("input", {
|
|
@@ -2203,28 +2203,28 @@ const Na = ["for"], xa = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
2203
2203
|
name: $.name,
|
|
2204
2204
|
disabled: a(v),
|
|
2205
2205
|
value: a(y),
|
|
2206
|
-
tabindex: a(
|
|
2206
|
+
tabindex: a(i),
|
|
2207
2207
|
"aria-invalid": a(h)
|
|
2208
2208
|
}, null, 8, xa), [
|
|
2209
|
-
[
|
|
2209
|
+
[Ft, a(f)]
|
|
2210
2210
|
]),
|
|
2211
2211
|
A($.$slots, "default", { value: a(s) }, () => [
|
|
2212
2212
|
X(L($.label), 1)
|
|
2213
2213
|
]),
|
|
2214
|
-
|
|
2214
|
+
ae(a(P), {
|
|
2215
2215
|
class: "vv-radio__hint",
|
|
2216
2216
|
params: { value: a(s) }
|
|
2217
2217
|
}, null, 8, ["params"])
|
|
2218
2218
|
], 10, Na));
|
|
2219
2219
|
}
|
|
2220
|
-
}), Ga = Vt, Ua = ["update:modelValue", "change"], ja = ["textContent"],
|
|
2220
|
+
}), Ga = Vt, Ua = ["update:modelValue", "change"], ja = ["textContent"], Fa = { class: "vv-radio-group__wrapper" }, Ka = {
|
|
2221
2221
|
name: "VvRadioGroup"
|
|
2222
2222
|
}, yo = /* @__PURE__ */ D({
|
|
2223
|
-
...
|
|
2223
|
+
...Ka,
|
|
2224
2224
|
props: Ga,
|
|
2225
2225
|
emits: Ua,
|
|
2226
2226
|
setup(l, { emit: t }) {
|
|
2227
|
-
const e = l, n =
|
|
2227
|
+
const e = l, n = ge(), o = Ze(e, "modelValue", t), { disabled: r, readonly: s, vertical: b, valid: c, invalid: d } = W(e);
|
|
2228
2228
|
He({
|
|
2229
2229
|
key: mt,
|
|
2230
2230
|
modelValue: o,
|
|
@@ -2233,10 +2233,10 @@ const Na = ["for"], xa = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
2233
2233
|
valid: c,
|
|
2234
2234
|
invalid: d
|
|
2235
2235
|
});
|
|
2236
|
-
const { getOptionLabel: p, getOptionValue: v } = Le(e), { bemCssClasses: h } =
|
|
2236
|
+
const { getOptionLabel: p, getOptionValue: v } = Le(e), { bemCssClasses: h } = G("vv-radio-group", {
|
|
2237
2237
|
disabled: r,
|
|
2238
2238
|
readonly: s,
|
|
2239
|
-
horizontal:
|
|
2239
|
+
horizontal: u(() => !b.value),
|
|
2240
2240
|
valid: c,
|
|
2241
2241
|
invalid: d
|
|
2242
2242
|
}), g = (f, V) => ({
|
|
@@ -2246,16 +2246,16 @@ const Na = ["for"], xa = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
2246
2246
|
value: v(f)
|
|
2247
2247
|
}), { HintSlot: y } = _e(e, n);
|
|
2248
2248
|
return (f, V) => (m(), _("fieldset", {
|
|
2249
|
-
class:
|
|
2249
|
+
class: F(a(h))
|
|
2250
2250
|
}, [
|
|
2251
2251
|
f.label ? (m(), _("legend", {
|
|
2252
2252
|
key: 0,
|
|
2253
2253
|
textContent: L(f.label)
|
|
2254
2254
|
}, null, 8, ja)) : I("", !0),
|
|
2255
|
-
E("div",
|
|
2256
|
-
f.options.length > 0 ? (m(!0), _(
|
|
2255
|
+
E("div", Fa, [
|
|
2256
|
+
f.options.length > 0 ? (m(!0), _(he, { key: 0 }, Ce(f.options, (P, $) => (m(), T(Ma, R({ key: $ }, g(P, $)), null, 16))), 128)) : A(f.$slots, "default", { key: 1 })
|
|
2257
2257
|
]),
|
|
2258
|
-
|
|
2258
|
+
ae(a(y), { class: "vv-radio-group__hint" })
|
|
2259
2259
|
], 2));
|
|
2260
2260
|
}
|
|
2261
2261
|
}), Wa = {
|
|
@@ -2283,49 +2283,49 @@ const Na = ["for"], xa = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
2283
2283
|
props: Xa,
|
|
2284
2284
|
emits: qa,
|
|
2285
2285
|
setup(l, { emit: t }) {
|
|
2286
|
-
const e = l, n =
|
|
2286
|
+
const e = l, n = useSlots(), o = ref(), {
|
|
2287
2287
|
icon: r,
|
|
2288
2288
|
iconPosition: s,
|
|
2289
2289
|
label: b,
|
|
2290
2290
|
modelValue: c,
|
|
2291
2291
|
count: d,
|
|
2292
|
-
valid:
|
|
2292
|
+
valid: i,
|
|
2293
2293
|
invalid: p,
|
|
2294
2294
|
loading: v
|
|
2295
|
-
} =
|
|
2296
|
-
() => e.floating &&
|
|
2297
|
-
), f =
|
|
2295
|
+
} = toRefs(e), h = computed(() => String(e.id || de())), g = computed(() => `${h.value}-hint`), y = computed(
|
|
2296
|
+
() => e.floating && isEmpty(e.placeholder) ? " " : e.placeholder
|
|
2297
|
+
), f = useDebouncedInput(c, t, e.debounce), { hasIcon: V, hasIconLeft: P, hasIconRight: $ } = useComponentIcon(
|
|
2298
2298
|
r,
|
|
2299
2299
|
s
|
|
2300
|
-
), { focused: x } =
|
|
2301
|
-
|
|
2300
|
+
), { focused: x } = useComponentFocus(o, t), C = useElementVisibility(o);
|
|
2301
|
+
watch(C, (q) => {
|
|
2302
2302
|
q && e.autofocus && (x.value = !0);
|
|
2303
2303
|
});
|
|
2304
|
-
const { formatted:
|
|
2304
|
+
const { formatted: H } = useTextCount(f, {
|
|
2305
2305
|
mode: e.count,
|
|
2306
2306
|
upperLimit: e.maxlength,
|
|
2307
2307
|
lowerLimit: e.minlength
|
|
2308
|
-
}), J =
|
|
2308
|
+
}), J = computed(() => !e.disabled && !e.readonly), B = computed(
|
|
2309
2309
|
() => J.value ? e.tabindex : -1
|
|
2310
|
-
),
|
|
2310
|
+
), U = computed(() => !isEmpty(c)), te = computed(() => {
|
|
2311
2311
|
if (e.invalid === !0)
|
|
2312
2312
|
return !0;
|
|
2313
2313
|
if (e.valid === !0)
|
|
2314
2314
|
return !1;
|
|
2315
|
-
}), { HintSlot:
|
|
2315
|
+
}), { HintSlot: oe, hasHint: ne, hasInvalid: le } = _e(e, n), { bemCssClasses: ve } = useBemModifiers("vv-textarea", {
|
|
2316
2316
|
modifiers: e.modifiers,
|
|
2317
|
-
valid:
|
|
2317
|
+
valid: i,
|
|
2318
2318
|
invalid: p,
|
|
2319
2319
|
loading: v,
|
|
2320
2320
|
disabled: e.disabled,
|
|
2321
2321
|
readonly: e.readonly,
|
|
2322
2322
|
iconLeft: P,
|
|
2323
2323
|
iconRight: $,
|
|
2324
|
-
floating: e.floating && !
|
|
2325
|
-
dirty:
|
|
2324
|
+
floating: e.floating && !isEmpty(e.label),
|
|
2325
|
+
dirty: U,
|
|
2326
2326
|
focused: x,
|
|
2327
2327
|
resizable: e.resizable
|
|
2328
|
-
}),
|
|
2328
|
+
}), se = computed(
|
|
2329
2329
|
() => ({
|
|
2330
2330
|
name: e.name,
|
|
2331
2331
|
placeholder: y.value,
|
|
@@ -2340,23 +2340,23 @@ const Na = ["for"], xa = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
2340
2340
|
rows: e.rows,
|
|
2341
2341
|
wrap: e.wrap,
|
|
2342
2342
|
spellcheck: e.spellcheck,
|
|
2343
|
-
"aria-invalid":
|
|
2344
|
-
"aria-describedby": !
|
|
2345
|
-
"aria-errormessage":
|
|
2343
|
+
"aria-invalid": te.value,
|
|
2344
|
+
"aria-describedby": !le.value && ne.value ? g.value : void 0,
|
|
2345
|
+
"aria-errormessage": le.value ? g.value : void 0
|
|
2346
2346
|
})
|
|
2347
|
-
),
|
|
2347
|
+
), re = computed(() => ({
|
|
2348
2348
|
valid: e.valid,
|
|
2349
2349
|
invalid: e.invalid,
|
|
2350
2350
|
modelValue: e.modelValue,
|
|
2351
2351
|
hintLabel: e.hintLabel,
|
|
2352
2352
|
maxlength: e.maxlength,
|
|
2353
2353
|
minlength: e.minlength,
|
|
2354
|
-
clear:
|
|
2355
|
-
})),
|
|
2354
|
+
clear: ie
|
|
2355
|
+
})), ie = () => {
|
|
2356
2356
|
f.value = void 0;
|
|
2357
2357
|
};
|
|
2358
2358
|
return (q, w) => (m(), _("div", {
|
|
2359
|
-
class:
|
|
2359
|
+
class: F(a(ve))
|
|
2360
2360
|
}, [
|
|
2361
2361
|
a(b) ? (m(), _("label", {
|
|
2362
2362
|
key: 0,
|
|
@@ -2364,8 +2364,8 @@ const Na = ["for"], xa = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
2364
2364
|
class: "vv-textarea__label"
|
|
2365
2365
|
}, L(a(b)), 9, Za)) : I("", !0),
|
|
2366
2366
|
E("div", Ya, [
|
|
2367
|
-
A(q.$slots, "before",
|
|
2368
|
-
a(P) ? (m(), T(
|
|
2367
|
+
A(q.$slots, "before", K(ee(a(re))), () => [
|
|
2368
|
+
a(P) ? (m(), T(M, R({
|
|
2369
2369
|
key: 0,
|
|
2370
2370
|
class: "vv-textarea__icon-left"
|
|
2371
2371
|
}, a(V)), null, 16)) : I("", !0)
|
|
@@ -2375,21 +2375,21 @@ const Na = ["for"], xa = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
2375
2375
|
ref_key: "textarea",
|
|
2376
2376
|
ref: o,
|
|
2377
2377
|
"onUpdate:modelValue": w[0] || (w[0] = (Z) => $e(f) ? f.value = Z : null)
|
|
2378
|
-
}, a(
|
|
2378
|
+
}, a(se), {
|
|
2379
2379
|
onKeyup: w[1] || (w[1] = (Z) => t("keyup", Z))
|
|
2380
2380
|
}), null, 16, Ja), [
|
|
2381
|
-
[
|
|
2381
|
+
[ct, a(f)]
|
|
2382
2382
|
]),
|
|
2383
|
-
A(q.$slots, "after",
|
|
2384
|
-
a($) ? (m(), T(
|
|
2383
|
+
A(q.$slots, "after", K(ee(a(re))), () => [
|
|
2384
|
+
a($) ? (m(), T(M, K(R({ key: 0 }, a(V))), null, 16)) : I("", !0)
|
|
2385
2385
|
]),
|
|
2386
2386
|
a(d) ? (m(), _("span", Qa, [
|
|
2387
|
-
A(q.$slots, "count",
|
|
2388
|
-
X(L(a(
|
|
2387
|
+
A(q.$slots, "count", K(ee(a(re))), () => [
|
|
2388
|
+
X(L(a(H)), 1)
|
|
2389
2389
|
])
|
|
2390
2390
|
])) : I("", !0)
|
|
2391
2391
|
]),
|
|
2392
|
-
|
|
2392
|
+
ae(a(oe), {
|
|
2393
2393
|
id: a(g),
|
|
2394
2394
|
class: "vv-textarea__hint"
|
|
2395
2395
|
}, null, 8, ["id"])
|
|
@@ -2398,23 +2398,23 @@ const Na = ["for"], xa = ["id", "name", "disabled", "value", "tabindex", "aria-i
|
|
|
2398
2398
|
});
|
|
2399
2399
|
export {
|
|
2400
2400
|
so as VolverPlugin,
|
|
2401
|
-
|
|
2401
|
+
sl as VvAccordion,
|
|
2402
2402
|
ro as VvAccordionGroup,
|
|
2403
2403
|
io as VvBadge,
|
|
2404
2404
|
uo as VvBreadcrumb,
|
|
2405
2405
|
co as VvButton,
|
|
2406
2406
|
vo as VvButtonGroup,
|
|
2407
2407
|
po as VvCard,
|
|
2408
|
-
|
|
2408
|
+
Ml as VvCheckbox,
|
|
2409
2409
|
fo as VvCheckboxGroup,
|
|
2410
2410
|
mo as VvCombobox,
|
|
2411
2411
|
bo as VvDialog,
|
|
2412
|
-
|
|
2413
|
-
|
|
2412
|
+
Ql as VvDropdown,
|
|
2413
|
+
M as VvIcon,
|
|
2414
2414
|
ho as VvInputText,
|
|
2415
2415
|
go as VvProgress,
|
|
2416
2416
|
Ma as VvRadio,
|
|
2417
2417
|
yo as VvRadioGroup,
|
|
2418
|
-
|
|
2418
|
+
ia as VvSelect,
|
|
2419
2419
|
_o as VvTextarea
|
|
2420
2420
|
};
|