@velkymx/vibeui 0.1.1 → 0.3.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/vibeui.es.js CHANGED
@@ -1,5 +1,5 @@
1
- import { defineComponent as c, computed as u, createElementBlock as l, createCommentVNode as o, openBlock as s, normalizeClass as d, renderSlot as p, createTextVNode as f, toDisplayString as b } from "vue";
2
- const g = /* @__PURE__ */ c({
1
+ import { defineComponent as p, computed as c, createElementBlock as s, createCommentVNode as u, openBlock as a, normalizeClass as h, renderSlot as $, createTextVNode as T, toDisplayString as f, createBlock as x, resolveDynamicComponent as P, withCtx as w, createElementVNode as v, normalizeStyle as E, unref as j, useSlots as D, Fragment as F, renderList as N, ref as I, watch as L, withDirectives as Y, vModelText as se, vModelSelect as de, withModifiers as Q, onMounted as oe, onBeforeUnmount as re } from "vue";
2
+ const ul = /* @__PURE__ */ p({
3
3
  __name: "VibeAlert",
4
4
  props: {
5
5
  variant: { type: String, default: "primary" },
@@ -8,38 +8,2625 @@ const g = /* @__PURE__ */ c({
8
8
  message: { type: String, required: !0 }
9
9
  },
10
10
  emits: ["update:modelValue", "component-error"],
11
- setup(t, { emit: i }) {
12
- const n = t, a = i, r = u({
13
- get: () => n.modelValue,
14
- set: (e) => a("update:modelValue", e)
15
- }), m = () => {
11
+ setup(e, { emit: d }) {
12
+ const t = e, l = d, i = c({
13
+ get: () => t.modelValue,
14
+ set: (r) => l("update:modelValue", r)
15
+ }), n = () => {
16
16
  try {
17
- r.value = !1;
18
- } catch (e) {
19
- a("component-error", {
17
+ i.value = !1;
18
+ } catch (r) {
19
+ l("component-error", {
20
20
  message: "Dismiss failed",
21
21
  componentName: "VibeAlert",
22
- originalError: e
22
+ originalError: r
23
23
  });
24
24
  }
25
25
  };
26
- return (e, y) => r.value ? (s(), l("div", {
26
+ return (r, o) => i.value ? (a(), s("div", {
27
27
  key: 0,
28
- class: d(`alert alert-${t.variant}`),
28
+ class: h(`alert alert-${e.variant}`),
29
29
  role: "alert"
30
30
  }, [
31
- p(e.$slots, "default", {}, () => [
32
- f(b(t.message), 1)
31
+ $(r.$slots, "default", {}, () => [
32
+ T(f(e.message), 1)
33
33
  ]),
34
- t.dismissable ? (s(), l("button", {
34
+ e.dismissable ? (a(), s("button", {
35
35
  key: 0,
36
36
  class: "btn-close",
37
- onClick: m,
37
+ onClick: n,
38
38
  "aria-label": "Close"
39
- })) : o("", !0)
40
- ], 2)) : o("", !0);
39
+ })) : u("", !0)
40
+ ], 2)) : u("", !0);
41
41
  }
42
- });
42
+ }), cl = /* @__PURE__ */ p({
43
+ __name: "VibeBadge",
44
+ props: {
45
+ variant: { type: String, default: "primary" },
46
+ pill: { type: Boolean, default: !1 },
47
+ tag: { type: String, default: "span" }
48
+ },
49
+ emits: ["component-error"],
50
+ setup(e, { emit: d }) {
51
+ const t = e, l = c(() => {
52
+ const i = ["badge", `bg-${t.variant}`];
53
+ return t.pill && i.push("rounded-pill"), i.join(" ");
54
+ });
55
+ return (i, n) => (a(), x(P(e.tag), {
56
+ class: h(l.value)
57
+ }, {
58
+ default: w(() => [
59
+ $(i.$slots, "default")
60
+ ]),
61
+ _: 3
62
+ }, 8, ["class"]));
63
+ }
64
+ }), fl = /* @__PURE__ */ p({
65
+ __name: "VibeButton",
66
+ props: {
67
+ variant: { type: String, default: "primary" },
68
+ size: { type: String, default: void 0 },
69
+ outline: { type: Boolean, default: !1 },
70
+ disabled: { type: Boolean, default: !1 },
71
+ type: { type: String, default: "button" },
72
+ href: { type: String, default: void 0 },
73
+ to: { type: [String, Object], default: void 0 },
74
+ active: { type: Boolean, default: !1 }
75
+ },
76
+ emits: ["click", "component-error"],
77
+ setup(e, { emit: d }) {
78
+ const t = e, l = d, i = c(() => t.href ? "a" : t.to ? "router-link" : "button"), n = c(() => {
79
+ const o = ["btn"];
80
+ return t.outline ? o.push(`btn-outline-${t.variant}`) : o.push(`btn-${t.variant}`), t.size && o.push(`btn-${t.size}`), t.active && o.push("active"), o.join(" ");
81
+ }), r = (o) => {
82
+ t.disabled || l("click", o);
83
+ };
84
+ return (o, g) => (a(), x(P(i.value), {
85
+ class: h(n.value),
86
+ type: e.href || e.to ? void 0 : e.type,
87
+ href: e.href,
88
+ to: e.to,
89
+ disabled: e.disabled,
90
+ "aria-disabled": e.disabled,
91
+ onClick: r
92
+ }, {
93
+ default: w(() => [
94
+ $(o.$slots, "default")
95
+ ]),
96
+ _: 3
97
+ }, 8, ["class", "type", "href", "to", "disabled", "aria-disabled"]));
98
+ }
99
+ }), ue = ["role", "aria-label"], vl = /* @__PURE__ */ p({
100
+ __name: "VibeButtonGroup",
101
+ props: {
102
+ size: { type: String, default: void 0 },
103
+ vertical: { type: Boolean, default: !1 },
104
+ role: { type: String, default: "group" },
105
+ ariaLabel: { type: String, default: void 0 }
106
+ },
107
+ emits: ["component-error"],
108
+ setup(e, { emit: d }) {
109
+ const t = e, l = c(() => {
110
+ const i = [t.vertical ? "btn-group-vertical" : "btn-group"];
111
+ return t.size && i.push(`btn-group-${t.size}`), i.join(" ");
112
+ });
113
+ return (i, n) => (a(), s("div", {
114
+ class: h(l.value),
115
+ role: e.role,
116
+ "aria-label": e.ariaLabel
117
+ }, [
118
+ $(i.$slots, "default")
119
+ ], 10, ue));
120
+ }
121
+ }), ce = ["disabled", "aria-label"], bl = /* @__PURE__ */ p({
122
+ __name: "VibeCloseButton",
123
+ props: {
124
+ disabled: { type: Boolean, default: !1 },
125
+ white: { type: Boolean, default: !1 },
126
+ ariaLabel: { type: String, default: "Close" }
127
+ },
128
+ emits: ["click", "component-error"],
129
+ setup(e, { emit: d }) {
130
+ const t = e, l = d, i = (n) => {
131
+ t.disabled || l("click", n);
132
+ };
133
+ return (n, r) => (a(), s("button", {
134
+ type: "button",
135
+ class: h(["btn-close", { "btn-close-white": e.white }]),
136
+ disabled: e.disabled,
137
+ "aria-label": e.ariaLabel,
138
+ onClick: i
139
+ }, null, 10, ce));
140
+ }
141
+ }), fe = { class: "visually-hidden" }, ml = /* @__PURE__ */ p({
142
+ __name: "VibeSpinner",
143
+ props: {
144
+ variant: { type: String, default: void 0 },
145
+ type: { type: String, default: "border" },
146
+ size: { type: String, default: void 0 },
147
+ label: { type: String, default: "Loading..." },
148
+ tag: { type: String, default: "div" }
149
+ },
150
+ emits: ["component-error"],
151
+ setup(e, { emit: d }) {
152
+ const t = e, l = c(() => {
153
+ const i = [`spinner-${t.type}`];
154
+ return t.variant && i.push(`text-${t.variant}`), t.size && i.push(`spinner-${t.type}-${t.size}`), i.join(" ");
155
+ });
156
+ return (i, n) => (a(), x(P(e.tag), {
157
+ class: h(l.value),
158
+ role: "status"
159
+ }, {
160
+ default: w(() => [
161
+ v("span", fe, f(e.label), 1)
162
+ ]),
163
+ _: 1
164
+ }, 8, ["class"]));
165
+ }
166
+ }), yl = /* @__PURE__ */ p({
167
+ __name: "VibePlaceholder",
168
+ props: {
169
+ variant: { type: String, default: void 0 },
170
+ size: { type: String, default: void 0 },
171
+ animation: { type: String, default: void 0 },
172
+ width: { type: [String, Number], default: void 0 },
173
+ tag: { type: String, default: "span" }
174
+ },
175
+ emits: ["component-error"],
176
+ setup(e, { emit: d }) {
177
+ const t = e, l = c(() => {
178
+ const r = ["placeholder"];
179
+ return t.variant && r.push(`bg-${t.variant}`), t.size && r.push(`placeholder-${t.size}`), r.join(" ");
180
+ }), i = c(() => {
181
+ if (t.animation) return `placeholder-${t.animation}`;
182
+ }), n = c(() => {
183
+ if (t.width)
184
+ return { width: typeof t.width == "number" ? `${t.width}%` : t.width };
185
+ });
186
+ return (r, o) => (a(), x(P(e.tag), {
187
+ class: h(i.value)
188
+ }, {
189
+ default: w(() => [
190
+ v("span", {
191
+ class: h(l.value),
192
+ style: E(n.value)
193
+ }, [
194
+ $(r.$slots, "default")
195
+ ], 6)
196
+ ]),
197
+ _: 3
198
+ }, 8, ["class"]));
199
+ }
200
+ }), ve = /* @__PURE__ */ p({
201
+ __name: "VibeCardHeader",
202
+ props: {
203
+ tag: { type: String, default: "div" }
204
+ },
205
+ emits: ["component-error"],
206
+ setup(e, { emit: d }) {
207
+ return (t, l) => (a(), x(P(e.tag), { class: "card-header" }, {
208
+ default: w(() => [
209
+ $(t.$slots, "default")
210
+ ]),
211
+ _: 3
212
+ }));
213
+ }
214
+ }), be = /* @__PURE__ */ p({
215
+ __name: "VibeCardBody",
216
+ props: {
217
+ tag: { type: String, default: "div" }
218
+ },
219
+ emits: ["component-error"],
220
+ setup(e, { emit: d }) {
221
+ return (t, l) => (a(), x(P(e.tag), { class: "card-body" }, {
222
+ default: w(() => [
223
+ $(t.$slots, "default")
224
+ ]),
225
+ _: 3
226
+ }));
227
+ }
228
+ }), me = /* @__PURE__ */ p({
229
+ __name: "VibeCardFooter",
230
+ props: {
231
+ tag: { type: String, default: "div" }
232
+ },
233
+ emits: ["component-error"],
234
+ setup(e, { emit: d }) {
235
+ return (t, l) => (a(), x(P(e.tag), { class: "card-footer" }, {
236
+ default: w(() => [
237
+ $(t.$slots, "default")
238
+ ]),
239
+ _: 3
240
+ }));
241
+ }
242
+ }), ye = ["src", "alt"], K = /* @__PURE__ */ p({
243
+ __name: "VibeCardImg",
244
+ props: {
245
+ src: { type: String, required: !0 },
246
+ alt: { type: String, default: "" },
247
+ top: { type: Boolean, default: !1 },
248
+ bottom: { type: Boolean, default: !1 }
249
+ },
250
+ emits: ["component-error"],
251
+ setup(e, { emit: d }) {
252
+ const t = e, l = t.top ? "card-img-top" : t.bottom ? "card-img-bottom" : "card-img";
253
+ return (i, n) => (a(), s("img", {
254
+ src: e.src,
255
+ alt: e.alt,
256
+ class: h(j(l))
257
+ }, null, 10, ye));
258
+ }
259
+ }), he = /* @__PURE__ */ p({
260
+ __name: "VibeCardTitle",
261
+ props: {
262
+ tag: { type: String, default: "h5" }
263
+ },
264
+ emits: ["component-error"],
265
+ setup(e, { emit: d }) {
266
+ return (t, l) => (a(), x(P(e.tag), { class: "card-title" }, {
267
+ default: w(() => [
268
+ $(t.$slots, "default")
269
+ ]),
270
+ _: 3
271
+ }));
272
+ }
273
+ }), ge = /* @__PURE__ */ p({
274
+ __name: "VibeCardText",
275
+ props: {
276
+ tag: { type: String, default: "p" }
277
+ },
278
+ emits: ["component-error"],
279
+ setup(e, { emit: d }) {
280
+ return (t, l) => (a(), x(P(e.tag), { class: "card-text" }, {
281
+ default: w(() => [
282
+ $(t.$slots, "default")
283
+ ]),
284
+ _: 3
285
+ }));
286
+ }
287
+ }), hl = /* @__PURE__ */ p({
288
+ __name: "VibeCard",
289
+ props: {
290
+ variant: { type: String, default: void 0 },
291
+ border: { type: String, default: void 0 },
292
+ textVariant: { type: String, default: void 0 },
293
+ tag: { type: String, default: "div" },
294
+ // Shorthand props for quick card creation
295
+ title: { type: String, default: void 0 },
296
+ body: { type: String, default: void 0 },
297
+ header: { type: String, default: void 0 },
298
+ footer: { type: String, default: void 0 },
299
+ headerImage: { type: String, default: void 0 },
300
+ headerImageAlt: { type: String, default: "" },
301
+ footerImage: { type: String, default: void 0 },
302
+ footerImageAlt: { type: String, default: "" }
303
+ },
304
+ emits: ["component-error"],
305
+ setup(e, { emit: d }) {
306
+ const t = e, l = D(), i = c(() => {
307
+ const o = ["card"];
308
+ return t.variant && o.push(`bg-${t.variant}`), t.border && o.push(`border-${t.border}`), t.textVariant && o.push(`text-${t.textVariant}`), o.join(" ");
309
+ }), n = c(() => !!(t.title || t.body || t.header || t.footer || t.headerImage || t.footerImage)), r = c(() => !!(l.default || l.header || l.footer || l.body));
310
+ return (o, g) => (a(), x(P(e.tag), {
311
+ class: h(i.value)
312
+ }, {
313
+ default: w(() => [
314
+ n.value && !r.value ? (a(), s(F, { key: 0 }, [
315
+ e.headerImage ? (a(), x(K, {
316
+ key: 0,
317
+ top: "",
318
+ src: e.headerImage,
319
+ alt: e.headerImageAlt
320
+ }, null, 8, ["src", "alt"])) : u("", !0),
321
+ e.header ? (a(), x(ve, { key: 1 }, {
322
+ default: w(() => [
323
+ T(f(e.header), 1)
324
+ ]),
325
+ _: 1
326
+ })) : u("", !0),
327
+ e.title || e.body ? (a(), x(be, { key: 2 }, {
328
+ default: w(() => [
329
+ e.title ? (a(), x(he, { key: 0 }, {
330
+ default: w(() => [
331
+ T(f(e.title), 1)
332
+ ]),
333
+ _: 1
334
+ })) : u("", !0),
335
+ e.body ? (a(), x(ge, { key: 1 }, {
336
+ default: w(() => [
337
+ T(f(e.body), 1)
338
+ ]),
339
+ _: 1
340
+ })) : u("", !0)
341
+ ]),
342
+ _: 1
343
+ })) : u("", !0),
344
+ e.footer ? (a(), x(me, { key: 3 }, {
345
+ default: w(() => [
346
+ T(f(e.footer), 1)
347
+ ]),
348
+ _: 1
349
+ })) : u("", !0),
350
+ e.footerImage ? (a(), x(K, {
351
+ key: 4,
352
+ bottom: "",
353
+ src: e.footerImage,
354
+ alt: e.footerImageAlt
355
+ }, null, 8, ["src", "alt"])) : u("", !0)
356
+ ], 64)) : $(o.$slots, "default", { key: 1 })
357
+ ]),
358
+ _: 3
359
+ }, 8, ["class"]));
360
+ }
361
+ }), pe = ["aria-current"], ke = /* @__PURE__ */ p({
362
+ __name: "VibeBreadcrumbItem",
363
+ props: {
364
+ active: { type: Boolean, default: !1 },
365
+ href: { type: String, default: void 0 },
366
+ to: { type: [String, Object], default: void 0 }
367
+ },
368
+ emits: ["component-error"],
369
+ setup(e, { emit: d }) {
370
+ const t = e, l = t.href ? "a" : t.to ? "router-link" : "span";
371
+ return (i, n) => (a(), s("li", {
372
+ class: h(["breadcrumb-item", { active: e.active }]),
373
+ "aria-current": e.active ? "page" : void 0
374
+ }, [
375
+ (a(), x(P(j(l)), {
376
+ href: e.href,
377
+ to: e.to
378
+ }, {
379
+ default: w(() => [
380
+ $(i.$slots, "default")
381
+ ]),
382
+ _: 3
383
+ }, 8, ["href", "to"]))
384
+ ], 10, pe));
385
+ }
386
+ }), $e = ["aria-label"], Se = { class: "breadcrumb" }, gl = /* @__PURE__ */ p({
387
+ __name: "VibeBreadcrumb",
388
+ props: {
389
+ ariaLabel: { type: String, default: "breadcrumb" },
390
+ items: { type: Array, default: void 0 }
391
+ },
392
+ emits: ["component-error"],
393
+ setup(e, { emit: d }) {
394
+ const t = D();
395
+ return (l, i) => (a(), s("nav", { "aria-label": e.ariaLabel }, [
396
+ v("ol", Se, [
397
+ e.items && e.items.length > 0 && !j(t).default ? (a(!0), s(F, { key: 0 }, N(e.items, (n, r) => (a(), x(ke, {
398
+ key: r,
399
+ href: n.href,
400
+ to: n.to,
401
+ active: n.active
402
+ }, {
403
+ default: w(() => [
404
+ T(f(n.text), 1)
405
+ ]),
406
+ _: 2
407
+ }, 1032, ["href", "to", "active"]))), 128)) : $(l.$slots, "default", { key: 1 })
408
+ ])
409
+ ], 8, $e));
410
+ }
411
+ }), Ve = { class: "nav-item" }, J = /* @__PURE__ */ p({
412
+ __name: "VibeNavItem",
413
+ props: {
414
+ active: { type: Boolean, default: !1 },
415
+ disabled: { type: Boolean, default: !1 },
416
+ href: { type: String, default: void 0 },
417
+ to: { type: [String, Object], default: void 0 }
418
+ },
419
+ emits: ["click", "component-error"],
420
+ setup(e, { emit: d }) {
421
+ const t = e, l = d, i = c(() => t.href ? "a" : t.to ? "router-link" : "a"), n = c(() => {
422
+ const o = ["nav-link"];
423
+ return t.active && o.push("active"), t.disabled && o.push("disabled"), o.join(" ");
424
+ }), r = (o) => {
425
+ t.disabled || l("click", o);
426
+ };
427
+ return (o, g) => (a(), s("li", Ve, [
428
+ (a(), x(P(i.value), {
429
+ class: h(n.value),
430
+ href: e.href,
431
+ to: e.to,
432
+ "aria-current": e.active ? "page" : void 0,
433
+ "aria-disabled": e.disabled,
434
+ onClick: r
435
+ }, {
436
+ default: w(() => [
437
+ $(o.$slots, "default")
438
+ ]),
439
+ _: 3
440
+ }, 8, ["class", "href", "to", "aria-current", "aria-disabled"]))
441
+ ]));
442
+ }
443
+ }), pl = /* @__PURE__ */ p({
444
+ __name: "VibeNav",
445
+ props: {
446
+ tabs: { type: Boolean, default: !1 },
447
+ pills: { type: Boolean, default: !1 },
448
+ fill: { type: Boolean, default: !1 },
449
+ justified: { type: Boolean, default: !1 },
450
+ vertical: { type: Boolean, default: !1 },
451
+ tag: { type: String, default: "ul" },
452
+ items: { type: Array, default: void 0 }
453
+ },
454
+ emits: ["component-error"],
455
+ setup(e, { emit: d }) {
456
+ const t = e, l = D(), i = c(() => {
457
+ const n = ["nav"];
458
+ return t.tabs && n.push("nav-tabs"), t.pills && n.push("nav-pills"), t.fill && n.push("nav-fill"), t.justified && n.push("nav-justified"), t.vertical && n.push("flex-column"), n.join(" ");
459
+ });
460
+ return (n, r) => (a(), x(P(e.tag), {
461
+ class: h(i.value)
462
+ }, {
463
+ default: w(() => [
464
+ e.items && e.items.length > 0 && !j(l).default ? (a(!0), s(F, { key: 0 }, N(e.items, (o, g) => (a(), x(J, {
465
+ key: g,
466
+ href: o.href,
467
+ to: o.to,
468
+ active: o.active,
469
+ disabled: o.disabled
470
+ }, {
471
+ default: w(() => [
472
+ T(f(o.text), 1)
473
+ ]),
474
+ _: 2
475
+ }, 1032, ["href", "to", "active", "disabled"]))), 128)) : $(n.$slots, "default", { key: 1 })
476
+ ]),
477
+ _: 3
478
+ }, 8, ["class"]));
479
+ }
480
+ }), kl = /* @__PURE__ */ p({
481
+ __name: "VibeNavbar",
482
+ props: {
483
+ variant: { type: String, default: "light" },
484
+ expand: { type: [Boolean, String], default: "lg" },
485
+ container: { type: [Boolean, String], default: !0 },
486
+ position: { type: String, default: void 0 },
487
+ tag: { type: String, default: "nav" }
488
+ },
489
+ emits: ["component-error"],
490
+ setup(e, { emit: d }) {
491
+ const t = e, l = c(() => {
492
+ const n = ["navbar"];
493
+ return t.expand === !0 ? n.push("navbar-expand") : typeof t.expand == "string" && n.push(`navbar-expand-${t.expand}`), t.variant === "dark" || t.variant === "light" ? n.push(`navbar-${t.variant}`) : n.push(`bg-${t.variant}`), t.position && n.push(t.position), n.join(" ");
494
+ }), i = c(() => {
495
+ if (t.container !== !1)
496
+ return t.container === !0 ? "container-fluid" : `container-${t.container}`;
497
+ });
498
+ return (n, r) => (a(), x(P(e.tag), {
499
+ class: h(l.value)
500
+ }, {
501
+ default: w(() => [
502
+ i.value ? (a(), s("div", {
503
+ key: 0,
504
+ class: h(i.value)
505
+ }, [
506
+ $(n.$slots, "default")
507
+ ], 2)) : $(n.$slots, "default", { key: 1 })
508
+ ]),
509
+ _: 3
510
+ }, 8, ["class"]));
511
+ }
512
+ }), $l = /* @__PURE__ */ p({
513
+ __name: "VibeNavbarBrand",
514
+ props: {
515
+ href: { type: String, default: void 0 },
516
+ to: { type: [String, Object], default: void 0 }
517
+ },
518
+ emits: ["component-error"],
519
+ setup(e, { emit: d }) {
520
+ const t = e, l = t.href ? "a" : t.to ? "router-link" : "span";
521
+ return (i, n) => (a(), x(P(j(l)), {
522
+ class: "navbar-brand",
523
+ href: e.href,
524
+ to: e.to
525
+ }, {
526
+ default: w(() => [
527
+ $(i.$slots, "default")
528
+ ]),
529
+ _: 3
530
+ }, 8, ["href", "to"]));
531
+ }
532
+ }), xe = ["data-bs-target", "aria-controls", "aria-label"], Sl = /* @__PURE__ */ p({
533
+ __name: "VibeNavbarToggle",
534
+ props: {
535
+ target: { type: String, required: !0 },
536
+ ariaLabel: { type: String, default: "Toggle navigation" }
537
+ },
538
+ emits: ["component-error"],
539
+ setup(e, { emit: d }) {
540
+ return (t, l) => (a(), s("button", {
541
+ class: "navbar-toggler",
542
+ type: "button",
543
+ "data-bs-toggle": "collapse",
544
+ "data-bs-target": `#${e.target}`,
545
+ "aria-controls": e.target,
546
+ "aria-expanded": "false",
547
+ "aria-label": e.ariaLabel
548
+ }, [...l[0] || (l[0] = [
549
+ v("span", { class: "navbar-toggler-icon" }, null, -1)
550
+ ])], 8, xe));
551
+ }
552
+ }), Vl = /* @__PURE__ */ p({
553
+ __name: "VibeNavbarNav",
554
+ props: {
555
+ tag: { type: String, default: "ul" },
556
+ items: { type: Array, default: void 0 }
557
+ },
558
+ emits: ["component-error"],
559
+ setup(e, { emit: d }) {
560
+ const t = D();
561
+ return (l, i) => (a(), x(P(e.tag), { class: "navbar-nav" }, {
562
+ default: w(() => [
563
+ e.items && e.items.length > 0 && !j(t).default ? (a(!0), s(F, { key: 0 }, N(e.items, (n, r) => (a(), x(J, {
564
+ key: r,
565
+ href: n.href,
566
+ to: n.to,
567
+ active: n.active,
568
+ disabled: n.disabled
569
+ }, {
570
+ default: w(() => [
571
+ T(f(n.text), 1)
572
+ ]),
573
+ _: 2
574
+ }, 1032, ["href", "to", "active", "disabled"]))), 128)) : $(l.$slots, "default", { key: 1 })
575
+ ]),
576
+ _: 3
577
+ }));
578
+ }
579
+ }), U = /* @__PURE__ */ p({
580
+ __name: "VibePaginationItem",
581
+ props: {
582
+ active: { type: Boolean, default: !1 },
583
+ disabled: { type: Boolean, default: !1 },
584
+ href: { type: String, default: void 0 },
585
+ to: { type: [String, Object], default: void 0 }
586
+ },
587
+ emits: ["click", "component-error"],
588
+ setup(e, { emit: d }) {
589
+ const t = e, l = d, i = c(() => t.href ? "a" : t.to ? "router-link" : "button"), n = (r) => {
590
+ t.disabled || l("click", r);
591
+ };
592
+ return (r, o) => (a(), s("li", {
593
+ class: h(["page-item", { active: e.active, disabled: e.disabled }])
594
+ }, [
595
+ (a(), x(P(i.value), {
596
+ class: "page-link",
597
+ href: e.href,
598
+ to: e.to,
599
+ type: i.value === "button" ? "button" : void 0,
600
+ disabled: e.disabled && i.value === "button",
601
+ "aria-current": e.active ? "page" : void 0,
602
+ "aria-disabled": e.disabled,
603
+ onClick: n
604
+ }, {
605
+ default: w(() => [
606
+ $(r.$slots, "default")
607
+ ]),
608
+ _: 3
609
+ }, 8, ["href", "to", "type", "disabled", "aria-current", "aria-disabled"]))
610
+ ], 2));
611
+ }
612
+ }), Be = ["aria-label"], xl = /* @__PURE__ */ p({
613
+ __name: "VibePagination",
614
+ props: {
615
+ size: { type: String, default: void 0 },
616
+ ariaLabel: { type: String, default: "Pagination" },
617
+ // Shorthand props
618
+ totalPages: { type: Number, default: void 0 },
619
+ currentPage: { type: Number, default: 1 },
620
+ showPrevNext: { type: Boolean, default: !0 }
621
+ },
622
+ emits: ["page-click", "component-error"],
623
+ setup(e, { emit: d }) {
624
+ const t = e, l = d, i = D(), n = c(() => {
625
+ const g = ["pagination"];
626
+ return t.size && g.push(`pagination-${t.size}`), g.join(" ");
627
+ }), r = c(() => t.totalPages ? Array.from({ length: t.totalPages }, (g, b) => b + 1) : []), o = (g) => {
628
+ g >= 1 && g <= t.totalPages && l("page-click", g);
629
+ };
630
+ return (g, b) => (a(), s("nav", { "aria-label": e.ariaLabel }, [
631
+ v("ul", {
632
+ class: h(n.value)
633
+ }, [
634
+ e.totalPages && !j(i).default ? (a(), s(F, { key: 0 }, [
635
+ e.showPrevNext ? (a(), x(U, {
636
+ key: 0,
637
+ disabled: e.currentPage === 1,
638
+ onClick: b[0] || (b[0] = (m) => o(e.currentPage - 1))
639
+ }, {
640
+ default: w(() => [...b[2] || (b[2] = [
641
+ T(" Previous ", -1)
642
+ ])]),
643
+ _: 1
644
+ }, 8, ["disabled"])) : u("", !0),
645
+ (a(!0), s(F, null, N(r.value, (m) => (a(), x(U, {
646
+ key: m,
647
+ active: m === e.currentPage,
648
+ onClick: (y) => o(m)
649
+ }, {
650
+ default: w(() => [
651
+ T(f(m), 1)
652
+ ]),
653
+ _: 2
654
+ }, 1032, ["active", "onClick"]))), 128)),
655
+ e.showPrevNext ? (a(), x(U, {
656
+ key: 1,
657
+ disabled: e.currentPage === e.totalPages,
658
+ onClick: b[1] || (b[1] = (m) => o(e.currentPage + 1))
659
+ }, {
660
+ default: w(() => [...b[3] || (b[3] = [
661
+ T(" Next ", -1)
662
+ ])]),
663
+ _: 1
664
+ }, 8, ["disabled"])) : u("", !0)
665
+ ], 64)) : $(g.$slots, "default", { key: 1 })
666
+ ], 2)
667
+ ], 8, Be));
668
+ }
669
+ }), Ce = /* @__PURE__ */ p({
670
+ __name: "VibeListGroupItem",
671
+ props: {
672
+ active: { type: Boolean, default: !1 },
673
+ disabled: { type: Boolean, default: !1 },
674
+ variant: { type: String, default: void 0 },
675
+ href: { type: String, default: void 0 },
676
+ to: { type: [String, Object], default: void 0 },
677
+ tag: { type: String, default: "li" },
678
+ action: { type: Boolean, default: !1 }
679
+ },
680
+ emits: ["click", "component-error"],
681
+ setup(e, { emit: d }) {
682
+ const t = e, l = d, i = c(() => t.href ? "a" : t.to ? "router-link" : t.action ? "button" : t.tag), n = c(() => {
683
+ const o = ["list-group-item"];
684
+ return t.active && o.push("active"), t.disabled && o.push("disabled"), t.variant && o.push(`list-group-item-${t.variant}`), (t.action || t.href || t.to) && o.push("list-group-item-action"), o.join(" ");
685
+ }), r = (o) => {
686
+ t.disabled || l("click", o);
687
+ };
688
+ return (o, g) => (a(), x(P(i.value), {
689
+ class: h(n.value),
690
+ href: e.href,
691
+ to: e.to,
692
+ type: i.value === "button" ? "button" : void 0,
693
+ disabled: e.disabled,
694
+ "aria-disabled": e.disabled,
695
+ "aria-current": e.active ? "true" : void 0,
696
+ onClick: r
697
+ }, {
698
+ default: w(() => [
699
+ $(o.$slots, "default")
700
+ ]),
701
+ _: 3
702
+ }, 8, ["class", "href", "to", "type", "disabled", "aria-disabled", "aria-current"]));
703
+ }
704
+ }), Bl = /* @__PURE__ */ p({
705
+ __name: "VibeListGroup",
706
+ props: {
707
+ flush: { type: Boolean, default: !1 },
708
+ horizontal: { type: [Boolean, String], default: !1 },
709
+ numbered: { type: Boolean, default: !1 },
710
+ tag: { type: String, default: "ul" },
711
+ items: { type: Array, default: void 0 }
712
+ },
713
+ emits: ["component-error"],
714
+ setup(e, { emit: d }) {
715
+ const t = e, l = D(), i = c(() => {
716
+ const n = ["list-group"];
717
+ return t.flush && n.push("list-group-flush"), t.numbered && n.push("list-group-numbered"), t.horizontal === !0 ? n.push("list-group-horizontal") : typeof t.horizontal == "string" && n.push(`list-group-horizontal-${t.horizontal}`), n.join(" ");
718
+ });
719
+ return (n, r) => (a(), x(P(e.tag), {
720
+ class: h(i.value)
721
+ }, {
722
+ default: w(() => [
723
+ e.items && e.items.length > 0 && !j(l).default ? (a(!0), s(F, { key: 0 }, N(e.items, (o, g) => (a(), x(Ce, {
724
+ key: g,
725
+ href: o.href,
726
+ to: o.to,
727
+ active: o.active,
728
+ disabled: o.disabled,
729
+ variant: o.variant
730
+ }, {
731
+ default: w(() => [
732
+ T(f(o.text), 1)
733
+ ]),
734
+ _: 2
735
+ }, 1032, ["href", "to", "active", "disabled", "variant"]))), 128)) : $(n.$slots, "default", { key: 1 })
736
+ ]),
737
+ _: 3
738
+ }, 8, ["class"]));
739
+ }
740
+ }), Cl = /* @__PURE__ */ p({
741
+ __name: "VibeProgress",
742
+ props: {
743
+ height: { type: String, default: void 0 }
744
+ },
745
+ emits: ["component-error"],
746
+ setup(e, { emit: d }) {
747
+ const t = e, l = c(() => {
748
+ if (t.height)
749
+ return { height: t.height };
750
+ });
751
+ return (i, n) => (a(), s("div", {
752
+ class: "progress",
753
+ style: E(l.value)
754
+ }, [
755
+ $(i.$slots, "default")
756
+ ], 4));
757
+ }
758
+ }), we = ["aria-valuenow", "aria-valuemax"], wl = /* @__PURE__ */ p({
759
+ __name: "VibeProgressBar",
760
+ props: {
761
+ value: { type: Number, default: 0 },
762
+ max: { type: Number, default: 100 },
763
+ variant: { type: String, default: void 0 },
764
+ striped: { type: Boolean, default: !1 },
765
+ animated: { type: Boolean, default: !1 },
766
+ label: { type: String, default: void 0 },
767
+ showValue: { type: Boolean, default: !1 }
768
+ },
769
+ emits: ["component-error"],
770
+ setup(e, { emit: d }) {
771
+ const t = e, l = c(() => {
772
+ const r = ["progress-bar"];
773
+ return t.variant && r.push(`bg-${t.variant}`), (t.striped || t.animated) && r.push("progress-bar-striped"), t.animated && r.push("progress-bar-animated"), r.join(" ");
774
+ }), i = c(() => ({ width: `${Math.min(100, Math.max(0, t.value / t.max * 100))}%` })), n = c(() => t.label ? t.label : t.showValue ? `${t.value}%` : "");
775
+ return (r, o) => (a(), s("div", {
776
+ class: h(l.value),
777
+ style: E(i.value),
778
+ role: "progressbar",
779
+ "aria-valuenow": e.value,
780
+ "aria-valuemin": 0,
781
+ "aria-valuemax": e.max
782
+ }, [
783
+ T(f(n.value) + " ", 1),
784
+ $(r.$slots, "default")
785
+ ], 14, we));
786
+ }
787
+ }), Te = { class: "accordion-item" }, qe = { class: "accordion-header" }, Me = ["data-bs-target", "aria-expanded", "aria-controls"], Pe = ["id", "data-bs-parent"], Fe = { class: "accordion-body" }, Ie = /* @__PURE__ */ p({
788
+ __name: "VibeAccordionItem",
789
+ props: {
790
+ id: { type: String, required: !0 },
791
+ title: { type: String, required: !0 },
792
+ parentId: { type: String, required: !0 },
793
+ show: { type: Boolean, default: !1 }
794
+ },
795
+ emits: ["component-error"],
796
+ setup(e, { emit: d }) {
797
+ const t = e, l = c(() => t.show ? "accordion-collapse collapse show" : "accordion-collapse collapse");
798
+ return (i, n) => (a(), s("div", Te, [
799
+ v("h2", qe, [
800
+ v("button", {
801
+ class: h(["accordion-button", { collapsed: !e.show }]),
802
+ type: "button",
803
+ "data-bs-toggle": "collapse",
804
+ "data-bs-target": `#${e.id}`,
805
+ "aria-expanded": e.show,
806
+ "aria-controls": e.id
807
+ }, f(e.title), 11, Me)
808
+ ]),
809
+ v("div", {
810
+ id: e.id,
811
+ class: h(l.value),
812
+ "data-bs-parent": `#${e.parentId}`
813
+ }, [
814
+ v("div", Fe, [
815
+ $(i.$slots, "default")
816
+ ])
817
+ ], 10, Pe)
818
+ ]));
819
+ }
820
+ }), Ne = ["id"], Tl = /* @__PURE__ */ p({
821
+ __name: "VibeAccordion",
822
+ props: {
823
+ id: { type: String, required: !0 },
824
+ flush: { type: Boolean, default: !1 },
825
+ items: { type: Array, default: void 0 }
826
+ },
827
+ emits: ["component-error"],
828
+ setup(e, { emit: d }) {
829
+ const t = D();
830
+ return (l, i) => (a(), s("div", {
831
+ id: e.id,
832
+ class: h(["accordion", { "accordion-flush": e.flush }])
833
+ }, [
834
+ e.items && e.items.length > 0 && !j(t).default ? (a(!0), s(F, { key: 0 }, N(e.items, (n, r) => (a(), x(Ie, {
835
+ key: r,
836
+ id: n.id,
837
+ "parent-id": e.id,
838
+ title: n.title,
839
+ show: n.show
840
+ }, {
841
+ default: w(() => [
842
+ T(f(n.content), 1)
843
+ ]),
844
+ _: 2
845
+ }, 1032, ["id", "parent-id", "title", "show"]))), 128)) : $(l.$slots, "default", { key: 1 })
846
+ ], 10, Ne));
847
+ }
848
+ }), ql = /* @__PURE__ */ p({
849
+ __name: "VibeCollapse",
850
+ props: {
851
+ id: { type: String, required: !0 },
852
+ modelValue: { type: Boolean, default: !1 },
853
+ tag: { type: String, default: "div" },
854
+ horizontal: { type: Boolean, default: !1 }
855
+ },
856
+ emits: ["update:modelValue", "show", "shown", "hide", "hidden", "component-error"],
857
+ setup(e, { emit: d }) {
858
+ const t = e, l = I(t.modelValue);
859
+ L(() => t.modelValue, (n) => {
860
+ l.value = n;
861
+ });
862
+ const i = c(() => {
863
+ const n = ["collapse"];
864
+ return t.horizontal && n.push("collapse-horizontal"), l.value && n.push("show"), n.join(" ");
865
+ });
866
+ return (n, r) => (a(), x(P(e.tag), {
867
+ id: e.id,
868
+ class: h(i.value)
869
+ }, {
870
+ default: w(() => [
871
+ $(n.$slots, "default")
872
+ ]),
873
+ _: 3
874
+ }, 8, ["id", "class"]));
875
+ }
876
+ }), ze = { key: 0 }, Ae = /* @__PURE__ */ p({
877
+ __name: "VibeDropdownItem",
878
+ props: {
879
+ active: { type: Boolean, default: !1 },
880
+ disabled: { type: Boolean, default: !1 },
881
+ href: { type: String, default: void 0 },
882
+ to: { type: [String, Object], default: void 0 },
883
+ divider: { type: Boolean, default: !1 },
884
+ header: { type: Boolean, default: !1 }
885
+ },
886
+ emits: ["click", "component-error"],
887
+ setup(e, { emit: d }) {
888
+ const t = e, l = d, i = c(() => t.divider ? "hr" : t.header ? "h6" : t.href ? "a" : t.to ? "router-link" : "button"), n = c(() => {
889
+ if (t.divider) return "dropdown-divider";
890
+ if (t.header) return "dropdown-header";
891
+ const o = ["dropdown-item"];
892
+ return t.active && o.push("active"), t.disabled && o.push("disabled"), o.join(" ");
893
+ }), r = (o) => {
894
+ !t.disabled && !t.divider && !t.header && l("click", o);
895
+ };
896
+ return (o, g) => !e.divider && !e.header ? (a(), s("li", ze, [
897
+ (a(), x(P(i.value), {
898
+ class: h(n.value),
899
+ href: e.href,
900
+ to: e.to,
901
+ type: i.value === "button" ? "button" : void 0,
902
+ disabled: e.disabled,
903
+ onClick: r
904
+ }, {
905
+ default: w(() => [
906
+ $(o.$slots, "default")
907
+ ]),
908
+ _: 3
909
+ }, 8, ["class", "href", "to", "type", "disabled"]))
910
+ ])) : (a(), x(P(i.value), {
911
+ key: 1,
912
+ class: h(n.value)
913
+ }, {
914
+ default: w(() => [
915
+ $(o.$slots, "default")
916
+ ]),
917
+ _: 3
918
+ }, 8, ["class"]));
919
+ }
920
+ }), Oe = ["id"], je = ["aria-labelledby"], Ml = /* @__PURE__ */ p({
921
+ __name: "VibeDropdown",
922
+ props: {
923
+ id: { type: String, required: !0 },
924
+ text: { type: String, default: "Dropdown" },
925
+ variant: { type: String, default: "primary" },
926
+ size: { type: String, default: void 0 },
927
+ split: { type: Boolean, default: !1 },
928
+ direction: { type: String, default: "down" },
929
+ menuEnd: { type: Boolean, default: !1 },
930
+ items: { type: Array, default: void 0 }
931
+ },
932
+ emits: ["component-error"],
933
+ setup(e, { emit: d }) {
934
+ const t = e, l = D(), i = c(() => t.direction === "up" ? "dropup" : t.direction === "end" ? "dropend" : t.direction === "start" ? "dropstart" : "dropdown"), n = c(() => {
935
+ const o = ["btn", `btn-${t.variant}`];
936
+ return t.size && o.push(`btn-${t.size}`), o.join(" ");
937
+ }), r = c(() => {
938
+ const o = ["dropdown-menu"];
939
+ return t.menuEnd && o.push("dropdown-menu-end"), o.join(" ");
940
+ });
941
+ return (o, g) => (a(), s("div", {
942
+ class: h(i.value)
943
+ }, [
944
+ v("button", {
945
+ id: e.id,
946
+ class: h([n.value, "dropdown-toggle"]),
947
+ type: "button",
948
+ "data-bs-toggle": "dropdown",
949
+ "aria-expanded": "false"
950
+ }, f(e.text), 11, Oe),
951
+ v("ul", {
952
+ class: h(r.value),
953
+ "aria-labelledby": e.id
954
+ }, [
955
+ e.items && e.items.length > 0 && !j(l).default ? (a(!0), s(F, { key: 0 }, N(e.items, (b, m) => (a(), x(Ae, {
956
+ key: m,
957
+ href: b.href,
958
+ to: b.to,
959
+ active: b.active,
960
+ disabled: b.disabled,
961
+ divider: b.divider,
962
+ header: b.header
963
+ }, {
964
+ default: w(() => [
965
+ T(f(b.text), 1)
966
+ ]),
967
+ _: 2
968
+ }, 1032, ["href", "to", "active", "disabled", "divider", "header"]))), 128)) : $(o.$slots, "default", { key: 1 })
969
+ ], 10, je)
970
+ ], 2));
971
+ }
972
+ }), Le = ["id", "aria-labelledby", "data-bs-backdrop", "data-bs-keyboard"], De = { class: "modal-content" }, Re = {
973
+ key: 0,
974
+ class: "modal-header"
975
+ }, Ge = ["id"], Ee = { class: "modal-body" }, He = {
976
+ key: 1,
977
+ class: "modal-footer"
978
+ }, Pl = /* @__PURE__ */ p({
979
+ __name: "VibeModal",
980
+ props: {
981
+ id: { type: String, required: !0 },
982
+ modelValue: { type: Boolean, default: !1 },
983
+ title: { type: String, default: "" },
984
+ size: { type: String, default: void 0 },
985
+ centered: { type: Boolean, default: !1 },
986
+ scrollable: { type: Boolean, default: !1 },
987
+ fullscreen: { type: [Boolean, String], default: !1 },
988
+ staticBackdrop: { type: Boolean, default: !1 },
989
+ hideHeader: { type: Boolean, default: !1 },
990
+ hideFooter: { type: Boolean, default: !1 }
991
+ },
992
+ emits: ["update:modelValue", "show", "shown", "hide", "hidden", "component-error"],
993
+ setup(e, { emit: d }) {
994
+ const t = e, l = c(() => {
995
+ const i = ["modal-dialog"];
996
+ return t.size && i.push(`modal-${t.size}`), t.centered && i.push("modal-dialog-centered"), t.scrollable && i.push("modal-dialog-scrollable"), t.fullscreen === !0 ? i.push("modal-fullscreen") : typeof t.fullscreen == "string" && i.push(`modal-fullscreen-${t.fullscreen}-down`), i.join(" ");
997
+ });
998
+ return (i, n) => (a(), s("div", {
999
+ id: e.id,
1000
+ class: "modal fade",
1001
+ tabindex: "-1",
1002
+ "aria-labelledby": `${e.id}-label`,
1003
+ "aria-hidden": "true",
1004
+ "data-bs-backdrop": e.staticBackdrop ? "static" : void 0,
1005
+ "data-bs-keyboard": !e.staticBackdrop
1006
+ }, [
1007
+ v("div", {
1008
+ class: h(l.value)
1009
+ }, [
1010
+ v("div", De, [
1011
+ e.hideHeader ? u("", !0) : (a(), s("div", Re, [
1012
+ v("h5", {
1013
+ id: `${e.id}-label`,
1014
+ class: "modal-title"
1015
+ }, [
1016
+ $(i.$slots, "header", {}, () => [
1017
+ T(f(e.title), 1)
1018
+ ])
1019
+ ], 8, Ge),
1020
+ n[0] || (n[0] = v("button", {
1021
+ type: "button",
1022
+ class: "btn-close",
1023
+ "data-bs-dismiss": "modal",
1024
+ "aria-label": "Close"
1025
+ }, null, -1))
1026
+ ])),
1027
+ v("div", Ee, [
1028
+ $(i.$slots, "default")
1029
+ ]),
1030
+ e.hideFooter ? u("", !0) : (a(), s("div", He, [
1031
+ $(i.$slots, "footer", {}, () => [
1032
+ n[1] || (n[1] = v("button", {
1033
+ type: "button",
1034
+ class: "btn btn-secondary",
1035
+ "data-bs-dismiss": "modal"
1036
+ }, "Close", -1))
1037
+ ])
1038
+ ]))
1039
+ ])
1040
+ ], 2)
1041
+ ], 8, Le));
1042
+ }
1043
+ }), Qe = ["id", "aria-labelledby", "data-bs-backdrop", "data-bs-scroll"], Ue = { class: "offcanvas-header" }, We = ["id"], Ye = { class: "offcanvas-body" }, Fl = /* @__PURE__ */ p({
1044
+ __name: "VibeOffcanvas",
1045
+ props: {
1046
+ id: { type: String, required: !0 },
1047
+ modelValue: { type: Boolean, default: !1 },
1048
+ title: { type: String, default: "" },
1049
+ placement: { type: String, default: "start" },
1050
+ backdrop: { type: [Boolean, String], default: !0 },
1051
+ scroll: { type: Boolean, default: !1 }
1052
+ },
1053
+ emits: ["update:modelValue", "show", "shown", "hide", "hidden", "component-error"],
1054
+ setup(e, { emit: d }) {
1055
+ const t = e, l = c(() => `offcanvas offcanvas-${t.placement}`);
1056
+ return (i, n) => (a(), s("div", {
1057
+ id: e.id,
1058
+ class: h(l.value),
1059
+ tabindex: "-1",
1060
+ "aria-labelledby": `${e.id}-label`,
1061
+ "data-bs-backdrop": e.backdrop === !1 ? "false" : e.backdrop === "static" ? "static" : "true",
1062
+ "data-bs-scroll": e.scroll
1063
+ }, [
1064
+ v("div", Ue, [
1065
+ v("h5", {
1066
+ id: `${e.id}-label`,
1067
+ class: "offcanvas-title"
1068
+ }, [
1069
+ $(i.$slots, "header", {}, () => [
1070
+ T(f(e.title), 1)
1071
+ ])
1072
+ ], 8, We),
1073
+ n[0] || (n[0] = v("button", {
1074
+ type: "button",
1075
+ class: "btn-close",
1076
+ "data-bs-dismiss": "offcanvas",
1077
+ "aria-label": "Close"
1078
+ }, null, -1))
1079
+ ]),
1080
+ v("div", Ye, [
1081
+ $(i.$slots, "default")
1082
+ ])
1083
+ ], 10, Qe));
1084
+ }
1085
+ }), Ke = ["id", "data-bs-autohide", "data-bs-delay"], Je = {
1086
+ key: 0,
1087
+ class: "toast-header"
1088
+ }, Xe = { class: "me-auto" }, Ze = { class: "toast-body" }, Il = /* @__PURE__ */ p({
1089
+ __name: "VibeToast",
1090
+ props: {
1091
+ id: { type: String, default: void 0 },
1092
+ modelValue: { type: Boolean, default: !1 },
1093
+ title: { type: String, default: "" },
1094
+ variant: { type: String, default: void 0 },
1095
+ autohide: { type: Boolean, default: !0 },
1096
+ delay: { type: Number, default: 5e3 }
1097
+ },
1098
+ emits: ["update:modelValue", "show", "shown", "hide", "hidden", "component-error"],
1099
+ setup(e, { emit: d }) {
1100
+ const t = e, l = c(() => {
1101
+ const i = ["toast"];
1102
+ return t.variant && i.push(`text-bg-${t.variant}`), i.join(" ");
1103
+ });
1104
+ return (i, n) => (a(), s("div", {
1105
+ id: e.id,
1106
+ class: h(l.value),
1107
+ role: "alert",
1108
+ "aria-live": "assertive",
1109
+ "aria-atomic": "true",
1110
+ "data-bs-autohide": e.autohide,
1111
+ "data-bs-delay": e.delay
1112
+ }, [
1113
+ e.title || i.$slots.header ? (a(), s("div", Je, [
1114
+ $(i.$slots, "header", {}, () => [
1115
+ v("strong", Xe, f(e.title), 1)
1116
+ ]),
1117
+ n[0] || (n[0] = v("button", {
1118
+ type: "button",
1119
+ class: "btn-close",
1120
+ "data-bs-dismiss": "toast",
1121
+ "aria-label": "Close"
1122
+ }, null, -1))
1123
+ ])) : u("", !0),
1124
+ v("div", Ze, [
1125
+ $(i.$slots, "default")
1126
+ ])
1127
+ ], 10, Ke));
1128
+ }
1129
+ }), _e = ["data-bs-interval"], et = ["src", "alt"], tt = {
1130
+ key: 1,
1131
+ class: "carousel-caption d-none d-md-block"
1132
+ }, at = { key: 0 }, lt = { key: 1 }, it = /* @__PURE__ */ p({
1133
+ __name: "VibeCarouselSlide",
1134
+ props: {
1135
+ active: { type: Boolean, default: !1 },
1136
+ interval: { type: Number, default: void 0 },
1137
+ imgSrc: { type: String, default: void 0 },
1138
+ imgAlt: { type: String, default: "" },
1139
+ caption: { type: String, default: void 0 },
1140
+ captionText: { type: String, default: void 0 }
1141
+ },
1142
+ emits: ["component-error"],
1143
+ setup(e, { emit: d }) {
1144
+ return (t, l) => (a(), s("div", {
1145
+ class: h(["carousel-item", { active: e.active }]),
1146
+ "data-bs-interval": e.interval
1147
+ }, [
1148
+ e.imgSrc ? (a(), s("img", {
1149
+ key: 0,
1150
+ src: e.imgSrc,
1151
+ class: "d-block w-100",
1152
+ alt: e.imgAlt
1153
+ }, null, 8, et)) : u("", !0),
1154
+ $(t.$slots, "img"),
1155
+ e.caption || e.captionText || t.$slots.caption ? (a(), s("div", tt, [
1156
+ $(t.$slots, "caption", {}, () => [
1157
+ e.caption ? (a(), s("h5", at, f(e.caption), 1)) : u("", !0),
1158
+ e.captionText ? (a(), s("p", lt, f(e.captionText), 1)) : u("", !0)
1159
+ ])
1160
+ ])) : u("", !0),
1161
+ $(t.$slots, "default")
1162
+ ], 10, _e));
1163
+ }
1164
+ }), nt = ["id", "data-bs-ride", "data-bs-interval", "data-bs-keyboard", "data-bs-pause", "data-bs-wrap", "data-bs-touch"], st = {
1165
+ key: 0,
1166
+ class: "carousel-indicators"
1167
+ }, dt = ["data-bs-target", "data-bs-slide-to", "aria-current", "aria-label"], ot = { class: "carousel-inner" }, rt = {
1168
+ key: 0,
1169
+ class: "carousel-indicators"
1170
+ }, ut = { class: "carousel-inner" }, ct = ["data-bs-target"], ft = ["data-bs-target"], Nl = /* @__PURE__ */ p({
1171
+ __name: "VibeCarousel",
1172
+ props: {
1173
+ id: { type: String, required: !0 },
1174
+ controls: { type: Boolean, default: !0 },
1175
+ indicators: { type: Boolean, default: !0 },
1176
+ ride: { type: [Boolean, String], default: !1 },
1177
+ interval: { type: [Number, Boolean], default: 5e3 },
1178
+ keyboard: { type: Boolean, default: !0 },
1179
+ pause: { type: [String, Boolean], default: "hover" },
1180
+ wrap: { type: Boolean, default: !0 },
1181
+ touch: { type: Boolean, default: !0 },
1182
+ dark: { type: Boolean, default: !1 },
1183
+ fade: { type: Boolean, default: !1 },
1184
+ items: { type: Array, default: void 0 }
1185
+ },
1186
+ emits: ["slide", "slid", "component-error"],
1187
+ setup(e, { emit: d }) {
1188
+ const t = D();
1189
+ return (l, i) => (a(), s("div", {
1190
+ id: e.id,
1191
+ class: h(["carousel", "slide", { "carousel-dark": e.dark, "carousel-fade": e.fade }]),
1192
+ "data-bs-ride": e.ride === !0 ? "carousel" : e.ride,
1193
+ "data-bs-interval": e.interval,
1194
+ "data-bs-keyboard": e.keyboard,
1195
+ "data-bs-pause": e.pause,
1196
+ "data-bs-wrap": e.wrap,
1197
+ "data-bs-touch": e.touch
1198
+ }, [
1199
+ e.items && e.items.length > 0 && !j(t).default ? (a(), s(F, { key: 0 }, [
1200
+ e.indicators ? (a(), s("div", st, [
1201
+ (a(!0), s(F, null, N(e.items, (n, r) => (a(), s("button", {
1202
+ key: `indicator-${r}`,
1203
+ type: "button",
1204
+ "data-bs-target": `#${e.id}`,
1205
+ "data-bs-slide-to": r,
1206
+ class: h({ active: n.active || r === 0 }),
1207
+ "aria-current": n.active || r === 0,
1208
+ "aria-label": `Slide ${r + 1}`
1209
+ }, null, 10, dt))), 128))
1210
+ ])) : u("", !0),
1211
+ v("div", ot, [
1212
+ (a(!0), s(F, null, N(e.items, (n, r) => (a(), x(it, {
1213
+ key: r,
1214
+ active: n.active || r === 0,
1215
+ interval: n.interval,
1216
+ "img-src": n.src,
1217
+ "img-alt": n.alt,
1218
+ caption: n.caption,
1219
+ "caption-text": n.captionText
1220
+ }, null, 8, ["active", "interval", "img-src", "img-alt", "caption", "caption-text"]))), 128))
1221
+ ])
1222
+ ], 64)) : (a(), s(F, { key: 1 }, [
1223
+ e.indicators ? (a(), s("div", rt, [
1224
+ $(l.$slots, "indicators")
1225
+ ])) : u("", !0),
1226
+ v("div", ut, [
1227
+ $(l.$slots, "default")
1228
+ ])
1229
+ ], 64)),
1230
+ e.controls ? (a(), s("button", {
1231
+ key: 2,
1232
+ class: "carousel-control-prev",
1233
+ type: "button",
1234
+ "data-bs-target": `#${e.id}`,
1235
+ "data-bs-slide": "prev"
1236
+ }, [...i[0] || (i[0] = [
1237
+ v("span", {
1238
+ class: "carousel-control-prev-icon",
1239
+ "aria-hidden": "true"
1240
+ }, null, -1),
1241
+ v("span", { class: "visually-hidden" }, "Previous", -1)
1242
+ ])], 8, ct)) : u("", !0),
1243
+ e.controls ? (a(), s("button", {
1244
+ key: 3,
1245
+ class: "carousel-control-next",
1246
+ type: "button",
1247
+ "data-bs-target": `#${e.id}`,
1248
+ "data-bs-slide": "next"
1249
+ }, [...i[1] || (i[1] = [
1250
+ v("span", {
1251
+ class: "carousel-control-next-icon",
1252
+ "aria-hidden": "true"
1253
+ }, null, -1),
1254
+ v("span", { class: "visually-hidden" }, "Next", -1)
1255
+ ])], 8, ft)) : u("", !0)
1256
+ ], 10, nt));
1257
+ }
1258
+ }), vt = ["data-bs-placement", "data-bs-title", "data-bs-trigger", "data-bs-html"], zl = /* @__PURE__ */ p({
1259
+ __name: "VibeTooltip",
1260
+ props: {
1261
+ content: { type: String, required: !0 },
1262
+ placement: { type: String, default: "top" },
1263
+ trigger: { type: String, default: "hover focus" },
1264
+ html: { type: Boolean, default: !1 }
1265
+ },
1266
+ emits: ["component-error"],
1267
+ setup(e, { emit: d }) {
1268
+ return (t, l) => (a(), s("span", {
1269
+ "data-bs-toggle": "tooltip",
1270
+ "data-bs-placement": e.placement,
1271
+ "data-bs-title": e.content,
1272
+ "data-bs-trigger": e.trigger,
1273
+ "data-bs-html": e.html
1274
+ }, [
1275
+ $(t.$slots, "default")
1276
+ ], 8, vt));
1277
+ }
1278
+ }), bt = ["data-bs-placement", "data-bs-title", "data-bs-content", "data-bs-trigger", "data-bs-html"], Al = /* @__PURE__ */ p({
1279
+ __name: "VibePopover",
1280
+ props: {
1281
+ title: { type: String, default: void 0 },
1282
+ content: { type: String, required: !0 },
1283
+ placement: { type: String, default: "top" },
1284
+ trigger: { type: String, default: "click" },
1285
+ html: { type: Boolean, default: !1 }
1286
+ },
1287
+ emits: ["component-error"],
1288
+ setup(e, { emit: d }) {
1289
+ return (t, l) => (a(), s("span", {
1290
+ "data-bs-toggle": "popover",
1291
+ "data-bs-placement": e.placement,
1292
+ "data-bs-title": e.title,
1293
+ "data-bs-content": e.content,
1294
+ "data-bs-trigger": e.trigger,
1295
+ "data-bs-html": e.html
1296
+ }, [
1297
+ $(t.$slots, "default")
1298
+ ], 8, bt));
1299
+ }
1300
+ }), Ol = /* @__PURE__ */ p({
1301
+ __name: "VibeScrollspy",
1302
+ props: {
1303
+ target: { type: String, required: !0 },
1304
+ offset: { type: Number, default: 10 },
1305
+ method: { type: String, default: "auto" },
1306
+ smoothScroll: { type: Boolean, default: !1 },
1307
+ tag: { type: String, default: "div" }
1308
+ },
1309
+ emits: ["activate", "component-error"],
1310
+ setup(e, { emit: d }) {
1311
+ return (t, l) => (a(), x(P(e.tag), {
1312
+ "data-bs-spy": "scroll",
1313
+ "data-bs-target": e.target,
1314
+ "data-bs-offset": e.offset,
1315
+ "data-bs-method": e.method,
1316
+ "data-bs-smooth-scroll": e.smoothScroll,
1317
+ tabindex: "0"
1318
+ }, {
1319
+ default: w(() => [
1320
+ $(t.$slots, "default")
1321
+ ]),
1322
+ _: 3
1323
+ }, 8, ["data-bs-target", "data-bs-offset", "data-bs-method", "data-bs-smooth-scroll"]));
1324
+ }
1325
+ }), mt = { class: "vibe-datatable" }, yt = { class: "row mb-3" }, ht = {
1326
+ key: 0,
1327
+ class: "col-md-6 mb-2 mb-md-0"
1328
+ }, gt = ["placeholder"], pt = {
1329
+ key: 1,
1330
+ class: "col-md-6"
1331
+ }, kt = { class: "d-flex justify-content-md-end align-items-center" }, $t = ["value"], St = ["onClick"], Vt = {
1332
+ key: 0,
1333
+ class: "ms-1"
1334
+ }, xt = ["onClick"], Bt = { key: 0 }, Ct = ["colspan"], wt = { class: "row" }, Tt = {
1335
+ key: 0,
1336
+ class: "col-md-6 mb-2 mb-md-0"
1337
+ }, qt = { class: "datatable-info" }, Mt = {
1338
+ key: 1,
1339
+ class: "col-md-6"
1340
+ }, Pt = { class: "pagination justify-content-md-end mb-0" }, Ft = {
1341
+ key: 0,
1342
+ class: "page-item"
1343
+ }, It = {
1344
+ key: 1,
1345
+ class: "page-item disabled"
1346
+ }, Nt = ["onClick"], zt = {
1347
+ key: 2,
1348
+ class: "page-item disabled"
1349
+ }, At = {
1350
+ key: 3,
1351
+ class: "page-item"
1352
+ }, Ot = /* @__PURE__ */ p({
1353
+ __name: "VibeDataTable",
1354
+ props: {
1355
+ // Data
1356
+ items: { type: Array, default: () => [] },
1357
+ columns: { type: Array, required: !0 },
1358
+ // Table styling
1359
+ striped: { type: Boolean, default: !1 },
1360
+ bordered: { type: Boolean, default: !1 },
1361
+ borderless: { type: Boolean, default: !1 },
1362
+ hover: { type: Boolean, default: !1 },
1363
+ small: { type: Boolean, default: !1 },
1364
+ responsive: { type: Boolean, default: !0 },
1365
+ variant: { type: String, default: void 0 },
1366
+ // Features
1367
+ searchable: { type: Boolean, default: !0 },
1368
+ sortable: { type: Boolean, default: !0 },
1369
+ paginated: { type: Boolean, default: !0 },
1370
+ // Search
1371
+ searchPlaceholder: { type: String, default: "Search..." },
1372
+ searchDebounce: { type: Number, default: 300 },
1373
+ // Pagination
1374
+ perPage: { type: Number, default: 10 },
1375
+ currentPage: { type: Number, default: 1 },
1376
+ perPageOptions: { type: Array, default: () => [5, 10, 25, 50, 100] },
1377
+ // Sorting
1378
+ sortBy: { type: String, default: void 0 },
1379
+ sortDesc: { type: Boolean, default: !1 },
1380
+ // Display
1381
+ showEmpty: { type: Boolean, default: !0 },
1382
+ emptyText: { type: String, default: "No data available" },
1383
+ showPerPage: { type: Boolean, default: !0 },
1384
+ showInfo: { type: Boolean, default: !0 },
1385
+ infoText: { type: String, default: "Showing {start} to {end} of {total} entries" },
1386
+ filteredInfoText: { type: String, default: "Showing {start} to {end} of {total} entries (filtered from {totalRows} total entries)" }
1387
+ },
1388
+ emits: ["update:currentPage", "update:perPage", "update:sortBy", "update:sortDesc", "row-clicked", "component-error"],
1389
+ setup(e, { emit: d }) {
1390
+ const t = e, l = d, i = I(""), n = I(null), r = I(""), o = I(t.currentPage), g = I(t.perPage), b = I(t.sortBy), m = I(t.sortDesc);
1391
+ L(() => t.currentPage, (k) => {
1392
+ o.value = k;
1393
+ }), L(() => t.perPage, (k) => {
1394
+ g.value = k;
1395
+ }), L(() => t.sortBy, (k) => {
1396
+ b.value = k;
1397
+ }), L(() => t.sortDesc, (k) => {
1398
+ m.value = k;
1399
+ }), L(i, (k) => {
1400
+ n.value && clearTimeout(n.value), n.value = window.setTimeout(() => {
1401
+ r.value = k, o.value = 1;
1402
+ }, t.searchDebounce);
1403
+ });
1404
+ const y = c(() => {
1405
+ if (!t.searchable || !r.value)
1406
+ return t.items;
1407
+ const k = r.value.toLowerCase();
1408
+ return t.items.filter((C) => t.columns.some((V) => {
1409
+ if (V.searchable === !1) return !1;
1410
+ const O = C[V.key];
1411
+ return O == null ? !1 : String(O).toLowerCase().includes(k);
1412
+ }));
1413
+ }), S = c(() => {
1414
+ if (!t.sortable || !b.value)
1415
+ return y.value;
1416
+ const k = [...y.value], C = b.value;
1417
+ return k.sort((V, O) => {
1418
+ let z = V[C], G = O[C];
1419
+ return z == null ? 1 : G == null ? -1 : (typeof z == "string" && (z = z.toLowerCase()), typeof G == "string" && (G = G.toLowerCase()), z < G ? m.value ? 1 : -1 : z > G ? m.value ? -1 : 1 : 0);
1420
+ }), k;
1421
+ }), q = c(() => {
1422
+ if (!t.paginated)
1423
+ return S.value;
1424
+ const k = (o.value - 1) * g.value, C = k + g.value;
1425
+ return S.value.slice(k, C);
1426
+ }), A = c(() => t.items.length), B = c(() => y.value.length), M = c(() => Math.ceil(B.value / g.value)), R = c(() => B.value === 0 ? 0 : (o.value - 1) * g.value + 1), X = c(() => {
1427
+ const k = o.value * g.value;
1428
+ return Math.min(k, B.value);
1429
+ }), Z = c(() => (B.value !== A.value ? t.filteredInfoText : t.infoText).replace("{start}", String(R.value)).replace("{end}", String(X.value)).replace("{total}", String(B.value)).replace("{totalRows}", String(A.value))), _ = c(() => {
1430
+ const k = ["table"];
1431
+ return t.striped && k.push("table-striped"), t.bordered && k.push("table-bordered"), t.borderless && k.push("table-borderless"), t.hover && k.push("table-hover"), t.small && k.push("table-sm"), t.variant && k.push(`table-${t.variant}`), k.join(" ");
1432
+ }), ee = (k) => {
1433
+ !t.sortable || k.sortable === !1 || (b.value === k.key ? m.value = !m.value : (b.value = k.key, m.value = !1), l("update:sortBy", b.value), l("update:sortDesc", m.value));
1434
+ }, H = (k) => {
1435
+ k < 1 || k > M.value || (o.value = k, l("update:currentPage", k));
1436
+ }, te = () => {
1437
+ o.value = 1, l("update:perPage", g.value), l("update:currentPage", 1);
1438
+ }, ae = (k, C) => {
1439
+ l("row-clicked", k, C);
1440
+ }, le = (k, C) => {
1441
+ const V = k[C.key];
1442
+ return C.formatter ? C.formatter(V, k) : V;
1443
+ }, ie = (k) => !t.sortable || k.sortable === !1 ? "" : b.value !== k.key ? "⇅" : m.value ? "↓" : "↑", ne = (k) => {
1444
+ const C = { ...k.thStyle };
1445
+ return t.sortable && k.sortable !== !1 && (C.cursor = "pointer"), C;
1446
+ };
1447
+ return (k, C) => (a(), s("div", mt, [
1448
+ v("div", yt, [
1449
+ e.searchable ? (a(), s("div", ht, [
1450
+ Y(v("input", {
1451
+ "onUpdate:modelValue": C[0] || (C[0] = (V) => i.value = V),
1452
+ type: "search",
1453
+ class: "form-control",
1454
+ placeholder: e.searchPlaceholder
1455
+ }, null, 8, gt), [
1456
+ [se, i.value]
1457
+ ])
1458
+ ])) : u("", !0),
1459
+ e.showPerPage && e.paginated ? (a(), s("div", pt, [
1460
+ v("div", kt, [
1461
+ C[6] || (C[6] = v("label", { class: "me-2 mb-0" }, "Show", -1)),
1462
+ Y(v("select", {
1463
+ "onUpdate:modelValue": C[1] || (C[1] = (V) => g.value = V),
1464
+ class: "form-select form-select-sm",
1465
+ style: { width: "auto" },
1466
+ onChange: te
1467
+ }, [
1468
+ (a(!0), s(F, null, N(e.perPageOptions, (V) => (a(), s("option", {
1469
+ key: V,
1470
+ value: V
1471
+ }, f(V), 9, $t))), 128))
1472
+ ], 544), [
1473
+ [
1474
+ de,
1475
+ g.value,
1476
+ void 0,
1477
+ { number: !0 }
1478
+ ]
1479
+ ]),
1480
+ C[7] || (C[7] = v("span", { class: "ms-2" }, "entries", -1))
1481
+ ])
1482
+ ])) : u("", !0)
1483
+ ]),
1484
+ v("div", {
1485
+ class: h({ "table-responsive": e.responsive })
1486
+ }, [
1487
+ v("table", {
1488
+ class: h(_.value)
1489
+ }, [
1490
+ v("thead", null, [
1491
+ v("tr", null, [
1492
+ (a(!0), s(F, null, N(e.columns, (V) => (a(), s("th", {
1493
+ key: V.key,
1494
+ class: h(V.headerClass),
1495
+ style: E(ne(V)),
1496
+ onClick: (O) => ee(V)
1497
+ }, [
1498
+ T(f(V.label) + " ", 1),
1499
+ e.sortable && V.sortable !== !1 ? (a(), s("span", Vt, f(ie(V)), 1)) : u("", !0)
1500
+ ], 14, St))), 128))
1501
+ ])
1502
+ ]),
1503
+ v("tbody", null, [
1504
+ (a(!0), s(F, null, N(q.value, (V, O) => (a(), s("tr", {
1505
+ key: O,
1506
+ onClick: (z) => ae(V, O),
1507
+ style: { cursor: "pointer" }
1508
+ }, [
1509
+ (a(!0), s(F, null, N(e.columns, (z) => (a(), s("td", {
1510
+ key: z.key,
1511
+ class: h(z.class),
1512
+ style: E(z.tdStyle)
1513
+ }, [
1514
+ $(k.$slots, `cell(${z.key})`, {
1515
+ item: V,
1516
+ value: V[z.key],
1517
+ index: O
1518
+ }, () => [
1519
+ T(f(le(V, z)), 1)
1520
+ ], !0)
1521
+ ], 6))), 128))
1522
+ ], 8, xt))), 128)),
1523
+ q.value.length === 0 && e.showEmpty ? (a(), s("tr", Bt, [
1524
+ v("td", {
1525
+ colspan: e.columns.length,
1526
+ class: "text-center"
1527
+ }, f(e.emptyText), 9, Ct)
1528
+ ])) : u("", !0)
1529
+ ])
1530
+ ], 2)
1531
+ ], 2),
1532
+ v("div", wt, [
1533
+ e.showInfo ? (a(), s("div", Tt, [
1534
+ v("div", qt, f(Z.value), 1)
1535
+ ])) : u("", !0),
1536
+ e.paginated && M.value > 1 ? (a(), s("div", Mt, [
1537
+ v("nav", null, [
1538
+ v("ul", Pt, [
1539
+ v("li", {
1540
+ class: h(["page-item", { disabled: o.value === 1 }])
1541
+ }, [
1542
+ v("a", {
1543
+ class: "page-link",
1544
+ href: "#",
1545
+ onClick: C[2] || (C[2] = Q((V) => H(o.value - 1), ["prevent"]))
1546
+ }, " Previous ")
1547
+ ], 2),
1548
+ o.value > 3 ? (a(), s("li", Ft, [
1549
+ v("a", {
1550
+ class: "page-link",
1551
+ href: "#",
1552
+ onClick: C[3] || (C[3] = Q((V) => H(1), ["prevent"]))
1553
+ }, "1")
1554
+ ])) : u("", !0),
1555
+ o.value > 4 ? (a(), s("li", It, [...C[8] || (C[8] = [
1556
+ v("span", { class: "page-link" }, "...", -1)
1557
+ ])])) : u("", !0),
1558
+ (a(!0), s(F, null, N(Array.from({ length: M.value }, (V, O) => O + 1).filter(
1559
+ (V) => V >= o.value - 2 && V <= o.value + 2
1560
+ ), (V) => (a(), s("li", {
1561
+ key: V,
1562
+ class: h(["page-item", { active: V === o.value }])
1563
+ }, [
1564
+ v("a", {
1565
+ class: "page-link",
1566
+ href: "#",
1567
+ onClick: Q((O) => H(V), ["prevent"])
1568
+ }, f(V), 9, Nt)
1569
+ ], 2))), 128)),
1570
+ o.value < M.value - 3 ? (a(), s("li", zt, [...C[9] || (C[9] = [
1571
+ v("span", { class: "page-link" }, "...", -1)
1572
+ ])])) : u("", !0),
1573
+ o.value < M.value - 2 ? (a(), s("li", At, [
1574
+ v("a", {
1575
+ class: "page-link",
1576
+ href: "#",
1577
+ onClick: C[4] || (C[4] = Q((V) => H(M.value), ["prevent"]))
1578
+ }, f(M.value), 1)
1579
+ ])) : u("", !0),
1580
+ v("li", {
1581
+ class: h(["page-item", { disabled: o.value === M.value }])
1582
+ }, [
1583
+ v("a", {
1584
+ class: "page-link",
1585
+ href: "#",
1586
+ onClick: C[5] || (C[5] = Q((V) => H(o.value + 1), ["prevent"]))
1587
+ }, " Next ")
1588
+ ], 2)
1589
+ ])
1590
+ ])
1591
+ ])) : u("", !0)
1592
+ ])
1593
+ ]));
1594
+ }
1595
+ }), W = (e, d) => {
1596
+ const t = e.__vccOpts || e;
1597
+ for (const [l, i] of d)
1598
+ t[l] = i;
1599
+ return t;
1600
+ }, jl = /* @__PURE__ */ W(Ot, [["__scopeId", "data-v-48221c7b"]]), jt = { class: "mb-3" }, Lt = ["for"], Dt = {
1601
+ key: 0,
1602
+ class: "text-danger"
1603
+ }, Rt = ["id", "type", "value", "placeholder", "disabled", "readonly", "required", "aria-invalid", "aria-describedby"], Gt = ["id"], Et = {
1604
+ key: 2,
1605
+ class: "valid-feedback",
1606
+ style: { display: "block" }
1607
+ }, Ht = ["id"], Ll = /* @__PURE__ */ p({
1608
+ __name: "VibeFormInput",
1609
+ props: {
1610
+ modelValue: { type: [String, Number], default: "" },
1611
+ type: { type: String, default: "text" },
1612
+ id: { type: String, required: !0 },
1613
+ label: { type: String, default: void 0 },
1614
+ placeholder: { type: String, default: void 0 },
1615
+ disabled: { type: Boolean, default: !1 },
1616
+ readonly: { type: Boolean, default: !1 },
1617
+ required: { type: Boolean, default: !1 },
1618
+ size: { type: String, default: void 0 },
1619
+ validationState: { type: String, default: null },
1620
+ validationMessage: { type: String, default: void 0 },
1621
+ validationRules: { type: [Array, Function], default: void 0 },
1622
+ validateOn: { type: String, default: "blur" },
1623
+ helpText: { type: String, default: void 0 },
1624
+ plaintext: { type: Boolean, default: !1 }
1625
+ },
1626
+ emits: ["update:modelValue", "validate", "blur", "focus", "input", "change"],
1627
+ setup(e, { emit: d }) {
1628
+ const t = e, l = d, i = c(() => t.validationState), n = c(() => {
1629
+ const m = [];
1630
+ return t.plaintext ? m.push("form-control-plaintext") : (m.push("form-control"), t.size && m.push(`form-control-${t.size}`)), i.value === "valid" && m.push("is-valid"), i.value === "invalid" && m.push("is-invalid"), m.join(" ");
1631
+ }), r = (m) => {
1632
+ const y = m.target, S = t.type === "number" ? y.value === "" ? "" : Number(y.value) : y.value;
1633
+ l("update:modelValue", S), l("input", m), t.validateOn === "input" && l("validate");
1634
+ }, o = (m) => {
1635
+ l("change", m), t.validateOn === "change" && l("validate");
1636
+ }, g = (m) => {
1637
+ l("blur", m), t.validateOn === "blur" && l("validate");
1638
+ }, b = (m) => {
1639
+ l("focus", m);
1640
+ };
1641
+ return (m, y) => (a(), s("div", jt, [
1642
+ e.label ? (a(), s("label", {
1643
+ key: 0,
1644
+ for: e.id,
1645
+ class: "form-label"
1646
+ }, [
1647
+ T(f(e.label) + " ", 1),
1648
+ e.required ? (a(), s("span", Dt, "*")) : u("", !0)
1649
+ ], 8, Lt)) : u("", !0),
1650
+ v("input", {
1651
+ id: e.id,
1652
+ type: e.type,
1653
+ class: h(n.value),
1654
+ value: e.modelValue,
1655
+ placeholder: e.placeholder,
1656
+ disabled: e.disabled,
1657
+ readonly: e.readonly || e.plaintext,
1658
+ required: e.required,
1659
+ "aria-invalid": i.value === "invalid",
1660
+ "aria-describedby": e.validationMessage || e.helpText ? `${e.id}-feedback` : void 0,
1661
+ onInput: r,
1662
+ onChange: o,
1663
+ onBlur: g,
1664
+ onFocus: b
1665
+ }, null, 42, Rt),
1666
+ e.helpText && !e.validationMessage ? (a(), s("div", {
1667
+ key: 1,
1668
+ id: `${e.id}-feedback`,
1669
+ class: "form-text"
1670
+ }, f(e.helpText), 9, Gt)) : u("", !0),
1671
+ i.value === "valid" ? (a(), s("div", Et, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
1672
+ i.value === "invalid" ? (a(), s("div", {
1673
+ key: 3,
1674
+ id: `${e.id}-feedback`,
1675
+ class: "invalid-feedback",
1676
+ style: { display: "block" }
1677
+ }, f(e.validationMessage || "Please provide a valid value."), 9, Ht)) : u("", !0)
1678
+ ]));
1679
+ }
1680
+ }), Qt = { class: "mb-3" }, Ut = ["for"], Wt = {
1681
+ key: 0,
1682
+ class: "text-danger"
1683
+ }, Yt = ["id", "value", "disabled", "required", "multiple", "size", "aria-invalid", "aria-describedby"], Kt = ["selected"], Jt = ["value", "disabled"], Xt = ["id"], Zt = {
1684
+ key: 2,
1685
+ class: "valid-feedback",
1686
+ style: { display: "block" }
1687
+ }, _t = ["id"], Dl = /* @__PURE__ */ p({
1688
+ __name: "VibeFormSelect",
1689
+ props: {
1690
+ modelValue: { type: [String, Number, Array], default: "" },
1691
+ id: { type: String, required: !0 },
1692
+ label: { type: String, default: void 0 },
1693
+ options: { type: Array, default: () => [] },
1694
+ disabled: { type: Boolean, default: !1 },
1695
+ required: { type: Boolean, default: !1 },
1696
+ multiple: { type: Boolean, default: !1 },
1697
+ size: { type: String, default: void 0 },
1698
+ htmlSize: { type: Number, default: void 0 },
1699
+ validationState: { type: String, default: null },
1700
+ validationMessage: { type: String, default: void 0 },
1701
+ validationRules: { type: [Array, Function], default: void 0 },
1702
+ validateOn: { type: String, default: "blur" },
1703
+ helpText: { type: String, default: void 0 },
1704
+ placeholder: { type: String, default: void 0 }
1705
+ },
1706
+ emits: ["update:modelValue", "validate", "blur", "focus", "change"],
1707
+ setup(e, { emit: d }) {
1708
+ const t = e, l = d, i = c(() => t.validationState), n = c(() => {
1709
+ const b = ["form-select"];
1710
+ return t.size && b.push(`form-select-${t.size}`), i.value === "valid" && b.push("is-valid"), i.value === "invalid" && b.push("is-invalid"), b.join(" ");
1711
+ }), r = (b) => {
1712
+ const m = b.target;
1713
+ let y;
1714
+ t.multiple ? y = Array.from(m.selectedOptions).map((q) => q.value) : y = m.value, l("update:modelValue", y), l("change", b), t.validateOn === "change" && l("validate");
1715
+ }, o = (b) => {
1716
+ l("blur", b), t.validateOn === "blur" && l("validate");
1717
+ }, g = (b) => {
1718
+ l("focus", b);
1719
+ };
1720
+ return (b, m) => (a(), s("div", Qt, [
1721
+ e.label ? (a(), s("label", {
1722
+ key: 0,
1723
+ for: e.id,
1724
+ class: "form-label"
1725
+ }, [
1726
+ T(f(e.label) + " ", 1),
1727
+ e.required ? (a(), s("span", Wt, "*")) : u("", !0)
1728
+ ], 8, Ut)) : u("", !0),
1729
+ v("select", {
1730
+ id: e.id,
1731
+ class: h(n.value),
1732
+ value: e.modelValue,
1733
+ disabled: e.disabled,
1734
+ required: e.required,
1735
+ multiple: e.multiple,
1736
+ size: e.htmlSize,
1737
+ "aria-invalid": i.value === "invalid",
1738
+ "aria-describedby": e.validationMessage || e.helpText ? `${e.id}-feedback` : void 0,
1739
+ onChange: r,
1740
+ onBlur: o,
1741
+ onFocus: g
1742
+ }, [
1743
+ e.placeholder && !e.multiple ? (a(), s("option", {
1744
+ key: 0,
1745
+ value: "",
1746
+ disabled: "",
1747
+ selected: !e.modelValue
1748
+ }, f(e.placeholder), 9, Kt)) : u("", !0),
1749
+ (a(!0), s(F, null, N(e.options, (y) => (a(), s("option", {
1750
+ key: y.value,
1751
+ value: y.value,
1752
+ disabled: y.disabled
1753
+ }, f(y.text), 9, Jt))), 128)),
1754
+ $(b.$slots, "default")
1755
+ ], 42, Yt),
1756
+ e.helpText && !e.validationMessage ? (a(), s("div", {
1757
+ key: 1,
1758
+ id: `${e.id}-feedback`,
1759
+ class: "form-text"
1760
+ }, f(e.helpText), 9, Xt)) : u("", !0),
1761
+ i.value === "valid" ? (a(), s("div", Zt, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
1762
+ i.value === "invalid" ? (a(), s("div", {
1763
+ key: 3,
1764
+ id: `${e.id}-feedback`,
1765
+ class: "invalid-feedback",
1766
+ style: { display: "block" }
1767
+ }, f(e.validationMessage || "Please select a valid option."), 9, _t)) : u("", !0)
1768
+ ]));
1769
+ }
1770
+ }), ea = { class: "mb-3" }, ta = ["for"], aa = {
1771
+ key: 0,
1772
+ class: "text-danger"
1773
+ }, la = ["id", "value", "placeholder", "disabled", "readonly", "required", "rows", "maxlength", "aria-invalid", "aria-describedby"], ia = {
1774
+ key: 1,
1775
+ class: "form-text"
1776
+ }, na = ["id"], sa = {
1777
+ key: 3,
1778
+ class: "valid-feedback",
1779
+ style: { display: "block" }
1780
+ }, da = ["id"], Rl = /* @__PURE__ */ p({
1781
+ __name: "VibeFormTextarea",
1782
+ props: {
1783
+ modelValue: { type: String, default: "" },
1784
+ id: { type: String, required: !0 },
1785
+ label: { type: String, default: void 0 },
1786
+ placeholder: { type: String, default: void 0 },
1787
+ disabled: { type: Boolean, default: !1 },
1788
+ readonly: { type: Boolean, default: !1 },
1789
+ required: { type: Boolean, default: !1 },
1790
+ rows: { type: Number, default: 3 },
1791
+ maxlength: { type: Number, default: void 0 },
1792
+ size: { type: String, default: void 0 },
1793
+ validationState: { type: String, default: null },
1794
+ validationMessage: { type: String, default: void 0 },
1795
+ validationRules: { type: [Array, Function], default: void 0 },
1796
+ validateOn: { type: String, default: "blur" },
1797
+ helpText: { type: String, default: void 0 },
1798
+ showCharCount: { type: Boolean, default: !1 }
1799
+ },
1800
+ emits: ["update:modelValue", "validate", "blur", "focus", "input", "change"],
1801
+ setup(e, { emit: d }) {
1802
+ const t = e, l = d, i = c(() => t.validationState), n = c(() => {
1803
+ const S = ["form-control"];
1804
+ return t.size && S.push(`form-control-${t.size}`), i.value === "valid" && S.push("is-valid"), i.value === "invalid" && S.push("is-invalid"), S.join(" ");
1805
+ }), r = c(() => t.modelValue ? t.modelValue.length : 0), o = c(() => t.maxlength ? `${r.value} / ${t.maxlength}` : `${r.value}`), g = (S) => {
1806
+ const q = S.target;
1807
+ l("update:modelValue", q.value), l("input", S), t.validateOn === "input" && l("validate");
1808
+ }, b = (S) => {
1809
+ l("change", S), t.validateOn === "change" && l("validate");
1810
+ }, m = (S) => {
1811
+ l("blur", S), t.validateOn === "blur" && l("validate");
1812
+ }, y = (S) => {
1813
+ l("focus", S);
1814
+ };
1815
+ return (S, q) => (a(), s("div", ea, [
1816
+ e.label ? (a(), s("label", {
1817
+ key: 0,
1818
+ for: e.id,
1819
+ class: "form-label"
1820
+ }, [
1821
+ T(f(e.label) + " ", 1),
1822
+ e.required ? (a(), s("span", aa, "*")) : u("", !0)
1823
+ ], 8, ta)) : u("", !0),
1824
+ v("textarea", {
1825
+ id: e.id,
1826
+ class: h(n.value),
1827
+ value: e.modelValue,
1828
+ placeholder: e.placeholder,
1829
+ disabled: e.disabled,
1830
+ readonly: e.readonly,
1831
+ required: e.required,
1832
+ rows: e.rows,
1833
+ maxlength: e.maxlength,
1834
+ "aria-invalid": i.value === "invalid",
1835
+ "aria-describedby": e.validationMessage || e.helpText ? `${e.id}-feedback` : void 0,
1836
+ onInput: g,
1837
+ onChange: b,
1838
+ onBlur: m,
1839
+ onFocus: y
1840
+ }, null, 42, la),
1841
+ e.showCharCount ? (a(), s("div", ia, f(o.value), 1)) : u("", !0),
1842
+ e.helpText && !e.validationMessage && !e.showCharCount ? (a(), s("div", {
1843
+ key: 2,
1844
+ id: `${e.id}-feedback`,
1845
+ class: "form-text"
1846
+ }, f(e.helpText), 9, na)) : u("", !0),
1847
+ i.value === "valid" ? (a(), s("div", sa, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
1848
+ i.value === "invalid" ? (a(), s("div", {
1849
+ key: 4,
1850
+ id: `${e.id}-feedback`,
1851
+ class: "invalid-feedback",
1852
+ style: { display: "block" }
1853
+ }, f(e.validationMessage || "Please provide a valid value."), 9, da)) : u("", !0)
1854
+ ]));
1855
+ }
1856
+ }), oa = { class: "mb-3" }, ra = ["for"], ua = {
1857
+ key: 0,
1858
+ class: "text-danger"
1859
+ }, ca = ["disabled"], fa = ["id", "value", "disabled", "readonly", "required", "min", "max", "step", "aria-invalid", "aria-describedby"], va = ["disabled"], ba = ["id"], ma = {
1860
+ key: 2,
1861
+ class: "valid-feedback",
1862
+ style: { display: "block" }
1863
+ }, ya = ["id"], ha = /* @__PURE__ */ p({
1864
+ __name: "VibeFormSpinbutton",
1865
+ props: {
1866
+ modelValue: { type: Number, default: 0 },
1867
+ id: { type: String, required: !0 },
1868
+ label: { type: String, default: void 0 },
1869
+ disabled: { type: Boolean, default: !1 },
1870
+ readonly: { type: Boolean, default: !1 },
1871
+ required: { type: Boolean, default: !1 },
1872
+ min: { type: Number, default: void 0 },
1873
+ max: { type: Number, default: void 0 },
1874
+ step: { type: Number, default: 1 },
1875
+ size: { type: String, default: void 0 },
1876
+ validationState: { type: String, default: null },
1877
+ validationMessage: { type: String, default: void 0 },
1878
+ validationRules: { type: [Array, Function], default: void 0 },
1879
+ validateOn: { type: String, default: "blur" },
1880
+ helpText: { type: String, default: void 0 },
1881
+ wrap: { type: Boolean, default: !1 },
1882
+ vertical: { type: Boolean, default: !1 }
1883
+ },
1884
+ emits: ["update:modelValue", "validate", "blur", "focus", "input", "change", "increment", "decrement"],
1885
+ setup(e, { emit: d }) {
1886
+ const t = e, l = d, i = c(() => t.validationState), n = c(() => {
1887
+ const B = ["form-control"];
1888
+ return t.size && B.push(`form-control-${t.size}`), i.value === "valid" && B.push("is-valid"), i.value === "invalid" && B.push("is-invalid"), B.join(" ");
1889
+ }), r = c(() => {
1890
+ const B = ["input-group"];
1891
+ return t.size && B.push(`input-group-${t.size}`), t.vertical && B.push("input-group-vertical"), B.join(" ");
1892
+ }), o = c(() => t.disabled || t.readonly ? !1 : t.min === void 0 || t.wrap ? !0 : t.modelValue > t.min), g = c(() => t.disabled || t.readonly ? !1 : t.max === void 0 || t.wrap ? !0 : t.modelValue < t.max), b = (B) => {
1893
+ const M = B.target;
1894
+ let R = M.value === "" ? 0 : Number(M.value);
1895
+ t.min !== void 0 && R < t.min && (R = t.min), t.max !== void 0 && R > t.max && (R = t.max), l("update:modelValue", R), l("input", B), t.validateOn === "input" && l("validate");
1896
+ }, m = (B) => {
1897
+ l("change", B), t.validateOn === "change" && l("validate");
1898
+ }, y = (B) => {
1899
+ l("blur", B), t.validateOn === "blur" && l("validate");
1900
+ }, S = (B) => {
1901
+ l("focus", B);
1902
+ }, q = () => {
1903
+ if (!g.value) return;
1904
+ let B = t.modelValue + t.step;
1905
+ t.max !== void 0 && B > t.max && (B = t.wrap ? t.min ?? 0 : t.max), l("update:modelValue", B), l("increment", B), t.validateOn === "change" && l("validate");
1906
+ }, A = () => {
1907
+ if (!o.value) return;
1908
+ let B = t.modelValue - t.step;
1909
+ t.min !== void 0 && B < t.min && (B = t.wrap ? t.max ?? 0 : t.min), l("update:modelValue", B), l("decrement", B), t.validateOn === "change" && l("validate");
1910
+ };
1911
+ return (B, M) => (a(), s("div", oa, [
1912
+ e.label ? (a(), s("label", {
1913
+ key: 0,
1914
+ for: e.id,
1915
+ class: "form-label"
1916
+ }, [
1917
+ T(f(e.label) + " ", 1),
1918
+ e.required ? (a(), s("span", ua, "*")) : u("", !0)
1919
+ ], 8, ra)) : u("", !0),
1920
+ v("div", {
1921
+ class: h(r.value)
1922
+ }, [
1923
+ v("button", {
1924
+ class: "btn btn-outline-secondary",
1925
+ type: "button",
1926
+ disabled: !o.value,
1927
+ onClick: A,
1928
+ "aria-label": "Decrement"
1929
+ }, [...M[0] || (M[0] = [
1930
+ v("span", { "aria-hidden": "true" }, "−", -1)
1931
+ ])], 8, ca),
1932
+ v("input", {
1933
+ id: e.id,
1934
+ type: "number",
1935
+ class: h(n.value),
1936
+ value: e.modelValue,
1937
+ disabled: e.disabled,
1938
+ readonly: e.readonly,
1939
+ required: e.required,
1940
+ min: e.min,
1941
+ max: e.max,
1942
+ step: e.step,
1943
+ "aria-invalid": i.value === "invalid",
1944
+ "aria-describedby": e.validationMessage || e.helpText ? `${e.id}-feedback` : void 0,
1945
+ onInput: b,
1946
+ onChange: m,
1947
+ onBlur: y,
1948
+ onFocus: S
1949
+ }, null, 42, fa),
1950
+ v("button", {
1951
+ class: "btn btn-outline-secondary",
1952
+ type: "button",
1953
+ disabled: !g.value,
1954
+ onClick: q,
1955
+ "aria-label": "Increment"
1956
+ }, [...M[1] || (M[1] = [
1957
+ v("span", { "aria-hidden": "true" }, "+", -1)
1958
+ ])], 8, va)
1959
+ ], 2),
1960
+ e.helpText && !e.validationMessage ? (a(), s("div", {
1961
+ key: 1,
1962
+ id: `${e.id}-feedback`,
1963
+ class: "form-text"
1964
+ }, f(e.helpText), 9, ba)) : u("", !0),
1965
+ i.value === "valid" ? (a(), s("div", ma, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
1966
+ i.value === "invalid" ? (a(), s("div", {
1967
+ key: 3,
1968
+ id: `${e.id}-feedback`,
1969
+ class: "invalid-feedback",
1970
+ style: { display: "block" }
1971
+ }, f(e.validationMessage || "Please provide a valid value."), 9, ya)) : u("", !0)
1972
+ ]));
1973
+ }
1974
+ }), Gl = /* @__PURE__ */ W(ha, [["__scopeId", "data-v-e706d3dc"]]), ga = { class: "mb-3" }, pa = ["for"], ka = {
1975
+ key: 0,
1976
+ class: "text-danger"
1977
+ }, $a = ["id", "type", "value", "disabled", "readonly", "required", "min", "max", "aria-invalid", "aria-describedby"], Sa = ["id"], Va = {
1978
+ key: 2,
1979
+ class: "valid-feedback",
1980
+ style: { display: "block" }
1981
+ }, xa = ["id"], El = /* @__PURE__ */ p({
1982
+ __name: "VibeFormDatepicker",
1983
+ props: {
1984
+ modelValue: { type: String, default: "" },
1985
+ id: { type: String, required: !0 },
1986
+ label: { type: String, default: void 0 },
1987
+ disabled: { type: Boolean, default: !1 },
1988
+ readonly: { type: Boolean, default: !1 },
1989
+ required: { type: Boolean, default: !1 },
1990
+ min: { type: String, default: void 0 },
1991
+ max: { type: String, default: void 0 },
1992
+ size: { type: String, default: void 0 },
1993
+ validationState: { type: String, default: null },
1994
+ validationMessage: { type: String, default: void 0 },
1995
+ validationRules: { type: [Array, Function], default: void 0 },
1996
+ validateOn: { type: String, default: "blur" },
1997
+ helpText: { type: String, default: void 0 },
1998
+ type: { type: String, default: "date" }
1999
+ },
2000
+ emits: ["update:modelValue", "validate", "blur", "focus", "input", "change"],
2001
+ setup(e, { emit: d }) {
2002
+ const t = e, l = d, i = c(() => t.validationState), n = c(() => {
2003
+ const m = ["form-control"];
2004
+ return t.size && m.push(`form-control-${t.size}`), i.value === "valid" && m.push("is-valid"), i.value === "invalid" && m.push("is-invalid"), m.join(" ");
2005
+ }), r = (m) => {
2006
+ const y = m.target;
2007
+ l("update:modelValue", y.value), l("input", m), t.validateOn === "input" && l("validate");
2008
+ }, o = (m) => {
2009
+ l("change", m), t.validateOn === "change" && l("validate");
2010
+ }, g = (m) => {
2011
+ l("blur", m), t.validateOn === "blur" && l("validate");
2012
+ }, b = (m) => {
2013
+ l("focus", m);
2014
+ };
2015
+ return (m, y) => (a(), s("div", ga, [
2016
+ e.label ? (a(), s("label", {
2017
+ key: 0,
2018
+ for: e.id,
2019
+ class: "form-label"
2020
+ }, [
2021
+ T(f(e.label) + " ", 1),
2022
+ e.required ? (a(), s("span", ka, "*")) : u("", !0)
2023
+ ], 8, pa)) : u("", !0),
2024
+ v("input", {
2025
+ id: e.id,
2026
+ type: e.type,
2027
+ class: h(n.value),
2028
+ value: e.modelValue,
2029
+ disabled: e.disabled,
2030
+ readonly: e.readonly,
2031
+ required: e.required,
2032
+ min: e.min,
2033
+ max: e.max,
2034
+ "aria-invalid": i.value === "invalid",
2035
+ "aria-describedby": e.validationMessage || e.helpText ? `${e.id}-feedback` : void 0,
2036
+ onInput: r,
2037
+ onChange: o,
2038
+ onBlur: g,
2039
+ onFocus: b
2040
+ }, null, 42, $a),
2041
+ e.helpText && !e.validationMessage ? (a(), s("div", {
2042
+ key: 1,
2043
+ id: `${e.id}-feedback`,
2044
+ class: "form-text"
2045
+ }, f(e.helpText), 9, Sa)) : u("", !0),
2046
+ i.value === "valid" ? (a(), s("div", Va, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
2047
+ i.value === "invalid" ? (a(), s("div", {
2048
+ key: 3,
2049
+ id: `${e.id}-feedback`,
2050
+ class: "invalid-feedback",
2051
+ style: { display: "block" }
2052
+ }, f(e.validationMessage || "Please provide a valid date."), 9, xa)) : u("", !0)
2053
+ ]));
2054
+ }
2055
+ }), Ba = ["id", "checked", "value", "disabled", "required", "indeterminate", "aria-invalid", "aria-describedby"], Ca = ["for"], wa = {
2056
+ key: 0,
2057
+ class: "text-danger"
2058
+ }, Ta = ["id"], qa = {
2059
+ key: 2,
2060
+ class: "valid-feedback",
2061
+ style: { display: "block" }
2062
+ }, Ma = ["id"], Hl = /* @__PURE__ */ p({
2063
+ __name: "VibeFormCheckbox",
2064
+ props: {
2065
+ modelValue: { type: [Boolean, Array], default: !1 },
2066
+ id: { type: String, required: !0 },
2067
+ label: { type: String, default: void 0 },
2068
+ value: { type: [String, Number, Boolean], default: !0 },
2069
+ disabled: { type: Boolean, default: !1 },
2070
+ required: { type: Boolean, default: !1 },
2071
+ inline: { type: Boolean, default: !1 },
2072
+ validationState: { type: String, default: null },
2073
+ validationMessage: { type: String, default: void 0 },
2074
+ validationRules: { type: [Array, Function], default: void 0 },
2075
+ validateOn: { type: String, default: "blur" },
2076
+ helpText: { type: String, default: void 0 },
2077
+ indeterminate: { type: Boolean, default: !1 }
2078
+ },
2079
+ emits: ["update:modelValue", "validate", "blur", "focus", "change"],
2080
+ setup(e, { emit: d }) {
2081
+ const t = e, l = d, i = c(() => t.validationState), n = c(() => {
2082
+ const y = ["form-check-input"];
2083
+ return i.value === "valid" && y.push("is-valid"), i.value === "invalid" && y.push("is-invalid"), y.join(" ");
2084
+ }), r = c(() => {
2085
+ const y = ["form-check"];
2086
+ return t.inline && y.push("form-check-inline"), y.join(" ");
2087
+ }), o = c(() => Array.isArray(t.modelValue) ? t.modelValue.includes(t.value) : t.modelValue === t.value || t.modelValue === !0), g = (y) => {
2088
+ const S = y.target;
2089
+ let q;
2090
+ if (Array.isArray(t.modelValue))
2091
+ if (q = [...t.modelValue], S.checked)
2092
+ q.includes(t.value) || q.push(t.value);
2093
+ else {
2094
+ const A = q.indexOf(t.value);
2095
+ A > -1 && q.splice(A, 1);
2096
+ }
2097
+ else
2098
+ q = S.checked;
2099
+ l("update:modelValue", q), l("change", y), t.validateOn === "change" && l("validate");
2100
+ }, b = (y) => {
2101
+ l("blur", y), t.validateOn === "blur" && l("validate");
2102
+ }, m = (y) => {
2103
+ l("focus", y);
2104
+ };
2105
+ return (y, S) => (a(), s("div", {
2106
+ class: h(r.value)
2107
+ }, [
2108
+ v("input", {
2109
+ id: e.id,
2110
+ type: "checkbox",
2111
+ class: h(n.value),
2112
+ checked: o.value,
2113
+ value: e.value,
2114
+ disabled: e.disabled,
2115
+ required: e.required,
2116
+ indeterminate: e.indeterminate,
2117
+ "aria-invalid": i.value === "invalid",
2118
+ "aria-describedby": e.validationMessage || e.helpText ? `${e.id}-feedback` : void 0,
2119
+ onChange: g,
2120
+ onBlur: b,
2121
+ onFocus: m
2122
+ }, null, 42, Ba),
2123
+ e.label ? (a(), s("label", {
2124
+ key: 0,
2125
+ for: e.id,
2126
+ class: "form-check-label"
2127
+ }, [
2128
+ T(f(e.label) + " ", 1),
2129
+ e.required ? (a(), s("span", wa, "*")) : u("", !0)
2130
+ ], 8, Ca)) : u("", !0),
2131
+ e.helpText && !e.validationMessage ? (a(), s("div", {
2132
+ key: 1,
2133
+ id: `${e.id}-feedback`,
2134
+ class: "form-text"
2135
+ }, f(e.helpText), 9, Ta)) : u("", !0),
2136
+ i.value === "valid" ? (a(), s("div", qa, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
2137
+ i.value === "invalid" ? (a(), s("div", {
2138
+ key: 3,
2139
+ id: `${e.id}-feedback`,
2140
+ class: "invalid-feedback",
2141
+ style: { display: "block" }
2142
+ }, f(e.validationMessage || "You must check this box."), 9, Ma)) : u("", !0)
2143
+ ], 2));
2144
+ }
2145
+ }), Pa = ["id", "checked", "value", "name", "disabled", "required", "aria-invalid", "aria-describedby"], Fa = ["for"], Ia = {
2146
+ key: 0,
2147
+ class: "text-danger"
2148
+ }, Na = ["id"], za = {
2149
+ key: 2,
2150
+ class: "valid-feedback",
2151
+ style: { display: "block" }
2152
+ }, Aa = ["id"], Ql = /* @__PURE__ */ p({
2153
+ __name: "VibeFormRadio",
2154
+ props: {
2155
+ modelValue: { type: [String, Number, Boolean], default: void 0 },
2156
+ id: { type: String, required: !0 },
2157
+ label: { type: String, default: void 0 },
2158
+ value: { type: [String, Number, Boolean], required: !0 },
2159
+ name: { type: String, required: !0 },
2160
+ disabled: { type: Boolean, default: !1 },
2161
+ required: { type: Boolean, default: !1 },
2162
+ inline: { type: Boolean, default: !1 },
2163
+ validationState: { type: String, default: null },
2164
+ validationMessage: { type: String, default: void 0 },
2165
+ validationRules: { type: [Array, Function], default: void 0 },
2166
+ validateOn: { type: String, default: "blur" },
2167
+ helpText: { type: String, default: void 0 }
2168
+ },
2169
+ emits: ["update:modelValue", "validate", "blur", "focus", "change"],
2170
+ setup(e, { emit: d }) {
2171
+ const t = e, l = d, i = c(() => t.validationState), n = c(() => {
2172
+ const y = ["form-check-input"];
2173
+ return i.value === "valid" && y.push("is-valid"), i.value === "invalid" && y.push("is-invalid"), y.join(" ");
2174
+ }), r = c(() => {
2175
+ const y = ["form-check"];
2176
+ return t.inline && y.push("form-check-inline"), y.join(" ");
2177
+ }), o = c(() => t.modelValue === t.value), g = (y) => {
2178
+ y.target.checked && l("update:modelValue", t.value), l("change", y), t.validateOn === "change" && l("validate");
2179
+ }, b = (y) => {
2180
+ l("blur", y), t.validateOn === "blur" && l("validate");
2181
+ }, m = (y) => {
2182
+ l("focus", y);
2183
+ };
2184
+ return (y, S) => (a(), s("div", {
2185
+ class: h(r.value)
2186
+ }, [
2187
+ v("input", {
2188
+ id: e.id,
2189
+ type: "radio",
2190
+ class: h(n.value),
2191
+ checked: o.value,
2192
+ value: e.value,
2193
+ name: e.name,
2194
+ disabled: e.disabled,
2195
+ required: e.required,
2196
+ "aria-invalid": i.value === "invalid",
2197
+ "aria-describedby": e.validationMessage || e.helpText ? `${e.id}-feedback` : void 0,
2198
+ onChange: g,
2199
+ onBlur: b,
2200
+ onFocus: m
2201
+ }, null, 42, Pa),
2202
+ e.label ? (a(), s("label", {
2203
+ key: 0,
2204
+ for: e.id,
2205
+ class: "form-check-label"
2206
+ }, [
2207
+ T(f(e.label) + " ", 1),
2208
+ e.required ? (a(), s("span", Ia, "*")) : u("", !0)
2209
+ ], 8, Fa)) : u("", !0),
2210
+ e.helpText && !e.validationMessage ? (a(), s("div", {
2211
+ key: 1,
2212
+ id: `${e.id}-feedback`,
2213
+ class: "form-text"
2214
+ }, f(e.helpText), 9, Na)) : u("", !0),
2215
+ i.value === "valid" ? (a(), s("div", za, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
2216
+ i.value === "invalid" ? (a(), s("div", {
2217
+ key: 3,
2218
+ id: `${e.id}-feedback`,
2219
+ class: "invalid-feedback",
2220
+ style: { display: "block" }
2221
+ }, f(e.validationMessage || "Please select an option."), 9, Aa)) : u("", !0)
2222
+ ], 2));
2223
+ }
2224
+ }), Oa = { class: "form-check form-switch" }, ja = ["id", "checked", "disabled", "required", "aria-invalid", "aria-describedby"], La = ["for"], Da = {
2225
+ key: 0,
2226
+ class: "text-danger"
2227
+ }, Ra = ["id"], Ga = {
2228
+ key: 2,
2229
+ class: "valid-feedback",
2230
+ style: { display: "block" }
2231
+ }, Ea = ["id"], Ul = /* @__PURE__ */ p({
2232
+ __name: "VibeFormSwitch",
2233
+ props: {
2234
+ modelValue: { type: Boolean, default: !1 },
2235
+ id: { type: String, required: !0 },
2236
+ label: { type: String, default: void 0 },
2237
+ disabled: { type: Boolean, default: !1 },
2238
+ required: { type: Boolean, default: !1 },
2239
+ validationState: { type: String, default: null },
2240
+ validationMessage: { type: String, default: void 0 },
2241
+ validationRules: { type: [Array, Function], default: void 0 },
2242
+ validateOn: { type: String, default: "blur" },
2243
+ helpText: { type: String, default: void 0 }
2244
+ },
2245
+ emits: ["update:modelValue", "validate", "blur", "focus", "change"],
2246
+ setup(e, { emit: d }) {
2247
+ const t = e, l = d, i = c(() => t.validationState), n = c(() => {
2248
+ const b = ["form-check-input"];
2249
+ return i.value === "valid" && b.push("is-valid"), i.value === "invalid" && b.push("is-invalid"), b.join(" ");
2250
+ }), r = (b) => {
2251
+ const m = b.target;
2252
+ l("update:modelValue", m.checked), l("change", b), t.validateOn === "change" && l("validate");
2253
+ }, o = (b) => {
2254
+ l("blur", b), t.validateOn === "blur" && l("validate");
2255
+ }, g = (b) => {
2256
+ l("focus", b);
2257
+ };
2258
+ return (b, m) => (a(), s("div", Oa, [
2259
+ v("input", {
2260
+ id: e.id,
2261
+ type: "checkbox",
2262
+ class: h(n.value),
2263
+ checked: e.modelValue,
2264
+ disabled: e.disabled,
2265
+ required: e.required,
2266
+ "aria-invalid": i.value === "invalid",
2267
+ "aria-describedby": e.validationMessage || e.helpText ? `${e.id}-feedback` : void 0,
2268
+ role: "switch",
2269
+ onChange: r,
2270
+ onBlur: o,
2271
+ onFocus: g
2272
+ }, null, 42, ja),
2273
+ e.label ? (a(), s("label", {
2274
+ key: 0,
2275
+ for: e.id,
2276
+ class: "form-check-label"
2277
+ }, [
2278
+ T(f(e.label) + " ", 1),
2279
+ e.required ? (a(), s("span", Da, "*")) : u("", !0)
2280
+ ], 8, La)) : u("", !0),
2281
+ e.helpText && !e.validationMessage ? (a(), s("div", {
2282
+ key: 1,
2283
+ id: `${e.id}-feedback`,
2284
+ class: "form-text"
2285
+ }, f(e.helpText), 9, Ra)) : u("", !0),
2286
+ i.value === "valid" ? (a(), s("div", Ga, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
2287
+ i.value === "invalid" ? (a(), s("div", {
2288
+ key: 3,
2289
+ id: `${e.id}-feedback`,
2290
+ class: "invalid-feedback",
2291
+ style: { display: "block" }
2292
+ }, f(e.validationMessage || "You must toggle this switch."), 9, Ea)) : u("", !0)
2293
+ ]));
2294
+ }
2295
+ }), Ha = ["for"], Qa = {
2296
+ key: 0,
2297
+ class: "text-danger"
2298
+ }, Ua = ["id"], Wa = {
2299
+ key: 1,
2300
+ class: "valid-feedback",
2301
+ style: { display: "block" }
2302
+ }, Ya = ["id"], Ka = ["for"], Ja = {
2303
+ key: 0,
2304
+ class: "text-danger"
2305
+ }, Xa = ["id"], Za = {
2306
+ key: 2,
2307
+ class: "valid-feedback",
2308
+ style: { display: "block" }
2309
+ }, _a = ["id"], Wl = /* @__PURE__ */ p({
2310
+ __name: "VibeFormGroup",
2311
+ props: {
2312
+ label: { type: String, default: void 0 },
2313
+ labelFor: { type: String, default: void 0 },
2314
+ required: { type: Boolean, default: !1 },
2315
+ validationState: { type: String, default: null },
2316
+ validationMessage: { type: String, default: void 0 },
2317
+ helpText: { type: String, default: void 0 },
2318
+ floating: { type: Boolean, default: !1 },
2319
+ row: { type: Boolean, default: !1 },
2320
+ labelCols: { type: [Number, String], default: void 0 },
2321
+ labelAlign: { type: String, default: void 0 }
2322
+ },
2323
+ setup(e) {
2324
+ const d = e, t = c(() => {
2325
+ const r = [];
2326
+ return d.floating ? r.push("form-floating") : d.row ? r.push("row", "mb-3") : r.push("mb-3"), r.join(" ");
2327
+ }), l = c(() => {
2328
+ const r = [];
2329
+ return d.floating ? r.push("form-label") : d.row ? (r.push("col-form-label"), d.labelCols && r.push(`col-sm-${d.labelCols}`), d.labelAlign && r.push(`text-${d.labelAlign}`)) : r.push("form-label"), r.join(" ");
2330
+ }), i = c(() => d.row && d.labelCols ? `col-sm-${12 - Number(d.labelCols)}` : ""), n = c(() => d.labelFor ? `${d.labelFor}-feedback` : void 0);
2331
+ return (r, o) => (a(), s("div", {
2332
+ class: h(t.value)
2333
+ }, [
2334
+ e.label && !e.floating ? (a(), s("label", {
2335
+ key: 0,
2336
+ for: e.labelFor,
2337
+ class: h(l.value)
2338
+ }, [
2339
+ T(f(e.label) + " ", 1),
2340
+ e.required ? (a(), s("span", Qa, "*")) : u("", !0)
2341
+ ], 10, Ha)) : u("", !0),
2342
+ e.row && e.labelCols ? (a(), s("div", {
2343
+ key: 1,
2344
+ class: h(i.value)
2345
+ }, [
2346
+ $(r.$slots, "default"),
2347
+ e.helpText && !e.validationMessage ? (a(), s("div", {
2348
+ key: 0,
2349
+ id: n.value,
2350
+ class: "form-text"
2351
+ }, f(e.helpText), 9, Ua)) : u("", !0),
2352
+ e.validationState === "valid" ? (a(), s("div", Wa, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
2353
+ e.validationState === "invalid" ? (a(), s("div", {
2354
+ key: 2,
2355
+ id: n.value,
2356
+ class: "invalid-feedback",
2357
+ style: { display: "block" }
2358
+ }, f(e.validationMessage || "Please provide a valid value."), 9, Ya)) : u("", !0)
2359
+ ], 2)) : (a(), s(F, { key: 2 }, [
2360
+ $(r.$slots, "default"),
2361
+ e.label && e.floating ? (a(), s("label", {
2362
+ key: 0,
2363
+ for: e.labelFor,
2364
+ class: h(l.value)
2365
+ }, [
2366
+ T(f(e.label) + " ", 1),
2367
+ e.required ? (a(), s("span", Ja, "*")) : u("", !0)
2368
+ ], 10, Ka)) : u("", !0),
2369
+ e.helpText && !e.validationMessage ? (a(), s("div", {
2370
+ key: 1,
2371
+ id: n.value,
2372
+ class: "form-text"
2373
+ }, f(e.helpText), 9, Xa)) : u("", !0),
2374
+ e.validationState === "valid" ? (a(), s("div", Za, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
2375
+ e.validationState === "invalid" ? (a(), s("div", {
2376
+ key: 3,
2377
+ id: n.value,
2378
+ class: "invalid-feedback",
2379
+ style: { display: "block" }
2380
+ }, f(e.validationMessage || "Please provide a valid value."), 9, _a)) : u("", !0)
2381
+ ], 64))
2382
+ ], 2));
2383
+ }
2384
+ }), el = { class: "mb-3" }, tl = ["for"], al = {
2385
+ key: 0,
2386
+ class: "text-danger"
2387
+ }, ll = {
2388
+ key: 1,
2389
+ class: "alert alert-warning",
2390
+ role: "alert"
2391
+ }, il = ["id"], nl = ["id"], sl = {
2392
+ key: 4,
2393
+ class: "valid-feedback",
2394
+ style: { display: "block" }
2395
+ }, dl = ["id"], ol = /* @__PURE__ */ p({
2396
+ __name: "VibeFormWysiwyg",
2397
+ props: {
2398
+ modelValue: { type: String, default: "" },
2399
+ id: { type: String, required: !0 },
2400
+ label: { type: String, default: void 0 },
2401
+ placeholder: { type: String, default: "Write something..." },
2402
+ disabled: { type: Boolean, default: !1 },
2403
+ readonly: { type: Boolean, default: !1 },
2404
+ required: { type: Boolean, default: !1 },
2405
+ theme: { type: String, default: "snow" },
2406
+ toolbar: { type: [Array, String, Boolean], default: void 0 },
2407
+ validationState: { type: String, default: null },
2408
+ validationMessage: { type: String, default: void 0 },
2409
+ validationRules: { type: [Array, Function], default: void 0 },
2410
+ validateOn: { type: String, default: "blur" },
2411
+ helpText: { type: String, default: void 0 },
2412
+ height: { type: String, default: "200px" }
2413
+ },
2414
+ emits: ["update:modelValue", "validate", "blur", "focus", "change", "ready"],
2415
+ setup(e, { emit: d }) {
2416
+ const t = e, l = d, i = I(null), n = I(null), r = I(!1), o = I(null), g = c(() => t.validationState), b = c(() => {
2417
+ const S = ["vibe-wysiwyg-container"];
2418
+ return g.value === "valid" && S.push("is-valid"), g.value === "invalid" && S.push("is-invalid"), t.disabled && S.push("disabled"), S.join(" ");
2419
+ }), m = [
2420
+ [{ header: [1, 2, 3, !1] }],
2421
+ ["bold", "italic", "underline", "strike"],
2422
+ [{ list: "ordered" }, { list: "bullet" }],
2423
+ [{ color: [] }, { background: [] }],
2424
+ ["link", "image"],
2425
+ ["clean"]
2426
+ ], y = () => t.toolbar === !1 ? !1 : t.toolbar === !0 || t.toolbar === void 0 ? m : t.toolbar;
2427
+ return oe(async () => {
2428
+ try {
2429
+ const S = await import("quill"), q = S.default || S;
2430
+ if (await import("quill/dist/quill.snow.css"), i.value) {
2431
+ const A = {
2432
+ theme: t.theme,
2433
+ placeholder: t.placeholder,
2434
+ readOnly: t.readonly || t.disabled,
2435
+ modules: {
2436
+ toolbar: y()
2437
+ }
2438
+ };
2439
+ n.value = new q(i.value, A), t.modelValue && (n.value.root.innerHTML = t.modelValue), n.value.on("text-change", () => {
2440
+ const B = n.value.root.innerHTML, M = n.value.getText().trim().length === 0;
2441
+ l("update:modelValue", M ? "" : B), l("change"), t.validateOn === "change" && l("validate");
2442
+ }), n.value.root.addEventListener("blur", () => {
2443
+ l("blur"), t.validateOn === "blur" && l("validate");
2444
+ }), n.value.root.addEventListener("focus", () => {
2445
+ l("focus");
2446
+ }), r.value = !0, l("ready", n.value);
2447
+ }
2448
+ } catch (S) {
2449
+ console.error("Failed to load Quill editor:", S), o.value = "Failed to load WYSIWYG editor. Please install quill: npm install quill", r.value = !1;
2450
+ }
2451
+ }), re(() => {
2452
+ n.value && (n.value = null);
2453
+ }), L(() => t.modelValue, (S) => {
2454
+ n.value && n.value.root.innerHTML !== S && (n.value.root.innerHTML = S || "");
2455
+ }), L(() => t.disabled, (S) => {
2456
+ n.value && n.value.enable(!S);
2457
+ }), L(() => t.readonly, (S) => {
2458
+ n.value && n.value.enable(!S);
2459
+ }), (S, q) => (a(), s("div", el, [
2460
+ e.label ? (a(), s("label", {
2461
+ key: 0,
2462
+ for: e.id,
2463
+ class: "form-label"
2464
+ }, [
2465
+ T(f(e.label) + " ", 1),
2466
+ e.required ? (a(), s("span", al, "*")) : u("", !0)
2467
+ ], 8, tl)) : u("", !0),
2468
+ o.value ? (a(), s("div", ll, f(o.value), 1)) : (a(), s("div", {
2469
+ key: 2,
2470
+ class: h(b.value),
2471
+ style: E({ minHeight: e.height })
2472
+ }, [
2473
+ v("div", {
2474
+ ref_key: "editorContainer",
2475
+ ref: i,
2476
+ id: e.id
2477
+ }, null, 8, il)
2478
+ ], 6)),
2479
+ e.helpText && !e.validationMessage ? (a(), s("div", {
2480
+ key: 3,
2481
+ id: `${e.id}-feedback`,
2482
+ class: "form-text"
2483
+ }, f(e.helpText), 9, nl)) : u("", !0),
2484
+ g.value === "valid" ? (a(), s("div", sl, f(e.validationMessage || "Looks good!"), 1)) : u("", !0),
2485
+ g.value === "invalid" ? (a(), s("div", {
2486
+ key: 5,
2487
+ id: `${e.id}-feedback`,
2488
+ class: "invalid-feedback",
2489
+ style: { display: "block" }
2490
+ }, f(e.validationMessage || "Please provide valid content."), 9, dl)) : u("", !0)
2491
+ ]));
2492
+ }
2493
+ }), Yl = /* @__PURE__ */ W(ol, [["__scopeId", "data-v-2eb8f4ff"]]);
2494
+ function Kl(e = "") {
2495
+ const d = I(e), t = I(null), l = I(""), i = I(!1), n = I(!1), r = I(!1), o = async (q) => {
2496
+ if (!q)
2497
+ return t.value = null, l.value = "", { valid: !0 };
2498
+ r.value = !0;
2499
+ try {
2500
+ const A = Array.isArray(q) ? q : [{ validator: q }];
2501
+ for (const B of A) {
2502
+ const M = await B.validator(d.value);
2503
+ if (M === !1 || typeof M == "string")
2504
+ return t.value = "invalid", l.value = typeof M == "string" ? M : B.message || "Invalid value", r.value = !1, { valid: !1, message: l.value };
2505
+ }
2506
+ return t.value = "valid", l.value = "", r.value = !1, { valid: !0 };
2507
+ } catch {
2508
+ return t.value = "invalid", l.value = "Validation error occurred", r.value = !1, { valid: !1, message: l.value };
2509
+ }
2510
+ }, g = () => {
2511
+ d.value = e, t.value = null, l.value = "", i.value = !1, n.value = !1, r.value = !1;
2512
+ }, b = () => {
2513
+ n.value = !0;
2514
+ }, m = () => {
2515
+ i.value = !0;
2516
+ }, y = c(() => t.value === "valid"), S = c(() => t.value === "invalid");
2517
+ return {
2518
+ value: d,
2519
+ validationState: t,
2520
+ validationMessage: l,
2521
+ isDirty: i,
2522
+ isTouched: n,
2523
+ isValidating: r,
2524
+ isValid: y,
2525
+ isInvalid: S,
2526
+ validate: o,
2527
+ reset: g,
2528
+ markAsTouched: b,
2529
+ markAsDirty: m
2530
+ };
2531
+ }
2532
+ const Jl = {
2533
+ required: (e = "This field is required") => ({
2534
+ validator: (d) => Array.isArray(d) ? d.length > 0 || e : typeof d == "string" ? d.trim().length > 0 || e : d != null && d !== "" || e,
2535
+ message: e
2536
+ }),
2537
+ email: (e = "Please enter a valid email address") => ({
2538
+ validator: (d) => d ? /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(d) || e : !0,
2539
+ message: e
2540
+ }),
2541
+ minLength: (e, d) => ({
2542
+ validator: (t) => t ? t.length >= e || d || `Minimum length is ${e} characters` : !0,
2543
+ message: d
2544
+ }),
2545
+ maxLength: (e, d) => ({
2546
+ validator: (t) => t ? t.length <= e || d || `Maximum length is ${e} characters` : !0,
2547
+ message: d
2548
+ }),
2549
+ min: (e, d) => ({
2550
+ validator: (t) => t == null || t === "" ? !0 : Number(t) >= e || d || `Minimum value is ${e}`,
2551
+ message: d
2552
+ }),
2553
+ max: (e, d) => ({
2554
+ validator: (t) => t == null || t === "" ? !0 : Number(t) <= e || d || `Maximum value is ${e}`,
2555
+ message: d
2556
+ }),
2557
+ pattern: (e, d = "Invalid format") => ({
2558
+ validator: (t) => t ? e.test(t) || d : !0,
2559
+ message: d
2560
+ }),
2561
+ url: (e = "Please enter a valid URL") => ({
2562
+ validator: (d) => {
2563
+ if (!d) return !0;
2564
+ try {
2565
+ return new URL(d), !0;
2566
+ } catch {
2567
+ return e;
2568
+ }
2569
+ },
2570
+ message: e
2571
+ }),
2572
+ // Async validator example for API validation
2573
+ async: (e) => ({
2574
+ validator: e
2575
+ })
2576
+ };
43
2577
  export {
44
- g as VibeAlert
2578
+ Tl as VibeAccordion,
2579
+ Ie as VibeAccordionItem,
2580
+ ul as VibeAlert,
2581
+ cl as VibeBadge,
2582
+ gl as VibeBreadcrumb,
2583
+ ke as VibeBreadcrumbItem,
2584
+ fl as VibeButton,
2585
+ vl as VibeButtonGroup,
2586
+ hl as VibeCard,
2587
+ be as VibeCardBody,
2588
+ me as VibeCardFooter,
2589
+ ve as VibeCardHeader,
2590
+ K as VibeCardImg,
2591
+ ge as VibeCardText,
2592
+ he as VibeCardTitle,
2593
+ Nl as VibeCarousel,
2594
+ it as VibeCarouselSlide,
2595
+ bl as VibeCloseButton,
2596
+ ql as VibeCollapse,
2597
+ jl as VibeDataTable,
2598
+ Ml as VibeDropdown,
2599
+ Ae as VibeDropdownItem,
2600
+ Hl as VibeFormCheckbox,
2601
+ El as VibeFormDatepicker,
2602
+ Wl as VibeFormGroup,
2603
+ Ll as VibeFormInput,
2604
+ Ql as VibeFormRadio,
2605
+ Dl as VibeFormSelect,
2606
+ Gl as VibeFormSpinbutton,
2607
+ Ul as VibeFormSwitch,
2608
+ Rl as VibeFormTextarea,
2609
+ Yl as VibeFormWysiwyg,
2610
+ Bl as VibeListGroup,
2611
+ Ce as VibeListGroupItem,
2612
+ Pl as VibeModal,
2613
+ pl as VibeNav,
2614
+ J as VibeNavItem,
2615
+ kl as VibeNavbar,
2616
+ $l as VibeNavbarBrand,
2617
+ Vl as VibeNavbarNav,
2618
+ Sl as VibeNavbarToggle,
2619
+ Fl as VibeOffcanvas,
2620
+ xl as VibePagination,
2621
+ U as VibePaginationItem,
2622
+ yl as VibePlaceholder,
2623
+ Al as VibePopover,
2624
+ Cl as VibeProgress,
2625
+ wl as VibeProgressBar,
2626
+ Ol as VibeScrollspy,
2627
+ ml as VibeSpinner,
2628
+ Il as VibeToast,
2629
+ zl as VibeTooltip,
2630
+ Kl as useFormValidation,
2631
+ Jl as validators
45
2632
  };