@maltjoy/core-vue 1.0.0-beta.2 → 1.0.0-beta.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/README.md +2 -0
- package/dist/components/JoyBadge/JoyBadge.types.d.ts +2 -0
- package/dist/components/JoyBadge/VJoyBadge.vue.d.ts +43 -0
- package/dist/components/JoyButton/VJoyButton.vue.d.ts +1 -1
- package/dist/components/JoyCheckbox/VJoyCheckbox.vue.d.ts +23 -0
- package/dist/components/JoyDropdown/JoyDropdown.types.d.ts +2 -2
- package/dist/components/JoyDropdownList/JoyDropdownList.types.d.ts +1 -1
- package/dist/components/JoyHighlight/JoyHighlight.types.d.ts +1 -1
- package/dist/components/JoyHighlight/VJoyHighlight.vue.d.ts +3 -3
- package/dist/components/index.d.ts +2 -1
- package/dist/joy-vue.js +1044 -884
- package/dist/joy-vue.umd.cjs +1 -1
- package/dist/style.css +1 -1
- package/joy-components.d.ts +27 -24
- package/package.json +17 -15
package/dist/joy-vue.js
CHANGED
|
@@ -1,11 +1,47 @@
|
|
|
1
|
-
import { defineComponent as $, openBlock as m, createElementBlock as p, normalizeClass as k,
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as $, openBlock as m, createElementBlock as p, normalizeClass as k, renderSlot as g, createTextVNode as J, toDisplayString as I, useAttrs as Re, computed as x, createBlock as q, resolveDynamicComponent as ce, unref as _, withCtx as L, createCommentVNode as w, createElementVNode as h, ref as b, mergeProps as Q, createVNode as fe, pushScopeId as te, popScopeId as le, getCurrentScope as ot, onScopeDispose as nt, getCurrentInstance as at, onMounted as Z, nextTick as Me, watch as B, h as it, reactive as X, onBeforeUnmount as Ne, normalizeStyle as K, Fragment as ye, renderList as ve, normalizeProps as me, guardReactiveProps as pe, Teleport as rt, useSlots as W, onBeforeMount as st, createSlots as ut } from "vue";
|
|
2
|
+
const dt = ["info", "gray", "green", "orange", "red", "teal", "turquoise", "pink", "dark-blue", "yellow"], ct = /* @__PURE__ */ $({
|
|
3
|
+
__name: "VJoyBadge",
|
|
4
|
+
props: {
|
|
5
|
+
/**
|
|
6
|
+
* Use label or slot in order to inject the text.
|
|
7
|
+
*/
|
|
8
|
+
label: {
|
|
9
|
+
type: String,
|
|
10
|
+
default: ""
|
|
11
|
+
},
|
|
12
|
+
/**
|
|
13
|
+
* Color of the badge. Override the color with `--badge-bg-color` and `--badge-circle-color` if needed
|
|
14
|
+
*/
|
|
15
|
+
variant: {
|
|
16
|
+
type: String,
|
|
17
|
+
validator(e) {
|
|
18
|
+
return dt.includes(e);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
setup(e) {
|
|
23
|
+
return (t, l) => (m(), p("span", {
|
|
24
|
+
class: k(["joy-badge", `joy-badge__${e.variant}`]),
|
|
25
|
+
role: "status"
|
|
26
|
+
}, [
|
|
27
|
+
g(t.$slots, "default", {}, () => [
|
|
28
|
+
J(I(e.label), 1)
|
|
29
|
+
], !0)
|
|
30
|
+
], 2));
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
const V = (e, t) => {
|
|
34
|
+
const l = e.__vccOpts || e;
|
|
35
|
+
for (const [o, n] of t)
|
|
36
|
+
l[o] = n;
|
|
37
|
+
return l;
|
|
38
|
+
}, ft = /* @__PURE__ */ V(ct, [["__scopeId", "data-v-c0310e42"]]), yt = ["teal", "white"], vt = /* @__PURE__ */ $({
|
|
3
39
|
__name: "VJoySpinner",
|
|
4
40
|
props: {
|
|
5
41
|
color: {
|
|
6
42
|
type: String,
|
|
7
43
|
validator(e) {
|
|
8
|
-
return
|
|
44
|
+
return yt.includes(e);
|
|
9
45
|
}
|
|
10
46
|
}
|
|
11
47
|
},
|
|
@@ -15,12 +51,7 @@ const rt = ["teal", "white"], st = /* @__PURE__ */ $({
|
|
|
15
51
|
}, null, 2));
|
|
16
52
|
}
|
|
17
53
|
});
|
|
18
|
-
const
|
|
19
|
-
const l = e.__vccOpts || e;
|
|
20
|
-
for (const [a, o] of t)
|
|
21
|
-
l[a] = o;
|
|
22
|
-
return l;
|
|
23
|
-
}, Ne = /* @__PURE__ */ V(st, [["__scopeId", "data-v-616a29d0"]]), ut = ["primary", "secondary"], dt = ["neutral", "success", "info", "warning", "error"], ct = ["main", "admin", "ghost"], ft = [...ut, ...ct], yt = ["large", "medium", "small", "xsmall", "xxsmall"], mt = ["name", "size"], vt = { class: "joy-button--slot" }, pt = /* @__PURE__ */ $({
|
|
54
|
+
const He = /* @__PURE__ */ V(vt, [["__scopeId", "data-v-616a29d0"]]), mt = ["primary", "secondary"], pt = ["neutral", "success", "info", "warning", "error"], ht = ["main", "admin", "ghost"], bt = [...mt, ...ht], gt = ["large", "medium", "small", "xsmall", "xxsmall"], _t = ["name", "size"], wt = { class: "joy-button--slot" }, St = /* @__PURE__ */ $({
|
|
24
55
|
__name: "VJoyButton",
|
|
25
56
|
props: {
|
|
26
57
|
/**
|
|
@@ -43,7 +74,7 @@ const V = (e, t) => {
|
|
|
43
74
|
type: String,
|
|
44
75
|
default: "primary",
|
|
45
76
|
validator(e) {
|
|
46
|
-
return
|
|
77
|
+
return bt.includes(e);
|
|
47
78
|
}
|
|
48
79
|
},
|
|
49
80
|
/** Button or Link size */
|
|
@@ -51,12 +82,12 @@ const V = (e, t) => {
|
|
|
51
82
|
type: String,
|
|
52
83
|
default: "medium",
|
|
53
84
|
validator(e) {
|
|
54
|
-
return
|
|
85
|
+
return gt.includes(e);
|
|
55
86
|
}
|
|
56
87
|
}
|
|
57
88
|
},
|
|
58
89
|
setup(e) {
|
|
59
|
-
const t = e, l =
|
|
90
|
+
const t = e, l = Re(), o = x(() => {
|
|
60
91
|
switch (t.size) {
|
|
61
92
|
case "xxsmall":
|
|
62
93
|
return "xsmall";
|
|
@@ -64,9 +95,11 @@ const V = (e, t) => {
|
|
|
64
95
|
return "xxsmall";
|
|
65
96
|
case "small":
|
|
66
97
|
return "xsmall";
|
|
98
|
+
default:
|
|
99
|
+
return "small";
|
|
67
100
|
}
|
|
68
|
-
}),
|
|
69
|
-
return (r, s) => (m(),
|
|
101
|
+
}), n = x(() => ["white", "ghost", "secondary"].includes(t.variant) ? "teal" : "white");
|
|
102
|
+
return (r, s) => (m(), q(ce(_(l).href ? "a" : "button"), {
|
|
70
103
|
disabled: e.loading || _(l).disabled,
|
|
71
104
|
class: k([
|
|
72
105
|
"joy-button",
|
|
@@ -82,22 +115,22 @@ const V = (e, t) => {
|
|
|
82
115
|
e.icon ? (m(), p("joy-icon", {
|
|
83
116
|
key: 0,
|
|
84
117
|
name: e.icon,
|
|
85
|
-
size: _(
|
|
118
|
+
size: _(o),
|
|
86
119
|
lazy: !1
|
|
87
|
-
}, null, 8,
|
|
88
|
-
e.loading ? (m(),
|
|
120
|
+
}, null, 8, _t)) : w("", !0),
|
|
121
|
+
e.loading ? (m(), q(He, {
|
|
89
122
|
key: 1,
|
|
90
|
-
color: _(
|
|
123
|
+
color: _(n)
|
|
91
124
|
}, null, 8, ["color"])) : w("", !0),
|
|
92
|
-
h("span",
|
|
93
|
-
|
|
125
|
+
h("span", wt, [
|
|
126
|
+
g(r.$slots, "default", {}, void 0, !0)
|
|
94
127
|
])
|
|
95
128
|
]),
|
|
96
129
|
_: 3
|
|
97
130
|
}, 8, ["disabled", "class"]));
|
|
98
131
|
}
|
|
99
132
|
});
|
|
100
|
-
const
|
|
133
|
+
const jt = /* @__PURE__ */ V(St, [["__scopeId", "data-v-ff4bd9af"]]), kt = ["aria-checked", "aria-hidden"], $t = { class: "joy-checkbox__input-wrapper" }, Vt = ["id", "name", "disabled", "checked", "required", "aria-checked", "value", "indeterminate"], xt = { class: "joy-checkbox__content-wrapper" }, Ot = { class: "joy-checkbox__content" }, It = /* @__PURE__ */ $({
|
|
101
134
|
__name: "VJoyCheckbox",
|
|
102
135
|
props: {
|
|
103
136
|
/** Can't be used in addition of v-model. See usage : https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/checkbox#indeterminate_state_checkboxes */
|
|
@@ -105,6 +138,14 @@ const ht = /* @__PURE__ */ V(pt, [["__scopeId", "data-v-62aca3ad"]]), bt = ["ari
|
|
|
105
138
|
type: Boolean,
|
|
106
139
|
default: !1
|
|
107
140
|
},
|
|
141
|
+
/**
|
|
142
|
+
* Internal purpose in order to prevent double focus mark on selectable-item
|
|
143
|
+
* @internal
|
|
144
|
+
*/
|
|
145
|
+
displayFocus: {
|
|
146
|
+
type: Boolean,
|
|
147
|
+
default: !0
|
|
148
|
+
},
|
|
108
149
|
/** Use it to replace the default slot */
|
|
109
150
|
label: {
|
|
110
151
|
type: String
|
|
@@ -135,17 +176,23 @@ const ht = /* @__PURE__ */ V(pt, [["__scopeId", "data-v-62aca3ad"]]), bt = ["ari
|
|
|
135
176
|
default: !1
|
|
136
177
|
}
|
|
137
178
|
},
|
|
138
|
-
emits: ["update:checked"],
|
|
179
|
+
emits: ["update:checked", "focus", "blur"],
|
|
139
180
|
setup(e, { expose: t, emit: l }) {
|
|
140
|
-
const
|
|
141
|
-
onChange: (
|
|
142
|
-
const
|
|
143
|
-
r.value = !1, l("update:checked",
|
|
181
|
+
const o = e, n = b(), r = b(o.indeterminate), s = b(!1), a = {
|
|
182
|
+
onChange: (c) => {
|
|
183
|
+
const f = c.target.checked;
|
|
184
|
+
r.value = !1, l("update:checked", f);
|
|
185
|
+
},
|
|
186
|
+
onFocus: () => {
|
|
187
|
+
s.value = !0, l("focus");
|
|
188
|
+
},
|
|
189
|
+
onBlur: () => {
|
|
190
|
+
s.value = !1, l("blur");
|
|
144
191
|
}
|
|
145
192
|
};
|
|
146
193
|
return t({
|
|
147
194
|
isIndeterminate: r
|
|
148
|
-
}), (
|
|
195
|
+
}), (c, f) => (m(), p("div", {
|
|
149
196
|
"aria-checked": e.checked,
|
|
150
197
|
"aria-hidden": e.disabled
|
|
151
198
|
}, [
|
|
@@ -154,55 +201,62 @@ const ht = /* @__PURE__ */ V(pt, [["__scopeId", "data-v-62aca3ad"]]), bt = ["ari
|
|
|
154
201
|
"joy-checkbox",
|
|
155
202
|
{
|
|
156
203
|
"joy-checkbox__checked": e.checked,
|
|
157
|
-
"joy-checkbox__indeterminate": r.value
|
|
204
|
+
"joy-checkbox__indeterminate": r.value,
|
|
205
|
+
"joy-checkbox__focusing": s.value && e.displayFocus
|
|
158
206
|
}
|
|
159
207
|
])
|
|
160
208
|
}, [
|
|
161
|
-
h("
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
209
|
+
h("div", $t, [
|
|
210
|
+
h("input", {
|
|
211
|
+
id: e.id,
|
|
212
|
+
ref_key: "input",
|
|
213
|
+
ref: n,
|
|
214
|
+
type: "checkbox",
|
|
215
|
+
class: "joy-checkbox__input",
|
|
216
|
+
role: "checkbox",
|
|
217
|
+
name: e.name,
|
|
218
|
+
disabled: e.disabled,
|
|
219
|
+
checked: e.checked,
|
|
220
|
+
required: e.required,
|
|
221
|
+
"aria-checked": e.checked,
|
|
222
|
+
value: e.value,
|
|
223
|
+
indeterminate: r.value,
|
|
224
|
+
onChange: f[0] || (f[0] = //@ts-ignore
|
|
225
|
+
(...u) => a.onChange && a.onChange(...u)),
|
|
226
|
+
onFocus: f[1] || (f[1] = //@ts-ignore
|
|
227
|
+
(...u) => a.onFocus && a.onFocus(...u)),
|
|
228
|
+
onBlur: f[2] || (f[2] = //@ts-ignore
|
|
229
|
+
(...u) => a.onBlur && a.onBlur(...u))
|
|
230
|
+
}, null, 40, Vt)
|
|
231
|
+
]),
|
|
232
|
+
h("div", xt, [
|
|
233
|
+
g(c.$slots, "default", {}, () => [
|
|
234
|
+
J(I(e.label), 1)
|
|
181
235
|
], !0),
|
|
182
|
-
h("div",
|
|
183
|
-
|
|
236
|
+
h("div", Ot, [
|
|
237
|
+
g(c.$slots, "checkbox-content", {}, void 0, !0)
|
|
184
238
|
])
|
|
185
239
|
])
|
|
186
240
|
], 2)
|
|
187
|
-
], 8,
|
|
241
|
+
], 8, kt));
|
|
188
242
|
}
|
|
189
243
|
});
|
|
190
|
-
const
|
|
244
|
+
const he = /* @__PURE__ */ V(It, [["__scopeId", "data-v-a39797a6"]]), We = (e) => (te("data-v-0d1ab3f2"), e = e(), le(), e), Bt = { class: "joy-counter" }, Lt = ["aria-label", "disabled"], Et = /* @__PURE__ */ We(() => /* @__PURE__ */ h("joy-icon", {
|
|
191
245
|
name: "minus",
|
|
192
246
|
color: "teal",
|
|
193
247
|
lazy: !1
|
|
194
|
-
}, null, -1)),
|
|
195
|
-
|
|
196
|
-
],
|
|
248
|
+
}, null, -1)), Ct = [
|
|
249
|
+
Et
|
|
250
|
+
], Pt = { class: "joy-counter__input-wrapper" }, Jt = ["id", "min", "max", "aria-invalid", "name", "required", "value"], qt = ["aria-label", "disabled"], Tt = /* @__PURE__ */ We(() => /* @__PURE__ */ h("joy-icon", {
|
|
197
251
|
name: "add",
|
|
198
252
|
lazy: !1,
|
|
199
253
|
color: "teal"
|
|
200
|
-
}, null, -1)),
|
|
201
|
-
|
|
202
|
-
],
|
|
254
|
+
}, null, -1)), zt = [
|
|
255
|
+
Tt
|
|
256
|
+
], At = {
|
|
203
257
|
key: 0,
|
|
204
258
|
class: "joy-counter_error"
|
|
205
|
-
},
|
|
259
|
+
}, Ft = /* @__PURE__ */ $({
|
|
206
260
|
__name: "VJoyCounter",
|
|
207
261
|
props: {
|
|
208
262
|
/** Removes any interactivity */
|
|
@@ -269,43 +323,46 @@ const pe = /* @__PURE__ */ V(St, [["__scopeId", "data-v-d6496829"]]), He = (e) =
|
|
|
269
323
|
},
|
|
270
324
|
emits: ["update:modelValue"],
|
|
271
325
|
setup(e, { expose: t, emit: l }) {
|
|
272
|
-
const
|
|
273
|
-
function r() {
|
|
274
|
-
const d = u(!1);
|
|
275
|
-
d >= 0 ? l("update:modelValue", d <= a.min ? a.min : d) : l("update:modelValue", 0), n();
|
|
276
|
-
}
|
|
326
|
+
const o = e, n = b(!1), r = b(!1);
|
|
277
327
|
function s() {
|
|
278
|
-
const d =
|
|
279
|
-
|
|
328
|
+
const d = f(!1);
|
|
329
|
+
d >= 0 ? l("update:modelValue", d <= o.min ? o.min : d) : l("update:modelValue", 0), c();
|
|
280
330
|
}
|
|
281
|
-
function
|
|
282
|
-
|
|
331
|
+
function a() {
|
|
332
|
+
const d = f();
|
|
333
|
+
o.max && d <= o.max ? l("update:modelValue", d >= o.max ? o.max : d) : o.max && d > o.max ? l("update:modelValue", o.max) : l("update:modelValue", d), c();
|
|
283
334
|
}
|
|
284
|
-
function
|
|
285
|
-
|
|
286
|
-
return parseFloat(d ? (a.modelValue + a.step).toFixed(S) : (a.modelValue - a.step).toFixed(S));
|
|
335
|
+
function c() {
|
|
336
|
+
n.value = !u();
|
|
287
337
|
}
|
|
288
|
-
function
|
|
289
|
-
|
|
338
|
+
function f(d = !0) {
|
|
339
|
+
const j = o.step.toString().split("."), S = j.length === 2 ? j[1].length : 0;
|
|
340
|
+
return parseFloat(d ? (o.modelValue + o.step).toFixed(S) : (o.modelValue - o.step).toFixed(S));
|
|
290
341
|
}
|
|
291
|
-
function
|
|
292
|
-
return
|
|
342
|
+
function u() {
|
|
343
|
+
return v() && i();
|
|
293
344
|
}
|
|
294
345
|
function v() {
|
|
295
|
-
return
|
|
346
|
+
return !o.max || o.modelValue <= o.max;
|
|
296
347
|
}
|
|
297
|
-
|
|
348
|
+
function i() {
|
|
349
|
+
return o.min <= o.modelValue;
|
|
350
|
+
}
|
|
351
|
+
const y = {
|
|
298
352
|
onInput: (d) => {
|
|
299
|
-
l("update:modelValue", +d.target.value || 0),
|
|
353
|
+
l("update:modelValue", +d.target.value || 0), n.value = !1;
|
|
354
|
+
},
|
|
355
|
+
onFocus: () => {
|
|
356
|
+
r.value = !0;
|
|
300
357
|
},
|
|
301
358
|
onBlur: () => {
|
|
302
|
-
|
|
359
|
+
r.value = !1, c();
|
|
303
360
|
}
|
|
304
361
|
};
|
|
305
362
|
return t({
|
|
306
|
-
props:
|
|
307
|
-
}), (d,
|
|
308
|
-
e.label ? (m(),
|
|
363
|
+
props: o
|
|
364
|
+
}), (d, j) => (m(), p("div", Bt, [
|
|
365
|
+
e.label ? (m(), q(_(N), {
|
|
309
366
|
key: 0,
|
|
310
367
|
for: e.id,
|
|
311
368
|
required: e.required && e.requiredMark,
|
|
@@ -313,95 +370,101 @@ const pe = /* @__PURE__ */ V(St, [["__scopeId", "data-v-d6496829"]]), He = (e) =
|
|
|
313
370
|
size: e.labelSize
|
|
314
371
|
}, {
|
|
315
372
|
default: L(() => [
|
|
316
|
-
|
|
317
|
-
|
|
373
|
+
g(d.$slots, "default", {}, () => [
|
|
374
|
+
J(I(e.label), 1)
|
|
318
375
|
], !0)
|
|
319
376
|
]),
|
|
320
377
|
_: 3
|
|
321
378
|
}, 8, ["for", "required", "optional-label", "size"])) : w("", !0),
|
|
322
|
-
h("div",
|
|
379
|
+
h("div", {
|
|
380
|
+
class: k(["joy-counter__wrapper", { "joy-counter--focusing": r.value }])
|
|
381
|
+
}, [
|
|
323
382
|
h("button", {
|
|
324
383
|
class: "joy-counter__decrement",
|
|
325
384
|
type: "button",
|
|
326
385
|
"aria-label": e.labelDecrement,
|
|
327
386
|
disabled: e.modelValue <= e.min,
|
|
328
|
-
onClick:
|
|
329
|
-
},
|
|
330
|
-
h("
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
387
|
+
onClick: s
|
|
388
|
+
}, Ct, 8, Lt),
|
|
389
|
+
h("div", Pt, [
|
|
390
|
+
h("input", Q({
|
|
391
|
+
id: e.id,
|
|
392
|
+
ref: "input",
|
|
393
|
+
type: "number",
|
|
394
|
+
class: { "joy-counter__invalid": e.invalid || n.value },
|
|
395
|
+
min: e.min,
|
|
396
|
+
max: e.max,
|
|
397
|
+
"aria-invalid": e.invalid || n.value,
|
|
398
|
+
name: e.name,
|
|
399
|
+
required: e.required,
|
|
400
|
+
step: "any",
|
|
401
|
+
value: e.modelValue
|
|
402
|
+
}, d.$attrs, {
|
|
403
|
+
onInput: j[0] || (j[0] = //@ts-ignore
|
|
404
|
+
(...S) => y.onInput && y.onInput(...S)),
|
|
405
|
+
onBlur: j[1] || (j[1] = //@ts-ignore
|
|
406
|
+
(...S) => y.onBlur && y.onBlur(...S)),
|
|
407
|
+
onFocus: j[2] || (j[2] = //@ts-ignore
|
|
408
|
+
(...S) => y.onFocus && y.onFocus(...S))
|
|
409
|
+
}), null, 16, Jt)
|
|
410
|
+
]),
|
|
348
411
|
h("button", {
|
|
349
412
|
class: "joy-counter__increment",
|
|
350
413
|
type: "button",
|
|
351
414
|
"aria-label": e.labelIncrement,
|
|
352
415
|
disabled: e.max ? e.modelValue >= e.max : !1,
|
|
353
|
-
onClick:
|
|
354
|
-
},
|
|
355
|
-
e.invalid && e.errorMessage ? (m(), p("div",
|
|
356
|
-
|
|
416
|
+
onClick: a
|
|
417
|
+
}, zt, 8, qt),
|
|
418
|
+
e.invalid && e.errorMessage ? (m(), p("div", At, [
|
|
419
|
+
fe(_(et), { "no-html-error-text": e.errorMessage }, null, 8, ["no-html-error-text"])
|
|
357
420
|
])) : w("", !0)
|
|
358
|
-
])
|
|
421
|
+
], 2)
|
|
359
422
|
]));
|
|
360
423
|
}
|
|
361
424
|
});
|
|
362
|
-
const
|
|
363
|
-
var
|
|
364
|
-
const
|
|
365
|
-
},
|
|
366
|
-
function
|
|
425
|
+
const Dt = /* @__PURE__ */ V(Ft, [["__scopeId", "data-v-0d1ab3f2"]]);
|
|
426
|
+
var _e;
|
|
427
|
+
const U = typeof window < "u", Ue = (e) => typeof e == "string", z = () => {
|
|
428
|
+
}, ee = U && ((_e = window == null ? void 0 : window.navigator) == null ? void 0 : _e.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent);
|
|
429
|
+
function C(e) {
|
|
367
430
|
return typeof e == "function" ? e() : _(e);
|
|
368
431
|
}
|
|
369
|
-
function
|
|
370
|
-
function l(...
|
|
371
|
-
return new Promise((
|
|
372
|
-
Promise.resolve(e(() => t.apply(this,
|
|
432
|
+
function Ge(e, t) {
|
|
433
|
+
function l(...o) {
|
|
434
|
+
return new Promise((n, r) => {
|
|
435
|
+
Promise.resolve(e(() => t.apply(this, o), { fn: t, thisArg: this, args: o })).then(n).catch(r);
|
|
373
436
|
});
|
|
374
437
|
}
|
|
375
438
|
return l;
|
|
376
439
|
}
|
|
377
|
-
function
|
|
378
|
-
let l,
|
|
379
|
-
const r = (
|
|
380
|
-
clearTimeout(
|
|
440
|
+
function Rt(e, t = {}) {
|
|
441
|
+
let l, o, n = z;
|
|
442
|
+
const r = (a) => {
|
|
443
|
+
clearTimeout(a), n(), n = z;
|
|
381
444
|
};
|
|
382
|
-
return (
|
|
383
|
-
const
|
|
384
|
-
return l && r(l),
|
|
385
|
-
|
|
386
|
-
l && r(l),
|
|
387
|
-
},
|
|
388
|
-
|
|
389
|
-
},
|
|
445
|
+
return (a) => {
|
|
446
|
+
const c = C(e), f = C(t.maxWait);
|
|
447
|
+
return l && r(l), c <= 0 || f !== void 0 && f <= 0 ? (o && (r(o), o = null), Promise.resolve(a())) : new Promise((u, v) => {
|
|
448
|
+
n = t.rejectOnCancel ? v : u, f && !o && (o = setTimeout(() => {
|
|
449
|
+
l && r(l), o = null, u(a());
|
|
450
|
+
}, f)), l = setTimeout(() => {
|
|
451
|
+
o && r(o), o = null, u(a());
|
|
452
|
+
}, c);
|
|
390
453
|
});
|
|
391
454
|
};
|
|
392
455
|
}
|
|
393
|
-
function
|
|
394
|
-
let
|
|
395
|
-
const
|
|
396
|
-
r && (clearTimeout(r), r = void 0,
|
|
456
|
+
function Mt(e, t = !0, l = !0, o = !1) {
|
|
457
|
+
let n = 0, r, s = !0, a = z, c;
|
|
458
|
+
const f = () => {
|
|
459
|
+
r && (clearTimeout(r), r = void 0, a(), a = z);
|
|
397
460
|
};
|
|
398
461
|
return (v) => {
|
|
399
|
-
const i =
|
|
400
|
-
return
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
}, Math.max(0, i -
|
|
404
|
-
})), !l && !r && (r = setTimeout(() => s = !0, i)), s = !1,
|
|
462
|
+
const i = C(e), y = Date.now() - n, d = () => c = v();
|
|
463
|
+
return f(), i <= 0 ? (n = Date.now(), d()) : (y > i && (l || !s) ? (n = Date.now(), d()) : t && (c = new Promise((j, S) => {
|
|
464
|
+
a = o ? S : j, r = setTimeout(() => {
|
|
465
|
+
n = Date.now(), s = !0, j(d()), f();
|
|
466
|
+
}, Math.max(0, i - y));
|
|
467
|
+
})), !l && !r && (r = setTimeout(() => s = !0, i)), s = !1, c);
|
|
405
468
|
};
|
|
406
469
|
}
|
|
407
470
|
const R = {
|
|
@@ -409,97 +472,140 @@ const R = {
|
|
|
409
472
|
updated: "updated",
|
|
410
473
|
unmounted: "unmounted"
|
|
411
474
|
};
|
|
412
|
-
function
|
|
475
|
+
function Nt(e) {
|
|
413
476
|
return e;
|
|
414
477
|
}
|
|
415
|
-
function
|
|
416
|
-
return
|
|
478
|
+
function G(e) {
|
|
479
|
+
return ot() ? (nt(e), !0) : !1;
|
|
417
480
|
}
|
|
418
|
-
function
|
|
419
|
-
return
|
|
481
|
+
function Ht(e, t = 200, l = {}) {
|
|
482
|
+
return Ge(Rt(t, l), e);
|
|
420
483
|
}
|
|
421
|
-
function
|
|
422
|
-
return
|
|
484
|
+
function Wt(e, t = 200, l = !1, o = !0, n = !1) {
|
|
485
|
+
return Ge(Mt(t, l, o, n), e);
|
|
423
486
|
}
|
|
424
|
-
function
|
|
425
|
-
return typeof e == "function" ?
|
|
487
|
+
function Ut(e) {
|
|
488
|
+
return typeof e == "function" ? x(e) : b(e);
|
|
426
489
|
}
|
|
427
|
-
function
|
|
428
|
-
|
|
490
|
+
function Ke(e, t = !0) {
|
|
491
|
+
at() ? Z(e) : t ? e() : Me(e);
|
|
429
492
|
}
|
|
430
|
-
function
|
|
493
|
+
function H(e) {
|
|
431
494
|
var t;
|
|
432
|
-
const l =
|
|
495
|
+
const l = C(e);
|
|
433
496
|
return (t = l == null ? void 0 : l.$el) != null ? t : l;
|
|
434
497
|
}
|
|
435
|
-
const
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
498
|
+
const be = U ? window : void 0;
|
|
499
|
+
U && window.document;
|
|
500
|
+
U && window.navigator;
|
|
501
|
+
U && window.location;
|
|
502
|
+
function ae(...e) {
|
|
503
|
+
let t, l, o, n;
|
|
504
|
+
if (Ue(e[0]) || Array.isArray(e[0]) ? ([l, o, n] = e, t = be) : [t, l, o, n] = e, !t)
|
|
439
505
|
return z;
|
|
440
|
-
Array.isArray(l) || (l = [l]), Array.isArray(
|
|
506
|
+
Array.isArray(l) || (l = [l]), Array.isArray(o) || (o = [o]);
|
|
441
507
|
const r = [], s = () => {
|
|
442
|
-
r.forEach((
|
|
443
|
-
},
|
|
444
|
-
s(),
|
|
445
|
-
}, { immediate: !0, flush: "post" }),
|
|
446
|
-
|
|
508
|
+
r.forEach((u) => u()), r.length = 0;
|
|
509
|
+
}, a = (u, v, i, y) => (u.addEventListener(v, i, y), () => u.removeEventListener(v, i, y)), c = B(() => [H(t), C(n)], ([u, v]) => {
|
|
510
|
+
s(), u && r.push(...l.flatMap((i) => o.map((y) => a(u, i, y, v))));
|
|
511
|
+
}, { immediate: !0, flush: "post" }), f = () => {
|
|
512
|
+
c(), s();
|
|
447
513
|
};
|
|
448
|
-
return
|
|
514
|
+
return G(f), f;
|
|
449
515
|
}
|
|
450
|
-
let
|
|
451
|
-
function
|
|
452
|
-
const { window:
|
|
453
|
-
if (!
|
|
516
|
+
let we = !1;
|
|
517
|
+
function Gt(e, t, l = {}) {
|
|
518
|
+
const { window: o = be, ignore: n = [], capture: r = !0, detectIframe: s = !1 } = l;
|
|
519
|
+
if (!o)
|
|
454
520
|
return;
|
|
455
|
-
|
|
456
|
-
let
|
|
457
|
-
const
|
|
458
|
-
if (typeof
|
|
459
|
-
return Array.from(
|
|
521
|
+
ee && !we && (we = !0, Array.from(o.document.body.children).forEach((i) => i.addEventListener("click", z)));
|
|
522
|
+
let a = !0;
|
|
523
|
+
const c = (i) => n.some((y) => {
|
|
524
|
+
if (typeof y == "string")
|
|
525
|
+
return Array.from(o.document.querySelectorAll(y)).some((d) => d === i.target || i.composedPath().includes(d));
|
|
460
526
|
{
|
|
461
|
-
const
|
|
462
|
-
return
|
|
527
|
+
const d = H(y);
|
|
528
|
+
return d && (i.target === d || i.composedPath().includes(d));
|
|
463
529
|
}
|
|
464
|
-
}),
|
|
465
|
-
|
|
466
|
-
const
|
|
467
|
-
if (!(!
|
|
468
|
-
if (i.detail === 0 && (
|
|
469
|
-
|
|
530
|
+
}), u = [
|
|
531
|
+
ae(o, "click", (i) => {
|
|
532
|
+
const y = H(e);
|
|
533
|
+
if (!(!y || y === i.target || i.composedPath().includes(y))) {
|
|
534
|
+
if (i.detail === 0 && (a = !c(i)), !a) {
|
|
535
|
+
a = !0;
|
|
470
536
|
return;
|
|
471
537
|
}
|
|
472
538
|
t(i);
|
|
473
539
|
}
|
|
474
540
|
}, { passive: !0, capture: r }),
|
|
475
|
-
|
|
476
|
-
const
|
|
477
|
-
|
|
541
|
+
ae(o, "pointerdown", (i) => {
|
|
542
|
+
const y = H(e);
|
|
543
|
+
y && (a = !i.composedPath().includes(y) && !c(i));
|
|
478
544
|
}, { passive: !0 }),
|
|
479
|
-
s &&
|
|
480
|
-
var
|
|
481
|
-
const
|
|
482
|
-
((
|
|
545
|
+
s && ae(o, "blur", (i) => {
|
|
546
|
+
var y;
|
|
547
|
+
const d = H(e);
|
|
548
|
+
((y = o.document.activeElement) == null ? void 0 : y.tagName) === "IFRAME" && !(d != null && d.contains(o.document.activeElement)) && t(i);
|
|
483
549
|
})
|
|
484
550
|
].filter(Boolean);
|
|
485
|
-
return () =>
|
|
551
|
+
return () => u.forEach((i) => i());
|
|
552
|
+
}
|
|
553
|
+
function Kt(e, t = !1) {
|
|
554
|
+
const l = b(), o = () => l.value = Boolean(e());
|
|
555
|
+
return o(), Ke(o, t), l;
|
|
486
556
|
}
|
|
487
|
-
const
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
var
|
|
557
|
+
const ie = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, re = "__vueuse_ssr_handlers__";
|
|
558
|
+
ie[re] = ie[re] || {};
|
|
559
|
+
ie[re];
|
|
560
|
+
var Se = Object.getOwnPropertySymbols, Qt = Object.prototype.hasOwnProperty, Zt = Object.prototype.propertyIsEnumerable, Yt = (e, t) => {
|
|
561
|
+
var l = {};
|
|
562
|
+
for (var o in e)
|
|
563
|
+
Qt.call(e, o) && t.indexOf(o) < 0 && (l[o] = e[o]);
|
|
564
|
+
if (e != null && Se)
|
|
565
|
+
for (var o of Se(e))
|
|
566
|
+
t.indexOf(o) < 0 && Zt.call(e, o) && (l[o] = e[o]);
|
|
567
|
+
return l;
|
|
568
|
+
};
|
|
569
|
+
function Xt(e, t, l = {}) {
|
|
570
|
+
const o = l, { window: n = be } = o, r = Yt(o, ["window"]);
|
|
571
|
+
let s;
|
|
572
|
+
const a = Kt(() => n && "ResizeObserver" in n), c = () => {
|
|
573
|
+
s && (s.disconnect(), s = void 0);
|
|
574
|
+
}, f = B(() => H(e), (v) => {
|
|
575
|
+
c(), a.value && n && v && (s = new ResizeObserver(t), s.observe(v, r));
|
|
576
|
+
}, { immediate: !0, flush: "post" }), u = () => {
|
|
577
|
+
c(), f();
|
|
578
|
+
};
|
|
579
|
+
return G(u), {
|
|
580
|
+
isSupported: a,
|
|
581
|
+
stop: u
|
|
582
|
+
};
|
|
583
|
+
}
|
|
584
|
+
var je;
|
|
491
585
|
(function(e) {
|
|
492
586
|
e.UP = "UP", e.RIGHT = "RIGHT", e.DOWN = "DOWN", e.LEFT = "LEFT", e.NONE = "NONE";
|
|
493
|
-
})(
|
|
494
|
-
|
|
587
|
+
})(je || (je = {}));
|
|
588
|
+
function el(e) {
|
|
589
|
+
const t = b(e == null ? void 0 : e.element), l = b(e == null ? void 0 : e.input);
|
|
590
|
+
function o() {
|
|
591
|
+
var n, r;
|
|
592
|
+
t.value && (t.value.style.height = "1px", t.value.style.height = `${(n = t.value) == null ? void 0 : n.scrollHeight}px`, (r = e == null ? void 0 : e.onResize) == null || r.call(e));
|
|
593
|
+
}
|
|
594
|
+
return B([l, t], o, { immediate: !0 }), Xt(t, () => o()), e != null && e.watch && B(e.watch, o, { immediate: !0, deep: !0 }), {
|
|
595
|
+
textarea: t,
|
|
596
|
+
input: l,
|
|
597
|
+
triggerResize: o
|
|
598
|
+
};
|
|
599
|
+
}
|
|
600
|
+
var tl = Object.defineProperty, ke = Object.getOwnPropertySymbols, ll = Object.prototype.hasOwnProperty, ol = Object.prototype.propertyIsEnumerable, $e = (e, t, l) => t in e ? tl(e, t, { enumerable: !0, configurable: !0, writable: !0, value: l }) : e[t] = l, nl = (e, t) => {
|
|
495
601
|
for (var l in t || (t = {}))
|
|
496
|
-
|
|
497
|
-
if (
|
|
498
|
-
for (var l of
|
|
499
|
-
|
|
602
|
+
ll.call(t, l) && $e(e, l, t[l]);
|
|
603
|
+
if (ke)
|
|
604
|
+
for (var l of ke(t))
|
|
605
|
+
ol.call(t, l) && $e(e, l, t[l]);
|
|
500
606
|
return e;
|
|
501
607
|
};
|
|
502
|
-
const
|
|
608
|
+
const al = {
|
|
503
609
|
easeInSine: [0.12, 0, 0.39, 0],
|
|
504
610
|
easeOutSine: [0.61, 1, 0.88, 1],
|
|
505
611
|
easeInOutSine: [0.37, 0, 0.63, 1],
|
|
@@ -525,209 +631,209 @@ const Ut = {
|
|
|
525
631
|
easeOutBack: [0.34, 1.56, 0.64, 1],
|
|
526
632
|
easeInOutBack: [0.68, -0.6, 0.32, 1.6]
|
|
527
633
|
};
|
|
528
|
-
|
|
529
|
-
linear:
|
|
530
|
-
},
|
|
531
|
-
const
|
|
634
|
+
nl({
|
|
635
|
+
linear: Nt
|
|
636
|
+
}, al);
|
|
637
|
+
const il = /* @__PURE__ */ $({
|
|
532
638
|
name: "OnClickOutside",
|
|
533
639
|
props: ["as", "options"],
|
|
534
640
|
emits: ["trigger"],
|
|
535
641
|
setup(e, { slots: t, emit: l }) {
|
|
536
|
-
const
|
|
537
|
-
return
|
|
538
|
-
l("trigger",
|
|
642
|
+
const o = b();
|
|
643
|
+
return Gt(o, (n) => {
|
|
644
|
+
l("trigger", n);
|
|
539
645
|
}, e.options), () => {
|
|
540
646
|
if (t.default)
|
|
541
|
-
return
|
|
647
|
+
return it(e.as || "div", { ref: o }, t.default());
|
|
542
648
|
};
|
|
543
649
|
}
|
|
544
650
|
});
|
|
545
|
-
function
|
|
651
|
+
function P(e) {
|
|
546
652
|
var t;
|
|
547
|
-
const l =
|
|
653
|
+
const l = C(e);
|
|
548
654
|
return (t = l == null ? void 0 : l.$el) != null ? t : l;
|
|
549
655
|
}
|
|
550
|
-
const
|
|
656
|
+
const M = U ? window : void 0;
|
|
551
657
|
function A(...e) {
|
|
552
|
-
let t, l,
|
|
553
|
-
if (
|
|
658
|
+
let t, l, o, n;
|
|
659
|
+
if (Ue(e[0]) || Array.isArray(e[0]) ? ([l, o, n] = e, t = M) : [t, l, o, n] = e, !t)
|
|
554
660
|
return z;
|
|
555
|
-
Array.isArray(l) || (l = [l]), Array.isArray(
|
|
661
|
+
Array.isArray(l) || (l = [l]), Array.isArray(o) || (o = [o]);
|
|
556
662
|
const r = [], s = () => {
|
|
557
|
-
r.forEach((
|
|
558
|
-
},
|
|
559
|
-
s(),
|
|
560
|
-
}, { immediate: !0, flush: "post" }),
|
|
561
|
-
|
|
663
|
+
r.forEach((u) => u()), r.length = 0;
|
|
664
|
+
}, a = (u, v, i, y) => (u.addEventListener(v, i, y), () => u.removeEventListener(v, i, y)), c = B(() => [P(t), C(n)], ([u, v]) => {
|
|
665
|
+
s(), u && r.push(...l.flatMap((i) => o.map((y) => a(u, i, y, v))));
|
|
666
|
+
}, { immediate: !0, flush: "post" }), f = () => {
|
|
667
|
+
c(), s();
|
|
562
668
|
};
|
|
563
|
-
return
|
|
669
|
+
return G(f), f;
|
|
564
670
|
}
|
|
565
|
-
let
|
|
566
|
-
function
|
|
567
|
-
const { window:
|
|
568
|
-
if (!
|
|
671
|
+
let Ve = !1;
|
|
672
|
+
function xe(e, t, l = {}) {
|
|
673
|
+
const { window: o = M, ignore: n = [], capture: r = !0, detectIframe: s = !1 } = l;
|
|
674
|
+
if (!o)
|
|
569
675
|
return;
|
|
570
|
-
|
|
571
|
-
let
|
|
572
|
-
const
|
|
573
|
-
if (typeof
|
|
574
|
-
return Array.from(
|
|
676
|
+
ee && !Ve && (Ve = !0, Array.from(o.document.body.children).forEach((i) => i.addEventListener("click", z)));
|
|
677
|
+
let a = !0;
|
|
678
|
+
const c = (i) => n.some((y) => {
|
|
679
|
+
if (typeof y == "string")
|
|
680
|
+
return Array.from(o.document.querySelectorAll(y)).some((d) => d === i.target || i.composedPath().includes(d));
|
|
575
681
|
{
|
|
576
|
-
const
|
|
577
|
-
return
|
|
682
|
+
const d = P(y);
|
|
683
|
+
return d && (i.target === d || i.composedPath().includes(d));
|
|
578
684
|
}
|
|
579
|
-
}),
|
|
580
|
-
A(
|
|
581
|
-
const
|
|
582
|
-
if (!(!
|
|
583
|
-
if (i.detail === 0 && (
|
|
584
|
-
|
|
685
|
+
}), u = [
|
|
686
|
+
A(o, "click", (i) => {
|
|
687
|
+
const y = P(e);
|
|
688
|
+
if (!(!y || y === i.target || i.composedPath().includes(y))) {
|
|
689
|
+
if (i.detail === 0 && (a = !c(i)), !a) {
|
|
690
|
+
a = !0;
|
|
585
691
|
return;
|
|
586
692
|
}
|
|
587
693
|
t(i);
|
|
588
694
|
}
|
|
589
695
|
}, { passive: !0, capture: r }),
|
|
590
|
-
A(
|
|
591
|
-
const
|
|
592
|
-
|
|
696
|
+
A(o, "pointerdown", (i) => {
|
|
697
|
+
const y = P(e);
|
|
698
|
+
y && (a = !i.composedPath().includes(y) && !c(i));
|
|
593
699
|
}, { passive: !0 }),
|
|
594
|
-
s && A(
|
|
595
|
-
var
|
|
596
|
-
const
|
|
597
|
-
((
|
|
700
|
+
s && A(o, "blur", (i) => {
|
|
701
|
+
var y;
|
|
702
|
+
const d = P(e);
|
|
703
|
+
((y = o.document.activeElement) == null ? void 0 : y.tagName) === "IFRAME" && !(d != null && d.contains(o.document.activeElement)) && t(i);
|
|
598
704
|
})
|
|
599
705
|
].filter(Boolean);
|
|
600
|
-
return () =>
|
|
706
|
+
return () => u.forEach((i) => i());
|
|
601
707
|
}
|
|
602
708
|
R.mounted + "", R.unmounted + "";
|
|
603
|
-
const
|
|
604
|
-
function
|
|
605
|
-
let t, l,
|
|
606
|
-
e.length === 3 ? (t = e[0], l = e[1],
|
|
607
|
-
const { target:
|
|
608
|
-
return A(
|
|
609
|
-
|
|
709
|
+
const rl = (e) => typeof e == "function" ? e : typeof e == "string" ? (t) => t.key === e : Array.isArray(e) ? (t) => e.includes(t.key) : () => !0;
|
|
710
|
+
function Oe(...e) {
|
|
711
|
+
let t, l, o = {};
|
|
712
|
+
e.length === 3 ? (t = e[0], l = e[1], o = e[2]) : e.length === 2 ? typeof e[1] == "object" ? (t = !0, l = e[0], o = e[1]) : (t = e[0], l = e[1]) : (t = !0, l = e[0]);
|
|
713
|
+
const { target: n = M, eventName: r = "keydown", passive: s = !1 } = o, a = rl(t);
|
|
714
|
+
return A(n, r, (f) => {
|
|
715
|
+
a(f) && l(f);
|
|
610
716
|
}, s);
|
|
611
717
|
}
|
|
612
|
-
var
|
|
718
|
+
var sl = Object.defineProperty, Ie = Object.getOwnPropertySymbols, ul = Object.prototype.hasOwnProperty, dl = Object.prototype.propertyIsEnumerable, Be = (e, t, l) => t in e ? sl(e, t, { enumerable: !0, configurable: !0, writable: !0, value: l }) : e[t] = l, cl = (e, t) => {
|
|
613
719
|
for (var l in t || (t = {}))
|
|
614
|
-
|
|
615
|
-
if (
|
|
616
|
-
for (var l of
|
|
617
|
-
|
|
720
|
+
ul.call(t, l) && Be(e, l, t[l]);
|
|
721
|
+
if (Ie)
|
|
722
|
+
for (var l of Ie(t))
|
|
723
|
+
dl.call(t, l) && Be(e, l, t[l]);
|
|
618
724
|
return e;
|
|
619
725
|
};
|
|
620
726
|
R.mounted + "";
|
|
621
|
-
const
|
|
622
|
-
function
|
|
623
|
-
var
|
|
624
|
-
const r =
|
|
727
|
+
const fl = 500;
|
|
728
|
+
function Le(e, t, l) {
|
|
729
|
+
var o, n;
|
|
730
|
+
const r = x(() => P(e));
|
|
625
731
|
let s;
|
|
626
|
-
function
|
|
732
|
+
function a() {
|
|
627
733
|
s && (clearTimeout(s), s = void 0);
|
|
628
734
|
}
|
|
629
|
-
function u
|
|
630
|
-
var v, i,
|
|
631
|
-
(v = l == null ? void 0 : l.modifiers) != null && v.self &&
|
|
735
|
+
function c(u) {
|
|
736
|
+
var v, i, y, d;
|
|
737
|
+
(v = l == null ? void 0 : l.modifiers) != null && v.self && u.target !== r.value || (a(), (i = l == null ? void 0 : l.modifiers) != null && i.prevent && u.preventDefault(), (y = l == null ? void 0 : l.modifiers) != null && y.stop && u.stopPropagation(), s = setTimeout(() => t(u), (d = l == null ? void 0 : l.delay) != null ? d : fl));
|
|
632
738
|
}
|
|
633
|
-
const
|
|
634
|
-
capture: (
|
|
635
|
-
once: (
|
|
739
|
+
const f = {
|
|
740
|
+
capture: (o = l == null ? void 0 : l.modifiers) == null ? void 0 : o.capture,
|
|
741
|
+
once: (n = l == null ? void 0 : l.modifiers) == null ? void 0 : n.once
|
|
636
742
|
};
|
|
637
|
-
A(r, "pointerdown",
|
|
743
|
+
A(r, "pointerdown", c, f), A(r, "pointerup", a, f), A(r, "pointerleave", a, f);
|
|
638
744
|
}
|
|
639
745
|
R.mounted + "";
|
|
640
|
-
const
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
function
|
|
644
|
-
const l =
|
|
645
|
-
return
|
|
746
|
+
const se = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, ue = "__vueuse_ssr_handlers__";
|
|
747
|
+
se[ue] = se[ue] || {};
|
|
748
|
+
se[ue];
|
|
749
|
+
function Qe(e, t = !1) {
|
|
750
|
+
const l = b(), o = () => l.value = Boolean(e());
|
|
751
|
+
return o(), Ke(o, t), l;
|
|
646
752
|
}
|
|
647
|
-
function
|
|
648
|
-
const l = t ? t.delayEnter : 0,
|
|
753
|
+
function yl(e, t = {}) {
|
|
754
|
+
const l = t ? t.delayEnter : 0, o = t ? t.delayLeave : 0, n = b(!1);
|
|
649
755
|
let r;
|
|
650
|
-
const s = (
|
|
651
|
-
const
|
|
652
|
-
r && (clearTimeout(r), r = void 0),
|
|
756
|
+
const s = (a) => {
|
|
757
|
+
const c = a ? l : o;
|
|
758
|
+
r && (clearTimeout(r), r = void 0), c ? r = setTimeout(() => n.value = a, c) : n.value = a;
|
|
653
759
|
};
|
|
654
|
-
return window && (A(e, "mouseenter", () => s(!0), { passive: !0 }), A(e, "mouseleave", () => s(!1), { passive: !0 })),
|
|
760
|
+
return window && (A(e, "mouseenter", () => s(!0), { passive: !0 }), A(e, "mouseleave", () => s(!1), { passive: !0 })), n;
|
|
655
761
|
}
|
|
656
762
|
R.mounted + "";
|
|
657
|
-
var
|
|
763
|
+
var Ee = Object.getOwnPropertySymbols, vl = Object.prototype.hasOwnProperty, ml = Object.prototype.propertyIsEnumerable, pl = (e, t) => {
|
|
658
764
|
var l = {};
|
|
659
|
-
for (var
|
|
660
|
-
|
|
661
|
-
if (e != null &&
|
|
662
|
-
for (var
|
|
663
|
-
t.indexOf(
|
|
765
|
+
for (var o in e)
|
|
766
|
+
vl.call(e, o) && t.indexOf(o) < 0 && (l[o] = e[o]);
|
|
767
|
+
if (e != null && Ee)
|
|
768
|
+
for (var o of Ee(e))
|
|
769
|
+
t.indexOf(o) < 0 && ml.call(e, o) && (l[o] = e[o]);
|
|
664
770
|
return l;
|
|
665
771
|
};
|
|
666
|
-
function
|
|
667
|
-
const
|
|
772
|
+
function hl(e, t, l = {}) {
|
|
773
|
+
const o = l, { window: n = M } = o, r = pl(o, ["window"]);
|
|
668
774
|
let s;
|
|
669
|
-
const
|
|
775
|
+
const a = Qe(() => n && "ResizeObserver" in n), c = () => {
|
|
670
776
|
s && (s.disconnect(), s = void 0);
|
|
671
|
-
},
|
|
672
|
-
|
|
673
|
-
}, { immediate: !0, flush: "post" }),
|
|
674
|
-
|
|
777
|
+
}, f = B(() => P(e), (v) => {
|
|
778
|
+
c(), a.value && n && v && (s = new ResizeObserver(t), s.observe(v, r));
|
|
779
|
+
}, { immediate: !0, flush: "post" }), u = () => {
|
|
780
|
+
c(), f();
|
|
675
781
|
};
|
|
676
|
-
return
|
|
677
|
-
isSupported:
|
|
678
|
-
stop:
|
|
782
|
+
return G(u), {
|
|
783
|
+
isSupported: a,
|
|
784
|
+
stop: u
|
|
679
785
|
};
|
|
680
786
|
}
|
|
681
|
-
function
|
|
682
|
-
const { window:
|
|
683
|
-
var
|
|
684
|
-
return (
|
|
685
|
-
}), s =
|
|
686
|
-
return
|
|
687
|
-
const
|
|
688
|
-
if (
|
|
689
|
-
const
|
|
690
|
-
if (
|
|
691
|
-
const v =
|
|
692
|
-
s.value = parseFloat(v.width),
|
|
787
|
+
function bl(e, t = { width: 0, height: 0 }, l = {}) {
|
|
788
|
+
const { window: o = M, box: n = "content-box" } = l, r = x(() => {
|
|
789
|
+
var c, f;
|
|
790
|
+
return (f = (c = P(e)) == null ? void 0 : c.namespaceURI) == null ? void 0 : f.includes("svg");
|
|
791
|
+
}), s = b(t.width), a = b(t.height);
|
|
792
|
+
return hl(e, ([c]) => {
|
|
793
|
+
const f = n === "border-box" ? c.borderBoxSize : n === "content-box" ? c.contentBoxSize : c.devicePixelContentBoxSize;
|
|
794
|
+
if (o && r.value) {
|
|
795
|
+
const u = P(e);
|
|
796
|
+
if (u) {
|
|
797
|
+
const v = o.getComputedStyle(u);
|
|
798
|
+
s.value = parseFloat(v.width), a.value = parseFloat(v.height);
|
|
693
799
|
}
|
|
694
|
-
} else if (
|
|
695
|
-
const
|
|
696
|
-
s.value =
|
|
800
|
+
} else if (f) {
|
|
801
|
+
const u = Array.isArray(f) ? f : [f];
|
|
802
|
+
s.value = u.reduce((v, { inlineSize: i }) => v + i, 0), a.value = u.reduce((v, { blockSize: i }) => v + i, 0);
|
|
697
803
|
} else
|
|
698
|
-
s.value =
|
|
699
|
-
}, l),
|
|
700
|
-
s.value =
|
|
804
|
+
s.value = c.contentRect.width, a.value = c.contentRect.height;
|
|
805
|
+
}, l), B(() => P(e), (c) => {
|
|
806
|
+
s.value = c ? t.width : 0, a.value = c ? t.height : 0;
|
|
701
807
|
}), {
|
|
702
808
|
width: s,
|
|
703
|
-
height:
|
|
809
|
+
height: a
|
|
704
810
|
};
|
|
705
811
|
}
|
|
706
812
|
R.mounted + "";
|
|
707
|
-
function
|
|
708
|
-
const
|
|
813
|
+
function Ce(e, { window: t = M, scrollTarget: l } = {}) {
|
|
814
|
+
const o = b(!1), n = () => {
|
|
709
815
|
if (!t)
|
|
710
816
|
return;
|
|
711
|
-
const r = t.document, s =
|
|
817
|
+
const r = t.document, s = P(e);
|
|
712
818
|
if (!s)
|
|
713
|
-
|
|
819
|
+
o.value = !1;
|
|
714
820
|
else {
|
|
715
|
-
const
|
|
716
|
-
|
|
821
|
+
const a = s.getBoundingClientRect();
|
|
822
|
+
o.value = a.top <= (t.innerHeight || r.documentElement.clientHeight) && a.left <= (t.innerWidth || r.documentElement.clientWidth) && a.bottom >= 0 && a.right >= 0;
|
|
717
823
|
}
|
|
718
824
|
};
|
|
719
|
-
return
|
|
825
|
+
return B(() => P(e), () => n(), { immediate: !0, flush: "post" }), t && A(l || t, "scroll", n, {
|
|
720
826
|
capture: !1,
|
|
721
827
|
passive: !0
|
|
722
|
-
}),
|
|
828
|
+
}), o;
|
|
723
829
|
}
|
|
724
830
|
R.mounted + "";
|
|
725
|
-
const
|
|
726
|
-
function
|
|
831
|
+
const Pe = 1;
|
|
832
|
+
function de(e, t = {}) {
|
|
727
833
|
const {
|
|
728
834
|
throttle: l = 0,
|
|
729
|
-
idle:
|
|
730
|
-
onStop:
|
|
835
|
+
idle: o = 200,
|
|
836
|
+
onStop: n = z,
|
|
731
837
|
onScroll: r = z,
|
|
732
838
|
offset: s = {
|
|
733
839
|
left: 0,
|
|
@@ -735,191 +841,191 @@ function ue(e, t = {}) {
|
|
|
735
841
|
top: 0,
|
|
736
842
|
bottom: 0
|
|
737
843
|
},
|
|
738
|
-
eventListenerOptions:
|
|
844
|
+
eventListenerOptions: a = {
|
|
739
845
|
capture: !1,
|
|
740
846
|
passive: !0
|
|
741
847
|
},
|
|
742
|
-
behavior:
|
|
743
|
-
} = t,
|
|
848
|
+
behavior: c = "auto"
|
|
849
|
+
} = t, f = b(0), u = b(0), v = x({
|
|
744
850
|
get() {
|
|
745
|
-
return
|
|
851
|
+
return f.value;
|
|
746
852
|
},
|
|
747
|
-
set(
|
|
748
|
-
|
|
853
|
+
set(O) {
|
|
854
|
+
y(O, void 0);
|
|
749
855
|
}
|
|
750
|
-
}), i =
|
|
856
|
+
}), i = x({
|
|
751
857
|
get() {
|
|
752
|
-
return
|
|
858
|
+
return u.value;
|
|
753
859
|
},
|
|
754
|
-
set(
|
|
755
|
-
|
|
860
|
+
set(O) {
|
|
861
|
+
y(void 0, O);
|
|
756
862
|
}
|
|
757
863
|
});
|
|
758
|
-
function
|
|
759
|
-
var
|
|
760
|
-
const
|
|
761
|
-
|
|
762
|
-
top: (
|
|
763
|
-
left: (
|
|
764
|
-
behavior:
|
|
864
|
+
function y(O, T) {
|
|
865
|
+
var D, F, ge;
|
|
866
|
+
const ne = C(e);
|
|
867
|
+
ne && ((ge = ne instanceof Document ? document.body : ne) == null || ge.scrollTo({
|
|
868
|
+
top: (D = C(T)) != null ? D : i.value,
|
|
869
|
+
left: (F = C(O)) != null ? F : v.value,
|
|
870
|
+
behavior: C(c)
|
|
765
871
|
}));
|
|
766
872
|
}
|
|
767
|
-
const
|
|
873
|
+
const d = b(!1), j = X({
|
|
768
874
|
left: !0,
|
|
769
875
|
right: !1,
|
|
770
876
|
top: !0,
|
|
771
877
|
bottom: !1
|
|
772
|
-
}),
|
|
878
|
+
}), S = X({
|
|
773
879
|
left: !1,
|
|
774
880
|
right: !1,
|
|
775
881
|
top: !1,
|
|
776
882
|
bottom: !1
|
|
777
|
-
}),
|
|
778
|
-
|
|
779
|
-
},
|
|
780
|
-
const
|
|
781
|
-
|
|
782
|
-
let
|
|
783
|
-
|
|
883
|
+
}), Y = (O) => {
|
|
884
|
+
d.value && (d.value = !1, S.left = !1, S.right = !1, S.top = !1, S.bottom = !1, n(O));
|
|
885
|
+
}, oe = Ht(Y, l + o), E = (O) => {
|
|
886
|
+
const T = O.target === document ? O.target.documentElement : O.target, D = T.scrollLeft;
|
|
887
|
+
S.left = D < f.value, S.right = D > u.value, j.left = D <= 0 + (s.left || 0), j.right = D + T.clientWidth >= T.scrollWidth - (s.right || 0) - Pe, f.value = D;
|
|
888
|
+
let F = T.scrollTop;
|
|
889
|
+
O.target === document && !F && (F = document.body.scrollTop), S.top = F < u.value, S.bottom = F > u.value, j.top = F <= 0 + (s.top || 0), j.bottom = F + T.clientHeight >= T.scrollHeight - (s.bottom || 0) - Pe, u.value = F, d.value = !0, oe(O), r(O);
|
|
784
890
|
};
|
|
785
|
-
return A(e, "scroll", l ?
|
|
891
|
+
return A(e, "scroll", l ? Wt(E, l, !0, !1) : E, a), A(e, "scrollend", Y, a), {
|
|
786
892
|
x: v,
|
|
787
893
|
y: i,
|
|
788
|
-
isScrolling:
|
|
789
|
-
arrivedState:
|
|
790
|
-
directions:
|
|
894
|
+
isScrolling: d,
|
|
895
|
+
arrivedState: j,
|
|
896
|
+
directions: S
|
|
791
897
|
};
|
|
792
898
|
}
|
|
793
|
-
var
|
|
899
|
+
var gl = Object.defineProperty, _l = Object.defineProperties, wl = Object.getOwnPropertyDescriptors, Je = Object.getOwnPropertySymbols, Sl = Object.prototype.hasOwnProperty, jl = Object.prototype.propertyIsEnumerable, qe = (e, t, l) => t in e ? gl(e, t, { enumerable: !0, configurable: !0, writable: !0, value: l }) : e[t] = l, Te = (e, t) => {
|
|
794
900
|
for (var l in t || (t = {}))
|
|
795
|
-
|
|
796
|
-
if (
|
|
797
|
-
for (var l of
|
|
798
|
-
|
|
901
|
+
Sl.call(t, l) && qe(e, l, t[l]);
|
|
902
|
+
if (Je)
|
|
903
|
+
for (var l of Je(t))
|
|
904
|
+
jl.call(t, l) && qe(e, l, t[l]);
|
|
799
905
|
return e;
|
|
800
|
-
},
|
|
801
|
-
function
|
|
802
|
-
var
|
|
803
|
-
const r = (
|
|
804
|
-
offset:
|
|
805
|
-
[r]: (
|
|
906
|
+
}, kl = (e, t) => _l(e, wl(t));
|
|
907
|
+
function ze(e, t, l = {}) {
|
|
908
|
+
var o, n;
|
|
909
|
+
const r = (o = l.direction) != null ? o : "bottom", s = X(de(e, kl(Te({}, l), {
|
|
910
|
+
offset: Te({
|
|
911
|
+
[r]: (n = l.distance) != null ? n : 0
|
|
806
912
|
}, l.offset)
|
|
807
913
|
})));
|
|
808
|
-
|
|
809
|
-
var
|
|
810
|
-
if (
|
|
811
|
-
const
|
|
812
|
-
height: (
|
|
813
|
-
width: (
|
|
914
|
+
B(() => s.arrivedState[r], async (a) => {
|
|
915
|
+
var c, f;
|
|
916
|
+
if (a) {
|
|
917
|
+
const u = C(e), v = {
|
|
918
|
+
height: (c = u == null ? void 0 : u.scrollHeight) != null ? c : 0,
|
|
919
|
+
width: (f = u == null ? void 0 : u.scrollWidth) != null ? f : 0
|
|
814
920
|
};
|
|
815
|
-
await t(s), l.preserveScrollPosition &&
|
|
816
|
-
|
|
817
|
-
top:
|
|
818
|
-
left:
|
|
921
|
+
await t(s), l.preserveScrollPosition && u && Me(() => {
|
|
922
|
+
u.scrollTo({
|
|
923
|
+
top: u.scrollHeight - v.height,
|
|
924
|
+
left: u.scrollWidth - v.width
|
|
819
925
|
});
|
|
820
926
|
});
|
|
821
927
|
}
|
|
822
928
|
});
|
|
823
929
|
}
|
|
824
930
|
R.mounted + "";
|
|
825
|
-
function
|
|
931
|
+
function Ae(e, t, l = {}) {
|
|
826
932
|
const {
|
|
827
|
-
root:
|
|
828
|
-
rootMargin:
|
|
933
|
+
root: o,
|
|
934
|
+
rootMargin: n = "0px",
|
|
829
935
|
threshold: r = 0.1,
|
|
830
|
-
window: s =
|
|
831
|
-
} = l,
|
|
832
|
-
let
|
|
833
|
-
const
|
|
834
|
-
el:
|
|
835
|
-
root:
|
|
936
|
+
window: s = M
|
|
937
|
+
} = l, a = Qe(() => s && "IntersectionObserver" in s);
|
|
938
|
+
let c = z;
|
|
939
|
+
const f = a.value ? B(() => ({
|
|
940
|
+
el: P(e),
|
|
941
|
+
root: P(o)
|
|
836
942
|
}), ({ el: v, root: i }) => {
|
|
837
|
-
if (
|
|
943
|
+
if (c(), !v)
|
|
838
944
|
return;
|
|
839
|
-
const
|
|
945
|
+
const y = new IntersectionObserver(t, {
|
|
840
946
|
root: i,
|
|
841
|
-
rootMargin:
|
|
947
|
+
rootMargin: n,
|
|
842
948
|
threshold: r
|
|
843
949
|
});
|
|
844
|
-
|
|
845
|
-
|
|
950
|
+
y.observe(v), c = () => {
|
|
951
|
+
y.disconnect(), c = z;
|
|
846
952
|
};
|
|
847
|
-
}, { immediate: !0, flush: "post" }) : z,
|
|
848
|
-
|
|
953
|
+
}, { immediate: !0, flush: "post" }) : z, u = () => {
|
|
954
|
+
c(), f();
|
|
849
955
|
};
|
|
850
|
-
return
|
|
851
|
-
isSupported:
|
|
852
|
-
stop:
|
|
956
|
+
return G(u), {
|
|
957
|
+
isSupported: a,
|
|
958
|
+
stop: u
|
|
853
959
|
};
|
|
854
960
|
}
|
|
855
961
|
R.mounted + "";
|
|
856
|
-
var
|
|
962
|
+
var $l = Object.defineProperty, Vl = Object.defineProperties, xl = Object.getOwnPropertyDescriptors, Fe = Object.getOwnPropertySymbols, Ol = Object.prototype.hasOwnProperty, Il = Object.prototype.propertyIsEnumerable, De = (e, t, l) => t in e ? $l(e, t, { enumerable: !0, configurable: !0, writable: !0, value: l }) : e[t] = l, Bl = (e, t) => {
|
|
857
963
|
for (var l in t || (t = {}))
|
|
858
|
-
|
|
859
|
-
if (
|
|
860
|
-
for (var l of
|
|
861
|
-
|
|
964
|
+
Ol.call(t, l) && De(e, l, t[l]);
|
|
965
|
+
if (Fe)
|
|
966
|
+
for (var l of Fe(t))
|
|
967
|
+
Il.call(t, l) && De(e, l, t[l]);
|
|
862
968
|
return e;
|
|
863
|
-
},
|
|
969
|
+
}, Ll = (e, t) => Vl(e, xl(t));
|
|
864
970
|
R.mounted + "";
|
|
865
|
-
function
|
|
971
|
+
function Ze(e) {
|
|
866
972
|
const t = window.getComputedStyle(e);
|
|
867
973
|
if (t.overflowX === "scroll" || t.overflowY === "scroll" || t.overflowX === "auto" && e.clientHeight < e.scrollHeight || t.overflowY === "auto" && e.clientWidth < e.scrollWidth)
|
|
868
974
|
return !0;
|
|
869
975
|
{
|
|
870
976
|
const l = e.parentNode;
|
|
871
|
-
return !l || l.tagName === "BODY" ? !1 :
|
|
977
|
+
return !l || l.tagName === "BODY" ? !1 : Ze(l);
|
|
872
978
|
}
|
|
873
979
|
}
|
|
874
|
-
function
|
|
980
|
+
function El(e) {
|
|
875
981
|
const t = e || window.event, l = t.target;
|
|
876
|
-
return
|
|
982
|
+
return Ze(l) ? !1 : t.touches.length > 1 ? !0 : (t.preventDefault && t.preventDefault(), !1);
|
|
877
983
|
}
|
|
878
|
-
function
|
|
879
|
-
const l =
|
|
880
|
-
let
|
|
881
|
-
|
|
882
|
-
if (
|
|
883
|
-
const
|
|
884
|
-
|
|
984
|
+
function Cl(e, t = !1) {
|
|
985
|
+
const l = b(t);
|
|
986
|
+
let o = null, n;
|
|
987
|
+
B(Ut(e), (a) => {
|
|
988
|
+
if (a) {
|
|
989
|
+
const c = a;
|
|
990
|
+
n = c.style.overflow, l.value && (c.style.overflow = "hidden");
|
|
885
991
|
}
|
|
886
992
|
}, {
|
|
887
993
|
immediate: !0
|
|
888
994
|
});
|
|
889
995
|
const r = () => {
|
|
890
|
-
const
|
|
891
|
-
!
|
|
892
|
-
|
|
893
|
-
}, { passive: !1 })),
|
|
996
|
+
const a = C(e);
|
|
997
|
+
!a || l.value || (ee && (o = A(a, "touchmove", (c) => {
|
|
998
|
+
El(c);
|
|
999
|
+
}, { passive: !1 })), a.style.overflow = "hidden", l.value = !0);
|
|
894
1000
|
}, s = () => {
|
|
895
|
-
const
|
|
896
|
-
!
|
|
1001
|
+
const a = C(e);
|
|
1002
|
+
!a || !l.value || (ee && (o == null || o()), a.style.overflow = n, l.value = !1);
|
|
897
1003
|
};
|
|
898
|
-
return
|
|
1004
|
+
return G(s), x({
|
|
899
1005
|
get() {
|
|
900
1006
|
return l.value;
|
|
901
1007
|
},
|
|
902
|
-
set(
|
|
903
|
-
|
|
1008
|
+
set(a) {
|
|
1009
|
+
a ? r() : s();
|
|
904
1010
|
}
|
|
905
1011
|
});
|
|
906
1012
|
}
|
|
907
|
-
const
|
|
1013
|
+
const Pl = () => {
|
|
908
1014
|
let e = !1;
|
|
909
|
-
const t =
|
|
910
|
-
return (l,
|
|
911
|
-
if (t.value =
|
|
1015
|
+
const t = b(!1);
|
|
1016
|
+
return (l, o) => {
|
|
1017
|
+
if (t.value = o.value, e)
|
|
912
1018
|
return;
|
|
913
1019
|
e = !0;
|
|
914
|
-
const
|
|
915
|
-
|
|
1020
|
+
const n = Cl(l, o.value);
|
|
1021
|
+
B(t, (r) => n.value = r);
|
|
916
1022
|
};
|
|
917
1023
|
};
|
|
918
|
-
|
|
919
|
-
const
|
|
1024
|
+
Pl();
|
|
1025
|
+
const Ye = ["medium", "small"], Jl = ["id", "tabindex", "aria-disabled", "aria-selected", "title", "aria-label", ".dataLabel", "onClick"], ql = {
|
|
920
1026
|
key: 0,
|
|
921
1027
|
class: "joy-dropdown-list__footer"
|
|
922
|
-
},
|
|
1028
|
+
}, Tl = /* @__PURE__ */ $({
|
|
923
1029
|
__name: "VJoyDropdownList",
|
|
924
1030
|
props: {
|
|
925
1031
|
options: {
|
|
@@ -935,7 +1041,7 @@ const Qe = ["medium", "small"], kl = ["id", "tabindex", "aria-disabled", "aria-s
|
|
|
935
1041
|
type: String,
|
|
936
1042
|
default: "medium",
|
|
937
1043
|
validator(e) {
|
|
938
|
-
return
|
|
1044
|
+
return Ye.includes(e);
|
|
939
1045
|
}
|
|
940
1046
|
},
|
|
941
1047
|
modelValue: {
|
|
@@ -952,38 +1058,38 @@ const Qe = ["medium", "small"], kl = ["id", "tabindex", "aria-disabled", "aria-s
|
|
|
952
1058
|
},
|
|
953
1059
|
emits: ["update:modelValue", "close:dropdownList"],
|
|
954
1060
|
setup(e, { expose: t, emit: l }) {
|
|
955
|
-
const
|
|
1061
|
+
const o = e, n = b(), r = x(() => (i) => !o.modelValue && !i.value ? !1 : o.modelValue === i.label || o.modelValue === i.value);
|
|
956
1062
|
function s(i) {
|
|
957
1063
|
i.disabled || l("update:modelValue", i.label);
|
|
958
1064
|
}
|
|
959
|
-
function
|
|
1065
|
+
function a() {
|
|
960
1066
|
var i;
|
|
961
|
-
return Array.from(((i =
|
|
1067
|
+
return Array.from(((i = n.value) == null ? void 0 : i.querySelectorAll("li")) || []);
|
|
962
1068
|
}
|
|
963
|
-
function
|
|
964
|
-
const i =
|
|
965
|
-
i && (i.focus(),
|
|
1069
|
+
function c() {
|
|
1070
|
+
const i = a().find((y) => y.getAttribute("aria-selected") === "true");
|
|
1071
|
+
i && (i.focus(), n.value.scrollTo({
|
|
966
1072
|
top: i.offsetTop
|
|
967
1073
|
}));
|
|
968
1074
|
}
|
|
969
|
-
function
|
|
970
|
-
return
|
|
1075
|
+
function f() {
|
|
1076
|
+
return a().find((i) => i === document.activeElement);
|
|
971
1077
|
}
|
|
972
|
-
function
|
|
973
|
-
var
|
|
974
|
-
if ((i.key === "Escape" || i.key === "Tab") && l("close:dropdownList"), (i.key === "Enter" || i.key === "enter") && (i.preventDefault(),
|
|
975
|
-
const
|
|
976
|
-
if (!
|
|
1078
|
+
function u(i) {
|
|
1079
|
+
var y;
|
|
1080
|
+
if ((i.key === "Escape" || i.key === "Tab") && l("close:dropdownList"), (i.key === "Enter" || i.key === "enter") && (i.preventDefault(), f() && ((y = n.value) != null && y.contains(f())))) {
|
|
1081
|
+
const d = f();
|
|
1082
|
+
if (!d)
|
|
977
1083
|
return;
|
|
978
|
-
if (
|
|
979
|
-
return
|
|
980
|
-
l("update:modelValue",
|
|
1084
|
+
if (d.querySelector("a"))
|
|
1085
|
+
return d.querySelector("a").click();
|
|
1086
|
+
l("update:modelValue", d.dataLabel);
|
|
981
1087
|
}
|
|
982
1088
|
if (i.key === " " && i.preventDefault(), ["ArrowDown", "ArrowUp", "Home", "End"].includes(i.key)) {
|
|
983
|
-
const
|
|
984
|
-
let
|
|
985
|
-
if (
|
|
986
|
-
i.preventDefault(), i.key === "ArrowDown" ?
|
|
1089
|
+
const d = a(), j = f();
|
|
1090
|
+
let S = d.indexOf(j);
|
|
1091
|
+
if (d.length) {
|
|
1092
|
+
i.preventDefault(), i.key === "ArrowDown" ? S++ : i.key === "ArrowUp" ? S-- : i.key === "Home" ? S = 0 : i.key === "End" && (S = d.length - 1), S < 0 && (S = 0), S > d.length - 1 && (S = 0), v(d[S]);
|
|
987
1093
|
return;
|
|
988
1094
|
}
|
|
989
1095
|
}
|
|
@@ -991,65 +1097,65 @@ const Qe = ["medium", "small"], kl = ["id", "tabindex", "aria-disabled", "aria-s
|
|
|
991
1097
|
function v(i) {
|
|
992
1098
|
i.focus();
|
|
993
1099
|
}
|
|
994
|
-
return
|
|
995
|
-
window.addEventListener("keydown",
|
|
996
|
-
}),
|
|
997
|
-
window.removeEventListener("keydown",
|
|
1100
|
+
return Z(() => {
|
|
1101
|
+
window.addEventListener("keydown", u), c();
|
|
1102
|
+
}), Ne(() => {
|
|
1103
|
+
window.removeEventListener("keydown", u);
|
|
998
1104
|
}), t({
|
|
999
1105
|
isSelected: r
|
|
1000
|
-
}), (i,
|
|
1106
|
+
}), (i, y) => (m(), p("div", {
|
|
1001
1107
|
class: "joy-dropdown-list",
|
|
1002
|
-
style:
|
|
1108
|
+
style: K({ "max-width": `${e.width}px`, "max-height": `${e.height}px` })
|
|
1003
1109
|
}, [
|
|
1004
1110
|
h("ul", {
|
|
1005
1111
|
ref_key: "listbox",
|
|
1006
|
-
ref:
|
|
1112
|
+
ref: n,
|
|
1007
1113
|
role: "listbox",
|
|
1008
1114
|
class: "joy-dropdown-list__items",
|
|
1009
|
-
style:
|
|
1115
|
+
style: K({ "max-height": `${e.height}px` })
|
|
1010
1116
|
}, [
|
|
1011
|
-
(m(!0), p(
|
|
1012
|
-
id:
|
|
1013
|
-
key:
|
|
1014
|
-
style:
|
|
1117
|
+
(m(!0), p(ye, null, ve(e.options, (d) => (m(), p("li", {
|
|
1118
|
+
id: d.id,
|
|
1119
|
+
key: d.label,
|
|
1120
|
+
style: K({ "max-width": `${e.width}px` }),
|
|
1015
1121
|
class: k([
|
|
1016
1122
|
"joy-dropdown-list__item",
|
|
1017
1123
|
`joy-dropdown-list__item--${e.size}`,
|
|
1018
1124
|
{
|
|
1019
|
-
"joy-dropdown-list__item--selected": _(r)(
|
|
1020
|
-
"joy-dropdown-list__item--disabled":
|
|
1125
|
+
"joy-dropdown-list__item--selected": _(r)(d),
|
|
1126
|
+
"joy-dropdown-list__item--disabled": d.disabled
|
|
1021
1127
|
}
|
|
1022
1128
|
]),
|
|
1023
|
-
tabindex:
|
|
1024
|
-
"aria-disabled":
|
|
1025
|
-
"aria-selected": _(r)(
|
|
1026
|
-
title:
|
|
1027
|
-
"aria-label":
|
|
1028
|
-
".dataLabel":
|
|
1129
|
+
tabindex: d.disabled ? void 0 : 0,
|
|
1130
|
+
"aria-disabled": d.disabled,
|
|
1131
|
+
"aria-selected": _(r)(d),
|
|
1132
|
+
title: d.label,
|
|
1133
|
+
"aria-label": d.label,
|
|
1134
|
+
".dataLabel": d.value || d.label,
|
|
1029
1135
|
role: "option",
|
|
1030
|
-
onClick: (
|
|
1136
|
+
onClick: (j) => s(d)
|
|
1031
1137
|
}, [
|
|
1032
|
-
|
|
1033
|
-
h("span", null,
|
|
1138
|
+
g(i.$slots, "label", me(pe(d)), () => [
|
|
1139
|
+
h("span", null, I(d.label), 1)
|
|
1034
1140
|
], !0)
|
|
1035
|
-
], 14,
|
|
1141
|
+
], 14, Jl))), 128))
|
|
1036
1142
|
], 4),
|
|
1037
|
-
i.$slots.footer ? (m(), p("footer",
|
|
1038
|
-
|
|
1143
|
+
i.$slots.footer ? (m(), p("footer", ql, [
|
|
1144
|
+
g(i.$slots, "footer", {}, void 0, !0)
|
|
1039
1145
|
])) : w("", !0)
|
|
1040
1146
|
], 4));
|
|
1041
1147
|
}
|
|
1042
1148
|
});
|
|
1043
|
-
const
|
|
1044
|
-
function
|
|
1149
|
+
const Xe = /* @__PURE__ */ V(Tl, [["__scopeId", "data-v-5ab31622"]]);
|
|
1150
|
+
function zl(e) {
|
|
1045
1151
|
const t = () => e();
|
|
1046
|
-
|
|
1152
|
+
Z(() => {
|
|
1047
1153
|
window.addEventListener("resize", t);
|
|
1048
|
-
}),
|
|
1154
|
+
}), Ne(() => {
|
|
1049
1155
|
window.removeEventListener("resize", t);
|
|
1050
1156
|
});
|
|
1051
1157
|
}
|
|
1052
|
-
const
|
|
1158
|
+
const Al = /* @__PURE__ */ $({
|
|
1053
1159
|
__name: "VJoyDropdown",
|
|
1054
1160
|
props: {
|
|
1055
1161
|
/** DOM valid selector to give to Vue3 Teleport "to" property */
|
|
@@ -1097,7 +1203,7 @@ const xl = /* @__PURE__ */ $({
|
|
|
1097
1203
|
type: String,
|
|
1098
1204
|
default: "medium",
|
|
1099
1205
|
validator(e) {
|
|
1100
|
-
return
|
|
1206
|
+
return Ye.includes(e);
|
|
1101
1207
|
}
|
|
1102
1208
|
},
|
|
1103
1209
|
modelValue: {
|
|
@@ -1128,87 +1234,87 @@ const xl = /* @__PURE__ */ $({
|
|
|
1128
1234
|
},
|
|
1129
1235
|
emits: ["update:modelValue"],
|
|
1130
1236
|
setup(e, { expose: t, emit: l }) {
|
|
1131
|
-
const
|
|
1237
|
+
const o = e, n = b(!1), r = b(null), s = b(), a = b(null), c = b(null), f = b(!1), u = {
|
|
1132
1238
|
ignore: [s, ".joy-dropdown__list"]
|
|
1133
1239
|
};
|
|
1134
1240
|
let v = null;
|
|
1135
|
-
const i =
|
|
1241
|
+
const i = X({
|
|
1136
1242
|
left: "auto",
|
|
1137
1243
|
top: "0px",
|
|
1138
1244
|
right: "auto"
|
|
1139
1245
|
});
|
|
1140
|
-
function
|
|
1141
|
-
v && clearTimeout(v),
|
|
1142
|
-
|
|
1246
|
+
function y() {
|
|
1247
|
+
v && clearTimeout(v), f.value = !0, v = setTimeout(() => {
|
|
1248
|
+
n.value = !1, f.value = !1;
|
|
1143
1249
|
}, 300);
|
|
1144
1250
|
}
|
|
1145
|
-
function
|
|
1146
|
-
|
|
1147
|
-
}
|
|
1148
|
-
function S() {
|
|
1149
|
-
d(), j();
|
|
1251
|
+
function d(E) {
|
|
1252
|
+
f.value = !1, v && clearTimeout(v), Y(), c.value = E.target, n.value = !0;
|
|
1150
1253
|
}
|
|
1151
1254
|
function j() {
|
|
1152
|
-
|
|
1255
|
+
y(), S();
|
|
1256
|
+
}
|
|
1257
|
+
function S() {
|
|
1258
|
+
c.value && c.value.focus();
|
|
1153
1259
|
}
|
|
1154
|
-
function
|
|
1155
|
-
const E = s.value.getBoundingClientRect(),
|
|
1156
|
-
|
|
1260
|
+
function Y() {
|
|
1261
|
+
const E = s.value.getBoundingClientRect(), O = document.documentElement.scrollTop + E.top, T = E.height, D = E.left, F = E.width;
|
|
1262
|
+
o.justify === "left" ? i.left = D + "px" : i.left = D + F - parseInt(o.width) + "px", o.direction === "down" ? i.top = O + T + parseInt(o.dropdownGap) + "px" : i.top = O - (parseInt(o.height) + parseInt(o.dropdownGap)) + "px";
|
|
1157
1263
|
}
|
|
1158
|
-
function
|
|
1159
|
-
l("update:modelValue", E),
|
|
1264
|
+
function oe(E) {
|
|
1265
|
+
l("update:modelValue", E), o.closeOnSelect && (y(), S());
|
|
1160
1266
|
}
|
|
1161
|
-
return
|
|
1162
|
-
showDropdownList:
|
|
1163
|
-
}), (E,
|
|
1267
|
+
return zl(y), t({
|
|
1268
|
+
showDropdownList: n
|
|
1269
|
+
}), (E, O) => (m(), q(_(il), {
|
|
1164
1270
|
ref_key: "dropdown",
|
|
1165
1271
|
ref: r,
|
|
1166
|
-
options:
|
|
1272
|
+
options: u,
|
|
1167
1273
|
class: "joy-dropdown",
|
|
1168
|
-
onTrigger:
|
|
1274
|
+
onTrigger: y
|
|
1169
1275
|
}, {
|
|
1170
1276
|
default: L(() => [
|
|
1171
1277
|
h("div", {
|
|
1172
1278
|
ref_key: "button",
|
|
1173
1279
|
ref: s,
|
|
1174
1280
|
class: "joy-dropdown__button",
|
|
1175
|
-
onClick:
|
|
1281
|
+
onClick: d
|
|
1176
1282
|
}, [
|
|
1177
|
-
|
|
1283
|
+
g(E.$slots, "dropdown-button", {}, void 0, !0)
|
|
1178
1284
|
], 512),
|
|
1179
|
-
(m(),
|
|
1285
|
+
(m(), q(rt, {
|
|
1180
1286
|
to: e.appendTo,
|
|
1181
1287
|
disabled: e.disableTeleport
|
|
1182
1288
|
}, [
|
|
1183
|
-
|
|
1289
|
+
n.value ? (m(), p("div", {
|
|
1184
1290
|
key: 0,
|
|
1185
1291
|
ref_key: "list",
|
|
1186
|
-
ref:
|
|
1292
|
+
ref: a,
|
|
1187
1293
|
class: k([
|
|
1188
1294
|
"joy-dropdown__list",
|
|
1189
1295
|
`joy-dropdown__list--${e.direction}`,
|
|
1190
1296
|
{
|
|
1191
|
-
"joy-dropdown__list--visible": !
|
|
1192
|
-
"joy-dropdown__list--hiding":
|
|
1297
|
+
"joy-dropdown__list--visible": !f.value,
|
|
1298
|
+
"joy-dropdown__list--hiding": f.value
|
|
1193
1299
|
}
|
|
1194
1300
|
]),
|
|
1195
|
-
style:
|
|
1301
|
+
style: K({
|
|
1196
1302
|
top: i.top,
|
|
1197
1303
|
left: i.left
|
|
1198
1304
|
})
|
|
1199
1305
|
}, [
|
|
1200
|
-
|
|
1306
|
+
fe(Xe, {
|
|
1201
1307
|
"model-value": e.modelValue,
|
|
1202
1308
|
options: e.options,
|
|
1203
1309
|
size: e.size,
|
|
1204
1310
|
width: e.width,
|
|
1205
1311
|
height: e.height,
|
|
1206
|
-
"onUpdate:modelValue":
|
|
1207
|
-
"onClose:dropdownList":
|
|
1312
|
+
"onUpdate:modelValue": oe,
|
|
1313
|
+
"onClose:dropdownList": j
|
|
1208
1314
|
}, {
|
|
1209
|
-
label: L((
|
|
1210
|
-
|
|
1211
|
-
h("span", null,
|
|
1315
|
+
label: L((T) => [
|
|
1316
|
+
g(E.$slots, "dropdown-item", me(pe(T)), () => [
|
|
1317
|
+
h("span", null, I(T.label), 1)
|
|
1212
1318
|
], !0)
|
|
1213
1319
|
]),
|
|
1214
1320
|
_: 3
|
|
@@ -1220,10 +1326,10 @@ const xl = /* @__PURE__ */ $({
|
|
|
1220
1326
|
}, 512));
|
|
1221
1327
|
}
|
|
1222
1328
|
});
|
|
1223
|
-
const
|
|
1329
|
+
const Fl = /* @__PURE__ */ V(Al, [["__scopeId", "data-v-49159b35"]]), Dl = (e) => (te("data-v-50e209d6"), e = e(), le(), e), Rl = ["aria-hidden"], Ml = /* @__PURE__ */ Dl(() => /* @__PURE__ */ h("joy-icon", {
|
|
1224
1330
|
"custom-class": "joy-icon-error",
|
|
1225
1331
|
name: "warning-triangle"
|
|
1226
|
-
}, null, -1)),
|
|
1332
|
+
}, null, -1)), Nl = /* @__PURE__ */ $({
|
|
1227
1333
|
__name: "VJoyFormError",
|
|
1228
1334
|
props: {
|
|
1229
1335
|
/** In some cases you'll need to inject the error in the DOM but hide it. Visible by default */
|
|
@@ -1240,17 +1346,17 @@ const Il = /* @__PURE__ */ V(xl, [["__scopeId", "data-v-49159b35"]]), Ol = (e) =
|
|
|
1240
1346
|
class: k(["joy-form-error", { "joy-has-error": e.visible }]),
|
|
1241
1347
|
role: "alert"
|
|
1242
1348
|
}, [
|
|
1243
|
-
|
|
1349
|
+
Ml,
|
|
1244
1350
|
h("div", null, [
|
|
1245
|
-
|
|
1246
|
-
|
|
1351
|
+
g(t.$slots, "default", {}, () => [
|
|
1352
|
+
J(I(e.noHtmlErrorText), 1)
|
|
1247
1353
|
], !0)
|
|
1248
1354
|
])
|
|
1249
|
-
], 10,
|
|
1355
|
+
], 10, Rl));
|
|
1250
1356
|
}
|
|
1251
1357
|
});
|
|
1252
|
-
const
|
|
1253
|
-
function
|
|
1358
|
+
const et = /* @__PURE__ */ V(Nl, [["__scopeId", "data-v-50e209d6"]]);
|
|
1359
|
+
function Hl(e) {
|
|
1254
1360
|
let t;
|
|
1255
1361
|
switch (e) {
|
|
1256
1362
|
case "error":
|
|
@@ -1264,7 +1370,7 @@ function Cl(e) {
|
|
|
1264
1370
|
}
|
|
1265
1371
|
return t;
|
|
1266
1372
|
}
|
|
1267
|
-
const
|
|
1373
|
+
const Wl = [...pt], Ul = ["name"], Gl = { class: "joy-highlight--text" }, Kl = /* @__PURE__ */ $({
|
|
1268
1374
|
__name: "VJoyHighlight",
|
|
1269
1375
|
props: {
|
|
1270
1376
|
accent: {
|
|
@@ -1280,51 +1386,51 @@ const Pl = [...dt], ql = ["name"], Jl = { class: "joy-highlight--text" }, Tl = /
|
|
|
1280
1386
|
type: String,
|
|
1281
1387
|
default: "neutral",
|
|
1282
1388
|
validator(e) {
|
|
1283
|
-
return
|
|
1389
|
+
return Wl.includes(e);
|
|
1284
1390
|
}
|
|
1285
1391
|
}
|
|
1286
1392
|
},
|
|
1287
1393
|
setup(e, { expose: t }) {
|
|
1288
|
-
const l = e,
|
|
1394
|
+
const l = e, o = x(() => l.icon ? l.icon : Hl(l.level));
|
|
1289
1395
|
return t({
|
|
1290
|
-
getRelevantIcon:
|
|
1291
|
-
}), (
|
|
1396
|
+
getRelevantIcon: o
|
|
1397
|
+
}), (n, r) => (m(), p("div", {
|
|
1292
1398
|
class: k([
|
|
1293
1399
|
"joy-highlight",
|
|
1294
1400
|
`joy-highlight_${e.level}`,
|
|
1295
1401
|
{
|
|
1296
1402
|
"joy-highlight__accent": e.accent,
|
|
1297
|
-
"joy-highlight__titled":
|
|
1403
|
+
"joy-highlight__titled": n.$slots["highlight-title"]
|
|
1298
1404
|
}
|
|
1299
1405
|
])
|
|
1300
1406
|
}, [
|
|
1301
1407
|
e.displayIcon ? (m(), p("joy-icon", {
|
|
1302
1408
|
key: 0,
|
|
1303
|
-
name: _(
|
|
1304
|
-
}, null, 8,
|
|
1305
|
-
h("div",
|
|
1409
|
+
name: _(o)
|
|
1410
|
+
}, null, 8, Ul)) : w("", !0),
|
|
1411
|
+
h("div", Gl, [
|
|
1306
1412
|
h("strong", null, [
|
|
1307
|
-
|
|
1413
|
+
g(n.$slots, "highlight-title", {}, void 0, !0)
|
|
1308
1414
|
]),
|
|
1309
|
-
|
|
1415
|
+
g(n.$slots, "default", {}, void 0, !0)
|
|
1310
1416
|
])
|
|
1311
1417
|
], 2));
|
|
1312
1418
|
}
|
|
1313
1419
|
});
|
|
1314
|
-
const
|
|
1420
|
+
const Ql = /* @__PURE__ */ V(Kl, [["__scopeId", "data-v-a0ff7a60"]]), Zl = ["small", "medium", "large"], Yl = {
|
|
1315
1421
|
key: 0,
|
|
1316
1422
|
class: "joy-label-required"
|
|
1317
|
-
},
|
|
1423
|
+
}, Xl = {
|
|
1318
1424
|
key: 1,
|
|
1319
1425
|
class: "joy-label-optional"
|
|
1320
|
-
},
|
|
1426
|
+
}, eo = /* @__PURE__ */ $({
|
|
1321
1427
|
__name: "VJoyLabel",
|
|
1322
1428
|
props: {
|
|
1323
1429
|
size: {
|
|
1324
1430
|
type: String,
|
|
1325
1431
|
default: "medium",
|
|
1326
1432
|
validator(e) {
|
|
1327
|
-
return
|
|
1433
|
+
return Zl.includes(e);
|
|
1328
1434
|
}
|
|
1329
1435
|
},
|
|
1330
1436
|
tagName: {
|
|
@@ -1340,19 +1446,19 @@ const zl = /* @__PURE__ */ V(Tl, [["__scopeId", "data-v-a0ff7a60"]]), Al = ["sma
|
|
|
1340
1446
|
}
|
|
1341
1447
|
},
|
|
1342
1448
|
setup(e) {
|
|
1343
|
-
return (t, l) => (m(),
|
|
1449
|
+
return (t, l) => (m(), q(ce(e.tagName), Q({
|
|
1344
1450
|
class: ["joy-label", `joy-label--${e.size}`]
|
|
1345
1451
|
}, t.$attrs), {
|
|
1346
1452
|
default: L(() => [
|
|
1347
|
-
|
|
1348
|
-
e.required ? (m(), p("span",
|
|
1349
|
-
e.optionalLabel ? (m(), p("span",
|
|
1453
|
+
g(t.$slots, "default", {}, void 0, !0),
|
|
1454
|
+
e.required ? (m(), p("span", Yl, "*")) : w("", !0),
|
|
1455
|
+
e.optionalLabel ? (m(), p("span", Xl, "- " + I(e.optionalLabel), 1)) : w("", !0)
|
|
1350
1456
|
]),
|
|
1351
1457
|
_: 3
|
|
1352
1458
|
}, 16, ["class"]));
|
|
1353
1459
|
}
|
|
1354
1460
|
});
|
|
1355
|
-
const
|
|
1461
|
+
const N = /* @__PURE__ */ V(eo, [["__scopeId", "data-v-1e682734"]]), to = ["large", "medium", "small"], lo = ["id", "disabled", "type", "value"], oo = ["name"], no = ["data-unit"], ao = /* @__PURE__ */ $({
|
|
1356
1462
|
__name: "VJoyInput",
|
|
1357
1463
|
props: {
|
|
1358
1464
|
disabled: {
|
|
@@ -1403,7 +1509,7 @@ const H = /* @__PURE__ */ V(Rl, [["__scopeId", "data-v-1e682734"]]), Nl = ["larg
|
|
|
1403
1509
|
type: String,
|
|
1404
1510
|
default: "medium",
|
|
1405
1511
|
validator(e) {
|
|
1406
|
-
return
|
|
1512
|
+
return to.includes(e);
|
|
1407
1513
|
}
|
|
1408
1514
|
},
|
|
1409
1515
|
type: String,
|
|
@@ -1412,45 +1518,45 @@ const H = /* @__PURE__ */ V(Rl, [["__scopeId", "data-v-1e682734"]]), Nl = ["larg
|
|
|
1412
1518
|
},
|
|
1413
1519
|
emits: ["update:modelValue"],
|
|
1414
1520
|
setup(e, { emit: t }) {
|
|
1415
|
-
const l = e,
|
|
1416
|
-
var
|
|
1417
|
-
return !!((
|
|
1418
|
-
}), v =
|
|
1419
|
-
|
|
1521
|
+
const l = e, o = b(), n = b(), r = Re(), s = W(), a = b(!1), c = x(() => l.clearable && l.modelValue.length > 0 && !l.unit), f = x(() => s.default && s.default()), u = x(() => {
|
|
1522
|
+
var y, d;
|
|
1523
|
+
return !!((y = n.value) != null && y.closest("joy-wrapper")) || !!((d = n.value) != null && d.closest(".joy-wrapper"));
|
|
1524
|
+
}), v = b(l.type);
|
|
1525
|
+
st(() => {
|
|
1420
1526
|
v.value = l.unit ? "number" : l.unit || "text";
|
|
1421
1527
|
});
|
|
1422
1528
|
const i = {
|
|
1423
1529
|
onFocus: () => {
|
|
1424
|
-
|
|
1530
|
+
a.value = !0;
|
|
1425
1531
|
},
|
|
1426
1532
|
onBlur: () => {
|
|
1427
|
-
|
|
1533
|
+
a.value = !1;
|
|
1428
1534
|
},
|
|
1429
|
-
onInput: (
|
|
1430
|
-
let
|
|
1431
|
-
t("update:modelValue",
|
|
1535
|
+
onInput: (y) => {
|
|
1536
|
+
let d = y.target.value;
|
|
1537
|
+
t("update:modelValue", d);
|
|
1432
1538
|
},
|
|
1433
1539
|
clearValue: () => {
|
|
1434
1540
|
l.disabled || t("update:modelValue", "");
|
|
1435
1541
|
}
|
|
1436
1542
|
};
|
|
1437
|
-
return (
|
|
1543
|
+
return (y, d) => (m(), p("div", {
|
|
1438
1544
|
ref_key: "root",
|
|
1439
|
-
ref:
|
|
1545
|
+
ref: n,
|
|
1440
1546
|
class: k([`joy-input--${l.size}`])
|
|
1441
1547
|
}, [
|
|
1442
1548
|
h("div", {
|
|
1443
1549
|
class: k([
|
|
1444
1550
|
"joy-input",
|
|
1445
1551
|
{
|
|
1446
|
-
"joy-input--focusing":
|
|
1552
|
+
"joy-input--focusing": a.value,
|
|
1447
1553
|
"joy-input--disabled": e.disabled,
|
|
1448
1554
|
"joy-input--invalid": e.invalid,
|
|
1449
1555
|
"joy-input--valid": !e.invalid && !_(r).disabled
|
|
1450
1556
|
}
|
|
1451
1557
|
])
|
|
1452
1558
|
}, [
|
|
1453
|
-
_(
|
|
1559
|
+
_(f) || e.label ? (m(), q(N, {
|
|
1454
1560
|
key: 0,
|
|
1455
1561
|
for: e.name,
|
|
1456
1562
|
required: e.required && e.requiredMark,
|
|
@@ -1458,8 +1564,8 @@ const H = /* @__PURE__ */ V(Rl, [["__scopeId", "data-v-1e682734"]]), Nl = ["larg
|
|
|
1458
1564
|
size: e.labelSize
|
|
1459
1565
|
}, {
|
|
1460
1566
|
default: L(() => [
|
|
1461
|
-
|
|
1462
|
-
|
|
1567
|
+
g(y.$slots, "default", {}, () => [
|
|
1568
|
+
J(I(e.label), 1)
|
|
1463
1569
|
], !0)
|
|
1464
1570
|
]),
|
|
1465
1571
|
_: 3
|
|
@@ -1471,14 +1577,14 @@ const H = /* @__PURE__ */ V(Rl, [["__scopeId", "data-v-1e682734"]]), Nl = ["larg
|
|
|
1471
1577
|
"joy-input--wrapper-has-icon": !!e.icon,
|
|
1472
1578
|
"joy-input--wrapper---clearable": e.clearable,
|
|
1473
1579
|
"joy-input--wrapper-unit": !!e.unit,
|
|
1474
|
-
"joy-input--wrapper-margin": !_(
|
|
1580
|
+
"joy-input--wrapper-margin": !_(u)
|
|
1475
1581
|
}
|
|
1476
1582
|
])
|
|
1477
1583
|
}, [
|
|
1478
|
-
h("input",
|
|
1584
|
+
h("input", Q(y.$attrs, {
|
|
1479
1585
|
id: l.name,
|
|
1480
1586
|
ref_key: "input",
|
|
1481
|
-
ref:
|
|
1587
|
+
ref: o,
|
|
1482
1588
|
disabled: e.disabled,
|
|
1483
1589
|
class: [
|
|
1484
1590
|
{
|
|
@@ -1488,38 +1594,38 @@ const H = /* @__PURE__ */ V(Rl, [["__scopeId", "data-v-1e682734"]]), Nl = ["larg
|
|
|
1488
1594
|
],
|
|
1489
1595
|
type: v.value,
|
|
1490
1596
|
value: e.modelValue,
|
|
1491
|
-
onFocus:
|
|
1492
|
-
(...
|
|
1493
|
-
onBlur:
|
|
1494
|
-
(...
|
|
1495
|
-
onInput:
|
|
1496
|
-
(...
|
|
1497
|
-
}), null, 16,
|
|
1498
|
-
_(
|
|
1597
|
+
onFocus: d[0] || (d[0] = //@ts-ignore
|
|
1598
|
+
(...j) => i.onFocus && i.onFocus(...j)),
|
|
1599
|
+
onBlur: d[1] || (d[1] = //@ts-ignore
|
|
1600
|
+
(...j) => i.onBlur && i.onBlur(...j)),
|
|
1601
|
+
onInput: d[2] || (d[2] = //@ts-ignore
|
|
1602
|
+
(...j) => i.onInput && i.onInput(...j))
|
|
1603
|
+
}), null, 16, lo),
|
|
1604
|
+
_(c) ? (m(), p("joy-icon", {
|
|
1499
1605
|
key: 0,
|
|
1500
1606
|
size: "xxsmall",
|
|
1501
1607
|
name: "cross",
|
|
1502
1608
|
class: "joy-input--clear",
|
|
1503
|
-
onClick:
|
|
1504
|
-
(...
|
|
1609
|
+
onClick: d[3] || (d[3] = //@ts-ignore
|
|
1610
|
+
(...j) => i.clearValue && i.clearValue(...j))
|
|
1505
1611
|
})) : w("", !0),
|
|
1506
1612
|
e.icon && !e.clearable ? (m(), p("joy-icon", {
|
|
1507
1613
|
key: 1,
|
|
1508
1614
|
role: "img",
|
|
1509
1615
|
class: "joy-input--decorative-icon",
|
|
1510
1616
|
name: e.icon
|
|
1511
|
-
}, null, 8,
|
|
1617
|
+
}, null, 8, oo)) : w("", !0),
|
|
1512
1618
|
e.unit ? (m(), p("div", {
|
|
1513
1619
|
key: 2,
|
|
1514
1620
|
"data-unit": e.unit,
|
|
1515
1621
|
class: "joy-input--unit"
|
|
1516
|
-
}, null, 8,
|
|
1622
|
+
}, null, 8, no)) : w("", !0)
|
|
1517
1623
|
], 2)
|
|
1518
1624
|
], 2)
|
|
1519
1625
|
], 2));
|
|
1520
1626
|
}
|
|
1521
1627
|
});
|
|
1522
|
-
const
|
|
1628
|
+
const io = /* @__PURE__ */ V(ao, [["__scopeId", "data-v-8258d6d7"]]), ro = ["teal", "white"], so = ["href"], uo = ["color", "name"], co = /* @__PURE__ */ $({
|
|
1523
1629
|
__name: "VJoyLink",
|
|
1524
1630
|
props: {
|
|
1525
1631
|
href: {
|
|
@@ -1530,35 +1636,35 @@ const Gl = /* @__PURE__ */ V(Ul, [["__scopeId", "data-v-8258d6d7"]]), Kl = ["tea
|
|
|
1530
1636
|
type: String,
|
|
1531
1637
|
default: "teal",
|
|
1532
1638
|
validator(e) {
|
|
1533
|
-
return
|
|
1639
|
+
return ro.includes(e);
|
|
1534
1640
|
}
|
|
1535
1641
|
},
|
|
1536
1642
|
icon: String
|
|
1537
1643
|
},
|
|
1538
1644
|
setup(e) {
|
|
1539
|
-
const t = e, l =
|
|
1540
|
-
return (
|
|
1645
|
+
const t = e, l = x(() => t.color === "white" ? "white" : "teal");
|
|
1646
|
+
return (o, n) => (m(), p("a", Q({ href: e.href }, o.$attrs, {
|
|
1541
1647
|
class: ["joy-link", `joy-link_${e.color}`]
|
|
1542
1648
|
}), [
|
|
1543
1649
|
e.icon ? (m(), p("joy-icon", {
|
|
1544
1650
|
key: 0,
|
|
1545
1651
|
color: _(l),
|
|
1546
1652
|
name: e.icon
|
|
1547
|
-
}, null, 8,
|
|
1548
|
-
|
|
1549
|
-
], 16,
|
|
1653
|
+
}, null, 8, uo)) : w("", !0),
|
|
1654
|
+
g(o.$slots, "default", {}, void 0, !0)
|
|
1655
|
+
], 16, so));
|
|
1550
1656
|
}
|
|
1551
1657
|
});
|
|
1552
|
-
const
|
|
1658
|
+
const fo = /* @__PURE__ */ V(co, [["__scopeId", "data-v-7ef59bc8"]]), yo = ["id"], vo = {
|
|
1553
1659
|
class: /* @__PURE__ */ k(["joy-multi-checkbox"])
|
|
1554
|
-
},
|
|
1660
|
+
}, mo = /* @__PURE__ */ $({
|
|
1555
1661
|
__name: "VJoyMultiCheckbox",
|
|
1556
1662
|
props: {
|
|
1557
1663
|
options: {
|
|
1558
1664
|
type: Array,
|
|
1559
1665
|
required: !0,
|
|
1560
1666
|
validator(e) {
|
|
1561
|
-
const t = e.every((
|
|
1667
|
+
const t = e.every((o) => Object.keys(o).includes("value")), l = e.every((o) => Object.keys(o).includes("label"));
|
|
1562
1668
|
return t && l;
|
|
1563
1669
|
}
|
|
1564
1670
|
},
|
|
@@ -1591,18 +1697,18 @@ const Xl = /* @__PURE__ */ V(Yl, [["__scopeId", "data-v-7ef59bc8"]]), ea = ["id"
|
|
|
1591
1697
|
emits: ["update:value"],
|
|
1592
1698
|
setup(e, { emit: t }) {
|
|
1593
1699
|
const l = e;
|
|
1594
|
-
function
|
|
1700
|
+
function o(r) {
|
|
1595
1701
|
return l.value.includes(r.value);
|
|
1596
1702
|
}
|
|
1597
|
-
function
|
|
1598
|
-
let
|
|
1599
|
-
s ?
|
|
1703
|
+
function n(r, s) {
|
|
1704
|
+
let a = [...l.value || []];
|
|
1705
|
+
s ? a.push(r) : a.splice(a.indexOf(r), 1), t("update:value", a);
|
|
1600
1706
|
}
|
|
1601
1707
|
return (r, s) => (m(), p("fieldset", {
|
|
1602
1708
|
id: e.id,
|
|
1603
1709
|
class: "joy-multi-checkbox__wrapper"
|
|
1604
1710
|
}, [
|
|
1605
|
-
e.label ? (m(),
|
|
1711
|
+
e.label ? (m(), q(_(N), {
|
|
1606
1712
|
key: 0,
|
|
1607
1713
|
"tag-name": "legend",
|
|
1608
1714
|
required: e.required && e.requiredMark,
|
|
@@ -1610,42 +1716,42 @@ const Xl = /* @__PURE__ */ V(Yl, [["__scopeId", "data-v-7ef59bc8"]]), ea = ["id"
|
|
|
1610
1716
|
size: e.labelSize
|
|
1611
1717
|
}, {
|
|
1612
1718
|
default: L(() => [
|
|
1613
|
-
|
|
1719
|
+
J(I(e.label), 1)
|
|
1614
1720
|
]),
|
|
1615
1721
|
_: 1
|
|
1616
1722
|
}, 8, ["required", "optional-label", "size"])) : w("", !0),
|
|
1617
|
-
h("div",
|
|
1618
|
-
(m(!0), p(
|
|
1619
|
-
id:
|
|
1620
|
-
key:
|
|
1621
|
-
name:
|
|
1622
|
-
value:
|
|
1623
|
-
checked: a
|
|
1624
|
-
"onUpdate:checked": (
|
|
1723
|
+
h("div", vo, [
|
|
1724
|
+
(m(!0), p(ye, null, ve(e.options, (a) => (m(), q(_(he), {
|
|
1725
|
+
id: a.id,
|
|
1726
|
+
key: a.id,
|
|
1727
|
+
name: a.name,
|
|
1728
|
+
value: a.value,
|
|
1729
|
+
checked: o(a),
|
|
1730
|
+
"onUpdate:checked": (c) => n(a.value, c)
|
|
1625
1731
|
}, {
|
|
1626
1732
|
default: L(() => [
|
|
1627
|
-
|
|
1628
|
-
|
|
1733
|
+
g(r.$slots, "checkbox", me(pe(a)), () => [
|
|
1734
|
+
J(I(a.label), 1)
|
|
1629
1735
|
], !0)
|
|
1630
1736
|
]),
|
|
1631
1737
|
_: 2
|
|
1632
1738
|
}, 1032, ["id", "name", "value", "checked", "onUpdate:checked"]))), 128))
|
|
1633
1739
|
])
|
|
1634
|
-
], 8,
|
|
1740
|
+
], 8, yo));
|
|
1635
1741
|
}
|
|
1636
1742
|
});
|
|
1637
|
-
const
|
|
1743
|
+
const po = /* @__PURE__ */ V(mo, [["__scopeId", "data-v-f4301a1f"]]), ho = ["small", "medium", "large"], bo = {
|
|
1638
1744
|
class: /* @__PURE__ */ k(["joy-panel__header"])
|
|
1639
|
-
},
|
|
1745
|
+
}, go = {
|
|
1640
1746
|
key: 0,
|
|
1641
1747
|
class: "joy-panel__header-title"
|
|
1642
|
-
},
|
|
1748
|
+
}, _o = {
|
|
1643
1749
|
key: 1,
|
|
1644
1750
|
class: "joy-panel__header-action"
|
|
1645
|
-
},
|
|
1751
|
+
}, wo = {
|
|
1646
1752
|
key: 2,
|
|
1647
1753
|
class: "joy-panel__header-subtitle"
|
|
1648
|
-
},
|
|
1754
|
+
}, So = { class: "joy-panel__body" }, jo = { class: "joy-panel__footer" }, ko = /* @__PURE__ */ $({
|
|
1649
1755
|
__name: "VJoyPanel",
|
|
1650
1756
|
props: {
|
|
1651
1757
|
flex: {
|
|
@@ -1659,62 +1765,62 @@ const aa = /* @__PURE__ */ V(la, [["__scopeId", "data-v-f4301a1f"]]), oa = ["sma
|
|
|
1659
1765
|
type: String,
|
|
1660
1766
|
defaut: "medium",
|
|
1661
1767
|
validator(e) {
|
|
1662
|
-
return
|
|
1768
|
+
return ho.includes(e);
|
|
1663
1769
|
}
|
|
1664
1770
|
}
|
|
1665
1771
|
},
|
|
1666
1772
|
setup(e) {
|
|
1667
|
-
const t =
|
|
1668
|
-
var
|
|
1669
|
-
return (
|
|
1773
|
+
const t = W(), l = b(), o = x(() => {
|
|
1774
|
+
var n;
|
|
1775
|
+
return (n = l.value) == null ? void 0 : n.closest(".joy-wrapper");
|
|
1670
1776
|
});
|
|
1671
|
-
return (
|
|
1777
|
+
return (n, r) => (m(), p("section", {
|
|
1672
1778
|
ref_key: "panel",
|
|
1673
1779
|
ref: l,
|
|
1674
|
-
style:
|
|
1675
|
-
class: k(["joy-panel", `joy-panel--${e.padding}`, { "joy-panel--no-margin": e.noMargin || _(
|
|
1780
|
+
style: K({ flex: e.flex }),
|
|
1781
|
+
class: k(["joy-panel", `joy-panel--${e.padding}`, { "joy-panel--no-margin": e.noMargin || _(o) }])
|
|
1676
1782
|
}, [
|
|
1677
|
-
h("header",
|
|
1678
|
-
_(t)["panel-title"] ? (m(), p("div",
|
|
1679
|
-
|
|
1783
|
+
h("header", bo, [
|
|
1784
|
+
_(t)["panel-title"] ? (m(), p("div", go, [
|
|
1785
|
+
g(n.$slots, "panel-title", {}, void 0, !0)
|
|
1680
1786
|
])) : w("", !0),
|
|
1681
|
-
_(t)["panel-action"] ? (m(), p("div",
|
|
1682
|
-
|
|
1787
|
+
_(t)["panel-action"] ? (m(), p("div", _o, [
|
|
1788
|
+
g(n.$slots, "panel-title-action", {}, void 0, !0)
|
|
1683
1789
|
])) : w("", !0),
|
|
1684
|
-
_(t)["panel-subtitle"] ? (m(), p("div",
|
|
1685
|
-
|
|
1790
|
+
_(t)["panel-subtitle"] ? (m(), p("div", wo, [
|
|
1791
|
+
g(n.$slots, "panel-subtitle", {}, void 0, !0)
|
|
1686
1792
|
])) : w("", !0)
|
|
1687
1793
|
]),
|
|
1688
|
-
h("div",
|
|
1689
|
-
|
|
1794
|
+
h("div", So, [
|
|
1795
|
+
g(n.$slots, "panel-body", {}, void 0, !0)
|
|
1690
1796
|
]),
|
|
1691
|
-
h("footer",
|
|
1692
|
-
|
|
1797
|
+
h("footer", jo, [
|
|
1798
|
+
g(n.$slots, "panel-action", {}, void 0, !0)
|
|
1693
1799
|
])
|
|
1694
1800
|
], 6));
|
|
1695
1801
|
}
|
|
1696
1802
|
});
|
|
1697
|
-
const
|
|
1803
|
+
const $o = /* @__PURE__ */ V(ko, [["__scopeId", "data-v-2e2ef043"]]), Vo = { class: "joy-panel-section" }, xo = {
|
|
1698
1804
|
key: 0,
|
|
1699
1805
|
class: "joy-panel-section__title"
|
|
1700
|
-
},
|
|
1806
|
+
}, Oo = {
|
|
1701
1807
|
key: 1,
|
|
1702
1808
|
class: "joy-panel-section__content"
|
|
1703
|
-
},
|
|
1809
|
+
}, Io = /* @__PURE__ */ $({
|
|
1704
1810
|
__name: "VJoyPanelSection",
|
|
1705
1811
|
setup(e) {
|
|
1706
|
-
const t =
|
|
1707
|
-
return (l,
|
|
1708
|
-
_(t)["panel-section-title"] ? (m(), p("div",
|
|
1709
|
-
|
|
1812
|
+
const t = W();
|
|
1813
|
+
return (l, o) => (m(), p("div", Vo, [
|
|
1814
|
+
_(t)["panel-section-title"] ? (m(), p("div", xo, [
|
|
1815
|
+
g(l.$slots, "panel-section-title", {}, void 0, !0)
|
|
1710
1816
|
])) : w("", !0),
|
|
1711
|
-
_(t)["panel-section-content"] ? (m(), p("div",
|
|
1712
|
-
|
|
1817
|
+
_(t)["panel-section-content"] ? (m(), p("div", Oo, [
|
|
1818
|
+
g(l.$slots, "panel-section-content", {}, void 0, !0)
|
|
1713
1819
|
])) : w("", !0)
|
|
1714
1820
|
]));
|
|
1715
1821
|
}
|
|
1716
1822
|
});
|
|
1717
|
-
const
|
|
1823
|
+
const Bo = /* @__PURE__ */ V(Io, [["__scopeId", "data-v-d88510ab"]]), Lo = ["id", "value", "checked", "disabled", "required", "name"], Eo = { class: "joy-radio-label" }, Co = { class: "joy-radio-content__wrapper" }, Po = { class: "joy-radio-content" }, Jo = /* @__PURE__ */ $({
|
|
1718
1824
|
__name: "VJoyRadio",
|
|
1719
1825
|
props: {
|
|
1720
1826
|
disabled: {
|
|
@@ -1750,33 +1856,42 @@ const ha = /* @__PURE__ */ V(pa, [["__scopeId", "data-v-d88510ab"]]), ba = ["id"
|
|
|
1750
1856
|
},
|
|
1751
1857
|
emits: ["update:modelValue"],
|
|
1752
1858
|
setup(e, { expose: t, emit: l }) {
|
|
1753
|
-
const
|
|
1754
|
-
function
|
|
1755
|
-
|
|
1859
|
+
const o = e, n = b(!1), r = b(!1), s = b(null), a = b(null), c = W(), f = x(() => !o.modelValue || !o.value ? !1 : o.modelValue === o.value);
|
|
1860
|
+
function u() {
|
|
1861
|
+
n.value = !!c["expandable-content"] && f.value;
|
|
1756
1862
|
}
|
|
1757
|
-
function
|
|
1758
|
-
l("update:modelValue",
|
|
1863
|
+
function v() {
|
|
1864
|
+
l("update:modelValue", o.value), u();
|
|
1865
|
+
}
|
|
1866
|
+
Z(() => {
|
|
1867
|
+
o.theme === "outline" && u();
|
|
1868
|
+
});
|
|
1869
|
+
function i() {
|
|
1870
|
+
r.value = !0;
|
|
1871
|
+
}
|
|
1872
|
+
function y() {
|
|
1873
|
+
r.value = !1;
|
|
1759
1874
|
}
|
|
1760
|
-
return
|
|
1761
|
-
|
|
1762
|
-
}), q(
|
|
1763
|
-
() => a.modelValue,
|
|
1875
|
+
return B(
|
|
1876
|
+
() => o.modelValue,
|
|
1764
1877
|
() => {
|
|
1765
|
-
|
|
1878
|
+
u();
|
|
1766
1879
|
}
|
|
1767
1880
|
), t({
|
|
1768
|
-
checked:
|
|
1769
|
-
isExpanded:
|
|
1770
|
-
}), (
|
|
1881
|
+
checked: f,
|
|
1882
|
+
isExpanded: n
|
|
1883
|
+
}), (d, j) => (m(), p("label", {
|
|
1771
1884
|
ref_key: "root",
|
|
1772
|
-
ref:
|
|
1885
|
+
ref: s,
|
|
1773
1886
|
class: k([
|
|
1774
1887
|
"joy-radio",
|
|
1775
1888
|
`joy-radio--${e.theme}`,
|
|
1776
1889
|
{
|
|
1777
|
-
"joy-radio--checked": _(
|
|
1890
|
+
"joy-radio--checked": _(f),
|
|
1778
1891
|
"joy-radio--disabled": e.disabled,
|
|
1779
|
-
"joy-radio--invalid": e.invalid
|
|
1892
|
+
"joy-radio--invalid": e.invalid,
|
|
1893
|
+
"joy-radio--outline-focus": r.value && e.theme === "outline",
|
|
1894
|
+
"joy-radio--focus": r.value && e.theme === "default"
|
|
1780
1895
|
}
|
|
1781
1896
|
])
|
|
1782
1897
|
}, [
|
|
@@ -1784,31 +1899,33 @@ const ha = /* @__PURE__ */ V(pa, [["__scopeId", "data-v-d88510ab"]]), ba = ["id"
|
|
|
1784
1899
|
id: e.id,
|
|
1785
1900
|
type: "radio",
|
|
1786
1901
|
value: e.value,
|
|
1787
|
-
checked: _(
|
|
1902
|
+
checked: _(f),
|
|
1788
1903
|
disabled: e.disabled,
|
|
1789
1904
|
required: e.required,
|
|
1790
1905
|
name: e.name,
|
|
1791
|
-
onChange:
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1906
|
+
onChange: v,
|
|
1907
|
+
onFocus: i,
|
|
1908
|
+
onBlur: y
|
|
1909
|
+
}, null, 40, Lo),
|
|
1910
|
+
h("span", Eo, [
|
|
1911
|
+
g(d.$slots, "default", {}, void 0, !0)
|
|
1795
1912
|
]),
|
|
1796
|
-
h("div",
|
|
1797
|
-
h("div",
|
|
1798
|
-
|
|
1913
|
+
h("div", Co, [
|
|
1914
|
+
h("div", Po, [
|
|
1915
|
+
g(d.$slots, "radio-content", {}, void 0, !0)
|
|
1799
1916
|
]),
|
|
1800
1917
|
h("div", {
|
|
1801
1918
|
ref_key: "expandableElement",
|
|
1802
|
-
ref:
|
|
1803
|
-
class: k(["joy-radio-expandable", { "joy-radio-expandable--expanded":
|
|
1919
|
+
ref: a,
|
|
1920
|
+
class: k(["joy-radio-expandable", { "joy-radio-expandable--expanded": n.value }])
|
|
1804
1921
|
}, [
|
|
1805
|
-
|
|
1922
|
+
g(d.$slots, "expandable-content", {}, void 0, !0)
|
|
1806
1923
|
], 2)
|
|
1807
1924
|
])
|
|
1808
1925
|
], 2));
|
|
1809
1926
|
}
|
|
1810
1927
|
});
|
|
1811
|
-
const
|
|
1928
|
+
const qo = /* @__PURE__ */ V(Jo, [["__scopeId", "data-v-24cea99b"]]), To = ["form", "name"], zo = /* @__PURE__ */ $({
|
|
1812
1929
|
__name: "VJoyRadioGroup",
|
|
1813
1930
|
props: {
|
|
1814
1931
|
direction: {
|
|
@@ -1830,19 +1947,19 @@ const ka = /* @__PURE__ */ V(Sa, [["__scopeId", "data-v-d5988486"]]), ja = ["for
|
|
|
1830
1947
|
form: e.form,
|
|
1831
1948
|
name: e.name
|
|
1832
1949
|
}, [
|
|
1833
|
-
|
|
1950
|
+
g(t.$slots, "radio-group-legend", {}, void 0, !0),
|
|
1834
1951
|
h("div", {
|
|
1835
1952
|
class: k(["joy-radio-group-container", `joy-radio-group-${e.direction}`])
|
|
1836
1953
|
}, [
|
|
1837
|
-
|
|
1954
|
+
g(t.$slots, "default", {}, void 0, !0)
|
|
1838
1955
|
], 2)
|
|
1839
|
-
], 8,
|
|
1956
|
+
], 8, To));
|
|
1840
1957
|
}
|
|
1841
1958
|
});
|
|
1842
|
-
const
|
|
1959
|
+
const Ao = /* @__PURE__ */ V(zo, [["__scopeId", "data-v-de56c3c4"]]), Fo = (e) => (te("data-v-d251a432"), e = e(), le(), e), Do = ["id", "name", "aria-invalid", "required", "disabled", "value"], Ro = /* @__PURE__ */ Fo(() => /* @__PURE__ */ h("joy-icon", {
|
|
1843
1960
|
class: "joy-select__chevron",
|
|
1844
1961
|
name: "chevron-down"
|
|
1845
|
-
}, null, -1)),
|
|
1962
|
+
}, null, -1)), Mo = /* @__PURE__ */ $({
|
|
1846
1963
|
__name: "VJoySelect",
|
|
1847
1964
|
props: {
|
|
1848
1965
|
disabled: {
|
|
@@ -1883,32 +2000,38 @@ const Va = /* @__PURE__ */ V($a, [["__scopeId", "data-v-de56c3c4"]]), xa = (e) =
|
|
|
1883
2000
|
},
|
|
1884
2001
|
emits: ["update:modelValue"],
|
|
1885
2002
|
setup(e, { emit: t }) {
|
|
1886
|
-
const l = e,
|
|
1887
|
-
|
|
1888
|
-
var
|
|
1889
|
-
const
|
|
1890
|
-
if (!
|
|
2003
|
+
const l = e, o = b(), n = b(), r = W(), s = b(!1);
|
|
2004
|
+
Z(() => {
|
|
2005
|
+
var i;
|
|
2006
|
+
const u = r.label && r.label();
|
|
2007
|
+
if (!u || !u.length)
|
|
1891
2008
|
return;
|
|
1892
|
-
const
|
|
1893
|
-
if (
|
|
1894
|
-
const
|
|
1895
|
-
if (!
|
|
2009
|
+
const v = u[0];
|
|
2010
|
+
if (v.type === "JoyLabel") {
|
|
2011
|
+
const y = (i = v.props) == null ? void 0 : i.for;
|
|
2012
|
+
if (!y) {
|
|
1896
2013
|
console.warn("JoyLabel for attribute is missing");
|
|
1897
2014
|
return;
|
|
1898
2015
|
}
|
|
1899
|
-
|
|
2016
|
+
y !== l.id && console.warn("JoyLabel for attribute does not match with JoySelect id");
|
|
1900
2017
|
}
|
|
1901
2018
|
});
|
|
1902
|
-
function
|
|
1903
|
-
const
|
|
1904
|
-
t("update:modelValue",
|
|
2019
|
+
function a(u) {
|
|
2020
|
+
const v = u.target.value;
|
|
2021
|
+
t("update:modelValue", v);
|
|
2022
|
+
}
|
|
2023
|
+
function c() {
|
|
2024
|
+
s.value = !0;
|
|
2025
|
+
}
|
|
2026
|
+
function f() {
|
|
2027
|
+
s.value = !1;
|
|
1905
2028
|
}
|
|
1906
|
-
return (
|
|
2029
|
+
return (u, v) => (m(), p("div", {
|
|
1907
2030
|
ref_key: "root",
|
|
1908
|
-
ref:
|
|
2031
|
+
ref: o
|
|
1909
2032
|
}, [
|
|
1910
|
-
|
|
1911
|
-
e.label ? (m(),
|
|
2033
|
+
g(u.$slots, "label", {}, () => [
|
|
2034
|
+
e.label ? (m(), q(N, {
|
|
1912
2035
|
key: 0,
|
|
1913
2036
|
required: e.required && e.requiredMark,
|
|
1914
2037
|
"optional-label": e.optionalLabel,
|
|
@@ -1916,7 +2039,7 @@ const Va = /* @__PURE__ */ V($a, [["__scopeId", "data-v-de56c3c4"]]), xa = (e) =
|
|
|
1916
2039
|
size: e.labelSize
|
|
1917
2040
|
}, {
|
|
1918
2041
|
default: L(() => [
|
|
1919
|
-
|
|
2042
|
+
J(I(e.label), 1)
|
|
1920
2043
|
]),
|
|
1921
2044
|
_: 1
|
|
1922
2045
|
}, 8, ["required", "optional-label", "for", "size"])) : w("", !0)
|
|
@@ -1925,29 +2048,32 @@ const Va = /* @__PURE__ */ V($a, [["__scopeId", "data-v-de56c3c4"]]), xa = (e) =
|
|
|
1925
2048
|
class: k({
|
|
1926
2049
|
"joy-select__wrapper": !0,
|
|
1927
2050
|
"joy-select--invalid": e.invalid,
|
|
1928
|
-
"joy-select--disabled": e.disabled
|
|
2051
|
+
"joy-select--disabled": e.disabled,
|
|
2052
|
+
"joy-select--focusing": s.value
|
|
1929
2053
|
})
|
|
1930
2054
|
}, [
|
|
1931
2055
|
h("select", {
|
|
1932
2056
|
id: e.id || e.name,
|
|
1933
2057
|
ref_key: "select",
|
|
1934
|
-
ref:
|
|
2058
|
+
ref: n,
|
|
1935
2059
|
class: "joy-select",
|
|
1936
2060
|
name: e.name,
|
|
1937
2061
|
"aria-invalid": e.invalid,
|
|
1938
2062
|
required: e.required,
|
|
1939
2063
|
disabled: e.disabled,
|
|
1940
2064
|
value: e.modelValue,
|
|
1941
|
-
onInput:
|
|
2065
|
+
onInput: a,
|
|
2066
|
+
onFocus: c,
|
|
2067
|
+
onBlur: f
|
|
1942
2068
|
}, [
|
|
1943
|
-
|
|
1944
|
-
], 40,
|
|
1945
|
-
|
|
2069
|
+
g(u.$slots, "default", {}, void 0, !0)
|
|
2070
|
+
], 40, Do),
|
|
2071
|
+
Ro
|
|
1946
2072
|
], 2)
|
|
1947
2073
|
], 512));
|
|
1948
2074
|
}
|
|
1949
2075
|
});
|
|
1950
|
-
const
|
|
2076
|
+
const No = /* @__PURE__ */ V(Mo, [["__scopeId", "data-v-d251a432"]]), Ho = ["aria-disabled"], Wo = ["id", "value", "checked", "disabled", "required", "name"], Uo = /* @__PURE__ */ $({
|
|
1951
2077
|
__name: "VJoySelectableItem",
|
|
1952
2078
|
props: {
|
|
1953
2079
|
disabled: {
|
|
@@ -1984,41 +2110,56 @@ const Ea = /* @__PURE__ */ V(La, [["__scopeId", "data-v-e856916f"]]), Ba = ["ari
|
|
|
1984
2110
|
},
|
|
1985
2111
|
emits: ["update:checked"],
|
|
1986
2112
|
setup(e, { emit: t }) {
|
|
1987
|
-
const l = e,
|
|
2113
|
+
const l = e, o = b(l.checked), n = b(), r = b(!1), s = l.multiple ? "div" : "label", a = {
|
|
1988
2114
|
onRadioChange: () => {
|
|
1989
2115
|
t("update:checked", l.value);
|
|
1990
2116
|
},
|
|
1991
2117
|
onClick: () => {
|
|
1992
2118
|
l.checked && !l.multiple && t("update:checked", "");
|
|
1993
2119
|
},
|
|
1994
|
-
onLabelClick: (
|
|
1995
|
-
l.multiple ||
|
|
2120
|
+
onLabelClick: (f) => {
|
|
2121
|
+
l.multiple || f.stopPropagation();
|
|
2122
|
+
},
|
|
2123
|
+
onFocus: () => {
|
|
2124
|
+
r.value = !0;
|
|
2125
|
+
},
|
|
2126
|
+
onBlur: () => {
|
|
2127
|
+
r.value = !1;
|
|
1996
2128
|
}
|
|
1997
2129
|
};
|
|
1998
|
-
function
|
|
1999
|
-
t("update:checked",
|
|
2130
|
+
function c(f) {
|
|
2131
|
+
t("update:checked", f);
|
|
2000
2132
|
}
|
|
2001
|
-
return (
|
|
2002
|
-
class:
|
|
2133
|
+
return (f, u) => (m(), p("div", {
|
|
2134
|
+
class: k([
|
|
2135
|
+
"joy-selectable-item__wrapper",
|
|
2136
|
+
{
|
|
2137
|
+
"joy-selectable-item--focusing": r.value
|
|
2138
|
+
}
|
|
2139
|
+
]),
|
|
2003
2140
|
"aria-disabled": e.disabled,
|
|
2004
|
-
onClick:
|
|
2005
|
-
(...
|
|
2141
|
+
onClick: u[4] || (u[4] = //@ts-ignore
|
|
2142
|
+
(...v) => a.onClick && a.onClick(...v))
|
|
2006
2143
|
}, [
|
|
2007
2144
|
e.multiple ? w("", !0) : (m(), p("input", {
|
|
2008
2145
|
key: 0,
|
|
2009
2146
|
id: e.id,
|
|
2010
2147
|
ref_key: "inputRadio",
|
|
2011
|
-
ref:
|
|
2148
|
+
ref: n,
|
|
2012
2149
|
type: "radio",
|
|
2013
2150
|
value: e.value,
|
|
2014
2151
|
checked: e.checked,
|
|
2015
2152
|
disabled: e.disabled,
|
|
2016
2153
|
required: e.required,
|
|
2017
2154
|
name: e.name,
|
|
2018
|
-
onChange:
|
|
2019
|
-
(...
|
|
2020
|
-
|
|
2021
|
-
|
|
2155
|
+
onChange: u[0] || (u[0] = //@ts-ignore
|
|
2156
|
+
(...v) => a.onRadioChange && a.onRadioChange(...v)),
|
|
2157
|
+
onFocus: u[1] || (u[1] = //@ts-ignore
|
|
2158
|
+
(...v) => a.onFocus && a.onFocus(...v)),
|
|
2159
|
+
onBlur: u[2] || (u[2] = //@ts-ignore
|
|
2160
|
+
(...v) => a.onBlur && a.onBlur(...v))
|
|
2161
|
+
}, null, 40, Wo)),
|
|
2162
|
+
(m(), q(ce(_(s)), {
|
|
2022
2163
|
for: e.id,
|
|
2023
2164
|
class: k([
|
|
2024
2165
|
"joy-selectable-item",
|
|
@@ -2029,47 +2170,50 @@ const Ea = /* @__PURE__ */ V(La, [["__scopeId", "data-v-e856916f"]]), Ba = ["ari
|
|
|
2029
2170
|
"joy-selectable-item--single": !e.multiple
|
|
2030
2171
|
}
|
|
2031
2172
|
]),
|
|
2032
|
-
onClick:
|
|
2173
|
+
onClick: a.onLabelClick
|
|
2033
2174
|
}, {
|
|
2034
2175
|
default: L(() => [
|
|
2035
|
-
e.multiple ? (m(),
|
|
2176
|
+
e.multiple ? (m(), q(_(he), {
|
|
2036
2177
|
key: 0,
|
|
2037
2178
|
id: e.id,
|
|
2038
|
-
checked:
|
|
2179
|
+
checked: o.value,
|
|
2039
2180
|
"onUpdate:checked": [
|
|
2040
|
-
|
|
2041
|
-
|
|
2181
|
+
u[3] || (u[3] = (v) => o.value = v),
|
|
2182
|
+
c
|
|
2042
2183
|
],
|
|
2043
2184
|
disabled: e.disabled,
|
|
2044
2185
|
value: e.value,
|
|
2045
2186
|
name: e.name,
|
|
2046
|
-
|
|
2187
|
+
"display-focus": !1,
|
|
2188
|
+
required: e.required,
|
|
2189
|
+
onFocus: a.onFocus,
|
|
2190
|
+
onBlur: a.onBlur
|
|
2047
2191
|
}, {
|
|
2048
2192
|
default: L(() => [
|
|
2049
|
-
|
|
2193
|
+
g(f.$slots, "default", {}, void 0, !0)
|
|
2050
2194
|
]),
|
|
2051
2195
|
_: 3
|
|
2052
|
-
}, 8, ["id", "checked", "disabled", "value", "name", "required"])) : w("", !0),
|
|
2053
|
-
e.multiple ? w("", !0) :
|
|
2196
|
+
}, 8, ["id", "checked", "disabled", "value", "name", "required", "onFocus", "onBlur"])) : w("", !0),
|
|
2197
|
+
e.multiple ? w("", !0) : g(f.$slots, "default", { key: 1 }, void 0, !0),
|
|
2054
2198
|
h("div", {
|
|
2055
|
-
class: k([{ "joy-selectable-item__sublabel":
|
|
2199
|
+
class: k([{ "joy-selectable-item__sublabel": f.$slots["selectable-item-sublabel"] }])
|
|
2056
2200
|
}, [
|
|
2057
|
-
|
|
2201
|
+
g(f.$slots, "selectable-item-sublabel", {}, void 0, !0)
|
|
2058
2202
|
], 2)
|
|
2059
2203
|
]),
|
|
2060
2204
|
_: 3
|
|
2061
2205
|
}, 8, ["for", "class", "onClick"]))
|
|
2062
|
-
],
|
|
2206
|
+
], 10, Ho));
|
|
2063
2207
|
}
|
|
2064
2208
|
});
|
|
2065
|
-
const
|
|
2209
|
+
const tt = /* @__PURE__ */ V(Uo, [["__scopeId", "data-v-cb2531c0"]]), Go = ["id"], Ko = /* @__PURE__ */ $({
|
|
2066
2210
|
__name: "VJoySelectableItemGroup",
|
|
2067
2211
|
props: {
|
|
2068
2212
|
options: {
|
|
2069
2213
|
type: Array,
|
|
2070
2214
|
required: !0,
|
|
2071
2215
|
validator(e) {
|
|
2072
|
-
const t = e.every((
|
|
2216
|
+
const t = e.every((o) => Object.keys(o).includes("value")), l = e.every((o) => Object.keys(o).includes("label"));
|
|
2073
2217
|
return t && l;
|
|
2074
2218
|
}
|
|
2075
2219
|
},
|
|
@@ -2104,20 +2248,20 @@ const Xe = /* @__PURE__ */ V(Pa, [["__scopeId", "data-v-c40bf83e"]]), qa = ["id"
|
|
|
2104
2248
|
emits: ["update:value"],
|
|
2105
2249
|
setup(e, { emit: t }) {
|
|
2106
2250
|
const l = e;
|
|
2107
|
-
function
|
|
2251
|
+
function o(r) {
|
|
2108
2252
|
return typeof l.value == "string" ? l.value === r.value : (l.value || []).includes(r.value);
|
|
2109
2253
|
}
|
|
2110
|
-
function
|
|
2254
|
+
function n(r, s) {
|
|
2111
2255
|
if (!l.multiple)
|
|
2112
2256
|
return t("update:value", s);
|
|
2113
|
-
let
|
|
2114
|
-
s && typeof s == "boolean" ?
|
|
2257
|
+
let a = [...l.value || []];
|
|
2258
|
+
s && typeof s == "boolean" ? a.push(r) : a.splice(a.indexOf(r), 1), t("update:value", a);
|
|
2115
2259
|
}
|
|
2116
2260
|
return (r, s) => (m(), p("fieldset", {
|
|
2117
2261
|
id: e.id,
|
|
2118
2262
|
class: "joy-selectable-item-group__wrapper"
|
|
2119
2263
|
}, [
|
|
2120
|
-
e.label ? (m(),
|
|
2264
|
+
e.label ? (m(), q(_(N), {
|
|
2121
2265
|
key: 0,
|
|
2122
2266
|
"tag-name": "legend",
|
|
2123
2267
|
required: e.required && e.requiredMark,
|
|
@@ -2125,7 +2269,7 @@ const Xe = /* @__PURE__ */ V(Pa, [["__scopeId", "data-v-c40bf83e"]]), qa = ["id"
|
|
|
2125
2269
|
size: e.labelSize
|
|
2126
2270
|
}, {
|
|
2127
2271
|
default: L(() => [
|
|
2128
|
-
|
|
2272
|
+
J(I(e.label), 1)
|
|
2129
2273
|
]),
|
|
2130
2274
|
_: 1
|
|
2131
2275
|
}, 8, ["required", "optional-label", "size"])) : w("", !0),
|
|
@@ -2139,33 +2283,33 @@ const Xe = /* @__PURE__ */ V(Pa, [["__scopeId", "data-v-c40bf83e"]]), qa = ["id"
|
|
|
2139
2283
|
}
|
|
2140
2284
|
])
|
|
2141
2285
|
}, [
|
|
2142
|
-
(m(!0), p(
|
|
2143
|
-
id:
|
|
2144
|
-
key:
|
|
2145
|
-
name:
|
|
2146
|
-
value:
|
|
2286
|
+
(m(!0), p(ye, null, ve(e.options, (a) => (m(), q(_(tt), {
|
|
2287
|
+
id: a.id,
|
|
2288
|
+
key: a.id,
|
|
2289
|
+
name: a.name,
|
|
2290
|
+
value: a.value,
|
|
2147
2291
|
multiple: e.multiple,
|
|
2148
|
-
checked: a
|
|
2149
|
-
"onUpdate:checked": (
|
|
2150
|
-
},
|
|
2292
|
+
checked: o(a),
|
|
2293
|
+
"onUpdate:checked": (c) => n(a.value, c)
|
|
2294
|
+
}, ut({
|
|
2151
2295
|
default: L(() => [
|
|
2152
|
-
|
|
2296
|
+
J(I(a.label) + " ", 1)
|
|
2153
2297
|
]),
|
|
2154
2298
|
_: 2
|
|
2155
2299
|
}, [
|
|
2156
|
-
|
|
2300
|
+
a.subLabel ? {
|
|
2157
2301
|
name: "selectable-item-sublabel",
|
|
2158
2302
|
fn: L(() => [
|
|
2159
|
-
|
|
2303
|
+
J(I(a.subLabel), 1)
|
|
2160
2304
|
]),
|
|
2161
2305
|
key: "0"
|
|
2162
2306
|
} : void 0
|
|
2163
2307
|
]), 1032, ["id", "name", "value", "multiple", "checked", "onUpdate:checked"]))), 128))
|
|
2164
2308
|
], 2)
|
|
2165
|
-
], 8,
|
|
2309
|
+
], 8, Go));
|
|
2166
2310
|
}
|
|
2167
2311
|
});
|
|
2168
|
-
const
|
|
2312
|
+
const Qo = /* @__PURE__ */ V(Ko, [["__scopeId", "data-v-3ba17434"]]), Zo = /* @__PURE__ */ $({
|
|
2169
2313
|
__name: "VJoyWrapper",
|
|
2170
2314
|
props: {
|
|
2171
2315
|
justify: {
|
|
@@ -2189,76 +2333,81 @@ const Ta = /* @__PURE__ */ V(Ja, [["__scopeId", "data-v-3ba17434"]]), za = /* @_
|
|
|
2189
2333
|
return (t, l) => (m(), p("div", {
|
|
2190
2334
|
class: k(["joy-wrapper", `joy-wrapper--justify-${e.justify}`, `joy-wrapper--align-${e.align}`, `joy-wrapper--direction-${e.direction}`, `joy-wrapper--wrap-${e.wrap}`])
|
|
2191
2335
|
}, [
|
|
2192
|
-
|
|
2336
|
+
g(t.$slots, "default", {}, void 0, !0)
|
|
2193
2337
|
], 2));
|
|
2194
2338
|
}
|
|
2195
2339
|
});
|
|
2196
|
-
const
|
|
2340
|
+
const Yo = /* @__PURE__ */ V(Zo, [["__scopeId", "data-v-319d995e"]]), Xo = { class: "joy-template__wrapper" }, en = {
|
|
2341
|
+
key: 0,
|
|
2342
|
+
class: "joy-template__heading"
|
|
2343
|
+
}, tn = {
|
|
2197
2344
|
key: 0,
|
|
2198
2345
|
class: "joy-template-slot-back"
|
|
2199
|
-
},
|
|
2346
|
+
}, ln = { class: "joy-template__heading___headings" }, on = {
|
|
2200
2347
|
key: 0,
|
|
2201
2348
|
class: "joy-template-slot-title"
|
|
2202
|
-
},
|
|
2349
|
+
}, nn = {
|
|
2203
2350
|
key: 1,
|
|
2204
2351
|
class: "joy-template-slot-subtitle"
|
|
2205
|
-
},
|
|
2352
|
+
}, an = {
|
|
2206
2353
|
key: 0,
|
|
2207
2354
|
class: "joy-template-slot-main"
|
|
2208
|
-
},
|
|
2355
|
+
}, rn = {
|
|
2209
2356
|
key: 1,
|
|
2210
2357
|
class: "joy-template-slot-sidebar"
|
|
2211
|
-
},
|
|
2358
|
+
}, sn = /* @__PURE__ */ $({
|
|
2212
2359
|
__name: "VJoyTemplate",
|
|
2213
2360
|
props: {
|
|
2214
2361
|
full: { type: Boolean, default: !1 },
|
|
2215
2362
|
sidebar: { type: String, default: "right" }
|
|
2216
2363
|
},
|
|
2217
2364
|
setup(e) {
|
|
2218
|
-
const t = e, l =
|
|
2219
|
-
return (
|
|
2365
|
+
const t = e, l = W(), o = x(() => !!l["template-back"] || !!l["template-title"] || !!l["template-subtitle"]);
|
|
2366
|
+
return (n, r) => (m(), p("main", {
|
|
2220
2367
|
class: k(["joy-template", { "joy-template--full": t.full }])
|
|
2221
2368
|
}, [
|
|
2222
|
-
h("div",
|
|
2223
|
-
_(
|
|
2224
|
-
|
|
2369
|
+
h("div", Xo, [
|
|
2370
|
+
_(o) ? (m(), p("div", en, [
|
|
2371
|
+
_(l)["template-back"] ? (m(), p("div", tn, [
|
|
2372
|
+
g(n.$slots, "template-back", {}, void 0, !0)
|
|
2373
|
+
])) : w("", !0),
|
|
2374
|
+
h("div", ln, [
|
|
2375
|
+
_(l)["template-title"] ? (m(), p("div", on, [
|
|
2376
|
+
g(n.$slots, "template-title", {}, void 0, !0)
|
|
2377
|
+
])) : w("", !0),
|
|
2378
|
+
_(l)["template-subtitle"] ? (m(), p("div", nn, [
|
|
2379
|
+
g(n.$slots, "template-subtitle", {}, void 0, !0)
|
|
2380
|
+
])) : w("", !0)
|
|
2381
|
+
])
|
|
2225
2382
|
])) : w("", !0),
|
|
2226
|
-
h("div",
|
|
2227
|
-
|
|
2228
|
-
|
|
2383
|
+
h("div", {
|
|
2384
|
+
class: k([
|
|
2385
|
+
"joy-template__content",
|
|
2386
|
+
{
|
|
2387
|
+
"joy-template__content--reverse": t.sidebar === "left"
|
|
2388
|
+
}
|
|
2389
|
+
])
|
|
2390
|
+
}, [
|
|
2391
|
+
n.$slots["template-main"] ? (m(), p("div", an, [
|
|
2392
|
+
g(n.$slots, "template-main", {}, void 0, !0)
|
|
2229
2393
|
])) : w("", !0),
|
|
2230
|
-
|
|
2231
|
-
|
|
2394
|
+
n.$slots["template-sidebar"] ? (m(), p("div", rn, [
|
|
2395
|
+
g(n.$slots, "template-sidebar", {}, void 0, !0)
|
|
2232
2396
|
])) : w("", !0)
|
|
2233
|
-
])
|
|
2234
|
-
])
|
|
2235
|
-
h("div", {
|
|
2236
|
-
class: k([
|
|
2237
|
-
"joy-template__content",
|
|
2238
|
-
{
|
|
2239
|
-
"joy-template__content--reverse": t.sidebar === "left"
|
|
2240
|
-
}
|
|
2241
|
-
])
|
|
2242
|
-
}, [
|
|
2243
|
-
a.$slots["template-main"] ? (m(), p("div", Wa, [
|
|
2244
|
-
b(a.$slots, "template-main", {}, void 0, !0)
|
|
2245
|
-
])) : w("", !0),
|
|
2246
|
-
a.$slots["template-sidebar"] ? (m(), p("div", Fa, [
|
|
2247
|
-
b(a.$slots, "template-sidebar", {}, void 0, !0)
|
|
2248
|
-
])) : w("", !0)
|
|
2249
|
-
], 2)
|
|
2397
|
+
], 2)
|
|
2398
|
+
])
|
|
2250
2399
|
], 2));
|
|
2251
2400
|
}
|
|
2252
2401
|
});
|
|
2253
|
-
const
|
|
2402
|
+
const un = /* @__PURE__ */ V(sn, [["__scopeId", "data-v-f891bd85"]]), dn = ["aria-disabled"], cn = { class: "joy-textarea_wrapper" }, fn = ["id", "disabled", "name", "required", "minlength", "value"], yn = {
|
|
2254
2403
|
key: 0,
|
|
2255
2404
|
class: "joy-textarea_helpers"
|
|
2256
|
-
},
|
|
2405
|
+
}, vn = {
|
|
2257
2406
|
key: 0,
|
|
2258
2407
|
name: "check",
|
|
2259
2408
|
color: "grey",
|
|
2260
2409
|
size: "xxsmall"
|
|
2261
|
-
},
|
|
2410
|
+
}, mn = /* @__PURE__ */ $({
|
|
2262
2411
|
__name: "VJoyTextarea",
|
|
2263
2412
|
props: {
|
|
2264
2413
|
disabled: {
|
|
@@ -2307,25 +2456,23 @@ const Ga = /* @__PURE__ */ V(Ua, [["__scopeId", "data-v-a03bc629"]]), Ka = ["ari
|
|
|
2307
2456
|
},
|
|
2308
2457
|
emits: ["update:modelValue"],
|
|
2309
2458
|
setup(e, { expose: t, emit: l }) {
|
|
2310
|
-
const
|
|
2311
|
-
|
|
2312
|
-
|
|
2313
|
-
}
|
|
2314
|
-
W(() => {
|
|
2315
|
-
y();
|
|
2316
|
-
});
|
|
2317
|
-
const c = {
|
|
2459
|
+
const o = e, n = b(), { triggerResize: r } = el({
|
|
2460
|
+
element: o.autogrow ? n : void 0
|
|
2461
|
+
}), s = b(!1), a = b(!1), c = x(() => o.maxlength ? o.modelValue.length > o.maxlength : !1), f = x(() => o.minlength ? o.modelValue.length < o.minlength : !1), u = {
|
|
2318
2462
|
onInput: (v) => {
|
|
2319
|
-
l("update:modelValue", v.target.value),
|
|
2463
|
+
l("update:modelValue", v.target.value), r();
|
|
2320
2464
|
},
|
|
2321
2465
|
onBlur: () => {
|
|
2322
|
-
s.value =
|
|
2466
|
+
a.value = !1, s.value = c.value || f.value;
|
|
2467
|
+
},
|
|
2468
|
+
onFocus: () => {
|
|
2469
|
+
a.value = !0;
|
|
2323
2470
|
}
|
|
2324
2471
|
};
|
|
2325
2472
|
return t({
|
|
2326
2473
|
isInvalid: s,
|
|
2327
|
-
valueOverMaxlength:
|
|
2328
|
-
valueUnderMinlength:
|
|
2474
|
+
valueOverMaxlength: c,
|
|
2475
|
+
valueUnderMinlength: f
|
|
2329
2476
|
}), (v, i) => (m(), p("div", {
|
|
2330
2477
|
"aria-disabled": e.disabled,
|
|
2331
2478
|
class: k([
|
|
@@ -2333,32 +2480,29 @@ const Ga = /* @__PURE__ */ V(Ua, [["__scopeId", "data-v-a03bc629"]]), Ka = ["ari
|
|
|
2333
2480
|
{
|
|
2334
2481
|
"joy-textarea_invalid": s.value || e.invalid,
|
|
2335
2482
|
"joy-textarea_disabled": e.disabled,
|
|
2336
|
-
"joy-textarea_autogrow": e.autogrow
|
|
2483
|
+
"joy-textarea_autogrow": e.autogrow,
|
|
2484
|
+
"joy-textarea_focusing": a.value
|
|
2337
2485
|
}
|
|
2338
2486
|
])
|
|
2339
2487
|
}, [
|
|
2340
|
-
|
|
2488
|
+
fe(_(N), {
|
|
2341
2489
|
for: e.id,
|
|
2342
2490
|
required: e.required && e.requiredMark,
|
|
2343
2491
|
"optional-label": e.optionalLabel,
|
|
2344
2492
|
size: e.labelSize
|
|
2345
2493
|
}, {
|
|
2346
2494
|
default: L(() => [
|
|
2347
|
-
|
|
2348
|
-
|
|
2495
|
+
g(v.$slots, "default", {}, () => [
|
|
2496
|
+
J(I(e.label), 1)
|
|
2349
2497
|
], !0)
|
|
2350
2498
|
]),
|
|
2351
2499
|
_: 3
|
|
2352
2500
|
}, 8, ["for", "required", "optional-label", "size"]),
|
|
2353
|
-
h("div",
|
|
2354
|
-
|
|
2355
|
-
ref: r,
|
|
2356
|
-
class: "joy-textarea_wrapper"
|
|
2357
|
-
}, [
|
|
2358
|
-
h("textarea", K(v.$attrs, {
|
|
2501
|
+
h("div", cn, [
|
|
2502
|
+
h("textarea", Q(v.$attrs, {
|
|
2359
2503
|
id: e.id,
|
|
2360
2504
|
ref_key: "textarea",
|
|
2361
|
-
ref:
|
|
2505
|
+
ref: n,
|
|
2362
2506
|
class: "joy-native-textarea",
|
|
2363
2507
|
disabled: e.disabled,
|
|
2364
2508
|
name: e.name,
|
|
@@ -2366,28 +2510,30 @@ const Ga = /* @__PURE__ */ V(Ua, [["__scopeId", "data-v-a03bc629"]]), Ka = ["ari
|
|
|
2366
2510
|
minlength: e.minlength,
|
|
2367
2511
|
value: e.modelValue,
|
|
2368
2512
|
onInput: i[0] || (i[0] = //@ts-ignore
|
|
2369
|
-
(...
|
|
2370
|
-
|
|
2371
|
-
(...
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2513
|
+
(...y) => u.onInput && u.onInput(...y)),
|
|
2514
|
+
onFocus: i[1] || (i[1] = //@ts-ignore
|
|
2515
|
+
(...y) => u.onFocus && u.onFocus(...y)),
|
|
2516
|
+
onBlur: i[2] || (i[2] = //@ts-ignore
|
|
2517
|
+
(...y) => u.onBlur && u.onBlur(...y))
|
|
2518
|
+
}), null, 16, fn)
|
|
2519
|
+
]),
|
|
2520
|
+
e.minlength || e.maxlength ? (m(), p("div", yn, [
|
|
2375
2521
|
e.minlength ? (m(), p("p", {
|
|
2376
2522
|
key: 0,
|
|
2377
2523
|
class: k(["joy-textarea-min", { "joy-textarea-min-invalid": e.invalid }])
|
|
2378
2524
|
}, [
|
|
2379
|
-
_(
|
|
2380
|
-
|
|
2525
|
+
_(f) ? w("", !0) : (m(), p("joy-icon", vn)),
|
|
2526
|
+
J(" " + I(e.minlengthLabel || `Minimum ${e.minlength} characters`), 1)
|
|
2381
2527
|
], 2)) : w("", !0),
|
|
2382
2528
|
e.maxlength ? (m(), p("p", {
|
|
2383
2529
|
key: 1,
|
|
2384
|
-
class: k(["joy-textarea-count", { "joy-textarea-count-invalid": _(
|
|
2385
|
-
},
|
|
2530
|
+
class: k(["joy-textarea-count", { "joy-textarea-count-invalid": _(c) }])
|
|
2531
|
+
}, I(e.modelValue.length + "/" + e.maxlength), 3)) : w("", !0)
|
|
2386
2532
|
])) : w("", !0)
|
|
2387
|
-
], 10,
|
|
2533
|
+
], 10, dn));
|
|
2388
2534
|
}
|
|
2389
2535
|
});
|
|
2390
|
-
const
|
|
2536
|
+
const pn = /* @__PURE__ */ V(mn, [["__scopeId", "data-v-1496c389"]]), lt = (e) => (te("data-v-cf79d999"), e = e(), le(), e), hn = { class: "joy-toggle__wrapper" }, bn = ["name", "disabled", "checked", "required", "aria-checked", "value"], gn = { class: "joy-toggle__content" }, _n = /* @__PURE__ */ lt(() => /* @__PURE__ */ h("span", { class: "joy-toggle__symbol" }, null, -1)), wn = { class: "joy-toggle__content-label" }, Sn = /* @__PURE__ */ lt(() => /* @__PURE__ */ h("span", { class: "joy-toggle__smile" }, [
|
|
2391
2537
|
/* @__PURE__ */ h("svg", {
|
|
2392
2538
|
width: "18",
|
|
2393
2539
|
height: "10",
|
|
@@ -2400,7 +2546,7 @@ const eo = /* @__PURE__ */ V(Xa, [["__scopeId", "data-v-650f33d9"]]), to = (e) =
|
|
|
2400
2546
|
fill: "currentColor"
|
|
2401
2547
|
})
|
|
2402
2548
|
])
|
|
2403
|
-
], -1)),
|
|
2549
|
+
], -1)), jn = /* @__PURE__ */ $({
|
|
2404
2550
|
__name: "VJoyToggle",
|
|
2405
2551
|
props: {
|
|
2406
2552
|
modelValue: {
|
|
@@ -2434,19 +2580,26 @@ const eo = /* @__PURE__ */ V(Xa, [["__scopeId", "data-v-650f33d9"]]), to = (e) =
|
|
|
2434
2580
|
},
|
|
2435
2581
|
emits: ["update:modelValue"],
|
|
2436
2582
|
setup(e, { emit: t }) {
|
|
2437
|
-
const l = {
|
|
2438
|
-
onChange: (
|
|
2439
|
-
const
|
|
2440
|
-
t("update:modelValue",
|
|
2583
|
+
const l = b(!1), o = {
|
|
2584
|
+
onChange: (n) => {
|
|
2585
|
+
const r = n.target.checked;
|
|
2586
|
+
t("update:modelValue", r);
|
|
2587
|
+
},
|
|
2588
|
+
onFocus: () => {
|
|
2589
|
+
l.value = !0;
|
|
2590
|
+
},
|
|
2591
|
+
onBlur: () => {
|
|
2592
|
+
l.value = !1;
|
|
2441
2593
|
}
|
|
2442
2594
|
};
|
|
2443
|
-
return (
|
|
2595
|
+
return (n, r) => (m(), p("div", hn, [
|
|
2444
2596
|
h("label", {
|
|
2445
2597
|
class: k([
|
|
2446
2598
|
"joy-toggle",
|
|
2447
2599
|
{
|
|
2448
2600
|
"joy-toggle__checked": e.modelValue,
|
|
2449
|
-
"joy-toggle__disabled": e.disabled
|
|
2601
|
+
"joy-toggle__disabled": e.disabled,
|
|
2602
|
+
"joy-toggle__focusing": l.value
|
|
2450
2603
|
}
|
|
2451
2604
|
])
|
|
2452
2605
|
}, [
|
|
@@ -2461,76 +2614,83 @@ const eo = /* @__PURE__ */ V(Xa, [["__scopeId", "data-v-650f33d9"]]), to = (e) =
|
|
|
2461
2614
|
required: e.required,
|
|
2462
2615
|
"aria-checked": e.modelValue,
|
|
2463
2616
|
value: e.value,
|
|
2464
|
-
onChange:
|
|
2465
|
-
(...
|
|
2466
|
-
|
|
2467
|
-
|
|
2468
|
-
|
|
2469
|
-
|
|
2470
|
-
|
|
2617
|
+
onChange: r[0] || (r[0] = //@ts-ignore
|
|
2618
|
+
(...s) => o.onChange && o.onChange(...s)),
|
|
2619
|
+
onFocus: r[1] || (r[1] = //@ts-ignore
|
|
2620
|
+
(...s) => o.onFocus && o.onFocus(...s)),
|
|
2621
|
+
onBlur: r[2] || (r[2] = //@ts-ignore
|
|
2622
|
+
(...s) => o.onBlur && o.onBlur(...s))
|
|
2623
|
+
}, null, 40, bn),
|
|
2624
|
+
h("p", gn, [
|
|
2625
|
+
_n,
|
|
2626
|
+
h("span", wn, [
|
|
2627
|
+
g(n.$slots, "default", {}, () => [
|
|
2628
|
+
J(I(e.label), 1)
|
|
2471
2629
|
], !0)
|
|
2472
2630
|
]),
|
|
2473
|
-
|
|
2631
|
+
Sn
|
|
2474
2632
|
])
|
|
2475
2633
|
], 2)
|
|
2476
2634
|
]));
|
|
2477
2635
|
}
|
|
2478
2636
|
});
|
|
2479
|
-
const
|
|
2637
|
+
const kn = /* @__PURE__ */ V(jn, [["__scopeId", "data-v-cf79d999"]]), $n = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2480
2638
|
__proto__: null,
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
|
|
2485
|
-
|
|
2486
|
-
|
|
2487
|
-
|
|
2488
|
-
|
|
2489
|
-
|
|
2490
|
-
|
|
2491
|
-
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2639
|
+
VJoyBadge: ft,
|
|
2640
|
+
VJoyButton: jt,
|
|
2641
|
+
VJoyCheckbox: he,
|
|
2642
|
+
VJoyCounter: Dt,
|
|
2643
|
+
VJoyDropdown: Fl,
|
|
2644
|
+
VJoyDropdownList: Xe,
|
|
2645
|
+
VJoyFormError: et,
|
|
2646
|
+
VJoyHighlight: Ql,
|
|
2647
|
+
VJoyInput: io,
|
|
2648
|
+
VJoyLabel: N,
|
|
2649
|
+
VJoyLink: fo,
|
|
2650
|
+
VJoyMultiCheckbox: po,
|
|
2651
|
+
VJoyPanel: $o,
|
|
2652
|
+
VJoyPanelSection: Bo,
|
|
2653
|
+
VJoyRadio: qo,
|
|
2654
|
+
VJoyRadioGroup: Ao,
|
|
2655
|
+
VJoySelect: No,
|
|
2656
|
+
VJoySelectableItem: tt,
|
|
2657
|
+
VJoySelectableItemGroup: Qo,
|
|
2658
|
+
VJoySpinner: He,
|
|
2659
|
+
VJoyTemplate: un,
|
|
2660
|
+
VJoyTextarea: pn,
|
|
2661
|
+
VJoyToggle: kn,
|
|
2662
|
+
VJoyWrapper: Yo
|
|
2663
|
+
}, Symbol.toStringTag, { value: "Module" })), xn = {
|
|
2505
2664
|
install: (e) => {
|
|
2506
|
-
Object.entries(
|
|
2665
|
+
Object.entries($n).forEach(([t, l]) => {
|
|
2507
2666
|
e.component(t, l);
|
|
2508
2667
|
});
|
|
2509
2668
|
}
|
|
2510
2669
|
};
|
|
2511
2670
|
export {
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2671
|
+
xn as JoyVuePlugin,
|
|
2672
|
+
ft as VJoyBadge,
|
|
2673
|
+
jt as VJoyButton,
|
|
2674
|
+
he as VJoyCheckbox,
|
|
2675
|
+
Dt as VJoyCounter,
|
|
2676
|
+
Fl as VJoyDropdown,
|
|
2677
|
+
Xe as VJoyDropdownList,
|
|
2678
|
+
et as VJoyFormError,
|
|
2679
|
+
Ql as VJoyHighlight,
|
|
2680
|
+
io as VJoyInput,
|
|
2681
|
+
N as VJoyLabel,
|
|
2682
|
+
fo as VJoyLink,
|
|
2683
|
+
po as VJoyMultiCheckbox,
|
|
2684
|
+
$o as VJoyPanel,
|
|
2685
|
+
Bo as VJoyPanelSection,
|
|
2686
|
+
qo as VJoyRadio,
|
|
2687
|
+
Ao as VJoyRadioGroup,
|
|
2688
|
+
No as VJoySelect,
|
|
2689
|
+
tt as VJoySelectableItem,
|
|
2690
|
+
Qo as VJoySelectableItemGroup,
|
|
2691
|
+
He as VJoySpinner,
|
|
2692
|
+
un as VJoyTemplate,
|
|
2693
|
+
pn as VJoyTextarea,
|
|
2694
|
+
kn as VJoyToggle,
|
|
2695
|
+
Yo as VJoyWrapper
|
|
2536
2696
|
};
|