@codemonster-ru/vueforge 0.3.5 → 0.5.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,607 +1,315 @@
1
- import { defineComponent as F, openBlock as r, createElementBlock as s, createVNode as S, unref as g, withCtx as _, renderSlot as u, resolveComponent as E, createElementVNode as i, inject as H, ref as I, computed as w, normalizeClass as h, Fragment as M, createTextVNode as z, toDisplayString as O, createBlock as y, createCommentVNode as m, defineAsyncComponent as U, resolveDynamicComponent as K, createStaticVNode as q, renderList as G, reactive as W, withDirectives as J, createSlots as Q, vShow as X } from "vue";
2
- const Y = { class: "vf-layout" }, Or = /* @__PURE__ */ F({
1
+ import { openBlock as p, createElementBlock as b, renderSlot as g, defineComponent as E, createVNode as Z, withCtx as L, resolveComponent as de, createElementVNode as $, ref as j, computed as C, watch as ae, normalizeClass as k, Fragment as ne, createTextVNode as ee, toDisplayString as H, createBlock as V, createCommentVNode as w, renderList as ye, withKeys as K, withModifiers as q, unref as J, nextTick as pe, onMounted as Re, onBeforeUnmount as Se, Teleport as Ve, withDirectives as _e, vShow as ke, reactive as ze, createSlots as We } from "vue";
2
+ import { useRoute as Me, useRouter as He } from "vue-router";
3
+ import { CmIcon as Q } from "@codemonster-ru/vueiconify";
4
+ const U = (t, e) => {
5
+ const r = t.__vccOpts || t;
6
+ for (const [o, n] of e)
7
+ r[o] = n;
8
+ return r;
9
+ }, Ee = {}, Ae = { class: "vf-header" };
10
+ function Pe(t, e) {
11
+ return p(), b("header", Ae, [
12
+ g(t.$slots, "default")
13
+ ]);
14
+ }
15
+ const De = /* @__PURE__ */ U(Ee, [["render", Pe]]), Oe = {}, Ne = { class: "vf-content" };
16
+ function Ie(t, e) {
17
+ return p(), b("div", Ne, [
18
+ g(t.$slots, "default")
19
+ ]);
20
+ }
21
+ const je = /* @__PURE__ */ U(Oe, [["render", Ie]]), Xe = {}, Ye = { class: "vf-footer" };
22
+ function Ke(t, e) {
23
+ return p(), b("footer", Ye, [
24
+ g(t.$slots, "default")
25
+ ]);
26
+ }
27
+ const qe = /* @__PURE__ */ U(Xe, [["render", Ke]]), Ue = { class: "vf-layout" }, No = /* @__PURE__ */ E({
3
28
  __name: "defaultLayout",
4
- setup(o) {
5
- return (e, a) => (r(), s("div", Y, [
6
- S(g(Qo), null, {
7
- default: _(() => [
8
- u(e.$slots, "header")
29
+ setup(t) {
30
+ return (e, r) => (p(), b("div", Ue, [
31
+ Z(De, null, {
32
+ default: L(() => [
33
+ g(e.$slots, "header")
9
34
  ]),
10
35
  _: 3
11
36
  }),
12
- S(g(sr), null, {
13
- default: _(() => [
14
- u(e.$slots, "content")
37
+ Z(je, null, {
38
+ default: L(() => [
39
+ g(e.$slots, "content")
15
40
  ]),
16
41
  _: 3
17
42
  }),
18
- S(g(or), null, {
19
- default: _(() => [
20
- u(e.$slots, "footer")
43
+ Z(qe, null, {
44
+ default: L(() => [
45
+ g(e.$slots, "footer")
21
46
  ]),
22
47
  _: 3
23
48
  })
24
49
  ]));
25
50
  }
26
- }), $ = (o, e) => {
27
- const a = o.__vccOpts || o;
28
- for (const [t, n] of e)
29
- a[t] = n;
30
- return a;
31
- }, ee = {}, oe = { class: "vf-left-sidebar-flexbox" }, re = { class: "vf-left-sidebar" }, te = { class: "vf-main-content" };
32
- function le(o, e) {
33
- const a = E("router-view");
34
- return r(), s("div", oe, [
35
- i("div", re, [
36
- u(o.$slots, "leftSidebar")
51
+ }), Ge = {}, Ze = { class: "vf-left-sidebar-flexbox" }, Je = { class: "vf-left-sidebar" }, Qe = { class: "vf-main-content" };
52
+ function et(t, e) {
53
+ const r = de("router-view");
54
+ return p(), b("div", Ze, [
55
+ $("div", Je, [
56
+ g(t.$slots, "leftSidebar")
37
57
  ]),
38
- i("div", te, [
39
- S(a)
58
+ $("div", Qe, [
59
+ Z(r)
40
60
  ])
41
61
  ]);
42
62
  }
43
- const jr = /* @__PURE__ */ $(ee, [["render", le]]), ne = {}, se = { class: "vf-demo" };
44
- function ae(o, e) {
45
- return r(), s("div", se, [
46
- u(o.$slots, "default")
63
+ const Io = /* @__PURE__ */ U(Ge, [["render", et]]), tt = {}, ot = { class: "vf-demo" };
64
+ function rt(t, e) {
65
+ return p(), b("div", ot, [
66
+ g(t.$slots, "default")
47
67
  ]);
48
68
  }
49
- const Pr = /* @__PURE__ */ $(ne, [["render", ae]]);
50
- /*!
51
- * vue-router v4.5.0
52
- * (c) 2024 Eduardo San Martin Morote
53
- * @license MIT
54
- */
55
- var L;
56
- (function(o) {
57
- o.pop = "pop", o.push = "push";
58
- })(L || (L = {}));
59
- var V;
60
- (function(o) {
61
- o.back = "back", o.forward = "forward", o.unknown = "";
62
- })(V || (V = {}));
63
- Symbol(process.env.NODE_ENV !== "production" ? "navigation failure" : "");
64
- var N;
65
- (function(o) {
66
- o[o.aborted = 4] = "aborted", o[o.cancelled = 8] = "cancelled", o[o.duplicated = 16] = "duplicated";
67
- })(N || (N = {}));
68
- Symbol(process.env.NODE_ENV !== "production" ? "router view location matched" : "");
69
- Symbol(process.env.NODE_ENV !== "production" ? "router view depth" : "");
70
- Symbol(process.env.NODE_ENV !== "production" ? "router" : "");
71
- const ce = Symbol(process.env.NODE_ENV !== "production" ? "route location" : "");
72
- Symbol(process.env.NODE_ENV !== "production" ? "router view location" : "");
73
- function ie(o) {
74
- return H(ce);
75
- }
76
- const ue = ["href"], T = /* @__PURE__ */ F({
69
+ const jo = /* @__PURE__ */ U(tt, [["render", rt]]), nt = ["href", "aria-disabled", "tabindex"], ue = /* @__PURE__ */ E({
77
70
  __name: "link",
78
71
  props: {
79
- to: { default: "" },
72
+ to: { default: void 0 },
73
+ href: { default: void 0 },
80
74
  url: { default: void 0 },
81
- type: { default: "a" },
75
+ as: { default: void 0 },
76
+ type: { default: void 0 },
82
77
  label: { default: "" },
83
78
  active: { type: Boolean },
84
79
  disabled: { type: Boolean }
85
80
  },
86
- emits: ["onActive"],
87
- setup(o, { emit: e }) {
88
- const a = e, t = o, n = ie(), l = I(null), b = w(() => (t.type === "router-link" && n.matched.some(({ name: f }) => t.to.name === f) && a("onActive"), t.active));
89
- return (f, d) => {
90
- const v = E("router-link");
91
- return f.type === "a" ? (r(), s("a", {
81
+ emits: ["click", "active", "update:active", "onActive"],
82
+ setup(t, { emit: e }) {
83
+ const r = e, o = t, n = Me(), d = He(), a = j(null), c = C(() => o.href ?? o.url), l = C(() => o.as ? o.as : o.type === "router-link" || o.type === "a" ? o.type : o.to ? "router-link" : "a"), f = C(() => o.to ? d.resolve(o.to) : null), u = C(() => {
84
+ if (l.value !== "router-link")
85
+ return !1;
86
+ const i = f.value;
87
+ return i ? i.name ? n.matched.some(({ name: m }) => m === i.name) : i.fullPath ? n.fullPath === i.fullPath : n.path === i.path : !1;
88
+ }), s = C(() => o.active === void 0 ? u.value : o.active), v = (i) => {
89
+ if (!o.disabled) {
90
+ r("click", i);
91
+ return;
92
+ }
93
+ i.preventDefault(), i.stopPropagation();
94
+ };
95
+ return ae(u, (i) => {
96
+ i && (r("active"), r("onActive")), r("update:active", i);
97
+ }), (i, m) => {
98
+ const _ = de("router-link");
99
+ return l.value === "a" ? (p(), b("a", {
92
100
  key: 0,
93
- href: f.url,
94
- class: h(["vf-link", { "vf-link_active": f.active, "vf-link_disabled": f.disabled }])
101
+ href: c.value,
102
+ class: k(["vf-link", { "vf-link_active": s.value, "vf-link_disabled": i.disabled }]),
103
+ "aria-disabled": i.disabled,
104
+ tabindex: i.disabled ? -1 : void 0,
105
+ onClick: v
95
106
  }, [
96
- f.$slots.default ? u(f.$slots, "default", { key: 0 }) : (r(), s(M, { key: 1 }, [
97
- z(O(f.label), 1)
107
+ i.$slots.default ? g(i.$slots, "default", { key: 0 }) : (p(), b(ne, { key: 1 }, [
108
+ ee(H(i.label), 1)
98
109
  ], 64))
99
- ], 10, ue)) : (r(), y(v, {
110
+ ], 10, nt)) : (p(), V(_, {
100
111
  key: 1,
101
112
  ref_key: "link",
102
- ref: l,
103
- to: f.to,
104
- class: h(["vf-link", { "vf-link_active": b.value }]),
105
- disabled: f.disabled,
113
+ ref: a,
114
+ to: i.to,
115
+ class: k(["vf-link", { "vf-link_active": s.value }]),
116
+ "aria-disabled": i.disabled,
117
+ tabindex: i.disabled ? -1 : void 0,
106
118
  "active-class": "vf-link_partially-active",
107
- "exact-active-class": "vf-link_active"
119
+ "exact-active-class": "vf-link_active",
120
+ onClick: v
108
121
  }, {
109
- default: _(() => [
110
- f.$slots.default ? u(f.$slots, "default", { key: 0 }) : (r(), s(M, { key: 1 }, [
111
- z(O(f.label), 1)
122
+ default: L(() => [
123
+ i.$slots.default ? g(i.$slots, "default", { key: 0 }) : (p(), b(ne, { key: 1 }, [
124
+ ee(H(i.label), 1)
112
125
  ], 64))
113
126
  ]),
114
127
  _: 3
115
- }, 8, ["to", "class", "disabled"]));
128
+ }, 8, ["to", "class", "aria-disabled", "tabindex"]));
116
129
  };
117
130
  }
118
- }), de = {}, ve = { class: "vf-card" }, fe = {
131
+ }), lt = {}, st = { class: "vf-card" }, at = {
119
132
  key: 0,
120
133
  class: "vf-card__default"
121
- }, he = {
134
+ }, it = {
122
135
  key: 1,
123
136
  class: "vf-card__header"
124
- }, pe = {
137
+ }, ct = {
125
138
  key: 2,
126
139
  class: "vf-card__body"
127
- }, ge = {
140
+ }, dt = {
128
141
  key: 3,
129
142
  class: "vf-card__footer"
130
143
  };
131
- function be(o, e) {
132
- return r(), s("div", ve, [
133
- o.$slots.default ? (r(), s("div", fe, [
134
- u(o.$slots, "default")
135
- ])) : m("", !0),
136
- o.$slots.header ? (r(), s("div", he, [
137
- u(o.$slots, "header")
138
- ])) : m("", !0),
139
- o.$slots.body ? (r(), s("div", pe, [
140
- u(o.$slots, "body")
141
- ])) : m("", !0),
142
- o.$slots.footer ? (r(), s("div", ge, [
143
- u(o.$slots, "footer")
144
- ])) : m("", !0)
144
+ function ut(t, e) {
145
+ return p(), b("div", st, [
146
+ t.$slots.default ? (p(), b("div", at, [
147
+ g(t.$slots, "default")
148
+ ])) : w("", !0),
149
+ t.$slots.header ? (p(), b("div", it, [
150
+ g(t.$slots, "header")
151
+ ])) : w("", !0),
152
+ t.$slots.body ? (p(), b("div", ct, [
153
+ g(t.$slots, "body")
154
+ ])) : w("", !0),
155
+ t.$slots.footer ? (p(), b("div", dt, [
156
+ g(t.$slots, "footer")
157
+ ])) : w("", !0)
145
158
  ]);
146
159
  }
147
- const _e = /* @__PURE__ */ $(de, [["render", be]]), me = { class: "vf-logo" }, ye = ["src", "width", "height", "alt"], Ce = ["src", "width", "height", "alt"], Mr = /* @__PURE__ */ F({
160
+ const ft = /* @__PURE__ */ U(lt, [["render", ut]]), vt = { class: "vf-logo" }, pt = ["src", "width", "height", "alt"], ht = ["src", "width", "height", "alt"], Xo = /* @__PURE__ */ E({
148
161
  __name: "logo",
149
162
  props: {
150
163
  to: { default: void 0 },
164
+ href: { default: void 0 },
151
165
  url: { default: void 0 },
152
166
  src: {},
153
167
  alt: { default: void 0 },
154
- type: { default: "" },
168
+ as: { default: void 0 },
169
+ type: { default: void 0 },
155
170
  dark: { type: Boolean },
156
171
  width: { default: void 0 },
157
172
  height: { default: void 0 }
158
173
  },
159
- setup(o) {
160
- const e = o, a = w(() => Array.isArray(e.src) ? e.dark ? e.src[1] : e.src[0] : e.src);
161
- return (t, n) => (r(), s("div", me, [
162
- t.type.length ? (r(), y(g(T), {
174
+ setup(t) {
175
+ const e = t, r = C(() => e.as ? e.as : e.type === "router-link" || e.type === "a" ? e.type : e.to ? "router-link" : e.href || e.url ? "a" : ""), o = C(() => Array.isArray(e.src) ? e.dark ? e.src[1] : e.src[0] : e.src);
176
+ return (n, d) => (p(), b("div", vt, [
177
+ r.value ? (p(), V(ue, {
163
178
  key: 0,
164
- type: t.type,
165
- to: t.to,
166
- url: t.url
179
+ as: r.value,
180
+ to: n.to,
181
+ href: n.href ?? n.url
167
182
  }, {
168
- default: _(() => [
169
- i("img", {
170
- src: a.value,
171
- width: t.width,
172
- height: t.height,
173
- alt: t.alt
174
- }, null, 8, ye)
183
+ default: L(() => [
184
+ $("img", {
185
+ src: o.value,
186
+ width: n.width,
187
+ height: n.height,
188
+ alt: n.alt
189
+ }, null, 8, pt)
175
190
  ]),
176
191
  _: 1
177
- }, 8, ["type", "to", "url"])) : (r(), s("img", {
192
+ }, 8, ["as", "to", "href"])) : (p(), b("img", {
178
193
  key: 1,
179
- src: a.value,
180
- width: t.width,
181
- height: t.height,
182
- alt: t.alt
183
- }, null, 8, Ce))
194
+ src: o.value,
195
+ width: n.width,
196
+ height: n.height,
197
+ alt: n.alt
198
+ }, null, 8, ht))
184
199
  ]));
185
200
  }
186
- }), p = (o, e) => {
187
- const a = o.__vccOpts || o;
188
- for (const [t, n] of e)
189
- a[t] = n;
190
- return a;
191
- }, we = {}, ke = {
192
- xmlns: "http://www.w3.org/2000/svg",
193
- viewBox: "0 0 512 512",
194
- fill: "none",
195
- width: "16",
196
- height: "16"
197
- };
198
- function Fe(o, e) {
199
- return r(), s("svg", ke, e[0] || (e[0] = [
200
- q('<circle fill="currentColor" cx="256" cy="256" r="128"></circle><rect fill="currentColor" y="240.03" width="96" height="31.94"></rect><rect fill="currentColor" x="416" y="240.03" width="96" height="31.94"></rect><rect fill="currentColor" x="239.95" width="32.1" height="96"></rect><polygon fill="currentColor" points="240 416 272 416 272 512 240.06 512 240 416"></polygon><rect fill="currentColor" x="93.09" y="60.96" width="31.94" height="96" transform="translate(-45.1 109.03) rotate(-45)"></rect><rect fill="currentColor" x="355.02" y="92.75" width="96" height="32.1" transform="translate(41.11 316.85) rotate(-45)"></rect><polygon fill="currentColor" points="357.08 380.39 379.71 357.76 447.59 425.65 425 448.23 357.08 380.39"></polygon><polygon fill="currentColor" points="131.75 357.04 154.37 379.67 86.49 447.55 63.9 424.96 131.75 357.04"></polygon>', 9)
201
- ]));
202
- }
203
- const $e = /* @__PURE__ */ p(we, [["render", Fe]]), Be = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
204
- __proto__: null,
205
- default: $e
206
- }, Symbol.toStringTag, { value: "Module" })), Se = {}, Oe = {
207
- xmlns: "http://www.w3.org/2000/svg",
208
- viewBox: "0 0 512 512",
209
- fill: "none",
210
- width: "16",
211
- height: "16"
212
- };
213
- function je(o, e) {
214
- return r(), s("svg", Oe, e[0] || (e[0] = [
215
- i("path", {
216
- fill: "currentColor",
217
- d: "m352,448c-123.71,0-224-100.29-224-224,0-107.81,76.16-197.81,177.61-219.18-16.05-3.15-32.64-4.82-49.61-4.82C114.62,0,0,114.62,0,256s114.62,256,256,256c75.54,0,143.44-32.73,190.3-84.77-28.66,13.32-60.61,20.77-94.3,20.77Z"
218
- }, null, -1)
219
- ]));
220
- }
221
- const Pe = /* @__PURE__ */ p(Se, [["render", je]]), Me = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
222
- __proto__: null,
223
- default: Pe
224
- }, Symbol.toStringTag, { value: "Module" })), ze = {}, xe = {
225
- xmlns: "http://www.w3.org/2000/svg",
226
- viewBox: "0 0 512 512",
227
- fill: "none",
228
- width: "16",
229
- height: "16"
230
- };
231
- function Te(o, e) {
232
- return r(), s("svg", xe, e[0] || (e[0] = [
233
- i("path", {
234
- fill: "currentColor",
235
- d: "M32,160h448c32.5,0,31.5-32,31.5-32s0-32-31.5-32H32c-32.5,0-31.5,32-31.5,32S-0.5,160,32,160z"
236
- }, null, -1),
237
- i("path", {
238
- fill: "currentColor",
239
- d: "M32,288h448c32.5,0,31.5-32,31.5-32s0-32-31.5-32H32c-32.5,0-31.5,32-31.5,32S-0.5,288,32,288z"
240
- }, null, -1),
241
- i("path", {
242
- fill: "currentColor",
243
- d: "M32,415.5h448c32.5,0,31.5-32,31.5-32s0-32-31.5-32H32c-32.5,0-31.5,32-31.5,32S-0.5,415.5,32,415.5z"
244
- }, null, -1)
245
- ]));
246
- }
247
- const Le = /* @__PURE__ */ p(ze, [["render", Te]]), Ve = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
248
- __proto__: null,
249
- default: Le
250
- }, Symbol.toStringTag, { value: "Module" })), Ne = {}, Re = {
251
- xmlns: "http://www.w3.org/2000/svg",
252
- viewBox: "0 0 512 512",
253
- fill: "none",
254
- width: "16",
255
- height: "16"
256
- };
257
- function De(o, e) {
258
- return r(), s("svg", Re, e[0] || (e[0] = [
259
- i("path", {
260
- fill: "currentColor",
261
- d: "m33,512h447c21.33,1,32-10.67,32-35,0-128-106.67-189-192-189h-128C106.67,288,0,352,0,480c-.11,21.99,11.33,32.21,33,32Z"
262
- }, null, -1),
263
- i("circle", {
264
- fill: "currentColor",
265
- cx: "256",
266
- cy: "127",
267
- r: "127"
268
- }, null, -1)
269
- ]));
270
- }
271
- const Ee = /* @__PURE__ */ p(Ne, [["render", De]]), Ze = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
272
- __proto__: null,
273
- default: Ee
274
- }, Symbol.toStringTag, { value: "Module" })), Ae = {}, He = {
275
- xmlns: "http://www.w3.org/2000/svg",
276
- viewBox: "0 0 512 512",
277
- fill: "none",
278
- width: "16",
279
- height: "16"
280
- };
281
- function Ie(o, e) {
282
- return r(), s("svg", He, e[0] || (e[0] = [
283
- i("path", {
284
- fill: "currentColor",
285
- d: "m220.45,16.12c18.29-17.75,38.39-24.95,64,0l208.5,192.5c20.88,21.19,15,47-17,47l-31.5.5v224c.04,21.44-10.88,32.07-32.32,32.32h-63.85c-21.36-.51-31.86-11.38-32.07-32.07v-128.25c.21-21.63-10.58-32.08-31.88-31.88h-63.88c-21.48-.1-32.04,10.63-31.94,31.94v127.94c-.11,21.25-10.59,31.95-31.77,31.77h-64c-22.05.21-32.5-10.69-32.03-32.03v-223.74l-31.76-.5c-33,0-37-26.88-16-47L220.45,16.12Z"
286
- }, null, -1)
287
- ]));
288
- }
289
- const Ue = /* @__PURE__ */ p(Ae, [["render", Ie]]), Ke = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
290
- __proto__: null,
291
- default: Ue
292
- }, Symbol.toStringTag, { value: "Module" })), qe = {}, Ge = {
293
- xmlns: "http://www.w3.org/2000/svg",
294
- viewBox: "0 0 512 512",
295
- fill: "none",
296
- width: "16",
297
- height: "16"
298
- };
299
- function We(o, e) {
300
- return r(), s("svg", Ge, e[0] || (e[0] = [
301
- i("path", {
302
- fill: "currentColor",
303
- d: "m496.36,59.31c15.08-15.08,15.08-32.92,0-48s-24.92-15.08-40,0L192.33,275.63,56.57,139.87c-15.08-15.08-30.17-15.09-45.25,0-15.08,15.08-15.09,30.17,0,45.25l158.39,158.39c15.08,15.08,30.17,15.09,45.25,0L496.36,59.31Z"
304
- }, null, -1)
305
- ]));
306
- }
307
- const Je = /* @__PURE__ */ p(qe, [["render", We]]), Qe = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
308
- __proto__: null,
309
- default: Je
310
- }, Symbol.toStringTag, { value: "Module" })), Xe = {}, Ye = {
311
- xmlns: "http://www.w3.org/2000/svg",
312
- viewBox: "0 0 512 512",
313
- fill: "none",
314
- width: "16",
315
- height: "16"
316
- };
317
- function eo(o, e) {
318
- return r(), s("svg", Ye, e[0] || (e[0] = [
319
- i("g", null, [
320
- i("path", { d: "m256,507c-67.04,0-130.08-26.11-177.48-73.52S5,323.04,5,256,31.11,125.92,78.52,78.52,188.96,5,256,5s130.08,26.11,177.48,73.52,73.52,110.44,73.52,177.48-26.11,130.08-73.52,177.48-110.44,73.52-177.48,73.52Z" }),
321
- i("path", {
322
- fill: "currentColor",
323
- d: "m256,10c33.21,0,65.43,6.5,95.75,19.33,29.29,12.39,55.6,30.13,78.2,52.72s40.33,48.9,52.72,78.2c12.82,30.32,19.33,62.54,19.33,95.75s-6.5,65.43-19.33,95.75c-12.39,29.29-30.13,55.6-52.72,78.2s-48.9,40.33-78.2,52.72c-30.32,12.82-62.54,19.33-95.75,19.33s-65.43-6.5-95.75-19.33c-29.29-12.39-55.6-30.13-78.2-52.72s-40.33-48.9-52.72-78.2c-12.82-30.32-19.33-62.54-19.33-95.75s6.5-65.43,19.33-95.75c12.39-29.29,30.13-55.6,52.72-78.2s48.9-40.33,78.2-52.72c30.32-12.82,62.54-19.33,95.75-19.33m0-10C114.62,0,0,114.62,0,256s114.62,256,256,256,256-114.62,256-256S397.38,0,256,0h0Z"
324
- })
325
- ], -1),
326
- i("path", {
327
- fill: "currentColor",
328
- d: "m257.5,9.5v495C102.44,488.3,21.16,410.81,8.5,248.5,16.5,128.5,98.26,27.89,257.5,9.5Z"
329
- }, null, -1)
330
- ]));
331
- }
332
- const oo = /* @__PURE__ */ p(Xe, [["render", eo]]), ro = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
333
- __proto__: null,
334
- default: oo
335
- }, Symbol.toStringTag, { value: "Module" })), to = {}, lo = {
336
- xmlns: "http://www.w3.org/2000/svg",
337
- viewBox: "0 0 512 512",
338
- fill: "none",
339
- width: "16",
340
- height: "16"
341
- };
342
- function no(o, e) {
343
- return r(), s("svg", lo, e[0] || (e[0] = [
344
- i("path", {
345
- fill: "currentColor",
346
- d: "m256,480c-119.85,0-217.71-94.12-223.71-212.48C25.72,137.84,131.42,29.08,261.23,32.06c58.54,1.34,111.52,25.16,150.69,63.15.02.02.06.02.08,0l22.54-22.54s.02-.06,0-.08C384.4,23.77,314.35-4.69,237.7.64,111.85,9.39,10.68,109.56.81,235.33c-11.82,150.71,106.97,276.67,255.19,276.67,94.72,0,197.27-90.53,208-112,8-16-16-24-24.17-16-17.03,16.67-107.72,96-183.83,96Z"
347
- }, null, -1),
348
- i("path", {
349
- fill: "currentColor",
350
- d: "m487,139.34V43.37c0-10.38-12.55-15.58-19.9-8.24l-95.97,95.97c-7.34,7.34-2.14,19.9,8.24,19.9h95.97c6.44,0,11.66-5.22,11.66-11.66Z"
351
- }, null, -1)
352
- ]));
353
- }
354
- const so = /* @__PURE__ */ p(to, [["render", no]]), ao = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
355
- __proto__: null,
356
- default: so
357
- }, Symbol.toStringTag, { value: "Module" })), co = {}, io = {
358
- xmlns: "http://www.w3.org/2000/svg",
359
- viewBox: "0 0 512 512",
360
- fill: "none",
361
- width: "16",
362
- height: "16"
363
- };
364
- function uo(o, e) {
365
- return r(), s("svg", io, e[0] || (e[0] = [
366
- i("path", {
367
- fill: "currentColor",
368
- d: "M279.6 158.3l168.1 168.1c16.1 16.1-.1 32.5-.1 32.5s-16 15.4-31.9-.5L256.1 198.8l-160 160c-16 16-31.5-.5-31.5-.5s-16.5-15.5-.5-31.5l168.5-168.5c16-16 31-16 47 0z"
369
- }, null, -1)
370
- ]));
371
- }
372
- const vo = /* @__PURE__ */ p(co, [["render", uo]]), fo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
373
- __proto__: null,
374
- default: vo
375
- }, Symbol.toStringTag, { value: "Module" })), ho = {}, po = {
376
- xmlns: "http://www.w3.org/2000/svg",
377
- viewBox: "0 0 512 512",
378
- fill: "none",
379
- width: "16",
380
- height: "16"
381
- };
382
- function go(o, e) {
383
- return r(), s("svg", po, e[0] || (e[0] = [
384
- i("path", {
385
- fill: "currentColor",
386
- d: "M232.4,353.7L64.3,185.6c-16.1-16.1,0.1-32.5,0.1-32.5s16-15.4,31.9,0.5l159.6,159.6l160-160 c16-16,31.5,0.5,31.5,0.5s16.5,15.5,0.5,31.5c-13,13-168.5,168.5-168.5,168.5C263.4,369.7,248.4,369.7,232.4,353.7z"
387
- }, null, -1)
388
- ]));
389
- }
390
- const bo = /* @__PURE__ */ p(ho, [["render", go]]), _o = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
391
- __proto__: null,
392
- default: bo
393
- }, Symbol.toStringTag, { value: "Module" })), mo = {}, yo = {
394
- xmlns: "http://www.w3.org/2000/svg",
395
- viewBox: "0 0 512 512",
396
- fill: "none",
397
- width: "16",
398
- height: "16"
399
- };
400
- function Co(o, e) {
401
- return r(), s("svg", yo, e[0] || (e[0] = [
402
- i("path", {
403
- fill: "currentColor",
404
- d: "M158.3,232.4L326.4,64.3c16.1-16.1,32.5,0.1,32.5,0.1s15.4,16-0.5,31.9L198.8,255.9l160,160 c16,16-0.5,31.5-0.5,31.5s-15.5,16.5-31.5,0.5c-13-13-168.5-168.5-168.5-168.5C142.3,263.4,142.3,248.4,158.3,232.4z"
405
- }, null, -1)
406
- ]));
407
- }
408
- const wo = /* @__PURE__ */ p(mo, [["render", Co]]), ko = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
409
- __proto__: null,
410
- default: wo
411
- }, Symbol.toStringTag, { value: "Module" })), Fo = {}, $o = {
412
- xmlns: "http://www.w3.org/2000/svg",
413
- viewBox: "0 0 512 512",
414
- fill: "none",
415
- width: "16",
416
- height: "16"
417
- };
418
- function Bo(o, e) {
419
- return r(), s("svg", $o, e[0] || (e[0] = [
420
- i("path", {
421
- fill: "currentColor",
422
- d: "M353.7,279.6L185.6,447.7c-16.1,16.1-32.5-0.1-32.5-0.1s-15.4-16,0.5-31.9l159.6-159.6l-160-160 c-16-16,0.5-31.5,0.5-31.5s15.5-16.5,31.5-0.5c13,13,168.5,168.5,168.5,168.5C369.7,248.6,369.7,263.6,353.7,279.6z"
423
- }, null, -1)
424
- ]));
425
- }
426
- const So = /* @__PURE__ */ p(Fo, [["render", Bo]]), Oo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
427
- __proto__: null,
428
- default: So
429
- }, Symbol.toStringTag, { value: "Module" })), jo = {}, Po = {
430
- xmlns: "http://www.w3.org/2000/svg",
431
- viewBox: "0 0 512 512",
432
- fill: "none",
433
- width: "16",
434
- height: "16"
435
- };
436
- function Mo(o, e) {
437
- return r(), s("svg", Po, e[0] || (e[0] = [
438
- i("path", {
439
- fill: "currentColor",
440
- d: "m484,508c5.66,5.66,18.34,5.66,24,0,5.66-5.66,5.66-18.34,0-24l-171.29-168.5-22.63,22.63,169.91,169.87Z"
441
- }, null, -1),
442
- i("path", {
443
- fill: "currentColor",
444
- d: "m327.76,56.24c-74.98-74.98-196.55-74.98-271.53,0s-74.98,196.55,0,271.53c74.98,74.98,196.55,74.98,271.53,0,74.98-74.98,74.98-196.55,0-271.53Zm-22.63,248.9c-62.48,62.48-163.79,62.48-226.27,0s-62.48-163.79,0-226.27,163.79-62.48,226.27,0,62.48,163.79,0,226.27Z"
445
- }, null, -1)
446
- ]));
447
- }
448
- const zo = /* @__PURE__ */ p(jo, [["render", Mo]]), xo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
449
- __proto__: null,
450
- default: zo
451
- }, Symbol.toStringTag, { value: "Module" })), To = {}, Lo = {
452
- xmlns: "http://www.w3.org/2000/svg",
453
- viewBox: "0 0 512 512",
454
- fill: "none",
455
- width: "16",
456
- height: "16"
457
- };
458
- function Vo(o, e) {
459
- return r(), s("svg", Lo, e[0] || (e[0] = [
460
- i("path", {
461
- fill: "currentColor",
462
- d: "m345.37.69c-5.57-1.85-11.6,1.15-13.47,6.72l-3.4,10.11c-1.88,5.58,1.12,11.63,6.71,13.51l-.46-.15c84.86,31.87,145.26,113.74,145.26,209.74,0,123.71-100.29,224-224,224S32,364.33,32,240.62c0-96.23,60.69-178.26,145.87-209.97l-.94.3c5.6-1.82,8.67-7.84,6.85-13.44l-3.3-10.14c-1.81-5.56-7.74-8.61-13.31-6.88C69.58,36.6,0,130.47,0,240.62c0,141.38,114.62,256,256,256s256-114.62,256-256c0-109.94-69.32-203.66-166.63-239.92Z"
463
- }, null, -1)
464
- ]));
465
- }
466
- const No = /* @__PURE__ */ p(To, [["render", Vo]]), Ro = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
467
- __proto__: null,
468
- default: No
469
- }, Symbol.toStringTag, { value: "Module" })), Do = (o, e, a) => {
470
- const t = o[e];
471
- return t ? typeof t == "function" ? t() : Promise.resolve(t) : new Promise((n, l) => {
472
- (typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(
473
- l.bind(
474
- null,
475
- new Error(
476
- "Unknown variable dynamic import: " + e + (e.split("/").length !== a ? ". Note that variables only represent file names one level deep." : "")
477
- )
478
- )
479
- );
480
- });
481
- }, Eo = ["bars", "check", "chevronDown", "chevronLeft", "chevronRight", "chevronUp", "circleHalf", "circleNotch", "house", "magnifyingGlass", "moon", "rotateRight", "sun", "user"], Zo = {
482
- list: Eo
483
- }, Ao = /* @__PURE__ */ F({
484
- __name: "icon",
485
- props: {
486
- icon: {
487
- type: String,
488
- default: "moon",
489
- validator: (o) => Zo.list.indexOf(o) > -1
490
- },
491
- spin: {
492
- type: Boolean,
493
- default: !1
494
- }
495
- },
496
- setup(o) {
497
- const e = o, a = w(() => {
498
- const n = e.icon;
499
- return U(() => Do(/* @__PURE__ */ Object.assign({ "./bars.vue": () => Promise.resolve().then(() => Ve), "./check.vue": () => Promise.resolve().then(() => Qe), "./chevronDown.vue": () => Promise.resolve().then(() => _o), "./chevronLeft.vue": () => Promise.resolve().then(() => ko), "./chevronRight.vue": () => Promise.resolve().then(() => Oo), "./chevronUp.vue": () => Promise.resolve().then(() => fo), "./circleHalf.vue": () => Promise.resolve().then(() => ro), "./circleNotch.vue": () => Promise.resolve().then(() => Ro), "./house.vue": () => Promise.resolve().then(() => Ke), "./icon.vue": () => Promise.resolve().then(() => Ho), "./magnifyingGlass.vue": () => Promise.resolve().then(() => xo), "./moon.vue": () => Promise.resolve().then(() => Me), "./rotateRight.vue": () => Promise.resolve().then(() => ao), "./sun.vue": () => Promise.resolve().then(() => Be), "./user.vue": () => Promise.resolve().then(() => Ze) }), `./${n}.vue`, 2));
500
- }), t = w(() => {
501
- let n = ["cm-icon"];
502
- return e.spin && n.push("cm-icon_animations_spin"), n;
503
- });
504
- return (n, l) => (r(), y(K(a.value), {
505
- class: h(t.value)
506
- }, null, 8, ["class"]));
507
- }
508
- }), k = /* @__PURE__ */ p(Ao, [["__scopeId", "data-v-e8b1cecb"]]), Ho = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
509
- __proto__: null,
510
- default: k
511
- }, Symbol.toStringTag, { value: "Module" })), Io = { class: "vf-menu__list" }, Uo = {
201
+ }), bt = {
202
+ class: "vf-menu__list",
203
+ role: "menu"
204
+ }, gt = {
512
205
  key: 1,
513
- class: "vf-menu__separator"
514
- }, Ko = ["onClick"], qo = /* @__PURE__ */ F({
206
+ class: "vf-menu__separator",
207
+ role: "separator"
208
+ }, mt = ["aria-expanded", "onClick", "onKeydown"], Yo = /* @__PURE__ */ E({
209
+ name: "VfMenu",
515
210
  __name: "menu",
516
211
  props: {
517
212
  items: {},
518
213
  orientation: { default: "vertical" }
519
214
  },
520
- emits: ["onActive"],
521
- setup(o, { emit: e }) {
522
- const a = e, t = o, n = (d, v) => `${d.label}_${v.toString()}`, l = (d) => Object.prototype.hasOwnProperty.call(d, "to") ? "router-link" : "a", b = (d) => {
523
- Object.prototype.hasOwnProperty.call(d, "items") ? (t.items.map((v) => {
524
- v !== d && (v.subMenuVisible = !1);
525
- }), d.subMenuVisible = !d.subMenuVisible) : Object.prototype.hasOwnProperty.call(d, "command") && d.command();
526
- }, f = (d) => {
527
- var v;
528
- for (const c in t.items) {
529
- const C = t.items[c];
530
- Object.prototype.hasOwnProperty.call(C, "items") && ((v = C.items) != null && v.some((P) => P === d) ? (C.active = !0, C.subMenuVisible = !0) : (C.active = !1, C.subMenuVisible = !1));
215
+ emits: ["active", "onActive"],
216
+ setup(t, { emit: e }) {
217
+ const r = e, o = t, n = j([]), d = (u, s) => `${u.label ?? u.to ?? u.href ?? u.url ?? "item"}_${s.toString()}`, a = (u) => u.to ? "router-link" : "a", c = (u) => u.map((s) => ({
218
+ ...s,
219
+ items: s.items ? c(s.items) : void 0
220
+ })), l = (u) => {
221
+ u.items && u.items.length ? (n.value.map((s) => {
222
+ s !== u && (s.subMenuVisible = !1);
223
+ }), u.subMenuVisible = !u.subMenuVisible) : Object.prototype.hasOwnProperty.call(u, "command") && typeof u.command == "function" && u.command();
224
+ }, f = (u) => {
225
+ var s;
226
+ for (const v in n.value) {
227
+ const i = n.value[v];
228
+ Object.prototype.hasOwnProperty.call(i, "items") && ((s = i.items) != null && s.some((m) => m === u) ? (i.active = !0, i.subMenuVisible = !0) : (i.active = !1, i.subMenuVisible = !1));
531
229
  }
532
- a("onActive", d);
230
+ r("active", u), r("onActive", u);
533
231
  };
534
- return (d, v) => (r(), s("div", {
535
- class: h(["vf-menu", `vf-menu_${d.orientation}`])
536
- }, [
537
- i("ul", Io, [
538
- (r(!0), s(M, null, G(d.items, (c, C) => (r(), s("li", {
539
- key: n(c, C),
540
- class: "vf-menu__item"
541
- }, [
542
- d.$slots[n(c, C)] ? u(d.$slots, n(c, C), {
543
- key: 0,
544
- item: { ...c, class: "vf-menu__link" }
545
- }) : c.separator ? (r(), s("hr", Uo)) : c.hasOwnProperty("items") ? (r(), s(M, { key: 2 }, [
546
- i("div", {
547
- class: h(["vf-menu__parent", { "vf-menu__parent_active": c.active }]),
548
- onClick: (P) => b(c)
549
- }, [
550
- c.icon ? (r(), y(g(k), {
551
- key: 0,
552
- icon: c.icon,
553
- class: "vf-menu__icon"
554
- }, null, 8, ["icon"])) : m("", !0),
555
- z(" " + O(c.label) + " ", 1),
556
- S(g(k), { icon: "chevronDown" })
557
- ], 10, Ko),
558
- c.items ? (r(), y(g(qo), {
232
+ return ae(
233
+ () => o.items,
234
+ (u) => {
235
+ n.value = c(u);
236
+ },
237
+ { deep: !0, immediate: !0 }
238
+ ), (u, s) => {
239
+ const v = de("VfMenu");
240
+ return p(), b("div", {
241
+ class: k(["vf-menu", `vf-menu_${u.orientation}`])
242
+ }, [
243
+ $("ul", bt, [
244
+ (p(!0), b(ne, null, ye(n.value, (i, m) => (p(), b("li", {
245
+ key: d(i, m),
246
+ class: "vf-menu__item",
247
+ role: "none"
248
+ }, [
249
+ u.$slots[d(i, m)] ? g(u.$slots, d(i, m), {
559
250
  key: 0,
560
- items: c.items,
561
- class: h(["vf-menu__submenu", { "vf-menu__submenu_visible": c.subMenuVisible }]),
562
- onOnActive: f
563
- }, null, 8, ["items", "class"])) : m("", !0)
564
- ], 64)) : (r(), y(g(T), {
565
- key: 3,
566
- to: c.to,
567
- url: c.url,
568
- type: l(c),
569
- class: "vf-menu__link",
570
- active: c.active,
571
- disabled: c.disabled,
572
- onClick: (P) => b(c),
573
- onOnActive: (P) => f(c)
574
- }, {
575
- default: _(() => [
576
- c.icon ? (r(), y(g(k), {
251
+ item: { ...i, class: "vf-menu__link" }
252
+ }) : i.separator ? (p(), b("hr", gt)) : i.items && i.items.length ? (p(), b(ne, { key: 2 }, [
253
+ $("div", {
254
+ class: k(["vf-menu__parent", { "vf-menu__parent_active": i.active }]),
255
+ role: "menuitem",
256
+ tabindex: "0",
257
+ "aria-expanded": i.subMenuVisible ? "true" : "false",
258
+ onClick: (_) => l(i),
259
+ onKeydown: [
260
+ K(q((_) => l(i), ["prevent"]), ["enter"]),
261
+ K(q((_) => l(i), ["prevent"]), ["space"])
262
+ ]
263
+ }, [
264
+ i.icon ? (p(), V(J(Q), {
265
+ key: 0,
266
+ icon: i.icon,
267
+ class: "vf-menu__icon"
268
+ }, null, 8, ["icon"])) : w("", !0),
269
+ ee(" " + H(i.label) + " ", 1),
270
+ Z(J(Q), { icon: "chevronDown" })
271
+ ], 42, mt),
272
+ i.items ? (p(), V(v, {
577
273
  key: 0,
578
- icon: c.icon,
579
- class: "vf-menu__icon"
580
- }, null, 8, ["icon"])) : m("", !0),
581
- z(" " + O(c.label), 1)
582
- ]),
583
- _: 2
584
- }, 1032, ["to", "url", "type", "active", "disabled", "onClick", "onOnActive"]))
585
- ]))), 128))
586
- ])
587
- ], 2));
274
+ items: i.items,
275
+ class: k(["vf-menu__submenu", { "vf-menu__submenu_visible": i.subMenuVisible }]),
276
+ onOnActive: f
277
+ }, null, 8, ["items", "class"])) : w("", !0)
278
+ ], 64)) : (p(), V(ue, {
279
+ key: 3,
280
+ to: i.to,
281
+ href: i.href ?? i.url,
282
+ as: a(i),
283
+ class: "vf-menu__link",
284
+ active: i.active,
285
+ disabled: i.disabled,
286
+ role: "menuitem",
287
+ "aria-disabled": i.disabled ? "true" : "false",
288
+ onClick: (_) => l(i),
289
+ onActive: (_) => f(i)
290
+ }, {
291
+ default: L(() => [
292
+ i.icon ? (p(), V(J(Q), {
293
+ key: 0,
294
+ icon: i.icon,
295
+ class: "vf-menu__icon"
296
+ }, null, 8, ["icon"])) : w("", !0),
297
+ ee(" " + H(i.label), 1)
298
+ ]),
299
+ _: 2
300
+ }, 1032, ["to", "href", "as", "active", "disabled", "aria-disabled", "onClick", "onActive"]))
301
+ ]))), 128))
302
+ ])
303
+ ], 2);
304
+ };
588
305
  }
589
- }), Go = {}, Wo = { class: "vf-header" };
590
- function Jo(o, e) {
591
- return r(), s("header", Wo, [
592
- u(o.$slots, "default")
593
- ]);
594
- }
595
- const Qo = /* @__PURE__ */ $(Go, [["render", Jo]]), Xo = {}, Yo = { class: "vf-footer" };
596
- function er(o, e) {
597
- return r(), s("footer", Yo, [
598
- u(o.$slots, "default")
599
- ]);
600
- }
601
- const or = /* @__PURE__ */ $(Xo, [["render", er]]), rr = ["disabled"], zr = /* @__PURE__ */ F({
306
+ }), yt = ["type", "disabled"], Ko = /* @__PURE__ */ E({
602
307
  __name: "button",
603
308
  props: {
604
309
  to: { default: void 0 },
310
+ href: { default: void 0 },
311
+ url: { default: void 0 },
312
+ as: { default: void 0 },
605
313
  icon: { default: void 0 },
606
314
  type: { default: "button" },
607
315
  size: { default: "normal" },
@@ -613,151 +321,997 @@ const or = /* @__PURE__ */ $(Xo, [["render", er]]), rr = ["disabled"], zr = /* @
613
321
  severity: { default: "primary" },
614
322
  disabled: { type: Boolean, default: !1 }
615
323
  },
616
- setup(o) {
617
- const e = o, a = w(() => {
618
- let l = ["vf-button", `vf-button_${e.severity}`];
619
- return ["top", "bottom"].includes(e.iconPos) && l.push("vf-button_vertical"), e.variant === "text" && l.push("vf-button_text"), e.variant === "outlined" && l.push("vf-button_outlined"), ["small", "large"].indexOf(e.size) > -1 && l.push(`vf-button_${e.size}`), (e.loading || e.disabled) && l.push("vf-button_disabled"), e.rounded && l.push("vf-button_rounded"), l;
620
- }), t = w(() => ["vf-button__icon", `vf-button__icon_${e.iconPos}`]), n = w(() => ["vf-button__label"]);
621
- return (l, b) => e.type === "button" ? (r(), s("button", {
324
+ setup(t) {
325
+ const e = t, r = ["button", "submit", "reset"], o = (u) => !!u && r.includes(u), n = C(() => e.as ? e.as === "button" : !(e.to || e.href || e.url || e.type && !o(e.type))), d = C(() => o(e.type) ? e.type : "button"), a = C(() => 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 = C(() => {
326
+ let u = ["vf-button", `vf-button_${e.severity}`];
327
+ return ["top", "bottom"].includes(e.iconPos) && u.push("vf-button_vertical"), e.variant === "text" && u.push("vf-button_text"), e.variant === "outlined" && u.push("vf-button_outlined"), ["small", "large"].indexOf(e.size) > -1 && u.push(`vf-button_${e.size}`), (e.loading || e.disabled) && u.push("vf-button_disabled"), e.rounded && u.push("vf-button_rounded"), u;
328
+ }), l = C(() => ["vf-button__icon", `vf-button__icon_${e.iconPos}`]), f = C(() => ["vf-button__label"]);
329
+ return (u, s) => n.value ? (p(), b("button", {
622
330
  key: 0,
623
- class: h(a.value),
331
+ type: d.value,
332
+ class: k(c.value),
624
333
  disabled: e.loading || e.disabled
625
334
  }, [
626
- e.icon && !e.loading ? (r(), y(g(k), {
335
+ e.icon && !e.loading ? (p(), V(J(Q), {
627
336
  key: 0,
628
337
  icon: e.icon,
629
- class: h(t.value)
630
- }, null, 8, ["icon", "class"])) : m("", !0),
631
- e.loading ? (r(), y(g(k), {
338
+ class: k(l.value)
339
+ }, null, 8, ["icon", "class"])) : w("", !0),
340
+ e.loading ? (p(), V(J(Q), {
632
341
  key: 1,
633
342
  icon: "circleNotch",
634
- class: h(t.value),
343
+ class: k(l.value),
635
344
  spin: ""
636
- }, null, 8, ["class"])) : m("", !0),
637
- l.$slots.default ? (r(), s("span", {
345
+ }, null, 8, ["class"])) : w("", !0),
346
+ u.$slots.default ? (p(), b("span", {
638
347
  key: 2,
639
- class: h(n.value)
348
+ class: k(f.value)
640
349
  }, [
641
- u(l.$slots, "default")
642
- ], 2)) : l.label ? (r(), s("span", {
350
+ g(u.$slots, "default")
351
+ ], 2)) : u.label ? (p(), b("span", {
643
352
  key: 3,
644
- class: h(n.value)
645
- }, O(l.label), 3)) : m("", !0)
646
- ], 10, rr)) : (r(), y(g(T), {
353
+ class: k(f.value)
354
+ }, H(u.label), 3)) : w("", !0)
355
+ ], 10, yt)) : (p(), V(ue, {
647
356
  key: 1,
648
357
  to: e.to,
649
- type: e.type,
650
- class: h(a.value),
358
+ href: e.href ?? e.url,
359
+ as: a.value,
360
+ class: k(c.value),
651
361
  disabled: e.loading || e.disabled
652
362
  }, {
653
- default: _(() => [
654
- e.icon ? (r(), y(g(k), {
363
+ default: L(() => [
364
+ e.icon ? (p(), V(J(Q), {
655
365
  key: 0,
656
366
  icon: e.icon,
657
- class: h(t.value)
658
- }, null, 8, ["icon", "class"])) : m("", !0),
659
- l.$slots.default ? (r(), s("span", {
367
+ class: k(l.value)
368
+ }, null, 8, ["icon", "class"])) : w("", !0),
369
+ u.$slots.default ? (p(), b("span", {
660
370
  key: 1,
661
- class: h(n.value)
371
+ class: k(f.value)
662
372
  }, [
663
- u(l.$slots, "default")
664
- ], 2)) : l.label ? (r(), s("span", {
373
+ g(u.$slots, "default")
374
+ ], 2)) : u.label ? (p(), b("span", {
665
375
  key: 2,
666
- class: h(n.value)
667
- }, O(l.label), 3)) : m("", !0)
376
+ class: k(f.value)
377
+ }, H(u.label), 3)) : w("", !0)
668
378
  ]),
669
379
  _: 3
670
- }, 8, ["to", "type", "class", "disabled"]));
380
+ }, 8, ["to", "href", "as", "class", "disabled"]));
671
381
  }
672
- }), tr = {}, lr = { class: "vf-content" };
673
- function nr(o, e) {
674
- return r(), s("div", lr, [
675
- u(o.$slots, "default")
676
- ]);
382
+ }), _t = {
383
+ key: 0,
384
+ class: "vf-input__prefix"
385
+ }, kt = ["type", "value", "placeholder", "disabled", "readonly"], Ct = {
386
+ key: 1,
387
+ class: "vf-input__suffix"
388
+ }, qo = /* @__PURE__ */ E({
389
+ __name: "input",
390
+ props: {
391
+ modelValue: { default: "" },
392
+ type: { default: "text" },
393
+ placeholder: { default: "" },
394
+ disabled: { type: Boolean, default: !1 },
395
+ readonly: { type: Boolean, default: !1 },
396
+ size: { default: "normal" },
397
+ variant: { default: "filled" }
398
+ },
399
+ emits: ["update:modelValue", "input", "change", "focus", "blur"],
400
+ setup(t, { emit: e }) {
401
+ const r = e, o = t, n = C(() => {
402
+ const f = ["vf-input", `vf-input_${o.variant}`];
403
+ return o.size !== "normal" && f.push(`vf-input_${o.size}`), o.disabled && f.push("vf-input_disabled"), f;
404
+ }), d = (f) => {
405
+ const u = f.target;
406
+ r("update:modelValue", u.value), r("input", f);
407
+ }, a = (f) => r("change", f), c = (f) => r("focus", f), l = (f) => r("blur", f);
408
+ return (f, u) => (p(), b("div", {
409
+ class: k(n.value)
410
+ }, [
411
+ f.$slots.prefix ? (p(), b("span", _t, [
412
+ g(f.$slots, "prefix")
413
+ ])) : w("", !0),
414
+ $("input", {
415
+ class: "vf-input__control",
416
+ type: f.type,
417
+ value: f.modelValue,
418
+ placeholder: f.placeholder,
419
+ disabled: f.disabled,
420
+ readonly: f.readonly,
421
+ onInput: d,
422
+ onChange: a,
423
+ onFocus: c,
424
+ onBlur: l
425
+ }, null, 40, kt),
426
+ f.$slots.suffix ? (p(), b("span", Ct, [
427
+ g(f.$slots, "suffix")
428
+ ])) : w("", !0)
429
+ ], 2));
430
+ }
431
+ }), he = [
432
+ "top",
433
+ "top-start",
434
+ "top-end",
435
+ "right",
436
+ "right-start",
437
+ "right-end",
438
+ "bottom",
439
+ "bottom-start",
440
+ "bottom-end",
441
+ "left",
442
+ "left-start",
443
+ "left-end"
444
+ ], O = (t) => {
445
+ if (t == null || !(t instanceof HTMLElement))
446
+ return null;
447
+ if (typeof window < "u") {
448
+ const e = window.getComputedStyle(t), r = `${e.overflowX}${e.overflowY}`;
449
+ if (/(auto|scroll|overlay)/.test(r))
450
+ return t;
451
+ }
452
+ return t.scrollHeight > t.clientHeight || t.scrollWidth > t.clientWidth ? t : O(t.parentNode);
453
+ };
454
+ function wt(t) {
455
+ return typeof window > "u" ? !1 : window.getComputedStyle(t).position === "fixed";
677
456
  }
678
- const sr = /* @__PURE__ */ $(tr, [["render", nr]]), ar = { class: "vf-popover" }, xr = /* @__PURE__ */ F({
457
+ const $t = (t, e) => t.strategy ? t.strategy : wt(e) ? "fixed" : "absolute", Y = (t, e) => $t(t, e) === "fixed", R = (t, e, r = {}) => {
458
+ const o = t.getBoundingClientRect(), n = e ? e.offsetParent : null, d = e ? Y(r, e) : !1;
459
+ if (n && !d) {
460
+ const a = n.getBoundingClientRect(), c = n.scrollLeft, l = n.scrollTop;
461
+ return {
462
+ left: o.left - a.left + c,
463
+ top: o.top - a.top + l,
464
+ width: o.width,
465
+ height: o.height
466
+ };
467
+ }
468
+ return {
469
+ left: o.left,
470
+ top: o.top,
471
+ width: o.width,
472
+ height: o.height
473
+ };
474
+ }, X = (t, e) => {
475
+ var r;
476
+ return (r = t.middleware) == null ? void 0 : r.find((o) => o.name === e);
477
+ }, Ce = (t, e) => !!X(t, e), Ft = (t) => {
478
+ const e = O(t);
479
+ let r = "";
480
+ 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;
481
+ }, Bt = (t) => t.scrollLeft + t.clientWidth, xt = (t) => t.scrollTop + t.clientHeight, z = (t, e, r = null, o = {}, n) => {
482
+ if (r === null && typeof window < "u" && Y(o, e))
483
+ return t;
484
+ let d = 0;
485
+ if (r === null) {
486
+ const a = O(e);
487
+ d = a ? a.scrollTop : 0;
488
+ }
489
+ return t - d;
490
+ }, W = (t, e, r = null, o = {}, n) => {
491
+ let d;
492
+ if (r === null && typeof window < "u" && Y(o, e))
493
+ d = window.innerWidth;
494
+ else if (r === null) {
495
+ const a = O(e);
496
+ d = a ? Bt(a) : 0;
497
+ } else
498
+ d = r.getBoundingClientRect().width;
499
+ return -(t + e.clientWidth - d);
500
+ }, P = (t, e, r = null, o = {}, n) => {
501
+ let d;
502
+ if (r === null && typeof window < "u" && Y(o, e))
503
+ d = window.innerHeight;
504
+ else if (r === null) {
505
+ const a = O(e);
506
+ d = a ? xt(a) : 0;
507
+ } else
508
+ d = r.getBoundingClientRect().height;
509
+ return -(t + e.clientHeight - d);
510
+ }, M = (t, e, r = null, o = {}, n) => {
511
+ if (r === null && typeof window < "u" && Y(o, e))
512
+ return t;
513
+ let d = 0;
514
+ if (r === null) {
515
+ const a = O(e);
516
+ d = a ? a.scrollLeft : 0;
517
+ }
518
+ return t - d;
519
+ }, be = ({
520
+ options: t,
521
+ primaryX: e,
522
+ primaryY: r,
523
+ floating: o,
524
+ placement: n,
525
+ reference: d,
526
+ scrollDirection: a
527
+ }) => {
528
+ const c = ie(d, o, n, t), l = X(t, "offset");
529
+ if (l) {
530
+ const f = l.fn({
531
+ x: c.x,
532
+ y: c.y,
533
+ options: t,
534
+ primaryX: e,
535
+ primaryY: r,
536
+ floating: o,
537
+ placement: n,
538
+ reference: d,
539
+ scrollDirection: a
540
+ });
541
+ c.x = f.x, c.y = f.y;
542
+ }
543
+ return Kt(c, o, d, t) ? {
544
+ x: c.x,
545
+ y: c.y,
546
+ placement: n
547
+ } : !1;
548
+ }, Tt = (t) => ({
549
+ name: "flip",
550
+ params: t,
551
+ fn: ({
552
+ x: e,
553
+ y: r,
554
+ options: o,
555
+ primaryX: n,
556
+ primaryY: d,
557
+ floating: a,
558
+ placement: c,
559
+ reference: l,
560
+ scrollDirection: f
561
+ }) => {
562
+ var u;
563
+ const s = {
564
+ x: e,
565
+ y: r,
566
+ placement: c
567
+ }, v = {
568
+ ...o,
569
+ middleware: (u = o.middleware) == null ? void 0 : u.filter((x) => x.name !== "shift")
570
+ }, i = (t == null ? void 0 : t.placements) ?? he, m = !(t != null && t.placements), _ = m ? he : i;
571
+ let y = !1;
572
+ const te = (x) => {
573
+ if (y)
574
+ return;
575
+ const B = be({
576
+ options: v,
577
+ primaryX: n,
578
+ primaryY: d,
579
+ floating: a,
580
+ placement: x,
581
+ reference: l,
582
+ scrollDirection: f
583
+ });
584
+ B && (s.x = B.x, s.y = B.y, s.placement = B.placement, y = !0);
585
+ }, oe = Ut(l, a, v);
586
+ if (!m && i.includes(c) && te(c), y || _.forEach(te), !y) {
587
+ const x = i.reduce(
588
+ (B, A) => {
589
+ const N = be({
590
+ options: v,
591
+ primaryX: n,
592
+ primaryY: d,
593
+ floating: a,
594
+ placement: A,
595
+ reference: l,
596
+ scrollDirection: f
597
+ });
598
+ if (!N)
599
+ return B;
600
+ const S = re(A), I = oe[S];
601
+ return !B || I > B.space ? { result: N, space: I } : B;
602
+ },
603
+ null
604
+ );
605
+ x && (s.x = x.result.x, s.y = x.result.y, s.placement = x.result.placement, y = !0);
606
+ }
607
+ if (!y && i.length > 0) {
608
+ const x = re(c);
609
+ let B = x, A = oe[x];
610
+ i.forEach((G) => {
611
+ const h = re(G), F = oe[h];
612
+ F > A && (A = F, B = h);
613
+ });
614
+ const N = qt(B, c, i), S = ie(l, a, N, v), I = X(v, "offset");
615
+ if (I) {
616
+ const G = I.fn({
617
+ x: S.x,
618
+ y: S.y,
619
+ options: v,
620
+ primaryX: n,
621
+ primaryY: d,
622
+ floating: a,
623
+ placement: N,
624
+ reference: l,
625
+ scrollDirection: f
626
+ });
627
+ S.x = G.x, S.y = G.y;
628
+ }
629
+ s.x = S.x, s.y = S.y, s.placement = S.placement;
630
+ }
631
+ return s;
632
+ }
633
+ }), Lt = (t, e, r, o, n) => {
634
+ var d, a, c;
635
+ let l = 0;
636
+ o.startsWith("right") ? l = -2 : o.startsWith("left") && (l = t);
637
+ const f = X(e, "arrow"), u = X(e, "shift");
638
+ if (f) {
639
+ const s = ((d = f.params) == null ? void 0 : d.arrow).getBoundingClientRect();
640
+ o.startsWith("right") ? l -= s.width / 2 : o.startsWith("left") && (l += s.width / 2);
641
+ }
642
+ if (Ce(e, "shift") && f) {
643
+ let s = null, v = 0;
644
+ u && (s = (a = u.params) == null ? void 0 : a.parent);
645
+ const i = (c = f.params) == null ? void 0 : c.arrow;
646
+ v = i.getBoundingClientRect().width / 2, v += Vt(i), v -= t, o.startsWith("right") ? W(r - l, n, s, e) <= t ? W(r, n, s, e) > 0 ? l = t - W(r, n, s, e) : l = t : M(r - l - v, n, s, e) <= t && (M(r - l - v, n, s, e) >= 0 ? (l = -2 - (M(r - l - v, n, s, e) + t), s && (l = -2)) : l = -2) : o.startsWith("left") ? W(r - l + v, n, s, e) <= t ? (l = t + W(r - v, n, s, e), l <= t && (l = t)) : M(r - l, n, s, e) <= t && (l = -2 + M(r, n, s, e), l <= -2 && (l = -2)) : W(r - l, n, s, e) <= t ? W(r - l, n, s, e) <= t && W(r, n, s, e) > 0 ? l = t - W(r, n, s, e) : l = t : M(r - l, n, s, e) <= t && (M(r - l, n, s, e) <= t && M(r, n, s, e) > 0 ? l = -(t - M(r, n, s, e)) : l = -2);
647
+ }
648
+ return l;
649
+ }, Rt = (t, e, r, o, n) => {
650
+ var d, a, c;
651
+ let l = 0;
652
+ o.startsWith("top") ? l = t : o.startsWith("bottom") && (l = -2);
653
+ const f = X(e, "arrow"), u = X(e, "shift");
654
+ if (f) {
655
+ const s = ((d = f.params) == null ? void 0 : d.arrow).getBoundingClientRect();
656
+ o.startsWith("top") ? l += s.height / 2 : o.startsWith("bottom") && (l -= s.height / 2);
657
+ }
658
+ if (Ce(e, "shift") && f) {
659
+ let s = null, v = 0;
660
+ u && (s = (a = u.params) == null ? void 0 : a.parent);
661
+ const i = (c = f.params) == null ? void 0 : c.arrow;
662
+ v = i.getBoundingClientRect().height / 2, v += zt(i), v -= t, o.startsWith("top") ? z(r - l, n, s, e) <= t ? z(r, n, s, e) >= 0 ? l = -(t - z(r, n, s, e)) : l = -2 : P(r - l + v, n, s, e) <= t && (l = t + P(r - v, n, s, e), l <= t && (l = t)) : o.startsWith("bottom") ? z(r - l - v, n, s, e) <= t ? z(r - l - v, n, s, e) >= 0 ? (l = -2 - (z(r - l - v, n, s, e) + t), s && (l = -2)) : l = -2 : P(r - l, n, s, e) <= t && (P(r, n, s, e) >= 0 ? l = t - P(r, n, s, e) : l = t) : z(r - l, n, s, e) <= t ? z(r - l, n, s, e) >= 0 ? l = -(t - z(r - l, n, s, e)) : l = -2 : P(r - l, n, s, e) <= t && (P(r - l, n, s, e) >= 0 ? l = t - P(r - l, n, s, e) : l = t);
663
+ }
664
+ return l;
665
+ }, St = (t) => ({
666
+ name: "offset",
667
+ params: { value: t },
668
+ fn: ({
669
+ x: e,
670
+ y: r,
671
+ options: o,
672
+ primaryX: n,
673
+ primaryY: d,
674
+ floating: a,
675
+ placement: c
676
+ }) => ({
677
+ x: e - Lt(t, o, n, c, a),
678
+ y: r - Rt(t, o, d, c, a),
679
+ placement: c
680
+ })
681
+ }), Vt = (t) => t.getBoundingClientRect().width !== t.clientWidth ? (t.getBoundingClientRect().width - t.clientWidth) / 2 : 0, zt = (t) => t.getBoundingClientRect().height !== t.clientHeight ? (t.getBoundingClientRect().height - t.clientHeight) / 2 : 0, Wt = (t, e) => {
682
+ const r = O(t), o = [];
683
+ if (r !== null) {
684
+ const n = () => e();
685
+ r.addEventListener("scroll", n, !1), o.push(() => r.removeEventListener("scroll", n, !1));
686
+ }
687
+ if (typeof window < "u") {
688
+ const n = () => e(), d = () => e();
689
+ window.addEventListener("scroll", n, !1), window.addEventListener("resize", d, !1), o.push(() => window.removeEventListener("scroll", n, !1)), o.push(() => window.removeEventListener("resize", d, !1));
690
+ }
691
+ if (typeof ResizeObserver < "u" && t instanceof HTMLElement) {
692
+ const n = new ResizeObserver(() => e());
693
+ n.observe(t), o.push(() => n.disconnect());
694
+ }
695
+ return () => o.forEach((n) => n());
696
+ }, Mt = (t, e, r = {}) => {
697
+ const o = R(t, e, r);
698
+ return {
699
+ x: o.left - e.getBoundingClientRect().width / 2 + o.width / 2,
700
+ y: o.top - e.getBoundingClientRect().height,
701
+ placement: "top"
702
+ };
703
+ }, Ht = (t, e, r = {}) => {
704
+ const o = R(t, e, r);
705
+ return {
706
+ x: o.left,
707
+ y: o.top - e.getBoundingClientRect().height,
708
+ placement: "top-start"
709
+ };
710
+ }, Et = (t, e, r = {}) => {
711
+ const o = R(t, e, r);
712
+ return {
713
+ x: o.left - e.getBoundingClientRect().width + o.width,
714
+ y: o.top - e.getBoundingClientRect().height,
715
+ placement: "top-end"
716
+ };
717
+ }, At = (t, e, r = {}) => {
718
+ const o = R(t, e, r);
719
+ return {
720
+ x: o.left + o.width,
721
+ y: o.top - e.getBoundingClientRect().height / 2 + o.height / 2,
722
+ placement: "right"
723
+ };
724
+ }, Pt = (t, e, r = {}) => {
725
+ const o = R(t, e, r);
726
+ return {
727
+ x: o.left + o.width,
728
+ y: o.top,
729
+ placement: "right-start"
730
+ };
731
+ }, Dt = (t, e, r = {}) => {
732
+ const o = R(t, e, r);
733
+ return {
734
+ x: o.left + o.width,
735
+ y: o.top + o.height - e.getBoundingClientRect().height,
736
+ placement: "right-end"
737
+ };
738
+ }, Ot = (t, e, r = {}) => {
739
+ const o = R(t, e, r);
740
+ return {
741
+ x: o.left + o.width / 2 - e.getBoundingClientRect().width / 2,
742
+ y: o.top + o.height,
743
+ placement: "bottom"
744
+ };
745
+ }, Nt = (t, e, r = {}) => {
746
+ const o = R(t, e, r);
747
+ return {
748
+ x: o.left,
749
+ y: o.top + o.height,
750
+ placement: "bottom-start"
751
+ };
752
+ }, It = (t, e, r = {}) => {
753
+ const o = R(t, e, r);
754
+ return {
755
+ x: o.left - e.getBoundingClientRect().width + o.width,
756
+ y: o.top + o.height,
757
+ placement: "bottom-end"
758
+ };
759
+ }, jt = (t, e, r = {}) => {
760
+ const o = R(t, e, r);
761
+ return {
762
+ x: o.left - e.getBoundingClientRect().width,
763
+ y: o.top + o.height / 2 - e.getBoundingClientRect().height / 2,
764
+ placement: "left"
765
+ };
766
+ }, Xt = (t, e, r = {}) => {
767
+ const o = R(t, e, r);
768
+ return {
769
+ x: o.left - e.getBoundingClientRect().width,
770
+ y: o.top,
771
+ placement: "left-start"
772
+ };
773
+ }, Yt = (t, e, r = {}) => {
774
+ const o = R(t, e, r);
775
+ return {
776
+ x: o.left - e.getBoundingClientRect().width,
777
+ y: o.top + o.height - e.getBoundingClientRect().height,
778
+ placement: "left-end"
779
+ };
780
+ }, ie = (t, e, r, o = {}) => {
781
+ switch (r) {
782
+ case "top":
783
+ return Mt(t, e, o);
784
+ case "top-start":
785
+ return Ht(t, e, o);
786
+ case "top-end":
787
+ return Et(t, e, o);
788
+ case "right":
789
+ return At(t, e, o);
790
+ case "right-start":
791
+ return Pt(t, e, o);
792
+ case "right-end":
793
+ return Dt(t, e, o);
794
+ case "bottom":
795
+ return Ot(t, e, o);
796
+ case "bottom-start":
797
+ return Nt(t, e, o);
798
+ case "bottom-end":
799
+ return It(t, e, o);
800
+ case "left":
801
+ return jt(t, e, o);
802
+ case "left-start":
803
+ return Xt(t, e, o);
804
+ case "left-end":
805
+ return Yt(t, e, o);
806
+ default:
807
+ return {
808
+ x: 0,
809
+ y: 0,
810
+ placement: ""
811
+ };
812
+ }
813
+ }, Kt = (t, e, r, o = {}) => {
814
+ if (Y(o, e)) {
815
+ if (typeof window > "u")
816
+ return !0;
817
+ const s = t.x, v = t.y, i = s + e.clientWidth, m = v + e.clientHeight;
818
+ return s >= 0 && v >= 0 && i <= window.innerWidth && m <= window.innerHeight;
819
+ }
820
+ if (O(r) !== null)
821
+ return z(t.y, e, null, o) > 0 && W(t.x, e, null, o) > 0 && P(t.y, e, null, o) > 0 && M(t.x, e, null, o) > 0;
822
+ if (typeof window > "u")
823
+ return !0;
824
+ const n = window.innerWidth, d = window.innerHeight, a = (r instanceof HTMLElement ? r.offsetParent : null) || e.offsetParent;
825
+ if (a) {
826
+ const s = a.getBoundingClientRect(), v = s.left + t.x, i = s.top + t.y, m = v + e.clientWidth, _ = i + e.clientHeight;
827
+ return v >= 0 && i >= 0 && m <= n && _ <= d;
828
+ }
829
+ const c = t.x, l = t.y, f = c + e.clientWidth, u = l + e.clientHeight;
830
+ return c >= 0 && l >= 0 && f <= n && u <= d;
831
+ }, re = (t) => t.startsWith("right") ? "right" : t.startsWith("left") ? "left" : t.startsWith("top") ? "top" : "bottom", qt = (t, e, r) => re(e) === t && r.includes(e) ? e : r.find((o) => re(o) === t) ?? r[0], Ut = (t, e, r = {}) => {
832
+ if (typeof window > "u")
833
+ return {
834
+ top: 0,
835
+ right: 0,
836
+ bottom: 0,
837
+ left: 0
838
+ };
839
+ const o = Y(r, e) ? null : O(t), n = t.getBoundingClientRect(), d = o ? o.getBoundingClientRect() : {
840
+ top: 0,
841
+ left: 0,
842
+ right: window.innerWidth,
843
+ bottom: window.innerHeight
844
+ };
845
+ return {
846
+ top: n.top - d.top,
847
+ right: d.right - n.right,
848
+ bottom: d.bottom - n.bottom,
849
+ left: n.left - d.left
850
+ };
851
+ }, Gt = (t, e, r = {}) => new Promise((o) => {
852
+ var n, d;
853
+ const a = r.placement ? r.placement : "bottom", c = {
854
+ x: 0,
855
+ y: 0,
856
+ placement: a,
857
+ middlewareData: {}
858
+ }, l = ie(t, e, a, r);
859
+ c.x = l.x, c.y = l.y, c.placement = l.placement;
860
+ const f = c.x, u = c.y, s = Ft(t);
861
+ (n = r.middleware) == null || n.forEach((_) => {
862
+ const y = _.fn({
863
+ x: c.x,
864
+ y: c.y,
865
+ options: r,
866
+ primaryX: f,
867
+ primaryY: u,
868
+ floating: e,
869
+ placement: c.placement,
870
+ reference: t,
871
+ scrollDirection: s
872
+ });
873
+ c.x = y.x, c.y = y.y, c.placement = y.placement, _.name === "arrow" && (y.baseX = y.x, y.baseY = y.y, y.x = y.arrowX ?? y.x, y.y = y.arrowY ?? y.y), c.middlewareData[_.name] = y;
874
+ });
875
+ const v = ie(t, e, c.placement, r), i = X(r, "offset"), m = i ? (d = i.params) == null ? void 0 : d.value : 0;
876
+ if (Number.isFinite(c.x) || (c.x = v.x), !Number.isFinite(c.y))
877
+ if (Y(r, e)) {
878
+ const _ = t.getBoundingClientRect(), y = e.getBoundingClientRect().height;
879
+ c.placement.startsWith("top") ? c.y = _.top - y - m : c.placement.startsWith("bottom") ? c.y = _.bottom + m : c.y = v.y;
880
+ } else
881
+ c.y = v.y;
882
+ o(c);
883
+ }), Zt = ["disabled", "aria-expanded", "onKeydown"], Jt = ["data-placement"], Qt = ["disabled", "aria-selected", "onClick"], Uo = /* @__PURE__ */ E({
884
+ __name: "select",
885
+ props: {
886
+ modelValue: { default: void 0 },
887
+ options: { default: () => [] },
888
+ optionLabel: { default: "label" },
889
+ optionValue: { default: "value" },
890
+ placeholder: { default: "" },
891
+ disabled: { type: Boolean, default: !1 },
892
+ size: { default: "normal" }
893
+ },
894
+ emits: ["update:modelValue", "change", "focus", "blur"],
895
+ setup(t, { emit: e }) {
896
+ let r = 0;
897
+ const o = e, n = t, d = j(null), a = j(null), c = j(null), l = j(!1), f = j("bottom"), u = j("bottom"), s = `vf-select-panel-${++r}`;
898
+ let v = null;
899
+ const i = C(() => n.options.map((h) => ({
900
+ label: h[n.optionLabel],
901
+ value: h[n.optionValue],
902
+ disabled: h.disabled
903
+ }))), m = C(() => i.value.find((h) => h.value === n.modelValue)), _ = C(() => {
904
+ var h;
905
+ return ((h = m.value) == null ? void 0 : h.label) ?? "";
906
+ }), y = C(() => {
907
+ const h = ["vf-select", l.value ? "vf-select_open" : ""];
908
+ return n.size !== "normal" && h.push(`vf-select_${n.size}`), n.disabled && h.push("vf-select_disabled"), h.filter(Boolean);
909
+ }), te = (h) => h.value === n.modelValue, oe = (h) => {
910
+ h.disabled || (o("update:modelValue", h.value), o("change", h.value), A());
911
+ }, x = (h) => o("focus", h), B = (h) => o("blur", h), A = () => {
912
+ l.value = !1, f.value = "bottom", u.value = "bottom";
913
+ }, N = () => {
914
+ n.disabled || (l.value = !l.value, l.value && (f.value = "bottom", u.value = "bottom"));
915
+ }, S = async () => {
916
+ var h, F;
917
+ l.value || (l.value = !0, await pe()), (F = (h = c.value) == null ? void 0 : h.querySelector(".vf-select__option:not(.is-disabled)")) == null || F.focus();
918
+ }, I = (h) => {
919
+ var T;
920
+ if (!l.value || !d.value)
921
+ return;
922
+ const F = h.target;
923
+ d.value.contains(F) || (T = c.value) != null && T.contains(F) || A();
924
+ }, G = () => {
925
+ if (!a.value || !c.value)
926
+ return;
927
+ const h = a.value, F = c.value, T = async () => {
928
+ const {
929
+ x: xe,
930
+ y: Te,
931
+ placement: Le
932
+ } = await Gt(h, F, {
933
+ placement: f.value,
934
+ strategy: "fixed",
935
+ middleware: [St(2), Tt({ placements: ["bottom", "top"] })]
936
+ });
937
+ u.value = Le ?? f.value, F.style.minWidth = `${h.getBoundingClientRect().width}px`, F.style.left = `${xe}px`, F.style.top = `${Te}px`;
938
+ }, le = async () => {
939
+ await T();
940
+ }, Be = Wt(h, () => {
941
+ le();
942
+ }), se = () => {
943
+ le();
944
+ };
945
+ document.addEventListener("scroll", se, !0), window.addEventListener("resize", se, !1), v = {
946
+ update: le,
947
+ destroy: () => {
948
+ Be(), document.removeEventListener("scroll", se, !0), window.removeEventListener("resize", se, !1);
949
+ }
950
+ }, v.update();
951
+ };
952
+ return ae(l, async (h) => {
953
+ if (!h) {
954
+ v && (v.destroy(), v = null);
955
+ return;
956
+ }
957
+ await pe(), v || G(), v == null || v.update();
958
+ }), ae(
959
+ () => n.options,
960
+ () => {
961
+ v == null || v.update();
962
+ },
963
+ { deep: !0 }
964
+ ), Re(() => {
965
+ document.addEventListener("click", I);
966
+ }), Se(() => {
967
+ document.removeEventListener("click", I), v == null || v.destroy(), v = null;
968
+ }), (h, F) => (p(), b("div", {
969
+ ref_key: "root",
970
+ ref: d,
971
+ class: k(y.value)
972
+ }, [
973
+ $("button", {
974
+ ref_key: "trigger",
975
+ ref: a,
976
+ class: "vf-select__control",
977
+ type: "button",
978
+ disabled: h.disabled,
979
+ "aria-expanded": l.value,
980
+ "aria-controls": s,
981
+ "aria-haspopup": "listbox",
982
+ onClick: N,
983
+ onKeydown: [
984
+ K(q(S, ["prevent"]), ["down"]),
985
+ K(q(N, ["prevent"]), ["enter"]),
986
+ K(q(A, ["prevent"]), ["esc"])
987
+ ],
988
+ onFocus: x,
989
+ onBlur: B
990
+ }, [
991
+ $("span", {
992
+ class: k(["vf-select__label", { "vf-select__label_placeholder": !_.value }])
993
+ }, H(_.value || h.placeholder), 3),
994
+ F[0] || (F[0] = $("span", {
995
+ class: "vf-select__chevron",
996
+ "aria-hidden": "true"
997
+ }, "▾", -1))
998
+ ], 40, Zt),
999
+ (p(), V(Ve, { to: "body" }, [
1000
+ _e($("div", {
1001
+ id: s,
1002
+ ref_key: "panel",
1003
+ ref: c,
1004
+ class: "vf-select__panel",
1005
+ role: "listbox",
1006
+ "data-placement": u.value
1007
+ }, [
1008
+ (p(!0), b(ne, null, ye(i.value, (T) => (p(), b("button", {
1009
+ key: T.value,
1010
+ class: k(["vf-select__option", { "is-active": te(T), "is-disabled": T.disabled }]),
1011
+ type: "button",
1012
+ role: "option",
1013
+ disabled: T.disabled,
1014
+ "aria-selected": te(T),
1015
+ onClick: (le) => oe(T)
1016
+ }, H(T.label), 11, Qt))), 128))
1017
+ ], 8, Jt), [
1018
+ [ke, l.value]
1019
+ ])
1020
+ ]))
1021
+ ], 2));
1022
+ }
1023
+ }), eo = ["checked", "disabled"], to = {
1024
+ key: 0,
1025
+ class: "vf-checkbox__label"
1026
+ }, Go = /* @__PURE__ */ E({
1027
+ __name: "checkbox",
1028
+ props: {
1029
+ modelValue: { type: Boolean, default: !1 },
1030
+ label: { default: "" },
1031
+ disabled: { type: Boolean, default: !1 }
1032
+ },
1033
+ emits: ["update:modelValue", "change"],
1034
+ setup(t, { emit: e }) {
1035
+ const r = e, o = t, n = C(() => {
1036
+ const a = ["vf-checkbox"];
1037
+ return o.disabled && a.push("vf-checkbox_disabled"), a;
1038
+ }), d = (a) => {
1039
+ const c = a.target;
1040
+ r("update:modelValue", c.checked), r("change", a);
1041
+ };
1042
+ return (a, c) => (p(), b("label", {
1043
+ class: k(n.value)
1044
+ }, [
1045
+ $("input", {
1046
+ class: "vf-checkbox__control",
1047
+ type: "checkbox",
1048
+ checked: a.modelValue,
1049
+ disabled: a.disabled,
1050
+ onChange: d
1051
+ }, null, 40, eo),
1052
+ c[0] || (c[0] = $("span", { class: "vf-checkbox__box" }, null, -1)),
1053
+ a.label || a.$slots.default ? (p(), b("span", to, [
1054
+ g(a.$slots, "default", {}, () => [
1055
+ ee(H(a.label), 1)
1056
+ ])
1057
+ ])) : w("", !0)
1058
+ ], 2));
1059
+ }
1060
+ }), oo = ["checked", "disabled"], ro = {
1061
+ key: 0,
1062
+ class: "vf-switch__label"
1063
+ }, Zo = /* @__PURE__ */ E({
1064
+ __name: "switch",
1065
+ props: {
1066
+ modelValue: { type: Boolean, default: !1 },
1067
+ label: { default: "" },
1068
+ disabled: { type: Boolean, default: !1 }
1069
+ },
1070
+ emits: ["update:modelValue", "change"],
1071
+ setup(t, { emit: e }) {
1072
+ const r = e, o = t, n = C(() => {
1073
+ const a = ["vf-switch"];
1074
+ return o.disabled && a.push("vf-switch_disabled"), a;
1075
+ }), d = (a) => {
1076
+ const c = a.target;
1077
+ r("update:modelValue", c.checked), r("change", a);
1078
+ };
1079
+ return (a, c) => (p(), b("label", {
1080
+ class: k(n.value)
1081
+ }, [
1082
+ $("input", {
1083
+ class: "vf-switch__control",
1084
+ type: "checkbox",
1085
+ checked: a.modelValue,
1086
+ disabled: a.disabled,
1087
+ onChange: d
1088
+ }, null, 40, oo),
1089
+ c[0] || (c[0] = $("span", { class: "vf-switch__track" }, [
1090
+ $("span", { class: "vf-switch__thumb" })
1091
+ ], -1)),
1092
+ a.label || a.$slots.default ? (p(), b("span", ro, [
1093
+ g(a.$slots, "default", {}, () => [
1094
+ ee(H(a.label), 1)
1095
+ ])
1096
+ ])) : w("", !0)
1097
+ ], 2));
1098
+ }
1099
+ }), no = { class: "vf-popover" }, lo = ["aria-expanded", "onKeydown"], Jo = /* @__PURE__ */ E({
679
1100
  __name: "popover",
680
- emits: ["onClick"],
681
- setup(o, { expose: e, emit: a }) {
682
- const t = a, n = W({ visible: !1 }), l = () => n.visible = !0, b = () => n.visible = !1, f = () => n.visible = !n.visible, d = () => t("onClick");
683
- return e({ show: l, hide: b, toggle: f }), (v, c) => (r(), s("div", ar, [
684
- i("div", {
1101
+ emits: ["click", "onClick"],
1102
+ setup(t, { expose: e, emit: r }) {
1103
+ const o = r, n = ze({ visible: !1 });
1104
+ let d = 0;
1105
+ const a = `vf-popover-panel-${++d}`, c = () => n.visible = !0, l = () => n.visible = !1, f = () => n.visible = !n.visible, u = () => {
1106
+ f(), o("click"), o("onClick");
1107
+ };
1108
+ return e({ show: c, hide: l, toggle: f }), (s, v) => (p(), b("div", no, [
1109
+ $("div", {
685
1110
  class: "vf-popover__button",
686
- onClick: d
1111
+ role: "button",
1112
+ tabindex: "0",
1113
+ "aria-haspopup": "dialog",
1114
+ "aria-expanded": n.visible,
1115
+ "aria-controls": a,
1116
+ onClick: u,
1117
+ onKeydown: [
1118
+ K(q(u, ["prevent"]), ["enter"]),
1119
+ K(q(u, ["prevent"]), ["space"])
1120
+ ]
687
1121
  }, [
688
- u(v.$slots, "button")
689
- ]),
690
- J(S(g(_e), { class: "vf-popover__wrapper" }, Q({
691
- default: _(() => [
692
- c[0] || (c[0] = i("div", { class: "vf-popover__arrow" }, null, -1))
1122
+ g(s.$slots, "button")
1123
+ ], 40, lo),
1124
+ _e(Z(ft, {
1125
+ id: a,
1126
+ class: "vf-popover__wrapper"
1127
+ }, We({
1128
+ default: L(() => [
1129
+ v[0] || (v[0] = $("div", { class: "vf-popover__arrow" }, null, -1))
693
1130
  ]),
694
1131
  _: 2
695
1132
  }, [
696
- v.$slots.default ? {
1133
+ s.$slots.default ? {
697
1134
  name: "default",
698
- fn: _(() => [
699
- u(v.$slots, "default")
1135
+ fn: L(() => [
1136
+ g(s.$slots, "default")
700
1137
  ]),
701
1138
  key: "0"
702
1139
  } : void 0,
703
- v.$slots.popoverHeader ? {
1140
+ s.$slots.header || s.$slots.popoverHeader ? {
704
1141
  name: "header",
705
- fn: _(() => [
706
- u(v.$slots, "popoverHeader")
1142
+ fn: L(() => [
1143
+ g(s.$slots, "header"),
1144
+ s.$slots.header ? w("", !0) : g(s.$slots, "popoverHeader", { key: 0 })
707
1145
  ]),
708
1146
  key: "1"
709
1147
  } : void 0,
710
- v.$slots.popoverBody ? {
1148
+ s.$slots.body || s.$slots.popoverBody ? {
711
1149
  name: "body",
712
- fn: _(() => [
713
- u(v.$slots, "popoverBody")
1150
+ fn: L(() => [
1151
+ g(s.$slots, "body"),
1152
+ s.$slots.body ? w("", !0) : g(s.$slots, "popoverBody", { key: 0 })
714
1153
  ]),
715
1154
  key: "2"
716
1155
  } : void 0,
717
- v.$slots.popoverFooter ? {
1156
+ s.$slots.footer || s.$slots.popoverFooter ? {
718
1157
  name: "footer",
719
- fn: _(() => [
720
- u(v.$slots, "popoverFooter")
1158
+ fn: L(() => [
1159
+ g(s.$slots, "footer"),
1160
+ s.$slots.footer ? w("", !0) : g(s.$slots, "popoverFooter", { key: 0 })
721
1161
  ]),
722
1162
  key: "3"
723
1163
  } : void 0
724
1164
  ]), 1536), [
725
- [X, n.visible]
1165
+ [ke, n.visible]
726
1166
  ])
727
1167
  ]));
728
1168
  }
729
- }), cr = {}, ir = { class: "vf-container" };
730
- function ur(o, e) {
731
- return r(), s("div", ir, [
732
- u(o.$slots, "default")
1169
+ }), so = {}, ao = { class: "vf-container" };
1170
+ function io(t, e) {
1171
+ return p(), b("div", ao, [
1172
+ g(t.$slots, "default")
733
1173
  ]);
734
1174
  }
735
- const Tr = /* @__PURE__ */ $(cr, [["render", ur]]), Z = (o, e) => "#" + o.replace(/^#/, "").replace(/../g, (a) => ("0" + Math.min(255, Math.max(0, parseInt(a, 16) + e)).toString(16)).slice(-2)), dr = (o, e) => Z(o, 16 * e), vr = (o, e) => Z(o, -16 * e), R = (o) => {
736
- const e = parseInt(o.replace("#", ""), 16), a = e >> 16 & 255, t = e >> 8 & 255, n = e & 255;
737
- return `${a}, ${t}, ${n}`;
738
- }, fr = (o) => {
739
- const e = o.replace(/([A-Z])/g, "-$1");
1175
+ const Qo = /* @__PURE__ */ U(so, [["render", io]]), co = ["dark", "light", "theme", "preset", "colors", "components", "colorScheme"], uo = (t) => {
1176
+ const e = t.replace(/([A-Z])/g, "-$1");
740
1177
  return e.charAt(0).toUpperCase() + e.slice(1);
741
- }, j = (o) => o.filter((e) => !hr.includes(e)).map((e) => fr(e)).join("-").toLowerCase(), hr = ["dark", "light", "theme", "preset", "colors", "components", "colorScheme"], B = [], x = [], A = (o, e = []) => {
742
- for (const a in o) {
743
- const t = o[a], n = e.concat([a]);
744
- if (typeof t == "object")
745
- A(t, n);
746
- else if (n.some((l) => l === "theme") && n.some((l) => l === "preset")) {
747
- if (n.some((l) => l === "colorScheme") && n.some((l) => l === "dark"))
748
- x.push(`--vf-${j(n)}: ${t}`);
749
- else if (B.push(`--vf-${j(n)}: ${t}`), n.some((l) => l === "colors") && (B.push(`--vf-${j(n)}-rgb: ${R(t)}`), a !== "white"))
750
- for (let l = 1; l < 10; ++l) {
751
- let b;
752
- l < 5 ? b = dr(t, 5 - l) : b = vr(t, l - 5), B.push(`--vf-${j(n)}-${l}00: ${b}`), B.push(`--vf-${j(n)}-${l}00-rgb: ${R(b)}`);
753
- }
1178
+ }, fo = (t) => t.filter((e) => !co.includes(e)).map((e) => uo(e)).join("-").toLowerCase(), vo = (t) => /^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/.test(t), fe = (t) => {
1179
+ if (!vo(t))
1180
+ return null;
1181
+ if (t.length === 4) {
1182
+ const e = t[1], r = t[2], o = t[3];
1183
+ return `#${e}${e}${r}${r}${o}${o}`;
1184
+ }
1185
+ return t.toLowerCase();
1186
+ }, we = (t) => {
1187
+ const e = fe(t);
1188
+ if (!e)
1189
+ return [0, 0, 0];
1190
+ const r = parseInt(e.slice(1), 16), o = r >> 16 & 255, n = r >> 8 & 255, d = r & 255;
1191
+ return [o, n, d];
1192
+ }, ge = (t) => {
1193
+ const [e, r, o] = we(t);
1194
+ return `${e}, ${r}, ${o}`;
1195
+ }, po = (t, e, r) => {
1196
+ const o = t / 255, n = e / 255, d = r / 255, a = Math.max(o, n, d), c = Math.min(o, n, d), l = a - c;
1197
+ let f = 0, u = 0;
1198
+ const s = (a + c) / 2;
1199
+ if (l !== 0) {
1200
+ switch (u = l / (1 - Math.abs(2 * s - 1)), a) {
1201
+ case o:
1202
+ f = (n - d) / l % 6;
1203
+ break;
1204
+ case n:
1205
+ f = (d - o) / l + 2;
1206
+ break;
1207
+ case d:
1208
+ f = (o - n) / l + 4;
1209
+ break;
754
1210
  }
1211
+ f *= 60, f < 0 && (f += 360);
755
1212
  }
756
- }, Lr = {
757
- install(o, e) {
758
- A(e), B.length && document.styleSheets[0].insertRule(`:root { ${B.join(";")} }`), x.length && document.styleSheets[0].insertRule(`:root[data-theme=dark] { ${x.join(";")} }`);
1213
+ return [f, u * 100, s * 100];
1214
+ }, ho = (t, e, r) => {
1215
+ const o = e / 100, n = r / 100, d = (1 - Math.abs(2 * n - 1)) * o, a = d * (1 - Math.abs(t / 60 % 2 - 1)), c = n - d / 2;
1216
+ let l = 0, f = 0, u = 0;
1217
+ t >= 0 && t < 60 ? (l = d, f = a, u = 0) : t >= 60 && t < 120 ? (l = a, f = d, u = 0) : t >= 120 && t < 180 ? (l = 0, f = d, u = a) : t >= 180 && t < 240 ? (l = 0, f = a, u = d) : t >= 240 && t < 300 ? (l = a, f = 0, u = d) : (l = d, f = 0, u = a);
1218
+ const s = Math.round((l + c) * 255), v = Math.round((f + c) * 255), i = Math.round((u + c) * 255);
1219
+ return [s, v, i];
1220
+ }, bo = (t, e, r) => `#${[t, e, r].map((o) => o.toString(16).padStart(2, "0")).join("")}`, go = (t, e, r) => Math.min(r, Math.max(e, t)), mo = (t, e) => {
1221
+ const r = fe(t);
1222
+ if (!r)
1223
+ return t;
1224
+ const [o, n, d] = we(r), [a, c, l] = po(o, n, d), u = (e - 5) * 7, s = go(l + u, 0, 100), [v, i, m] = ho(a, c, s);
1225
+ return bo(v, i, m);
1226
+ }, yo = (t) => {
1227
+ if (typeof document > "u")
1228
+ return null;
1229
+ const e = document.getElementById(t);
1230
+ if (e && e.tagName.toLowerCase() === "style")
1231
+ return e;
1232
+ const r = document.createElement("style");
1233
+ return r.id = t, document.head.appendChild(r), r;
1234
+ }, ce = (t) => !!t && typeof t == "object" && !Array.isArray(t), ve = (t, e) => {
1235
+ if (!e)
1236
+ return { ...t };
1237
+ const r = { ...t };
1238
+ for (const o in e) {
1239
+ const n = e[o], d = t[o];
1240
+ ce(d) && ce(n) ? r[o] = ve(d, n) : r[o] = n;
1241
+ }
1242
+ return r;
1243
+ }, $e = (t) => {
1244
+ if (!t)
1245
+ return null;
1246
+ if (ce(t) && "preset" in t) {
1247
+ const e = t;
1248
+ return {
1249
+ preset: e.preset ?? {},
1250
+ overrides: e.overrides,
1251
+ selector: e.selector,
1252
+ darkSelector: e.darkSelector
1253
+ };
759
1254
  }
760
- }, D = {
1255
+ return { preset: t };
1256
+ }, _o = (t) => {
1257
+ const e = [], r = [], o = (n, d) => {
1258
+ if (!(!n || typeof n != "object"))
1259
+ for (const a in n) {
1260
+ const c = n[a], l = d.concat([a]);
1261
+ if (c && typeof c == "object") {
1262
+ o(c, l);
1263
+ continue;
1264
+ }
1265
+ if (typeof c != "string")
1266
+ continue;
1267
+ const u = l.includes("colorScheme") && l.includes("dark") ? r : e, s = fo(l);
1268
+ if (u.push(`--vf-${s}: ${c}`), l.includes("colors")) {
1269
+ const v = fe(c);
1270
+ if (!v)
1271
+ continue;
1272
+ if (u.push(`--vf-${s}-rgb: ${ge(v)}`), a !== "white")
1273
+ for (let i = 1; i < 10; ++i) {
1274
+ const m = mo(v, i);
1275
+ u.push(`--vf-${s}-${i}00: ${m}`), u.push(`--vf-${s}-${i}00-rgb: ${ge(m)}`);
1276
+ }
1277
+ }
1278
+ }
1279
+ };
1280
+ return o(t, []), { baseVars: e, darkVars: r };
1281
+ }, ko = (t, e, r) => {
1282
+ const { baseVars: o, darkVars: n } = _o(t), d = yo("vueforge-theme");
1283
+ if (!d)
1284
+ return;
1285
+ const a = [];
1286
+ o.length && a.push(`${e} { ${o.join(";")} }`), n.length && a.push(`${r} { ${n.join(";")} }`), d.textContent = a.join(`
1287
+ `);
1288
+ };
1289
+ let D = null;
1290
+ const Co = (t) => ({
1291
+ selector: t.selector ?? ":root",
1292
+ darkSelector: t.darkSelector ?? ":root[data-theme=dark]"
1293
+ }), Fe = (t) => {
1294
+ const e = $e(t);
1295
+ if (!e)
1296
+ return;
1297
+ const r = ve(e.preset, e.overrides), { selector: o, darkSelector: n } = Co(e);
1298
+ D = { ...e }, ko(r, o, n);
1299
+ }, er = (t) => {
1300
+ if (!D)
1301
+ return;
1302
+ const e = t.overrides === void 0 ? D.overrides : ve(D.overrides ?? {}, t.overrides ?? {}), r = {
1303
+ preset: t.preset ?? D.preset,
1304
+ overrides: e,
1305
+ selector: t.selector ?? D.selector,
1306
+ darkSelector: t.darkSelector ?? D.darkSelector
1307
+ };
1308
+ Fe(r);
1309
+ }, tr = () => D ? { ...D } : null, or = {
1310
+ install(t, e = {}) {
1311
+ const r = $e(e.theme);
1312
+ r && Fe(r);
1313
+ }
1314
+ }, me = {
761
1315
  colors: {
762
1316
  white: "#ffffff",
763
1317
  green: "#0cbc87",
@@ -788,7 +1342,7 @@ const Tr = /* @__PURE__ */ $(cr, [["render", ur]]), Z = (o, e) => "#" + o.replac
788
1342
  dividerColor: "#2e2e32"
789
1343
  }
790
1344
  }
791
- }, pr = {
1345
+ }, wo = {
792
1346
  padding: "6px 10px",
793
1347
  borderRadius: "6px",
794
1348
  roundedBorderRadius: "2rem",
@@ -928,30 +1482,48 @@ const Tr = /* @__PURE__ */ $(cr, [["render", ur]]), Z = (o, e) => "#" + o.replac
928
1482
  }
929
1483
  }
930
1484
  }
931
- }, gr = {
1485
+ }, $o = {
932
1486
  padding: "12px",
933
1487
  borderColor: "var(--vf-border-color)",
934
1488
  borderRadius: "6px"
935
- }, br = {}, _r = {
1489
+ }, Fo = {}, Bo = {
936
1490
  padding: "12px"
937
- }, mr = {}, yr = {}, Cr = {
1491
+ }, xo = {}, To = {}, Lo = {
938
1492
  color: "var(--vf-secondary-text-color)",
939
1493
  padding: "12px",
940
1494
  marginTop: "24px",
941
1495
  borderTop: "1px solid var(--vf-footer-border-color)",
942
1496
  borderColor: "var(--vf-border-color)",
943
1497
  backgroundColor: "var(--vf-bg-color)"
944
- }, wr = {
1498
+ }, Ro = {
945
1499
  height: "55px",
946
1500
  padding: "0",
947
1501
  borderColor: "var(--vf-border-color)",
948
1502
  borderBottom: "1px solid var(--vf-header-border-color)",
949
1503
  marginBottom: "24px",
950
1504
  backgroundColor: "var(--vf-bg-color)"
951
- }, kr = {
1505
+ }, So = {
1506
+ padding: "0.5rem 0.75rem",
1507
+ borderRadius: "6px",
1508
+ borderColor: "var(--vf-border-color)",
1509
+ backgroundColor: "var(--vf-bg-color)",
1510
+ textColor: "var(--vf-text-color)",
1511
+ placeholderColor: "var(--vf-secondary-text-color)",
1512
+ focusBorderColor: "var(--vf-blue-600)",
1513
+ hoverBorderColor: "var(--vf-blue-500)",
1514
+ disabledOpacity: "0.6",
1515
+ small: {
1516
+ padding: "0.375rem 0.5rem",
1517
+ fontSize: "0.875rem"
1518
+ },
1519
+ large: {
1520
+ padding: "0.625rem 0.875rem",
1521
+ fontSize: "1.125rem"
1522
+ }
1523
+ }, Vo = {
952
1524
  hoverColor: "var(--vf-blue)",
953
1525
  activeColor: "var(--vf-blue)"
954
- }, Fr = {}, $r = {
1526
+ }, zo = {}, Wo = {
955
1527
  separatorColor: "var(--vf-border-color)",
956
1528
  link: {
957
1529
  hoverColor: "var(--vf-blue)",
@@ -967,40 +1539,95 @@ const Tr = /* @__PURE__ */ $(cr, [["render", ur]]), Z = (o, e) => "#" + o.replac
967
1539
  marginBottom: "0.5rem",
968
1540
  marginLeft: "0.5rem"
969
1541
  }
970
- }, Br = {
1542
+ }, Mo = {
971
1543
  backgroundColor: "var(--vf-bg-color)"
972
- }, Vr = {
973
- ...D,
1544
+ }, Ho = {
1545
+ padding: "0.5rem 0.75rem",
1546
+ borderRadius: "6px",
1547
+ borderColor: "var(--vf-border-color)",
1548
+ backgroundColor: "var(--vf-bg-color)",
1549
+ textColor: "var(--vf-text-color)",
1550
+ focusBorderColor: "var(--vf-blue-600)",
1551
+ hoverBorderColor: "var(--vf-blue-500)",
1552
+ disabledOpacity: "0.6",
1553
+ panelBackgroundColor: "var(--vf-bg-color)",
1554
+ panelBorderColor: "var(--vf-border-color)",
1555
+ panelShadow: "0 10px 30px rgba(0, 0, 0, 0.12)",
1556
+ optionHoverBackgroundColor: "rgba(var(--vf-blue-600-rgb), 0.08)",
1557
+ optionActiveBackgroundColor: "rgba(var(--vf-blue-600-rgb), 0.14)",
1558
+ optionActiveTextColor: "var(--vf-text-color)",
1559
+ small: {
1560
+ padding: "0.375rem 0.5rem",
1561
+ fontSize: "0.875rem"
1562
+ },
1563
+ large: {
1564
+ padding: "0.625rem 0.875rem",
1565
+ fontSize: "1.125rem"
1566
+ }
1567
+ }, Eo = {
1568
+ size: "1rem",
1569
+ gap: "0.5rem",
1570
+ borderRadius: "4px",
1571
+ borderColor: "var(--vf-border-color)",
1572
+ backgroundColor: "var(--vf-bg-color)",
1573
+ checkedBackgroundColor: "var(--vf-blue)",
1574
+ checkedBorderColor: "var(--vf-blue)",
1575
+ checkColor: "#ffffff",
1576
+ textColor: "var(--vf-text-color)",
1577
+ disabledOpacity: "0.6"
1578
+ }, Ao = {
1579
+ width: "2.25rem",
1580
+ height: "1.25rem",
1581
+ thumbSize: "1rem",
1582
+ gap: "0.5rem",
1583
+ backgroundColor: "var(--vf-border-color)",
1584
+ checkedBackgroundColor: "var(--vf-blue)",
1585
+ thumbColor: "#ffffff",
1586
+ textColor: "var(--vf-text-color)",
1587
+ disabledOpacity: "0.6"
1588
+ }, rr = {
1589
+ ...me,
974
1590
  components: {
975
- base: D,
976
- button: pr,
977
- card: gr,
978
- codeBlock: br,
979
- container: _r,
980
- content: mr,
981
- demo: yr,
982
- footer: Cr,
983
- header: wr,
984
- link: kr,
985
- logo: Fr,
986
- menu: $r,
987
- popover: Br
1591
+ base: me,
1592
+ button: wo,
1593
+ card: $o,
1594
+ codeBlock: Fo,
1595
+ container: Bo,
1596
+ content: xo,
1597
+ demo: To,
1598
+ footer: Lo,
1599
+ header: Ro,
1600
+ input: So,
1601
+ link: Vo,
1602
+ logo: zo,
1603
+ menu: Wo,
1604
+ popover: Mo,
1605
+ select: Ho,
1606
+ checkbox: Eo,
1607
+ switch: Ao
988
1608
  }
989
1609
  };
990
1610
  export {
991
- zr as Button,
992
- _e as Card,
993
- Tr as Container,
994
- sr as Content,
995
- Or as DefaultLayout,
996
- Vr as DefaultTheme,
997
- Pr as Demo,
998
- or as Footer,
999
- Qo as Header,
1000
- jr as LeftSidebarLayout,
1001
- T as Link,
1002
- Mr as Logo,
1003
- qo as Menu,
1004
- xr as Popover,
1005
- Lr as VueForge
1611
+ Ko as Button,
1612
+ ft as Card,
1613
+ Go as Checkbox,
1614
+ Qo as Container,
1615
+ je as Content,
1616
+ No as DefaultLayout,
1617
+ rr as DefaultTheme,
1618
+ jo as Demo,
1619
+ qe as Footer,
1620
+ De as Header,
1621
+ qo as Input,
1622
+ Io as LeftSidebarLayout,
1623
+ ue as Link,
1624
+ Xo as Logo,
1625
+ Yo as Menu,
1626
+ Jo as Popover,
1627
+ Uo as Select,
1628
+ Zo as Switch,
1629
+ or as VueForge,
1630
+ tr as getTheme,
1631
+ Fe as setTheme,
1632
+ er as updateTheme
1006
1633
  };