@kode4/react-foundation 0.1.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.
Files changed (126) hide show
  1. package/DESIGN-SYSTEM.md +190 -0
  2. package/INSTRUCTIONS.md +694 -0
  3. package/LICENSE +21 -0
  4. package/README.md +53 -0
  5. package/errors.d.ts +24 -0
  6. package/forms/Form/Form.d.ts +30 -0
  7. package/forms/Form/index.d.ts +1 -0
  8. package/forms/index.d.ts +1 -0
  9. package/hooks/index.d.ts +1 -0
  10. package/hooks/useMediaQuery.d.ts +8 -0
  11. package/index.d.ts +24 -0
  12. package/index.js +1679 -0
  13. package/index.js.map +1 -0
  14. package/internal/env.d.ts +1 -0
  15. package/internal/registry.d.ts +3 -0
  16. package/internal/type-utils.d.ts +6 -0
  17. package/layout/AppLayout/AppLayout.d.ts +18 -0
  18. package/layout/AppLayout/index.d.ts +1 -0
  19. package/layout/CenteredLayout/CenteredLayout.d.ts +12 -0
  20. package/layout/CenteredLayout/index.d.ts +1 -0
  21. package/layout/Columns/Columns.d.ts +35 -0
  22. package/layout/Columns/index.d.ts +1 -0
  23. package/layout/Container/Container.d.ts +5 -0
  24. package/layout/Container/index.d.ts +1 -0
  25. package/layout/DashboardGrid/DashboardGrid.d.ts +37 -0
  26. package/layout/DashboardGrid/index.d.ts +1 -0
  27. package/layout/FillHeight/FillHeight.d.ts +16 -0
  28. package/layout/FillHeight/index.d.ts +1 -0
  29. package/layout/Footer/Footer.d.ts +5 -0
  30. package/layout/Footer/index.d.ts +1 -0
  31. package/layout/Header/Header.d.ts +13 -0
  32. package/layout/Header/index.d.ts +1 -0
  33. package/layout/SideBar/SideBar.d.ts +6 -0
  34. package/layout/SideBar/index.d.ts +1 -0
  35. package/layout/SiteLayout/SiteLayout.d.ts +27 -0
  36. package/layout/SiteLayout/index.d.ts +1 -0
  37. package/layout/SkipLink/SkipLink.d.ts +9 -0
  38. package/layout/SkipLink/index.d.ts +1 -0
  39. package/layout/TopBar/TopBar.d.ts +32 -0
  40. package/layout/TopBar/index.d.ts +1 -0
  41. package/layout/index.d.ts +12 -0
  42. package/package.json +52 -0
  43. package/query/index.d.ts +1 -0
  44. package/query/sort.d.ts +19 -0
  45. package/router/DefaultErrorBoundary.d.ts +5 -0
  46. package/router/TypedLink/TypedLink.d.ts +22 -0
  47. package/router/TypedLink/index.d.ts +1 -0
  48. package/router/adapter.d.ts +27 -0
  49. package/router/chain.d.ts +17 -0
  50. package/router/context.d.ts +24 -0
  51. package/router/createAppRouter.d.ts +15 -0
  52. package/router/defineRoute.d.ts +11 -0
  53. package/router/index.d.ts +11 -0
  54. package/router/menu.d.ts +51 -0
  55. package/router/pathTo.d.ts +21 -0
  56. package/router/types.d.ts +72 -0
  57. package/router/useRoute.d.ts +22 -0
  58. package/style.css +3 -0
  59. package/theme/ModeToggle/ModeToggle.d.ts +6 -0
  60. package/theme/ModeToggle/index.d.ts +1 -0
  61. package/theme/ThemeProvider/ThemeProvider.d.ts +25 -0
  62. package/theme/ThemeProvider/index.d.ts +1 -0
  63. package/theme/Toaster/Toaster.d.ts +9 -0
  64. package/theme/Toaster/index.d.ts +2 -0
  65. package/theme/Toaster/toast.d.ts +38 -0
  66. package/theme/index.d.ts +3 -0
  67. package/ui/Accordion/Accordion.d.ts +7 -0
  68. package/ui/Accordion/index.d.ts +1 -0
  69. package/ui/Alert/Alert.d.ts +11 -0
  70. package/ui/Alert/index.d.ts +1 -0
  71. package/ui/AlertDialog/AlertDialog.d.ts +19 -0
  72. package/ui/AlertDialog/index.d.ts +1 -0
  73. package/ui/Avatar/Avatar.d.ts +7 -0
  74. package/ui/Avatar/index.d.ts +1 -0
  75. package/ui/AwaitErrorBlock/AwaitErrorBlock.d.ts +11 -0
  76. package/ui/AwaitErrorBlock/index.d.ts +1 -0
  77. package/ui/Badge/Badge.d.ts +10 -0
  78. package/ui/Badge/index.d.ts +1 -0
  79. package/ui/Button/Button.d.ts +13 -0
  80. package/ui/Button/index.d.ts +1 -0
  81. package/ui/Card/Card.d.ts +11 -0
  82. package/ui/Card/index.d.ts +1 -0
  83. package/ui/Checkbox/Checkbox.d.ts +5 -0
  84. package/ui/Checkbox/index.d.ts +1 -0
  85. package/ui/Command/Command.d.ts +19 -0
  86. package/ui/Command/index.d.ts +1 -0
  87. package/ui/Dialog/Dialog.d.ts +17 -0
  88. package/ui/Dialog/index.d.ts +1 -0
  89. package/ui/DropdownMenu/DropdownMenu.d.ts +28 -0
  90. package/ui/DropdownMenu/index.d.ts +1 -0
  91. package/ui/ErrorBlock/ErrorBlock.d.ts +21 -0
  92. package/ui/ErrorBlock/index.d.ts +1 -0
  93. package/ui/Input/Input.d.ts +4 -0
  94. package/ui/Input/index.d.ts +1 -0
  95. package/ui/Label/Label.d.ts +5 -0
  96. package/ui/Label/index.d.ts +1 -0
  97. package/ui/Pagination/Pagination.d.ts +17 -0
  98. package/ui/Pagination/index.d.ts +1 -0
  99. package/ui/Popover/Popover.d.ts +7 -0
  100. package/ui/Popover/index.d.ts +1 -0
  101. package/ui/Progress/Progress.d.ts +16 -0
  102. package/ui/Progress/index.d.ts +1 -0
  103. package/ui/RadioGroup/RadioGroup.d.ts +7 -0
  104. package/ui/RadioGroup/index.d.ts +1 -0
  105. package/ui/Select/Select.d.ts +16 -0
  106. package/ui/Select/index.d.ts +1 -0
  107. package/ui/Separator/Separator.d.ts +5 -0
  108. package/ui/Separator/index.d.ts +1 -0
  109. package/ui/Sheet/Sheet.d.ts +17 -0
  110. package/ui/Sheet/index.d.ts +1 -0
  111. package/ui/Skeleton/Skeleton.d.ts +4 -0
  112. package/ui/Skeleton/index.d.ts +1 -0
  113. package/ui/Spinner/Spinner.d.ts +35 -0
  114. package/ui/Spinner/index.d.ts +1 -0
  115. package/ui/Switch/Switch.d.ts +5 -0
  116. package/ui/Switch/index.d.ts +1 -0
  117. package/ui/Table/Table.d.ts +11 -0
  118. package/ui/Table/index.d.ts +1 -0
  119. package/ui/Tabs/Tabs.d.ts +8 -0
  120. package/ui/Tabs/index.d.ts +1 -0
  121. package/ui/Textarea/Textarea.d.ts +4 -0
  122. package/ui/Textarea/index.d.ts +1 -0
  123. package/ui/Tooltip/Tooltip.d.ts +7 -0
  124. package/ui/Tooltip/index.d.ts +1 -0
  125. package/ui/index.d.ts +29 -0
  126. package/utils.d.ts +8 -0
package/index.js ADDED
@@ -0,0 +1,1679 @@
1
+ import { Link as e, NavLink as t, createBrowserRouter as n, isRouteErrorResponse as r, useAsyncError as i, useLoaderData as a, useParams as o, useRouteError as s, useSearchParams as c } from "react-router-dom";
2
+ import { Accordion as l, AlertDialog as u, Avatar as d, Checkbox as f, Dialog as p, DropdownMenu as m, Label as ee, Popover as h, Progress as te, RadioGroup as g, Select as _, Separator as ne, Slot as v, Switch as y, Tabs as b, Tooltip as x } from "radix-ui";
3
+ import { createContext as S, useCallback as re, useContext as C, useEffect as w, useId as ie, useLayoutEffect as ae, useMemo as T, useRef as oe, useState as E } from "react";
4
+ import { Controller as se, FormProvider as ce, useFormContext as le, useFormState as ue } from "react-hook-form";
5
+ import { clsx as de } from "clsx";
6
+ import { jsx as D, jsxs as O } from "react/jsx-runtime";
7
+ import { cva as k } from "class-variance-authority";
8
+ import { AlertCircleIcon as fe, CheckIcon as A, ChevronDownIcon as j, ChevronLeftIcon as pe, ChevronRightIcon as me, ChevronUpIcon as he, CircleIcon as ge, Loader2Icon as _e, MegaphoneIcon as ve, MenuIcon as ye, MoonIcon as be, MoreHorizontalIcon as xe, SearchIcon as Se, SparklesIcon as Ce, SunIcon as we, XIcon as M } from "lucide-react";
9
+ import { Toaster as Te, toast as N } from "sonner";
10
+ import { Command as P } from "cmdk";
11
+ //#region src/lib/errors.ts
12
+ var F = class extends Error {
13
+ code;
14
+ details;
15
+ constructor(e, t, n) {
16
+ super(t), this.name = "AppError", this.code = e, this.details = n;
17
+ }
18
+ };
19
+ function I(e) {
20
+ return e instanceof F ? {
21
+ code: e.code,
22
+ message: e.message,
23
+ details: e.details,
24
+ original: e
25
+ } : r(e) ? {
26
+ code: String(e.status),
27
+ message: e.statusText || `HTTP ${e.status}`,
28
+ details: e.data,
29
+ original: e
30
+ } : e instanceof Error ? {
31
+ message: e.message,
32
+ original: e
33
+ } : typeof e == "string" ? {
34
+ message: e,
35
+ original: e
36
+ } : {
37
+ message: "An unknown error occurred",
38
+ original: e
39
+ };
40
+ }
41
+ //#endregion
42
+ //#region src/lib/utils.ts
43
+ function L(...e) {
44
+ return de(e);
45
+ }
46
+ //#endregion
47
+ //#region src/lib/ui/Label/Label.tsx
48
+ function Ee({ className: e, ...t }) {
49
+ return /* @__PURE__ */ D(ee.Root, {
50
+ className: L("k4-label", e),
51
+ ...t
52
+ });
53
+ }
54
+ //#endregion
55
+ //#region src/lib/forms/Form/Form.tsx
56
+ var De = ce, Oe = S(void 0);
57
+ function ke(e) {
58
+ return /* @__PURE__ */ D(Oe.Provider, {
59
+ value: { name: e.name },
60
+ children: /* @__PURE__ */ D(se, { ...e })
61
+ });
62
+ }
63
+ var Ae = S(void 0);
64
+ function R() {
65
+ let e = C(Oe), t = C(Ae), { getFieldState: n } = le(), r = ue({ name: e?.name });
66
+ if (!e) throw Error("useFormField should be used within <FormField>");
67
+ let i = n(e.name, r), a = t?.id ?? e.name;
68
+ return {
69
+ id: a,
70
+ name: e.name,
71
+ formItemId: `${a}-form-item`,
72
+ formDescriptionId: `${a}-form-item-description`,
73
+ formMessageId: `${a}-form-item-message`,
74
+ ...i
75
+ };
76
+ }
77
+ function je({ className: e, ...t }) {
78
+ let n = ie();
79
+ return /* @__PURE__ */ D(Ae.Provider, {
80
+ value: { id: n },
81
+ children: /* @__PURE__ */ D("div", {
82
+ className: L("k4-form__item", e),
83
+ ...t
84
+ })
85
+ });
86
+ }
87
+ function Me({ className: e, ...t }) {
88
+ let { error: n, formItemId: r } = R();
89
+ return /* @__PURE__ */ D(Ee, {
90
+ className: L("k4-form__label", n && "k4-form__label--error", e),
91
+ htmlFor: r,
92
+ ...t
93
+ });
94
+ }
95
+ function Ne(e) {
96
+ let { error: t, formItemId: n, formDescriptionId: r, formMessageId: i } = R();
97
+ return /* @__PURE__ */ D(v.Root, {
98
+ id: n,
99
+ "aria-describedby": t ? `${r} ${i}` : r,
100
+ "aria-invalid": !!t,
101
+ ...e
102
+ });
103
+ }
104
+ function Pe({ className: e, ...t }) {
105
+ let { formDescriptionId: n } = R();
106
+ return /* @__PURE__ */ D("p", {
107
+ id: n,
108
+ className: L("k4-form__description", e),
109
+ ...t
110
+ });
111
+ }
112
+ function Fe({ className: e, children: t, ...n }) {
113
+ let { error: r, formMessageId: i } = R(), a = r ? String(r.message ?? "") : t;
114
+ return a ? /* @__PURE__ */ D("p", {
115
+ id: i,
116
+ className: L("k4-form__message", e),
117
+ ...n,
118
+ children: a
119
+ }) : null;
120
+ }
121
+ //#endregion
122
+ //#region src/lib/hooks/useMediaQuery.ts
123
+ function Ie(e) {
124
+ let [t, n] = E(() => typeof window < "u" ? window.matchMedia(e).matches : !1);
125
+ return w(() => {
126
+ let t = window.matchMedia(e), r = () => n(t.matches);
127
+ return r(), t.addEventListener("change", r), () => t.removeEventListener("change", r);
128
+ }, [e]), t;
129
+ }
130
+ //#endregion
131
+ //#region src/lib/layout/AppLayout/AppLayout.tsx
132
+ function Le({ header: e, footer: t, mainId: n = "main", contentLabel: r = "Main content", className: i, children: a, ...o }) {
133
+ return /* @__PURE__ */ O("div", {
134
+ className: L("k4-app-layout", i),
135
+ ...o,
136
+ children: [
137
+ e != null && /* @__PURE__ */ D("div", {
138
+ className: "k4-app-layout__header",
139
+ children: e
140
+ }),
141
+ /* @__PURE__ */ D("main", {
142
+ id: n,
143
+ className: "k4-app-layout__content",
144
+ tabIndex: 0,
145
+ "aria-label": r,
146
+ children: a
147
+ }),
148
+ t != null && /* @__PURE__ */ D("div", {
149
+ className: "k4-app-layout__footer",
150
+ children: t
151
+ })
152
+ ]
153
+ });
154
+ }
155
+ //#endregion
156
+ //#region src/lib/layout/CenteredLayout/CenteredLayout.tsx
157
+ function Re({ header: e, footer: t, mainId: n = "main", className: r, children: i, ...a }) {
158
+ return /* @__PURE__ */ O("div", {
159
+ className: L("k4-centered-layout", r),
160
+ ...a,
161
+ children: [
162
+ e != null && /* @__PURE__ */ D("div", {
163
+ className: "k4-centered-layout__header",
164
+ children: e
165
+ }),
166
+ /* @__PURE__ */ D("main", {
167
+ id: n,
168
+ className: "k4-centered-layout__content",
169
+ children: i
170
+ }),
171
+ t != null && /* @__PURE__ */ D("div", {
172
+ className: "k4-centered-layout__footer",
173
+ children: t
174
+ })
175
+ ]
176
+ });
177
+ }
178
+ //#endregion
179
+ //#region src/lib/layout/Columns/Columns.tsx
180
+ var ze = k("k4-columns", {
181
+ variants: {
182
+ fillHeight: {
183
+ true: "k4-columns--fill",
184
+ false: ""
185
+ },
186
+ scroll: {
187
+ true: "k4-columns--scroll",
188
+ false: ""
189
+ },
190
+ gap: {
191
+ true: "k4-columns--gap",
192
+ false: ""
193
+ }
194
+ },
195
+ defaultVariants: {
196
+ fillHeight: !1,
197
+ scroll: !1,
198
+ gap: !0
199
+ }
200
+ });
201
+ function Be({ left: e, right: t, leftWidth: n, rightWidth: r, fillHeight: i, scroll: a, gap: o, className: s, style: c, children: l, ...u }) {
202
+ let d = {
203
+ ...n ? { "--k4-columns-left": n } : null,
204
+ ...r ? { "--k4-columns-right": r } : null
205
+ }, f = a ? { tabIndex: 0 } : {};
206
+ return /* @__PURE__ */ O("div", {
207
+ className: L(ze({
208
+ fillHeight: i,
209
+ scroll: a,
210
+ gap: o
211
+ }), e != null && "k4-columns--has-left", t != null && "k4-columns--has-right", s),
212
+ style: {
213
+ ...d,
214
+ ...c
215
+ },
216
+ ...u,
217
+ children: [
218
+ e != null && /* @__PURE__ */ D("div", {
219
+ className: "k4-columns__cell k4-columns__left",
220
+ ...f,
221
+ children: e
222
+ }),
223
+ /* @__PURE__ */ D("div", {
224
+ className: "k4-columns__cell k4-columns__content",
225
+ ...f,
226
+ children: l
227
+ }),
228
+ t != null && /* @__PURE__ */ D("div", {
229
+ className: "k4-columns__cell k4-columns__right",
230
+ ...f,
231
+ children: t
232
+ })
233
+ ]
234
+ });
235
+ }
236
+ //#endregion
237
+ //#region src/lib/layout/Container/Container.tsx
238
+ function Ve({ className: e, ...t }) {
239
+ return /* @__PURE__ */ D("div", {
240
+ className: L("k4-container", e),
241
+ ...t
242
+ });
243
+ }
244
+ //#endregion
245
+ //#region src/lib/layout/DashboardGrid/DashboardGrid.tsx
246
+ var He = S(4);
247
+ function Ue({ columns: e = 4, rowHeight: t = "7rem", className: n, style: r, children: i, ...a }) {
248
+ return /* @__PURE__ */ D(He.Provider, {
249
+ value: e,
250
+ children: /* @__PURE__ */ D("div", {
251
+ className: L("k4-dashboard-grid", n),
252
+ style: {
253
+ "--k4-grid-columns": e,
254
+ "--k4-grid-row-height": t,
255
+ ...r
256
+ },
257
+ ...a,
258
+ children: i
259
+ })
260
+ });
261
+ }
262
+ function We({ colSpan: e = 1, rowSpan: t = 1, className: n, style: r, children: i, ...a }) {
263
+ let o = C(He), s = Math.max(1, Math.min(e, o)), c = Math.max(1, t);
264
+ return /* @__PURE__ */ D("div", {
265
+ className: L("k4-dashboard-grid__item", n),
266
+ style: {
267
+ "--k4-grid-col-span": s,
268
+ "--k4-grid-row-span": c,
269
+ ...r
270
+ },
271
+ ...a,
272
+ children: i
273
+ });
274
+ }
275
+ //#endregion
276
+ //#region src/lib/layout/FillHeight/FillHeight.tsx
277
+ function Ge({ className: e, ...t }) {
278
+ return /* @__PURE__ */ D("div", {
279
+ className: L("k4-fill-height", e),
280
+ ...t
281
+ });
282
+ }
283
+ //#endregion
284
+ //#region src/lib/layout/Footer/Footer.tsx
285
+ function Ke({ className: e, ...t }) {
286
+ return /* @__PURE__ */ D("footer", {
287
+ className: L("k4-footer", e),
288
+ ...t
289
+ });
290
+ }
291
+ //#endregion
292
+ //#region src/lib/layout/Header/Header.tsx
293
+ function qe({ start: e, end: t, condense: n, className: r, children: i, ...a }) {
294
+ return /* @__PURE__ */ O("header", {
295
+ className: L("k4-header", n && "k4-header--condense", r),
296
+ ...a,
297
+ children: [
298
+ e != null && /* @__PURE__ */ D("div", {
299
+ className: "k4-header__start",
300
+ children: e
301
+ }),
302
+ i != null && /* @__PURE__ */ D("div", {
303
+ className: "k4-header__center",
304
+ children: i
305
+ }),
306
+ t != null && /* @__PURE__ */ D("div", {
307
+ className: "k4-header__end",
308
+ children: t
309
+ })
310
+ ]
311
+ });
312
+ }
313
+ //#endregion
314
+ //#region src/lib/layout/SideBar/SideBar.tsx
315
+ function z({ items: e }) {
316
+ return e.length ? /* @__PURE__ */ D("aside", {
317
+ className: "k4-sidebar",
318
+ children: /* @__PURE__ */ D("nav", { children: /* @__PURE__ */ D("ul", { children: e.map((e, t) => /* @__PURE__ */ D(B, { item: e }, V(e, t))) }) })
319
+ }) : null;
320
+ }
321
+ function B({ item: e }) {
322
+ switch (e.kind) {
323
+ case "item": return /* @__PURE__ */ D(Je, { item: e });
324
+ case "group": return /* @__PURE__ */ D(Ye, { item: e });
325
+ case "separator": return /* @__PURE__ */ D(Xe, {});
326
+ case "content": return /* @__PURE__ */ D(Ze, { children: e.content });
327
+ }
328
+ }
329
+ function Je({ item: e }) {
330
+ return /* @__PURE__ */ O("li", { children: [/* @__PURE__ */ D(t, {
331
+ to: e.path,
332
+ end: !e.children?.length,
333
+ className: ({ isActive: e }) => L("k4-sidebar__link", e && "k4-sidebar__link--active"),
334
+ children: /* @__PURE__ */ D("span", {
335
+ className: "k4-sidebar__label",
336
+ children: e.label
337
+ })
338
+ }), e.children?.length ? /* @__PURE__ */ D("ul", {
339
+ className: "k4-sidebar__children",
340
+ children: e.children.map((e, t) => /* @__PURE__ */ D(B, { item: e }, V(e, t)))
341
+ }) : null] });
342
+ }
343
+ function Ye({ item: e }) {
344
+ return /* @__PURE__ */ O("li", {
345
+ className: "k4-sidebar__group",
346
+ children: [/* @__PURE__ */ D("span", {
347
+ className: "k4-sidebar__group-label",
348
+ children: e.label
349
+ }), /* @__PURE__ */ D("ul", { children: e.items.map((e, t) => /* @__PURE__ */ D(B, { item: e }, V(e, t))) })]
350
+ });
351
+ }
352
+ function Xe() {
353
+ return /* @__PURE__ */ D("li", {
354
+ className: "k4-sidebar__separator",
355
+ role: "separator"
356
+ });
357
+ }
358
+ function Ze({ children: e }) {
359
+ return /* @__PURE__ */ D("li", {
360
+ className: "k4-sidebar__content",
361
+ children: e
362
+ });
363
+ }
364
+ function V(e, t) {
365
+ return e.kind === "item" ? e.path : e.kind === "group" ? `group-${e.label}` : `${e.kind}-${t}`;
366
+ }
367
+ //#endregion
368
+ //#region src/lib/layout/SiteLayout/SiteLayout.tsx
369
+ function Qe({ header: e, footer: t, mainId: n = "main", maxWidth: r = "default", className: i, children: a, ...o }) {
370
+ let s = r !== "full", c = s && r !== "default" ? { "--k4-site-width": r } : void 0;
371
+ return /* @__PURE__ */ O("div", {
372
+ className: L("k4-site-layout", i),
373
+ ...o,
374
+ children: [
375
+ e != null && /* @__PURE__ */ D("div", {
376
+ className: "k4-site-layout__header",
377
+ children: e
378
+ }),
379
+ /* @__PURE__ */ D("main", {
380
+ id: n,
381
+ className: L("k4-site-layout__content", s && "k4-site-layout__content--constrained"),
382
+ style: c,
383
+ children: a
384
+ }),
385
+ t != null && /* @__PURE__ */ D("div", {
386
+ className: "k4-site-layout__footer",
387
+ children: t
388
+ })
389
+ ]
390
+ });
391
+ }
392
+ //#endregion
393
+ //#region src/lib/layout/SkipLink/SkipLink.tsx
394
+ function $e({ targetId: e = "main", className: t, children: n, ...r }) {
395
+ return /* @__PURE__ */ D("a", {
396
+ href: `#${e}`,
397
+ className: L("k4-skip-link", t),
398
+ ...r,
399
+ children: n ?? "Skip to main content"
400
+ });
401
+ }
402
+ //#endregion
403
+ //#region src/lib/ui/Button/Button.tsx
404
+ var H = k("k4-button", {
405
+ variants: {
406
+ variant: {
407
+ default: "k4-button--default",
408
+ primary: "k4-button--primary",
409
+ secondary: "k4-button--secondary",
410
+ destructive: "k4-button--destructive",
411
+ success: "k4-button--success",
412
+ ghost: "k4-button--ghost",
413
+ link: "k4-button--link"
414
+ },
415
+ appearance: {
416
+ filled: "",
417
+ outline: "k4-button--outline"
418
+ },
419
+ size: {
420
+ default: "k4-button--size-default",
421
+ sm: "k4-button--size-sm",
422
+ lg: "k4-button--size-lg",
423
+ icon: "k4-button--size-icon"
424
+ }
425
+ },
426
+ defaultVariants: {
427
+ variant: "default",
428
+ appearance: "filled",
429
+ size: "default"
430
+ }
431
+ });
432
+ function U({ className: e, variant: t, appearance: n, size: r, asChild: i = !1, ...a }) {
433
+ return /* @__PURE__ */ D(i ? v.Root : "button", {
434
+ className: L(H({
435
+ variant: t,
436
+ appearance: n,
437
+ size: r
438
+ }), e),
439
+ ...a
440
+ });
441
+ }
442
+ //#endregion
443
+ //#region src/lib/ui/Sheet/Sheet.tsx
444
+ var W = p.Root, G = p.Trigger, et = p.Close, K = p.Portal;
445
+ function tt({ className: e, ...t }) {
446
+ return /* @__PURE__ */ D(p.Overlay, {
447
+ className: L("k4-sheet__overlay", e),
448
+ ...t
449
+ });
450
+ }
451
+ function nt({ className: e, children: t, side: n = "right", ...r }) {
452
+ return /* @__PURE__ */ O(K, { children: [/* @__PURE__ */ D(tt, {}), /* @__PURE__ */ O(p.Content, {
453
+ className: L("k4-sheet__content", `k4-sheet__content--${n}`, e),
454
+ ...r,
455
+ children: [t, /* @__PURE__ */ O(p.Close, {
456
+ className: "k4-sheet__close",
457
+ children: [/* @__PURE__ */ D(M, {}), /* @__PURE__ */ D("span", {
458
+ className: "k4-sr-only",
459
+ children: "Close"
460
+ })]
461
+ })]
462
+ })] });
463
+ }
464
+ function rt({ className: e, ...t }) {
465
+ return /* @__PURE__ */ D("div", {
466
+ className: L("k4-sheet__header", e),
467
+ ...t
468
+ });
469
+ }
470
+ function it({ className: e, ...t }) {
471
+ return /* @__PURE__ */ D("div", {
472
+ className: L("k4-sheet__footer", e),
473
+ ...t
474
+ });
475
+ }
476
+ function at({ className: e, ...t }) {
477
+ return /* @__PURE__ */ D(p.Title, {
478
+ className: L("k4-sheet__title", e),
479
+ ...t
480
+ });
481
+ }
482
+ function ot({ className: e, ...t }) {
483
+ return /* @__PURE__ */ D(p.Description, {
484
+ className: L("k4-sheet__description", e),
485
+ ...t
486
+ });
487
+ }
488
+ //#endregion
489
+ //#region src/lib/layout/TopBar/TopBar.tsx
490
+ var st = "not all";
491
+ function ct({ items: e, brand: n, end: r, mobileMenu: i, mobileQuery: a = "(max-width: 768px)" }) {
492
+ let o = oe(null), [s, c] = E(!1), l = Ie(a ?? st);
493
+ ae(() => {
494
+ let e = o.current;
495
+ if (!e) return;
496
+ let t = () => c(e.scrollWidth > e.clientWidth + 1);
497
+ t();
498
+ let n = new ResizeObserver(t);
499
+ return n.observe(e), () => n.disconnect();
500
+ }, [e]);
501
+ let u = l || s;
502
+ return /* @__PURE__ */ O("header", {
503
+ className: "k4-topbar",
504
+ children: [
505
+ u ? /* @__PURE__ */ D(lt, { items: i ?? e }) : null,
506
+ n,
507
+ /* @__PURE__ */ D("nav", {
508
+ ref: o,
509
+ className: L("k4-topbar__nav", u && "k4-topbar__nav--collapsed"),
510
+ inert: u,
511
+ children: e.map((e) => e.kind === "item" ? /* @__PURE__ */ D(t, {
512
+ to: e.path,
513
+ end: e.path === "/",
514
+ className: ({ isActive: e }) => L("k4-topbar__link", e && "k4-topbar__link--active"),
515
+ children: e.label
516
+ }, e.path) : null)
517
+ }),
518
+ /* @__PURE__ */ D("div", {
519
+ className: "k4-topbar__end",
520
+ children: r
521
+ })
522
+ ]
523
+ });
524
+ }
525
+ function lt({ items: e }) {
526
+ let [t, n] = E(!1);
527
+ return /* @__PURE__ */ O(W, {
528
+ open: t,
529
+ onOpenChange: n,
530
+ children: [/* @__PURE__ */ D(G, {
531
+ asChild: !0,
532
+ children: /* @__PURE__ */ D(U, {
533
+ variant: "ghost",
534
+ size: "icon",
535
+ className: "k4-topbar__burger",
536
+ "aria-label": "Open navigation menu",
537
+ children: /* @__PURE__ */ D(ye, {})
538
+ })
539
+ }), /* @__PURE__ */ O(nt, {
540
+ side: "left",
541
+ className: "k4-topbar__drawer",
542
+ children: [/* @__PURE__ */ D(rt, { children: /* @__PURE__ */ D(at, { children: "Navigation" }) }), /* @__PURE__ */ D("div", {
543
+ className: "k4-topbar__drawer-nav",
544
+ onClick: (e) => {
545
+ e.target.closest("a") && n(!1);
546
+ },
547
+ children: /* @__PURE__ */ D(z, { items: e })
548
+ })]
549
+ })]
550
+ });
551
+ }
552
+ //#endregion
553
+ //#region src/lib/query/sort.ts
554
+ var ut = /* @__PURE__ */ function(e) {
555
+ return e.Asc = "ASC", e.Desc = "DESC", e;
556
+ }({}), dt = k("k4-alert", {
557
+ variants: {
558
+ variant: {
559
+ default: "k4-alert--default",
560
+ primary: "k4-alert--primary",
561
+ secondary: "k4-alert--secondary",
562
+ destructive: "k4-alert--destructive",
563
+ success: "k4-alert--success"
564
+ },
565
+ appearance: {
566
+ filled: "",
567
+ outline: "k4-alert--outline"
568
+ }
569
+ },
570
+ defaultVariants: {
571
+ variant: "default",
572
+ appearance: "filled"
573
+ }
574
+ });
575
+ function ft({ className: e, variant: t, appearance: n, ...r }) {
576
+ return /* @__PURE__ */ D("div", {
577
+ role: "alert",
578
+ className: L(dt({
579
+ variant: t,
580
+ appearance: n
581
+ }), e),
582
+ ...r
583
+ });
584
+ }
585
+ function pt({ className: e, ...t }) {
586
+ return /* @__PURE__ */ D("div", {
587
+ className: L("k4-alert__title", e),
588
+ ...t
589
+ });
590
+ }
591
+ function mt({ className: e, ...t }) {
592
+ return /* @__PURE__ */ D("div", {
593
+ className: L("k4-alert__description", e),
594
+ ...t
595
+ });
596
+ }
597
+ //#endregion
598
+ //#region src/lib/ui/ErrorBlock/ErrorBlock.tsx
599
+ function ht({ error: e, onRetry: t }) {
600
+ let n = I(e);
601
+ return /* @__PURE__ */ O("span", {
602
+ className: "k4-error-inline",
603
+ children: [/* @__PURE__ */ O("span", {
604
+ className: "k4-error-inline__message",
605
+ children: [n.code && /* @__PURE__ */ O("strong", { children: [n.code, ": "] }), n.message]
606
+ }), t && /* @__PURE__ */ D("button", {
607
+ type: "button",
608
+ className: "k4-error-inline__retry",
609
+ onClick: t,
610
+ children: "retry"
611
+ })]
612
+ });
613
+ }
614
+ function q({ error: e, title: t, onRetry: n }) {
615
+ let r = I(e);
616
+ return /* @__PURE__ */ O(ft, {
617
+ variant: "destructive",
618
+ className: "k4-error-block",
619
+ children: [
620
+ /* @__PURE__ */ D(fe, {}),
621
+ /* @__PURE__ */ D(pt, { children: t ?? gt(r) }),
622
+ /* @__PURE__ */ O(mt, { children: [
623
+ /* @__PURE__ */ D("p", { children: r.message }),
624
+ r.details ? /* @__PURE__ */ D("pre", {
625
+ className: "k4-error-block__details",
626
+ children: typeof r.details == "string" ? r.details : JSON.stringify(r.details, null, 2)
627
+ }) : null,
628
+ n && /* @__PURE__ */ D(U, {
629
+ size: "sm",
630
+ className: "k4-error-block__retry",
631
+ onClick: n,
632
+ children: "Try again"
633
+ })
634
+ ] })
635
+ ]
636
+ });
637
+ }
638
+ function gt(e) {
639
+ return e.code ? `Error ${e.code}` : "Something went wrong";
640
+ }
641
+ //#endregion
642
+ //#region src/lib/router/DefaultErrorBoundary.tsx
643
+ function J() {
644
+ return /* @__PURE__ */ D(q, { error: s() });
645
+ }
646
+ //#endregion
647
+ //#region src/lib/internal/registry.ts
648
+ var _t = /* @__PURE__ */ new WeakMap();
649
+ function vt(e, t) {
650
+ _t.set(e, t);
651
+ }
652
+ function yt(e) {
653
+ let t = _t.get(e);
654
+ if (t === void 0) {
655
+ let t = e.path ?? e.menu?.label ?? "(anonymous)";
656
+ throw Error(`Route "${t}" has not been registered. Did you pass it to buildRouterConfig()?`);
657
+ }
658
+ return t;
659
+ }
660
+ //#endregion
661
+ //#region src/lib/ui/Spinner/Spinner.tsx
662
+ function bt({ className: e, ...t }) {
663
+ return /* @__PURE__ */ D(_e, {
664
+ role: "status",
665
+ "aria-label": "Loading",
666
+ className: L("k4-spinner", e),
667
+ ...t
668
+ });
669
+ }
670
+ function xt({ label: e, vertical: t }) {
671
+ return /* @__PURE__ */ O("span", {
672
+ className: L("k4-dots-spinner", t && "k4-dots-spinner--vertical"),
673
+ children: [/* @__PURE__ */ O("span", {
674
+ className: "k4-dots-spinner__dots",
675
+ children: [
676
+ /* @__PURE__ */ D("span", { className: "k4-dots-spinner__dot" }),
677
+ /* @__PURE__ */ D("span", { className: "k4-dots-spinner__dot" }),
678
+ /* @__PURE__ */ D("span", { className: "k4-dots-spinner__dot" })
679
+ ]
680
+ }), e && /* @__PURE__ */ D("span", {
681
+ className: "k4-dots-spinner__label",
682
+ children: e
683
+ })]
684
+ });
685
+ }
686
+ function St({ label: e = "Loading…" }) {
687
+ return /* @__PURE__ */ D("div", {
688
+ className: "k4-spinner-block",
689
+ children: /* @__PURE__ */ D(xt, {
690
+ label: e,
691
+ vertical: !0
692
+ })
693
+ });
694
+ }
695
+ function Ct() {
696
+ return /* @__PURE__ */ D(St, { label: "Loading application…" });
697
+ }
698
+ //#endregion
699
+ //#region src/lib/router/adapter.ts
700
+ function wt(e, t) {
701
+ if (!t) return e;
702
+ let n = e.endsWith("/") ? e.slice(0, -1) : e, r = t.startsWith("/") ? t.slice(1) : t;
703
+ return n ? `${n}/${r}` : `/${r}`;
704
+ }
705
+ function Tt(e, t) {
706
+ let n = e.loader;
707
+ if (n) return async ({ params: r, request: i }) => {
708
+ let a = r;
709
+ if (e.params) {
710
+ let t = e.params.safeParse(r);
711
+ if (!t.success) throw new Response(t.error.message, {
712
+ status: 400,
713
+ statusText: "Invalid path parameters"
714
+ });
715
+ a = t.data;
716
+ }
717
+ let o = {};
718
+ if (e.search) {
719
+ let t = new URL(i.url), n = Object.fromEntries(t.searchParams.entries()), r = e.search.safeParse(n);
720
+ if (!r.success) throw new Response(r.error.message, {
721
+ status: 400,
722
+ statusText: "Invalid search parameters"
723
+ });
724
+ o = r.data;
725
+ }
726
+ return n({
727
+ params: a,
728
+ search: o,
729
+ request: i,
730
+ context: t
731
+ });
732
+ };
733
+ }
734
+ function Et(e, t, n) {
735
+ let r = e.index || !e.path ? t : wt(t, e.path);
736
+ vt(e, r);
737
+ let i = e.component, a = e.errorBoundary ?? J, o = Tt(e, n), s = e.children?.map((e) => Et(e, r, n));
738
+ return e.index ? {
739
+ index: !0,
740
+ Component: i,
741
+ ErrorBoundary: a,
742
+ loader: o
743
+ } : {
744
+ ...e.path != null && { path: e.path },
745
+ Component: i,
746
+ ErrorBoundary: a,
747
+ loader: o,
748
+ children: s
749
+ };
750
+ }
751
+ function Dt(e, t, n = {}) {
752
+ return [{
753
+ HydrateFallback: n.hydrateFallback ?? Ct,
754
+ ErrorBoundary: n.errorBoundary ?? J,
755
+ children: e.map((e) => Et(e, "/", t))
756
+ }];
757
+ }
758
+ //#endregion
759
+ //#region src/lib/router/chain.ts
760
+ var Ot = class e {
761
+ steps;
762
+ constructor(e = []) {
763
+ this.steps = e;
764
+ }
765
+ use(t) {
766
+ return new e([...this.steps, t]);
767
+ }
768
+ build() {
769
+ let e = this.steps;
770
+ return async (t) => {
771
+ let n = {};
772
+ for (let r of e) {
773
+ let e = await r({
774
+ ...t,
775
+ data: n
776
+ });
777
+ typeof e == "object" && e && (n = {
778
+ ...n,
779
+ ...e
780
+ });
781
+ }
782
+ return n;
783
+ };
784
+ }
785
+ };
786
+ function kt() {
787
+ return new Ot();
788
+ }
789
+ //#endregion
790
+ //#region src/lib/router/createAppRouter.ts
791
+ function At(e, t, r) {
792
+ return n(Dt(e, t, r));
793
+ }
794
+ //#endregion
795
+ //#region src/lib/router/defineRoute.ts
796
+ function jt(e) {
797
+ return e;
798
+ }
799
+ //#endregion
800
+ //#region src/lib/router/menu.ts
801
+ function Mt(e) {
802
+ return typeof e == "object" && "route" in e;
803
+ }
804
+ function Nt(e) {
805
+ return typeof e == "object" && "group" in e;
806
+ }
807
+ function Y(e) {
808
+ return e.map((e) => {
809
+ if (Mt(e)) {
810
+ let t = yt(e.route);
811
+ return {
812
+ kind: "item",
813
+ label: e.label ?? e.route.menu?.label ?? t,
814
+ icon: e.icon ?? e.route.menu?.icon,
815
+ path: t,
816
+ children: e.children?.length ? Y(e.children) : void 0
817
+ };
818
+ }
819
+ return Nt(e) ? {
820
+ kind: "group",
821
+ label: e.group,
822
+ items: Y(e.children)
823
+ } : e === "separator" ? { kind: "separator" } : {
824
+ kind: "content",
825
+ content: e.content
826
+ };
827
+ });
828
+ }
829
+ function Pt(e, t) {
830
+ let n, r = -1;
831
+ for (let i of e) i.kind === "item" && Ft(i, t) && i.path.length > r && (n = i, r = i.path.length);
832
+ return n;
833
+ }
834
+ function Ft(e, t) {
835
+ return It(e.path, t) ? !0 : e.children?.some((e) => e.kind === "item" && Ft(e, t)) ?? !1;
836
+ }
837
+ function It(e, t) {
838
+ return e === "/" ? t === "/" : t === e || t.startsWith(e + "/");
839
+ }
840
+ //#endregion
841
+ //#region src/lib/internal/env.ts
842
+ var Lt = !1;
843
+ //#endregion
844
+ //#region src/lib/router/pathTo.ts
845
+ function Rt(e, ...t) {
846
+ let n = yt(e), r = t[0] ?? {}, i = n;
847
+ if (r.params) for (let [e, t] of Object.entries(r.params)) i = i.replace(`:${e}`, encodeURIComponent(String(t)));
848
+ if (r.search && e.search) {
849
+ let t = e.search.safeParse(r.search);
850
+ if (!t.success && Lt && console.warn(`pathTo(): search params for "${n}" failed to parse and were dropped.`, t.error), t.success) {
851
+ let e = new URLSearchParams();
852
+ for (let [n, r] of Object.entries(t.data)) if (r != null) if (Array.isArray(r)) for (let t of r) e.append(n, String(t));
853
+ else e.set(n, String(r));
854
+ let n = e.toString();
855
+ n && (i += `?${n}`);
856
+ }
857
+ }
858
+ return i;
859
+ }
860
+ //#endregion
861
+ //#region src/lib/router/TypedLink/TypedLink.tsx
862
+ function zt(t) {
863
+ let { route: n, params: r, search: i, ...a } = t;
864
+ return /* @__PURE__ */ D(e, {
865
+ to: Rt(n, {
866
+ params: r,
867
+ search: i
868
+ }),
869
+ ...a
870
+ });
871
+ }
872
+ //#endregion
873
+ //#region src/lib/router/useRoute.ts
874
+ function Bt(e) {
875
+ let t = o(), [n] = c(), r = a();
876
+ return {
877
+ params: T(() => {
878
+ if (!e.params) return t;
879
+ let n = e.params.safeParse(t);
880
+ return n.success ? n.data : t;
881
+ }, [t, e.params]),
882
+ search: T(() => {
883
+ if (!e.search) return {};
884
+ let t = Object.fromEntries(n.entries()), r = e.search.safeParse(t);
885
+ return r.success ? r.data : {};
886
+ }, [n, e.search]),
887
+ data: r
888
+ };
889
+ }
890
+ //#endregion
891
+ //#region src/lib/ui/DropdownMenu/DropdownMenu.tsx
892
+ var Vt = m.Root, Ht = m.Portal, Ut = m.Trigger, Wt = m.Group, Gt = m.RadioGroup, Kt = m.Sub;
893
+ function qt({ className: e, sideOffset: t = 4, ...n }) {
894
+ return /* @__PURE__ */ D(m.Portal, { children: /* @__PURE__ */ D(m.Content, {
895
+ sideOffset: t,
896
+ className: L("k4-dropdown-menu__content", e),
897
+ ...n
898
+ }) });
899
+ }
900
+ function X({ className: e, inset: t, variant: n = "default", ...r }) {
901
+ return /* @__PURE__ */ D(m.Item, {
902
+ className: L("k4-dropdown-menu__item", t && "k4-dropdown-menu__item--inset", n === "destructive" && "k4-dropdown-menu__item--destructive", e),
903
+ ...r
904
+ });
905
+ }
906
+ function Jt({ className: e, children: t, checked: n, ...r }) {
907
+ return /* @__PURE__ */ O(m.CheckboxItem, {
908
+ className: L("k4-dropdown-menu__checkbox-item", e),
909
+ checked: n,
910
+ ...r,
911
+ children: [/* @__PURE__ */ D("span", {
912
+ className: "k4-dropdown-menu__indicator",
913
+ children: /* @__PURE__ */ D(m.ItemIndicator, { children: /* @__PURE__ */ D(A, {}) })
914
+ }), t]
915
+ });
916
+ }
917
+ function Yt({ className: e, children: t, ...n }) {
918
+ return /* @__PURE__ */ O(m.RadioItem, {
919
+ className: L("k4-dropdown-menu__radio-item", e),
920
+ ...n,
921
+ children: [/* @__PURE__ */ D("span", {
922
+ className: "k4-dropdown-menu__indicator",
923
+ children: /* @__PURE__ */ D(m.ItemIndicator, { children: /* @__PURE__ */ D(ge, { className: "k4-dropdown-menu__radio-dot" }) })
924
+ }), t]
925
+ });
926
+ }
927
+ function Xt({ className: e, inset: t, ...n }) {
928
+ return /* @__PURE__ */ D(m.Label, {
929
+ className: L("k4-dropdown-menu__label", t && "k4-dropdown-menu__label--inset", e),
930
+ ...n
931
+ });
932
+ }
933
+ function Zt({ className: e, ...t }) {
934
+ return /* @__PURE__ */ D(m.Separator, {
935
+ className: L("k4-dropdown-menu__separator", e),
936
+ ...t
937
+ });
938
+ }
939
+ function Qt({ className: e, ...t }) {
940
+ return /* @__PURE__ */ D("span", {
941
+ className: L("k4-dropdown-menu__shortcut", e),
942
+ ...t
943
+ });
944
+ }
945
+ function $t({ className: e, inset: t, children: n, ...r }) {
946
+ return /* @__PURE__ */ O(m.SubTrigger, {
947
+ className: L("k4-dropdown-menu__sub-trigger", t && "k4-dropdown-menu__sub-trigger--inset", e),
948
+ ...r,
949
+ children: [n, /* @__PURE__ */ D(me, { className: "k4-dropdown-menu__sub-chevron" })]
950
+ });
951
+ }
952
+ function en({ className: e, ...t }) {
953
+ return /* @__PURE__ */ D(m.SubContent, {
954
+ className: L("k4-dropdown-menu__sub-content", e),
955
+ ...t
956
+ });
957
+ }
958
+ //#endregion
959
+ //#region src/lib/theme/ThemeProvider/ThemeProvider.tsx
960
+ var tn = S(void 0), nn = () => typeof window < "u" && window.matchMedia("(prefers-color-scheme: dark)").matches;
961
+ function rn(e) {
962
+ return e === "system" ? nn() ? "dark" : "light" : e;
963
+ }
964
+ function an({ children: e, defaultMode: t = "system", storageKey: n = "k4-ui-theme" }) {
965
+ let [r, i] = E(() => {
966
+ if (typeof window > "u") return t;
967
+ let e = window.localStorage.getItem(n);
968
+ return e === "light" || e === "dark" || e === "system" ? e : t;
969
+ }), [a, o] = E(() => rn(r));
970
+ w(() => {
971
+ let e = () => {
972
+ let e = rn(r);
973
+ o(e), document.documentElement.classList.toggle("dark", e === "dark");
974
+ };
975
+ if (e(), r !== "system") return;
976
+ let t = window.matchMedia("(prefers-color-scheme: dark)");
977
+ return t.addEventListener("change", e), () => t.removeEventListener("change", e);
978
+ }, [r]);
979
+ let s = re((e) => {
980
+ window.localStorage.setItem(n, e), i(e);
981
+ }, [n]), c = T(() => ({
982
+ mode: r,
983
+ resolvedMode: a,
984
+ setMode: s
985
+ }), [
986
+ r,
987
+ a,
988
+ s
989
+ ]);
990
+ return /* @__PURE__ */ D(tn.Provider, {
991
+ value: c,
992
+ children: e
993
+ });
994
+ }
995
+ function Z() {
996
+ let e = C(tn);
997
+ if (!e) throw Error("useTheme must be used inside <ThemeProvider>");
998
+ return e;
999
+ }
1000
+ //#endregion
1001
+ //#region src/lib/theme/ModeToggle/ModeToggle.tsx
1002
+ function on() {
1003
+ let { setMode: e } = Z();
1004
+ return /* @__PURE__ */ O(Vt, { children: [/* @__PURE__ */ D(Ut, {
1005
+ asChild: !0,
1006
+ children: /* @__PURE__ */ O(U, {
1007
+ appearance: "outline",
1008
+ size: "icon",
1009
+ className: "k4-mode-toggle",
1010
+ children: [
1011
+ /* @__PURE__ */ D(we, { className: "k4-mode-toggle__sun" }),
1012
+ /* @__PURE__ */ D(be, { className: "k4-mode-toggle__moon" }),
1013
+ /* @__PURE__ */ D("span", {
1014
+ className: "k4-sr-only",
1015
+ children: "Toggle theme"
1016
+ })
1017
+ ]
1018
+ })
1019
+ }), /* @__PURE__ */ O(qt, {
1020
+ align: "end",
1021
+ children: [
1022
+ /* @__PURE__ */ D(X, {
1023
+ onClick: () => e("light"),
1024
+ children: "Light"
1025
+ }),
1026
+ /* @__PURE__ */ D(X, {
1027
+ onClick: () => e("dark"),
1028
+ children: "Dark"
1029
+ }),
1030
+ /* @__PURE__ */ D(X, {
1031
+ onClick: () => e("system"),
1032
+ children: "System"
1033
+ })
1034
+ ]
1035
+ })] });
1036
+ }
1037
+ //#endregion
1038
+ //#region src/lib/theme/Toaster/Toaster.tsx
1039
+ function sn(e) {
1040
+ let { resolvedMode: t } = Z();
1041
+ return /* @__PURE__ */ D(Te, {
1042
+ theme: t,
1043
+ richColors: !0,
1044
+ className: "k4-toaster",
1045
+ ...e
1046
+ });
1047
+ }
1048
+ //#endregion
1049
+ //#region src/lib/theme/Toaster/toast.tsx
1050
+ function cn(e, t) {
1051
+ return (n, r = {}) => {
1052
+ let { appearance: i = "filled", className: a, ...o } = r, s = "icon" in r ? r.icon : t;
1053
+ return N(n, {
1054
+ ...o,
1055
+ icon: s,
1056
+ className: [
1057
+ e,
1058
+ i === "outline" && "k4-toast--outline",
1059
+ a
1060
+ ].filter(Boolean).join(" ")
1061
+ });
1062
+ };
1063
+ }
1064
+ var ln = Object.assign((e, t) => N(e, t), N, {
1065
+ primary: cn("k4-toast--primary", /* @__PURE__ */ D(ve, {})),
1066
+ secondary: cn("k4-toast--secondary", /* @__PURE__ */ D(Ce, {}))
1067
+ }), un = l.Root;
1068
+ function dn({ className: e, ...t }) {
1069
+ return /* @__PURE__ */ D(l.Item, {
1070
+ className: L("k4-accordion__item", e),
1071
+ ...t
1072
+ });
1073
+ }
1074
+ function fn({ className: e, children: t, ...n }) {
1075
+ return /* @__PURE__ */ D(l.Header, {
1076
+ className: "k4-accordion__header",
1077
+ children: /* @__PURE__ */ O(l.Trigger, {
1078
+ className: L("k4-accordion__trigger", e),
1079
+ ...n,
1080
+ children: [t, /* @__PURE__ */ D(j, { className: "k4-accordion__chevron" })]
1081
+ })
1082
+ });
1083
+ }
1084
+ function pn({ className: e, children: t, ...n }) {
1085
+ return /* @__PURE__ */ D(l.Content, {
1086
+ className: "k4-accordion__content",
1087
+ ...n,
1088
+ children: /* @__PURE__ */ D("div", {
1089
+ className: L("k4-accordion__content-inner", e),
1090
+ children: t
1091
+ })
1092
+ });
1093
+ }
1094
+ //#endregion
1095
+ //#region src/lib/ui/AlertDialog/AlertDialog.tsx
1096
+ var mn = u.Root, hn = u.Trigger, gn = u.Portal;
1097
+ function _n({ className: e, ...t }) {
1098
+ return /* @__PURE__ */ D(u.Overlay, {
1099
+ className: L("k4-alert-dialog__overlay", e),
1100
+ ...t
1101
+ });
1102
+ }
1103
+ function vn({ className: e, ...t }) {
1104
+ return /* @__PURE__ */ O(gn, { children: [/* @__PURE__ */ D(_n, {}), /* @__PURE__ */ D(u.Content, {
1105
+ className: L("k4-alert-dialog__content", e),
1106
+ ...t
1107
+ })] });
1108
+ }
1109
+ function yn({ className: e, ...t }) {
1110
+ return /* @__PURE__ */ D("div", {
1111
+ className: L("k4-alert-dialog__header", e),
1112
+ ...t
1113
+ });
1114
+ }
1115
+ function bn({ className: e, ...t }) {
1116
+ return /* @__PURE__ */ D("div", {
1117
+ className: L("k4-alert-dialog__footer", e),
1118
+ ...t
1119
+ });
1120
+ }
1121
+ function xn({ className: e, ...t }) {
1122
+ return /* @__PURE__ */ D(u.Title, {
1123
+ className: L("k4-alert-dialog__title", e),
1124
+ ...t
1125
+ });
1126
+ }
1127
+ function Sn({ className: e, ...t }) {
1128
+ return /* @__PURE__ */ D(u.Description, {
1129
+ className: L("k4-alert-dialog__description", e),
1130
+ ...t
1131
+ });
1132
+ }
1133
+ function Cn({ className: e, variant: t, appearance: n, size: r, ...i }) {
1134
+ return /* @__PURE__ */ D(u.Action, {
1135
+ className: L(H({
1136
+ variant: t,
1137
+ appearance: n,
1138
+ size: r
1139
+ }), e),
1140
+ ...i
1141
+ });
1142
+ }
1143
+ function wn({ className: e, variant: t, appearance: n = "outline", size: r, ...i }) {
1144
+ return /* @__PURE__ */ D(u.Cancel, {
1145
+ className: L(H({
1146
+ variant: t,
1147
+ appearance: n,
1148
+ size: r
1149
+ }), e),
1150
+ ...i
1151
+ });
1152
+ }
1153
+ //#endregion
1154
+ //#region src/lib/ui/Avatar/Avatar.tsx
1155
+ function Tn({ className: e, ...t }) {
1156
+ return /* @__PURE__ */ D(d.Root, {
1157
+ className: L("k4-avatar", e),
1158
+ ...t
1159
+ });
1160
+ }
1161
+ function En({ className: e, ...t }) {
1162
+ return /* @__PURE__ */ D(d.Image, {
1163
+ className: L("k4-avatar__image", e),
1164
+ ...t
1165
+ });
1166
+ }
1167
+ function Dn({ className: e, ...t }) {
1168
+ return /* @__PURE__ */ D(d.Fallback, {
1169
+ className: L("k4-avatar__fallback", e),
1170
+ ...t
1171
+ });
1172
+ }
1173
+ //#endregion
1174
+ //#region src/lib/ui/AwaitErrorBlock/AwaitErrorBlock.tsx
1175
+ function On({ title: e }) {
1176
+ return /* @__PURE__ */ D(q, {
1177
+ error: i(),
1178
+ title: e
1179
+ });
1180
+ }
1181
+ //#endregion
1182
+ //#region src/lib/ui/Badge/Badge.tsx
1183
+ var kn = k("k4-badge", {
1184
+ variants: { variant: {
1185
+ default: "k4-badge--default",
1186
+ secondary: "k4-badge--secondary",
1187
+ destructive: "k4-badge--destructive",
1188
+ success: "k4-badge--success",
1189
+ outline: "k4-badge--outline"
1190
+ } },
1191
+ defaultVariants: { variant: "default" }
1192
+ });
1193
+ function An({ className: e, variant: t, asChild: n = !1, ...r }) {
1194
+ return /* @__PURE__ */ D(n ? v.Root : "span", {
1195
+ className: L(kn({ variant: t }), e),
1196
+ ...r
1197
+ });
1198
+ }
1199
+ //#endregion
1200
+ //#region src/lib/ui/Card/Card.tsx
1201
+ function jn({ className: e, ...t }) {
1202
+ return /* @__PURE__ */ D("div", {
1203
+ className: L("k4-card", e),
1204
+ ...t
1205
+ });
1206
+ }
1207
+ function Mn({ className: e, ...t }) {
1208
+ return /* @__PURE__ */ D("div", {
1209
+ className: L("k4-card__header", e),
1210
+ ...t
1211
+ });
1212
+ }
1213
+ function Nn({ className: e, ...t }) {
1214
+ return /* @__PURE__ */ D("div", {
1215
+ className: L("k4-card__title", e),
1216
+ ...t
1217
+ });
1218
+ }
1219
+ function Pn({ className: e, ...t }) {
1220
+ return /* @__PURE__ */ D("div", {
1221
+ className: L("k4-card__description", e),
1222
+ ...t
1223
+ });
1224
+ }
1225
+ function Fn({ className: e, ...t }) {
1226
+ return /* @__PURE__ */ D("div", {
1227
+ className: L("k4-card__action", e),
1228
+ ...t
1229
+ });
1230
+ }
1231
+ function In({ className: e, ...t }) {
1232
+ return /* @__PURE__ */ D("div", {
1233
+ className: L("k4-card__content", e),
1234
+ ...t
1235
+ });
1236
+ }
1237
+ function Ln({ className: e, ...t }) {
1238
+ return /* @__PURE__ */ D("div", {
1239
+ className: L("k4-card__footer", e),
1240
+ ...t
1241
+ });
1242
+ }
1243
+ //#endregion
1244
+ //#region src/lib/ui/Checkbox/Checkbox.tsx
1245
+ function Rn({ className: e, ...t }) {
1246
+ return /* @__PURE__ */ D(f.Root, {
1247
+ className: L("k4-checkbox", e),
1248
+ ...t,
1249
+ children: /* @__PURE__ */ D(f.Indicator, {
1250
+ className: "k4-checkbox__indicator",
1251
+ children: /* @__PURE__ */ D(A, {})
1252
+ })
1253
+ });
1254
+ }
1255
+ //#endregion
1256
+ //#region src/lib/ui/Dialog/Dialog.tsx
1257
+ var zn = p.Root, Bn = p.Trigger, Vn = p.Portal, Hn = p.Close;
1258
+ function Q({ className: e, ...t }) {
1259
+ return /* @__PURE__ */ D(p.Overlay, {
1260
+ className: L("k4-dialog__overlay", e),
1261
+ ...t
1262
+ });
1263
+ }
1264
+ function Un({ className: e, children: t, showCloseButton: n = !0, ...r }) {
1265
+ return /* @__PURE__ */ O(Vn, { children: [/* @__PURE__ */ D(Q, {}), /* @__PURE__ */ O(p.Content, {
1266
+ className: L("k4-dialog__content", e),
1267
+ ...r,
1268
+ children: [t, n && /* @__PURE__ */ O(p.Close, {
1269
+ className: "k4-dialog__close",
1270
+ children: [/* @__PURE__ */ D(M, {}), /* @__PURE__ */ D("span", {
1271
+ className: "k4-sr-only",
1272
+ children: "Close"
1273
+ })]
1274
+ })]
1275
+ })] });
1276
+ }
1277
+ function Wn({ className: e, ...t }) {
1278
+ return /* @__PURE__ */ D("div", {
1279
+ className: L("k4-dialog__header", e),
1280
+ ...t
1281
+ });
1282
+ }
1283
+ function Gn({ className: e, ...t }) {
1284
+ return /* @__PURE__ */ D("div", {
1285
+ className: L("k4-dialog__footer", e),
1286
+ ...t
1287
+ });
1288
+ }
1289
+ function Kn({ className: e, ...t }) {
1290
+ return /* @__PURE__ */ D(p.Title, {
1291
+ className: L("k4-dialog__title", e),
1292
+ ...t
1293
+ });
1294
+ }
1295
+ function qn({ className: e, ...t }) {
1296
+ return /* @__PURE__ */ D(p.Description, {
1297
+ className: L("k4-dialog__description", e),
1298
+ ...t
1299
+ });
1300
+ }
1301
+ //#endregion
1302
+ //#region src/lib/ui/Command/Command.tsx
1303
+ function Jn({ className: e, ...t }) {
1304
+ return /* @__PURE__ */ D(P, {
1305
+ className: L("k4-command", e),
1306
+ ...t
1307
+ });
1308
+ }
1309
+ function Yn({ title: e = "Command Palette", description: t = "Search for a command to run...", children: n, className: r, showCloseButton: i = !0, ...a }) {
1310
+ return /* @__PURE__ */ D(zn, {
1311
+ ...a,
1312
+ children: /* @__PURE__ */ O(Un, {
1313
+ className: L("k4-command__dialog-content", r),
1314
+ showCloseButton: i,
1315
+ children: [/* @__PURE__ */ O(Wn, {
1316
+ className: "k4-sr-only",
1317
+ children: [/* @__PURE__ */ D(Kn, { children: e }), /* @__PURE__ */ D(qn, { children: t })]
1318
+ }), /* @__PURE__ */ D(Jn, {
1319
+ className: "k4-command--dialog",
1320
+ children: n
1321
+ })]
1322
+ })
1323
+ });
1324
+ }
1325
+ function Xn({ className: e, ...t }) {
1326
+ return /* @__PURE__ */ O("div", {
1327
+ className: "k4-command__input-wrapper",
1328
+ children: [/* @__PURE__ */ D(Se, { className: "k4-command__search-icon" }), /* @__PURE__ */ D(P.Input, {
1329
+ className: L("k4-command__input", e),
1330
+ ...t
1331
+ })]
1332
+ });
1333
+ }
1334
+ function Zn({ className: e, ...t }) {
1335
+ return /* @__PURE__ */ D(P.List, {
1336
+ className: L("k4-command__list", e),
1337
+ ...t
1338
+ });
1339
+ }
1340
+ function Qn(e) {
1341
+ return /* @__PURE__ */ D(P.Empty, {
1342
+ className: "k4-command__empty",
1343
+ ...e
1344
+ });
1345
+ }
1346
+ function $n({ className: e, ...t }) {
1347
+ return /* @__PURE__ */ D(P.Group, {
1348
+ className: L("k4-command__group", e),
1349
+ ...t
1350
+ });
1351
+ }
1352
+ function er({ className: e, ...t }) {
1353
+ return /* @__PURE__ */ D(P.Separator, {
1354
+ className: L("k4-command__separator", e),
1355
+ ...t
1356
+ });
1357
+ }
1358
+ function tr({ className: e, ...t }) {
1359
+ return /* @__PURE__ */ D(P.Item, {
1360
+ className: L("k4-command__item", e),
1361
+ ...t
1362
+ });
1363
+ }
1364
+ function nr({ className: e, ...t }) {
1365
+ return /* @__PURE__ */ D("span", {
1366
+ className: L("k4-command__shortcut", e),
1367
+ ...t
1368
+ });
1369
+ }
1370
+ //#endregion
1371
+ //#region src/lib/ui/Input/Input.tsx
1372
+ function rr({ className: e, type: t, ...n }) {
1373
+ return /* @__PURE__ */ D("input", {
1374
+ type: t,
1375
+ className: L("k4-input", e),
1376
+ ...n
1377
+ });
1378
+ }
1379
+ //#endregion
1380
+ //#region src/lib/ui/Pagination/Pagination.tsx
1381
+ function ir({ className: e, ...t }) {
1382
+ return /* @__PURE__ */ D("nav", {
1383
+ role: "navigation",
1384
+ "aria-label": "pagination",
1385
+ className: L("k4-pagination", e),
1386
+ ...t
1387
+ });
1388
+ }
1389
+ function ar({ className: e, ...t }) {
1390
+ return /* @__PURE__ */ D("ul", {
1391
+ className: L("k4-pagination__content", e),
1392
+ ...t
1393
+ });
1394
+ }
1395
+ function or(e) {
1396
+ return /* @__PURE__ */ D("li", { ...e });
1397
+ }
1398
+ function $({ className: e, isActive: t, variant: n, size: r = "icon", ...i }) {
1399
+ return /* @__PURE__ */ D("a", {
1400
+ "aria-current": t ? "page" : void 0,
1401
+ className: L(H({
1402
+ variant: n ?? (t ? "default" : "ghost"),
1403
+ appearance: t ? "outline" : "filled",
1404
+ size: r
1405
+ }), e),
1406
+ ...i
1407
+ });
1408
+ }
1409
+ function sr({ className: e, ...t }) {
1410
+ return /* @__PURE__ */ O($, {
1411
+ "aria-label": "Go to previous page",
1412
+ size: "default",
1413
+ className: L("k4-pagination__nav", e),
1414
+ ...t,
1415
+ children: [/* @__PURE__ */ D(pe, {}), /* @__PURE__ */ D("span", { children: "Previous" })]
1416
+ });
1417
+ }
1418
+ function cr({ className: e, ...t }) {
1419
+ return /* @__PURE__ */ O($, {
1420
+ "aria-label": "Go to next page",
1421
+ size: "default",
1422
+ className: L("k4-pagination__nav", e),
1423
+ ...t,
1424
+ children: [/* @__PURE__ */ D("span", { children: "Next" }), /* @__PURE__ */ D(me, {})]
1425
+ });
1426
+ }
1427
+ function lr({ className: e, ...t }) {
1428
+ return /* @__PURE__ */ D("span", {
1429
+ "aria-hidden": !0,
1430
+ className: L("k4-pagination__ellipsis", e),
1431
+ ...t,
1432
+ children: /* @__PURE__ */ D(xe, {})
1433
+ });
1434
+ }
1435
+ //#endregion
1436
+ //#region src/lib/ui/Popover/Popover.tsx
1437
+ var ur = h.Root, dr = h.Trigger, fr = h.Anchor;
1438
+ function pr({ className: e, align: t = "center", sideOffset: n = 4, ...r }) {
1439
+ return /* @__PURE__ */ D(h.Portal, { children: /* @__PURE__ */ D(h.Content, {
1440
+ align: t,
1441
+ sideOffset: n,
1442
+ className: L("k4-popover__content", e),
1443
+ ...r
1444
+ }) });
1445
+ }
1446
+ //#endregion
1447
+ //#region src/lib/ui/Progress/Progress.tsx
1448
+ var mr = k("k4-progress", {
1449
+ variants: { variant: {
1450
+ default: "k4-progress--default",
1451
+ secondary: "k4-progress--secondary",
1452
+ destructive: "k4-progress--destructive",
1453
+ success: "k4-progress--success"
1454
+ } },
1455
+ defaultVariants: { variant: "default" }
1456
+ });
1457
+ function hr({ className: e, value: t, variant: n, ...r }) {
1458
+ let i = typeof t == "number";
1459
+ return /* @__PURE__ */ D(te.Root, {
1460
+ className: L(mr({ variant: n }), e),
1461
+ value: t,
1462
+ ...r,
1463
+ children: /* @__PURE__ */ D(te.Indicator, {
1464
+ className: "k4-progress__indicator",
1465
+ style: i ? { transform: `translateX(-${100 - t}%)` } : void 0
1466
+ })
1467
+ });
1468
+ }
1469
+ //#endregion
1470
+ //#region src/lib/ui/RadioGroup/RadioGroup.tsx
1471
+ function gr({ className: e, ...t }) {
1472
+ return /* @__PURE__ */ D(g.Root, {
1473
+ className: L("k4-radio-group", e),
1474
+ ...t
1475
+ });
1476
+ }
1477
+ function _r({ className: e, ...t }) {
1478
+ return /* @__PURE__ */ D(g.Item, {
1479
+ className: L("k4-radio-group__item", e),
1480
+ ...t,
1481
+ children: /* @__PURE__ */ D(g.Indicator, {
1482
+ className: "k4-radio-group__indicator",
1483
+ children: /* @__PURE__ */ D(ge, {})
1484
+ })
1485
+ });
1486
+ }
1487
+ //#endregion
1488
+ //#region src/lib/ui/Select/Select.tsx
1489
+ var vr = _.Root, yr = _.Group, br = _.Value;
1490
+ function xr({ className: e, size: t = "default", children: n, ...r }) {
1491
+ return /* @__PURE__ */ O(_.Trigger, {
1492
+ className: L("k4-select__trigger", `k4-select__trigger--${t}`, e),
1493
+ ...r,
1494
+ children: [n, /* @__PURE__ */ D(_.Icon, {
1495
+ asChild: !0,
1496
+ children: /* @__PURE__ */ D(j, { className: "k4-select__chevron" })
1497
+ })]
1498
+ });
1499
+ }
1500
+ function Sr({ className: e, children: t, position: n = "popper", ...r }) {
1501
+ return /* @__PURE__ */ D(_.Portal, { children: /* @__PURE__ */ O(_.Content, {
1502
+ className: L("k4-select__content", n === "popper" && "k4-select__content--popper", e),
1503
+ position: n,
1504
+ ...r,
1505
+ children: [
1506
+ /* @__PURE__ */ D(Er, {}),
1507
+ /* @__PURE__ */ D(_.Viewport, {
1508
+ className: "k4-select__viewport",
1509
+ children: t
1510
+ }),
1511
+ /* @__PURE__ */ D(Dr, {})
1512
+ ]
1513
+ }) });
1514
+ }
1515
+ function Cr({ className: e, ...t }) {
1516
+ return /* @__PURE__ */ D(_.Label, {
1517
+ className: L("k4-select__label", e),
1518
+ ...t
1519
+ });
1520
+ }
1521
+ function wr({ className: e, children: t, ...n }) {
1522
+ return /* @__PURE__ */ O(_.Item, {
1523
+ className: L("k4-select__item", e),
1524
+ ...n,
1525
+ children: [/* @__PURE__ */ D("span", {
1526
+ className: "k4-select__item-indicator",
1527
+ children: /* @__PURE__ */ D(_.ItemIndicator, { children: /* @__PURE__ */ D(A, {}) })
1528
+ }), /* @__PURE__ */ D(_.ItemText, { children: t })]
1529
+ });
1530
+ }
1531
+ function Tr({ className: e, ...t }) {
1532
+ return /* @__PURE__ */ D(_.Separator, {
1533
+ className: L("k4-select__separator", e),
1534
+ ...t
1535
+ });
1536
+ }
1537
+ function Er({ className: e, ...t }) {
1538
+ return /* @__PURE__ */ D(_.ScrollUpButton, {
1539
+ className: L("k4-select__scroll-button", e),
1540
+ ...t,
1541
+ children: /* @__PURE__ */ D(he, {})
1542
+ });
1543
+ }
1544
+ function Dr({ className: e, ...t }) {
1545
+ return /* @__PURE__ */ D(_.ScrollDownButton, {
1546
+ className: L("k4-select__scroll-button", e),
1547
+ ...t,
1548
+ children: /* @__PURE__ */ D(j, {})
1549
+ });
1550
+ }
1551
+ //#endregion
1552
+ //#region src/lib/ui/Separator/Separator.tsx
1553
+ function Or({ className: e, orientation: t = "horizontal", decorative: n = !0, ...r }) {
1554
+ return /* @__PURE__ */ D(ne.Root, {
1555
+ decorative: n,
1556
+ orientation: t,
1557
+ className: L("k4-separator", e),
1558
+ ...r
1559
+ });
1560
+ }
1561
+ //#endregion
1562
+ //#region src/lib/ui/Skeleton/Skeleton.tsx
1563
+ function kr({ className: e, ...t }) {
1564
+ return /* @__PURE__ */ D("div", {
1565
+ className: L("k4-skeleton", e),
1566
+ ...t
1567
+ });
1568
+ }
1569
+ //#endregion
1570
+ //#region src/lib/ui/Switch/Switch.tsx
1571
+ function Ar({ className: e, ...t }) {
1572
+ return /* @__PURE__ */ D(y.Root, {
1573
+ className: L("k4-switch", e),
1574
+ ...t,
1575
+ children: /* @__PURE__ */ D(y.Thumb, { className: "k4-switch__thumb" })
1576
+ });
1577
+ }
1578
+ //#endregion
1579
+ //#region src/lib/ui/Table/Table.tsx
1580
+ function jr({ className: e, ...t }) {
1581
+ return /* @__PURE__ */ D("div", {
1582
+ className: "k4-table-container",
1583
+ children: /* @__PURE__ */ D("table", {
1584
+ className: L("k4-table", e),
1585
+ ...t
1586
+ })
1587
+ });
1588
+ }
1589
+ function Mr({ className: e, ...t }) {
1590
+ return /* @__PURE__ */ D("thead", {
1591
+ className: L("k4-table__header", e),
1592
+ ...t
1593
+ });
1594
+ }
1595
+ function Nr({ className: e, ...t }) {
1596
+ return /* @__PURE__ */ D("tbody", {
1597
+ className: L("k4-table__body", e),
1598
+ ...t
1599
+ });
1600
+ }
1601
+ function Pr({ className: e, ...t }) {
1602
+ return /* @__PURE__ */ D("tfoot", {
1603
+ className: L("k4-table__footer", e),
1604
+ ...t
1605
+ });
1606
+ }
1607
+ function Fr({ className: e, ...t }) {
1608
+ return /* @__PURE__ */ D("tr", {
1609
+ className: L("k4-table__row", e),
1610
+ ...t
1611
+ });
1612
+ }
1613
+ function Ir({ className: e, ...t }) {
1614
+ return /* @__PURE__ */ D("th", {
1615
+ className: L("k4-table__head", e),
1616
+ ...t
1617
+ });
1618
+ }
1619
+ function Lr({ className: e, ...t }) {
1620
+ return /* @__PURE__ */ D("td", {
1621
+ className: L("k4-table__cell", e),
1622
+ ...t
1623
+ });
1624
+ }
1625
+ function Rr({ className: e, ...t }) {
1626
+ return /* @__PURE__ */ D("caption", {
1627
+ className: L("k4-table__caption", e),
1628
+ ...t
1629
+ });
1630
+ }
1631
+ //#endregion
1632
+ //#region src/lib/ui/Tabs/Tabs.tsx
1633
+ function zr({ className: e, ...t }) {
1634
+ return /* @__PURE__ */ D(b.Root, {
1635
+ className: L("k4-tabs", e),
1636
+ ...t
1637
+ });
1638
+ }
1639
+ function Br({ className: e, ...t }) {
1640
+ return /* @__PURE__ */ D(b.List, {
1641
+ className: L("k4-tabs__list", e),
1642
+ ...t
1643
+ });
1644
+ }
1645
+ function Vr({ className: e, ...t }) {
1646
+ return /* @__PURE__ */ D(b.Trigger, {
1647
+ className: L("k4-tabs__trigger", e),
1648
+ ...t
1649
+ });
1650
+ }
1651
+ function Hr({ className: e, ...t }) {
1652
+ return /* @__PURE__ */ D(b.Content, {
1653
+ className: L("k4-tabs__content", e),
1654
+ ...t
1655
+ });
1656
+ }
1657
+ //#endregion
1658
+ //#region src/lib/ui/Textarea/Textarea.tsx
1659
+ function Ur({ className: e, ...t }) {
1660
+ return /* @__PURE__ */ D("textarea", {
1661
+ className: L("k4-textarea", e),
1662
+ ...t
1663
+ });
1664
+ }
1665
+ //#endregion
1666
+ //#region src/lib/ui/Tooltip/Tooltip.tsx
1667
+ var Wr = x.Provider, Gr = x.Root, Kr = x.Trigger;
1668
+ function qr({ className: e, sideOffset: t = 0, children: n, ...r }) {
1669
+ return /* @__PURE__ */ D(x.Portal, { children: /* @__PURE__ */ O(x.Content, {
1670
+ sideOffset: t,
1671
+ className: L("k4-tooltip__content", e),
1672
+ ...r,
1673
+ children: [n, /* @__PURE__ */ D(x.Arrow, { className: "k4-tooltip__arrow" })]
1674
+ }) });
1675
+ }
1676
+ //#endregion
1677
+ export { un as Accordion, pn as AccordionContent, dn as AccordionItem, fn as AccordionTrigger, ft as Alert, mt as AlertDescription, mn as AlertDialog, Cn as AlertDialogAction, wn as AlertDialogCancel, vn as AlertDialogContent, Sn as AlertDialogDescription, bn as AlertDialogFooter, yn as AlertDialogHeader, _n as AlertDialogOverlay, gn as AlertDialogPortal, xn as AlertDialogTitle, hn as AlertDialogTrigger, pt as AlertTitle, F as AppError, Le as AppLayout, Tn as Avatar, Dn as AvatarFallback, En as AvatarImage, On as AwaitErrorBlock, An as Badge, U as Button, jn as Card, Fn as CardAction, In as CardContent, Pn as CardDescription, Ln as CardFooter, Mn as CardHeader, Nn as CardTitle, Re as CenteredLayout, Rn as Checkbox, Be as Columns, Jn as Command, Yn as CommandDialog, Qn as CommandEmpty, $n as CommandGroup, Xn as CommandInput, tr as CommandItem, Zn as CommandList, er as CommandSeparator, nr as CommandShortcut, Ve as Container, Ue as DashboardGrid, We as DashboardGridItem, J as DefaultErrorBoundary, Ct as DefaultHydrateFallback, zn as Dialog, Hn as DialogClose, Un as DialogContent, qn as DialogDescription, Gn as DialogFooter, Wn as DialogHeader, Q as DialogOverlay, Vn as DialogPortal, Kn as DialogTitle, Bn as DialogTrigger, xt as DotsSpinner, Vt as DropdownMenu, Jt as DropdownMenuCheckboxItem, qt as DropdownMenuContent, Wt as DropdownMenuGroup, X as DropdownMenuItem, Xt as DropdownMenuLabel, Ht as DropdownMenuPortal, Gt as DropdownMenuRadioGroup, Yt as DropdownMenuRadioItem, Zt as DropdownMenuSeparator, Qt as DropdownMenuShortcut, Kt as DropdownMenuSub, en as DropdownMenuSubContent, $t as DropdownMenuSubTrigger, Ut as DropdownMenuTrigger, q as ErrorBlock, ht as ErrorInline, Ge as FillHeight, Ke as Footer, De as Form, Ne as FormControl, Pe as FormDescription, ke as FormField, je as FormItem, Me as FormLabel, Fe as FormMessage, qe as Header, rr as Input, Ee as Label, on as ModeToggle, ir as Pagination, ar as PaginationContent, lr as PaginationEllipsis, or as PaginationItem, $ as PaginationLink, cr as PaginationNext, sr as PaginationPrevious, ur as Popover, fr as PopoverAnchor, pr as PopoverContent, dr as PopoverTrigger, hr as Progress, gr as RadioGroup, _r as RadioGroupItem, vr as Select, Sr as SelectContent, yr as SelectGroup, wr as SelectItem, Cr as SelectLabel, Dr as SelectScrollDownButton, Er as SelectScrollUpButton, Tr as SelectSeparator, xr as SelectTrigger, br as SelectValue, Or as Separator, W as Sheet, et as SheetClose, nt as SheetContent, ot as SheetDescription, it as SheetFooter, rt as SheetHeader, tt as SheetOverlay, K as SheetPortal, at as SheetTitle, G as SheetTrigger, z as SideBar, Qe as SiteLayout, kr as Skeleton, $e as SkipLink, ut as SortDirection, bt as Spinner, St as SpinnerBlock, Ar as Switch, jr as Table, Nr as TableBody, Rr as TableCaption, Lr as TableCell, Pr as TableFooter, Ir as TableHead, Mr as TableHeader, Fr as TableRow, zr as Tabs, Hr as TabsContent, Br as TabsList, Vr as TabsTrigger, Ur as Textarea, an as ThemeProvider, sn as Toaster, Gr as Tooltip, qr as TooltipContent, Wr as TooltipProvider, Kr as TooltipTrigger, ct as TopBar, zt as TypedLink, dt as alertVariants, kn as badgeVariants, Dt as buildRouterConfig, H as buttonVariants, kt as chain, L as cn, ze as columnsVariants, At as createAppRouter, jt as defineRoute, Pt as findActiveTopItem, I as normalizeError, Rt as pathTo, mr as progressVariants, Y as resolveMenu, ln as toast, R as useFormField, Ie as useMediaQuery, Bt as useRoute, Z as useTheme };
1678
+
1679
+ //# sourceMappingURL=index.js.map