@maltjoy/core-vue 1.0.0-beta.2 → 1.0.0-beta.4

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