@goplusvn/core 0.1.1 → 0.1.3

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 (223) hide show
  1. package/package.json +31 -175
  2. package/dist/audit/index.d.mts +0 -115
  3. package/dist/audit/index.d.ts +0 -115
  4. package/dist/audit/index.js +0 -204
  5. package/dist/audit/index.js.map +0 -1
  6. package/dist/audit/index.mjs +0 -200
  7. package/dist/audit/index.mjs.map +0 -1
  8. package/dist/auth/index.d.mts +0 -86
  9. package/dist/auth/index.d.ts +0 -86
  10. package/dist/auth/index.js +0 -210
  11. package/dist/auth/index.js.map +0 -1
  12. package/dist/auth/index.mjs +0 -198
  13. package/dist/auth/index.mjs.map +0 -1
  14. package/dist/button-1dWvP9Ib.d.mts +0 -30
  15. package/dist/button-1dWvP9Ib.d.ts +0 -30
  16. package/dist/calendar-2QzdEo1z.d.mts +0 -20
  17. package/dist/calendar-2QzdEo1z.d.ts +0 -20
  18. package/dist/code-generation/index.d.mts +0 -30
  19. package/dist/code-generation/index.d.ts +0 -30
  20. package/dist/code-generation/index.js +0 -31
  21. package/dist/code-generation/index.js.map +0 -1
  22. package/dist/code-generation/index.mjs +0 -28
  23. package/dist/code-generation/index.mjs.map +0 -1
  24. package/dist/configs/index.d.mts +0 -175
  25. package/dist/configs/index.d.ts +0 -175
  26. package/dist/configs/index.js +0 -254
  27. package/dist/configs/index.js.map +0 -1
  28. package/dist/configs/index.mjs +0 -233
  29. package/dist/configs/index.mjs.map +0 -1
  30. package/dist/crud/index.d.mts +0 -646
  31. package/dist/crud/index.d.ts +0 -646
  32. package/dist/crud/index.js +0 -11772
  33. package/dist/crud/index.js.map +0 -1
  34. package/dist/crud/index.mjs +0 -11665
  35. package/dist/crud/index.mjs.map +0 -1
  36. package/dist/crud/server.d.mts +0 -20
  37. package/dist/crud/server.d.ts +0 -20
  38. package/dist/crud/server.js +0 -123
  39. package/dist/crud/server.js.map +0 -1
  40. package/dist/crud/server.mjs +0 -120
  41. package/dist/crud/server.mjs.map +0 -1
  42. package/dist/data-table-skeleton-12NA8Mjx.d.mts +0 -39
  43. package/dist/data-table-skeleton-12NA8Mjx.d.ts +0 -39
  44. package/dist/dialog-bKfjZMTd.d.mts +0 -22
  45. package/dist/dialog-bKfjZMTd.d.ts +0 -22
  46. package/dist/dynamic-icon-DrGIiu2N.d.mts +0 -10
  47. package/dist/dynamic-icon-DrGIiu2N.d.ts +0 -10
  48. package/dist/home/index.d.mts +0 -269
  49. package/dist/home/index.d.ts +0 -269
  50. package/dist/home/index.js +0 -1678
  51. package/dist/home/index.js.map +0 -1
  52. package/dist/home/index.mjs +0 -1635
  53. package/dist/home/index.mjs.map +0 -1
  54. package/dist/hooks/index.d.mts +0 -7
  55. package/dist/hooks/index.d.ts +0 -7
  56. package/dist/hooks/index.js +0 -8316
  57. package/dist/hooks/index.js.map +0 -1
  58. package/dist/hooks/index.mjs +0 -8255
  59. package/dist/hooks/index.mjs.map +0 -1
  60. package/dist/index-50hpiPrV.d.ts +0 -116
  61. package/dist/index-B9zQVEVi.d.mts +0 -116
  62. package/dist/index.d.mts +0 -5
  63. package/dist/index.d.ts +0 -5
  64. package/dist/index.js +0 -123
  65. package/dist/index.js.map +0 -1
  66. package/dist/index.mjs +0 -118
  67. package/dist/index.mjs.map +0 -1
  68. package/dist/infrastructure/index.d.mts +0 -423
  69. package/dist/infrastructure/index.d.ts +0 -423
  70. package/dist/infrastructure/index.js +0 -633
  71. package/dist/infrastructure/index.js.map +0 -1
  72. package/dist/infrastructure/index.mjs +0 -619
  73. package/dist/infrastructure/index.mjs.map +0 -1
  74. package/dist/label-DWTEkNPo.d.ts +0 -226
  75. package/dist/label-LPpdcoBx.d.mts +0 -226
  76. package/dist/layout/index.d.mts +0 -48
  77. package/dist/layout/index.d.ts +0 -48
  78. package/dist/layout/index.js +0 -117
  79. package/dist/layout/index.js.map +0 -1
  80. package/dist/layout/index.mjs +0 -90
  81. package/dist/layout/index.mjs.map +0 -1
  82. package/dist/navigation/index.d.mts +0 -16
  83. package/dist/navigation/index.d.ts +0 -16
  84. package/dist/navigation/index.js +0 -53
  85. package/dist/navigation/index.js.map +0 -1
  86. package/dist/navigation/index.mjs +0 -50
  87. package/dist/navigation/index.mjs.map +0 -1
  88. package/dist/notification/index.d.mts +0 -105
  89. package/dist/notification/index.d.ts +0 -105
  90. package/dist/notification/index.js +0 -278
  91. package/dist/notification/index.js.map +0 -1
  92. package/dist/notification/index.mjs +0 -274
  93. package/dist/notification/index.mjs.map +0 -1
  94. package/dist/organization/index.d.mts +0 -99
  95. package/dist/organization/index.d.ts +0 -99
  96. package/dist/organization/index.js +0 -360
  97. package/dist/organization/index.js.map +0 -1
  98. package/dist/organization/index.mjs +0 -352
  99. package/dist/organization/index.mjs.map +0 -1
  100. package/dist/plugin/index.d.mts +0 -83
  101. package/dist/plugin/index.d.ts +0 -83
  102. package/dist/plugin/index.js +0 -86
  103. package/dist/plugin/index.js.map +0 -1
  104. package/dist/plugin/index.mjs +0 -84
  105. package/dist/plugin/index.mjs.map +0 -1
  106. package/dist/providers/index.d.mts +0 -25
  107. package/dist/providers/index.d.ts +0 -25
  108. package/dist/providers/index.js +0 -84
  109. package/dist/providers/index.js.map +0 -1
  110. package/dist/providers/index.mjs +0 -77
  111. package/dist/providers/index.mjs.map +0 -1
  112. package/dist/rbac/index.d.mts +0 -226
  113. package/dist/rbac/index.d.ts +0 -226
  114. package/dist/rbac/index.js +0 -4784
  115. package/dist/rbac/index.js.map +0 -1
  116. package/dist/rbac/index.mjs +0 -4722
  117. package/dist/rbac/index.mjs.map +0 -1
  118. package/dist/rbac/permissions.d.mts +0 -26
  119. package/dist/rbac/permissions.d.ts +0 -26
  120. package/dist/rbac/permissions.js +0 -94
  121. package/dist/rbac/permissions.js.map +0 -1
  122. package/dist/rbac/permissions.mjs +0 -90
  123. package/dist/rbac/permissions.mjs.map +0 -1
  124. package/dist/rbac/server.d.mts +0 -1
  125. package/dist/rbac/server.d.ts +0 -1
  126. package/dist/rbac/server.js +0 -128
  127. package/dist/rbac/server.js.map +0 -1
  128. package/dist/rbac/server.mjs +0 -124
  129. package/dist/rbac/server.mjs.map +0 -1
  130. package/dist/schemas/index.d.mts +0 -1257
  131. package/dist/schemas/index.d.ts +0 -1257
  132. package/dist/schemas/index.js +0 -572
  133. package/dist/schemas/index.js.map +0 -1
  134. package/dist/schemas/index.mjs +0 -523
  135. package/dist/schemas/index.mjs.map +0 -1
  136. package/dist/server-QuYCTa89.d.mts +0 -83
  137. package/dist/server-QuYCTa89.d.ts +0 -83
  138. package/dist/sonner-C74GlRDQ.d.mts +0 -71
  139. package/dist/sonner-C74GlRDQ.d.ts +0 -71
  140. package/dist/status-BOXZgIqX.d.mts +0 -12
  141. package/dist/status-BOXZgIqX.d.ts +0 -12
  142. package/dist/system/index.d.mts +0 -77
  143. package/dist/system/index.d.ts +0 -77
  144. package/dist/system/index.js +0 -102
  145. package/dist/system/index.js.map +0 -1
  146. package/dist/system/index.mjs +0 -100
  147. package/dist/system/index.mjs.map +0 -1
  148. package/dist/tabs-C6FfBwPY.d.mts +0 -18
  149. package/dist/tabs-C6FfBwPY.d.ts +0 -18
  150. package/dist/tenant-provider-B8eC_Wpb.d.mts +0 -27
  151. package/dist/tenant-provider-B8eC_Wpb.d.ts +0 -27
  152. package/dist/types/index.d.mts +0 -469
  153. package/dist/types/index.d.ts +0 -469
  154. package/dist/types/index.js +0 -25
  155. package/dist/types/index.js.map +0 -1
  156. package/dist/types/index.mjs +0 -21
  157. package/dist/types/index.mjs.map +0 -1
  158. package/dist/ui/auth.d.mts +0 -39
  159. package/dist/ui/auth.d.ts +0 -39
  160. package/dist/ui/auth.js +0 -4941
  161. package/dist/ui/auth.js.map +0 -1
  162. package/dist/ui/auth.mjs +0 -4896
  163. package/dist/ui/auth.mjs.map +0 -1
  164. package/dist/ui/crud.d.mts +0 -2
  165. package/dist/ui/crud.d.ts +0 -2
  166. package/dist/ui/crud.js +0 -4
  167. package/dist/ui/crud.js.map +0 -1
  168. package/dist/ui/crud.mjs +0 -3
  169. package/dist/ui/crud.mjs.map +0 -1
  170. package/dist/ui/data-display.d.mts +0 -596
  171. package/dist/ui/data-display.d.ts +0 -596
  172. package/dist/ui/data-display.js +0 -5307
  173. package/dist/ui/data-display.js.map +0 -1
  174. package/dist/ui/data-display.mjs +0 -5212
  175. package/dist/ui/data-display.mjs.map +0 -1
  176. package/dist/ui/feedback.d.mts +0 -55
  177. package/dist/ui/feedback.d.ts +0 -55
  178. package/dist/ui/feedback.js +0 -2608
  179. package/dist/ui/feedback.js.map +0 -1
  180. package/dist/ui/feedback.mjs +0 -2526
  181. package/dist/ui/feedback.mjs.map +0 -1
  182. package/dist/ui/forms.d.mts +0 -309
  183. package/dist/ui/forms.d.ts +0 -309
  184. package/dist/ui/forms.js +0 -4656
  185. package/dist/ui/forms.js.map +0 -1
  186. package/dist/ui/forms.mjs +0 -4571
  187. package/dist/ui/forms.mjs.map +0 -1
  188. package/dist/ui/index.d.mts +0 -331
  189. package/dist/ui/index.d.ts +0 -331
  190. package/dist/ui/index.js +0 -16953
  191. package/dist/ui/index.js.map +0 -1
  192. package/dist/ui/index.mjs +0 -16598
  193. package/dist/ui/index.mjs.map +0 -1
  194. package/dist/ui/primitives/client.d.mts +0 -61
  195. package/dist/ui/primitives/client.d.ts +0 -61
  196. package/dist/ui/primitives/client.js +0 -3408
  197. package/dist/ui/primitives/client.js.map +0 -1
  198. package/dist/ui/primitives/client.mjs +0 -3256
  199. package/dist/ui/primitives/client.mjs.map +0 -1
  200. package/dist/ui/primitives.d.mts +0 -113
  201. package/dist/ui/primitives.d.ts +0 -113
  202. package/dist/ui/primitives.js +0 -3356
  203. package/dist/ui/primitives.js.map +0 -1
  204. package/dist/ui/primitives.mjs +0 -3227
  205. package/dist/ui/primitives.mjs.map +0 -1
  206. package/dist/user/index.d.mts +0 -228
  207. package/dist/user/index.d.ts +0 -228
  208. package/dist/user/index.js +0 -4306
  209. package/dist/user/index.js.map +0 -1
  210. package/dist/user/index.mjs +0 -4260
  211. package/dist/user/index.mjs.map +0 -1
  212. package/dist/utils/index.d.mts +0 -205
  213. package/dist/utils/index.d.ts +0 -205
  214. package/dist/utils/index.js +0 -574
  215. package/dist/utils/index.js.map +0 -1
  216. package/dist/utils/index.mjs +0 -514
  217. package/dist/utils/index.mjs.map +0 -1
  218. package/dist/workflow/index.d.mts +0 -40
  219. package/dist/workflow/index.d.ts +0 -40
  220. package/dist/workflow/index.js +0 -3710
  221. package/dist/workflow/index.js.map +0 -1
  222. package/dist/workflow/index.mjs +0 -3677
  223. package/dist/workflow/index.mjs.map +0 -1
@@ -1,3256 +0,0 @@
1
- import { clsx } from 'clsx';
2
- import { twMerge } from 'tailwind-merge';
3
- import * as React6 from 'react';
4
- import { useState, useRef, useMemo, useEffect, useCallback, useContext, createContext } from 'react';
5
- import { cva } from 'class-variance-authority';
6
- import { Slot } from '@radix-ui/react-slot';
7
- import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
8
- import { ChevronLeft, ChevronRight, X, ChevronsUpDown, Search, Check, ChevronDown, ChevronUp, Dot, GripVertical, icons, PanelLeft } from 'lucide-react';
9
- import { DayPicker } from 'react-day-picker';
10
- import * as ScrollAreaPrimitive from '@radix-ui/react-scroll-area';
11
- import * as SelectPrimitive from '@radix-ui/react-select';
12
- import * as PopoverPrimitive from '@radix-ui/react-popover';
13
- import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
14
- import * as SwitchPrimitives from '@radix-ui/react-switch';
15
- import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
16
- import * as LabelPrimitive from '@radix-ui/react-label';
17
- import * as TooltipPrimitive from '@radix-ui/react-tooltip';
18
- import 'react-use';
19
- import '@radix-ui/react-direction';
20
- import * as ResizablePrimitive from 'react-resizable-panels';
21
- import * as SliderPrimitive from '@radix-ui/react-slider';
22
- import * as MenubarPrimitive from '@radix-ui/react-menubar';
23
- import * as NavigationMenuPrimitive from '@radix-ui/react-navigation-menu';
24
- import * as TogglePrimitive from '@radix-ui/react-toggle';
25
- import * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';
26
- import * as ProgressPrimitive from '@radix-ui/react-progress';
27
- import * as SheetPrimitive from '@radix-ui/react-dialog';
28
- import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
29
- import { Drawer as Drawer$1 } from 'vaul';
30
- import { Toaster as Toaster$1 } from 'sonner';
31
- import '@radix-ui/react-alert-dialog';
32
- import { useRouter } from 'next/navigation';
33
- import Link2 from 'next/link';
34
-
35
- var __getOwnPropNames = Object.getOwnPropertyNames;
36
- var __esm = (fn, res) => function __init() {
37
- return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
38
- };
39
- function cn(...inputs) {
40
- return twMerge(clsx(inputs));
41
- }
42
- var Logger;
43
- var init_utils = __esm({
44
- "src/utils/index.ts"() {
45
- Logger = class {
46
- log(level, message, context, error) {
47
- const entry = {
48
- timestamp: (/* @__PURE__ */ new Date()).toISOString(),
49
- level,
50
- message,
51
- context
52
- };
53
- if (error instanceof Error) {
54
- entry.error = {
55
- name: error.name,
56
- message: error.message,
57
- stack: error.stack
58
- };
59
- } else if (error) {
60
- entry.error = error;
61
- }
62
- const logString = JSON.stringify(entry);
63
- switch (level) {
64
- case "error":
65
- console.error(logString);
66
- break;
67
- case "warn":
68
- console.warn(logString);
69
- break;
70
- case "debug":
71
- if (process.env.NODE_ENV === "development") console.debug(logString);
72
- break;
73
- default:
74
- console.log(logString);
75
- }
76
- }
77
- info(message, context) {
78
- this.log("info", message, context);
79
- }
80
- warn(message, context) {
81
- this.log("warn", message, context);
82
- }
83
- error(message, error, context) {
84
- this.log("error", message, context, error);
85
- }
86
- debug(message, context) {
87
- this.log("debug", message, context);
88
- }
89
- };
90
- new Logger();
91
- }
92
- });
93
- var buttonVariants, Button;
94
- var init_button = __esm({
95
- "src/ui/primitives/button.tsx"() {
96
- init_utils();
97
- buttonVariants = cva(
98
- "inline-flex items-center justify-center gap-1.5 whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",
99
- {
100
- variants: {
101
- variant: {
102
- // Existing variants (backwards-compatible)
103
- default: "bg-primary text-primary-foreground hover:bg-primary/90",
104
- destructive: "bg-destructive text-destructive-foreground hover:bg-destructive/90",
105
- outline: "border border-input bg-background hover:bg-accent hover:text-accent-foreground",
106
- secondary: "bg-secondary text-secondary-foreground hover:bg-secondary/80",
107
- ghost: "hover:bg-accent hover:text-accent-foreground",
108
- link: "text-primary underline-offset-4 hover:underline",
109
- // New Plane-inspired variants using semantic tokens
110
- accent: "bg-accent-primary text-text-on-color hover:bg-accent-primary-hover active:bg-accent-primary-active disabled:bg-layer-disabled disabled:text-text-disabled",
111
- danger: "bg-danger text-text-on-color hover:bg-danger-hover active:bg-danger-hover disabled:bg-layer-disabled disabled:text-text-disabled",
112
- "danger-outline": "border border-danger bg-layer-2 text-danger-text hover:bg-danger-subtle active:bg-danger-subtle disabled:border-border-subtle disabled:bg-layer-2 disabled:text-text-disabled",
113
- success: "bg-success-semantic text-text-on-color hover:bg-success-semantic/90 active:bg-success-semantic/80 disabled:bg-layer-disabled disabled:text-text-disabled",
114
- tertiary: "bg-layer-3 text-text-secondary hover:bg-layer-3-hover active:bg-layer-3-hover disabled:bg-transparent disabled:text-text-disabled"
115
- },
116
- size: {
117
- // Existing sizes (backwards-compatible)
118
- default: "h-10 px-4 py-2",
119
- sm: "h-9 rounded-md px-3",
120
- lg: "h-11 rounded-md px-8",
121
- icon: "h-10 w-10",
122
- // New ERP-specific compact sizes
123
- xs: "h-7 rounded-sm px-2 text-xs",
124
- compact: "h-8 rounded-md px-3 text-xs",
125
- "icon-sm": "h-8 w-8",
126
- "icon-xs": "h-7 w-7"
127
- }
128
- },
129
- defaultVariants: {
130
- variant: "default",
131
- size: "default"
132
- }
133
- }
134
- );
135
- Button = React6.forwardRef(
136
- ({ className, variant, size, asChild = false, loading = false, prependIcon, appendIcon, children, disabled, ...props }, ref) => {
137
- if (asChild) {
138
- return /* @__PURE__ */ jsx(
139
- Slot,
140
- {
141
- className: cn(buttonVariants({ variant, size }), className),
142
- ref,
143
- ...{ disabled: disabled || loading },
144
- ...props,
145
- children: React6.isValidElement(children) && (prependIcon || appendIcon) ? React6.cloneElement(children, {}, /* @__PURE__ */ jsxs(Fragment, { children: [
146
- prependIcon && React6.cloneElement(prependIcon, {
147
- className: cn("shrink-0", size === "xs" || size === "compact" ? "size-3.5" : "size-4")
148
- }),
149
- children.props.children,
150
- appendIcon && React6.cloneElement(appendIcon, {
151
- className: cn("shrink-0", size === "xs" || size === "compact" ? "size-3.5" : "size-4")
152
- })
153
- ] })) : children
154
- }
155
- );
156
- }
157
- return /* @__PURE__ */ jsxs(
158
- "button",
159
- {
160
- className: cn(buttonVariants({ variant, size }), className),
161
- ref,
162
- disabled: disabled || loading,
163
- ...props,
164
- children: [
165
- prependIcon && React6.cloneElement(prependIcon, {
166
- className: cn("shrink-0", size === "xs" || size === "compact" ? "size-3.5" : "size-4")
167
- }),
168
- children,
169
- appendIcon && React6.cloneElement(appendIcon, {
170
- className: cn("shrink-0", size === "xs" || size === "compact" ? "size-3.5" : "size-4")
171
- })
172
- ]
173
- }
174
- );
175
- }
176
- );
177
- Button.displayName = "Button";
178
- }
179
- });
180
- function Calendar({
181
- className,
182
- classNames,
183
- showOutsideDays = true,
184
- ...props
185
- }) {
186
- return /* @__PURE__ */ jsx(
187
- DayPicker,
188
- {
189
- showOutsideDays,
190
- className: cn("p-3", className),
191
- classNames: {
192
- month: "space-y-4",
193
- month_caption: "flex justify-center pt-1 items-center",
194
- caption_label: "text-sm font-medium",
195
- nav: "relative gap-x-1 flex items-center",
196
- button_previous: cn(
197
- buttonVariants({ variant: "outline" }),
198
- "absolute top-0 start-0 h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100"
199
- ),
200
- button_next: cn(
201
- buttonVariants({ variant: "outline" }),
202
- "absolute top-0 end-0 h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100"
203
- ),
204
- month_grid: "w-full border-collapse space-y-1",
205
- weekdays: "flex",
206
- weekday: "text-muted-foreground rounded-md w-8 font-normal text-[0.8rem]",
207
- week: "flex w-full mt-2",
208
- day: cn(
209
- buttonVariants({ variant: "ghost" }),
210
- "relative h-8 w-8 p-0 font-normal text-center text-sm focus-within:relative focus-within:z-20 [&:has([aria-selected])]:bg-accent [&:has([aria-selected].day-outside)]:bg-accent/50 [&:has([aria-selected].day-range-end)]:rounded-e-md"
211
- ),
212
- day_button: "cursor-pointer h-full w-full aria-selected:opacity-100",
213
- range_start: "rounded-md!",
214
- range_end: "rounded-md!",
215
- selected: cn(
216
- "bg-primary text-primary-foreground hover:bg-primary hover:text-primary-foreground focus:bg-primary focus:text-primary-foreground",
217
- props.mode === "range" && "rounded-none"
218
- ),
219
- today: "bg-accent text-accent-foreground",
220
- outside: "day-outside text-muted-foreground opacity-50 aria-selected:bg-accent/50 aria-selected:text-muted-foreground aria-selected:opacity-30",
221
- disabled: "text-muted-foreground opacity-50",
222
- range_middle: "aria-selected:bg-accent aria-selected:text-accent-foreground",
223
- hidden: "invisible",
224
- ...classNames
225
- },
226
- components: {
227
- Chevron: (props2) => {
228
- if (props2.orientation === "left") {
229
- return /* @__PURE__ */ jsx(ChevronLeft, { className: "h-4 w-4" });
230
- }
231
- return /* @__PURE__ */ jsx(ChevronRight, { className: "h-4 w-4" });
232
- }
233
- },
234
- ...props
235
- }
236
- );
237
- }
238
- var init_calendar = __esm({
239
- "src/ui/primitives/calendar.tsx"() {
240
- "use client";
241
- init_utils();
242
- init_button();
243
- Calendar.displayName = "Calendar";
244
- }
245
- });
246
- var Input;
247
- var init_input = __esm({
248
- "src/ui/primitives/input.tsx"() {
249
- init_utils();
250
- Input = React6.forwardRef(
251
- ({ className, type, ...props }, ref) => {
252
- return /* @__PURE__ */ jsx(
253
- "input",
254
- {
255
- type,
256
- className: cn(
257
- "flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",
258
- className
259
- ),
260
- ref,
261
- ...props
262
- }
263
- );
264
- }
265
- );
266
- Input.displayName = "Input";
267
- }
268
- });
269
- function ScrollArea({
270
- orientation,
271
- className,
272
- children,
273
- ...props
274
- }) {
275
- return /* @__PURE__ */ jsxs(
276
- ScrollAreaPrimitive.Root,
277
- {
278
- "data-slot": "scroll-area",
279
- className: cn("relative overflow-hidden", className),
280
- ...props,
281
- children: [
282
- /* @__PURE__ */ jsx(
283
- ScrollAreaPrimitive.Viewport,
284
- {
285
- "data-slot": "scroll-area-viewport",
286
- className: "h-full w-full rounded-[inherit]",
287
- children
288
- }
289
- ),
290
- /* @__PURE__ */ jsx(ScrollBar, { orientation }),
291
- /* @__PURE__ */ jsx(ScrollAreaPrimitive.Corner, {})
292
- ]
293
- }
294
- );
295
- }
296
- function ScrollBar({
297
- className,
298
- orientation = "vertical",
299
- ...props
300
- }) {
301
- return /* @__PURE__ */ jsx(
302
- ScrollAreaPrimitive.ScrollAreaScrollbar,
303
- {
304
- "data-slot": "scroll-area-scrollbar",
305
- orientation,
306
- className: cn(
307
- "flex touch-none select-none transition-colors",
308
- orientation === "vertical" && "h-full w-2.5 border-l border-l-transparent p-[1px]",
309
- orientation === "horizontal" && "h-2.5 flex-col border-t border-t-transparent p-[1px]",
310
- className
311
- ),
312
- ...props,
313
- children: /* @__PURE__ */ jsx(ScrollAreaPrimitive.ScrollAreaThumb, { className: "relative flex-1 rounded-full bg-border" })
314
- }
315
- );
316
- }
317
- var init_scroll_area = __esm({
318
- "src/ui/primitives/scroll-area.tsx"() {
319
- "use client";
320
- init_utils();
321
- }
322
- });
323
- function Combobox({
324
- options,
325
- value,
326
- onValueChange,
327
- placeholder = "Select option...",
328
- searchPlaceholder = "Search...",
329
- emptyText = "No option found.",
330
- disabled = false,
331
- className,
332
- id
333
- }) {
334
- const [open, setOpen] = useState(false);
335
- const [searchValue, setSearchValue] = useState("");
336
- const containerRef = useRef(null);
337
- const searchInputRef = useRef(null);
338
- const dropdownRef = useRef(null);
339
- const selectedOption = options.find(
340
- (option) => String(option.value) === String(value)
341
- );
342
- const filteredOptions = useMemo(() => {
343
- if (!searchValue.trim()) {
344
- return options;
345
- }
346
- const searchLower = searchValue.toLowerCase();
347
- return options.filter(
348
- (option) => option.label.toLowerCase().includes(searchLower) || String(option.value).toLowerCase().includes(searchLower)
349
- );
350
- }, [options, searchValue]);
351
- useEffect(() => {
352
- if (!open) {
353
- setSearchValue("");
354
- }
355
- }, [open]);
356
- useEffect(() => {
357
- if (open && searchInputRef.current) {
358
- setTimeout(() => {
359
- searchInputRef.current?.focus();
360
- }, 50);
361
- }
362
- }, [open]);
363
- useEffect(() => {
364
- if (!open) return;
365
- const handleClickOutside = (event) => {
366
- const target = event.target;
367
- if (containerRef.current && !containerRef.current.contains(target) && dropdownRef.current && !dropdownRef.current.contains(target)) {
368
- if (target.closest('[data-slot="dialog-content"]')) {
369
- return;
370
- }
371
- setOpen(false);
372
- }
373
- };
374
- const handleEscape = (event) => {
375
- if (event.key === "Escape" && open) {
376
- event.stopPropagation();
377
- setOpen(false);
378
- }
379
- };
380
- document.addEventListener("mousedown", handleClickOutside, true);
381
- document.addEventListener("keydown", handleEscape, true);
382
- return () => {
383
- document.removeEventListener("mousedown", handleClickOutside, true);
384
- document.removeEventListener("keydown", handleEscape, true);
385
- };
386
- }, [open]);
387
- const handleSelect = useCallback(
388
- (optionValue) => {
389
- if (onValueChange) {
390
- onValueChange(optionValue);
391
- setOpen(false);
392
- }
393
- },
394
- [onValueChange]
395
- );
396
- const handleClear = useCallback(
397
- (e) => {
398
- e.preventDefault();
399
- e.stopPropagation();
400
- if (onValueChange) {
401
- onValueChange(void 0);
402
- }
403
- },
404
- [onValueChange]
405
- );
406
- return /* @__PURE__ */ jsxs("div", { ref: containerRef, className: "relative w-full", children: [
407
- /* @__PURE__ */ jsxs(
408
- Button,
409
- {
410
- type: "button",
411
- variant: "outline",
412
- role: "combobox",
413
- "aria-expanded": open,
414
- disabled,
415
- className: cn("w-full justify-between", className),
416
- id,
417
- onClick: (e) => {
418
- e.stopPropagation();
419
- setOpen(!open);
420
- },
421
- children: [
422
- /* @__PURE__ */ jsx("span", { className: "truncate", children: selectedOption ? selectedOption.label : placeholder }),
423
- /* @__PURE__ */ jsxs("div", { className: "ml-2 flex items-center gap-1 shrink-0", children: [
424
- selectedOption && /* @__PURE__ */ jsx(
425
- "div",
426
- {
427
- role: "button",
428
- tabIndex: 0,
429
- className: "h-4 w-4 p-0 hover:bg-transparent cursor-pointer flex items-center justify-center",
430
- onClick: handleClear,
431
- onKeyDown: (e) => {
432
- if (e.key === "Enter" || e.key === " ") {
433
- e.preventDefault();
434
- e.stopPropagation();
435
- handleClear(e);
436
- }
437
- },
438
- children: /* @__PURE__ */ jsx(X, { className: "h-3.5 w-3.5 text-red-500 hover:text-red-600" })
439
- }
440
- ),
441
- /* @__PURE__ */ jsx(ChevronsUpDown, { className: "h-4 w-4 opacity-50" })
442
- ] })
443
- ]
444
- }
445
- ),
446
- open && /* @__PURE__ */ jsx(
447
- "div",
448
- {
449
- ref: dropdownRef,
450
- className: "absolute z-[100] mt-1 w-full rounded-md border bg-popover text-popover-foreground shadow-md",
451
- style: {
452
- top: "100%",
453
- left: 0
454
- },
455
- children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col", children: [
456
- /* @__PURE__ */ jsxs("div", { className: "flex items-center border-b px-3 py-2", children: [
457
- /* @__PURE__ */ jsx(Search, { className: "mr-2 h-4 w-4 shrink-0 opacity-50" }),
458
- /* @__PURE__ */ jsx(
459
- Input,
460
- {
461
- ref: searchInputRef,
462
- placeholder: searchPlaceholder,
463
- value: searchValue,
464
- onChange: (e) => {
465
- e.stopPropagation();
466
- setSearchValue(e.target.value);
467
- },
468
- onKeyDown: (e) => {
469
- e.stopPropagation();
470
- if (e.key === "Escape") {
471
- e.preventDefault();
472
- setOpen(false);
473
- }
474
- if (e.key === "Enter") {
475
- e.preventDefault();
476
- if (filteredOptions.length > 0) {
477
- handleSelect(filteredOptions[0].value);
478
- }
479
- }
480
- },
481
- onClick: (e) => {
482
- e.stopPropagation();
483
- },
484
- onFocus: (e) => {
485
- e.stopPropagation();
486
- },
487
- className: "border-0 focus-visible:ring-0 focus-visible:ring-offset-0 h-9 bg-transparent px-0"
488
- }
489
- ),
490
- searchValue && /* @__PURE__ */ jsx(
491
- Button,
492
- {
493
- type: "button",
494
- variant: "ghost",
495
- size: "sm",
496
- className: "h-6 w-6 p-0",
497
- onClick: (e) => {
498
- e.stopPropagation();
499
- setSearchValue("");
500
- searchInputRef.current?.focus();
501
- },
502
- children: /* @__PURE__ */ jsx(X, { className: "h-3 w-3" })
503
- }
504
- )
505
- ] }),
506
- /* @__PURE__ */ jsx(ScrollArea, { className: "max-h-[300px]", children: filteredOptions.length === 0 ? /* @__PURE__ */ jsx("div", { className: "py-6 text-center text-sm text-muted-foreground", children: emptyText }) : /* @__PURE__ */ jsx("div", { className: "p-1", children: filteredOptions.map((option) => {
507
- const isSelected = String(value) === String(option.value);
508
- return /* @__PURE__ */ jsxs(
509
- "div",
510
- {
511
- role: "option",
512
- "aria-selected": isSelected,
513
- className: cn(
514
- "relative flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none",
515
- "hover:bg-accent hover:text-accent-foreground",
516
- isSelected && "bg-accent text-accent-foreground"
517
- ),
518
- onMouseDown: (e) => {
519
- e.preventDefault();
520
- e.stopPropagation();
521
- handleSelect(option.value);
522
- },
523
- onClick: (e) => {
524
- e.preventDefault();
525
- e.stopPropagation();
526
- handleSelect(option.value);
527
- },
528
- children: [
529
- /* @__PURE__ */ jsx(
530
- Check,
531
- {
532
- className: cn(
533
- "mr-2 h-4 w-4 shrink-0",
534
- isSelected ? "opacity-100" : "opacity-0"
535
- )
536
- }
537
- ),
538
- /* @__PURE__ */ jsx("span", { className: "flex-1 truncate", children: option.label })
539
- ]
540
- },
541
- String(option.value)
542
- );
543
- }) }) })
544
- ] })
545
- }
546
- )
547
- ] });
548
- }
549
- var init_combobox = __esm({
550
- "src/ui/primitives/combobox.tsx"() {
551
- "use client";
552
- init_utils();
553
- init_button();
554
- init_input();
555
- init_scroll_area();
556
- }
557
- });
558
- function Select({
559
- ...props
560
- }) {
561
- return /* @__PURE__ */ jsx(SelectPrimitive.Root, { "data-slot": "select", ...props });
562
- }
563
- function SelectGroup({
564
- ...props
565
- }) {
566
- return /* @__PURE__ */ jsx(SelectPrimitive.Group, { "data-slot": "select-group", ...props });
567
- }
568
- function SelectValue({
569
- ...props
570
- }) {
571
- return /* @__PURE__ */ jsx(SelectPrimitive.Value, { "data-slot": "select-value", ...props });
572
- }
573
- function SelectTrigger({
574
- className,
575
- children,
576
- ...props
577
- }) {
578
- return /* @__PURE__ */ jsxs(
579
- SelectPrimitive.Trigger,
580
- {
581
- "data-slot": "select-trigger",
582
- className: cn(
583
- "cursor-pointer flex h-9 w-full items-center justify-between whitespace-nowrap rounded-md border border-input bg-transparent px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-hidden focus:ring-1 focus:ring-ring disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",
584
- className
585
- ),
586
- ...props,
587
- children: [
588
- children,
589
- /* @__PURE__ */ jsx(SelectPrimitive.Icon, { asChild: true, children: /* @__PURE__ */ jsx(ChevronDown, { className: "h-4 w-4 opacity-50" }) })
590
- ]
591
- }
592
- );
593
- }
594
- function SelectScrollUpButton({
595
- className,
596
- ...props
597
- }) {
598
- return /* @__PURE__ */ jsx(
599
- SelectPrimitive.ScrollUpButton,
600
- {
601
- "data-slot": "select-scroll-up-button",
602
- className: cn(
603
- "flex cursor-pointer items-center justify-center py-1",
604
- className
605
- ),
606
- ...props,
607
- children: /* @__PURE__ */ jsx(ChevronUp, { className: "h-4 w-4" })
608
- }
609
- );
610
- }
611
- function SelectScrollDownButton({
612
- className,
613
- ...props
614
- }) {
615
- return /* @__PURE__ */ jsx(
616
- SelectPrimitive.ScrollDownButton,
617
- {
618
- "data-slot": "select-scroll-down-button",
619
- className: cn(
620
- "flex cursor-pointer items-center justify-center py-1",
621
- className
622
- ),
623
- ...props,
624
- children: /* @__PURE__ */ jsx(ChevronDown, { className: "h-4 w-4" })
625
- }
626
- );
627
- }
628
- function SelectContent({
629
- className,
630
- children,
631
- position = "popper",
632
- ...props
633
- }) {
634
- return /* @__PURE__ */ jsx(SelectPrimitive.Portal, { children: /* @__PURE__ */ jsxs(
635
- SelectPrimitive.Content,
636
- {
637
- "data-slot": "select-content",
638
- className: cn(
639
- "relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
640
- position === "popper" && "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",
641
- className
642
- ),
643
- position,
644
- ...props,
645
- children: [
646
- /* @__PURE__ */ jsx(SelectScrollUpButton, {}),
647
- /* @__PURE__ */ jsx(
648
- SelectPrimitive.Viewport,
649
- {
650
- className: cn(
651
- "p-1",
652
- position === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"
653
- ),
654
- children
655
- }
656
- ),
657
- /* @__PURE__ */ jsx(SelectScrollDownButton, {})
658
- ]
659
- }
660
- ) });
661
- }
662
- function SelectLabel({
663
- className,
664
- ...props
665
- }) {
666
- return /* @__PURE__ */ jsx(
667
- SelectPrimitive.Label,
668
- {
669
- "data-slot": "select-label",
670
- className: cn("px-2 py-1.5 text-sm font-semibold", className),
671
- ...props
672
- }
673
- );
674
- }
675
- function SelectItem({
676
- className,
677
- children,
678
- ...props
679
- }) {
680
- return /* @__PURE__ */ jsxs(
681
- SelectPrimitive.Item,
682
- {
683
- "data-slot": "select-item",
684
- className: cn(
685
- "relative flex w-full cursor-pointer select-none items-center rounded-sm py-1.5 pl-2 pr-8 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
686
- className
687
- ),
688
- ...props,
689
- children: [
690
- /* @__PURE__ */ jsx("span", { className: "absolute right-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx(SelectPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Check, { className: "h-4 w-4" }) }) }),
691
- /* @__PURE__ */ jsx(SelectPrimitive.ItemText, { children })
692
- ]
693
- }
694
- );
695
- }
696
- function SelectSeparator({
697
- className,
698
- ...props
699
- }) {
700
- return /* @__PURE__ */ jsx(
701
- SelectPrimitive.Separator,
702
- {
703
- "data-slot": "select-separator",
704
- className: cn("-mx-1 my-1 h-px bg-muted", className),
705
- ...props
706
- }
707
- );
708
- }
709
- var init_select = __esm({
710
- "src/ui/primitives/select.tsx"() {
711
- "use client";
712
- init_utils();
713
- }
714
- });
715
- function Popover({
716
- ...props
717
- }) {
718
- return /* @__PURE__ */ jsx(PopoverPrimitive.Root, { "data-slot": "popover", ...props });
719
- }
720
- function PopoverTrigger({
721
- className,
722
- ...props
723
- }) {
724
- return /* @__PURE__ */ jsx(
725
- PopoverPrimitive.Trigger,
726
- {
727
- "data-slot": "popover-trigger",
728
- className: cn("cursor-pointer", className),
729
- ...props
730
- }
731
- );
732
- }
733
- function PopoverAnchor({
734
- ...props
735
- }) {
736
- return /* @__PURE__ */ jsx(PopoverPrimitive.Anchor, { "data-slot": "popover-anchor", ...props });
737
- }
738
- function PopoverContent({
739
- className,
740
- align = "center",
741
- sideOffset = 4,
742
- container,
743
- ...props
744
- }) {
745
- return /* @__PURE__ */ jsx(PopoverPrimitive.Portal, { container, children: /* @__PURE__ */ jsx(
746
- PopoverPrimitive.Content,
747
- {
748
- "data-slot": "popover-content",
749
- align,
750
- sideOffset,
751
- className: cn(
752
- "z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-hidden data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
753
- className
754
- ),
755
- ...props
756
- }
757
- ) });
758
- }
759
- var init_popover = __esm({
760
- "src/ui/primitives/popover.tsx"() {
761
- "use client";
762
- init_utils();
763
- }
764
- });
765
- function DropdownMenu({
766
- ...props
767
- }) {
768
- return /* @__PURE__ */ jsx(DropdownMenuPrimitive.Root, { "data-slot": "dropdown-menu", ...props });
769
- }
770
- function DropdownMenuPortal({
771
- ...props
772
- }) {
773
- return /* @__PURE__ */ jsx(DropdownMenuPrimitive.Portal, { "data-slot": "dropdown-menu-portal", ...props });
774
- }
775
- function DropdownMenuTrigger({
776
- className,
777
- ...props
778
- }) {
779
- return /* @__PURE__ */ jsx(
780
- DropdownMenuPrimitive.Trigger,
781
- {
782
- "data-slot": "dropdown-menu-trigger",
783
- className: cn("cursor-pointer", className),
784
- ...props
785
- }
786
- );
787
- }
788
- function DropdownMenuGroup({
789
- ...props
790
- }) {
791
- return /* @__PURE__ */ jsx(DropdownMenuPrimitive.Group, { "data-slot": "dropdown-menu-group", ...props });
792
- }
793
- function DropdownMenuRadioGroup({
794
- ...props
795
- }) {
796
- return /* @__PURE__ */ jsx(
797
- DropdownMenuPrimitive.RadioGroup,
798
- {
799
- "data-slot": "dropdown-menu-radio-group",
800
- ...props
801
- }
802
- );
803
- }
804
- function DropdownMenuSub({
805
- ...props
806
- }) {
807
- return /* @__PURE__ */ jsx(DropdownMenuPrimitive.Sub, { "data-slot": "dropdown-menu-sub", ...props });
808
- }
809
- function DropdownMenuSubTrigger({
810
- className,
811
- inset,
812
- children,
813
- ...props
814
- }) {
815
- return /* @__PURE__ */ jsxs(
816
- DropdownMenuPrimitive.SubTrigger,
817
- {
818
- "data-slot": "dropdown-menu-sub-trigger",
819
- "data-inset": inset,
820
- className: cn(
821
- "cursor-pointer flex items-center rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[inset]:ps-8 focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",
822
- className
823
- ),
824
- ...props,
825
- children: [
826
- children,
827
- /* @__PURE__ */ jsx(ChevronRight, { className: "ms-auto h-4 w-4 rtl:-scale-100" })
828
- ]
829
- }
830
- );
831
- }
832
- function DropdownMenuSubContent({
833
- className,
834
- ...props
835
- }) {
836
- return /* @__PURE__ */ jsx(
837
- DropdownMenuPrimitive.SubContent,
838
- {
839
- "data-slot": "dropdown-menu-sub-content",
840
- className: cn(
841
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
842
- className
843
- ),
844
- ...props
845
- }
846
- );
847
- }
848
- function DropdownMenuContent({
849
- className,
850
- sideOffset = 4,
851
- ...props
852
- }) {
853
- return /* @__PURE__ */ jsx(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ jsx(
854
- DropdownMenuPrimitive.Content,
855
- {
856
- "data-slot": "dropdown-menu-content",
857
- sideOffset,
858
- className: cn(
859
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
860
- className
861
- ),
862
- ...props
863
- }
864
- ) });
865
- }
866
- function DropdownMenuItem({
867
- className,
868
- inset,
869
- ...props
870
- }) {
871
- return /* @__PURE__ */ jsx(
872
- DropdownMenuPrimitive.Item,
873
- {
874
- "data-slot": "dropdown-menu-item",
875
- "data-inset": inset,
876
- className: cn(
877
- "relative flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm outline-hidden transition-colors focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 data-[inset]:ps-8",
878
- className
879
- ),
880
- ...props
881
- }
882
- );
883
- }
884
- function DropdownMenuCheckboxItem({
885
- className,
886
- children,
887
- checked,
888
- ...props
889
- }) {
890
- return /* @__PURE__ */ jsxs(
891
- DropdownMenuPrimitive.CheckboxItem,
892
- {
893
- "data-slot": "dropdown-menu-checkbox-item",
894
- className: cn(
895
- "relative flex cursor-pointer select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden transition-colors focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
896
- className
897
- ),
898
- checked,
899
- ...props,
900
- children: [
901
- /* @__PURE__ */ jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Check, { className: "h-4 w-4" }) }) }),
902
- children
903
- ]
904
- }
905
- );
906
- }
907
- function DropdownMenuRadioItem({
908
- className,
909
- children,
910
- ...props
911
- }) {
912
- return /* @__PURE__ */ jsxs(
913
- DropdownMenuPrimitive.RadioItem,
914
- {
915
- "data-slot": "dropdown-menu-radio-item",
916
- className: cn(
917
- "relative flex cursor-pointer select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden transition-colors focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
918
- className
919
- ),
920
- ...props,
921
- children: [
922
- /* @__PURE__ */ jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Dot, { className: "h-4 w-4 fill-current" }) }) }),
923
- children
924
- ]
925
- }
926
- );
927
- }
928
- function DropdownMenuLabel({
929
- className,
930
- inset,
931
- ...props
932
- }) {
933
- return /* @__PURE__ */ jsx(
934
- DropdownMenuPrimitive.Label,
935
- {
936
- "data-slot": "dropdown-menu-label",
937
- "data-inset": inset,
938
- className: cn(
939
- "px-2 py-1.5 text-sm font-semibold data-[inset]:ps-8",
940
- className
941
- ),
942
- ...props
943
- }
944
- );
945
- }
946
- function DropdownMenuSeparator({
947
- className,
948
- ...props
949
- }) {
950
- return /* @__PURE__ */ jsx(
951
- DropdownMenuPrimitive.Separator,
952
- {
953
- "data-slot": "dropdown-menu-separator",
954
- className: cn("-mx-1 my-1 h-px bg-muted", className),
955
- ...props
956
- }
957
- );
958
- }
959
- function DropdownMenuShortcut({
960
- className,
961
- ...props
962
- }) {
963
- return /* @__PURE__ */ jsx(
964
- "span",
965
- {
966
- "data-slot": "dropdown-menu-shortcut",
967
- className: cn("ml-auto text-xs tracking-widest opacity-60", className),
968
- ...props
969
- }
970
- );
971
- }
972
- var init_dropdown_menu = __esm({
973
- "src/ui/primitives/dropdown-menu.tsx"() {
974
- "use client";
975
- init_utils();
976
- }
977
- });
978
- function Switch({ className, ...props }) {
979
- return /* @__PURE__ */ jsx(
980
- SwitchPrimitives.Root,
981
- {
982
- "data-slot": "switch",
983
- className: cn(
984
- "peer inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",
985
- className
986
- ),
987
- ...props,
988
- children: /* @__PURE__ */ jsx(
989
- SwitchPrimitives.Thumb,
990
- {
991
- "data-slot": "switch-thumb",
992
- className: cn(
993
- "pointer-events-none block h-4 w-4 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0 rtl:data-[state=checked]:-translate-x-4"
994
- )
995
- }
996
- )
997
- }
998
- );
999
- }
1000
- var init_switch = __esm({
1001
- "src/ui/primitives/switch.tsx"() {
1002
- "use client";
1003
- init_utils();
1004
- }
1005
- });
1006
- var Checkbox;
1007
- var init_checkbox = __esm({
1008
- "src/ui/primitives/checkbox.tsx"() {
1009
- "use client";
1010
- init_utils();
1011
- Checkbox = React6.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
1012
- CheckboxPrimitive.Root,
1013
- {
1014
- ref,
1015
- className: cn(
1016
- "peer h-4 w-4 shrink-0 rounded-sm border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",
1017
- className
1018
- ),
1019
- ...props,
1020
- children: /* @__PURE__ */ jsx(
1021
- CheckboxPrimitive.Indicator,
1022
- {
1023
- className: cn("flex items-center justify-center text-current"),
1024
- children: /* @__PURE__ */ jsx(Check, { className: "h-4 w-4" })
1025
- }
1026
- )
1027
- }
1028
- ));
1029
- Checkbox.displayName = CheckboxPrimitive.Root.displayName;
1030
- }
1031
- });
1032
- var Label3;
1033
- var init_label = __esm({
1034
- "src/ui/primitives/label.tsx"() {
1035
- "use client";
1036
- init_utils();
1037
- Label3 = React6.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
1038
- LabelPrimitive.Root,
1039
- {
1040
- ref,
1041
- className: cn(
1042
- "text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70",
1043
- className
1044
- ),
1045
- ...props
1046
- }
1047
- ));
1048
- Label3.displayName = LabelPrimitive.Root.displayName;
1049
- }
1050
- });
1051
- function TooltipProvider({
1052
- delayDuration = 0,
1053
- ...props
1054
- }) {
1055
- return /* @__PURE__ */ jsx(
1056
- TooltipPrimitive.Provider,
1057
- {
1058
- "data-slot": "tooltip-provider",
1059
- delayDuration,
1060
- ...props
1061
- }
1062
- );
1063
- }
1064
- function Tooltip({
1065
- ...props
1066
- }) {
1067
- return /* @__PURE__ */ jsx(TooltipProvider, { children: /* @__PURE__ */ jsx(TooltipPrimitive.Root, { "data-slot": "tooltip", ...props }) });
1068
- }
1069
- function TooltipTrigger({
1070
- className,
1071
- ...props
1072
- }) {
1073
- return /* @__PURE__ */ jsx(
1074
- TooltipPrimitive.Trigger,
1075
- {
1076
- "data-slot": "tooltip-trigger",
1077
- className: cn("cursor-pointer", className),
1078
- ...props
1079
- }
1080
- );
1081
- }
1082
- function TooltipContent({
1083
- className,
1084
- sideOffset = 0,
1085
- ...props
1086
- }) {
1087
- return /* @__PURE__ */ jsx(
1088
- TooltipPrimitive.Content,
1089
- {
1090
- "data-slot": "tooltip-content",
1091
- sideOffset,
1092
- className: cn(
1093
- "z-50 overflow-hidden rounded-md bg-primary px-3 py-1.5 text-sm text-primary-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
1094
- className
1095
- ),
1096
- ...props
1097
- }
1098
- );
1099
- }
1100
- var init_tooltip = __esm({
1101
- "src/ui/primitives/tooltip.tsx"() {
1102
- "use client";
1103
- init_utils();
1104
- }
1105
- });
1106
- var init_tenant_provider = __esm({
1107
- "src/providers/tenant-provider.tsx"() {
1108
- createContext(void 0);
1109
- }
1110
- });
1111
- var defaultSettings, SettingsContext;
1112
- var init_providers = __esm({
1113
- "src/providers/index.tsx"() {
1114
- "use client";
1115
- init_tenant_provider();
1116
- defaultSettings = {
1117
- theme: "blue",
1118
- mode: "system",
1119
- radius: 0.5,
1120
- layout: "vertical",
1121
- locale: "vi",
1122
- sidebarVariant: "sidebar",
1123
- sidebarCollapsible: "icon",
1124
- density: "comfortable"
1125
- };
1126
- SettingsContext = createContext(void 0);
1127
- }
1128
- });
1129
- function ResizablePanelGroup({
1130
- className,
1131
- ...props
1132
- }) {
1133
- return /* @__PURE__ */ jsx(
1134
- ResizablePrimitive.PanelGroup,
1135
- {
1136
- "data-slot": "resizable-panel-group",
1137
- className: cn(
1138
- "flex h-full w-full data-[panel-group-direction=vertical]:flex-col",
1139
- className
1140
- ),
1141
- ...props
1142
- }
1143
- );
1144
- }
1145
- function ResizablePanel({
1146
- ...props
1147
- }) {
1148
- return /* @__PURE__ */ jsx(ResizablePrimitive.Panel, { "data-slot": "resizable-panel", ...props });
1149
- }
1150
- function ResizableHandle({
1151
- withHandle,
1152
- className,
1153
- ...props
1154
- }) {
1155
- return /* @__PURE__ */ jsx(
1156
- ResizablePrimitive.PanelResizeHandle,
1157
- {
1158
- "data-slot": "resizable-handle",
1159
- className: cn(
1160
- "relative flex w-px items-center justify-center bg-border after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:outline-hidden focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-1 data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:-translate-y-1/2 data-[panel-group-direction=vertical]:after:translate-x-0 [&[data-panel-group-direction=vertical]>div]:rotate-90",
1161
- className
1162
- ),
1163
- ...props,
1164
- children: withHandle && /* @__PURE__ */ jsx("div", { className: "z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border", children: /* @__PURE__ */ jsx(GripVertical, { className: "h-2.5 w-2.5" }) })
1165
- }
1166
- );
1167
- }
1168
- var init_resizable = __esm({
1169
- "src/ui/primitives/resizable.tsx"() {
1170
- "use client";
1171
- init_utils();
1172
- }
1173
- });
1174
- function Slider({
1175
- className,
1176
- ...props
1177
- }) {
1178
- return /* @__PURE__ */ jsxs(
1179
- SliderPrimitive.Root,
1180
- {
1181
- className: cn(
1182
- "relative flex w-full touch-none select-none items-center",
1183
- className
1184
- ),
1185
- ...props,
1186
- children: [
1187
- /* @__PURE__ */ jsx(SliderPrimitive.Track, { className: "relative h-1.5 w-full grow overflow-hidden rounded-full bg-primary/20", children: /* @__PURE__ */ jsx(SliderPrimitive.Range, { className: "absolute h-full bg-primary" }) }),
1188
- /* @__PURE__ */ jsx(SliderPrimitive.Thumb, { className: "cursor-pointer block h-4 w-4 rounded-full border border-primary/50 bg-background shadow-sm transition-colors focus-visible:outline-hidden focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50" })
1189
- ]
1190
- }
1191
- );
1192
- }
1193
- var init_slider = __esm({
1194
- "src/ui/primitives/slider.tsx"() {
1195
- "use client";
1196
- init_utils();
1197
- }
1198
- });
1199
- function MenubarMenu({
1200
- ...props
1201
- }) {
1202
- return /* @__PURE__ */ jsx(MenubarPrimitive.Menu, { "data-slot": "menubar-menu", ...props });
1203
- }
1204
- function MenubarGroup({
1205
- ...props
1206
- }) {
1207
- return /* @__PURE__ */ jsx(MenubarPrimitive.Group, { "data-slot": "menubar-group", ...props });
1208
- }
1209
- function MenubarPortal({
1210
- ...props
1211
- }) {
1212
- return /* @__PURE__ */ jsx(MenubarPrimitive.Portal, { "data-slot": "menubar-portal", ...props });
1213
- }
1214
- function MenubarRadioGroup({
1215
- ...props
1216
- }) {
1217
- return /* @__PURE__ */ jsx(MenubarPrimitive.RadioGroup, { "data-slot": "menubar-radio-group", ...props });
1218
- }
1219
- function Menubar({
1220
- className,
1221
- ...props
1222
- }) {
1223
- return /* @__PURE__ */ jsx(
1224
- MenubarPrimitive.Root,
1225
- {
1226
- "data-slot": "menubar",
1227
- className: cn(
1228
- "flex h-9 items-center gap-x-1 rounded-md border bg-background p-1",
1229
- className
1230
- ),
1231
- ...props
1232
- }
1233
- );
1234
- }
1235
- function MenubarTrigger({
1236
- className,
1237
- ...props
1238
- }) {
1239
- return /* @__PURE__ */ jsx(
1240
- MenubarPrimitive.Trigger,
1241
- {
1242
- "data-slot": "menubar-trigger",
1243
- className: cn(
1244
- "flex cursor-pointer select-none items-center rounded-sm px-3 py-1 text-sm font-medium outline-hidden focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",
1245
- className
1246
- ),
1247
- ...props
1248
- }
1249
- );
1250
- }
1251
- function MenubarSubTrigger({
1252
- className,
1253
- inset,
1254
- children,
1255
- ...props
1256
- }) {
1257
- return /* @__PURE__ */ jsxs(
1258
- MenubarPrimitive.SubTrigger,
1259
- {
1260
- "data-slot": "menubar-sub-trigger",
1261
- "data-inset": inset,
1262
- className: cn(
1263
- "focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground cursor-pointer flex items-center rounded-sm px-2 py-1.5 text-sm outline-none select-none data-[inset]:ps-8",
1264
- className
1265
- ),
1266
- ...props,
1267
- children: [
1268
- children,
1269
- /* @__PURE__ */ jsx(ChevronRight, { className: "ms-auto h-4 w-4 rtl:-scale-x-100" })
1270
- ]
1271
- }
1272
- );
1273
- }
1274
- function MenubarSub({
1275
- ...props
1276
- }) {
1277
- return /* @__PURE__ */ jsx(MenubarPrimitive.Sub, { "data-slot": "menubar-sub", ...props });
1278
- }
1279
- function MenubarSubContent({
1280
- className,
1281
- ...props
1282
- }) {
1283
- return /* @__PURE__ */ jsx(
1284
- MenubarPrimitive.SubContent,
1285
- {
1286
- "data-slot": "menubar-sub-content",
1287
- className: cn(
1288
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
1289
- className
1290
- ),
1291
- ...props
1292
- }
1293
- );
1294
- }
1295
- function MenubarContent({
1296
- className,
1297
- align = "start",
1298
- alignOffset = -4,
1299
- sideOffset = 8,
1300
- ...props
1301
- }) {
1302
- return /* @__PURE__ */ jsx(MenubarPortal, { children: /* @__PURE__ */ jsx(
1303
- MenubarPrimitive.Content,
1304
- {
1305
- "data-slot": "menubar-content",
1306
- align,
1307
- alignOffset,
1308
- sideOffset,
1309
- className: cn(
1310
- "z-50 min-w-[12rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
1311
- className
1312
- ),
1313
- ...props
1314
- }
1315
- ) });
1316
- }
1317
- function MenubarItem({
1318
- className,
1319
- inset,
1320
- variant = "default",
1321
- ...props
1322
- }) {
1323
- return /* @__PURE__ */ jsx(
1324
- MenubarPrimitive.Item,
1325
- {
1326
- "data-slot": "menubar-item",
1327
- "data-inset": inset,
1328
- "data-variant": variant,
1329
- className: cn(
1330
- "relative flex cursor-pointer items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground",
1331
- className
1332
- ),
1333
- ...props
1334
- }
1335
- );
1336
- }
1337
- function MenubarCheckboxItem({
1338
- className,
1339
- children,
1340
- checked,
1341
- ...props
1342
- }) {
1343
- return /* @__PURE__ */ jsxs(
1344
- MenubarPrimitive.CheckboxItem,
1345
- {
1346
- "data-slot": "menubar-checkbox-item",
1347
- className: cn(
1348
- "relative flex cursor-pointer select-none items-center rounded-sm py-1.5 ps-8 pe-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
1349
- className
1350
- ),
1351
- checked,
1352
- ...props,
1353
- children: [
1354
- /* @__PURE__ */ jsx("span", { className: "absolute start-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx(MenubarPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Check, { className: "h-4 w-4" }) }) }),
1355
- children
1356
- ]
1357
- }
1358
- );
1359
- }
1360
- function MenubarRadioItem({
1361
- className,
1362
- children,
1363
- ...props
1364
- }) {
1365
- return /* @__PURE__ */ jsxs(
1366
- MenubarPrimitive.RadioItem,
1367
- {
1368
- "data-slot": "menubar-radio-item",
1369
- className: cn(
1370
- "relative flex cursor-pointer select-none items-center rounded-sm py-1.5 ps-8 pe-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
1371
- className
1372
- ),
1373
- ...props,
1374
- children: [
1375
- /* @__PURE__ */ jsx("span", { className: "absolute start-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx(MenubarPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Dot, { className: "h-4 w-4 fill-current" }) }) }),
1376
- children
1377
- ]
1378
- }
1379
- );
1380
- }
1381
- function MenubarLabel({
1382
- className,
1383
- inset,
1384
- ...props
1385
- }) {
1386
- return /* @__PURE__ */ jsx(
1387
- MenubarPrimitive.Label,
1388
- {
1389
- "data-slot": "menubar-label",
1390
- className: cn(
1391
- "px-2 py-1.5 text-sm font-semibold",
1392
- inset && "ps-8",
1393
- className
1394
- ),
1395
- ...props
1396
- }
1397
- );
1398
- }
1399
- function MenubarSeparator({
1400
- className,
1401
- ...props
1402
- }) {
1403
- return /* @__PURE__ */ jsx(
1404
- MenubarPrimitive.Separator,
1405
- {
1406
- "data-slot": "menubar-separator",
1407
- className: cn("-mx-1 my-1 h-px bg-muted", className),
1408
- ...props
1409
- }
1410
- );
1411
- }
1412
- function MenubarShortcut({
1413
- className,
1414
- ...props
1415
- }) {
1416
- return /* @__PURE__ */ jsx(
1417
- "span",
1418
- {
1419
- "data-slot": "menubar-shortcut",
1420
- className: cn(
1421
- "ms-auto text-xs tracking-widest text-muted-foreground",
1422
- className
1423
- ),
1424
- ...props
1425
- }
1426
- );
1427
- }
1428
- var init_menubar = __esm({
1429
- "src/ui/primitives/menubar.tsx"() {
1430
- "use client";
1431
- init_utils();
1432
- }
1433
- });
1434
- function NavigationMenu({
1435
- className,
1436
- children,
1437
- viewport = true,
1438
- ...props
1439
- }) {
1440
- return /* @__PURE__ */ jsxs(
1441
- NavigationMenuPrimitive.Root,
1442
- {
1443
- "data-slot": "navigation-menu",
1444
- "data-viewport": viewport,
1445
- className: cn(
1446
- "group/navigation-menu relative flex max-w-max flex-1 items-center justify-center",
1447
- className
1448
- ),
1449
- ...props,
1450
- children: [
1451
- children,
1452
- viewport && /* @__PURE__ */ jsx(NavigationMenuViewport, {})
1453
- ]
1454
- }
1455
- );
1456
- }
1457
- function NavigationMenuList({
1458
- className,
1459
- ...props
1460
- }) {
1461
- return /* @__PURE__ */ jsx(
1462
- NavigationMenuPrimitive.List,
1463
- {
1464
- "data-slot": "navigation-menu-list",
1465
- className: cn(
1466
- "group flex flex-1 list-none items-center justify-center gap-1",
1467
- className
1468
- ),
1469
- ...props
1470
- }
1471
- );
1472
- }
1473
- function NavigationMenuItem({
1474
- className,
1475
- ...props
1476
- }) {
1477
- return /* @__PURE__ */ jsx(
1478
- NavigationMenuPrimitive.Item,
1479
- {
1480
- "data-slot": "navigation-menu-item",
1481
- className: cn("relative", className),
1482
- ...props
1483
- }
1484
- );
1485
- }
1486
- function NavigationMenuTrigger({
1487
- className,
1488
- children,
1489
- ...props
1490
- }) {
1491
- return /* @__PURE__ */ jsxs(
1492
- NavigationMenuPrimitive.Trigger,
1493
- {
1494
- "data-slot": "navigation-menu-trigger",
1495
- className: cn(navigationMenuTriggerStyle(), "group", className),
1496
- ...props,
1497
- children: [
1498
- children,
1499
- " ",
1500
- /* @__PURE__ */ jsx(
1501
- ChevronDown,
1502
- {
1503
- className: "relative top-[1px] ms-1 size-3 transition duration-300 group-data-[state=open]:rotate-180",
1504
- "aria-hidden": "true"
1505
- }
1506
- )
1507
- ]
1508
- }
1509
- );
1510
- }
1511
- function NavigationMenuContent({
1512
- className,
1513
- ...props
1514
- }) {
1515
- return /* @__PURE__ */ jsx(
1516
- NavigationMenuPrimitive.Content,
1517
- {
1518
- "data-slot": "navigation-menu-content",
1519
- className: cn(
1520
- "data-[motion^=from-]:animate-in data-[motion^=to-]:animate-out data-[motion^=from-]:fade-in data-[motion^=to-]:fade-out data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 top-0 left-0 w-full p-2 pr-2.5 md:absolute md:w-auto",
1521
- "group-data-[viewport=false]/navigation-menu:bg-popover group-data-[viewport=false]/navigation-menu:text-popover-foreground group-data-[viewport=false]/navigation-menu:data-[state=open]:animate-in group-data-[viewport=false]/navigation-menu:data-[state=closed]:animate-out group-data-[viewport=false]/navigation-menu:data-[state=closed]:zoom-out-95 group-data-[viewport=false]/navigation-menu:data-[state=open]:zoom-in-95 group-data-[viewport=false]/navigation-menu:data-[state=open]:fade-in-0 group-data-[viewport=false]/navigation-menu:data-[state=closed]:fade-out-0 group-data-[viewport=false]/navigation-menu:top-full group-data-[viewport=false]/navigation-menu:mt-1.5 group-data-[viewport=false]/navigation-menu:overflow-hidden group-data-[viewport=false]/navigation-menu:rounded-md group-data-[viewport=false]/navigation-menu:border group-data-[viewport=false]/navigation-menu:shadow group-data-[viewport=false]/navigation-menu:duration-200 **:data-[slot=navigation-menu-link]:focus:ring-0 **:data-[slot=navigation-menu-link]:focus:outline-none",
1522
- className
1523
- ),
1524
- ...props
1525
- }
1526
- );
1527
- }
1528
- function NavigationMenuLink({
1529
- className,
1530
- ...props
1531
- }) {
1532
- return /* @__PURE__ */ jsx(
1533
- NavigationMenuPrimitive.Link,
1534
- {
1535
- "data-slot": "navigation-menu-link",
1536
- className: cn(
1537
- "data-[active=true]:focus:bg-accent data-[active=true]:hover:bg-accent data-[active=true]:bg-accent/50 data-[active=true]:text-accent-foreground hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus-visible:ring-ring/50 [&_svg:not([class*='text-'])]:text-muted-foreground flex flex-col gap-1 rounded-sm p-2 text-sm transition-all outline-none focus-visible:ring-[3px] focus-visible:outline-1 [&_svg:not([class*='size-'])]:size-4",
1538
- className
1539
- ),
1540
- ...props
1541
- }
1542
- );
1543
- }
1544
- function NavigationMenuViewport({
1545
- className,
1546
- ...props
1547
- }) {
1548
- return /* @__PURE__ */ jsx("div", { className: cn("absolute start-0 top-full flex justify-center"), children: /* @__PURE__ */ jsx(
1549
- NavigationMenuPrimitive.Viewport,
1550
- {
1551
- "data-slot": "navigation-menu-viewport",
1552
- className: cn(
1553
- "origin-top-center relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-sm data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-90 md:w-[var(--radix-navigation-menu-viewport-width)]",
1554
- className
1555
- ),
1556
- ...props
1557
- }
1558
- ) });
1559
- }
1560
- function NavigationMenuIndicator({
1561
- className,
1562
- ...props
1563
- }) {
1564
- return /* @__PURE__ */ jsx(
1565
- NavigationMenuPrimitive.Indicator,
1566
- {
1567
- "data-slot": "navigation-menu-indicator",
1568
- className: cn(
1569
- "top-full z-1 flex h-1.5 items-end justify-center overflow-hidden data-[state=visible]:animate-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:fade-in",
1570
- className
1571
- ),
1572
- ...props,
1573
- children: /* @__PURE__ */ jsx("div", { className: "relative top-[60%] h-2 w-2 rotate-45 rounded-te-sm bg-border shadow-md" })
1574
- }
1575
- );
1576
- }
1577
- var navigationMenuTriggerStyle;
1578
- var init_navigation_menu = __esm({
1579
- "src/ui/primitives/navigation-menu.tsx"() {
1580
- init_utils();
1581
- navigationMenuTriggerStyle = cva(
1582
- "group cursor-pointer inline-flex h-9 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground disabled:pointer-events-none disabled:opacity-50 data-[state=open]:hover:bg-accent data-[state=open]:text-accent-foreground data-[state=open]:focus:bg-accent data-[state=open]:bg-accent/50 focus-visible:ring-ring/50 outline-none transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1"
1583
- );
1584
- }
1585
- });
1586
- function Toggle({
1587
- className,
1588
- variant,
1589
- size,
1590
- ...props
1591
- }) {
1592
- return /* @__PURE__ */ jsx(
1593
- TogglePrimitive.Root,
1594
- {
1595
- "data-slot": "toggle",
1596
- className: cn(toggleVariants({ variant, size, className })),
1597
- ...props
1598
- }
1599
- );
1600
- }
1601
- var toggleVariants;
1602
- var init_toggle = __esm({
1603
- "src/ui/primitives/toggle.tsx"() {
1604
- "use client";
1605
- init_utils();
1606
- toggleVariants = cva(
1607
- "cursor-pointer inline-flex items-center justify-center rounded-md text-sm font-medium transition-colors hover:bg-muted hover:text-muted-foreground focus-visible:outline-hidden focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 data-[state=on]:bg-accent data-[state=on]:text-accent-foreground",
1608
- {
1609
- variants: {
1610
- variant: {
1611
- default: "bg-transparent",
1612
- outline: "border border-input bg-transparent hover:bg-accent hover:text-accent-foreground"
1613
- },
1614
- size: {
1615
- default: "h-9 px-3",
1616
- sm: "h-8 px-2",
1617
- lg: "h-10 px-3"
1618
- }
1619
- },
1620
- defaultVariants: {
1621
- variant: "default",
1622
- size: "default"
1623
- }
1624
- }
1625
- );
1626
- }
1627
- });
1628
- function ToggleGroup({
1629
- className,
1630
- variant,
1631
- size,
1632
- children,
1633
- ...props
1634
- }) {
1635
- return /* @__PURE__ */ jsx(
1636
- ToggleGroupPrimitive.Root,
1637
- {
1638
- "data-slot": "toggle-group",
1639
- className: cn("flex items-center justify-center gap-1", className),
1640
- ...props,
1641
- children: /* @__PURE__ */ jsx(ToggleGroupContext.Provider, { value: { variant, size }, children })
1642
- }
1643
- );
1644
- }
1645
- function ToggleGroupItem({
1646
- className,
1647
- children,
1648
- variant,
1649
- size,
1650
- ...props
1651
- }) {
1652
- const context = useContext(ToggleGroupContext);
1653
- return /* @__PURE__ */ jsx(
1654
- ToggleGroupPrimitive.Item,
1655
- {
1656
- "data-slot": "toggle-group-item",
1657
- className: cn(
1658
- toggleVariants({
1659
- variant: context.variant || variant,
1660
- size: context.size || size
1661
- }),
1662
- className
1663
- ),
1664
- ...props,
1665
- children
1666
- }
1667
- );
1668
- }
1669
- var ToggleGroupContext;
1670
- var init_toggle_group = __esm({
1671
- "src/ui/primitives/toggle-group.tsx"() {
1672
- "use client";
1673
- init_utils();
1674
- init_toggle();
1675
- ToggleGroupContext = createContext({
1676
- size: "default",
1677
- variant: "default"
1678
- });
1679
- }
1680
- });
1681
- function DynamicIcon({ name, ...props }) {
1682
- if (!name) return null;
1683
- const LucideIcon = icons[name];
1684
- if (!LucideIcon) return null;
1685
- return /* @__PURE__ */ jsx(LucideIcon, { ...props });
1686
- }
1687
- var init_dynamic_icon = __esm({
1688
- "src/ui/primitives/dynamic-icon.tsx"() {
1689
- "use client";
1690
- }
1691
- });
1692
- function Progress({
1693
- className,
1694
- value,
1695
- max,
1696
- ...props
1697
- }) {
1698
- return /* @__PURE__ */ jsx(
1699
- ProgressPrimitive.Root,
1700
- {
1701
- "data-slot": "progress",
1702
- className: cn(
1703
- "relative h-2 w-full overflow-hidden rounded-lg bg-primary/20",
1704
- className
1705
- ),
1706
- max,
1707
- ...props,
1708
- children: /* @__PURE__ */ jsx(
1709
- ProgressPrimitive.Indicator,
1710
- {
1711
- "data-slot": "progress-indicator",
1712
- className: "h-full w-full flex-1 bg-primary transition-all",
1713
- style: {
1714
- transform: `translateX(-${100 - (value || 0) / (max || 100) * 100}%)`
1715
- }
1716
- }
1717
- )
1718
- }
1719
- );
1720
- }
1721
- var init_progress = __esm({
1722
- "src/ui/feedback/progress.tsx"() {
1723
- "use client";
1724
- init_utils();
1725
- }
1726
- });
1727
- function Sheet({
1728
- ...props
1729
- }) {
1730
- return /* @__PURE__ */ jsx(SheetPrimitive.Root, { "data-slot": "sheet", ...props });
1731
- }
1732
- function SheetTrigger({
1733
- className,
1734
- ...props
1735
- }) {
1736
- return /* @__PURE__ */ jsx(
1737
- SheetPrimitive.Trigger,
1738
- {
1739
- "data-slot": "sheet-trigger",
1740
- className: cn("cursor-pointer", className),
1741
- ...props
1742
- }
1743
- );
1744
- }
1745
- function SheetClose({
1746
- ...props
1747
- }) {
1748
- return /* @__PURE__ */ jsx(SheetPrimitive.Close, { "data-slot": "sheet-close", ...props });
1749
- }
1750
- function SheetPortal({
1751
- ...props
1752
- }) {
1753
- return /* @__PURE__ */ jsx(SheetPrimitive.Portal, { "data-slot": "sheet-portal", ...props });
1754
- }
1755
- function SheetOverlay({
1756
- className,
1757
- ...props
1758
- }) {
1759
- return /* @__PURE__ */ jsx(
1760
- SheetPrimitive.Overlay,
1761
- {
1762
- "data-slot": "sheet-overlay",
1763
- className: cn(
1764
- "fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
1765
- className
1766
- ),
1767
- ...props
1768
- }
1769
- );
1770
- }
1771
- function SheetContent({
1772
- className,
1773
- children,
1774
- side = "right",
1775
- ...props
1776
- }) {
1777
- return /* @__PURE__ */ jsxs(SheetPortal, { children: [
1778
- /* @__PURE__ */ jsx(SheetOverlay, {}),
1779
- /* @__PURE__ */ jsx(
1780
- SheetPrimitive.Content,
1781
- {
1782
- "data-slot": "sheet-content",
1783
- className: cn(sheetVariants({ side }), className),
1784
- ...props,
1785
- children
1786
- }
1787
- )
1788
- ] });
1789
- }
1790
- function SheetHeader({ className, ...props }) {
1791
- return /* @__PURE__ */ jsx(
1792
- "div",
1793
- {
1794
- "data-slot": "sheet-header",
1795
- className: cn("flex flex-col space-y-1", className),
1796
- ...props
1797
- }
1798
- );
1799
- }
1800
- function SheetFooter({ className, ...props }) {
1801
- return /* @__PURE__ */ jsx(
1802
- "div",
1803
- {
1804
- "data-slot": "sheet-footer",
1805
- className: cn(
1806
- "flex flex-col-reverse sm:flex-row sm:justify-end sm:gap-x-2",
1807
- className
1808
- ),
1809
- ...props
1810
- }
1811
- );
1812
- }
1813
- function SheetTitle({
1814
- className,
1815
- ...props
1816
- }) {
1817
- return /* @__PURE__ */ jsx(
1818
- SheetPrimitive.Title,
1819
- {
1820
- "data-slot": "sheet-title",
1821
- className: cn("text-lg font-semibold text-foreground", className),
1822
- ...props
1823
- }
1824
- );
1825
- }
1826
- function SheetDescription({
1827
- className,
1828
- ...props
1829
- }) {
1830
- return /* @__PURE__ */ jsx(
1831
- SheetPrimitive.Description,
1832
- {
1833
- "data-slot": "sheet-description",
1834
- className: cn("text-sm text-muted-foreground", className),
1835
- ...props
1836
- }
1837
- );
1838
- }
1839
- var sheetVariants;
1840
- var init_sheet = __esm({
1841
- "src/ui/feedback/sheet.tsx"() {
1842
- "use client";
1843
- init_utils();
1844
- sheetVariants = cva(
1845
- "fixed z-50 gap-4 bg-background p-4 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500 data-[state=open]:animate-in data-[state=closed]:animate-out",
1846
- {
1847
- variants: {
1848
- side: {
1849
- top: "inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",
1850
- bottom: "inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",
1851
- left: "inset-y-0 left-0 h-full w-72 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",
1852
- right: "inset-y-0 right-0 h-full w-72 border-s data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm",
1853
- start: "inset-y-0 start-0 h-full w-72 border-e data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left data-[state=closed]:rtl:slide-out-to-right data-[state=open]:rtl:slide-in-from-right sm:max-w-sm",
1854
- end: "inset-y-0 end-0 h-full w-72 border-s data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right data-[state=closed]:rtl:slide-out-to-left data-[state=open]:rtl:slide-in-from-left sm:max-w-sm"
1855
- }
1856
- },
1857
- defaultVariants: {
1858
- side: "right"
1859
- }
1860
- }
1861
- );
1862
- }
1863
- });
1864
- var init_alert = __esm({
1865
- "src/ui/feedback/alert.tsx"() {
1866
- cva(
1867
- "relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7",
1868
- {
1869
- variants: {
1870
- variant: {
1871
- default: "bg-background text-foreground",
1872
- destructive: "border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive"
1873
- }
1874
- },
1875
- defaultVariants: {
1876
- variant: "default"
1877
- }
1878
- }
1879
- );
1880
- }
1881
- });
1882
- function ContextMenu({
1883
- ...props
1884
- }) {
1885
- return /* @__PURE__ */ jsx(ContextMenuPrimitive.Root, { "data-slot": "context-menu", ...props });
1886
- }
1887
- function ContextMenuTrigger({
1888
- ...props
1889
- }) {
1890
- return /* @__PURE__ */ jsx(ContextMenuPrimitive.Trigger, { "data-slot": "context-menu-trigger", ...props });
1891
- }
1892
- function ContextMenuGroup({
1893
- ...props
1894
- }) {
1895
- return /* @__PURE__ */ jsx(ContextMenuPrimitive.Group, { "data-slot": "context-menu-group", ...props });
1896
- }
1897
- function ContextMenuPortal({
1898
- ...props
1899
- }) {
1900
- return /* @__PURE__ */ jsx(ContextMenuPrimitive.Portal, { "data-slot": "context-menu-portal", ...props });
1901
- }
1902
- function ContextMenuSub({
1903
- ...props
1904
- }) {
1905
- return /* @__PURE__ */ jsx(ContextMenuPrimitive.Sub, { "data-slot": "context-menu-sub", ...props });
1906
- }
1907
- function ContextMenuRadioGroup({
1908
- ...props
1909
- }) {
1910
- return /* @__PURE__ */ jsx(
1911
- ContextMenuPrimitive.RadioGroup,
1912
- {
1913
- "data-slot": "context-menu-radio-group",
1914
- ...props
1915
- }
1916
- );
1917
- }
1918
- function ContextMenuSubTrigger({
1919
- className,
1920
- inset,
1921
- children,
1922
- ...props
1923
- }) {
1924
- return /* @__PURE__ */ jsxs(
1925
- ContextMenuPrimitive.SubTrigger,
1926
- {
1927
- "data-slot": "context-menu-sub-trigger",
1928
- className: cn(
1929
- "flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",
1930
- inset && "ps-8",
1931
- className
1932
- ),
1933
- ...props,
1934
- children: [
1935
- children,
1936
- /* @__PURE__ */ jsx(ChevronRight, { className: "ml-auto h-4 w-4" })
1937
- ]
1938
- }
1939
- );
1940
- }
1941
- function ContextMenuSubContent({
1942
- className,
1943
- ...props
1944
- }) {
1945
- return /* @__PURE__ */ jsx(
1946
- ContextMenuPrimitive.SubContent,
1947
- {
1948
- "data-slot": "context-menu-sub-content",
1949
- className: cn(
1950
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
1951
- className
1952
- ),
1953
- ...props
1954
- }
1955
- );
1956
- }
1957
- function ContextMenuContent({
1958
- className,
1959
- ...props
1960
- }) {
1961
- return /* @__PURE__ */ jsx(ContextMenuPrimitive.Portal, { children: /* @__PURE__ */ jsx(
1962
- ContextMenuPrimitive.Content,
1963
- {
1964
- "data-slot": "context-menu-content",
1965
- className: cn(
1966
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
1967
- className
1968
- ),
1969
- ...props
1970
- }
1971
- ) });
1972
- }
1973
- function ContextMenuItem({
1974
- className,
1975
- inset,
1976
- variant = "default",
1977
- ...props
1978
- }) {
1979
- return /* @__PURE__ */ jsx(
1980
- ContextMenuPrimitive.Item,
1981
- {
1982
- "data-slot": "context-menu-item",
1983
- "data-inset": inset,
1984
- "data-variant": variant,
1985
- className: cn(
1986
- "relative flex cursor-pointer items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground",
1987
- className
1988
- ),
1989
- ...props
1990
- }
1991
- );
1992
- }
1993
- function ContextMenuCheckboxItem({
1994
- className,
1995
- children,
1996
- checked,
1997
- ...props
1998
- }) {
1999
- return /* @__PURE__ */ jsxs(
2000
- ContextMenuPrimitive.CheckboxItem,
2001
- {
2002
- "data-slot": "context-menu-checkbox-item",
2003
- className: cn(
2004
- "relative flex cursor-pointer select-none items-center rounded-sm py-1.5 ps-8 pe-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
2005
- className
2006
- ),
2007
- checked,
2008
- ...props,
2009
- children: [
2010
- /* @__PURE__ */ jsx("span", { className: "absolute start-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx(ContextMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Check, { className: "h-4 w-4" }) }) }),
2011
- children
2012
- ]
2013
- }
2014
- );
2015
- }
2016
- function ContextMenuRadioItem({
2017
- className,
2018
- children,
2019
- ...props
2020
- }) {
2021
- return /* @__PURE__ */ jsxs(
2022
- ContextMenuPrimitive.RadioItem,
2023
- {
2024
- "data-slot": "context-menu-radio-item",
2025
- className: cn(
2026
- "relative flex cursor-pointer select-none items-center rounded-sm py-1.5 ps-8 pe-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
2027
- className
2028
- ),
2029
- ...props,
2030
- children: [
2031
- /* @__PURE__ */ jsx("span", { className: "absolute start-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx(ContextMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(Dot, { className: "h-4 w-4 fill-current" }) }) }),
2032
- children
2033
- ]
2034
- }
2035
- );
2036
- }
2037
- function ContextMenuLabel({
2038
- className,
2039
- inset,
2040
- ...props
2041
- }) {
2042
- return /* @__PURE__ */ jsx(
2043
- ContextMenuPrimitive.Label,
2044
- {
2045
- "data-slot": "context-menu-label",
2046
- className: cn(
2047
- "px-2 py-1.5 text-sm font-semibold text-foreground",
2048
- inset && "ps-8",
2049
- className
2050
- ),
2051
- ...props
2052
- }
2053
- );
2054
- }
2055
- function ContextMenuSeparator({
2056
- className,
2057
- ...props
2058
- }) {
2059
- return /* @__PURE__ */ jsx(
2060
- ContextMenuPrimitive.Separator,
2061
- {
2062
- "data-slot": "context-menu-separator",
2063
- className: cn("-mx-1 my-1 h-px bg-border", className),
2064
- ...props
2065
- }
2066
- );
2067
- }
2068
- function ContextMenuShortcut({
2069
- className,
2070
- ...props
2071
- }) {
2072
- return /* @__PURE__ */ jsx(
2073
- "span",
2074
- {
2075
- "data-slot": "context-menu-shortcut",
2076
- className: cn(
2077
- "ms-auto text-sm tracking-widest text-muted-foreground",
2078
- className
2079
- ),
2080
- ...props
2081
- }
2082
- );
2083
- }
2084
- var init_context_menu = __esm({
2085
- "src/ui/feedback/context-menu.tsx"() {
2086
- "use client";
2087
- init_utils();
2088
- }
2089
- });
2090
- function Drawer({
2091
- shouldScaleBackground = true,
2092
- ...props
2093
- }) {
2094
- return /* @__PURE__ */ jsx(
2095
- Drawer$1.Root,
2096
- {
2097
- "data-slot": "drawer",
2098
- shouldScaleBackground,
2099
- ...props
2100
- }
2101
- );
2102
- }
2103
- function DrawerTrigger({
2104
- className,
2105
- ...props
2106
- }) {
2107
- return /* @__PURE__ */ jsx(
2108
- Drawer$1.Trigger,
2109
- {
2110
- "data-slot": "drawer-trigger",
2111
- className: cn("cursor-pointer", className),
2112
- ...props
2113
- }
2114
- );
2115
- }
2116
- function DrawerPortal({
2117
- children,
2118
- ...props
2119
- }) {
2120
- const Portal8 = Drawer$1.Portal;
2121
- return /* @__PURE__ */ jsx(Portal8, { "data-slot": "drawer-portal", ...props, children });
2122
- }
2123
- function DrawerClose({
2124
- ...props
2125
- }) {
2126
- return /* @__PURE__ */ jsx(Drawer$1.Close, { "data-slot": "drawer-close", ...props });
2127
- }
2128
- function DrawerOverlay({
2129
- className,
2130
- ...props
2131
- }) {
2132
- return /* @__PURE__ */ jsx(
2133
- Drawer$1.Overlay,
2134
- {
2135
- "data-slot": "drawer-overlay",
2136
- className: cn("fixed inset-0 z-50 bg-black/80", className),
2137
- ...props
2138
- }
2139
- );
2140
- }
2141
- function DrawerContent({
2142
- className,
2143
- children,
2144
- ...props
2145
- }) {
2146
- return /* @__PURE__ */ jsxs(DrawerPortal, { "data-slot": "drawer-portal", children: [
2147
- /* @__PURE__ */ jsx(DrawerOverlay, {}),
2148
- /* @__PURE__ */ jsxs(
2149
- Drawer$1.Content,
2150
- {
2151
- "data-slot": "drawer-content",
2152
- className: cn(
2153
- "fixed inset-x-0 bottom-0 z-50 mt-24 flex h-auto flex-col rounded-t-[10px] border bg-background",
2154
- className
2155
- ),
2156
- ...props,
2157
- children: [
2158
- /* @__PURE__ */ jsx("div", { className: "mx-auto mt-4 h-2 w-[100px] rounded-full bg-muted" }),
2159
- children
2160
- ]
2161
- }
2162
- )
2163
- ] });
2164
- }
2165
- function DrawerHeader({ className, ...props }) {
2166
- return /* @__PURE__ */ jsx(
2167
- "div",
2168
- {
2169
- "data-slot": "drawer-header",
2170
- className: cn("grid gap-1.5 p-4 text-center sm:text-start", className),
2171
- ...props
2172
- }
2173
- );
2174
- }
2175
- function DrawerFooter({ className, ...props }) {
2176
- return /* @__PURE__ */ jsx(
2177
- "div",
2178
- {
2179
- "data-slot": "drawer-footer",
2180
- className: cn("mt-auto flex flex-col gap-2 p-4", className),
2181
- ...props
2182
- }
2183
- );
2184
- }
2185
- function DrawerTitle({
2186
- className,
2187
- ...props
2188
- }) {
2189
- return /* @__PURE__ */ jsx(
2190
- Drawer$1.Title,
2191
- {
2192
- "data-slot": "drawer-title",
2193
- className: cn(
2194
- "text-lg font-semibold leading-none tracking-tight",
2195
- className
2196
- ),
2197
- ...props
2198
- }
2199
- );
2200
- }
2201
- function DrawerDescription({
2202
- className,
2203
- ...props
2204
- }) {
2205
- return /* @__PURE__ */ jsx(
2206
- Drawer$1.Description,
2207
- {
2208
- "data-slot": "drawer-description",
2209
- className: cn("text-sm text-muted-foreground", className),
2210
- ...props
2211
- }
2212
- );
2213
- }
2214
- var init_drawer = __esm({
2215
- "src/ui/feedback/drawer.tsx"() {
2216
- "use client";
2217
- init_utils();
2218
- }
2219
- });
2220
- function Toaster({ ...props }) {
2221
- const { settings } = useSettings();
2222
- const mode = settings.mode;
2223
- return /* @__PURE__ */ jsx(
2224
- Toaster$1,
2225
- {
2226
- theme: mode,
2227
- className: "toaster group",
2228
- toastOptions: {
2229
- classNames: {
2230
- toast: "group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",
2231
- description: "group-[.toast]:text-muted-foreground",
2232
- actionButton: "group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",
2233
- cancelButton: "group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"
2234
- }
2235
- },
2236
- richColors: true,
2237
- closeButton: true,
2238
- ...props
2239
- }
2240
- );
2241
- }
2242
- var init_sonner = __esm({
2243
- "src/ui/feedback/sonner.tsx"() {
2244
- "use client";
2245
- init_hooks();
2246
- }
2247
- });
2248
- var GlobalErrorEmitter;
2249
- var init_error_dialog = __esm({
2250
- "src/ui/feedback/error-dialog.tsx"() {
2251
- "use client";
2252
- GlobalErrorEmitter = class {
2253
- constructor() {
2254
- this.listeners = [];
2255
- }
2256
- subscribe(listener) {
2257
- this.listeners.push(listener);
2258
- return () => {
2259
- this.listeners = this.listeners.filter((l) => l !== listener);
2260
- };
2261
- }
2262
- emit(data) {
2263
- this.listeners.forEach((listener) => listener(data));
2264
- }
2265
- };
2266
- new GlobalErrorEmitter();
2267
- createContext(null);
2268
- }
2269
- });
2270
- var init_feedback = __esm({
2271
- "src/ui/feedback/index.tsx"() {
2272
- init_progress();
2273
- init_sheet();
2274
- init_alert();
2275
- init_context_menu();
2276
- init_drawer();
2277
- init_sonner();
2278
- init_error_dialog();
2279
- }
2280
- });
2281
-
2282
- // src/hooks/use-tenant.ts
2283
- var init_use_tenant = __esm({
2284
- "src/hooks/use-tenant.ts"() {
2285
- }
2286
- });
2287
- function useMediaQuery(query) {
2288
- const [matches, setMatches] = useState(false);
2289
- useEffect(() => {
2290
- if (typeof window !== "undefined") {
2291
- const media = window.matchMedia(query);
2292
- setMatches(media.matches);
2293
- const listener = (event) => setMatches(event.matches);
2294
- media.addEventListener("change", listener);
2295
- return () => media.removeEventListener("change", listener);
2296
- }
2297
- }, [query]);
2298
- return matches;
2299
- }
2300
- function useMobile() {
2301
- return useMediaQuery("(max-width: 768px)");
2302
- }
2303
- function useSettings() {
2304
- const context = useContext(SettingsContext);
2305
- if (!context) {
2306
- return defaultSettingsValue;
2307
- }
2308
- return context;
2309
- }
2310
- function usePrefetch() {
2311
- const router = useRouter();
2312
- const prefetchedRoutes = useRef(/* @__PURE__ */ new Set());
2313
- const prefetchedAPIs = useRef(/* @__PURE__ */ new Set());
2314
- const prefetchRoute = useCallback(
2315
- (route) => {
2316
- if (prefetchedRoutes.current.has(route)) {
2317
- return;
2318
- }
2319
- try {
2320
- router.prefetch(route);
2321
- prefetchedRoutes.current.add(route);
2322
- } catch (error) {
2323
- console.debug("Prefetch failed for route:", route, error);
2324
- }
2325
- },
2326
- [router]
2327
- );
2328
- const prefetchAPI = useCallback((endpoint, options) => {
2329
- const url = endpoint;
2330
- const cacheKey = `${url}-${JSON.stringify(options || {})}`;
2331
- if (prefetchedAPIs.current.has(cacheKey)) {
2332
- return;
2333
- }
2334
- try {
2335
- fetch(url, {
2336
- method: "HEAD",
2337
- ...options,
2338
- headers: {
2339
- ...options?.headers,
2340
- "Cache-Control": "max-age=60"
2341
- }
2342
- }).then(() => {
2343
- prefetchedAPIs.current.add(cacheKey);
2344
- }).catch(() => {
2345
- });
2346
- } catch (error) {
2347
- console.debug("API prefetch failed:", url, error);
2348
- }
2349
- }, []);
2350
- const prefetchCrudPage = useCallback(
2351
- (entity, apiEndpoint) => {
2352
- const route = `/crud/${entity}`;
2353
- prefetchRoute(route);
2354
- const apiUrl = `${apiEndpoint}?page=1&pageSize=10`;
2355
- prefetchAPI(apiUrl);
2356
- },
2357
- [prefetchRoute, prefetchAPI]
2358
- );
2359
- const prefetchNextPage = useCallback(
2360
- (apiEndpoint, currentPage, pageSize, queryParams) => {
2361
- const nextPage = currentPage + 1;
2362
- const params = new URLSearchParams({
2363
- page: String(nextPage),
2364
- pageSize: String(pageSize)
2365
- });
2366
- if (queryParams) {
2367
- Object.entries(queryParams).forEach(([k, v]) => {
2368
- if (v === void 0 || v === null || v === "") {
2369
- return;
2370
- }
2371
- if (typeof v === "object" && !Array.isArray(v)) {
2372
- params.append(k, JSON.stringify(v));
2373
- } else if (Array.isArray(v)) {
2374
- params.append(k, JSON.stringify(v));
2375
- } else {
2376
- params.append(k, String(v));
2377
- }
2378
- });
2379
- }
2380
- const apiUrl = `${apiEndpoint}?${params.toString()}`;
2381
- prefetchAPI(apiUrl);
2382
- },
2383
- [prefetchAPI]
2384
- );
2385
- return {
2386
- prefetchRoute,
2387
- prefetchAPI,
2388
- prefetchCrudPage,
2389
- prefetchNextPage
2390
- };
2391
- }
2392
- var defaultSettingsValue;
2393
- var init_hooks = __esm({
2394
- "src/hooks/index.tsx"() {
2395
- "use client";
2396
- init_providers();
2397
- init_use_tenant();
2398
- defaultSettingsValue = {
2399
- settings: defaultSettings,
2400
- updateSettings: () => {
2401
- },
2402
- resetSettings: () => {
2403
- }
2404
- };
2405
- createContext(null);
2406
- }
2407
- });
2408
- function useSidebar() {
2409
- const context = React6.useContext(SidebarContext);
2410
- if (!context) {
2411
- throw new Error("useSidebar must be used within a SidebarProvider.");
2412
- }
2413
- return context;
2414
- }
2415
- var SIDEBAR_WIDTH, SIDEBAR_WIDTH_MOBILE, SIDEBAR_WIDTH_ICON, SIDEBAR_KEYBOARD_SHORTCUT, SidebarContext, SidebarProvider, Sidebar, SidebarTrigger, SidebarRail, SidebarInset, SidebarInput, SidebarHeader, SidebarFooter, SidebarSeparator, SidebarContent, SidebarGroup, SidebarGroupLabel, SidebarGroupAction, SidebarGroupContent, SidebarMenu, SidebarMenuItem, sidebarMenuButtonVariants, SidebarMenuButton, SidebarMenuAction, SidebarMenuBadge, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubItem, SidebarMenuSubButton;
2416
- var init_sidebar = __esm({
2417
- "src/ui/primitives/sidebar.tsx"() {
2418
- "use client";
2419
- init_hooks();
2420
- init_utils();
2421
- init_button();
2422
- init_feedback();
2423
- init_tooltip();
2424
- SIDEBAR_WIDTH = "16rem";
2425
- SIDEBAR_WIDTH_MOBILE = "18rem";
2426
- SIDEBAR_WIDTH_ICON = "3rem";
2427
- SIDEBAR_KEYBOARD_SHORTCUT = "b";
2428
- SidebarContext = React6.createContext(null);
2429
- SidebarProvider = React6.forwardRef(
2430
- ({
2431
- defaultOpen = false,
2432
- open: openProp,
2433
- onOpenChange: setOpenProp,
2434
- className,
2435
- style,
2436
- children,
2437
- ...props
2438
- }, ref) => {
2439
- const isMobile = useMobile();
2440
- const [openMobile, setOpenMobile] = React6.useState(false);
2441
- const [hoverOpen, setHoverOpen] = React6.useState(false);
2442
- const [_open, _setOpen] = React6.useState(defaultOpen);
2443
- const open = openProp ?? _open;
2444
- const setOpen = React6.useCallback(
2445
- (value) => {
2446
- if (setOpenProp) {
2447
- return setOpenProp(typeof value === "function" ? value(open) : value);
2448
- }
2449
- _setOpen(value);
2450
- },
2451
- [setOpenProp, open]
2452
- );
2453
- const toggleSidebar = React6.useCallback(() => {
2454
- return isMobile ? setOpenMobile((open2) => !open2) : setOpen((open2) => !open2);
2455
- }, [isMobile, setOpen, setOpenMobile]);
2456
- React6.useEffect(() => {
2457
- const handleKeyDown = (event) => {
2458
- if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {
2459
- event.preventDefault();
2460
- toggleSidebar();
2461
- }
2462
- };
2463
- window.addEventListener("keydown", handleKeyDown);
2464
- return () => window.removeEventListener("keydown", handleKeyDown);
2465
- }, [toggleSidebar]);
2466
- const state = open ? "expanded" : "collapsed";
2467
- const isHoverExpanded = !open && hoverOpen;
2468
- const contextValue = React6.useMemo(
2469
- () => ({
2470
- state,
2471
- open,
2472
- setOpen,
2473
- isMobile,
2474
- openMobile,
2475
- setOpenMobile,
2476
- toggleSidebar,
2477
- hoverOpen,
2478
- setHoverOpen,
2479
- isHoverExpanded
2480
- }),
2481
- [
2482
- state,
2483
- open,
2484
- setOpen,
2485
- isMobile,
2486
- openMobile,
2487
- setOpenMobile,
2488
- toggleSidebar,
2489
- hoverOpen,
2490
- setHoverOpen,
2491
- isHoverExpanded
2492
- ]
2493
- );
2494
- return /* @__PURE__ */ jsx(SidebarContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsx(TooltipProvider, { delayDuration: 0, children: /* @__PURE__ */ jsx(
2495
- "div",
2496
- {
2497
- style: {
2498
- "--sidebar-width": SIDEBAR_WIDTH,
2499
- "--sidebar-width-icon": SIDEBAR_WIDTH_ICON,
2500
- ...style
2501
- },
2502
- className: cn(
2503
- "group/sidebar-wrapper flex min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar",
2504
- className
2505
- ),
2506
- ref,
2507
- ...props,
2508
- children
2509
- }
2510
- ) }) });
2511
- }
2512
- );
2513
- SidebarProvider.displayName = "SidebarProvider";
2514
- Sidebar = React6.forwardRef(
2515
- ({
2516
- side = "left",
2517
- variant = "sidebar",
2518
- collapsible = "offcanvas",
2519
- hoverExpandEnabled = true,
2520
- className,
2521
- children,
2522
- ...props
2523
- }, ref) => {
2524
- const {
2525
- isMobile,
2526
- state,
2527
- openMobile,
2528
- setOpenMobile,
2529
- setHoverOpen,
2530
- isHoverExpanded
2531
- } = useSidebar();
2532
- const handleMouseEnter = React6.useCallback(() => {
2533
- if (hoverExpandEnabled && state === "collapsed" && collapsible === "icon") {
2534
- setHoverOpen(true);
2535
- }
2536
- }, [hoverExpandEnabled, state, collapsible, setHoverOpen]);
2537
- const handleMouseLeave = React6.useCallback(() => {
2538
- if (hoverExpandEnabled) {
2539
- setHoverOpen(false);
2540
- }
2541
- }, [hoverExpandEnabled, setHoverOpen]);
2542
- if (collapsible === "none") {
2543
- return /* @__PURE__ */ jsx(
2544
- "div",
2545
- {
2546
- className: cn(
2547
- "flex h-full w-(--sidebar-width) flex-col bg-sidebar text-sidebar-foreground",
2548
- className
2549
- ),
2550
- ref,
2551
- ...props,
2552
- children
2553
- }
2554
- );
2555
- }
2556
- if (isMobile) {
2557
- return /* @__PURE__ */ jsx(Sheet, { open: openMobile, onOpenChange: setOpenMobile, ...props, children: /* @__PURE__ */ jsxs(
2558
- SheetContent,
2559
- {
2560
- "data-sidebar": "sidebar",
2561
- "data-mobile": "true",
2562
- className: "w-(--sidebar-width) bg-background p-0 text-foreground [&>button]:hidden",
2563
- style: {
2564
- "--sidebar-width": SIDEBAR_WIDTH_MOBILE
2565
- },
2566
- side,
2567
- children: [
2568
- /* @__PURE__ */ jsx(SheetTitle, { className: "sr-only", children: "Mobile Menu" }),
2569
- /* @__PURE__ */ jsx("div", { className: "flex h-full w-full flex-col", children })
2570
- ]
2571
- }
2572
- ) });
2573
- }
2574
- return /* @__PURE__ */ jsxs(
2575
- "div",
2576
- {
2577
- ref,
2578
- className: cn(
2579
- "group peer hidden md:block transition-colors duration-200",
2580
- // Blue bg + white text when collapsed, white bg + dark text when expanded/hover
2581
- state === "collapsed" && !isHoverExpanded ? "text-sidebar-foreground" : "text-foreground"
2582
- ),
2583
- "data-state": state,
2584
- "data-hover-expanded": isHoverExpanded,
2585
- "data-collapsible": state === "collapsed" ? collapsible : "",
2586
- "data-variant": variant,
2587
- "data-side": side,
2588
- onMouseEnter: handleMouseEnter,
2589
- onMouseLeave: handleMouseLeave,
2590
- children: [
2591
- /* @__PURE__ */ jsx(
2592
- "div",
2593
- {
2594
- className: cn(
2595
- "duration-200 relative h-svh w-(--sidebar-width) bg-transparent transition-[width] ease-linear",
2596
- "group-data-[collapsible=offcanvas]:w-0",
2597
- "group-data-[collapsible=icon]:w-(--sidebar-width-icon)",
2598
- variant === "floating" || variant === "inset" ? "group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_2px)]" : "group-data-[collapsible=icon]:w-(--sidebar-width-icon)"
2599
- )
2600
- }
2601
- ),
2602
- /* @__PURE__ */ jsx(
2603
- "div",
2604
- {
2605
- className: cn(
2606
- "duration-200 fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] ease-linear md:flex",
2607
- side === "left" ? "left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]" : "right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",
2608
- // Adjustments for collapsible=icon
2609
- variant === "floating" || variant === "inset" ? "p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_8px)] group-data-[collapsible=icon]:px-2.5" : "group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[collapsible=icon]:border-r group-data-[collapsible=icon]:px-0",
2610
- // Hover expand - override icon width to full width on hover
2611
- "group-data-[hover-expanded=true]:!w-(--sidebar-width) group-data-[hover-expanded=true]:shadow-xl group-data-[hover-expanded=true]:z-[100]",
2612
- className
2613
- ),
2614
- ...props,
2615
- children: /* @__PURE__ */ jsx(
2616
- "div",
2617
- {
2618
- "data-sidebar": "sidebar",
2619
- className: cn(
2620
- "flex h-full w-full flex-col border-r transition-colors duration-200",
2621
- // Blue background when collapsed, white when expanded/hover
2622
- "group-data-[state=collapsed]:bg-sidebar group-data-[state=collapsed]:border-sidebar-border",
2623
- "group-data-[state=expanded]:bg-background group-data-[state=expanded]:border-border",
2624
- "group-data-[hover-expanded=true]:!bg-background group-data-[hover-expanded=true]:!border-border",
2625
- "group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow"
2626
- ),
2627
- children
2628
- }
2629
- )
2630
- }
2631
- )
2632
- ]
2633
- }
2634
- );
2635
- }
2636
- );
2637
- Sidebar.displayName = "Sidebar";
2638
- SidebarTrigger = React6.forwardRef(({ className, onClick, ...props }, ref) => {
2639
- const { toggleSidebar } = useSidebar();
2640
- return /* @__PURE__ */ jsxs(
2641
- Button,
2642
- {
2643
- ref,
2644
- "data-sidebar": "trigger",
2645
- variant: "ghost",
2646
- size: "icon",
2647
- className: cn("h-7 w-7", className),
2648
- onClick: (event) => {
2649
- onClick?.(event);
2650
- toggleSidebar();
2651
- },
2652
- ...props,
2653
- children: [
2654
- /* @__PURE__ */ jsx(PanelLeft, {}),
2655
- /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Toggle Sidebar" })
2656
- ]
2657
- }
2658
- );
2659
- });
2660
- SidebarTrigger.displayName = "SidebarTrigger";
2661
- SidebarRail = React6.forwardRef(({ className, ...props }, ref) => {
2662
- const { toggleSidebar } = useSidebar();
2663
- return /* @__PURE__ */ jsx(
2664
- "button",
2665
- {
2666
- ref,
2667
- "data-sidebar": "rail",
2668
- "aria-label": "Toggle Sidebar",
2669
- tabIndex: -1,
2670
- onClick: toggleSidebar,
2671
- title: "Toggle Sidebar",
2672
- className: cn(
2673
- "absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex",
2674
- "[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize",
2675
- "[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize",
2676
- "group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar",
2677
- "[[data-side=left][data-collapsible=offcanvas]_&]:-right-2",
2678
- "[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",
2679
- className
2680
- ),
2681
- ...props
2682
- }
2683
- );
2684
- });
2685
- SidebarRail.displayName = "SidebarRail";
2686
- SidebarInset = React6.forwardRef(({ className, ...props }, ref) => {
2687
- return /* @__PURE__ */ jsx(
2688
- "main",
2689
- {
2690
- ref,
2691
- className: cn(
2692
- "relative flex min-h-svh flex-1 flex-col bg-muted/40 transition-[margin] duration-200 ease-linear",
2693
- "peer-data-[variant=inset]:min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow",
2694
- className
2695
- ),
2696
- ...props
2697
- }
2698
- );
2699
- });
2700
- SidebarInset.displayName = "SidebarInset";
2701
- SidebarInput = React6.forwardRef(({ className, ...props }, ref) => {
2702
- return /* @__PURE__ */ jsx(
2703
- "input",
2704
- {
2705
- ref,
2706
- "data-sidebar": "input",
2707
- className: cn(
2708
- "flex h-8 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-sidebar-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",
2709
- className
2710
- ),
2711
- ...props
2712
- }
2713
- );
2714
- });
2715
- SidebarInput.displayName = "SidebarInput";
2716
- SidebarHeader = React6.forwardRef(({ className, ...props }, ref) => {
2717
- return /* @__PURE__ */ jsx(
2718
- "div",
2719
- {
2720
- ref,
2721
- "data-sidebar": "header",
2722
- className: cn("flex flex-col gap-2 p-2", className),
2723
- ...props
2724
- }
2725
- );
2726
- });
2727
- SidebarHeader.displayName = "SidebarHeader";
2728
- SidebarFooter = React6.forwardRef(({ className, ...props }, ref) => {
2729
- return /* @__PURE__ */ jsx(
2730
- "div",
2731
- {
2732
- ref,
2733
- "data-sidebar": "footer",
2734
- className: cn("flex flex-col gap-2 p-2", className),
2735
- ...props
2736
- }
2737
- );
2738
- });
2739
- SidebarFooter.displayName = "SidebarFooter";
2740
- SidebarSeparator = React6.forwardRef(({ className, ...props }, ref) => {
2741
- return /* @__PURE__ */ jsx(
2742
- "div",
2743
- {
2744
- ref,
2745
- "data-sidebar": "separator",
2746
- className: cn("mx-2 h-[1px] w-auto bg-sidebar-border", className),
2747
- ...props
2748
- }
2749
- );
2750
- });
2751
- SidebarSeparator.displayName = "SidebarSeparator";
2752
- SidebarContent = React6.forwardRef(({ className, ...props }, ref) => {
2753
- return /* @__PURE__ */ jsx(
2754
- "div",
2755
- {
2756
- ref,
2757
- "data-sidebar": "content",
2758
- className: cn(
2759
- "flex min-h-0 flex-1 flex-col gap-2 overflow-auto",
2760
- // Hide overflow when collapsed, but show when hover-expanded
2761
- "group-data-[collapsible=icon]:overflow-hidden group-data-[hover-expanded=true]:!overflow-auto",
2762
- className
2763
- ),
2764
- ...props
2765
- }
2766
- );
2767
- });
2768
- SidebarContent.displayName = "SidebarContent";
2769
- SidebarGroup = React6.forwardRef(({ className, ...props }, ref) => {
2770
- return /* @__PURE__ */ jsx(
2771
- "div",
2772
- {
2773
- ref,
2774
- "data-sidebar": "group",
2775
- className: cn("relative flex w-full min-w-0 flex-col p-2", className),
2776
- ...props
2777
- }
2778
- );
2779
- });
2780
- SidebarGroup.displayName = "SidebarGroup";
2781
- SidebarGroupLabel = React6.forwardRef(({ className, asChild = false, ...props }, ref) => {
2782
- const Comp = asChild ? Slot : "div";
2783
- return /* @__PURE__ */ jsx(
2784
- Comp,
2785
- {
2786
- ref,
2787
- "data-sidebar": "group-label",
2788
- className: cn(
2789
- "duration-200 flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-bold text-primary uppercase tracking-wider outline-none ring-sidebar-ring transition-[margin,opa] ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0",
2790
- // Hide when collapsed, show when hover-expanded
2791
- "group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",
2792
- "group-data-[hover-expanded=true]:!mt-0 group-data-[hover-expanded=true]:!opacity-100",
2793
- className
2794
- ),
2795
- ...props
2796
- }
2797
- );
2798
- });
2799
- SidebarGroupLabel.displayName = "SidebarGroupLabel";
2800
- SidebarGroupAction = React6.forwardRef(({ className, asChild = false, ...props }, ref) => {
2801
- const Comp = asChild ? Slot : "button";
2802
- return /* @__PURE__ */ jsx(
2803
- Comp,
2804
- {
2805
- ref,
2806
- "data-sidebar": "group-action",
2807
- className: cn(
2808
- "absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0",
2809
- // Increases the hit area of the button on mobile.
2810
- "after:absolute after:-inset-2 after:md:hidden",
2811
- "group-data-[collapsible=icon]:hidden",
2812
- className
2813
- ),
2814
- ...props
2815
- }
2816
- );
2817
- });
2818
- SidebarGroupAction.displayName = "SidebarGroupAction";
2819
- SidebarGroupContent = React6.forwardRef(({ className, ...props }, ref) => {
2820
- return /* @__PURE__ */ jsx(
2821
- "div",
2822
- {
2823
- ref,
2824
- "data-sidebar": "group-content",
2825
- className: cn("w-full text-sm", className),
2826
- ...props
2827
- }
2828
- );
2829
- });
2830
- SidebarGroupContent.displayName = "SidebarGroupContent";
2831
- SidebarMenu = React6.forwardRef(({ className, ...props }, ref) => {
2832
- return /* @__PURE__ */ jsx(
2833
- "ul",
2834
- {
2835
- ref,
2836
- "data-sidebar": "menu",
2837
- className: cn("flex w-full min-w-0 flex-col gap-1", className),
2838
- ...props
2839
- }
2840
- );
2841
- });
2842
- SidebarMenu.displayName = "SidebarMenu";
2843
- SidebarMenuItem = React6.forwardRef(({ className, ...props }, ref) => {
2844
- return /* @__PURE__ */ jsx(
2845
- "li",
2846
- {
2847
- ref,
2848
- "data-sidebar": "menu-item",
2849
- className: cn("group/menu-item relative", className),
2850
- ...props
2851
- }
2852
- );
2853
- });
2854
- SidebarMenuItem.displayName = "SidebarMenuItem";
2855
- sidebarMenuButtonVariants = cva(
2856
- // Base styles + hover-expand overrides
2857
- "peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 group-data-[hover-expanded=true]:!size-auto group-data-[hover-expanded=true]:!w-full group-data-[hover-expanded=true]:!p-2",
2858
- {
2859
- variants: {
2860
- variant: {
2861
- default: "hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",
2862
- outline: "bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"
2863
- },
2864
- size: {
2865
- default: "h-8 text-sm",
2866
- sm: "h-7 text-xs",
2867
- lg: "h-12 text-sm group-data-[collapsible=icon]:!p-0"
2868
- },
2869
- isActive: {
2870
- true: "bg-primary/10 text-primary font-bold"
2871
- }
2872
- },
2873
- defaultVariants: {
2874
- variant: "default",
2875
- size: "default"
2876
- }
2877
- }
2878
- );
2879
- SidebarMenuButton = React6.forwardRef(
2880
- ({
2881
- asChild = false,
2882
- isActive = false,
2883
- variant = "default",
2884
- size = "default",
2885
- tooltip,
2886
- className,
2887
- ...props
2888
- }, ref) => {
2889
- const Comp = asChild ? Slot : "button";
2890
- const { isMobile, state } = useSidebar();
2891
- const button = /* @__PURE__ */ jsx(
2892
- Comp,
2893
- {
2894
- ref,
2895
- "data-sidebar": "menu-button",
2896
- "data-size": size,
2897
- "data-active": isActive,
2898
- className: cn(
2899
- sidebarMenuButtonVariants({ variant, size, isActive }),
2900
- className
2901
- ),
2902
- ...props
2903
- }
2904
- );
2905
- if (!tooltip) {
2906
- return button;
2907
- }
2908
- if (typeof tooltip === "string") {
2909
- tooltip = {
2910
- children: tooltip
2911
- };
2912
- }
2913
- return /* @__PURE__ */ jsxs(Tooltip, { children: [
2914
- /* @__PURE__ */ jsx(TooltipTrigger, { asChild: true, children: button }),
2915
- /* @__PURE__ */ jsx(
2916
- TooltipContent,
2917
- {
2918
- side: "right",
2919
- align: "center",
2920
- hidden: state !== "collapsed" || isMobile,
2921
- ...tooltip
2922
- }
2923
- )
2924
- ] });
2925
- }
2926
- );
2927
- SidebarMenuButton.displayName = "SidebarMenuButton";
2928
- SidebarMenuAction = React6.forwardRef(({ className, asChild = false, showOnHover = false, ...props }, ref) => {
2929
- const Comp = asChild ? Slot : "button";
2930
- return /* @__PURE__ */ jsx(
2931
- Comp,
2932
- {
2933
- ref,
2934
- "data-sidebar": "menu-action",
2935
- className: cn(
2936
- "absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0",
2937
- // Increases the hit area of the button on mobile.
2938
- "after:absolute after:-inset-2 after:md:hidden",
2939
- "peer-data-[size=sm]/menu-button:top-1",
2940
- "peer-data-[size=default]/menu-button:top-1.5",
2941
- "peer-data-[size=lg]/menu-button:top-2.5",
2942
- "group-data-[collapsible=icon]:hidden",
2943
- showOnHover && "group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 md:opacity-0",
2944
- className
2945
- ),
2946
- ...props
2947
- }
2948
- );
2949
- });
2950
- SidebarMenuAction.displayName = "SidebarMenuAction";
2951
- SidebarMenuBadge = React6.forwardRef(({ className, ...props }, ref) => {
2952
- return /* @__PURE__ */ jsx(
2953
- "div",
2954
- {
2955
- ref,
2956
- "data-sidebar": "menu-badge",
2957
- className: cn(
2958
- "pointer-events-none absolute right-1 flex h-5 min-w-5 items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums text-sidebar-foreground select-none",
2959
- "peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground",
2960
- "peer-data-[size=sm]/menu-button:top-1",
2961
- "peer-data-[size=default]/menu-button:top-1.5",
2962
- "peer-data-[size=lg]/menu-button:top-2.5",
2963
- "group-data-[collapsible=icon]:hidden",
2964
- className
2965
- ),
2966
- ...props
2967
- }
2968
- );
2969
- });
2970
- SidebarMenuBadge.displayName = "SidebarMenuBadge";
2971
- SidebarMenuSkeleton = React6.forwardRef(({ className, showIcon = false, ...props }, ref) => {
2972
- const width = React6.useMemo(() => {
2973
- return `${Math.floor(Math.random() * 40) + 50}%`;
2974
- }, []);
2975
- return /* @__PURE__ */ jsxs(
2976
- "div",
2977
- {
2978
- ref,
2979
- "data-sidebar": "menu-skeleton",
2980
- className: cn("flex h-8 items-center gap-2 rounded-md px-2", className),
2981
- ...props,
2982
- children: [
2983
- showIcon && /* @__PURE__ */ jsx(
2984
- "div",
2985
- {
2986
- className: "size-4 rounded-md animate-pulse bg-muted",
2987
- "data-sidebar": "menu-skeleton-icon"
2988
- }
2989
- ),
2990
- /* @__PURE__ */ jsx(
2991
- "div",
2992
- {
2993
- className: "h-4 flex-1 max-w-[--skeleton-width] animate-pulse bg-muted rounded-full",
2994
- "data-sidebar": "menu-skeleton-text",
2995
- style: {
2996
- "--skeleton-width": width
2997
- }
2998
- }
2999
- )
3000
- ]
3001
- }
3002
- );
3003
- });
3004
- SidebarMenuSkeleton.displayName = "SidebarMenuSkeleton";
3005
- SidebarMenuSub = React6.forwardRef(({ className, ...props }, ref) => {
3006
- return /* @__PURE__ */ jsx(
3007
- "ul",
3008
- {
3009
- ref,
3010
- "data-sidebar": "menu-sub",
3011
- className: cn(
3012
- "mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5",
3013
- // Hide when collapsed, show when hover-expanded
3014
- "group-data-[collapsible=icon]:hidden group-data-[hover-expanded=true]:!flex",
3015
- className
3016
- ),
3017
- ...props
3018
- }
3019
- );
3020
- });
3021
- SidebarMenuSub.displayName = "SidebarMenuSub";
3022
- SidebarMenuSubItem = React6.forwardRef(({ ...props }, ref) => /* @__PURE__ */ jsx("li", { ref, ...props }));
3023
- SidebarMenuSubItem.displayName = "SidebarMenuSubItem";
3024
- SidebarMenuSubButton = React6.forwardRef(({ asChild = false, size = "md", isActive, className, ...props }, ref) => {
3025
- const Comp = asChild ? Slot : "a";
3026
- return /* @__PURE__ */ jsx(
3027
- Comp,
3028
- {
3029
- ref,
3030
- "data-sidebar": "menu-sub-button",
3031
- "data-size": size,
3032
- "data-active": isActive,
3033
- className: cn(
3034
- "flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 text-xs",
3035
- "data-[active=true]:bg-primary/15 data-[active=true]:!text-primary data-[active=true]:font-bold",
3036
- size === "sm" && "text-xs",
3037
- size === "md" && "text-sm",
3038
- className
3039
- ),
3040
- ...props
3041
- }
3042
- );
3043
- });
3044
- SidebarMenuSubButton.displayName = "SidebarMenuSubButton";
3045
- }
3046
- });
3047
- function StickyLayout({ className, asChild, ...props }) {
3048
- const Comp = asChild ? Slot : "div";
3049
- return /* @__PURE__ */ jsx(
3050
- Comp,
3051
- {
3052
- "data-slot": "sticky-layout",
3053
- className: cn("grid items-start gap-4 lg:grid-cols-2", className),
3054
- ...props
3055
- }
3056
- );
3057
- }
3058
- function StickyLayoutPane({
3059
- className,
3060
- ...props
3061
- }) {
3062
- return /* @__PURE__ */ jsx(
3063
- "div",
3064
- {
3065
- "data-slot": "sticky-layout-pane",
3066
- className: cn(
3067
- "top-20 flex flex-col items-center text-center space-y-1.5 lg:sticky lg:block lg:text-start",
3068
- className
3069
- ),
3070
- ...props
3071
- }
3072
- );
3073
- }
3074
- function StickyLayoutContent({
3075
- className,
3076
- ...props
3077
- }) {
3078
- return /* @__PURE__ */ jsx(
3079
- "div",
3080
- {
3081
- "data-slot": "sticky-layout-content",
3082
- className: cn("space-y-4", className),
3083
- ...props
3084
- }
3085
- );
3086
- }
3087
- var init_sticky_layout = __esm({
3088
- "src/ui/primitives/sticky-layout.tsx"() {
3089
- init_utils();
3090
- }
3091
- });
3092
- function PrefetchLink({
3093
- children,
3094
- crudEntity,
3095
- href,
3096
- className,
3097
- ...props
3098
- }) {
3099
- const { prefetchRoute, prefetchCrudPage } = usePrefetch();
3100
- const handleMouseEnter = useCallback(() => {
3101
- if (typeof href === "string") {
3102
- prefetchRoute(href);
3103
- if (crudEntity) {
3104
- prefetchCrudPage(crudEntity, `/api/${crudEntity}`);
3105
- } else {
3106
- const crudMatch = href.match(/\/(?:[a-z]{2}\/)?crud\/([^/]+)/);
3107
- if (crudMatch) {
3108
- const entity = crudMatch[1];
3109
- prefetchCrudPage(entity, `/api/${entity}`);
3110
- }
3111
- }
3112
- }
3113
- }, [href, crudEntity, prefetchRoute, prefetchCrudPage]);
3114
- return /* @__PURE__ */ jsx(
3115
- Link2,
3116
- {
3117
- href,
3118
- className,
3119
- onMouseEnter: handleMouseEnter,
3120
- ...props,
3121
- children
3122
- }
3123
- );
3124
- }
3125
- var init_prefetch_link = __esm({
3126
- "src/ui/primitives/prefetch-link.tsx"() {
3127
- "use client";
3128
- init_hooks();
3129
- }
3130
- });
3131
- var InputNumber;
3132
- var init_input_number = __esm({
3133
- "src/ui/primitives/input-number.tsx"() {
3134
- "use client";
3135
- init_utils();
3136
- init_input();
3137
- InputNumber = React6.forwardRef(
3138
- ({ value, onChange, className, decimalScale = 0, suffix, ...props }, ref) => {
3139
- const [displayValue, setDisplayValue] = React6.useState("");
3140
- const parseDisplayValue = (val) => {
3141
- const clean = val.replace(/\./g, "").replace(",", ".");
3142
- return Number(clean);
3143
- };
3144
- const formatNumber = React6.useCallback(
3145
- (num) => {
3146
- return new Intl.NumberFormat("vi-VN", {
3147
- maximumFractionDigits: decimalScale,
3148
- minimumFractionDigits: 0
3149
- }).format(num);
3150
- },
3151
- [decimalScale]
3152
- );
3153
- React6.useEffect(() => {
3154
- if (value === null || value === void 0 || value === "") {
3155
- setDisplayValue("");
3156
- return;
3157
- }
3158
- const numValue = Number(value);
3159
- if (isNaN(numValue)) return;
3160
- const currentNum = parseDisplayValue(displayValue);
3161
- if (currentNum !== numValue) {
3162
- setDisplayValue(formatNumber(numValue));
3163
- }
3164
- }, [value, decimalScale, displayValue, formatNumber]);
3165
- const handleChange = (e) => {
3166
- const rawValue = e.target.value;
3167
- let cleanVal = rawValue.replace(/[^0-9,]/g, "");
3168
- const parts = cleanVal.split(",");
3169
- if (parts.length > 2) {
3170
- cleanVal = parts[0] + "," + parts.slice(1).join("");
3171
- }
3172
- if (cleanVal === "") {
3173
- setDisplayValue("");
3174
- onChange?.(null);
3175
- return;
3176
- }
3177
- const [integerPart, decimalPart] = cleanVal.split(",");
3178
- let formattedInteger = integerPart;
3179
- if (integerPart) {
3180
- formattedInteger = new Intl.NumberFormat("vi-VN").format(
3181
- Number(integerPart)
3182
- );
3183
- }
3184
- let newDisplayValue = formattedInteger;
3185
- let finalDecimalPart = decimalPart;
3186
- if (decimalPart !== void 0) {
3187
- if (decimalScale !== void 0 && decimalPart.length > decimalScale) {
3188
- finalDecimalPart = decimalPart.substring(0, decimalScale);
3189
- }
3190
- newDisplayValue += "," + finalDecimalPart;
3191
- }
3192
- setDisplayValue(newDisplayValue);
3193
- let numStr = integerPart;
3194
- if (finalDecimalPart !== void 0) {
3195
- numStr += "." + finalDecimalPart;
3196
- }
3197
- const numValue = Number(numStr.replace(/\./g, ""));
3198
- onChange?.(numValue);
3199
- };
3200
- return /* @__PURE__ */ jsxs("div", { className: "relative", children: [
3201
- /* @__PURE__ */ jsx(
3202
- Input,
3203
- {
3204
- ...props,
3205
- ref,
3206
- type: "text",
3207
- inputMode: "numeric",
3208
- value: displayValue,
3209
- onChange: handleChange,
3210
- className: cn("pr-8", className)
3211
- }
3212
- ),
3213
- suffix && /* @__PURE__ */ jsx("div", { className: "absolute inset-y-0 right-0 flex items-center pr-3 pointer-events-none text-muted-foreground text-sm", children: suffix })
3214
- ] });
3215
- }
3216
- );
3217
- InputNumber.displayName = "InputNumber";
3218
- }
3219
- });
3220
-
3221
- // src/ui/primitives/client.ts
3222
- var init_client = __esm({
3223
- "src/ui/primitives/client.ts"() {
3224
- init_calendar();
3225
- init_combobox();
3226
- init_scroll_area();
3227
- init_select();
3228
- init_popover();
3229
- init_dropdown_menu();
3230
- init_switch();
3231
- init_checkbox();
3232
- init_label();
3233
- init_tooltip();
3234
- init_sidebar();
3235
- init_resizable();
3236
- init_slider();
3237
- init_toggle();
3238
- init_toggle_group();
3239
- init_menubar();
3240
- init_navigation_menu();
3241
- init_sticky_layout();
3242
- init_prefetch_link();
3243
- init_dynamic_icon();
3244
- init_input_number();
3245
- init_sheet();
3246
- init_context_menu();
3247
- init_drawer();
3248
- init_progress();
3249
- init_sonner();
3250
- }
3251
- });
3252
- init_client();
3253
-
3254
- export { Calendar, Checkbox, Combobox, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, DynamicIcon, InputNumber, Label3 as Label, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, PrefetchLink, Progress, ResizableHandle, ResizablePanel, ResizablePanelGroup, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Slider, StickyLayout, StickyLayoutContent, StickyLayoutPane, Switch, Toaster, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, navigationMenuTriggerStyle, sheetVariants, toggleVariants, useSidebar };
3255
- //# sourceMappingURL=client.mjs.map
3256
- //# sourceMappingURL=client.mjs.map