@defaultusr/dai-ui 1.2.0 → 1.2.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/dist/assets/main.css +1 -1
- package/dist/main.js +256 -252
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { useFormControl as
|
|
2
|
-
import { Menu as
|
|
3
|
-
import { reactive as ce, watch as
|
|
1
|
+
import { useFormControl as A, Combobox as te, ComboboxInput as oe, injectCombobox as ae, ComboboxOptions as le, ComboboxOption as ie, PopoverDialog as ne, MenuItems as se, MenuItem as re, Tab as de, TabList as ue } from "vue-composable-ui";
|
|
2
|
+
import { Menu as Nt, Popover as Ut, TabContainer as Xt, TabPanel as Dt } from "vue-composable-ui";
|
|
3
|
+
import { reactive as ce, watch as T, onUnmounted as R, defineComponent as v, createElementBlock as u, openBlock as i, renderSlot as b, createTextVNode as z, toDisplayString as k, normalizeClass as w, createBlock as p, createCommentVNode as y, createElementVNode as d, computed as _, createVNode as V, normalizeProps as fe, guardReactiveProps as me, withCtx as f, Transition as P, mergeModels as C, useModel as B, useId as q, useTemplateRef as L, mergeProps as $, unref as n, inject as ve, Fragment as I, ref as U, onMounted as O, withDirectives as X, renderList as D, vModelSelect as he, vModelText as pe, vModelRadio as be, resolveDynamicComponent as ye, nextTick as ge, normalizeStyle as N, Teleport as Z, TransitionGroup as we, withModifiers as ke } from "vue";
|
|
4
4
|
import './assets/main.css';function $e(e, ...t) {
|
|
5
5
|
let o = [];
|
|
6
6
|
const l = ce(t);
|
|
@@ -10,7 +10,7 @@ import './assets/main.css';function $e(e, ...t) {
|
|
|
10
10
|
function s() {
|
|
11
11
|
e.classList.remove(...o);
|
|
12
12
|
}
|
|
13
|
-
return
|
|
13
|
+
return T(
|
|
14
14
|
l,
|
|
15
15
|
() => {
|
|
16
16
|
s(), a();
|
|
@@ -20,31 +20,31 @@ import './assets/main.css';function $e(e, ...t) {
|
|
|
20
20
|
classList: l
|
|
21
21
|
};
|
|
22
22
|
}
|
|
23
|
-
const xe = { class: "dai-label" }, F = /* @__PURE__ */
|
|
23
|
+
const xe = { class: "dai-label" }, F = /* @__PURE__ */ v({
|
|
24
24
|
__name: "label",
|
|
25
25
|
props: {
|
|
26
26
|
text: {}
|
|
27
27
|
},
|
|
28
28
|
setup(e) {
|
|
29
29
|
return (t, o) => (i(), u("label", xe, [
|
|
30
|
-
|
|
30
|
+
b(t.$slots, "default", {}, () => [
|
|
31
31
|
z(k(e.text), 1)
|
|
32
32
|
])
|
|
33
33
|
]));
|
|
34
34
|
}
|
|
35
|
-
}), _e = { class: "dai-hint" }, H = /* @__PURE__ */
|
|
35
|
+
}), _e = { class: "dai-hint" }, H = /* @__PURE__ */ v({
|
|
36
36
|
__name: "hint",
|
|
37
37
|
props: {
|
|
38
38
|
text: {}
|
|
39
39
|
},
|
|
40
40
|
setup(e) {
|
|
41
41
|
return (t, o) => (i(), u("div", _e, [
|
|
42
|
-
|
|
42
|
+
b(t.$slots, "default", {}, () => [
|
|
43
43
|
z(k(e.text), 1)
|
|
44
44
|
])
|
|
45
45
|
]));
|
|
46
46
|
}
|
|
47
|
-
}), Be = { class: "dai-form-control__input-group__box" }, Ve = /* @__PURE__ */
|
|
47
|
+
}), Be = { class: "dai-form-control__input-group__box" }, Ve = /* @__PURE__ */ v({
|
|
48
48
|
inheritAttrs: !1,
|
|
49
49
|
__name: "inputGroup",
|
|
50
50
|
props: {
|
|
@@ -69,14 +69,14 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
69
69
|
"dai-form-control__input-group--invalid": e.invalid
|
|
70
70
|
}])
|
|
71
71
|
}, [
|
|
72
|
-
e.label ? (i(),
|
|
72
|
+
e.label ? (i(), p(F, {
|
|
73
73
|
key: 0,
|
|
74
74
|
text: e.label,
|
|
75
75
|
for: e.labelFor,
|
|
76
76
|
class: "dai-form-control__input-group__label"
|
|
77
77
|
}, null, 8, ["text", "for"])) : y("", !0),
|
|
78
78
|
d("div", Be, [
|
|
79
|
-
|
|
79
|
+
b(t.$slots, "default")
|
|
80
80
|
])
|
|
81
81
|
], 2));
|
|
82
82
|
}
|
|
@@ -84,7 +84,7 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
84
84
|
key: 0,
|
|
85
85
|
class: "dai-form-control__validation-message",
|
|
86
86
|
role: "alert"
|
|
87
|
-
}, S = /* @__PURE__ */
|
|
87
|
+
}, S = /* @__PURE__ */ v({
|
|
88
88
|
inheritAttrs: !1,
|
|
89
89
|
__name: "formControl",
|
|
90
90
|
props: {
|
|
@@ -112,30 +112,30 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
112
112
|
"dai-form-control--lg": l.value === "large"
|
|
113
113
|
}])
|
|
114
114
|
}, [
|
|
115
|
-
e.label && e.labelPosition !== "inside" ? (i(),
|
|
115
|
+
e.label && e.labelPosition !== "inside" ? (i(), p(F, {
|
|
116
116
|
key: 0,
|
|
117
117
|
for: e.labelFor,
|
|
118
118
|
text: e.label
|
|
119
119
|
}, null, 8, ["for", "text"])) : y("", !0),
|
|
120
120
|
d("div", Me, [
|
|
121
|
-
|
|
121
|
+
V(Ve, fe(me({
|
|
122
122
|
...t,
|
|
123
123
|
label: e.labelPosition === "inside" ? e.label : void 0,
|
|
124
124
|
variant: o.value,
|
|
125
125
|
size: l.value
|
|
126
126
|
})), {
|
|
127
|
-
default:
|
|
128
|
-
|
|
127
|
+
default: f(() => [
|
|
128
|
+
b(a.$slots, "default")
|
|
129
129
|
]),
|
|
130
130
|
_: 3
|
|
131
131
|
}, 16),
|
|
132
|
-
e.hint ? (i(),
|
|
132
|
+
e.hint ? (i(), p(H, {
|
|
133
133
|
key: 0,
|
|
134
134
|
text: e.hint,
|
|
135
135
|
class: "dai-form-control__hint"
|
|
136
136
|
}, null, 8, ["text"])) : y("", !0),
|
|
137
|
-
|
|
138
|
-
default:
|
|
137
|
+
V(P, { name: "dai-form-control__validation-message-transition" }, {
|
|
138
|
+
default: f(() => [
|
|
139
139
|
e.validationMessage ? (i(), u("div", Ce, [
|
|
140
140
|
s[0] || (s[0] = d("svg", {
|
|
141
141
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -155,7 +155,7 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
155
155
|
])
|
|
156
156
|
], 2));
|
|
157
157
|
}
|
|
158
|
-
}), Ee = ["value"], ze = /* @__PURE__ */
|
|
158
|
+
}), Ee = ["value"], ze = /* @__PURE__ */ v({
|
|
159
159
|
inheritAttrs: !1,
|
|
160
160
|
__name: "combobox",
|
|
161
161
|
props: /* @__PURE__ */ C({
|
|
@@ -182,31 +182,31 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
182
182
|
}),
|
|
183
183
|
emits: ["update:modelValue"],
|
|
184
184
|
setup(e) {
|
|
185
|
-
const t = e, o = B(e, "modelValue"), l = t.id || q(), a = L("formElement"), { isValid: s, validationMessage: r } =
|
|
185
|
+
const t = e, o = B(e, "modelValue"), l = t.id || q(), a = L("formElement"), { isValid: s, validationMessage: r, validate: g } = A(
|
|
186
186
|
a,
|
|
187
187
|
t.validators,
|
|
188
188
|
t.showValidationError
|
|
189
189
|
);
|
|
190
|
-
return (g,
|
|
190
|
+
return T(o, () => g()), (h, m) => (i(), p(S, $(t, {
|
|
191
191
|
labelFor: n(l),
|
|
192
192
|
validationMessage: e.showValidationError ? "" : n(r),
|
|
193
193
|
invalid: !n(s),
|
|
194
|
-
class:
|
|
194
|
+
class: h.$attrs.class
|
|
195
195
|
}), {
|
|
196
|
-
default:
|
|
197
|
-
|
|
196
|
+
default: f(() => [
|
|
197
|
+
V(n(te), $({ ...h.$attrs, class: void 0, required: void 0 }, {
|
|
198
198
|
id: n(l),
|
|
199
199
|
modelValue: o.value,
|
|
200
|
-
"onUpdate:modelValue":
|
|
200
|
+
"onUpdate:modelValue": m[0] || (m[0] = (c) => o.value = c)
|
|
201
201
|
}), {
|
|
202
|
-
default:
|
|
202
|
+
default: f(() => [
|
|
203
203
|
d("input", $({
|
|
204
204
|
ref_key: "formElement",
|
|
205
205
|
ref: a,
|
|
206
206
|
type: "text",
|
|
207
207
|
value: o.value
|
|
208
|
-
}, { required:
|
|
209
|
-
|
|
208
|
+
}, { required: h.$attrs.required }, { class: "dai-combobox__stab-input" }), null, 16, Ee),
|
|
209
|
+
b(h.$slots, "default")
|
|
210
210
|
]),
|
|
211
211
|
_: 3
|
|
212
212
|
}, 16, ["id", "modelValue"])
|
|
@@ -214,12 +214,12 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
214
214
|
_: 3
|
|
215
215
|
}, 16, ["labelFor", "validationMessage", "invalid", "class"]));
|
|
216
216
|
}
|
|
217
|
-
}),
|
|
217
|
+
}), kt = /* @__PURE__ */ v({
|
|
218
218
|
__name: "comboboxInput",
|
|
219
219
|
setup(e) {
|
|
220
|
-
return (t, o) => (i(),
|
|
221
|
-
default:
|
|
222
|
-
|
|
220
|
+
return (t, o) => (i(), p(n(oe), { class: "dai-form-control__input-group__control" }, {
|
|
221
|
+
default: f(() => [
|
|
222
|
+
b(t.$slots, "default")
|
|
223
223
|
]),
|
|
224
224
|
_: 3
|
|
225
225
|
}));
|
|
@@ -227,7 +227,7 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
227
227
|
}), Le = {
|
|
228
228
|
key: 0,
|
|
229
229
|
class: "dai-form-control__input-group__control__placeholder"
|
|
230
|
-
}, qe = /* @__PURE__ */
|
|
230
|
+
}, qe = /* @__PURE__ */ v({
|
|
231
231
|
__name: "comboboxButton",
|
|
232
232
|
props: {
|
|
233
233
|
placeholder: {}
|
|
@@ -245,7 +245,7 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
245
245
|
type: "button",
|
|
246
246
|
class: "dai-form-control__input-group__control dai-combobox-btn"
|
|
247
247
|
}), [
|
|
248
|
-
|
|
248
|
+
b(l.$slots, "default", {}, () => [
|
|
249
249
|
n(t).displayValue.value ? (i(), u(I, { key: 1 }, [
|
|
250
250
|
z(k(n(t).displayValue), 1)
|
|
251
251
|
], 64)) : (i(), u("span", Le, k(e.placeholder || "Select..."), 1)),
|
|
@@ -265,17 +265,17 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
265
265
|
])
|
|
266
266
|
], 16));
|
|
267
267
|
}
|
|
268
|
-
}), Te = /* @__PURE__ */
|
|
268
|
+
}), Te = /* @__PURE__ */ v({
|
|
269
269
|
__name: "comboboxOptions",
|
|
270
270
|
setup(e) {
|
|
271
|
-
return (t, o) => (i(),
|
|
271
|
+
return (t, o) => (i(), p(P, {
|
|
272
272
|
"enter-from-class": "dai-combobox-options--anim",
|
|
273
273
|
"leave-to-class": "dai-combobox-options--anim"
|
|
274
274
|
}, {
|
|
275
|
-
default:
|
|
276
|
-
|
|
277
|
-
default:
|
|
278
|
-
|
|
275
|
+
default: f(() => [
|
|
276
|
+
V(n(le), { class: "dai-combobox-options" }, {
|
|
277
|
+
default: f(() => [
|
|
278
|
+
b(t.$slots, "default")
|
|
279
279
|
]),
|
|
280
280
|
_: 3
|
|
281
281
|
})
|
|
@@ -288,18 +288,18 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
288
288
|
class: "dai-combobox-option__check",
|
|
289
289
|
xmlns: "http://www.w3.org/2000/svg",
|
|
290
290
|
viewBox: "0 0 16 16"
|
|
291
|
-
}, Pe = /* @__PURE__ */
|
|
291
|
+
}, Pe = /* @__PURE__ */ v({
|
|
292
292
|
__name: "comboboxOption",
|
|
293
293
|
props: {
|
|
294
294
|
value: {}
|
|
295
295
|
},
|
|
296
296
|
setup(e) {
|
|
297
|
-
return (t, o) => (i(),
|
|
297
|
+
return (t, o) => (i(), p(n(ie), {
|
|
298
298
|
value: e.value,
|
|
299
299
|
class: "dai-combobox-option"
|
|
300
300
|
}, {
|
|
301
|
-
default:
|
|
302
|
-
|
|
301
|
+
default: f(({ isActive: l, isSelected: a }) => [
|
|
302
|
+
b(t.$slots, "default", {
|
|
303
303
|
isActive: l,
|
|
304
304
|
isSelected: a
|
|
305
305
|
}),
|
|
@@ -328,7 +328,7 @@ const xe = { class: "dai-label" }, F = /* @__PURE__ */ h({
|
|
|
328
328
|
};
|
|
329
329
|
function Fe(e, t) {
|
|
330
330
|
return i(), u("button", Oe, [
|
|
331
|
-
|
|
331
|
+
b(e.$slots, "default")
|
|
332
332
|
]);
|
|
333
333
|
}
|
|
334
334
|
const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern", "title", "autocomplete", "value"], Ne = {
|
|
@@ -343,7 +343,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
343
343
|
fill: "none",
|
|
344
344
|
viewBox: "0 0 24 24",
|
|
345
345
|
stroke: "currentColor"
|
|
346
|
-
},
|
|
346
|
+
}, $t = /* @__PURE__ */ v({
|
|
347
347
|
inheritAttrs: !1,
|
|
348
348
|
__name: "input",
|
|
349
349
|
props: /* @__PURE__ */ C({
|
|
@@ -379,54 +379,54 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
379
379
|
emits: ["update:modelValue", "update:files"],
|
|
380
380
|
setup(e) {
|
|
381
381
|
const t = e, o = t.id || q(), l = _(() => typeof t.autocomplete == "string" ? t.autocomplete : t.autocomplete ? "on" : "off"), a = B(e, "modelValue"), s = B(e, "files", {
|
|
382
|
-
set(
|
|
383
|
-
return r.value && (r.value.files =
|
|
382
|
+
set(M) {
|
|
383
|
+
return r.value && (r.value.files = M), M;
|
|
384
384
|
}
|
|
385
|
-
}), r = L("formElement"), { isValid: g, validationMessage:
|
|
385
|
+
}), r = L("formElement"), { isValid: g, validationMessage: h, validate: m } = A(
|
|
386
386
|
r,
|
|
387
387
|
t.validators,
|
|
388
388
|
t.showValidationError
|
|
389
|
-
),
|
|
390
|
-
|
|
389
|
+
), c = U(!1);
|
|
390
|
+
T(a, () => {
|
|
391
391
|
s.value = r.value?.files || null;
|
|
392
392
|
});
|
|
393
393
|
let x;
|
|
394
|
-
const j = _(() => t.type === "password" ?
|
|
394
|
+
const j = _(() => t.type === "password" ? c.value ? "text" : "password" : t.type), Y = _(() => t.mask ? t.mask : t.type === "tel" ? {
|
|
395
395
|
mask: "{+7} (000) 000-00-00"
|
|
396
396
|
} : t.mask), G = _(() => t.pattern ? t.pattern : t.type === "tel" ? "^\\+7 \\(9\\d{2}\\) \\d{3}-\\d{2}-\\d{2}" : t.pattern), Q = _(() => t.title ? t.title : t.type === "tel" ? "+7 (999) 888-77-66" : t.title);
|
|
397
397
|
function W() {
|
|
398
|
-
|
|
398
|
+
c.value = !c.value;
|
|
399
399
|
}
|
|
400
400
|
function J() {
|
|
401
401
|
a.value = "";
|
|
402
402
|
}
|
|
403
|
-
function ee(
|
|
403
|
+
function ee(M) {
|
|
404
404
|
if (x)
|
|
405
405
|
return;
|
|
406
|
-
const { value: E } =
|
|
406
|
+
const { value: E } = M.target;
|
|
407
407
|
a.value = E;
|
|
408
408
|
}
|
|
409
409
|
return O(() => {
|
|
410
|
-
Y.value && import("imask").then((
|
|
411
|
-
x =
|
|
410
|
+
Y.value && import("imask").then((M) => {
|
|
411
|
+
x = M.default(
|
|
412
412
|
r.value,
|
|
413
413
|
Y.value
|
|
414
414
|
), x.on("accept", () => {
|
|
415
415
|
a.value = x.value;
|
|
416
416
|
});
|
|
417
417
|
});
|
|
418
|
-
}), (
|
|
418
|
+
}), (M, E) => (i(), p(S, $(t, {
|
|
419
419
|
"label-for": n(o),
|
|
420
|
-
"validation-message": e.showValidationError ? "" : n(
|
|
420
|
+
"validation-message": e.showValidationError ? "" : n(h),
|
|
421
421
|
invalid: t.invalid || !n(g),
|
|
422
|
-
class:
|
|
422
|
+
class: M.$attrs.class
|
|
423
423
|
}), {
|
|
424
|
-
default:
|
|
425
|
-
|
|
424
|
+
default: f(() => [
|
|
425
|
+
b(M.$slots, "prepend"),
|
|
426
426
|
d("input", $({
|
|
427
427
|
ref_key: "formElement",
|
|
428
428
|
ref: r
|
|
429
|
-
}, { ...
|
|
429
|
+
}, { ...M.$attrs, class: void 0 }, {
|
|
430
430
|
id: n(o),
|
|
431
431
|
type: j.value,
|
|
432
432
|
pattern: G.value,
|
|
@@ -434,16 +434,16 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
434
434
|
autocomplete: l.value,
|
|
435
435
|
value: a.value,
|
|
436
436
|
onInputPassive: ee,
|
|
437
|
-
onKeyupPassive: E[0] || (E[0] = (
|
|
437
|
+
onKeyupPassive: E[0] || (E[0] = (yt) => !n(g) && n(m)()),
|
|
438
438
|
class: "dai-form-control__input-group__control dai-form-control__input"
|
|
439
439
|
}), null, 16, Se),
|
|
440
|
-
|
|
441
|
-
t.type === "password" && a.value ? (i(),
|
|
440
|
+
b(M.$slots, "append"),
|
|
441
|
+
t.type === "password" && a.value ? (i(), p(K, {
|
|
442
442
|
key: 0,
|
|
443
443
|
onClick: W
|
|
444
444
|
}, {
|
|
445
|
-
default:
|
|
446
|
-
|
|
445
|
+
default: f(() => [
|
|
446
|
+
c.value ? (i(), u("svg", Ue, [...E[2] || (E[2] = [
|
|
447
447
|
d("path", {
|
|
448
448
|
"stroke-linecap": "round",
|
|
449
449
|
"stroke-linejoin": "round",
|
|
@@ -467,11 +467,11 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
467
467
|
]),
|
|
468
468
|
_: 1
|
|
469
469
|
})) : y("", !0),
|
|
470
|
-
e.clearable && a.value && !t.disabled ? (i(),
|
|
470
|
+
e.clearable && a.value && !t.disabled ? (i(), p(K, {
|
|
471
471
|
key: 1,
|
|
472
472
|
onClick: J
|
|
473
473
|
}, {
|
|
474
|
-
default:
|
|
474
|
+
default: f(() => [...E[3] || (E[3] = [
|
|
475
475
|
d("svg", {
|
|
476
476
|
xmlns: "http://www.w3.org/2000/svg",
|
|
477
477
|
fill: "none",
|
|
@@ -492,7 +492,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
492
492
|
_: 3
|
|
493
493
|
}, 16, ["label-for", "validation-message", "invalid", "class"]));
|
|
494
494
|
}
|
|
495
|
-
}), Xe = ["id"], De = ["value"],
|
|
495
|
+
}), Xe = ["id"], De = ["value"], xt = /* @__PURE__ */ v({
|
|
496
496
|
inheritAttrs: !1,
|
|
497
497
|
__name: "select",
|
|
498
498
|
props: /* @__PURE__ */ C({
|
|
@@ -522,36 +522,36 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
522
522
|
}),
|
|
523
523
|
emits: ["update:modelValue"],
|
|
524
524
|
setup(e) {
|
|
525
|
-
const t = e, o = t.id || q(), l = B(e, "modelValue"), a = L("formElement"), { isValid: s, validationMessage: r, validate: g } =
|
|
525
|
+
const t = e, o = t.id || q(), l = B(e, "modelValue"), a = L("formElement"), { isValid: s, validationMessage: r, validate: g } = A(
|
|
526
526
|
a,
|
|
527
527
|
t.validators,
|
|
528
528
|
t.showValidationError
|
|
529
529
|
);
|
|
530
|
-
return (
|
|
530
|
+
return (h, m) => (i(), p(S, $(t, {
|
|
531
531
|
"label-for": n(o),
|
|
532
532
|
"validation-message": e.showValidationError ? "" : n(r),
|
|
533
533
|
invalid: t.invalid || !n(s),
|
|
534
|
-
class:
|
|
534
|
+
class: h.$attrs.class
|
|
535
535
|
}), {
|
|
536
|
-
default:
|
|
536
|
+
default: f(() => [
|
|
537
537
|
X(d("select", $({
|
|
538
538
|
ref_key: "formElement",
|
|
539
539
|
ref: a
|
|
540
|
-
}, { ...
|
|
540
|
+
}, { ...h.$attrs, class: void 0 }, {
|
|
541
541
|
id: n(o),
|
|
542
|
-
"onUpdate:modelValue":
|
|
542
|
+
"onUpdate:modelValue": m[0] || (m[0] = (c) => l.value = c),
|
|
543
543
|
class: "dai-form-control__input-group__control dai-select"
|
|
544
544
|
}), [
|
|
545
|
-
|
|
546
|
-
(i(!0), u(I, null, D(e.options, (
|
|
547
|
-
value:
|
|
548
|
-
key:
|
|
549
|
-
}, k(
|
|
545
|
+
b(h.$slots, "default", {}, () => [
|
|
546
|
+
(i(!0), u(I, null, D(e.options, (c) => (i(), u("option", {
|
|
547
|
+
value: c[e.optionValue],
|
|
548
|
+
key: c[e.optionValue]
|
|
549
|
+
}, k(c[e.optionText]), 9, De))), 128))
|
|
550
550
|
])
|
|
551
551
|
], 16, Xe), [
|
|
552
552
|
[he, l.value]
|
|
553
553
|
]),
|
|
554
|
-
|
|
554
|
+
m[1] || (m[1] = d("svg", {
|
|
555
555
|
class: "dai-select__chevron",
|
|
556
556
|
xmlns: "http://www.w3.org/2000/svg",
|
|
557
557
|
viewBox: "0 0 16 16"
|
|
@@ -567,7 +567,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
567
567
|
_: 3
|
|
568
568
|
}, 16, ["label-for", "validation-message", "invalid", "class"]));
|
|
569
569
|
}
|
|
570
|
-
}),
|
|
570
|
+
}), _t = /* @__PURE__ */ v({
|
|
571
571
|
__name: "selectbox",
|
|
572
572
|
props: /* @__PURE__ */ C({
|
|
573
573
|
options: {},
|
|
@@ -598,20 +598,20 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
598
598
|
emits: ["update:modelValue"],
|
|
599
599
|
setup(e) {
|
|
600
600
|
const t = e, o = B(e, "modelValue");
|
|
601
|
-
return (l, a) => (i(),
|
|
601
|
+
return (l, a) => (i(), p(n(ze), $(t, {
|
|
602
602
|
displayValue: (s) => e.options.find((r) => r[e.optionValue] === s)?.[e.optionText] || "",
|
|
603
603
|
modelValue: o.value,
|
|
604
604
|
"onUpdate:modelValue": a[0] || (a[0] = (s) => o.value = s)
|
|
605
605
|
}), {
|
|
606
|
-
default:
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
default:
|
|
610
|
-
(i(!0), u(I, null, D(e.options, (s) => (i(),
|
|
606
|
+
default: f(() => [
|
|
607
|
+
V(n(qe), { placeholder: e.placeholder }, null, 8, ["placeholder"]),
|
|
608
|
+
V(n(Te), null, {
|
|
609
|
+
default: f(() => [
|
|
610
|
+
(i(!0), u(I, null, D(e.options, (s) => (i(), p(n(Pe), {
|
|
611
611
|
key: s[e.optionValue],
|
|
612
612
|
value: s[e.optionValue]
|
|
613
613
|
}, {
|
|
614
|
-
default:
|
|
614
|
+
default: f(() => [
|
|
615
615
|
z(k(s[e.optionText]), 1)
|
|
616
616
|
]),
|
|
617
617
|
_: 2
|
|
@@ -623,7 +623,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
623
623
|
_: 1
|
|
624
624
|
}, 16, ["displayValue", "modelValue"]));
|
|
625
625
|
}
|
|
626
|
-
}), He = ["id"],
|
|
626
|
+
}), He = ["id"], Bt = /* @__PURE__ */ v({
|
|
627
627
|
inheritAttrs: !1,
|
|
628
628
|
__name: "textarea",
|
|
629
629
|
props: /* @__PURE__ */ C({
|
|
@@ -637,31 +637,31 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
637
637
|
}),
|
|
638
638
|
emits: ["update:modelValue"],
|
|
639
639
|
setup(e) {
|
|
640
|
-
const t = e, o = t.id || q(), l = B(e, "modelValue"), a = L("formElement"), { isValid: s, validationMessage: r, validate: g } =
|
|
640
|
+
const t = e, o = t.id || q(), l = B(e, "modelValue"), a = L("formElement"), { isValid: s, validationMessage: r, validate: g } = A(
|
|
641
641
|
a,
|
|
642
642
|
t.validators,
|
|
643
643
|
t.showValidationError
|
|
644
644
|
);
|
|
645
|
-
function
|
|
645
|
+
function h() {
|
|
646
646
|
if (!t.autosize) return;
|
|
647
|
-
const
|
|
648
|
-
|
|
647
|
+
const m = a.value, c = m.offsetHeight - m.clientHeight;
|
|
648
|
+
m.style.height = "auto", m.style.height = `${m.scrollHeight + c}px`;
|
|
649
649
|
}
|
|
650
|
-
return O(
|
|
650
|
+
return O(h), (m, c) => (i(), p(S, $(t, {
|
|
651
651
|
"label-for": n(o),
|
|
652
652
|
"validation-message": e.showValidationError ? "" : n(r),
|
|
653
653
|
invalid: !n(s),
|
|
654
|
-
class:
|
|
654
|
+
class: m.$attrs.class
|
|
655
655
|
}), {
|
|
656
|
-
default:
|
|
656
|
+
default: f(() => [
|
|
657
657
|
X(d("textarea", $({
|
|
658
658
|
ref_key: "formElement",
|
|
659
659
|
ref: a
|
|
660
|
-
}, { ...
|
|
660
|
+
}, { ...m.$attrs, class: void 0 }, {
|
|
661
661
|
id: n(o),
|
|
662
|
-
"onUpdate:modelValue":
|
|
663
|
-
onKeyupPassive:
|
|
664
|
-
onInputPassive:
|
|
662
|
+
"onUpdate:modelValue": c[0] || (c[0] = (x) => l.value = x),
|
|
663
|
+
onKeyupPassive: c[1] || (c[1] = (x) => !n(s) && n(g)()),
|
|
664
|
+
onInputPassive: h,
|
|
665
665
|
class: ["form-control__textarea", {
|
|
666
666
|
"form-control__textarea--autosize": e.autosize
|
|
667
667
|
}]
|
|
@@ -672,7 +672,10 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
672
672
|
_: 1
|
|
673
673
|
}, 16, ["label-for", "validation-message", "invalid", "class"]));
|
|
674
674
|
}
|
|
675
|
-
}), Ye = ["checked", "id"],
|
|
675
|
+
}), Ye = ["checked", "id"], Ke = {
|
|
676
|
+
key: 0,
|
|
677
|
+
class: "dai-checkbox-control__label-container"
|
|
678
|
+
}, Vt = /* @__PURE__ */ v({
|
|
676
679
|
inheritAttrs: !1,
|
|
677
680
|
__name: "checkbox",
|
|
678
681
|
props: /* @__PURE__ */ C({
|
|
@@ -690,13 +693,13 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
690
693
|
}),
|
|
691
694
|
emits: ["update:modelValue"],
|
|
692
695
|
setup(e) {
|
|
693
|
-
const t = e, o = t.id || q(), l = t.value || o, a = B(e, "modelValue"), s = L("formElement"), { isValid: r } =
|
|
696
|
+
const t = e, o = t.id || q(), l = t.value || o, a = B(e, "modelValue"), s = L("formElement"), { isValid: r } = A(
|
|
694
697
|
s,
|
|
695
698
|
t.validators,
|
|
696
699
|
t.showValidationError
|
|
697
700
|
), g = _(() => Array.isArray(a.value) ? a.value.includes(l) : a.value);
|
|
698
|
-
function
|
|
699
|
-
const x =
|
|
701
|
+
function h(m) {
|
|
702
|
+
const x = m.target.checked;
|
|
700
703
|
if (Array.isArray(a.value))
|
|
701
704
|
if (x)
|
|
702
705
|
a.value.push(l);
|
|
@@ -707,15 +710,15 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
707
710
|
else
|
|
708
711
|
a.value = x;
|
|
709
712
|
}
|
|
710
|
-
return (
|
|
711
|
-
class: w(["dai-checkbox-control",
|
|
713
|
+
return (m, c) => (i(), u("div", {
|
|
714
|
+
class: w(["dai-checkbox-control", m.$attrs.class])
|
|
712
715
|
}, [
|
|
713
716
|
d("input", $({
|
|
714
717
|
ref_key: "formElement",
|
|
715
718
|
ref: s
|
|
716
|
-
}, { ...
|
|
719
|
+
}, { ...m.$attrs, class: "" }, {
|
|
717
720
|
checked: g.value,
|
|
718
|
-
onChange:
|
|
721
|
+
onChange: h,
|
|
719
722
|
id: n(o),
|
|
720
723
|
type: "checkbox",
|
|
721
724
|
class: ["dai-checkbox", {
|
|
@@ -725,24 +728,25 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
725
728
|
"dai-checkbox--lg": e.size === "large"
|
|
726
729
|
}]
|
|
727
730
|
}), null, 16, Ye),
|
|
728
|
-
e.label ||
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
731
|
+
e.label || m.$slots.default ? (i(), u("div", Ke, [
|
|
732
|
+
V(F, {
|
|
733
|
+
for: n(o),
|
|
734
|
+
class: "dai-checkbox-control__label"
|
|
735
|
+
}, {
|
|
736
|
+
default: f(() => [
|
|
737
|
+
b(m.$slots, "default", {}, () => [
|
|
738
|
+
z(k(e.label), 1)
|
|
739
|
+
])
|
|
740
|
+
]),
|
|
741
|
+
_: 3
|
|
742
|
+
}, 8, ["for"])
|
|
743
|
+
])) : y("", !0),
|
|
744
|
+
e.hint || m.$slots.hint ? (i(), p(H, {
|
|
741
745
|
key: 1,
|
|
742
746
|
class: "dai-checkbox-control__hint"
|
|
743
747
|
}, {
|
|
744
|
-
default:
|
|
745
|
-
|
|
748
|
+
default: f(() => [
|
|
749
|
+
b(m.$slots, "hint", {}, () => [
|
|
746
750
|
z(k(e.hint), 1)
|
|
747
751
|
])
|
|
748
752
|
]),
|
|
@@ -750,13 +754,13 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
750
754
|
})) : y("", !0)
|
|
751
755
|
], 2));
|
|
752
756
|
}
|
|
753
|
-
}),
|
|
757
|
+
}), Re = { class: "flex items-center h-5" }, Ze = ["value", "id"], Ge = {
|
|
754
758
|
key: 0,
|
|
755
759
|
class: "text-sm"
|
|
756
|
-
},
|
|
760
|
+
}, Qe = ["for"], We = {
|
|
757
761
|
key: 0,
|
|
758
762
|
class: "text-secondary-500 dark:text-secondary-400"
|
|
759
|
-
},
|
|
763
|
+
}, Mt = /* @__PURE__ */ v({
|
|
760
764
|
inheritAttrs: !1,
|
|
761
765
|
__name: "radio",
|
|
762
766
|
props: /* @__PURE__ */ C({
|
|
@@ -772,7 +776,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
772
776
|
}),
|
|
773
777
|
emits: ["update:modelValue"],
|
|
774
778
|
setup(e) {
|
|
775
|
-
const t = e, o = B(e, "modelValue"), l = q(), a = L("formElement"), { isValid: s } =
|
|
779
|
+
const t = e, o = B(e, "modelValue"), l = q(), a = L("formElement"), { isValid: s } = A(
|
|
776
780
|
a,
|
|
777
781
|
t.validators,
|
|
778
782
|
t.showValidationError
|
|
@@ -780,12 +784,12 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
780
784
|
return (r, g) => (i(), u("div", {
|
|
781
785
|
class: w(["flex items-start gap-3", r.$attrs.class])
|
|
782
786
|
}, [
|
|
783
|
-
d("div",
|
|
787
|
+
d("div", Re, [
|
|
784
788
|
X(d("input", $({
|
|
785
789
|
type: "radio",
|
|
786
790
|
ref_key: "formElement",
|
|
787
791
|
ref: a,
|
|
788
|
-
"onUpdate:modelValue": g[0] || (g[0] = (
|
|
792
|
+
"onUpdate:modelValue": g[0] || (g[0] = (h) => o.value = h)
|
|
789
793
|
}, { ...r.$attrs, class: "" }, {
|
|
790
794
|
value: e.value,
|
|
791
795
|
id: n(l),
|
|
@@ -793,20 +797,20 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
793
797
|
[`radio--${e.color}`]: e.color,
|
|
794
798
|
"radio--invalid": !n(s)
|
|
795
799
|
}]
|
|
796
|
-
}), null, 16,
|
|
800
|
+
}), null, 16, Ze), [
|
|
797
801
|
[be, o.value]
|
|
798
802
|
])
|
|
799
803
|
]),
|
|
800
|
-
e.label ? (i(), u("div",
|
|
804
|
+
e.label ? (i(), u("div", Ge, [
|
|
801
805
|
d("label", {
|
|
802
806
|
for: n(l),
|
|
803
807
|
class: "font-medium select-none cursor-pointer"
|
|
804
|
-
}, k(e.label), 9,
|
|
805
|
-
e.hint ? (i(), u("p",
|
|
808
|
+
}, k(e.label), 9, Qe),
|
|
809
|
+
e.hint ? (i(), u("p", We, k(e.hint), 1)) : y("", !0)
|
|
806
810
|
])) : y("", !0)
|
|
807
811
|
], 2));
|
|
808
812
|
}
|
|
809
|
-
}),
|
|
813
|
+
}), Je = { class: "dai-switch-control" }, et = ["id", "aria-checked"], Ct = /* @__PURE__ */ v({
|
|
810
814
|
__name: "switch",
|
|
811
815
|
props: /* @__PURE__ */ C({
|
|
812
816
|
label: {},
|
|
@@ -818,7 +822,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
818
822
|
emits: ["update:modelValue"],
|
|
819
823
|
setup(e) {
|
|
820
824
|
const t = B(e, "modelValue"), o = q();
|
|
821
|
-
return (l, a) => (i(), u("div",
|
|
825
|
+
return (l, a) => (i(), u("div", Je, [
|
|
822
826
|
d("button", {
|
|
823
827
|
onClick: a[0] || (a[0] = (s) => t.value = !t.value),
|
|
824
828
|
id: n(o),
|
|
@@ -832,24 +836,24 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
832
836
|
"aria-hidden": "true",
|
|
833
837
|
class: "dai-switch__thumb"
|
|
834
838
|
}, null, -1)
|
|
835
|
-
])], 10,
|
|
836
|
-
e.label || l.$slots.default ? (i(),
|
|
839
|
+
])], 10, et),
|
|
840
|
+
e.label || l.$slots.default ? (i(), p(F, {
|
|
837
841
|
key: 0,
|
|
838
842
|
for: n(o)
|
|
839
843
|
}, {
|
|
840
|
-
default:
|
|
841
|
-
|
|
844
|
+
default: f(() => [
|
|
845
|
+
b(l.$slots, "default", {}, () => [
|
|
842
846
|
z(k(e.label), 1)
|
|
843
847
|
])
|
|
844
848
|
]),
|
|
845
849
|
_: 3
|
|
846
850
|
}, 8, ["for"])) : y("", !0),
|
|
847
|
-
e.hint || l.$slots.hint ? (i(),
|
|
851
|
+
e.hint || l.$slots.hint ? (i(), p(H, {
|
|
848
852
|
key: 1,
|
|
849
853
|
class: "dai-switch-control__hint"
|
|
850
854
|
}, {
|
|
851
|
-
default:
|
|
852
|
-
|
|
855
|
+
default: f(() => [
|
|
856
|
+
b(l.$slots, "hint", {}, () => [
|
|
853
857
|
z(k(e.hint), 1)
|
|
854
858
|
])
|
|
855
859
|
]),
|
|
@@ -857,10 +861,10 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
857
861
|
})) : y("", !0)
|
|
858
862
|
]));
|
|
859
863
|
}
|
|
860
|
-
}),
|
|
864
|
+
}), tt = {
|
|
861
865
|
key: 0,
|
|
862
866
|
class: "dai-btn__spinner"
|
|
863
|
-
},
|
|
867
|
+
}, ot = { class: "dai-btn__caption" }, Et = /* @__PURE__ */ v({
|
|
864
868
|
__name: "btn",
|
|
865
869
|
props: {
|
|
866
870
|
submit: { type: [Boolean, String] },
|
|
@@ -883,7 +887,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
883
887
|
},
|
|
884
888
|
setup(e) {
|
|
885
889
|
const t = e, o = _(() => t.submit ? "submit" : t.reset ? "reset" : "button"), l = _(() => t.variant ? t.variant : t.plain ? "plain" : t.muted ? "muted" : t.outlined ? "outlined" : "flat"), a = _(() => t.size ? t.size : t.sm ? "small" : t.lg ? "large" : "medium");
|
|
886
|
-
return (s, r) => (i(),
|
|
890
|
+
return (s, r) => (i(), p(ye(e.href ? "a" : "button"), {
|
|
887
891
|
type: e.href ? void 0 : o.value,
|
|
888
892
|
form: typeof e.submit == "string" ? e.submit : void 0,
|
|
889
893
|
href: e.href,
|
|
@@ -901,8 +905,8 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
901
905
|
"dai-btn--condensed": e.condensed
|
|
902
906
|
}])
|
|
903
907
|
}, {
|
|
904
|
-
default:
|
|
905
|
-
e.loading ? (i(), u("span",
|
|
908
|
+
default: f(() => [
|
|
909
|
+
e.loading ? (i(), u("span", tt, [...r[0] || (r[0] = [
|
|
906
910
|
d("svg", {
|
|
907
911
|
xmlns: "http://www.w3.org/2000/svg",
|
|
908
912
|
fill: "none",
|
|
@@ -923,12 +927,12 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
923
927
|
})
|
|
924
928
|
], -1)
|
|
925
929
|
])])) : y("", !0),
|
|
926
|
-
d("span",
|
|
930
|
+
d("span", ot, [
|
|
927
931
|
e.icon ? (i(), u("div", {
|
|
928
932
|
key: 0,
|
|
929
933
|
class: w([e.icon, "dai-btn__icon"])
|
|
930
934
|
}, null, 2)) : y("", !0),
|
|
931
|
-
|
|
935
|
+
b(s.$slots, "default"),
|
|
932
936
|
e.iconAfter ? (i(), u("div", {
|
|
933
937
|
key: 1,
|
|
934
938
|
class: w([e.iconAfter, "dai-btn__icon"])
|
|
@@ -938,17 +942,17 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
938
942
|
_: 3
|
|
939
943
|
}, 8, ["type", "form", "href", "class"]));
|
|
940
944
|
}
|
|
941
|
-
}),
|
|
945
|
+
}), zt = /* @__PURE__ */ v({
|
|
942
946
|
__name: "popoverDialog",
|
|
943
947
|
setup(e) {
|
|
944
|
-
return (t, o) => (i(),
|
|
948
|
+
return (t, o) => (i(), p(P, {
|
|
945
949
|
"enter-from-class": "dai-popover-dialog--anim",
|
|
946
950
|
"leave-to-class": "dai-popover-dialog--anim"
|
|
947
951
|
}, {
|
|
948
|
-
default:
|
|
949
|
-
|
|
950
|
-
default:
|
|
951
|
-
|
|
952
|
+
default: f(() => [
|
|
953
|
+
V(n(ne), { class: "dai-popover-dialog" }, {
|
|
954
|
+
default: f(() => [
|
|
955
|
+
b(t.$slots, "default")
|
|
952
956
|
]),
|
|
953
957
|
_: 3
|
|
954
958
|
})
|
|
@@ -956,17 +960,17 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
956
960
|
_: 3
|
|
957
961
|
}));
|
|
958
962
|
}
|
|
959
|
-
}),
|
|
963
|
+
}), Lt = /* @__PURE__ */ v({
|
|
960
964
|
__name: "menuItems",
|
|
961
965
|
setup(e) {
|
|
962
|
-
return (t, o) => (i(),
|
|
966
|
+
return (t, o) => (i(), p(P, {
|
|
963
967
|
"enter-from-class": "dai-menu-items--anim",
|
|
964
968
|
"leave-to-class": "dai-menu-items--anim"
|
|
965
969
|
}, {
|
|
966
|
-
default:
|
|
967
|
-
|
|
968
|
-
default:
|
|
969
|
-
|
|
970
|
+
default: f(() => [
|
|
971
|
+
V(n(se), { class: "dai-menu-items" }, {
|
|
972
|
+
default: f(() => [
|
|
973
|
+
b(t.$slots, "default")
|
|
970
974
|
]),
|
|
971
975
|
_: 3
|
|
972
976
|
})
|
|
@@ -974,23 +978,23 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
974
978
|
_: 3
|
|
975
979
|
}));
|
|
976
980
|
}
|
|
977
|
-
}),
|
|
981
|
+
}), at = {
|
|
978
982
|
key: 0,
|
|
979
983
|
class: "text-secondary-400 flex-shrink-0"
|
|
980
|
-
},
|
|
984
|
+
}, qt = /* @__PURE__ */ v({
|
|
981
985
|
__name: "menuItem",
|
|
982
986
|
props: {
|
|
983
987
|
icon: {}
|
|
984
988
|
},
|
|
985
989
|
setup(e) {
|
|
986
|
-
return (t, o) => (i(),
|
|
987
|
-
default:
|
|
988
|
-
e.icon ? (i(), u("div",
|
|
990
|
+
return (t, o) => (i(), p(n(re), { class: "dai-menu-item" }, {
|
|
991
|
+
default: f(({ isActive: l, isSelected: a }) => [
|
|
992
|
+
e.icon ? (i(), u("div", at, [
|
|
989
993
|
d("div", {
|
|
990
994
|
class: w(["h-5 w-5", e.icon])
|
|
991
995
|
}, null, 2)
|
|
992
996
|
])) : y("", !0),
|
|
993
|
-
|
|
997
|
+
b(t.$slots, "default", {
|
|
994
998
|
isActive: l,
|
|
995
999
|
isSelected: a
|
|
996
1000
|
})
|
|
@@ -998,7 +1002,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
998
1002
|
_: 3
|
|
999
1003
|
}));
|
|
1000
1004
|
}
|
|
1001
|
-
}),
|
|
1005
|
+
}), Tt = /* @__PURE__ */ v({
|
|
1002
1006
|
__name: "tab",
|
|
1003
1007
|
props: {
|
|
1004
1008
|
id: {},
|
|
@@ -1006,19 +1010,19 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1006
1010
|
value: {}
|
|
1007
1011
|
},
|
|
1008
1012
|
setup(e) {
|
|
1009
|
-
return (t, o) => (i(),
|
|
1013
|
+
return (t, o) => (i(), p(n(de), {
|
|
1010
1014
|
id: e.id,
|
|
1011
1015
|
"aria-controls": e.ariaControls,
|
|
1012
1016
|
value: e.value,
|
|
1013
1017
|
class: "dai-tab"
|
|
1014
1018
|
}, {
|
|
1015
|
-
default:
|
|
1016
|
-
|
|
1019
|
+
default: f(() => [
|
|
1020
|
+
b(t.$slots, "default")
|
|
1017
1021
|
]),
|
|
1018
1022
|
_: 3
|
|
1019
1023
|
}, 8, ["id", "aria-controls", "value"]));
|
|
1020
1024
|
}
|
|
1021
|
-
}),
|
|
1025
|
+
}), At = /* @__PURE__ */ v({
|
|
1022
1026
|
__name: "tabList",
|
|
1023
1027
|
setup(e) {
|
|
1024
1028
|
const t = L("tablist"), o = L("slider"), l = U({});
|
|
@@ -1033,25 +1037,25 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1033
1037
|
transition: o.value.offsetLeft > r.offsetLeft ? "left .2s, right .5s" : "left .5s, right .2s"
|
|
1034
1038
|
});
|
|
1035
1039
|
}
|
|
1036
|
-
return O(() => ge(a)), (s, r) => (i(),
|
|
1040
|
+
return O(() => ge(a)), (s, r) => (i(), p(n(ue), {
|
|
1037
1041
|
ref_key: "tablist",
|
|
1038
1042
|
ref: t,
|
|
1039
1043
|
onClickPassive: a,
|
|
1040
1044
|
class: "dai-tab-list"
|
|
1041
1045
|
}, {
|
|
1042
|
-
default:
|
|
1046
|
+
default: f(() => [
|
|
1043
1047
|
d("div", {
|
|
1044
1048
|
ref_key: "slider",
|
|
1045
1049
|
ref: o,
|
|
1046
1050
|
class: "dai-tab-list__slider",
|
|
1047
1051
|
style: N(l.value)
|
|
1048
1052
|
}, null, 4),
|
|
1049
|
-
|
|
1053
|
+
b(s.$slots, "default")
|
|
1050
1054
|
]),
|
|
1051
1055
|
_: 3
|
|
1052
1056
|
}, 512));
|
|
1053
1057
|
}
|
|
1054
|
-
}),
|
|
1058
|
+
}), lt = ["id"], Pt = /* @__PURE__ */ v({
|
|
1055
1059
|
inheritAttrs: !1,
|
|
1056
1060
|
__name: "offcanvas",
|
|
1057
1061
|
props: /* @__PURE__ */ C({
|
|
@@ -1068,7 +1072,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1068
1072
|
emits: ["update:modelValue"],
|
|
1069
1073
|
setup(e) {
|
|
1070
1074
|
const t = e, o = B(e, "modelValue"), l = t.id ?? q(), { classList: a } = $e(document.body, "nui-body-push");
|
|
1071
|
-
|
|
1075
|
+
T(o, () => {
|
|
1072
1076
|
if (!t.push || (a.splice(1), !o.value))
|
|
1073
1077
|
return;
|
|
1074
1078
|
let r = "nui-body-push--" + t.position;
|
|
@@ -1081,8 +1085,8 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1081
1085
|
window.addEventListener("click", s, { passive: !0 });
|
|
1082
1086
|
}), R(() => {
|
|
1083
1087
|
window.removeEventListener("click", s);
|
|
1084
|
-
}), (r, g) => (i(),
|
|
1085
|
-
|
|
1088
|
+
}), (r, g) => (i(), p(Z, { to: "body" }, [
|
|
1089
|
+
V(P, {
|
|
1086
1090
|
appear: "",
|
|
1087
1091
|
"enter-from-class": "nui-offcanvas--animate-hidden",
|
|
1088
1092
|
"enter-to-class": "nui-offcanvas--animate-shown",
|
|
@@ -1091,7 +1095,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1091
1095
|
"leave-to-class": "nui-offcanvas--animate-hidden",
|
|
1092
1096
|
"leave-active-class": "ease-in-out"
|
|
1093
1097
|
}, {
|
|
1094
|
-
default:
|
|
1098
|
+
default: f(() => [
|
|
1095
1099
|
o.value ? (i(), u("div", $({
|
|
1096
1100
|
key: 0,
|
|
1097
1101
|
id: n(l)
|
|
@@ -1103,49 +1107,49 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1103
1107
|
"nui-offcanvas--xl": e.xl
|
|
1104
1108
|
}]
|
|
1105
1109
|
}), [
|
|
1106
|
-
|
|
1107
|
-
], 16,
|
|
1110
|
+
b(r.$slots, "default")
|
|
1111
|
+
], 16, lt)) : y("", !0)
|
|
1108
1112
|
]),
|
|
1109
1113
|
_: 3
|
|
1110
1114
|
})
|
|
1111
1115
|
]));
|
|
1112
1116
|
}
|
|
1113
|
-
}),
|
|
1117
|
+
}), it = {
|
|
1114
1118
|
key: 0,
|
|
1115
1119
|
role: "alert"
|
|
1116
|
-
},
|
|
1120
|
+
}, nt = {
|
|
1117
1121
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1118
1122
|
fill: "none",
|
|
1119
1123
|
viewBox: "0 0 24 24",
|
|
1120
1124
|
stroke: "currentColor"
|
|
1121
|
-
},
|
|
1125
|
+
}, st = {
|
|
1122
1126
|
key: 0,
|
|
1123
1127
|
"stroke-linecap": "round",
|
|
1124
1128
|
"stroke-linejoin": "round",
|
|
1125
1129
|
"stroke-width": "2",
|
|
1126
1130
|
d: "M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z"
|
|
1127
|
-
},
|
|
1131
|
+
}, rt = {
|
|
1128
1132
|
key: 1,
|
|
1129
1133
|
"stroke-linecap": "round",
|
|
1130
1134
|
"stroke-linejoin": "round",
|
|
1131
1135
|
"stroke-width": "2",
|
|
1132
1136
|
d: "M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"
|
|
1133
|
-
},
|
|
1137
|
+
}, dt = {
|
|
1134
1138
|
key: 2,
|
|
1135
1139
|
"stroke-linecap": "round",
|
|
1136
1140
|
"stroke-linejoin": "round",
|
|
1137
1141
|
"stroke-width": "2",
|
|
1138
1142
|
d: "M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z"
|
|
1139
|
-
},
|
|
1143
|
+
}, ut = {
|
|
1140
1144
|
key: 3,
|
|
1141
1145
|
"stroke-linecap": "round",
|
|
1142
1146
|
"stroke-linejoin": "round",
|
|
1143
1147
|
"stroke-width": "2",
|
|
1144
1148
|
d: "M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"
|
|
1145
|
-
},
|
|
1149
|
+
}, ct = { class: "dai-notification__content" }, ft = {
|
|
1146
1150
|
key: 0,
|
|
1147
1151
|
class: "dai-notification__content__detail"
|
|
1148
|
-
},
|
|
1152
|
+
}, mt = /* @__PURE__ */ v({
|
|
1149
1153
|
__name: "notification",
|
|
1150
1154
|
props: /* @__PURE__ */ C({
|
|
1151
1155
|
color: {},
|
|
@@ -1165,7 +1169,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1165
1169
|
function a() {
|
|
1166
1170
|
clearTimeout(l), o.value && t.timeout && (l = setTimeout(() => o.value = !1, t.timeout));
|
|
1167
1171
|
}
|
|
1168
|
-
return
|
|
1172
|
+
return T(o, a, { immediate: !0 }), (s, r) => o.value ? (i(), u("div", it, [
|
|
1169
1173
|
d("div", {
|
|
1170
1174
|
class: w(["dai-notification", [`dai-notification--${e.color || "secondary"}`]])
|
|
1171
1175
|
}, [
|
|
@@ -1173,17 +1177,17 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1173
1177
|
key: 0,
|
|
1174
1178
|
class: w(["dai-notification__icon", [`dai-notification__icon--${e.icon}`]])
|
|
1175
1179
|
}, [
|
|
1176
|
-
(i(), u("svg",
|
|
1177
|
-
e.icon == "success" ? (i(), u("path",
|
|
1180
|
+
(i(), u("svg", nt, [
|
|
1181
|
+
e.icon == "success" ? (i(), u("path", st)) : e.icon == "info" ? (i(), u("path", rt)) : e.icon == "warning" ? (i(), u("path", dt)) : e.icon == "danger" ? (i(), u("path", ut)) : y("", !0)
|
|
1178
1182
|
]))
|
|
1179
1183
|
], 2)) : y("", !0),
|
|
1180
|
-
d("div",
|
|
1184
|
+
d("div", ct, [
|
|
1181
1185
|
d("div", {
|
|
1182
1186
|
class: w(["dai-notification__content__message", {
|
|
1183
1187
|
"dai-notification__content__message--bold": e.detail
|
|
1184
1188
|
}])
|
|
1185
1189
|
}, k(e.message), 3),
|
|
1186
|
-
e.detail ? (i(), u("div",
|
|
1190
|
+
e.detail ? (i(), u("div", ft, k(e.detail), 1)) : y("", !0)
|
|
1187
1191
|
]),
|
|
1188
1192
|
e.dismissible ? (i(), u("div", {
|
|
1189
1193
|
key: 1,
|
|
@@ -1207,7 +1211,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1207
1211
|
], 2)
|
|
1208
1212
|
])) : y("", !0);
|
|
1209
1213
|
}
|
|
1210
|
-
}),
|
|
1214
|
+
}), jt = /* @__PURE__ */ v({
|
|
1211
1215
|
__name: "notificationQueue",
|
|
1212
1216
|
props: /* @__PURE__ */ C({
|
|
1213
1217
|
length: { default: 3 },
|
|
@@ -1226,19 +1230,19 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1226
1230
|
function s() {
|
|
1227
1231
|
o.value.length === 0 || l.value.length >= t.length || (l.value.push({ ...o.value[0], id: a++, show: !0 }), o.value.shift());
|
|
1228
1232
|
}
|
|
1229
|
-
function r(
|
|
1233
|
+
function r(h) {
|
|
1230
1234
|
setTimeout(() => {
|
|
1231
1235
|
l.value = l.value.filter(
|
|
1232
|
-
(
|
|
1236
|
+
(m) => m.id !== h
|
|
1233
1237
|
), s();
|
|
1234
1238
|
}, 200);
|
|
1235
1239
|
}
|
|
1236
|
-
|
|
1240
|
+
T(o, s, { immediate: !0, deep: !0 });
|
|
1237
1241
|
const g = _(() => {
|
|
1238
|
-
const
|
|
1239
|
-
return t.positionX === "right" ?
|
|
1242
|
+
const h = ["dai-notification-queue__item--anim"];
|
|
1243
|
+
return t.positionX === "right" ? h.push("dai-notification-queue__item--anim-x-right") : t.positionX === "left" ? h.push("dai-notification-queue__item--anim-x-left") : t.positionX === "center" && t.positionY === "top" ? h.push("dai-notification-queue__item--anim-y-top") : t.positionX === "center" && t.positionY === "bottom" && h.push("dai-notification-queue__item--anim-y-bottom"), h.join(" ");
|
|
1240
1244
|
});
|
|
1241
|
-
return (
|
|
1245
|
+
return (h, m) => (i(), u("div", {
|
|
1242
1246
|
class: w(["dai-notification-queue", {
|
|
1243
1247
|
"dai-notification-queue--fixed": e.position == "fixed",
|
|
1244
1248
|
"dai-notification-queue--absolute": e.position == "absolute",
|
|
@@ -1249,23 +1253,23 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1249
1253
|
"dai-notification-queue--x-right": e.positionX == "right"
|
|
1250
1254
|
}])
|
|
1251
1255
|
}, [
|
|
1252
|
-
|
|
1256
|
+
V(we, {
|
|
1253
1257
|
appear: "",
|
|
1254
1258
|
"enter-from-class": g.value,
|
|
1255
1259
|
"enter-active-class": "dai-notification-queue__item--anim-in",
|
|
1256
1260
|
"leave-to-class": g.value,
|
|
1257
1261
|
"leave-active-class": "dai-notification-queue__item--anim-out"
|
|
1258
1262
|
}, {
|
|
1259
|
-
default:
|
|
1260
|
-
(i(!0), u(I, null, D(l.value, (
|
|
1261
|
-
key:
|
|
1262
|
-
color:
|
|
1263
|
-
icon:
|
|
1264
|
-
message:
|
|
1265
|
-
detail:
|
|
1266
|
-
timeout:
|
|
1267
|
-
modelValue:
|
|
1268
|
-
"onUpdate:modelValue": [(x) =>
|
|
1263
|
+
default: f(() => [
|
|
1264
|
+
(i(!0), u(I, null, D(l.value, (c) => (i(), p(mt, {
|
|
1265
|
+
key: c.id,
|
|
1266
|
+
color: c.color,
|
|
1267
|
+
icon: c.type,
|
|
1268
|
+
message: c.message,
|
|
1269
|
+
detail: c.detail,
|
|
1270
|
+
timeout: c.timeout ?? e.timeout,
|
|
1271
|
+
modelValue: c.show,
|
|
1272
|
+
"onUpdate:modelValue": [(x) => c.show = x, (x) => r(c.id)],
|
|
1269
1273
|
class: "dai-notification-queue__item"
|
|
1270
1274
|
}, null, 8, ["color", "icon", "message", "detail", "timeout", "modelValue", "onUpdate:modelValue"]))), 128))
|
|
1271
1275
|
]),
|
|
@@ -1273,7 +1277,7 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1273
1277
|
}, 8, ["enter-from-class", "leave-to-class"])
|
|
1274
1278
|
], 2));
|
|
1275
1279
|
}
|
|
1276
|
-
}),
|
|
1280
|
+
}), vt = ["aria-valuenow"], It = /* @__PURE__ */ v({
|
|
1277
1281
|
__name: "progressbar",
|
|
1278
1282
|
props: {
|
|
1279
1283
|
value: {},
|
|
@@ -1309,12 +1313,12 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1309
1313
|
"progress-infinite": o.value
|
|
1310
1314
|
}, "h-full shadow-none relative text-center whitespace-nowrap text-white justify-center"])
|
|
1311
1315
|
}, null, 6)
|
|
1312
|
-
], 14,
|
|
1316
|
+
], 14, vt));
|
|
1313
1317
|
}
|
|
1314
|
-
}),
|
|
1318
|
+
}), ht = {
|
|
1315
1319
|
key: 0,
|
|
1316
1320
|
class: "z-50"
|
|
1317
|
-
},
|
|
1321
|
+
}, pt = { class: "fixed inset-0 overflow-y-auto" }, bt = { class: "modal__dialog" }, Ot = /* @__PURE__ */ v({
|
|
1318
1322
|
inheritAttrs: !1,
|
|
1319
1323
|
__name: "modal",
|
|
1320
1324
|
props: {
|
|
@@ -1327,27 +1331,27 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1327
1331
|
function o() {
|
|
1328
1332
|
t.value = !1;
|
|
1329
1333
|
}
|
|
1330
|
-
return
|
|
1334
|
+
return T(t, (l) => {
|
|
1331
1335
|
l ? document.body.classList.add("overflow-hidden") : document.body.classList.remove("overflow-hidden");
|
|
1332
|
-
}), (l, a) => (i(),
|
|
1333
|
-
|
|
1336
|
+
}), (l, a) => (i(), p(Z, { to: "body" }, [
|
|
1337
|
+
V(P, {
|
|
1334
1338
|
appear: "",
|
|
1335
1339
|
name: "modal",
|
|
1336
1340
|
duration: { enter: 300, leave: 200 }
|
|
1337
1341
|
}, {
|
|
1338
|
-
default:
|
|
1339
|
-
t.value ? (i(), u("div",
|
|
1342
|
+
default: f(() => [
|
|
1343
|
+
t.value ? (i(), u("div", ht, [
|
|
1340
1344
|
a[0] || (a[0] = d("div", {
|
|
1341
1345
|
class: "modal__backdrop fixed inset-0 bg-primary-50/60 backdrop-blur-sm",
|
|
1342
1346
|
"aria-hidden": "true"
|
|
1343
1347
|
}, null, -1)),
|
|
1344
|
-
d("div",
|
|
1348
|
+
d("div", pt, [
|
|
1345
1349
|
d("div", {
|
|
1346
1350
|
onClick: ke(o, ["self"]),
|
|
1347
1351
|
class: "min-h-full flex items-center justify-center p-4 sm:p-6"
|
|
1348
1352
|
}, [
|
|
1349
|
-
d("div",
|
|
1350
|
-
|
|
1353
|
+
d("div", bt, [
|
|
1354
|
+
b(l.$slots, "default", { close: o })
|
|
1351
1355
|
])
|
|
1352
1356
|
])
|
|
1353
1357
|
])
|
|
@@ -1359,34 +1363,34 @@ const K = /* @__PURE__ */ je(Ie, [["render", Fe]]), Se = ["id", "type", "pattern
|
|
|
1359
1363
|
}
|
|
1360
1364
|
});
|
|
1361
1365
|
export {
|
|
1362
|
-
|
|
1363
|
-
|
|
1366
|
+
Et as Btn,
|
|
1367
|
+
Vt as Checkbox,
|
|
1364
1368
|
ze as Combobox,
|
|
1365
1369
|
qe as ComboboxButton,
|
|
1366
|
-
|
|
1370
|
+
kt as ComboboxInput,
|
|
1367
1371
|
Pe as ComboboxOption,
|
|
1368
1372
|
Te as ComboboxOptions,
|
|
1369
1373
|
H as Hint,
|
|
1370
|
-
|
|
1374
|
+
$t as Input,
|
|
1371
1375
|
F as Label,
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1376
|
+
Nt as Menu,
|
|
1377
|
+
qt as MenuItem,
|
|
1378
|
+
Lt as MenuItems,
|
|
1379
|
+
Ot as Modal,
|
|
1380
|
+
mt as Notification,
|
|
1381
|
+
jt as NotificationQueue,
|
|
1382
|
+
Pt as Offcanvas,
|
|
1383
|
+
Ut as Popover,
|
|
1384
|
+
zt as PopoverDialog,
|
|
1385
|
+
It as Progressbar,
|
|
1386
|
+
Mt as Radio,
|
|
1387
|
+
xt as Select,
|
|
1388
|
+
_t as Selectbox,
|
|
1389
|
+
Ct as Switch,
|
|
1390
|
+
Tt as Tab,
|
|
1391
|
+
Xt as TabContainer,
|
|
1392
|
+
At as TabList,
|
|
1393
|
+
Dt as TabPanel,
|
|
1394
|
+
Bt as Textarea,
|
|
1391
1395
|
$e as useClassList
|
|
1392
1396
|
};
|