@aggc/ui 0.4.0 → 0.4.1

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.
Files changed (71) hide show
  1. package/dist/chunks/UiSkeleton.vue_vue_type_script_setup_true_lang-Lghyrtms.js +1201 -0
  2. package/dist/chunks/pageHeader-CcJrPX_8.js +522 -0
  3. package/dist/components/PageSurface.styles.d.ts +1 -0
  4. package/dist/components/PageSurface.vue.d.ts +13 -0
  5. package/dist/components/ResultPanel.styles.d.ts +64 -0
  6. package/dist/components/ResultPanel.vue.d.ts +16 -0
  7. package/dist/components/SectionCard.styles.d.ts +13 -0
  8. package/dist/components/SectionCard.vue.d.ts +27 -0
  9. package/dist/components/StatusBadge.styles.d.ts +24 -0
  10. package/dist/components/StatusBadge.vue.d.ts +18 -0
  11. package/dist/components/UiButton.styles.d.ts +54 -0
  12. package/dist/components/UiButton.vue.d.ts +28 -0
  13. package/dist/components/UiCheckbox.styles.d.ts +42 -0
  14. package/dist/components/UiCheckbox.vue.d.ts +37 -0
  15. package/dist/components/UiField.styles.d.ts +7 -0
  16. package/dist/components/UiField.vue.d.ts +22 -0
  17. package/dist/components/UiLoadingState.styles.d.ts +4 -0
  18. package/dist/components/UiLoadingState.vue.d.ts +10 -0
  19. package/dist/components/UiSegmentedControl.styles.d.ts +23 -0
  20. package/dist/components/UiSegmentedControl.vue.d.ts +14 -0
  21. package/dist/components/UiSelect.styles.d.ts +104 -0
  22. package/dist/components/UiSelect.vue.d.ts +35 -0
  23. package/dist/components/UiSkeleton.styles.d.ts +67 -0
  24. package/dist/components/UiSkeleton.vue.d.ts +12 -0
  25. package/dist/components/index.d.ts +11 -0
  26. package/dist/components.d.ts +1 -0
  27. package/dist/components.js +14 -0
  28. package/dist/css.d.ts +2 -0
  29. package/dist/css.js +1 -0
  30. package/dist/fonts.css +6 -0
  31. package/dist/index.d.ts +3 -0
  32. package/dist/index.js +65 -0
  33. package/dist/styles/index.d.ts +20 -0
  34. package/dist/styles/layouts/cluster.d.ts +27 -0
  35. package/dist/styles/layouts/page.d.ts +2 -0
  36. package/dist/styles/layouts/split.d.ts +22 -0
  37. package/dist/styles/layouts/stack.d.ts +19 -0
  38. package/dist/styles/patterns/actionToolbar.d.ts +1 -0
  39. package/dist/styles/patterns/emptyState.d.ts +2 -0
  40. package/dist/styles/patterns/infoPanel.d.ts +2 -0
  41. package/dist/styles/patterns/metricGrid.d.ts +22 -0
  42. package/dist/styles/patterns/pageHeader.d.ts +3 -0
  43. package/dist/styles/patterns/resultRegion.d.ts +1 -0
  44. package/dist/styles/patterns/selectableListDetail.d.ts +3 -0
  45. package/dist/styles/primitives/feedback.d.ts +4 -0
  46. package/dist/styles/primitives/fields.d.ts +3 -0
  47. package/dist/styles/primitives/surfaces.d.ts +3 -0
  48. package/dist/styles/primitives/typography.d.ts +6 -0
  49. package/dist/styles/recipes/badge.recipe.d.ts +32 -0
  50. package/dist/styles/recipes/button.recipe.d.ts +51 -0
  51. package/dist/styles/recipes/card.recipe.d.ts +59 -0
  52. package/dist/styles/recipes/dropdown.recipe.d.ts +25 -0
  53. package/dist/styles/recipes/input.recipe.d.ts +32 -0
  54. package/dist/styles.d.ts +1 -0
  55. package/dist/styles.js +429 -0
  56. package/dist/tokens/colors.d.ts +360 -0
  57. package/dist/tokens/core-colors.d.ts +238 -0
  58. package/dist/tokens/desktop-colors.d.ts +132 -0
  59. package/dist/tokens/index.d.ts +7 -0
  60. package/dist/tokens/motion.d.ts +10 -0
  61. package/dist/tokens/radius.d.ts +5 -0
  62. package/dist/tokens/spacing.d.ts +8 -0
  63. package/dist/tokens/typography.d.ts +10 -0
  64. package/dist/tokens-core.d.ts +5 -0
  65. package/dist/tokens-core.js +69 -0
  66. package/dist/tokens-desktop.d.ts +1 -0
  67. package/dist/tokens-desktop.js +30 -0
  68. package/dist/tokens.d.ts +1 -0
  69. package/dist/tokens.js +16 -0
  70. package/dist/ui.css +2026 -0
  71. package/package.json +1 -1
@@ -0,0 +1,1201 @@
1
+ import { defineComponent as p, openBlock as l, createElementBlock as o, normalizeClass as t, unref as a, renderSlot as y, createElementVNode as d, createBlock as ee, resolveDynamicComponent as ae, toDisplayString as c, createVNode as L, withCtx as te, createTextVNode as E, Fragment as z, renderList as V, createCommentVNode as b, withKeys as U, withModifiers as K, ref as $, useId as se, computed as R, watch as N, onMounted as le, onBeforeUnmount as oe, nextTick as T, normalizeStyle as ne } from "vue";
2
+ import { j as ie, o as g, q as D, n as G, r as i, g as re, f as de, a as X, l as ce, p as ue, b as be, h as ge, i as fe, d as pe } from "./pageHeader-CcJrPX_8.js";
3
+ import { CheckCircle2 as me, TriangleAlert as he, LoaderCircle as ve, Check as q, ChevronDown as ye } from "lucide-vue-next";
4
+ const Ce = ie, Ea = /* @__PURE__ */ p({
5
+ __name: "PageSurface",
6
+ setup(e) {
7
+ return (s, n) => (l(), o("div", {
8
+ class: t(a(Ce))
9
+ }, [
10
+ y(s.$slots, "default")
11
+ ], 2));
12
+ }
13
+ }), xe = g({
14
+ base: {
15
+ display: "inline-flex",
16
+ alignItems: "center",
17
+ justifyContent: "center",
18
+ borderRadius: "full",
19
+ borderWidth: "1px",
20
+ px: "3",
21
+ py: "1.5",
22
+ fontSize: "xs",
23
+ fontWeight: "700",
24
+ textTransform: "uppercase",
25
+ letterSpacing: "0.1em",
26
+ backdropFilter: "blur(16px) saturate(140%)",
27
+ boxShadow: "inset 0 1px 0 rgba(255,255,255,0.16)",
28
+ _dark: {
29
+ boxShadow: "inset 0 1px 0 rgba(255,255,255,0.04)"
30
+ }
31
+ },
32
+ variants: {
33
+ tone: {
34
+ success: {
35
+ bg: "badge.successBg",
36
+ color: "badge.successText",
37
+ borderColor: "badge.successBorder"
38
+ },
39
+ warning: {
40
+ bg: "badge.warningBg",
41
+ color: "badge.warningText",
42
+ borderColor: "badge.warningBorder"
43
+ },
44
+ info: {
45
+ bg: "badge.infoBg",
46
+ color: "badge.infoText",
47
+ borderColor: "badge.infoBorder"
48
+ },
49
+ neutral: {
50
+ bg: "badge.neutralBg",
51
+ color: "badge.neutralText",
52
+ borderColor: "badge.neutralBorder"
53
+ }
54
+ }
55
+ },
56
+ defaultVariants: {
57
+ tone: "neutral"
58
+ }
59
+ }), we = /* @__PURE__ */ p({
60
+ __name: "StatusBadge",
61
+ props: {
62
+ tone: { default: "neutral" }
63
+ },
64
+ setup(e) {
65
+ const s = e;
66
+ return (n, f) => (l(), o("span", {
67
+ class: t(a(xe)({ tone: s.tone }))
68
+ }, [
69
+ y(n.$slots, "default")
70
+ ], 2));
71
+ }
72
+ }), ke = g({
73
+ base: {
74
+ borderWidth: "1px",
75
+ padding: "5"
76
+ },
77
+ variants: {
78
+ ok: {
79
+ true: {
80
+ borderColor: "result.okBorder",
81
+ bg: "result.okBg"
82
+ },
83
+ false: {
84
+ borderColor: "result.failBorder",
85
+ bg: "result.failBg"
86
+ }
87
+ }
88
+ }
89
+ }), Se = (e) => D(G, ke({ ok: e })), Be = i({
90
+ display: "flex",
91
+ justifyContent: "space-between",
92
+ gap: "4",
93
+ alignItems: { base: "flex-start", md: "center" },
94
+ flexDirection: { base: "column", md: "row" },
95
+ mb: "3"
96
+ }), $e = i({
97
+ display: "flex",
98
+ alignItems: "center",
99
+ gap: "3"
100
+ }), ze = g({
101
+ base: {
102
+ width: "10",
103
+ height: "10",
104
+ borderRadius: "full",
105
+ display: "flex",
106
+ alignItems: "center",
107
+ justifyContent: "center"
108
+ },
109
+ variants: {
110
+ ok: {
111
+ true: {
112
+ bg: "bg.accentSoft",
113
+ color: "text.accent"
114
+ },
115
+ false: {
116
+ bg: "badge.warningBg",
117
+ color: "badge.warningText"
118
+ }
119
+ }
120
+ }
121
+ }), Ve = i({
122
+ fontSize: "lg",
123
+ fontWeight: "700",
124
+ color: "text.primary"
125
+ }), Y = g({
126
+ base: {},
127
+ variants: {
128
+ spaced: {
129
+ true: { mb: "3" },
130
+ false: { mb: "0" }
131
+ }
132
+ }
133
+ }), H = g({
134
+ base: {
135
+ fontSize: "sm",
136
+ fontWeight: "700",
137
+ mb: "2"
138
+ },
139
+ variants: {
140
+ tone: {
141
+ detail: { color: "result.detailText" },
142
+ warning: { color: "result.warningLabel" },
143
+ error: { color: "result.errorLabel" }
144
+ }
145
+ }
146
+ }), P = g({
147
+ base: {
148
+ display: "grid",
149
+ gap: "1.5",
150
+ pl: "4"
151
+ },
152
+ variants: {
153
+ tone: {
154
+ detail: { color: "result.bodyText" },
155
+ warning: { color: "result.warningBody" },
156
+ error: { color: "result.errorBody" }
157
+ }
158
+ }
159
+ }), Re = ["aria-live", "role"], Le = { key: 2 }, Fa = /* @__PURE__ */ p({
160
+ __name: "ResultPanel",
161
+ props: {
162
+ ok: { type: Boolean },
163
+ summary: {},
164
+ warnings: {},
165
+ errors: {},
166
+ messages: {},
167
+ live: {},
168
+ passLabel: {},
169
+ failLabel: {},
170
+ detailsLabel: {},
171
+ warningsLabel: {},
172
+ errorsLabel: {}
173
+ },
174
+ setup(e) {
175
+ const s = e;
176
+ return (n, f) => (l(), o("div", {
177
+ class: t(a(Se)(e.ok)),
178
+ "aria-live": s.live ?? "polite",
179
+ role: (s.live ?? "polite") === "off" ? void 0 : "status"
180
+ }, [
181
+ d("div", {
182
+ class: t(a(Be))
183
+ }, [
184
+ d("div", {
185
+ class: t(a($e))
186
+ }, [
187
+ d("div", {
188
+ class: t(a(ze)({ ok: e.ok }))
189
+ }, [
190
+ (l(), ee(ae(e.ok ? a(me) : a(he)), { size: 18 }))
191
+ ], 2),
192
+ d("h3", {
193
+ class: t(a(Ve))
194
+ }, c(s.summary), 3)
195
+ ], 2),
196
+ L(we, {
197
+ tone: e.ok ? "success" : "warning"
198
+ }, {
199
+ default: te(() => [
200
+ E(c(e.ok ? s.passLabel ?? "Pass" : s.failLabel ?? "Fail"), 1)
201
+ ]),
202
+ _: 1
203
+ }, 8, ["tone"])
204
+ ], 2),
205
+ e.messages?.length ? (l(), o("div", {
206
+ key: 0,
207
+ class: t(a(Y)({ spaced: !0 }))
208
+ }, [
209
+ d("p", {
210
+ class: t(a(H)({ tone: "detail" }))
211
+ }, c(s.detailsLabel ?? "Details"), 3),
212
+ d("ul", {
213
+ class: t(a(P)({ tone: "detail" }))
214
+ }, [
215
+ (l(!0), o(z, null, V(e.messages, (u) => (l(), o("li", { key: u }, c(u), 1))), 128))
216
+ ], 2)
217
+ ], 2)) : b("", !0),
218
+ e.warnings?.length ? (l(), o("div", {
219
+ key: 1,
220
+ class: t(a(Y)({ spaced: !!e.errors?.length }))
221
+ }, [
222
+ d("p", {
223
+ class: t(a(H)({ tone: "warning" }))
224
+ }, c(s.warningsLabel ?? "Warnings"), 3),
225
+ d("ul", {
226
+ class: t(a(P)({ tone: "warning" }))
227
+ }, [
228
+ (l(!0), o(z, null, V(e.warnings, (u) => (l(), o("li", { key: u }, c(u), 1))), 128))
229
+ ], 2)
230
+ ], 2)) : b("", !0),
231
+ e.errors?.length ? (l(), o("div", Le, [
232
+ d("p", {
233
+ class: t(a(H)({ tone: "error" }))
234
+ }, c(s.errorsLabel ?? "Errors"), 3),
235
+ d("ul", {
236
+ class: t(a(P)({ tone: "error" }))
237
+ }, [
238
+ (l(!0), o(z, null, V(e.errors, (u) => (l(), o("li", { key: u }, c(u), 1))), 128))
239
+ ], 2)
240
+ ])) : b("", !0)
241
+ ], 10, Re));
242
+ }
243
+ }), Ie = i({
244
+ padding: "6"
245
+ }), We = i({
246
+ height: "100%",
247
+ minHeight: "0",
248
+ display: "grid",
249
+ gridTemplateRows: "auto minmax(0, 1fr)"
250
+ }), De = G, Te = re, He = i({
251
+ position: "relative",
252
+ zIndex: "1",
253
+ mb: "5"
254
+ }), Pe = i({
255
+ position: "relative",
256
+ zIndex: "1",
257
+ mb: "0"
258
+ }), Ee = de, Fe = X, je = ce, Oe = i({
259
+ color: "text.secondary",
260
+ lineHeight: "1.65",
261
+ fontSize: "sm",
262
+ maxWidth: "2xl"
263
+ }), Ae = ue, Me = i({
264
+ position: "relative",
265
+ zIndex: "1",
266
+ minHeight: "0",
267
+ overflowY: "auto",
268
+ paddingRight: "1",
269
+ overscrollBehavior: "contain"
270
+ }), Ue = i({
271
+ position: "relative",
272
+ zIndex: "1"
273
+ }), ja = /* @__PURE__ */ p({
274
+ __name: "SectionCard",
275
+ props: {
276
+ title: {},
277
+ eyebrow: { default: "Workspace surface" },
278
+ description: { default: "" },
279
+ scrollBody: { type: Boolean, default: !1 },
280
+ collapseBodyGap: { type: Boolean, default: !1 }
281
+ },
282
+ setup(e) {
283
+ const s = e;
284
+ return (n, f) => (l(), o("section", {
285
+ class: t(a(D)(a(De), a(Ie), s.scrollBody && a(We)))
286
+ }, [
287
+ d("div", {
288
+ class: t(a(D)(a(Te), s.collapseBodyGap ? a(Pe) : a(He)))
289
+ }, [
290
+ d("div", {
291
+ class: t(a(Ee))
292
+ }, [
293
+ s.eyebrow ? (l(), o("p", {
294
+ key: 0,
295
+ class: t(a(Fe))
296
+ }, c(s.eyebrow), 3)) : b("", !0),
297
+ d("h2", {
298
+ class: t(a(je))
299
+ }, c(s.title), 3),
300
+ s.description ? (l(), o("p", {
301
+ key: 1,
302
+ class: t(a(Oe))
303
+ }, c(s.description), 3)) : b("", !0)
304
+ ], 2),
305
+ n.$slots.actions ? (l(), o("div", {
306
+ key: 0,
307
+ class: t(a(Ae))
308
+ }, [
309
+ y(n.$slots, "actions")
310
+ ], 2)) : b("", !0)
311
+ ], 2),
312
+ d("div", {
313
+ class: t(s.scrollBody ? a(Me) : a(Ue))
314
+ }, [
315
+ y(n.$slots, "default")
316
+ ], 2)
317
+ ], 2));
318
+ }
319
+ }), Ke = be, Ne = i({
320
+ display: "inline-flex",
321
+ alignItems: "center",
322
+ justifyContent: "center",
323
+ gap: "2",
324
+ minWidth: "0"
325
+ }), Ye = i({
326
+ visibility: "hidden"
327
+ }), Ge = i({
328
+ position: "absolute",
329
+ inset: "0",
330
+ display: "inline-flex",
331
+ alignItems: "center",
332
+ justifyContent: "center",
333
+ gap: "2",
334
+ px: "4",
335
+ py: "3",
336
+ pointerEvents: "none"
337
+ }), Xe = ["type", "disabled", "aria-busy", "aria-label"], Oa = /* @__PURE__ */ p({
338
+ __name: "UiButton",
339
+ props: {
340
+ variant: { default: "solid" },
341
+ loading: { type: Boolean, default: !1 },
342
+ loadingLabel: { default: "Working..." },
343
+ disabled: { type: Boolean, default: !1 },
344
+ type: { default: "button" },
345
+ ariaLabel: { default: void 0 }
346
+ },
347
+ setup(e) {
348
+ return (s, n) => (l(), o("button", {
349
+ type: e.type,
350
+ disabled: e.disabled || e.loading,
351
+ "aria-busy": e.loading || void 0,
352
+ "aria-label": e.ariaLabel,
353
+ class: t(a(Ke)({ variant: e.variant, disabled: e.disabled, loading: e.loading }))
354
+ }, [
355
+ d("span", {
356
+ class: t([a(Ne), e.loading ? a(Ye) : void 0])
357
+ }, [
358
+ y(s.$slots, "default")
359
+ ], 2),
360
+ e.loading ? (l(), o("span", {
361
+ key: 0,
362
+ class: t(a(Ge))
363
+ }, [
364
+ L(a(ve), {
365
+ size: 14,
366
+ class: "aggc-spin",
367
+ "aria-hidden": "true"
368
+ }),
369
+ d("span", null, c(e.loadingLabel), 1)
370
+ ], 2)) : b("", !0)
371
+ ], 10, Xe));
372
+ }
373
+ }), qe = g({
374
+ base: {
375
+ width: "100%",
376
+ display: "flex",
377
+ alignItems: "flex-start",
378
+ gap: "3",
379
+ textAlign: "left",
380
+ borderRadius: "2xl",
381
+ borderWidth: "1px",
382
+ px: "4",
383
+ py: "3.5",
384
+ color: "text.primary",
385
+ transition: "all 160ms ease"
386
+ },
387
+ variants: {
388
+ checked: {
389
+ true: {
390
+ borderColor: "border.accent",
391
+ bg: "bg.selected",
392
+ boxShadow: "0 18px 40px -30px rgba(49,94,255,0.56)"
393
+ },
394
+ false: {
395
+ borderColor: "border.default",
396
+ bg: "bg.input",
397
+ boxShadow: "0 14px 32px -30px rgba(15,23,42,0.42)"
398
+ }
399
+ },
400
+ disabled: {
401
+ true: {
402
+ cursor: "not-allowed",
403
+ opacity: 0.5
404
+ },
405
+ false: {
406
+ cursor: "pointer"
407
+ }
408
+ }
409
+ },
410
+ compoundVariants: [
411
+ {
412
+ checked: !0,
413
+ disabled: !1,
414
+ css: {
415
+ _hover: {
416
+ borderColor: "border.accent",
417
+ transform: "translateY(-1px)"
418
+ }
419
+ }
420
+ },
421
+ {
422
+ checked: !1,
423
+ disabled: !1,
424
+ css: {
425
+ _hover: {
426
+ borderColor: "border.strong",
427
+ transform: "translateY(-1px)"
428
+ }
429
+ }
430
+ }
431
+ ],
432
+ defaultVariants: {
433
+ checked: !1,
434
+ disabled: !1
435
+ }
436
+ }), Je = g({
437
+ base: {
438
+ mt: "0.5",
439
+ flexShrink: "0",
440
+ width: "22px",
441
+ height: "22px",
442
+ borderRadius: "md",
443
+ borderWidth: "1px",
444
+ display: "flex",
445
+ alignItems: "center",
446
+ justifyContent: "center",
447
+ transition: "all 160ms ease"
448
+ },
449
+ variants: {
450
+ checked: {
451
+ true: {
452
+ borderColor: "border.accent",
453
+ bg: "bg.accentStrong",
454
+ color: "text.inverse",
455
+ boxShadow: "0 12px 24px -16px rgba(49,94,255,0.7)"
456
+ },
457
+ false: {
458
+ borderColor: "border.default",
459
+ bg: "bg.buttonOutline",
460
+ color: "transparent",
461
+ boxShadow: "inset 0 1px 0 rgba(255,255,255,0.32)"
462
+ }
463
+ }
464
+ },
465
+ defaultVariants: {
466
+ checked: !1
467
+ }
468
+ }), Qe = i({
469
+ display: "grid",
470
+ gap: "1",
471
+ minWidth: "0"
472
+ }), Ze = i({
473
+ fontSize: "sm",
474
+ fontWeight: "700",
475
+ lineHeight: "1.45"
476
+ }), _e = i({
477
+ color: "text.secondary",
478
+ fontSize: "sm",
479
+ lineHeight: "1.55"
480
+ }), ea = ["id", "name", "aria-checked", "aria-describedby", "aria-invalid", "disabled", "onKeydown"], Aa = /* @__PURE__ */ p({
481
+ __name: "UiCheckbox",
482
+ props: {
483
+ modelValue: { type: Boolean },
484
+ id: { default: void 0 },
485
+ name: { default: void 0 },
486
+ label: { default: void 0 },
487
+ description: { default: void 0 },
488
+ disabled: { type: Boolean, default: !1 },
489
+ invalid: { type: Boolean, default: !1 },
490
+ ariaDescribedby: { default: void 0 }
491
+ },
492
+ emits: ["update:modelValue"],
493
+ setup(e, { emit: s }) {
494
+ const n = e, f = s;
495
+ function u() {
496
+ n.disabled || f("update:modelValue", !n.modelValue);
497
+ }
498
+ return (m, I) => (l(), o("button", {
499
+ type: "button",
500
+ id: e.id,
501
+ name: e.name,
502
+ role: "checkbox",
503
+ "aria-checked": e.modelValue,
504
+ "aria-describedby": e.ariaDescribedby,
505
+ "aria-invalid": e.invalid || void 0,
506
+ disabled: e.disabled,
507
+ class: t(a(qe)({ checked: e.modelValue, disabled: e.disabled })),
508
+ onClick: u,
509
+ onKeydown: [
510
+ U(K(u, ["prevent"]), ["enter"]),
511
+ U(K(u, ["prevent"]), ["space"])
512
+ ]
513
+ }, [
514
+ d("span", {
515
+ class: t(a(Je)({ checked: e.modelValue })),
516
+ "aria-hidden": "true"
517
+ }, [
518
+ L(a(q), { size: 14 })
519
+ ], 2),
520
+ d("span", {
521
+ class: t(a(Qe))
522
+ }, [
523
+ e.label || m.$slots.default ? (l(), o("span", {
524
+ key: 0,
525
+ class: t(a(Ze))
526
+ }, [
527
+ y(m.$slots, "default", {}, () => [
528
+ E(c(e.label), 1)
529
+ ])
530
+ ], 2)) : b("", !0),
531
+ e.description || m.$slots.description ? (l(), o("span", {
532
+ key: 1,
533
+ class: t(a(_e))
534
+ }, [
535
+ y(m.$slots, "description", {}, () => [
536
+ E(c(e.description), 1)
537
+ ])
538
+ ], 2)) : b("", !0)
539
+ ], 2)
540
+ ], 42, ea));
541
+ }
542
+ }), aa = i({
543
+ display: "grid",
544
+ gap: "2",
545
+ minWidth: "0"
546
+ }), ta = i({
547
+ display: "flex",
548
+ alignItems: "flex-start",
549
+ justifyContent: "space-between",
550
+ gap: "3"
551
+ }), sa = i({
552
+ display: "grid",
553
+ gap: "1",
554
+ minWidth: "0"
555
+ }), la = X, oa = i({
556
+ fontSize: "sm",
557
+ fontWeight: "700",
558
+ color: "text.primary"
559
+ }), na = ge, ia = i({
560
+ flexShrink: "0"
561
+ }), ra = ["for"], da = ["id"], Ma = /* @__PURE__ */ p({
562
+ __name: "UiField",
563
+ props: {
564
+ id: {},
565
+ forId: {},
566
+ label: {},
567
+ hint: {},
568
+ eyebrow: {}
569
+ },
570
+ setup(e) {
571
+ return (s, n) => (l(), o("div", {
572
+ class: t(a(aa))
573
+ }, [
574
+ e.eyebrow || e.label || e.hint || s.$slots.meta ? (l(), o("div", {
575
+ key: 0,
576
+ class: t(a(ta))
577
+ }, [
578
+ d("div", {
579
+ class: t(a(sa))
580
+ }, [
581
+ e.eyebrow ? (l(), o("p", {
582
+ key: 0,
583
+ class: t(a(la))
584
+ }, c(e.eyebrow), 3)) : b("", !0),
585
+ e.label ? (l(), o("label", {
586
+ key: 1,
587
+ for: e.forId,
588
+ class: t(a(oa))
589
+ }, c(e.label), 11, ra)) : b("", !0),
590
+ e.hint ? (l(), o("p", {
591
+ key: 2,
592
+ id: e.id,
593
+ class: t(a(na))
594
+ }, c(e.hint), 11, da)) : b("", !0)
595
+ ], 2),
596
+ s.$slots.meta ? (l(), o("div", {
597
+ key: 0,
598
+ class: t(a(ia))
599
+ }, [
600
+ y(s.$slots, "meta")
601
+ ], 2)) : b("", !0)
602
+ ], 2)) : b("", !0),
603
+ y(s.$slots, "default")
604
+ ], 2));
605
+ }
606
+ }), ca = D(
607
+ fe,
608
+ i({
609
+ paddingX: "4",
610
+ paddingY: "3",
611
+ display: "flex",
612
+ alignItems: "center",
613
+ gap: "3",
614
+ color: "text.secondary",
615
+ fontSize: "sm",
616
+ lineHeight: "1.5"
617
+ })
618
+ ), ua = i({
619
+ width: "2.5",
620
+ height: "2.5",
621
+ borderRadius: "full",
622
+ flexShrink: "0",
623
+ bg: "text.accent",
624
+ boxShadow: "0 0 0 0 rgba(49,94,255,0.35)",
625
+ animation: "loadingPulse 1.2s ease-out infinite"
626
+ }), ba = i({
627
+ display: "grid",
628
+ gap: "0.5"
629
+ }), ga = i({
630
+ fontWeight: "700",
631
+ color: "text.primary"
632
+ }), fa = ["aria-live", "role"], Ua = /* @__PURE__ */ p({
633
+ __name: "UiLoadingState",
634
+ props: {
635
+ title: {},
636
+ description: {},
637
+ live: { default: "polite" }
638
+ },
639
+ setup(e) {
640
+ return (s, n) => (l(), o("div", {
641
+ class: t(a(ca)),
642
+ "data-testid": "loading-state",
643
+ "aria-live": e.live,
644
+ role: e.live === "off" ? void 0 : "status"
645
+ }, [
646
+ d("span", {
647
+ class: t(a(ua)),
648
+ "aria-hidden": "true",
649
+ "data-ui-loading-pulse": ""
650
+ }, null, 2),
651
+ d("div", {
652
+ class: t(a(ba))
653
+ }, [
654
+ d("p", {
655
+ class: t(a(ga))
656
+ }, c(e.title), 3),
657
+ d("p", null, c(e.description), 1)
658
+ ], 2)
659
+ ], 10, fa));
660
+ }
661
+ }), pa = i({
662
+ display: "inline-flex",
663
+ width: "fit-content",
664
+ borderRadius: "full",
665
+ borderWidth: "1px",
666
+ borderColor: "border.default",
667
+ bg: "bg.input",
668
+ padding: "1",
669
+ gap: "1",
670
+ backdropFilter: "blur(18px) saturate(140%)",
671
+ boxShadow: "inset 0 1px 0 rgba(255,255,255,0.18)"
672
+ }), ma = g({
673
+ base: {
674
+ borderRadius: "full",
675
+ px: "3.5",
676
+ py: "2",
677
+ fontSize: "sm",
678
+ fontWeight: "600",
679
+ cursor: "pointer",
680
+ borderWidth: "1px",
681
+ transition: "all 160ms ease"
682
+ },
683
+ variants: {
684
+ active: {
685
+ true: {
686
+ borderColor: "border.accent",
687
+ bg: "bg.accentStrong",
688
+ color: "text.inverse",
689
+ boxShadow: "0 14px 26px -16px rgba(49,94,255,0.68)",
690
+ _hover: {
691
+ bg: "bg.accentStrong"
692
+ }
693
+ },
694
+ false: {
695
+ borderColor: "transparent",
696
+ bg: "transparent",
697
+ color: "text.secondary",
698
+ boxShadow: "none",
699
+ _hover: {
700
+ bg: "bg.hover"
701
+ }
702
+ }
703
+ }
704
+ }
705
+ }), ha = ["onClick"], Ka = /* @__PURE__ */ p({
706
+ __name: "UiSegmentedControl",
707
+ props: {
708
+ modelValue: {},
709
+ options: {}
710
+ },
711
+ emits: ["update:modelValue"],
712
+ setup(e) {
713
+ return (s, n) => (l(), o("div", {
714
+ class: t(a(pa))
715
+ }, [
716
+ (l(!0), o(z, null, V(e.options, (f) => (l(), o("button", {
717
+ key: f.value,
718
+ type: "button",
719
+ class: t(a(ma)({ active: f.value === e.modelValue })),
720
+ onClick: (u) => s.$emit("update:modelValue", f.value)
721
+ }, c(f.label), 11, ha))), 128))
722
+ ], 2));
723
+ }
724
+ }), va = g({
725
+ base: {
726
+ position: "relative"
727
+ },
728
+ variants: {
729
+ open: {
730
+ true: { zIndex: "30" },
731
+ false: { zIndex: "1" }
732
+ }
733
+ },
734
+ defaultVariants: {
735
+ open: !1
736
+ }
737
+ }), ya = g({
738
+ base: {
739
+ width: "100%",
740
+ display: "flex",
741
+ alignItems: "center",
742
+ justifyContent: "space-between",
743
+ gap: "3",
744
+ borderWidth: "1px",
745
+ fontSize: "sm",
746
+ overflow: "hidden",
747
+ backdropFilter: "blur(24px) saturate(145%)",
748
+ transition: "all 160ms ease"
749
+ },
750
+ variants: {
751
+ size: {
752
+ sm: {
753
+ minHeight: "40px",
754
+ borderRadius: "lg",
755
+ px: "3",
756
+ py: "2.5"
757
+ },
758
+ md: {
759
+ minHeight: "48px",
760
+ borderRadius: "xl",
761
+ px: "4",
762
+ py: "3"
763
+ }
764
+ },
765
+ open: {
766
+ true: {
767
+ borderColor: "border.accent",
768
+ bg: "bg.cardStrong",
769
+ boxShadow: "0 18px 42px -28px rgba(49,94,255,0.42)"
770
+ },
771
+ false: {
772
+ borderColor: "border.default",
773
+ bg: "bg.input",
774
+ boxShadow: "inset 0 1px 0 rgba(255,255,255,0.22)"
775
+ }
776
+ },
777
+ selected: {
778
+ true: { color: "text.primary" },
779
+ false: { color: "text.muted" }
780
+ },
781
+ disabled: {
782
+ true: {
783
+ cursor: "not-allowed",
784
+ opacity: 0.55
785
+ },
786
+ false: {
787
+ cursor: "pointer"
788
+ }
789
+ }
790
+ },
791
+ compoundVariants: [
792
+ {
793
+ disabled: !1,
794
+ css: {
795
+ _hover: {
796
+ borderColor: "border.strong",
797
+ bg: "bg.cardStrong"
798
+ }
799
+ }
800
+ }
801
+ ],
802
+ defaultVariants: {
803
+ size: "md",
804
+ open: !1,
805
+ selected: !1,
806
+ disabled: !1
807
+ }
808
+ }), Ca = pe({
809
+ placement: "anchored",
810
+ density: "cozy"
811
+ }), xa = i({
812
+ width: "100%",
813
+ zIndex: "30",
814
+ maxHeight: "320px",
815
+ overflowY: "auto",
816
+ display: "grid"
817
+ }), wa = i({
818
+ display: "block",
819
+ textAlign: "left",
820
+ minWidth: "0",
821
+ flex: "1",
822
+ overflow: "hidden"
823
+ }), ka = i({
824
+ display: "block",
825
+ overflow: "hidden",
826
+ textOverflow: "ellipsis",
827
+ whiteSpace: "nowrap"
828
+ }), Sa = g({
829
+ base: {
830
+ color: "text.muted",
831
+ transition: "transform 160ms ease"
832
+ },
833
+ variants: {
834
+ open: {
835
+ true: { transform: "rotate(180deg)" },
836
+ false: { transform: "rotate(0deg)" }
837
+ }
838
+ },
839
+ defaultVariants: {
840
+ open: !1
841
+ }
842
+ }), Ba = g({
843
+ base: {
844
+ width: "100%",
845
+ display: "flex",
846
+ alignItems: "flex-start",
847
+ justifyContent: "space-between",
848
+ gap: "3",
849
+ textAlign: "left",
850
+ borderRadius: "xl",
851
+ px: "3",
852
+ borderWidth: "1px",
853
+ cursor: "pointer",
854
+ transition: "all 140ms ease",
855
+ _hover: {
856
+ bg: "bg.selected",
857
+ borderColor: "border.accent"
858
+ }
859
+ },
860
+ variants: {
861
+ size: {
862
+ sm: { py: "2.5" },
863
+ md: { py: "3" }
864
+ },
865
+ active: {
866
+ true: {
867
+ color: "text.primary",
868
+ bg: "bg.selected",
869
+ borderColor: "border.accent"
870
+ },
871
+ false: {
872
+ color: "text.secondary",
873
+ bg: "transparent",
874
+ borderColor: "transparent"
875
+ }
876
+ }
877
+ },
878
+ defaultVariants: {
879
+ size: "md",
880
+ active: !1
881
+ }
882
+ }), $a = i({
883
+ display: "grid",
884
+ gap: "0.5",
885
+ minWidth: "0"
886
+ }), za = i({
887
+ fontSize: "sm",
888
+ fontWeight: "600",
889
+ minWidth: "0",
890
+ overflow: "hidden",
891
+ textOverflow: "ellipsis",
892
+ whiteSpace: "nowrap"
893
+ }), Va = i({
894
+ color: "text.secondary",
895
+ fontSize: "xs",
896
+ lineHeight: "1.45",
897
+ overflowWrap: "anywhere"
898
+ }), Ra = g({
899
+ base: {
900
+ color: "text.accent",
901
+ transition: "opacity 140ms ease"
902
+ },
903
+ variants: {
904
+ selected: {
905
+ true: { opacity: 1 },
906
+ false: { opacity: 0 }
907
+ }
908
+ },
909
+ defaultVariants: {
910
+ selected: !1
911
+ }
912
+ }), La = ["id", "name", "disabled", "aria-expanded", "aria-controls", "aria-label", "aria-labelledby", "aria-describedby", "aria-invalid"], Ia = ["id", "aria-activedescendant"], Wa = ["id", "aria-selected", "onMouseenter", "onClick", "onKeydown"], Na = /* @__PURE__ */ p({
913
+ __name: "UiSelect",
914
+ props: {
915
+ modelValue: {},
916
+ options: {},
917
+ id: { default: void 0 },
918
+ name: { default: void 0 },
919
+ placeholder: { default: "Select an option" },
920
+ disabled: { type: Boolean, default: !1 },
921
+ invalid: { type: Boolean, default: !1 },
922
+ size: { default: "md" },
923
+ ariaLabel: { default: void 0 },
924
+ ariaLabelledby: { default: void 0 },
925
+ ariaDescribedby: { default: void 0 }
926
+ },
927
+ emits: ["update:modelValue"],
928
+ setup(e, { emit: s }) {
929
+ const n = e, f = s, u = $(null), m = $(null), I = $([]), h = $(!1), x = $(-1), J = se(), W = R(() => n.id ?? `ui-select-${J}`), F = R(() => `${W.value}-listbox`), j = R(
930
+ () => n.options.find((r) => r.value === n.modelValue) ?? null
931
+ );
932
+ function k(r) {
933
+ if (!n.options.length) {
934
+ x.value = -1;
935
+ return;
936
+ }
937
+ const v = (r + n.options.length) % n.options.length;
938
+ x.value = v, T(() => {
939
+ I.value[v]?.focus();
940
+ });
941
+ }
942
+ function w() {
943
+ h.value = !1, x.value = -1;
944
+ }
945
+ async function O() {
946
+ if (n.disabled || !n.options.length)
947
+ return;
948
+ h.value = !0;
949
+ const r = n.options.findIndex((v) => v.value === n.modelValue);
950
+ await T(), k(r >= 0 ? r : 0);
951
+ }
952
+ function Q() {
953
+ if (h.value) {
954
+ w();
955
+ return;
956
+ }
957
+ O();
958
+ }
959
+ function A(r) {
960
+ f("update:modelValue", r), w(), T(() => {
961
+ m.value?.focus();
962
+ });
963
+ }
964
+ function Z(r) {
965
+ n.disabled || (r.key === "ArrowDown" || r.key === "Enter" || r.key === " ") && (r.preventDefault(), O());
966
+ }
967
+ function _(r, v) {
968
+ switch (r.key) {
969
+ case "ArrowDown":
970
+ r.preventDefault(), k(v + 1);
971
+ break;
972
+ case "ArrowUp":
973
+ r.preventDefault(), k(v - 1);
974
+ break;
975
+ case "Home":
976
+ r.preventDefault(), k(0);
977
+ break;
978
+ case "End":
979
+ r.preventDefault(), k(n.options.length - 1);
980
+ break;
981
+ case "Escape":
982
+ r.preventDefault(), w(), m.value?.focus();
983
+ break;
984
+ case "Enter":
985
+ case " ":
986
+ r.preventDefault(), A(n.options[v].value);
987
+ break;
988
+ }
989
+ }
990
+ function M(r) {
991
+ h.value && (u.value?.contains(r.target) || w());
992
+ }
993
+ return N(
994
+ () => n.options,
995
+ () => {
996
+ I.value = [], n.options.some((r) => r.value === n.modelValue) || w();
997
+ }
998
+ ), N(
999
+ () => n.disabled,
1000
+ (r) => {
1001
+ r && w();
1002
+ }
1003
+ ), le(() => {
1004
+ document.addEventListener("pointerdown", M);
1005
+ }), oe(() => {
1006
+ document.removeEventListener("pointerdown", M);
1007
+ }), (r, v) => (l(), o("div", {
1008
+ ref_key: "rootRef",
1009
+ ref: u,
1010
+ class: t(a(va)({ open: h.value }))
1011
+ }, [
1012
+ d("button", {
1013
+ ref_key: "triggerRef",
1014
+ ref: m,
1015
+ type: "button",
1016
+ id: W.value,
1017
+ name: e.name,
1018
+ disabled: e.disabled,
1019
+ class: t(a(ya)({ size: e.size, open: h.value, selected: !!j.value, disabled: e.disabled })),
1020
+ "aria-haspopup": "listbox",
1021
+ "aria-expanded": h.value,
1022
+ "aria-controls": F.value,
1023
+ "aria-label": e.ariaLabel,
1024
+ "aria-labelledby": e.ariaLabelledby,
1025
+ "aria-describedby": e.ariaDescribedby,
1026
+ "aria-invalid": e.invalid || void 0,
1027
+ onClick: Q,
1028
+ onKeydown: Z
1029
+ }, [
1030
+ d("span", {
1031
+ class: t(a(wa))
1032
+ }, [
1033
+ d("span", {
1034
+ class: t(a(ka))
1035
+ }, c(j.value?.label ?? e.placeholder), 3)
1036
+ ], 2),
1037
+ L(a(ye), {
1038
+ size: 16,
1039
+ class: t(a(Sa)({ open: h.value }))
1040
+ }, null, 8, ["class"])
1041
+ ], 42, La),
1042
+ h.value ? (l(), o("div", {
1043
+ key: 0,
1044
+ id: F.value,
1045
+ class: t([a(Ca), a(xa)]),
1046
+ role: "listbox",
1047
+ "aria-activedescendant": x.value >= 0 ? `${W.value}-${x.value}` : void 0
1048
+ }, [
1049
+ (l(!0), o(z, null, V(e.options, (C, S) => (l(), o("button", {
1050
+ id: `${W.value}-${S}`,
1051
+ key: C.value,
1052
+ ref_for: !0,
1053
+ ref: (B) => I.value[S] = B,
1054
+ type: "button",
1055
+ role: "option",
1056
+ "aria-selected": C.value === e.modelValue,
1057
+ class: t(a(Ba)({ size: e.size, active: x.value === S || C.value === e.modelValue })),
1058
+ onMouseenter: (B) => x.value = S,
1059
+ onClick: (B) => A(C.value),
1060
+ onKeydown: (B) => _(B, S)
1061
+ }, [
1062
+ d("span", {
1063
+ class: t(a($a))
1064
+ }, [
1065
+ d("span", {
1066
+ class: t(a(za))
1067
+ }, c(C.label), 3),
1068
+ C.description && e.size === "md" ? (l(), o("span", {
1069
+ key: 0,
1070
+ class: t(a(Va))
1071
+ }, c(C.description), 3)) : b("", !0)
1072
+ ], 2),
1073
+ L(a(q), {
1074
+ size: 15,
1075
+ class: t(a(Ra)({ selected: C.value === e.modelValue }))
1076
+ }, null, 8, ["class"])
1077
+ ], 42, Wa))), 128))
1078
+ ], 10, Ia)) : b("", !0)
1079
+ ], 2));
1080
+ }
1081
+ }), Da = g({
1082
+ base: {
1083
+ position: "relative",
1084
+ overflow: "hidden",
1085
+ _before: {
1086
+ content: '""',
1087
+ position: "absolute",
1088
+ inset: "0",
1089
+ background: "linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.62) 50%, rgba(255,255,255,0) 100%)",
1090
+ transform: "translateX(-100%)",
1091
+ animation: "aggc-shimmer 1.45s ease-in-out infinite"
1092
+ },
1093
+ _dark: {
1094
+ _before: {
1095
+ background: "linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(186,204,236,0.22) 50%, rgba(255,255,255,0) 100%)"
1096
+ }
1097
+ }
1098
+ },
1099
+ variants: {
1100
+ variant: {
1101
+ text: {
1102
+ width: "100%",
1103
+ height: "0.875rem",
1104
+ borderRadius: "md",
1105
+ bg: "rgba(127, 146, 184, 0.14)",
1106
+ _dark: {
1107
+ bg: "rgba(210, 220, 240, 0.09)"
1108
+ }
1109
+ },
1110
+ title: {
1111
+ width: "100%",
1112
+ height: "1.75rem",
1113
+ borderRadius: "xl",
1114
+ bg: "rgba(127, 146, 184, 0.14)",
1115
+ _dark: {
1116
+ bg: "rgba(210, 220, 240, 0.09)"
1117
+ }
1118
+ },
1119
+ rect: {
1120
+ width: "100%",
1121
+ height: "5rem",
1122
+ borderRadius: "xl",
1123
+ bg: "rgba(127, 146, 184, 0.14)",
1124
+ _dark: {
1125
+ bg: "rgba(210, 220, 240, 0.09)"
1126
+ }
1127
+ },
1128
+ pill: {
1129
+ width: "5rem",
1130
+ height: "1.75rem",
1131
+ borderRadius: "999px",
1132
+ bg: "rgba(127, 146, 184, 0.14)",
1133
+ _dark: {
1134
+ bg: "rgba(210, 220, 240, 0.09)"
1135
+ }
1136
+ },
1137
+ circle: {
1138
+ width: "2.75rem",
1139
+ height: "2.75rem",
1140
+ borderRadius: "999px",
1141
+ bg: "rgba(127, 146, 184, 0.14)",
1142
+ _dark: {
1143
+ bg: "rgba(210, 220, 240, 0.09)"
1144
+ }
1145
+ },
1146
+ stat: {
1147
+ width: "100%",
1148
+ height: "4.75rem",
1149
+ borderRadius: "xl",
1150
+ bg: "rgba(117, 138, 178, 0.16)",
1151
+ _dark: {
1152
+ bg: "rgba(210, 220, 240, 0.11)"
1153
+ }
1154
+ },
1155
+ action: {
1156
+ width: "100%",
1157
+ height: "2.75rem",
1158
+ borderRadius: "xl",
1159
+ bg: "rgba(127, 146, 184, 0.14)",
1160
+ _dark: {
1161
+ bg: "rgba(210, 220, 240, 0.09)"
1162
+ }
1163
+ }
1164
+ }
1165
+ },
1166
+ defaultVariants: {
1167
+ variant: "rect"
1168
+ }
1169
+ }), Ya = /* @__PURE__ */ p({
1170
+ __name: "UiSkeleton",
1171
+ props: {
1172
+ variant: { default: "rect" },
1173
+ width: { default: void 0 },
1174
+ height: { default: void 0 }
1175
+ },
1176
+ setup(e) {
1177
+ const s = e, n = R(() => Da({ variant: s.variant })), f = R(() => ({
1178
+ width: s.width ?? (s.variant === "circle" ? "2.75rem" : s.variant === "pill" ? "5rem" : "100%"),
1179
+ height: s.height ?? (s.variant === "text" ? "0.875rem" : s.variant === "title" || s.variant === "pill" ? "1.75rem" : s.variant === "circle" || s.variant === "action" ? "2.75rem" : s.variant === "stat" ? "4.75rem" : "5rem")
1180
+ }));
1181
+ return (u, m) => (l(), o("div", {
1182
+ "aria-hidden": "true",
1183
+ "data-ui-skeleton": "",
1184
+ class: t(n.value),
1185
+ style: ne(f.value)
1186
+ }, null, 6));
1187
+ }
1188
+ });
1189
+ export {
1190
+ Ea as _,
1191
+ Fa as a,
1192
+ ja as b,
1193
+ we as c,
1194
+ Oa as d,
1195
+ Aa as e,
1196
+ Ma as f,
1197
+ Ua as g,
1198
+ Ka as h,
1199
+ Na as i,
1200
+ Ya as j
1201
+ };