@rotki/ui-library 0.2.2 → 0.2.3
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/components/index.es.js +1 -1
- package/dist/components/steppers/Stepper.vue.d.ts +10 -0
- package/dist/index-8228cd5f.js +2332 -0
- package/dist/index.es.js +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/dist/index-b9d540d9.js +0 -2310
|
@@ -0,0 +1,2332 @@
|
|
|
1
|
+
import { defineComponent as $, useCssVars as ze, unref as t, useCssModule as Z, toRefs as se, computed as b, openBlock as c, createElementBlock as f, normalizeClass as j, createElementVNode as x, Fragment as q, createCommentVNode as E, toDisplayString as V, useAttrs as Me, mergeProps as le, renderSlot as te, createBlock as Y, createVNode as Q, withCtx as X, createTextVNode as Ye, cloneVNode as at, h as Te, inject as Qe, provide as Ue, ref as k, onMounted as _e, watchEffect as ue, toRaw as P, watch as ce, onUnmounted as lt, nextTick as oe, useSlots as ye, resolveDynamicComponent as he, withModifiers as Re, renderList as de, isRef as it, Transition as rt, normalizeProps as De, guardReactiveProps as Pe, createSlots as Ie } from "vue";
|
|
2
|
+
import { get as _, objectOmit as be, set as ae } from "@vueuse/shared";
|
|
3
|
+
import { u as ut } from "./index-1f5d0d16.js";
|
|
4
|
+
import { useElementBounding as je, useVirtualList as ct, useArrayMap as dt, createGlobalState as Mt } from "@vueuse/core";
|
|
5
|
+
const pt = ["aria-valuenow"], _t = ["viewBox"], yt = ["stroke-width"], ft = /* @__PURE__ */ $({
|
|
6
|
+
name: "RuiProgress",
|
|
7
|
+
__name: "Progress",
|
|
8
|
+
props: {
|
|
9
|
+
value: { default: 0 },
|
|
10
|
+
bufferValue: { default: 0 },
|
|
11
|
+
variant: { default: "determinate" },
|
|
12
|
+
color: { default: "inherit" },
|
|
13
|
+
circular: { type: Boolean, default: !1 },
|
|
14
|
+
showLabel: { type: Boolean, default: !1 },
|
|
15
|
+
thickness: { default: 4 },
|
|
16
|
+
size: { default: 32 }
|
|
17
|
+
},
|
|
18
|
+
setup(e) {
|
|
19
|
+
const s = e;
|
|
20
|
+
ze((g) => ({
|
|
21
|
+
"54a5d9d4": t(p),
|
|
22
|
+
"284f2d02": t(i),
|
|
23
|
+
"399567a9": t(y),
|
|
24
|
+
fa8ad720: t(N),
|
|
25
|
+
"53bb3a7c": t(r)
|
|
26
|
+
}));
|
|
27
|
+
const n = Z(), { variant: a, value: o, bufferValue: l, thickness: i, size: p } = se(s), u = b(
|
|
28
|
+
() => Math.max(0, Math.min(_(o) ?? 100, 100))
|
|
29
|
+
), d = b(() => `${Math.floor(_(u))}%`), r = b(() => -100 + _(u)), y = b(() => `${_(r)}%`), N = b(
|
|
30
|
+
() => `${-100 + Math.max(0, Math.min(_(l) ?? 100, 100))}%`
|
|
31
|
+
), I = b(
|
|
32
|
+
() => +_(i) * 32 / +_(p)
|
|
33
|
+
), z = b(() => 40 + _(I));
|
|
34
|
+
return (g, M) => (c(), f("div", {
|
|
35
|
+
class: j([
|
|
36
|
+
t(n).wrapper,
|
|
37
|
+
g.circular ? "inline-flex" : "w-full",
|
|
38
|
+
{ [t(n)["has-label"]]: g.showLabel && t(a) !== "indeterminate" }
|
|
39
|
+
])
|
|
40
|
+
}, [
|
|
41
|
+
x("div", {
|
|
42
|
+
"aria-valuenow": t(o),
|
|
43
|
+
class: j([
|
|
44
|
+
g.circular && t(a) !== "buffer" ? t(n).circular : t(n).progress,
|
|
45
|
+
t(n)[t(a) ?? ""],
|
|
46
|
+
t(n)[g.color ?? ""]
|
|
47
|
+
]),
|
|
48
|
+
"aria-valuemax": "100",
|
|
49
|
+
"aria-valuemin": "0",
|
|
50
|
+
role: "progressbar"
|
|
51
|
+
}, [
|
|
52
|
+
g.circular && t(a) !== "buffer" ? (c(), f("svg", {
|
|
53
|
+
key: 0,
|
|
54
|
+
viewBox: `0 0 ${t(z)} ${t(z)}`
|
|
55
|
+
}, [
|
|
56
|
+
x("circle", {
|
|
57
|
+
cx: "50%",
|
|
58
|
+
cy: "50%",
|
|
59
|
+
fill: "none",
|
|
60
|
+
r: "20",
|
|
61
|
+
"stroke-width": t(I)
|
|
62
|
+
}, null, 8, yt)
|
|
63
|
+
], 8, _t)) : (c(), f(q, { key: 1 }, [
|
|
64
|
+
t(a) === "buffer" ? (c(), f("div", {
|
|
65
|
+
key: 0,
|
|
66
|
+
class: j(t(n)["buffer-dots"])
|
|
67
|
+
}, null, 2)) : E("", !0),
|
|
68
|
+
x("div", {
|
|
69
|
+
class: j([t(n).rail, { [t(n)["buffer-rail"]]: t(a) === "buffer" }])
|
|
70
|
+
}, null, 2),
|
|
71
|
+
x("div", {
|
|
72
|
+
class: j(t(n)[t(a) ?? ""])
|
|
73
|
+
}, null, 2)
|
|
74
|
+
], 64))
|
|
75
|
+
], 10, pt),
|
|
76
|
+
g.showLabel && t(a) !== "indeterminate" ? (c(), f("div", {
|
|
77
|
+
key: 0,
|
|
78
|
+
class: j(t(n).label)
|
|
79
|
+
}, V(t(d)), 3)) : E("", !0)
|
|
80
|
+
], 2));
|
|
81
|
+
}
|
|
82
|
+
}), jt = "_wrapper_g0b28_1", vt = "_label_g0b28_4", gt = "_circular_g0b28_7", Lt = "_progress_g0b28_12", Nt = "_rail_g0b28_16", bt = "_determinate_g0b28_19", mt = "_buffer_g0b28_20", Tt = "_indeterminate_g0b28_24", Dt = "_primary_g0b28_36", It = "_secondary_g0b28_47", zt = "_inherit_g0b28_58", ht = "_spin_g0b28_1", xt = {
|
|
83
|
+
wrapper: jt,
|
|
84
|
+
"has-label": "_has-label_g0b28_1",
|
|
85
|
+
label: vt,
|
|
86
|
+
circular: gt,
|
|
87
|
+
progress: Lt,
|
|
88
|
+
rail: Nt,
|
|
89
|
+
determinate: bt,
|
|
90
|
+
buffer: mt,
|
|
91
|
+
indeterminate: Tt,
|
|
92
|
+
"slide-rail": "_slide-rail_g0b28_1",
|
|
93
|
+
"buffer-dots": "_buffer-dots_g0b28_28",
|
|
94
|
+
"buffer-pulse": "_buffer-pulse_g0b28_1",
|
|
95
|
+
"buffer-rail": "_buffer-rail_g0b28_32",
|
|
96
|
+
primary: Dt,
|
|
97
|
+
secondary: It,
|
|
98
|
+
inherit: zt,
|
|
99
|
+
spin: ht,
|
|
100
|
+
"collapse-stroke": "_collapse-stroke_g0b28_1"
|
|
101
|
+
}, H = (e, s) => {
|
|
102
|
+
const n = e.__vccOpts || e;
|
|
103
|
+
for (const [a, o] of s)
|
|
104
|
+
n[a] = o;
|
|
105
|
+
return n;
|
|
106
|
+
}, St = {
|
|
107
|
+
$style: xt
|
|
108
|
+
}, Ve = /* @__PURE__ */ H(ft, [["__cssModules", St]]), At = ["disabled"], wt = /* @__PURE__ */ $({
|
|
109
|
+
name: "RuiButton",
|
|
110
|
+
__name: "Button",
|
|
111
|
+
props: {
|
|
112
|
+
disabled: { type: Boolean, default: !1 },
|
|
113
|
+
loading: { type: Boolean, default: !1 },
|
|
114
|
+
color: { default: void 0 },
|
|
115
|
+
rounded: { type: Boolean, default: !1 },
|
|
116
|
+
elevation: { default: null },
|
|
117
|
+
variant: { default: "default" },
|
|
118
|
+
icon: { type: Boolean, default: !1 },
|
|
119
|
+
size: { default: void 0 }
|
|
120
|
+
},
|
|
121
|
+
setup(e) {
|
|
122
|
+
const s = e, { disabled: n, elevation: a, variant: o, size: l } = se(s), i = Me(), p = Z(), u = b(() => {
|
|
123
|
+
if (_(n))
|
|
124
|
+
return 0;
|
|
125
|
+
const r = _(a);
|
|
126
|
+
return r !== null ? r : _(o) === "fab" ? 6 : 0;
|
|
127
|
+
}), d = b(() => {
|
|
128
|
+
const r = _(l);
|
|
129
|
+
return r === "lg" ? 26 : r === "sm" ? 18 : 22;
|
|
130
|
+
});
|
|
131
|
+
return (r, y) => (c(), f("button", le({
|
|
132
|
+
class: [
|
|
133
|
+
t(p).btn,
|
|
134
|
+
t(p)[r.color ?? "grey"],
|
|
135
|
+
t(p)[t(l) ?? ""],
|
|
136
|
+
t(p)[t(o)],
|
|
137
|
+
`shadow-${t(u)}`,
|
|
138
|
+
{
|
|
139
|
+
[t(p).loading]: r.loading,
|
|
140
|
+
[t(p)._rounded]: r.rounded,
|
|
141
|
+
[t(p).icon]: r.icon
|
|
142
|
+
}
|
|
143
|
+
],
|
|
144
|
+
disabled: t(n) || r.loading
|
|
145
|
+
}, t(i)), [
|
|
146
|
+
te(r.$slots, "prepend"),
|
|
147
|
+
x("span", {
|
|
148
|
+
class: j(t(p).label)
|
|
149
|
+
}, [
|
|
150
|
+
te(r.$slots, "default")
|
|
151
|
+
], 2),
|
|
152
|
+
te(r.$slots, "append"),
|
|
153
|
+
r.loading ? (c(), Y(Ve, {
|
|
154
|
+
key: 0,
|
|
155
|
+
circular: "",
|
|
156
|
+
class: j(t(p).spinner),
|
|
157
|
+
variant: "indeterminate",
|
|
158
|
+
size: t(d)
|
|
159
|
+
}, null, 8, ["class", "size"])) : E("", !0)
|
|
160
|
+
], 16, At));
|
|
161
|
+
}
|
|
162
|
+
}), kt = "_btn_153yk_315", Ot = "_primary_153yk_318", Et = "_secondary_153yk_321", Ct = "_error_153yk_324", $t = "_warning_153yk_327", Yt = "_info_153yk_330", Qt = "_success_153yk_334", Ut = "_grey_153yk_338", Rt = "_outlined_153yk_341", Pt = "_text_153yk_341", Vt = "_label_153yk_350", Bt = "__rounded_153yk_353", Ft = "_sm_153yk_356", Gt = "_lg_153yk_359", Wt = "_fab_153yk_443", Zt = "_icon_153yk_452", Ht = "_loading_153yk_464", Jt = "_spinner_153yk_467", Kt = {
|
|
163
|
+
btn: kt,
|
|
164
|
+
primary: Ot,
|
|
165
|
+
secondary: Et,
|
|
166
|
+
error: Ct,
|
|
167
|
+
warning: $t,
|
|
168
|
+
info: Yt,
|
|
169
|
+
success: Qt,
|
|
170
|
+
grey: Ut,
|
|
171
|
+
outlined: Rt,
|
|
172
|
+
text: Pt,
|
|
173
|
+
label: Vt,
|
|
174
|
+
_rounded: Bt,
|
|
175
|
+
sm: Ft,
|
|
176
|
+
lg: Gt,
|
|
177
|
+
fab: Wt,
|
|
178
|
+
icon: Zt,
|
|
179
|
+
loading: Ht,
|
|
180
|
+
spinner: Jt,
|
|
181
|
+
"bg-tint": "_bg-tint_153yk_1",
|
|
182
|
+
"bg-shade": "_bg-shade_153yk_1",
|
|
183
|
+
"text-tint": "_text-tint_153yk_1",
|
|
184
|
+
"text-shade": "_text-shade_153yk_1"
|
|
185
|
+
}, Xt = {
|
|
186
|
+
$style: Kt
|
|
187
|
+
}, ve = /* @__PURE__ */ H(wt, [["__cssModules", Xt]]), qt = ["height", "width"], en = ["d"], tn = /* @__PURE__ */ $({
|
|
188
|
+
name: "RuiIcon",
|
|
189
|
+
__name: "Icon",
|
|
190
|
+
props: {
|
|
191
|
+
name: {},
|
|
192
|
+
size: { default: 24 },
|
|
193
|
+
color: { default: void 0 }
|
|
194
|
+
},
|
|
195
|
+
setup(e) {
|
|
196
|
+
const s = e, n = Z(), { registeredIcons: a } = ut(), { name: o } = se(s), l = b(() => {
|
|
197
|
+
const i = _(o), p = `ri-${i}`, u = _(a)[p];
|
|
198
|
+
return u || console.error(
|
|
199
|
+
`Icons "${i}" not found. Make sure that you have register the icon when installing the RuiPlugin`
|
|
200
|
+
), u;
|
|
201
|
+
});
|
|
202
|
+
return (i, p) => (c(), f("svg", {
|
|
203
|
+
class: j([t(n).remixicon, t(n)[i.color ?? ""]]),
|
|
204
|
+
height: i.size,
|
|
205
|
+
width: i.size,
|
|
206
|
+
viewBox: "0 0 24 24",
|
|
207
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
208
|
+
}, [
|
|
209
|
+
x("path", {
|
|
210
|
+
d: t(l),
|
|
211
|
+
fill: "currentColor"
|
|
212
|
+
}, null, 8, en)
|
|
213
|
+
], 10, qt));
|
|
214
|
+
}
|
|
215
|
+
}), nn = "_remixicon_2d6in_315", on = "_primary_2d6in_315", sn = "_secondary_2d6in_318", an = "_error_2d6in_321", ln = "_warning_2d6in_324", rn = "_info_2d6in_327", un = "_success_2d6in_330", cn = {
|
|
216
|
+
remixicon: nn,
|
|
217
|
+
primary: on,
|
|
218
|
+
secondary: sn,
|
|
219
|
+
error: an,
|
|
220
|
+
warning: ln,
|
|
221
|
+
info: rn,
|
|
222
|
+
success: un,
|
|
223
|
+
"bg-tint": "_bg-tint_2d6in_1",
|
|
224
|
+
"bg-shade": "_bg-shade_2d6in_1",
|
|
225
|
+
"text-tint": "_text-tint_2d6in_1",
|
|
226
|
+
"text-shade": "_text-shade_2d6in_1"
|
|
227
|
+
}, dn = {
|
|
228
|
+
$style: cn
|
|
229
|
+
}, C = /* @__PURE__ */ H(tn, [["__cssModules", dn]]), Mn = { class: "flex space-x-3 py-1 flex-grow" }, pn = {
|
|
230
|
+
key: 0,
|
|
231
|
+
class: "font-medium"
|
|
232
|
+
}, _n = { class: "text-body-2" }, yn = { key: 0 }, fn = { key: 1 }, jn = /* @__PURE__ */ $({
|
|
233
|
+
name: "RuiAlert",
|
|
234
|
+
__name: "Alert",
|
|
235
|
+
props: {
|
|
236
|
+
title: { default: "" },
|
|
237
|
+
description: { default: "" },
|
|
238
|
+
type: { default: "primary" },
|
|
239
|
+
icon: { default: "" },
|
|
240
|
+
variant: { default: "default" },
|
|
241
|
+
actionText: { default: "" },
|
|
242
|
+
closeable: { type: Boolean, default: !1 }
|
|
243
|
+
},
|
|
244
|
+
emits: ["action", "close"],
|
|
245
|
+
setup(e, { emit: s }) {
|
|
246
|
+
const n = e, { icon: a, type: o } = se(n), l = b(() => {
|
|
247
|
+
const u = _(a);
|
|
248
|
+
return u || ({
|
|
249
|
+
primary: "",
|
|
250
|
+
secondary: "",
|
|
251
|
+
warning: "alert-line",
|
|
252
|
+
info: "information-line",
|
|
253
|
+
error: "error-warning-line",
|
|
254
|
+
success: "checkbox-circle-line"
|
|
255
|
+
}[_(o)] ?? "");
|
|
256
|
+
}), i = Z(), p = Me();
|
|
257
|
+
return (u, d) => (c(), f("div", le({
|
|
258
|
+
class: [t(i).alert, t(i)[t(o)], t(i)[u.variant]]
|
|
259
|
+
}, t(p)), [
|
|
260
|
+
x("div", Mn, [
|
|
261
|
+
t(l) ? (c(), f("div", {
|
|
262
|
+
key: 0,
|
|
263
|
+
class: j(t(i).icon)
|
|
264
|
+
}, [
|
|
265
|
+
Q(C, {
|
|
266
|
+
name: t(l),
|
|
267
|
+
size: "22"
|
|
268
|
+
}, null, 8, ["name"])
|
|
269
|
+
], 2)) : E("", !0),
|
|
270
|
+
x("div", {
|
|
271
|
+
class: j(["space-y-1 flex-grow", t(i).texts])
|
|
272
|
+
}, [
|
|
273
|
+
u.title ? (c(), f("div", pn, V(u.title), 1)) : E("", !0),
|
|
274
|
+
x("div", _n, V(u.description), 1)
|
|
275
|
+
], 2)
|
|
276
|
+
]),
|
|
277
|
+
u.actionText ? (c(), f("div", yn, [
|
|
278
|
+
Q(ve, {
|
|
279
|
+
variant: "text",
|
|
280
|
+
size: "sm",
|
|
281
|
+
color: u.variant === "filled" ? void 0 : t(o),
|
|
282
|
+
class: j(t(i).action),
|
|
283
|
+
onClick: d[0] || (d[0] = (r) => s("action"))
|
|
284
|
+
}, {
|
|
285
|
+
default: X(() => [
|
|
286
|
+
Ye(V(u.actionText), 1)
|
|
287
|
+
]),
|
|
288
|
+
_: 1
|
|
289
|
+
}, 8, ["color", "class"])
|
|
290
|
+
])) : E("", !0),
|
|
291
|
+
u.closeable ? (c(), f("div", fn, [
|
|
292
|
+
Q(ve, {
|
|
293
|
+
color: u.variant === "filled" ? void 0 : t(o),
|
|
294
|
+
size: "sm",
|
|
295
|
+
icon: "",
|
|
296
|
+
variant: "text",
|
|
297
|
+
class: j(t(i).close),
|
|
298
|
+
onClick: d[1] || (d[1] = (r) => s("close"))
|
|
299
|
+
}, {
|
|
300
|
+
default: X(() => [
|
|
301
|
+
Q(C, {
|
|
302
|
+
name: "close-fill",
|
|
303
|
+
size: "20"
|
|
304
|
+
})
|
|
305
|
+
]),
|
|
306
|
+
_: 1
|
|
307
|
+
}, 8, ["color", "class"])
|
|
308
|
+
])) : E("", !0)
|
|
309
|
+
], 16));
|
|
310
|
+
}
|
|
311
|
+
}), vn = "_alert_1r1r6_315", gn = "_primary_1r1r6_315", Ln = "_icon_1r1r6_318", Nn = "_texts_1r1r6_319", bn = "_action_1r1r6_320", mn = "_close_1r1r6_321", Tn = "_outlined_1r1r6_321", Dn = "_secondary_1r1r6_330", In = "_error_1r1r6_345", zn = "_warning_1r1r6_360", hn = "_info_1r1r6_375", xn = "_success_1r1r6_390", Sn = "_filled_1r1r6_416", An = {
|
|
312
|
+
alert: vn,
|
|
313
|
+
primary: gn,
|
|
314
|
+
default: "_default_1r1r6_315",
|
|
315
|
+
"bg-shade": "_bg-shade_1r1r6_1",
|
|
316
|
+
icon: Ln,
|
|
317
|
+
texts: Nn,
|
|
318
|
+
action: bn,
|
|
319
|
+
close: mn,
|
|
320
|
+
outlined: Tn,
|
|
321
|
+
"text-tint": "_text-tint_1r1r6_1",
|
|
322
|
+
secondary: Dn,
|
|
323
|
+
error: In,
|
|
324
|
+
warning: zn,
|
|
325
|
+
info: hn,
|
|
326
|
+
success: xn,
|
|
327
|
+
"bg-tint": "_bg-tint_1r1r6_1",
|
|
328
|
+
filled: Sn,
|
|
329
|
+
"text-shade": "_text-shade_1r1r6_1"
|
|
330
|
+
}, wn = {
|
|
331
|
+
$style: An
|
|
332
|
+
}, _i = /* @__PURE__ */ H(jn, [["__cssModules", wn]]);
|
|
333
|
+
function ne(e, s, ...n) {
|
|
334
|
+
if (e in s) {
|
|
335
|
+
let o = s[e];
|
|
336
|
+
return typeof o == "function" ? o(...n) : o;
|
|
337
|
+
}
|
|
338
|
+
let a = new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(s).map((o) => `"${o}"`).join(", ")}.`);
|
|
339
|
+
throw Error.captureStackTrace && Error.captureStackTrace(a, ne), a;
|
|
340
|
+
}
|
|
341
|
+
var ge = ((e) => (e[e.None = 0] = "None", e[e.RenderStrategy = 1] = "RenderStrategy", e[e.Static = 2] = "Static", e))(ge || {}), kn = ((e) => (e[e.Unmount = 0] = "Unmount", e[e.Hidden = 1] = "Hidden", e))(kn || {});
|
|
342
|
+
function pe({ visible: e = !0, features: s = 0, ourProps: n, theirProps: a, ...o }) {
|
|
343
|
+
var l;
|
|
344
|
+
let i = Fe(a, n), p = Object.assign(o, { props: i });
|
|
345
|
+
if (e || s & 2 && i.static)
|
|
346
|
+
return me(p);
|
|
347
|
+
if (s & 1) {
|
|
348
|
+
let u = (l = i.unmount) == null || l ? 0 : 1;
|
|
349
|
+
return ne(u, { 0() {
|
|
350
|
+
return null;
|
|
351
|
+
}, 1() {
|
|
352
|
+
return me({ ...o, props: { ...i, hidden: !0, style: { display: "none" } } });
|
|
353
|
+
} });
|
|
354
|
+
}
|
|
355
|
+
return me(p);
|
|
356
|
+
}
|
|
357
|
+
function me({ props: e, attrs: s, slots: n, slot: a, name: o }) {
|
|
358
|
+
var l, i;
|
|
359
|
+
let { as: p, ...u } = xe(e, ["unmount", "static"]), d = (l = n.default) == null ? void 0 : l.call(n, a), r = {};
|
|
360
|
+
if (a) {
|
|
361
|
+
let y = !1, N = [];
|
|
362
|
+
for (let [I, z] of Object.entries(a))
|
|
363
|
+
typeof z == "boolean" && (y = !0), z === !0 && N.push(I);
|
|
364
|
+
y && (r["data-headlessui-state"] = N.join(" "));
|
|
365
|
+
}
|
|
366
|
+
if (p === "template") {
|
|
367
|
+
if (d = Be(d ?? []), Object.keys(u).length > 0 || Object.keys(s).length > 0) {
|
|
368
|
+
let [y, ...N] = d ?? [];
|
|
369
|
+
if (!En(y) || N.length > 0)
|
|
370
|
+
throw new Error(['Passing props on "template"!', "", `The current component <${o} /> is rendering a "template".`, "However we need to passthrough the following props:", Object.keys(u).concat(Object.keys(s)).map((g) => g.trim()).filter((g, M, m) => m.indexOf(g) === M).sort((g, M) => g.localeCompare(M)).map((g) => ` - ${g}`).join(`
|
|
371
|
+
`), "", "You can apply a few solutions:", ['Add an `as="..."` prop, to ensure that we render an actual element instead of a "template".', "Render a single element as the child so that we can forward the props onto that element."].map((g) => ` - ${g}`).join(`
|
|
372
|
+
`)].join(`
|
|
373
|
+
`));
|
|
374
|
+
let I = Fe((i = y.props) != null ? i : {}, u), z = at(y, I);
|
|
375
|
+
for (let g in I)
|
|
376
|
+
g.startsWith("on") && (z.props || (z.props = {}), z.props[g] = I[g]);
|
|
377
|
+
return z;
|
|
378
|
+
}
|
|
379
|
+
return Array.isArray(d) && d.length === 1 ? d[0] : d;
|
|
380
|
+
}
|
|
381
|
+
return Te(p, Object.assign({}, u, r), { default: () => d });
|
|
382
|
+
}
|
|
383
|
+
function Be(e) {
|
|
384
|
+
return e.flatMap((s) => s.type === q ? Be(s.children) : [s]);
|
|
385
|
+
}
|
|
386
|
+
function Fe(...e) {
|
|
387
|
+
if (e.length === 0)
|
|
388
|
+
return {};
|
|
389
|
+
if (e.length === 1)
|
|
390
|
+
return e[0];
|
|
391
|
+
let s = {}, n = {};
|
|
392
|
+
for (let a of e)
|
|
393
|
+
for (let o in a)
|
|
394
|
+
o.startsWith("on") && typeof a[o] == "function" ? (n[o] != null || (n[o] = []), n[o].push(a[o])) : s[o] = a[o];
|
|
395
|
+
if (s.disabled || s["aria-disabled"])
|
|
396
|
+
return Object.assign(s, Object.fromEntries(Object.keys(n).map((a) => [a, void 0])));
|
|
397
|
+
for (let a in n)
|
|
398
|
+
Object.assign(s, { [a](o, ...l) {
|
|
399
|
+
let i = n[a];
|
|
400
|
+
for (let p of i) {
|
|
401
|
+
if (o instanceof Event && o.defaultPrevented)
|
|
402
|
+
return;
|
|
403
|
+
p(o, ...l);
|
|
404
|
+
}
|
|
405
|
+
} });
|
|
406
|
+
return s;
|
|
407
|
+
}
|
|
408
|
+
function On(e) {
|
|
409
|
+
let s = Object.assign({}, e);
|
|
410
|
+
for (let n in s)
|
|
411
|
+
s[n] === void 0 && delete s[n];
|
|
412
|
+
return s;
|
|
413
|
+
}
|
|
414
|
+
function xe(e, s = []) {
|
|
415
|
+
let n = Object.assign({}, e);
|
|
416
|
+
for (let a of s)
|
|
417
|
+
a in n && delete n[a];
|
|
418
|
+
return n;
|
|
419
|
+
}
|
|
420
|
+
function En(e) {
|
|
421
|
+
return e == null ? !1 : typeof e.type == "string" || typeof e.type == "object" || typeof e.type == "function";
|
|
422
|
+
}
|
|
423
|
+
let Cn = 0;
|
|
424
|
+
function $n() {
|
|
425
|
+
return ++Cn;
|
|
426
|
+
}
|
|
427
|
+
function Ne() {
|
|
428
|
+
return $n();
|
|
429
|
+
}
|
|
430
|
+
var K = ((e) => (e.Space = " ", e.Enter = "Enter", e.Escape = "Escape", e.Backspace = "Backspace", e.Delete = "Delete", e.ArrowLeft = "ArrowLeft", e.ArrowUp = "ArrowUp", e.ArrowRight = "ArrowRight", e.ArrowDown = "ArrowDown", e.Home = "Home", e.End = "End", e.PageUp = "PageUp", e.PageDown = "PageDown", e.Tab = "Tab", e))(K || {});
|
|
431
|
+
function Yn(e) {
|
|
432
|
+
throw new Error("Unexpected object: " + e);
|
|
433
|
+
}
|
|
434
|
+
var G = ((e) => (e[e.First = 0] = "First", e[e.Previous = 1] = "Previous", e[e.Next = 2] = "Next", e[e.Last = 3] = "Last", e[e.Specific = 4] = "Specific", e[e.Nothing = 5] = "Nothing", e))(G || {});
|
|
435
|
+
function Qn(e, s) {
|
|
436
|
+
let n = s.resolveItems();
|
|
437
|
+
if (n.length <= 0)
|
|
438
|
+
return null;
|
|
439
|
+
let a = s.resolveActiveIndex(), o = a ?? -1, l = (() => {
|
|
440
|
+
switch (e.focus) {
|
|
441
|
+
case 0:
|
|
442
|
+
return n.findIndex((i) => !s.resolveDisabled(i));
|
|
443
|
+
case 1: {
|
|
444
|
+
let i = n.slice().reverse().findIndex((p, u, d) => o !== -1 && d.length - u - 1 >= o ? !1 : !s.resolveDisabled(p));
|
|
445
|
+
return i === -1 ? i : n.length - 1 - i;
|
|
446
|
+
}
|
|
447
|
+
case 2:
|
|
448
|
+
return n.findIndex((i, p) => p <= o ? !1 : !s.resolveDisabled(i));
|
|
449
|
+
case 3: {
|
|
450
|
+
let i = n.slice().reverse().findIndex((p) => !s.resolveDisabled(p));
|
|
451
|
+
return i === -1 ? i : n.length - 1 - i;
|
|
452
|
+
}
|
|
453
|
+
case 4:
|
|
454
|
+
return n.findIndex((i) => s.resolveId(i) === e.id);
|
|
455
|
+
case 5:
|
|
456
|
+
return null;
|
|
457
|
+
default:
|
|
458
|
+
Yn(e);
|
|
459
|
+
}
|
|
460
|
+
})();
|
|
461
|
+
return l === -1 ? a : l;
|
|
462
|
+
}
|
|
463
|
+
function U(e) {
|
|
464
|
+
var s;
|
|
465
|
+
return e == null || e.value == null ? null : (s = e.value.$el) != null ? s : e.value;
|
|
466
|
+
}
|
|
467
|
+
let Ge = Symbol("Context");
|
|
468
|
+
var Le = ((e) => (e[e.Open = 1] = "Open", e[e.Closed = 2] = "Closed", e[e.Closing = 4] = "Closing", e[e.Opening = 8] = "Opening", e))(Le || {});
|
|
469
|
+
function Un() {
|
|
470
|
+
return Qe(Ge, null);
|
|
471
|
+
}
|
|
472
|
+
function Rn(e) {
|
|
473
|
+
Ue(Ge, e);
|
|
474
|
+
}
|
|
475
|
+
function Ae(e, s) {
|
|
476
|
+
if (e)
|
|
477
|
+
return e;
|
|
478
|
+
let n = s ?? "button";
|
|
479
|
+
if (typeof n == "string" && n.toLowerCase() === "button")
|
|
480
|
+
return "button";
|
|
481
|
+
}
|
|
482
|
+
function Pn(e, s) {
|
|
483
|
+
let n = k(Ae(e.value.type, e.value.as));
|
|
484
|
+
return _e(() => {
|
|
485
|
+
n.value = Ae(e.value.type, e.value.as);
|
|
486
|
+
}), ue(() => {
|
|
487
|
+
var a;
|
|
488
|
+
n.value || U(s) && U(s) instanceof HTMLButtonElement && !((a = U(s)) != null && a.hasAttribute("type")) && (n.value = "button");
|
|
489
|
+
}), n;
|
|
490
|
+
}
|
|
491
|
+
var Vn = Object.defineProperty, Bn = (e, s, n) => s in e ? Vn(e, s, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[s] = n, we = (e, s, n) => (Bn(e, typeof s != "symbol" ? s + "" : s, n), n);
|
|
492
|
+
let Fn = class {
|
|
493
|
+
constructor() {
|
|
494
|
+
we(this, "current", this.detect()), we(this, "currentId", 0);
|
|
495
|
+
}
|
|
496
|
+
set(s) {
|
|
497
|
+
this.current !== s && (this.currentId = 0, this.current = s);
|
|
498
|
+
}
|
|
499
|
+
reset() {
|
|
500
|
+
this.set(this.detect());
|
|
501
|
+
}
|
|
502
|
+
nextId() {
|
|
503
|
+
return ++this.currentId;
|
|
504
|
+
}
|
|
505
|
+
get isServer() {
|
|
506
|
+
return this.current === "server";
|
|
507
|
+
}
|
|
508
|
+
get isClient() {
|
|
509
|
+
return this.current === "client";
|
|
510
|
+
}
|
|
511
|
+
detect() {
|
|
512
|
+
return typeof window > "u" || typeof document > "u" ? "server" : "client";
|
|
513
|
+
}
|
|
514
|
+
}, Se = new Fn();
|
|
515
|
+
function We(e) {
|
|
516
|
+
if (Se.isServer)
|
|
517
|
+
return null;
|
|
518
|
+
if (e instanceof Node)
|
|
519
|
+
return e.ownerDocument;
|
|
520
|
+
if (e != null && e.hasOwnProperty("value")) {
|
|
521
|
+
let s = U(e);
|
|
522
|
+
if (s)
|
|
523
|
+
return s.ownerDocument;
|
|
524
|
+
}
|
|
525
|
+
return document;
|
|
526
|
+
}
|
|
527
|
+
function Gn({ container: e, accept: s, walk: n, enabled: a }) {
|
|
528
|
+
ue(() => {
|
|
529
|
+
let o = e.value;
|
|
530
|
+
if (!o || a !== void 0 && !a.value)
|
|
531
|
+
return;
|
|
532
|
+
let l = We(e);
|
|
533
|
+
if (!l)
|
|
534
|
+
return;
|
|
535
|
+
let i = Object.assign((u) => s(u), { acceptNode: s }), p = l.createTreeWalker(o, NodeFilter.SHOW_ELEMENT, i, !1);
|
|
536
|
+
for (; p.nextNode(); )
|
|
537
|
+
n(p.currentNode);
|
|
538
|
+
});
|
|
539
|
+
}
|
|
540
|
+
let ke = ["[contentEditable=true]", "[tabindex]", "a[href]", "area[href]", "button:not([disabled])", "iframe", "input:not([disabled])", "select:not([disabled])", "textarea:not([disabled])"].map((e) => `${e}:not([tabindex='-1'])`).join(",");
|
|
541
|
+
var Wn = ((e) => (e[e.First = 1] = "First", e[e.Previous = 2] = "Previous", e[e.Next = 4] = "Next", e[e.Last = 8] = "Last", e[e.WrapAround = 16] = "WrapAround", e[e.NoScroll = 32] = "NoScroll", e))(Wn || {}), Zn = ((e) => (e[e.Error = 0] = "Error", e[e.Overflow = 1] = "Overflow", e[e.Success = 2] = "Success", e[e.Underflow = 3] = "Underflow", e))(Zn || {}), Hn = ((e) => (e[e.Previous = -1] = "Previous", e[e.Next = 1] = "Next", e))(Hn || {}), Ze = ((e) => (e[e.Strict = 0] = "Strict", e[e.Loose = 1] = "Loose", e))(Ze || {});
|
|
542
|
+
function Jn(e, s = 0) {
|
|
543
|
+
var n;
|
|
544
|
+
return e === ((n = We(e)) == null ? void 0 : n.body) ? !1 : ne(s, { 0() {
|
|
545
|
+
return e.matches(ke);
|
|
546
|
+
}, 1() {
|
|
547
|
+
let a = e;
|
|
548
|
+
for (; a !== null; ) {
|
|
549
|
+
if (a.matches(ke))
|
|
550
|
+
return !0;
|
|
551
|
+
a = a.parentElement;
|
|
552
|
+
}
|
|
553
|
+
return !1;
|
|
554
|
+
} });
|
|
555
|
+
}
|
|
556
|
+
var Kn = ((e) => (e[e.Keyboard = 0] = "Keyboard", e[e.Mouse = 1] = "Mouse", e))(Kn || {});
|
|
557
|
+
typeof window < "u" && typeof document < "u" && (document.addEventListener("keydown", (e) => {
|
|
558
|
+
e.metaKey || e.altKey || e.ctrlKey || (document.documentElement.dataset.headlessuiFocusVisible = "");
|
|
559
|
+
}, !0), document.addEventListener("click", (e) => {
|
|
560
|
+
e.detail === 1 ? delete document.documentElement.dataset.headlessuiFocusVisible : e.detail === 0 && (document.documentElement.dataset.headlessuiFocusVisible = "");
|
|
561
|
+
}, !0));
|
|
562
|
+
function Xn(e, s = (n) => n) {
|
|
563
|
+
return e.slice().sort((n, a) => {
|
|
564
|
+
let o = s(n), l = s(a);
|
|
565
|
+
if (o === null || l === null)
|
|
566
|
+
return 0;
|
|
567
|
+
let i = o.compareDocumentPosition(l);
|
|
568
|
+
return i & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : i & Node.DOCUMENT_POSITION_PRECEDING ? 1 : 0;
|
|
569
|
+
});
|
|
570
|
+
}
|
|
571
|
+
function Oe(e, s, n) {
|
|
572
|
+
Se.isServer || ue((a) => {
|
|
573
|
+
document.addEventListener(e, s, n), a(() => document.removeEventListener(e, s, n));
|
|
574
|
+
});
|
|
575
|
+
}
|
|
576
|
+
function qn(e, s, n) {
|
|
577
|
+
Se.isServer || ue((a) => {
|
|
578
|
+
window.addEventListener(e, s, n), a(() => window.removeEventListener(e, s, n));
|
|
579
|
+
});
|
|
580
|
+
}
|
|
581
|
+
function eo(e, s, n = b(() => !0)) {
|
|
582
|
+
function a(l, i) {
|
|
583
|
+
if (!n.value || l.defaultPrevented)
|
|
584
|
+
return;
|
|
585
|
+
let p = i(l);
|
|
586
|
+
if (p === null || !p.getRootNode().contains(p))
|
|
587
|
+
return;
|
|
588
|
+
let u = function d(r) {
|
|
589
|
+
return typeof r == "function" ? d(r()) : Array.isArray(r) || r instanceof Set ? r : [r];
|
|
590
|
+
}(e);
|
|
591
|
+
for (let d of u) {
|
|
592
|
+
if (d === null)
|
|
593
|
+
continue;
|
|
594
|
+
let r = d instanceof HTMLElement ? d : U(d);
|
|
595
|
+
if (r != null && r.contains(p) || l.composed && l.composedPath().includes(r))
|
|
596
|
+
return;
|
|
597
|
+
}
|
|
598
|
+
return !Jn(p, Ze.Loose) && p.tabIndex !== -1 && l.preventDefault(), s(l, p);
|
|
599
|
+
}
|
|
600
|
+
let o = k(null);
|
|
601
|
+
Oe("mousedown", (l) => {
|
|
602
|
+
var i, p;
|
|
603
|
+
n.value && (o.value = ((p = (i = l.composedPath) == null ? void 0 : i.call(l)) == null ? void 0 : p[0]) || l.target);
|
|
604
|
+
}, !0), Oe("click", (l) => {
|
|
605
|
+
o.value && (a(l, () => o.value), o.value = null);
|
|
606
|
+
}, !0), qn("blur", (l) => a(l, () => window.document.activeElement instanceof HTMLIFrameElement ? window.document.activeElement : null), !0);
|
|
607
|
+
}
|
|
608
|
+
var He = ((e) => (e[e.None = 1] = "None", e[e.Focusable = 2] = "Focusable", e[e.Hidden = 4] = "Hidden", e))(He || {});
|
|
609
|
+
let to = $({ name: "Hidden", props: { as: { type: [Object, String], default: "div" }, features: { type: Number, default: 1 } }, setup(e, { slots: s, attrs: n }) {
|
|
610
|
+
return () => {
|
|
611
|
+
let { features: a, ...o } = e, l = { "aria-hidden": (a & 2) === 2 ? !0 : void 0, style: { position: "fixed", top: 1, left: 1, width: 1, height: 0, padding: 0, margin: -1, overflow: "hidden", clip: "rect(0, 0, 0, 0)", whiteSpace: "nowrap", borderWidth: "0", ...(a & 4) === 4 && (a & 2) !== 2 && { display: "none" } } };
|
|
612
|
+
return pe({ ourProps: l, theirProps: o, slot: {}, attrs: n, slots: s, name: "Hidden" });
|
|
613
|
+
};
|
|
614
|
+
} });
|
|
615
|
+
function Je(e = {}, s = null, n = []) {
|
|
616
|
+
for (let [a, o] of Object.entries(e))
|
|
617
|
+
Xe(n, Ke(s, a), o);
|
|
618
|
+
return n;
|
|
619
|
+
}
|
|
620
|
+
function Ke(e, s) {
|
|
621
|
+
return e ? e + "[" + s + "]" : s;
|
|
622
|
+
}
|
|
623
|
+
function Xe(e, s, n) {
|
|
624
|
+
if (Array.isArray(n))
|
|
625
|
+
for (let [a, o] of n.entries())
|
|
626
|
+
Xe(e, Ke(s, a.toString()), o);
|
|
627
|
+
else
|
|
628
|
+
n instanceof Date ? e.push([s, n.toISOString()]) : typeof n == "boolean" ? e.push([s, n ? "1" : "0"]) : typeof n == "string" ? e.push([s, n]) : typeof n == "number" ? e.push([s, `${n}`]) : n == null ? e.push([s, ""]) : Je(n, s, e);
|
|
629
|
+
}
|
|
630
|
+
function no(e, s, n) {
|
|
631
|
+
let a = k(n == null ? void 0 : n.value), o = b(() => e.value !== void 0);
|
|
632
|
+
return [b(() => o.value ? e.value : a.value), function(l) {
|
|
633
|
+
return o.value || (a.value = l), s == null ? void 0 : s(l);
|
|
634
|
+
}];
|
|
635
|
+
}
|
|
636
|
+
function Ee(e) {
|
|
637
|
+
return [e.screenX, e.screenY];
|
|
638
|
+
}
|
|
639
|
+
function oo() {
|
|
640
|
+
let e = k([-1, -1]);
|
|
641
|
+
return { wasMoved(s) {
|
|
642
|
+
let n = Ee(s);
|
|
643
|
+
return e.value[0] === n[0] && e.value[1] === n[1] ? !1 : (e.value = n, !0);
|
|
644
|
+
}, update(s) {
|
|
645
|
+
e.value = Ee(s);
|
|
646
|
+
} };
|
|
647
|
+
}
|
|
648
|
+
function so() {
|
|
649
|
+
return /iPhone/gi.test(window.navigator.platform) || /Mac/gi.test(window.navigator.platform) && window.navigator.maxTouchPoints > 0;
|
|
650
|
+
}
|
|
651
|
+
function ao() {
|
|
652
|
+
return /Android/gi.test(window.navigator.userAgent);
|
|
653
|
+
}
|
|
654
|
+
function lo() {
|
|
655
|
+
return so() || ao();
|
|
656
|
+
}
|
|
657
|
+
function qe() {
|
|
658
|
+
let e = [], s = { addEventListener(n, a, o, l) {
|
|
659
|
+
return n.addEventListener(a, o, l), s.add(() => n.removeEventListener(a, o, l));
|
|
660
|
+
}, requestAnimationFrame(...n) {
|
|
661
|
+
let a = requestAnimationFrame(...n);
|
|
662
|
+
s.add(() => cancelAnimationFrame(a));
|
|
663
|
+
}, nextFrame(...n) {
|
|
664
|
+
s.requestAnimationFrame(() => {
|
|
665
|
+
s.requestAnimationFrame(...n);
|
|
666
|
+
});
|
|
667
|
+
}, setTimeout(...n) {
|
|
668
|
+
let a = setTimeout(...n);
|
|
669
|
+
s.add(() => clearTimeout(a));
|
|
670
|
+
}, style(n, a, o) {
|
|
671
|
+
let l = n.style.getPropertyValue(a);
|
|
672
|
+
return Object.assign(n.style, { [a]: o }), this.add(() => {
|
|
673
|
+
Object.assign(n.style, { [a]: l });
|
|
674
|
+
});
|
|
675
|
+
}, group(n) {
|
|
676
|
+
let a = qe();
|
|
677
|
+
return n(a), this.add(() => a.dispose());
|
|
678
|
+
}, add(n) {
|
|
679
|
+
return e.push(n), () => {
|
|
680
|
+
let a = e.indexOf(n);
|
|
681
|
+
if (a >= 0)
|
|
682
|
+
for (let o of e.splice(a, 1))
|
|
683
|
+
o();
|
|
684
|
+
};
|
|
685
|
+
}, dispose() {
|
|
686
|
+
for (let n of e.splice(0))
|
|
687
|
+
n();
|
|
688
|
+
} };
|
|
689
|
+
return s;
|
|
690
|
+
}
|
|
691
|
+
function io(e, s) {
|
|
692
|
+
return e === s;
|
|
693
|
+
}
|
|
694
|
+
var ro = ((e) => (e[e.Open = 0] = "Open", e[e.Closed = 1] = "Closed", e))(ro || {}), uo = ((e) => (e[e.Single = 0] = "Single", e[e.Multi = 1] = "Multi", e))(uo || {}), co = ((e) => (e[e.Pointer = 0] = "Pointer", e[e.Other = 1] = "Other", e))(co || {});
|
|
695
|
+
let et = Symbol("ComboboxContext");
|
|
696
|
+
function fe(e) {
|
|
697
|
+
let s = Qe(et, null);
|
|
698
|
+
if (s === null) {
|
|
699
|
+
let n = new Error(`<${e} /> is missing a parent <Combobox /> component.`);
|
|
700
|
+
throw Error.captureStackTrace && Error.captureStackTrace(n, fe), n;
|
|
701
|
+
}
|
|
702
|
+
return s;
|
|
703
|
+
}
|
|
704
|
+
let Mo = $({ name: "Combobox", emits: { "update:modelValue": (e) => !0 }, props: { as: { type: [Object, String], default: "template" }, disabled: { type: [Boolean], default: !1 }, by: { type: [String, Function], default: () => io }, modelValue: { type: [Object, String, Number, Boolean], default: void 0 }, defaultValue: { type: [Object, String, Number, Boolean], default: void 0 }, form: { type: String, optional: !0 }, name: { type: String, optional: !0 }, nullable: { type: Boolean, default: !1 }, multiple: { type: [Boolean], default: !1 } }, inheritAttrs: !1, setup(e, { slots: s, attrs: n, emit: a }) {
|
|
705
|
+
let o = k(1), l = k(null), i = k(null), p = k(null), u = k(null), d = k({ static: !1, hold: !1 }), r = k([]), y = k(null), N = k(1), I = k(!1);
|
|
706
|
+
function z(D = (S) => S) {
|
|
707
|
+
let S = y.value !== null ? r.value[y.value] : null, w = Xn(D(r.value.slice()), (O) => U(O.dataRef.domRef)), h = S ? w.indexOf(S) : null;
|
|
708
|
+
return h === -1 && (h = null), { options: w, activeOptionIndex: h };
|
|
709
|
+
}
|
|
710
|
+
let g = b(() => e.multiple ? 1 : 0), M = b(() => e.nullable), [m, v] = no(b(() => e.modelValue === void 0 ? ne(g.value, { 1: [], 0: void 0 }) : e.modelValue), (D) => a("update:modelValue", D), b(() => e.defaultValue)), L = { comboboxState: o, value: m, mode: g, compare(D, S) {
|
|
711
|
+
if (typeof e.by == "string") {
|
|
712
|
+
let w = e.by;
|
|
713
|
+
return (D == null ? void 0 : D[w]) === (S == null ? void 0 : S[w]);
|
|
714
|
+
}
|
|
715
|
+
return e.by(D, S);
|
|
716
|
+
}, defaultValue: b(() => e.defaultValue), nullable: M, inputRef: i, labelRef: l, buttonRef: p, optionsRef: u, disabled: b(() => e.disabled), options: r, change(D) {
|
|
717
|
+
v(D);
|
|
718
|
+
}, activeOptionIndex: b(() => {
|
|
719
|
+
if (I.value && y.value === null && r.value.length > 0) {
|
|
720
|
+
let D = r.value.findIndex((S) => !S.dataRef.disabled);
|
|
721
|
+
D !== -1 && (y.value = D);
|
|
722
|
+
}
|
|
723
|
+
return y.value;
|
|
724
|
+
}), activationTrigger: N, optionsPropsRef: d, closeCombobox() {
|
|
725
|
+
I.value = !1, !e.disabled && o.value !== 1 && (o.value = 1, y.value = null);
|
|
726
|
+
}, openCombobox() {
|
|
727
|
+
if (I.value = !0, e.disabled || o.value === 0)
|
|
728
|
+
return;
|
|
729
|
+
let D = r.value.findIndex((S) => {
|
|
730
|
+
let w = P(S.dataRef.value);
|
|
731
|
+
return ne(g.value, { 0: () => L.compare(P(L.value.value), P(w)), 1: () => P(L.value.value).some((h) => L.compare(P(h), P(w))) });
|
|
732
|
+
});
|
|
733
|
+
D !== -1 && (y.value = D), o.value = 0;
|
|
734
|
+
}, goToOption(D, S, w) {
|
|
735
|
+
if (I.value = !1, e.disabled || u.value && !d.value.static && o.value === 1)
|
|
736
|
+
return;
|
|
737
|
+
let h = z();
|
|
738
|
+
if (h.activeOptionIndex === null) {
|
|
739
|
+
let R = h.options.findIndex((ie) => !ie.dataRef.disabled);
|
|
740
|
+
R !== -1 && (h.activeOptionIndex = R);
|
|
741
|
+
}
|
|
742
|
+
let O = Qn(D === G.Specific ? { focus: G.Specific, id: S } : { focus: D }, { resolveItems: () => h.options, resolveActiveIndex: () => h.activeOptionIndex, resolveId: (R) => R.id, resolveDisabled: (R) => R.dataRef.disabled });
|
|
743
|
+
y.value = O, N.value = w ?? 1, r.value = h.options;
|
|
744
|
+
}, selectOption(D) {
|
|
745
|
+
let S = r.value.find((h) => h.id === D);
|
|
746
|
+
if (!S)
|
|
747
|
+
return;
|
|
748
|
+
let { dataRef: w } = S;
|
|
749
|
+
v(ne(g.value, { 0: () => w.value, 1: () => {
|
|
750
|
+
let h = P(L.value.value).slice(), O = P(w.value), R = h.findIndex((ie) => L.compare(O, P(ie)));
|
|
751
|
+
return R === -1 ? h.push(O) : h.splice(R, 1), h;
|
|
752
|
+
} }));
|
|
753
|
+
}, selectActiveOption() {
|
|
754
|
+
if (L.activeOptionIndex.value === null)
|
|
755
|
+
return;
|
|
756
|
+
let { dataRef: D, id: S } = r.value[L.activeOptionIndex.value];
|
|
757
|
+
v(ne(g.value, { 0: () => D.value, 1: () => {
|
|
758
|
+
let w = P(L.value.value).slice(), h = P(D.value), O = w.findIndex((R) => L.compare(h, P(R)));
|
|
759
|
+
return O === -1 ? w.push(h) : w.splice(O, 1), w;
|
|
760
|
+
} })), L.goToOption(G.Specific, S);
|
|
761
|
+
}, registerOption(D, S) {
|
|
762
|
+
let w = { id: D, dataRef: S }, h = z((O) => [...O, w]);
|
|
763
|
+
if (y.value === null) {
|
|
764
|
+
let O = S.value.value;
|
|
765
|
+
ne(g.value, { 0: () => L.compare(P(L.value.value), P(O)), 1: () => P(L.value.value).some((R) => L.compare(P(R), P(O))) }) && (h.activeOptionIndex = h.options.indexOf(w));
|
|
766
|
+
}
|
|
767
|
+
r.value = h.options, y.value = h.activeOptionIndex, N.value = 1, h.options.some((O) => !U(O.dataRef.domRef)) && requestAnimationFrame(() => {
|
|
768
|
+
let O = z();
|
|
769
|
+
r.value = O.options, y.value = O.activeOptionIndex;
|
|
770
|
+
});
|
|
771
|
+
}, unregisterOption(D) {
|
|
772
|
+
var S;
|
|
773
|
+
L.activeOptionIndex.value !== null && ((S = L.options.value[L.activeOptionIndex.value]) == null ? void 0 : S.id) === D && (I.value = !0);
|
|
774
|
+
let w = z((h) => {
|
|
775
|
+
let O = h.findIndex((R) => R.id === D);
|
|
776
|
+
return O !== -1 && h.splice(O, 1), h;
|
|
777
|
+
});
|
|
778
|
+
r.value = w.options, y.value = w.activeOptionIndex, N.value = 1;
|
|
779
|
+
} };
|
|
780
|
+
eo([i, p, u], () => L.closeCombobox(), b(() => o.value === 0)), Ue(et, L), Rn(b(() => ne(o.value, { 0: Le.Open, 1: Le.Closed })));
|
|
781
|
+
let B = b(() => L.activeOptionIndex.value === null ? null : r.value[L.activeOptionIndex.value].dataRef.value), ee = b(() => {
|
|
782
|
+
var D;
|
|
783
|
+
return (D = U(i)) == null ? void 0 : D.closest("form");
|
|
784
|
+
});
|
|
785
|
+
return _e(() => {
|
|
786
|
+
ce([ee], () => {
|
|
787
|
+
if (!ee.value || e.defaultValue === void 0)
|
|
788
|
+
return;
|
|
789
|
+
function D() {
|
|
790
|
+
L.change(e.defaultValue);
|
|
791
|
+
}
|
|
792
|
+
return ee.value.addEventListener("reset", D), () => {
|
|
793
|
+
var S;
|
|
794
|
+
(S = ee.value) == null || S.removeEventListener("reset", D);
|
|
795
|
+
};
|
|
796
|
+
}, { immediate: !0 });
|
|
797
|
+
}), () => {
|
|
798
|
+
let { name: D, disabled: S, form: w, ...h } = e, O = { open: o.value === 0, disabled: S, activeIndex: L.activeOptionIndex.value, activeOption: B.value, value: m.value };
|
|
799
|
+
return Te(q, [...D != null && m.value != null ? Je({ [D]: m.value }).map(([R, ie]) => Te(to, On({ features: He.Hidden, key: R, as: "input", type: "hidden", hidden: !0, readOnly: !0, form: w, name: R, value: ie }))) : [], pe({ theirProps: { ...n, ...xe(h, ["modelValue", "defaultValue", "nullable", "multiple", "onUpdate:modelValue", "by"]) }, ourProps: {}, slot: O, slots: s, attrs: n, name: "Combobox" })]);
|
|
800
|
+
};
|
|
801
|
+
} });
|
|
802
|
+
$({ name: "ComboboxLabel", props: { as: { type: [Object, String], default: "label" }, id: { type: String, default: () => `headlessui-combobox-label-${Ne()}` } }, setup(e, { attrs: s, slots: n }) {
|
|
803
|
+
let a = fe("ComboboxLabel");
|
|
804
|
+
function o() {
|
|
805
|
+
var l;
|
|
806
|
+
(l = U(a.inputRef)) == null || l.focus({ preventScroll: !0 });
|
|
807
|
+
}
|
|
808
|
+
return () => {
|
|
809
|
+
let l = { open: a.comboboxState.value === 0, disabled: a.disabled.value }, { id: i, ...p } = e, u = { id: i, ref: a.labelRef, onClick: o };
|
|
810
|
+
return pe({ ourProps: u, theirProps: p, slot: l, attrs: s, slots: n, name: "ComboboxLabel" });
|
|
811
|
+
};
|
|
812
|
+
} });
|
|
813
|
+
let po = $({ name: "ComboboxButton", props: { as: { type: [Object, String], default: "button" }, id: { type: String, default: () => `headlessui-combobox-button-${Ne()}` } }, setup(e, { attrs: s, slots: n, expose: a }) {
|
|
814
|
+
let o = fe("ComboboxButton");
|
|
815
|
+
a({ el: o.buttonRef, $el: o.buttonRef });
|
|
816
|
+
function l(u) {
|
|
817
|
+
o.disabled.value || (o.comboboxState.value === 0 ? o.closeCombobox() : (u.preventDefault(), o.openCombobox()), oe(() => {
|
|
818
|
+
var d;
|
|
819
|
+
return (d = U(o.inputRef)) == null ? void 0 : d.focus({ preventScroll: !0 });
|
|
820
|
+
}));
|
|
821
|
+
}
|
|
822
|
+
function i(u) {
|
|
823
|
+
switch (u.key) {
|
|
824
|
+
case K.ArrowDown:
|
|
825
|
+
u.preventDefault(), u.stopPropagation(), o.comboboxState.value === 1 && o.openCombobox(), oe(() => {
|
|
826
|
+
var d;
|
|
827
|
+
return (d = o.inputRef.value) == null ? void 0 : d.focus({ preventScroll: !0 });
|
|
828
|
+
});
|
|
829
|
+
return;
|
|
830
|
+
case K.ArrowUp:
|
|
831
|
+
u.preventDefault(), u.stopPropagation(), o.comboboxState.value === 1 && (o.openCombobox(), oe(() => {
|
|
832
|
+
o.value.value || o.goToOption(G.Last);
|
|
833
|
+
})), oe(() => {
|
|
834
|
+
var d;
|
|
835
|
+
return (d = o.inputRef.value) == null ? void 0 : d.focus({ preventScroll: !0 });
|
|
836
|
+
});
|
|
837
|
+
return;
|
|
838
|
+
case K.Escape:
|
|
839
|
+
if (o.comboboxState.value !== 0)
|
|
840
|
+
return;
|
|
841
|
+
u.preventDefault(), o.optionsRef.value && !o.optionsPropsRef.value.static && u.stopPropagation(), o.closeCombobox(), oe(() => {
|
|
842
|
+
var d;
|
|
843
|
+
return (d = o.inputRef.value) == null ? void 0 : d.focus({ preventScroll: !0 });
|
|
844
|
+
});
|
|
845
|
+
return;
|
|
846
|
+
}
|
|
847
|
+
}
|
|
848
|
+
let p = Pn(b(() => ({ as: e.as, type: s.type })), o.buttonRef);
|
|
849
|
+
return () => {
|
|
850
|
+
var u, d;
|
|
851
|
+
let r = { open: o.comboboxState.value === 0, disabled: o.disabled.value, value: o.value.value }, { id: y, ...N } = e, I = { ref: o.buttonRef, id: y, type: p.value, tabindex: "-1", "aria-haspopup": "listbox", "aria-controls": (u = U(o.optionsRef)) == null ? void 0 : u.id, "aria-expanded": o.disabled.value ? void 0 : o.comboboxState.value === 0, "aria-labelledby": o.labelRef.value ? [(d = U(o.labelRef)) == null ? void 0 : d.id, y].join(" ") : void 0, disabled: o.disabled.value === !0 ? !0 : void 0, onKeydown: i, onClick: l };
|
|
852
|
+
return pe({ ourProps: I, theirProps: N, slot: r, attrs: s, slots: n, name: "ComboboxButton" });
|
|
853
|
+
};
|
|
854
|
+
} }), _o = $({ name: "ComboboxInput", props: { as: { type: [Object, String], default: "input" }, static: { type: Boolean, default: !1 }, unmount: { type: Boolean, default: !0 }, displayValue: { type: Function }, defaultValue: { type: String, default: void 0 }, id: { type: String, default: () => `headlessui-combobox-input-${Ne()}` } }, emits: { change: (e) => !0 }, setup(e, { emit: s, attrs: n, slots: a, expose: o }) {
|
|
855
|
+
let l = fe("ComboboxInput"), i = { value: !1 };
|
|
856
|
+
o({ el: l.inputRef, $el: l.inputRef });
|
|
857
|
+
let p = b(() => {
|
|
858
|
+
var M;
|
|
859
|
+
let m = l.value.value;
|
|
860
|
+
return U(l.inputRef) ? typeof e.displayValue < "u" && m !== void 0 ? (M = e.displayValue(m)) != null ? M : "" : typeof m == "string" ? m : "" : "";
|
|
861
|
+
});
|
|
862
|
+
_e(() => {
|
|
863
|
+
ce([p, l.comboboxState], ([M, m], [v, L]) => {
|
|
864
|
+
if (i.value)
|
|
865
|
+
return;
|
|
866
|
+
let B = U(l.inputRef);
|
|
867
|
+
B && (L === 0 && m === 1 || M !== v) && (B.value = M);
|
|
868
|
+
}, { immediate: !0 }), ce([l.comboboxState], ([M], [m]) => {
|
|
869
|
+
if (M === 0 && m === 1) {
|
|
870
|
+
let v = U(l.inputRef);
|
|
871
|
+
if (!v)
|
|
872
|
+
return;
|
|
873
|
+
let L = v.value, { selectionStart: B, selectionEnd: ee, selectionDirection: D } = v;
|
|
874
|
+
v.value = "", v.value = L, D !== null ? v.setSelectionRange(B, ee, D) : v.setSelectionRange(B, ee);
|
|
875
|
+
}
|
|
876
|
+
});
|
|
877
|
+
});
|
|
878
|
+
let u = k(!1), d = k(null);
|
|
879
|
+
function r() {
|
|
880
|
+
u.value = !0;
|
|
881
|
+
}
|
|
882
|
+
function y() {
|
|
883
|
+
qe().nextFrame(() => {
|
|
884
|
+
u.value = !1, d.value && (l.openCombobox(), s("change", d.value), d.value = null);
|
|
885
|
+
});
|
|
886
|
+
}
|
|
887
|
+
function N(M) {
|
|
888
|
+
switch (i.value = !0, M.key) {
|
|
889
|
+
case K.Backspace:
|
|
890
|
+
case K.Delete:
|
|
891
|
+
if (l.mode.value !== 0 || !l.nullable.value)
|
|
892
|
+
return;
|
|
893
|
+
let m = M.currentTarget;
|
|
894
|
+
requestAnimationFrame(() => {
|
|
895
|
+
if (m.value === "") {
|
|
896
|
+
l.change(null);
|
|
897
|
+
let v = U(l.optionsRef);
|
|
898
|
+
v && (v.scrollTop = 0), l.goToOption(G.Nothing);
|
|
899
|
+
}
|
|
900
|
+
});
|
|
901
|
+
break;
|
|
902
|
+
case K.Enter:
|
|
903
|
+
if (i.value = !1, l.comboboxState.value !== 0 || u.value)
|
|
904
|
+
return;
|
|
905
|
+
if (M.preventDefault(), M.stopPropagation(), l.activeOptionIndex.value === null) {
|
|
906
|
+
l.closeCombobox();
|
|
907
|
+
return;
|
|
908
|
+
}
|
|
909
|
+
l.selectActiveOption(), l.mode.value === 0 && l.closeCombobox();
|
|
910
|
+
break;
|
|
911
|
+
case K.ArrowDown:
|
|
912
|
+
return i.value = !1, M.preventDefault(), M.stopPropagation(), ne(l.comboboxState.value, { 0: () => l.goToOption(G.Next), 1: () => l.openCombobox() });
|
|
913
|
+
case K.ArrowUp:
|
|
914
|
+
return i.value = !1, M.preventDefault(), M.stopPropagation(), ne(l.comboboxState.value, { 0: () => l.goToOption(G.Previous), 1: () => {
|
|
915
|
+
l.openCombobox(), oe(() => {
|
|
916
|
+
l.value.value || l.goToOption(G.Last);
|
|
917
|
+
});
|
|
918
|
+
} });
|
|
919
|
+
case K.Home:
|
|
920
|
+
if (M.shiftKey)
|
|
921
|
+
break;
|
|
922
|
+
return i.value = !1, M.preventDefault(), M.stopPropagation(), l.goToOption(G.First);
|
|
923
|
+
case K.PageUp:
|
|
924
|
+
return i.value = !1, M.preventDefault(), M.stopPropagation(), l.goToOption(G.First);
|
|
925
|
+
case K.End:
|
|
926
|
+
if (M.shiftKey)
|
|
927
|
+
break;
|
|
928
|
+
return i.value = !1, M.preventDefault(), M.stopPropagation(), l.goToOption(G.Last);
|
|
929
|
+
case K.PageDown:
|
|
930
|
+
return i.value = !1, M.preventDefault(), M.stopPropagation(), l.goToOption(G.Last);
|
|
931
|
+
case K.Escape:
|
|
932
|
+
if (i.value = !1, l.comboboxState.value !== 0)
|
|
933
|
+
return;
|
|
934
|
+
M.preventDefault(), l.optionsRef.value && !l.optionsPropsRef.value.static && M.stopPropagation(), l.closeCombobox();
|
|
935
|
+
break;
|
|
936
|
+
case K.Tab:
|
|
937
|
+
if (i.value = !1, l.comboboxState.value !== 0)
|
|
938
|
+
return;
|
|
939
|
+
l.mode.value === 0 && l.selectActiveOption(), l.closeCombobox();
|
|
940
|
+
break;
|
|
941
|
+
}
|
|
942
|
+
}
|
|
943
|
+
function I(M) {
|
|
944
|
+
if (u.value) {
|
|
945
|
+
d.value = M;
|
|
946
|
+
return;
|
|
947
|
+
}
|
|
948
|
+
l.openCombobox(), s("change", M);
|
|
949
|
+
}
|
|
950
|
+
function z() {
|
|
951
|
+
i.value = !1;
|
|
952
|
+
}
|
|
953
|
+
let g = b(() => {
|
|
954
|
+
var M, m, v, L;
|
|
955
|
+
return (L = (v = (m = e.defaultValue) != null ? m : l.defaultValue.value !== void 0 ? (M = e.displayValue) == null ? void 0 : M.call(e, l.defaultValue.value) : null) != null ? v : l.defaultValue.value) != null ? L : "";
|
|
956
|
+
});
|
|
957
|
+
return () => {
|
|
958
|
+
var M, m, v, L, B, ee;
|
|
959
|
+
let D = { open: l.comboboxState.value === 0 }, { id: S, displayValue: w, onChange: h, ...O } = e, R = { "aria-controls": (M = l.optionsRef.value) == null ? void 0 : M.id, "aria-expanded": l.disabled.value ? void 0 : l.comboboxState.value === 0, "aria-activedescendant": l.activeOptionIndex.value === null || (m = l.options.value[l.activeOptionIndex.value]) == null ? void 0 : m.id, "aria-labelledby": (B = (v = U(l.labelRef)) == null ? void 0 : v.id) != null ? B : (L = U(l.buttonRef)) == null ? void 0 : L.id, "aria-autocomplete": "list", id: S, onCompositionstart: r, onCompositionend: y, onKeydown: N, onInput: I, onBlur: z, role: "combobox", type: (ee = n.type) != null ? ee : "text", tabIndex: 0, ref: l.inputRef, defaultValue: g.value, disabled: l.disabled.value === !0 ? !0 : void 0 };
|
|
960
|
+
return pe({ ourProps: R, theirProps: O, slot: D, attrs: n, slots: a, features: ge.RenderStrategy | ge.Static, name: "ComboboxInput" });
|
|
961
|
+
};
|
|
962
|
+
} }), yo = $({ name: "ComboboxOptions", props: { as: { type: [Object, String], default: "ul" }, static: { type: Boolean, default: !1 }, unmount: { type: Boolean, default: !0 }, hold: { type: [Boolean], default: !1 } }, setup(e, { attrs: s, slots: n, expose: a }) {
|
|
963
|
+
let o = fe("ComboboxOptions"), l = `headlessui-combobox-options-${Ne()}`;
|
|
964
|
+
a({ el: o.optionsRef, $el: o.optionsRef }), ue(() => {
|
|
965
|
+
o.optionsPropsRef.value.static = e.static;
|
|
966
|
+
}), ue(() => {
|
|
967
|
+
o.optionsPropsRef.value.hold = e.hold;
|
|
968
|
+
});
|
|
969
|
+
let i = Un(), p = b(() => i !== null ? (i.value & Le.Open) === Le.Open : o.comboboxState.value === 0);
|
|
970
|
+
return Gn({ container: b(() => U(o.optionsRef)), enabled: b(() => o.comboboxState.value === 0), accept(u) {
|
|
971
|
+
return u.getAttribute("role") === "option" ? NodeFilter.FILTER_REJECT : u.hasAttribute("role") ? NodeFilter.FILTER_SKIP : NodeFilter.FILTER_ACCEPT;
|
|
972
|
+
}, walk(u) {
|
|
973
|
+
u.setAttribute("role", "none");
|
|
974
|
+
} }), () => {
|
|
975
|
+
var u, d, r;
|
|
976
|
+
let y = { open: o.comboboxState.value === 0 }, N = { "aria-labelledby": (r = (u = U(o.labelRef)) == null ? void 0 : u.id) != null ? r : (d = U(o.buttonRef)) == null ? void 0 : d.id, id: l, ref: o.optionsRef, role: "listbox", "aria-multiselectable": o.mode.value === 1 ? !0 : void 0 }, I = xe(e, ["hold"]);
|
|
977
|
+
return pe({ ourProps: N, theirProps: I, slot: y, attrs: s, slots: n, features: ge.RenderStrategy | ge.Static, visible: p.value, name: "ComboboxOptions" });
|
|
978
|
+
};
|
|
979
|
+
} }), fo = $({ name: "ComboboxOption", props: { as: { type: [Object, String], default: "li" }, value: { type: [Object, String, Number, Boolean] }, disabled: { type: Boolean, default: !1 } }, setup(e, { slots: s, attrs: n, expose: a }) {
|
|
980
|
+
let o = fe("ComboboxOption"), l = `headlessui-combobox-option-${Ne()}`, i = k(null);
|
|
981
|
+
a({ el: i, $el: i });
|
|
982
|
+
let p = b(() => o.activeOptionIndex.value !== null ? o.options.value[o.activeOptionIndex.value].id === l : !1), u = b(() => ne(o.mode.value, { 0: () => o.compare(P(o.value.value), P(e.value)), 1: () => P(o.value.value).some((M) => o.compare(P(M), P(e.value))) })), d = b(() => ({ disabled: e.disabled, value: e.value, domRef: i }));
|
|
983
|
+
_e(() => o.registerOption(l, d)), lt(() => o.unregisterOption(l)), ue(() => {
|
|
984
|
+
o.comboboxState.value === 0 && p.value && o.activationTrigger.value !== 0 && oe(() => {
|
|
985
|
+
var M, m;
|
|
986
|
+
return (m = (M = U(i)) == null ? void 0 : M.scrollIntoView) == null ? void 0 : m.call(M, { block: "nearest" });
|
|
987
|
+
});
|
|
988
|
+
});
|
|
989
|
+
function r(M) {
|
|
990
|
+
if (e.disabled)
|
|
991
|
+
return M.preventDefault();
|
|
992
|
+
o.selectOption(l), o.mode.value === 0 && o.closeCombobox(), lo() || requestAnimationFrame(() => {
|
|
993
|
+
var m;
|
|
994
|
+
return (m = U(o.inputRef)) == null ? void 0 : m.focus();
|
|
995
|
+
});
|
|
996
|
+
}
|
|
997
|
+
function y() {
|
|
998
|
+
if (e.disabled)
|
|
999
|
+
return o.goToOption(G.Nothing);
|
|
1000
|
+
o.goToOption(G.Specific, l);
|
|
1001
|
+
}
|
|
1002
|
+
let N = oo();
|
|
1003
|
+
function I(M) {
|
|
1004
|
+
N.update(M);
|
|
1005
|
+
}
|
|
1006
|
+
function z(M) {
|
|
1007
|
+
N.wasMoved(M) && (e.disabled || p.value || o.goToOption(G.Specific, l, 0));
|
|
1008
|
+
}
|
|
1009
|
+
function g(M) {
|
|
1010
|
+
N.wasMoved(M) && (e.disabled || p.value && (o.optionsPropsRef.value.hold || o.goToOption(G.Nothing)));
|
|
1011
|
+
}
|
|
1012
|
+
return () => {
|
|
1013
|
+
let { disabled: M } = e, m = { active: p.value, selected: u.value, disabled: M }, v = { id: l, ref: i, role: "option", tabIndex: M === !0 ? void 0 : -1, "aria-disabled": M === !0 ? !0 : void 0, "aria-selected": u.value, disabled: void 0, onClick: r, onFocus: y, onPointerenter: I, onMouseenter: I, onPointermove: z, onMousemove: z, onPointerleave: g, onMouseleave: g };
|
|
1014
|
+
return pe({ ourProps: v, theirProps: e, slot: m, attrs: n, slots: s, name: "ComboboxOption" });
|
|
1015
|
+
};
|
|
1016
|
+
} });
|
|
1017
|
+
const jo = { class: "flex items-center shrink-0" }, vo = /* @__PURE__ */ x("legend", null, null, -1), go = [
|
|
1018
|
+
vo
|
|
1019
|
+
], Lo = { class: "flex items-center shrink-0" }, No = {
|
|
1020
|
+
key: 0,
|
|
1021
|
+
class: "details pt-1"
|
|
1022
|
+
}, bo = {
|
|
1023
|
+
key: 0,
|
|
1024
|
+
class: "text-rui-error text-caption"
|
|
1025
|
+
}, mo = {
|
|
1026
|
+
key: 1,
|
|
1027
|
+
class: "text-rui-text-secondary text-caption"
|
|
1028
|
+
}, To = {
|
|
1029
|
+
key: 2,
|
|
1030
|
+
class: "h-5"
|
|
1031
|
+
}, Do = /* @__PURE__ */ $({
|
|
1032
|
+
name: "RuiTextField",
|
|
1033
|
+
__name: "TextField",
|
|
1034
|
+
props: {
|
|
1035
|
+
modelValue: { default: "" },
|
|
1036
|
+
label: { default: "" },
|
|
1037
|
+
placeholder: { default: "" },
|
|
1038
|
+
disabled: { type: Boolean, default: !1 },
|
|
1039
|
+
variant: { default: "default" },
|
|
1040
|
+
color: { default: "grey" },
|
|
1041
|
+
dense: { type: Boolean, default: !1 },
|
|
1042
|
+
hint: { default: "" },
|
|
1043
|
+
as: { default: "input" },
|
|
1044
|
+
errorMessages: { default: () => [] },
|
|
1045
|
+
hideDetails: { type: Boolean, default: !1 },
|
|
1046
|
+
prependIcon: { default: "" },
|
|
1047
|
+
appendIcon: { default: "" }
|
|
1048
|
+
},
|
|
1049
|
+
emits: ["update:modelValue", "focus-input", "blur", "remove"],
|
|
1050
|
+
setup(e, { emit: s }) {
|
|
1051
|
+
const n = e;
|
|
1052
|
+
ze((v) => ({
|
|
1053
|
+
"7472fb32": t(I),
|
|
1054
|
+
"5914c95d": t(z),
|
|
1055
|
+
"1c99e6de": t(l)
|
|
1056
|
+
}));
|
|
1057
|
+
const { label: a } = se(n), o = (v) => {
|
|
1058
|
+
const L = v.target.value;
|
|
1059
|
+
s("update:modelValue", L);
|
|
1060
|
+
}, l = b(() => _(a) ? `' ${_(a)} '` : '"\\200B"'), i = k(), p = k(), { left: u, right: d } = je(i), {
|
|
1061
|
+
left: r,
|
|
1062
|
+
right: y,
|
|
1063
|
+
width: N
|
|
1064
|
+
} = je(p), I = b(
|
|
1065
|
+
() => `${_(r) - _(u)}px`
|
|
1066
|
+
), z = b(
|
|
1067
|
+
() => `${_(d) - _(y)}px`
|
|
1068
|
+
), g = Z(), M = Me(), m = ye();
|
|
1069
|
+
return (v, L) => (c(), f("div", {
|
|
1070
|
+
class: j(t(M).class)
|
|
1071
|
+
}, [
|
|
1072
|
+
x("div", {
|
|
1073
|
+
ref_key: "wrapper",
|
|
1074
|
+
ref: i,
|
|
1075
|
+
class: j([
|
|
1076
|
+
t(g).wrapper,
|
|
1077
|
+
t(g)[v.color],
|
|
1078
|
+
t(g)[v.variant],
|
|
1079
|
+
{
|
|
1080
|
+
[t(g).dense]: v.dense,
|
|
1081
|
+
[t(g)["with-error"]]: v.errorMessages.length > 0,
|
|
1082
|
+
[t(g)["no-label"]]: !t(a)
|
|
1083
|
+
}
|
|
1084
|
+
])
|
|
1085
|
+
}, [
|
|
1086
|
+
x("div", jo, [
|
|
1087
|
+
t(m).prepend ? (c(), f("div", {
|
|
1088
|
+
key: 0,
|
|
1089
|
+
class: j(t(g).prepend)
|
|
1090
|
+
}, [
|
|
1091
|
+
te(v.$slots, "prepend")
|
|
1092
|
+
], 2)) : v.prependIcon ? (c(), f("div", {
|
|
1093
|
+
key: 1,
|
|
1094
|
+
class: j([t(g).icon, t(g).prepend])
|
|
1095
|
+
}, [
|
|
1096
|
+
Q(C, { name: v.prependIcon }, null, 8, ["name"])
|
|
1097
|
+
], 2)) : E("", !0)
|
|
1098
|
+
]),
|
|
1099
|
+
x("div", {
|
|
1100
|
+
ref_key: "innerWrapper",
|
|
1101
|
+
ref: p,
|
|
1102
|
+
class: "flex flex-1 overflow-hidden",
|
|
1103
|
+
onClick: L[3] || (L[3] = (B) => s("focus-input", B))
|
|
1104
|
+
}, [
|
|
1105
|
+
(c(), Y(he(v.as), le({
|
|
1106
|
+
value: v.modelValue,
|
|
1107
|
+
placeholder: v.placeholder || " ",
|
|
1108
|
+
class: t(g).input,
|
|
1109
|
+
disabled: v.disabled,
|
|
1110
|
+
dense: v.dense,
|
|
1111
|
+
variant: v.variant,
|
|
1112
|
+
"wrapper-width": t(N)
|
|
1113
|
+
}, t(be)(t(M), ["class"]), {
|
|
1114
|
+
onInput: L[0] || (L[0] = (B) => o(B)),
|
|
1115
|
+
onBlur: L[1] || (L[1] = (B) => s("blur", B)),
|
|
1116
|
+
onRemove: L[2] || (L[2] = (B) => s("remove", B))
|
|
1117
|
+
}), null, 16, ["value", "placeholder", "class", "disabled", "dense", "variant", "wrapper-width"])),
|
|
1118
|
+
x("label", {
|
|
1119
|
+
class: j(t(g).label)
|
|
1120
|
+
}, V(t(a)), 3),
|
|
1121
|
+
v.variant === "outlined" ? (c(), f("fieldset", {
|
|
1122
|
+
key: 0,
|
|
1123
|
+
class: j(t(g).fieldset)
|
|
1124
|
+
}, go, 2)) : E("", !0)
|
|
1125
|
+
], 512),
|
|
1126
|
+
x("div", Lo, [
|
|
1127
|
+
t(m).append ? (c(), f("div", {
|
|
1128
|
+
key: 0,
|
|
1129
|
+
class: j(t(g).append)
|
|
1130
|
+
}, [
|
|
1131
|
+
te(v.$slots, "append")
|
|
1132
|
+
], 2)) : v.appendIcon ? (c(), f("div", {
|
|
1133
|
+
key: 1,
|
|
1134
|
+
class: j([t(g).icon, t(g).append])
|
|
1135
|
+
}, [
|
|
1136
|
+
Q(C, { name: v.appendIcon }, null, 8, ["name"])
|
|
1137
|
+
], 2)) : E("", !0)
|
|
1138
|
+
])
|
|
1139
|
+
], 2),
|
|
1140
|
+
v.hideDetails ? E("", !0) : (c(), f("div", No, [
|
|
1141
|
+
v.errorMessages.length > 0 ? (c(), f("div", bo, V(v.errorMessages[0]), 1)) : v.hint ? (c(), f("div", mo, V(v.hint), 1)) : (c(), f("div", To))
|
|
1142
|
+
]))
|
|
1143
|
+
], 2));
|
|
1144
|
+
}
|
|
1145
|
+
}), Io = "_wrapper_mt8jw_316", zo = "_label_mt8jw_316", ho = "_icon_mt8jw_322", xo = "_filled_mt8jw_325", So = "_input_mt8jw_325", Ao = "_outlined_mt8jw_331", wo = "_fieldset_mt8jw_331", ko = "_prepend_mt8jw_380", Oo = "_append_mt8jw_383", Eo = "_primary_mt8jw_386", Co = "_secondary_mt8jw_395", $o = "_error_mt8jw_404", Yo = "_warning_mt8jw_413", Qo = "_info_mt8jw_422", Uo = "_success_mt8jw_431", Ro = "_dense_mt8jw_449", Po = {
|
|
1146
|
+
wrapper: Io,
|
|
1147
|
+
label: zo,
|
|
1148
|
+
icon: ho,
|
|
1149
|
+
filled: xo,
|
|
1150
|
+
input: So,
|
|
1151
|
+
outlined: Ao,
|
|
1152
|
+
fieldset: wo,
|
|
1153
|
+
prepend: ko,
|
|
1154
|
+
append: Oo,
|
|
1155
|
+
primary: Eo,
|
|
1156
|
+
secondary: Co,
|
|
1157
|
+
error: $o,
|
|
1158
|
+
warning: Yo,
|
|
1159
|
+
info: Qo,
|
|
1160
|
+
success: Uo,
|
|
1161
|
+
"with-error": "_with-error_mt8jw_440",
|
|
1162
|
+
dense: Ro,
|
|
1163
|
+
"no-label": "_no-label_mt8jw_494",
|
|
1164
|
+
"bg-tint": "_bg-tint_mt8jw_1",
|
|
1165
|
+
"bg-shade": "_bg-shade_mt8jw_1",
|
|
1166
|
+
"text-tint": "_text-tint_mt8jw_1",
|
|
1167
|
+
"text-shade": "_text-shade_mt8jw_1"
|
|
1168
|
+
}, Vo = {
|
|
1169
|
+
$style: Po
|
|
1170
|
+
}, tt = /* @__PURE__ */ H(Do, [["__cssModules", Vo]]), Bo = ["disabled"], Fo = /* @__PURE__ */ $({
|
|
1171
|
+
name: "RuiChip",
|
|
1172
|
+
__name: "Chip",
|
|
1173
|
+
props: {
|
|
1174
|
+
label: {},
|
|
1175
|
+
dismissible: { type: Boolean, default: !1 },
|
|
1176
|
+
disabled: { type: Boolean, default: !1 },
|
|
1177
|
+
size: { default: "md" },
|
|
1178
|
+
variant: { default: "filled" },
|
|
1179
|
+
color: { default: "grey" }
|
|
1180
|
+
},
|
|
1181
|
+
emits: ["remove"],
|
|
1182
|
+
setup(e, { emit: s }) {
|
|
1183
|
+
const n = Z(), a = ye();
|
|
1184
|
+
return (o, l) => (c(), f("div", {
|
|
1185
|
+
class: j([
|
|
1186
|
+
t(n).chip,
|
|
1187
|
+
t(n)[o.color ?? ""],
|
|
1188
|
+
t(n)[o.size ?? ""],
|
|
1189
|
+
t(n)[o.variant ?? ""],
|
|
1190
|
+
{ [t(n).disabled]: o.disabled }
|
|
1191
|
+
]),
|
|
1192
|
+
role: "button",
|
|
1193
|
+
tabindex: "0"
|
|
1194
|
+
}, [
|
|
1195
|
+
t(a).prepend ? (c(), f("div", {
|
|
1196
|
+
key: 0,
|
|
1197
|
+
class: j(t(n).chip__prepend)
|
|
1198
|
+
}, [
|
|
1199
|
+
te(o.$slots, "prepend")
|
|
1200
|
+
], 2)) : E("", !0),
|
|
1201
|
+
x("span", {
|
|
1202
|
+
class: j(t(n).chip__label)
|
|
1203
|
+
}, V(o.label), 3),
|
|
1204
|
+
o.dismissible ? (c(), f("button", {
|
|
1205
|
+
key: 1,
|
|
1206
|
+
class: j(t(n).chip__close),
|
|
1207
|
+
disabled: o.disabled,
|
|
1208
|
+
onClick: l[0] || (l[0] = Re((i) => s("remove"), ["stop"]))
|
|
1209
|
+
}, [
|
|
1210
|
+
Q(C, {
|
|
1211
|
+
class: j(t(n).chip__close_icon),
|
|
1212
|
+
size: o.size === "sm" ? 16 : 24,
|
|
1213
|
+
name: "close-circle-line"
|
|
1214
|
+
}, null, 8, ["class", "size"])
|
|
1215
|
+
], 10, Bo)) : E("", !0)
|
|
1216
|
+
], 2));
|
|
1217
|
+
}
|
|
1218
|
+
}), Go = "_chip_tuzt7_315", Wo = "_grey_tuzt7_319", Zo = "_filled_tuzt7_322", Ho = "_outlined_tuzt7_325", Jo = "_primary_tuzt7_328", Ko = "_secondary_tuzt7_334", Xo = "_error_tuzt7_340", qo = "_warning_tuzt7_346", es = "_info_tuzt7_352", ts = "_success_tuzt7_358", ns = "_chip__prepend_tuzt7_364", os = "_chip__label_tuzt7_368", ss = "_chip__close_tuzt7_371", as = "_chip__close_icon_tuzt7_375", ls = "_md_tuzt7_378", is = "_sm_tuzt7_381", rs = "_sm__prepend_tuzt7_384", us = "_sm__label_tuzt7_387", cs = "_sm__close_tuzt7_390", ds = "_disabled_tuzt7_395", Ms = {
|
|
1219
|
+
chip: Go,
|
|
1220
|
+
grey: Wo,
|
|
1221
|
+
filled: Zo,
|
|
1222
|
+
outlined: Ho,
|
|
1223
|
+
primary: Jo,
|
|
1224
|
+
secondary: Ko,
|
|
1225
|
+
error: Xo,
|
|
1226
|
+
warning: qo,
|
|
1227
|
+
info: es,
|
|
1228
|
+
success: ts,
|
|
1229
|
+
chip__prepend: ns,
|
|
1230
|
+
chip__label: os,
|
|
1231
|
+
chip__close: ss,
|
|
1232
|
+
chip__close_icon: as,
|
|
1233
|
+
md: ls,
|
|
1234
|
+
sm: is,
|
|
1235
|
+
sm__prepend: rs,
|
|
1236
|
+
sm__label: us,
|
|
1237
|
+
sm__close: cs,
|
|
1238
|
+
disabled: ds,
|
|
1239
|
+
"bg-tint": "_bg-tint_tuzt7_1",
|
|
1240
|
+
"bg-shade": "_bg-shade_tuzt7_1",
|
|
1241
|
+
"text-tint": "_text-tint_tuzt7_1",
|
|
1242
|
+
"text-shade": "_text-shade_tuzt7_1"
|
|
1243
|
+
}, ps = {
|
|
1244
|
+
$style: Ms
|
|
1245
|
+
}, Ce = /* @__PURE__ */ H(Fo, [["__cssModules", ps]]), _s = /* @__PURE__ */ $({
|
|
1246
|
+
__name: "AutoCompleteSelection",
|
|
1247
|
+
props: {
|
|
1248
|
+
data: {},
|
|
1249
|
+
hasValue: { type: Boolean },
|
|
1250
|
+
wrapperWidth: {},
|
|
1251
|
+
textProp: { default: "text" },
|
|
1252
|
+
keyProp: { default: "id" },
|
|
1253
|
+
dense: { type: Boolean, default: !1 },
|
|
1254
|
+
itemDisabledProp: { default: "" },
|
|
1255
|
+
variant: {}
|
|
1256
|
+
},
|
|
1257
|
+
emits: ["remove"],
|
|
1258
|
+
setup(e, { emit: s }) {
|
|
1259
|
+
const n = e;
|
|
1260
|
+
ze((M) => ({
|
|
1261
|
+
"0f128096": t(r)
|
|
1262
|
+
}));
|
|
1263
|
+
const a = Z(), o = Me(), { data: l, textProp: i, wrapperWidth: p } = se(n), u = k(), d = k(), r = k(120), y = k(0), N = b(() => Array.isArray(_(l))), I = b(() => {
|
|
1264
|
+
const M = _(l);
|
|
1265
|
+
if (!(Array.isArray(M) || !M))
|
|
1266
|
+
return M[_(i)];
|
|
1267
|
+
}), z = b(() => _(p) - _(r)), g = async () => {
|
|
1268
|
+
const M = _(l);
|
|
1269
|
+
if (!Array.isArray(M) || M.length === 0) {
|
|
1270
|
+
ae(y, 0);
|
|
1271
|
+
return;
|
|
1272
|
+
}
|
|
1273
|
+
const m = M.length - _(y);
|
|
1274
|
+
if (m <= 0) {
|
|
1275
|
+
ae(y, _(y) + m);
|
|
1276
|
+
return;
|
|
1277
|
+
}
|
|
1278
|
+
const v = _(je(d).width);
|
|
1279
|
+
if (_(z) < v) {
|
|
1280
|
+
ae(y, 0), ae(r, _(p) - v);
|
|
1281
|
+
return;
|
|
1282
|
+
}
|
|
1283
|
+
for (let L = 0; L < m; L++)
|
|
1284
|
+
if (ae(y, _(y) + 1), await oe(), _(je(u).width) > _(z)) {
|
|
1285
|
+
ae(y, _(y) - 1), await oe(), _(je(u).width) > _(z) && ae(y, _(y) - 1);
|
|
1286
|
+
break;
|
|
1287
|
+
}
|
|
1288
|
+
};
|
|
1289
|
+
return _e(async () => {
|
|
1290
|
+
oe(() => {
|
|
1291
|
+
g();
|
|
1292
|
+
}).catch();
|
|
1293
|
+
}), ce([l, p], () => {
|
|
1294
|
+
g();
|
|
1295
|
+
}), (M, m) => {
|
|
1296
|
+
var v;
|
|
1297
|
+
return c(), f(q, null, [
|
|
1298
|
+
t(N) && ((v = t(l)) != null && v.length) ? (c(), f("div", {
|
|
1299
|
+
key: 0,
|
|
1300
|
+
ref_key: "innerWrapper",
|
|
1301
|
+
ref: u,
|
|
1302
|
+
class: j(t(a).wrapper)
|
|
1303
|
+
}, [
|
|
1304
|
+
x("div", {
|
|
1305
|
+
class: j(t(a).chips_wrapper)
|
|
1306
|
+
}, [
|
|
1307
|
+
x("div", {
|
|
1308
|
+
class: j([t(a).chips, t(a)[M.variant ?? ""]])
|
|
1309
|
+
}, [
|
|
1310
|
+
(c(!0), f(q, null, de(t(l).slice(0, t(y)), (L) => (c(), Y(Ce, {
|
|
1311
|
+
key: L[M.keyProp],
|
|
1312
|
+
class: j(t(a).chip),
|
|
1313
|
+
disabled: !!M.itemDisabledProp && L[M.itemDisabledProp],
|
|
1314
|
+
label: L[t(i)] ?? "",
|
|
1315
|
+
size: M.dense ? "sm" : "md",
|
|
1316
|
+
dismissible: "",
|
|
1317
|
+
onRemove: (B) => s("remove", L)
|
|
1318
|
+
}, null, 8, ["class", "disabled", "label", "size", "onRemove"]))), 128)),
|
|
1319
|
+
t(l).length > t(y) ? (c(), f("div", {
|
|
1320
|
+
key: 0,
|
|
1321
|
+
ref_key: "more",
|
|
1322
|
+
ref: d,
|
|
1323
|
+
class: j(t(a).remaining)
|
|
1324
|
+
}, [
|
|
1325
|
+
Q(Ce, {
|
|
1326
|
+
class: j(t(a).chip),
|
|
1327
|
+
label: `+${t(l).length - t(y)}`,
|
|
1328
|
+
size: M.dense ? "sm" : "md",
|
|
1329
|
+
color: "secondary"
|
|
1330
|
+
}, null, 8, ["class", "label", "size"])
|
|
1331
|
+
], 2)) : E("", !0)
|
|
1332
|
+
], 2)
|
|
1333
|
+
], 2)
|
|
1334
|
+
], 2)) : E("", !0),
|
|
1335
|
+
Q(t(_o), le({
|
|
1336
|
+
class: [
|
|
1337
|
+
t(a).input,
|
|
1338
|
+
t(a)[M.variant ?? ""],
|
|
1339
|
+
{ [t(a).multiple]: t(N), [t(a).has_value]: M.hasValue }
|
|
1340
|
+
],
|
|
1341
|
+
"data-has-value": M.hasValue,
|
|
1342
|
+
"display-value": (L) => t(I)
|
|
1343
|
+
}, t(be)(t(o), ["value", "dense"])), null, 16, ["class", "data-has-value", "display-value"])
|
|
1344
|
+
], 64);
|
|
1345
|
+
};
|
|
1346
|
+
}
|
|
1347
|
+
}), ys = "_wrapper_1mrdp_1", fs = "_chips_wrapper_1mrdp_4", js = "_chips_1mrdp_4", vs = "_filled_1mrdp_13", gs = "_outlined_1mrdp_16", Ls = "_input_1mrdp_20", Ns = "_multiple_1mrdp_27", bs = "_has_value_1mrdp_27", ms = {
|
|
1348
|
+
wrapper: ys,
|
|
1349
|
+
chips_wrapper: fs,
|
|
1350
|
+
chips: js,
|
|
1351
|
+
default: "_default_1mrdp_10",
|
|
1352
|
+
filled: vs,
|
|
1353
|
+
outlined: gs,
|
|
1354
|
+
input: Ls,
|
|
1355
|
+
multiple: Ns,
|
|
1356
|
+
has_value: bs
|
|
1357
|
+
}, Ts = {
|
|
1358
|
+
$style: ms
|
|
1359
|
+
}, Ds = /* @__PURE__ */ H(_s, [["__cssModules", Ts]]), Is = { class: "relative" }, zs = { class: "flex space-x-1 items-center" }, hs = ["disabled"], xs = { class: "block truncate" }, Ss = /* @__PURE__ */ $({
|
|
1360
|
+
name: "RuiAutoComplete",
|
|
1361
|
+
__name: "AutoComplete",
|
|
1362
|
+
props: {
|
|
1363
|
+
data: {},
|
|
1364
|
+
modelValue: {},
|
|
1365
|
+
nullable: { type: Boolean, default: !1 },
|
|
1366
|
+
disabled: { type: Boolean, default: !1 },
|
|
1367
|
+
searchQuery: { default: "" },
|
|
1368
|
+
searchProp: { default: "" },
|
|
1369
|
+
placeholder: { default: "" },
|
|
1370
|
+
label: { default: "" },
|
|
1371
|
+
keyProp: { default: "id" },
|
|
1372
|
+
textProp: { default: "text" },
|
|
1373
|
+
itemDisabledProp: { default: "disabled" },
|
|
1374
|
+
variant: { default: "default" },
|
|
1375
|
+
color: { default: "grey" },
|
|
1376
|
+
dense: { type: Boolean, default: !1 },
|
|
1377
|
+
hint: { default: "" },
|
|
1378
|
+
errorMessages: { default: () => [] }
|
|
1379
|
+
},
|
|
1380
|
+
emits: ["update:modelValue"],
|
|
1381
|
+
setup(e, { emit: s }) {
|
|
1382
|
+
const n = e, a = Z(), o = ye(), {
|
|
1383
|
+
data: l,
|
|
1384
|
+
modelValue: i,
|
|
1385
|
+
searchQuery: p,
|
|
1386
|
+
searchProp: u,
|
|
1387
|
+
textProp: d,
|
|
1388
|
+
keyProp: r,
|
|
1389
|
+
itemDisabledProp: y,
|
|
1390
|
+
hint: N,
|
|
1391
|
+
errorMessages: I
|
|
1392
|
+
} = se(n), z = k(_(p) ?? ""), g = k(), M = b(() => {
|
|
1393
|
+
var F;
|
|
1394
|
+
const T = (F = _(z)) == null ? void 0 : F.toLowerCase(), A = _(u), J = _(d);
|
|
1395
|
+
return T ? _(l).filter((re) => A ? re[J].toLowerCase().includes(T) || re[A].toLowerCase().includes(T) : re[J].toLowerCase().includes(T)) : _(l);
|
|
1396
|
+
}), m = b(() => Array.isArray(_(i))), v = b(() => {
|
|
1397
|
+
var A;
|
|
1398
|
+
const T = _(i);
|
|
1399
|
+
return Array.isArray(T) ? !!((A = _(T)) != null && A.length) : !!T;
|
|
1400
|
+
}), L = b(() => {
|
|
1401
|
+
var T;
|
|
1402
|
+
return !(_(N) || (T = _(I)) != null && T.length);
|
|
1403
|
+
}), B = (T) => {
|
|
1404
|
+
const A = _(i);
|
|
1405
|
+
(!(T && A) || T !== A) && s("update:modelValue", T);
|
|
1406
|
+
}, ee = (T) => {
|
|
1407
|
+
ae(z, T);
|
|
1408
|
+
}, D = () => {
|
|
1409
|
+
var T, A;
|
|
1410
|
+
(A = (T = _(g)) == null ? void 0 : T.el) == null || A.click();
|
|
1411
|
+
}, S = () => {
|
|
1412
|
+
s("update:modelValue", _(m) ? [] : null), ee("");
|
|
1413
|
+
}, w = (T) => {
|
|
1414
|
+
const A = _(i);
|
|
1415
|
+
if (!_(m) || !Array.isArray(A))
|
|
1416
|
+
return;
|
|
1417
|
+
const J = _(r);
|
|
1418
|
+
s(
|
|
1419
|
+
"update:modelValue",
|
|
1420
|
+
A.filter((F) => F[J] !== T[J])
|
|
1421
|
+
);
|
|
1422
|
+
};
|
|
1423
|
+
ce(m, (T) => {
|
|
1424
|
+
const A = _(i);
|
|
1425
|
+
T ? s("update:modelValue", _(v) ? [A] : []) : Array.isArray(A) ? s("update:modelValue", A[0] ?? null) : s("update:modelValue", null);
|
|
1426
|
+
});
|
|
1427
|
+
const { list: h, containerProps: O, wrapperProps: R, scrollTo: ie } = ct(
|
|
1428
|
+
M,
|
|
1429
|
+
{
|
|
1430
|
+
itemHeight: 40,
|
|
1431
|
+
overscan: 1
|
|
1432
|
+
}
|
|
1433
|
+
);
|
|
1434
|
+
ce(M, () => {
|
|
1435
|
+
ie(0);
|
|
1436
|
+
});
|
|
1437
|
+
const nt = dt(h, ({ data: T }) => T), ot = (T) => {
|
|
1438
|
+
if (!T && _(v)) {
|
|
1439
|
+
const A = _(i), J = _(r), F = Array.isArray(A) ? A[A.length - 1][J] : A[J];
|
|
1440
|
+
oe(() => {
|
|
1441
|
+
ie(_(M).findIndex((re) => re[J] === F));
|
|
1442
|
+
});
|
|
1443
|
+
}
|
|
1444
|
+
};
|
|
1445
|
+
return (T, A) => (c(), f("div", {
|
|
1446
|
+
class: j([t(m) ? t(a).multiple : t(a).single, t(a)[T.variant ?? ""]])
|
|
1447
|
+
}, [
|
|
1448
|
+
Q(t(Mo), {
|
|
1449
|
+
by: t(r),
|
|
1450
|
+
class: j([
|
|
1451
|
+
{
|
|
1452
|
+
[t(a).disabled]: T.disabled,
|
|
1453
|
+
[t(a).has_details]: !t(L)
|
|
1454
|
+
}
|
|
1455
|
+
]),
|
|
1456
|
+
disabled: T.disabled,
|
|
1457
|
+
"model-value": t(i),
|
|
1458
|
+
multiple: t(m),
|
|
1459
|
+
nullable: T.nullable,
|
|
1460
|
+
"onUpdate:modelValue": A[4] || (A[4] = (J) => B(J))
|
|
1461
|
+
}, {
|
|
1462
|
+
default: X(({ open: J }) => [
|
|
1463
|
+
x("div", Is, [
|
|
1464
|
+
Q(tt, {
|
|
1465
|
+
modelValue: t(z),
|
|
1466
|
+
"onUpdate:modelValue": A[1] || (A[1] = (F) => it(z) ? z.value = F : null),
|
|
1467
|
+
as: Ds,
|
|
1468
|
+
color: T.color,
|
|
1469
|
+
data: t(i),
|
|
1470
|
+
dense: T.dense,
|
|
1471
|
+
disabled: T.disabled,
|
|
1472
|
+
"error-messages": t(I),
|
|
1473
|
+
"has-value": t(v),
|
|
1474
|
+
"hide-details": t(L),
|
|
1475
|
+
hint: t(N),
|
|
1476
|
+
"item-disabled-prop": t(y),
|
|
1477
|
+
"key-prop": t(r),
|
|
1478
|
+
label: T.label,
|
|
1479
|
+
placeholder: T.placeholder,
|
|
1480
|
+
"text-prop": t(d),
|
|
1481
|
+
variant: T.variant,
|
|
1482
|
+
onRemove: A[2] || (A[2] = (F) => w(F)),
|
|
1483
|
+
onFocusInput: (F) => !J && D()
|
|
1484
|
+
}, {
|
|
1485
|
+
append: X(() => [
|
|
1486
|
+
x("div", zs, [
|
|
1487
|
+
T.nullable && t(v) ? (c(), f("button", {
|
|
1488
|
+
key: 0,
|
|
1489
|
+
class: j(t(a).clear_button),
|
|
1490
|
+
disabled: T.disabled,
|
|
1491
|
+
tabindex: "-1",
|
|
1492
|
+
type: "button",
|
|
1493
|
+
onClick: A[0] || (A[0] = Re((F) => S(), ["prevent", "stop"]))
|
|
1494
|
+
}, [
|
|
1495
|
+
Q(C, {
|
|
1496
|
+
class: j(t(a).clear_icon),
|
|
1497
|
+
name: "close-line"
|
|
1498
|
+
}, null, 8, ["class"])
|
|
1499
|
+
], 10, hs)) : E("", !0),
|
|
1500
|
+
Q(t(po), {
|
|
1501
|
+
ref_key: "button",
|
|
1502
|
+
ref: g,
|
|
1503
|
+
class: j([{ [t(a).toggle_disabled]: T.disabled }]),
|
|
1504
|
+
disabled: T.disabled,
|
|
1505
|
+
onClick: (F) => ot(J)
|
|
1506
|
+
}, {
|
|
1507
|
+
default: X(() => [
|
|
1508
|
+
Q(C, {
|
|
1509
|
+
class: j([t(a).toggle_icon, { "rotate-180": J }]),
|
|
1510
|
+
name: "arrow-drop-down-fill"
|
|
1511
|
+
}, null, 8, ["class"])
|
|
1512
|
+
]),
|
|
1513
|
+
_: 2
|
|
1514
|
+
}, 1032, ["class", "disabled", "onClick"])
|
|
1515
|
+
])
|
|
1516
|
+
]),
|
|
1517
|
+
_: 2
|
|
1518
|
+
}, 1032, ["modelValue", "color", "data", "dense", "disabled", "error-messages", "has-value", "hide-details", "hint", "item-disabled-prop", "key-prop", "label", "placeholder", "text-prop", "variant", "onFocusInput"]),
|
|
1519
|
+
Q(rt, {
|
|
1520
|
+
"enter-active-class": "transition duration-100 ease-out",
|
|
1521
|
+
"enter-from-class": "transform scale-95 opacity-0",
|
|
1522
|
+
"enter-to-class": "transform scale-100 opacity-100",
|
|
1523
|
+
"leave-active-class": "transition duration-75 ease-out",
|
|
1524
|
+
"leave-from-class": "transform scale-100 opacity-100",
|
|
1525
|
+
"leave-to-class": "transform scale-95 opacity-0",
|
|
1526
|
+
onAfterLeave: A[3] || (A[3] = (F) => ee(""))
|
|
1527
|
+
}, {
|
|
1528
|
+
default: X(() => [
|
|
1529
|
+
Q(t(yo), {
|
|
1530
|
+
class: j(t(a).options)
|
|
1531
|
+
}, {
|
|
1532
|
+
default: X(() => [
|
|
1533
|
+
t(M).length === 0 && t(z) !== "" ? (c(), f("div", {
|
|
1534
|
+
key: 0,
|
|
1535
|
+
class: j(t(a).empty)
|
|
1536
|
+
}, " Nothing options found. ", 2)) : (c(), f("div", le({ key: 1 }, t(O), { class: "max-h-60" }), [
|
|
1537
|
+
x("div", De(Pe(t(R))), [
|
|
1538
|
+
(c(!0), f(q, null, de(t(nt), (F) => (c(), Y(t(fo), {
|
|
1539
|
+
key: F[t(r)],
|
|
1540
|
+
class: "h-10",
|
|
1541
|
+
disabled: !!t(y) && F[t(y)],
|
|
1542
|
+
value: F,
|
|
1543
|
+
as: "template"
|
|
1544
|
+
}, {
|
|
1545
|
+
default: X(({ selected: re, disabled: st }) => [
|
|
1546
|
+
x("li", {
|
|
1547
|
+
class: j([
|
|
1548
|
+
t(a).option,
|
|
1549
|
+
{
|
|
1550
|
+
[t(a).option__disabled]: st,
|
|
1551
|
+
[t(a).option__selected]: re,
|
|
1552
|
+
[t(a).option__prefixed]: !!t(o).prefix
|
|
1553
|
+
}
|
|
1554
|
+
])
|
|
1555
|
+
}, [
|
|
1556
|
+
t(o).prefix ? (c(), f("span", {
|
|
1557
|
+
key: 0,
|
|
1558
|
+
class: j({ prefix: !!t(o).prefix })
|
|
1559
|
+
}, [
|
|
1560
|
+
te(T.$slots, "prefix", le({ class: "prefix" }, F))
|
|
1561
|
+
], 2)) : E("", !0),
|
|
1562
|
+
x("span", xs, [
|
|
1563
|
+
t(o).default ? te(T.$slots, "default", De(le({ key: 0 }, F))) : (c(), f(q, { key: 1 }, [
|
|
1564
|
+
Ye(V(F[t(d)]), 1)
|
|
1565
|
+
], 64))
|
|
1566
|
+
]),
|
|
1567
|
+
re ? (c(), f("span", {
|
|
1568
|
+
key: 1,
|
|
1569
|
+
class: j(t(a).option__selected_icon)
|
|
1570
|
+
}, [
|
|
1571
|
+
Q(C, {
|
|
1572
|
+
"aria-hidden": "true",
|
|
1573
|
+
class: "h-5 w-5",
|
|
1574
|
+
name: "check-line"
|
|
1575
|
+
})
|
|
1576
|
+
], 2)) : E("", !0)
|
|
1577
|
+
], 2)
|
|
1578
|
+
]),
|
|
1579
|
+
_: 2
|
|
1580
|
+
}, 1032, ["disabled", "value"]))), 128))
|
|
1581
|
+
], 16)
|
|
1582
|
+
], 16))
|
|
1583
|
+
]),
|
|
1584
|
+
_: 3
|
|
1585
|
+
}, 8, ["class"])
|
|
1586
|
+
]),
|
|
1587
|
+
_: 3
|
|
1588
|
+
})
|
|
1589
|
+
])
|
|
1590
|
+
]),
|
|
1591
|
+
_: 3
|
|
1592
|
+
}, 8, ["by", "class", "disabled", "model-value", "multiple", "nullable"])
|
|
1593
|
+
], 2));
|
|
1594
|
+
}
|
|
1595
|
+
}), As = "_toggle_icon_17co6_1", ws = "_clear_button_17co6_5", ks = "_clear_icon_17co6_8", Os = "_has_details_17co6_12", Es = "_options_17co6_12", Cs = "_multiple_17co6_16", $s = "_single_17co6_17", Ys = "_filled_17co6_22", Qs = "_outlined_17co6_23", Us = "_empty_17co6_30", Rs = "_option_17co6_12", Ps = "_option__selected_17co6_37", Vs = "_option__disabled_17co6_40", Bs = "_option__selected_icon_17co6_43", Fs = "_option__prefixed_17co6_49", Gs = {
|
|
1596
|
+
toggle_icon: As,
|
|
1597
|
+
clear_button: ws,
|
|
1598
|
+
clear_icon: ks,
|
|
1599
|
+
has_details: Os,
|
|
1600
|
+
options: Es,
|
|
1601
|
+
multiple: Cs,
|
|
1602
|
+
single: $s,
|
|
1603
|
+
default: "_default_17co6_21",
|
|
1604
|
+
filled: Ys,
|
|
1605
|
+
outlined: Qs,
|
|
1606
|
+
empty: Us,
|
|
1607
|
+
option: Rs,
|
|
1608
|
+
option__selected: Ps,
|
|
1609
|
+
option__disabled: Vs,
|
|
1610
|
+
option__selected_icon: Bs,
|
|
1611
|
+
option__prefixed: Fs
|
|
1612
|
+
}, Ws = {
|
|
1613
|
+
$style: Gs
|
|
1614
|
+
}, fi = /* @__PURE__ */ H(Ss, [["__cssModules", Ws]]), Zs = /* @__PURE__ */ $({
|
|
1615
|
+
name: "RuiButtonGroup",
|
|
1616
|
+
__name: "ButtonGroup",
|
|
1617
|
+
props: {
|
|
1618
|
+
vertical: { type: Boolean, default: !1 },
|
|
1619
|
+
color: { default: void 0 },
|
|
1620
|
+
variant: { default: "default" },
|
|
1621
|
+
size: { default: void 0 }
|
|
1622
|
+
},
|
|
1623
|
+
setup(e) {
|
|
1624
|
+
const s = ye(), n = b(() => {
|
|
1625
|
+
var o;
|
|
1626
|
+
return ((o = s.default) == null ? void 0 : o.call(s)) ?? [];
|
|
1627
|
+
}), a = Z();
|
|
1628
|
+
return (o, l) => (c(), f("div", null, [
|
|
1629
|
+
x("div", {
|
|
1630
|
+
class: j([
|
|
1631
|
+
t(a).wrapper,
|
|
1632
|
+
t(a)[o.color ?? ""],
|
|
1633
|
+
t(a)[o.variant],
|
|
1634
|
+
{ [t(a).wrapper__vertical]: o.vertical }
|
|
1635
|
+
])
|
|
1636
|
+
}, [
|
|
1637
|
+
(c(!0), f(q, null, de(t(n), (i, p) => (c(), Y(he(i), {
|
|
1638
|
+
key: p,
|
|
1639
|
+
color: o.color,
|
|
1640
|
+
variant: o.variant,
|
|
1641
|
+
size: o.size,
|
|
1642
|
+
class: j(t(a).button)
|
|
1643
|
+
}, null, 8, ["color", "variant", "size", "class"]))), 128))
|
|
1644
|
+
], 2)
|
|
1645
|
+
]));
|
|
1646
|
+
}
|
|
1647
|
+
}), Hs = "_wrapper_j3xuo_315", Js = "_wrapper__vertical_j3xuo_319", Ks = "_button_j3xuo_322", Xs = "_primary_j3xuo_328", qs = "_outlined_j3xuo_331", ea = "_text_j3xuo_331", ta = "_secondary_j3xuo_337", na = "_error_j3xuo_346", oa = "_warning_j3xuo_355", sa = "_info_j3xuo_364", aa = "_success_j3xuo_373", la = {
|
|
1648
|
+
wrapper: Hs,
|
|
1649
|
+
wrapper__vertical: Js,
|
|
1650
|
+
button: Ks,
|
|
1651
|
+
primary: Xs,
|
|
1652
|
+
outlined: qs,
|
|
1653
|
+
text: ea,
|
|
1654
|
+
secondary: ta,
|
|
1655
|
+
error: na,
|
|
1656
|
+
warning: oa,
|
|
1657
|
+
info: sa,
|
|
1658
|
+
success: aa,
|
|
1659
|
+
"bg-tint": "_bg-tint_j3xuo_1",
|
|
1660
|
+
"bg-shade": "_bg-shade_j3xuo_1",
|
|
1661
|
+
"text-tint": "_text-tint_j3xuo_1",
|
|
1662
|
+
"text-shade": "_text-shade_j3xuo_1"
|
|
1663
|
+
}, ia = {
|
|
1664
|
+
$style: la
|
|
1665
|
+
}, ji = /* @__PURE__ */ H(Zs, [["__cssModules", ia]]), ra = ["checked", "disabled"], ua = {
|
|
1666
|
+
key: 0,
|
|
1667
|
+
class: "details"
|
|
1668
|
+
}, ca = {
|
|
1669
|
+
key: 0,
|
|
1670
|
+
class: "text-rui-error text-caption"
|
|
1671
|
+
}, da = {
|
|
1672
|
+
key: 1,
|
|
1673
|
+
class: "text-rui-text-secondary text-caption"
|
|
1674
|
+
}, Ma = {
|
|
1675
|
+
key: 2,
|
|
1676
|
+
class: "h-5"
|
|
1677
|
+
}, pa = /* @__PURE__ */ $({
|
|
1678
|
+
name: "RuiCheckbox",
|
|
1679
|
+
__name: "Checkbox",
|
|
1680
|
+
props: {
|
|
1681
|
+
modelValue: { type: Boolean, default: !1 },
|
|
1682
|
+
indeterminate: { type: Boolean, default: !1 },
|
|
1683
|
+
disabled: { type: Boolean, default: !1 },
|
|
1684
|
+
color: { default: void 0 },
|
|
1685
|
+
size: { default: void 0 },
|
|
1686
|
+
hint: { default: "" },
|
|
1687
|
+
errorMessages: { default: () => [] },
|
|
1688
|
+
hideDetails: { type: Boolean, default: !1 }
|
|
1689
|
+
},
|
|
1690
|
+
emits: ["update:modelValue", "update:indeterminate"],
|
|
1691
|
+
setup(e, { emit: s }) {
|
|
1692
|
+
const n = e, { size: a } = se(n), o = (u) => {
|
|
1693
|
+
const d = u.target.checked;
|
|
1694
|
+
d && s("update:indeterminate", !1), s("update:modelValue", d);
|
|
1695
|
+
}, l = b(() => {
|
|
1696
|
+
const u = _(a);
|
|
1697
|
+
return u === "lg" ? 28 : u === "sm" ? 20 : 24;
|
|
1698
|
+
}), i = Z(), p = Me();
|
|
1699
|
+
return (u, d) => (c(), f("div", {
|
|
1700
|
+
class: j(t(p).class)
|
|
1701
|
+
}, [
|
|
1702
|
+
x("label", {
|
|
1703
|
+
class: j([
|
|
1704
|
+
t(i).wrapper,
|
|
1705
|
+
t(i)[t(a) ?? ""],
|
|
1706
|
+
{
|
|
1707
|
+
[t(i).disabled]: u.disabled
|
|
1708
|
+
}
|
|
1709
|
+
])
|
|
1710
|
+
}, [
|
|
1711
|
+
x("input", le({
|
|
1712
|
+
checked: u.modelValue,
|
|
1713
|
+
type: "checkbox",
|
|
1714
|
+
class: t(i).input,
|
|
1715
|
+
disabled: u.disabled
|
|
1716
|
+
}, t(be)(t(p), ["class"]), {
|
|
1717
|
+
onInput: d[0] || (d[0] = (r) => o(r))
|
|
1718
|
+
}), null, 16, ra),
|
|
1719
|
+
x("div", {
|
|
1720
|
+
class: j([
|
|
1721
|
+
t(i).checkbox,
|
|
1722
|
+
t(i)[u.color ?? ""],
|
|
1723
|
+
t(i)[t(a) ?? ""],
|
|
1724
|
+
{
|
|
1725
|
+
[t(i).checked]: u.modelValue || u.indeterminate,
|
|
1726
|
+
[t(i).disabled]: u.disabled,
|
|
1727
|
+
[t(i)["with-error"]]: u.errorMessages.length > 0
|
|
1728
|
+
}
|
|
1729
|
+
])
|
|
1730
|
+
}, [
|
|
1731
|
+
u.indeterminate ? (c(), Y(C, {
|
|
1732
|
+
key: 0,
|
|
1733
|
+
name: "checkbox-indeterminate-fill",
|
|
1734
|
+
size: t(l)
|
|
1735
|
+
}, null, 8, ["size"])) : u.modelValue ? (c(), Y(C, {
|
|
1736
|
+
key: 1,
|
|
1737
|
+
name: "checkbox-fill",
|
|
1738
|
+
size: t(l)
|
|
1739
|
+
}, null, 8, ["size"])) : (c(), Y(C, {
|
|
1740
|
+
key: 2,
|
|
1741
|
+
name: "checkbox-blank-line",
|
|
1742
|
+
size: t(l)
|
|
1743
|
+
}, null, 8, ["size"]))
|
|
1744
|
+
], 2),
|
|
1745
|
+
x("div", {
|
|
1746
|
+
class: j([t(i).label, "text-body-1"])
|
|
1747
|
+
}, [
|
|
1748
|
+
te(u.$slots, "default")
|
|
1749
|
+
], 2)
|
|
1750
|
+
], 2),
|
|
1751
|
+
u.hideDetails ? E("", !0) : (c(), f("div", ua, [
|
|
1752
|
+
u.errorMessages.length > 0 ? (c(), f("div", ca, V(u.errorMessages[0]), 1)) : u.hint ? (c(), f("div", da, V(u.hint), 1)) : (c(), f("div", Ma))
|
|
1753
|
+
]))
|
|
1754
|
+
], 2));
|
|
1755
|
+
}
|
|
1756
|
+
}), _a = "_wrapper_1bkf8_1", ya = "_disabled_1bkf8_4", fa = "_checkbox_1bkf8_7", ja = "_label_1bkf8_13", va = "_input_1bkf8_16", ga = "_lg_1bkf8_39", La = "_sm_1bkf8_42", Na = "_primary_1bkf8_45", ba = "_checked_1bkf8_48", ma = "_secondary_1bkf8_51", Ta = "_error_1bkf8_57", Da = "_warning_1bkf8_63", Ia = "_info_1bkf8_69", za = "_success_1bkf8_75", ha = {
|
|
1757
|
+
wrapper: _a,
|
|
1758
|
+
disabled: ya,
|
|
1759
|
+
checkbox: fa,
|
|
1760
|
+
label: ja,
|
|
1761
|
+
input: va,
|
|
1762
|
+
"with-error": "_with-error_1bkf8_30",
|
|
1763
|
+
lg: ga,
|
|
1764
|
+
sm: La,
|
|
1765
|
+
primary: Na,
|
|
1766
|
+
checked: ba,
|
|
1767
|
+
secondary: ma,
|
|
1768
|
+
error: Ta,
|
|
1769
|
+
warning: Da,
|
|
1770
|
+
info: Ia,
|
|
1771
|
+
success: za
|
|
1772
|
+
}, xa = {
|
|
1773
|
+
$style: ha
|
|
1774
|
+
}, vi = /* @__PURE__ */ H(pa, [["__cssModules", xa]]), W = {
|
|
1775
|
+
inactive: "inactive",
|
|
1776
|
+
active: "active",
|
|
1777
|
+
done: "done",
|
|
1778
|
+
error: "error",
|
|
1779
|
+
warning: "warning",
|
|
1780
|
+
info: "info",
|
|
1781
|
+
success: "success"
|
|
1782
|
+
}, $e = {
|
|
1783
|
+
vertical: "vertical",
|
|
1784
|
+
horizontal: "horizontal"
|
|
1785
|
+
}, Sa = /* @__PURE__ */ $({
|
|
1786
|
+
__name: "StepperIcon",
|
|
1787
|
+
props: {
|
|
1788
|
+
state: { default: W.inactive },
|
|
1789
|
+
index: {}
|
|
1790
|
+
},
|
|
1791
|
+
setup(e) {
|
|
1792
|
+
const s = Z();
|
|
1793
|
+
return (n, a) => (c(), f("span", {
|
|
1794
|
+
class: j([t(s).indicator, t(s)[n.state]])
|
|
1795
|
+
}, [
|
|
1796
|
+
n.state === t(W).inactive || n.state === t(W).active ? (c(), f("span", {
|
|
1797
|
+
key: 0,
|
|
1798
|
+
class: j(t(s).text)
|
|
1799
|
+
}, V(n.index), 3)) : n.state === t(W).done ? (c(), Y(C, {
|
|
1800
|
+
key: 1,
|
|
1801
|
+
class: j(t(s).text),
|
|
1802
|
+
size: 20,
|
|
1803
|
+
name: "check-line"
|
|
1804
|
+
}, null, 8, ["class"])) : n.state === t(W).success ? (c(), Y(C, {
|
|
1805
|
+
key: 2,
|
|
1806
|
+
name: "checkbox-circle-fill"
|
|
1807
|
+
})) : n.state === t(W).error ? (c(), Y(C, {
|
|
1808
|
+
key: 3,
|
|
1809
|
+
name: "error-warning-fill"
|
|
1810
|
+
})) : n.state === t(W).warning ? (c(), Y(C, {
|
|
1811
|
+
key: 4,
|
|
1812
|
+
name: "alert-fill"
|
|
1813
|
+
})) : n.state === t(W).info ? (c(), Y(C, {
|
|
1814
|
+
key: 5,
|
|
1815
|
+
name: "information-fill"
|
|
1816
|
+
})) : E("", !0)
|
|
1817
|
+
], 2));
|
|
1818
|
+
}
|
|
1819
|
+
}), Aa = "_indicator_vbhrs_1", wa = "_text_vbhrs_4", ka = "_inactive_vbhrs_7", Oa = "_active_vbhrs_10", Ea = "_done_vbhrs_10", Ca = {
|
|
1820
|
+
indicator: Aa,
|
|
1821
|
+
text: wa,
|
|
1822
|
+
inactive: ka,
|
|
1823
|
+
active: Oa,
|
|
1824
|
+
done: Ea
|
|
1825
|
+
}, $a = {
|
|
1826
|
+
$style: Ca
|
|
1827
|
+
}, Ya = /* @__PURE__ */ H(Sa, [["__cssModules", $a]]), Qa = /* @__PURE__ */ $({
|
|
1828
|
+
__name: "StepperCustomIcon",
|
|
1829
|
+
props: {
|
|
1830
|
+
state: { default: W.inactive },
|
|
1831
|
+
index: {}
|
|
1832
|
+
},
|
|
1833
|
+
setup(e) {
|
|
1834
|
+
const s = Z();
|
|
1835
|
+
return (n, a) => (c(), f("span", {
|
|
1836
|
+
class: j([t(s).indicator, t(s)[n.state]])
|
|
1837
|
+
}, [
|
|
1838
|
+
n.state === t(W).inactive ? (c(), f("span", {
|
|
1839
|
+
key: 0,
|
|
1840
|
+
class: j(t(s).text)
|
|
1841
|
+
}, V(n.index), 3)) : n.state === t(W).active ? (c(), Y(C, {
|
|
1842
|
+
key: 1,
|
|
1843
|
+
name: "checkbox-blank-circle-fill",
|
|
1844
|
+
size: 20
|
|
1845
|
+
})) : n.state === t(W).done ? (c(), Y(C, {
|
|
1846
|
+
key: 2,
|
|
1847
|
+
class: j(t(s).text),
|
|
1848
|
+
size: 20,
|
|
1849
|
+
name: "check-line"
|
|
1850
|
+
}, null, 8, ["class"])) : (c(), f("span", {
|
|
1851
|
+
key: 3,
|
|
1852
|
+
class: j(t(s).text)
|
|
1853
|
+
}, V(n.index), 3))
|
|
1854
|
+
], 2));
|
|
1855
|
+
}
|
|
1856
|
+
}), Ua = "_indicator_1fggs_1", Ra = "_inactive_1fggs_4", Pa = "_text_1fggs_7", Va = {
|
|
1857
|
+
indicator: Ua,
|
|
1858
|
+
inactive: Ra,
|
|
1859
|
+
text: Pa
|
|
1860
|
+
}, Ba = {
|
|
1861
|
+
$style: Va
|
|
1862
|
+
}, Fa = /* @__PURE__ */ H(Qa, [["__cssModules", Ba]]), Ga = /* @__PURE__ */ $({
|
|
1863
|
+
name: "RuiStepper",
|
|
1864
|
+
__name: "Stepper",
|
|
1865
|
+
props: {
|
|
1866
|
+
step: { default: 0 },
|
|
1867
|
+
steps: {},
|
|
1868
|
+
iconTop: { type: Boolean, default: !1 },
|
|
1869
|
+
custom: { type: Boolean, default: !1 },
|
|
1870
|
+
titleClass: { default: "" },
|
|
1871
|
+
subtitleClass: { default: "" },
|
|
1872
|
+
orientation: { default: $e.horizontal },
|
|
1873
|
+
keepActiveVisible: { type: Boolean, default: !0 }
|
|
1874
|
+
},
|
|
1875
|
+
setup(e) {
|
|
1876
|
+
const s = e, n = Z(), { custom: a, steps: o, step: l, orientation: i, keepActiveVisible: p } = se(s), u = b(() => {
|
|
1877
|
+
if (!_(a))
|
|
1878
|
+
return _(o);
|
|
1879
|
+
const r = _(l);
|
|
1880
|
+
return _(o).map((y, N) => {
|
|
1881
|
+
let I = W.inactive;
|
|
1882
|
+
return N + 1 === r && (I = W.active), N + 1 < r && (I = W.done), {
|
|
1883
|
+
...y,
|
|
1884
|
+
state: I
|
|
1885
|
+
};
|
|
1886
|
+
});
|
|
1887
|
+
}), d = k();
|
|
1888
|
+
return ce(l, () => {
|
|
1889
|
+
!_(p) || _(i) !== $e.horizontal || oe(() => {
|
|
1890
|
+
var y;
|
|
1891
|
+
const r = _(d);
|
|
1892
|
+
if (r) {
|
|
1893
|
+
const N = r.querySelector(".active-step");
|
|
1894
|
+
(y = N == null ? void 0 : N.scrollIntoView) == null || y.call(N, {
|
|
1895
|
+
behavior: "smooth",
|
|
1896
|
+
inline: "center"
|
|
1897
|
+
});
|
|
1898
|
+
}
|
|
1899
|
+
});
|
|
1900
|
+
}), (r, y) => (c(), f("div", {
|
|
1901
|
+
ref_key: "wrapperRef",
|
|
1902
|
+
ref: d,
|
|
1903
|
+
class: j([[
|
|
1904
|
+
t(n).stepper,
|
|
1905
|
+
t(n)[t(i) ?? ""],
|
|
1906
|
+
{ [t(n)["icon-top"]]: r.iconTop, [t(n).custom]: t(a) }
|
|
1907
|
+
], "no-scrollbar overflow-auto"])
|
|
1908
|
+
}, [
|
|
1909
|
+
(c(!0), f(q, null, de(t(u), ({ title: N, description: I, state: z }, g) => (c(), f(q, { key: g }, [
|
|
1910
|
+
g > 0 ? (c(), f("hr", {
|
|
1911
|
+
key: 0,
|
|
1912
|
+
class: j(t(n).divider)
|
|
1913
|
+
}, null, 2)) : E("", !0),
|
|
1914
|
+
x("div", {
|
|
1915
|
+
class: j([
|
|
1916
|
+
t(n).step,
|
|
1917
|
+
t(n)[z ?? t(W).inactive],
|
|
1918
|
+
{
|
|
1919
|
+
"active-step": z === t(W).active
|
|
1920
|
+
}
|
|
1921
|
+
])
|
|
1922
|
+
}, [
|
|
1923
|
+
te(r.$slots, "icon", De(Pe({ state: z, index: g + 1 })), () => [
|
|
1924
|
+
t(a) ? (c(), Y(Fa, {
|
|
1925
|
+
key: 0,
|
|
1926
|
+
index: g + 1,
|
|
1927
|
+
state: z
|
|
1928
|
+
}, null, 8, ["index", "state"])) : (c(), Y(Ya, {
|
|
1929
|
+
key: 1,
|
|
1930
|
+
index: g + 1,
|
|
1931
|
+
state: z
|
|
1932
|
+
}, null, 8, ["index", "state"]))
|
|
1933
|
+
]),
|
|
1934
|
+
N || I ? (c(), f("div", {
|
|
1935
|
+
key: 0,
|
|
1936
|
+
class: j(t(n).label)
|
|
1937
|
+
}, [
|
|
1938
|
+
N ? (c(), f("span", {
|
|
1939
|
+
key: 0,
|
|
1940
|
+
class: j([[t(n).title, { [r.titleClass]: t(a) }], "text-subtitle-2"])
|
|
1941
|
+
}, V(N), 3)) : E("", !0),
|
|
1942
|
+
I ? (c(), f("span", {
|
|
1943
|
+
key: 1,
|
|
1944
|
+
class: j([[t(n).subtitle, { [r.subtitleClass]: t(a) }], "text-caption"])
|
|
1945
|
+
}, V(I), 3)) : E("", !0)
|
|
1946
|
+
], 2)) : E("", !0)
|
|
1947
|
+
], 2)
|
|
1948
|
+
], 64))), 128))
|
|
1949
|
+
], 2));
|
|
1950
|
+
}
|
|
1951
|
+
}), Wa = "_stepper_niksj_1", Za = "_horizontal_niksj_4", Ha = "_vertical_niksj_7", Ja = "_step_niksj_1", Ka = "_divider_niksj_13", Xa = "_custom_niksj_16", qa = "_indicator_niksj_25", el = "_label_niksj_28", tl = "_inactive_niksj_31", nl = "_title_niksj_34", ol = "_subtitle_niksj_37", sl = "_active_niksj_40", al = "_done_niksj_40", ll = "_error_niksj_46", il = "_warning_niksj_49", rl = "_info_niksj_52", ul = "_success_niksj_55", cl = {
|
|
1952
|
+
stepper: Wa,
|
|
1953
|
+
horizontal: Za,
|
|
1954
|
+
vertical: Ha,
|
|
1955
|
+
step: Ja,
|
|
1956
|
+
divider: Ka,
|
|
1957
|
+
custom: Xa,
|
|
1958
|
+
"icon-top": "_icon-top_niksj_19",
|
|
1959
|
+
indicator: qa,
|
|
1960
|
+
label: el,
|
|
1961
|
+
inactive: tl,
|
|
1962
|
+
title: nl,
|
|
1963
|
+
subtitle: ol,
|
|
1964
|
+
active: sl,
|
|
1965
|
+
done: al,
|
|
1966
|
+
error: ll,
|
|
1967
|
+
warning: il,
|
|
1968
|
+
info: rl,
|
|
1969
|
+
success: ul
|
|
1970
|
+
}, dl = {
|
|
1971
|
+
$style: cl
|
|
1972
|
+
}, gi = /* @__PURE__ */ H(Ga, [["__cssModules", dl]]), Ml = ["onClick"], pl = { key: 0 }, _l = ["onClick"], yl = { key: 0 }, fl = /* @__PURE__ */ $({
|
|
1973
|
+
name: "RuiFooterStepper",
|
|
1974
|
+
__name: "FooterStepper",
|
|
1975
|
+
props: {
|
|
1976
|
+
pages: {},
|
|
1977
|
+
modelValue: { default: 1 },
|
|
1978
|
+
variant: { default: "numeric" },
|
|
1979
|
+
arrowButtons: { type: Boolean, default: !1 }
|
|
1980
|
+
},
|
|
1981
|
+
emits: ["update:modelValue"],
|
|
1982
|
+
setup(e, { emit: s }) {
|
|
1983
|
+
const n = e, a = Z(), { modelValue: o, pages: l } = se(n), i = (r) => {
|
|
1984
|
+
s("update:modelValue", _(o) + r);
|
|
1985
|
+
}, p = () => {
|
|
1986
|
+
_(o) && i(-1);
|
|
1987
|
+
}, u = () => {
|
|
1988
|
+
_(o) < _(l) && i(1);
|
|
1989
|
+
}, d = (r) => {
|
|
1990
|
+
i(r - _(o));
|
|
1991
|
+
};
|
|
1992
|
+
return (r, y) => (c(), f("div", {
|
|
1993
|
+
class: j([t(a)["footer-stepper"], t(a)[r.variant ?? ""]])
|
|
1994
|
+
}, [
|
|
1995
|
+
r.variant === "pill" ? (c(), f("div", {
|
|
1996
|
+
key: 0,
|
|
1997
|
+
class: j(t(a).pills)
|
|
1998
|
+
}, [
|
|
1999
|
+
(c(!0), f(q, null, de(t(l), (N) => (c(), f("span", {
|
|
2000
|
+
key: N,
|
|
2001
|
+
class: j([t(a).pill, { [t(a).active]: t(o) === N }]),
|
|
2002
|
+
onClick: (I) => d(N)
|
|
2003
|
+
}, null, 10, Ml))), 128))
|
|
2004
|
+
], 2)) : (c(), f(q, { key: 1 }, [
|
|
2005
|
+
Q(ve, {
|
|
2006
|
+
class: j({ [t(a).arrow__button]: r.arrowButtons }),
|
|
2007
|
+
disabled: t(o) <= 1,
|
|
2008
|
+
icon: r.arrowButtons,
|
|
2009
|
+
variant: r.arrowButtons ? "outlined" : "text",
|
|
2010
|
+
color: "primary",
|
|
2011
|
+
onClick: y[0] || (y[0] = (N) => p())
|
|
2012
|
+
}, Ie({
|
|
2013
|
+
default: X(() => [
|
|
2014
|
+
r.arrowButtons ? (c(), Y(C, {
|
|
2015
|
+
key: 1,
|
|
2016
|
+
size: 24,
|
|
2017
|
+
name: "arrow-left-line"
|
|
2018
|
+
})) : (c(), f("span", pl, "Back"))
|
|
2019
|
+
]),
|
|
2020
|
+
_: 2
|
|
2021
|
+
}, [
|
|
2022
|
+
r.arrowButtons ? void 0 : {
|
|
2023
|
+
name: "prepend",
|
|
2024
|
+
fn: X(() => [
|
|
2025
|
+
Q(C, {
|
|
2026
|
+
size: 18,
|
|
2027
|
+
name: "arrow-left-s-line"
|
|
2028
|
+
})
|
|
2029
|
+
]),
|
|
2030
|
+
key: "0"
|
|
2031
|
+
}
|
|
2032
|
+
]), 1032, ["class", "disabled", "icon", "variant"]),
|
|
2033
|
+
r.variant === "numeric" ? (c(), f("span", {
|
|
2034
|
+
key: 0,
|
|
2035
|
+
class: j(t(a).numeric)
|
|
2036
|
+
}, V(t(o)) + "/" + V(t(l)), 3)) : r.variant === "bullet" ? (c(), f("div", {
|
|
2037
|
+
key: 1,
|
|
2038
|
+
class: j(t(a).bullets)
|
|
2039
|
+
}, [
|
|
2040
|
+
(c(!0), f(q, null, de(t(l), (N) => (c(), f("span", {
|
|
2041
|
+
key: N,
|
|
2042
|
+
class: j([t(a).bullet, { [t(a).active]: t(o) === N }]),
|
|
2043
|
+
onClick: (I) => d(N)
|
|
2044
|
+
}, null, 10, _l))), 128))
|
|
2045
|
+
], 2)) : r.variant === "progress" ? (c(), Y(Ve, {
|
|
2046
|
+
key: 2,
|
|
2047
|
+
class: j(t(a).progress),
|
|
2048
|
+
value: t(o) / t(l) * 100
|
|
2049
|
+
}, null, 8, ["class", "value"])) : E("", !0),
|
|
2050
|
+
Q(ve, {
|
|
2051
|
+
class: j({ [t(a).arrow__button]: r.arrowButtons }),
|
|
2052
|
+
disabled: t(o) >= t(l),
|
|
2053
|
+
icon: r.arrowButtons,
|
|
2054
|
+
variant: r.arrowButtons ? "outlined" : "text",
|
|
2055
|
+
color: "primary",
|
|
2056
|
+
onClick: y[1] || (y[1] = (N) => u())
|
|
2057
|
+
}, Ie({
|
|
2058
|
+
default: X(() => [
|
|
2059
|
+
r.arrowButtons ? (c(), Y(C, {
|
|
2060
|
+
key: 1,
|
|
2061
|
+
size: 24,
|
|
2062
|
+
name: "arrow-right-line"
|
|
2063
|
+
})) : (c(), f("span", yl, "Next"))
|
|
2064
|
+
]),
|
|
2065
|
+
_: 2
|
|
2066
|
+
}, [
|
|
2067
|
+
r.arrowButtons ? void 0 : {
|
|
2068
|
+
name: "append",
|
|
2069
|
+
fn: X(() => [
|
|
2070
|
+
Q(C, {
|
|
2071
|
+
size: 18,
|
|
2072
|
+
name: "arrow-right-s-line"
|
|
2073
|
+
})
|
|
2074
|
+
]),
|
|
2075
|
+
key: "0"
|
|
2076
|
+
}
|
|
2077
|
+
]), 1032, ["class", "disabled", "icon", "variant"])
|
|
2078
|
+
], 64))
|
|
2079
|
+
], 2));
|
|
2080
|
+
}
|
|
2081
|
+
}), jl = "_numeric_1bbl9_4", vl = "_bullets_1bbl9_7", gl = "_pills_1bbl9_8", Ll = "_bullet_1bbl9_7", Nl = "_pill_1bbl9_8", bl = "_active_1bbl9_17", ml = "_progress_1bbl9_39", Tl = "_arrow__button_1bbl9_42", Dl = {
|
|
2082
|
+
"footer-stepper": "_footer-stepper_1bbl9_1",
|
|
2083
|
+
numeric: jl,
|
|
2084
|
+
bullets: vl,
|
|
2085
|
+
pills: gl,
|
|
2086
|
+
bullet: Ll,
|
|
2087
|
+
pill: Nl,
|
|
2088
|
+
active: bl,
|
|
2089
|
+
progress: ml,
|
|
2090
|
+
arrow__button: Tl
|
|
2091
|
+
}, Il = {
|
|
2092
|
+
$style: Dl
|
|
2093
|
+
}, Li = /* @__PURE__ */ H(fl, [["__cssModules", Il]]), zl = Mt(() => ({ count: k(0) })), hl = (e = "") => {
|
|
2094
|
+
const { count: s } = zl(), n = _(s);
|
|
2095
|
+
return ae(s, n + 1), `${e}-${_(s)}`;
|
|
2096
|
+
}, xl = {
|
|
2097
|
+
key: 0,
|
|
2098
|
+
class: "details"
|
|
2099
|
+
}, Sl = {
|
|
2100
|
+
key: 0,
|
|
2101
|
+
class: "text-rui-error text-caption"
|
|
2102
|
+
}, Al = {
|
|
2103
|
+
key: 1,
|
|
2104
|
+
class: "text-rui-text-secondary text-caption"
|
|
2105
|
+
}, wl = {
|
|
2106
|
+
key: 2,
|
|
2107
|
+
class: "h-5"
|
|
2108
|
+
}, kl = /* @__PURE__ */ $({
|
|
2109
|
+
name: "RuiRadioGroup",
|
|
2110
|
+
__name: "RadioGroup",
|
|
2111
|
+
props: {
|
|
2112
|
+
modelValue: { default: "" },
|
|
2113
|
+
inline: { type: Boolean, default: !1 },
|
|
2114
|
+
hint: { default: "" },
|
|
2115
|
+
errorMessages: { default: () => [] },
|
|
2116
|
+
hideDetails: { type: Boolean, default: !1 }
|
|
2117
|
+
},
|
|
2118
|
+
emits: ["update:modelValue"],
|
|
2119
|
+
setup(e, { emit: s }) {
|
|
2120
|
+
const n = k("");
|
|
2121
|
+
_e(() => {
|
|
2122
|
+
ae(n, hl("radio-group"));
|
|
2123
|
+
});
|
|
2124
|
+
const a = ye(), o = b(() => {
|
|
2125
|
+
var i, p;
|
|
2126
|
+
return ((p = (i = a.default) == null ? void 0 : i.call(a)) == null ? void 0 : p[0].children) ?? [];
|
|
2127
|
+
}), l = Z();
|
|
2128
|
+
return (i, p) => (c(), f("div", null, [
|
|
2129
|
+
x("div", {
|
|
2130
|
+
class: j([t(l).wrapper, { [t(l).wrapper__inline]: i.inline }])
|
|
2131
|
+
}, [
|
|
2132
|
+
(c(!0), f(q, null, de(t(o), (u, d) => (c(), Y(he(u), {
|
|
2133
|
+
key: d,
|
|
2134
|
+
"model-value": i.modelValue,
|
|
2135
|
+
"hide-details": "",
|
|
2136
|
+
name: t(n),
|
|
2137
|
+
"onUpdate:modelValue": p[0] || (p[0] = (r) => s("update:modelValue", r))
|
|
2138
|
+
}, null, 8, ["model-value", "name"]))), 128))
|
|
2139
|
+
], 2),
|
|
2140
|
+
i.hideDetails ? E("", !0) : (c(), f("div", xl, [
|
|
2141
|
+
i.errorMessages.length > 0 ? (c(), f("div", Sl, V(i.errorMessages[0]), 1)) : i.hint ? (c(), f("div", Al, V(i.hint), 1)) : (c(), f("div", wl))
|
|
2142
|
+
]))
|
|
2143
|
+
]));
|
|
2144
|
+
}
|
|
2145
|
+
}), Ol = "_wrapper__inline_1tfcu_1", El = {
|
|
2146
|
+
wrapper__inline: Ol
|
|
2147
|
+
}, Cl = {
|
|
2148
|
+
$style: El
|
|
2149
|
+
}, Ni = /* @__PURE__ */ H(kl, [["__cssModules", Cl]]), $l = ["checked", "disabled", "value"], Yl = {
|
|
2150
|
+
key: 0,
|
|
2151
|
+
class: "details"
|
|
2152
|
+
}, Ql = {
|
|
2153
|
+
key: 0,
|
|
2154
|
+
class: "text-rui-error text-caption"
|
|
2155
|
+
}, Ul = {
|
|
2156
|
+
key: 1,
|
|
2157
|
+
class: "text-rui-text-secondary text-caption"
|
|
2158
|
+
}, Rl = {
|
|
2159
|
+
key: 2,
|
|
2160
|
+
class: "h-5"
|
|
2161
|
+
}, Pl = /* @__PURE__ */ $({
|
|
2162
|
+
name: "RuiRadio",
|
|
2163
|
+
__name: "Radio",
|
|
2164
|
+
props: {
|
|
2165
|
+
value: {},
|
|
2166
|
+
modelValue: { default: "" },
|
|
2167
|
+
disabled: { type: Boolean, default: !1 },
|
|
2168
|
+
color: { default: void 0 },
|
|
2169
|
+
size: { default: void 0 },
|
|
2170
|
+
hint: { default: "" },
|
|
2171
|
+
errorMessages: { default: () => [] },
|
|
2172
|
+
hideDetails: { type: Boolean, default: !1 }
|
|
2173
|
+
},
|
|
2174
|
+
emits: ["update:modelValue"],
|
|
2175
|
+
setup(e, { emit: s }) {
|
|
2176
|
+
const n = e, { modelValue: a, size: o, value: l } = se(n), i = (y) => {
|
|
2177
|
+
y.target.checked && s("update:modelValue", _(l));
|
|
2178
|
+
}, p = b(() => {
|
|
2179
|
+
const y = _(o);
|
|
2180
|
+
return y === "lg" ? 28 : y === "sm" ? 20 : 24;
|
|
2181
|
+
}), u = b(() => _(a) === _(l)), d = Z(), r = Me();
|
|
2182
|
+
return (y, N) => (c(), f("div", {
|
|
2183
|
+
class: j(t(r).class)
|
|
2184
|
+
}, [
|
|
2185
|
+
x("label", {
|
|
2186
|
+
class: j([
|
|
2187
|
+
t(d).wrapper,
|
|
2188
|
+
t(d)[t(o) ?? ""],
|
|
2189
|
+
{
|
|
2190
|
+
[t(d).disabled]: y.disabled
|
|
2191
|
+
}
|
|
2192
|
+
])
|
|
2193
|
+
}, [
|
|
2194
|
+
x("input", le({
|
|
2195
|
+
checked: t(u),
|
|
2196
|
+
type: "radio",
|
|
2197
|
+
class: t(d).input,
|
|
2198
|
+
disabled: y.disabled
|
|
2199
|
+
}, t(be)(t(r), ["class"]), {
|
|
2200
|
+
value: t(l),
|
|
2201
|
+
onInput: N[0] || (N[0] = (I) => i(I))
|
|
2202
|
+
}), null, 16, $l),
|
|
2203
|
+
x("div", {
|
|
2204
|
+
class: j([
|
|
2205
|
+
t(d).radio,
|
|
2206
|
+
t(d)[y.color ?? ""],
|
|
2207
|
+
t(d)[t(o) ?? ""],
|
|
2208
|
+
{
|
|
2209
|
+
[t(d).checked]: t(u),
|
|
2210
|
+
[t(d).disabled]: y.disabled,
|
|
2211
|
+
[t(d)["with-error"]]: y.errorMessages.length > 0
|
|
2212
|
+
}
|
|
2213
|
+
])
|
|
2214
|
+
}, [
|
|
2215
|
+
t(u) ? (c(), Y(C, {
|
|
2216
|
+
key: 0,
|
|
2217
|
+
name: "radio-button-line",
|
|
2218
|
+
size: t(p)
|
|
2219
|
+
}, null, 8, ["size"])) : (c(), Y(C, {
|
|
2220
|
+
key: 1,
|
|
2221
|
+
name: "checkbox-blank-circle-line",
|
|
2222
|
+
size: t(p)
|
|
2223
|
+
}, null, 8, ["size"]))
|
|
2224
|
+
], 2),
|
|
2225
|
+
x("div", {
|
|
2226
|
+
class: j([t(d).label, "text-body-1"])
|
|
2227
|
+
}, [
|
|
2228
|
+
te(y.$slots, "default")
|
|
2229
|
+
], 2)
|
|
2230
|
+
], 2),
|
|
2231
|
+
y.hideDetails ? E("", !0) : (c(), f("div", Yl, [
|
|
2232
|
+
y.errorMessages.length > 0 ? (c(), f("div", Ql, V(y.errorMessages[0]), 1)) : y.hint ? (c(), f("div", Ul, V(y.hint), 1)) : (c(), f("div", Rl))
|
|
2233
|
+
]))
|
|
2234
|
+
], 2));
|
|
2235
|
+
}
|
|
2236
|
+
}), Vl = "_wrapper_1a51t_1", Bl = "_disabled_1a51t_4", Fl = "_radio_1a51t_7", Gl = "_label_1a51t_13", Wl = "_input_1a51t_16", Zl = "_lg_1a51t_39", Hl = "_sm_1a51t_42", Jl = "_primary_1a51t_45", Kl = "_checked_1a51t_48", Xl = "_secondary_1a51t_51", ql = "_error_1a51t_57", ei = "_warning_1a51t_63", ti = "_info_1a51t_69", ni = "_success_1a51t_75", oi = {
|
|
2237
|
+
wrapper: Vl,
|
|
2238
|
+
disabled: Bl,
|
|
2239
|
+
radio: Fl,
|
|
2240
|
+
label: Gl,
|
|
2241
|
+
input: Wl,
|
|
2242
|
+
"with-error": "_with-error_1a51t_30",
|
|
2243
|
+
lg: Zl,
|
|
2244
|
+
sm: Hl,
|
|
2245
|
+
primary: Jl,
|
|
2246
|
+
checked: Kl,
|
|
2247
|
+
secondary: Xl,
|
|
2248
|
+
error: ql,
|
|
2249
|
+
warning: ei,
|
|
2250
|
+
info: ti,
|
|
2251
|
+
success: ni
|
|
2252
|
+
}, si = {
|
|
2253
|
+
$style: oi
|
|
2254
|
+
}, bi = /* @__PURE__ */ H(Pl, [["__cssModules", si]]), ai = { class: "flex items-center" }, mi = /* @__PURE__ */ $({
|
|
2255
|
+
name: "RuiRevealableTextField",
|
|
2256
|
+
__name: "RevealableTextField",
|
|
2257
|
+
setup(e) {
|
|
2258
|
+
const s = k(!0), n = Me(), a = ye();
|
|
2259
|
+
return (o, l) => (c(), Y(tt, le(t(n), {
|
|
2260
|
+
type: t(s) ? "password" : "text"
|
|
2261
|
+
}), Ie({
|
|
2262
|
+
append: X(() => [
|
|
2263
|
+
x("div", ai, [
|
|
2264
|
+
Q(ve, {
|
|
2265
|
+
tabindex: "-1",
|
|
2266
|
+
variant: "text",
|
|
2267
|
+
type: "button",
|
|
2268
|
+
icon: "",
|
|
2269
|
+
class: "-mr-1 !p-2",
|
|
2270
|
+
onClick: l[0] || (l[0] = (i) => s.value = !t(s))
|
|
2271
|
+
}, {
|
|
2272
|
+
default: X(() => [
|
|
2273
|
+
Q(C, {
|
|
2274
|
+
class: "text-black/[.54] dark:text-white/[.56]",
|
|
2275
|
+
size: "20",
|
|
2276
|
+
name: t(s) ? "eye-off-line" : "eye-line"
|
|
2277
|
+
}, null, 8, ["name"])
|
|
2278
|
+
]),
|
|
2279
|
+
_: 1
|
|
2280
|
+
}),
|
|
2281
|
+
te(o.$slots, "append")
|
|
2282
|
+
])
|
|
2283
|
+
]),
|
|
2284
|
+
_: 2
|
|
2285
|
+
}, [
|
|
2286
|
+
t(a).prepend ? {
|
|
2287
|
+
name: "prepend",
|
|
2288
|
+
fn: X(() => [
|
|
2289
|
+
te(o.$slots, "prepend")
|
|
2290
|
+
]),
|
|
2291
|
+
key: "0"
|
|
2292
|
+
} : void 0
|
|
2293
|
+
]), 1040, ["type"]));
|
|
2294
|
+
}
|
|
2295
|
+
}), li = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI4N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AwIDYuN3oiIGZpbGw9IiMwMDAiLz48cGF0aCBkPSJNNzIuODg5IDQwLjIwMWMuMDYxLjQyNi0uNDI2Ljg1My0xLjA2NS45NDRzLTEuMjQ4LS4xODMtMS4zMDgtLjU3OS40MjYtLjg1MyAxLjA2NS0uOTQ0IDEuMjE3LjE0MyAxLjMwOC41Nzl6bS45NDMgMy43MTVhMi4zOCAyLjM4IDAgMCAxLTEuNDkxLjgyMmMtLjA2MS0uMDYxLS4xNTItLjA2MS0uMjc0LS4wNjEtLjA3OS4wMDUtLjE1NS4wMzctLjIxMy4wOTEtLjY0OC4wMTQtMS4yODgtLjE0NC0xLjg1Ni0uNDU3YTIuMzggMi4zOCAwIDAgMCAxLjgyNi43MDFjLjA4Ny4wNjYuMTk1LjA5OS4zMDQuMDkxLjEyMi0uMDMuMjEzLS4wNjEuMjQzLS4xNTIuNzkxLS4xODMgMS40My0uNTg4IDEuNDYxLTEuMDQ1di4wMDl6IiBmaWxsPSIjZmZmIi8+PC9zdmc+Cg==", ii = { class: "h-12 space-x-4 flex items-center" }, ri = /* @__PURE__ */ x("img", {
|
|
2296
|
+
class: "h-full",
|
|
2297
|
+
src: li,
|
|
2298
|
+
alt: "Rotki"
|
|
2299
|
+
}, null, -1), ui = {
|
|
2300
|
+
key: 0,
|
|
2301
|
+
class: "text-h4 text-rui-light-primary"
|
|
2302
|
+
}, Ti = /* @__PURE__ */ $({
|
|
2303
|
+
name: "RuiLogo",
|
|
2304
|
+
__name: "Logo",
|
|
2305
|
+
props: {
|
|
2306
|
+
text: { type: Boolean, default: !1 }
|
|
2307
|
+
},
|
|
2308
|
+
setup(e) {
|
|
2309
|
+
return (s, n) => (c(), f("div", ii, [
|
|
2310
|
+
ri,
|
|
2311
|
+
s.text ? (c(), f("div", ui, "rotki")) : E("", !0)
|
|
2312
|
+
]));
|
|
2313
|
+
}
|
|
2314
|
+
});
|
|
2315
|
+
export {
|
|
2316
|
+
_i as A,
|
|
2317
|
+
ji as B,
|
|
2318
|
+
vi as C,
|
|
2319
|
+
Li as F,
|
|
2320
|
+
ve as R,
|
|
2321
|
+
W as S,
|
|
2322
|
+
Ti as _,
|
|
2323
|
+
fi as a,
|
|
2324
|
+
Ce as b,
|
|
2325
|
+
C as c,
|
|
2326
|
+
Ve as d,
|
|
2327
|
+
bi as e,
|
|
2328
|
+
Ni as f,
|
|
2329
|
+
mi as g,
|
|
2330
|
+
gi as h,
|
|
2331
|
+
tt as i
|
|
2332
|
+
};
|