@foundrykit/primitives 2.1.3 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (196) hide show
  1. package/README.md +11 -0
  2. package/dist/{chunk-SEDTBIZW.js → chunk-OMPTY5WQ.js} +1 -1
  3. package/dist/components/accordion/index.js +60 -6
  4. package/dist/components/alert/index.js +62 -6
  5. package/dist/components/alert-dialog/index.js +142 -13
  6. package/dist/components/aspect-ratio/index.js +9 -3
  7. package/dist/components/avatar/index.js +50 -5
  8. package/dist/components/badge/index.js +37 -4
  9. package/dist/components/breadcrumb/index.js +95 -9
  10. package/dist/components/button/index.js +1 -1
  11. package/dist/components/button-group/index.js +74 -6
  12. package/dist/components/card/index.js +66 -8
  13. package/dist/components/checkbox/index.js +30 -3
  14. package/dist/components/collapsible/index.js +33 -7
  15. package/dist/components/context-menu/index.js +208 -17
  16. package/dist/components/dialog/index.js +126 -12
  17. package/dist/components/direction/index.js +10 -2
  18. package/dist/components/drawer/index.js +118 -12
  19. package/dist/components/dropdown/index.js +216 -17
  20. package/dist/components/empty/index.js +95 -9
  21. package/dist/components/field/index.js +211 -13
  22. package/dist/components/hover-card/index.js +35 -5
  23. package/dist/components/input-group/index.d.ts +1 -1
  24. package/dist/components/input-group/index.js +1 -1
  25. package/dist/components/item/index.js +178 -14
  26. package/dist/components/kbd/index.js +27 -4
  27. package/dist/components/label/index.js +21 -3
  28. package/dist/components/menubar/index.js +235 -18
  29. package/dist/components/native-select/index.js +25 -3
  30. package/dist/components/navigation-menu/index.js +161 -11
  31. package/dist/components/popover/index.js +40 -6
  32. package/dist/components/progress/index.js +30 -3
  33. package/dist/components/radio-group/index.js +43 -4
  34. package/dist/components/resizable/index.js +43 -5
  35. package/dist/components/scroll-area/index.js +58 -4
  36. package/dist/components/section/index.js +13 -3
  37. package/dist/components/select/index.js +159 -12
  38. package/dist/components/sheet/index.js +118 -10
  39. package/dist/components/skeleton/index.js +13 -3
  40. package/dist/components/slider/index.js +64 -3
  41. package/dist/components/sonner/index.js +21 -4
  42. package/dist/components/spinner/index.js +19 -3
  43. package/dist/components/switch/index.js +30 -3
  44. package/dist/components/table/index.js +105 -10
  45. package/dist/components/tabs/index.js +63 -6
  46. package/dist/components/toggle/index.js +41 -4
  47. package/dist/components/toggle-group/index.js +80 -4
  48. package/dist/components/tooltip/index.js +51 -6
  49. package/dist/components/typography/index.js +147 -14
  50. package/dist/index.d.ts +1 -0
  51. package/dist/index.js +221 -254
  52. package/package.json +3 -3
  53. package/dist/chunk-25N35Z5M.js +0 -42
  54. package/dist/chunk-2JOT4DV4.js +0 -66
  55. package/dist/chunk-2SBGU5XA.js +0 -233
  56. package/dist/chunk-2UG6OCGA.js +0 -75
  57. package/dist/chunk-3BAO7TAS.js +0 -105
  58. package/dist/chunk-3NQR7JZR.js +0 -128
  59. package/dist/chunk-3QUMCM5K.js +0 -225
  60. package/dist/chunk-3TZXV53R.js +0 -55
  61. package/dist/chunk-3UKWAM5M.js +0 -33
  62. package/dist/chunk-44I6VK3H.js +0 -105
  63. package/dist/chunk-67UXTT4O.js +0 -116
  64. package/dist/chunk-727ACUWN.js +0 -82
  65. package/dist/chunk-76APYFRN.js +0 -29
  66. package/dist/chunk-AJAAMJYH.js +0 -12
  67. package/dist/chunk-B5YCE3UP.js +0 -57
  68. package/dist/chunk-BIFBYERK.js +0 -69
  69. package/dist/chunk-DXZ4GUQO.js +0 -33
  70. package/dist/chunk-ED6T7ZZN.js +0 -130
  71. package/dist/chunk-EEAK2RWF.js +0 -23
  72. package/dist/chunk-F2TEA6ER.js +0 -138
  73. package/dist/chunk-FF5D53KL.js +0 -69
  74. package/dist/chunk-FRIOQFPE.js +0 -171
  75. package/dist/chunk-G2YBCHWR.js +0 -46
  76. package/dist/chunk-GKCBSG2W.js +0 -67
  77. package/dist/chunk-GPEL656S.js +0 -84
  78. package/dist/chunk-JKKCRFYB.js +0 -36
  79. package/dist/chunk-JTSIBZS4.js +0 -194
  80. package/dist/chunk-MCXSVXO4.js +0 -24
  81. package/dist/chunk-MMZJQ7RW.js +0 -33
  82. package/dist/chunk-MYIUX3DT.js +0 -62
  83. package/dist/chunk-P5KEJOBH.js +0 -155
  84. package/dist/chunk-PAO3DSEF.js +0 -48
  85. package/dist/chunk-PLLG76QJ.js +0 -32
  86. package/dist/chunk-SDYKJVXX.js +0 -253
  87. package/dist/chunk-SIQHWNPH.js +0 -45
  88. package/dist/chunk-SKR3J46C.js +0 -17
  89. package/dist/chunk-STRBREHN.js +0 -17
  90. package/dist/chunk-SUEPE6OX.js +0 -47
  91. package/dist/chunk-TA23RNS4.js +0 -162
  92. package/dist/chunk-TRXU4SOJ.js +0 -224
  93. package/dist/chunk-U7JIOR7A.js +0 -172
  94. package/dist/chunk-VPBVKBZ7.js +0 -25
  95. package/dist/chunk-W4XY3SNY.js +0 -40
  96. package/dist/chunk-YT2ZIMZI.js +0 -16
  97. package/dist/components/accordion/index.cjs +0 -104
  98. package/dist/components/accordion/index.d.cts +0 -25
  99. package/dist/components/alert/index.cjs +0 -96
  100. package/dist/components/alert/index.d.cts +0 -28
  101. package/dist/components/alert-dialog/index.cjs +0 -200
  102. package/dist/components/alert-dialog/index.d.cts +0 -42
  103. package/dist/components/aspect-ratio/index.cjs +0 -47
  104. package/dist/components/aspect-ratio/index.d.cts +0 -19
  105. package/dist/components/avatar/index.cjs +0 -92
  106. package/dist/components/avatar/index.d.cts +0 -24
  107. package/dist/components/badge/index.cjs +0 -67
  108. package/dist/components/badge/index.d.cts +0 -24
  109. package/dist/components/breadcrumb/index.cjs +0 -135
  110. package/dist/components/breadcrumb/index.d.cts +0 -33
  111. package/dist/components/button/index.cjs +0 -87
  112. package/dist/components/button/index.d.cts +0 -28
  113. package/dist/components/button-group/index.cjs +0 -142
  114. package/dist/components/button-group/index.d.cts +0 -33
  115. package/dist/components/card/index.cjs +0 -104
  116. package/dist/components/card/index.d.cts +0 -27
  117. package/dist/components/checkbox/index.cjs +0 -68
  118. package/dist/components/checkbox/index.d.cts +0 -17
  119. package/dist/components/collapsible/index.cjs +0 -73
  120. package/dist/components/collapsible/index.d.cts +0 -22
  121. package/dist/components/context-menu/index.cjs +0 -274
  122. package/dist/components/context-menu/index.d.cts +0 -48
  123. package/dist/components/dialog/index.cjs +0 -182
  124. package/dist/components/dialog/index.d.cts +0 -38
  125. package/dist/components/direction/index.cjs +0 -39
  126. package/dist/components/direction/index.d.cts +0 -20
  127. package/dist/components/drawer/index.cjs +0 -164
  128. package/dist/components/drawer/index.d.cts +0 -35
  129. package/dist/components/dropdown/index.cjs +0 -282
  130. package/dist/components/dropdown/index.d.cts +0 -52
  131. package/dist/components/empty/index.cjs +0 -135
  132. package/dist/components/empty/index.d.cts +0 -38
  133. package/dist/components/field/index.cjs +0 -269
  134. package/dist/components/field/index.d.cts +0 -42
  135. package/dist/components/hover-card/index.cjs +0 -77
  136. package/dist/components/hover-card/index.d.cts +0 -22
  137. package/dist/components/input/index.cjs +0 -47
  138. package/dist/components/input/index.d.cts +0 -17
  139. package/dist/components/input-group/index.cjs +0 -270
  140. package/dist/components/input-group/index.d.cts +0 -44
  141. package/dist/components/item/index.cjs +0 -262
  142. package/dist/components/item/index.d.cts +0 -47
  143. package/dist/components/kbd/index.cjs +0 -57
  144. package/dist/components/kbd/index.d.cts +0 -19
  145. package/dist/components/label/index.cjs +0 -59
  146. package/dist/components/label/index.d.cts +0 -16
  147. package/dist/components/menubar/index.cjs +0 -303
  148. package/dist/components/menubar/index.d.cts +0 -49
  149. package/dist/components/native-select/index.cjs +0 -53
  150. package/dist/components/native-select/index.d.cts +0 -19
  151. package/dist/components/navigation-menu/index.cjs +0 -215
  152. package/dist/components/navigation-menu/index.d.cts +0 -37
  153. package/dist/components/popover/index.cjs +0 -84
  154. package/dist/components/popover/index.d.cts +0 -23
  155. package/dist/components/progress/index.cjs +0 -68
  156. package/dist/components/progress/index.d.cts +0 -16
  157. package/dist/components/radio-group/index.cjs +0 -83
  158. package/dist/components/radio-group/index.d.cts +0 -22
  159. package/dist/components/resizable/index.cjs +0 -75
  160. package/dist/components/resizable/index.d.cts +0 -25
  161. package/dist/components/scroll-area/index.cjs +0 -98
  162. package/dist/components/scroll-area/index.d.cts +0 -21
  163. package/dist/components/section/index.cjs +0 -41
  164. package/dist/components/section/index.d.cts +0 -27
  165. package/dist/components/select/index.cjs +0 -215
  166. package/dist/components/select/index.d.cts +0 -36
  167. package/dist/components/separator/index.cjs +0 -63
  168. package/dist/components/separator/index.d.cts +0 -18
  169. package/dist/components/sheet/index.cjs +0 -170
  170. package/dist/components/sheet/index.d.cts +0 -31
  171. package/dist/components/skeleton/index.cjs +0 -41
  172. package/dist/components/skeleton/index.d.cts +0 -14
  173. package/dist/components/slider/index.cjs +0 -102
  174. package/dist/components/slider/index.d.cts +0 -19
  175. package/dist/components/sonner/index.cjs +0 -51
  176. package/dist/components/sonner/index.d.cts +0 -18
  177. package/dist/components/spinner/index.cjs +0 -47
  178. package/dist/components/spinner/index.d.cts +0 -17
  179. package/dist/components/switch/index.cjs +0 -68
  180. package/dist/components/switch/index.d.cts +0 -17
  181. package/dist/components/table/index.cjs +0 -147
  182. package/dist/components/table/index.d.cts +0 -35
  183. package/dist/components/tabs/index.cjs +0 -107
  184. package/dist/components/tabs/index.d.cts +0 -27
  185. package/dist/components/textarea/index.cjs +0 -44
  186. package/dist/components/textarea/index.d.cts +0 -15
  187. package/dist/components/toggle/index.cjs +0 -81
  188. package/dist/components/toggle/index.d.cts +0 -26
  189. package/dist/components/toggle-group/index.cjs +0 -120
  190. package/dist/components/toggle-group/index.d.cts +0 -27
  191. package/dist/components/tooltip/index.cjs +0 -95
  192. package/dist/components/tooltip/index.d.cts +0 -25
  193. package/dist/components/typography/index.cjs +0 -197
  194. package/dist/components/typography/index.d.cts +0 -28
  195. package/dist/index.cjs +0 -4094
  196. package/dist/index.d.cts +0 -83
@@ -1,96 +0,0 @@
1
- "use strict";
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __export = (target, all) => {
7
- for (var name in all)
8
- __defProp(target, name, { get: all[name], enumerable: true });
9
- };
10
- var __copyProps = (to, from, except, desc) => {
11
- if (from && typeof from === "object" || typeof from === "function") {
12
- for (let key of __getOwnPropNames(from))
13
- if (!__hasOwnProp.call(to, key) && key !== except)
14
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
- }
16
- return to;
17
- };
18
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
-
20
- // src/components/alert/index.tsx
21
- var alert_exports = {};
22
- __export(alert_exports, {
23
- Alert: () => Alert,
24
- AlertDescription: () => AlertDescription,
25
- AlertTitle: () => AlertTitle,
26
- alertVariants: () => alertVariants
27
- });
28
- module.exports = __toCommonJS(alert_exports);
29
- var import_utils = require("@foundrykit/utils");
30
- var import_class_variance_authority = require("class-variance-authority");
31
- var import_jsx_runtime = require("react/jsx-runtime");
32
- var alertVariants = (0, import_class_variance_authority.cva)(
33
- "relative grid w-full grid-cols-[0_1fr] items-start gap-y-0.5 rounded-lg border px-4 py-3 text-sm has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] has-[>svg]:gap-x-3 [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",
34
- {
35
- variants: {
36
- variant: {
37
- default: "bg-background text-foreground",
38
- destructive: "text-destructive bg-background *:data-[slot=alert-description]:text-destructive/90 [&>svg]:text-current"
39
- }
40
- },
41
- defaultVariants: {
42
- variant: "default"
43
- }
44
- }
45
- );
46
- function Alert({
47
- className,
48
- variant,
49
- ...props
50
- }) {
51
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
52
- "div",
53
- {
54
- "data-slot": "alert",
55
- role: "alert",
56
- className: (0, import_utils.cn)(alertVariants({ variant }), className),
57
- ...props
58
- }
59
- );
60
- }
61
- function AlertTitle({ className, ...props }) {
62
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
63
- "div",
64
- {
65
- "data-slot": "alert-title",
66
- className: (0, import_utils.cn)(
67
- "col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight",
68
- className
69
- ),
70
- ...props
71
- }
72
- );
73
- }
74
- function AlertDescription({
75
- className,
76
- ...props
77
- }) {
78
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
79
- "div",
80
- {
81
- "data-slot": "alert-description",
82
- className: (0, import_utils.cn)(
83
- "text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",
84
- className
85
- ),
86
- ...props
87
- }
88
- );
89
- }
90
- // Annotate the CommonJS export names for ESM import in node:
91
- 0 && (module.exports = {
92
- Alert,
93
- AlertDescription,
94
- AlertTitle,
95
- alertVariants
96
- });
@@ -1,28 +0,0 @@
1
- import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import * as class_variance_authority_types from 'class-variance-authority/types';
3
- import { VariantProps } from 'class-variance-authority';
4
- import * as React from 'react';
5
-
6
- declare const alertVariants: (props?: ({
7
- variant?: "default" | "destructive" | null | undefined;
8
- } & class_variance_authority_types.ClassProp) | undefined) => string;
9
- /**
10
- * Callout banner for surfacing a short, important message. Compose with
11
- * {@link AlertTitle} and {@link AlertDescription}, and optionally lead with a
12
- * lucide icon. Styled via {@link alertVariants} with a `variant`
13
- * (default, destructive).
14
- *
15
- * @example
16
- * ```tsx
17
- * <Alert variant="destructive">
18
- * <AlertCircleIcon />
19
- * <AlertTitle>Something went wrong</AlertTitle>
20
- * <AlertDescription>Please try again later.</AlertDescription>
21
- * </Alert>
22
- * ```
23
- */
24
- declare function Alert({ className, variant, ...props }: React.ComponentProps<'div'> & VariantProps<typeof alertVariants>): react_jsx_runtime.JSX.Element;
25
- declare function AlertTitle({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
26
- declare function AlertDescription({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
27
-
28
- export { Alert, AlertDescription, AlertTitle, alertVariants };
@@ -1,200 +0,0 @@
1
- "use strict";
2
- "use client";
3
- var __create = Object.create;
4
- var __defProp = Object.defineProperty;
5
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
- var __getOwnPropNames = Object.getOwnPropertyNames;
7
- var __getProtoOf = Object.getPrototypeOf;
8
- var __hasOwnProp = Object.prototype.hasOwnProperty;
9
- var __export = (target, all) => {
10
- for (var name in all)
11
- __defProp(target, name, { get: all[name], enumerable: true });
12
- };
13
- var __copyProps = (to, from, except, desc) => {
14
- if (from && typeof from === "object" || typeof from === "function") {
15
- for (let key of __getOwnPropNames(from))
16
- if (!__hasOwnProp.call(to, key) && key !== except)
17
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
18
- }
19
- return to;
20
- };
21
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
22
- // If the importer is in node compatibility mode or this is not an ESM
23
- // file that has been converted to a CommonJS file using a Babel-
24
- // compatible transform (i.e. "__esModule" has not been set), then set
25
- // "default" to the CommonJS "module.exports" for node compatibility.
26
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
27
- mod
28
- ));
29
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
30
-
31
- // src/components/alert-dialog/index.tsx
32
- var alert_dialog_exports = {};
33
- __export(alert_dialog_exports, {
34
- AlertDialog: () => AlertDialog,
35
- AlertDialogAction: () => AlertDialogAction,
36
- AlertDialogCancel: () => AlertDialogCancel,
37
- AlertDialogContent: () => AlertDialogContent,
38
- AlertDialogDescription: () => AlertDialogDescription,
39
- AlertDialogFooter: () => AlertDialogFooter,
40
- AlertDialogHeader: () => AlertDialogHeader,
41
- AlertDialogOverlay: () => AlertDialogOverlay,
42
- AlertDialogPortal: () => AlertDialogPortal,
43
- AlertDialogTitle: () => AlertDialogTitle,
44
- AlertDialogTrigger: () => AlertDialogTrigger
45
- });
46
- module.exports = __toCommonJS(alert_dialog_exports);
47
- var import_utils = require("@foundrykit/utils");
48
- var AlertDialogPrimitive = __toESM(require("@radix-ui/react-alert-dialog"), 1);
49
- var import_jsx_runtime = require("react/jsx-runtime");
50
- function AlertDialog({
51
- ...props
52
- }) {
53
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDialogPrimitive.Root, { "data-slot": "alert-dialog", ...props });
54
- }
55
- function AlertDialogTrigger({
56
- ...props
57
- }) {
58
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDialogPrimitive.Trigger, { "data-slot": "alert-dialog-trigger", ...props });
59
- }
60
- function AlertDialogPortal({
61
- ...props
62
- }) {
63
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDialogPrimitive.Portal, { "data-slot": "alert-dialog-portal", ...props });
64
- }
65
- function AlertDialogOverlay({
66
- className,
67
- ...props
68
- }) {
69
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
70
- AlertDialogPrimitive.Overlay,
71
- {
72
- "data-slot": "alert-dialog-overlay",
73
- className: (0, import_utils.cn)(
74
- "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",
75
- className
76
- ),
77
- ...props
78
- }
79
- );
80
- }
81
- function AlertDialogContent({
82
- className,
83
- ...props
84
- }) {
85
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(AlertDialogPortal, { children: [
86
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AlertDialogOverlay, {}),
87
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
88
- AlertDialogPrimitive.Content,
89
- {
90
- "data-slot": "alert-dialog-content",
91
- className: (0, import_utils.cn)(
92
- "bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 motion-safe:data-[state=closed]:zoom-out-95 motion-safe:data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg",
93
- className
94
- ),
95
- ...props
96
- }
97
- )
98
- ] });
99
- }
100
- function AlertDialogHeader({
101
- className,
102
- ...props
103
- }) {
104
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
105
- "div",
106
- {
107
- "data-slot": "alert-dialog-header",
108
- className: (0, import_utils.cn)("flex flex-col gap-2 text-center sm:text-left", className),
109
- ...props
110
- }
111
- );
112
- }
113
- function AlertDialogFooter({
114
- className,
115
- ...props
116
- }) {
117
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
118
- "div",
119
- {
120
- "data-slot": "alert-dialog-footer",
121
- className: (0, import_utils.cn)(
122
- "flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",
123
- className
124
- ),
125
- ...props
126
- }
127
- );
128
- }
129
- function AlertDialogTitle({
130
- className,
131
- ...props
132
- }) {
133
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
134
- AlertDialogPrimitive.Title,
135
- {
136
- "data-slot": "alert-dialog-title",
137
- className: (0, import_utils.cn)("text-lg font-semibold", className),
138
- ...props
139
- }
140
- );
141
- }
142
- function AlertDialogDescription({
143
- className,
144
- ...props
145
- }) {
146
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
147
- AlertDialogPrimitive.Description,
148
- {
149
- "data-slot": "alert-dialog-description",
150
- className: (0, import_utils.cn)("text-muted-foreground text-sm", className),
151
- ...props
152
- }
153
- );
154
- }
155
- function AlertDialogAction({
156
- className,
157
- ...props
158
- }) {
159
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
160
- AlertDialogPrimitive.Action,
161
- {
162
- "data-slot": "alert-dialog-action",
163
- className: (0, import_utils.cn)(
164
- "bg-primary text-primary-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive hover:bg-primary/90 inline-flex h-9 shrink-0 items-center justify-center gap-2 rounded-md px-4 py-2 text-sm font-medium whitespace-nowrap shadow-xs transition-all outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 has-[>svg]:px-3 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
165
- className
166
- ),
167
- ...props
168
- }
169
- );
170
- }
171
- function AlertDialogCancel({
172
- className,
173
- ...props
174
- }) {
175
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
176
- AlertDialogPrimitive.Cancel,
177
- {
178
- "data-slot": "alert-dialog-cancel",
179
- className: (0, import_utils.cn)(
180
- "bg-background focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:border-input dark:hover:bg-input/50 hover:bg-accent hover:text-accent-foreground inline-flex h-9 shrink-0 items-center justify-center gap-2 rounded-md border px-4 py-2 text-sm font-medium whitespace-nowrap shadow-xs transition-all outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 has-[>svg]:px-3 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
181
- className
182
- ),
183
- ...props
184
- }
185
- );
186
- }
187
- // Annotate the CommonJS export names for ESM import in node:
188
- 0 && (module.exports = {
189
- AlertDialog,
190
- AlertDialogAction,
191
- AlertDialogCancel,
192
- AlertDialogContent,
193
- AlertDialogDescription,
194
- AlertDialogFooter,
195
- AlertDialogHeader,
196
- AlertDialogOverlay,
197
- AlertDialogPortal,
198
- AlertDialogTitle,
199
- AlertDialogTrigger
200
- });
@@ -1,42 +0,0 @@
1
- import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import * as AlertDialogPrimitive from '@radix-ui/react-alert-dialog';
3
- import * as React from 'react';
4
-
5
- /**
6
- * Modal confirmation dialog built on Radix `AlertDialog.Root` that interrupts
7
- * the user with important content and expects a response. Compose with
8
- * {@link AlertDialogTrigger}, {@link AlertDialogContent},
9
- * {@link AlertDialogHeader}, {@link AlertDialogFooter},
10
- * {@link AlertDialogTitle}, {@link AlertDialogDescription},
11
- * {@link AlertDialogAction} and {@link AlertDialogCancel}.
12
- *
13
- * @example
14
- * ```tsx
15
- * <AlertDialog>
16
- * <AlertDialogTrigger>Delete</AlertDialogTrigger>
17
- * <AlertDialogContent>
18
- * <AlertDialogHeader>
19
- * <AlertDialogTitle>Are you sure?</AlertDialogTitle>
20
- * <AlertDialogDescription>This cannot be undone.</AlertDialogDescription>
21
- * </AlertDialogHeader>
22
- * <AlertDialogFooter>
23
- * <AlertDialogCancel>Cancel</AlertDialogCancel>
24
- * <AlertDialogAction>Continue</AlertDialogAction>
25
- * </AlertDialogFooter>
26
- * </AlertDialogContent>
27
- * </AlertDialog>
28
- * ```
29
- */
30
- declare function AlertDialog({ ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Root>): react_jsx_runtime.JSX.Element;
31
- declare function AlertDialogTrigger({ ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Trigger>): react_jsx_runtime.JSX.Element;
32
- declare function AlertDialogPortal({ ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Portal>): react_jsx_runtime.JSX.Element;
33
- declare function AlertDialogOverlay({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Overlay>): react_jsx_runtime.JSX.Element;
34
- declare function AlertDialogContent({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Content>): react_jsx_runtime.JSX.Element;
35
- declare function AlertDialogHeader({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
36
- declare function AlertDialogFooter({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
37
- declare function AlertDialogTitle({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Title>): react_jsx_runtime.JSX.Element;
38
- declare function AlertDialogDescription({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Description>): react_jsx_runtime.JSX.Element;
39
- declare function AlertDialogAction({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Action>): react_jsx_runtime.JSX.Element;
40
- declare function AlertDialogCancel({ className, ...props }: React.ComponentProps<typeof AlertDialogPrimitive.Cancel>): react_jsx_runtime.JSX.Element;
41
-
42
- export { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger };
@@ -1,47 +0,0 @@
1
- "use strict";
2
- "use client";
3
- var __create = Object.create;
4
- var __defProp = Object.defineProperty;
5
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
- var __getOwnPropNames = Object.getOwnPropertyNames;
7
- var __getProtoOf = Object.getPrototypeOf;
8
- var __hasOwnProp = Object.prototype.hasOwnProperty;
9
- var __export = (target, all) => {
10
- for (var name in all)
11
- __defProp(target, name, { get: all[name], enumerable: true });
12
- };
13
- var __copyProps = (to, from, except, desc) => {
14
- if (from && typeof from === "object" || typeof from === "function") {
15
- for (let key of __getOwnPropNames(from))
16
- if (!__hasOwnProp.call(to, key) && key !== except)
17
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
18
- }
19
- return to;
20
- };
21
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
22
- // If the importer is in node compatibility mode or this is not an ESM
23
- // file that has been converted to a CommonJS file using a Babel-
24
- // compatible transform (i.e. "__esModule" has not been set), then set
25
- // "default" to the CommonJS "module.exports" for node compatibility.
26
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
27
- mod
28
- ));
29
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
30
-
31
- // src/components/aspect-ratio/index.tsx
32
- var aspect_ratio_exports = {};
33
- __export(aspect_ratio_exports, {
34
- AspectRatio: () => AspectRatio
35
- });
36
- module.exports = __toCommonJS(aspect_ratio_exports);
37
- var AspectRatioPrimitive = __toESM(require("@radix-ui/react-aspect-ratio"), 1);
38
- var import_jsx_runtime = require("react/jsx-runtime");
39
- function AspectRatio({
40
- ...props
41
- }) {
42
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AspectRatioPrimitive.Root, { "data-slot": "aspect-ratio", ...props });
43
- }
44
- // Annotate the CommonJS export names for ESM import in node:
45
- 0 && (module.exports = {
46
- AspectRatio
47
- });
@@ -1,19 +0,0 @@
1
- import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import * as AspectRatioPrimitive from '@radix-ui/react-aspect-ratio';
3
- import * as React from 'react';
4
-
5
- /**
6
- * Constrains its content to a given width-to-height `ratio`, built on Radix
7
- * `AspectRatio.Root`. Handy for images, video embeds and media placeholders
8
- * that must keep a consistent shape as they scale.
9
- *
10
- * @example
11
- * ```tsx
12
- * <AspectRatio ratio={16 / 9}>
13
- * <img src="/cover.jpg" alt="Cover" className="h-full w-full object-cover" />
14
- * </AspectRatio>
15
- * ```
16
- */
17
- declare function AspectRatio({ ...props }: React.ComponentProps<typeof AspectRatioPrimitive.Root>): react_jsx_runtime.JSX.Element;
18
-
19
- export { AspectRatio };
@@ -1,92 +0,0 @@
1
- "use strict";
2
- "use client";
3
- var __create = Object.create;
4
- var __defProp = Object.defineProperty;
5
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
- var __getOwnPropNames = Object.getOwnPropertyNames;
7
- var __getProtoOf = Object.getPrototypeOf;
8
- var __hasOwnProp = Object.prototype.hasOwnProperty;
9
- var __export = (target, all) => {
10
- for (var name in all)
11
- __defProp(target, name, { get: all[name], enumerable: true });
12
- };
13
- var __copyProps = (to, from, except, desc) => {
14
- if (from && typeof from === "object" || typeof from === "function") {
15
- for (let key of __getOwnPropNames(from))
16
- if (!__hasOwnProp.call(to, key) && key !== except)
17
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
18
- }
19
- return to;
20
- };
21
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
22
- // If the importer is in node compatibility mode or this is not an ESM
23
- // file that has been converted to a CommonJS file using a Babel-
24
- // compatible transform (i.e. "__esModule" has not been set), then set
25
- // "default" to the CommonJS "module.exports" for node compatibility.
26
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
27
- mod
28
- ));
29
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
30
-
31
- // src/components/avatar/index.tsx
32
- var avatar_exports = {};
33
- __export(avatar_exports, {
34
- Avatar: () => Avatar,
35
- AvatarFallback: () => AvatarFallback,
36
- AvatarImage: () => AvatarImage
37
- });
38
- module.exports = __toCommonJS(avatar_exports);
39
- var import_utils = require("@foundrykit/utils");
40
- var AvatarPrimitive = __toESM(require("@radix-ui/react-avatar"), 1);
41
- var import_jsx_runtime = require("react/jsx-runtime");
42
- function Avatar({
43
- className,
44
- ...props
45
- }) {
46
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
47
- AvatarPrimitive.Root,
48
- {
49
- "data-slot": "avatar",
50
- className: (0, import_utils.cn)(
51
- "relative flex size-8 shrink-0 overflow-hidden rounded-full",
52
- className
53
- ),
54
- ...props
55
- }
56
- );
57
- }
58
- function AvatarImage({
59
- className,
60
- ...props
61
- }) {
62
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
63
- AvatarPrimitive.Image,
64
- {
65
- "data-slot": "avatar-image",
66
- className: (0, import_utils.cn)("aspect-square size-full", className),
67
- ...props
68
- }
69
- );
70
- }
71
- function AvatarFallback({
72
- className,
73
- ...props
74
- }) {
75
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
76
- AvatarPrimitive.Fallback,
77
- {
78
- "data-slot": "avatar-fallback",
79
- className: (0, import_utils.cn)(
80
- "bg-muted flex size-full items-center justify-center rounded-full",
81
- className
82
- ),
83
- ...props
84
- }
85
- );
86
- }
87
- // Annotate the CommonJS export names for ESM import in node:
88
- 0 && (module.exports = {
89
- Avatar,
90
- AvatarFallback,
91
- AvatarImage
92
- });
@@ -1,24 +0,0 @@
1
- import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import * as AvatarPrimitive from '@radix-ui/react-avatar';
3
- import * as React from 'react';
4
-
5
- /**
6
- * Circular avatar container built on Radix `Avatar.Root`. Compose with
7
- * {@link AvatarImage} and {@link AvatarFallback}; the fallback shows while the
8
- * image is loading or unavailable. Defaults to a `size-8` rounded shape.
9
- *
10
- * @example
11
- * ```tsx
12
- * <Avatar>
13
- * <AvatarImage src="/user.png" alt="Jane" />
14
- * <AvatarFallback>JD</AvatarFallback>
15
- * </Avatar>
16
- * ```
17
- */
18
- declare function Avatar({ className, ...props }: React.ComponentProps<typeof AvatarPrimitive.Root>): react_jsx_runtime.JSX.Element;
19
- /** Image element (Radix `Avatar.Image`) rendered inside an {@link Avatar}. */
20
- declare function AvatarImage({ className, ...props }: React.ComponentProps<typeof AvatarPrimitive.Image>): react_jsx_runtime.JSX.Element;
21
- /** Fallback (Radix `Avatar.Fallback`) shown when the image cannot be displayed. */
22
- declare function AvatarFallback({ className, ...props }: React.ComponentProps<typeof AvatarPrimitive.Fallback>): react_jsx_runtime.JSX.Element;
23
-
24
- export { Avatar, AvatarFallback, AvatarImage };
@@ -1,67 +0,0 @@
1
- "use strict";
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __export = (target, all) => {
7
- for (var name in all)
8
- __defProp(target, name, { get: all[name], enumerable: true });
9
- };
10
- var __copyProps = (to, from, except, desc) => {
11
- if (from && typeof from === "object" || typeof from === "function") {
12
- for (let key of __getOwnPropNames(from))
13
- if (!__hasOwnProp.call(to, key) && key !== except)
14
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
- }
16
- return to;
17
- };
18
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
-
20
- // src/components/badge/index.tsx
21
- var badge_exports = {};
22
- __export(badge_exports, {
23
- Badge: () => Badge,
24
- badgeVariants: () => badgeVariants
25
- });
26
- module.exports = __toCommonJS(badge_exports);
27
- var import_utils = require("@foundrykit/utils");
28
- var import_react_slot = require("@radix-ui/react-slot");
29
- var import_class_variance_authority = require("class-variance-authority");
30
- var import_jsx_runtime = require("react/jsx-runtime");
31
- var badgeVariants = (0, import_class_variance_authority.cva)(
32
- "focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-md border px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] [&>svg]:pointer-events-none [&>svg]:size-3",
33
- {
34
- variants: {
35
- variant: {
36
- default: "bg-primary text-primary-foreground [a&]:hover:bg-primary/90 border-transparent",
37
- secondary: "bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90 border-transparent",
38
- destructive: "bg-destructive [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60 border-transparent text-white",
39
- outline: "text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground"
40
- }
41
- },
42
- defaultVariants: {
43
- variant: "default"
44
- }
45
- }
46
- );
47
- function Badge({
48
- className,
49
- variant,
50
- asChild = false,
51
- ...props
52
- }) {
53
- const Comp = asChild ? import_react_slot.Slot : "span";
54
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
55
- Comp,
56
- {
57
- "data-slot": "badge",
58
- className: (0, import_utils.cn)(badgeVariants({ variant }), className),
59
- ...props
60
- }
61
- );
62
- }
63
- // Annotate the CommonJS export names for ESM import in node:
64
- 0 && (module.exports = {
65
- Badge,
66
- badgeVariants
67
- });
@@ -1,24 +0,0 @@
1
- import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import * as class_variance_authority_types from 'class-variance-authority/types';
3
- import { VariantProps } from 'class-variance-authority';
4
- import * as React from 'react';
5
-
6
- declare const badgeVariants: (props?: ({
7
- variant?: "default" | "destructive" | "secondary" | "outline" | null | undefined;
8
- } & class_variance_authority_types.ClassProp) | undefined) => string;
9
- /**
10
- * Small inline label/status indicator styled via {@link badgeVariants} with a
11
- * `variant` (default, secondary, destructive, outline). Renders a `<span>` by
12
- * default; pass `asChild` to render another element (e.g. a link) via Radix
13
- * `Slot` while keeping the badge styling.
14
- *
15
- * @example
16
- * ```tsx
17
- * <Badge variant="secondary">Beta</Badge>
18
- * ```
19
- */
20
- declare function Badge({ className, variant, asChild, ...props }: React.ComponentProps<'span'> & VariantProps<typeof badgeVariants> & {
21
- asChild?: boolean;
22
- }): react_jsx_runtime.JSX.Element;
23
-
24
- export { Badge, badgeVariants };