@codemonster-ru/vueforge 0.19.0 → 0.20.0

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/index.ts.mjs CHANGED
@@ -1,7 +1,7 @@
1
- import { defineComponent as Z, ref as R, computed as g, watch as ee, resolveComponent as Xe, openBlock as m, createElementBlock as h, normalizeClass as E, renderSlot as F, Fragment as ue, createTextVNode as ae, toDisplayString as M, createBlock as le, withCtx as ye, createCommentVNode as V, createElementVNode as B, renderList as Be, withKeys as q, withModifiers as Y, unref as $e, createVNode as qe, useSlots as Ue, nextTick as ke, onMounted as Fe, onBeforeUnmount as Ce, Teleport as we, withDirectives as ve, vShow as fe, provide as Ze, inject as Me, reactive as lt, createSlots as nt } from "vue";
1
+ import { defineComponent as U, ref as I, computed as h, watch as te, resolveComponent as Xe, openBlock as g, createElementBlock as _, normalizeClass as D, renderSlot as L, Fragment as se, createTextVNode as Q, toDisplayString as O, createBlock as le, withCtx as ye, createCommentVNode as T, createElementVNode as F, renderList as ke, withKeys as q, withModifiers as Y, unref as xe, createVNode as qe, useSlots as Ue, nextTick as Ce, onMounted as Fe, onBeforeUnmount as we, Teleport as $e, withDirectives as ve, vShow as fe, provide as Ze, inject as We, reactive as lt, createSlots as nt } from "vue";
2
2
  import { useRoute as st, useRouter as it } from "vue-router";
3
- import { CmIcon as xe } from "@codemonster-ru/vueiconify";
4
- const dt = ["href", "aria-disabled", "tabindex"], Je = /* @__PURE__ */ Z({
3
+ import { CmIcon as Be } from "@codemonster-ru/vueiconify";
4
+ const dt = ["href", "aria-disabled", "tabindex"], Je = /* @__PURE__ */ U({
5
5
  __name: "link",
6
6
  props: {
7
7
  to: { default: void 0 },
@@ -15,48 +15,48 @@ const dt = ["href", "aria-disabled", "tabindex"], Je = /* @__PURE__ */ Z({
15
15
  },
16
16
  emits: ["click", "active", "update:active", "onActive"],
17
17
  setup(t, { emit: e }) {
18
- const r = e, o = t, a = st(), u = it(), d = R(null), c = g(() => o.href ?? o.url), l = g(() => o.as ? o.as === "router-link" && !o.to ? "a" : o.as : o.type === "router-link" || o.type === "a" ? o.type === "router-link" && !o.to ? "a" : o.type : o.to ? "router-link" : "a"), i = g(() => o.to), n = g(() => o.to ? u.resolve(o.to) : null), s = g(() => {
18
+ const r = e, o = t, a = st(), v = it(), i = I(null), c = h(() => o.href ?? o.url), l = h(() => o.as ? o.as === "router-link" && !o.to ? "a" : o.as : o.type === "router-link" || o.type === "a" ? o.type === "router-link" && !o.to ? "a" : o.type : o.to ? "router-link" : "a"), d = h(() => o.to), n = h(() => o.to ? v.resolve(o.to) : null), s = h(() => {
19
19
  if (l.value !== "router-link")
20
20
  return !1;
21
- const f = n.value;
22
- return f ? f.name ? a.matched.some(({ name: C }) => C === f.name) : f.fullPath ? a.fullPath === f.fullPath : a.path === f.path : !1;
23
- }), v = g(() => o.active === void 0 ? s.value : o.active), b = (f) => {
21
+ const u = n.value;
22
+ return u ? u.name ? a.matched.some(({ name: y }) => y === u.name) : u.fullPath ? a.fullPath === u.fullPath : a.path === u.path : !1;
23
+ }), f = h(() => o.active === void 0 ? s.value : o.active), p = (u) => {
24
24
  if (!o.disabled) {
25
- r("click", f);
25
+ r("click", u);
26
26
  return;
27
27
  }
28
- f.preventDefault(), f.stopPropagation();
28
+ u.preventDefault(), u.stopPropagation();
29
29
  };
30
- return ee(s, (f) => {
31
- f && (r("active"), r("onActive")), r("update:active", f);
32
- }), (f, C) => {
33
- const $ = Xe("router-link");
34
- return l.value === "a" ? (m(), h("a", {
30
+ return te(s, (u) => {
31
+ u && (r("active"), r("onActive")), r("update:active", u);
32
+ }), (u, y) => {
33
+ const m = Xe("router-link");
34
+ return l.value === "a" ? (g(), _("a", {
35
35
  key: 0,
36
36
  href: c.value,
37
- class: E(["vf-link", { "vf-link_active": v.value, "vf-link_disabled": f.disabled }]),
38
- "aria-disabled": f.disabled,
39
- tabindex: f.disabled ? -1 : void 0,
40
- onClick: b
37
+ class: D(["vf-link", { "vf-link_active": f.value, "vf-link_disabled": u.disabled }]),
38
+ "aria-disabled": u.disabled,
39
+ tabindex: u.disabled ? -1 : void 0,
40
+ onClick: p
41
41
  }, [
42
- f.$slots.default ? F(f.$slots, "default", { key: 0 }) : (m(), h(ue, { key: 1 }, [
43
- ae(M(f.label), 1)
42
+ u.$slots.default ? L(u.$slots, "default", { key: 0 }) : (g(), _(se, { key: 1 }, [
43
+ Q(O(u.label), 1)
44
44
  ], 64))
45
- ], 10, dt)) : (m(), le($, {
45
+ ], 10, dt)) : (g(), le(m, {
46
46
  key: 1,
47
47
  ref_key: "link",
48
- ref: d,
49
- to: i.value,
50
- class: E(["vf-link", { "vf-link_active": v.value }]),
51
- "aria-disabled": f.disabled,
52
- tabindex: f.disabled ? -1 : void 0,
48
+ ref: i,
49
+ to: d.value,
50
+ class: D(["vf-link", { "vf-link_active": f.value }]),
51
+ "aria-disabled": u.disabled,
52
+ tabindex: u.disabled ? -1 : void 0,
53
53
  "active-class": "vf-link_partially-active",
54
54
  "exact-active-class": "vf-link_active",
55
- onClick: b
55
+ onClick: p
56
56
  }, {
57
57
  default: ye(() => [
58
- f.$slots.default ? F(f.$slots, "default", { key: 0 }) : (m(), h(ue, { key: 1 }, [
59
- ae(M(f.label), 1)
58
+ u.$slots.default ? L(u.$slots, "default", { key: 0 }) : (g(), _(se, { key: 1 }, [
59
+ Q(O(u.label), 1)
60
60
  ], 64))
61
61
  ]),
62
62
  _: 3
@@ -77,34 +77,34 @@ const dt = ["href", "aria-disabled", "tabindex"], Je = /* @__PURE__ */ Z({
77
77
  }, bt = {
78
78
  key: 2,
79
79
  class: "vf-card__body"
80
- }, mt = {
80
+ }, gt = {
81
81
  key: 3,
82
82
  class: "vf-card__footer"
83
83
  };
84
- function gt(t, e) {
85
- return m(), h("div", vt, [
86
- t.$slots.default ? (m(), h("div", ft, [
87
- F(t.$slots, "default")
88
- ])) : V("", !0),
89
- t.$slots.header ? (m(), h("div", pt, [
90
- F(t.$slots, "header")
91
- ])) : V("", !0),
92
- t.$slots.body ? (m(), h("div", bt, [
93
- F(t.$slots, "body")
94
- ])) : V("", !0),
95
- t.$slots.footer ? (m(), h("div", mt, [
96
- F(t.$slots, "footer")
97
- ])) : V("", !0)
84
+ function mt(t, e) {
85
+ return g(), _("div", vt, [
86
+ t.$slots.default ? (g(), _("div", ft, [
87
+ L(t.$slots, "default")
88
+ ])) : T("", !0),
89
+ t.$slots.header ? (g(), _("div", pt, [
90
+ L(t.$slots, "header")
91
+ ])) : T("", !0),
92
+ t.$slots.body ? (g(), _("div", bt, [
93
+ L(t.$slots, "body")
94
+ ])) : T("", !0),
95
+ t.$slots.footer ? (g(), _("div", gt, [
96
+ L(t.$slots, "footer")
97
+ ])) : T("", !0)
98
98
  ]);
99
99
  }
100
- const ht = /* @__PURE__ */ ct(ut, [["render", gt]]), yt = {
100
+ const ht = /* @__PURE__ */ ct(ut, [["render", mt]]), yt = {
101
101
  class: "vf-menu__list",
102
102
  role: "menu"
103
103
  }, _t = {
104
104
  key: 1,
105
105
  class: "vf-menu__separator",
106
106
  role: "separator"
107
- }, kt = ["aria-expanded", "onClick", "onKeydown"], Ea = /* @__PURE__ */ Z({
107
+ }, kt = ["aria-expanded", "onClick", "onKeydown"], Aa = /* @__PURE__ */ U({
108
108
  name: "VfMenu",
109
109
  __name: "menu",
110
110
  props: {
@@ -113,87 +113,87 @@ const ht = /* @__PURE__ */ ct(ut, [["render", gt]]), yt = {
113
113
  },
114
114
  emits: ["active", "onActive"],
115
115
  setup(t, { emit: e }) {
116
- const r = e, o = t, a = R([]), u = (n, s) => `${n.label ?? n.to ?? n.href ?? n.url ?? "item"}_${s.toString()}`, d = (n) => n.to ? "router-link" : "a", c = (n) => n.map((s) => ({
116
+ const r = e, o = t, a = I([]), v = (n, s) => `${n.label ?? n.to ?? n.href ?? n.url ?? "item"}_${s.toString()}`, i = (n) => n.to ? "router-link" : "a", c = (n) => n.map((s) => ({
117
117
  ...s,
118
118
  items: s.items ? c(s.items) : void 0
119
119
  })), l = (n) => {
120
120
  n.items && n.items.length ? (a.value.map((s) => {
121
121
  s !== n && (s.subMenuVisible = !1);
122
122
  }), n.subMenuVisible = !n.subMenuVisible) : Object.prototype.hasOwnProperty.call(n, "command") && typeof n.command == "function" && n.command();
123
- }, i = (n) => {
123
+ }, d = (n) => {
124
124
  var s;
125
- for (const v in a.value) {
126
- const b = a.value[v];
127
- Object.prototype.hasOwnProperty.call(b, "items") && ((s = b.items) != null && s.some((f) => f === n) ? (b.active = !0, b.subMenuVisible = !0) : (b.active = !1, b.subMenuVisible = !1));
125
+ for (const f in a.value) {
126
+ const p = a.value[f];
127
+ Object.prototype.hasOwnProperty.call(p, "items") && ((s = p.items) != null && s.some((u) => u === n) ? (p.active = !0, p.subMenuVisible = !0) : (p.active = !1, p.subMenuVisible = !1));
128
128
  }
129
129
  r("active", n), r("onActive", n);
130
130
  };
131
- return ee(
131
+ return te(
132
132
  () => o.items,
133
133
  (n) => {
134
134
  a.value = c(n);
135
135
  },
136
136
  { deep: !0, immediate: !0 }
137
137
  ), (n, s) => {
138
- const v = Xe("VfMenu");
139
- return m(), h("div", {
140
- class: E(["vf-menu", `vf-menu_${n.orientation}`])
138
+ const f = Xe("VfMenu");
139
+ return g(), _("div", {
140
+ class: D(["vf-menu", `vf-menu_${n.orientation}`])
141
141
  }, [
142
- B("ul", yt, [
143
- (m(!0), h(ue, null, Be(a.value, (b, f) => (m(), h("li", {
144
- key: u(b, f),
142
+ F("ul", yt, [
143
+ (g(!0), _(se, null, ke(a.value, (p, u) => (g(), _("li", {
144
+ key: v(p, u),
145
145
  class: "vf-menu__item",
146
146
  role: "none"
147
147
  }, [
148
- n.$slots[u(b, f)] ? F(n.$slots, u(b, f), {
148
+ n.$slots[v(p, u)] ? L(n.$slots, v(p, u), {
149
149
  key: 0,
150
- item: { ...b, class: "vf-menu__link" }
151
- }) : b.separator ? (m(), h("hr", _t)) : b.items && b.items.length ? (m(), h(ue, { key: 2 }, [
152
- B("div", {
153
- class: E(["vf-menu__parent", { "vf-menu__parent_active": b.active }]),
150
+ item: { ...p, class: "vf-menu__link" }
151
+ }) : p.separator ? (g(), _("hr", _t)) : p.items && p.items.length ? (g(), _(se, { key: 2 }, [
152
+ F("div", {
153
+ class: D(["vf-menu__parent", { "vf-menu__parent_active": p.active }]),
154
154
  role: "menuitem",
155
155
  tabindex: "0",
156
- "aria-expanded": b.subMenuVisible ? "true" : "false",
157
- onClick: (C) => l(b),
156
+ "aria-expanded": p.subMenuVisible ? "true" : "false",
157
+ onClick: (y) => l(p),
158
158
  onKeydown: [
159
- q(Y((C) => l(b), ["prevent"]), ["enter"]),
160
- q(Y((C) => l(b), ["prevent"]), ["space"])
159
+ q(Y((y) => l(p), ["prevent"]), ["enter"]),
160
+ q(Y((y) => l(p), ["prevent"]), ["space"])
161
161
  ]
162
162
  }, [
163
- b.icon ? (m(), le($e(xe), {
163
+ p.icon ? (g(), le(xe(Be), {
164
164
  key: 0,
165
- icon: b.icon,
165
+ icon: p.icon,
166
166
  class: "vf-menu__icon"
167
- }, null, 8, ["icon"])) : V("", !0),
168
- ae(" " + M(b.label) + " ", 1),
169
- qe($e(xe), { icon: "chevronDown" })
167
+ }, null, 8, ["icon"])) : T("", !0),
168
+ Q(" " + O(p.label) + " ", 1),
169
+ qe(xe(Be), { icon: "chevronDown" })
170
170
  ], 42, kt),
171
- b.items ? (m(), le(v, {
171
+ p.items ? (g(), le(f, {
172
172
  key: 0,
173
- items: b.items,
174
- class: E(["vf-menu__submenu", { "vf-menu__submenu_visible": b.subMenuVisible }]),
175
- onOnActive: i
176
- }, null, 8, ["items", "class"])) : V("", !0)
177
- ], 64)) : (m(), le(Je, {
173
+ items: p.items,
174
+ class: D(["vf-menu__submenu", { "vf-menu__submenu_visible": p.subMenuVisible }]),
175
+ onOnActive: d
176
+ }, null, 8, ["items", "class"])) : T("", !0)
177
+ ], 64)) : (g(), le(Je, {
178
178
  key: 3,
179
- to: b.to,
180
- href: b.href ?? b.url,
181
- as: d(b),
179
+ to: p.to,
180
+ href: p.href ?? p.url,
181
+ as: i(p),
182
182
  class: "vf-menu__link",
183
- active: b.active,
184
- disabled: b.disabled,
183
+ active: p.active,
184
+ disabled: p.disabled,
185
185
  role: "menuitem",
186
- "aria-disabled": b.disabled ? "true" : "false",
187
- onClick: (C) => l(b),
188
- onActive: (C) => i(b)
186
+ "aria-disabled": p.disabled ? "true" : "false",
187
+ onClick: (y) => l(p),
188
+ onActive: (y) => d(p)
189
189
  }, {
190
190
  default: ye(() => [
191
- b.icon ? (m(), le($e(xe), {
191
+ p.icon ? (g(), le(xe(Be), {
192
192
  key: 0,
193
- icon: b.icon,
193
+ icon: p.icon,
194
194
  class: "vf-menu__icon"
195
- }, null, 8, ["icon"])) : V("", !0),
196
- ae(" " + M(b.label), 1)
195
+ }, null, 8, ["icon"])) : T("", !0),
196
+ Q(" " + O(p.label), 1)
197
197
  ]),
198
198
  _: 2
199
199
  }, 1032, ["to", "href", "as", "active", "disabled", "aria-disabled", "onClick", "onActive"]))
@@ -202,7 +202,7 @@ const ht = /* @__PURE__ */ ct(ut, [["render", gt]]), yt = {
202
202
  ], 2);
203
203
  };
204
204
  }
205
- }), Ct = ["type", "disabled"], Wa = /* @__PURE__ */ Z({
205
+ }), Ct = ["type", "disabled"], Ka = /* @__PURE__ */ U({
206
206
  __name: "button",
207
207
  props: {
208
208
  to: { default: void 0 },
@@ -221,59 +221,59 @@ const ht = /* @__PURE__ */ ct(ut, [["render", gt]]), yt = {
221
221
  disabled: { type: Boolean, default: !1 }
222
222
  },
223
223
  setup(t) {
224
- const e = t, r = ["button", "submit", "reset"], o = (n) => !!n && r.includes(n), a = g(() => e.as ? e.as === "button" : !(e.to || e.href || e.url || e.type && !o(e.type))), u = g(() => o(e.type) ? e.type : "button"), d = g(() => e.as === "link" ? e.to ? "router-link" : "a" : e.type && !o(e.type) ? e.type === "router-link" && e.to ? "router-link" : "a" : e.to ? "router-link" : "a"), c = g(() => {
224
+ const e = t, r = ["button", "submit", "reset"], o = (n) => !!n && r.includes(n), a = h(() => e.as ? e.as === "button" : !(e.to || e.href || e.url || e.type && !o(e.type))), v = h(() => o(e.type) ? e.type : "button"), i = h(() => e.as === "link" ? e.to ? "router-link" : "a" : e.type && !o(e.type) ? e.type === "router-link" && e.to ? "router-link" : "a" : e.to ? "router-link" : "a"), c = h(() => {
225
225
  let n = ["vf-button", `vf-button_${e.severity}`];
226
226
  return ["top", "bottom"].includes(e.iconPos) && n.push("vf-button_vertical"), e.variant === "text" && n.push("vf-button_text"), e.variant === "outlined" && n.push("vf-button_outlined"), ["small", "large"].indexOf(e.size) > -1 && n.push(`vf-button_${e.size}`), (e.loading || e.disabled) && n.push("vf-button_disabled"), e.rounded && n.push("vf-button_rounded"), n;
227
- }), l = g(() => ["vf-button__icon", `vf-button__icon_${e.iconPos}`]), i = g(() => ["vf-button__label"]);
228
- return (n, s) => a.value ? (m(), h("button", {
227
+ }), l = h(() => ["vf-button__icon", `vf-button__icon_${e.iconPos}`]), d = h(() => ["vf-button__label"]);
228
+ return (n, s) => a.value ? (g(), _("button", {
229
229
  key: 0,
230
- type: u.value,
231
- class: E(c.value),
230
+ type: v.value,
231
+ class: D(c.value),
232
232
  disabled: e.loading || e.disabled
233
233
  }, [
234
- e.icon && !e.loading ? (m(), le($e(xe), {
234
+ e.icon && !e.loading ? (g(), le(xe(Be), {
235
235
  key: 0,
236
236
  icon: e.icon,
237
- class: E(l.value)
238
- }, null, 8, ["icon", "class"])) : V("", !0),
239
- e.loading ? (m(), le($e(xe), {
237
+ class: D(l.value)
238
+ }, null, 8, ["icon", "class"])) : T("", !0),
239
+ e.loading ? (g(), le(xe(Be), {
240
240
  key: 1,
241
241
  icon: "circleNotch",
242
- class: E(l.value),
242
+ class: D(l.value),
243
243
  spin: ""
244
- }, null, 8, ["class"])) : V("", !0),
245
- n.$slots.default ? (m(), h("span", {
244
+ }, null, 8, ["class"])) : T("", !0),
245
+ n.$slots.default ? (g(), _("span", {
246
246
  key: 2,
247
- class: E(i.value)
247
+ class: D(d.value)
248
248
  }, [
249
- F(n.$slots, "default")
250
- ], 2)) : n.label ? (m(), h("span", {
249
+ L(n.$slots, "default")
250
+ ], 2)) : n.label ? (g(), _("span", {
251
251
  key: 3,
252
- class: E(i.value)
253
- }, M(n.label), 3)) : V("", !0)
254
- ], 10, Ct)) : (m(), le(Je, {
252
+ class: D(d.value)
253
+ }, O(n.label), 3)) : T("", !0)
254
+ ], 10, Ct)) : (g(), le(Je, {
255
255
  key: 1,
256
256
  to: e.to,
257
257
  href: e.href ?? e.url,
258
- as: d.value,
259
- class: E(c.value),
258
+ as: i.value,
259
+ class: D(c.value),
260
260
  disabled: e.loading || e.disabled
261
261
  }, {
262
262
  default: ye(() => [
263
- e.icon ? (m(), le($e(xe), {
263
+ e.icon ? (g(), le(xe(Be), {
264
264
  key: 0,
265
265
  icon: e.icon,
266
- class: E(l.value)
267
- }, null, 8, ["icon", "class"])) : V("", !0),
268
- n.$slots.default ? (m(), h("span", {
266
+ class: D(l.value)
267
+ }, null, 8, ["icon", "class"])) : T("", !0),
268
+ n.$slots.default ? (g(), _("span", {
269
269
  key: 1,
270
- class: E(i.value)
270
+ class: D(d.value)
271
271
  }, [
272
- F(n.$slots, "default")
273
- ], 2)) : n.label ? (m(), h("span", {
272
+ L(n.$slots, "default")
273
+ ], 2)) : n.label ? (g(), _("span", {
274
274
  key: 2,
275
- class: E(i.value)
276
- }, M(n.label), 3)) : V("", !0)
275
+ class: D(d.value)
276
+ }, O(n.label), 3)) : T("", !0)
277
277
  ]),
278
278
  _: 3
279
279
  }, 8, ["to", "href", "as", "class", "disabled"]));
@@ -284,7 +284,7 @@ const ht = /* @__PURE__ */ ct(ut, [["render", gt]]), yt = {
284
284
  }, $t = ["type", "value", "placeholder", "disabled", "readonly"], xt = {
285
285
  key: 1,
286
286
  class: "vf-input__suffix"
287
- }, Ma = /* @__PURE__ */ Z({
287
+ }, Na = /* @__PURE__ */ U({
288
288
  __name: "input",
289
289
  props: {
290
290
  modelValue: { default: "" },
@@ -297,41 +297,41 @@ const ht = /* @__PURE__ */ ct(ut, [["render", gt]]), yt = {
297
297
  },
298
298
  emits: ["update:modelValue", "input", "change", "focus", "blur"],
299
299
  setup(t, { emit: e }) {
300
- const r = e, o = t, a = g(() => {
301
- const i = ["vf-input", `vf-input_${o.variant}`];
302
- return o.size !== "normal" && i.push(`vf-input_${o.size}`), o.disabled && i.push("vf-input_disabled"), i;
303
- }), u = (i) => {
304
- const n = i.target;
305
- r("update:modelValue", n.value), r("input", i);
306
- }, d = (i) => r("change", i), c = (i) => r("focus", i), l = (i) => r("blur", i);
307
- return (i, n) => (m(), h("div", {
308
- class: E(a.value)
300
+ const r = e, o = t, a = h(() => {
301
+ const d = ["vf-input", `vf-input_${o.variant}`];
302
+ return o.size !== "normal" && d.push(`vf-input_${o.size}`), o.disabled && d.push("vf-input_disabled"), d;
303
+ }), v = (d) => {
304
+ const n = d.target;
305
+ r("update:modelValue", n.value), r("input", d);
306
+ }, i = (d) => r("change", d), c = (d) => r("focus", d), l = (d) => r("blur", d);
307
+ return (d, n) => (g(), _("div", {
308
+ class: D(a.value)
309
309
  }, [
310
- i.$slots.prefix ? (m(), h("span", wt, [
311
- F(i.$slots, "prefix")
312
- ])) : V("", !0),
313
- B("input", {
310
+ d.$slots.prefix ? (g(), _("span", wt, [
311
+ L(d.$slots, "prefix")
312
+ ])) : T("", !0),
313
+ F("input", {
314
314
  class: "vf-input__control",
315
- type: i.type,
316
- value: i.modelValue,
317
- placeholder: i.placeholder,
318
- disabled: i.disabled,
319
- readonly: i.readonly,
320
- onInput: u,
321
- onChange: d,
315
+ type: d.type,
316
+ value: d.modelValue,
317
+ placeholder: d.placeholder,
318
+ disabled: d.disabled,
319
+ readonly: d.readonly,
320
+ onInput: v,
321
+ onChange: i,
322
322
  onFocus: c,
323
323
  onBlur: l
324
324
  }, null, 40, $t),
325
- i.$slots.suffix ? (m(), h("span", xt, [
326
- F(i.$slots, "suffix")
327
- ])) : V("", !0)
325
+ d.$slots.suffix ? (g(), _("span", xt, [
326
+ L(d.$slots, "suffix")
327
+ ])) : T("", !0)
328
328
  ], 2));
329
329
  }
330
330
  }), Bt = ["for"], zt = {
331
331
  key: 0,
332
332
  class: "vf-form-field__required",
333
333
  "aria-hidden": "true"
334
- }, Ft = { class: "vf-form-field__control" }, St = ["id"], Vt = ["id"], Ha = /* @__PURE__ */ Z({
334
+ }, Ft = { class: "vf-form-field__control" }, St = ["id"], Vt = ["id"], Ya = /* @__PURE__ */ U({
335
335
  __name: "form-field",
336
336
  props: {
337
337
  id: { default: void 0 },
@@ -343,56 +343,56 @@ const ht = /* @__PURE__ */ ct(ut, [["render", gt]]), yt = {
343
343
  size: { default: "normal" }
344
344
  },
345
345
  setup(t) {
346
- const e = t, r = Ue(), o = `vf-form-field-${Math.random().toString(36).slice(2, 10)}`, a = g(() => e.id || o), u = g(() => `${a.value}-hint`), d = g(() => `${a.value}-error`), c = g(() => !!e.label || !!r.label), l = g(() => !!e.hint || !!r.hint), i = g(() => !!e.error || !!r.error), n = g(() => {
347
- const v = [];
348
- return l.value && v.push(u.value), i.value && v.push(d.value), v.length ? v.join(" ") : void 0;
349
- }), s = g(() => {
350
- const v = ["vf-form-field"];
351
- return e.size !== "normal" && v.push(`vf-form-field_${e.size}`), e.disabled && v.push("vf-form-field_disabled"), i.value && v.push("vf-form-field_invalid"), v;
346
+ const e = t, r = Ue(), o = `vf-form-field-${Math.random().toString(36).slice(2, 10)}`, a = h(() => e.id || o), v = h(() => `${a.value}-hint`), i = h(() => `${a.value}-error`), c = h(() => !!e.label || !!r.label), l = h(() => !!e.hint || !!r.hint), d = h(() => !!e.error || !!r.error), n = h(() => {
347
+ const f = [];
348
+ return l.value && f.push(v.value), d.value && f.push(i.value), f.length ? f.join(" ") : void 0;
349
+ }), s = h(() => {
350
+ const f = ["vf-form-field"];
351
+ return e.size !== "normal" && f.push(`vf-form-field_${e.size}`), e.disabled && f.push("vf-form-field_disabled"), d.value && f.push("vf-form-field_invalid"), f;
352
352
  });
353
- return (v, b) => (m(), h("div", {
354
- class: E(s.value)
353
+ return (f, p) => (g(), _("div", {
354
+ class: D(s.value)
355
355
  }, [
356
- c.value ? (m(), h("label", {
356
+ c.value ? (g(), _("label", {
357
357
  key: 0,
358
358
  class: "vf-form-field__label",
359
359
  for: a.value
360
360
  }, [
361
- F(v.$slots, "label", {}, () => [
362
- ae(M(v.label), 1)
361
+ L(f.$slots, "label", {}, () => [
362
+ Q(O(f.label), 1)
363
363
  ]),
364
- v.required ? (m(), h("span", zt, "*")) : V("", !0)
365
- ], 8, Bt)) : V("", !0),
366
- B("div", Ft, [
367
- F(v.$slots, "default", {
364
+ f.required ? (g(), _("span", zt, "*")) : T("", !0)
365
+ ], 8, Bt)) : T("", !0),
366
+ F("div", Ft, [
367
+ L(f.$slots, "default", {
368
368
  id: a.value,
369
369
  describedBy: n.value,
370
- invalid: i.value,
371
- required: v.required
370
+ invalid: d.value,
371
+ required: f.required
372
372
  })
373
373
  ]),
374
- l.value ? (m(), h("p", {
374
+ l.value ? (g(), _("p", {
375
375
  key: 1,
376
- id: u.value,
376
+ id: v.value,
377
377
  class: "vf-form-field__hint"
378
378
  }, [
379
- F(v.$slots, "hint", {}, () => [
380
- ae(M(v.hint), 1)
379
+ L(f.$slots, "hint", {}, () => [
380
+ Q(O(f.hint), 1)
381
381
  ])
382
- ], 8, St)) : V("", !0),
383
- i.value ? (m(), h("p", {
382
+ ], 8, St)) : T("", !0),
383
+ d.value ? (g(), _("p", {
384
384
  key: 2,
385
- id: d.value,
385
+ id: i.value,
386
386
  class: "vf-form-field__error",
387
387
  role: "alert"
388
388
  }, [
389
- F(v.$slots, "error", {}, () => [
390
- ae(M(v.error), 1)
389
+ L(f.$slots, "error", {}, () => [
390
+ Q(O(f.error), 1)
391
391
  ])
392
- ], 8, Vt)) : V("", !0)
392
+ ], 8, Vt)) : T("", !0)
393
393
  ], 2));
394
394
  }
395
- }), Lt = ["value", "placeholder", "disabled", "readonly", "rows"], Aa = /* @__PURE__ */ Z({
395
+ }), Lt = ["value", "placeholder", "disabled", "readonly", "rows"], Ga = /* @__PURE__ */ U({
396
396
  __name: "textarea",
397
397
  props: {
398
398
  modelValue: { default: "" },
@@ -405,25 +405,25 @@ const ht = /* @__PURE__ */ ct(ut, [["render", gt]]), yt = {
405
405
  },
406
406
  emits: ["update:modelValue", "input", "change", "focus", "blur"],
407
407
  setup(t, { emit: e }) {
408
- const r = e, o = t, a = g(() => {
409
- const i = ["vf-textarea", `vf-textarea_${o.variant}`];
410
- return o.size !== "normal" && i.push(`vf-textarea_${o.size}`), o.disabled && i.push("vf-textarea_disabled"), i;
411
- }), u = (i) => {
412
- const n = i.target;
413
- r("update:modelValue", n.value), r("input", i);
414
- }, d = (i) => r("change", i), c = (i) => r("focus", i), l = (i) => r("blur", i);
415
- return (i, n) => (m(), h("div", {
416
- class: E(a.value)
408
+ const r = e, o = t, a = h(() => {
409
+ const d = ["vf-textarea", `vf-textarea_${o.variant}`];
410
+ return o.size !== "normal" && d.push(`vf-textarea_${o.size}`), o.disabled && d.push("vf-textarea_disabled"), d;
411
+ }), v = (d) => {
412
+ const n = d.target;
413
+ r("update:modelValue", n.value), r("input", d);
414
+ }, i = (d) => r("change", d), c = (d) => r("focus", d), l = (d) => r("blur", d);
415
+ return (d, n) => (g(), _("div", {
416
+ class: D(a.value)
417
417
  }, [
418
- B("textarea", {
418
+ F("textarea", {
419
419
  class: "vf-textarea__control",
420
- value: i.modelValue,
421
- placeholder: i.placeholder,
422
- disabled: i.disabled,
423
- readonly: i.readonly,
424
- rows: i.rows,
425
- onInput: u,
426
- onChange: d,
420
+ value: d.modelValue,
421
+ placeholder: d.placeholder,
422
+ disabled: d.disabled,
423
+ readonly: d.readonly,
424
+ rows: d.rows,
425
+ onInput: v,
426
+ onChange: i,
427
427
  onFocus: c,
428
428
  onBlur: l
429
429
  }, null, 40, Lt)
@@ -455,13 +455,13 @@ const ht = /* @__PURE__ */ ct(ut, [["render", gt]]), yt = {
455
455
  function Tt(t) {
456
456
  return typeof window > "u" ? !1 : window.getComputedStyle(t).position === "fixed";
457
457
  }
458
- const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge = (t, e) => Rt(t, e) === "fixed", se = (t, e, r = {}) => {
459
- const o = t.getBoundingClientRect(), a = e ? e.offsetParent : null, u = e ? ge(r, e) : !1;
460
- if (a && !u) {
461
- const d = a.getBoundingClientRect(), c = a.scrollLeft, l = a.scrollTop;
458
+ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", me = (t, e) => Rt(t, e) === "fixed", ie = (t, e, r = {}) => {
459
+ const o = t.getBoundingClientRect(), a = e ? e.offsetParent : null, v = e ? me(r, e) : !1;
460
+ if (a && !v) {
461
+ const i = a.getBoundingClientRect(), c = a.scrollLeft, l = a.scrollTop;
462
462
  return {
463
- left: o.left - d.left + c,
464
- top: o.top - d.top + l,
463
+ left: o.left - i.left + c,
464
+ top: o.top - i.top + l,
465
465
  width: o.width,
466
466
  height: o.height
467
467
  };
@@ -479,56 +479,56 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
479
479
  const e = pe(t);
480
480
  let r = "";
481
481
  return e !== null && ((e.dataset.scrollTop === void 0 || e.scrollTop === +e.dataset.scrollTop) && (e.dataset.scrollTop = "0"), (e.dataset.scrollLeft === void 0 || e.scrollLeft === +e.dataset.scrollLeft) && (e.dataset.scrollLeft = "0"), e.scrollTop > +e.dataset.scrollTop ? r = "bottom" : e.scrollTop < +e.dataset.scrollTop ? r = "top" : e.scrollLeft > +e.dataset.scrollLeft ? r = "right" : e.scrollLeft < +e.dataset.scrollLeft && (r = "left"), e.dataset.scrollTop = e.scrollTop <= 0 ? "0" : e.scrollTop.toString(), e.dataset.scrollLeft = e.scrollLeft <= 0 ? "0" : e.scrollLeft.toString()), r;
482
- }, Re = (t) => t.scrollLeft + t.clientWidth, Pe = (t) => t.scrollTop + t.clientHeight, ie = (t, e, r = null, o = {}, a) => {
483
- if (r === null && typeof window < "u" && ge(o, e))
482
+ }, Re = (t) => t.scrollLeft + t.clientWidth, Pe = (t) => t.scrollTop + t.clientHeight, de = (t, e, r = null, o = {}, a) => {
483
+ if (r === null && typeof window < "u" && me(o, e))
484
484
  return t;
485
- let u = 0;
485
+ let v = 0;
486
486
  if (r === null) {
487
- const d = pe(e);
488
- u = d ? d.scrollTop : 0;
487
+ const i = pe(e);
488
+ v = i ? i.scrollTop : 0;
489
489
  }
490
- return t - u;
491
- }, de = (t, e, r = null, o = {}, a) => {
492
- let u;
493
- if (r === null && typeof window < "u" && ge(o, e))
494
- u = window.innerWidth;
490
+ return t - v;
491
+ }, ce = (t, e, r = null, o = {}, a) => {
492
+ let v;
493
+ if (r === null && typeof window < "u" && me(o, e))
494
+ v = window.innerWidth;
495
495
  else if (r === null) {
496
- const d = pe(e);
497
- u = d ? Re(d) : 0;
496
+ const i = pe(e);
497
+ v = i ? Re(i) : 0;
498
498
  } else
499
- u = r.getBoundingClientRect().width;
500
- return -(t + e.clientWidth - u);
499
+ v = r.getBoundingClientRect().width;
500
+ return -(t + e.clientWidth - v);
501
501
  }, be = (t, e, r = null, o = {}, a) => {
502
- let u;
503
- if (r === null && typeof window < "u" && ge(o, e))
504
- u = window.innerHeight;
502
+ let v;
503
+ if (r === null && typeof window < "u" && me(o, e))
504
+ v = window.innerHeight;
505
505
  else if (r === null) {
506
- const d = pe(e);
507
- u = d ? Pe(d) : 0;
506
+ const i = pe(e);
507
+ v = i ? Pe(i) : 0;
508
508
  } else
509
- u = r.getBoundingClientRect().height;
510
- return -(t + e.clientHeight - u);
511
- }, ce = (t, e, r = null, o = {}, a) => {
512
- if (r === null && typeof window < "u" && ge(o, e))
509
+ v = r.getBoundingClientRect().height;
510
+ return -(t + e.clientHeight - v);
511
+ }, ue = (t, e, r = null, o = {}, a) => {
512
+ if (r === null && typeof window < "u" && me(o, e))
513
513
  return t;
514
- let u = 0;
514
+ let v = 0;
515
515
  if (r === null) {
516
- const d = pe(e);
517
- u = d ? d.scrollLeft : 0;
516
+ const i = pe(e);
517
+ v = i ? i.scrollLeft : 0;
518
518
  }
519
- return t - u;
519
+ return t - v;
520
520
  }, Ye = ({
521
521
  options: t,
522
522
  primaryX: e,
523
523
  primaryY: r,
524
524
  floating: o,
525
525
  placement: a,
526
- reference: u,
527
- scrollDirection: d
526
+ reference: v,
527
+ scrollDirection: i
528
528
  }) => {
529
- const c = Ie(u, o, a, t), l = _e(t, "offset");
529
+ const c = Me(v, o, a, t), l = _e(t, "offset");
530
530
  if (l) {
531
- const i = l.fn({
531
+ const d = l.fn({
532
532
  x: c.x,
533
533
  y: c.y,
534
534
  options: t,
@@ -536,12 +536,12 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
536
536
  primaryY: r,
537
537
  floating: o,
538
538
  placement: a,
539
- reference: u,
540
- scrollDirection: d
539
+ reference: v,
540
+ scrollDirection: i
541
541
  });
542
- c.x = i.x, c.y = i.y;
542
+ c.x = d.x, c.y = d.y;
543
543
  }
544
- return Ut(c, o, u, t) ? {
544
+ return Ut(c, o, v, t) ? {
545
545
  x: c.x,
546
546
  y: c.y,
547
547
  placement: a
@@ -554,113 +554,113 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
554
554
  y: r,
555
555
  options: o,
556
556
  primaryX: a,
557
- primaryY: u,
558
- floating: d,
557
+ primaryY: v,
558
+ floating: i,
559
559
  placement: c,
560
560
  reference: l,
561
- scrollDirection: i
561
+ scrollDirection: d
562
562
  }) => {
563
563
  var n;
564
564
  const s = {
565
565
  x: e,
566
566
  y: r,
567
567
  placement: c
568
- }, v = {
568
+ }, f = {
569
569
  ...o,
570
- middleware: (n = o.middleware) == null ? void 0 : n.filter((T) => T.name !== "shift")
571
- }, b = (t == null ? void 0 : t.placements) ?? Ne, f = !(t != null && t.placements), C = f ? Ne : b;
572
- let $ = !1;
573
- const S = (T) => {
574
- if ($)
570
+ middleware: (n = o.middleware) == null ? void 0 : n.filter((S) => S.name !== "shift")
571
+ }, p = (t == null ? void 0 : t.placements) ?? Ne, u = !(t != null && t.placements), y = u ? Ne : p;
572
+ let m = !1;
573
+ const C = (S) => {
574
+ if (m)
575
575
  return;
576
576
  const H = Ye({
577
- options: v,
577
+ options: f,
578
578
  primaryX: a,
579
- primaryY: u,
580
- floating: d,
581
- placement: T,
579
+ primaryY: v,
580
+ floating: i,
581
+ placement: S,
582
582
  reference: l,
583
- scrollDirection: i
583
+ scrollDirection: d
584
584
  });
585
- H && (s.x = H.x, s.y = H.y, s.placement = H.placement, $ = !0);
586
- }, I = Jt(l, d, v);
587
- if (!f && b.includes(c) && S(c), $ || C.forEach(S), !$) {
588
- const T = b.reduce(
589
- (H, P) => {
590
- const D = Ye({
591
- options: v,
585
+ H && (s.x = H.x, s.y = H.y, s.placement = H.placement, m = !0);
586
+ }, M = Jt(l, i, f);
587
+ if (!u && p.includes(c) && C(c), m || y.forEach(C), !m) {
588
+ const S = p.reduce(
589
+ (H, R) => {
590
+ const P = Ye({
591
+ options: f,
592
592
  primaryX: a,
593
- primaryY: u,
594
- floating: d,
595
- placement: P,
593
+ primaryY: v,
594
+ floating: i,
595
+ placement: R,
596
596
  reference: l,
597
- scrollDirection: i
597
+ scrollDirection: d
598
598
  });
599
- if (!D)
599
+ if (!P)
600
600
  return H;
601
- const A = ze(P), L = I[A];
602
- return !H || L > H.space ? { result: D, space: L } : H;
601
+ const W = ze(R), z = M[W];
602
+ return !H || z > H.space ? { result: P, space: z } : H;
603
603
  },
604
604
  null
605
605
  );
606
- T && (s.x = T.result.x, s.y = T.result.y, s.placement = T.result.placement, $ = !0);
606
+ S && (s.x = S.result.x, s.y = S.result.y, s.placement = S.result.placement, m = !0);
607
607
  }
608
- if (!$ && b.length > 0) {
609
- const T = ze(c);
610
- let H = T, P = I[T];
611
- b.forEach((w) => {
612
- const y = ze(w), z = I[y];
613
- z > P && (P = z, H = y);
608
+ if (!m && p.length > 0) {
609
+ const S = ze(c);
610
+ let H = S, R = M[S];
611
+ p.forEach((x) => {
612
+ const k = ze(x), V = M[k];
613
+ V > R && (R = V, H = k);
614
614
  });
615
- const D = Zt(H, c, b), A = Ie(l, d, D, v), L = _e(v, "offset");
616
- if (L) {
617
- const w = L.fn({
618
- x: A.x,
619
- y: A.y,
620
- options: v,
615
+ const P = Zt(H, c, p), W = Me(l, i, P, f), z = _e(f, "offset");
616
+ if (z) {
617
+ const x = z.fn({
618
+ x: W.x,
619
+ y: W.y,
620
+ options: f,
621
621
  primaryX: a,
622
- primaryY: u,
623
- floating: d,
624
- placement: D,
622
+ primaryY: v,
623
+ floating: i,
624
+ placement: P,
625
625
  reference: l,
626
- scrollDirection: i
626
+ scrollDirection: d
627
627
  });
628
- A.x = w.x, A.y = w.y;
628
+ W.x = x.x, W.y = x.y;
629
629
  }
630
- s.x = A.x, s.y = A.y, s.placement = A.placement;
630
+ s.x = W.x, s.y = W.y, s.placement = W.placement;
631
631
  }
632
632
  return s;
633
633
  }
634
634
  }), et = (t, e, r, o, a) => {
635
- var u, d, c;
635
+ var v, i, c;
636
636
  let l = 0;
637
637
  o.startsWith("right") ? l = -t : o.startsWith("left") && (l = t);
638
- const i = _e(e, "arrow"), n = _e(e, "shift");
639
- if (i) {
640
- const s = ((u = i.params) == null ? void 0 : u.arrow).getBoundingClientRect();
638
+ const d = _e(e, "arrow"), n = _e(e, "shift");
639
+ if (d) {
640
+ const s = ((v = d.params) == null ? void 0 : v.arrow).getBoundingClientRect();
641
641
  o.startsWith("right") ? l -= s.width / 2 : o.startsWith("left") && (l += s.width / 2);
642
642
  }
643
- if (Qe(e, "shift") && i) {
644
- let s = null, v = 0;
645
- n && (s = (d = n.params) == null ? void 0 : d.parent);
646
- const b = (c = i.params) == null ? void 0 : c.arrow;
647
- v = b.getBoundingClientRect().width / 2, v += Dt(b), v -= t, o.startsWith("right") ? de(r - l, a, s, e) <= t ? de(r, a, s, e) > 0 ? l = t - de(r, a, s, e) : l = t : ce(r - l - v, a, s, e) <= t && (ce(r - l - v, a, s, e) >= 0 ? (l = -t - (ce(r - l - v, a, s, e) + t), s && (l = -t)) : l = -t) : o.startsWith("left") ? de(r - l + v, a, s, e) <= t ? (l = t + de(r - v, a, s, e), l <= t && (l = t)) : ce(r - l, a, s, e) <= t && (l = -t + ce(r, a, s, e), l <= -t && (l = -t)) : de(r - l, a, s, e) <= t ? de(r - l, a, s, e) <= t && de(r, a, s, e) > 0 ? l = t - de(r, a, s, e) : l = t : ce(r - l, a, s, e) <= t && (ce(r - l, a, s, e) <= t && ce(r, a, s, e) > 0 ? l = -(t - ce(r, a, s, e)) : l = -t);
643
+ if (Qe(e, "shift") && d) {
644
+ let s = null, f = 0;
645
+ n && (s = (i = n.params) == null ? void 0 : i.parent);
646
+ const p = (c = d.params) == null ? void 0 : c.arrow;
647
+ f = p.getBoundingClientRect().width / 2, f += It(p), f -= t, o.startsWith("right") ? ce(r - l, a, s, e) <= t ? ce(r, a, s, e) > 0 ? l = t - ce(r, a, s, e) : l = t : ue(r - l - f, a, s, e) <= t && (ue(r - l - f, a, s, e) >= 0 ? (l = -t - (ue(r - l - f, a, s, e) + t), s && (l = -t)) : l = -t) : o.startsWith("left") ? ce(r - l + f, a, s, e) <= t ? (l = t + ce(r - f, a, s, e), l <= t && (l = t)) : ue(r - l, a, s, e) <= t && (l = -t + ue(r, a, s, e), l <= -t && (l = -t)) : ce(r - l, a, s, e) <= t ? ce(r - l, a, s, e) <= t && ce(r, a, s, e) > 0 ? l = t - ce(r, a, s, e) : l = t : ue(r - l, a, s, e) <= t && (ue(r - l, a, s, e) <= t && ue(r, a, s, e) > 0 ? l = -(t - ue(r, a, s, e)) : l = -t);
648
648
  }
649
649
  return l;
650
650
  }, tt = (t, e, r, o, a) => {
651
- var u, d, c;
651
+ var v, i, c;
652
652
  let l = 0;
653
653
  o.startsWith("top") ? l = t : o.startsWith("bottom") && (l = -t);
654
- const i = _e(e, "arrow"), n = _e(e, "shift");
655
- if (i) {
656
- const s = ((u = i.params) == null ? void 0 : u.arrow).getBoundingClientRect();
654
+ const d = _e(e, "arrow"), n = _e(e, "shift");
655
+ if (d) {
656
+ const s = ((v = d.params) == null ? void 0 : v.arrow).getBoundingClientRect();
657
657
  o.startsWith("top") ? l += s.height / 2 : o.startsWith("bottom") && (l -= s.height / 2);
658
658
  }
659
- if (Qe(e, "shift") && i) {
660
- let s = null, v = 0;
661
- n && (s = (d = n.params) == null ? void 0 : d.parent);
662
- const b = (c = i.params) == null ? void 0 : c.arrow;
663
- v = b.getBoundingClientRect().height / 2, v += Ot(b), v -= t, o.startsWith("top") ? ie(r - l, a, s, e) <= t ? ie(r, a, s, e) >= 0 ? l = -(t - ie(r, a, s, e)) : l = -t : be(r - l + v, a, s, e) <= t && (l = t + be(r - v, a, s, e), l <= t && (l = t)) : o.startsWith("bottom") ? ie(r - l - v, a, s, e) <= t ? ie(r - l - v, a, s, e) >= 0 ? (l = -t - (ie(r - l - v, a, s, e) + t), s && (l = -t)) : l = -t : be(r - l, a, s, e) <= t && (be(r, a, s, e) >= 0 ? l = t - be(r, a, s, e) : l = t) : ie(r - l, a, s, e) <= t ? ie(r - l, a, s, e) >= 0 ? l = -(t - ie(r - l, a, s, e)) : l = -t : be(r - l, a, s, e) <= t && (be(r - l, a, s, e) >= 0 ? l = t - be(r - l, a, s, e) : l = t);
659
+ if (Qe(e, "shift") && d) {
660
+ let s = null, f = 0;
661
+ n && (s = (i = n.params) == null ? void 0 : i.parent);
662
+ const p = (c = d.params) == null ? void 0 : c.arrow;
663
+ f = p.getBoundingClientRect().height / 2, f += Dt(p), f -= t, o.startsWith("top") ? de(r - l, a, s, e) <= t ? de(r, a, s, e) >= 0 ? l = -(t - de(r, a, s, e)) : l = -t : be(r - l + f, a, s, e) <= t && (l = t + be(r - f, a, s, e), l <= t && (l = t)) : o.startsWith("bottom") ? de(r - l - f, a, s, e) <= t ? de(r - l - f, a, s, e) >= 0 ? (l = -t - (de(r - l - f, a, s, e) + t), s && (l = -t)) : l = -t : be(r - l, a, s, e) <= t && (be(r, a, s, e) >= 0 ? l = t - be(r, a, s, e) : l = t) : de(r - l, a, s, e) <= t ? de(r - l, a, s, e) >= 0 ? l = -(t - de(r - l, a, s, e)) : l = -t : be(r - l, a, s, e) <= t && (be(r - l, a, s, e) >= 0 ? l = t - be(r - l, a, s, e) : l = t);
664
664
  }
665
665
  return l;
666
666
  }, Ve = (t) => ({
@@ -671,15 +671,15 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
671
671
  y: r,
672
672
  options: o,
673
673
  primaryX: a,
674
- primaryY: u,
675
- floating: d,
674
+ primaryY: v,
675
+ floating: i,
676
676
  placement: c
677
677
  }) => ({
678
- x: e - et(t, o, a, c, d),
679
- y: r - tt(t, o, u, c, d),
678
+ x: e - et(t, o, a, c, i),
679
+ y: r - tt(t, o, v, c, i),
680
680
  placement: c
681
681
  })
682
- }), It = (t) => ({
682
+ }), Mt = (t) => ({
683
683
  name: "shift",
684
684
  params: t,
685
685
  fn: ({
@@ -687,143 +687,143 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
687
687
  y: r,
688
688
  options: o,
689
689
  primaryX: a,
690
- primaryY: u,
691
- floating: d,
690
+ primaryY: v,
691
+ floating: i,
692
692
  placement: c,
693
693
  reference: l
694
694
  }) => {
695
- var i;
695
+ var d;
696
696
  const n = {
697
697
  x: e,
698
698
  y: r,
699
699
  placement: c
700
- }, s = o.middleware || [], v = s.findIndex((z) => z.name === "shift"), b = s.findIndex((z) => z.name === "offset"), f = b !== -1 && (v === -1 || b > v), C = s.find((z) => z.name === "offset"), $ = C ? (i = C.params) == null ? void 0 : i.value : 0, S = f ? et($, o, a, c, d) : 0, I = f ? tt($, o, u, c, d) : 0, T = e - S, H = r - I;
701
- let P = T, D = H;
702
- const A = C ? Math.abs($) : 0, L = A, w = A;
703
- if (ge(o, d) && typeof window < "u") {
704
- const z = L, K = window.innerWidth - d.clientWidth - L, G = K < z ? z : K, j = w, te = window.innerHeight - d.clientHeight - w, X = te < j ? j : te;
705
- P < z ? P = z : P > G && (P = G), D < j ? D = j : D > X && (D = X), f ? (n.x = e + (P - T), n.y = r + (D - H)) : (n.x = P, n.y = D);
706
- const oe = L, J = window.innerWidth - d.clientWidth - L, ne = w, _ = window.innerHeight - d.clientHeight - w, O = f ? oe + S : oe, W = f ? J + S : J, Q = f ? ne + I : ne, p = f ? _ + I : _;
707
- return n.x < O ? n.x = O : n.x > W && (n.x = W), n.y < Q ? n.y = Q : n.y > p && (n.y = p), n;
700
+ }, s = o.middleware || [], f = s.findIndex((V) => V.name === "shift"), p = s.findIndex((V) => V.name === "offset"), u = p !== -1 && (f === -1 || p > f), y = s.find((V) => V.name === "offset"), m = y ? (d = y.params) == null ? void 0 : d.value : 0, C = u ? et(m, o, a, c, i) : 0, M = u ? tt(m, o, v, c, i) : 0, S = e - C, H = r - M;
701
+ let R = S, P = H;
702
+ const W = y ? Math.abs(m) : 0, z = W, x = W;
703
+ if (me(o, i) && typeof window < "u") {
704
+ const V = z, K = window.innerWidth - i.clientWidth - z, G = K < V ? V : K, j = x, oe = window.innerHeight - i.clientHeight - x, X = oe < j ? j : oe;
705
+ R < V ? R = V : R > G && (R = G), P < j ? P = j : P > X && (P = X), u ? (n.x = e + (R - S), n.y = r + (P - H)) : (n.x = R, n.y = P);
706
+ const ae = z, J = window.innerWidth - i.clientWidth - z, ne = x, w = window.innerHeight - i.clientHeight - x, E = u ? ae + C : ae, A = u ? J + C : J, ee = u ? ne + M : ne, b = u ? w + M : w;
707
+ return n.x < E ? n.x = E : n.x > A && (n.x = A), n.y < ee ? n.y = ee : n.y > b && (n.y = b), n;
708
708
  }
709
- const y = pe(d);
710
- if (y !== null) {
711
- const z = se(l, d, o), K = z.left, G = z.left + z.width, j = z.top, te = z.top + z.height, X = y.scrollLeft + L, oe = Re(y) - d.clientWidth - L, J = oe < X ? X : oe, ne = y.scrollTop + w, _ = Pe(y) - d.clientHeight - w, O = _ < ne ? ne : _, W = y.scrollLeft, Q = Re(y), p = y.scrollTop, k = Pe(y);
712
- G <= W ? P = X : K >= Q && (P = J), te <= p ? D = ne : j >= k && (D = O), D < ne ? D = ne : D > O && (D = O), P < X ? P = X : P > J && (P = J);
709
+ const k = pe(i);
710
+ if (k !== null) {
711
+ const V = ie(l, i, o), K = V.left, G = V.left + V.width, j = V.top, oe = V.top + V.height, X = k.scrollLeft + z, ae = Re(k) - i.clientWidth - z, J = ae < X ? X : ae, ne = k.scrollTop + x, w = Pe(k) - i.clientHeight - x, E = w < ne ? ne : w, A = k.scrollLeft, ee = Re(k), b = k.scrollTop, $ = Pe(k);
712
+ G <= A ? R = X : K >= ee && (R = J), oe <= b ? P = ne : j >= $ && (P = E), P < ne ? P = ne : P > E && (P = E), R < X ? R = X : R > J && (R = J);
713
713
  }
714
- if (f ? (n.x = e + (P - T), n.y = r + (D - H)) : (n.x = P, n.y = D), y !== null) {
715
- const z = y.scrollLeft + L, K = Re(y) - d.clientWidth - L, G = y.scrollTop + w, j = Pe(y) - d.clientHeight - w, te = f ? z + S : z, X = f ? K + S : K, oe = f ? G + I : G, J = f ? j + I : j;
716
- n.x < te ? n.x = te : n.x > X && (n.x = X), n.y < oe ? n.y = oe : n.y > J && (n.y = J);
714
+ if (u ? (n.x = e + (R - S), n.y = r + (P - H)) : (n.x = R, n.y = P), k !== null) {
715
+ const V = k.scrollLeft + z, K = Re(k) - i.clientWidth - z, G = k.scrollTop + x, j = Pe(k) - i.clientHeight - x, oe = u ? V + C : V, X = u ? K + C : K, ae = u ? G + M : G, J = u ? j + M : j;
716
+ n.x < oe ? n.x = oe : n.x > X && (n.x = X), n.y < ae ? n.y = ae : n.y > J && (n.y = J);
717
717
  }
718
718
  return n;
719
719
  }
720
- }), Dt = (t) => t.getBoundingClientRect().width !== t.clientWidth ? (t.getBoundingClientRect().width - t.clientWidth) / 2 : 0, Ot = (t) => t.getBoundingClientRect().height !== t.clientHeight ? (t.getBoundingClientRect().height - t.clientHeight) / 2 : 0, Le = (t, e) => {
720
+ }), It = (t) => t.getBoundingClientRect().width !== t.clientWidth ? (t.getBoundingClientRect().width - t.clientWidth) / 2 : 0, Dt = (t) => t.getBoundingClientRect().height !== t.clientHeight ? (t.getBoundingClientRect().height - t.clientHeight) / 2 : 0, Le = (t, e) => {
721
721
  const r = pe(t), o = [];
722
722
  if (r !== null) {
723
723
  const a = () => e();
724
724
  r.addEventListener("scroll", a, !1), o.push(() => r.removeEventListener("scroll", a, !1));
725
725
  }
726
726
  if (typeof window < "u") {
727
- const a = () => e(), u = () => e();
728
- window.addEventListener("scroll", a, !1), window.addEventListener("resize", u, !1), o.push(() => window.removeEventListener("scroll", a, !1)), o.push(() => window.removeEventListener("resize", u, !1));
727
+ const a = () => e(), v = () => e();
728
+ window.addEventListener("scroll", a, !1), window.addEventListener("resize", v, !1), o.push(() => window.removeEventListener("scroll", a, !1)), o.push(() => window.removeEventListener("resize", v, !1));
729
729
  }
730
730
  if (typeof ResizeObserver < "u" && t instanceof HTMLElement) {
731
731
  const a = new ResizeObserver(() => e());
732
732
  a.observe(t), o.push(() => a.disconnect());
733
733
  }
734
734
  return () => o.forEach((a) => a());
735
- }, Et = (t, e, r = {}) => {
736
- const o = se(t, e, r);
735
+ }, Ot = (t, e, r = {}) => {
736
+ const o = ie(t, e, r);
737
737
  return {
738
738
  x: o.left - e.getBoundingClientRect().width / 2 + o.width / 2,
739
739
  y: o.top - e.getBoundingClientRect().height,
740
740
  placement: "top"
741
741
  };
742
- }, Wt = (t, e, r = {}) => {
743
- const o = se(t, e, r);
742
+ }, Et = (t, e, r = {}) => {
743
+ const o = ie(t, e, r);
744
744
  return {
745
745
  x: o.left,
746
746
  y: o.top - e.getBoundingClientRect().height,
747
747
  placement: "top-start"
748
748
  };
749
- }, Mt = (t, e, r = {}) => {
750
- const o = se(t, e, r);
749
+ }, Wt = (t, e, r = {}) => {
750
+ const o = ie(t, e, r);
751
751
  return {
752
752
  x: o.left - e.getBoundingClientRect().width + o.width,
753
753
  y: o.top - e.getBoundingClientRect().height,
754
754
  placement: "top-end"
755
755
  };
756
756
  }, Ht = (t, e, r = {}) => {
757
- const o = se(t, e, r);
757
+ const o = ie(t, e, r);
758
758
  return {
759
759
  x: o.left + o.width,
760
760
  y: o.top - e.getBoundingClientRect().height / 2 + o.height / 2,
761
761
  placement: "right"
762
762
  };
763
763
  }, At = (t, e, r = {}) => {
764
- const o = se(t, e, r);
764
+ const o = ie(t, e, r);
765
765
  return {
766
766
  x: o.left + o.width,
767
767
  y: o.top,
768
768
  placement: "right-start"
769
769
  };
770
770
  }, Kt = (t, e, r = {}) => {
771
- const o = se(t, e, r);
771
+ const o = ie(t, e, r);
772
772
  return {
773
773
  x: o.left + o.width,
774
774
  y: o.top + o.height - e.getBoundingClientRect().height,
775
775
  placement: "right-end"
776
776
  };
777
777
  }, Nt = (t, e, r = {}) => {
778
- const o = se(t, e, r);
778
+ const o = ie(t, e, r);
779
779
  return {
780
780
  x: o.left + o.width / 2 - e.getBoundingClientRect().width / 2,
781
781
  y: o.top + o.height,
782
782
  placement: "bottom"
783
783
  };
784
784
  }, Yt = (t, e, r = {}) => {
785
- const o = se(t, e, r);
785
+ const o = ie(t, e, r);
786
786
  return {
787
787
  x: o.left,
788
788
  y: o.top + o.height,
789
789
  placement: "bottom-start"
790
790
  };
791
791
  }, Gt = (t, e, r = {}) => {
792
- const o = se(t, e, r);
792
+ const o = ie(t, e, r);
793
793
  return {
794
794
  x: o.left - e.getBoundingClientRect().width + o.width,
795
795
  y: o.top + o.height,
796
796
  placement: "bottom-end"
797
797
  };
798
798
  }, jt = (t, e, r = {}) => {
799
- const o = se(t, e, r);
799
+ const o = ie(t, e, r);
800
800
  return {
801
801
  x: o.left - e.getBoundingClientRect().width,
802
802
  y: o.top + o.height / 2 - e.getBoundingClientRect().height / 2,
803
803
  placement: "left"
804
804
  };
805
805
  }, Xt = (t, e, r = {}) => {
806
- const o = se(t, e, r);
806
+ const o = ie(t, e, r);
807
807
  return {
808
808
  x: o.left - e.getBoundingClientRect().width,
809
809
  y: o.top,
810
810
  placement: "left-start"
811
811
  };
812
812
  }, qt = (t, e, r = {}) => {
813
- const o = se(t, e, r);
813
+ const o = ie(t, e, r);
814
814
  return {
815
815
  x: o.left - e.getBoundingClientRect().width,
816
816
  y: o.top + o.height - e.getBoundingClientRect().height,
817
817
  placement: "left-end"
818
818
  };
819
- }, Ie = (t, e, r, o = {}) => {
819
+ }, Me = (t, e, r, o = {}) => {
820
820
  switch (r) {
821
821
  case "top":
822
- return Et(t, e, o);
822
+ return Ot(t, e, o);
823
823
  case "top-start":
824
- return Wt(t, e, o);
824
+ return Et(t, e, o);
825
825
  case "top-end":
826
- return Mt(t, e, o);
826
+ return Wt(t, e, o);
827
827
  case "right":
828
828
  return Ht(t, e, o);
829
829
  case "right-start":
@@ -850,23 +850,23 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
850
850
  };
851
851
  }
852
852
  }, Ut = (t, e, r, o = {}) => {
853
- if (ge(o, e)) {
853
+ if (me(o, e)) {
854
854
  if (typeof window > "u")
855
855
  return !0;
856
- const s = t.x, v = t.y, b = s + e.clientWidth, f = v + e.clientHeight;
857
- return s >= 0 && v >= 0 && b <= window.innerWidth && f <= window.innerHeight;
856
+ const s = t.x, f = t.y, p = s + e.clientWidth, u = f + e.clientHeight;
857
+ return s >= 0 && f >= 0 && p <= window.innerWidth && u <= window.innerHeight;
858
858
  }
859
859
  if (pe(r) !== null)
860
- return ie(t.y, e, null, o) > 0 && de(t.x, e, null, o) > 0 && be(t.y, e, null, o) > 0 && ce(t.x, e, null, o) > 0;
860
+ return de(t.y, e, null, o) > 0 && ce(t.x, e, null, o) > 0 && be(t.y, e, null, o) > 0 && ue(t.x, e, null, o) > 0;
861
861
  if (typeof window > "u")
862
862
  return !0;
863
- const a = window.innerWidth, u = window.innerHeight, d = (r instanceof HTMLElement ? r.offsetParent : null) || e.offsetParent;
864
- if (d) {
865
- const s = d.getBoundingClientRect(), v = s.left + t.x, b = s.top + t.y, f = v + e.clientWidth, C = b + e.clientHeight;
866
- return v >= 0 && b >= 0 && f <= a && C <= u;
863
+ const a = window.innerWidth, v = window.innerHeight, i = (r instanceof HTMLElement ? r.offsetParent : null) || e.offsetParent;
864
+ if (i) {
865
+ const s = i.getBoundingClientRect(), f = s.left + t.x, p = s.top + t.y, u = f + e.clientWidth, y = p + e.clientHeight;
866
+ return f >= 0 && p >= 0 && u <= a && y <= v;
867
867
  }
868
- const c = t.x, l = t.y, i = c + e.clientWidth, n = l + e.clientHeight;
869
- return c >= 0 && l >= 0 && i <= a && n <= u;
868
+ const c = t.x, l = t.y, d = c + e.clientWidth, n = l + e.clientHeight;
869
+ return c >= 0 && l >= 0 && d <= a && n <= v;
870
870
  }, ze = (t) => t.startsWith("right") ? "right" : t.startsWith("left") ? "left" : t.startsWith("top") ? "top" : "bottom", Zt = (t, e, r) => ze(e) === t && r.includes(e) ? e : r.find((o) => ze(o) === t) ?? r[0], Jt = (t, e, r = {}) => {
871
871
  if (typeof window > "u")
872
872
  return {
@@ -875,51 +875,51 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
875
875
  bottom: 0,
876
876
  left: 0
877
877
  };
878
- const o = ge(r, e) ? null : pe(t), a = t.getBoundingClientRect(), u = o ? o.getBoundingClientRect() : {
878
+ const o = me(r, e) ? null : pe(t), a = t.getBoundingClientRect(), v = o ? o.getBoundingClientRect() : {
879
879
  top: 0,
880
880
  left: 0,
881
881
  right: window.innerWidth,
882
882
  bottom: window.innerHeight
883
883
  };
884
884
  return {
885
- top: a.top - u.top,
886
- right: u.right - a.right,
887
- bottom: u.bottom - a.bottom,
888
- left: a.left - u.left
885
+ top: a.top - v.top,
886
+ right: v.right - a.right,
887
+ bottom: v.bottom - a.bottom,
888
+ left: a.left - v.left
889
889
  };
890
890
  }, Te = (t, e, r = {}) => new Promise((o) => {
891
- var a, u;
892
- const d = r.placement ? r.placement : "bottom", c = {
891
+ var a, v;
892
+ const i = r.placement ? r.placement : "bottom", c = {
893
893
  x: 0,
894
894
  y: 0,
895
- placement: d,
895
+ placement: i,
896
896
  middlewareData: {}
897
- }, l = Ie(t, e, d, r);
897
+ }, l = Me(t, e, i, r);
898
898
  c.x = l.x, c.y = l.y, c.placement = l.placement;
899
- const i = c.x, n = c.y, s = Pt(t);
900
- (a = r.middleware) == null || a.forEach((C) => {
901
- const $ = C.fn({
899
+ const d = c.x, n = c.y, s = Pt(t);
900
+ (a = r.middleware) == null || a.forEach((y) => {
901
+ const m = y.fn({
902
902
  x: c.x,
903
903
  y: c.y,
904
904
  options: r,
905
- primaryX: i,
905
+ primaryX: d,
906
906
  primaryY: n,
907
907
  floating: e,
908
908
  placement: c.placement,
909
909
  reference: t,
910
910
  scrollDirection: s
911
911
  });
912
- c.x = $.x, c.y = $.y, c.placement = $.placement, C.name === "arrow" && ($.baseX = $.x, $.baseY = $.y, $.x = $.arrowX ?? $.x, $.y = $.arrowY ?? $.y), c.middlewareData[C.name] = $;
912
+ c.x = m.x, c.y = m.y, c.placement = m.placement, y.name === "arrow" && (m.baseX = m.x, m.baseY = m.y, m.x = m.arrowX ?? m.x, m.y = m.arrowY ?? m.y), c.middlewareData[y.name] = m;
913
913
  });
914
- const v = Ie(t, e, c.placement, r), b = _e(r, "offset"), f = b ? (u = b.params) == null ? void 0 : u.value : 0;
915
- if (Number.isFinite(c.x) || (c.x = v.x), !Number.isFinite(c.y))
916
- if (ge(r, e)) {
917
- const C = t.getBoundingClientRect(), $ = e.getBoundingClientRect().height;
918
- c.placement.startsWith("top") ? c.y = C.top - $ - f : c.placement.startsWith("bottom") ? c.y = C.bottom + f : c.y = v.y;
914
+ const f = Me(t, e, c.placement, r), p = _e(r, "offset"), u = p ? (v = p.params) == null ? void 0 : v.value : 0;
915
+ if (Number.isFinite(c.x) || (c.x = f.x), !Number.isFinite(c.y))
916
+ if (me(r, e)) {
917
+ const y = t.getBoundingClientRect(), m = e.getBoundingClientRect().height;
918
+ c.placement.startsWith("top") ? c.y = y.top - m - u : c.placement.startsWith("bottom") ? c.y = y.bottom + u : c.y = f.y;
919
919
  } else
920
- c.y = v.y;
920
+ c.y = f.y;
921
921
  o(c);
922
- }), Qt = ["disabled", "aria-expanded", "onKeydown"], eo = ["data-placement"], to = ["disabled", "aria-selected", "onClick"], Ka = /* @__PURE__ */ Z({
922
+ }), Qt = ["disabled", "aria-expanded", "onKeydown"], eo = ["data-placement"], to = ["disabled", "aria-selected", "onClick"], ja = /* @__PURE__ */ U({
923
923
  __name: "select",
924
924
  props: {
925
925
  modelValue: { default: void 0 },
@@ -934,110 +934,110 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
934
934
  emits: ["update:modelValue", "change", "focus", "blur"],
935
935
  setup(t, { emit: e }) {
936
936
  let r = 0;
937
- const o = e, a = t, u = R(null), d = R(null), c = R(null), l = R(!1), i = R("bottom"), n = R("bottom"), s = `vf-select-panel-${++r}`;
938
- let v = null;
939
- const b = g(() => a.options.map((y) => ({
940
- label: y[a.optionLabel],
941
- value: y[a.optionValue],
942
- disabled: y.disabled
943
- }))), f = g(() => b.value.find((y) => y.value === a.modelValue)), C = g(() => {
944
- var y;
945
- return ((y = f.value) == null ? void 0 : y.label) ?? "";
946
- }), $ = g(() => {
947
- const y = ["vf-select", `vf-select_${a.variant}`, l.value ? "vf-select_open" : ""];
948
- return a.size !== "normal" && y.push(`vf-select_${a.size}`), a.disabled && y.push("vf-select_disabled"), y.filter(Boolean);
949
- }), S = (y) => y.value === a.modelValue, I = (y) => {
950
- y.disabled || (o("update:modelValue", y.value), o("change", y.value), P());
951
- }, T = (y) => o("focus", y), H = (y) => o("blur", y), P = () => {
952
- l.value = !1, i.value = "bottom", n.value = "bottom";
953
- }, D = () => {
954
- a.disabled || (l.value = !l.value, l.value && (i.value = "bottom", n.value = "bottom"));
955
- }, A = async () => {
956
- var y, z;
957
- l.value || (l.value = !0, await ke()), (z = (y = c.value) == null ? void 0 : y.querySelector(".vf-select__option:not(.is-disabled)")) == null || z.focus();
958
- }, L = (y) => {
937
+ const o = e, a = t, v = I(null), i = I(null), c = I(null), l = I(!1), d = I("bottom"), n = I("bottom"), s = `vf-select-panel-${++r}`;
938
+ let f = null;
939
+ const p = h(() => a.options.map((k) => ({
940
+ label: k[a.optionLabel],
941
+ value: k[a.optionValue],
942
+ disabled: k.disabled
943
+ }))), u = h(() => p.value.find((k) => k.value === a.modelValue)), y = h(() => {
944
+ var k;
945
+ return ((k = u.value) == null ? void 0 : k.label) ?? "";
946
+ }), m = h(() => {
947
+ const k = ["vf-select", `vf-select_${a.variant}`, l.value ? "vf-select_open" : ""];
948
+ return a.size !== "normal" && k.push(`vf-select_${a.size}`), a.disabled && k.push("vf-select_disabled"), k.filter(Boolean);
949
+ }), C = (k) => k.value === a.modelValue, M = (k) => {
950
+ k.disabled || (o("update:modelValue", k.value), o("change", k.value), R());
951
+ }, S = (k) => o("focus", k), H = (k) => o("blur", k), R = () => {
952
+ l.value = !1, d.value = "bottom", n.value = "bottom";
953
+ }, P = () => {
954
+ a.disabled || (l.value = !l.value, l.value && (d.value = "bottom", n.value = "bottom"));
955
+ }, W = async () => {
956
+ var k, V;
957
+ l.value || (l.value = !0, await Ce()), (V = (k = c.value) == null ? void 0 : k.querySelector(".vf-select__option:not(.is-disabled)")) == null || V.focus();
958
+ }, z = (k) => {
959
959
  var K;
960
- if (!l.value || !u.value)
960
+ if (!l.value || !v.value)
961
961
  return;
962
- const z = y.target;
963
- u.value.contains(z) || (K = c.value) != null && K.contains(z) || P();
964
- }, w = () => {
965
- if (!d.value || !c.value)
962
+ const V = k.target;
963
+ v.value.contains(V) || (K = c.value) != null && K.contains(V) || R();
964
+ }, x = () => {
965
+ if (!i.value || !c.value)
966
966
  return;
967
- const y = d.value, z = c.value, K = async () => {
967
+ const k = i.value, V = c.value, K = async () => {
968
968
  const {
969
969
  x: X,
970
- y: oe,
970
+ y: ae,
971
971
  placement: J
972
- } = await Te(y, z, {
973
- placement: i.value,
972
+ } = await Te(k, V, {
973
+ placement: d.value,
974
974
  strategy: "fixed",
975
975
  middleware: [Ve(2), Se({ placements: ["bottom", "top"] })]
976
976
  });
977
- n.value = J ?? i.value, z.style.minWidth = `${y.getBoundingClientRect().width}px`, z.style.left = `${X}px`, z.style.top = `${oe}px`;
977
+ n.value = J ?? d.value, V.style.minWidth = `${k.getBoundingClientRect().width}px`, V.style.left = `${X}px`, V.style.top = `${ae}px`;
978
978
  }, G = async () => {
979
979
  await K();
980
- }, j = Le(y, () => {
980
+ }, j = Le(k, () => {
981
981
  G();
982
- }), te = () => {
982
+ }), oe = () => {
983
983
  G();
984
984
  };
985
- document.addEventListener("scroll", te, !0), window.addEventListener("resize", te, !1), v = {
985
+ document.addEventListener("scroll", oe, !0), window.addEventListener("resize", oe, !1), f = {
986
986
  update: G,
987
987
  destroy: () => {
988
- j(), document.removeEventListener("scroll", te, !0), window.removeEventListener("resize", te, !1);
988
+ j(), document.removeEventListener("scroll", oe, !0), window.removeEventListener("resize", oe, !1);
989
989
  }
990
- }, v.update();
990
+ }, f.update();
991
991
  };
992
- return ee(l, async (y) => {
993
- if (!y) {
994
- v && (v.destroy(), v = null);
992
+ return te(l, async (k) => {
993
+ if (!k) {
994
+ f && (f.destroy(), f = null);
995
995
  return;
996
996
  }
997
- await ke(), v || w(), v == null || v.update();
998
- }), ee(
997
+ await Ce(), f || x(), f == null || f.update();
998
+ }), te(
999
999
  () => a.options,
1000
1000
  () => {
1001
- v == null || v.update();
1001
+ f == null || f.update();
1002
1002
  },
1003
1003
  { deep: !0 }
1004
1004
  ), Fe(() => {
1005
- document.addEventListener("click", L);
1006
- }), Ce(() => {
1007
- document.removeEventListener("click", L), v == null || v.destroy(), v = null;
1008
- }), (y, z) => (m(), h("div", {
1005
+ document.addEventListener("click", z);
1006
+ }), we(() => {
1007
+ document.removeEventListener("click", z), f == null || f.destroy(), f = null;
1008
+ }), (k, V) => (g(), _("div", {
1009
1009
  ref_key: "root",
1010
- ref: u,
1011
- class: E($.value)
1010
+ ref: v,
1011
+ class: D(m.value)
1012
1012
  }, [
1013
- B("button", {
1013
+ F("button", {
1014
1014
  ref_key: "trigger",
1015
- ref: d,
1015
+ ref: i,
1016
1016
  class: "vf-select__control",
1017
1017
  type: "button",
1018
- disabled: y.disabled,
1018
+ disabled: k.disabled,
1019
1019
  "aria-expanded": l.value,
1020
1020
  "aria-controls": s,
1021
1021
  "aria-haspopup": "listbox",
1022
- onClick: D,
1022
+ onClick: P,
1023
1023
  onKeydown: [
1024
- q(Y(A, ["prevent"]), ["down"]),
1025
- q(Y(D, ["prevent"]), ["enter"]),
1026
- q(Y(P, ["prevent"]), ["esc"])
1024
+ q(Y(W, ["prevent"]), ["down"]),
1025
+ q(Y(P, ["prevent"]), ["enter"]),
1026
+ q(Y(R, ["prevent"]), ["esc"])
1027
1027
  ],
1028
- onFocus: T,
1028
+ onFocus: S,
1029
1029
  onBlur: H
1030
1030
  }, [
1031
- B("span", {
1032
- class: E(["vf-select__label", { "vf-select__label_placeholder": !C.value }])
1033
- }, M(C.value || y.placeholder), 3),
1034
- z[0] || (z[0] = B("span", {
1031
+ F("span", {
1032
+ class: D(["vf-select__label", { "vf-select__label_placeholder": !y.value }])
1033
+ }, O(y.value || k.placeholder), 3),
1034
+ V[0] || (V[0] = F("span", {
1035
1035
  class: "vf-select__chevron",
1036
1036
  "aria-hidden": "true"
1037
1037
  }, "▾", -1))
1038
1038
  ], 40, Qt),
1039
- (m(), le(we, { to: "body" }, [
1040
- ve(B("div", {
1039
+ (g(), le($e, { to: "body" }, [
1040
+ ve(F("div", {
1041
1041
  id: s,
1042
1042
  ref_key: "panel",
1043
1043
  ref: c,
@@ -1045,15 +1045,15 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1045
1045
  role: "listbox",
1046
1046
  "data-placement": n.value
1047
1047
  }, [
1048
- (m(!0), h(ue, null, Be(b.value, (K) => (m(), h("button", {
1048
+ (g(!0), _(se, null, ke(p.value, (K) => (g(), _("button", {
1049
1049
  key: K.value,
1050
- class: E(["vf-select__option", { "is-active": S(K), "is-disabled": K.disabled }]),
1050
+ class: D(["vf-select__option", { "is-active": C(K), "is-disabled": K.disabled }]),
1051
1051
  type: "button",
1052
1052
  role: "option",
1053
1053
  disabled: K.disabled,
1054
- "aria-selected": S(K),
1055
- onClick: (G) => I(K)
1056
- }, M(K.label), 11, to))), 128))
1054
+ "aria-selected": C(K),
1055
+ onClick: (G) => M(K)
1056
+ }, O(K.label), 11, to))), 128))
1057
1057
  ], 8, eo), [
1058
1058
  [fe, l.value]
1059
1059
  ])
@@ -1066,7 +1066,7 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1066
1066
  }, no = ["id", "disabled", "aria-selected", "onClick"], so = {
1067
1067
  key: 2,
1068
1068
  class: "vf-autocomplete__empty"
1069
- }, Na = /* @__PURE__ */ Z({
1069
+ }, Xa = /* @__PURE__ */ U({
1070
1070
  __name: "autocomplete",
1071
1071
  props: {
1072
1072
  modelValue: { default: void 0 },
@@ -1086,201 +1086,201 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1086
1086
  emits: ["update:modelValue", "change", "focus", "blur", "search"],
1087
1087
  setup(t, { emit: e }) {
1088
1088
  let r = 0;
1089
- const o = e, a = t, u = R(null), d = R(null), c = R(null), l = R(!1), i = R(""), n = R(-1), s = R("bottom"), v = R("bottom"), b = `vf-autocomplete-panel-${++r}`;
1090
- let f = null;
1091
- const C = g(() => a.options.map((_) => ({
1092
- label: _[a.optionLabel],
1093
- value: _[a.optionValue],
1094
- disabled: _.disabled
1095
- }))), $ = g(() => C.value.find((_) => _.value === a.modelValue)), S = g(() => {
1089
+ const o = e, a = t, v = I(null), i = I(null), c = I(null), l = I(!1), d = I(""), n = I(-1), s = I("bottom"), f = I("bottom"), p = `vf-autocomplete-panel-${++r}`;
1090
+ let u = null;
1091
+ const y = h(() => a.options.map((w) => ({
1092
+ label: w[a.optionLabel],
1093
+ value: w[a.optionValue],
1094
+ disabled: w.disabled
1095
+ }))), m = h(() => y.value.find((w) => w.value === a.modelValue)), C = h(() => {
1096
1096
  if (!a.filter)
1097
- return C.value;
1098
- const _ = i.value.trim().toLowerCase();
1099
- return _ ? C.value.filter((O) => O.label.toLowerCase().includes(_)) : C.value;
1100
- }), I = g(() => {
1097
+ return y.value;
1098
+ const w = d.value.trim().toLowerCase();
1099
+ return w ? y.value.filter((E) => E.label.toLowerCase().includes(w)) : y.value;
1100
+ }), M = h(() => {
1101
1101
  if (!(!l.value || n.value < 0))
1102
1102
  return H(n.value);
1103
- }), T = g(() => {
1104
- const _ = ["vf-autocomplete", `vf-autocomplete_${a.variant}`, l.value ? "vf-autocomplete_open" : ""];
1105
- return a.size !== "normal" && _.push(`vf-autocomplete_${a.size}`), a.disabled && _.push("vf-autocomplete_disabled"), _.filter(Boolean);
1106
- }), H = (_) => `${b}-option-${_}`, P = (_) => _.value === a.modelValue, D = () => S.value.findIndex((_) => !_.disabled), A = (_) => {
1107
- const O = S.value;
1108
- if (!O.length) {
1103
+ }), S = h(() => {
1104
+ const w = ["vf-autocomplete", `vf-autocomplete_${a.variant}`, l.value ? "vf-autocomplete_open" : ""];
1105
+ return a.size !== "normal" && w.push(`vf-autocomplete_${a.size}`), a.disabled && w.push("vf-autocomplete_disabled"), w.filter(Boolean);
1106
+ }), H = (w) => `${p}-option-${w}`, R = (w) => w.value === a.modelValue, P = () => C.value.findIndex((w) => !w.disabled), W = (w) => {
1107
+ const E = C.value;
1108
+ if (!E.length) {
1109
1109
  n.value = -1;
1110
1110
  return;
1111
1111
  }
1112
- let W = n.value;
1113
- (W < 0 || W >= O.length) && (W = _ > 0 ? -1 : O.length);
1114
- for (let Q = 0; Q < O.length; Q += 1)
1115
- if (W = (W + _ + O.length) % O.length, !O[W].disabled) {
1116
- n.value = W;
1112
+ let A = n.value;
1113
+ (A < 0 || A >= E.length) && (A = w > 0 ? -1 : E.length);
1114
+ for (let ee = 0; ee < E.length; ee += 1)
1115
+ if (A = (A + w + E.length) % E.length, !E[A].disabled) {
1116
+ n.value = A;
1117
1117
  return;
1118
1118
  }
1119
1119
  n.value = -1;
1120
- }, L = () => {
1121
- a.disabled || (l.value = !0, s.value = "bottom", v.value = "bottom", n.value < 0 && (n.value = D()));
1122
- }, w = () => {
1123
- l.value = !1, n.value = -1, s.value = "bottom", v.value = "bottom";
1124
- }, y = () => {
1120
+ }, z = () => {
1121
+ a.disabled || (l.value = !0, s.value = "bottom", f.value = "bottom", n.value < 0 && (n.value = P()));
1122
+ }, x = () => {
1123
+ l.value = !1, n.value = -1, s.value = "bottom", f.value = "bottom";
1124
+ }, k = () => {
1125
1125
  if (l.value) {
1126
- w();
1126
+ x();
1127
1127
  return;
1128
1128
  }
1129
- L();
1130
- }, z = (_) => {
1131
- _.disabled || (i.value = _.label, o("update:modelValue", _.value), o("change", _.value), w());
1132
- }, K = (_) => {
1133
- const O = _.target;
1134
- i.value = O.value, o("search", O.value), L(), n.value = D();
1135
- }, G = (_) => {
1136
- o("focus", _), L();
1137
- }, j = (_) => {
1138
- o("blur", _);
1139
- }, te = () => {
1129
+ z();
1130
+ }, V = (w) => {
1131
+ w.disabled || (d.value = w.label, o("update:modelValue", w.value), o("change", w.value), x());
1132
+ }, K = (w) => {
1133
+ const E = w.target;
1134
+ d.value = E.value, o("search", E.value), z(), n.value = P();
1135
+ }, G = (w) => {
1136
+ o("focus", w), z();
1137
+ }, j = (w) => {
1138
+ o("blur", w);
1139
+ }, oe = () => {
1140
1140
  if (!l.value) {
1141
- L();
1141
+ z();
1142
1142
  return;
1143
1143
  }
1144
- A(1);
1144
+ W(1);
1145
1145
  }, X = () => {
1146
1146
  if (!l.value) {
1147
- L();
1147
+ z();
1148
1148
  return;
1149
1149
  }
1150
- A(-1);
1151
- }, oe = () => {
1150
+ W(-1);
1151
+ }, ae = () => {
1152
1152
  if (!l.value) {
1153
- L();
1153
+ z();
1154
1154
  return;
1155
1155
  }
1156
- const _ = S.value[n.value];
1157
- _ && !_.disabled && z(_);
1158
- }, J = (_) => {
1159
- var W;
1160
- if (!l.value || !u.value)
1156
+ const w = C.value[n.value];
1157
+ w && !w.disabled && V(w);
1158
+ }, J = (w) => {
1159
+ var A;
1160
+ if (!l.value || !v.value)
1161
1161
  return;
1162
- const O = _.target;
1163
- u.value.contains(O) || (W = c.value) != null && W.contains(O) || w();
1162
+ const E = w.target;
1163
+ v.value.contains(E) || (A = c.value) != null && A.contains(E) || x();
1164
1164
  }, ne = () => {
1165
- if (!d.value || !c.value)
1165
+ if (!i.value || !c.value)
1166
1166
  return;
1167
- const _ = d.value, O = c.value, W = async () => {
1167
+ const w = i.value, E = c.value, A = async () => {
1168
1168
  const {
1169
- x,
1169
+ x: B,
1170
1170
  y: N,
1171
1171
  placement: re
1172
- } = await Te(_, O, {
1172
+ } = await Te(w, E, {
1173
1173
  placement: s.value,
1174
1174
  strategy: "fixed",
1175
1175
  middleware: [Ve(2), Se({ placements: ["bottom", "top"] })]
1176
1176
  });
1177
- v.value = re ?? s.value, O.style.minWidth = `${_.getBoundingClientRect().width}px`, O.style.left = `${x}px`, O.style.top = `${N}px`;
1178
- }, Q = async () => {
1179
- await W();
1180
- }, p = Le(_, () => {
1181
- Q();
1182
- }), k = () => {
1183
- Q();
1177
+ f.value = re ?? s.value, E.style.minWidth = `${w.getBoundingClientRect().width}px`, E.style.left = `${B}px`, E.style.top = `${N}px`;
1178
+ }, ee = async () => {
1179
+ await A();
1180
+ }, b = Le(w, () => {
1181
+ ee();
1182
+ }), $ = () => {
1183
+ ee();
1184
1184
  };
1185
- document.addEventListener("scroll", k, !0), window.addEventListener("resize", k, !1), f = {
1186
- update: Q,
1185
+ document.addEventListener("scroll", $, !0), window.addEventListener("resize", $, !1), u = {
1186
+ update: ee,
1187
1187
  destroy: () => {
1188
- p(), document.removeEventListener("scroll", k, !0), window.removeEventListener("resize", k, !1);
1188
+ b(), document.removeEventListener("scroll", $, !0), window.removeEventListener("resize", $, !1);
1189
1189
  }
1190
- }, f.update();
1190
+ }, u.update();
1191
1191
  };
1192
- return ee(
1192
+ return te(
1193
1193
  () => a.modelValue,
1194
1194
  () => {
1195
- var _;
1196
- i.value = ((_ = $.value) == null ? void 0 : _.label) ?? "";
1195
+ var w;
1196
+ d.value = ((w = m.value) == null ? void 0 : w.label) ?? "";
1197
1197
  },
1198
1198
  { immediate: !0 }
1199
- ), ee(
1199
+ ), te(
1200
1200
  () => a.options,
1201
1201
  () => {
1202
- var _;
1203
- l.value || (i.value = ((_ = $.value) == null ? void 0 : _.label) ?? ""), f == null || f.update();
1202
+ var w;
1203
+ l.value || (d.value = ((w = m.value) == null ? void 0 : w.label) ?? ""), u == null || u.update();
1204
1204
  },
1205
1205
  { deep: !0 }
1206
- ), ee(S, () => {
1207
- n.value >= S.value.length && (n.value = D());
1208
- }), ee(l, async (_) => {
1209
- if (!_) {
1210
- f && (f.destroy(), f = null);
1206
+ ), te(C, () => {
1207
+ n.value >= C.value.length && (n.value = P());
1208
+ }), te(l, async (w) => {
1209
+ if (!w) {
1210
+ u && (u.destroy(), u = null);
1211
1211
  return;
1212
1212
  }
1213
- await ke(), f || ne(), f == null || f.update();
1213
+ await Ce(), u || ne(), u == null || u.update();
1214
1214
  }), Fe(() => {
1215
1215
  document.addEventListener("click", J);
1216
- }), Ce(() => {
1217
- document.removeEventListener("click", J), f == null || f.destroy(), f = null;
1218
- }), (_, O) => (m(), h("div", {
1216
+ }), we(() => {
1217
+ document.removeEventListener("click", J), u == null || u.destroy(), u = null;
1218
+ }), (w, E) => (g(), _("div", {
1219
1219
  ref_key: "root",
1220
- ref: u,
1221
- class: E(T.value)
1220
+ ref: v,
1221
+ class: D(S.value)
1222
1222
  }, [
1223
- B("input", {
1223
+ F("input", {
1224
1224
  ref_key: "control",
1225
- ref: d,
1225
+ ref: i,
1226
1226
  class: "vf-autocomplete__control",
1227
1227
  type: "text",
1228
1228
  role: "combobox",
1229
- value: i.value,
1230
- placeholder: _.placeholder,
1231
- disabled: _.disabled,
1232
- readonly: _.readonly,
1229
+ value: d.value,
1230
+ placeholder: w.placeholder,
1231
+ disabled: w.disabled,
1232
+ readonly: w.readonly,
1233
1233
  "aria-expanded": l.value,
1234
1234
  "aria-autocomplete": "list",
1235
- "aria-controls": b,
1236
- "aria-activedescendant": I.value,
1235
+ "aria-controls": p,
1236
+ "aria-activedescendant": M.value,
1237
1237
  onInput: K,
1238
1238
  onFocus: G,
1239
1239
  onBlur: j,
1240
- onClick: L,
1240
+ onClick: z,
1241
1241
  onKeydown: [
1242
- q(Y(te, ["prevent"]), ["down"]),
1242
+ q(Y(oe, ["prevent"]), ["down"]),
1243
1243
  q(Y(X, ["prevent"]), ["up"]),
1244
- q(Y(oe, ["prevent"]), ["enter"]),
1245
- q(Y(w, ["prevent"]), ["esc"]),
1246
- q(w, ["tab"])
1244
+ q(Y(ae, ["prevent"]), ["enter"]),
1245
+ q(Y(x, ["prevent"]), ["esc"]),
1246
+ q(x, ["tab"])
1247
1247
  ]
1248
1248
  }, null, 40, oo),
1249
- B("button", {
1249
+ F("button", {
1250
1250
  class: "vf-autocomplete__chevron",
1251
1251
  type: "button",
1252
- disabled: _.disabled,
1252
+ disabled: w.disabled,
1253
1253
  "aria-hidden": "true",
1254
1254
  tabindex: "-1",
1255
- onMousedown: O[0] || (O[0] = Y(() => {
1255
+ onMousedown: E[0] || (E[0] = Y(() => {
1256
1256
  }, ["prevent"])),
1257
- onClick: y
1257
+ onClick: k
1258
1258
  }, " ▾ ", 40, ao),
1259
- (m(), le(we, { to: "body" }, [
1260
- ve(B("div", {
1261
- id: b,
1259
+ (g(), le($e, { to: "body" }, [
1260
+ ve(F("div", {
1261
+ id: p,
1262
1262
  ref_key: "panel",
1263
1263
  ref: c,
1264
1264
  class: "vf-autocomplete__panel",
1265
1265
  role: "listbox",
1266
- "data-placement": v.value
1266
+ "data-placement": f.value
1267
1267
  }, [
1268
- _.loading ? (m(), h("div", lo, M(_.loadingText), 1)) : S.value.length > 0 ? (m(!0), h(ue, { key: 1 }, Be(S.value, (W, Q) => (m(), h("button", {
1269
- id: H(Q),
1270
- key: W.value,
1271
- class: E(["vf-autocomplete__option", {
1272
- "is-active": P(W),
1273
- "is-disabled": W.disabled,
1274
- "is-highlighted": Q === n.value
1268
+ w.loading ? (g(), _("div", lo, O(w.loadingText), 1)) : C.value.length > 0 ? (g(!0), _(se, { key: 1 }, ke(C.value, (A, ee) => (g(), _("button", {
1269
+ id: H(ee),
1270
+ key: A.value,
1271
+ class: D(["vf-autocomplete__option", {
1272
+ "is-active": R(A),
1273
+ "is-disabled": A.disabled,
1274
+ "is-highlighted": ee === n.value
1275
1275
  }]),
1276
1276
  type: "button",
1277
1277
  role: "option",
1278
- disabled: W.disabled,
1279
- "aria-selected": P(W),
1280
- onMousedown: O[1] || (O[1] = Y(() => {
1278
+ disabled: A.disabled,
1279
+ "aria-selected": R(A),
1280
+ onMousedown: E[1] || (E[1] = Y(() => {
1281
1281
  }, ["prevent"])),
1282
- onClick: (p) => z(W)
1283
- }, M(W.label), 43, no))), 128)) : (m(), h("div", so, M(_.emptyText), 1))
1282
+ onClick: (b) => V(A)
1283
+ }, O(A.label), 43, no))), 128)) : (g(), _("div", so, O(w.emptyText), 1))
1284
1284
  ], 8, ro), [
1285
1285
  [fe, l.value]
1286
1286
  ])
@@ -1293,14 +1293,14 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1293
1293
  }, vo = ["value", "placeholder", "onKeydown"], fo = {
1294
1294
  key: 1,
1295
1295
  class: "vf-multiselect__loading"
1296
- }, po = ["id", "disabled", "aria-selected", "onClick"], bo = { class: "vf-multiselect__option-label" }, mo = {
1296
+ }, po = ["id", "disabled", "aria-selected", "onClick"], bo = { class: "vf-multiselect__option-label" }, go = {
1297
1297
  key: 0,
1298
1298
  class: "vf-multiselect__option-check",
1299
1299
  "aria-hidden": "true"
1300
- }, go = {
1300
+ }, mo = {
1301
1301
  key: 3,
1302
1302
  class: "vf-multiselect__empty"
1303
- }, Ya = /* @__PURE__ */ Z({
1303
+ }, qa = /* @__PURE__ */ U({
1304
1304
  __name: "multi-select",
1305
1305
  props: {
1306
1306
  modelValue: { default: () => [] },
@@ -1322,216 +1322,216 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1322
1322
  emits: ["update:modelValue", "change", "search", "focus", "blur"],
1323
1323
  setup(t, { emit: e }) {
1324
1324
  let r = 0;
1325
- const o = e, a = t, u = R(null), d = R(null), c = R(null), l = R(null), i = R(!1), n = R(""), s = R(-1), v = R("bottom"), b = R("bottom"), f = `vf-multiselect-panel-${++r}`;
1326
- let C = null;
1327
- const $ = g(() => a.options.map((p) => ({
1328
- label: p[a.optionLabel],
1329
- value: p[a.optionValue],
1330
- disabled: p.disabled
1331
- }))), S = g(() => Array.isArray(a.modelValue) ? a.modelValue : []), I = g(() => {
1325
+ const o = e, a = t, v = I(null), i = I(null), c = I(null), l = I(null), d = I(!1), n = I(""), s = I(-1), f = I("bottom"), p = I("bottom"), u = `vf-multiselect-panel-${++r}`;
1326
+ let y = null;
1327
+ const m = h(() => a.options.map((b) => ({
1328
+ label: b[a.optionLabel],
1329
+ value: b[a.optionValue],
1330
+ disabled: b.disabled
1331
+ }))), C = h(() => Array.isArray(a.modelValue) ? a.modelValue : []), M = h(() => {
1332
1332
  if (!a.filter)
1333
- return $.value;
1334
- const p = n.value.trim().toLowerCase();
1335
- return p ? $.value.filter((k) => k.label.toLowerCase().includes(p)) : $.value;
1336
- }), T = g(() => $.value.filter((p) => S.value.includes(p.value))), H = g(() => T.value.length === 0 ? a.placeholder : T.value.map((p) => p.label).join(", ")), P = g(() => {
1337
- const p = ["vf-multiselect", `vf-multiselect_${a.variant}`, i.value ? "vf-multiselect_open" : ""];
1338
- return a.size !== "normal" && p.push(`vf-multiselect_${a.size}`), a.disabled && p.push("vf-multiselect_disabled"), p.filter(Boolean);
1339
- }), D = (p) => `${f}-option-${p}`, A = () => I.value.findIndex((p) => !p.disabled), L = (p) => S.value.includes(p.value), w = (p) => {
1340
- o("update:modelValue", p), o("change", p);
1341
- }, y = (p) => {
1342
- if (!(p.disabled || a.readonly)) {
1343
- if (L(p)) {
1344
- w(S.value.filter((k) => k !== p.value));
1333
+ return m.value;
1334
+ const b = n.value.trim().toLowerCase();
1335
+ return b ? m.value.filter(($) => $.label.toLowerCase().includes(b)) : m.value;
1336
+ }), S = h(() => m.value.filter((b) => C.value.includes(b.value))), H = h(() => S.value.length === 0 ? a.placeholder : S.value.map((b) => b.label).join(", ")), R = h(() => {
1337
+ const b = ["vf-multiselect", `vf-multiselect_${a.variant}`, d.value ? "vf-multiselect_open" : ""];
1338
+ return a.size !== "normal" && b.push(`vf-multiselect_${a.size}`), a.disabled && b.push("vf-multiselect_disabled"), b.filter(Boolean);
1339
+ }), P = (b) => `${u}-option-${b}`, W = () => M.value.findIndex((b) => !b.disabled), z = (b) => C.value.includes(b.value), x = (b) => {
1340
+ o("update:modelValue", b), o("change", b);
1341
+ }, k = (b) => {
1342
+ if (!(b.disabled || a.readonly)) {
1343
+ if (z(b)) {
1344
+ x(C.value.filter(($) => $ !== b.value));
1345
1345
  return;
1346
1346
  }
1347
- w([...S.value, p.value]);
1347
+ x([...C.value, b.value]);
1348
1348
  }
1349
- }, z = () => {
1350
- a.readonly || w([]);
1351
- }, K = (p) => {
1352
- const k = I.value;
1353
- if (!k.length) {
1349
+ }, V = () => {
1350
+ a.readonly || x([]);
1351
+ }, K = (b) => {
1352
+ const $ = M.value;
1353
+ if (!$.length) {
1354
1354
  s.value = -1;
1355
1355
  return;
1356
1356
  }
1357
- let x = s.value;
1358
- (x < 0 || x >= k.length) && (x = p > 0 ? -1 : k.length);
1359
- for (let N = 0; N < k.length; N += 1)
1360
- if (x = (x + p + k.length) % k.length, !k[x].disabled) {
1361
- s.value = x;
1357
+ let B = s.value;
1358
+ (B < 0 || B >= $.length) && (B = b > 0 ? -1 : $.length);
1359
+ for (let N = 0; N < $.length; N += 1)
1360
+ if (B = (B + b + $.length) % $.length, !$[B].disabled) {
1361
+ s.value = B;
1362
1362
  return;
1363
1363
  }
1364
1364
  s.value = -1;
1365
1365
  }, G = async () => {
1366
- var p;
1367
- a.disabled || (i.value = !0, v.value = "bottom", b.value = "bottom", s.value < 0 && (s.value = A()), a.filter && (await ke(), (p = l.value) == null || p.focus()));
1366
+ var b;
1367
+ a.disabled || (d.value = !0, f.value = "bottom", p.value = "bottom", s.value < 0 && (s.value = W()), a.filter && (await Ce(), (b = l.value) == null || b.focus()));
1368
1368
  }, j = () => {
1369
- i.value = !1, s.value = -1, v.value = "bottom", b.value = "bottom", n.value = "";
1370
- }, te = () => {
1371
- if (i.value) {
1369
+ d.value = !1, s.value = -1, f.value = "bottom", p.value = "bottom", n.value = "";
1370
+ }, oe = () => {
1371
+ if (d.value) {
1372
1372
  j();
1373
1373
  return;
1374
1374
  }
1375
1375
  G();
1376
1376
  }, X = () => {
1377
- if (!i.value) {
1377
+ if (!d.value) {
1378
1378
  G();
1379
1379
  return;
1380
1380
  }
1381
1381
  K(1);
1382
- }, oe = () => {
1383
- if (!i.value) {
1382
+ }, ae = () => {
1383
+ if (!d.value) {
1384
1384
  G();
1385
1385
  return;
1386
1386
  }
1387
1387
  K(-1);
1388
1388
  }, J = () => {
1389
- if (!i.value) {
1389
+ if (!d.value) {
1390
1390
  G();
1391
1391
  return;
1392
1392
  }
1393
- const p = I.value[s.value];
1394
- p && !p.disabled && y(p);
1395
- }, ne = (p) => {
1396
- const k = p.target;
1397
- n.value = k.value, o("search", k.value), s.value = A();
1398
- }, _ = (p) => o("focus", p), O = (p) => o("blur", p), W = (p) => {
1399
- var x;
1400
- if (!i.value || !u.value)
1393
+ const b = M.value[s.value];
1394
+ b && !b.disabled && k(b);
1395
+ }, ne = (b) => {
1396
+ const $ = b.target;
1397
+ n.value = $.value, o("search", $.value), s.value = W();
1398
+ }, w = (b) => o("focus", b), E = (b) => o("blur", b), A = (b) => {
1399
+ var B;
1400
+ if (!d.value || !v.value)
1401
1401
  return;
1402
- const k = p.target;
1403
- u.value.contains(k) || (x = c.value) != null && x.contains(k) || j();
1404
- }, Q = () => {
1405
- if (!d.value || !c.value)
1402
+ const $ = b.target;
1403
+ v.value.contains($) || (B = c.value) != null && B.contains($) || j();
1404
+ }, ee = () => {
1405
+ if (!i.value || !c.value)
1406
1406
  return;
1407
- const p = d.value, k = c.value, x = async () => {
1407
+ const b = i.value, $ = c.value, B = async () => {
1408
1408
  const {
1409
1409
  x: he,
1410
- y: Oe,
1411
- placement: Ee
1412
- } = await Te(p, k, {
1413
- placement: v.value,
1410
+ y: De,
1411
+ placement: Oe
1412
+ } = await Te(b, $, {
1413
+ placement: f.value,
1414
1414
  strategy: "fixed",
1415
1415
  middleware: [Ve(2), Se({ placements: ["bottom", "top"] })]
1416
1416
  });
1417
- b.value = Ee ?? v.value, k.style.minWidth = `${p.getBoundingClientRect().width}px`, k.style.left = `${he}px`, k.style.top = `${Oe}px`;
1417
+ p.value = Oe ?? f.value, $.style.minWidth = `${b.getBoundingClientRect().width}px`, $.style.left = `${he}px`, $.style.top = `${De}px`;
1418
1418
  }, N = async () => {
1419
- await x();
1420
- }, re = Le(p, () => {
1419
+ await B();
1420
+ }, re = Le(b, () => {
1421
1421
  N();
1422
- }), U = () => {
1422
+ }), Z = () => {
1423
1423
  N();
1424
1424
  };
1425
- document.addEventListener("scroll", U, !0), window.addEventListener("resize", U, !1), C = {
1425
+ document.addEventListener("scroll", Z, !0), window.addEventListener("resize", Z, !1), y = {
1426
1426
  update: N,
1427
1427
  destroy: () => {
1428
- re(), document.removeEventListener("scroll", U, !0), window.removeEventListener("resize", U, !1);
1428
+ re(), document.removeEventListener("scroll", Z, !0), window.removeEventListener("resize", Z, !1);
1429
1429
  }
1430
- }, C.update();
1430
+ }, y.update();
1431
1431
  };
1432
- return ee(
1432
+ return te(
1433
1433
  () => a.options,
1434
1434
  () => {
1435
- s.value >= I.value.length && (s.value = A()), C == null || C.update();
1435
+ s.value >= M.value.length && (s.value = W()), y == null || y.update();
1436
1436
  },
1437
1437
  { deep: !0 }
1438
- ), ee(i, async (p) => {
1439
- if (!p) {
1440
- C && (C.destroy(), C = null);
1438
+ ), te(d, async (b) => {
1439
+ if (!b) {
1440
+ y && (y.destroy(), y = null);
1441
1441
  return;
1442
1442
  }
1443
- await ke(), C || Q(), C == null || C.update();
1444
- }), ee(I, () => {
1445
- s.value >= I.value.length && (s.value = A());
1443
+ await Ce(), y || ee(), y == null || y.update();
1444
+ }), te(M, () => {
1445
+ s.value >= M.value.length && (s.value = W());
1446
1446
  }), Fe(() => {
1447
- document.addEventListener("click", W);
1448
- }), Ce(() => {
1449
- document.removeEventListener("click", W), C == null || C.destroy(), C = null;
1450
- }), (p, k) => (m(), h("div", {
1447
+ document.addEventListener("click", A);
1448
+ }), we(() => {
1449
+ document.removeEventListener("click", A), y == null || y.destroy(), y = null;
1450
+ }), (b, $) => (g(), _("div", {
1451
1451
  ref_key: "root",
1452
- ref: u,
1453
- class: E(P.value)
1452
+ ref: v,
1453
+ class: D(R.value)
1454
1454
  }, [
1455
- B("button", {
1455
+ F("button", {
1456
1456
  ref_key: "trigger",
1457
- ref: d,
1457
+ ref: i,
1458
1458
  class: "vf-multiselect__control",
1459
1459
  type: "button",
1460
- disabled: p.disabled,
1461
- "aria-expanded": i.value,
1462
- "aria-controls": f,
1460
+ disabled: b.disabled,
1461
+ "aria-expanded": d.value,
1462
+ "aria-controls": u,
1463
1463
  "aria-haspopup": "listbox",
1464
- onClick: te,
1464
+ onClick: oe,
1465
1465
  onKeydown: [
1466
1466
  q(Y(X, ["prevent"]), ["down"]),
1467
- q(Y(oe, ["prevent"]), ["up"]),
1467
+ q(Y(ae, ["prevent"]), ["up"]),
1468
1468
  q(Y(J, ["prevent"]), ["enter"]),
1469
1469
  q(Y(j, ["prevent"]), ["esc"])
1470
1470
  ],
1471
- onFocus: _,
1472
- onBlur: O
1471
+ onFocus: w,
1472
+ onBlur: E
1473
1473
  }, [
1474
- B("span", {
1475
- class: E(["vf-multiselect__label", { "vf-multiselect__label_placeholder": S.value.length === 0 }])
1476
- }, M(H.value), 3),
1477
- k[0] || (k[0] = B("span", {
1474
+ F("span", {
1475
+ class: D(["vf-multiselect__label", { "vf-multiselect__label_placeholder": C.value.length === 0 }])
1476
+ }, O(H.value), 3),
1477
+ $[0] || ($[0] = F("span", {
1478
1478
  class: "vf-multiselect__chevron",
1479
1479
  "aria-hidden": "true"
1480
1480
  }, "▾", -1))
1481
1481
  ], 40, io),
1482
- p.clearable && S.value.length > 0 && !p.disabled && !p.readonly ? (m(), h("button", {
1482
+ b.clearable && C.value.length > 0 && !b.disabled && !b.readonly ? (g(), _("button", {
1483
1483
  key: 0,
1484
1484
  class: "vf-multiselect__clear",
1485
1485
  type: "button",
1486
1486
  "aria-label": "Clear selection",
1487
- onClick: Y(z, ["stop"])
1488
- }, " ✕ ")) : V("", !0),
1489
- (m(), le(we, { to: "body" }, [
1490
- ve(B("div", {
1491
- id: f,
1487
+ onClick: Y(V, ["stop"])
1488
+ }, " ✕ ")) : T("", !0),
1489
+ (g(), le($e, { to: "body" }, [
1490
+ ve(F("div", {
1491
+ id: u,
1492
1492
  ref_key: "panel",
1493
1493
  ref: c,
1494
1494
  class: "vf-multiselect__panel",
1495
1495
  role: "listbox",
1496
1496
  "aria-multiselectable": "true",
1497
- "data-placement": b.value
1497
+ "data-placement": p.value
1498
1498
  }, [
1499
- p.filter ? (m(), h("div", uo, [
1500
- B("input", {
1499
+ b.filter ? (g(), _("div", uo, [
1500
+ F("input", {
1501
1501
  ref_key: "searchInput",
1502
1502
  ref: l,
1503
1503
  class: "vf-multiselect__search-control",
1504
1504
  type: "text",
1505
1505
  value: n.value,
1506
- placeholder: p.searchPlaceholder,
1506
+ placeholder: b.searchPlaceholder,
1507
1507
  onInput: ne,
1508
1508
  onKeydown: [
1509
1509
  q(Y(X, ["prevent"]), ["down"]),
1510
- q(Y(oe, ["prevent"]), ["up"]),
1510
+ q(Y(ae, ["prevent"]), ["up"]),
1511
1511
  q(Y(J, ["prevent"]), ["enter"]),
1512
1512
  q(Y(j, ["prevent"]), ["esc"])
1513
1513
  ]
1514
1514
  }, null, 40, vo)
1515
- ])) : V("", !0),
1516
- p.loading ? (m(), h("div", fo, M(p.loadingText), 1)) : I.value.length > 0 ? (m(!0), h(ue, { key: 2 }, Be(I.value, (x, N) => (m(), h("button", {
1517
- id: D(N),
1518
- key: x.value,
1519
- class: E(["vf-multiselect__option", {
1520
- "is-active": L(x),
1521
- "is-disabled": x.disabled,
1515
+ ])) : T("", !0),
1516
+ b.loading ? (g(), _("div", fo, O(b.loadingText), 1)) : M.value.length > 0 ? (g(!0), _(se, { key: 2 }, ke(M.value, (B, N) => (g(), _("button", {
1517
+ id: P(N),
1518
+ key: B.value,
1519
+ class: D(["vf-multiselect__option", {
1520
+ "is-active": z(B),
1521
+ "is-disabled": B.disabled,
1522
1522
  "is-highlighted": N === s.value
1523
1523
  }]),
1524
1524
  type: "button",
1525
1525
  role: "option",
1526
- disabled: x.disabled,
1527
- "aria-selected": L(x),
1528
- onClick: (re) => y(x)
1526
+ disabled: B.disabled,
1527
+ "aria-selected": z(B),
1528
+ onClick: (re) => k(B)
1529
1529
  }, [
1530
- B("span", bo, M(x.label), 1),
1531
- L(x) ? (m(), h("span", mo, "✓")) : V("", !0)
1532
- ], 10, po))), 128)) : (m(), h("div", go, M(p.emptyText), 1))
1530
+ F("span", bo, O(B.label), 1),
1531
+ z(B) ? (g(), _("span", go, "✓")) : T("", !0)
1532
+ ], 10, po))), 128)) : (g(), _("div", mo, O(b.emptyText), 1))
1533
1533
  ], 8, co), [
1534
- [fe, i.value]
1534
+ [fe, d.value]
1535
1535
  ])
1536
1536
  ]))
1537
1537
  ], 2));
@@ -1542,7 +1542,7 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1542
1542
  }, wo = {
1543
1543
  class: "vf-datepicker__days",
1544
1544
  role: "grid"
1545
- }, $o = ["disabled", "data-date", "onClick"], Ga = /* @__PURE__ */ Z({
1545
+ }, $o = ["disabled", "data-date", "onClick"], Ua = /* @__PURE__ */ U({
1546
1546
  __name: "datepicker",
1547
1547
  props: {
1548
1548
  modelValue: { default: void 0 },
@@ -1559,223 +1559,223 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1559
1559
  emits: ["update:modelValue", "change", "focus", "blur"],
1560
1560
  setup(t, { emit: e }) {
1561
1561
  let r = 0;
1562
- const o = e, a = t, u = R(null), d = R(null), c = R(null), l = R(!1), i = R("bottom"), n = R("bottom"), s = `vf-datepicker-panel-${++r}`, v = R(J(X(a.modelValue) ?? /* @__PURE__ */ new Date()));
1563
- let b = null;
1564
- const f = g(() => X(a.modelValue)), C = g(() => X(a.min)), $ = g(() => X(a.max)), S = g(() => f.value ? f.value.toLocaleDateString(a.locale, {
1562
+ const o = e, a = t, v = I(null), i = I(null), c = I(null), l = I(!1), d = I("bottom"), n = I("bottom"), s = `vf-datepicker-panel-${++r}`, f = I(J(X(a.modelValue) ?? /* @__PURE__ */ new Date()));
1563
+ let p = null;
1564
+ const u = h(() => X(a.modelValue)), y = h(() => X(a.min)), m = h(() => X(a.max)), C = h(() => u.value ? u.value.toLocaleDateString(a.locale, {
1565
1565
  year: "numeric",
1566
1566
  month: "short",
1567
1567
  day: "numeric"
1568
- }) : ""), I = g(() => v.value.toLocaleDateString(a.locale, {
1568
+ }) : ""), M = h(() => f.value.toLocaleDateString(a.locale, {
1569
1569
  year: "numeric",
1570
1570
  month: "long"
1571
- })), T = g(() => {
1572
- const p = new Intl.DateTimeFormat(a.locale, { weekday: "short" }), k = new Date(2026, 0, 4);
1573
- return Array.from({ length: 7 }, (x, N) => {
1574
- const re = (N + a.firstDayOfWeek) % 7, U = new Date(k);
1575
- return U.setDate(k.getDate() + re), p.format(U);
1571
+ })), S = h(() => {
1572
+ const b = new Intl.DateTimeFormat(a.locale, { weekday: "short" }), $ = new Date(2026, 0, 4);
1573
+ return Array.from({ length: 7 }, (B, N) => {
1574
+ const re = (N + a.firstDayOfWeek) % 7, Z = new Date($);
1575
+ return Z.setDate($.getDate() + re), b.format(Z);
1576
1576
  });
1577
- }), H = g(() => {
1578
- const p = O(v.value, a.firstDayOfWeek), k = f.value ? W(f.value) : null, x = W(/* @__PURE__ */ new Date());
1577
+ }), H = h(() => {
1578
+ const b = E(f.value, a.firstDayOfWeek), $ = u.value ? A(u.value) : null, B = A(/* @__PURE__ */ new Date());
1579
1579
  return Array.from({ length: 42 }, (N, re) => {
1580
- const U = _(p, re), he = W(U);
1580
+ const Z = w(b, re), he = A(Z);
1581
1581
  return {
1582
1582
  key: `${he}-${re}`,
1583
1583
  iso: he,
1584
- date: U,
1585
- day: U.getDate(),
1586
- inCurrentMonth: U.getMonth() === v.value.getMonth(),
1587
- isDisabled: Q(U, C.value, $.value),
1588
- isSelected: k === he,
1589
- isToday: he === x
1584
+ date: Z,
1585
+ day: Z.getDate(),
1586
+ inCurrentMonth: Z.getMonth() === f.value.getMonth(),
1587
+ isDisabled: ee(Z, y.value, m.value),
1588
+ isSelected: $ === he,
1589
+ isToday: he === B
1590
1590
  };
1591
1591
  });
1592
- }), P = g(() => {
1593
- const p = ["vf-datepicker", `vf-datepicker_${a.variant}`, l.value ? "vf-datepicker_open" : ""];
1594
- return a.size !== "normal" && p.push(`vf-datepicker_${a.size}`), a.disabled && p.push("vf-datepicker_disabled"), p.filter(Boolean);
1595
- }), D = (p) => o("focus", p), A = (p) => o("blur", p), L = () => {
1596
- a.disabled || a.readonly || (l.value = !0, i.value = "bottom", n.value = "bottom");
1597
- }, w = () => {
1598
- l.value = !1, i.value = "bottom", n.value = "bottom";
1599
- }, y = () => {
1592
+ }), R = h(() => {
1593
+ const b = ["vf-datepicker", `vf-datepicker_${a.variant}`, l.value ? "vf-datepicker_open" : ""];
1594
+ return a.size !== "normal" && b.push(`vf-datepicker_${a.size}`), a.disabled && b.push("vf-datepicker_disabled"), b.filter(Boolean);
1595
+ }), P = (b) => o("focus", b), W = (b) => o("blur", b), z = () => {
1596
+ a.disabled || a.readonly || (l.value = !0, d.value = "bottom", n.value = "bottom");
1597
+ }, x = () => {
1598
+ l.value = !1, d.value = "bottom", n.value = "bottom";
1599
+ }, k = () => {
1600
1600
  if (l.value) {
1601
- w();
1601
+ x();
1602
1602
  return;
1603
1603
  }
1604
- L();
1605
- }, z = () => {
1606
- v.value = ne(v.value, -1);
1604
+ z();
1605
+ }, V = () => {
1606
+ f.value = ne(f.value, -1);
1607
1607
  }, K = () => {
1608
- v.value = ne(v.value, 1);
1609
- }, G = (p) => {
1610
- if (a.readonly || Q(p, C.value, $.value))
1608
+ f.value = ne(f.value, 1);
1609
+ }, G = (b) => {
1610
+ if (a.readonly || ee(b, y.value, m.value))
1611
1611
  return;
1612
- const k = W(p);
1613
- o("update:modelValue", k), o("change", k), w();
1614
- }, j = (p) => {
1615
- var x;
1616
- if (!l.value || !u.value)
1612
+ const $ = A(b);
1613
+ o("update:modelValue", $), o("change", $), x();
1614
+ }, j = (b) => {
1615
+ var B;
1616
+ if (!l.value || !v.value)
1617
1617
  return;
1618
- const k = p.target;
1619
- u.value.contains(k) || (x = c.value) != null && x.contains(k) || w();
1620
- }, te = () => {
1621
- if (!d.value || !c.value)
1618
+ const $ = b.target;
1619
+ v.value.contains($) || (B = c.value) != null && B.contains($) || x();
1620
+ }, oe = () => {
1621
+ if (!i.value || !c.value)
1622
1622
  return;
1623
- const p = d.value, k = c.value, x = async () => {
1623
+ const b = i.value, $ = c.value, B = async () => {
1624
1624
  const {
1625
1625
  x: he,
1626
- y: Oe,
1627
- placement: Ee
1628
- } = await Te(p, k, {
1629
- placement: i.value,
1626
+ y: De,
1627
+ placement: Oe
1628
+ } = await Te(b, $, {
1629
+ placement: d.value,
1630
1630
  strategy: "fixed",
1631
1631
  middleware: [Ve(2), Se({ placements: ["bottom", "top"] })]
1632
1632
  });
1633
- n.value = Ee ?? i.value, k.style.left = `${he}px`, k.style.top = `${Oe}px`;
1633
+ n.value = Oe ?? d.value, $.style.left = `${he}px`, $.style.top = `${De}px`;
1634
1634
  }, N = async () => {
1635
- await x();
1636
- }, re = Le(p, () => {
1635
+ await B();
1636
+ }, re = Le(b, () => {
1637
1637
  N();
1638
- }), U = () => {
1638
+ }), Z = () => {
1639
1639
  N();
1640
1640
  };
1641
- document.addEventListener("scroll", U, !0), window.addEventListener("resize", U, !1), b = {
1641
+ document.addEventListener("scroll", Z, !0), window.addEventListener("resize", Z, !1), p = {
1642
1642
  update: N,
1643
1643
  destroy: () => {
1644
- re(), document.removeEventListener("scroll", U, !0), window.removeEventListener("resize", U, !1);
1644
+ re(), document.removeEventListener("scroll", Z, !0), window.removeEventListener("resize", Z, !1);
1645
1645
  }
1646
- }, b.update();
1646
+ }, p.update();
1647
1647
  };
1648
- ee(
1648
+ te(
1649
1649
  () => a.modelValue,
1650
- (p) => {
1651
- const k = X(p);
1652
- k && (v.value = J(k));
1650
+ (b) => {
1651
+ const $ = X(b);
1652
+ $ && (f.value = J($));
1653
1653
  },
1654
1654
  { immediate: !0 }
1655
- ), ee(
1655
+ ), te(
1656
1656
  () => [a.min, a.max],
1657
1657
  () => {
1658
- b == null || b.update();
1658
+ p == null || p.update();
1659
1659
  }
1660
- ), ee(l, async (p) => {
1661
- if (!p) {
1662
- b && (b.destroy(), b = null);
1660
+ ), te(l, async (b) => {
1661
+ if (!b) {
1662
+ p && (p.destroy(), p = null);
1663
1663
  return;
1664
1664
  }
1665
- await ke(), b || te(), b == null || b.update();
1665
+ await Ce(), p || oe(), p == null || p.update();
1666
1666
  }), Fe(() => {
1667
1667
  document.addEventListener("click", j);
1668
- }), Ce(() => {
1669
- document.removeEventListener("click", j), b == null || b.destroy(), b = null;
1668
+ }), we(() => {
1669
+ document.removeEventListener("click", j), p == null || p.destroy(), p = null;
1670
1670
  });
1671
- function X(p) {
1672
- if (!p)
1671
+ function X(b) {
1672
+ if (!b)
1673
1673
  return null;
1674
- const k = p.match(/^(\d{4})-(\d{2})-(\d{2})$/);
1675
- if (!k)
1674
+ const $ = b.match(/^(\d{4})-(\d{2})-(\d{2})$/);
1675
+ if (!$)
1676
1676
  return null;
1677
- const x = Number(k[1]), N = Number(k[2]) - 1, re = Number(k[3]), U = new Date(x, N, re);
1678
- return U.getFullYear() !== x || U.getMonth() !== N || U.getDate() !== re ? null : oe(U);
1677
+ const B = Number($[1]), N = Number($[2]) - 1, re = Number($[3]), Z = new Date(B, N, re);
1678
+ return Z.getFullYear() !== B || Z.getMonth() !== N || Z.getDate() !== re ? null : ae(Z);
1679
1679
  }
1680
- function oe(p) {
1681
- return new Date(p.getFullYear(), p.getMonth(), p.getDate());
1680
+ function ae(b) {
1681
+ return new Date(b.getFullYear(), b.getMonth(), b.getDate());
1682
1682
  }
1683
- function J(p) {
1684
- return new Date(p.getFullYear(), p.getMonth(), 1);
1683
+ function J(b) {
1684
+ return new Date(b.getFullYear(), b.getMonth(), 1);
1685
1685
  }
1686
- function ne(p, k) {
1687
- return new Date(p.getFullYear(), p.getMonth() + k, 1);
1686
+ function ne(b, $) {
1687
+ return new Date(b.getFullYear(), b.getMonth() + $, 1);
1688
1688
  }
1689
- function _(p, k) {
1690
- return new Date(p.getFullYear(), p.getMonth(), p.getDate() + k);
1689
+ function w(b, $) {
1690
+ return new Date(b.getFullYear(), b.getMonth(), b.getDate() + $);
1691
1691
  }
1692
- function O(p, k) {
1693
- const x = J(p), re = (x.getDay() - k + 7) % 7;
1694
- return _(x, -re);
1692
+ function E(b, $) {
1693
+ const B = J(b), re = (B.getDay() - $ + 7) % 7;
1694
+ return w(B, -re);
1695
1695
  }
1696
- function W(p) {
1697
- const k = p.getFullYear(), x = `${p.getMonth() + 1}`.padStart(2, "0"), N = `${p.getDate()}`.padStart(2, "0");
1698
- return `${k}-${x}-${N}`;
1696
+ function A(b) {
1697
+ const $ = b.getFullYear(), B = `${b.getMonth() + 1}`.padStart(2, "0"), N = `${b.getDate()}`.padStart(2, "0");
1698
+ return `${$}-${B}-${N}`;
1699
1699
  }
1700
- function Q(p, k, x) {
1701
- const N = oe(p).getTime();
1702
- return !!(k && N < k.getTime() || x && N > x.getTime());
1700
+ function ee(b, $, B) {
1701
+ const N = ae(b).getTime();
1702
+ return !!($ && N < $.getTime() || B && N > B.getTime());
1703
1703
  }
1704
- return (p, k) => (m(), h("div", {
1704
+ return (b, $) => (g(), _("div", {
1705
1705
  ref_key: "root",
1706
- ref: u,
1707
- class: E(P.value)
1706
+ ref: v,
1707
+ class: D(R.value)
1708
1708
  }, [
1709
- B("button", {
1709
+ F("button", {
1710
1710
  ref_key: "control",
1711
- ref: d,
1711
+ ref: i,
1712
1712
  class: "vf-datepicker__control",
1713
1713
  type: "button",
1714
- disabled: p.disabled,
1714
+ disabled: b.disabled,
1715
1715
  "aria-expanded": l.value,
1716
1716
  "aria-controls": s,
1717
1717
  "aria-haspopup": "dialog",
1718
- onClick: y,
1718
+ onClick: k,
1719
1719
  onKeydown: [
1720
- q(Y(L, ["prevent"]), ["down"]),
1721
- q(Y(y, ["prevent"]), ["enter"]),
1722
- q(Y(w, ["prevent"]), ["esc"])
1720
+ q(Y(z, ["prevent"]), ["down"]),
1721
+ q(Y(k, ["prevent"]), ["enter"]),
1722
+ q(Y(x, ["prevent"]), ["esc"])
1723
1723
  ],
1724
- onFocus: D,
1725
- onBlur: A
1724
+ onFocus: P,
1725
+ onBlur: W
1726
1726
  }, [
1727
- B("span", {
1728
- class: E(["vf-datepicker__label", { "vf-datepicker__label_placeholder": !f.value }])
1729
- }, M(S.value || p.placeholder), 3),
1730
- k[0] || (k[0] = B("span", {
1727
+ F("span", {
1728
+ class: D(["vf-datepicker__label", { "vf-datepicker__label_placeholder": !u.value }])
1729
+ }, O(C.value || b.placeholder), 3),
1730
+ $[0] || ($[0] = F("span", {
1731
1731
  class: "vf-datepicker__chevron",
1732
1732
  "aria-hidden": "true"
1733
1733
  }, "▾", -1))
1734
1734
  ], 40, ho),
1735
- (m(), le(we, { to: "body" }, [
1736
- ve(B("div", {
1735
+ (g(), le($e, { to: "body" }, [
1736
+ ve(F("div", {
1737
1737
  id: s,
1738
1738
  ref_key: "panel",
1739
1739
  ref: c,
1740
1740
  class: "vf-datepicker__panel",
1741
1741
  role: "dialog",
1742
1742
  "data-placement": n.value,
1743
- onKeydown: q(Y(w, ["prevent"]), ["esc"])
1743
+ onKeydown: q(Y(x, ["prevent"]), ["esc"])
1744
1744
  }, [
1745
- B("div", _o, [
1746
- B("button", {
1745
+ F("div", _o, [
1746
+ F("button", {
1747
1747
  class: "vf-datepicker__nav",
1748
1748
  type: "button",
1749
1749
  "aria-label": "Previous month",
1750
- onClick: z
1750
+ onClick: V
1751
1751
  }, " ‹ "),
1752
- B("span", ko, M(I.value), 1),
1753
- B("button", {
1752
+ F("span", ko, O(M.value), 1),
1753
+ F("button", {
1754
1754
  class: "vf-datepicker__nav",
1755
1755
  type: "button",
1756
1756
  "aria-label": "Next month",
1757
1757
  onClick: K
1758
1758
  }, " › ")
1759
1759
  ]),
1760
- B("div", Co, [
1761
- (m(!0), h(ue, null, Be(T.value, (x) => (m(), h("span", {
1762
- key: x,
1760
+ F("div", Co, [
1761
+ (g(!0), _(se, null, ke(S.value, (B) => (g(), _("span", {
1762
+ key: B,
1763
1763
  class: "vf-datepicker__weekday"
1764
- }, M(x), 1))), 128))
1764
+ }, O(B), 1))), 128))
1765
1765
  ]),
1766
- B("div", wo, [
1767
- (m(!0), h(ue, null, Be(H.value, (x) => (m(), h("button", {
1768
- key: x.key,
1769
- class: E(["vf-datepicker__day", {
1770
- "is-outside": !x.inCurrentMonth,
1771
- "is-selected": x.isSelected,
1772
- "is-today": x.isToday
1766
+ F("div", wo, [
1767
+ (g(!0), _(se, null, ke(H.value, (B) => (g(), _("button", {
1768
+ key: B.key,
1769
+ class: D(["vf-datepicker__day", {
1770
+ "is-outside": !B.inCurrentMonth,
1771
+ "is-selected": B.isSelected,
1772
+ "is-today": B.isToday
1773
1773
  }]),
1774
1774
  type: "button",
1775
- disabled: x.isDisabled,
1776
- "data-date": x.iso,
1777
- onClick: (N) => G(x.date)
1778
- }, M(x.day), 11, $o))), 128))
1775
+ disabled: B.isDisabled,
1776
+ "data-date": B.iso,
1777
+ onClick: (N) => G(B.date)
1778
+ }, O(B.day), 11, $o))), 128))
1779
1779
  ])
1780
1780
  ], 40, yo), [
1781
1781
  [fe, l.value]
@@ -1783,10 +1783,101 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1783
1783
  ]))
1784
1784
  ], 2));
1785
1785
  }
1786
- }), xo = ["checked", "disabled"], Bo = {
1786
+ }), xo = ["disabled"], Bo = ["disabled", "aria-current", "aria-label", "onClick"], zo = ["disabled"], Za = /* @__PURE__ */ U({
1787
+ __name: "pagination",
1788
+ props: {
1789
+ modelValue: { default: 1 },
1790
+ totalItems: { default: 0 },
1791
+ pageSize: { default: 10 },
1792
+ totalPages: { default: void 0 },
1793
+ siblingCount: { default: 1 },
1794
+ boundaryCount: { default: 1 },
1795
+ disabled: { type: Boolean, default: !1 },
1796
+ size: { default: "normal" },
1797
+ variant: { default: "filled" },
1798
+ prevLabel: { default: "Prev" },
1799
+ nextLabel: { default: "Next" },
1800
+ ellipsisLabel: { default: "..." }
1801
+ },
1802
+ emits: ["update:modelValue", "change"],
1803
+ setup(t, { emit: e }) {
1804
+ const r = t, o = e, a = (u, y, m) => Math.min(m, Math.max(y, u)), v = (u, y) => {
1805
+ if (y < u)
1806
+ return [];
1807
+ const m = [];
1808
+ for (let C = u; C <= y; C += 1)
1809
+ m.push(C);
1810
+ return m;
1811
+ }, i = h(() => {
1812
+ if (typeof r.totalPages == "number" && Number.isFinite(r.totalPages))
1813
+ return Math.max(1, Math.floor(r.totalPages));
1814
+ const u = Math.max(1, Math.floor(r.pageSize));
1815
+ return Math.max(1, Math.ceil(Math.max(0, r.totalItems) / u));
1816
+ }), c = h(() => a(Math.floor(r.modelValue), 1, i.value)), l = h(() => c.value <= 1), d = h(() => c.value >= i.value), n = h(() => r.disabled || i.value <= 1), s = h(() => {
1817
+ const u = i.value, y = c.value, m = Math.max(0, Math.floor(r.siblingCount)), C = Math.max(0, Math.floor(r.boundaryCount)), M = m * 2 + C * 2 + 3, S = [];
1818
+ if (u <= M)
1819
+ return v(1, u).map((z) => ({ key: `page-${z}`, type: "page", page: z }));
1820
+ const H = v(1, C), R = v(u - C + 1, u), P = Math.max(Math.min(y - m, u - C - m * 2 - 1), C + 2), W = Math.min(Math.max(y + m, C + m * 2 + 2), u - C - 1);
1821
+ for (const z of H)
1822
+ S.push({ key: `page-${z}`, type: "page", page: z });
1823
+ P > C + 2 ? S.push({ key: "ellipsis-start", type: "ellipsis", page: -1 }) : C + 1 <= u - C && S.push({ key: `page-${C + 1}`, type: "page", page: C + 1 });
1824
+ for (const z of v(P, W))
1825
+ S.push({ key: `page-${z}`, type: "page", page: z });
1826
+ W < u - C - 1 ? S.push({ key: "ellipsis-end", type: "ellipsis", page: -2 }) : u - C > C && S.push({ key: `page-${u - C}`, type: "page", page: u - C });
1827
+ for (const z of R)
1828
+ S.push({ key: `page-${z}`, type: "page", page: z });
1829
+ return S;
1830
+ }), f = h(() => {
1831
+ const u = ["vf-pagination", `vf-pagination_${r.variant}`];
1832
+ return r.size !== "normal" && u.push(`vf-pagination_${r.size}`), r.disabled && u.push("vf-pagination_disabled"), u;
1833
+ }), p = (u, y) => {
1834
+ if (n.value)
1835
+ return;
1836
+ const m = a(u, 1, i.value);
1837
+ m !== r.modelValue && (o("update:modelValue", m), o("change", m, y));
1838
+ };
1839
+ return (u, y) => (g(), _("nav", {
1840
+ class: D(f.value),
1841
+ "aria-label": "Pagination"
1842
+ }, [
1843
+ F("button", {
1844
+ class: "vf-pagination__item vf-pagination__item_nav",
1845
+ type: "button",
1846
+ disabled: n.value || l.value,
1847
+ "aria-label": "Previous page",
1848
+ onClick: y[0] || (y[0] = (m) => p(c.value - 1, m))
1849
+ }, O(u.prevLabel), 9, xo),
1850
+ (g(!0), _(se, null, ke(s.value, (m) => (g(), _("button", {
1851
+ key: m.key,
1852
+ class: D(["vf-pagination__item", {
1853
+ "is-current": m.type === "page" && m.page === c.value,
1854
+ "is-ellipsis": m.type === "ellipsis"
1855
+ }]),
1856
+ type: "button",
1857
+ disabled: n.value || m.type === "ellipsis",
1858
+ "aria-current": m.type === "page" && m.page === c.value ? "page" : void 0,
1859
+ "aria-label": m.type === "page" ? `Page ${m.page}` : void 0,
1860
+ onClick: (C) => m.type === "page" && p(m.page, C)
1861
+ }, [
1862
+ m.type === "page" ? (g(), _(se, { key: 0 }, [
1863
+ Q(O(m.page), 1)
1864
+ ], 64)) : (g(), _(se, { key: 1 }, [
1865
+ Q(O(u.ellipsisLabel), 1)
1866
+ ], 64))
1867
+ ], 10, Bo))), 128)),
1868
+ F("button", {
1869
+ class: "vf-pagination__item vf-pagination__item_nav",
1870
+ type: "button",
1871
+ disabled: n.value || d.value,
1872
+ "aria-label": "Next page",
1873
+ onClick: y[1] || (y[1] = (m) => p(c.value + 1, m))
1874
+ }, O(u.nextLabel), 9, zo)
1875
+ ], 2));
1876
+ }
1877
+ }), Fo = ["checked", "disabled"], So = {
1787
1878
  key: 0,
1788
1879
  class: "vf-checkbox__label"
1789
- }, ja = /* @__PURE__ */ Z({
1880
+ }, Ja = /* @__PURE__ */ U({
1790
1881
  __name: "checkbox",
1791
1882
  props: {
1792
1883
  modelValue: { type: Boolean, default: !1 },
@@ -1796,32 +1887,32 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1796
1887
  },
1797
1888
  emits: ["update:modelValue", "change"],
1798
1889
  setup(t, { emit: e }) {
1799
- const r = e, o = t, a = g(() => {
1800
- const d = ["vf-checkbox", `vf-checkbox_${o.variant}`];
1801
- return o.disabled && d.push("vf-checkbox_disabled"), d;
1802
- }), u = (d) => {
1803
- const c = d.target;
1804
- r("update:modelValue", c.checked), r("change", d);
1890
+ const r = e, o = t, a = h(() => {
1891
+ const i = ["vf-checkbox", `vf-checkbox_${o.variant}`];
1892
+ return o.disabled && i.push("vf-checkbox_disabled"), i;
1893
+ }), v = (i) => {
1894
+ const c = i.target;
1895
+ r("update:modelValue", c.checked), r("change", i);
1805
1896
  };
1806
- return (d, c) => (m(), h("label", {
1807
- class: E(a.value)
1897
+ return (i, c) => (g(), _("label", {
1898
+ class: D(a.value)
1808
1899
  }, [
1809
- B("input", {
1900
+ F("input", {
1810
1901
  class: "vf-checkbox__control",
1811
1902
  type: "checkbox",
1812
- checked: d.modelValue,
1813
- disabled: d.disabled,
1814
- onChange: u
1815
- }, null, 40, xo),
1816
- c[0] || (c[0] = B("span", { class: "vf-checkbox__box" }, null, -1)),
1817
- d.label || d.$slots.default ? (m(), h("span", Bo, [
1818
- F(d.$slots, "default", {}, () => [
1819
- ae(M(d.label), 1)
1903
+ checked: i.modelValue,
1904
+ disabled: i.disabled,
1905
+ onChange: v
1906
+ }, null, 40, Fo),
1907
+ c[0] || (c[0] = F("span", { class: "vf-checkbox__box" }, null, -1)),
1908
+ i.label || i.$slots.default ? (g(), _("span", So, [
1909
+ L(i.$slots, "default", {}, () => [
1910
+ Q(O(i.label), 1)
1820
1911
  ])
1821
- ])) : V("", !0)
1912
+ ])) : T("", !0)
1822
1913
  ], 2));
1823
1914
  }
1824
- }), ot = Symbol("VueForgeRadioGroup"), zo = ["aria-disabled", "aria-label", "aria-labelledby"], Xa = /* @__PURE__ */ Z({
1915
+ }), ot = Symbol("VueForgeRadioGroup"), Vo = ["aria-disabled", "aria-label", "aria-labelledby"], Qa = /* @__PURE__ */ U({
1825
1916
  __name: "radio-group",
1826
1917
  props: {
1827
1918
  modelValue: { type: [String, Number, Boolean, null], default: void 0 },
@@ -1834,32 +1925,32 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1834
1925
  },
1835
1926
  emits: ["update:modelValue", "change"],
1836
1927
  setup(t, { emit: e }) {
1837
- const r = e, o = t, a = g(() => {
1928
+ const r = e, o = t, a = h(() => {
1838
1929
  const c = ["vf-radio-group"];
1839
1930
  return o.direction === "horizontal" && c.push("vf-radio-group_horizontal"), c;
1840
- }), u = (c, l) => {
1931
+ }), v = (c, l) => {
1841
1932
  r("update:modelValue", c), r("change", c, l);
1842
- }, d = {
1843
- name: g(() => o.name),
1844
- modelValue: g(() => o.modelValue),
1845
- disabled: g(() => o.disabled),
1846
- variant: g(() => o.variant),
1847
- onChange: u
1933
+ }, i = {
1934
+ name: h(() => o.name),
1935
+ modelValue: h(() => o.modelValue),
1936
+ disabled: h(() => o.disabled),
1937
+ variant: h(() => o.variant),
1938
+ onChange: v
1848
1939
  };
1849
- return Ze(ot, d), (c, l) => (m(), h("div", {
1850
- class: E(a.value),
1940
+ return Ze(ot, i), (c, l) => (g(), _("div", {
1941
+ class: D(a.value),
1851
1942
  role: "radiogroup",
1852
1943
  "aria-disabled": c.disabled || void 0,
1853
1944
  "aria-label": c.ariaLabel || void 0,
1854
1945
  "aria-labelledby": c.ariaLabelledby || void 0
1855
1946
  }, [
1856
- F(c.$slots, "default")
1857
- ], 10, zo));
1947
+ L(c.$slots, "default")
1948
+ ], 10, Vo));
1858
1949
  }
1859
- }), Fo = ["name", "value", "checked", "disabled"], So = {
1950
+ }), Lo = ["name", "value", "checked", "disabled"], To = {
1860
1951
  key: 0,
1861
1952
  class: "vf-radio__label"
1862
- }, qa = /* @__PURE__ */ Z({
1953
+ }, er = /* @__PURE__ */ U({
1863
1954
  __name: "radio-button",
1864
1955
  props: {
1865
1956
  modelValue: { type: [String, Number, Boolean, null], default: void 0 },
@@ -1871,33 +1962,33 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1871
1962
  },
1872
1963
  emits: ["update:modelValue", "change"],
1873
1964
  setup(t, { emit: e }) {
1874
- const r = e, o = t, a = Me(ot, null), u = g(() => a ? a.modelValue.value : o.modelValue), d = g(() => a ? a.name.value : o.name), c = g(() => a ? a.variant.value : o.variant), l = g(() => (a ? a.disabled.value : !1) || o.disabled), i = g(() => u.value === o.value), n = g(() => {
1875
- const v = ["vf-radio", `vf-radio_${c.value}`];
1876
- return l.value && v.push("vf-radio_disabled"), v;
1877
- }), s = (v) => {
1878
- l.value || (a ? a.onChange(o.value, v) : r("update:modelValue", o.value), r("change", o.value, v));
1965
+ const r = e, o = t, a = We(ot, null), v = h(() => a ? a.modelValue.value : o.modelValue), i = h(() => a ? a.name.value : o.name), c = h(() => a ? a.variant.value : o.variant), l = h(() => (a ? a.disabled.value : !1) || o.disabled), d = h(() => v.value === o.value), n = h(() => {
1966
+ const f = ["vf-radio", `vf-radio_${c.value}`];
1967
+ return l.value && f.push("vf-radio_disabled"), f;
1968
+ }), s = (f) => {
1969
+ l.value || (a ? a.onChange(o.value, f) : r("update:modelValue", o.value), r("change", o.value, f));
1879
1970
  };
1880
- return (v, b) => (m(), h("label", {
1881
- class: E(n.value)
1971
+ return (f, p) => (g(), _("label", {
1972
+ class: D(n.value)
1882
1973
  }, [
1883
- B("input", {
1974
+ F("input", {
1884
1975
  class: "vf-radio__control",
1885
1976
  type: "radio",
1886
- name: d.value,
1887
- value: v.value,
1888
- checked: i.value,
1977
+ name: i.value,
1978
+ value: f.value,
1979
+ checked: d.value,
1889
1980
  disabled: l.value,
1890
1981
  onChange: s
1891
- }, null, 40, Fo),
1892
- b[0] || (b[0] = B("span", { class: "vf-radio__circle" }, null, -1)),
1893
- v.label || v.$slots.default ? (m(), h("span", So, [
1894
- F(v.$slots, "default", {}, () => [
1895
- ae(M(v.label), 1)
1982
+ }, null, 40, Lo),
1983
+ p[0] || (p[0] = F("span", { class: "vf-radio__circle" }, null, -1)),
1984
+ f.label || f.$slots.default ? (g(), _("span", To, [
1985
+ L(f.$slots, "default", {}, () => [
1986
+ Q(O(f.label), 1)
1896
1987
  ])
1897
- ])) : V("", !0)
1988
+ ])) : T("", !0)
1898
1989
  ], 2));
1899
1990
  }
1900
- }), He = Symbol("VueForgeTabs"), Vo = ["aria-orientation", "aria-label", "aria-labelledby"], Lo = { class: "vf-tabs__panels" }, Ua = /* @__PURE__ */ Z({
1991
+ }), He = Symbol("VueForgeTabs"), Ro = ["aria-orientation", "aria-label", "aria-labelledby"], Po = { class: "vf-tabs__panels" }, tr = /* @__PURE__ */ U({
1901
1992
  __name: "tabs",
1902
1993
  props: {
1903
1994
  modelValue: { default: void 0 },
@@ -1909,54 +2000,54 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1909
2000
  emits: ["update:modelValue", "change"],
1910
2001
  setup(t, { emit: e }) {
1911
2002
  let r = 0;
1912
- const o = e, a = t, u = ++r, d = (f) => String(f).toLowerCase().trim().replace(/\s+/g, "-").replace(/[^a-z0-9_-]/g, ""), c = g(() => {
1913
- const f = ["vf-tabs"];
1914
- return a.orientation === "vertical" && f.push("vf-tabs_vertical"), a.disabled && f.push("vf-tabs_disabled"), f;
1915
- }), l = R(null), i = () => l.value ? Array.from(l.value.querySelectorAll('[role="tab"]:not([disabled])')) : [], n = (f) => {
1916
- f && (f.focus(), f.click());
1917
- }, s = (f) => {
2003
+ const o = e, a = t, v = ++r, i = (u) => String(u).toLowerCase().trim().replace(/\s+/g, "-").replace(/[^a-z0-9_-]/g, ""), c = h(() => {
2004
+ const u = ["vf-tabs"];
2005
+ return a.orientation === "vertical" && u.push("vf-tabs_vertical"), a.disabled && u.push("vf-tabs_disabled"), u;
2006
+ }), l = I(null), d = () => l.value ? Array.from(l.value.querySelectorAll('[role="tab"]:not([disabled])')) : [], n = (u) => {
2007
+ u && (u.focus(), u.click());
2008
+ }, s = (u) => {
1918
2009
  if (a.disabled)
1919
2010
  return;
1920
- const C = a.orientation === "horizontal", $ = f.key, S = C ? ["ArrowRight"] : ["ArrowDown"], I = C ? ["ArrowLeft"] : ["ArrowUp"];
1921
- if (![...S, ...I, "Home", "End"].includes($))
2011
+ const y = a.orientation === "horizontal", m = u.key, C = y ? ["ArrowRight"] : ["ArrowDown"], M = y ? ["ArrowLeft"] : ["ArrowUp"];
2012
+ if (![...C, ...M, "Home", "End"].includes(m))
1922
2013
  return;
1923
- const T = i();
1924
- if (!T.length)
2014
+ const S = d();
2015
+ if (!S.length)
1925
2016
  return;
1926
- const H = T.findIndex((L) => L.getAttribute("aria-selected") === "true"), P = T.findIndex((L) => L === document.activeElement), D = P >= 0 ? P : Math.max(H, 0);
1927
- let A = D;
1928
- S.includes($) ? A = (D + 1) % T.length : I.includes($) ? A = (D - 1 + T.length) % T.length : $ === "Home" ? A = 0 : $ === "End" && (A = T.length - 1), f.preventDefault(), n(T[A]);
1929
- }, v = (f, C) => {
1930
- o("update:modelValue", f), o("change", f, C);
1931
- }, b = {
1932
- activeValue: g(() => a.modelValue),
1933
- disabled: g(() => a.disabled),
1934
- orientation: g(() => a.orientation),
1935
- onChange: v,
1936
- getTabId: (f) => `vf-tab-${u}-${d(f)}`,
1937
- getPanelId: (f) => `vf-tabpanel-${u}-${d(f)}`
2017
+ const H = S.findIndex((z) => z.getAttribute("aria-selected") === "true"), R = S.findIndex((z) => z === document.activeElement), P = R >= 0 ? R : Math.max(H, 0);
2018
+ let W = P;
2019
+ C.includes(m) ? W = (P + 1) % S.length : M.includes(m) ? W = (P - 1 + S.length) % S.length : m === "Home" ? W = 0 : m === "End" && (W = S.length - 1), u.preventDefault(), n(S[W]);
2020
+ }, f = (u, y) => {
2021
+ o("update:modelValue", u), o("change", u, y);
2022
+ }, p = {
2023
+ activeValue: h(() => a.modelValue),
2024
+ disabled: h(() => a.disabled),
2025
+ orientation: h(() => a.orientation),
2026
+ onChange: f,
2027
+ getTabId: (u) => `vf-tab-${v}-${i(u)}`,
2028
+ getPanelId: (u) => `vf-tabpanel-${v}-${i(u)}`
1938
2029
  };
1939
- return Ze(He, b), (f, C) => (m(), h("div", {
1940
- class: E(c.value)
2030
+ return Ze(He, p), (u, y) => (g(), _("div", {
2031
+ class: D(c.value)
1941
2032
  }, [
1942
- B("div", {
2033
+ F("div", {
1943
2034
  ref_key: "list",
1944
2035
  ref: l,
1945
2036
  class: "vf-tabs__list",
1946
2037
  role: "tablist",
1947
- "aria-orientation": f.orientation,
1948
- "aria-label": f.ariaLabel || void 0,
1949
- "aria-labelledby": f.ariaLabelledby || void 0,
2038
+ "aria-orientation": u.orientation,
2039
+ "aria-label": u.ariaLabel || void 0,
2040
+ "aria-labelledby": u.ariaLabelledby || void 0,
1950
2041
  onKeydown: s
1951
2042
  }, [
1952
- F(f.$slots, "tabs")
1953
- ], 40, Vo),
1954
- B("div", Lo, [
1955
- F(f.$slots, "panels")
2043
+ L(u.$slots, "tabs")
2044
+ ], 40, Ro),
2045
+ F("div", Po, [
2046
+ L(u.$slots, "panels")
1956
2047
  ])
1957
2048
  ], 2));
1958
2049
  }
1959
- }), To = ["id", "aria-selected", "aria-controls", "disabled", "tabindex"], Za = /* @__PURE__ */ Z({
2050
+ }), Mo = ["id", "aria-selected", "aria-controls", "disabled", "tabindex"], or = /* @__PURE__ */ U({
1960
2051
  __name: "tab",
1961
2052
  props: {
1962
2053
  value: {},
@@ -1965,51 +2056,51 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
1965
2056
  },
1966
2057
  emits: ["change"],
1967
2058
  setup(t, { emit: e }) {
1968
- const r = e, o = t, a = Me(He, null), u = g(() => (a == null ? void 0 : a.activeValue.value) === o.value), d = g(() => ((a == null ? void 0 : a.disabled.value) ?? !1) || o.disabled), c = g(() => a ? a.getTabId(o.value) : void 0), l = g(() => a ? a.getPanelId(o.value) : void 0), i = g(() => d.value ? -1 : u.value ? 0 : -1), n = (s) => {
1969
- !a || d.value || (a.onChange(o.value, s), r("change", o.value, s));
2059
+ const r = e, o = t, a = We(He, null), v = h(() => (a == null ? void 0 : a.activeValue.value) === o.value), i = h(() => ((a == null ? void 0 : a.disabled.value) ?? !1) || o.disabled), c = h(() => a ? a.getTabId(o.value) : void 0), l = h(() => a ? a.getPanelId(o.value) : void 0), d = h(() => i.value ? -1 : v.value ? 0 : -1), n = (s) => {
2060
+ !a || i.value || (a.onChange(o.value, s), r("change", o.value, s));
1970
2061
  };
1971
- return (s, v) => (m(), h("button", {
2062
+ return (s, f) => (g(), _("button", {
1972
2063
  id: c.value,
1973
- class: E(["vf-tab", { "vf-tab_active": u.value, "vf-tab_disabled": d.value }]),
2064
+ class: D(["vf-tab", { "vf-tab_active": v.value, "vf-tab_disabled": i.value }]),
1974
2065
  type: "button",
1975
2066
  role: "tab",
1976
- "aria-selected": u.value,
2067
+ "aria-selected": v.value,
1977
2068
  "aria-controls": l.value,
1978
- disabled: d.value,
1979
- tabindex: i.value,
2069
+ disabled: i.value,
2070
+ tabindex: d.value,
1980
2071
  onClick: n
1981
2072
  }, [
1982
- F(s.$slots, "default", {}, () => [
1983
- ae(M(s.label), 1)
2073
+ L(s.$slots, "default", {}, () => [
2074
+ Q(O(s.label), 1)
1984
2075
  ])
1985
- ], 10, To));
2076
+ ], 10, Mo));
1986
2077
  }
1987
- }), Ro = ["id", "aria-labelledby"], Ja = /* @__PURE__ */ Z({
2078
+ }), Io = ["id", "aria-labelledby"], ar = /* @__PURE__ */ U({
1988
2079
  __name: "tab-panel",
1989
2080
  props: {
1990
2081
  value: {}
1991
2082
  },
1992
2083
  setup(t) {
1993
- const e = t, r = Me(He, null), o = g(() => (r == null ? void 0 : r.activeValue.value) === e.value), a = g(() => r ? r.getTabId(e.value) : void 0), u = g(() => r ? r.getPanelId(e.value) : void 0);
1994
- return (d, c) => ve((m(), h("div", {
1995
- id: u.value,
2084
+ const e = t, r = We(He, null), o = h(() => (r == null ? void 0 : r.activeValue.value) === e.value), a = h(() => r ? r.getTabId(e.value) : void 0), v = h(() => r ? r.getPanelId(e.value) : void 0);
2085
+ return (i, c) => ve((g(), _("div", {
2086
+ id: v.value,
1996
2087
  class: "vf-tab-panel",
1997
2088
  role: "tabpanel",
1998
2089
  tabindex: "0",
1999
2090
  "aria-labelledby": a.value
2000
2091
  }, [
2001
- F(d.$slots, "default")
2002
- ], 8, Ro)), [
2092
+ L(i.$slots, "default")
2093
+ ], 8, Io)), [
2003
2094
  [fe, o.value]
2004
2095
  ]);
2005
2096
  }
2006
- }), Po = ["data-severity"], Io = { class: "vf-toast__body" }, Do = {
2097
+ }), Do = ["data-severity"], Oo = { class: "vf-toast__body" }, Eo = {
2007
2098
  key: 0,
2008
2099
  class: "vf-toast__title"
2009
- }, Oo = {
2100
+ }, Wo = {
2010
2101
  key: 1,
2011
2102
  class: "vf-toast__message"
2012
- }, Qa = /* @__PURE__ */ Z({
2103
+ }, rr = /* @__PURE__ */ U({
2013
2104
  __name: "toast",
2014
2105
  props: {
2015
2106
  modelValue: { type: Boolean, default: !1 },
@@ -2023,82 +2114,82 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2023
2114
  setup(t, { emit: e }) {
2024
2115
  const r = e, o = t;
2025
2116
  let a = null;
2026
- const u = () => {
2117
+ const v = () => {
2027
2118
  a !== null && (clearTimeout(a), a = null);
2028
- }, d = () => {
2029
- u(), !(!o.modelValue || o.duration <= 0) && (a = window.setTimeout(() => {
2119
+ }, i = () => {
2120
+ v(), !(!o.modelValue || o.duration <= 0) && (a = window.setTimeout(() => {
2030
2121
  r("update:modelValue", !1), r("close");
2031
2122
  }, o.duration));
2032
2123
  }, c = () => {
2033
- u(), r("update:modelValue", !1), r("close");
2124
+ v(), r("update:modelValue", !1), r("close");
2034
2125
  };
2035
- return ee(
2126
+ return te(
2036
2127
  () => o.modelValue,
2037
2128
  (l) => {
2038
- l && r("open"), d();
2129
+ l && r("open"), i();
2039
2130
  },
2040
2131
  { immediate: !0 }
2041
- ), Ce(() => {
2042
- u();
2043
- }), (l, i) => ve((m(), h("div", {
2132
+ ), we(() => {
2133
+ v();
2134
+ }), (l, d) => ve((g(), _("div", {
2044
2135
  class: "vf-toast",
2045
2136
  role: "status",
2046
2137
  "aria-live": "polite",
2047
2138
  "data-severity": l.severity
2048
2139
  }, [
2049
- B("div", Io, [
2050
- l.title ? (m(), h("div", Do, M(l.title), 1)) : V("", !0),
2051
- l.message || l.$slots.default ? (m(), h("div", Oo, [
2052
- F(l.$slots, "default", {}, () => [
2053
- ae(M(l.message), 1)
2140
+ F("div", Oo, [
2141
+ l.title ? (g(), _("div", Eo, O(l.title), 1)) : T("", !0),
2142
+ l.message || l.$slots.default ? (g(), _("div", Wo, [
2143
+ L(l.$slots, "default", {}, () => [
2144
+ Q(O(l.message), 1)
2054
2145
  ])
2055
- ])) : V("", !0)
2146
+ ])) : T("", !0)
2056
2147
  ]),
2057
- l.closable ? (m(), h("button", {
2148
+ l.closable ? (g(), _("button", {
2058
2149
  key: 0,
2059
2150
  class: "vf-toast__close",
2060
2151
  type: "button",
2061
2152
  onClick: c
2062
2153
  }, [
2063
- F(l.$slots, "close", {}, () => [
2064
- i[0] || (i[0] = ae("×"))
2154
+ L(l.$slots, "close", {}, () => [
2155
+ d[0] || (d[0] = Q("×"))
2065
2156
  ])
2066
- ])) : V("", !0)
2067
- ], 8, Po)), [
2157
+ ])) : T("", !0)
2158
+ ], 8, Do)), [
2068
2159
  [fe, l.modelValue]
2069
2160
  ]);
2070
2161
  }
2071
- }), er = /* @__PURE__ */ Z({
2162
+ }), lr = /* @__PURE__ */ U({
2072
2163
  __name: "toast-container",
2073
2164
  props: {
2074
2165
  position: { default: "top-right" }
2075
2166
  },
2076
2167
  setup(t) {
2077
- const e = t, r = g(() => `vf-toast-container_${e.position}`);
2078
- return (o, a) => (m(), le(we, { to: "body" }, [
2079
- B("div", {
2080
- class: E(["vf-toast-container", r.value]),
2168
+ const e = t, r = h(() => `vf-toast-container_${e.position}`);
2169
+ return (o, a) => (g(), le($e, { to: "body" }, [
2170
+ F("div", {
2171
+ class: D(["vf-toast-container", r.value]),
2081
2172
  role: "region",
2082
2173
  "aria-live": "polite"
2083
2174
  }, [
2084
- F(o.$slots, "default")
2175
+ L(o.$slots, "default")
2085
2176
  ], 2)
2086
2177
  ]));
2087
2178
  }
2088
- }), Eo = ["data-severity"], Wo = {
2179
+ }), Ho = ["data-severity"], Ao = {
2089
2180
  key: 0,
2090
2181
  class: "vf-alert__icon",
2091
2182
  "aria-hidden": "true"
2092
- }, Mo = { class: "vf-alert__body" }, Ho = {
2183
+ }, Ko = { class: "vf-alert__body" }, No = {
2093
2184
  key: 0,
2094
2185
  class: "vf-alert__title"
2095
- }, Ao = {
2186
+ }, Yo = {
2096
2187
  key: 1,
2097
2188
  class: "vf-alert__message"
2098
- }, Ko = {
2189
+ }, Go = {
2099
2190
  key: 1,
2100
2191
  class: "vf-alert__actions"
2101
- }, tr = /* @__PURE__ */ Z({
2192
+ }, nr = /* @__PURE__ */ U({
2102
2193
  __name: "alert",
2103
2194
  props: {
2104
2195
  modelValue: { type: Boolean },
@@ -2110,8 +2201,8 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2110
2201
  },
2111
2202
  emits: ["update:modelValue", "close"],
2112
2203
  setup(t, { emit: e }) {
2113
- const r = e, o = t, a = R(!0), u = g(() => typeof o.modelValue == "boolean"), d = g(() => u.value ? o.modelValue : a.value);
2114
- ee(
2204
+ const r = e, o = t, a = I(!0), v = h(() => typeof o.modelValue == "boolean"), i = h(() => v.value ? o.modelValue : a.value);
2205
+ te(
2115
2206
  () => o.modelValue,
2116
2207
  (l) => {
2117
2208
  typeof l == "boolean" && (a.value = l);
@@ -2119,52 +2210,52 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2119
2210
  { immediate: !0 }
2120
2211
  );
2121
2212
  const c = () => {
2122
- u.value ? r("update:modelValue", !1) : a.value = !1, r("close");
2213
+ v.value ? r("update:modelValue", !1) : a.value = !1, r("close");
2123
2214
  };
2124
- return (l, i) => ve((m(), h("div", {
2215
+ return (l, d) => ve((g(), _("div", {
2125
2216
  class: "vf-alert",
2126
2217
  role: "alert",
2127
2218
  "data-severity": l.severity
2128
2219
  }, [
2129
- l.$slots.icon || l.icon ? (m(), h("div", Wo, [
2130
- F(l.$slots, "icon", {}, () => [
2131
- ae(M(l.icon), 1)
2220
+ l.$slots.icon || l.icon ? (g(), _("div", Ao, [
2221
+ L(l.$slots, "icon", {}, () => [
2222
+ Q(O(l.icon), 1)
2132
2223
  ])
2133
- ])) : V("", !0),
2134
- B("div", Mo, [
2135
- l.title || l.$slots.title ? (m(), h("div", Ho, [
2136
- F(l.$slots, "title", {}, () => [
2137
- ae(M(l.title), 1)
2224
+ ])) : T("", !0),
2225
+ F("div", Ko, [
2226
+ l.title || l.$slots.title ? (g(), _("div", No, [
2227
+ L(l.$slots, "title", {}, () => [
2228
+ Q(O(l.title), 1)
2138
2229
  ])
2139
- ])) : V("", !0),
2140
- l.message || l.$slots.default ? (m(), h("div", Ao, [
2141
- F(l.$slots, "default", {}, () => [
2142
- ae(M(l.message), 1)
2230
+ ])) : T("", !0),
2231
+ l.message || l.$slots.default ? (g(), _("div", Yo, [
2232
+ L(l.$slots, "default", {}, () => [
2233
+ Q(O(l.message), 1)
2143
2234
  ])
2144
- ])) : V("", !0)
2235
+ ])) : T("", !0)
2145
2236
  ]),
2146
- l.$slots.actions ? (m(), h("div", Ko, [
2147
- F(l.$slots, "actions")
2148
- ])) : V("", !0),
2149
- l.closable ? (m(), h("button", {
2237
+ l.$slots.actions ? (g(), _("div", Go, [
2238
+ L(l.$slots, "actions")
2239
+ ])) : T("", !0),
2240
+ l.closable ? (g(), _("button", {
2150
2241
  key: 2,
2151
2242
  class: "vf-alert__close",
2152
2243
  type: "button",
2153
2244
  "aria-label": "Close",
2154
2245
  onClick: c
2155
2246
  }, [
2156
- F(l.$slots, "close", {}, () => [
2157
- i[0] || (i[0] = ae("×"))
2247
+ L(l.$slots, "close", {}, () => [
2248
+ d[0] || (d[0] = Q("×"))
2158
2249
  ])
2159
- ])) : V("", !0)
2160
- ], 8, Eo)), [
2161
- [fe, d.value]
2250
+ ])) : T("", !0)
2251
+ ], 8, Ho)), [
2252
+ [fe, i.value]
2162
2253
  ]);
2163
2254
  }
2164
- }), No = ["checked", "disabled"], Yo = {
2255
+ }), jo = ["checked", "disabled"], Xo = {
2165
2256
  key: 0,
2166
2257
  class: "vf-switch__label"
2167
- }, or = /* @__PURE__ */ Z({
2258
+ }, sr = /* @__PURE__ */ U({
2168
2259
  __name: "switch",
2169
2260
  props: {
2170
2261
  modelValue: { type: Boolean, default: !1 },
@@ -2173,95 +2264,95 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2173
2264
  },
2174
2265
  emits: ["update:modelValue", "change"],
2175
2266
  setup(t, { emit: e }) {
2176
- const r = e, o = t, a = g(() => {
2177
- const d = ["vf-switch"];
2178
- return o.disabled && d.push("vf-switch_disabled"), d;
2179
- }), u = (d) => {
2180
- const c = d.target;
2181
- r("update:modelValue", c.checked), r("change", d);
2267
+ const r = e, o = t, a = h(() => {
2268
+ const i = ["vf-switch"];
2269
+ return o.disabled && i.push("vf-switch_disabled"), i;
2270
+ }), v = (i) => {
2271
+ const c = i.target;
2272
+ r("update:modelValue", c.checked), r("change", i);
2182
2273
  };
2183
- return (d, c) => (m(), h("label", {
2184
- class: E(a.value)
2274
+ return (i, c) => (g(), _("label", {
2275
+ class: D(a.value)
2185
2276
  }, [
2186
- B("input", {
2277
+ F("input", {
2187
2278
  class: "vf-switch__control",
2188
2279
  type: "checkbox",
2189
- checked: d.modelValue,
2190
- disabled: d.disabled,
2191
- onChange: u
2192
- }, null, 40, No),
2193
- c[0] || (c[0] = B("span", { class: "vf-switch__track" }, [
2194
- B("span", { class: "vf-switch__thumb" })
2280
+ checked: i.modelValue,
2281
+ disabled: i.disabled,
2282
+ onChange: v
2283
+ }, null, 40, jo),
2284
+ c[0] || (c[0] = F("span", { class: "vf-switch__track" }, [
2285
+ F("span", { class: "vf-switch__thumb" })
2195
2286
  ], -1)),
2196
- d.label || d.$slots.default ? (m(), h("span", Yo, [
2197
- F(d.$slots, "default", {}, () => [
2198
- ae(M(d.label), 1)
2287
+ i.label || i.$slots.default ? (g(), _("span", Xo, [
2288
+ L(i.$slots, "default", {}, () => [
2289
+ Q(O(i.label), 1)
2199
2290
  ])
2200
- ])) : V("", !0)
2291
+ ])) : T("", !0)
2201
2292
  ], 2));
2202
2293
  }
2203
- }), Go = { class: "vf-popover" }, jo = ["aria-expanded", "onKeydown"], ar = /* @__PURE__ */ Z({
2294
+ }), qo = { class: "vf-popover" }, Uo = ["aria-expanded", "onKeydown"], ir = /* @__PURE__ */ U({
2204
2295
  __name: "popover",
2205
2296
  emits: ["click", "onClick"],
2206
2297
  setup(t, { expose: e, emit: r }) {
2207
2298
  const o = r, a = lt({ visible: !1 });
2208
- let u = 0;
2209
- const d = `vf-popover-panel-${++u}`, c = () => a.visible = !0, l = () => a.visible = !1, i = () => a.visible = !a.visible, n = () => {
2210
- i(), o("click"), o("onClick");
2299
+ let v = 0;
2300
+ const i = `vf-popover-panel-${++v}`, c = () => a.visible = !0, l = () => a.visible = !1, d = () => a.visible = !a.visible, n = () => {
2301
+ d(), o("click"), o("onClick");
2211
2302
  };
2212
- return e({ show: c, hide: l, toggle: i }), (s, v) => (m(), h("div", Go, [
2213
- B("div", {
2303
+ return e({ show: c, hide: l, toggle: d }), (s, f) => (g(), _("div", qo, [
2304
+ F("div", {
2214
2305
  class: "vf-popover__button",
2215
2306
  role: "button",
2216
2307
  tabindex: "0",
2217
2308
  "aria-haspopup": "dialog",
2218
2309
  "aria-expanded": a.visible,
2219
- "aria-controls": d,
2310
+ "aria-controls": i,
2220
2311
  onClick: n,
2221
2312
  onKeydown: [
2222
2313
  q(Y(n, ["prevent"]), ["enter"]),
2223
2314
  q(Y(n, ["prevent"]), ["space"])
2224
2315
  ]
2225
2316
  }, [
2226
- F(s.$slots, "button")
2227
- ], 40, jo),
2317
+ L(s.$slots, "button")
2318
+ ], 40, Uo),
2228
2319
  ve(qe(ht, {
2229
- id: d,
2320
+ id: i,
2230
2321
  class: "vf-popover__wrapper"
2231
2322
  }, nt({
2232
2323
  default: ye(() => [
2233
- v[0] || (v[0] = B("div", { class: "vf-popover__arrow" }, null, -1))
2324
+ f[0] || (f[0] = F("div", { class: "vf-popover__arrow" }, null, -1))
2234
2325
  ]),
2235
2326
  _: 2
2236
2327
  }, [
2237
2328
  s.$slots.default ? {
2238
2329
  name: "default",
2239
2330
  fn: ye(() => [
2240
- F(s.$slots, "default")
2331
+ L(s.$slots, "default")
2241
2332
  ]),
2242
2333
  key: "0"
2243
2334
  } : void 0,
2244
2335
  s.$slots.header || s.$slots.popoverHeader ? {
2245
2336
  name: "header",
2246
2337
  fn: ye(() => [
2247
- F(s.$slots, "header"),
2248
- s.$slots.header ? V("", !0) : F(s.$slots, "popoverHeader", { key: 0 })
2338
+ L(s.$slots, "header"),
2339
+ s.$slots.header ? T("", !0) : L(s.$slots, "popoverHeader", { key: 0 })
2249
2340
  ]),
2250
2341
  key: "1"
2251
2342
  } : void 0,
2252
2343
  s.$slots.body || s.$slots.popoverBody ? {
2253
2344
  name: "body",
2254
2345
  fn: ye(() => [
2255
- F(s.$slots, "body"),
2256
- s.$slots.body ? V("", !0) : F(s.$slots, "popoverBody", { key: 0 })
2346
+ L(s.$slots, "body"),
2347
+ s.$slots.body ? T("", !0) : L(s.$slots, "popoverBody", { key: 0 })
2257
2348
  ]),
2258
2349
  key: "2"
2259
2350
  } : void 0,
2260
2351
  s.$slots.footer || s.$slots.popoverFooter ? {
2261
2352
  name: "footer",
2262
2353
  fn: ye(() => [
2263
- F(s.$slots, "footer"),
2264
- s.$slots.footer ? V("", !0) : F(s.$slots, "popoverFooter", { key: 0 })
2354
+ L(s.$slots, "footer"),
2355
+ s.$slots.footer ? T("", !0) : L(s.$slots, "popoverFooter", { key: 0 })
2265
2356
  ]),
2266
2357
  key: "3"
2267
2358
  } : void 0
@@ -2270,16 +2361,16 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2270
2361
  ])
2271
2362
  ]));
2272
2363
  }
2273
- }), Xo = ["aria-labelledby", "aria-describedby"], qo = {
2364
+ }), Zo = ["aria-labelledby", "aria-describedby"], Jo = {
2274
2365
  key: 0,
2275
2366
  class: "vf-modal__header"
2276
- }, Uo = {
2367
+ }, Qo = {
2277
2368
  key: 0,
2278
2369
  class: "vf-modal__title"
2279
- }, Zo = {
2370
+ }, ea = {
2280
2371
  key: 3,
2281
2372
  class: "vf-modal__footer"
2282
- }, rr = /* @__PURE__ */ Z({
2373
+ }, dr = /* @__PURE__ */ U({
2283
2374
  __name: "modal",
2284
2375
  props: {
2285
2376
  modelValue: { type: Boolean, default: !1 },
@@ -2293,111 +2384,111 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2293
2384
  emits: ["update:modelValue", "open", "close"],
2294
2385
  setup(t, { expose: e, emit: r }) {
2295
2386
  const o = r, a = t;
2296
- let u = 0, d = 0, c = "", l = null;
2297
- const i = R(null), n = Ue(), s = `vf-modal-title-${++u}`, v = `vf-modal-body-${u}`, b = g(() => !!a.title || !!n.header), f = g(() => !!n.body || !!n.default), C = g(() => {
2298
- const w = ["vf-modal"];
2299
- return a.size !== "md" && w.push(`vf-modal_${a.size}`), w;
2300
- }), $ = () => o("update:modelValue", !0), S = () => {
2387
+ let v = 0, i = 0, c = "", l = null;
2388
+ const d = I(null), n = Ue(), s = `vf-modal-title-${++v}`, f = `vf-modal-body-${v}`, p = h(() => !!a.title || !!n.header), u = h(() => !!n.body || !!n.default), y = h(() => {
2389
+ const x = ["vf-modal"];
2390
+ return a.size !== "md" && x.push(`vf-modal_${a.size}`), x;
2391
+ }), m = () => o("update:modelValue", !0), C = () => {
2301
2392
  o("update:modelValue", !1), o("close");
2302
- }, I = () => {
2303
- a.closeOnOverlay && S();
2304
- }, T = (w) => {
2305
- !a.modelValue || !a.closeOnEsc || w.key === "Escape" && (w.preventDefault(), S());
2306
- }, H = () => i.value ? Array.from(i.value.querySelectorAll('a[href],button:not([disabled]),textarea:not([disabled]),input:not([disabled]),select:not([disabled]),[tabindex]:not([tabindex="-1"])')).filter((y) => !y.hasAttribute("disabled") && !y.getAttribute("aria-hidden")) : [], P = () => {
2307
- var y;
2308
- const w = H();
2309
- w.length ? w[0].focus() : (y = i.value) == null || y.focus();
2310
- }, D = (w) => {
2393
+ }, M = () => {
2394
+ a.closeOnOverlay && C();
2395
+ }, S = (x) => {
2396
+ !a.modelValue || !a.closeOnEsc || x.key === "Escape" && (x.preventDefault(), C());
2397
+ }, H = () => d.value ? Array.from(d.value.querySelectorAll('a[href],button:not([disabled]),textarea:not([disabled]),input:not([disabled]),select:not([disabled]),[tabindex]:not([tabindex="-1"])')).filter((k) => !k.hasAttribute("disabled") && !k.getAttribute("aria-hidden")) : [], R = () => {
2398
+ var k;
2399
+ const x = H();
2400
+ x.length ? x[0].focus() : (k = d.value) == null || k.focus();
2401
+ }, P = (x) => {
2311
2402
  var j;
2312
- if (w.key !== "Tab")
2403
+ if (x.key !== "Tab")
2313
2404
  return;
2314
- const y = H();
2315
- if (!y.length) {
2316
- w.preventDefault(), (j = i.value) == null || j.focus();
2405
+ const k = H();
2406
+ if (!k.length) {
2407
+ x.preventDefault(), (j = d.value) == null || j.focus();
2317
2408
  return;
2318
2409
  }
2319
- const z = y[0], K = y[y.length - 1], G = document.activeElement;
2320
- if (w.shiftKey && G === z) {
2321
- w.preventDefault(), K.focus();
2410
+ const V = k[0], K = k[k.length - 1], G = document.activeElement;
2411
+ if (x.shiftKey && G === V) {
2412
+ x.preventDefault(), K.focus();
2322
2413
  return;
2323
2414
  }
2324
- !w.shiftKey && G === K && (w.preventDefault(), z.focus());
2325
- }, A = () => {
2326
- !a.lockScroll || typeof document > "u" || (d === 0 && (c = document.body.style.overflow, document.body.style.overflow = "hidden"), d += 1);
2327
- }, L = () => {
2328
- !a.lockScroll || typeof document > "u" || (d = Math.max(0, d - 1), d === 0 && (document.body.style.overflow = c));
2415
+ !x.shiftKey && G === K && (x.preventDefault(), V.focus());
2416
+ }, W = () => {
2417
+ !a.lockScroll || typeof document > "u" || (i === 0 && (c = document.body.style.overflow, document.body.style.overflow = "hidden"), i += 1);
2418
+ }, z = () => {
2419
+ !a.lockScroll || typeof document > "u" || (i = Math.max(0, i - 1), i === 0 && (document.body.style.overflow = c));
2329
2420
  };
2330
- return ee(
2421
+ return te(
2331
2422
  () => a.modelValue,
2332
- async (w) => {
2333
- w ? (typeof document < "u" && (l = document.activeElement), A(), o("open"), await ke(), P(), typeof document < "u" && document.addEventListener("keydown", T)) : (L(), typeof document < "u" && (document.removeEventListener("keydown", T), l == null || l.focus()));
2423
+ async (x) => {
2424
+ x ? (typeof document < "u" && (l = document.activeElement), W(), o("open"), await Ce(), R(), typeof document < "u" && document.addEventListener("keydown", S)) : (z(), typeof document < "u" && (document.removeEventListener("keydown", S), l == null || l.focus()));
2334
2425
  },
2335
2426
  { immediate: !0 }
2336
- ), Ce(() => {
2337
- L(), typeof document < "u" && document.removeEventListener("keydown", T);
2338
- }), e({ open: $, close: S }), (w, y) => (m(), le(we, { to: "body" }, [
2339
- ve(B("div", {
2340
- class: E(C.value),
2427
+ ), we(() => {
2428
+ z(), typeof document < "u" && document.removeEventListener("keydown", S);
2429
+ }), e({ open: m, close: C }), (x, k) => (g(), le($e, { to: "body" }, [
2430
+ ve(F("div", {
2431
+ class: D(y.value),
2341
2432
  role: "presentation"
2342
2433
  }, [
2343
- B("div", {
2434
+ F("div", {
2344
2435
  class: "vf-modal__overlay",
2345
- onClick: I
2436
+ onClick: M
2346
2437
  }),
2347
- B("div", {
2438
+ F("div", {
2348
2439
  ref_key: "panel",
2349
- ref: i,
2440
+ ref: d,
2350
2441
  class: "vf-modal__panel",
2351
2442
  role: "dialog",
2352
2443
  "aria-modal": "true",
2353
- "aria-labelledby": b.value ? s : void 0,
2354
- "aria-describedby": f.value ? v : void 0,
2444
+ "aria-labelledby": p.value ? s : void 0,
2445
+ "aria-describedby": u.value ? f : void 0,
2355
2446
  tabindex: "-1",
2356
- onKeydown: D
2447
+ onKeydown: P
2357
2448
  }, [
2358
- b.value ? (m(), h("div", qo, [
2359
- B("div", {
2449
+ p.value ? (g(), _("div", Jo, [
2450
+ F("div", {
2360
2451
  id: s,
2361
2452
  class: "vf-modal__header-content"
2362
2453
  }, [
2363
- F(w.$slots, "header", {}, () => [
2364
- w.title ? (m(), h("h3", Uo, M(w.title), 1)) : V("", !0)
2454
+ L(x.$slots, "header", {}, () => [
2455
+ x.title ? (g(), _("h3", Qo, O(x.title), 1)) : T("", !0)
2365
2456
  ])
2366
2457
  ])
2367
- ])) : V("", !0),
2368
- w.showClose ? F(w.$slots, "close", {
2458
+ ])) : T("", !0),
2459
+ x.showClose ? L(x.$slots, "close", {
2369
2460
  key: 1,
2370
- close: S
2461
+ close: C
2371
2462
  }, () => [
2372
- B("button", {
2463
+ F("button", {
2373
2464
  type: "button",
2374
2465
  class: "vf-modal__close",
2375
2466
  "aria-label": "Close",
2376
- onClick: S
2467
+ onClick: C
2377
2468
  }, "×")
2378
- ]) : V("", !0),
2379
- w.$slots.body || w.$slots.default ? (m(), h("div", {
2469
+ ]) : T("", !0),
2470
+ x.$slots.body || x.$slots.default ? (g(), _("div", {
2380
2471
  key: 2,
2381
- id: v,
2472
+ id: f,
2382
2473
  class: "vf-modal__body"
2383
2474
  }, [
2384
- F(w.$slots, "body"),
2385
- w.$slots.body ? V("", !0) : F(w.$slots, "default", { key: 0 })
2386
- ])) : V("", !0),
2387
- w.$slots.footer ? (m(), h("div", Zo, [
2388
- F(w.$slots, "footer")
2389
- ])) : V("", !0)
2390
- ], 40, Xo)
2475
+ L(x.$slots, "body"),
2476
+ x.$slots.body ? T("", !0) : L(x.$slots, "default", { key: 0 })
2477
+ ])) : T("", !0),
2478
+ x.$slots.footer ? (g(), _("div", ea, [
2479
+ L(x.$slots, "footer")
2480
+ ])) : T("", !0)
2481
+ ], 40, Zo)
2391
2482
  ], 2), [
2392
- [fe, w.modelValue]
2483
+ [fe, x.modelValue]
2393
2484
  ])
2394
2485
  ]));
2395
2486
  }
2396
- }), Jo = ["data-placement"], Qo = { class: "vf-tooltip__content" }, ea = {
2487
+ }), ta = ["data-placement"], oa = { class: "vf-tooltip__content" }, aa = {
2397
2488
  key: 0,
2398
2489
  class: "vf-tooltip__arrow",
2399
2490
  "aria-hidden": "true"
2400
- }, lr = /* @__PURE__ */ Z({
2491
+ }, cr = /* @__PURE__ */ U({
2401
2492
  __name: "tooltip",
2402
2493
  props: {
2403
2494
  text: { default: "" },
@@ -2408,93 +2499,93 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2408
2499
  setup(t) {
2409
2500
  const e = t;
2410
2501
  let r = 0;
2411
- const o = R(null), a = R(null), u = R(!1), d = R("top"), c = `vf-tooltip-${++r}`;
2502
+ const o = I(null), a = I(null), v = I(!1), i = I("top"), c = `vf-tooltip-${++r}`;
2412
2503
  let l = null;
2413
- const i = () => {
2414
- e.disabled || (u.value = !0);
2504
+ const d = () => {
2505
+ e.disabled || (v.value = !0);
2415
2506
  }, n = () => {
2416
- u.value = !1;
2507
+ v.value = !1;
2417
2508
  }, s = () => {
2418
2509
  if (!o.value || !a.value)
2419
2510
  return;
2420
- const b = o.value, f = a.value, C = async () => {
2511
+ const p = o.value, u = a.value, y = async () => {
2421
2512
  const {
2422
- x: T,
2513
+ x: S,
2423
2514
  y: H,
2424
- placement: P
2425
- } = await Te(b, f, {
2515
+ placement: R
2516
+ } = await Te(p, u, {
2426
2517
  placement: e.placement,
2427
2518
  strategy: "fixed",
2428
- middleware: [Ve(8), Se(), It()]
2519
+ middleware: [Ve(8), Se(), Mt()]
2429
2520
  });
2430
- d.value = P ?? e.placement, f.style.left = `${T}px`, f.style.top = `${H}px`;
2431
- }, $ = async () => {
2432
- await C();
2433
- }, S = Le(b, () => {
2434
- $();
2435
- }), I = () => {
2436
- $();
2521
+ i.value = R ?? e.placement, u.style.left = `${S}px`, u.style.top = `${H}px`;
2522
+ }, m = async () => {
2523
+ await y();
2524
+ }, C = Le(p, () => {
2525
+ m();
2526
+ }), M = () => {
2527
+ m();
2437
2528
  };
2438
- document.addEventListener("scroll", I, !0), window.addEventListener("resize", I, !1), l = {
2439
- update: $,
2529
+ document.addEventListener("scroll", M, !0), window.addEventListener("resize", M, !1), l = {
2530
+ update: m,
2440
2531
  destroy: () => {
2441
- S(), document.removeEventListener("scroll", I, !0), window.removeEventListener("resize", I, !1);
2532
+ C(), document.removeEventListener("scroll", M, !0), window.removeEventListener("resize", M, !1);
2442
2533
  }
2443
2534
  }, l.update();
2444
2535
  };
2445
- ee(u, async (b) => {
2446
- if (!b) {
2536
+ te(v, async (p) => {
2537
+ if (!p) {
2447
2538
  l && (l.destroy(), l = null);
2448
2539
  return;
2449
2540
  }
2450
2541
  l || s(), l == null || l.update();
2451
2542
  }), Fe(() => {
2452
- u.value && s();
2453
- }), Ce(() => {
2543
+ v.value && s();
2544
+ }), we(() => {
2454
2545
  l == null || l.destroy(), l = null;
2455
2546
  });
2456
- const v = g(() => !!e.text || !!(a.value && a.value.textContent));
2457
- return ee(v, (b) => {
2458
- b || (u.value = !1);
2459
- }), (b, f) => (m(), h(ue, null, [
2460
- B("span", {
2547
+ const f = h(() => !!e.text || !!(a.value && a.value.textContent));
2548
+ return te(f, (p) => {
2549
+ p || (v.value = !1);
2550
+ }), (p, u) => (g(), _(se, null, [
2551
+ F("span", {
2461
2552
  ref_key: "trigger",
2462
2553
  ref: o,
2463
2554
  class: "vf-tooltip__trigger",
2464
2555
  "aria-describedby": c,
2465
- onMouseenter: i,
2556
+ onMouseenter: d,
2466
2557
  onMouseleave: n,
2467
- onFocus: i,
2558
+ onFocus: d,
2468
2559
  onBlur: n
2469
2560
  }, [
2470
- F(b.$slots, "default")
2561
+ L(p.$slots, "default")
2471
2562
  ], 544),
2472
- (m(), le(we, { to: "body" }, [
2473
- ve(B("div", {
2563
+ (g(), le($e, { to: "body" }, [
2564
+ ve(F("div", {
2474
2565
  id: c,
2475
2566
  ref_key: "panel",
2476
2567
  ref: a,
2477
2568
  class: "vf-tooltip",
2478
2569
  role: "tooltip",
2479
- "data-placement": d.value
2570
+ "data-placement": i.value
2480
2571
  }, [
2481
- B("span", Qo, [
2482
- F(b.$slots, "content", {}, () => [
2483
- ae(M(b.text), 1)
2572
+ F("span", oa, [
2573
+ L(p.$slots, "content", {}, () => [
2574
+ Q(O(p.text), 1)
2484
2575
  ])
2485
2576
  ]),
2486
- b.arrow ? (m(), h("span", ea)) : V("", !0)
2487
- ], 8, Jo), [
2488
- [fe, u.value]
2577
+ p.arrow ? (g(), _("span", aa)) : T("", !0)
2578
+ ], 8, ta), [
2579
+ [fe, v.value]
2489
2580
  ])
2490
2581
  ]))
2491
2582
  ], 64));
2492
2583
  }
2493
- }), ta = ["dark", "light", "theme", "preset", "colors", "components", "colorScheme"], oa = (t) => {
2584
+ }), ra = ["dark", "light", "theme", "preset", "colors", "components", "colorScheme"], la = (t) => {
2494
2585
  const e = t.replace(/([A-Z])/g, "-$1");
2495
2586
  return e.charAt(0).toUpperCase() + e.slice(1);
2496
- }, aa = (t) => t.filter((e) => !ta.includes(e)).map((e) => oa(e)).join("-").toLowerCase(), We = (t) => t.join("."), ra = (t) => /^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/.test(t), Ae = (t) => {
2497
- if (!ra(t))
2587
+ }, na = (t) => t.filter((e) => !ra.includes(e)).map((e) => la(e)).join("-").toLowerCase(), Ee = (t) => t.join("."), sa = (t) => /^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/.test(t), Ae = (t) => {
2588
+ if (!sa(t))
2498
2589
  return null;
2499
2590
  if (t.length === 4) {
2500
2591
  const e = t[1], r = t[2], o = t[3];
@@ -2505,55 +2596,55 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2505
2596
  const e = Ae(t);
2506
2597
  if (!e)
2507
2598
  return [0, 0, 0];
2508
- const r = parseInt(e.slice(1), 16), o = r >> 16 & 255, a = r >> 8 & 255, u = r & 255;
2509
- return [o, a, u];
2599
+ const r = parseInt(e.slice(1), 16), o = r >> 16 & 255, a = r >> 8 & 255, v = r & 255;
2600
+ return [o, a, v];
2510
2601
  }, Ge = (t) => {
2511
2602
  const [e, r, o] = at(t);
2512
2603
  return `${e}, ${r}, ${o}`;
2513
- }, la = (t, e, r) => {
2514
- const o = t / 255, a = e / 255, u = r / 255, d = Math.max(o, a, u), c = Math.min(o, a, u), l = d - c;
2515
- let i = 0, n = 0;
2516
- const s = (d + c) / 2;
2604
+ }, ia = (t, e, r) => {
2605
+ const o = t / 255, a = e / 255, v = r / 255, i = Math.max(o, a, v), c = Math.min(o, a, v), l = i - c;
2606
+ let d = 0, n = 0;
2607
+ const s = (i + c) / 2;
2517
2608
  if (l !== 0) {
2518
- switch (n = l / (1 - Math.abs(2 * s - 1)), d) {
2609
+ switch (n = l / (1 - Math.abs(2 * s - 1)), i) {
2519
2610
  case o:
2520
- i = (a - u) / l % 6;
2611
+ d = (a - v) / l % 6;
2521
2612
  break;
2522
2613
  case a:
2523
- i = (u - o) / l + 2;
2614
+ d = (v - o) / l + 2;
2524
2615
  break;
2525
- case u:
2526
- i = (o - a) / l + 4;
2616
+ case v:
2617
+ d = (o - a) / l + 4;
2527
2618
  break;
2528
2619
  }
2529
- i *= 60, i < 0 && (i += 360);
2620
+ d *= 60, d < 0 && (d += 360);
2530
2621
  }
2531
- return [i, n * 100, s * 100];
2532
- }, na = (t, e, r) => {
2533
- const o = e / 100, a = r / 100, u = (1 - Math.abs(2 * a - 1)) * o, d = u * (1 - Math.abs(t / 60 % 2 - 1)), c = a - u / 2;
2534
- let l = 0, i = 0, n = 0;
2535
- t >= 0 && t < 60 ? (l = u, i = d, n = 0) : t >= 60 && t < 120 ? (l = d, i = u, n = 0) : t >= 120 && t < 180 ? (l = 0, i = u, n = d) : t >= 180 && t < 240 ? (l = 0, i = d, n = u) : t >= 240 && t < 300 ? (l = d, i = 0, n = u) : (l = u, i = 0, n = d);
2536
- const s = Math.round((l + c) * 255), v = Math.round((i + c) * 255), b = Math.round((n + c) * 255);
2537
- return [s, v, b];
2538
- }, sa = (t, e, r) => `#${[t, e, r].map((o) => o.toString(16).padStart(2, "0")).join("")}`, ia = (t, e, r) => Math.min(r, Math.max(e, t)), da = (t, e) => {
2622
+ return [d, n * 100, s * 100];
2623
+ }, da = (t, e, r) => {
2624
+ const o = e / 100, a = r / 100, v = (1 - Math.abs(2 * a - 1)) * o, i = v * (1 - Math.abs(t / 60 % 2 - 1)), c = a - v / 2;
2625
+ let l = 0, d = 0, n = 0;
2626
+ t >= 0 && t < 60 ? (l = v, d = i, n = 0) : t >= 60 && t < 120 ? (l = i, d = v, n = 0) : t >= 120 && t < 180 ? (l = 0, d = v, n = i) : t >= 180 && t < 240 ? (l = 0, d = i, n = v) : t >= 240 && t < 300 ? (l = i, d = 0, n = v) : (l = v, d = 0, n = i);
2627
+ const s = Math.round((l + c) * 255), f = Math.round((d + c) * 255), p = Math.round((n + c) * 255);
2628
+ return [s, f, p];
2629
+ }, ca = (t, e, r) => `#${[t, e, r].map((o) => o.toString(16).padStart(2, "0")).join("")}`, ua = (t, e, r) => Math.min(r, Math.max(e, t)), va = (t, e) => {
2539
2630
  const r = Ae(t);
2540
2631
  if (!r)
2541
2632
  return t;
2542
- const [o, a, u] = at(r), [d, c, l] = la(o, a, u), n = (e - 5) * 7, s = ia(l + n, 0, 100), [v, b, f] = na(d, c, s);
2543
- return sa(v, b, f);
2544
- }, De = (t) => !!t && typeof t == "object" && !Array.isArray(t), Ke = (t, e) => {
2633
+ const [o, a, v] = at(r), [i, c, l] = ia(o, a, v), n = (e - 5) * 7, s = ua(l + n, 0, 100), [f, p, u] = da(i, c, s);
2634
+ return ca(f, p, u);
2635
+ }, Ie = (t) => !!t && typeof t == "object" && !Array.isArray(t), Ke = (t, e) => {
2545
2636
  if (!e)
2546
2637
  return { ...t };
2547
2638
  const r = { ...t };
2548
2639
  for (const o in e) {
2549
- const a = e[o], u = t[o];
2550
- De(u) && De(a) ? r[o] = Ke(u, a) : r[o] = a;
2640
+ const a = e[o], v = t[o];
2641
+ Ie(v) && Ie(a) ? r[o] = Ke(v, a) : r[o] = a;
2551
2642
  }
2552
2643
  return r;
2553
- }, ca = (t) => {
2644
+ }, fa = (t) => {
2554
2645
  if (!t)
2555
2646
  return null;
2556
- if (De(t) && "preset" in t) {
2647
+ if (Ie(t) && "preset" in t) {
2557
2648
  const e = t;
2558
2649
  return {
2559
2650
  preset: e.preset ?? {},
@@ -2564,42 +2655,42 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2564
2655
  };
2565
2656
  }
2566
2657
  return { preset: t };
2567
- }, ua = (t) => {
2568
- const e = [], r = [], o = [], a = [], u = (l) => o.push(l), d = (l) => a.push(l), c = (l, i) => {
2658
+ }, pa = (t) => {
2659
+ const e = [], r = [], o = [], a = [], v = (l) => o.push(l), i = (l) => a.push(l), c = (l, d) => {
2569
2660
  if (!(!l || typeof l != "object"))
2570
2661
  for (const n in l) {
2571
- const s = l[n], v = i.concat([n]);
2572
- if (De(s)) {
2573
- c(s, v);
2662
+ const s = l[n], f = d.concat([n]);
2663
+ if (Ie(s)) {
2664
+ c(s, f);
2574
2665
  continue;
2575
2666
  }
2576
2667
  if (s && typeof s == "object") {
2577
- d(`Theme value "${We(v)}" is not a plain object or string and will be ignored.`);
2668
+ i(`Theme value "${Ee(f)}" is not a plain object or string and will be ignored.`);
2578
2669
  continue;
2579
2670
  }
2580
2671
  if (typeof s != "string") {
2581
- d(`Theme value "${We(v)}" is not a string and will be ignored.`);
2672
+ i(`Theme value "${Ee(f)}" is not a string and will be ignored.`);
2582
2673
  continue;
2583
2674
  }
2584
- const f = v.includes("colorScheme") && v.includes("dark") ? r : e, C = aa(v);
2585
- if (f.push(`--vf-${C}: ${s}`), v.includes("colors")) {
2586
- const $ = Ae(s);
2587
- if (!$) {
2588
- u(
2589
- `Theme color "${We(v)}" is not hex. Shade variables will not be generated for it.`
2675
+ const u = f.includes("colorScheme") && f.includes("dark") ? r : e, y = na(f);
2676
+ if (u.push(`--vf-${y}: ${s}`), f.includes("colors")) {
2677
+ const m = Ae(s);
2678
+ if (!m) {
2679
+ v(
2680
+ `Theme color "${Ee(f)}" is not hex. Shade variables will not be generated for it.`
2590
2681
  );
2591
2682
  continue;
2592
2683
  }
2593
- if (f.push(`--vf-${C}-rgb: ${Ge($)}`), n !== "white")
2594
- for (let S = 1; S < 10; ++S) {
2595
- const I = da($, S);
2596
- f.push(`--vf-${C}-${S}00: ${I}`), f.push(`--vf-${C}-${S}00-rgb: ${Ge(I)}`);
2684
+ if (u.push(`--vf-${y}-rgb: ${Ge(m)}`), n !== "white")
2685
+ for (let C = 1; C < 10; ++C) {
2686
+ const M = va(m, C);
2687
+ u.push(`--vf-${y}-${C}00: ${M}`), u.push(`--vf-${y}-${C}00-rgb: ${Ge(M)}`);
2597
2688
  }
2598
2689
  }
2599
2690
  }
2600
2691
  };
2601
2692
  return c(t, []), { baseVars: e, darkVars: r, warnings: o, errors: a };
2602
- }, va = (t) => {
2693
+ }, ba = (t) => {
2603
2694
  if (typeof document > "u")
2604
2695
  return null;
2605
2696
  const e = document.getElementById(t);
@@ -2607,11 +2698,11 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2607
2698
  return e;
2608
2699
  const r = document.createElement("style");
2609
2700
  return r.id = t, document.head.appendChild(r), r;
2610
- }, fa = (t) => ({
2701
+ }, ga = (t) => ({
2611
2702
  selector: t.selector ?? ":root",
2612
2703
  darkSelector: t.darkSelector ?? ":root[data-theme=dark]"
2613
- }), pa = (t, e, r, o) => {
2614
- const { baseVars: a, darkVars: u, warnings: d, errors: c } = ua(t), l = va("vueforge-theme");
2704
+ }), ma = (t, e, r, o) => {
2705
+ const { baseVars: a, darkVars: v, warnings: i, errors: c } = pa(t), l = ba("vueforge-theme");
2615
2706
  if (!l)
2616
2707
  return;
2617
2708
  if (c.length) {
@@ -2620,31 +2711,31 @@ const Rt = (t, e) => t.strategy ? t.strategy : Tt(e) ? "fixed" : "absolute", ge
2620
2711
  for (const n of c)
2621
2712
  console.warn(`[VueForge] ${n}`);
2622
2713
  }
2623
- if (d.length)
2624
- for (const n of d)
2714
+ if (i.length)
2715
+ for (const n of i)
2625
2716
  console.warn(`[VueForge] ${n}`);
2626
- const i = [];
2627
- a.length && i.push(`${e} { ${a.join(";")} }`), u.length && i.push(`${r} { ${u.join(";")} }`), l.textContent = i.join(`
2717
+ const d = [];
2718
+ a.length && d.push(`${e} { ${a.join(";")} }`), v.length && d.push(`${r} { ${v.join(";")} }`), l.textContent = d.join(`
2628
2719
  `);
2629
2720
  };
2630
- let me = null;
2721
+ let ge = null;
2631
2722
  const rt = (t) => {
2632
- const e = ca(t);
2723
+ const e = fa(t);
2633
2724
  if (!e)
2634
2725
  return;
2635
- const r = Ke(e.preset, e.overrides), { selector: o, darkSelector: a } = fa(e);
2636
- me = { ...e }, pa(r, o, a, e.strict);
2637
- }, nr = (t) => {
2638
- if (!me)
2726
+ const r = Ke(e.preset, e.overrides), { selector: o, darkSelector: a } = ga(e);
2727
+ ge = { ...e }, ma(r, o, a, e.strict);
2728
+ }, ur = (t) => {
2729
+ if (!ge)
2639
2730
  return;
2640
- const e = t.overrides === void 0 ? me.overrides : Ke(me.overrides ?? {}, t.overrides ?? {}), r = {
2641
- preset: t.preset ?? me.preset,
2731
+ const e = t.overrides === void 0 ? ge.overrides : Ke(ge.overrides ?? {}, t.overrides ?? {}), r = {
2732
+ preset: t.preset ?? ge.preset,
2642
2733
  overrides: e,
2643
- selector: t.selector ?? me.selector,
2644
- darkSelector: t.darkSelector ?? me.darkSelector
2734
+ selector: t.selector ?? ge.selector,
2735
+ darkSelector: t.darkSelector ?? ge.darkSelector
2645
2736
  };
2646
2737
  rt(r);
2647
- }, sr = () => me ? { ...me } : null, ir = {
2738
+ }, vr = () => ge ? { ...ge } : null, fr = {
2648
2739
  install(t, e = {}) {
2649
2740
  e.theme && rt(e.theme);
2650
2741
  }
@@ -2711,7 +2802,7 @@ const rt = (t) => {
2711
2802
  dividerColor: "#2e2e32"
2712
2803
  }
2713
2804
  }
2714
- }, ba = {
2805
+ }, ha = {
2715
2806
  fontSize: "var(--vf-typography-font-size)",
2716
2807
  padding: "var(--vf-controls-padding-y) var(--vf-controls-padding-x)",
2717
2808
  borderRadius: "var(--vf-radii-md)",
@@ -2853,11 +2944,11 @@ const rt = (t) => {
2853
2944
  }
2854
2945
  }
2855
2946
  }
2856
- }, ma = {
2947
+ }, ya = {
2857
2948
  padding: "12px",
2858
2949
  borderColor: "var(--vf-border-color)",
2859
2950
  borderRadius: "var(--vf-radii-md)"
2860
- }, ga = {
2951
+ }, _a = {
2861
2952
  gap: "0.5rem",
2862
2953
  fontSize: "var(--vf-typography-font-size)",
2863
2954
  padding: "var(--vf-controls-padding-y) var(--vf-controls-padding-x)",
@@ -2878,7 +2969,7 @@ const rt = (t) => {
2878
2969
  padding: "var(--vf-sizes-lg-padding-y) var(--vf-sizes-lg-padding-x)",
2879
2970
  fontSize: "var(--vf-sizes-lg-font-size)"
2880
2971
  }
2881
- }, ha = {
2972
+ }, ka = {
2882
2973
  gap: "0.375rem",
2883
2974
  textColor: "var(--vf-text-color)",
2884
2975
  labelFontSize: "0.875rem",
@@ -2898,7 +2989,7 @@ const rt = (t) => {
2898
2989
  labelFontSize: "0.9375rem",
2899
2990
  hintFontSize: "0.875rem"
2900
2991
  }
2901
- }, ya = {
2992
+ }, Ca = {
2902
2993
  gap: "0.5rem",
2903
2994
  fontSize: "var(--vf-typography-font-size)",
2904
2995
  padding: "var(--vf-controls-padding-y) var(--vf-controls-padding-x)",
@@ -2921,10 +3012,10 @@ const rt = (t) => {
2921
3012
  padding: "var(--vf-sizes-lg-padding-y) var(--vf-sizes-lg-padding-x)",
2922
3013
  fontSize: "var(--vf-sizes-lg-font-size)"
2923
3014
  }
2924
- }, _a = {
3015
+ }, wa = {
2925
3016
  hoverColor: "var(--vf-blue)",
2926
3017
  activeColor: "var(--vf-blue)"
2927
- }, ka = {
3018
+ }, $a = {
2928
3019
  iconGap: "6px",
2929
3020
  submenuOffset: "12px",
2930
3021
  separatorThickness: "1px",
@@ -2944,7 +3035,7 @@ const rt = (t) => {
2944
3035
  marginBottom: "0.5rem",
2945
3036
  marginLeft: "0.5rem"
2946
3037
  }
2947
- }, Ca = {
3038
+ }, xa = {
2948
3039
  width: "90vw",
2949
3040
  maxWidth: "520px",
2950
3041
  maxHeight: "80vh",
@@ -2971,9 +3062,9 @@ const rt = (t) => {
2971
3062
  closeColor: "var(--vf-text-color)",
2972
3063
  closeFontSize: "1.25rem",
2973
3064
  closeHoverBackgroundColor: "rgba(0, 0, 0, 0.06)"
2974
- }, wa = {
3065
+ }, Ba = {
2975
3066
  backgroundColor: "var(--vf-bg-color)"
2976
- }, $a = {
3067
+ }, za = {
2977
3068
  minWidth: "12rem",
2978
3069
  fontSize: "var(--vf-typography-font-size)",
2979
3070
  controlGap: "0.75rem",
@@ -3006,7 +3097,7 @@ const rt = (t) => {
3006
3097
  padding: "var(--vf-sizes-lg-padding-y) var(--vf-sizes-lg-padding-x)",
3007
3098
  fontSize: "var(--vf-sizes-lg-font-size)"
3008
3099
  }
3009
- }, xa = {
3100
+ }, Fa = {
3010
3101
  minWidth: "12rem",
3011
3102
  fontSize: "var(--vf-typography-font-size)",
3012
3103
  controlGap: "0.5rem",
@@ -3045,7 +3136,7 @@ const rt = (t) => {
3045
3136
  padding: "var(--vf-sizes-lg-padding-y) var(--vf-sizes-lg-padding-x)",
3046
3137
  fontSize: "var(--vf-sizes-lg-font-size)"
3047
3138
  }
3048
- }, Ba = {
3139
+ }, Sa = {
3049
3140
  minWidth: "12rem",
3050
3141
  fontSize: "var(--vf-typography-font-size)",
3051
3142
  controlGap: "0.5rem",
@@ -3090,7 +3181,7 @@ const rt = (t) => {
3090
3181
  padding: "var(--vf-sizes-lg-padding-y) var(--vf-sizes-lg-padding-x)",
3091
3182
  fontSize: "var(--vf-sizes-lg-font-size)"
3092
3183
  }
3093
- }, za = {
3184
+ }, Va = {
3094
3185
  minWidth: "12rem",
3095
3186
  fontSize: "var(--vf-typography-font-size)",
3096
3187
  controlGap: "0.75rem",
@@ -3140,7 +3231,32 @@ const rt = (t) => {
3140
3231
  fontSize: "var(--vf-sizes-lg-font-size)",
3141
3232
  daySize: "2.2rem"
3142
3233
  }
3143
- }, Fa = {
3234
+ }, La = {
3235
+ gap: "0.4rem",
3236
+ itemMinWidth: "2rem",
3237
+ fontSize: "var(--vf-typography-font-size)",
3238
+ padding: "0.35rem 0.65rem",
3239
+ borderRadius: "var(--vf-radii-md)",
3240
+ borderColor: "var(--vf-border-color)",
3241
+ backgroundColor: "var(--vf-controls-background-color)",
3242
+ textColor: "var(--vf-text-color)",
3243
+ hoverBackgroundColor: "rgba(var(--vf-blue-600-rgb), 0.08)",
3244
+ activeBorderColor: "rgba(var(--vf-blue-600-rgb), 0.28)",
3245
+ activeBackgroundColor: "rgba(var(--vf-blue-600-rgb), 0.14)",
3246
+ activeTextColor: "var(--vf-text-color)",
3247
+ focusBorderColor: "var(--vf-blue-600)",
3248
+ focusRingShadow: "var(--vf-states-focus-ring-shadow)",
3249
+ disabledOpacity: "var(--vf-states-disabled-opacity)",
3250
+ ellipsisPadding: "0.35rem 0.5rem",
3251
+ small: {
3252
+ fontSize: "var(--vf-sizes-sm-font-size)",
3253
+ padding: "0.3rem 0.5rem"
3254
+ },
3255
+ large: {
3256
+ fontSize: "var(--vf-sizes-lg-font-size)",
3257
+ padding: "0.45rem 0.8rem"
3258
+ }
3259
+ }, Ta = {
3144
3260
  size: "1rem",
3145
3261
  gap: "0.5rem",
3146
3262
  borderRadius: "var(--vf-radii-sm)",
@@ -3152,7 +3268,7 @@ const rt = (t) => {
3152
3268
  checkColor: "#ffffff",
3153
3269
  textColor: "var(--vf-text-color)",
3154
3270
  disabledOpacity: "var(--vf-states-disabled-opacity)"
3155
- }, Sa = {
3271
+ }, Ra = {
3156
3272
  size: "1rem",
3157
3273
  dotSize: "0.45rem",
3158
3274
  gap: "0.5rem",
@@ -3166,7 +3282,7 @@ const rt = (t) => {
3166
3282
  dotColor: "#ffffff",
3167
3283
  textColor: "var(--vf-text-color)",
3168
3284
  disabledOpacity: "var(--vf-states-disabled-opacity)"
3169
- }, Va = {
3285
+ }, Pa = {
3170
3286
  width: "2.25rem",
3171
3287
  height: "1.25rem",
3172
3288
  thumbSize: "1rem",
@@ -3178,7 +3294,7 @@ const rt = (t) => {
3178
3294
  thumbColor: "#ffffff",
3179
3295
  textColor: "var(--vf-text-color)",
3180
3296
  disabledOpacity: "var(--vf-states-disabled-opacity)"
3181
- }, La = {
3297
+ }, Ma = {
3182
3298
  gap: "0.75rem",
3183
3299
  listGap: "0.5rem",
3184
3300
  listBorderWidth: "1px",
@@ -3199,7 +3315,7 @@ const rt = (t) => {
3199
3315
  panelBackgroundColor: "transparent",
3200
3316
  panelTextColor: "var(--vf-text-color)",
3201
3317
  disabledOpacity: "var(--vf-states-disabled-opacity)"
3202
- }, Ta = {
3318
+ }, Ia = {
3203
3319
  padding: "0.35rem 0.6rem",
3204
3320
  borderRadius: "8px",
3205
3321
  backgroundColor: "rgba(0, 0, 0, 0.8)",
@@ -3210,7 +3326,7 @@ const rt = (t) => {
3210
3326
  zIndex: "120",
3211
3327
  maxWidth: "240px",
3212
3328
  arrowSize: "8px"
3213
- }, Ra = {
3329
+ }, Da = {
3214
3330
  gap: "0.75rem",
3215
3331
  padding: "0.75rem 0.9rem",
3216
3332
  borderRadius: "var(--vf-radii-md)",
@@ -3249,7 +3365,7 @@ const rt = (t) => {
3249
3365
  borderColor: "rgba(var(--vf-red-600-rgb), 0.45)",
3250
3366
  textColor: "var(--vf-text-color)"
3251
3367
  }
3252
- }, Pa = {
3368
+ }, Oa = {
3253
3369
  gap: "0.75rem",
3254
3370
  padding: "0.75rem 0.9rem",
3255
3371
  borderRadius: "var(--vf-radii-md)",
@@ -3287,60 +3403,62 @@ const rt = (t) => {
3287
3403
  borderColor: "rgba(var(--vf-red-600-rgb), 0.45)",
3288
3404
  textColor: "var(--vf-text-color)"
3289
3405
  }
3290
- }, dr = {
3406
+ }, pr = {
3291
3407
  ...je,
3292
3408
  components: {
3293
3409
  base: je,
3294
- button: ba,
3295
- card: ma,
3296
- input: ga,
3297
- formField: ha,
3298
- textarea: ya,
3299
- link: _a,
3300
- menu: ka,
3301
- modal: Ca,
3302
- popover: wa,
3303
- select: $a,
3304
- autocomplete: xa,
3305
- multiselect: Ba,
3306
- datepicker: za,
3307
- checkbox: Fa,
3308
- radio: Sa,
3309
- switch: Va,
3310
- tabs: La,
3311
- tooltip: Ta,
3312
- toast: Ra,
3313
- alert: Pa
3410
+ button: ha,
3411
+ card: ya,
3412
+ input: _a,
3413
+ formField: ka,
3414
+ textarea: Ca,
3415
+ link: wa,
3416
+ menu: $a,
3417
+ modal: xa,
3418
+ popover: Ba,
3419
+ select: za,
3420
+ autocomplete: Fa,
3421
+ multiselect: Sa,
3422
+ datepicker: Va,
3423
+ pagination: La,
3424
+ checkbox: Ta,
3425
+ radio: Ra,
3426
+ switch: Pa,
3427
+ tabs: Ma,
3428
+ tooltip: Ia,
3429
+ toast: Da,
3430
+ alert: Oa
3314
3431
  }
3315
3432
  };
3316
3433
  export {
3317
- tr as Alert,
3318
- Na as Autocomplete,
3319
- Wa as Button,
3434
+ nr as Alert,
3435
+ Xa as Autocomplete,
3436
+ Ka as Button,
3320
3437
  ht as Card,
3321
- ja as Checkbox,
3322
- Ga as DatePicker,
3323
- dr as DefaultTheme,
3324
- Ha as FormField,
3325
- Ma as Input,
3438
+ Ja as Checkbox,
3439
+ Ua as DatePicker,
3440
+ pr as DefaultTheme,
3441
+ Ya as FormField,
3442
+ Na as Input,
3326
3443
  Je as Link,
3327
- Ea as Menu,
3328
- rr as Modal,
3329
- Ya as MultiSelect,
3330
- ar as Popover,
3331
- qa as RadioButton,
3332
- Xa as RadioGroup,
3333
- Ka as Select,
3334
- or as Switch,
3335
- Za as Tab,
3336
- Ja as TabPanel,
3337
- Ua as Tabs,
3338
- Aa as Textarea,
3339
- Qa as Toast,
3340
- er as ToastContainer,
3341
- lr as Tooltip,
3342
- ir as VueForge,
3343
- sr as getTheme,
3444
+ Aa as Menu,
3445
+ dr as Modal,
3446
+ qa as MultiSelect,
3447
+ Za as Pagination,
3448
+ ir as Popover,
3449
+ er as RadioButton,
3450
+ Qa as RadioGroup,
3451
+ ja as Select,
3452
+ sr as Switch,
3453
+ or as Tab,
3454
+ ar as TabPanel,
3455
+ tr as Tabs,
3456
+ Ga as Textarea,
3457
+ rr as Toast,
3458
+ lr as ToastContainer,
3459
+ cr as Tooltip,
3460
+ fr as VueForge,
3461
+ vr as getTheme,
3344
3462
  rt as setTheme,
3345
- nr as updateTheme
3463
+ ur as updateTheme
3346
3464
  };