@codefast/ui 0.3.11-canary.1 → 0.3.11

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 (149) hide show
  1. package/CHANGELOG.md +36 -0
  2. package/README.md +34 -14
  3. package/dist/components/accordion.d.ts +29 -10
  4. package/dist/components/accordion.js +38 -37
  5. package/dist/components/alert-dialog.d.ts +60 -24
  6. package/dist/components/alert-dialog.js +69 -72
  7. package/dist/components/alert.d.ts +27 -15
  8. package/dist/components/alert.js +29 -31
  9. package/dist/components/aspect-ratio.d.ts +8 -4
  10. package/dist/components/aspect-ratio.js +7 -5
  11. package/dist/components/avatar.d.ts +17 -6
  12. package/dist/components/avatar.js +19 -17
  13. package/dist/components/badge.d.ts +21 -14
  14. package/dist/components/badge.js +19 -22
  15. package/dist/components/breadcrumb.d.ts +35 -12
  16. package/dist/components/breadcrumb.js +48 -54
  17. package/dist/components/button-group.d.ts +29 -14
  18. package/dist/components/button-group.js +27 -32
  19. package/dist/components/button.d.ts +35 -25
  20. package/dist/components/button.js +50 -48
  21. package/dist/components/calendar.d.ts +24 -9
  22. package/dist/components/calendar.js +92 -98
  23. package/dist/components/card.d.ts +34 -10
  24. package/dist/components/card.js +39 -37
  25. package/dist/components/carousel.d.ts +55 -24
  26. package/dist/components/carousel.js +113 -130
  27. package/dist/components/chart.d.ts +72 -36
  28. package/dist/components/chart.js +154 -166
  29. package/dist/components/checkbox-cards.d.ts +15 -8
  30. package/dist/components/checkbox-cards.js +22 -25
  31. package/dist/components/checkbox-group.d.ts +16 -8
  32. package/dist/components/checkbox-group.js +19 -19
  33. package/dist/components/checkbox.d.ts +9 -4
  34. package/dist/components/checkbox.js +14 -14
  35. package/dist/components/collapsible.d.ts +14 -6
  36. package/dist/components/collapsible.js +18 -16
  37. package/dist/components/command.d.ts +55 -23
  38. package/dist/components/command.js +70 -85
  39. package/dist/components/context-menu.d.ts +72 -22
  40. package/dist/components/context-menu.js +88 -109
  41. package/dist/components/dialog.d.ts +53 -22
  42. package/dist/components/dialog.js +71 -85
  43. package/dist/components/drawer.d.ts +60 -28
  44. package/dist/components/drawer.js +59 -67
  45. package/dist/components/dropdown-menu.d.ts +73 -22
  46. package/dist/components/dropdown-menu.js +95 -112
  47. package/dist/components/empty.d.ts +37 -15
  48. package/dist/components/empty.js +43 -45
  49. package/dist/components/field.d.ts +63 -25
  50. package/dist/components/field.js +88 -104
  51. package/dist/components/form.d.ts +37 -15
  52. package/dist/components/form.js +65 -70
  53. package/dist/components/hover-card.d.ts +21 -7
  54. package/dist/components/hover-card.js +24 -24
  55. package/dist/components/input-group.d.ts +53 -28
  56. package/dist/components/input-group.js +63 -77
  57. package/dist/components/input-number.d.ts +28 -7
  58. package/dist/components/input-number.js +55 -59
  59. package/dist/components/input-otp.d.ts +24 -10
  60. package/dist/components/input-otp.js +33 -37
  61. package/dist/components/input-password.d.ts +12 -5
  62. package/dist/components/input-password.js +31 -32
  63. package/dist/components/input-search.d.ts +18 -8
  64. package/dist/components/input-search.js +43 -41
  65. package/dist/components/input.d.ts +10 -4
  66. package/dist/components/input.js +9 -7
  67. package/dist/components/item.d.ts +69 -32
  68. package/dist/components/item.js +89 -92
  69. package/dist/components/kbd.d.ts +13 -5
  70. package/dist/components/kbd.js +13 -11
  71. package/dist/components/label.d.ts +9 -4
  72. package/dist/components/label.js +9 -7
  73. package/dist/components/menubar.d.ts +80 -23
  74. package/dist/components/menubar.js +97 -118
  75. package/dist/components/native-select.d.ts +16 -6
  76. package/dist/components/native-select.js +25 -26
  77. package/dist/components/navigation-menu.d.ts +36 -12
  78. package/dist/components/navigation-menu.js +60 -75
  79. package/dist/components/pagination.d.ts +35 -14
  80. package/dist/components/pagination.js +54 -69
  81. package/dist/components/popover.d.ts +24 -8
  82. package/dist/components/popover.js +28 -28
  83. package/dist/components/progress-circle.d.ts +106 -88
  84. package/dist/components/progress-circle.js +106 -138
  85. package/dist/components/progress.d.ts +10 -4
  86. package/dist/components/progress.js +14 -14
  87. package/dist/components/radio-cards.d.ts +10 -4
  88. package/dist/components/radio-cards.js +22 -23
  89. package/dist/components/radio-group.d.ts +13 -5
  90. package/dist/components/radio-group.js +18 -16
  91. package/dist/components/radio.d.ts +12 -5
  92. package/dist/components/radio.js +10 -8
  93. package/dist/components/resizable.d.ts +18 -7
  94. package/dist/components/resizable.js +22 -22
  95. package/dist/components/scroll-area.d.ts +33 -20
  96. package/dist/components/scroll-area.js +84 -88
  97. package/dist/components/select.d.ts +50 -16
  98. package/dist/components/select.js +77 -96
  99. package/dist/components/separator.d.ts +29 -19
  100. package/dist/components/separator.js +36 -34
  101. package/dist/components/sheet.d.ts +62 -29
  102. package/dist/components/sheet.js +79 -100
  103. package/dist/components/sidebar.d.ts +160 -66
  104. package/dist/components/sidebar.js +294 -336
  105. package/dist/components/skeleton.d.ts +9 -4
  106. package/dist/components/skeleton.js +8 -6
  107. package/dist/components/slider.d.ts +13 -4
  108. package/dist/components/slider.js +34 -40
  109. package/dist/components/sonner.d.ts +10 -7
  110. package/dist/components/sonner.js +16 -14
  111. package/dist/components/spinner.d.ts +12 -5
  112. package/dist/components/spinner.js +33 -35
  113. package/dist/components/switch.d.ts +9 -4
  114. package/dist/components/switch.js +13 -11
  115. package/dist/components/table.d.ts +37 -11
  116. package/dist/components/table.js +47 -45
  117. package/dist/components/tabs.d.ts +21 -7
  118. package/dist/components/tabs.js +24 -22
  119. package/dist/components/textarea.d.ts +9 -4
  120. package/dist/components/textarea.js +8 -6
  121. package/dist/components/toggle-group.d.ts +24 -9
  122. package/dist/components/toggle-group.js +41 -42
  123. package/dist/components/toggle.d.ts +25 -17
  124. package/dist/components/toggle.js +30 -28
  125. package/dist/components/tooltip.d.ts +24 -8
  126. package/dist/components/tooltip.js +29 -32
  127. package/dist/hooks/use-animated-value.d.ts +4 -1
  128. package/dist/hooks/use-animated-value.js +57 -36
  129. package/dist/hooks/use-copy-to-clipboard.d.ts +11 -5
  130. package/dist/hooks/use-copy-to-clipboard.js +39 -20
  131. package/dist/hooks/use-is-mobile.d.ts +4 -1
  132. package/dist/hooks/use-is-mobile.js +21 -1
  133. package/dist/hooks/use-media-query.d.ts +4 -1
  134. package/dist/hooks/use-media-query.js +45 -18
  135. package/dist/hooks/use-mutation-observer.d.ts +6 -2
  136. package/dist/hooks/use-mutation-observer.js +34 -16
  137. package/dist/hooks/use-pagination.d.ts +22 -14
  138. package/dist/hooks/use-pagination.js +100 -49
  139. package/dist/index.d.ts +69 -130
  140. package/dist/index.js +11 -11
  141. package/dist/primitives/checkbox-group.d.ts +105 -83
  142. package/dist/primitives/checkbox-group.js +111 -84
  143. package/dist/primitives/input-number.d.ts +51 -40
  144. package/dist/primitives/input-number.js +483 -350
  145. package/dist/primitives/input.d.ts +48 -42
  146. package/dist/primitives/input.js +65 -43
  147. package/dist/primitives/progress-circle.d.ts +79 -48
  148. package/dist/primitives/progress-circle.js +154 -105
  149. package/package.json +6 -7
@@ -1,22 +1,24 @@
1
1
  "use client";
2
2
  import { jsx } from "react/jsx-runtime";
3
- import { CollapsibleContent, CollapsibleTrigger, Root } from "@radix-ui/react-collapsible";
3
+ import * as CollapsiblePrimitive from "@radix-ui/react-collapsible";
4
+ //#region src/components/collapsible.tsx
4
5
  function Collapsible({ ...props }) {
5
- return /*#__PURE__*/ jsx(Root, {
6
- "data-slot": "collapsible",
7
- ...props
8
- });
6
+ return /* @__PURE__ */ jsx(CollapsiblePrimitive.Root, {
7
+ "data-slot": "collapsible",
8
+ ...props
9
+ });
9
10
  }
10
- function collapsible_CollapsibleTrigger({ ...props }) {
11
- return /*#__PURE__*/ jsx(CollapsibleTrigger, {
12
- "data-slot": "collapsible-trigger",
13
- ...props
14
- });
11
+ function CollapsibleTrigger({ ...props }) {
12
+ return /* @__PURE__ */ jsx(CollapsiblePrimitive.CollapsibleTrigger, {
13
+ "data-slot": "collapsible-trigger",
14
+ ...props
15
+ });
15
16
  }
16
- function collapsible_CollapsibleContent({ ...props }) {
17
- return /*#__PURE__*/ jsx(CollapsibleContent, {
18
- "data-slot": "collapsible-content",
19
- ...props
20
- });
17
+ function CollapsibleContent({ ...props }) {
18
+ return /* @__PURE__ */ jsx(CollapsiblePrimitive.CollapsibleContent, {
19
+ "data-slot": "collapsible-content",
20
+ ...props
21
+ });
21
22
  }
22
- export { Collapsible, collapsible_CollapsibleContent as CollapsibleContent, collapsible_CollapsibleTrigger as CollapsibleTrigger };
23
+ //#endregion
24
+ export { Collapsible, CollapsibleContent, CollapsibleTrigger };
@@ -1,25 +1,57 @@
1
- import type { ComponentProps, JSX } from "react";
2
- import { Command as CommandPrimitive } from "cmdk";
3
- import { Dialog } from "./dialog";
4
- type CommandProps = ComponentProps<typeof CommandPrimitive>;
5
- declare function Command({ className, ...props }: CommandProps): JSX.Element;
1
+ import { Dialog } from "./dialog.js";
2
+ import { ComponentProps, JSX } from "react";
3
+ import { Command as Command$1 } from "cmdk";
4
+
5
+ //#region src/components/command.d.ts
6
+ type CommandProps = ComponentProps<typeof Command$1>;
7
+ declare function Command({
8
+ className,
9
+ ...props
10
+ }: CommandProps): JSX.Element;
6
11
  type CommandDialogProps = ComponentProps<typeof Dialog>;
7
- declare function CommandDialog({ children, ...props }: CommandDialogProps): JSX.Element;
8
- type CommandInputProps = ComponentProps<typeof CommandPrimitive.Input>;
9
- declare function CommandInput({ className, ...props }: CommandInputProps): JSX.Element;
10
- type CommandListProps = ComponentProps<typeof CommandPrimitive.List>;
11
- declare function CommandList({ className, ...props }: CommandListProps): JSX.Element;
12
- type CommandEmptyProps = ComponentProps<typeof CommandPrimitive.Empty>;
13
- declare function CommandEmpty({ className, ...props }: CommandEmptyProps): JSX.Element;
14
- type CommandGroupProps = ComponentProps<typeof CommandPrimitive.Group>;
15
- declare function CommandGroup({ className, ...props }: CommandGroupProps): JSX.Element;
16
- type CommandSeparatorProps = ComponentProps<typeof CommandPrimitive.Separator>;
17
- declare function CommandSeparator({ className, ...props }: CommandSeparatorProps): JSX.Element;
18
- type CommandItemProps = ComponentProps<typeof CommandPrimitive.Item>;
19
- declare function CommandItem({ className, ...props }: CommandItemProps): JSX.Element;
20
- type CommandLoadingProps = ComponentProps<typeof CommandPrimitive.Loading>;
21
- declare function CommandLoading({ className, ...props }: CommandLoadingProps): JSX.Element;
12
+ declare function CommandDialog({
13
+ children,
14
+ ...props
15
+ }: CommandDialogProps): JSX.Element;
16
+ type CommandInputProps = ComponentProps<typeof Command$1.Input>;
17
+ declare function CommandInput({
18
+ className,
19
+ ...props
20
+ }: CommandInputProps): JSX.Element;
21
+ type CommandListProps = ComponentProps<typeof Command$1.List>;
22
+ declare function CommandList({
23
+ className,
24
+ ...props
25
+ }: CommandListProps): JSX.Element;
26
+ type CommandEmptyProps = ComponentProps<typeof Command$1.Empty>;
27
+ declare function CommandEmpty({
28
+ className,
29
+ ...props
30
+ }: CommandEmptyProps): JSX.Element;
31
+ type CommandGroupProps = ComponentProps<typeof Command$1.Group>;
32
+ declare function CommandGroup({
33
+ className,
34
+ ...props
35
+ }: CommandGroupProps): JSX.Element;
36
+ type CommandSeparatorProps = ComponentProps<typeof Command$1.Separator>;
37
+ declare function CommandSeparator({
38
+ className,
39
+ ...props
40
+ }: CommandSeparatorProps): JSX.Element;
41
+ type CommandItemProps = ComponentProps<typeof Command$1.Item>;
42
+ declare function CommandItem({
43
+ className,
44
+ ...props
45
+ }: CommandItemProps): JSX.Element;
46
+ type CommandLoadingProps = ComponentProps<typeof Command$1.Loading>;
47
+ declare function CommandLoading({
48
+ className,
49
+ ...props
50
+ }: CommandLoadingProps): JSX.Element;
22
51
  type CommandShortcutProps = ComponentProps<"span">;
23
- declare function CommandShortcut({ className, ...props }: CommandShortcutProps): JSX.Element;
24
- export { Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandLoading, CommandSeparator, CommandShortcut, };
25
- export type { CommandDialogProps, CommandEmptyProps, CommandGroupProps, CommandInputProps, CommandItemProps, CommandListProps, CommandLoadingProps, CommandProps, CommandSeparatorProps, CommandShortcutProps, };
52
+ declare function CommandShortcut({
53
+ className,
54
+ ...props
55
+ }: CommandShortcutProps): JSX.Element;
56
+ //#endregion
57
+ export { Command, CommandDialog, type CommandDialogProps, CommandEmpty, type CommandEmptyProps, CommandGroup, type CommandGroupProps, CommandInput, type CommandInputProps, CommandItem, type CommandItemProps, CommandList, type CommandListProps, CommandLoading, type CommandLoadingProps, type CommandProps, CommandSeparator, type CommandSeparatorProps, CommandShortcut, type CommandShortcutProps };
@@ -1,107 +1,92 @@
1
1
  "use client";
2
- import { jsx, jsxs } from "react/jsx-runtime";
2
+ import { Dialog, DialogContent, DialogDescription, DialogTitle } from "./dialog.js";
3
3
  import { cn } from "@codefast/tailwind-variants";
4
- import { VisuallyHidden } from "@radix-ui/react-visually-hidden";
5
- import { Command } from "cmdk";
6
4
  import { SearchIcon } from "lucide-react";
7
- import { Dialog, DialogContent, DialogDescription, DialogTitle } from "./dialog.js";
8
- function command_Command({ className, ...props }) {
9
- return /*#__PURE__*/ jsx(Command, {
10
- className: cn("flex flex-col overflow-hidden rounded-[inherit] bg-popover text-popover-foreground outline-hidden", className),
11
- "data-slot": "command",
12
- ...props
13
- });
5
+ import { jsx, jsxs } from "react/jsx-runtime";
6
+ import { VisuallyHidden } from "@radix-ui/react-visually-hidden";
7
+ import { Command as Command$1 } from "cmdk";
8
+ //#region src/components/command.tsx
9
+ function Command({ className, ...props }) {
10
+ return /* @__PURE__ */ jsx(Command$1, {
11
+ className: cn("flex flex-col overflow-hidden rounded-[inherit] bg-popover text-popover-foreground outline-hidden", className),
12
+ "data-slot": "command",
13
+ ...props
14
+ });
14
15
  }
15
16
  function CommandDialog({ children, ...props }) {
16
- return /*#__PURE__*/ jsx(Dialog, {
17
- "data-slot": "command-dialog",
18
- ...props,
19
- children: /*#__PURE__*/ jsxs(DialogContent, {
20
- className: "rounded-t-lg sm:rounded-lg",
21
- "data-slot": "command-dialog-content",
22
- children: [
23
- /*#__PURE__*/ jsxs(VisuallyHidden, {
24
- children: [
25
- /*#__PURE__*/ jsx(DialogTitle, {
26
- children: "Search command"
27
- }),
28
- /*#__PURE__*/ jsx(DialogDescription, {
29
- children: "Use the search bar to find and select the desired command."
30
- })
31
- ]
32
- }),
33
- /*#__PURE__*/ jsx(command_Command, {
34
- className: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-input]]:h-12",
35
- children: children
36
- })
37
- ]
38
- })
39
- });
17
+ return /* @__PURE__ */ jsx(Dialog, {
18
+ "data-slot": "command-dialog",
19
+ ...props,
20
+ children: /* @__PURE__ */ jsxs(DialogContent, {
21
+ className: "rounded-t-lg sm:rounded-lg",
22
+ "data-slot": "command-dialog-content",
23
+ children: [/* @__PURE__ */ jsxs(VisuallyHidden, { children: [/* @__PURE__ */ jsx(DialogTitle, { children: "Search command" }), /* @__PURE__ */ jsx(DialogDescription, { children: "Use the search bar to find and select the desired command." })] }), /* @__PURE__ */ jsx(Command, {
24
+ className: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-input]]:h-12",
25
+ children
26
+ })]
27
+ })
28
+ });
40
29
  }
41
30
  function CommandInput({ className, ...props }) {
42
- return /*#__PURE__*/ jsxs("div", {
43
- "cmdk-input-wrapper": true,
44
- className: "flex items-center gap-2 border-b px-3",
45
- "data-slot": "command-input-wrapper",
46
- children: [
47
- /*#__PURE__*/ jsx(SearchIcon, {
48
- className: "size-4 shrink-0 opacity-50"
49
- }),
50
- /*#__PURE__*/ jsx(Command.Input, {
51
- className: cn("flex h-10 w-full text-base outline-hidden placeholder:text-muted-foreground disabled:opacity-50 md:text-sm", className),
52
- "data-slot": "command-input",
53
- ...props
54
- })
55
- ]
56
- });
31
+ return /* @__PURE__ */ jsxs("div", {
32
+ "cmdk-input-wrapper": true,
33
+ className: "flex items-center gap-2 border-b px-3",
34
+ "data-slot": "command-input-wrapper",
35
+ children: [/* @__PURE__ */ jsx(SearchIcon, { className: "size-4 shrink-0 opacity-50" }), /* @__PURE__ */ jsx(Command$1.Input, {
36
+ className: cn("flex h-10 w-full text-base outline-hidden placeholder:text-muted-foreground disabled:opacity-50 md:text-sm", className),
37
+ "data-slot": "command-input",
38
+ ...props
39
+ })]
40
+ });
57
41
  }
58
42
  function CommandList({ className, ...props }) {
59
- return /*#__PURE__*/ jsx(Command.List, {
60
- className: cn("max-h-75 overflow-x-hidden overflow-y-auto", className),
61
- "data-slot": "command-list",
62
- ...props
63
- });
43
+ return /* @__PURE__ */ jsx(Command$1.List, {
44
+ className: cn("max-h-75 overflow-x-hidden overflow-y-auto", className),
45
+ "data-slot": "command-list",
46
+ ...props
47
+ });
64
48
  }
65
49
  function CommandEmpty({ className, ...props }) {
66
- return /*#__PURE__*/ jsx(Command.Empty, {
67
- className: cn("py-6 text-center text-sm", className),
68
- "data-slot": "command-empty",
69
- ...props
70
- });
50
+ return /* @__PURE__ */ jsx(Command$1.Empty, {
51
+ className: cn("py-6 text-center text-sm", className),
52
+ "data-slot": "command-empty",
53
+ ...props
54
+ });
71
55
  }
72
56
  function CommandGroup({ className, ...props }) {
73
- return /*#__PURE__*/ jsx(Command.Group, {
74
- className: cn("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground", className),
75
- "data-slot": "command-group",
76
- ...props
77
- });
57
+ return /* @__PURE__ */ jsx(Command$1.Group, {
58
+ className: cn("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground", className),
59
+ "data-slot": "command-group",
60
+ ...props
61
+ });
78
62
  }
79
63
  function CommandSeparator({ className, ...props }) {
80
- return /*#__PURE__*/ jsx(Command.Separator, {
81
- className: cn("-mx-1 h-px bg-border", className),
82
- "data-slot": "command-separator",
83
- ...props
84
- });
64
+ return /* @__PURE__ */ jsx(Command$1.Separator, {
65
+ className: cn("-mx-1 h-px bg-border", className),
66
+ "data-slot": "command-separator",
67
+ ...props
68
+ });
85
69
  }
86
70
  function CommandItem({ className, ...props }) {
87
- return /*#__PURE__*/ jsx(Command.Item, {
88
- className: cn("group/command-item relative flex cursor-default items-center gap-x-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none aria-disabled:opacity-50 aria-selected:bg-accent aria-selected:text-accent-foreground [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground", className),
89
- "data-slot": "command-item",
90
- ...props
91
- });
71
+ return /* @__PURE__ */ jsx(Command$1.Item, {
72
+ className: cn("group/command-item relative flex cursor-default items-center gap-x-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none aria-disabled:opacity-50 aria-selected:bg-accent aria-selected:text-accent-foreground [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground", className),
73
+ "data-slot": "command-item",
74
+ ...props
75
+ });
92
76
  }
93
77
  function CommandLoading({ className, ...props }) {
94
- return /*#__PURE__*/ jsx(Command.Loading, {
95
- className: cn("flex justify-center p-2", className),
96
- "data-slot": "command-loading",
97
- ...props
98
- });
78
+ return /* @__PURE__ */ jsx(Command$1.Loading, {
79
+ className: cn("flex justify-center p-2", className),
80
+ "data-slot": "command-loading",
81
+ ...props
82
+ });
99
83
  }
100
84
  function CommandShortcut({ className, ...props }) {
101
- return /*#__PURE__*/ jsx("span", {
102
- className: cn("ml-auto text-xs tracking-widest text-muted-foreground", className),
103
- "data-slot": "command-shortcut",
104
- ...props
105
- });
85
+ return /* @__PURE__ */ jsx("span", {
86
+ className: cn("ml-auto text-xs tracking-widest text-muted-foreground", className),
87
+ "data-slot": "command-shortcut",
88
+ ...props
89
+ });
106
90
  }
107
- export { command_Command as Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandLoading, CommandSeparator, CommandShortcut };
91
+ //#endregion
92
+ export { Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandLoading, CommandSeparator, CommandShortcut };
@@ -1,41 +1,91 @@
1
- import type { ComponentProps, JSX } from "react";
1
+ import { ComponentProps, JSX } from "react";
2
2
  import * as ContextMenuPrimitive from "@radix-ui/react-context-menu";
3
+
4
+ //#region src/components/context-menu.d.ts
3
5
  type ContextMenuProps = ComponentProps<typeof ContextMenuPrimitive.Root>;
4
- declare function ContextMenu({ ...props }: ContextMenuProps): JSX.Element;
6
+ declare function ContextMenu({
7
+ ...props
8
+ }: ContextMenuProps): JSX.Element;
5
9
  type ContextMenuTriggerProps = ComponentProps<typeof ContextMenuPrimitive.Trigger>;
6
- declare function ContextMenuTrigger({ ...props }: ContextMenuTriggerProps): JSX.Element;
10
+ declare function ContextMenuTrigger({
11
+ ...props
12
+ }: ContextMenuTriggerProps): JSX.Element;
7
13
  type ContextMenuGroupProps = ComponentProps<typeof ContextMenuPrimitive.Group>;
8
- declare function ContextMenuGroup({ ...props }: ContextMenuGroupProps): JSX.Element;
14
+ declare function ContextMenuGroup({
15
+ ...props
16
+ }: ContextMenuGroupProps): JSX.Element;
9
17
  type ContextMenuSubProps = ComponentProps<typeof ContextMenuPrimitive.Sub>;
10
- declare function ContextMenuSub({ ...props }: ContextMenuSubProps): JSX.Element;
18
+ declare function ContextMenuSub({
19
+ ...props
20
+ }: ContextMenuSubProps): JSX.Element;
11
21
  type ContextMenuRadioGroupProps = ComponentProps<typeof ContextMenuPrimitive.RadioGroup>;
12
- declare function ContextMenuRadioGroup({ ...props }: ContextMenuRadioGroupProps): JSX.Element;
22
+ declare function ContextMenuRadioGroup({
23
+ ...props
24
+ }: ContextMenuRadioGroupProps): JSX.Element;
13
25
  interface ContextMenuSubTriggerProps extends ComponentProps<typeof ContextMenuPrimitive.SubTrigger> {
14
- inset?: boolean;
26
+ inset?: boolean;
15
27
  }
16
- declare function ContextMenuSubTrigger({ children, className, inset, ...props }: ContextMenuSubTriggerProps): JSX.Element;
28
+ declare function ContextMenuSubTrigger({
29
+ children,
30
+ className,
31
+ inset,
32
+ ...props
33
+ }: ContextMenuSubTriggerProps): JSX.Element;
17
34
  type ContextMenuSubContentProps = ComponentProps<typeof ContextMenuPrimitive.SubContent>;
18
- declare function ContextMenuSubContent({ className, ...props }: ContextMenuSubContentProps): JSX.Element;
35
+ declare function ContextMenuSubContent({
36
+ className,
37
+ ...props
38
+ }: ContextMenuSubContentProps): JSX.Element;
19
39
  type ContextMenuContentProps = ComponentProps<typeof ContextMenuPrimitive.Content>;
20
- declare function ContextMenuContent({ className, ...props }: ContextMenuContentProps): JSX.Element;
40
+ declare function ContextMenuContent({
41
+ className,
42
+ ...props
43
+ }: ContextMenuContentProps): JSX.Element;
21
44
  interface ContextMenuItemProps extends ComponentProps<typeof ContextMenuPrimitive.Item> {
22
- inset?: boolean;
23
- variant?: "default" | "destructive";
45
+ inset?: boolean;
46
+ variant?: "default" | "destructive";
24
47
  }
25
- declare function ContextMenuItem({ className, inset, variant, ...props }: ContextMenuItemProps): JSX.Element;
48
+ declare function ContextMenuItem({
49
+ className,
50
+ inset,
51
+ variant,
52
+ ...props
53
+ }: ContextMenuItemProps): JSX.Element;
26
54
  type ContextMenuCheckboxItemProps = ComponentProps<typeof ContextMenuPrimitive.CheckboxItem>;
27
- declare function ContextMenuCheckboxItem({ checked, children, className, ...props }: ContextMenuCheckboxItemProps): JSX.Element;
55
+ declare function ContextMenuCheckboxItem({
56
+ checked,
57
+ children,
58
+ className,
59
+ ...props
60
+ }: ContextMenuCheckboxItemProps): JSX.Element;
28
61
  type ContextMenuRadioItemProps = ComponentProps<typeof ContextMenuPrimitive.RadioItem>;
29
- declare function ContextMenuRadioItem({ children, className, ...props }: ContextMenuRadioItemProps): JSX.Element;
62
+ declare function ContextMenuRadioItem({
63
+ children,
64
+ className,
65
+ ...props
66
+ }: ContextMenuRadioItemProps): JSX.Element;
30
67
  interface ContextMenuLabelProps extends ComponentProps<typeof ContextMenuPrimitive.Label> {
31
- inset?: boolean;
68
+ inset?: boolean;
32
69
  }
33
- declare function ContextMenuLabel({ className, inset, ...props }: ContextMenuLabelProps): JSX.Element;
70
+ declare function ContextMenuLabel({
71
+ className,
72
+ inset,
73
+ ...props
74
+ }: ContextMenuLabelProps): JSX.Element;
34
75
  type ContextMenuSeparatorProps = ComponentProps<typeof ContextMenuPrimitive.Separator>;
35
- declare function ContextMenuSeparator({ className, ...props }: ContextMenuSeparatorProps): JSX.Element;
76
+ declare function ContextMenuSeparator({
77
+ className,
78
+ ...props
79
+ }: ContextMenuSeparatorProps): JSX.Element;
36
80
  type ContextMenuShortcutProps = ComponentProps<"span">;
37
- declare function ContextMenuShortcut({ className, ...props }: ContextMenuShortcutProps): JSX.Element;
81
+ declare function ContextMenuShortcut({
82
+ className,
83
+ ...props
84
+ }: ContextMenuShortcutProps): JSX.Element;
38
85
  type ContextMenuArrowProps = ComponentProps<typeof ContextMenuPrimitive.Arrow>;
39
- declare function ContextMenuArrow({ className, ...props }: ContextMenuArrowProps): JSX.Element;
40
- export { ContextMenu, ContextMenuArrow, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, };
41
- export type { ContextMenuArrowProps, ContextMenuCheckboxItemProps, ContextMenuContentProps, ContextMenuGroupProps, ContextMenuItemProps, ContextMenuLabelProps, ContextMenuProps, ContextMenuRadioGroupProps, ContextMenuRadioItemProps, ContextMenuSeparatorProps, ContextMenuShortcutProps, ContextMenuSubContentProps, ContextMenuSubProps, ContextMenuSubTriggerProps, ContextMenuTriggerProps, };
86
+ declare function ContextMenuArrow({
87
+ className,
88
+ ...props
89
+ }: ContextMenuArrowProps): JSX.Element;
90
+ //#endregion
91
+ export { ContextMenu, ContextMenuArrow, type ContextMenuArrowProps, ContextMenuCheckboxItem, type ContextMenuCheckboxItemProps, ContextMenuContent, type ContextMenuContentProps, ContextMenuGroup, type ContextMenuGroupProps, ContextMenuItem, type ContextMenuItemProps, ContextMenuLabel, type ContextMenuLabelProps, type ContextMenuProps, ContextMenuRadioGroup, type ContextMenuRadioGroupProps, ContextMenuRadioItem, type ContextMenuRadioItemProps, ContextMenuSeparator, type ContextMenuSeparatorProps, ContextMenuShortcut, type ContextMenuShortcutProps, ContextMenuSub, ContextMenuSubContent, type ContextMenuSubContentProps, type ContextMenuSubProps, ContextMenuSubTrigger, type ContextMenuSubTriggerProps, ContextMenuTrigger, type ContextMenuTriggerProps };