@almanaclabs/blaze-ui 0.3.2 → 0.4.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 (66) hide show
  1. package/README.md +23 -0
  2. package/dist/components/accordion/accordion.js +53 -0
  3. package/dist/components/alert/alert.js +43 -0
  4. package/dist/components/alert-dialog/alert-dialog.js +94 -0
  5. package/dist/components/aspect-ratio/aspect-ratio.js +13 -0
  6. package/dist/components/attachment/attachment.js +104 -0
  7. package/dist/components/avatar/avatar.js +50 -0
  8. package/dist/components/badge/badge.js +29 -0
  9. package/dist/components/breadcrumb/breadcrumb.js +72 -0
  10. package/dist/components/bubble/bubble.js +73 -0
  11. package/dist/components/button/button.js +46 -0
  12. package/dist/components/button-group/button-group.js +41 -0
  13. package/dist/components/calendar/calendar.js +92 -0
  14. package/dist/components/card/card.js +56 -0
  15. package/dist/components/carousel/carousel.js +110 -0
  16. package/dist/components/chart/chart.js +131 -0
  17. package/dist/components/checkbox/checkbox.js +20 -0
  18. package/dist/components/collapsible/collapsible.js +23 -0
  19. package/dist/components/combobox/combobox.js +165 -0
  20. package/dist/components/data-table/data-table.js +30 -0
  21. package/dist/components/date-picker/date-picker.js +39 -0
  22. package/dist/components/dialog/dialog.js +92 -0
  23. package/dist/components/drawer/drawer.js +121 -0
  24. package/dist/components/dropdown-menu/dropdown-menu.js +136 -0
  25. package/dist/components/empty/empty.js +59 -0
  26. package/dist/components/field/field.js +107 -0
  27. package/dist/components/hover-card/hover-card.js +36 -0
  28. package/dist/components/input/input.js +15 -0
  29. package/dist/components/input-group/input-group.js +77 -0
  30. package/dist/components/item/item.js +121 -0
  31. package/dist/components/label/label.js +13 -0
  32. package/dist/components/marker/marker.js +43 -0
  33. package/dist/components/message/message.js +49 -0
  34. package/dist/components/native-select/native-select.js +39 -0
  35. package/dist/components/pagination/pagination.js +80 -0
  36. package/dist/components/popover/popover.js +54 -0
  37. package/dist/components/progress/progress.js +45 -0
  38. package/dist/components/questionnaire/questionnaire-primitive.js +353 -0
  39. package/dist/components/questionnaire/questionnaire.js +169 -0
  40. package/dist/components/radio-group/radio-group.js +26 -0
  41. package/dist/components/scroll-area/scroll-area.js +37 -0
  42. package/dist/components/select/select.js +98 -0
  43. package/dist/components/separator/separator.js +15 -0
  44. package/dist/components/sheet/sheet.js +89 -0
  45. package/dist/components/sidebar/sidebar.js +358 -0
  46. package/dist/components/skeleton/skeleton.js +12 -0
  47. package/dist/components/slider/slider.js +37 -0
  48. package/dist/components/spinner/spinner.js +15 -0
  49. package/dist/components/switch/switch.js +19 -0
  50. package/dist/components/table/table.js +66 -0
  51. package/dist/components/tabs/tabs.js +46 -0
  52. package/dist/components/textarea/textarea.js +13 -0
  53. package/dist/components/toast/toast.js +116 -0
  54. package/dist/components/toggle/toggle.js +35 -0
  55. package/dist/components/toggle-group/toggle-group.js +52 -0
  56. package/dist/components/tooltip/tooltip.js +41 -0
  57. package/dist/hooks/use-mobile.js +14 -0
  58. package/dist/index.js +56 -3699
  59. package/dist/lib/utils.js +8 -0
  60. package/dist/recipes/recipe-runtime.d.ts +6 -0
  61. package/dist/recipes/recipe-runtime.d.ts.map +1 -0
  62. package/package.json +2 -1
  63. package/recipes/README.md +22 -0
  64. package/recipes/manifest.json +12 -0
  65. package/recipes/workspace-shell/README.md +41 -0
  66. package/recipes/workspace-shell/workspace-shell.tsx +386 -0
package/README.md CHANGED
@@ -58,3 +58,26 @@ the rendered anchor as a button to assistive technology.
58
58
 
59
59
  Buttons use `type="button"` by default. Set `type="submit"` explicitly inside
60
60
  forms.
61
+
62
+ ## Package structure
63
+
64
+ Root named imports are the supported consumer API:
65
+
66
+ ```tsx
67
+ import { Button, DatePicker } from '@almanaclabs/blaze-ui'
68
+ ```
69
+
70
+ The published package intentionally preserves its internal ESM modules so
71
+ application bundlers can tree-shake components and place them in the chunks
72
+ that use them. Paths under `dist/components/**` are private implementation
73
+ details, not public APIs. Keep the package's `sideEffects` declaration limited
74
+ to CSS so JavaScript remains tree-shakeable without dropping required styles.
75
+
76
+ ## Recipes
77
+
78
+ Copyable recipe source and agent instructions are installed under
79
+ `node_modules/@almanaclabs/blaze-ui/recipes`. Inspect `recipes/manifest.json` to
80
+ discover available recipes, then copy or adapt a recipe into the application.
81
+
82
+ Recipes are not runtime exports. Applications own their routing, authorization,
83
+ data, and business behavior.
@@ -0,0 +1,53 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { jsx as t, jsxs as n } from "react/jsx-runtime";
3
+ import { Accordion as r } from "@base-ui/react/accordion";
4
+ import { IconChevronDown as i, IconChevronUp as a } from "@tabler/icons-react";
5
+ //#region src/components/accordion/accordion.tsx
6
+ function o({ className: n, ...i }) {
7
+ return /* @__PURE__ */ t(r.Root, {
8
+ "data-slot": "accordion",
9
+ className: e("flex w-full flex-col", n),
10
+ ...i
11
+ });
12
+ }
13
+ function s({ className: n, ...i }) {
14
+ return /* @__PURE__ */ t(r.Item, {
15
+ "data-slot": "accordion-item",
16
+ className: e("not-last:border-b", n),
17
+ ...i
18
+ });
19
+ }
20
+ function c({ className: o, children: s, ...c }) {
21
+ return /* @__PURE__ */ t(r.Header, {
22
+ className: "flex",
23
+ children: /* @__PURE__ */ n(r.Trigger, {
24
+ "data-slot": "accordion-trigger",
25
+ className: e("group/accordion-trigger relative flex flex-1 items-start justify-between rounded-lg border border-transparent py-2.5 text-left text-sm font-medium transition-all outline-none hover:underline focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:after:border-ring aria-disabled:pointer-events-none aria-disabled:opacity-50 **:data-[slot=accordion-trigger-icon]:ml-auto **:data-[slot=accordion-trigger-icon]:size-4 **:data-[slot=accordion-trigger-icon]:text-muted-foreground", o),
26
+ ...c,
27
+ children: [
28
+ s,
29
+ /* @__PURE__ */ t(i, {
30
+ "data-slot": "accordion-trigger-icon",
31
+ className: "pointer-events-none shrink-0 group-aria-expanded/accordion-trigger:hidden"
32
+ }),
33
+ /* @__PURE__ */ t(a, {
34
+ "data-slot": "accordion-trigger-icon",
35
+ className: "pointer-events-none hidden shrink-0 group-aria-expanded/accordion-trigger:inline"
36
+ })
37
+ ]
38
+ })
39
+ });
40
+ }
41
+ function l({ className: n, children: i, ...a }) {
42
+ return /* @__PURE__ */ t(r.Panel, {
43
+ "data-slot": "accordion-content",
44
+ className: "overflow-hidden text-sm data-open:animate-accordion-down data-closed:animate-accordion-up",
45
+ ...a,
46
+ children: /* @__PURE__ */ t("div", {
47
+ className: e("h-(--accordion-panel-height) pt-0 pb-2.5 data-ending-style:h-0 data-starting-style:h-0 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4", n),
48
+ children: i
49
+ })
50
+ });
51
+ }
52
+ //#endregion
53
+ export { o as Accordion, l as AccordionContent, s as AccordionItem, c as AccordionTrigger };
@@ -0,0 +1,43 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { cva as t } from "class-variance-authority";
3
+ import { jsx as n } from "react/jsx-runtime";
4
+ import "react";
5
+ //#region src/components/alert/alert.tsx
6
+ var r = t("group/alert relative grid w-full gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4", {
7
+ variants: { variant: {
8
+ default: "bg-card text-card-foreground",
9
+ destructive: "bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current"
10
+ } },
11
+ defaultVariants: { variant: "default" }
12
+ });
13
+ function i({ className: t, variant: i, ...a }) {
14
+ return /* @__PURE__ */ n("div", {
15
+ "data-slot": "alert",
16
+ role: "alert",
17
+ className: e(r({ variant: i }), t),
18
+ ...a
19
+ });
20
+ }
21
+ function a({ className: t, ...r }) {
22
+ return /* @__PURE__ */ n("div", {
23
+ "data-slot": "alert-title",
24
+ className: e("font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground", t),
25
+ ...r
26
+ });
27
+ }
28
+ function o({ className: t, ...r }) {
29
+ return /* @__PURE__ */ n("div", {
30
+ "data-slot": "alert-description",
31
+ className: e("text-sm text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4", t),
32
+ ...r
33
+ });
34
+ }
35
+ function s({ className: t, ...r }) {
36
+ return /* @__PURE__ */ n("div", {
37
+ "data-slot": "alert-action",
38
+ className: e("absolute top-2 right-2", t),
39
+ ...r
40
+ });
41
+ }
42
+ //#endregion
43
+ export { i as Alert, s as AlertAction, o as AlertDescription, a as AlertTitle };
@@ -0,0 +1,94 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { Button as t } from "../button/button.js";
3
+ import { jsx as n, jsxs as r } from "react/jsx-runtime";
4
+ import "react";
5
+ import { AlertDialog as i } from "@base-ui/react/alert-dialog";
6
+ //#region src/components/alert-dialog/alert-dialog.tsx
7
+ function a({ ...e }) {
8
+ return /* @__PURE__ */ n(i.Root, {
9
+ "data-slot": "alert-dialog",
10
+ ...e
11
+ });
12
+ }
13
+ function o({ ...e }) {
14
+ return /* @__PURE__ */ n(i.Trigger, {
15
+ "data-slot": "alert-dialog-trigger",
16
+ ...e
17
+ });
18
+ }
19
+ function s({ ...e }) {
20
+ return /* @__PURE__ */ n(i.Portal, {
21
+ "data-slot": "alert-dialog-portal",
22
+ ...e
23
+ });
24
+ }
25
+ function c({ className: t, ...r }) {
26
+ return /* @__PURE__ */ n(i.Backdrop, {
27
+ "data-slot": "alert-dialog-overlay",
28
+ className: e("fixed inset-0 isolate z-50 bg-foreground/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0", t),
29
+ ...r
30
+ });
31
+ }
32
+ function l({ className: t, size: a = "default", ...o }) {
33
+ return /* @__PURE__ */ r(s, { children: [/* @__PURE__ */ n(c, {}), /* @__PURE__ */ n(i.Popup, {
34
+ "data-slot": "alert-dialog-content",
35
+ "data-size": a,
36
+ className: e("group/alert-dialog-content fixed top-1/2 left-1/2 z-50 grid w-full -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", t),
37
+ ...o
38
+ })] });
39
+ }
40
+ function u({ className: t, ...r }) {
41
+ return /* @__PURE__ */ n("div", {
42
+ "data-slot": "alert-dialog-header",
43
+ className: e("grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]", t),
44
+ ...r
45
+ });
46
+ }
47
+ function d({ className: t, ...r }) {
48
+ return /* @__PURE__ */ n("div", {
49
+ "data-slot": "alert-dialog-footer",
50
+ className: e("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end", t),
51
+ ...r
52
+ });
53
+ }
54
+ function f({ className: t, ...r }) {
55
+ return /* @__PURE__ */ n("div", {
56
+ "data-slot": "alert-dialog-media",
57
+ className: e("mb-2 inline-flex size-10 items-center justify-center rounded-md bg-muted sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-6", t),
58
+ ...r
59
+ });
60
+ }
61
+ function p({ className: t, ...r }) {
62
+ return /* @__PURE__ */ n(i.Title, {
63
+ "data-slot": "alert-dialog-title",
64
+ className: e("font-heading text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2", t),
65
+ ...r
66
+ });
67
+ }
68
+ function m({ className: t, ...r }) {
69
+ return /* @__PURE__ */ n(i.Description, {
70
+ "data-slot": "alert-dialog-description",
71
+ className: e("text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground", t),
72
+ ...r
73
+ });
74
+ }
75
+ function h({ className: r, ...i }) {
76
+ return /* @__PURE__ */ n(t, {
77
+ "data-slot": "alert-dialog-action",
78
+ className: e(r),
79
+ ...i
80
+ });
81
+ }
82
+ function g({ className: r, variant: a = "outline", size: o = "default", ...s }) {
83
+ return /* @__PURE__ */ n(i.Close, {
84
+ "data-slot": "alert-dialog-cancel",
85
+ className: e(r),
86
+ render: /* @__PURE__ */ n(t, {
87
+ variant: a,
88
+ size: o
89
+ }),
90
+ ...s
91
+ });
92
+ }
93
+ //#endregion
94
+ export { a as AlertDialog, h as AlertDialogAction, g as AlertDialogCancel, l as AlertDialogContent, m as AlertDialogDescription, d as AlertDialogFooter, u as AlertDialogHeader, f as AlertDialogMedia, c as AlertDialogOverlay, s as AlertDialogPortal, p as AlertDialogTitle, o as AlertDialogTrigger };
@@ -0,0 +1,13 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { jsx as t } from "react/jsx-runtime";
3
+ //#region src/components/aspect-ratio/aspect-ratio.tsx
4
+ function n({ ratio: n, className: r, ...i }) {
5
+ return /* @__PURE__ */ t("div", {
6
+ "data-slot": "aspect-ratio",
7
+ style: { "--ratio": n },
8
+ className: e("relative aspect-(--ratio)", r),
9
+ ...i
10
+ });
11
+ }
12
+ //#endregion
13
+ export { n as AspectRatio };
@@ -0,0 +1,104 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { Button as t } from "../button/button.js";
3
+ import { cva as n } from "class-variance-authority";
4
+ import { jsx as r } from "react/jsx-runtime";
5
+ import "react";
6
+ import { mergeProps as i } from "@base-ui/react/merge-props";
7
+ import { useRender as a } from "@base-ui/react/use-render";
8
+ //#region src/components/attachment/attachment.tsx
9
+ var o = n("group/attachment relative flex w-fit max-w-full min-w-0 shrink-0 flex-wrap rounded-xl border bg-card text-card-foreground transition-colors focus-within:ring-1 focus-within:ring-ring/50 has-[>a,>button]:hover:bg-muted/50 data-[state=error]:border-destructive/30 data-[state=idle]:border-dashed", { variants: {
10
+ size: {
11
+ default: "gap-2 text-sm has-data-[slot=attachment-content]:px-2.5 has-data-[slot=attachment-content]:py-2 has-data-[slot=attachment-media]:p-2",
12
+ sm: "gap-2.5 text-xs has-data-[slot=attachment-content]:px-2 has-data-[slot=attachment-content]:py-1.5 has-data-[slot=attachment-media]:p-1.5",
13
+ xs: "gap-1.5 rounded-lg text-xs has-data-[slot=attachment-content]:px-1.5 has-data-[slot=attachment-content]:py-1 has-data-[slot=attachment-media]:p-1"
14
+ },
15
+ orientation: {
16
+ horizontal: "min-w-40 items-center",
17
+ vertical: "w-24 flex-col has-data-[slot=attachment-content]:w-30"
18
+ }
19
+ } });
20
+ function s({ className: t, state: n = "done", size: i = "default", orientation: a = "horizontal", ...s }) {
21
+ return /* @__PURE__ */ r("div", {
22
+ "data-slot": "attachment",
23
+ "data-state": n,
24
+ "data-size": i,
25
+ "data-orientation": a,
26
+ className: e(o({
27
+ size: i,
28
+ orientation: a
29
+ }), t),
30
+ ...s
31
+ });
32
+ }
33
+ var c = n("relative flex aspect-square w-10 shrink-0 items-center justify-center overflow-hidden rounded-lg bg-muted text-foreground group-data-[orientation=vertical]/attachment:w-full group-data-[size=sm]/attachment:w-8 group-data-[size=xs]/attachment:w-7 group-data-[size=xs]/attachment:rounded-md group-data-[state=error]/attachment:bg-destructive/10 group-data-[state=error]/attachment:text-destructive group-data-[orientation=vertical]/attachment:*:data-[slot=spinner]:size-6! [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 group-data-[orientation=vertical]/attachment:[&_svg:not([class*='size-'])]:size-6 group-data-[size=xs]/attachment:[&_svg:not([class*='size-'])]:size-3.5", {
34
+ variants: { variant: {
35
+ icon: "",
36
+ image: "opacity-60 group-data-[state=done]/attachment:opacity-100 group-data-[state=idle]/attachment:opacity-100 *:[img]:aspect-square *:[img]:w-full *:[img]:object-cover"
37
+ } },
38
+ defaultVariants: { variant: "icon" }
39
+ });
40
+ function l({ className: t, variant: n = "icon", ...i }) {
41
+ return /* @__PURE__ */ r("div", {
42
+ "data-slot": "attachment-media",
43
+ "data-variant": n,
44
+ className: e(c({ variant: n }), t),
45
+ ...i
46
+ });
47
+ }
48
+ function u({ className: t, ...n }) {
49
+ return /* @__PURE__ */ r("div", {
50
+ "data-slot": "attachment-content",
51
+ className: e("max-w-full min-w-0 flex-1 leading-tight group-data-[orientation=vertical]/attachment:px-1", t),
52
+ ...n
53
+ });
54
+ }
55
+ function d({ className: t, ...n }) {
56
+ return /* @__PURE__ */ r("span", {
57
+ "data-slot": "attachment-title",
58
+ className: e("block max-w-full min-w-0 truncate font-medium group-data-[state=processing]/attachment:shimmer group-data-[state=uploading]/attachment:shimmer", t),
59
+ ...n
60
+ });
61
+ }
62
+ function f({ className: t, ...n }) {
63
+ return /* @__PURE__ */ r("span", {
64
+ "data-slot": "attachment-description",
65
+ className: e("mt-0.5 block min-w-0 truncate text-xs text-muted-foreground group-data-[state=error]/attachment:text-destructive/80", "max-w-full", t),
66
+ ...n
67
+ });
68
+ }
69
+ function p({ className: t, ...n }) {
70
+ return /* @__PURE__ */ r("div", {
71
+ "data-slot": "attachment-actions",
72
+ className: e("relative z-20 flex shrink-0 items-center group-data-[orientation=vertical]/attachment:absolute group-data-[orientation=vertical]/attachment:top-3 group-data-[orientation=vertical]/attachment:right-3 group-data-[orientation=vertical]/attachment:gap-1", t),
73
+ ...n
74
+ });
75
+ }
76
+ function m({ className: n, variant: i, size: a = "icon-xs", ...o }) {
77
+ return /* @__PURE__ */ r(t, {
78
+ "data-slot": "attachment-action",
79
+ variant: i ?? "ghost",
80
+ size: a,
81
+ className: e(n),
82
+ ...o
83
+ });
84
+ }
85
+ function h({ className: t, render: n, type: r, ...o }) {
86
+ return a({
87
+ defaultTagName: "button",
88
+ props: i({
89
+ type: n ? r : r ?? "button",
90
+ className: e("absolute inset-0 z-10 outline-none", t)
91
+ }, o),
92
+ render: n,
93
+ state: { slot: "attachment-trigger" }
94
+ });
95
+ }
96
+ function g({ className: t, ...n }) {
97
+ return /* @__PURE__ */ r("div", {
98
+ "data-slot": "attachment-group",
99
+ className: e("flex min-w-0 scroll-fade-x snap-x snap-mandatory scroll-px-1 scrollbar-none gap-3 overflow-x-auto overscroll-x-contain py-1 *:data-[slot=attachment]:flex-none *:data-[slot=attachment]:snap-start", t),
100
+ ...n
101
+ });
102
+ }
103
+ //#endregion
104
+ export { s as Attachment, m as AttachmentAction, p as AttachmentActions, u as AttachmentContent, f as AttachmentDescription, g as AttachmentGroup, l as AttachmentMedia, d as AttachmentTitle, h as AttachmentTrigger };
@@ -0,0 +1,50 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { jsx as t } from "react/jsx-runtime";
3
+ import "react";
4
+ import { Avatar as n } from "@base-ui/react/avatar";
5
+ //#region src/components/avatar/avatar.tsx
6
+ function r({ className: r, size: i = "default", ...a }) {
7
+ return /* @__PURE__ */ t(n.Root, {
8
+ "data-slot": "avatar",
9
+ "data-size": i,
10
+ className: e("group/avatar relative flex size-8 shrink-0 rounded-full select-none after:absolute after:inset-0 after:rounded-full after:border after:border-border after:mix-blend-darken data-[size=lg]:size-10 data-[size=sm]:size-6 dark:after:mix-blend-lighten", r),
11
+ ...a
12
+ });
13
+ }
14
+ function i({ className: r, ...i }) {
15
+ return /* @__PURE__ */ t(n.Image, {
16
+ "data-slot": "avatar-image",
17
+ className: e("aspect-square size-full rounded-full object-cover", r),
18
+ ...i
19
+ });
20
+ }
21
+ function a({ className: r, ...i }) {
22
+ return /* @__PURE__ */ t(n.Fallback, {
23
+ "data-slot": "avatar-fallback",
24
+ className: e("flex size-full items-center justify-center rounded-full bg-muted text-sm text-foreground group-data-[size=sm]/avatar:text-xs", r),
25
+ ...i
26
+ });
27
+ }
28
+ function o({ className: n, ...r }) {
29
+ return /* @__PURE__ */ t("span", {
30
+ "data-slot": "avatar-badge",
31
+ className: e("absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-primary text-primary-foreground bg-blend-color ring-2 ring-background select-none", "group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden", "group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2", "group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2", n),
32
+ ...r
33
+ });
34
+ }
35
+ function s({ className: n, ...r }) {
36
+ return /* @__PURE__ */ t("div", {
37
+ "data-slot": "avatar-group",
38
+ className: e("group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:ring-background", n),
39
+ ...r
40
+ });
41
+ }
42
+ function c({ className: n, ...r }) {
43
+ return /* @__PURE__ */ t("div", {
44
+ "data-slot": "avatar-group-count",
45
+ className: e("relative flex size-8 shrink-0 items-center justify-center rounded-full bg-muted text-sm text-muted-foreground ring-2 ring-background group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 [&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3", n),
46
+ ...r
47
+ });
48
+ }
49
+ //#endregion
50
+ export { r as Avatar, o as AvatarBadge, a as AvatarFallback, s as AvatarGroup, c as AvatarGroupCount, i as AvatarImage };
@@ -0,0 +1,29 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { cva as t } from "class-variance-authority";
3
+ import { mergeProps as n } from "@base-ui/react/merge-props";
4
+ import { useRender as r } from "@base-ui/react/use-render";
5
+ //#region src/components/badge/badge.tsx
6
+ var i = t("group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!", {
7
+ variants: { variant: {
8
+ default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",
9
+ secondary: "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",
10
+ destructive: "bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20",
11
+ outline: "border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground",
12
+ ghost: "hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50",
13
+ link: "text-primary underline-offset-4 hover:underline"
14
+ } },
15
+ defaultVariants: { variant: "default" }
16
+ });
17
+ function a({ className: t, variant: a = "default", render: o, ...s }) {
18
+ return r({
19
+ defaultTagName: "span",
20
+ props: n({ className: e(i({ variant: a }), t) }, s),
21
+ render: o,
22
+ state: {
23
+ slot: "badge",
24
+ variant: a
25
+ }
26
+ });
27
+ }
28
+ //#endregion
29
+ export { a as Badge, i as badgeVariants };
@@ -0,0 +1,72 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { jsx as t, jsxs as n } from "react/jsx-runtime";
3
+ import "react";
4
+ import { IconChevronRight as r, IconDots as i } from "@tabler/icons-react";
5
+ import { mergeProps as a } from "@base-ui/react/merge-props";
6
+ import { useRender as o } from "@base-ui/react/use-render";
7
+ //#region src/components/breadcrumb/breadcrumb.tsx
8
+ function s({ className: n, ...r }) {
9
+ return /* @__PURE__ */ t("nav", {
10
+ "aria-label": "breadcrumb",
11
+ "data-slot": "breadcrumb",
12
+ className: e(n),
13
+ ...r
14
+ });
15
+ }
16
+ function c({ className: n, ...r }) {
17
+ return /* @__PURE__ */ t("ol", {
18
+ "data-slot": "breadcrumb-list",
19
+ className: e("flex flex-wrap items-center gap-1.5 text-sm wrap-break-word text-muted-foreground", n),
20
+ ...r
21
+ });
22
+ }
23
+ function l({ className: n, ...r }) {
24
+ return /* @__PURE__ */ t("li", {
25
+ "data-slot": "breadcrumb-item",
26
+ className: e("inline-flex items-center gap-1", n),
27
+ ...r
28
+ });
29
+ }
30
+ function u({ className: t, render: n, ...r }) {
31
+ return o({
32
+ defaultTagName: "a",
33
+ props: a({ className: e("transition-colors hover:text-foreground", t) }, r),
34
+ render: n,
35
+ state: { slot: "breadcrumb-link" }
36
+ });
37
+ }
38
+ function d({ className: n, ...r }) {
39
+ return /* @__PURE__ */ t("span", {
40
+ "data-slot": "breadcrumb-page",
41
+ role: "link",
42
+ "aria-disabled": "true",
43
+ "aria-current": "page",
44
+ className: e("font-normal text-foreground", n),
45
+ ...r
46
+ });
47
+ }
48
+ function f({ children: n, className: i, ...a }) {
49
+ return /* @__PURE__ */ t("li", {
50
+ "data-slot": "breadcrumb-separator",
51
+ role: "presentation",
52
+ "aria-hidden": "true",
53
+ className: e("[&>svg]:size-3.5", i),
54
+ ...a,
55
+ children: n ?? /* @__PURE__ */ t(r, {})
56
+ });
57
+ }
58
+ function p({ className: r, ...a }) {
59
+ return /* @__PURE__ */ n("span", {
60
+ "data-slot": "breadcrumb-ellipsis",
61
+ role: "presentation",
62
+ "aria-hidden": "true",
63
+ className: e("flex size-5 items-center justify-center [&>svg]:size-4", r),
64
+ ...a,
65
+ children: [/* @__PURE__ */ t(i, {}), /* @__PURE__ */ t("span", {
66
+ className: "sr-only",
67
+ children: "More"
68
+ })]
69
+ });
70
+ }
71
+ //#endregion
72
+ export { s as Breadcrumb, p as BreadcrumbEllipsis, l as BreadcrumbItem, u as BreadcrumbLink, c as BreadcrumbList, d as BreadcrumbPage, f as BreadcrumbSeparator };
@@ -0,0 +1,73 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { cva as t } from "class-variance-authority";
3
+ import { jsx as n } from "react/jsx-runtime";
4
+ import "react";
5
+ import { mergeProps as r } from "@base-ui/react/merge-props";
6
+ import { useRender as i } from "@base-ui/react/use-render";
7
+ //#region src/components/bubble/bubble.tsx
8
+ function a({ className: t, ...r }) {
9
+ return /* @__PURE__ */ n("div", {
10
+ "data-slot": "bubble-group",
11
+ className: e("flex min-w-0 flex-col gap-2", t),
12
+ ...r
13
+ });
14
+ }
15
+ var o = t("group/bubble relative flex w-fit max-w-[80%] min-w-0 flex-col gap-1 group-data-[align=end]/message:self-end data-[align=end]:self-end data-[variant=ghost]:max-w-full", {
16
+ variants: { variant: {
17
+ default: "*:data-[slot=bubble-content]:bg-primary *:data-[slot=bubble-content]:text-primary-foreground [&>[data-slot=bubble-content]:is(button,a):hover]:bg-primary/80",
18
+ secondary: "*:data-[slot=bubble-content]:bg-secondary *:data-[slot=bubble-content]:text-secondary-foreground [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)]",
19
+ muted: "*:data-[slot=bubble-content]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[color-mix(in_oklch,var(--muted),var(--foreground)_5%)]",
20
+ tinted: "*:data-[slot=bubble-content]:bg-[oklch(from_var(--primary)_0.93_calc(c*0.4)_h)] *:data-[slot=bubble-content]:text-foreground dark:*:data-[slot=bubble-content]:bg-[oklch(from_var(--primary)_0.3_calc(c*0.4)_h)] [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[oklch(from_var(--primary)_0.88_calc(c*0.5)_h)] dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-[oklch(from_var(--primary)_0.35_calc(c*0.5)_h)]",
21
+ outline: "*:data-[slot=bubble-content]:border-border *:data-[slot=bubble-content]:bg-background [&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:text-foreground dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-input/30",
22
+ ghost: "border-none *:data-[slot=bubble-content]:rounded-none *:data-[slot=bubble-content]:bg-transparent *:data-[slot=bubble-content]:p-0 [&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:text-foreground dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted/50",
23
+ destructive: "*:data-[slot=bubble-content]:bg-destructive/10 *:data-[slot=bubble-content]:text-destructive dark:*:data-[slot=bubble-content]:bg-destructive/20 [&>[data-slot=bubble-content]:is(button,a):hover]:bg-destructive/20 dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-destructive/30"
24
+ } },
25
+ defaultVariants: { variant: "default" }
26
+ });
27
+ function s({ variant: t = "default", align: r = "start", className: i, ...a }) {
28
+ return /* @__PURE__ */ n("div", {
29
+ "data-slot": "bubble",
30
+ "data-variant": t,
31
+ "data-align": r,
32
+ className: e(o({ variant: t }), i),
33
+ ...a
34
+ });
35
+ }
36
+ function c({ className: t, render: n, ...a }) {
37
+ return i({
38
+ defaultTagName: "div",
39
+ props: r({ className: e("w-fit max-w-full min-w-0 overflow-hidden rounded-xl border border-transparent px-3 py-2 text-sm leading-relaxed wrap-break-word group-data-[align=end]/bubble:self-end [button]:text-left [button,a]:transition-colors [button,a]:outline-none [button,a]:focus-visible:border-ring [button,a]:focus-visible:ring-3 [button,a]:focus-visible:ring-ring/50", t) }, a),
40
+ render: n,
41
+ state: { slot: "bubble-content" }
42
+ });
43
+ }
44
+ var l = t("absolute z-10 flex w-fit shrink-0 items-center justify-center gap-1 rounded-full bg-muted px-1.5 py-0.5 text-sm ring-3 ring-card has-[button]:p-0", {
45
+ variants: {
46
+ side: {
47
+ top: "top-0 -translate-y-3/4",
48
+ bottom: "bottom-0 translate-y-3/4"
49
+ },
50
+ align: {
51
+ start: "left-3",
52
+ end: "right-3"
53
+ }
54
+ },
55
+ defaultVariants: {
56
+ side: "bottom",
57
+ align: "end"
58
+ }
59
+ });
60
+ function u({ side: t = "bottom", align: r = "end", className: i, ...a }) {
61
+ return /* @__PURE__ */ n("div", {
62
+ "data-slot": "bubble-reactions",
63
+ "data-align": r,
64
+ "data-side": t,
65
+ className: e(l({
66
+ side: t,
67
+ align: r
68
+ }), i),
69
+ ...a
70
+ });
71
+ }
72
+ //#endregion
73
+ export { s as Bubble, c as BubbleContent, a as BubbleGroup, u as BubbleReactions };
@@ -0,0 +1,46 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { Button as t } from "@base-ui/react/button";
3
+ import { cva as n } from "class-variance-authority";
4
+ import { jsx as r } from "react/jsx-runtime";
5
+ //#region src/components/button/button.tsx
6
+ var i = n("group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
7
+ variants: {
8
+ variant: {
9
+ default: "bg-primary text-primary-foreground hover:bg-primary/80",
10
+ outline: "border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",
11
+ secondary: "bg-secondary text-secondary-foreground hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)] aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",
12
+ ghost: "hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50",
13
+ destructive: "bg-destructive/10 text-destructive hover:bg-destructive/15 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/10 dark:hover:bg-destructive/15 dark:focus-visible:ring-destructive/40",
14
+ link: "text-primary underline-offset-4 hover:underline"
15
+ },
16
+ size: {
17
+ default: "h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
18
+ xs: "h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",
19
+ sm: "h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",
20
+ lg: "h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
21
+ icon: "size-8",
22
+ "icon-xs": "size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3",
23
+ "icon-sm": "size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg",
24
+ "icon-lg": "size-9"
25
+ }
26
+ },
27
+ defaultVariants: {
28
+ variant: "default",
29
+ size: "default"
30
+ }
31
+ });
32
+ function a({ className: n, variant: a = "default", size: o = "default", ...s }) {
33
+ let c = i({
34
+ variant: a,
35
+ size: o
36
+ });
37
+ return /* @__PURE__ */ r(t, {
38
+ "data-slot": "button",
39
+ "data-variant": a,
40
+ "data-size": o,
41
+ className: typeof n == "function" ? (t) => e(c, n(t)) : e(c, n),
42
+ ...s
43
+ });
44
+ }
45
+ //#endregion
46
+ export { a as Button, i as buttonVariants };
@@ -0,0 +1,41 @@
1
+ import { cn as e } from "../../lib/utils.js";
2
+ import { Separator as t } from "../separator/separator.js";
3
+ import { cva as n } from "class-variance-authority";
4
+ import { jsx as r } from "react/jsx-runtime";
5
+ import { mergeProps as i } from "@base-ui/react/merge-props";
6
+ import { useRender as a } from "@base-ui/react/use-render";
7
+ //#region src/components/button-group/button-group.tsx
8
+ var o = n("flex w-fit items-stretch *:focus-visible:relative *:focus-visible:z-10 has-[>[data-slot=button-group]]:gap-2 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-lg [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1", {
9
+ variants: { orientation: {
10
+ horizontal: "*:data-slot:rounded-r-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-r-lg! [&>[data-slot]~[data-slot]]:rounded-l-none [&>[data-slot]~[data-slot]]:border-l-0",
11
+ vertical: "flex-col *:data-slot:rounded-b-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-b-lg! [&>[data-slot]~[data-slot]]:rounded-t-none [&>[data-slot]~[data-slot]]:border-t-0"
12
+ } },
13
+ defaultVariants: { orientation: "horizontal" }
14
+ });
15
+ function s({ className: t, orientation: n, ...i }) {
16
+ return /* @__PURE__ */ r("div", {
17
+ role: "group",
18
+ "data-slot": "button-group",
19
+ "data-orientation": n,
20
+ className: e(o({ orientation: n }), t),
21
+ ...i
22
+ });
23
+ }
24
+ function c({ className: t, render: n, ...r }) {
25
+ return a({
26
+ defaultTagName: "div",
27
+ props: i({ className: e("flex items-center gap-2 rounded-lg border bg-muted px-2.5 text-sm font-medium [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4", t) }, r),
28
+ render: n,
29
+ state: { slot: "button-group-text" }
30
+ });
31
+ }
32
+ function l({ className: n, orientation: i = "vertical", ...a }) {
33
+ return /* @__PURE__ */ r(t, {
34
+ "data-slot": "button-group-separator",
35
+ orientation: i,
36
+ className: e("relative self-stretch bg-input data-horizontal:mx-px data-horizontal:w-auto data-vertical:my-px data-vertical:h-auto", n),
37
+ ...a
38
+ });
39
+ }
40
+ //#endregion
41
+ export { s as ButtonGroup, l as ButtonGroupSeparator, c as ButtonGroupText, o as buttonGroupVariants };