@otfdashkit/ui 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.
- package/LICENSE +1 -1
- package/README.md +28 -41
- package/dist/index.js +972 -655
- package/dist/index.mjs +826 -525
- package/package.json +5 -4
- package/src/advanced/BulkActions/BulkActions.tsx +2 -2
- package/src/advanced/CommandBar/CommandBar.tsx +2 -2
- package/src/advanced/Filters/Filters.tsx +6 -6
- package/src/advanced/Kanban/Kanban.tsx +1 -1
- package/src/advanced/ToggleButton/ToggleButton.tsx +1 -1
- package/src/advanced/bulk-actions.tsx +1 -46
- package/src/advanced/command-bar.tsx +1 -115
- package/src/advanced/filters.tsx +1 -103
- package/src/advanced/kanban.tsx +1 -95
- package/src/advanced/toggle-button.tsx +1 -78
- package/src/blocks/ChatDetail/ChatDetail.tsx +4 -4
- package/src/blocks/FeedbackModal/FeedbackModal.tsx +3 -3
- package/src/blocks/FileCards/FileCards.tsx +2 -2
- package/src/blocks/FilesList/FilesList.tsx +3 -3
- package/src/blocks/IntegrationCard/IntegrationCard.tsx +3 -3
- package/src/blocks/InviteModal/InviteModal.tsx +7 -7
- package/src/blocks/ManageTagsModal/ManageTagsModal.tsx +4 -4
- package/src/blocks/MessagesCard/MessagesCard.tsx +3 -3
- package/src/blocks/MetricCard/MetricCard.tsx +3 -3
- package/src/blocks/NotificationSettings/NotificationSettings.tsx +4 -4
- package/src/blocks/OrganizationMenu/OrganizationMenu.tsx +30 -11
- package/src/blocks/RolesMenu/RolesMenu.tsx +4 -4
- package/src/blocks/SelectUsersModal/SelectUsersModal.tsx +5 -5
- package/src/blocks/SidebarLayoutDashboard/SidebarLayoutDashboard.tsx +5 -5
- package/src/blocks/SidebarLayoutGroups/SidebarLayoutGroups.tsx +2 -2
- package/src/blocks/SidebarLayoutMinimal/SidebarLayoutMinimal.tsx +3 -3
- package/src/blocks/SidebarLayoutSearch/SidebarLayoutSearch.tsx +3 -3
- package/src/blocks/SidebarLayoutUser/SidebarLayoutUser.tsx +4 -4
- package/src/blocks/SortableTaskList/SortableTaskList.tsx +3 -3
- package/src/blocks/StackedLayoutBranded/StackedLayoutBranded.tsx +4 -4
- package/src/blocks/StackedLayoutTabs/StackedLayoutTabs.tsx +4 -4
- package/src/blocks/TaskCard/TaskCard.tsx +4 -4
- package/src/blocks/UserMenu/UserMenu.tsx +3 -3
- package/src/blocks/WorkspaceMembers/WorkspaceMembers.tsx +5 -5
- package/src/blocks/chat-detail.tsx +1 -73
- package/src/blocks/feedback-modal.tsx +1 -68
- package/src/blocks/file-cards.tsx +1 -56
- package/src/blocks/files-list.tsx +1 -72
- package/src/blocks/integration-card.tsx +1 -50
- package/src/blocks/invite-modal.tsx +1 -69
- package/src/blocks/manage-tags-modal.tsx +1 -63
- package/src/blocks/messages-card.tsx +1 -59
- package/src/blocks/metric-card.tsx +1 -79
- package/src/blocks/notification-settings.tsx +1 -61
- package/src/blocks/organization-menu.tsx +1 -85
- package/src/blocks/roles-menu.tsx +1 -61
- package/src/blocks/select-users-modal.tsx +1 -64
- package/src/blocks/sidebar-layout-dashboard.tsx +1 -97
- package/src/blocks/sidebar-layout-groups.tsx +1 -79
- package/src/blocks/sidebar-layout-minimal.tsx +1 -73
- package/src/blocks/sidebar-layout-search.tsx +1 -79
- package/src/blocks/sidebar-layout-user.tsx +1 -82
- package/src/blocks/sortable-task-list.tsx +1 -70
- package/src/blocks/stacked-layout-branded.tsx +1 -64
- package/src/blocks/stacked-layout-tabs.tsx +1 -80
- package/src/blocks/task-card.tsx +1 -88
- package/src/blocks/user-menu.tsx +1 -62
- package/src/blocks/workspace-members.tsx +1 -61
- package/src/charts/sparkline.tsx +1 -1
- package/src/components/DataGrid/DataGrid.tsx +1 -1
- package/src/components/DataTable/DataTable.tsx +4 -4
- package/src/components/EmptyState/EmptyState.tsx +6 -22
- package/src/components/Persona/Persona.tsx +1 -1
- package/src/components/Stat/Stat.tsx +1 -1
- package/src/components/Stepper/Stepper.tsx +13 -2
- package/src/components/banner.tsx +1 -203
- package/src/components/breadcrumb.tsx +1 -58
- package/src/components/command-item.tsx +1 -36
- package/src/components/data-grid.tsx +1 -125
- package/src/components/data-table.tsx +1 -139
- package/src/components/empty-state.tsx +1 -31
- package/src/components/hotkeys.tsx +1 -31
- package/src/components/icon-badge.tsx +1 -35
- package/src/components/loading-overlay.tsx +1 -38
- package/src/components/persona.tsx +1 -38
- package/src/components/property-list.tsx +1 -29
- package/src/components/stat.tsx +1 -51
- package/src/components/stepper.tsx +1 -69
- package/src/components/structured-list.tsx +1 -51
- package/src/components/timeline.tsx +1 -69
- package/src/components/toaster.tsx +1 -42
- package/src/data/DataList.tsx +1 -1
- package/src/engagement/Tour/Tour.tsx +1 -1
- package/src/engagement/beacon.tsx +1 -50
- package/src/engagement/tour.tsx +1 -106
- package/src/forms/ArrayField/ArrayField.tsx +2 -2
- package/src/forms/AutoForm/AutoForm.tsx +9 -8
- package/src/forms/DatePicker/DatePicker.tsx +3 -3
- package/src/forms/FloatingLabelInput/FloatingLabelInput.tsx +104 -0
- package/src/forms/FloatingLabelInput/index.ts +1 -0
- package/src/forms/PasswordInput/PasswordInput.tsx +2 -2
- package/src/forms/SearchInput/SearchInput.tsx +2 -2
- package/src/forms/StepForm/StepForm.tsx +2 -2
- package/src/forms/array-field.tsx +1 -61
- package/src/forms/auto-form.tsx +1 -133
- package/src/forms/date-picker.tsx +1 -109
- package/src/forms/field.tsx +1 -62
- package/src/forms/file-upload.tsx +1 -101
- package/src/forms/floating-label-input.tsx +1 -0
- package/src/forms/form.tsx +1 -57
- package/src/forms/object-field.tsx +1 -53
- package/src/forms/password-input.tsx +1 -54
- package/src/forms/search-input.tsx +1 -64
- package/src/forms/step-form.tsx +1 -113
- package/src/index.ts +11 -3
- package/src/primitives/Button/Button.tsx +18 -0
- package/src/primitives/cart-line-item.tsx +81 -0
- package/src/primitives/code-block.tsx +1 -1
- package/src/primitives/comparison.tsx +1 -1
- package/src/primitives/empty-cart.tsx +52 -0
- package/src/primitives/price-tag.tsx +62 -0
- package/src/primitives/qr-code.tsx +5 -1
- package/src/primitives/quantity-stepper.tsx +92 -0
- package/src/primitives/variant-picker.tsx +74 -0
- package/src/themes/base.css +18 -0
package/dist/index.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var clsx = require('clsx');
|
|
4
4
|
var tailwindMerge = require('tailwind-merge');
|
|
5
|
-
var
|
|
5
|
+
var React136 = require('react');
|
|
6
6
|
var AccordionPrimitive = require('@radix-ui/react-accordion');
|
|
7
7
|
var lucideReact = require('lucide-react');
|
|
8
8
|
var jsxRuntime = require('react/jsx-runtime');
|
|
@@ -21,10 +21,9 @@ var DialogPrimitive = require('@radix-ui/react-dialog');
|
|
|
21
21
|
var ContextMenuPrimitive = require('@radix-ui/react-context-menu');
|
|
22
22
|
var vaul = require('vaul');
|
|
23
23
|
var DropdownMenuPrimitive = require('@radix-ui/react-dropdown-menu');
|
|
24
|
-
var reactHookForm = require('react-hook-form');
|
|
25
|
-
var LabelPrimitive = require('@radix-ui/react-label');
|
|
26
24
|
var HoverCardPrimitive = require('@radix-ui/react-hover-card');
|
|
27
25
|
var inputOtp = require('input-otp');
|
|
26
|
+
var LabelPrimitive = require('@radix-ui/react-label');
|
|
28
27
|
var MenubarPrimitive = require('@radix-ui/react-menubar');
|
|
29
28
|
var NavigationMenuPrimitive = require('@radix-ui/react-navigation-menu');
|
|
30
29
|
var PopoverPrimitive = require('@radix-ui/react-popover');
|
|
@@ -56,6 +55,7 @@ var extensionTable = require('@tiptap/extension-table');
|
|
|
56
55
|
var extensionTableRow = require('@tiptap/extension-table-row');
|
|
57
56
|
var extensionTableCell = require('@tiptap/extension-table-cell');
|
|
58
57
|
var extensionTableHeader = require('@tiptap/extension-table-header');
|
|
58
|
+
var reactHookForm = require('react-hook-form');
|
|
59
59
|
var zod = require('@hookform/resolvers/zod');
|
|
60
60
|
var z = require('zod');
|
|
61
61
|
var reactColorful = require('react-colorful');
|
|
@@ -84,7 +84,7 @@ function _interopNamespace(e) {
|
|
|
84
84
|
return Object.freeze(n);
|
|
85
85
|
}
|
|
86
86
|
|
|
87
|
-
var
|
|
87
|
+
var React136__namespace = /*#__PURE__*/_interopNamespace(React136);
|
|
88
88
|
var AccordionPrimitive__namespace = /*#__PURE__*/_interopNamespace(AccordionPrimitive);
|
|
89
89
|
var AlertDialogPrimitive__namespace = /*#__PURE__*/_interopNamespace(AlertDialogPrimitive);
|
|
90
90
|
var AspectRatioPrimitive__namespace = /*#__PURE__*/_interopNamespace(AspectRatioPrimitive);
|
|
@@ -96,8 +96,8 @@ var CollapsiblePrimitive__namespace = /*#__PURE__*/_interopNamespace(Collapsible
|
|
|
96
96
|
var DialogPrimitive__namespace = /*#__PURE__*/_interopNamespace(DialogPrimitive);
|
|
97
97
|
var ContextMenuPrimitive__namespace = /*#__PURE__*/_interopNamespace(ContextMenuPrimitive);
|
|
98
98
|
var DropdownMenuPrimitive__namespace = /*#__PURE__*/_interopNamespace(DropdownMenuPrimitive);
|
|
99
|
-
var LabelPrimitive__namespace = /*#__PURE__*/_interopNamespace(LabelPrimitive);
|
|
100
99
|
var HoverCardPrimitive__namespace = /*#__PURE__*/_interopNamespace(HoverCardPrimitive);
|
|
100
|
+
var LabelPrimitive__namespace = /*#__PURE__*/_interopNamespace(LabelPrimitive);
|
|
101
101
|
var MenubarPrimitive__namespace = /*#__PURE__*/_interopNamespace(MenubarPrimitive);
|
|
102
102
|
var NavigationMenuPrimitive__namespace = /*#__PURE__*/_interopNamespace(NavigationMenuPrimitive);
|
|
103
103
|
var PopoverPrimitive__namespace = /*#__PURE__*/_interopNamespace(PopoverPrimitive);
|
|
@@ -124,7 +124,7 @@ function cn(...inputs) {
|
|
|
124
124
|
return tailwindMerge.twMerge(clsx.clsx(inputs));
|
|
125
125
|
}
|
|
126
126
|
var Accordion = AccordionPrimitive__namespace.Root;
|
|
127
|
-
var AccordionItem =
|
|
127
|
+
var AccordionItem = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
128
128
|
AccordionPrimitive__namespace.Item,
|
|
129
129
|
{
|
|
130
130
|
ref,
|
|
@@ -133,7 +133,7 @@ var AccordionItem = React131__namespace.forwardRef(({ className, ...props }, ref
|
|
|
133
133
|
}
|
|
134
134
|
));
|
|
135
135
|
AccordionItem.displayName = "AccordionItem";
|
|
136
|
-
var AccordionTrigger =
|
|
136
|
+
var AccordionTrigger = React136__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(AccordionPrimitive__namespace.Header, { className: "flex", children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
137
137
|
AccordionPrimitive__namespace.Trigger,
|
|
138
138
|
{
|
|
139
139
|
ref,
|
|
@@ -149,7 +149,7 @@ var AccordionTrigger = React131__namespace.forwardRef(({ className, children, ..
|
|
|
149
149
|
}
|
|
150
150
|
) }));
|
|
151
151
|
AccordionTrigger.displayName = AccordionPrimitive__namespace.Trigger.displayName;
|
|
152
|
-
var AccordionContent =
|
|
152
|
+
var AccordionContent = React136__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
153
153
|
AccordionPrimitive__namespace.Content,
|
|
154
154
|
{
|
|
155
155
|
ref,
|
|
@@ -181,7 +181,7 @@ var buttonVariants = classVarianceAuthority.cva(
|
|
|
181
181
|
defaultVariants: { variant: "default", size: "default" }
|
|
182
182
|
}
|
|
183
183
|
);
|
|
184
|
-
var Button =
|
|
184
|
+
var Button = React136__namespace.default.forwardRef(
|
|
185
185
|
({ className, variant, size, asChild = false, ...props }, ref) => {
|
|
186
186
|
const Comp = asChild ? reactSlot.Slot : "button";
|
|
187
187
|
return /* @__PURE__ */ jsxRuntime.jsx(Comp, { className: cn(buttonVariants({ variant, size }), className), ref, ...props });
|
|
@@ -191,7 +191,7 @@ Button.displayName = "Button";
|
|
|
191
191
|
var AlertDialog = AlertDialogPrimitive__namespace.Root;
|
|
192
192
|
var AlertDialogTrigger = AlertDialogPrimitive__namespace.Trigger;
|
|
193
193
|
var AlertDialogPortal = AlertDialogPrimitive__namespace.Portal;
|
|
194
|
-
var AlertDialogOverlay =
|
|
194
|
+
var AlertDialogOverlay = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
195
195
|
AlertDialogPrimitive__namespace.Overlay,
|
|
196
196
|
{
|
|
197
197
|
className: cn(
|
|
@@ -203,7 +203,7 @@ var AlertDialogOverlay = React131__namespace.forwardRef(({ className, ...props }
|
|
|
203
203
|
}
|
|
204
204
|
));
|
|
205
205
|
AlertDialogOverlay.displayName = AlertDialogPrimitive__namespace.Overlay.displayName;
|
|
206
|
-
var AlertDialogContent =
|
|
206
|
+
var AlertDialogContent = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(AlertDialogPortal, { children: [
|
|
207
207
|
/* @__PURE__ */ jsxRuntime.jsx(AlertDialogOverlay, {}),
|
|
208
208
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
209
209
|
AlertDialogPrimitive__namespace.Content,
|
|
@@ -246,7 +246,7 @@ var AlertDialogFooter = ({
|
|
|
246
246
|
}
|
|
247
247
|
);
|
|
248
248
|
AlertDialogFooter.displayName = "AlertDialogFooter";
|
|
249
|
-
var AlertDialogTitle =
|
|
249
|
+
var AlertDialogTitle = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
250
250
|
AlertDialogPrimitive__namespace.Title,
|
|
251
251
|
{
|
|
252
252
|
ref,
|
|
@@ -255,7 +255,7 @@ var AlertDialogTitle = React131__namespace.forwardRef(({ className, ...props },
|
|
|
255
255
|
}
|
|
256
256
|
));
|
|
257
257
|
AlertDialogTitle.displayName = AlertDialogPrimitive__namespace.Title.displayName;
|
|
258
|
-
var AlertDialogDescription =
|
|
258
|
+
var AlertDialogDescription = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
259
259
|
AlertDialogPrimitive__namespace.Description,
|
|
260
260
|
{
|
|
261
261
|
ref,
|
|
@@ -264,7 +264,7 @@ var AlertDialogDescription = React131__namespace.forwardRef(({ className, ...pro
|
|
|
264
264
|
}
|
|
265
265
|
));
|
|
266
266
|
AlertDialogDescription.displayName = AlertDialogPrimitive__namespace.Description.displayName;
|
|
267
|
-
var AlertDialogAction =
|
|
267
|
+
var AlertDialogAction = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
268
268
|
AlertDialogPrimitive__namespace.Action,
|
|
269
269
|
{
|
|
270
270
|
ref,
|
|
@@ -273,7 +273,7 @@ var AlertDialogAction = React131__namespace.forwardRef(({ className, ...props },
|
|
|
273
273
|
}
|
|
274
274
|
));
|
|
275
275
|
AlertDialogAction.displayName = AlertDialogPrimitive__namespace.Action.displayName;
|
|
276
|
-
var AlertDialogCancel =
|
|
276
|
+
var AlertDialogCancel = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
277
277
|
AlertDialogPrimitive__namespace.Cancel,
|
|
278
278
|
{
|
|
279
279
|
ref,
|
|
@@ -300,7 +300,7 @@ var alertVariants = classVarianceAuthority.cva(
|
|
|
300
300
|
}
|
|
301
301
|
}
|
|
302
302
|
);
|
|
303
|
-
var Alert =
|
|
303
|
+
var Alert = React136__namespace.forwardRef(({ className, variant, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
304
304
|
"div",
|
|
305
305
|
{
|
|
306
306
|
ref,
|
|
@@ -310,7 +310,7 @@ var Alert = React131__namespace.forwardRef(({ className, variant, ...props }, re
|
|
|
310
310
|
}
|
|
311
311
|
));
|
|
312
312
|
Alert.displayName = "Alert";
|
|
313
|
-
var AlertTitle =
|
|
313
|
+
var AlertTitle = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
314
314
|
"h5",
|
|
315
315
|
{
|
|
316
316
|
ref,
|
|
@@ -319,7 +319,7 @@ var AlertTitle = React131__namespace.forwardRef(({ className, ...props }, ref) =
|
|
|
319
319
|
}
|
|
320
320
|
));
|
|
321
321
|
AlertTitle.displayName = "AlertTitle";
|
|
322
|
-
var AlertDescription =
|
|
322
|
+
var AlertDescription = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
323
323
|
"div",
|
|
324
324
|
{
|
|
325
325
|
ref,
|
|
@@ -329,7 +329,7 @@ var AlertDescription = React131__namespace.forwardRef(({ className, ...props },
|
|
|
329
329
|
));
|
|
330
330
|
AlertDescription.displayName = "AlertDescription";
|
|
331
331
|
var AspectRatio = AspectRatioPrimitive__namespace.Root;
|
|
332
|
-
var Avatar =
|
|
332
|
+
var Avatar = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
333
333
|
AvatarPrimitive__namespace.Root,
|
|
334
334
|
{
|
|
335
335
|
ref,
|
|
@@ -338,9 +338,9 @@ var Avatar = React131__namespace.default.forwardRef(({ className, ...props }, re
|
|
|
338
338
|
}
|
|
339
339
|
));
|
|
340
340
|
Avatar.displayName = AvatarPrimitive__namespace.Root.displayName;
|
|
341
|
-
var AvatarImage =
|
|
341
|
+
var AvatarImage = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(AvatarPrimitive__namespace.Image, { ref, className: cn("aspect-square h-full w-full object-cover", className), ...props }));
|
|
342
342
|
AvatarImage.displayName = AvatarPrimitive__namespace.Image.displayName;
|
|
343
|
-
var AvatarFallback =
|
|
343
|
+
var AvatarFallback = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
344
344
|
AvatarPrimitive__namespace.Fallback,
|
|
345
345
|
{
|
|
346
346
|
ref,
|
|
@@ -349,15 +349,15 @@ var AvatarFallback = React131__namespace.default.forwardRef(({ className, ...pro
|
|
|
349
349
|
}
|
|
350
350
|
));
|
|
351
351
|
AvatarFallback.displayName = AvatarPrimitive__namespace.Fallback.displayName;
|
|
352
|
-
var AvatarGroup =
|
|
352
|
+
var AvatarGroup = React136__namespace.default.forwardRef(
|
|
353
353
|
({ className, max = 4, size = 32, spacing, renderOverflow, children, ...props }, ref) => {
|
|
354
|
-
const items =
|
|
354
|
+
const items = React136__namespace.default.Children.toArray(children).filter(React136__namespace.default.isValidElement);
|
|
355
355
|
const overlap = spacing ?? Math.round(size / 3);
|
|
356
356
|
const visible = items.slice(0, max);
|
|
357
357
|
const remaining = Math.max(0, items.length - max);
|
|
358
358
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, className: cn("flex items-center", className), "data-slot": "avatar-group", ...props, children: [
|
|
359
359
|
visible.map(
|
|
360
|
-
(child, i) =>
|
|
360
|
+
(child, i) => React136__namespace.default.cloneElement(child, {
|
|
361
361
|
key: child.key ?? i,
|
|
362
362
|
style: {
|
|
363
363
|
width: size,
|
|
@@ -563,8 +563,8 @@ function CalendarDayButton({
|
|
|
563
563
|
...props
|
|
564
564
|
}) {
|
|
565
565
|
const defaultClassNames = reactDayPicker.getDefaultClassNames();
|
|
566
|
-
const ref =
|
|
567
|
-
|
|
566
|
+
const ref = React136__namespace.useRef(null);
|
|
567
|
+
React136__namespace.useEffect(() => {
|
|
568
568
|
if (modifiers.focused) ref.current?.focus();
|
|
569
569
|
}, [modifiers.focused]);
|
|
570
570
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -587,7 +587,7 @@ function CalendarDayButton({
|
|
|
587
587
|
}
|
|
588
588
|
);
|
|
589
589
|
}
|
|
590
|
-
var Card =
|
|
590
|
+
var Card = React136__namespace.default.forwardRef(
|
|
591
591
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
592
592
|
"div",
|
|
593
593
|
{
|
|
@@ -598,35 +598,35 @@ var Card = React131__namespace.default.forwardRef(
|
|
|
598
598
|
)
|
|
599
599
|
);
|
|
600
600
|
Card.displayName = "Card";
|
|
601
|
-
var CardHeader =
|
|
601
|
+
var CardHeader = React136__namespace.default.forwardRef(
|
|
602
602
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex flex-col space-y-1.5 p-6", className), ...props })
|
|
603
603
|
);
|
|
604
604
|
CardHeader.displayName = "CardHeader";
|
|
605
|
-
var CardTitle =
|
|
605
|
+
var CardTitle = React136__namespace.default.forwardRef(
|
|
606
606
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("font-semibold leading-none tracking-tight", className), ...props })
|
|
607
607
|
);
|
|
608
608
|
CardTitle.displayName = "CardTitle";
|
|
609
|
-
var CardDescription =
|
|
609
|
+
var CardDescription = React136__namespace.default.forwardRef(
|
|
610
610
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("text-sm text-muted-foreground", className), ...props })
|
|
611
611
|
);
|
|
612
612
|
CardDescription.displayName = "CardDescription";
|
|
613
|
-
var CardContent =
|
|
613
|
+
var CardContent = React136__namespace.default.forwardRef(
|
|
614
614
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("p-6 pt-0", className), ...props })
|
|
615
615
|
);
|
|
616
616
|
CardContent.displayName = "CardContent";
|
|
617
|
-
var CardFooter =
|
|
617
|
+
var CardFooter = React136__namespace.default.forwardRef(
|
|
618
618
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex items-center p-6 pt-0", className), ...props })
|
|
619
619
|
);
|
|
620
620
|
CardFooter.displayName = "CardFooter";
|
|
621
|
-
var CarouselContext =
|
|
621
|
+
var CarouselContext = React136__namespace.createContext(null);
|
|
622
622
|
function useCarousel() {
|
|
623
|
-
const context =
|
|
623
|
+
const context = React136__namespace.useContext(CarouselContext);
|
|
624
624
|
if (!context) {
|
|
625
625
|
throw new Error("useCarousel must be used within a <Carousel />");
|
|
626
626
|
}
|
|
627
627
|
return context;
|
|
628
628
|
}
|
|
629
|
-
var Carousel =
|
|
629
|
+
var Carousel = React136__namespace.forwardRef(
|
|
630
630
|
({
|
|
631
631
|
orientation = "horizontal",
|
|
632
632
|
opts,
|
|
@@ -643,22 +643,22 @@ var Carousel = React131__namespace.forwardRef(
|
|
|
643
643
|
},
|
|
644
644
|
plugins
|
|
645
645
|
);
|
|
646
|
-
const [canScrollPrev, setCanScrollPrev] =
|
|
647
|
-
const [canScrollNext, setCanScrollNext] =
|
|
648
|
-
const onSelect =
|
|
646
|
+
const [canScrollPrev, setCanScrollPrev] = React136__namespace.useState(false);
|
|
647
|
+
const [canScrollNext, setCanScrollNext] = React136__namespace.useState(false);
|
|
648
|
+
const onSelect = React136__namespace.useCallback((api2) => {
|
|
649
649
|
if (!api2) {
|
|
650
650
|
return;
|
|
651
651
|
}
|
|
652
652
|
setCanScrollPrev(api2.canScrollPrev());
|
|
653
653
|
setCanScrollNext(api2.canScrollNext());
|
|
654
654
|
}, []);
|
|
655
|
-
const scrollPrev =
|
|
655
|
+
const scrollPrev = React136__namespace.useCallback(() => {
|
|
656
656
|
api?.scrollPrev();
|
|
657
657
|
}, [api]);
|
|
658
|
-
const scrollNext =
|
|
658
|
+
const scrollNext = React136__namespace.useCallback(() => {
|
|
659
659
|
api?.scrollNext();
|
|
660
660
|
}, [api]);
|
|
661
|
-
const handleKeyDown =
|
|
661
|
+
const handleKeyDown = React136__namespace.useCallback(
|
|
662
662
|
(event) => {
|
|
663
663
|
if (event.key === "ArrowLeft") {
|
|
664
664
|
event.preventDefault();
|
|
@@ -670,13 +670,13 @@ var Carousel = React131__namespace.forwardRef(
|
|
|
670
670
|
},
|
|
671
671
|
[scrollPrev, scrollNext]
|
|
672
672
|
);
|
|
673
|
-
|
|
673
|
+
React136__namespace.useEffect(() => {
|
|
674
674
|
if (!api || !setApi) {
|
|
675
675
|
return;
|
|
676
676
|
}
|
|
677
677
|
setApi(api);
|
|
678
678
|
}, [api, setApi]);
|
|
679
|
-
|
|
679
|
+
React136__namespace.useEffect(() => {
|
|
680
680
|
if (!api) {
|
|
681
681
|
return;
|
|
682
682
|
}
|
|
@@ -717,7 +717,7 @@ var Carousel = React131__namespace.forwardRef(
|
|
|
717
717
|
}
|
|
718
718
|
);
|
|
719
719
|
Carousel.displayName = "Carousel";
|
|
720
|
-
var CarouselContent =
|
|
720
|
+
var CarouselContent = React136__namespace.forwardRef(({ className, ...props }, ref) => {
|
|
721
721
|
const { carouselRef, orientation } = useCarousel();
|
|
722
722
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { ref: carouselRef, className: "overflow-hidden", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
723
723
|
"div",
|
|
@@ -733,7 +733,7 @@ var CarouselContent = React131__namespace.forwardRef(({ className, ...props }, r
|
|
|
733
733
|
) });
|
|
734
734
|
});
|
|
735
735
|
CarouselContent.displayName = "CarouselContent";
|
|
736
|
-
var CarouselItem =
|
|
736
|
+
var CarouselItem = React136__namespace.forwardRef(({ className, ...props }, ref) => {
|
|
737
737
|
const { orientation } = useCarousel();
|
|
738
738
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
739
739
|
"div",
|
|
@@ -751,7 +751,7 @@ var CarouselItem = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
751
751
|
);
|
|
752
752
|
});
|
|
753
753
|
CarouselItem.displayName = "CarouselItem";
|
|
754
|
-
var CarouselPrevious =
|
|
754
|
+
var CarouselPrevious = React136__namespace.forwardRef(({ className, variant = "outline", size = "icon", ...props }, ref) => {
|
|
755
755
|
const { orientation, scrollPrev, canScrollPrev } = useCarousel();
|
|
756
756
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
757
757
|
Button,
|
|
@@ -775,7 +775,7 @@ var CarouselPrevious = React131__namespace.forwardRef(({ className, variant = "o
|
|
|
775
775
|
);
|
|
776
776
|
});
|
|
777
777
|
CarouselPrevious.displayName = "CarouselPrevious";
|
|
778
|
-
var CarouselNext =
|
|
778
|
+
var CarouselNext = React136__namespace.forwardRef(({ className, variant = "outline", size = "icon", ...props }, ref) => {
|
|
779
779
|
const { orientation, scrollNext, canScrollNext } = useCarousel();
|
|
780
780
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
781
781
|
Button,
|
|
@@ -799,17 +799,173 @@ var CarouselNext = React131__namespace.forwardRef(({ className, variant = "outli
|
|
|
799
799
|
);
|
|
800
800
|
});
|
|
801
801
|
CarouselNext.displayName = "CarouselNext";
|
|
802
|
+
var SIZE = {
|
|
803
|
+
sm: { price: "text-sm", compare: "text-xs" },
|
|
804
|
+
md: { price: "text-lg", compare: "text-sm" },
|
|
805
|
+
lg: { price: "text-2xl", compare: "text-base" }
|
|
806
|
+
};
|
|
807
|
+
function formatMoney(minor, currency, locale) {
|
|
808
|
+
return new Intl.NumberFormat(locale, { style: "currency", currency }).format(minor / 100);
|
|
809
|
+
}
|
|
810
|
+
var PriceTag = React136__namespace.default.forwardRef(
|
|
811
|
+
({ amount, compareAt, currency = "USD", locale = "en-US", size = "md", showDiscount = true, className, ...props }, ref) => {
|
|
812
|
+
const onSale = compareAt !== void 0 && compareAt > amount;
|
|
813
|
+
const pct = onSale ? Math.round((1 - amount / compareAt) * 100) : 0;
|
|
814
|
+
const s = SIZE[size];
|
|
815
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("span", { ref, className: cn("inline-flex items-baseline gap-2 font-sans tabular-nums", className), ...props, children: [
|
|
816
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("font-semibold tracking-tight text-foreground", s.price), children: formatMoney(amount, currency, locale) }),
|
|
817
|
+
onSale && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
818
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("text-muted-foreground line-through", s.compare), children: formatMoney(compareAt, currency, locale) }),
|
|
819
|
+
showDiscount && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "rounded-full bg-destructive/10 px-2 py-0.5 text-xs font-semibold text-destructive", children: [
|
|
820
|
+
"\u2212",
|
|
821
|
+
pct,
|
|
822
|
+
"%"
|
|
823
|
+
] })
|
|
824
|
+
] })
|
|
825
|
+
] });
|
|
826
|
+
}
|
|
827
|
+
);
|
|
828
|
+
PriceTag.displayName = "PriceTag";
|
|
829
|
+
var QuantityStepper = React136__namespace.default.forwardRef(
|
|
830
|
+
({
|
|
831
|
+
value: valueProp,
|
|
832
|
+
defaultValue = 1,
|
|
833
|
+
onValueChange,
|
|
834
|
+
min = 1,
|
|
835
|
+
max = 99,
|
|
836
|
+
step = 1,
|
|
837
|
+
size = "md",
|
|
838
|
+
disabled = false,
|
|
839
|
+
className,
|
|
840
|
+
"aria-label": ariaLabel = "Quantity",
|
|
841
|
+
...props
|
|
842
|
+
}, ref) => {
|
|
843
|
+
const isControlled = valueProp !== void 0;
|
|
844
|
+
const [internal, setInternal] = React136__namespace.default.useState(defaultValue);
|
|
845
|
+
const value = isControlled ? valueProp : internal;
|
|
846
|
+
const commit = (next) => {
|
|
847
|
+
const clamped = Math.max(min, Math.min(max, next));
|
|
848
|
+
if (!isControlled) setInternal(clamped);
|
|
849
|
+
onValueChange?.(clamped);
|
|
850
|
+
};
|
|
851
|
+
const dim = size === "sm" ? "h-7 w-7" : "h-9 w-9";
|
|
852
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
853
|
+
"div",
|
|
854
|
+
{
|
|
855
|
+
ref,
|
|
856
|
+
role: "group",
|
|
857
|
+
"aria-label": ariaLabel,
|
|
858
|
+
className: cn("inline-flex items-center rounded-md border border-input", className),
|
|
859
|
+
...props,
|
|
860
|
+
children: [
|
|
861
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
862
|
+
Button,
|
|
863
|
+
{
|
|
864
|
+
type: "button",
|
|
865
|
+
variant: "ghost",
|
|
866
|
+
size: "icon",
|
|
867
|
+
className: cn("rounded-r-none", dim),
|
|
868
|
+
disabled: disabled || value <= min,
|
|
869
|
+
onClick: () => commit(value - step),
|
|
870
|
+
"aria-label": "Decrease quantity",
|
|
871
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Minus, { className: "h-4 w-4" })
|
|
872
|
+
}
|
|
873
|
+
),
|
|
874
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
875
|
+
"span",
|
|
876
|
+
{
|
|
877
|
+
"aria-live": "polite",
|
|
878
|
+
className: cn("select-none text-center text-sm font-medium tabular-nums", size === "sm" ? "min-w-7" : "min-w-8"),
|
|
879
|
+
children: value
|
|
880
|
+
}
|
|
881
|
+
),
|
|
882
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
883
|
+
Button,
|
|
884
|
+
{
|
|
885
|
+
type: "button",
|
|
886
|
+
variant: "ghost",
|
|
887
|
+
size: "icon",
|
|
888
|
+
className: cn("rounded-l-none", dim),
|
|
889
|
+
disabled: disabled || value >= max,
|
|
890
|
+
onClick: () => commit(value + step),
|
|
891
|
+
"aria-label": "Increase quantity",
|
|
892
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { className: "h-4 w-4" })
|
|
893
|
+
}
|
|
894
|
+
)
|
|
895
|
+
]
|
|
896
|
+
}
|
|
897
|
+
);
|
|
898
|
+
}
|
|
899
|
+
);
|
|
900
|
+
QuantityStepper.displayName = "QuantityStepper";
|
|
901
|
+
var CartLineItem = React136__namespace.default.forwardRef(
|
|
902
|
+
({
|
|
903
|
+
image,
|
|
904
|
+
title,
|
|
905
|
+
variant,
|
|
906
|
+
price,
|
|
907
|
+
compareAt,
|
|
908
|
+
currency = "USD",
|
|
909
|
+
quantity,
|
|
910
|
+
onQuantityChange,
|
|
911
|
+
onRemove,
|
|
912
|
+
minQuantity = 1,
|
|
913
|
+
maxQuantity = 99,
|
|
914
|
+
className,
|
|
915
|
+
...props
|
|
916
|
+
}, ref) => {
|
|
917
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
918
|
+
"div",
|
|
919
|
+
{
|
|
920
|
+
ref,
|
|
921
|
+
className: cn("flex items-center gap-4 rounded-lg border border-border bg-card p-3", className),
|
|
922
|
+
...props,
|
|
923
|
+
children: [
|
|
924
|
+
image && /* @__PURE__ */ jsxRuntime.jsx("img", { src: image, alt: "", className: "h-16 w-16 flex-none rounded-md object-cover" }),
|
|
925
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex min-w-0 flex-1 flex-col gap-1", children: [
|
|
926
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate font-medium text-card-foreground", children: title }),
|
|
927
|
+
variant && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate text-sm text-muted-foreground", children: variant }),
|
|
928
|
+
/* @__PURE__ */ jsxRuntime.jsx(PriceTag, { amount: price, compareAt, currency, size: "sm" })
|
|
929
|
+
] }),
|
|
930
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
931
|
+
QuantityStepper,
|
|
932
|
+
{
|
|
933
|
+
value: quantity,
|
|
934
|
+
min: minQuantity,
|
|
935
|
+
max: maxQuantity,
|
|
936
|
+
onValueChange: onQuantityChange,
|
|
937
|
+
size: "sm"
|
|
938
|
+
}
|
|
939
|
+
),
|
|
940
|
+
onRemove && /* @__PURE__ */ jsxRuntime.jsx(
|
|
941
|
+
Button,
|
|
942
|
+
{
|
|
943
|
+
type: "button",
|
|
944
|
+
variant: "ghost",
|
|
945
|
+
size: "icon",
|
|
946
|
+
className: "h-8 w-8 text-muted-foreground hover:text-destructive",
|
|
947
|
+
onClick: onRemove,
|
|
948
|
+
"aria-label": `Remove ${title}`,
|
|
949
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "h-4 w-4" })
|
|
950
|
+
}
|
|
951
|
+
)
|
|
952
|
+
]
|
|
953
|
+
}
|
|
954
|
+
);
|
|
955
|
+
}
|
|
956
|
+
);
|
|
957
|
+
CartLineItem.displayName = "CartLineItem";
|
|
802
958
|
var THEMES = { light: "", dark: ".dark" };
|
|
803
|
-
var ChartContext =
|
|
959
|
+
var ChartContext = React136__namespace.createContext(null);
|
|
804
960
|
function useChart() {
|
|
805
|
-
const context =
|
|
961
|
+
const context = React136__namespace.useContext(ChartContext);
|
|
806
962
|
if (!context) {
|
|
807
963
|
throw new Error("useChart must be used within a <ChartContainer />");
|
|
808
964
|
}
|
|
809
965
|
return context;
|
|
810
966
|
}
|
|
811
|
-
var ChartContainer =
|
|
812
|
-
const uniqueId =
|
|
967
|
+
var ChartContainer = React136__namespace.forwardRef(({ id, className, children, config, ...props }, ref) => {
|
|
968
|
+
const uniqueId = React136__namespace.useId();
|
|
813
969
|
const chartId = `chart-${id || uniqueId.replace(/:/g, "")}`;
|
|
814
970
|
return /* @__PURE__ */ jsxRuntime.jsx(ChartContext.Provider, { value: { config }, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
815
971
|
"div",
|
|
@@ -855,7 +1011,7 @@ ${colorConfig.map(([key, itemConfig]) => {
|
|
|
855
1011
|
);
|
|
856
1012
|
};
|
|
857
1013
|
var ChartTooltip = RechartsPrimitive__namespace.Tooltip;
|
|
858
|
-
var ChartTooltipContent =
|
|
1014
|
+
var ChartTooltipContent = React136__namespace.forwardRef(
|
|
859
1015
|
({
|
|
860
1016
|
active,
|
|
861
1017
|
payload,
|
|
@@ -872,7 +1028,7 @@ var ChartTooltipContent = React131__namespace.forwardRef(
|
|
|
872
1028
|
labelKey
|
|
873
1029
|
}, ref) => {
|
|
874
1030
|
const { config } = useChart();
|
|
875
|
-
const tooltipLabel =
|
|
1031
|
+
const tooltipLabel = React136__namespace.useMemo(() => {
|
|
876
1032
|
if (hideLabel || !payload?.length) {
|
|
877
1033
|
return null;
|
|
878
1034
|
}
|
|
@@ -968,7 +1124,7 @@ var ChartTooltipContent = React131__namespace.forwardRef(
|
|
|
968
1124
|
);
|
|
969
1125
|
ChartTooltipContent.displayName = "ChartTooltip";
|
|
970
1126
|
var ChartLegend = RechartsPrimitive__namespace.Legend;
|
|
971
|
-
var ChartLegendContent =
|
|
1127
|
+
var ChartLegendContent = React136__namespace.forwardRef(
|
|
972
1128
|
({ className, hideIcon = false, payload, verticalAlign = "bottom", nameKey }, ref) => {
|
|
973
1129
|
const { config } = useChart();
|
|
974
1130
|
if (!payload?.length) {
|
|
@@ -1026,7 +1182,7 @@ function getPayloadConfigFromPayload(config, payload, key) {
|
|
|
1026
1182
|
}
|
|
1027
1183
|
return configLabelKey in config ? config[configLabelKey] : config[key];
|
|
1028
1184
|
}
|
|
1029
|
-
var Checkbox =
|
|
1185
|
+
var Checkbox = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1030
1186
|
CheckboxPrimitive__namespace.Root,
|
|
1031
1187
|
{
|
|
1032
1188
|
ref,
|
|
@@ -1066,7 +1222,7 @@ function detectTheme(node) {
|
|
|
1066
1222
|
}
|
|
1067
1223
|
return document.documentElement.classList.contains("dark") ? "dark" : "light";
|
|
1068
1224
|
}
|
|
1069
|
-
var CodeBlock =
|
|
1225
|
+
var CodeBlock = React136__namespace.default.forwardRef(
|
|
1070
1226
|
({
|
|
1071
1227
|
code,
|
|
1072
1228
|
language = "tsx",
|
|
@@ -1077,10 +1233,10 @@ var CodeBlock = React131__namespace.default.forwardRef(
|
|
|
1077
1233
|
className,
|
|
1078
1234
|
...props
|
|
1079
1235
|
}, ref) => {
|
|
1080
|
-
const containerRef =
|
|
1081
|
-
const [html, setHtml] =
|
|
1082
|
-
const [copied, setCopied] =
|
|
1083
|
-
|
|
1236
|
+
const containerRef = React136__namespace.default.useRef(null);
|
|
1237
|
+
const [html, setHtml] = React136__namespace.default.useState(null);
|
|
1238
|
+
const [copied, setCopied] = React136__namespace.default.useState(false);
|
|
1239
|
+
React136__namespace.default.useEffect(() => {
|
|
1084
1240
|
let cancelled = false;
|
|
1085
1241
|
getHighlighter().then((hl) => {
|
|
1086
1242
|
if (cancelled) return;
|
|
@@ -1095,7 +1251,7 @@ var CodeBlock = React131__namespace.default.forwardRef(
|
|
|
1095
1251
|
cancelled = true;
|
|
1096
1252
|
};
|
|
1097
1253
|
}, [code, language, theme]);
|
|
1098
|
-
const onCopy =
|
|
1254
|
+
const onCopy = React136__namespace.default.useCallback(async () => {
|
|
1099
1255
|
try {
|
|
1100
1256
|
await navigator.clipboard.writeText(code);
|
|
1101
1257
|
setCopied(true);
|
|
@@ -1103,7 +1259,7 @@ var CodeBlock = React131__namespace.default.forwardRef(
|
|
|
1103
1259
|
} catch {
|
|
1104
1260
|
}
|
|
1105
1261
|
}, [code]);
|
|
1106
|
-
const lines =
|
|
1262
|
+
const lines = React136__namespace.default.useMemo(() => code.split("\n"), [code]);
|
|
1107
1263
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1108
1264
|
"div",
|
|
1109
1265
|
{
|
|
@@ -1171,7 +1327,7 @@ var Dialog = DialogPrimitive__namespace.Root;
|
|
|
1171
1327
|
var DialogTrigger = DialogPrimitive__namespace.Trigger;
|
|
1172
1328
|
var DialogPortal = DialogPrimitive__namespace.Portal;
|
|
1173
1329
|
var DialogClose = DialogPrimitive__namespace.Close;
|
|
1174
|
-
var DialogOverlay =
|
|
1330
|
+
var DialogOverlay = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1175
1331
|
DialogPrimitive__namespace.Overlay,
|
|
1176
1332
|
{
|
|
1177
1333
|
ref,
|
|
@@ -1185,7 +1341,7 @@ var DialogOverlay = React131__namespace.default.forwardRef(({ className, ...prop
|
|
|
1185
1341
|
}
|
|
1186
1342
|
));
|
|
1187
1343
|
DialogOverlay.displayName = DialogPrimitive__namespace.Overlay.displayName;
|
|
1188
|
-
var DialogContent =
|
|
1344
|
+
var DialogContent = React136__namespace.default.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DialogPortal, { children: [
|
|
1189
1345
|
/* @__PURE__ */ jsxRuntime.jsx(DialogOverlay, {}),
|
|
1190
1346
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
1191
1347
|
DialogPrimitive__namespace.Content,
|
|
@@ -1215,7 +1371,7 @@ var DialogHeader = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("
|
|
|
1215
1371
|
DialogHeader.displayName = "DialogHeader";
|
|
1216
1372
|
var DialogFooter = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", className), ...props });
|
|
1217
1373
|
DialogFooter.displayName = "DialogFooter";
|
|
1218
|
-
var DialogTitle =
|
|
1374
|
+
var DialogTitle = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1219
1375
|
DialogPrimitive__namespace.Title,
|
|
1220
1376
|
{
|
|
1221
1377
|
ref,
|
|
@@ -1224,7 +1380,7 @@ var DialogTitle = React131__namespace.default.forwardRef(({ className, ...props
|
|
|
1224
1380
|
}
|
|
1225
1381
|
));
|
|
1226
1382
|
DialogTitle.displayName = DialogPrimitive__namespace.Title.displayName;
|
|
1227
|
-
var DialogDescription =
|
|
1383
|
+
var DialogDescription = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1228
1384
|
DialogPrimitive__namespace.Description,
|
|
1229
1385
|
{
|
|
1230
1386
|
ref,
|
|
@@ -1233,7 +1389,7 @@ var DialogDescription = React131__namespace.default.forwardRef(({ className, ...
|
|
|
1233
1389
|
}
|
|
1234
1390
|
));
|
|
1235
1391
|
DialogDescription.displayName = DialogPrimitive__namespace.Description.displayName;
|
|
1236
|
-
var Command =
|
|
1392
|
+
var Command = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1237
1393
|
cmdk.Command,
|
|
1238
1394
|
{
|
|
1239
1395
|
ref,
|
|
@@ -1248,7 +1404,7 @@ Command.displayName = cmdk.Command.displayName;
|
|
|
1248
1404
|
var CommandDialog = ({ children, ...props }) => {
|
|
1249
1405
|
return /* @__PURE__ */ jsxRuntime.jsx(Dialog, { ...props, children: /* @__PURE__ */ jsxRuntime.jsx(DialogContent, { className: "overflow-hidden p-0", children: /* @__PURE__ */ jsxRuntime.jsx(Command, { className: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children }) }) });
|
|
1250
1406
|
};
|
|
1251
|
-
var CommandInput =
|
|
1407
|
+
var CommandInput = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center border-b px-3", "cmdk-input-wrapper": "", children: [
|
|
1252
1408
|
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Search, { className: "mr-2 h-4 w-4 shrink-0 opacity-50" }),
|
|
1253
1409
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1254
1410
|
cmdk.Command.Input,
|
|
@@ -1263,7 +1419,7 @@ var CommandInput = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
1263
1419
|
)
|
|
1264
1420
|
] }));
|
|
1265
1421
|
CommandInput.displayName = cmdk.Command.Input.displayName;
|
|
1266
|
-
var CommandList =
|
|
1422
|
+
var CommandList = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1267
1423
|
cmdk.Command.List,
|
|
1268
1424
|
{
|
|
1269
1425
|
ref,
|
|
@@ -1272,7 +1428,7 @@ var CommandList = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
1272
1428
|
}
|
|
1273
1429
|
));
|
|
1274
1430
|
CommandList.displayName = cmdk.Command.List.displayName;
|
|
1275
|
-
var CommandEmpty =
|
|
1431
|
+
var CommandEmpty = React136__namespace.forwardRef((props, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1276
1432
|
cmdk.Command.Empty,
|
|
1277
1433
|
{
|
|
1278
1434
|
ref,
|
|
@@ -1281,7 +1437,7 @@ var CommandEmpty = React131__namespace.forwardRef((props, ref) => /* @__PURE__ *
|
|
|
1281
1437
|
}
|
|
1282
1438
|
));
|
|
1283
1439
|
CommandEmpty.displayName = cmdk.Command.Empty.displayName;
|
|
1284
|
-
var CommandGroup =
|
|
1440
|
+
var CommandGroup = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1285
1441
|
cmdk.Command.Group,
|
|
1286
1442
|
{
|
|
1287
1443
|
ref,
|
|
@@ -1293,7 +1449,7 @@ var CommandGroup = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
1293
1449
|
}
|
|
1294
1450
|
));
|
|
1295
1451
|
CommandGroup.displayName = cmdk.Command.Group.displayName;
|
|
1296
|
-
var CommandSeparator =
|
|
1452
|
+
var CommandSeparator = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1297
1453
|
cmdk.Command.Separator,
|
|
1298
1454
|
{
|
|
1299
1455
|
ref,
|
|
@@ -1302,7 +1458,7 @@ var CommandSeparator = React131__namespace.forwardRef(({ className, ...props },
|
|
|
1302
1458
|
}
|
|
1303
1459
|
));
|
|
1304
1460
|
CommandSeparator.displayName = cmdk.Command.Separator.displayName;
|
|
1305
|
-
var CommandItem =
|
|
1461
|
+
var CommandItem = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1306
1462
|
cmdk.Command.Item,
|
|
1307
1463
|
{
|
|
1308
1464
|
ref,
|
|
@@ -1330,7 +1486,7 @@ var CommandShortcut = ({
|
|
|
1330
1486
|
);
|
|
1331
1487
|
};
|
|
1332
1488
|
CommandShortcut.displayName = "CommandShortcut";
|
|
1333
|
-
var Comparison =
|
|
1489
|
+
var Comparison = React136__namespace.default.forwardRef(
|
|
1334
1490
|
({
|
|
1335
1491
|
before,
|
|
1336
1492
|
after,
|
|
@@ -1346,10 +1502,10 @@ var Comparison = React131__namespace.default.forwardRef(
|
|
|
1346
1502
|
...props
|
|
1347
1503
|
}, ref) => {
|
|
1348
1504
|
const isControlled = valueProp !== void 0;
|
|
1349
|
-
const [internal, setInternal] =
|
|
1505
|
+
const [internal, setInternal] = React136__namespace.default.useState(defaultValue);
|
|
1350
1506
|
const value = Math.max(0, Math.min(100, isControlled ? valueProp : internal));
|
|
1351
|
-
const containerRef =
|
|
1352
|
-
const commit =
|
|
1507
|
+
const containerRef = React136__namespace.default.useRef(null);
|
|
1508
|
+
const commit = React136__namespace.default.useCallback(
|
|
1353
1509
|
(next) => {
|
|
1354
1510
|
const clamped = Math.max(0, Math.min(100, next));
|
|
1355
1511
|
if (!isControlled) setInternal(clamped);
|
|
@@ -1357,7 +1513,7 @@ var Comparison = React131__namespace.default.forwardRef(
|
|
|
1357
1513
|
},
|
|
1358
1514
|
[isControlled, onValueChange]
|
|
1359
1515
|
);
|
|
1360
|
-
const updateFromPointer =
|
|
1516
|
+
const updateFromPointer = React136__namespace.default.useCallback(
|
|
1361
1517
|
(clientX, clientY) => {
|
|
1362
1518
|
const el = containerRef.current;
|
|
1363
1519
|
if (!el) return;
|
|
@@ -1480,30 +1636,30 @@ var ContextMenuSub = ContextMenuPrimitive__namespace.Sub;
|
|
|
1480
1636
|
var ContextMenuRadioGroup = ContextMenuPrimitive__namespace.RadioGroup;
|
|
1481
1637
|
var contentStyle = "z-50 min-w-[8rem] overflow-hidden rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--popover))] p-1 text-[hsl(var(--popover-foreground))] shadow-md animate-in fade-in-80";
|
|
1482
1638
|
var itemStyle = "relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-[hsl(var(--accent))] focus:text-[hsl(var(--accent-foreground))] data-[disabled]:pointer-events-none data-[disabled]:opacity-50";
|
|
1483
|
-
var ContextMenuContent =
|
|
1639
|
+
var ContextMenuContent = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.Content, { ref, className: cn(contentStyle, className), ...props }) }));
|
|
1484
1640
|
ContextMenuContent.displayName = ContextMenuPrimitive__namespace.Content.displayName;
|
|
1485
|
-
var ContextMenuItem =
|
|
1641
|
+
var ContextMenuItem = React136__namespace.default.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.Item, { ref, className: cn(itemStyle, inset && "pl-8", className), ...props }));
|
|
1486
1642
|
ContextMenuItem.displayName = ContextMenuPrimitive__namespace.Item.displayName;
|
|
1487
|
-
var ContextMenuCheckboxItem =
|
|
1643
|
+
var ContextMenuCheckboxItem = React136__namespace.default.forwardRef(({ className, children, checked, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(ContextMenuPrimitive__namespace.CheckboxItem, { ref, className: cn(itemStyle, "pl-8", className), checked, ...props, children: [
|
|
1488
1644
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.ItemIndicator, { children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Check, { className: "h-4 w-4" }) }) }),
|
|
1489
1645
|
children
|
|
1490
1646
|
] }));
|
|
1491
1647
|
ContextMenuCheckboxItem.displayName = ContextMenuPrimitive__namespace.CheckboxItem.displayName;
|
|
1492
|
-
var ContextMenuRadioItem =
|
|
1648
|
+
var ContextMenuRadioItem = React136__namespace.default.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(ContextMenuPrimitive__namespace.RadioItem, { ref, className: cn(itemStyle, "pl-8", className), ...props, children: [
|
|
1493
1649
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.ItemIndicator, { children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Circle, { className: "h-2 w-2 fill-current" }) }) }),
|
|
1494
1650
|
children
|
|
1495
1651
|
] }));
|
|
1496
1652
|
ContextMenuRadioItem.displayName = ContextMenuPrimitive__namespace.RadioItem.displayName;
|
|
1497
|
-
var ContextMenuLabel =
|
|
1653
|
+
var ContextMenuLabel = React136__namespace.default.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.Label, { ref, className: cn("px-2 py-1.5 text-xs font-semibold text-[hsl(var(--muted-foreground))]", inset && "pl-8", className), ...props }));
|
|
1498
1654
|
ContextMenuLabel.displayName = ContextMenuPrimitive__namespace.Label.displayName;
|
|
1499
|
-
var ContextMenuSeparator =
|
|
1655
|
+
var ContextMenuSeparator = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.Separator, { ref, className: cn("-mx-1 my-1 h-px bg-[hsl(var(--muted))]", className), ...props }));
|
|
1500
1656
|
ContextMenuSeparator.displayName = ContextMenuPrimitive__namespace.Separator.displayName;
|
|
1501
|
-
var ContextMenuSubTrigger =
|
|
1657
|
+
var ContextMenuSubTrigger = React136__namespace.default.forwardRef(({ className, inset, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(ContextMenuPrimitive__namespace.SubTrigger, { ref, className: cn(itemStyle, inset && "pl-8", className), ...props, children: [
|
|
1502
1658
|
children,
|
|
1503
1659
|
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { className: "ml-auto h-4 w-4" })
|
|
1504
1660
|
] }));
|
|
1505
1661
|
ContextMenuSubTrigger.displayName = ContextMenuPrimitive__namespace.SubTrigger.displayName;
|
|
1506
|
-
var ContextMenuSubContent =
|
|
1662
|
+
var ContextMenuSubContent = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(ContextMenuPrimitive__namespace.SubContent, { ref, className: cn(contentStyle, className), ...props }));
|
|
1507
1663
|
ContextMenuSubContent.displayName = ContextMenuPrimitive__namespace.SubContent.displayName;
|
|
1508
1664
|
var ContextMenuShortcut = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("ml-auto text-xs tracking-widest opacity-60", className), ...props });
|
|
1509
1665
|
var Drawer = ({
|
|
@@ -1520,7 +1676,7 @@ Drawer.displayName = "Drawer";
|
|
|
1520
1676
|
var DrawerTrigger = vaul.Drawer.Trigger;
|
|
1521
1677
|
var DrawerPortal = vaul.Drawer.Portal;
|
|
1522
1678
|
var DrawerClose = vaul.Drawer.Close;
|
|
1523
|
-
var DrawerOverlay =
|
|
1679
|
+
var DrawerOverlay = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1524
1680
|
vaul.Drawer.Overlay,
|
|
1525
1681
|
{
|
|
1526
1682
|
ref,
|
|
@@ -1529,7 +1685,7 @@ var DrawerOverlay = React131__namespace.forwardRef(({ className, ...props }, ref
|
|
|
1529
1685
|
}
|
|
1530
1686
|
));
|
|
1531
1687
|
DrawerOverlay.displayName = vaul.Drawer.Overlay.displayName;
|
|
1532
|
-
var DrawerContent =
|
|
1688
|
+
var DrawerContent = React136__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DrawerPortal, { children: [
|
|
1533
1689
|
/* @__PURE__ */ jsxRuntime.jsx(DrawerOverlay, {}),
|
|
1534
1690
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
1535
1691
|
vaul.Drawer.Content,
|
|
@@ -1570,7 +1726,7 @@ var DrawerFooter = ({
|
|
|
1570
1726
|
}
|
|
1571
1727
|
);
|
|
1572
1728
|
DrawerFooter.displayName = "DrawerFooter";
|
|
1573
|
-
var DrawerTitle =
|
|
1729
|
+
var DrawerTitle = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1574
1730
|
vaul.Drawer.Title,
|
|
1575
1731
|
{
|
|
1576
1732
|
ref,
|
|
@@ -1582,7 +1738,7 @@ var DrawerTitle = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
1582
1738
|
}
|
|
1583
1739
|
));
|
|
1584
1740
|
DrawerTitle.displayName = vaul.Drawer.Title.displayName;
|
|
1585
|
-
var DrawerDescription =
|
|
1741
|
+
var DrawerDescription = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1586
1742
|
vaul.Drawer.Description,
|
|
1587
1743
|
{
|
|
1588
1744
|
ref,
|
|
@@ -1607,134 +1763,65 @@ var itemStyle2 = cn(
|
|
|
1607
1763
|
"focus:bg-[hsl(var(--accent))] focus:text-[hsl(var(--accent-foreground))]",
|
|
1608
1764
|
"data-[disabled]:pointer-events-none data-[disabled]:opacity-50"
|
|
1609
1765
|
);
|
|
1610
|
-
var DropdownMenuContent =
|
|
1766
|
+
var DropdownMenuContent = React136__namespace.default.forwardRef(({ className, sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Content, { ref, sideOffset, className: cn(contentStyle2, className), ...props }) }));
|
|
1611
1767
|
DropdownMenuContent.displayName = DropdownMenuPrimitive__namespace.Content.displayName;
|
|
1612
|
-
var DropdownMenuItem =
|
|
1768
|
+
var DropdownMenuItem = React136__namespace.default.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Item, { ref, className: cn(itemStyle2, inset && "pl-8", className), ...props }));
|
|
1613
1769
|
DropdownMenuItem.displayName = DropdownMenuPrimitive__namespace.Item.displayName;
|
|
1614
|
-
var DropdownMenuCheckboxItem =
|
|
1770
|
+
var DropdownMenuCheckboxItem = React136__namespace.default.forwardRef(({ className, children, checked, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DropdownMenuPrimitive__namespace.CheckboxItem, { ref, className: cn(itemStyle2, "pl-8", className), checked, ...props, children: [
|
|
1615
1771
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.ItemIndicator, { children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Check, { className: "h-4 w-4" }) }) }),
|
|
1616
1772
|
children
|
|
1617
1773
|
] }));
|
|
1618
1774
|
DropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive__namespace.CheckboxItem.displayName;
|
|
1619
|
-
var DropdownMenuRadioItem =
|
|
1775
|
+
var DropdownMenuRadioItem = React136__namespace.default.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DropdownMenuPrimitive__namespace.RadioItem, { ref, className: cn(itemStyle2, "pl-8", className), ...props, children: [
|
|
1620
1776
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.ItemIndicator, { children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Circle, { className: "h-2 w-2 fill-current" }) }) }),
|
|
1621
1777
|
children
|
|
1622
1778
|
] }));
|
|
1623
1779
|
DropdownMenuRadioItem.displayName = DropdownMenuPrimitive__namespace.RadioItem.displayName;
|
|
1624
|
-
var DropdownMenuLabel =
|
|
1780
|
+
var DropdownMenuLabel = React136__namespace.default.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Label, { ref, className: cn("px-2 py-1.5 text-xs font-semibold text-[hsl(var(--muted-foreground))]", inset && "pl-8", className), ...props }));
|
|
1625
1781
|
DropdownMenuLabel.displayName = DropdownMenuPrimitive__namespace.Label.displayName;
|
|
1626
|
-
var DropdownMenuSeparator =
|
|
1782
|
+
var DropdownMenuSeparator = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Separator, { ref, className: cn("-mx-1 my-1 h-px bg-[hsl(var(--muted))]", className), ...props }));
|
|
1627
1783
|
DropdownMenuSeparator.displayName = DropdownMenuPrimitive__namespace.Separator.displayName;
|
|
1628
|
-
var DropdownMenuSubTrigger =
|
|
1784
|
+
var DropdownMenuSubTrigger = React136__namespace.default.forwardRef(({ className, inset, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DropdownMenuPrimitive__namespace.SubTrigger, { ref, className: cn(itemStyle2, inset && "pl-8", "data-[state=open]:bg-[hsl(var(--accent))]", className), ...props, children: [
|
|
1629
1785
|
children,
|
|
1630
1786
|
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { className: "ml-auto h-4 w-4" })
|
|
1631
1787
|
] }));
|
|
1632
1788
|
DropdownMenuSubTrigger.displayName = DropdownMenuPrimitive__namespace.SubTrigger.displayName;
|
|
1633
|
-
var DropdownMenuSubContent =
|
|
1789
|
+
var DropdownMenuSubContent = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.SubContent, { ref, className: cn(contentStyle2, className), ...props }));
|
|
1634
1790
|
DropdownMenuSubContent.displayName = DropdownMenuPrimitive__namespace.SubContent.displayName;
|
|
1635
1791
|
var DropdownMenuShortcut = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("ml-auto text-xs tracking-widest opacity-60", className), ...props });
|
|
1636
1792
|
DropdownMenuShortcut.displayName = "DropdownMenuShortcut";
|
|
1637
|
-
var
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
className
|
|
1793
|
+
var EmptyCart = React136__namespace.default.forwardRef(
|
|
1794
|
+
({
|
|
1795
|
+
title = "Your cart is empty",
|
|
1796
|
+
description = "Browse the catalog and add something you love.",
|
|
1797
|
+
actionLabel = "Continue shopping",
|
|
1798
|
+
onAction,
|
|
1799
|
+
icon,
|
|
1800
|
+
className,
|
|
1645
1801
|
...props
|
|
1802
|
+
}, ref) => {
|
|
1803
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1804
|
+
"div",
|
|
1805
|
+
{
|
|
1806
|
+
ref,
|
|
1807
|
+
className: cn("flex flex-col items-center justify-center gap-4 px-6 py-12 text-center", className),
|
|
1808
|
+
...props,
|
|
1809
|
+
children: [
|
|
1810
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex h-14 w-14 items-center justify-center rounded-full bg-[hsl(var(--muted))] text-[hsl(var(--muted-foreground))]", children: icon ?? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ShoppingCart, { className: "h-6 w-6", strokeWidth: 1.5 }) }),
|
|
1811
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-1", children: [
|
|
1812
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-base font-semibold text-foreground", children: title }),
|
|
1813
|
+
description && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "max-w-xs text-sm text-muted-foreground", children: description })
|
|
1814
|
+
] }),
|
|
1815
|
+
actionLabel && onAction && /* @__PURE__ */ jsxRuntime.jsx(Button, { onClick: onAction, className: "mt-1", children: actionLabel })
|
|
1816
|
+
]
|
|
1817
|
+
}
|
|
1818
|
+
);
|
|
1646
1819
|
}
|
|
1647
|
-
)
|
|
1648
|
-
|
|
1649
|
-
var FormFieldContext = React131__namespace.createContext(null);
|
|
1650
|
-
var useFormField = () => {
|
|
1651
|
-
const fieldContext = React131__namespace.useContext(FormFieldContext);
|
|
1652
|
-
const itemContext = React131__namespace.useContext(FormItemContext);
|
|
1653
|
-
const { getFieldState, formState } = reactHookForm.useFormContext();
|
|
1654
|
-
if (!fieldContext) {
|
|
1655
|
-
throw new Error("useFormField should be used within <FormField>");
|
|
1656
|
-
}
|
|
1657
|
-
if (!itemContext) {
|
|
1658
|
-
throw new Error("useFormField should be used within <FormItem>");
|
|
1659
|
-
}
|
|
1660
|
-
const fieldState = getFieldState(fieldContext.name, formState);
|
|
1661
|
-
const { id } = itemContext;
|
|
1662
|
-
return {
|
|
1663
|
-
id,
|
|
1664
|
-
name: fieldContext.name,
|
|
1665
|
-
formItemId: `${id}-form-item`,
|
|
1666
|
-
formDescriptionId: `${id}-form-item-description`,
|
|
1667
|
-
formMessageId: `${id}-form-item-message`,
|
|
1668
|
-
...fieldState
|
|
1669
|
-
};
|
|
1670
|
-
};
|
|
1671
|
-
var FormItemContext = React131__namespace.createContext(null);
|
|
1672
|
-
var FormItem = React131__namespace.forwardRef(({ className, ...props }, ref) => {
|
|
1673
|
-
const id = React131__namespace.useId();
|
|
1674
|
-
return /* @__PURE__ */ jsxRuntime.jsx(FormItemContext.Provider, { value: { id }, children: /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("space-y-2", className), ...props }) });
|
|
1675
|
-
});
|
|
1676
|
-
FormItem.displayName = "FormItem";
|
|
1677
|
-
var FormLabel = React131__namespace.forwardRef(({ className, ...props }, ref) => {
|
|
1678
|
-
const { error, formItemId } = useFormField();
|
|
1679
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1680
|
-
Label3,
|
|
1681
|
-
{
|
|
1682
|
-
ref,
|
|
1683
|
-
className: cn(error && "text-destructive", className),
|
|
1684
|
-
htmlFor: formItemId,
|
|
1685
|
-
...props
|
|
1686
|
-
}
|
|
1687
|
-
);
|
|
1688
|
-
});
|
|
1689
|
-
FormLabel.displayName = "FormLabel";
|
|
1690
|
-
var FormControl = React131__namespace.forwardRef(({ ...props }, ref) => {
|
|
1691
|
-
const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
|
|
1692
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1693
|
-
reactSlot.Slot,
|
|
1694
|
-
{
|
|
1695
|
-
ref,
|
|
1696
|
-
id: formItemId,
|
|
1697
|
-
"aria-describedby": !error ? `${formDescriptionId}` : `${formDescriptionId} ${formMessageId}`,
|
|
1698
|
-
"aria-invalid": !!error,
|
|
1699
|
-
...props
|
|
1700
|
-
}
|
|
1701
|
-
);
|
|
1702
|
-
});
|
|
1703
|
-
FormControl.displayName = "FormControl";
|
|
1704
|
-
var FormDescription = React131__namespace.forwardRef(({ className, ...props }, ref) => {
|
|
1705
|
-
const { formDescriptionId } = useFormField();
|
|
1706
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1707
|
-
"p",
|
|
1708
|
-
{
|
|
1709
|
-
ref,
|
|
1710
|
-
id: formDescriptionId,
|
|
1711
|
-
className: cn("text-[0.8rem] text-muted-foreground", className),
|
|
1712
|
-
...props
|
|
1713
|
-
}
|
|
1714
|
-
);
|
|
1715
|
-
});
|
|
1716
|
-
FormDescription.displayName = "FormDescription";
|
|
1717
|
-
var FormMessage = React131__namespace.forwardRef(({ className, children, ...props }, ref) => {
|
|
1718
|
-
const { error, formMessageId } = useFormField();
|
|
1719
|
-
const body = error ? String(error?.message ?? "") : children;
|
|
1720
|
-
if (!body) {
|
|
1721
|
-
return null;
|
|
1722
|
-
}
|
|
1723
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1724
|
-
"p",
|
|
1725
|
-
{
|
|
1726
|
-
ref,
|
|
1727
|
-
id: formMessageId,
|
|
1728
|
-
className: cn("text-[0.8rem] font-medium text-destructive", className),
|
|
1729
|
-
...props,
|
|
1730
|
-
children: body
|
|
1731
|
-
}
|
|
1732
|
-
);
|
|
1733
|
-
});
|
|
1734
|
-
FormMessage.displayName = "FormMessage";
|
|
1820
|
+
);
|
|
1821
|
+
EmptyCart.displayName = "EmptyCart";
|
|
1735
1822
|
var HoverCard = HoverCardPrimitive__namespace.Root;
|
|
1736
1823
|
var HoverCardTrigger = HoverCardPrimitive__namespace.Trigger;
|
|
1737
|
-
var HoverCardContent =
|
|
1824
|
+
var HoverCardContent = React136__namespace.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1738
1825
|
HoverCardPrimitive__namespace.Content,
|
|
1739
1826
|
{
|
|
1740
1827
|
ref,
|
|
@@ -1748,7 +1835,7 @@ var HoverCardContent = React131__namespace.forwardRef(({ className, align = "cen
|
|
|
1748
1835
|
}
|
|
1749
1836
|
));
|
|
1750
1837
|
HoverCardContent.displayName = HoverCardPrimitive__namespace.Content.displayName;
|
|
1751
|
-
var InputOTP =
|
|
1838
|
+
var InputOTP = React136__namespace.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1752
1839
|
inputOtp.OTPInput,
|
|
1753
1840
|
{
|
|
1754
1841
|
ref,
|
|
@@ -1761,10 +1848,10 @@ var InputOTP = React131__namespace.forwardRef(({ className, containerClassName,
|
|
|
1761
1848
|
}
|
|
1762
1849
|
));
|
|
1763
1850
|
InputOTP.displayName = "InputOTP";
|
|
1764
|
-
var InputOTPGroup =
|
|
1851
|
+
var InputOTPGroup = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex items-center", className), ...props }));
|
|
1765
1852
|
InputOTPGroup.displayName = "InputOTPGroup";
|
|
1766
|
-
var InputOTPSlot =
|
|
1767
|
-
const inputOTPContext =
|
|
1853
|
+
var InputOTPSlot = React136__namespace.forwardRef(({ index, className, ...props }, ref) => {
|
|
1854
|
+
const inputOTPContext = React136__namespace.useContext(inputOtp.OTPInputContext);
|
|
1768
1855
|
const { char, hasFakeCaret, isActive } = inputOTPContext.slots[index];
|
|
1769
1856
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1770
1857
|
"div",
|
|
@@ -1784,9 +1871,9 @@ var InputOTPSlot = React131__namespace.forwardRef(({ index, className, ...props
|
|
|
1784
1871
|
);
|
|
1785
1872
|
});
|
|
1786
1873
|
InputOTPSlot.displayName = "InputOTPSlot";
|
|
1787
|
-
var InputOTPSeparator =
|
|
1874
|
+
var InputOTPSeparator = React136__namespace.forwardRef(({ ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, role: "separator", ...props, children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Minus, {}) }));
|
|
1788
1875
|
InputOTPSeparator.displayName = "InputOTPSeparator";
|
|
1789
|
-
var Input =
|
|
1876
|
+
var Input = React136__namespace.default.forwardRef(
|
|
1790
1877
|
({ className, type, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1791
1878
|
"input",
|
|
1792
1879
|
{
|
|
@@ -1805,7 +1892,19 @@ var Input = React131__namespace.default.forwardRef(
|
|
|
1805
1892
|
)
|
|
1806
1893
|
);
|
|
1807
1894
|
Input.displayName = "Input";
|
|
1808
|
-
var
|
|
1895
|
+
var labelVariants = classVarianceAuthority.cva(
|
|
1896
|
+
"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
|
|
1897
|
+
);
|
|
1898
|
+
var Label3 = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1899
|
+
LabelPrimitive__namespace.Root,
|
|
1900
|
+
{
|
|
1901
|
+
ref,
|
|
1902
|
+
className: cn(labelVariants(), className),
|
|
1903
|
+
...props
|
|
1904
|
+
}
|
|
1905
|
+
));
|
|
1906
|
+
Label3.displayName = LabelPrimitive__namespace.Root.displayName;
|
|
1907
|
+
var LogoCarousel = React136__namespace.default.forwardRef(
|
|
1809
1908
|
({
|
|
1810
1909
|
className,
|
|
1811
1910
|
logos,
|
|
@@ -1899,7 +1998,7 @@ var SPEED_DURATION = {
|
|
|
1899
1998
|
normal: "40s",
|
|
1900
1999
|
fast: "20s"
|
|
1901
2000
|
};
|
|
1902
|
-
var Marquee =
|
|
2001
|
+
var Marquee = React136__namespace.default.forwardRef(
|
|
1903
2002
|
({
|
|
1904
2003
|
children,
|
|
1905
2004
|
speed = "normal",
|
|
@@ -1963,7 +2062,7 @@ function MenubarSub({
|
|
|
1963
2062
|
}) {
|
|
1964
2063
|
return /* @__PURE__ */ jsxRuntime.jsx(MenubarPrimitive__namespace.Sub, { "data-slot": "menubar-sub", ...props });
|
|
1965
2064
|
}
|
|
1966
|
-
var Menubar =
|
|
2065
|
+
var Menubar = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1967
2066
|
MenubarPrimitive__namespace.Root,
|
|
1968
2067
|
{
|
|
1969
2068
|
ref,
|
|
@@ -1975,7 +2074,7 @@ var Menubar = React131__namespace.forwardRef(({ className, ...props }, ref) => /
|
|
|
1975
2074
|
}
|
|
1976
2075
|
));
|
|
1977
2076
|
Menubar.displayName = MenubarPrimitive__namespace.Root.displayName;
|
|
1978
|
-
var MenubarTrigger =
|
|
2077
|
+
var MenubarTrigger = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1979
2078
|
MenubarPrimitive__namespace.Trigger,
|
|
1980
2079
|
{
|
|
1981
2080
|
ref,
|
|
@@ -1987,7 +2086,7 @@ var MenubarTrigger = React131__namespace.forwardRef(({ className, ...props }, re
|
|
|
1987
2086
|
}
|
|
1988
2087
|
));
|
|
1989
2088
|
MenubarTrigger.displayName = MenubarPrimitive__namespace.Trigger.displayName;
|
|
1990
|
-
var MenubarSubTrigger =
|
|
2089
|
+
var MenubarSubTrigger = React136__namespace.forwardRef(({ className, inset, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1991
2090
|
MenubarPrimitive__namespace.SubTrigger,
|
|
1992
2091
|
{
|
|
1993
2092
|
ref,
|
|
@@ -2004,7 +2103,7 @@ var MenubarSubTrigger = React131__namespace.forwardRef(({ className, inset, chil
|
|
|
2004
2103
|
}
|
|
2005
2104
|
));
|
|
2006
2105
|
MenubarSubTrigger.displayName = MenubarPrimitive__namespace.SubTrigger.displayName;
|
|
2007
|
-
var MenubarSubContent =
|
|
2106
|
+
var MenubarSubContent = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2008
2107
|
MenubarPrimitive__namespace.SubContent,
|
|
2009
2108
|
{
|
|
2010
2109
|
ref,
|
|
@@ -2016,7 +2115,7 @@ var MenubarSubContent = React131__namespace.forwardRef(({ className, ...props },
|
|
|
2016
2115
|
}
|
|
2017
2116
|
));
|
|
2018
2117
|
MenubarSubContent.displayName = MenubarPrimitive__namespace.SubContent.displayName;
|
|
2019
|
-
var MenubarContent =
|
|
2118
|
+
var MenubarContent = React136__namespace.forwardRef(
|
|
2020
2119
|
({ className, align = "start", alignOffset = -4, sideOffset = 8, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(MenubarPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2021
2120
|
MenubarPrimitive__namespace.Content,
|
|
2022
2121
|
{
|
|
@@ -2033,7 +2132,7 @@ var MenubarContent = React131__namespace.forwardRef(
|
|
|
2033
2132
|
) })
|
|
2034
2133
|
);
|
|
2035
2134
|
MenubarContent.displayName = MenubarPrimitive__namespace.Content.displayName;
|
|
2036
|
-
var MenubarItem =
|
|
2135
|
+
var MenubarItem = React136__namespace.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2037
2136
|
MenubarPrimitive__namespace.Item,
|
|
2038
2137
|
{
|
|
2039
2138
|
ref,
|
|
@@ -2046,7 +2145,7 @@ var MenubarItem = React131__namespace.forwardRef(({ className, inset, ...props }
|
|
|
2046
2145
|
}
|
|
2047
2146
|
));
|
|
2048
2147
|
MenubarItem.displayName = MenubarPrimitive__namespace.Item.displayName;
|
|
2049
|
-
var MenubarCheckboxItem =
|
|
2148
|
+
var MenubarCheckboxItem = React136__namespace.forwardRef(({ className, children, checked, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2050
2149
|
MenubarPrimitive__namespace.CheckboxItem,
|
|
2051
2150
|
{
|
|
2052
2151
|
ref,
|
|
@@ -2063,7 +2162,7 @@ var MenubarCheckboxItem = React131__namespace.forwardRef(({ className, children,
|
|
|
2063
2162
|
}
|
|
2064
2163
|
));
|
|
2065
2164
|
MenubarCheckboxItem.displayName = MenubarPrimitive__namespace.CheckboxItem.displayName;
|
|
2066
|
-
var MenubarRadioItem =
|
|
2165
|
+
var MenubarRadioItem = React136__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2067
2166
|
MenubarPrimitive__namespace.RadioItem,
|
|
2068
2167
|
{
|
|
2069
2168
|
ref,
|
|
@@ -2079,7 +2178,7 @@ var MenubarRadioItem = React131__namespace.forwardRef(({ className, children, ..
|
|
|
2079
2178
|
}
|
|
2080
2179
|
));
|
|
2081
2180
|
MenubarRadioItem.displayName = MenubarPrimitive__namespace.RadioItem.displayName;
|
|
2082
|
-
var MenubarLabel =
|
|
2181
|
+
var MenubarLabel = React136__namespace.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2083
2182
|
MenubarPrimitive__namespace.Label,
|
|
2084
2183
|
{
|
|
2085
2184
|
ref,
|
|
@@ -2092,7 +2191,7 @@ var MenubarLabel = React131__namespace.forwardRef(({ className, inset, ...props
|
|
|
2092
2191
|
}
|
|
2093
2192
|
));
|
|
2094
2193
|
MenubarLabel.displayName = MenubarPrimitive__namespace.Label.displayName;
|
|
2095
|
-
var MenubarSeparator =
|
|
2194
|
+
var MenubarSeparator = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2096
2195
|
MenubarPrimitive__namespace.Separator,
|
|
2097
2196
|
{
|
|
2098
2197
|
ref,
|
|
@@ -2117,7 +2216,7 @@ var MenubarShortcut = ({
|
|
|
2117
2216
|
);
|
|
2118
2217
|
};
|
|
2119
2218
|
MenubarShortcut.displayname = "MenubarShortcut";
|
|
2120
|
-
var NavigationMenu =
|
|
2219
|
+
var NavigationMenu = React136__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2121
2220
|
NavigationMenuPrimitive__namespace.Root,
|
|
2122
2221
|
{
|
|
2123
2222
|
ref,
|
|
@@ -2133,7 +2232,7 @@ var NavigationMenu = React131__namespace.forwardRef(({ className, children, ...p
|
|
|
2133
2232
|
}
|
|
2134
2233
|
));
|
|
2135
2234
|
NavigationMenu.displayName = NavigationMenuPrimitive__namespace.Root.displayName;
|
|
2136
|
-
var NavigationMenuList =
|
|
2235
|
+
var NavigationMenuList = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2137
2236
|
NavigationMenuPrimitive__namespace.List,
|
|
2138
2237
|
{
|
|
2139
2238
|
ref,
|
|
@@ -2149,7 +2248,7 @@ var NavigationMenuItem = NavigationMenuPrimitive__namespace.Item;
|
|
|
2149
2248
|
var navigationMenuTriggerStyle = classVarianceAuthority.cva(
|
|
2150
2249
|
"group inline-flex h-9 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[state=open]:text-accent-foreground data-[state=open]:bg-accent/50 data-[state=open]:hover:bg-accent data-[state=open]:focus:bg-accent"
|
|
2151
2250
|
);
|
|
2152
|
-
var NavigationMenuTrigger =
|
|
2251
|
+
var NavigationMenuTrigger = React136__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2153
2252
|
NavigationMenuPrimitive__namespace.Trigger,
|
|
2154
2253
|
{
|
|
2155
2254
|
ref,
|
|
@@ -2169,7 +2268,7 @@ var NavigationMenuTrigger = React131__namespace.forwardRef(({ className, childre
|
|
|
2169
2268
|
}
|
|
2170
2269
|
));
|
|
2171
2270
|
NavigationMenuTrigger.displayName = NavigationMenuPrimitive__namespace.Trigger.displayName;
|
|
2172
|
-
var NavigationMenuContent =
|
|
2271
|
+
var NavigationMenuContent = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2173
2272
|
NavigationMenuPrimitive__namespace.Content,
|
|
2174
2273
|
{
|
|
2175
2274
|
ref,
|
|
@@ -2182,7 +2281,7 @@ var NavigationMenuContent = React131__namespace.forwardRef(({ className, ...prop
|
|
|
2182
2281
|
));
|
|
2183
2282
|
NavigationMenuContent.displayName = NavigationMenuPrimitive__namespace.Content.displayName;
|
|
2184
2283
|
var NavigationMenuLink = NavigationMenuPrimitive__namespace.Link;
|
|
2185
|
-
var NavigationMenuViewport =
|
|
2284
|
+
var NavigationMenuViewport = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("absolute left-0 top-full flex justify-center"), children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2186
2285
|
NavigationMenuPrimitive__namespace.Viewport,
|
|
2187
2286
|
{
|
|
2188
2287
|
className: cn(
|
|
@@ -2194,7 +2293,7 @@ var NavigationMenuViewport = React131__namespace.forwardRef(({ className, ...pro
|
|
|
2194
2293
|
}
|
|
2195
2294
|
) }));
|
|
2196
2295
|
NavigationMenuViewport.displayName = NavigationMenuPrimitive__namespace.Viewport.displayName;
|
|
2197
|
-
var NavigationMenuIndicator =
|
|
2296
|
+
var NavigationMenuIndicator = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2198
2297
|
NavigationMenuPrimitive__namespace.Indicator,
|
|
2199
2298
|
{
|
|
2200
2299
|
ref,
|
|
@@ -2217,7 +2316,7 @@ var Pagination = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
|
2217
2316
|
}
|
|
2218
2317
|
);
|
|
2219
2318
|
Pagination.displayName = "Pagination";
|
|
2220
|
-
var PaginationContent =
|
|
2319
|
+
var PaginationContent = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2221
2320
|
"ul",
|
|
2222
2321
|
{
|
|
2223
2322
|
ref,
|
|
@@ -2226,7 +2325,7 @@ var PaginationContent = React131__namespace.forwardRef(({ className, ...props },
|
|
|
2226
2325
|
}
|
|
2227
2326
|
));
|
|
2228
2327
|
PaginationContent.displayName = "PaginationContent";
|
|
2229
|
-
var PaginationItem =
|
|
2328
|
+
var PaginationItem = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("li", { ref, className: cn("", className), ...props }));
|
|
2230
2329
|
PaginationItem.displayName = "PaginationItem";
|
|
2231
2330
|
var PaginationLink = ({
|
|
2232
2331
|
className,
|
|
@@ -2301,7 +2400,7 @@ PaginationEllipsis.displayName = "PaginationEllipsis";
|
|
|
2301
2400
|
var Popover = PopoverPrimitive__namespace.Root;
|
|
2302
2401
|
var PopoverTrigger = PopoverPrimitive__namespace.Trigger;
|
|
2303
2402
|
var PopoverAnchor = PopoverPrimitive__namespace.Anchor;
|
|
2304
|
-
var PopoverContent =
|
|
2403
|
+
var PopoverContent = React136__namespace.default.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(PopoverPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2305
2404
|
PopoverPrimitive__namespace.Content,
|
|
2306
2405
|
{
|
|
2307
2406
|
ref,
|
|
@@ -2318,7 +2417,7 @@ var PopoverContent = React131__namespace.default.forwardRef(({ className, align
|
|
|
2318
2417
|
}
|
|
2319
2418
|
) }));
|
|
2320
2419
|
PopoverContent.displayName = PopoverPrimitive__namespace.Content.displayName;
|
|
2321
|
-
var Progress =
|
|
2420
|
+
var Progress = React136__namespace.default.forwardRef(({ className, value, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2322
2421
|
ProgressPrimitive__namespace.Root,
|
|
2323
2422
|
{
|
|
2324
2423
|
ref,
|
|
@@ -2334,7 +2433,7 @@ var Progress = React131__namespace.default.forwardRef(({ className, value, ...pr
|
|
|
2334
2433
|
}
|
|
2335
2434
|
));
|
|
2336
2435
|
Progress.displayName = ProgressPrimitive__namespace.Root.displayName;
|
|
2337
|
-
var QrCode =
|
|
2436
|
+
var QrCode = React136__namespace.default.forwardRef(
|
|
2338
2437
|
({
|
|
2339
2438
|
value,
|
|
2340
2439
|
size = 192,
|
|
@@ -2391,9 +2490,9 @@ var QrCode = React131__namespace.default.forwardRef(
|
|
|
2391
2490
|
}
|
|
2392
2491
|
);
|
|
2393
2492
|
QrCode.displayName = "QrCode";
|
|
2394
|
-
var RadioGroup4 =
|
|
2493
|
+
var RadioGroup4 = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(RadioGroupPrimitive__namespace.Root, { className: cn("grid gap-2", className), ref, ...props }));
|
|
2395
2494
|
RadioGroup4.displayName = RadioGroupPrimitive__namespace.Root.displayName;
|
|
2396
|
-
var RadioGroupItem =
|
|
2495
|
+
var RadioGroupItem = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2397
2496
|
RadioGroupPrimitive__namespace.Item,
|
|
2398
2497
|
{
|
|
2399
2498
|
ref,
|
|
@@ -2408,12 +2507,12 @@ var RadioGroupItem = React131__namespace.default.forwardRef(({ className, ...pro
|
|
|
2408
2507
|
}
|
|
2409
2508
|
));
|
|
2410
2509
|
RadioGroupItem.displayName = RadioGroupPrimitive__namespace.Item.displayName;
|
|
2411
|
-
var
|
|
2510
|
+
var SIZE2 = {
|
|
2412
2511
|
sm: "h-4 w-4",
|
|
2413
2512
|
md: "h-5 w-5",
|
|
2414
2513
|
lg: "h-6 w-6"
|
|
2415
2514
|
};
|
|
2416
|
-
var Rating =
|
|
2515
|
+
var Rating = React136__namespace.default.forwardRef(
|
|
2417
2516
|
({
|
|
2418
2517
|
value: valueProp,
|
|
2419
2518
|
defaultValue = 0,
|
|
@@ -2429,10 +2528,10 @@ var Rating = React131__namespace.default.forwardRef(
|
|
|
2429
2528
|
...props
|
|
2430
2529
|
}, ref) => {
|
|
2431
2530
|
const isControlled = valueProp !== void 0;
|
|
2432
|
-
const [internal, setInternal] =
|
|
2531
|
+
const [internal, setInternal] = React136__namespace.default.useState(defaultValue);
|
|
2433
2532
|
const value = isControlled ? valueProp : internal;
|
|
2434
2533
|
const step = allowHalf ? 0.5 : 1;
|
|
2435
|
-
const commit =
|
|
2534
|
+
const commit = React136__namespace.default.useCallback(
|
|
2436
2535
|
(next) => {
|
|
2437
2536
|
const clamped = Math.max(0, Math.min(max, next));
|
|
2438
2537
|
if (!isControlled) setInternal(clamped);
|
|
@@ -2479,13 +2578,13 @@ var Rating = React131__namespace.default.forwardRef(
|
|
|
2479
2578
|
children: Array.from({ length: max }).map((_, i) => {
|
|
2480
2579
|
const fillPercent = Math.max(0, Math.min(1, value - i)) * 100;
|
|
2481
2580
|
const Icon2 = /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "relative inline-block leading-none", children: [
|
|
2482
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("block text-muted-foreground/40",
|
|
2581
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("block text-muted-foreground/40", SIZE2[size]), children: emptyIcon ?? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Star, { className: "h-full w-full", strokeWidth: 1.5 }) }),
|
|
2483
2582
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2484
2583
|
"span",
|
|
2485
2584
|
{
|
|
2486
2585
|
className: cn(
|
|
2487
2586
|
"absolute inset-0 overflow-hidden text-[hsl(var(--primary))]",
|
|
2488
|
-
|
|
2587
|
+
SIZE2[size]
|
|
2489
2588
|
),
|
|
2490
2589
|
style: { width: `${fillPercent}%` },
|
|
2491
2590
|
"aria-hidden": "true",
|
|
@@ -2546,7 +2645,7 @@ var ResizableHandle = ({
|
|
|
2546
2645
|
children: withHandle && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.GripVertical, { className: "h-2.5 w-2.5" }) })
|
|
2547
2646
|
}
|
|
2548
2647
|
);
|
|
2549
|
-
var ScrollArea =
|
|
2648
|
+
var ScrollArea = React136__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2550
2649
|
ScrollAreaPrimitive__namespace.Root,
|
|
2551
2650
|
{
|
|
2552
2651
|
ref,
|
|
@@ -2560,7 +2659,7 @@ var ScrollArea = React131__namespace.forwardRef(({ className, children, ...props
|
|
|
2560
2659
|
}
|
|
2561
2660
|
));
|
|
2562
2661
|
ScrollArea.displayName = ScrollAreaPrimitive__namespace.Root.displayName;
|
|
2563
|
-
var ScrollBar =
|
|
2662
|
+
var ScrollBar = React136__namespace.forwardRef(({ className, orientation = "vertical", ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2564
2663
|
ScrollAreaPrimitive__namespace.ScrollAreaScrollbar,
|
|
2565
2664
|
{
|
|
2566
2665
|
ref,
|
|
@@ -2579,7 +2678,7 @@ ScrollBar.displayName = ScrollAreaPrimitive__namespace.ScrollAreaScrollbar.displ
|
|
|
2579
2678
|
var Select = SelectPrimitive__namespace.Root;
|
|
2580
2679
|
var SelectGroup = SelectPrimitive__namespace.Group;
|
|
2581
2680
|
var SelectValue = SelectPrimitive__namespace.Value;
|
|
2582
|
-
var SelectTrigger =
|
|
2681
|
+
var SelectTrigger = React136__namespace.default.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2583
2682
|
SelectPrimitive__namespace.Trigger,
|
|
2584
2683
|
{
|
|
2585
2684
|
ref,
|
|
@@ -2599,7 +2698,7 @@ var SelectTrigger = React131__namespace.default.forwardRef(({ className, childre
|
|
|
2599
2698
|
}
|
|
2600
2699
|
));
|
|
2601
2700
|
SelectTrigger.displayName = SelectPrimitive__namespace.Trigger.displayName;
|
|
2602
|
-
var SelectScrollUpButton =
|
|
2701
|
+
var SelectScrollUpButton = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2603
2702
|
SelectPrimitive__namespace.ScrollUpButton,
|
|
2604
2703
|
{
|
|
2605
2704
|
ref,
|
|
@@ -2609,7 +2708,7 @@ var SelectScrollUpButton = React131__namespace.default.forwardRef(({ className,
|
|
|
2609
2708
|
}
|
|
2610
2709
|
));
|
|
2611
2710
|
SelectScrollUpButton.displayName = SelectPrimitive__namespace.ScrollUpButton.displayName;
|
|
2612
|
-
var SelectScrollDownButton =
|
|
2711
|
+
var SelectScrollDownButton = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2613
2712
|
SelectPrimitive__namespace.ScrollDownButton,
|
|
2614
2713
|
{
|
|
2615
2714
|
ref,
|
|
@@ -2619,7 +2718,7 @@ var SelectScrollDownButton = React131__namespace.default.forwardRef(({ className
|
|
|
2619
2718
|
}
|
|
2620
2719
|
));
|
|
2621
2720
|
SelectScrollDownButton.displayName = SelectPrimitive__namespace.ScrollDownButton.displayName;
|
|
2622
|
-
var SelectContent =
|
|
2721
|
+
var SelectContent = React136__namespace.default.forwardRef(({ className, children, position = "popper", ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(SelectPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2623
2722
|
SelectPrimitive__namespace.Content,
|
|
2624
2723
|
{
|
|
2625
2724
|
ref,
|
|
@@ -2646,7 +2745,7 @@ var SelectContent = React131__namespace.default.forwardRef(({ className, childre
|
|
|
2646
2745
|
}
|
|
2647
2746
|
) }));
|
|
2648
2747
|
SelectContent.displayName = SelectPrimitive__namespace.Content.displayName;
|
|
2649
|
-
var SelectLabel =
|
|
2748
|
+
var SelectLabel = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2650
2749
|
SelectPrimitive__namespace.Label,
|
|
2651
2750
|
{
|
|
2652
2751
|
ref,
|
|
@@ -2655,7 +2754,7 @@ var SelectLabel = React131__namespace.default.forwardRef(({ className, ...props
|
|
|
2655
2754
|
}
|
|
2656
2755
|
));
|
|
2657
2756
|
SelectLabel.displayName = SelectPrimitive__namespace.Label.displayName;
|
|
2658
|
-
var SelectItem =
|
|
2757
|
+
var SelectItem = React136__namespace.default.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2659
2758
|
SelectPrimitive__namespace.Item,
|
|
2660
2759
|
{
|
|
2661
2760
|
ref,
|
|
@@ -2673,7 +2772,7 @@ var SelectItem = React131__namespace.default.forwardRef(({ className, children,
|
|
|
2673
2772
|
}
|
|
2674
2773
|
));
|
|
2675
2774
|
SelectItem.displayName = SelectPrimitive__namespace.Item.displayName;
|
|
2676
|
-
var SelectSeparator =
|
|
2775
|
+
var SelectSeparator = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2677
2776
|
SelectPrimitive__namespace.Separator,
|
|
2678
2777
|
{
|
|
2679
2778
|
ref,
|
|
@@ -2682,7 +2781,7 @@ var SelectSeparator = React131__namespace.default.forwardRef(({ className, ...pr
|
|
|
2682
2781
|
}
|
|
2683
2782
|
));
|
|
2684
2783
|
SelectSeparator.displayName = SelectPrimitive__namespace.Separator.displayName;
|
|
2685
|
-
var Separator6 =
|
|
2784
|
+
var Separator6 = React136__namespace.default.forwardRef(({ className, orientation = "horizontal", decorative = true, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2686
2785
|
SeparatorPrimitive__namespace.Root,
|
|
2687
2786
|
{
|
|
2688
2787
|
ref,
|
|
@@ -2701,7 +2800,7 @@ var Sheet = DialogPrimitive__namespace.Root;
|
|
|
2701
2800
|
var SheetTrigger = DialogPrimitive__namespace.Trigger;
|
|
2702
2801
|
var SheetClose = DialogPrimitive__namespace.Close;
|
|
2703
2802
|
var SheetPortal = DialogPrimitive__namespace.Portal;
|
|
2704
|
-
var SheetOverlay =
|
|
2803
|
+
var SheetOverlay = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2705
2804
|
DialogPrimitive__namespace.Overlay,
|
|
2706
2805
|
{
|
|
2707
2806
|
ref,
|
|
@@ -2729,7 +2828,7 @@ var sheetVariants = classVarianceAuthority.cva(
|
|
|
2729
2828
|
defaultVariants: { side: "right" }
|
|
2730
2829
|
}
|
|
2731
2830
|
);
|
|
2732
|
-
var SheetContent =
|
|
2831
|
+
var SheetContent = React136__namespace.default.forwardRef(({ side = "right", className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(SheetPortal, { children: [
|
|
2733
2832
|
/* @__PURE__ */ jsxRuntime.jsx(SheetOverlay, {}),
|
|
2734
2833
|
/* @__PURE__ */ jsxRuntime.jsxs(DialogPrimitive__namespace.Content, { ref, className: cn(sheetVariants({ side }), className), ...props, children: [
|
|
2735
2834
|
/* @__PURE__ */ jsxRuntime.jsxs(DialogPrimitive__namespace.Close, { className: "absolute right-4 top-4 rounded-sm opacity-70 hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-[hsl(var(--ring))]", children: [
|
|
@@ -2742,9 +2841,9 @@ var SheetContent = React131__namespace.default.forwardRef(({ side = "right", cla
|
|
|
2742
2841
|
SheetContent.displayName = DialogPrimitive__namespace.Content.displayName;
|
|
2743
2842
|
var SheetHeader = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("flex flex-col space-y-2 text-center sm:text-left", className), ...props });
|
|
2744
2843
|
var SheetFooter = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", className), ...props });
|
|
2745
|
-
var SheetTitle =
|
|
2844
|
+
var SheetTitle = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Title, { ref, className: cn("text-lg font-semibold", className), ...props }));
|
|
2746
2845
|
SheetTitle.displayName = DialogPrimitive__namespace.Title.displayName;
|
|
2747
|
-
var SheetDescription =
|
|
2846
|
+
var SheetDescription = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Description, { ref, className: cn("text-sm text-[hsl(var(--muted-foreground))]", className), ...props }));
|
|
2748
2847
|
SheetDescription.displayName = DialogPrimitive__namespace.Description.displayName;
|
|
2749
2848
|
function Skeleton({ className, ...props }) {
|
|
2750
2849
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -2755,7 +2854,7 @@ function Skeleton({ className, ...props }) {
|
|
|
2755
2854
|
}
|
|
2756
2855
|
);
|
|
2757
2856
|
}
|
|
2758
|
-
var Slider =
|
|
2857
|
+
var Slider = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2759
2858
|
SliderPrimitive__namespace.Root,
|
|
2760
2859
|
{
|
|
2761
2860
|
ref,
|
|
@@ -2779,7 +2878,7 @@ function Spinner({ className, ...props }) {
|
|
|
2779
2878
|
}
|
|
2780
2879
|
);
|
|
2781
2880
|
}
|
|
2782
|
-
var Switch =
|
|
2881
|
+
var Switch = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2783
2882
|
SwitchPrimitive__namespace.Root,
|
|
2784
2883
|
{
|
|
2785
2884
|
ref,
|
|
@@ -2805,7 +2904,7 @@ var Switch = React131__namespace.default.forwardRef(({ className, ...props }, re
|
|
|
2805
2904
|
}
|
|
2806
2905
|
));
|
|
2807
2906
|
Switch.displayName = SwitchPrimitive__namespace.Root.displayName;
|
|
2808
|
-
var Table =
|
|
2907
|
+
var Table = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative w-full overflow-auto", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2809
2908
|
"table",
|
|
2810
2909
|
{
|
|
2811
2910
|
ref,
|
|
@@ -2814,9 +2913,9 @@ var Table = React131__namespace.forwardRef(({ className, ...props }, ref) => /*
|
|
|
2814
2913
|
}
|
|
2815
2914
|
) }));
|
|
2816
2915
|
Table.displayName = "Table";
|
|
2817
|
-
var TableHeader =
|
|
2916
|
+
var TableHeader = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("thead", { ref, className: cn("[&_tr]:border-b", className), ...props }));
|
|
2818
2917
|
TableHeader.displayName = "TableHeader";
|
|
2819
|
-
var TableBody =
|
|
2918
|
+
var TableBody = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2820
2919
|
"tbody",
|
|
2821
2920
|
{
|
|
2822
2921
|
ref,
|
|
@@ -2825,7 +2924,7 @@ var TableBody = React131__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
2825
2924
|
}
|
|
2826
2925
|
));
|
|
2827
2926
|
TableBody.displayName = "TableBody";
|
|
2828
|
-
var TableFooter =
|
|
2927
|
+
var TableFooter = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2829
2928
|
"tfoot",
|
|
2830
2929
|
{
|
|
2831
2930
|
ref,
|
|
@@ -2837,7 +2936,7 @@ var TableFooter = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
2837
2936
|
}
|
|
2838
2937
|
));
|
|
2839
2938
|
TableFooter.displayName = "TableFooter";
|
|
2840
|
-
var TableRow =
|
|
2939
|
+
var TableRow = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2841
2940
|
"tr",
|
|
2842
2941
|
{
|
|
2843
2942
|
ref,
|
|
@@ -2849,7 +2948,7 @@ var TableRow = React131__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
2849
2948
|
}
|
|
2850
2949
|
));
|
|
2851
2950
|
TableRow.displayName = "TableRow";
|
|
2852
|
-
var TableHead =
|
|
2951
|
+
var TableHead = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2853
2952
|
"th",
|
|
2854
2953
|
{
|
|
2855
2954
|
ref,
|
|
@@ -2861,7 +2960,7 @@ var TableHead = React131__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
2861
2960
|
}
|
|
2862
2961
|
));
|
|
2863
2962
|
TableHead.displayName = "TableHead";
|
|
2864
|
-
var TableCell =
|
|
2963
|
+
var TableCell = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2865
2964
|
"td",
|
|
2866
2965
|
{
|
|
2867
2966
|
ref,
|
|
@@ -2873,7 +2972,7 @@ var TableCell = React131__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
2873
2972
|
}
|
|
2874
2973
|
));
|
|
2875
2974
|
TableCell.displayName = "TableCell";
|
|
2876
|
-
var TableCaption =
|
|
2975
|
+
var TableCaption = React136__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2877
2976
|
"caption",
|
|
2878
2977
|
{
|
|
2879
2978
|
ref,
|
|
@@ -2883,7 +2982,7 @@ var TableCaption = React131__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
2883
2982
|
));
|
|
2884
2983
|
TableCaption.displayName = "TableCaption";
|
|
2885
2984
|
var Tabs = TabsPrimitive__namespace.Root;
|
|
2886
|
-
var TabsList =
|
|
2985
|
+
var TabsList = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2887
2986
|
TabsPrimitive__namespace.List,
|
|
2888
2987
|
{
|
|
2889
2988
|
ref,
|
|
@@ -2895,7 +2994,7 @@ var TabsList = React131__namespace.default.forwardRef(({ className, ...props },
|
|
|
2895
2994
|
}
|
|
2896
2995
|
));
|
|
2897
2996
|
TabsList.displayName = TabsPrimitive__namespace.List.displayName;
|
|
2898
|
-
var TabsTrigger =
|
|
2997
|
+
var TabsTrigger = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2899
2998
|
TabsPrimitive__namespace.Trigger,
|
|
2900
2999
|
{
|
|
2901
3000
|
ref,
|
|
@@ -2910,7 +3009,7 @@ var TabsTrigger = React131__namespace.default.forwardRef(({ className, ...props
|
|
|
2910
3009
|
}
|
|
2911
3010
|
));
|
|
2912
3011
|
TabsTrigger.displayName = TabsPrimitive__namespace.Trigger.displayName;
|
|
2913
|
-
var TabsContent =
|
|
3012
|
+
var TabsContent = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2914
3013
|
TabsPrimitive__namespace.Content,
|
|
2915
3014
|
{
|
|
2916
3015
|
ref,
|
|
@@ -2922,7 +3021,7 @@ var TabsContent = React131__namespace.default.forwardRef(({ className, ...props
|
|
|
2922
3021
|
}
|
|
2923
3022
|
));
|
|
2924
3023
|
TabsContent.displayName = TabsPrimitive__namespace.Content.displayName;
|
|
2925
|
-
var Textarea =
|
|
3024
|
+
var Textarea = React136__namespace.default.forwardRef(
|
|
2926
3025
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2927
3026
|
"textarea",
|
|
2928
3027
|
{
|
|
@@ -2940,7 +3039,7 @@ var Textarea = React131__namespace.default.forwardRef(
|
|
|
2940
3039
|
)
|
|
2941
3040
|
);
|
|
2942
3041
|
Textarea.displayName = "Textarea";
|
|
2943
|
-
var TextureCard =
|
|
3042
|
+
var TextureCard = React136__namespace.forwardRef(
|
|
2944
3043
|
({ children, className, padding = true, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2945
3044
|
"div",
|
|
2946
3045
|
{
|
|
@@ -2957,15 +3056,15 @@ var TextureCard = React131__namespace.forwardRef(
|
|
|
2957
3056
|
)
|
|
2958
3057
|
);
|
|
2959
3058
|
TextureCard.displayName = "TextureCard";
|
|
2960
|
-
var TextureCardHeader =
|
|
3059
|
+
var TextureCardHeader = React136__namespace.forwardRef(
|
|
2961
3060
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex flex-col gap-1.5 mb-4", className), ...props })
|
|
2962
3061
|
);
|
|
2963
3062
|
TextureCardHeader.displayName = "TextureCardHeader";
|
|
2964
|
-
var TextureCardTitle =
|
|
3063
|
+
var TextureCardTitle = React136__namespace.forwardRef(
|
|
2965
3064
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("h3", { ref, className: cn("font-semibold text-base leading-tight tracking-tight text-foreground", className), ...props })
|
|
2966
3065
|
);
|
|
2967
3066
|
TextureCardTitle.displayName = "TextureCardTitle";
|
|
2968
|
-
var TextureCardDescription =
|
|
3067
|
+
var TextureCardDescription = React136__namespace.forwardRef(
|
|
2969
3068
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("p", { ref, className: cn("text-sm text-muted-foreground", className), ...props })
|
|
2970
3069
|
);
|
|
2971
3070
|
TextureCardDescription.displayName = "TextureCardDescription";
|
|
@@ -2989,7 +3088,7 @@ var toggleVariants = classVarianceAuthority.cva(
|
|
|
2989
3088
|
}
|
|
2990
3089
|
}
|
|
2991
3090
|
);
|
|
2992
|
-
var Toggle =
|
|
3091
|
+
var Toggle = React136__namespace.forwardRef(({ className, variant, size, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2993
3092
|
TogglePrimitive__namespace.Root,
|
|
2994
3093
|
{
|
|
2995
3094
|
ref,
|
|
@@ -2998,11 +3097,11 @@ var Toggle = React131__namespace.forwardRef(({ className, variant, size, ...prop
|
|
|
2998
3097
|
}
|
|
2999
3098
|
));
|
|
3000
3099
|
Toggle.displayName = TogglePrimitive__namespace.Root.displayName;
|
|
3001
|
-
var ToggleGroupContext =
|
|
3100
|
+
var ToggleGroupContext = React136__namespace.createContext({
|
|
3002
3101
|
size: "default",
|
|
3003
3102
|
variant: "default"
|
|
3004
3103
|
});
|
|
3005
|
-
var ToggleGroup =
|
|
3104
|
+
var ToggleGroup = React136__namespace.forwardRef(({ className, variant, size, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
3006
3105
|
ToggleGroupPrimitive__namespace.Root,
|
|
3007
3106
|
{
|
|
3008
3107
|
ref,
|
|
@@ -3012,8 +3111,8 @@ var ToggleGroup = React131__namespace.forwardRef(({ className, variant, size, ch
|
|
|
3012
3111
|
}
|
|
3013
3112
|
));
|
|
3014
3113
|
ToggleGroup.displayName = ToggleGroupPrimitive__namespace.Root.displayName;
|
|
3015
|
-
var ToggleGroupItem =
|
|
3016
|
-
const context =
|
|
3114
|
+
var ToggleGroupItem = React136__namespace.forwardRef(({ className, children, variant, size, ...props }, ref) => {
|
|
3115
|
+
const context = React136__namespace.useContext(ToggleGroupContext);
|
|
3017
3116
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
3018
3117
|
ToggleGroupPrimitive__namespace.Item,
|
|
3019
3118
|
{
|
|
@@ -3034,7 +3133,7 @@ ToggleGroupItem.displayName = ToggleGroupPrimitive__namespace.Item.displayName;
|
|
|
3034
3133
|
var TooltipProvider = TooltipPrimitive__namespace.Provider;
|
|
3035
3134
|
var Tooltip2 = TooltipPrimitive__namespace.Root;
|
|
3036
3135
|
var TooltipTrigger = TooltipPrimitive__namespace.Trigger;
|
|
3037
|
-
var TooltipContent =
|
|
3136
|
+
var TooltipContent = React136__namespace.default.forwardRef(({ className, sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(TooltipPrimitive__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3038
3137
|
TooltipPrimitive__namespace.Content,
|
|
3039
3138
|
{
|
|
3040
3139
|
ref,
|
|
@@ -3050,6 +3149,52 @@ var TooltipContent = React131__namespace.default.forwardRef(({ className, sideOf
|
|
|
3050
3149
|
}
|
|
3051
3150
|
) }));
|
|
3052
3151
|
TooltipContent.displayName = TooltipPrimitive__namespace.Content.displayName;
|
|
3152
|
+
var VariantPicker = React136__namespace.default.forwardRef(
|
|
3153
|
+
({ label, options, value: valueProp, defaultValue, onValueChange, className, ...props }, ref) => {
|
|
3154
|
+
const isControlled = valueProp !== void 0;
|
|
3155
|
+
const [internal, setInternal] = React136__namespace.default.useState(defaultValue);
|
|
3156
|
+
const value = isControlled ? valueProp : internal;
|
|
3157
|
+
const select = (v) => {
|
|
3158
|
+
if (!isControlled) setInternal(v);
|
|
3159
|
+
onValueChange?.(v);
|
|
3160
|
+
};
|
|
3161
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, role: "radiogroup", "aria-label": label, className: cn("flex flex-col gap-2", className), ...props, children: [
|
|
3162
|
+
label && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs font-semibold uppercase tracking-wide text-muted-foreground", children: label }),
|
|
3163
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap gap-2", children: options.map((opt) => {
|
|
3164
|
+
const selected = value === opt.value;
|
|
3165
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
3166
|
+
"button",
|
|
3167
|
+
{
|
|
3168
|
+
type: "button",
|
|
3169
|
+
role: "radio",
|
|
3170
|
+
"aria-checked": selected,
|
|
3171
|
+
disabled: opt.disabled,
|
|
3172
|
+
onClick: () => select(opt.value),
|
|
3173
|
+
className: cn(
|
|
3174
|
+
"inline-flex items-center gap-2 rounded-md border px-3 py-1.5 text-sm font-medium transition-colors",
|
|
3175
|
+
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
|
|
3176
|
+
selected ? "border-primary bg-primary/10 text-[hsl(var(--primary))]" : "border-border hover:bg-accent hover:text-accent-foreground",
|
|
3177
|
+
opt.disabled && "cursor-not-allowed text-muted-foreground line-through opacity-50"
|
|
3178
|
+
),
|
|
3179
|
+
children: [
|
|
3180
|
+
opt.swatch && /* @__PURE__ */ jsxRuntime.jsx(
|
|
3181
|
+
"span",
|
|
3182
|
+
{
|
|
3183
|
+
"aria-hidden": "true",
|
|
3184
|
+
className: "h-4 w-4 rounded-full border border-border",
|
|
3185
|
+
style: { backgroundColor: opt.swatch }
|
|
3186
|
+
}
|
|
3187
|
+
),
|
|
3188
|
+
opt.label
|
|
3189
|
+
]
|
|
3190
|
+
},
|
|
3191
|
+
opt.value
|
|
3192
|
+
);
|
|
3193
|
+
}) })
|
|
3194
|
+
] });
|
|
3195
|
+
}
|
|
3196
|
+
);
|
|
3197
|
+
VariantPicker.displayName = "VariantPicker";
|
|
3053
3198
|
var bannerVariants = classVarianceAuthority.cva(
|
|
3054
3199
|
"relative flex items-start gap-3 rounded-lg border px-4 py-3.5 text-sm transition-all",
|
|
3055
3200
|
{
|
|
@@ -3146,8 +3291,8 @@ function Banner({
|
|
|
3146
3291
|
className,
|
|
3147
3292
|
children
|
|
3148
3293
|
}) {
|
|
3149
|
-
const [dismissed, setDismissed] =
|
|
3150
|
-
const [exiting, setExiting] =
|
|
3294
|
+
const [dismissed, setDismissed] = React136__namespace.default.useState(false);
|
|
3295
|
+
const [exiting, setExiting] = React136__namespace.default.useState(false);
|
|
3151
3296
|
const handleDismiss = () => {
|
|
3152
3297
|
setExiting(true);
|
|
3153
3298
|
setTimeout(() => {
|
|
@@ -3208,7 +3353,7 @@ function BreadcrumbSeparator({ className }) {
|
|
|
3208
3353
|
return /* @__PURE__ */ jsxRuntime.jsx("li", { role: "presentation", "aria-hidden": "true", className: cn("flex items-center text-[hsl(var(--muted-foreground))]", className), children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { className: "h-3.5 w-3.5" }) });
|
|
3209
3354
|
}
|
|
3210
3355
|
function Breadcrumb({ children, className }) {
|
|
3211
|
-
const items =
|
|
3356
|
+
const items = React136__namespace.default.Children.toArray(children);
|
|
3212
3357
|
const withSeparators = [];
|
|
3213
3358
|
items.forEach((item, i) => {
|
|
3214
3359
|
withSeparators.push(item);
|
|
@@ -3216,9 +3361,30 @@ function Breadcrumb({ children, className }) {
|
|
|
3216
3361
|
});
|
|
3217
3362
|
return /* @__PURE__ */ jsxRuntime.jsx("nav", { "aria-label": "breadcrumb", children: /* @__PURE__ */ jsxRuntime.jsx("ol", { className: cn("flex flex-wrap items-center gap-1", className), children: withSeparators }) });
|
|
3218
3363
|
}
|
|
3364
|
+
function CommandItem2({ icon, label, description, shortcut, active, onClick, className }) {
|
|
3365
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
3366
|
+
"div",
|
|
3367
|
+
{
|
|
3368
|
+
onClick,
|
|
3369
|
+
className: cn(
|
|
3370
|
+
"flex items-center gap-3 rounded-md px-3 py-2 cursor-pointer transition-colors",
|
|
3371
|
+
active ? "bg-[hsl(var(--accent))] text-[hsl(var(--accent-foreground))]" : "hover:bg-[hsl(var(--accent)/0.6)]",
|
|
3372
|
+
className
|
|
3373
|
+
),
|
|
3374
|
+
children: [
|
|
3375
|
+
icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "shrink-0 text-[hsl(var(--muted-foreground))] h-4 w-4 flex items-center justify-center", children: icon }),
|
|
3376
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0 flex-1", children: [
|
|
3377
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-medium truncate", children: label }),
|
|
3378
|
+
description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-[hsl(var(--muted-foreground))] truncate", children: description })
|
|
3379
|
+
] }),
|
|
3380
|
+
shortcut && /* @__PURE__ */ jsxRuntime.jsx("kbd", { className: "shrink-0 pointer-events-none inline-flex h-5 items-center gap-1 rounded border border-[hsl(var(--border))] bg-[hsl(var(--muted))] px-1.5 text-[10px] font-medium text-[hsl(var(--muted-foreground))]", children: shortcut })
|
|
3381
|
+
]
|
|
3382
|
+
}
|
|
3383
|
+
);
|
|
3384
|
+
}
|
|
3219
3385
|
function EditableCell({ value: initial, onSave }) {
|
|
3220
|
-
const [editing, setEditing] =
|
|
3221
|
-
const [val, setVal] =
|
|
3386
|
+
const [editing, setEditing] = React136__namespace.default.useState(false);
|
|
3387
|
+
const [val, setVal] = React136__namespace.default.useState(String(initial ?? ""));
|
|
3222
3388
|
const commit = () => {
|
|
3223
3389
|
onSave(val);
|
|
3224
3390
|
setEditing(false);
|
|
@@ -3249,10 +3415,10 @@ var selectionCol = () => ({
|
|
|
3249
3415
|
enableResizing: false
|
|
3250
3416
|
});
|
|
3251
3417
|
function DataGrid({ columns, data: initialData, onDataChange, editable, className }) {
|
|
3252
|
-
const [data, setData] =
|
|
3253
|
-
const [rowSelection, setRowSelection] =
|
|
3418
|
+
const [data, setData] = React136__namespace.default.useState(initialData);
|
|
3419
|
+
const [rowSelection, setRowSelection] = React136__namespace.default.useState({});
|
|
3254
3420
|
const columnResizeMode = "onChange";
|
|
3255
|
-
const editableColumns =
|
|
3421
|
+
const editableColumns = React136__namespace.default.useMemo(() => {
|
|
3256
3422
|
if (!editable) return columns;
|
|
3257
3423
|
return columns.map((col) => ({
|
|
3258
3424
|
...col,
|
|
@@ -3271,7 +3437,7 @@ function DataGrid({ columns, data: initialData, onDataChange, editable, classNam
|
|
|
3271
3437
|
)
|
|
3272
3438
|
}));
|
|
3273
3439
|
}, [columns, data, editable, onDataChange]);
|
|
3274
|
-
const allColumns =
|
|
3440
|
+
const allColumns = React136__namespace.default.useMemo(() => [selectionCol(), ...editableColumns], [editableColumns]);
|
|
3275
3441
|
const table = reactTable.useReactTable({
|
|
3276
3442
|
data,
|
|
3277
3443
|
columns: allColumns,
|
|
@@ -3342,7 +3508,7 @@ function DataTableToolbar({ table, searchColumn }) {
|
|
|
3342
3508
|
) });
|
|
3343
3509
|
}
|
|
3344
3510
|
function DataTable({ columns, data, pageSize = 10, searchable, searchColumn, loading }) {
|
|
3345
|
-
const [sorting, setSorting] =
|
|
3511
|
+
const [sorting, setSorting] = React136__namespace.default.useState([]);
|
|
3346
3512
|
const table = reactTable.useReactTable({
|
|
3347
3513
|
data,
|
|
3348
3514
|
columns,
|
|
@@ -3367,18 +3533,57 @@ function DataTable({ columns, data, pageSize = 10, searchable, searchColumn, loa
|
|
|
3367
3533
|
/* @__PURE__ */ jsxRuntime.jsx(DataTablePagination, { table })
|
|
3368
3534
|
] });
|
|
3369
3535
|
}
|
|
3370
|
-
var EmptyStateIcon =
|
|
3536
|
+
var EmptyStateIcon = React136__namespace.default.forwardRef(
|
|
3371
3537
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex h-12 w-12 items-center justify-center rounded-full bg-[hsl(var(--muted))] text-[hsl(var(--muted-foreground))]", className), ...props })
|
|
3372
3538
|
);
|
|
3373
3539
|
EmptyStateIcon.displayName = "EmptyStateIcon";
|
|
3374
|
-
|
|
3375
|
-
|
|
3376
|
-
|
|
3377
|
-
|
|
3378
|
-
|
|
3379
|
-
|
|
3540
|
+
var sizeMap = {
|
|
3541
|
+
sm: "py-8 gap-2",
|
|
3542
|
+
default: "py-12 gap-3",
|
|
3543
|
+
lg: "py-20 gap-4"
|
|
3544
|
+
};
|
|
3545
|
+
var titleSizeMap = {
|
|
3546
|
+
sm: "text-sm font-semibold",
|
|
3547
|
+
default: "text-base font-semibold",
|
|
3548
|
+
lg: "text-lg font-semibold"
|
|
3549
|
+
};
|
|
3550
|
+
var descSizeMap = {
|
|
3551
|
+
sm: "text-xs",
|
|
3552
|
+
default: "text-sm",
|
|
3553
|
+
lg: "text-base"
|
|
3554
|
+
};
|
|
3555
|
+
var iconSizeMap = {
|
|
3556
|
+
sm: "h-10 w-10",
|
|
3557
|
+
default: "h-12 w-12",
|
|
3558
|
+
lg: "h-16 w-16"
|
|
3559
|
+
};
|
|
3560
|
+
function EmptyState({
|
|
3561
|
+
icon,
|
|
3562
|
+
title,
|
|
3563
|
+
description,
|
|
3564
|
+
action,
|
|
3565
|
+
secondaryAction,
|
|
3566
|
+
size = "default",
|
|
3567
|
+
className
|
|
3568
|
+
}) {
|
|
3569
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex flex-col items-center justify-center text-center", sizeMap[size], className), children: [
|
|
3570
|
+
icon && /* @__PURE__ */ jsxRuntime.jsx(EmptyStateIcon, { className: iconSizeMap[size], children: icon }),
|
|
3571
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1 max-w-sm", children: [
|
|
3572
|
+
/* @__PURE__ */ jsxRuntime.jsx("h3", { className: cn(titleSizeMap[size], "text-[hsl(var(--foreground))]"), children: title }),
|
|
3573
|
+
description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: cn(descSizeMap[size], "text-[hsl(var(--muted-foreground))]"), children: description })
|
|
3380
3574
|
] }),
|
|
3381
|
-
action && /* @__PURE__ */ jsxRuntime.
|
|
3575
|
+
(action || secondaryAction) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 mt-1", children: [
|
|
3576
|
+
action && /* @__PURE__ */ jsxRuntime.jsx(Button, { size: size === "sm" ? "sm" : "default", onClick: action.onClick, children: action.label }),
|
|
3577
|
+
secondaryAction && /* @__PURE__ */ jsxRuntime.jsx(
|
|
3578
|
+
Button,
|
|
3579
|
+
{
|
|
3580
|
+
variant: "outline",
|
|
3581
|
+
size: size === "sm" ? "sm" : "default",
|
|
3582
|
+
onClick: secondaryAction.onClick,
|
|
3583
|
+
children: secondaryAction.label
|
|
3584
|
+
}
|
|
3585
|
+
)
|
|
3586
|
+
] })
|
|
3382
3587
|
] });
|
|
3383
3588
|
}
|
|
3384
3589
|
function HotkeyBadge({ children, className }) {
|
|
@@ -3398,13 +3603,13 @@ var colorMap = {
|
|
|
3398
3603
|
error: "bg-red-100 text-red-700 dark:bg-red-900/30 dark:text-red-400",
|
|
3399
3604
|
purple: "bg-purple-100 text-purple-700 dark:bg-purple-900/30 dark:text-purple-400"
|
|
3400
3605
|
};
|
|
3401
|
-
var
|
|
3606
|
+
var sizeMap2 = {
|
|
3402
3607
|
sm: "h-7 w-7 [&>*]:h-3.5 [&>*]:w-3.5",
|
|
3403
3608
|
md: "h-10 w-10 [&>*]:h-5 [&>*]:w-5",
|
|
3404
3609
|
lg: "h-14 w-14 [&>*]:h-7 [&>*]:w-7"
|
|
3405
3610
|
};
|
|
3406
3611
|
function IconBadge({ icon, color = "default", size = "md", className }) {
|
|
3407
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("inline-flex items-center justify-center rounded-full shrink-0", colorMap[color],
|
|
3612
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("inline-flex items-center justify-center rounded-full shrink-0", colorMap[color], sizeMap2[size], className), children: icon });
|
|
3408
3613
|
}
|
|
3409
3614
|
function LoadingOverlay({ loading, text, fullPage, children, className }) {
|
|
3410
3615
|
if (fullPage) {
|
|
@@ -3421,13 +3626,13 @@ function LoadingOverlay({ loading, text, fullPage, children, className }) {
|
|
|
3421
3626
|
] }) })
|
|
3422
3627
|
] });
|
|
3423
3628
|
}
|
|
3424
|
-
var
|
|
3629
|
+
var sizeMap3 = {
|
|
3425
3630
|
sm: { avatar: "h-7 w-7", name: "text-sm", subtitle: "text-xs" },
|
|
3426
3631
|
md: { avatar: "h-9 w-9", name: "text-sm font-medium", subtitle: "text-xs" },
|
|
3427
3632
|
lg: { avatar: "h-12 w-12", name: "text-base font-medium", subtitle: "text-sm" }
|
|
3428
3633
|
};
|
|
3429
3634
|
function Persona({ name, subtitle, src, size = "md", badge, className }) {
|
|
3430
|
-
const s =
|
|
3635
|
+
const s = sizeMap3[size];
|
|
3431
3636
|
const initials = name.split(" ").map((w) => w[0]).slice(0, 2).join("").toUpperCase();
|
|
3432
3637
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex items-center gap-2.5", className), children: [
|
|
3433
3638
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative shrink-0", children: [
|
|
@@ -3443,7 +3648,7 @@ function Persona({ name, subtitle, src, size = "md", badge, className }) {
|
|
|
3443
3648
|
] })
|
|
3444
3649
|
] });
|
|
3445
3650
|
}
|
|
3446
|
-
var PropertyList =
|
|
3651
|
+
var PropertyList = React136__namespace.default.forwardRef(
|
|
3447
3652
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("dl", { ref, className: cn("divide-y divide-[hsl(var(--border))]", className), ...props })
|
|
3448
3653
|
);
|
|
3449
3654
|
PropertyList.displayName = "PropertyList";
|
|
@@ -3529,7 +3734,7 @@ function StructuredListItem({ left, title, description, right, onClick, classNam
|
|
|
3529
3734
|
}
|
|
3530
3735
|
);
|
|
3531
3736
|
}
|
|
3532
|
-
var StructuredList =
|
|
3737
|
+
var StructuredList = React136__namespace.default.forwardRef(
|
|
3533
3738
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("space-y-4", className), ...props })
|
|
3534
3739
|
);
|
|
3535
3740
|
StructuredList.displayName = "StructuredList";
|
|
@@ -3539,7 +3744,7 @@ var dotColors = {
|
|
|
3539
3744
|
error: "bg-red-500",
|
|
3540
3745
|
warning: "bg-yellow-500"
|
|
3541
3746
|
};
|
|
3542
|
-
var TimelineContent =
|
|
3747
|
+
var TimelineContent = React136__namespace.default.forwardRef(
|
|
3543
3748
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("pb-1", className), ...props })
|
|
3544
3749
|
);
|
|
3545
3750
|
TimelineContent.displayName = "TimelineContent";
|
|
@@ -3562,9 +3767,9 @@ function TimelineItem({ icon, title, description, timestamp, variant = "default"
|
|
|
3562
3767
|
] });
|
|
3563
3768
|
}
|
|
3564
3769
|
function Timeline({ children, className }) {
|
|
3565
|
-
const items =
|
|
3770
|
+
const items = React136__namespace.default.Children.toArray(children);
|
|
3566
3771
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("", className), children: items.map(
|
|
3567
|
-
(child, i) =>
|
|
3772
|
+
(child, i) => React136__namespace.default.isValidElement(child) ? React136__namespace.default.cloneElement(child, { isLast: i === items.length - 1 }) : child
|
|
3568
3773
|
) });
|
|
3569
3774
|
}
|
|
3570
3775
|
var INITIAL_MESSAGES = [
|
|
@@ -3589,8 +3794,8 @@ function ChatBubble({ msg }) {
|
|
|
3589
3794
|
] });
|
|
3590
3795
|
}
|
|
3591
3796
|
function ChatDetail({ className }) {
|
|
3592
|
-
const [messages, setMessages] =
|
|
3593
|
-
const [input, setInput] =
|
|
3797
|
+
const [messages, setMessages] = React136.useState(INITIAL_MESSAGES);
|
|
3798
|
+
const [input, setInput] = React136.useState("");
|
|
3594
3799
|
const send = () => {
|
|
3595
3800
|
if (!input.trim()) return;
|
|
3596
3801
|
const now = (/* @__PURE__ */ new Date()).toLocaleTimeString([], { hour: "2-digit", minute: "2-digit" });
|
|
@@ -3623,9 +3828,9 @@ function ChatDetail({ className }) {
|
|
|
3623
3828
|
}
|
|
3624
3829
|
var REACTIONS = ["\u{1F60A}", "\u{1F610}", "\u{1F615}", "\u{1F621}", "\u{1F929}"];
|
|
3625
3830
|
function FeedbackModal({ onSubmit, className }) {
|
|
3626
|
-
const [reaction, setReaction] =
|
|
3627
|
-
const [text, setText] =
|
|
3628
|
-
const [submitted, setSubmitted] =
|
|
3831
|
+
const [reaction, setReaction] = React136.useState("");
|
|
3832
|
+
const [text, setText] = React136.useState("");
|
|
3833
|
+
const [submitted, setSubmitted] = React136.useState(false);
|
|
3629
3834
|
const handleSubmit = () => {
|
|
3630
3835
|
onSubmit?.({ reaction, text });
|
|
3631
3836
|
setSubmitted(true);
|
|
@@ -3748,7 +3953,7 @@ function FileRow({ file, onDelete }) {
|
|
|
3748
3953
|
] });
|
|
3749
3954
|
}
|
|
3750
3955
|
function FilesList({ className }) {
|
|
3751
|
-
const [files, setFiles] =
|
|
3956
|
+
const [files, setFiles] = React136__namespace.default.useState(FILES2);
|
|
3752
3957
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("rounded-md border border-[hsl(var(--border))] overflow-hidden", className), children: /* @__PURE__ */ jsxRuntime.jsxs("table", { className: "w-full", children: [
|
|
3753
3958
|
/* @__PURE__ */ jsxRuntime.jsx("thead", { className: "bg-[hsl(var(--muted)/0.5)]", children: /* @__PURE__ */ jsxRuntime.jsx("tr", { children: ["Name", "Type", "Size", "Modified", ""].map((h) => /* @__PURE__ */ jsxRuntime.jsx("th", { className: "px-4 py-2.5 text-left text-xs font-medium text-[hsl(var(--muted-foreground))]", children: h }, h)) }) }),
|
|
3754
3959
|
/* @__PURE__ */ jsxRuntime.jsx("tbody", { children: files.map((f) => /* @__PURE__ */ jsxRuntime.jsx(FileRow, { file: f, onDelete: () => setFiles((fs) => fs.filter((x) => x.id !== f.id)) }, f.id)) })
|
|
@@ -3761,7 +3966,7 @@ function IntegrationCard({
|
|
|
3761
3966
|
connected = false,
|
|
3762
3967
|
className
|
|
3763
3968
|
}) {
|
|
3764
|
-
const [isConnected, setIsConnected] =
|
|
3969
|
+
const [isConnected, setIsConnected] = React136.useState(connected);
|
|
3765
3970
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex items-center gap-4 rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--card))] p-4", className), children: [
|
|
3766
3971
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex h-10 w-10 shrink-0 items-center justify-center rounded-md bg-[hsl(var(--muted))] text-[hsl(var(--muted-foreground))]", children: icon ?? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-base font-bold", children: name[0] }) }),
|
|
3767
3972
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 min-w-0", children: [
|
|
@@ -3795,9 +4000,9 @@ var PENDING = [
|
|
|
3795
4000
|
{ email: "sam@startup.io", role: "Viewer" }
|
|
3796
4001
|
];
|
|
3797
4002
|
function InviteModal({ className }) {
|
|
3798
|
-
const [email, setEmail] =
|
|
3799
|
-
const [role, setRole] =
|
|
3800
|
-
const [pending, setPending] =
|
|
4003
|
+
const [email, setEmail] = React136.useState("");
|
|
4004
|
+
const [role, setRole] = React136.useState("Member");
|
|
4005
|
+
const [pending, setPending] = React136.useState(PENDING);
|
|
3801
4006
|
const invite = () => {
|
|
3802
4007
|
if (!email.trim()) return;
|
|
3803
4008
|
setPending((p) => [...p, { email: email.trim(), role }]);
|
|
@@ -3828,7 +4033,7 @@ function InviteModal({ className }) {
|
|
|
3828
4033
|
pending.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", children: [
|
|
3829
4034
|
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs font-medium text-[hsl(var(--muted-foreground))]", children: "Pending invites" }),
|
|
3830
4035
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "divide-y divide-[hsl(var(--border))] rounded-md border border-[hsl(var(--border))]", children: pending.map((p, i) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 px-3 py-2", children: [
|
|
3831
|
-
/* @__PURE__ */ jsxRuntime.jsx(Avatar, { className: "h-6 w-6", children: /* @__PURE__ */ jsxRuntime.jsx(AvatarFallback, { className: "text-[10px]", children: p.email
|
|
4036
|
+
/* @__PURE__ */ jsxRuntime.jsx(Avatar, { className: "h-6 w-6", children: /* @__PURE__ */ jsxRuntime.jsx(AvatarFallback, { className: "text-[10px]", children: p.email.charAt(0).toUpperCase() }) }),
|
|
3832
4037
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex-1 text-sm truncate", children: p.email }),
|
|
3833
4038
|
/* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: "outline", className: "text-[10px] px-1.5 py-0.5 shrink-0", children: p.role }),
|
|
3834
4039
|
/* @__PURE__ */ jsxRuntime.jsx("button", { onClick: () => setPending((ps) => ps.filter((_, j) => j !== i)), children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "h-3.5 w-3.5 text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))]" }) })
|
|
@@ -3844,9 +4049,9 @@ var INITIAL_TAGS = [
|
|
|
3844
4049
|
{ id: "4", name: "Research", color: "bg-purple-500" }
|
|
3845
4050
|
];
|
|
3846
4051
|
function ManageTagsModal({ className }) {
|
|
3847
|
-
const [tags, setTags] =
|
|
3848
|
-
const [newTag, setNewTag] =
|
|
3849
|
-
const [colorIdx, setColorIdx] =
|
|
4052
|
+
const [tags, setTags] = React136.useState(INITIAL_TAGS);
|
|
4053
|
+
const [newTag, setNewTag] = React136.useState("");
|
|
4054
|
+
const [colorIdx, setColorIdx] = React136.useState(0);
|
|
3850
4055
|
const addTag = () => {
|
|
3851
4056
|
if (!newTag.trim()) return;
|
|
3852
4057
|
const id = `tag-${Date.now()}`;
|
|
@@ -4048,13 +4253,13 @@ function Heatmap({
|
|
|
4048
4253
|
showLegend = true,
|
|
4049
4254
|
formatTooltip
|
|
4050
4255
|
}) {
|
|
4051
|
-
const valueByDate =
|
|
4256
|
+
const valueByDate = React136.useMemo(() => {
|
|
4052
4257
|
const m = /* @__PURE__ */ new Map();
|
|
4053
4258
|
for (const d of data) m.set(d.date, d.value);
|
|
4054
4259
|
return m;
|
|
4055
4260
|
}, [data]);
|
|
4056
|
-
const max =
|
|
4057
|
-
const grid =
|
|
4261
|
+
const max = React136.useMemo(() => Math.max(1, ...data.map((d) => d.value)), [data]);
|
|
4262
|
+
const grid = React136.useMemo(() => {
|
|
4058
4263
|
const end = startOfWeek(endDate);
|
|
4059
4264
|
end.setDate(end.getDate() + 6);
|
|
4060
4265
|
const cols = [];
|
|
@@ -4072,7 +4277,7 @@ function Heatmap({
|
|
|
4072
4277
|
}
|
|
4073
4278
|
return cols;
|
|
4074
4279
|
}, [endDate, weeks, valueByDate]);
|
|
4075
|
-
const monthLabels =
|
|
4280
|
+
const monthLabels = React136.useMemo(() => {
|
|
4076
4281
|
const labels = [];
|
|
4077
4282
|
let lastMonth = -1;
|
|
4078
4283
|
grid.forEach((col, i) => {
|
|
@@ -4243,9 +4448,9 @@ function apply(mode) {
|
|
|
4243
4448
|
document.documentElement.classList.toggle("dark", isDark);
|
|
4244
4449
|
}
|
|
4245
4450
|
function ThemeSwitch({ defaultMode, onChange, className, variant = "segmented" }) {
|
|
4246
|
-
const [mode, setMode] =
|
|
4247
|
-
const didMount =
|
|
4248
|
-
|
|
4451
|
+
const [mode, setMode] = React136__namespace.default.useState(() => defaultMode ?? readInitial());
|
|
4452
|
+
const didMount = React136__namespace.default.useRef(false);
|
|
4453
|
+
React136__namespace.default.useEffect(() => {
|
|
4249
4454
|
if (!didMount.current) {
|
|
4250
4455
|
didMount.current = true;
|
|
4251
4456
|
return;
|
|
@@ -4257,7 +4462,7 @@ function ThemeSwitch({ defaultMode, onChange, className, variant = "segmented" }
|
|
|
4257
4462
|
}
|
|
4258
4463
|
onChange?.(mode);
|
|
4259
4464
|
}, [mode, onChange]);
|
|
4260
|
-
|
|
4465
|
+
React136__namespace.default.useEffect(() => {
|
|
4261
4466
|
if (mode !== "system" || typeof window === "undefined") return;
|
|
4262
4467
|
const mql = window.matchMedia("(prefers-color-scheme: dark)");
|
|
4263
4468
|
const handler = () => apply("system");
|
|
@@ -4348,7 +4553,7 @@ function FloatingActionButton({
|
|
|
4348
4553
|
position = "bottom-right",
|
|
4349
4554
|
className
|
|
4350
4555
|
}) {
|
|
4351
|
-
const [open, setOpen] =
|
|
4556
|
+
const [open, setOpen] = React136__namespace.default.useState(false);
|
|
4352
4557
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
4353
4558
|
"div",
|
|
4354
4559
|
{
|
|
@@ -4389,7 +4594,7 @@ function FloatingActionButton({
|
|
|
4389
4594
|
] }),
|
|
4390
4595
|
sections.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(Separator6, {})
|
|
4391
4596
|
] }),
|
|
4392
|
-
sections.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "px-3 py-2.5 space-y-3", children: sections.map((section, i) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
4597
|
+
sections.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "px-3 py-2.5 space-y-3", children: sections.map((section, i) => /* @__PURE__ */ jsxRuntime.jsxs(React136__namespace.default.Fragment, { children: [
|
|
4393
4598
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
4394
4599
|
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[9px] font-semibold uppercase tracking-widest text-muted-foreground mb-1.5", children: section.label }),
|
|
4395
4600
|
section.content
|
|
@@ -4431,7 +4636,7 @@ function applyTheme(val) {
|
|
|
4431
4636
|
}
|
|
4432
4637
|
}
|
|
4433
4638
|
function PaletteSwatches({ options = DEFAULT_THEME_OPTIONS }) {
|
|
4434
|
-
const [activeValue, setActiveValue] =
|
|
4639
|
+
const [activeValue, setActiveValue] = React136__namespace.default.useState(readStoredTheme);
|
|
4435
4640
|
const activeOption = options.find((o) => o.value === activeValue) ?? options[0];
|
|
4436
4641
|
const handleSelect = (value) => {
|
|
4437
4642
|
setActiveValue(value);
|
|
@@ -4508,7 +4713,7 @@ function NotifRow({ label, description, checked, onChange }) {
|
|
|
4508
4713
|
] });
|
|
4509
4714
|
}
|
|
4510
4715
|
function NotificationSettings({ className }) {
|
|
4511
|
-
const [states, setStates] =
|
|
4716
|
+
const [states, setStates] = React136.useState(
|
|
4512
4717
|
Object.fromEntries(NOTIFICATIONS.map((n) => [n.id, n.default]))
|
|
4513
4718
|
);
|
|
4514
4719
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--card))] p-6", className), children: [
|
|
@@ -4521,23 +4726,23 @@ function NotificationSettings({ className }) {
|
|
|
4521
4726
|
NotifRow,
|
|
4522
4727
|
{
|
|
4523
4728
|
...n,
|
|
4524
|
-
checked: states[n.id],
|
|
4729
|
+
checked: states[n.id] ?? false,
|
|
4525
4730
|
onChange: (val) => setStates((s) => ({ ...s, [n.id]: val }))
|
|
4526
4731
|
},
|
|
4527
4732
|
n.id
|
|
4528
4733
|
)) })
|
|
4529
4734
|
] });
|
|
4530
4735
|
}
|
|
4531
|
-
var SidebarCtx =
|
|
4736
|
+
var SidebarCtx = React136.createContext({
|
|
4532
4737
|
collapsed: false,
|
|
4533
4738
|
toggleCollapsed: () => {
|
|
4534
4739
|
}
|
|
4535
4740
|
});
|
|
4536
4741
|
function useSidebar() {
|
|
4537
|
-
return
|
|
4742
|
+
return React136.useContext(SidebarCtx);
|
|
4538
4743
|
}
|
|
4539
4744
|
function SidebarRoot({ children, storageKey = "sidebar-collapsed", defaultCollapsed = false, className }) {
|
|
4540
|
-
const [collapsed, setCollapsed] =
|
|
4745
|
+
const [collapsed, setCollapsed] = React136.useState(() => {
|
|
4541
4746
|
if (typeof window === "undefined") return defaultCollapsed;
|
|
4542
4747
|
try {
|
|
4543
4748
|
return JSON.parse(localStorage.getItem(storageKey) ?? String(defaultCollapsed));
|
|
@@ -4545,7 +4750,7 @@ function SidebarRoot({ children, storageKey = "sidebar-collapsed", defaultCollap
|
|
|
4545
4750
|
return defaultCollapsed;
|
|
4546
4751
|
}
|
|
4547
4752
|
});
|
|
4548
|
-
const toggleCollapsed =
|
|
4753
|
+
const toggleCollapsed = React136.useCallback(() => {
|
|
4549
4754
|
setCollapsed((v) => {
|
|
4550
4755
|
const next = !v;
|
|
4551
4756
|
try {
|
|
@@ -4673,7 +4878,7 @@ function OrgMenu({
|
|
|
4673
4878
|
onCreateOrg,
|
|
4674
4879
|
className
|
|
4675
4880
|
}) {
|
|
4676
|
-
const [internalId, setInternalId] =
|
|
4881
|
+
const [internalId, setInternalId] = React136.useState(defaultOrgId ?? ORGS[0]?.id ?? "1");
|
|
4677
4882
|
const activeId = currentOrgId ?? internalId;
|
|
4678
4883
|
const current = ORGS.find((o) => o.id === activeId) ?? ORGS[0];
|
|
4679
4884
|
const { collapsed } = useSidebar();
|
|
@@ -4722,8 +4927,8 @@ var ROLES = [
|
|
|
4722
4927
|
{ value: "viewer", label: "Viewer", description: "Read-only access" }
|
|
4723
4928
|
];
|
|
4724
4929
|
function RolesMenu({ value = "member", onChange, className }) {
|
|
4725
|
-
const [role, setRole] =
|
|
4726
|
-
const current = ROLES.find((r) => r.value === role) ?? ROLES[
|
|
4930
|
+
const [role, setRole] = React136.useState(value);
|
|
4931
|
+
const current = ROLES.find((r) => r.value === role) ?? ROLES[0];
|
|
4727
4932
|
const handleChange = (v) => {
|
|
4728
4933
|
setRole(v);
|
|
4729
4934
|
onChange?.(v);
|
|
@@ -4752,8 +4957,8 @@ var USERS = [
|
|
|
4752
4957
|
{ id: "6", name: "Mike Liu", email: "mike@acme.com", initials: "ML" }
|
|
4753
4958
|
];
|
|
4754
4959
|
function SelectUsersModal({ onConfirm, className }) {
|
|
4755
|
-
const [query, setQuery] =
|
|
4756
|
-
const [selected, setSelected] =
|
|
4960
|
+
const [query, setQuery] = React136.useState("");
|
|
4961
|
+
const [selected, setSelected] = React136.useState(/* @__PURE__ */ new Set());
|
|
4757
4962
|
const filtered = USERS.filter(
|
|
4758
4963
|
(u) => u.name.toLowerCase().includes(query.toLowerCase()) || u.email.toLowerCase().includes(query.toLowerCase())
|
|
4759
4964
|
);
|
|
@@ -4963,7 +5168,7 @@ function SidebarLayoutSearch({
|
|
|
4963
5168
|
children,
|
|
4964
5169
|
className
|
|
4965
5170
|
}) {
|
|
4966
|
-
const [query, setQuery] =
|
|
5171
|
+
const [query, setQuery] = React136.useState("");
|
|
4967
5172
|
const filtered = ALL_ITEMS.filter((i) => i.label.toLowerCase().includes(query.toLowerCase()));
|
|
4968
5173
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex h-[600px] overflow-hidden rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--background))]", className), children: [
|
|
4969
5174
|
/* @__PURE__ */ jsxRuntime.jsxs("aside", { className: "flex w-60 flex-col border-r border-[hsl(var(--border))] bg-[hsl(var(--card))]", children: [
|
|
@@ -5054,7 +5259,7 @@ function TaskRow({ task, onToggle }) {
|
|
|
5054
5259
|
] });
|
|
5055
5260
|
}
|
|
5056
5261
|
function SortableTaskList({ className }) {
|
|
5057
|
-
const [tasks, setTasks] =
|
|
5262
|
+
const [tasks, setTasks] = React136.useState(TASKS);
|
|
5058
5263
|
const toggle = (id) => setTasks((ts) => ts.map((t) => t.id === id ? { ...t, done: !t.done } : t));
|
|
5059
5264
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--card))] p-4 space-y-4", className), children: SECTIONS.map((section) => {
|
|
5060
5265
|
const items = tasks.filter((t) => t.status === section);
|
|
@@ -5108,8 +5313,8 @@ function StackedLayoutTabs({
|
|
|
5108
5313
|
children,
|
|
5109
5314
|
className
|
|
5110
5315
|
}) {
|
|
5111
|
-
const [activeTab, setActiveTab] =
|
|
5112
|
-
const [activeNav, setActiveNav] =
|
|
5316
|
+
const [activeTab, setActiveTab] = React136.useState(0);
|
|
5317
|
+
const [activeNav, setActiveNav] = React136.useState(0);
|
|
5113
5318
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex h-[600px] flex-col overflow-hidden rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--background))]", className), children: [
|
|
5114
5319
|
/* @__PURE__ */ jsxRuntime.jsxs("nav", { className: "flex h-14 items-center gap-6 border-b border-[hsl(var(--border))] bg-[hsl(var(--card))] px-4", children: [
|
|
5115
5320
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold text-sm shrink-0", children: brandName }),
|
|
@@ -5252,8 +5457,8 @@ var MEMBERS = [
|
|
|
5252
5457
|
];
|
|
5253
5458
|
var roleVariant = (role) => role === "Owner" ? "default" : role === "Admin" ? "secondary" : "outline";
|
|
5254
5459
|
function WorkspaceMembers({ className }) {
|
|
5255
|
-
const [query, setQuery] =
|
|
5256
|
-
const [members, setMembers] =
|
|
5460
|
+
const [query, setQuery] = React136.useState("");
|
|
5461
|
+
const [members, setMembers] = React136.useState(MEMBERS);
|
|
5257
5462
|
const filtered = members.filter(
|
|
5258
5463
|
(m) => m.name.toLowerCase().includes(query.toLowerCase()) || m.email.toLowerCase().includes(query.toLowerCase())
|
|
5259
5464
|
);
|
|
@@ -5307,8 +5512,8 @@ function BulkActions({ count, actions, onClear, className }) {
|
|
|
5307
5512
|
] });
|
|
5308
5513
|
}
|
|
5309
5514
|
function useCommandBar() {
|
|
5310
|
-
const [open, setOpen] =
|
|
5311
|
-
|
|
5515
|
+
const [open, setOpen] = React136__namespace.default.useState(false);
|
|
5516
|
+
React136__namespace.default.useEffect(() => {
|
|
5312
5517
|
const handler = (e) => {
|
|
5313
5518
|
if ((e.metaKey || e.ctrlKey) && e.key === "k") {
|
|
5314
5519
|
e.preventDefault();
|
|
@@ -5348,12 +5553,12 @@ function CommandBarItem({ icon, label, shortcut, onSelect, active, className })
|
|
|
5348
5553
|
);
|
|
5349
5554
|
}
|
|
5350
5555
|
function CommandBar({ open, onOpenChange, children, placeholder = "Search commands...", onSearch }) {
|
|
5351
|
-
const [query, setQuery] =
|
|
5556
|
+
const [query, setQuery] = React136__namespace.default.useState("");
|
|
5352
5557
|
const handleSearch = (v) => {
|
|
5353
5558
|
setQuery(v);
|
|
5354
5559
|
onSearch?.(v);
|
|
5355
5560
|
};
|
|
5356
|
-
const items =
|
|
5561
|
+
const items = React136__namespace.default.useRef(null);
|
|
5357
5562
|
const handleKeyDown = (e) => {
|
|
5358
5563
|
if (e.key === "Escape") {
|
|
5359
5564
|
onOpenChange(false);
|
|
@@ -5394,10 +5599,10 @@ function CommandBar({ open, onOpenChange, children, placeholder = "Search comman
|
|
|
5394
5599
|
var textOps = ["contains", "equals", "starts with"];
|
|
5395
5600
|
var numOps = ["=", ">", "<", ">=", "<="];
|
|
5396
5601
|
function AddFilterPopover({ filters, onAdd }) {
|
|
5397
|
-
const [open, setOpen] =
|
|
5398
|
-
const [key, setKey] =
|
|
5399
|
-
const [op, setOp] =
|
|
5400
|
-
const [val, setVal] =
|
|
5602
|
+
const [open, setOpen] = React136__namespace.default.useState(false);
|
|
5603
|
+
const [key, setKey] = React136__namespace.default.useState("");
|
|
5604
|
+
const [op, setOp] = React136__namespace.default.useState("");
|
|
5605
|
+
const [val, setVal] = React136__namespace.default.useState("");
|
|
5401
5606
|
const def = filters.find((f) => f.key === key);
|
|
5402
5607
|
const ops = def?.type === "number" ? numOps : textOps;
|
|
5403
5608
|
const handleAdd = () => {
|
|
@@ -5509,7 +5714,7 @@ function formatColumnSubLabel(date, scale) {
|
|
|
5509
5714
|
function snapDate(date, scale) {
|
|
5510
5715
|
return startOfScale(date, scale);
|
|
5511
5716
|
}
|
|
5512
|
-
var Gantt =
|
|
5717
|
+
var Gantt = React136__namespace.default.forwardRef(
|
|
5513
5718
|
({
|
|
5514
5719
|
items,
|
|
5515
5720
|
scale = "days",
|
|
@@ -5527,7 +5732,7 @@ var Gantt = React131__namespace.default.forwardRef(
|
|
|
5527
5732
|
}, ref) => {
|
|
5528
5733
|
const interactive = !!onItemMove || !!onItemResize;
|
|
5529
5734
|
const columnWidth = DEFAULT_COLUMN_WIDTH[scale];
|
|
5530
|
-
const viewport =
|
|
5735
|
+
const viewport = React136__namespace.default.useMemo(() => {
|
|
5531
5736
|
const earliest = startDate ?? (items.length ? new Date(Math.min(...items.map((i) => i.start.getTime()))) : /* @__PURE__ */ new Date());
|
|
5532
5737
|
const latest = endDate ?? (items.length ? new Date(Math.max(...items.map((i) => i.end.getTime()))) : dateFns.addDays(/* @__PURE__ */ new Date(), 14));
|
|
5533
5738
|
return {
|
|
@@ -5537,7 +5742,7 @@ var Gantt = React131__namespace.default.forwardRef(
|
|
|
5537
5742
|
}, [items, startDate, endDate, scale]);
|
|
5538
5743
|
const colCount = totalColumns(viewport.start, viewport.end, scale);
|
|
5539
5744
|
const timelineWidth = colCount * columnWidth;
|
|
5540
|
-
const grouped =
|
|
5745
|
+
const grouped = React136__namespace.default.useMemo(() => {
|
|
5541
5746
|
const map = /* @__PURE__ */ new Map();
|
|
5542
5747
|
for (const it of items) {
|
|
5543
5748
|
const k = it.group ?? void 0;
|
|
@@ -5547,7 +5752,7 @@ var Gantt = React131__namespace.default.forwardRef(
|
|
|
5547
5752
|
return Array.from(map.entries());
|
|
5548
5753
|
}, [items]);
|
|
5549
5754
|
const hasGroups = grouped.some(([k]) => k !== void 0);
|
|
5550
|
-
const [collapsed, setCollapsed] =
|
|
5755
|
+
const [collapsed, setCollapsed] = React136__namespace.default.useState(() => /* @__PURE__ */ new Set());
|
|
5551
5756
|
const toggleGroup = (key) => {
|
|
5552
5757
|
setCollapsed((prev) => {
|
|
5553
5758
|
const next = new Set(prev);
|
|
@@ -5556,7 +5761,7 @@ var Gantt = React131__namespace.default.forwardRef(
|
|
|
5556
5761
|
return next;
|
|
5557
5762
|
});
|
|
5558
5763
|
};
|
|
5559
|
-
const rows =
|
|
5764
|
+
const rows = React136__namespace.default.useMemo(() => {
|
|
5560
5765
|
const out = [];
|
|
5561
5766
|
for (const [groupKey, list] of grouped) {
|
|
5562
5767
|
if (groupKey !== void 0) {
|
|
@@ -5567,21 +5772,21 @@ var Gantt = React131__namespace.default.forwardRef(
|
|
|
5567
5772
|
}
|
|
5568
5773
|
return out;
|
|
5569
5774
|
}, [grouped, collapsed]);
|
|
5570
|
-
const itemRowIndex =
|
|
5775
|
+
const itemRowIndex = React136__namespace.default.useMemo(() => {
|
|
5571
5776
|
const m = /* @__PURE__ */ new Map();
|
|
5572
5777
|
rows.forEach((r, i) => {
|
|
5573
5778
|
if (r.kind === "item") m.set(r.item.id, i);
|
|
5574
5779
|
});
|
|
5575
5780
|
return m;
|
|
5576
5781
|
}, [rows]);
|
|
5577
|
-
const todayOffsetPx =
|
|
5782
|
+
const todayOffsetPx = React136__namespace.default.useMemo(() => {
|
|
5578
5783
|
if (!showToday) return null;
|
|
5579
5784
|
const now = /* @__PURE__ */ new Date();
|
|
5580
5785
|
const u = unitsBetween(viewport.start, now, scale);
|
|
5581
5786
|
if (u < 0 || u > colCount) return null;
|
|
5582
5787
|
return u * columnWidth;
|
|
5583
5788
|
}, [showToday, viewport.start, scale, colCount, columnWidth]);
|
|
5584
|
-
const columnDates =
|
|
5789
|
+
const columnDates = React136__namespace.default.useMemo(() => {
|
|
5585
5790
|
return Array.from(
|
|
5586
5791
|
{ length: colCount },
|
|
5587
5792
|
(_, i) => addUnits(viewport.start, i, scale)
|
|
@@ -5805,12 +6010,12 @@ function GanttBar({
|
|
|
5805
6010
|
}) {
|
|
5806
6011
|
const color = item.color ?? DEFAULT_COLOR2;
|
|
5807
6012
|
const progress = Math.max(0, Math.min(100, item.progress ?? 0));
|
|
5808
|
-
const [previewLeftDelta, setPreviewLeftDelta] =
|
|
5809
|
-
const [previewRightDelta, setPreviewRightDelta] =
|
|
5810
|
-
const dragMode =
|
|
5811
|
-
const startX =
|
|
5812
|
-
const longPressTimer =
|
|
5813
|
-
const moved =
|
|
6013
|
+
const [previewLeftDelta, setPreviewLeftDelta] = React136__namespace.default.useState(0);
|
|
6014
|
+
const [previewRightDelta, setPreviewRightDelta] = React136__namespace.default.useState(0);
|
|
6015
|
+
const dragMode = React136__namespace.default.useRef(null);
|
|
6016
|
+
const startX = React136__namespace.default.useRef(0);
|
|
6017
|
+
const longPressTimer = React136__namespace.default.useRef(null);
|
|
6018
|
+
const moved = React136__namespace.default.useRef(false);
|
|
5814
6019
|
const baseLeft = unitsBetween(viewportStart, item.start, scale) * columnWidth;
|
|
5815
6020
|
const baseRight = unitsBetween(viewportStart, item.end, scale) * columnWidth;
|
|
5816
6021
|
const baseWidth = Math.max(columnWidth * 0.25, baseRight - baseLeft);
|
|
@@ -6016,7 +6221,7 @@ function DependencyLayer({
|
|
|
6016
6221
|
timelineWidth,
|
|
6017
6222
|
totalHeight
|
|
6018
6223
|
}) {
|
|
6019
|
-
const itemById =
|
|
6224
|
+
const itemById = React136__namespace.default.useMemo(() => {
|
|
6020
6225
|
const m = /* @__PURE__ */ new Map();
|
|
6021
6226
|
for (const it of items) m.set(it.id, it);
|
|
6022
6227
|
return m;
|
|
@@ -6115,9 +6320,9 @@ function KanbanColumn({ column, isOver }) {
|
|
|
6115
6320
|
] });
|
|
6116
6321
|
}
|
|
6117
6322
|
function Kanban({ columns: initialColumns, onMoveCard, className }) {
|
|
6118
|
-
const [cols, setCols] =
|
|
6119
|
-
const [activeCard, setActiveCard] =
|
|
6120
|
-
const [overColId, setOverColId] =
|
|
6323
|
+
const [cols, setCols] = React136__namespace.default.useState(initialColumns);
|
|
6324
|
+
const [activeCard, setActiveCard] = React136__namespace.default.useState(null);
|
|
6325
|
+
const [overColId, setOverColId] = React136__namespace.default.useState(null);
|
|
6121
6326
|
const sensors = core.useSensors(core.useSensor(core.PointerSensor, { activationConstraint: { distance: 5 } }));
|
|
6122
6327
|
const findColByCard = (cardId) => cols.find((c) => c.cards.some((card) => card.id === cardId));
|
|
6123
6328
|
const onDragStart = ({ active }) => {
|
|
@@ -6186,10 +6391,10 @@ function ToolbarButton({
|
|
|
6186
6391
|
] });
|
|
6187
6392
|
}
|
|
6188
6393
|
function LinkPopover({ editor }) {
|
|
6189
|
-
const [open, setOpen] =
|
|
6190
|
-
const [url, setUrl] =
|
|
6394
|
+
const [open, setOpen] = React136__namespace.default.useState(false);
|
|
6395
|
+
const [url, setUrl] = React136__namespace.default.useState("");
|
|
6191
6396
|
const isActive = editor.isActive("link");
|
|
6192
|
-
|
|
6397
|
+
React136__namespace.default.useEffect(() => {
|
|
6193
6398
|
if (!open) return;
|
|
6194
6399
|
const current = editor.getAttributes("link")?.href;
|
|
6195
6400
|
setUrl(current ?? "");
|
|
@@ -6654,7 +6859,7 @@ var proseClasses = cn(
|
|
|
6654
6859
|
// Selected cells in tables
|
|
6655
6860
|
"[&_.selectedCell]:bg-[hsl(var(--accent))]/40"
|
|
6656
6861
|
);
|
|
6657
|
-
var RichEditor =
|
|
6862
|
+
var RichEditor = React136__namespace.default.forwardRef(
|
|
6658
6863
|
function RichEditor2({
|
|
6659
6864
|
value,
|
|
6660
6865
|
defaultValue,
|
|
@@ -6668,12 +6873,12 @@ var RichEditor = React131__namespace.default.forwardRef(
|
|
|
6668
6873
|
}, ref) {
|
|
6669
6874
|
const isControlled = value !== void 0;
|
|
6670
6875
|
const initialContent = isControlled ? value ?? "" : defaultValue ?? "";
|
|
6671
|
-
const debounceRef =
|
|
6672
|
-
const onChangeRef =
|
|
6673
|
-
|
|
6876
|
+
const debounceRef = React136__namespace.default.useRef(null);
|
|
6877
|
+
const onChangeRef = React136__namespace.default.useRef(onChange);
|
|
6878
|
+
React136__namespace.default.useEffect(() => {
|
|
6674
6879
|
onChangeRef.current = onChange;
|
|
6675
6880
|
}, [onChange]);
|
|
6676
|
-
const [charCount, setCharCount] =
|
|
6881
|
+
const [charCount, setCharCount] = React136__namespace.default.useState(0);
|
|
6677
6882
|
const editor = react$1.useEditor({
|
|
6678
6883
|
editable,
|
|
6679
6884
|
content: initialContent,
|
|
@@ -6716,18 +6921,18 @@ var RichEditor = React131__namespace.default.forwardRef(
|
|
|
6716
6921
|
}, 100);
|
|
6717
6922
|
}
|
|
6718
6923
|
});
|
|
6719
|
-
|
|
6924
|
+
React136__namespace.default.useEffect(() => {
|
|
6720
6925
|
if (!editor || !isControlled) return;
|
|
6721
6926
|
const current = editor.getHTML();
|
|
6722
6927
|
if ((value ?? "") !== current) {
|
|
6723
6928
|
editor.commands.setContent(value ?? "", { emitUpdate: false });
|
|
6724
6929
|
}
|
|
6725
6930
|
}, [editor, isControlled, value]);
|
|
6726
|
-
|
|
6931
|
+
React136__namespace.default.useEffect(() => {
|
|
6727
6932
|
if (!editor) return;
|
|
6728
6933
|
if (editor.isEditable !== editable) editor.setEditable(editable);
|
|
6729
6934
|
}, [editor, editable]);
|
|
6730
|
-
|
|
6935
|
+
React136__namespace.default.useEffect(() => {
|
|
6731
6936
|
return () => {
|
|
6732
6937
|
if (debounceRef.current) clearTimeout(debounceRef.current);
|
|
6733
6938
|
};
|
|
@@ -6825,10 +7030,10 @@ function ToggleButtonGroup(props) {
|
|
|
6825
7030
|
props.onChange(val);
|
|
6826
7031
|
}
|
|
6827
7032
|
};
|
|
6828
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("inline-flex items-center gap-1 rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--muted)/0.4)] p-0.5", className), children:
|
|
6829
|
-
if (!
|
|
7033
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("inline-flex items-center gap-1 rounded-md border border-[hsl(var(--border))] bg-[hsl(var(--muted)/0.4)] p-0.5", className), children: React136__namespace.default.Children.map(children, (child) => {
|
|
7034
|
+
if (!React136__namespace.default.isValidElement(child)) return child;
|
|
6830
7035
|
const tb = child;
|
|
6831
|
-
return
|
|
7036
|
+
return React136__namespace.default.cloneElement(tb, {
|
|
6832
7037
|
pressed: isPressed(tb.props.value),
|
|
6833
7038
|
onClick: () => handleClick(tb.props.value)
|
|
6834
7039
|
});
|
|
@@ -7068,7 +7273,7 @@ function Sparkline({
|
|
|
7068
7273
|
const max = Math.max(...data);
|
|
7069
7274
|
const range = max - min || 1;
|
|
7070
7275
|
const pad = 2;
|
|
7071
|
-
const lastY = pad + (1 - (data
|
|
7276
|
+
const lastY = pad + (1 - ((data.at(-1) ?? 0) - min) / range) * (height - pad * 2);
|
|
7072
7277
|
const areaPath = type === "area" ? `${path} L ${width - pad},${height - pad} L ${pad},${height - pad} Z` : void 0;
|
|
7073
7278
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7074
7279
|
"svg",
|
|
@@ -7092,7 +7297,7 @@ var colorMap2 = {
|
|
|
7092
7297
|
warning: "bg-yellow-500",
|
|
7093
7298
|
error: "bg-red-500"
|
|
7094
7299
|
};
|
|
7095
|
-
var
|
|
7300
|
+
var sizeMap4 = {
|
|
7096
7301
|
sm: "h-1.5 w-1.5",
|
|
7097
7302
|
md: "h-2.5 w-2.5",
|
|
7098
7303
|
lg: "h-3.5 w-3.5"
|
|
@@ -7100,7 +7305,7 @@ var sizeMap3 = {
|
|
|
7100
7305
|
function BeaconDot({ color = "primary", size = "md" }) {
|
|
7101
7306
|
return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "relative flex", children: [
|
|
7102
7307
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("animate-ping absolute inline-flex h-full w-full rounded-full opacity-75", colorMap2[color]) }),
|
|
7103
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("relative inline-flex rounded-full",
|
|
7308
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("relative inline-flex rounded-full", sizeMap4[size], colorMap2[color]) })
|
|
7104
7309
|
] });
|
|
7105
7310
|
}
|
|
7106
7311
|
function Beacon({ color = "primary", size = "md", children, className }) {
|
|
@@ -7112,24 +7317,24 @@ function Beacon({ color = "primary", size = "md", children, className }) {
|
|
|
7112
7317
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute -top-1 -right-1 flex", children: /* @__PURE__ */ jsxRuntime.jsx(BeaconDot, { color, size }) })
|
|
7113
7318
|
] });
|
|
7114
7319
|
}
|
|
7115
|
-
var TourContext =
|
|
7320
|
+
var TourContext = React136.createContext(null);
|
|
7116
7321
|
function useTour() {
|
|
7117
|
-
const ctx =
|
|
7322
|
+
const ctx = React136.useContext(TourContext);
|
|
7118
7323
|
if (!ctx) throw new Error("useTour must be used within <Tour>");
|
|
7119
7324
|
return ctx;
|
|
7120
7325
|
}
|
|
7121
7326
|
function Tour({ totalSteps, children }) {
|
|
7122
|
-
const [currentStep, setCurrentStep] =
|
|
7123
|
-
const [isActive, setIsActive] =
|
|
7124
|
-
const stop =
|
|
7125
|
-
const start =
|
|
7327
|
+
const [currentStep, setCurrentStep] = React136.useState(0);
|
|
7328
|
+
const [isActive, setIsActive] = React136.useState(false);
|
|
7329
|
+
const stop = React136.useCallback(() => setIsActive(false), []);
|
|
7330
|
+
const start = React136.useCallback(() => {
|
|
7126
7331
|
setCurrentStep(0);
|
|
7127
7332
|
setIsActive(true);
|
|
7128
7333
|
}, []);
|
|
7129
|
-
const next =
|
|
7130
|
-
const prev =
|
|
7131
|
-
const goTo =
|
|
7132
|
-
|
|
7334
|
+
const next = React136.useCallback(() => setCurrentStep((s) => Math.min(s + 1, totalSteps - 1)), [totalSteps]);
|
|
7335
|
+
const prev = React136.useCallback(() => setCurrentStep((s) => Math.max(s - 1, 0)), []);
|
|
7336
|
+
const goTo = React136.useCallback((step) => setCurrentStep(Math.max(0, Math.min(step, totalSteps - 1))), [totalSteps]);
|
|
7337
|
+
React136.useEffect(() => {
|
|
7133
7338
|
if (!isActive) return;
|
|
7134
7339
|
const onKey = (e) => {
|
|
7135
7340
|
if (e.key === "Escape") stop();
|
|
@@ -7177,13 +7382,13 @@ function TourStep({ step, title, description, placement = "bottom", children })
|
|
|
7177
7382
|
] })
|
|
7178
7383
|
] });
|
|
7179
7384
|
}
|
|
7180
|
-
var ChecklistContext =
|
|
7385
|
+
var ChecklistContext = React136.createContext(null);
|
|
7181
7386
|
function useChecklist() {
|
|
7182
|
-
const ctx =
|
|
7387
|
+
const ctx = React136.useContext(ChecklistContext);
|
|
7183
7388
|
if (!ctx) throw new Error("<ChecklistItem> must be used inside <Checklist>");
|
|
7184
7389
|
return ctx;
|
|
7185
7390
|
}
|
|
7186
|
-
var Checklist =
|
|
7391
|
+
var Checklist = React136__namespace.default.forwardRef(
|
|
7187
7392
|
({
|
|
7188
7393
|
title = "Getting started",
|
|
7189
7394
|
description,
|
|
@@ -7197,32 +7402,32 @@ var Checklist = React131__namespace.default.forwardRef(
|
|
|
7197
7402
|
children,
|
|
7198
7403
|
...props
|
|
7199
7404
|
}, ref) => {
|
|
7200
|
-
const [internalCompleted, setInternalCompleted] =
|
|
7201
|
-
const [open, setOpen] =
|
|
7202
|
-
const completedFiredRef =
|
|
7405
|
+
const [internalCompleted, setInternalCompleted] = React136.useState({});
|
|
7406
|
+
const [open, setOpen] = React136.useState(defaultOpen);
|
|
7407
|
+
const completedFiredRef = React136__namespace.default.useRef(false);
|
|
7203
7408
|
const isControlled = controlledCompleted !== void 0;
|
|
7204
7409
|
const completed = isControlled ? controlledCompleted : internalCompleted;
|
|
7205
|
-
const setCompleted =
|
|
7410
|
+
const setCompleted = React136.useCallback(
|
|
7206
7411
|
(id, value) => {
|
|
7207
7412
|
if (!isControlled) setInternalCompleted((prev) => ({ ...prev, [id]: value }));
|
|
7208
7413
|
onItemChange?.(id, value);
|
|
7209
7414
|
},
|
|
7210
7415
|
[isControlled, onItemChange]
|
|
7211
7416
|
);
|
|
7212
|
-
const total =
|
|
7417
|
+
const total = React136.useMemo(() => {
|
|
7213
7418
|
let n = 0;
|
|
7214
|
-
|
|
7215
|
-
if (
|
|
7419
|
+
React136__namespace.default.Children.forEach(children, (child) => {
|
|
7420
|
+
if (React136__namespace.default.isValidElement(child) && child.type.displayName === "ChecklistItem") {
|
|
7216
7421
|
n++;
|
|
7217
7422
|
}
|
|
7218
7423
|
});
|
|
7219
7424
|
return n;
|
|
7220
7425
|
}, [children]);
|
|
7221
|
-
const doneCount =
|
|
7426
|
+
const doneCount = React136.useMemo(
|
|
7222
7427
|
() => Object.values(completed).filter(Boolean).length,
|
|
7223
7428
|
[completed]
|
|
7224
7429
|
);
|
|
7225
|
-
|
|
7430
|
+
React136__namespace.default.useEffect(() => {
|
|
7226
7431
|
if (!completedFiredRef.current && total > 0 && doneCount >= total) {
|
|
7227
7432
|
completedFiredRef.current = true;
|
|
7228
7433
|
onComplete?.();
|
|
@@ -7283,11 +7488,11 @@ var Checklist = React131__namespace.default.forwardRef(
|
|
|
7283
7488
|
}
|
|
7284
7489
|
);
|
|
7285
7490
|
Checklist.displayName = "Checklist";
|
|
7286
|
-
var ChecklistItem =
|
|
7491
|
+
var ChecklistItem = React136__namespace.default.forwardRef(
|
|
7287
7492
|
({ id, title, description, action, onActivate, className, ...props }, ref) => {
|
|
7288
7493
|
const { completed, setCompleted } = useChecklist();
|
|
7289
7494
|
const done = !!completed[id];
|
|
7290
|
-
const toggle =
|
|
7495
|
+
const toggle = React136.useCallback(() => {
|
|
7291
7496
|
setCompleted(id, !done);
|
|
7292
7497
|
}, [id, done, setCompleted]);
|
|
7293
7498
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -7366,9 +7571,9 @@ function IntroDisclosure({
|
|
|
7366
7571
|
finishLabel = "Get started"
|
|
7367
7572
|
}) {
|
|
7368
7573
|
const isControlled = controlledOpen !== void 0;
|
|
7369
|
-
const [internalOpen, setInternalOpen] =
|
|
7370
|
-
const [step, setStep] =
|
|
7371
|
-
|
|
7574
|
+
const [internalOpen, setInternalOpen] = React136.useState(false);
|
|
7575
|
+
const [step, setStep] = React136.useState(0);
|
|
7576
|
+
React136.useEffect(() => {
|
|
7372
7577
|
if (isControlled) return;
|
|
7373
7578
|
if (typeof window === "undefined") return;
|
|
7374
7579
|
if (!storageKey) {
|
|
@@ -7381,19 +7586,19 @@ function IntroDisclosure({
|
|
|
7381
7586
|
const isOpen = isControlled ? controlledOpen : internalOpen;
|
|
7382
7587
|
const total = steps.length;
|
|
7383
7588
|
const isLast = step === total - 1;
|
|
7384
|
-
const close =
|
|
7589
|
+
const close = React136.useCallback(() => {
|
|
7385
7590
|
if (!isControlled) {
|
|
7386
7591
|
setInternalOpen(false);
|
|
7387
7592
|
if (storageKey && typeof window !== "undefined") window.localStorage.setItem(storageKey, "1");
|
|
7388
7593
|
}
|
|
7389
7594
|
onOpenChange?.(false);
|
|
7390
7595
|
}, [isControlled, onOpenChange, storageKey]);
|
|
7391
|
-
const next =
|
|
7596
|
+
const next = React136.useCallback(() => {
|
|
7392
7597
|
if (isLast) close();
|
|
7393
7598
|
else setStep((s) => s + 1);
|
|
7394
7599
|
}, [isLast, close]);
|
|
7395
|
-
const prev =
|
|
7396
|
-
|
|
7600
|
+
const prev = React136.useCallback(() => setStep((s) => Math.max(0, s - 1)), []);
|
|
7601
|
+
React136.useEffect(() => {
|
|
7397
7602
|
if (!isOpen) return;
|
|
7398
7603
|
const onKey = (e) => {
|
|
7399
7604
|
if (e.key === "Escape") close();
|
|
@@ -7403,7 +7608,7 @@ function IntroDisclosure({
|
|
|
7403
7608
|
window.addEventListener("keydown", onKey);
|
|
7404
7609
|
return () => window.removeEventListener("keydown", onKey);
|
|
7405
7610
|
}, [isOpen, close, next, prev]);
|
|
7406
|
-
const current =
|
|
7611
|
+
const current = React136.useMemo(() => steps[Math.min(step, total - 1)], [steps, step, total]);
|
|
7407
7612
|
if (!isOpen || total === 0 || !current) return null;
|
|
7408
7613
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7409
7614
|
"div",
|
|
@@ -7583,9 +7788,9 @@ function CalendarGrid({ year, month, selected, onSelect }) {
|
|
|
7583
7788
|
] });
|
|
7584
7789
|
}
|
|
7585
7790
|
function DatePicker({ value, onChange, placeholder = "Pick a date", disabled, className }) {
|
|
7586
|
-
const [open, setOpen] =
|
|
7791
|
+
const [open, setOpen] = React136.useState(false);
|
|
7587
7792
|
const now = value ?? /* @__PURE__ */ new Date();
|
|
7588
|
-
const [view, setView] =
|
|
7793
|
+
const [view, setView] = React136.useState({ year: now.getFullYear(), month: now.getMonth() });
|
|
7589
7794
|
function navigate(delta) {
|
|
7590
7795
|
setView((v) => {
|
|
7591
7796
|
const date = new Date(v.year, v.month + delta);
|
|
@@ -7631,7 +7836,7 @@ function Field({ label, description, error, required, children, className }) {
|
|
|
7631
7836
|
error && /* @__PURE__ */ jsxRuntime.jsx(FieldError, { children: error })
|
|
7632
7837
|
] });
|
|
7633
7838
|
}
|
|
7634
|
-
var FieldLabel =
|
|
7839
|
+
var FieldLabel = React136__namespace.default.forwardRef(
|
|
7635
7840
|
({ className, required, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7636
7841
|
"label",
|
|
7637
7842
|
{
|
|
@@ -7646,7 +7851,7 @@ var FieldLabel = React131__namespace.default.forwardRef(
|
|
|
7646
7851
|
)
|
|
7647
7852
|
);
|
|
7648
7853
|
FieldLabel.displayName = "FieldLabel";
|
|
7649
|
-
var FieldDescription =
|
|
7854
|
+
var FieldDescription = React136__namespace.default.forwardRef(
|
|
7650
7855
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
7651
7856
|
"p",
|
|
7652
7857
|
{
|
|
@@ -7657,7 +7862,7 @@ var FieldDescription = React131__namespace.default.forwardRef(
|
|
|
7657
7862
|
)
|
|
7658
7863
|
);
|
|
7659
7864
|
FieldDescription.displayName = "FieldDescription";
|
|
7660
|
-
var FieldError =
|
|
7865
|
+
var FieldError = React136__namespace.default.forwardRef(
|
|
7661
7866
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
7662
7867
|
"p",
|
|
7663
7868
|
{
|
|
@@ -7720,6 +7925,7 @@ function FieldRenderer({ name, field, register, setValue, watch, error }) {
|
|
|
7720
7925
|
}
|
|
7721
7926
|
function AutoForm({ schema, onSubmit, defaultValues, submitLabel = "Submit" }) {
|
|
7722
7927
|
const { register, handleSubmit, setValue, watch, formState } = reactHookForm.useForm({
|
|
7928
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
7723
7929
|
resolver: zod.zodResolver(schema),
|
|
7724
7930
|
defaultValues
|
|
7725
7931
|
});
|
|
@@ -7757,7 +7963,7 @@ function defaultFor(format3, showAlpha) {
|
|
|
7757
7963
|
if (format3 === "rgb") return showAlpha ? "rgba(59, 130, 246, 1)" : "rgb(59, 130, 246)";
|
|
7758
7964
|
return showAlpha ? "hsla(217, 91%, 60%, 1)" : "hsl(217, 91%, 60%)";
|
|
7759
7965
|
}
|
|
7760
|
-
var ColorPicker =
|
|
7966
|
+
var ColorPicker = React136__namespace.default.forwardRef(
|
|
7761
7967
|
({
|
|
7762
7968
|
value: valueProp,
|
|
7763
7969
|
defaultValue,
|
|
@@ -7772,21 +7978,21 @@ var ColorPicker = React131__namespace.default.forwardRef(
|
|
|
7772
7978
|
}, ref) => {
|
|
7773
7979
|
const fallback = defaultValue ?? defaultFor(format3, showAlpha);
|
|
7774
7980
|
const isControlled = valueProp !== void 0;
|
|
7775
|
-
const [internal, setInternal] =
|
|
7981
|
+
const [internal, setInternal] = React136__namespace.default.useState(fallback);
|
|
7776
7982
|
const value = isControlled ? valueProp : internal;
|
|
7777
|
-
const [draft, setDraft] =
|
|
7778
|
-
const [draftValid, setDraftValid] =
|
|
7779
|
-
|
|
7983
|
+
const [draft, setDraft] = React136__namespace.default.useState(value);
|
|
7984
|
+
const [draftValid, setDraftValid] = React136__namespace.default.useState(true);
|
|
7985
|
+
React136__namespace.default.useEffect(() => {
|
|
7780
7986
|
setDraft(value);
|
|
7781
7987
|
setDraftValid(true);
|
|
7782
7988
|
}, [value]);
|
|
7783
|
-
const [eyeDropperSupported, setEyeDropperSupported] =
|
|
7784
|
-
|
|
7989
|
+
const [eyeDropperSupported, setEyeDropperSupported] = React136__namespace.default.useState(false);
|
|
7990
|
+
React136__namespace.default.useEffect(() => {
|
|
7785
7991
|
if (typeof window !== "undefined" && "EyeDropper" in window) {
|
|
7786
7992
|
setEyeDropperSupported(true);
|
|
7787
7993
|
}
|
|
7788
7994
|
}, []);
|
|
7789
|
-
const commit =
|
|
7995
|
+
const commit = React136__namespace.default.useCallback(
|
|
7790
7996
|
(next) => {
|
|
7791
7997
|
if (!isControlled) setInternal(next);
|
|
7792
7998
|
onValueChange?.(next);
|
|
@@ -7949,8 +8155,8 @@ function filterBySize(files, maxSize) {
|
|
|
7949
8155
|
return maxSize ? files.filter((f) => f.size <= maxSize) : files;
|
|
7950
8156
|
}
|
|
7951
8157
|
function FileUpload({ accept, multiple, maxSize, onFiles, className, disabled }) {
|
|
7952
|
-
const inputRef =
|
|
7953
|
-
const [dragging, setDragging] =
|
|
8158
|
+
const inputRef = React136.useRef(null);
|
|
8159
|
+
const [dragging, setDragging] = React136.useState(false);
|
|
7954
8160
|
function handleFiles(raw) {
|
|
7955
8161
|
if (!raw) return;
|
|
7956
8162
|
const files = filterBySize(Array.from(raw), maxSize);
|
|
@@ -8023,7 +8229,91 @@ function FileUploadPreview({ files, onRemove, className }) {
|
|
|
8023
8229
|
] })
|
|
8024
8230
|
] }, i)) });
|
|
8025
8231
|
}
|
|
8026
|
-
var
|
|
8232
|
+
var FloatingLabelInput = React136__namespace.default.forwardRef(
|
|
8233
|
+
({ label, error, hint, wrapperClassName, className, id, value, defaultValue, onFocus, onBlur, onChange, ...props }, ref) => {
|
|
8234
|
+
const autoId = React136.useId();
|
|
8235
|
+
const inputId = id ?? autoId;
|
|
8236
|
+
const errorId = error ? `${inputId}-error` : void 0;
|
|
8237
|
+
const hintId = hint ? `${inputId}-hint` : void 0;
|
|
8238
|
+
const describedBy = [errorId, hintId].filter(Boolean).join(" ") || void 0;
|
|
8239
|
+
const [focused, setFocused] = React136.useState(false);
|
|
8240
|
+
const [filled, setFilled] = React136.useState(() => {
|
|
8241
|
+
if (value !== void 0 && value !== null && value !== "") return true;
|
|
8242
|
+
if (defaultValue !== void 0 && defaultValue !== null && defaultValue !== "") return true;
|
|
8243
|
+
return false;
|
|
8244
|
+
});
|
|
8245
|
+
const isFloated = focused || filled;
|
|
8246
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "floating-label-input", className: cn("flex flex-col gap-1.5", wrapperClassName), children: [
|
|
8247
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
|
|
8248
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8249
|
+
"input",
|
|
8250
|
+
{
|
|
8251
|
+
ref,
|
|
8252
|
+
id: inputId,
|
|
8253
|
+
value,
|
|
8254
|
+
defaultValue,
|
|
8255
|
+
"data-slot": "input",
|
|
8256
|
+
"data-state": isFloated ? "floated" : "rest",
|
|
8257
|
+
"aria-invalid": Boolean(error) || void 0,
|
|
8258
|
+
"aria-describedby": describedBy,
|
|
8259
|
+
onFocus: (e) => {
|
|
8260
|
+
setFocused(true);
|
|
8261
|
+
onFocus?.(e);
|
|
8262
|
+
},
|
|
8263
|
+
onBlur: (e) => {
|
|
8264
|
+
setFocused(false);
|
|
8265
|
+
onBlur?.(e);
|
|
8266
|
+
},
|
|
8267
|
+
onChange: (e) => {
|
|
8268
|
+
setFilled(e.target.value.length > 0);
|
|
8269
|
+
onChange?.(e);
|
|
8270
|
+
},
|
|
8271
|
+
className: cn(
|
|
8272
|
+
// Reset + structure
|
|
8273
|
+
"peer w-full appearance-none bg-transparent",
|
|
8274
|
+
"h-14 rounded-md border px-3 pt-5 pb-1.5",
|
|
8275
|
+
"text-base text-foreground leading-tight",
|
|
8276
|
+
// Border / focus ring colors
|
|
8277
|
+
"border-input focus:border-ring focus:outline-none focus:ring-2 focus:ring-ring/30",
|
|
8278
|
+
error && "border-destructive focus:border-destructive focus:ring-destructive/30",
|
|
8279
|
+
"disabled:cursor-not-allowed disabled:opacity-50",
|
|
8280
|
+
"placeholder:text-transparent",
|
|
8281
|
+
// hide native placeholder; label takes its job
|
|
8282
|
+
className
|
|
8283
|
+
),
|
|
8284
|
+
...props
|
|
8285
|
+
}
|
|
8286
|
+
),
|
|
8287
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8288
|
+
"label",
|
|
8289
|
+
{
|
|
8290
|
+
htmlFor: inputId,
|
|
8291
|
+
className: cn(
|
|
8292
|
+
"pointer-events-none absolute left-3",
|
|
8293
|
+
"origin-[0_50%] transition-all duration-150 ease-out",
|
|
8294
|
+
"text-muted-foreground",
|
|
8295
|
+
// Rest: centered vertically inside the field, full size
|
|
8296
|
+
!isFloated && "top-1/2 -translate-y-1/2 text-base",
|
|
8297
|
+
// Floated: tucked into the top with a small subtle background
|
|
8298
|
+
isFloated && "top-1.5 text-[11px] uppercase tracking-wider text-foreground/85",
|
|
8299
|
+
error && "text-destructive"
|
|
8300
|
+
),
|
|
8301
|
+
children: label
|
|
8302
|
+
}
|
|
8303
|
+
)
|
|
8304
|
+
] }),
|
|
8305
|
+
error ? /* @__PURE__ */ jsxRuntime.jsx("p", { id: errorId, className: "text-xs text-destructive", children: error }) : hint ? /* @__PURE__ */ jsxRuntime.jsx("p", { id: hintId, className: "text-xs text-muted-foreground", children: hint }) : null
|
|
8306
|
+
] });
|
|
8307
|
+
}
|
|
8308
|
+
);
|
|
8309
|
+
FloatingLabelInput.displayName = "FloatingLabelInput";
|
|
8310
|
+
function FormField(props) {
|
|
8311
|
+
return /* @__PURE__ */ jsxRuntime.jsx(reactHookForm.Controller, { ...props });
|
|
8312
|
+
}
|
|
8313
|
+
function FormItem({ className, ...props }) {
|
|
8314
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("flex flex-col gap-1.5", className), ...props });
|
|
8315
|
+
}
|
|
8316
|
+
var FormLabel = React136__namespace.default.forwardRef(
|
|
8027
8317
|
({ className, error, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8028
8318
|
"label",
|
|
8029
8319
|
{
|
|
@@ -8037,14 +8327,24 @@ var FormLabel2 = React131__namespace.default.forwardRef(
|
|
|
8037
8327
|
}
|
|
8038
8328
|
)
|
|
8039
8329
|
);
|
|
8040
|
-
|
|
8041
|
-
var
|
|
8330
|
+
FormLabel.displayName = "FormLabel";
|
|
8331
|
+
var FormControl = React136__namespace.default.forwardRef(
|
|
8042
8332
|
({ ...props }, ref) => {
|
|
8043
|
-
const id =
|
|
8333
|
+
const id = React136.useId();
|
|
8044
8334
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { ref, id, ...props });
|
|
8045
8335
|
}
|
|
8046
8336
|
);
|
|
8047
|
-
|
|
8337
|
+
FormControl.displayName = "FormControl";
|
|
8338
|
+
function FormDescription({ className, ...props }) {
|
|
8339
|
+
return /* @__PURE__ */ jsxRuntime.jsx("p", { className: cn("text-xs text-[hsl(var(--muted-foreground))]", className), ...props });
|
|
8340
|
+
}
|
|
8341
|
+
function FormMessage({ className, children, name }) {
|
|
8342
|
+
const { formState } = reactHookForm.useFormContext();
|
|
8343
|
+
const error = name ? formState.errors[name] : void 0;
|
|
8344
|
+
const message = error?.message ? String(error.message) : children;
|
|
8345
|
+
if (!message) return null;
|
|
8346
|
+
return /* @__PURE__ */ jsxRuntime.jsx("p", { className: cn("text-xs text-[hsl(var(--destructive))]", className), children: message });
|
|
8347
|
+
}
|
|
8048
8348
|
function ObjectField({
|
|
8049
8349
|
title,
|
|
8050
8350
|
description,
|
|
@@ -8053,7 +8353,7 @@ function ObjectField({
|
|
|
8053
8353
|
children,
|
|
8054
8354
|
className
|
|
8055
8355
|
}) {
|
|
8056
|
-
const [open, setOpen] =
|
|
8356
|
+
const [open, setOpen] = React136.useState(defaultOpen);
|
|
8057
8357
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("rounded-md border border-[hsl(var(--border))] overflow-hidden", className), children: [
|
|
8058
8358
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8059
8359
|
"div",
|
|
@@ -8085,9 +8385,9 @@ function getStrength(value) {
|
|
|
8085
8385
|
if (score <= 3) return { level: "medium", width: "w-2/3", color: "bg-yellow-500" };
|
|
8086
8386
|
return { level: "strong", width: "w-full", color: "bg-green-500" };
|
|
8087
8387
|
}
|
|
8088
|
-
var PasswordInput =
|
|
8388
|
+
var PasswordInput = React136__namespace.default.forwardRef(
|
|
8089
8389
|
({ className, strength, ...props }, ref) => {
|
|
8090
|
-
const [show, setShow] =
|
|
8390
|
+
const [show, setShow] = React136.useState(false);
|
|
8091
8391
|
const value = String(props.value ?? "");
|
|
8092
8392
|
const str = getStrength(value);
|
|
8093
8393
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-1.5", children: [
|
|
@@ -8120,9 +8420,9 @@ var PasswordInput = React131__namespace.default.forwardRef(
|
|
|
8120
8420
|
}
|
|
8121
8421
|
);
|
|
8122
8422
|
PasswordInput.displayName = "PasswordInput";
|
|
8123
|
-
var SearchInput =
|
|
8423
|
+
var SearchInput = React136__namespace.default.forwardRef(
|
|
8124
8424
|
({ className, shortcut, onClear, onChange, value: valueProp, defaultValue, ...props }, ref) => {
|
|
8125
|
-
const [internalValue, setInternalValue] =
|
|
8425
|
+
const [internalValue, setInternalValue] = React136.useState(defaultValue ?? "");
|
|
8126
8426
|
const isControlled = valueProp !== void 0;
|
|
8127
8427
|
const value = isControlled ? String(valueProp) : String(internalValue);
|
|
8128
8428
|
function handleChange(e) {
|
|
@@ -8165,14 +8465,14 @@ var SearchInput = React131__namespace.default.forwardRef(
|
|
|
8165
8465
|
}
|
|
8166
8466
|
);
|
|
8167
8467
|
SearchInput.displayName = "SearchInput";
|
|
8168
|
-
var StepFormContext =
|
|
8468
|
+
var StepFormContext = React136.createContext(null);
|
|
8169
8469
|
function useStepForm() {
|
|
8170
|
-
const ctx =
|
|
8470
|
+
const ctx = React136.useContext(StepFormContext);
|
|
8171
8471
|
if (!ctx) throw new Error("useStepForm must be used within StepForm");
|
|
8172
8472
|
return ctx;
|
|
8173
8473
|
}
|
|
8174
8474
|
function StepForm({ steps, onSubmit, children, className }) {
|
|
8175
|
-
const [currentStep, setCurrentStep] =
|
|
8475
|
+
const [currentStep, setCurrentStep] = React136.useState(0);
|
|
8176
8476
|
const totalSteps = steps.length;
|
|
8177
8477
|
const ctx = {
|
|
8178
8478
|
currentStep,
|
|
@@ -8183,7 +8483,7 @@ function StepForm({ steps, onSubmit, children, className }) {
|
|
|
8183
8483
|
isFirst: currentStep === 0,
|
|
8184
8484
|
isLast: currentStep === totalSteps - 1
|
|
8185
8485
|
};
|
|
8186
|
-
const childArray =
|
|
8486
|
+
const childArray = React136__namespace.default.Children.toArray(children);
|
|
8187
8487
|
const currentChild = childArray[currentStep];
|
|
8188
8488
|
return /* @__PURE__ */ jsxRuntime.jsx(StepFormContext.Provider, { value: ctx, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex flex-col gap-6", className), children: [
|
|
8189
8489
|
/* @__PURE__ */ jsxRuntime.jsx(StepIndicator, { steps, currentStep }),
|
|
@@ -8192,7 +8492,7 @@ function StepForm({ steps, onSubmit, children, className }) {
|
|
|
8192
8492
|
] }) });
|
|
8193
8493
|
}
|
|
8194
8494
|
function StepIndicator({ steps, currentStep }) {
|
|
8195
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: steps.map((label, i) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8495
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: steps.map((label, i) => /* @__PURE__ */ jsxRuntime.jsxs(React136__namespace.default.Fragment, { children: [
|
|
8196
8496
|
i > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("h-px flex-1 bg-[hsl(var(--border))]", i <= currentStep && "bg-[hsl(var(--primary))]") }),
|
|
8197
8497
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-1", children: [
|
|
8198
8498
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: cn(
|
|
@@ -8221,7 +8521,7 @@ function StepFormNavigation({ onSubmit, submitLabel = "Submit" }) {
|
|
|
8221
8521
|
isLast ? /* @__PURE__ */ jsxRuntime.jsx(Button, { type: "button", onClick: onSubmit, children: submitLabel }) : /* @__PURE__ */ jsxRuntime.jsx(Button, { type: "button", onClick: next, children: "Next" })
|
|
8222
8522
|
] });
|
|
8223
8523
|
}
|
|
8224
|
-
var Tags =
|
|
8524
|
+
var Tags = React136__namespace.default.forwardRef(
|
|
8225
8525
|
({
|
|
8226
8526
|
value: valueProp,
|
|
8227
8527
|
defaultValue,
|
|
@@ -8237,25 +8537,25 @@ var Tags = React131__namespace.default.forwardRef(
|
|
|
8237
8537
|
...props
|
|
8238
8538
|
}, ref) => {
|
|
8239
8539
|
const isControlled = valueProp !== void 0;
|
|
8240
|
-
const [internal, setInternal] =
|
|
8540
|
+
const [internal, setInternal] = React136__namespace.default.useState(defaultValue ?? []);
|
|
8241
8541
|
const tags = isControlled ? valueProp : internal;
|
|
8242
|
-
const [input, setInput] =
|
|
8243
|
-
const [error, setError] =
|
|
8244
|
-
const [focused, setFocused] =
|
|
8245
|
-
const [activeIndex, setActiveIndex] =
|
|
8246
|
-
const inputRef =
|
|
8247
|
-
const containerRef =
|
|
8248
|
-
|
|
8542
|
+
const [input, setInput] = React136__namespace.default.useState("");
|
|
8543
|
+
const [error, setError] = React136__namespace.default.useState(null);
|
|
8544
|
+
const [focused, setFocused] = React136__namespace.default.useState(false);
|
|
8545
|
+
const [activeIndex, setActiveIndex] = React136__namespace.default.useState(0);
|
|
8546
|
+
const inputRef = React136__namespace.default.useRef(null);
|
|
8547
|
+
const containerRef = React136__namespace.default.useRef(null);
|
|
8548
|
+
React136__namespace.default.useImperativeHandle(ref, () => containerRef.current);
|
|
8249
8549
|
const atMax = maxTags !== void 0 && tags.length >= maxTags;
|
|
8250
8550
|
const inputDisabled = disabled || atMax;
|
|
8251
|
-
const commit =
|
|
8551
|
+
const commit = React136__namespace.default.useCallback(
|
|
8252
8552
|
(next) => {
|
|
8253
8553
|
if (!isControlled) setInternal(next);
|
|
8254
8554
|
onValueChange?.(next);
|
|
8255
8555
|
},
|
|
8256
8556
|
[isControlled, onValueChange]
|
|
8257
8557
|
);
|
|
8258
|
-
const addTag =
|
|
8558
|
+
const addTag = React136__namespace.default.useCallback(
|
|
8259
8559
|
(raw) => {
|
|
8260
8560
|
const tag = raw.trim();
|
|
8261
8561
|
if (!tag) return false;
|
|
@@ -8281,20 +8581,20 @@ var Tags = React131__namespace.default.forwardRef(
|
|
|
8281
8581
|
},
|
|
8282
8582
|
[tags, allowDuplicates, validate, atMax, commit]
|
|
8283
8583
|
);
|
|
8284
|
-
const removeTag =
|
|
8584
|
+
const removeTag = React136__namespace.default.useCallback(
|
|
8285
8585
|
(index) => {
|
|
8286
8586
|
commit(tags.filter((_, i) => i !== index));
|
|
8287
8587
|
setError(null);
|
|
8288
8588
|
},
|
|
8289
8589
|
[tags, commit]
|
|
8290
8590
|
);
|
|
8291
|
-
const filteredSuggestions =
|
|
8591
|
+
const filteredSuggestions = React136__namespace.default.useMemo(() => {
|
|
8292
8592
|
if (!suggestions || !input.trim()) return [];
|
|
8293
8593
|
const q = input.trim().toLowerCase();
|
|
8294
8594
|
return suggestions.filter((s) => s.toLowerCase().includes(q)).filter((s) => allowDuplicates || !tags.includes(s)).slice(0, 8);
|
|
8295
8595
|
}, [suggestions, input, tags, allowDuplicates]);
|
|
8296
8596
|
const showPopover = focused && !inputDisabled && filteredSuggestions.length > 0;
|
|
8297
|
-
|
|
8597
|
+
React136__namespace.default.useEffect(() => {
|
|
8298
8598
|
if (activeIndex >= filteredSuggestions.length) setActiveIndex(0);
|
|
8299
8599
|
}, [filteredSuggestions.length, activeIndex]);
|
|
8300
8600
|
const handleKeyDown = (e) => {
|
|
@@ -8436,7 +8736,7 @@ var Tags = React131__namespace.default.forwardRef(
|
|
|
8436
8736
|
}
|
|
8437
8737
|
);
|
|
8438
8738
|
Tags.displayName = "Tags";
|
|
8439
|
-
var AppShellCtx =
|
|
8739
|
+
var AppShellCtx = React136__namespace.default.createContext({
|
|
8440
8740
|
collapsed: false,
|
|
8441
8741
|
setCollapsed: () => {
|
|
8442
8742
|
},
|
|
@@ -8444,12 +8744,12 @@ var AppShellCtx = React131__namespace.default.createContext({
|
|
|
8444
8744
|
setMobileOpen: () => {
|
|
8445
8745
|
}
|
|
8446
8746
|
});
|
|
8447
|
-
var useAppShell = () =>
|
|
8448
|
-
var AppShell =
|
|
8747
|
+
var useAppShell = () => React136__namespace.default.useContext(AppShellCtx);
|
|
8748
|
+
var AppShell = React136__namespace.default.forwardRef(
|
|
8449
8749
|
({ className, defaultCollapsed = false, children, ...props }, ref) => {
|
|
8450
|
-
const [collapsed, setCollapsed] =
|
|
8451
|
-
const [mobileOpen, setMobileOpen] =
|
|
8452
|
-
|
|
8750
|
+
const [collapsed, setCollapsed] = React136__namespace.default.useState(defaultCollapsed);
|
|
8751
|
+
const [mobileOpen, setMobileOpen] = React136__namespace.default.useState(false);
|
|
8752
|
+
React136__namespace.default.useEffect(() => {
|
|
8453
8753
|
const handleClick = (e) => {
|
|
8454
8754
|
const target = e.target;
|
|
8455
8755
|
if (target.closest("a[href]") || target.closest("[data-mobile-close]")) {
|
|
@@ -8480,7 +8780,7 @@ var AppShell = React131__namespace.default.forwardRef(
|
|
|
8480
8780
|
}
|
|
8481
8781
|
);
|
|
8482
8782
|
AppShell.displayName = "AppShell";
|
|
8483
|
-
var AppShellSidebar =
|
|
8783
|
+
var AppShellSidebar = React136__namespace.default.forwardRef(
|
|
8484
8784
|
({ className, ...props }, ref) => {
|
|
8485
8785
|
const { mobileOpen } = useAppShell();
|
|
8486
8786
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -8501,11 +8801,11 @@ var AppShellSidebar = React131__namespace.default.forwardRef(
|
|
|
8501
8801
|
}
|
|
8502
8802
|
);
|
|
8503
8803
|
AppShellSidebar.displayName = "AppShellSidebar";
|
|
8504
|
-
var AppShellMain =
|
|
8804
|
+
var AppShellMain = React136__namespace.default.forwardRef(
|
|
8505
8805
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex-1 min-w-0 flex flex-col overflow-auto", className), ...props })
|
|
8506
8806
|
);
|
|
8507
8807
|
AppShellMain.displayName = "AppShellMain";
|
|
8508
|
-
var MobileSidebarTrigger =
|
|
8808
|
+
var MobileSidebarTrigger = React136__namespace.default.forwardRef(
|
|
8509
8809
|
({ className, ...props }, ref) => {
|
|
8510
8810
|
const { mobileOpen, setMobileOpen } = useAppShell();
|
|
8511
8811
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -8527,21 +8827,21 @@ var MobileSidebarTrigger = React131__namespace.default.forwardRef(
|
|
|
8527
8827
|
}
|
|
8528
8828
|
);
|
|
8529
8829
|
MobileSidebarTrigger.displayName = "MobileSidebarTrigger";
|
|
8530
|
-
var
|
|
8830
|
+
var sizeMap5 = {
|
|
8531
8831
|
sm: "max-w-screen-sm",
|
|
8532
8832
|
md: "max-w-screen-md",
|
|
8533
8833
|
lg: "max-w-screen-lg",
|
|
8534
8834
|
xl: "max-w-screen-xl",
|
|
8535
8835
|
full: "max-w-full"
|
|
8536
8836
|
};
|
|
8537
|
-
var Container =
|
|
8837
|
+
var Container = React136__namespace.default.forwardRef(
|
|
8538
8838
|
({ className, size = "lg", noPadding = false, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8539
8839
|
"div",
|
|
8540
8840
|
{
|
|
8541
8841
|
ref,
|
|
8542
8842
|
className: cn(
|
|
8543
8843
|
"mx-auto w-full",
|
|
8544
|
-
|
|
8844
|
+
sizeMap5[size],
|
|
8545
8845
|
!noPadding && "px-4 sm:px-6 lg:px-8",
|
|
8546
8846
|
className
|
|
8547
8847
|
),
|
|
@@ -8550,7 +8850,7 @@ var Container = React131__namespace.default.forwardRef(
|
|
|
8550
8850
|
)
|
|
8551
8851
|
);
|
|
8552
8852
|
Container.displayName = "Container";
|
|
8553
|
-
var Navbar =
|
|
8853
|
+
var Navbar = React136__namespace.default.forwardRef(
|
|
8554
8854
|
({ className, sticky = false, border = true, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8555
8855
|
"nav",
|
|
8556
8856
|
{
|
|
@@ -8566,7 +8866,7 @@ var Navbar = React131__namespace.default.forwardRef(
|
|
|
8566
8866
|
)
|
|
8567
8867
|
);
|
|
8568
8868
|
Navbar.displayName = "Navbar";
|
|
8569
|
-
var NavbarBrand =
|
|
8869
|
+
var NavbarBrand = React136__namespace.default.forwardRef(
|
|
8570
8870
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex items-center gap-2 px-4 shrink-0", className), ...props })
|
|
8571
8871
|
);
|
|
8572
8872
|
NavbarBrand.displayName = "NavbarBrand";
|
|
@@ -8575,7 +8875,7 @@ var alignMap = {
|
|
|
8575
8875
|
center: "justify-center flex-1",
|
|
8576
8876
|
end: "justify-end ml-auto"
|
|
8577
8877
|
};
|
|
8578
|
-
var NavbarContent =
|
|
8878
|
+
var NavbarContent = React136__namespace.default.forwardRef(
|
|
8579
8879
|
({ className, align = "start", ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8580
8880
|
"div",
|
|
8581
8881
|
{
|
|
@@ -8586,11 +8886,11 @@ var NavbarContent = React131__namespace.default.forwardRef(
|
|
|
8586
8886
|
)
|
|
8587
8887
|
);
|
|
8588
8888
|
NavbarContent.displayName = "NavbarContent";
|
|
8589
|
-
var NavbarItem =
|
|
8889
|
+
var NavbarItem = React136__namespace.default.forwardRef(
|
|
8590
8890
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex items-center", className), ...props })
|
|
8591
8891
|
);
|
|
8592
8892
|
NavbarItem.displayName = "NavbarItem";
|
|
8593
|
-
var Page =
|
|
8893
|
+
var Page = React136__namespace.default.forwardRef(
|
|
8594
8894
|
({ className, maxWidth, style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8595
8895
|
"div",
|
|
8596
8896
|
{
|
|
@@ -8602,7 +8902,7 @@ var Page = React131__namespace.default.forwardRef(
|
|
|
8602
8902
|
)
|
|
8603
8903
|
);
|
|
8604
8904
|
Page.displayName = "Page";
|
|
8605
|
-
var PageHeader =
|
|
8905
|
+
var PageHeader = React136__namespace.default.forwardRef(
|
|
8606
8906
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8607
8907
|
"div",
|
|
8608
8908
|
{
|
|
@@ -8613,7 +8913,7 @@ var PageHeader = React131__namespace.default.forwardRef(
|
|
|
8613
8913
|
)
|
|
8614
8914
|
);
|
|
8615
8915
|
PageHeader.displayName = "PageHeader";
|
|
8616
|
-
var PageTitle =
|
|
8916
|
+
var PageTitle = React136__namespace.default.forwardRef(
|
|
8617
8917
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8618
8918
|
"h1",
|
|
8619
8919
|
{
|
|
@@ -8624,19 +8924,19 @@ var PageTitle = React131__namespace.default.forwardRef(
|
|
|
8624
8924
|
)
|
|
8625
8925
|
);
|
|
8626
8926
|
PageTitle.displayName = "PageTitle";
|
|
8627
|
-
var PageDescription =
|
|
8927
|
+
var PageDescription = React136__namespace.default.forwardRef(
|
|
8628
8928
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("p", { ref, className: cn("text-sm text-[hsl(var(--muted-foreground))] mt-1", className), ...props })
|
|
8629
8929
|
);
|
|
8630
8930
|
PageDescription.displayName = "PageDescription";
|
|
8631
|
-
var PageActions =
|
|
8931
|
+
var PageActions = React136__namespace.default.forwardRef(
|
|
8632
8932
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex items-center gap-2 shrink-0", className), ...props })
|
|
8633
8933
|
);
|
|
8634
8934
|
PageActions.displayName = "PageActions";
|
|
8635
|
-
var PageBody =
|
|
8935
|
+
var PageBody = React136__namespace.default.forwardRef(
|
|
8636
8936
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex-1 p-6 flex flex-col gap-6", className), ...props })
|
|
8637
8937
|
);
|
|
8638
8938
|
PageBody.displayName = "PageBody";
|
|
8639
|
-
var ResizeBox =
|
|
8939
|
+
var ResizeBox = React136__namespace.default.forwardRef(
|
|
8640
8940
|
({ className, resize = "both", minWidth = 100, minHeight = 100, style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8641
8941
|
"div",
|
|
8642
8942
|
{
|
|
@@ -8653,7 +8953,7 @@ var HandleIcon = () => /* @__PURE__ */ jsxRuntime.jsxs("svg", { width: "10", hei
|
|
|
8653
8953
|
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M8 5L5 8", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round" }),
|
|
8654
8954
|
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M8 8L8 8", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round" })
|
|
8655
8955
|
] });
|
|
8656
|
-
var ResizeHandle =
|
|
8956
|
+
var ResizeHandle = React136__namespace.default.forwardRef(
|
|
8657
8957
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8658
8958
|
"div",
|
|
8659
8959
|
{
|
|
@@ -8669,16 +8969,16 @@ var ResizeHandle = React131__namespace.default.forwardRef(
|
|
|
8669
8969
|
)
|
|
8670
8970
|
);
|
|
8671
8971
|
ResizeHandle.displayName = "ResizeHandle";
|
|
8672
|
-
var SidebarCtx2 =
|
|
8673
|
-
var useSidebarCtx = () =>
|
|
8972
|
+
var SidebarCtx2 = React136__namespace.default.createContext({ collapsed: false });
|
|
8973
|
+
var useSidebarCtx = () => React136__namespace.default.useContext(SidebarCtx2);
|
|
8674
8974
|
var makeSlot = (name, cls) => {
|
|
8675
|
-
const C =
|
|
8975
|
+
const C = React136__namespace.default.forwardRef(
|
|
8676
8976
|
({ className, ...p }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn(cls, className), ...p })
|
|
8677
8977
|
);
|
|
8678
8978
|
C.displayName = name;
|
|
8679
8979
|
return C;
|
|
8680
8980
|
};
|
|
8681
|
-
var Sidebar2 =
|
|
8981
|
+
var Sidebar2 = React136__namespace.default.forwardRef(
|
|
8682
8982
|
({ className, collapsed = false, onCollapse, width = "240px", style, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(SidebarCtx2.Provider, { value: { collapsed }, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8683
8983
|
"div",
|
|
8684
8984
|
{
|
|
@@ -8706,7 +9006,7 @@ var SidebarContent = makeSlot("SidebarContent", "flex-1 overflow-y-auto py-2");
|
|
|
8706
9006
|
var SidebarFooter2 = makeSlot("SidebarFooter", "px-3 py-3 border-t border-[hsl(var(--border))] shrink-0");
|
|
8707
9007
|
var SidebarGroup = makeSlot("SidebarGroup", "mb-2");
|
|
8708
9008
|
var SidebarSeparator2 = makeSlot("SidebarSeparator", "h-px bg-[hsl(var(--border))] mx-3 my-2");
|
|
8709
|
-
var SidebarGroupLabel =
|
|
9009
|
+
var SidebarGroupLabel = React136__namespace.default.forwardRef(
|
|
8710
9010
|
({ className, ...props }, ref) => {
|
|
8711
9011
|
const { collapsed } = useSidebarCtx();
|
|
8712
9012
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -8720,7 +9020,7 @@ var SidebarGroupLabel = React131__namespace.default.forwardRef(
|
|
|
8720
9020
|
}
|
|
8721
9021
|
);
|
|
8722
9022
|
SidebarGroupLabel.displayName = "SidebarGroupLabel";
|
|
8723
|
-
var SidebarItem2 =
|
|
9023
|
+
var SidebarItem2 = React136__namespace.default.forwardRef(
|
|
8724
9024
|
({ className, icon, label, active, href, badge, onClick, ...props }, ref) => {
|
|
8725
9025
|
const { collapsed } = useSidebarCtx();
|
|
8726
9026
|
const cls = cn(
|
|
@@ -8739,11 +9039,11 @@ var SidebarItem2 = React131__namespace.default.forwardRef(
|
|
|
8739
9039
|
}
|
|
8740
9040
|
);
|
|
8741
9041
|
SidebarItem2.displayName = "SidebarItem";
|
|
8742
|
-
var SplitPage =
|
|
9042
|
+
var SplitPage = React136__namespace.default.forwardRef(
|
|
8743
9043
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex h-full w-full overflow-hidden", className), ...props })
|
|
8744
9044
|
);
|
|
8745
9045
|
SplitPage.displayName = "SplitPage";
|
|
8746
|
-
var SplitPageList =
|
|
9046
|
+
var SplitPageList = React136__namespace.default.forwardRef(
|
|
8747
9047
|
({ className, width = "320px", style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8748
9048
|
"div",
|
|
8749
9049
|
{
|
|
@@ -8755,7 +9055,7 @@ var SplitPageList = React131__namespace.default.forwardRef(
|
|
|
8755
9055
|
)
|
|
8756
9056
|
);
|
|
8757
9057
|
SplitPageList.displayName = "SplitPageList";
|
|
8758
|
-
var SplitPageDetail =
|
|
9058
|
+
var SplitPageDetail = React136__namespace.default.forwardRef(
|
|
8759
9059
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex-1 min-w-0 h-full overflow-auto", className), ...props })
|
|
8760
9060
|
);
|
|
8761
9061
|
SplitPageDetail.displayName = "SplitPageDetail";
|
|
@@ -8780,7 +9080,7 @@ var justifyMap = {
|
|
|
8780
9080
|
around: "justify-around",
|
|
8781
9081
|
evenly: "justify-evenly"
|
|
8782
9082
|
};
|
|
8783
|
-
var Stack =
|
|
9083
|
+
var Stack = React136__namespace.default.forwardRef(
|
|
8784
9084
|
({ className, gap, direction = "col", align, justify, wrap, style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8785
9085
|
"div",
|
|
8786
9086
|
{
|
|
@@ -8799,15 +9099,15 @@ var Stack = React131__namespace.default.forwardRef(
|
|
|
8799
9099
|
)
|
|
8800
9100
|
);
|
|
8801
9101
|
Stack.displayName = "Stack";
|
|
8802
|
-
var HStack =
|
|
9102
|
+
var HStack = React136__namespace.default.forwardRef(
|
|
8803
9103
|
(props, ref) => /* @__PURE__ */ jsxRuntime.jsx(Stack, { ref, direction: "row", ...props })
|
|
8804
9104
|
);
|
|
8805
9105
|
HStack.displayName = "HStack";
|
|
8806
|
-
var VStack =
|
|
9106
|
+
var VStack = React136__namespace.default.forwardRef(
|
|
8807
9107
|
(props, ref) => /* @__PURE__ */ jsxRuntime.jsx(Stack, { ref, direction: "col", ...props })
|
|
8808
9108
|
);
|
|
8809
9109
|
VStack.displayName = "VStack";
|
|
8810
|
-
var PageLayout =
|
|
9110
|
+
var PageLayout = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8811
9111
|
"div",
|
|
8812
9112
|
{
|
|
8813
9113
|
ref,
|
|
@@ -8817,7 +9117,7 @@ var PageLayout = React131__namespace.default.forwardRef(({ className, ...props }
|
|
|
8817
9117
|
}
|
|
8818
9118
|
));
|
|
8819
9119
|
PageLayout.displayName = "PageLayout";
|
|
8820
|
-
var PageHeader2 =
|
|
9120
|
+
var PageHeader2 = React136__namespace.default.forwardRef(
|
|
8821
9121
|
({ className, title, description, actions, back, children }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8822
9122
|
"div",
|
|
8823
9123
|
{
|
|
@@ -8839,7 +9139,7 @@ var PageHeader2 = React131__namespace.default.forwardRef(
|
|
|
8839
9139
|
)
|
|
8840
9140
|
);
|
|
8841
9141
|
PageHeader2.displayName = "PageHeader";
|
|
8842
|
-
var PageContainer =
|
|
9142
|
+
var PageContainer = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8843
9143
|
"div",
|
|
8844
9144
|
{
|
|
8845
9145
|
ref,
|
|
@@ -8853,7 +9153,7 @@ var PageContainer = React131__namespace.default.forwardRef(({ className, ...prop
|
|
|
8853
9153
|
}
|
|
8854
9154
|
));
|
|
8855
9155
|
PageContainer.displayName = "PageContainer";
|
|
8856
|
-
var PageMain =
|
|
9156
|
+
var PageMain = React136__namespace.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8857
9157
|
"div",
|
|
8858
9158
|
{
|
|
8859
9159
|
ref,
|
|
@@ -8868,7 +9168,7 @@ var PageMain = React131__namespace.default.forwardRef(({ className, ...props },
|
|
|
8868
9168
|
}
|
|
8869
9169
|
));
|
|
8870
9170
|
PageMain.displayName = "PageMain";
|
|
8871
|
-
var CommandPaletteCtx =
|
|
9171
|
+
var CommandPaletteCtx = React136.createContext({
|
|
8872
9172
|
open: false,
|
|
8873
9173
|
setOpen: () => {
|
|
8874
9174
|
},
|
|
@@ -8878,9 +9178,9 @@ var CommandPaletteCtx = React131.createContext({
|
|
|
8878
9178
|
function CommandPaletteProvider({
|
|
8879
9179
|
children
|
|
8880
9180
|
}) {
|
|
8881
|
-
const [open, setOpen] =
|
|
8882
|
-
const toggle =
|
|
8883
|
-
|
|
9181
|
+
const [open, setOpen] = React136.useState(false);
|
|
9182
|
+
const toggle = React136.useCallback(() => setOpen((v) => !v), []);
|
|
9183
|
+
React136.useEffect(() => {
|
|
8884
9184
|
const down = (e) => {
|
|
8885
9185
|
if (e.key === "k" && (e.metaKey || e.ctrlKey) || e.key === "/") {
|
|
8886
9186
|
if (e.key === "/" && e.target.tagName !== "BODY") return;
|
|
@@ -8894,7 +9194,7 @@ function CommandPaletteProvider({
|
|
|
8894
9194
|
return /* @__PURE__ */ jsxRuntime.jsx(CommandPaletteCtx.Provider, { value: { open, setOpen, toggle }, children });
|
|
8895
9195
|
}
|
|
8896
9196
|
function useCommandPalette() {
|
|
8897
|
-
return
|
|
9197
|
+
return React136.useContext(CommandPaletteCtx);
|
|
8898
9198
|
}
|
|
8899
9199
|
function CommandPalette({
|
|
8900
9200
|
open,
|
|
@@ -9002,7 +9302,7 @@ function CommandPalette({
|
|
|
9002
9302
|
)
|
|
9003
9303
|
] });
|
|
9004
9304
|
}
|
|
9005
|
-
var HotkeysCtx =
|
|
9305
|
+
var HotkeysCtx = React136.createContext({
|
|
9006
9306
|
hotkeys: [],
|
|
9007
9307
|
registerHotkeys: () => () => {
|
|
9008
9308
|
}
|
|
@@ -9025,16 +9325,16 @@ function HotkeysProvider({
|
|
|
9025
9325
|
children,
|
|
9026
9326
|
hotkeys: initialHotkeys = []
|
|
9027
9327
|
}) {
|
|
9028
|
-
const [hotkeys, setHotkeys] =
|
|
9029
|
-
const seqRef =
|
|
9030
|
-
const seqTimerRef =
|
|
9031
|
-
const registerHotkeys =
|
|
9328
|
+
const [hotkeys, setHotkeys] = React136.useState(initialHotkeys);
|
|
9329
|
+
const seqRef = React136.useRef([]);
|
|
9330
|
+
const seqTimerRef = React136.useRef(null);
|
|
9331
|
+
const registerHotkeys = React136.useCallback((newHotkeys) => {
|
|
9032
9332
|
setHotkeys((prev) => [...prev, ...newHotkeys]);
|
|
9033
9333
|
return () => {
|
|
9034
9334
|
setHotkeys((prev) => prev.filter((h) => !newHotkeys.includes(h)));
|
|
9035
9335
|
};
|
|
9036
9336
|
}, []);
|
|
9037
|
-
|
|
9337
|
+
React136.useEffect(() => {
|
|
9038
9338
|
const handleKeyDown = (e) => {
|
|
9039
9339
|
const target = e.target;
|
|
9040
9340
|
if (target.tagName === "INPUT" || target.tagName === "TEXTAREA" || target.tagName === "SELECT" || target.isContentEditable) {
|
|
@@ -9074,14 +9374,14 @@ function HotkeysProvider({
|
|
|
9074
9374
|
return /* @__PURE__ */ jsxRuntime.jsx(HotkeysCtx.Provider, { value: { hotkeys, registerHotkeys }, children });
|
|
9075
9375
|
}
|
|
9076
9376
|
function useHotkeys() {
|
|
9077
|
-
return
|
|
9377
|
+
return React136.useContext(HotkeysCtx);
|
|
9078
9378
|
}
|
|
9079
9379
|
function HelpSheet({
|
|
9080
9380
|
open,
|
|
9081
9381
|
onClose
|
|
9082
9382
|
}) {
|
|
9083
9383
|
const { hotkeys } = useHotkeys();
|
|
9084
|
-
|
|
9384
|
+
React136.useEffect(() => {
|
|
9085
9385
|
const handleEsc = (e) => {
|
|
9086
9386
|
if (e.key === "Escape" && open) onClose();
|
|
9087
9387
|
};
|
|
@@ -9235,9 +9535,9 @@ function ToastItem({ toast: t, onDismiss }) {
|
|
|
9235
9535
|
);
|
|
9236
9536
|
}
|
|
9237
9537
|
function Toaster() {
|
|
9238
|
-
const [toasts, setToasts] =
|
|
9239
|
-
const timers =
|
|
9240
|
-
const dismiss =
|
|
9538
|
+
const [toasts, setToasts] = React136.useState([]);
|
|
9539
|
+
const timers = React136.useRef(/* @__PURE__ */ new Map());
|
|
9540
|
+
const dismiss = React136.useCallback((id) => {
|
|
9241
9541
|
setToasts(
|
|
9242
9542
|
(prev) => prev.map((t) => t.id === id ? { ...t, visible: false } : t)
|
|
9243
9543
|
);
|
|
@@ -9250,7 +9550,7 @@ function Toaster() {
|
|
|
9250
9550
|
timers.current.delete(id);
|
|
9251
9551
|
}
|
|
9252
9552
|
}, []);
|
|
9253
|
-
|
|
9553
|
+
React136.useEffect(() => {
|
|
9254
9554
|
const unsubToast = toastEmitter.onToast((event) => {
|
|
9255
9555
|
setToasts((prev) => {
|
|
9256
9556
|
const next = [
|
|
@@ -9299,7 +9599,7 @@ var directionClasses = {
|
|
|
9299
9599
|
bl: "bg-gradient-to-bl",
|
|
9300
9600
|
l: "bg-gradient-to-l"
|
|
9301
9601
|
};
|
|
9302
|
-
var GradientHeading =
|
|
9602
|
+
var GradientHeading = React136__namespace.default.forwardRef(
|
|
9303
9603
|
({
|
|
9304
9604
|
as: Tag = "h2",
|
|
9305
9605
|
preset = "primary",
|
|
@@ -9345,7 +9645,7 @@ function formatNumber(value, decimals, format3, locale) {
|
|
|
9345
9645
|
}
|
|
9346
9646
|
return decimals > 0 ? value.toFixed(decimals) : String(Math.round(value));
|
|
9347
9647
|
}
|
|
9348
|
-
var AnimatedNumber =
|
|
9648
|
+
var AnimatedNumber = React136__namespace.default.forwardRef(
|
|
9349
9649
|
({
|
|
9350
9650
|
value,
|
|
9351
9651
|
from = 0,
|
|
@@ -9360,12 +9660,12 @@ var AnimatedNumber = React131__namespace.default.forwardRef(
|
|
|
9360
9660
|
className,
|
|
9361
9661
|
...props
|
|
9362
9662
|
}, ref) => {
|
|
9363
|
-
const [displayed, setDisplayed] =
|
|
9364
|
-
const rafRef =
|
|
9365
|
-
const startTimeRef =
|
|
9366
|
-
const containerRef =
|
|
9367
|
-
const hasStarted =
|
|
9368
|
-
const runAnimation =
|
|
9663
|
+
const [displayed, setDisplayed] = React136.useState(autoStart ? from : value);
|
|
9664
|
+
const rafRef = React136.useRef(null);
|
|
9665
|
+
const startTimeRef = React136.useRef(null);
|
|
9666
|
+
const containerRef = React136.useRef(null);
|
|
9667
|
+
const hasStarted = React136.useRef(false);
|
|
9668
|
+
const runAnimation = React136__namespace.default.useCallback(
|
|
9369
9669
|
(startFrom) => {
|
|
9370
9670
|
if (rafRef.current !== null) cancelAnimationFrame(rafRef.current);
|
|
9371
9671
|
startTimeRef.current = null;
|
|
@@ -9388,7 +9688,7 @@ var AnimatedNumber = React131__namespace.default.forwardRef(
|
|
|
9388
9688
|
},
|
|
9389
9689
|
[value, duration, easing]
|
|
9390
9690
|
);
|
|
9391
|
-
|
|
9691
|
+
React136.useEffect(() => {
|
|
9392
9692
|
if (!autoStart) return void 0;
|
|
9393
9693
|
if (typeof IntersectionObserver !== "undefined") {
|
|
9394
9694
|
const el = containerRef.current;
|
|
@@ -9409,11 +9709,11 @@ var AnimatedNumber = React131__namespace.default.forwardRef(
|
|
|
9409
9709
|
return void 0;
|
|
9410
9710
|
}
|
|
9411
9711
|
}, []);
|
|
9412
|
-
|
|
9712
|
+
React136.useEffect(() => {
|
|
9413
9713
|
if (!hasStarted.current) return;
|
|
9414
9714
|
runAnimation(displayed);
|
|
9415
9715
|
}, [value]);
|
|
9416
|
-
|
|
9716
|
+
React136.useEffect(() => {
|
|
9417
9717
|
return () => {
|
|
9418
9718
|
if (rafRef.current !== null) cancelAnimationFrame(rafRef.current);
|
|
9419
9719
|
};
|
|
@@ -9453,9 +9753,9 @@ function TextReveal({
|
|
|
9453
9753
|
className,
|
|
9454
9754
|
style
|
|
9455
9755
|
}) {
|
|
9456
|
-
const [revealed, setRevealed] =
|
|
9457
|
-
const containerRef =
|
|
9458
|
-
|
|
9756
|
+
const [revealed, setRevealed] = React136.useState(false);
|
|
9757
|
+
const containerRef = React136.useRef(null);
|
|
9758
|
+
React136.useEffect(() => {
|
|
9459
9759
|
if (!autoStart) return void 0;
|
|
9460
9760
|
const el = containerRef.current;
|
|
9461
9761
|
if (!el) return void 0;
|
|
@@ -9477,7 +9777,7 @@ function TextReveal({
|
|
|
9477
9777
|
}
|
|
9478
9778
|
}, [autoStart, delay]);
|
|
9479
9779
|
const units = mode === "chars" ? text.split("") : mode === "words" ? text.split(" ") : [text];
|
|
9480
|
-
return
|
|
9780
|
+
return React136__namespace.default.createElement(
|
|
9481
9781
|
Tag,
|
|
9482
9782
|
{
|
|
9483
9783
|
ref: containerRef,
|
|
@@ -9517,16 +9817,16 @@ function Typewriter({
|
|
|
9517
9817
|
className,
|
|
9518
9818
|
style
|
|
9519
9819
|
}) {
|
|
9520
|
-
const [display, setDisplay] =
|
|
9521
|
-
const [phase, setPhase] =
|
|
9522
|
-
const [wordIdx, setWordIdx] =
|
|
9523
|
-
const [cursorVisible, setCursorVisible] =
|
|
9524
|
-
const timerRef =
|
|
9525
|
-
|
|
9820
|
+
const [display, setDisplay] = React136.useState("");
|
|
9821
|
+
const [phase, setPhase] = React136.useState("typing");
|
|
9822
|
+
const [wordIdx, setWordIdx] = React136.useState(0);
|
|
9823
|
+
const [cursorVisible, setCursorVisible] = React136.useState(true);
|
|
9824
|
+
const timerRef = React136.useRef(null);
|
|
9825
|
+
React136.useEffect(() => {
|
|
9526
9826
|
const id = setInterval(() => setCursorVisible((v) => !v), 530);
|
|
9527
9827
|
return () => clearInterval(id);
|
|
9528
9828
|
}, []);
|
|
9529
|
-
|
|
9829
|
+
React136.useEffect(() => {
|
|
9530
9830
|
if (!words.length) return void 0;
|
|
9531
9831
|
const word = words[wordIdx] ?? "";
|
|
9532
9832
|
if (phase === "typing") {
|
|
@@ -9557,7 +9857,7 @@ function Typewriter({
|
|
|
9557
9857
|
if (timerRef.current) clearTimeout(timerRef.current);
|
|
9558
9858
|
};
|
|
9559
9859
|
}, [display, phase, wordIdx, words, typeSpeed, deleteSpeed, pauseAfter, loop]);
|
|
9560
|
-
return
|
|
9860
|
+
return React136__namespace.default.createElement(
|
|
9561
9861
|
Tag,
|
|
9562
9862
|
{
|
|
9563
9863
|
"data-slot": "typewriter",
|
|
@@ -9596,9 +9896,9 @@ var headingVariants = classVarianceAuthority.cva("font-heading tracking-tight te
|
|
|
9596
9896
|
},
|
|
9597
9897
|
defaultVariants: { size: "lg", tone: "default" }
|
|
9598
9898
|
});
|
|
9599
|
-
var Heading =
|
|
9899
|
+
var Heading = React136__namespace.default.forwardRef(
|
|
9600
9900
|
({ as: Tag = "h2", size, tone, className, ...props }, ref) => {
|
|
9601
|
-
return
|
|
9901
|
+
return React136__namespace.default.createElement(Tag, {
|
|
9602
9902
|
ref,
|
|
9603
9903
|
"data-slot": "heading",
|
|
9604
9904
|
className: cn(headingVariants({ size, tone }), className),
|
|
@@ -9628,9 +9928,9 @@ var bodyVariants = classVarianceAuthority.cva("font-sans", {
|
|
|
9628
9928
|
},
|
|
9629
9929
|
defaultVariants: { size: "md", tone: "default", weight: "normal" }
|
|
9630
9930
|
});
|
|
9631
|
-
var Body =
|
|
9931
|
+
var Body = React136__namespace.default.forwardRef(
|
|
9632
9932
|
({ as: Tag = "p", size, tone, weight, className, ...props }, ref) => {
|
|
9633
|
-
return
|
|
9933
|
+
return React136__namespace.default.createElement(Tag, {
|
|
9634
9934
|
ref,
|
|
9635
9935
|
"data-slot": "body",
|
|
9636
9936
|
className: cn(bodyVariants({ size, tone, weight }), className),
|
|
@@ -9649,7 +9949,7 @@ var captionVariants = classVarianceAuthority.cva("font-sans text-[11px] font-sem
|
|
|
9649
9949
|
},
|
|
9650
9950
|
defaultVariants: { tone: "default" }
|
|
9651
9951
|
});
|
|
9652
|
-
var Caption =
|
|
9952
|
+
var Caption = React136__namespace.default.forwardRef(
|
|
9653
9953
|
({ tone, className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
9654
9954
|
"span",
|
|
9655
9955
|
{
|
|
@@ -9661,7 +9961,7 @@ var Caption = React131__namespace.default.forwardRef(
|
|
|
9661
9961
|
)
|
|
9662
9962
|
);
|
|
9663
9963
|
Caption.displayName = "Caption";
|
|
9664
|
-
var Code3 =
|
|
9964
|
+
var Code3 = React136__namespace.default.forwardRef(
|
|
9665
9965
|
({ block, className, children, ...props }, ref) => {
|
|
9666
9966
|
if (block) {
|
|
9667
9967
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -9713,7 +10013,7 @@ var presetStyles = {
|
|
|
9713
10013
|
},
|
|
9714
10014
|
custom: {}
|
|
9715
10015
|
};
|
|
9716
|
-
var GradientBackground =
|
|
10016
|
+
var GradientBackground = React136__namespace.default.forwardRef(
|
|
9717
10017
|
({
|
|
9718
10018
|
fixed = false,
|
|
9719
10019
|
preset = "slate",
|
|
@@ -9772,7 +10072,7 @@ var DEFAULT_COLORS4 = [
|
|
|
9772
10072
|
"hsl(280 100% 70% / 0.25)",
|
|
9773
10073
|
"hsl(217 33% 17% / 0.4)"
|
|
9774
10074
|
];
|
|
9775
|
-
var AnimatedGradient =
|
|
10075
|
+
var AnimatedGradient = React136__namespace.default.forwardRef(
|
|
9776
10076
|
({
|
|
9777
10077
|
colors = DEFAULT_COLORS4,
|
|
9778
10078
|
speed = 1,
|
|
@@ -9783,7 +10083,7 @@ var AnimatedGradient = React131__namespace.default.forwardRef(
|
|
|
9783
10083
|
style,
|
|
9784
10084
|
...props
|
|
9785
10085
|
}, ref) => {
|
|
9786
|
-
const idRef =
|
|
10086
|
+
const idRef = React136.useRef(`ag-${Math.random().toString(36).slice(2, 7)}`);
|
|
9787
10087
|
idRef.current;
|
|
9788
10088
|
const [c0 = DEFAULT_COLORS4[0], c1 = DEFAULT_COLORS4[1], c2 = DEFAULT_COLORS4[2]] = colors;
|
|
9789
10089
|
const duration0 = (12 / speed).toFixed(1);
|
|
@@ -9891,7 +10191,7 @@ var AnimatedGradient = React131__namespace.default.forwardRef(
|
|
|
9891
10191
|
}
|
|
9892
10192
|
);
|
|
9893
10193
|
AnimatedGradient.displayName = "AnimatedGradient";
|
|
9894
|
-
var DottedBackground =
|
|
10194
|
+
var DottedBackground = React136__namespace.default.forwardRef(
|
|
9895
10195
|
({
|
|
9896
10196
|
color,
|
|
9897
10197
|
dotSize = 1,
|
|
@@ -9938,7 +10238,7 @@ var DottedBackground = React131__namespace.default.forwardRef(
|
|
|
9938
10238
|
}
|
|
9939
10239
|
);
|
|
9940
10240
|
DottedBackground.displayName = "DottedBackground";
|
|
9941
|
-
var NoiseBackground =
|
|
10241
|
+
var NoiseBackground = React136__namespace.default.forwardRef(
|
|
9942
10242
|
({
|
|
9943
10243
|
opacity = 0.04,
|
|
9944
10244
|
frequency = 0.65,
|
|
@@ -10034,7 +10334,7 @@ var DEFAULT_COLORS5 = [
|
|
|
10034
10334
|
[0.55, 0.3, 0.95]
|
|
10035
10335
|
// chart-3 violet
|
|
10036
10336
|
];
|
|
10037
|
-
var HeroShaderA =
|
|
10337
|
+
var HeroShaderA = React136__namespace.default.forwardRef(
|
|
10038
10338
|
({
|
|
10039
10339
|
className,
|
|
10040
10340
|
colors = DEFAULT_COLORS5,
|
|
@@ -10045,11 +10345,11 @@ var HeroShaderA = React131__namespace.default.forwardRef(
|
|
|
10045
10345
|
style,
|
|
10046
10346
|
...props
|
|
10047
10347
|
}, ref) => {
|
|
10048
|
-
const wrapRef =
|
|
10049
|
-
const canvasRef =
|
|
10050
|
-
const fallbackRef =
|
|
10051
|
-
|
|
10052
|
-
|
|
10348
|
+
const wrapRef = React136.useRef(null);
|
|
10349
|
+
const canvasRef = React136.useRef(null);
|
|
10350
|
+
const fallbackRef = React136.useRef(false);
|
|
10351
|
+
React136__namespace.default.useImperativeHandle(ref, () => wrapRef.current);
|
|
10352
|
+
React136.useEffect(() => {
|
|
10053
10353
|
if (typeof window === "undefined") return;
|
|
10054
10354
|
const reduceMotion = window.matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
10055
10355
|
const canvas = canvasRef.current;
|
|
@@ -10185,7 +10485,7 @@ var HeroShaderA = React131__namespace.default.forwardRef(
|
|
|
10185
10485
|
}
|
|
10186
10486
|
);
|
|
10187
10487
|
HeroShaderA.displayName = "HeroShaderA";
|
|
10188
|
-
var ScrollHeader =
|
|
10488
|
+
var ScrollHeader = React136__namespace.default.forwardRef(
|
|
10189
10489
|
({
|
|
10190
10490
|
title,
|
|
10191
10491
|
subtitle,
|
|
@@ -10197,8 +10497,8 @@ var ScrollHeader = React131__namespace.default.forwardRef(
|
|
|
10197
10497
|
sticky = true,
|
|
10198
10498
|
className
|
|
10199
10499
|
}, ref) => {
|
|
10200
|
-
const [scrolled, setScrolled] =
|
|
10201
|
-
|
|
10500
|
+
const [scrolled, setScrolled] = React136.useState(false);
|
|
10501
|
+
React136.useEffect(() => {
|
|
10202
10502
|
const container = scrollRef?.current ?? window;
|
|
10203
10503
|
const handleScroll = () => {
|
|
10204
10504
|
const scrollY = container === window ? window.scrollY : container.scrollTop;
|
|
@@ -10272,7 +10572,7 @@ var DEFAULT_TRANSITION = {
|
|
|
10272
10572
|
ease: [0.16, 1, 0.3, 1]
|
|
10273
10573
|
// ease-out-expo (BezierDefinition)
|
|
10274
10574
|
};
|
|
10275
|
-
var FadeIn =
|
|
10575
|
+
var FadeIn = React136__namespace.default.forwardRef(
|
|
10276
10576
|
({ delay = 0, duration, children, ...props }, ref) => {
|
|
10277
10577
|
const transition = {
|
|
10278
10578
|
...DEFAULT_TRANSITION,
|
|
@@ -10300,7 +10600,7 @@ var DIRECTION_PRESET_MAP = {
|
|
|
10300
10600
|
left: "slideLeft",
|
|
10301
10601
|
right: "slideRight"
|
|
10302
10602
|
};
|
|
10303
|
-
var SlideIn =
|
|
10603
|
+
var SlideIn = React136__namespace.default.forwardRef(
|
|
10304
10604
|
({ direction = "up", delay = 0, duration, children, ...props }, ref) => {
|
|
10305
10605
|
const preset = MOTION_PRESETS[DIRECTION_PRESET_MAP[direction]];
|
|
10306
10606
|
const transition = {
|
|
@@ -10323,7 +10623,7 @@ var SlideIn = React131__namespace.default.forwardRef(
|
|
|
10323
10623
|
}
|
|
10324
10624
|
);
|
|
10325
10625
|
SlideIn.displayName = "SlideIn";
|
|
10326
|
-
var ScaleIn =
|
|
10626
|
+
var ScaleIn = React136__namespace.default.forwardRef(
|
|
10327
10627
|
({ delay = 0, duration, children, ...props }, ref) => {
|
|
10328
10628
|
const transition = {
|
|
10329
10629
|
...DEFAULT_TRANSITION,
|
|
@@ -10346,7 +10646,7 @@ var ScaleIn = React131__namespace.default.forwardRef(
|
|
|
10346
10646
|
);
|
|
10347
10647
|
ScaleIn.displayName = "ScaleIn";
|
|
10348
10648
|
function Reveal({ preset = "fadeIn", delay = 0, once = true, children, className }) {
|
|
10349
|
-
const ref =
|
|
10649
|
+
const ref = React136.useRef(null);
|
|
10350
10650
|
const isInView = react.useInView(ref, { once });
|
|
10351
10651
|
const variants = MOTION_PRESETS[preset];
|
|
10352
10652
|
const transition = { ...DEFAULT_TRANSITION, delay };
|
|
@@ -10364,7 +10664,7 @@ function Reveal({ preset = "fadeIn", delay = 0, once = true, children, className
|
|
|
10364
10664
|
);
|
|
10365
10665
|
}
|
|
10366
10666
|
function Stagger({ staggerDelay = 0.05, preset = "fadeIn", children, className, once = true }) {
|
|
10367
|
-
const ref =
|
|
10667
|
+
const ref = React136.useRef(null);
|
|
10368
10668
|
const isInView = react.useInView(ref, { once });
|
|
10369
10669
|
const childVariants = MOTION_PRESETS[preset];
|
|
10370
10670
|
const containerVariants = {
|
|
@@ -10387,19 +10687,19 @@ function Stagger({ staggerDelay = 0.05, preset = "fadeIn", children, className,
|
|
|
10387
10687
|
initial: "hidden",
|
|
10388
10688
|
animate: isInView ? "visible" : "hidden",
|
|
10389
10689
|
className,
|
|
10390
|
-
children:
|
|
10690
|
+
children: React136__namespace.default.Children.map(children, (child, i) => /* @__PURE__ */ jsxRuntime.jsx(react.motion.div, { variants: itemVariants, children: child }, i))
|
|
10391
10691
|
}
|
|
10392
10692
|
);
|
|
10393
10693
|
}
|
|
10394
|
-
var Morph =
|
|
10694
|
+
var Morph = React136__namespace.default.forwardRef(
|
|
10395
10695
|
({ layoutId, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(react.motion.div, { ref, layoutId, layout: true, ...props, children })
|
|
10396
10696
|
);
|
|
10397
10697
|
Morph.displayName = "Morph";
|
|
10398
10698
|
var rippleCounter = 0;
|
|
10399
|
-
var Ripple =
|
|
10699
|
+
var Ripple = React136__namespace.default.forwardRef(
|
|
10400
10700
|
({ color = "currentColor", duration = 0.6, children, style, ...props }, ref) => {
|
|
10401
|
-
const [ripples, setRipples] =
|
|
10402
|
-
const handlePointerDown =
|
|
10701
|
+
const [ripples, setRipples] = React136.useState([]);
|
|
10702
|
+
const handlePointerDown = React136.useCallback(
|
|
10403
10703
|
(e) => {
|
|
10404
10704
|
const rect = e.currentTarget.getBoundingClientRect();
|
|
10405
10705
|
const x = e.clientX - rect.left;
|
|
@@ -10410,7 +10710,7 @@ var Ripple = React131__namespace.default.forwardRef(
|
|
|
10410
10710
|
},
|
|
10411
10711
|
[]
|
|
10412
10712
|
);
|
|
10413
|
-
const removeRipple =
|
|
10713
|
+
const removeRipple = React136.useCallback((key) => {
|
|
10414
10714
|
setRipples((prev) => prev.filter((r) => r.key !== key));
|
|
10415
10715
|
}, []);
|
|
10416
10716
|
const rippleTransition = {
|
|
@@ -10452,9 +10752,9 @@ var Ripple = React131__namespace.default.forwardRef(
|
|
|
10452
10752
|
}
|
|
10453
10753
|
);
|
|
10454
10754
|
Ripple.displayName = "Ripple";
|
|
10455
|
-
var Parallax =
|
|
10755
|
+
var Parallax = React136__namespace.default.forwardRef(
|
|
10456
10756
|
({ offset = 50, scrollRef, children, style, ...props }, ref) => {
|
|
10457
|
-
const innerRef =
|
|
10757
|
+
const innerRef = React136.useRef(null);
|
|
10458
10758
|
const resolvedRef = ref ?? innerRef;
|
|
10459
10759
|
const { scrollYProgress } = react.useScroll({
|
|
10460
10760
|
target: resolvedRef,
|
|
@@ -10475,13 +10775,13 @@ var Parallax = React131__namespace.default.forwardRef(
|
|
|
10475
10775
|
);
|
|
10476
10776
|
Parallax.displayName = "Parallax";
|
|
10477
10777
|
function useLayoutId(key) {
|
|
10478
|
-
const id =
|
|
10778
|
+
const id = React136.useId();
|
|
10479
10779
|
return `${key}-${id}`;
|
|
10480
10780
|
}
|
|
10481
10781
|
function Transition({ show = true, children, mode = "wait" }) {
|
|
10482
10782
|
return /* @__PURE__ */ jsxRuntime.jsx(react.AnimatePresence, { mode, children: show ? children : null });
|
|
10483
10783
|
}
|
|
10484
|
-
var DataList =
|
|
10784
|
+
var DataList = React136__namespace.default.forwardRef(
|
|
10485
10785
|
({ divided = true, bordered = true, className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
10486
10786
|
"ul",
|
|
10487
10787
|
{
|
|
@@ -10498,7 +10798,7 @@ var DataList = React131__namespace.default.forwardRef(
|
|
|
10498
10798
|
)
|
|
10499
10799
|
);
|
|
10500
10800
|
DataList.displayName = "DataList";
|
|
10501
|
-
var DataListItem =
|
|
10801
|
+
var DataListItem = React136__namespace.default.forwardRef(
|
|
10502
10802
|
({ left, title, description, right, interactive, onSelect, className, children, ...props }, ref) => {
|
|
10503
10803
|
const clickable = interactive || !!onSelect;
|
|
10504
10804
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -10558,7 +10858,7 @@ function getWeekDays(date, weekStartsOn) {
|
|
|
10558
10858
|
const start = dateFns.startOfWeek(date, { weekStartsOn });
|
|
10559
10859
|
return Array.from({ length: 7 }, (_, i) => dateFns.addDays(start, i));
|
|
10560
10860
|
}
|
|
10561
|
-
var EventCalendar =
|
|
10861
|
+
var EventCalendar = React136__namespace.default.forwardRef(
|
|
10562
10862
|
({
|
|
10563
10863
|
events,
|
|
10564
10864
|
view: viewProp,
|
|
@@ -10573,20 +10873,20 @@ var EventCalendar = React131__namespace.default.forwardRef(
|
|
|
10573
10873
|
className,
|
|
10574
10874
|
...props
|
|
10575
10875
|
}, ref) => {
|
|
10576
|
-
const [internalView, setInternalView] =
|
|
10876
|
+
const [internalView, setInternalView] = React136__namespace.default.useState("month");
|
|
10577
10877
|
const view = viewProp ?? internalView;
|
|
10578
|
-
const commitView =
|
|
10878
|
+
const commitView = React136__namespace.default.useCallback(
|
|
10579
10879
|
(next) => {
|
|
10580
10880
|
if (viewProp === void 0) setInternalView(next);
|
|
10581
10881
|
onViewChange?.(next);
|
|
10582
10882
|
},
|
|
10583
10883
|
[viewProp, onViewChange]
|
|
10584
10884
|
);
|
|
10585
|
-
const [internalDate, setInternalDate] =
|
|
10885
|
+
const [internalDate, setInternalDate] = React136__namespace.default.useState(
|
|
10586
10886
|
() => defaultDate ?? /* @__PURE__ */ new Date()
|
|
10587
10887
|
);
|
|
10588
10888
|
const date = dateProp ?? internalDate;
|
|
10589
|
-
const commitDate =
|
|
10889
|
+
const commitDate = React136__namespace.default.useCallback(
|
|
10590
10890
|
(next) => {
|
|
10591
10891
|
if (dateProp === void 0) setInternalDate(next);
|
|
10592
10892
|
onDateChange?.(next);
|
|
@@ -10612,7 +10912,7 @@ var EventCalendar = React131__namespace.default.forwardRef(
|
|
|
10612
10912
|
handleToday();
|
|
10613
10913
|
}
|
|
10614
10914
|
};
|
|
10615
|
-
const headerLabel =
|
|
10915
|
+
const headerLabel = React136__namespace.default.useMemo(() => {
|
|
10616
10916
|
if (view === "month") return dateFns.format(date, "MMMM yyyy");
|
|
10617
10917
|
if (view === "week") {
|
|
10618
10918
|
const start = dateFns.startOfWeek(date, { weekStartsOn });
|
|
@@ -10761,11 +11061,11 @@ function MonthView({
|
|
|
10761
11061
|
onEventCreate,
|
|
10762
11062
|
onDayPick
|
|
10763
11063
|
}) {
|
|
10764
|
-
const cells =
|
|
11064
|
+
const cells = React136__namespace.default.useMemo(
|
|
10765
11065
|
() => getMonthMatrix(date, weekStartsOn),
|
|
10766
11066
|
[date, weekStartsOn]
|
|
10767
11067
|
);
|
|
10768
|
-
const weekdayLabels =
|
|
11068
|
+
const weekdayLabels = React136__namespace.default.useMemo(() => {
|
|
10769
11069
|
const start = dateFns.startOfWeek(/* @__PURE__ */ new Date(), { weekStartsOn });
|
|
10770
11070
|
return Array.from({ length: 7 }, (_, i) => dateFns.format(dateFns.addDays(start, i), "EEE"));
|
|
10771
11071
|
}, [weekStartsOn]);
|
|
@@ -10912,7 +11212,7 @@ function HourGrid({
|
|
|
10912
11212
|
onEventCreate,
|
|
10913
11213
|
onEventResize
|
|
10914
11214
|
}) {
|
|
10915
|
-
const hours =
|
|
11215
|
+
const hours = React136__namespace.default.useMemo(() => Array.from({ length: 24 }, (_, i) => i), []);
|
|
10916
11216
|
const today = /* @__PURE__ */ new Date();
|
|
10917
11217
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
10918
11218
|
"div",
|
|
@@ -10966,7 +11266,7 @@ function DayColumn({
|
|
|
10966
11266
|
onEventResize,
|
|
10967
11267
|
showHeader
|
|
10968
11268
|
}) {
|
|
10969
|
-
const bodyRef =
|
|
11269
|
+
const bodyRef = React136__namespace.default.useRef(null);
|
|
10970
11270
|
const handleEmptyClick = (e) => {
|
|
10971
11271
|
if (e.target.closest("[data-event-block]")) return;
|
|
10972
11272
|
if (!onEventCreate) return;
|
|
@@ -11047,10 +11347,10 @@ function EventBlock({ event, day, onClick, onResize }) {
|
|
|
11047
11347
|
dateFns.differenceInMinutes(visibleEnd, visibleStart)
|
|
11048
11348
|
);
|
|
11049
11349
|
const top = startMinutes / 60 * HOUR_ROW_PX;
|
|
11050
|
-
const [resizingDelta, setResizingDelta] =
|
|
11350
|
+
const [resizingDelta, setResizingDelta] = React136__namespace.default.useState(0);
|
|
11051
11351
|
const height = durationMinutes / 60 * HOUR_ROW_PX + resizingDelta;
|
|
11052
|
-
const isResizing =
|
|
11053
|
-
const startY =
|
|
11352
|
+
const isResizing = React136__namespace.default.useRef(false);
|
|
11353
|
+
const startY = React136__namespace.default.useRef(0);
|
|
11054
11354
|
const handleResizePointerDown = (e) => {
|
|
11055
11355
|
if (!onResize) return;
|
|
11056
11356
|
e.preventDefault();
|
|
@@ -11139,7 +11439,7 @@ function WeekView({
|
|
|
11139
11439
|
onEventCreate,
|
|
11140
11440
|
onEventResize
|
|
11141
11441
|
}) {
|
|
11142
|
-
const days =
|
|
11442
|
+
const days = React136__namespace.default.useMemo(
|
|
11143
11443
|
() => getWeekDays(date, weekStartsOn),
|
|
11144
11444
|
[date, weekStartsOn]
|
|
11145
11445
|
);
|
|
@@ -11172,7 +11472,7 @@ function DayView({
|
|
|
11172
11472
|
}
|
|
11173
11473
|
) });
|
|
11174
11474
|
}
|
|
11175
|
-
var GridList =
|
|
11475
|
+
var GridList = React136__namespace.default.forwardRef(
|
|
11176
11476
|
({ minItemWidth = 240, gap = 1, className, style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
11177
11477
|
"ul",
|
|
11178
11478
|
{
|
|
@@ -11189,7 +11489,7 @@ var GridList = React131__namespace.default.forwardRef(
|
|
|
11189
11489
|
)
|
|
11190
11490
|
);
|
|
11191
11491
|
GridList.displayName = "GridList";
|
|
11192
|
-
var GridListItem =
|
|
11492
|
+
var GridListItem = React136__namespace.default.forwardRef(
|
|
11193
11493
|
({ interactive, onSelect, className, ...props }, ref) => {
|
|
11194
11494
|
const clickable = interactive || !!onSelect;
|
|
11195
11495
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -11260,7 +11560,7 @@ async function extractCroppedDataUrl(image, crop, format3, quality) {
|
|
|
11260
11560
|
const mime = format3 === "jpeg" ? "image/jpeg" : format3 === "webp" ? "image/webp" : "image/png";
|
|
11261
11561
|
return canvas.toDataURL(mime, quality);
|
|
11262
11562
|
}
|
|
11263
|
-
var ImageCrop =
|
|
11563
|
+
var ImageCrop = React136__namespace.default.forwardRef(
|
|
11264
11564
|
({
|
|
11265
11565
|
src,
|
|
11266
11566
|
aspect,
|
|
@@ -11275,13 +11575,13 @@ var ImageCrop = React131__namespace.default.forwardRef(
|
|
|
11275
11575
|
className,
|
|
11276
11576
|
...props
|
|
11277
11577
|
}, ref) => {
|
|
11278
|
-
const [crop, setCrop] =
|
|
11279
|
-
const imgRef =
|
|
11280
|
-
const timerRef =
|
|
11281
|
-
|
|
11578
|
+
const [crop, setCrop] = React136__namespace.default.useState(void 0);
|
|
11579
|
+
const imgRef = React136__namespace.default.useRef(null);
|
|
11580
|
+
const timerRef = React136__namespace.default.useRef(null);
|
|
11581
|
+
React136__namespace.default.useEffect(() => {
|
|
11282
11582
|
setCrop(void 0);
|
|
11283
11583
|
}, [src]);
|
|
11284
|
-
|
|
11584
|
+
React136__namespace.default.useEffect(() => {
|
|
11285
11585
|
return () => {
|
|
11286
11586
|
if (timerRef.current) clearTimeout(timerRef.current);
|
|
11287
11587
|
};
|
|
@@ -11506,7 +11806,7 @@ function TreeRow({
|
|
|
11506
11806
|
}
|
|
11507
11807
|
);
|
|
11508
11808
|
}
|
|
11509
|
-
var Tree =
|
|
11809
|
+
var Tree = React136__namespace.default.forwardRef(
|
|
11510
11810
|
({
|
|
11511
11811
|
data,
|
|
11512
11812
|
defaultExpandedIds,
|
|
@@ -11522,21 +11822,21 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11522
11822
|
...props
|
|
11523
11823
|
}, ref) => {
|
|
11524
11824
|
const isControlled = expandedIds !== void 0;
|
|
11525
|
-
const [internalExpanded, setInternalExpanded] =
|
|
11825
|
+
const [internalExpanded, setInternalExpanded] = React136__namespace.default.useState(
|
|
11526
11826
|
() => new Set(defaultExpandedIds ?? [])
|
|
11527
11827
|
);
|
|
11528
|
-
const expandedSet =
|
|
11828
|
+
const expandedSet = React136__namespace.default.useMemo(
|
|
11529
11829
|
() => isControlled ? new Set(expandedIds) : internalExpanded,
|
|
11530
11830
|
[isControlled, expandedIds, internalExpanded]
|
|
11531
11831
|
);
|
|
11532
|
-
const commitExpanded =
|
|
11832
|
+
const commitExpanded = React136__namespace.default.useCallback(
|
|
11533
11833
|
(next) => {
|
|
11534
11834
|
if (!isControlled) setInternalExpanded(next);
|
|
11535
11835
|
onExpandedChange?.(Array.from(next));
|
|
11536
11836
|
},
|
|
11537
11837
|
[isControlled, onExpandedChange]
|
|
11538
11838
|
);
|
|
11539
|
-
const toggle =
|
|
11839
|
+
const toggle = React136__namespace.default.useCallback(
|
|
11540
11840
|
(id) => {
|
|
11541
11841
|
const next = new Set(expandedSet);
|
|
11542
11842
|
if (next.has(id)) next.delete(id);
|
|
@@ -11545,7 +11845,7 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11545
11845
|
},
|
|
11546
11846
|
[expandedSet, commitExpanded]
|
|
11547
11847
|
);
|
|
11548
|
-
const expand =
|
|
11848
|
+
const expand = React136__namespace.default.useCallback(
|
|
11549
11849
|
(id) => {
|
|
11550
11850
|
if (expandedSet.has(id)) return;
|
|
11551
11851
|
const next = new Set(expandedSet);
|
|
@@ -11554,7 +11854,7 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11554
11854
|
},
|
|
11555
11855
|
[expandedSet, commitExpanded]
|
|
11556
11856
|
);
|
|
11557
|
-
const collapse =
|
|
11857
|
+
const collapse = React136__namespace.default.useCallback(
|
|
11558
11858
|
(id) => {
|
|
11559
11859
|
if (!expandedSet.has(id)) return;
|
|
11560
11860
|
const next = new Set(expandedSet);
|
|
@@ -11563,27 +11863,27 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11563
11863
|
},
|
|
11564
11864
|
[expandedSet, commitExpanded]
|
|
11565
11865
|
);
|
|
11566
|
-
const rows =
|
|
11866
|
+
const rows = React136__namespace.default.useMemo(
|
|
11567
11867
|
() => flatten(data, expandedSet),
|
|
11568
11868
|
[data, expandedSet]
|
|
11569
11869
|
);
|
|
11570
|
-
const [focusedId, setFocusedId] =
|
|
11870
|
+
const [focusedId, setFocusedId] = React136__namespace.default.useState(
|
|
11571
11871
|
() => selectedId ?? data[0]?.id ?? null
|
|
11572
11872
|
);
|
|
11573
|
-
const rowRefs =
|
|
11574
|
-
const registerRef =
|
|
11873
|
+
const rowRefs = React136__namespace.default.useRef(/* @__PURE__ */ new Map());
|
|
11874
|
+
const registerRef = React136__namespace.default.useCallback(
|
|
11575
11875
|
(id, el) => {
|
|
11576
11876
|
if (el) rowRefs.current.set(id, el);
|
|
11577
11877
|
else rowRefs.current.delete(id);
|
|
11578
11878
|
},
|
|
11579
11879
|
[]
|
|
11580
11880
|
);
|
|
11581
|
-
const moveFocus =
|
|
11881
|
+
const moveFocus = React136__namespace.default.useCallback((id) => {
|
|
11582
11882
|
setFocusedId(id);
|
|
11583
11883
|
const el = rowRefs.current.get(id);
|
|
11584
11884
|
el?.focus();
|
|
11585
11885
|
}, []);
|
|
11586
|
-
const onRowKeyDown =
|
|
11886
|
+
const onRowKeyDown = React136__namespace.default.useCallback(
|
|
11587
11887
|
(e, row) => {
|
|
11588
11888
|
const idx = rows.findIndex((r) => r.node.id === row.node.id);
|
|
11589
11889
|
if (idx === -1) return;
|
|
@@ -11633,11 +11933,11 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11633
11933
|
core.useSensor(core.PointerSensor, { activationConstraint: { distance: 5 } }),
|
|
11634
11934
|
core.useSensor(core.KeyboardSensor)
|
|
11635
11935
|
);
|
|
11636
|
-
const [activeDragId, setActiveDragId] =
|
|
11637
|
-
const handleDragStart =
|
|
11936
|
+
const [activeDragId, setActiveDragId] = React136__namespace.default.useState(null);
|
|
11937
|
+
const handleDragStart = React136__namespace.default.useCallback((e) => {
|
|
11638
11938
|
setActiveDragId(String(e.active.id));
|
|
11639
11939
|
}, []);
|
|
11640
|
-
const handleDragEnd =
|
|
11940
|
+
const handleDragEnd = React136__namespace.default.useCallback(
|
|
11641
11941
|
(e) => {
|
|
11642
11942
|
setActiveDragId(null);
|
|
11643
11943
|
const { active, over } = e;
|
|
@@ -11653,8 +11953,8 @@ var Tree = React131__namespace.default.forwardRef(
|
|
|
11653
11953
|
},
|
|
11654
11954
|
[onMove]
|
|
11655
11955
|
);
|
|
11656
|
-
const handleDragCancel =
|
|
11657
|
-
const scrollerRef =
|
|
11956
|
+
const handleDragCancel = React136__namespace.default.useCallback(() => setActiveDragId(null), []);
|
|
11957
|
+
const scrollerRef = React136__namespace.default.useRef(null);
|
|
11658
11958
|
const virtualizer = reactVirtual.useVirtualizer({
|
|
11659
11959
|
count: virtualize ? rows.length : 0,
|
|
11660
11960
|
getScrollElement: () => scrollerRef.current,
|
|
@@ -11756,7 +12056,7 @@ async function exitFs() {
|
|
|
11756
12056
|
if (d.exitFullscreen) return void d.exitFullscreen();
|
|
11757
12057
|
if (d.webkitExitFullscreen) return void d.webkitExitFullscreen();
|
|
11758
12058
|
}
|
|
11759
|
-
var VideoPlayer =
|
|
12059
|
+
var VideoPlayer = React136__namespace.default.forwardRef(
|
|
11760
12060
|
({
|
|
11761
12061
|
src,
|
|
11762
12062
|
poster,
|
|
@@ -11773,33 +12073,33 @@ var VideoPlayer = React131__namespace.default.forwardRef(
|
|
|
11773
12073
|
muted: mutedProp,
|
|
11774
12074
|
...videoProps
|
|
11775
12075
|
}, ref) => {
|
|
11776
|
-
const containerRef =
|
|
11777
|
-
const videoRef =
|
|
11778
|
-
const hideTimerRef =
|
|
11779
|
-
const [isPlaying, setIsPlaying] =
|
|
11780
|
-
const [hasPlayed, setHasPlayed] =
|
|
11781
|
-
const [currentTime, setCurrentTime] =
|
|
11782
|
-
const [duration, setDuration] =
|
|
11783
|
-
const [buffered, setBuffered] =
|
|
11784
|
-
const [volume, setVolume] =
|
|
11785
|
-
const [isMuted, setIsMuted] =
|
|
11786
|
-
const [isFullscreen, setIsFullscreen] =
|
|
11787
|
-
const [showControls, setShowControls] =
|
|
11788
|
-
|
|
11789
|
-
|
|
12076
|
+
const containerRef = React136__namespace.default.useRef(null);
|
|
12077
|
+
const videoRef = React136__namespace.default.useRef(null);
|
|
12078
|
+
const hideTimerRef = React136__namespace.default.useRef(null);
|
|
12079
|
+
const [isPlaying, setIsPlaying] = React136__namespace.default.useState(false);
|
|
12080
|
+
const [hasPlayed, setHasPlayed] = React136__namespace.default.useState(Boolean(autoPlay));
|
|
12081
|
+
const [currentTime, setCurrentTime] = React136__namespace.default.useState(0);
|
|
12082
|
+
const [duration, setDuration] = React136__namespace.default.useState(0);
|
|
12083
|
+
const [buffered, setBuffered] = React136__namespace.default.useState(0);
|
|
12084
|
+
const [volume, setVolume] = React136__namespace.default.useState(1);
|
|
12085
|
+
const [isMuted, setIsMuted] = React136__namespace.default.useState(Boolean(mutedProp ?? autoPlay));
|
|
12086
|
+
const [isFullscreen, setIsFullscreen] = React136__namespace.default.useState(false);
|
|
12087
|
+
const [showControls, setShowControls] = React136__namespace.default.useState(true);
|
|
12088
|
+
React136__namespace.default.useImperativeHandle(ref, () => containerRef.current);
|
|
12089
|
+
React136__namespace.default.useEffect(() => {
|
|
11790
12090
|
const v = videoRef.current;
|
|
11791
12091
|
if (!v) return;
|
|
11792
12092
|
v.volume = volume;
|
|
11793
12093
|
v.muted = isMuted;
|
|
11794
12094
|
}, [volume, isMuted]);
|
|
11795
|
-
const showAndScheduleHide =
|
|
12095
|
+
const showAndScheduleHide = React136__namespace.default.useCallback(() => {
|
|
11796
12096
|
setShowControls(true);
|
|
11797
12097
|
if (hideTimerRef.current) clearTimeout(hideTimerRef.current);
|
|
11798
12098
|
if (isPlaying) {
|
|
11799
12099
|
hideTimerRef.current = setTimeout(() => setShowControls(false), 3e3);
|
|
11800
12100
|
}
|
|
11801
12101
|
}, [isPlaying]);
|
|
11802
|
-
|
|
12102
|
+
React136__namespace.default.useEffect(() => {
|
|
11803
12103
|
if (!isPlaying) {
|
|
11804
12104
|
if (hideTimerRef.current) clearTimeout(hideTimerRef.current);
|
|
11805
12105
|
setShowControls(true);
|
|
@@ -11810,7 +12110,7 @@ var VideoPlayer = React131__namespace.default.forwardRef(
|
|
|
11810
12110
|
if (hideTimerRef.current) clearTimeout(hideTimerRef.current);
|
|
11811
12111
|
};
|
|
11812
12112
|
}, [isPlaying]);
|
|
11813
|
-
|
|
12113
|
+
React136__namespace.default.useEffect(() => {
|
|
11814
12114
|
const onFsChange = () => setIsFullscreen(isFullscreenActive());
|
|
11815
12115
|
document.addEventListener("fullscreenchange", onFsChange);
|
|
11816
12116
|
document.addEventListener("webkitfullscreenchange", onFsChange);
|
|
@@ -11819,7 +12119,7 @@ var VideoPlayer = React131__namespace.default.forwardRef(
|
|
|
11819
12119
|
document.removeEventListener("webkitfullscreenchange", onFsChange);
|
|
11820
12120
|
};
|
|
11821
12121
|
}, []);
|
|
11822
|
-
const togglePlay =
|
|
12122
|
+
const togglePlay = React136__namespace.default.useCallback(() => {
|
|
11823
12123
|
const v = videoRef.current;
|
|
11824
12124
|
if (!v) return;
|
|
11825
12125
|
if (v.paused) {
|
|
@@ -11828,22 +12128,22 @@ var VideoPlayer = React131__namespace.default.forwardRef(
|
|
|
11828
12128
|
v.pause();
|
|
11829
12129
|
}
|
|
11830
12130
|
}, []);
|
|
11831
|
-
const toggleMute =
|
|
12131
|
+
const toggleMute = React136__namespace.default.useCallback(() => {
|
|
11832
12132
|
setIsMuted((m) => !m);
|
|
11833
12133
|
}, []);
|
|
11834
|
-
const toggleFullscreen =
|
|
12134
|
+
const toggleFullscreen = React136__namespace.default.useCallback(() => {
|
|
11835
12135
|
const el = containerRef.current;
|
|
11836
12136
|
if (!el) return;
|
|
11837
12137
|
if (isFullscreenActive()) void exitFs();
|
|
11838
12138
|
else void requestFs(el);
|
|
11839
12139
|
}, []);
|
|
11840
|
-
const seekTo =
|
|
12140
|
+
const seekTo = React136__namespace.default.useCallback((time) => {
|
|
11841
12141
|
const v = videoRef.current;
|
|
11842
12142
|
if (!v) return;
|
|
11843
12143
|
const clamped = Math.max(0, Math.min(v.duration || 0, time));
|
|
11844
12144
|
v.currentTime = clamped;
|
|
11845
12145
|
}, []);
|
|
11846
|
-
const seekBy =
|
|
12146
|
+
const seekBy = React136__namespace.default.useCallback(
|
|
11847
12147
|
(delta) => {
|
|
11848
12148
|
seekTo((videoRef.current?.currentTime ?? 0) + delta);
|
|
11849
12149
|
},
|
|
@@ -12191,7 +12491,7 @@ function Combobox({
|
|
|
12191
12491
|
className,
|
|
12192
12492
|
contentWidth = "trigger"
|
|
12193
12493
|
}) {
|
|
12194
|
-
const [open, setOpen] =
|
|
12494
|
+
const [open, setOpen] = React136__namespace.default.useState(false);
|
|
12195
12495
|
const selected = options.find((o) => o.value === value);
|
|
12196
12496
|
return /* @__PURE__ */ jsxRuntime.jsxs(Popover, { open, onOpenChange: setOpen, children: [
|
|
12197
12497
|
/* @__PURE__ */ jsxRuntime.jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -12285,9 +12585,9 @@ function ColorSchemeSelect({
|
|
|
12285
12585
|
className
|
|
12286
12586
|
}) {
|
|
12287
12587
|
const fallback = defaultValue ?? options[0]?.value ?? "";
|
|
12288
|
-
const [value, setValue] =
|
|
12289
|
-
const didMount =
|
|
12290
|
-
|
|
12588
|
+
const [value, setValue] = React136__namespace.default.useState(() => readInitial2(fallback));
|
|
12589
|
+
const didMount = React136__namespace.default.useRef(false);
|
|
12590
|
+
React136__namespace.default.useEffect(() => {
|
|
12291
12591
|
if (!didMount.current) {
|
|
12292
12592
|
didMount.current = true;
|
|
12293
12593
|
return;
|
|
@@ -12332,10 +12632,10 @@ function SidebarResizer({
|
|
|
12332
12632
|
onWidthChange,
|
|
12333
12633
|
className
|
|
12334
12634
|
}) {
|
|
12335
|
-
const [isDragging, setIsDragging] =
|
|
12336
|
-
const startX =
|
|
12337
|
-
const startWidth =
|
|
12338
|
-
|
|
12635
|
+
const [isDragging, setIsDragging] = React136.useState(false);
|
|
12636
|
+
const startX = React136.useRef(0);
|
|
12637
|
+
const startWidth = React136.useRef(defaultWidth);
|
|
12638
|
+
React136.useEffect(() => {
|
|
12339
12639
|
if (typeof window === "undefined") return;
|
|
12340
12640
|
try {
|
|
12341
12641
|
const stored = localStorage.getItem(storageKey);
|
|
@@ -12347,7 +12647,7 @@ function SidebarResizer({
|
|
|
12347
12647
|
} catch {
|
|
12348
12648
|
}
|
|
12349
12649
|
}, [storageKey, min, max, onWidthChange]);
|
|
12350
|
-
const handlePointerDown =
|
|
12650
|
+
const handlePointerDown = React136.useCallback(
|
|
12351
12651
|
(e) => {
|
|
12352
12652
|
e.preventDefault();
|
|
12353
12653
|
e.currentTarget.setPointerCapture(e.pointerId);
|
|
@@ -12360,7 +12660,7 @@ function SidebarResizer({
|
|
|
12360
12660
|
},
|
|
12361
12661
|
[]
|
|
12362
12662
|
);
|
|
12363
|
-
const handlePointerMove =
|
|
12663
|
+
const handlePointerMove = React136.useCallback(
|
|
12364
12664
|
(e) => {
|
|
12365
12665
|
if (!isDragging) return;
|
|
12366
12666
|
const delta = e.clientX - startX.current;
|
|
@@ -12373,7 +12673,7 @@ function SidebarResizer({
|
|
|
12373
12673
|
},
|
|
12374
12674
|
[isDragging, min, max, onWidthChange]
|
|
12375
12675
|
);
|
|
12376
|
-
const handlePointerUp =
|
|
12676
|
+
const handlePointerUp = React136.useCallback(
|
|
12377
12677
|
(e) => {
|
|
12378
12678
|
if (!isDragging) return;
|
|
12379
12679
|
setIsDragging(false);
|
|
@@ -12411,10 +12711,10 @@ function getInitials(name) {
|
|
|
12411
12711
|
}
|
|
12412
12712
|
function WorkspacesMenu({ workspaces, current, onSelect, className }) {
|
|
12413
12713
|
const { collapsed } = useSidebar();
|
|
12414
|
-
const [open, setOpen] =
|
|
12415
|
-
const ref =
|
|
12714
|
+
const [open, setOpen] = React136.useState(false);
|
|
12715
|
+
const ref = React136.useRef(null);
|
|
12416
12716
|
const currentWorkspace = workspaces.find((w) => w.id === current);
|
|
12417
|
-
|
|
12717
|
+
React136.useEffect(() => {
|
|
12418
12718
|
if (!open) return;
|
|
12419
12719
|
function handleClickOutside(e) {
|
|
12420
12720
|
if (ref.current && !ref.current.contains(e.target)) {
|
|
@@ -12497,9 +12797,9 @@ function getInitials2(name) {
|
|
|
12497
12797
|
}
|
|
12498
12798
|
function AppShellUserMenu({ name, email, avatar, onSignOut, onProfile, onSettings, className }) {
|
|
12499
12799
|
const { collapsed } = useSidebar();
|
|
12500
|
-
const [open, setOpen] =
|
|
12501
|
-
const ref =
|
|
12502
|
-
|
|
12800
|
+
const [open, setOpen] = React136.useState(false);
|
|
12801
|
+
const ref = React136.useRef(null);
|
|
12802
|
+
React136.useEffect(() => {
|
|
12503
12803
|
if (!open) return;
|
|
12504
12804
|
function handleClickOutside(e) {
|
|
12505
12805
|
if (ref.current && !ref.current.contains(e.target)) {
|
|
@@ -12733,6 +13033,10 @@ function SortableNav({ items, onReorder, className }) {
|
|
|
12733
13033
|
return /* @__PURE__ */ jsxRuntime.jsx(core.DndContext, { sensors, collisionDetection: core.closestCenter, onDragEnd: handleDragEnd, children: /* @__PURE__ */ jsxRuntime.jsx(sortable.SortableContext, { items: items.map((i) => i.id), strategy: sortable.verticalListSortingStrategy, children: /* @__PURE__ */ jsxRuntime.jsx("nav", { "data-slot": "sortable-nav", className: cn("space-y-0.5 px-2 py-1", className), children: items.map((item) => /* @__PURE__ */ jsxRuntime.jsx(SortableNavItemWrapper, { item }, item.id)) }) }) });
|
|
12734
13034
|
}
|
|
12735
13035
|
|
|
13036
|
+
Object.defineProperty(exports, "Form", {
|
|
13037
|
+
enumerable: true,
|
|
13038
|
+
get: function () { return reactHookForm.FormProvider; }
|
|
13039
|
+
});
|
|
12736
13040
|
Object.defineProperty(exports, "AnimatePresence", {
|
|
12737
13041
|
enumerable: true,
|
|
12738
13042
|
get: function () { return react.AnimatePresence; }
|
|
@@ -12822,6 +13126,7 @@ exports.CarouselContent = CarouselContent;
|
|
|
12822
13126
|
exports.CarouselItem = CarouselItem;
|
|
12823
13127
|
exports.CarouselNext = CarouselNext;
|
|
12824
13128
|
exports.CarouselPrevious = CarouselPrevious;
|
|
13129
|
+
exports.CartLineItem = CartLineItem;
|
|
12825
13130
|
exports.ChartContainer = ChartContainer;
|
|
12826
13131
|
exports.ChartLegend = ChartLegend;
|
|
12827
13132
|
exports.ChartLegendContent = ChartLegendContent;
|
|
@@ -12849,7 +13154,9 @@ exports.CommandDialog = CommandDialog;
|
|
|
12849
13154
|
exports.CommandEmpty = CommandEmpty;
|
|
12850
13155
|
exports.CommandGroup = CommandGroup;
|
|
12851
13156
|
exports.CommandInput = CommandInput;
|
|
13157
|
+
exports.CommandItem = CommandItem;
|
|
12852
13158
|
exports.CommandList = CommandList;
|
|
13159
|
+
exports.CommandListItem = CommandItem2;
|
|
12853
13160
|
exports.CommandPalette = CommandPalette;
|
|
12854
13161
|
exports.CommandPaletteProvider = CommandPaletteProvider;
|
|
12855
13162
|
exports.CommandSeparator = CommandSeparator;
|
|
@@ -12917,6 +13224,7 @@ exports.DropdownMenuSub = DropdownMenuSub;
|
|
|
12917
13224
|
exports.DropdownMenuSubContent = DropdownMenuSubContent;
|
|
12918
13225
|
exports.DropdownMenuSubTrigger = DropdownMenuSubTrigger;
|
|
12919
13226
|
exports.DropdownMenuTrigger = DropdownMenuTrigger;
|
|
13227
|
+
exports.EmptyCart = EmptyCart;
|
|
12920
13228
|
exports.EmptyState = EmptyState;
|
|
12921
13229
|
exports.EmptyStateIcon = EmptyStateIcon;
|
|
12922
13230
|
exports.EventCalendar = EventCalendar;
|
|
@@ -12934,7 +13242,14 @@ exports.FilterBadge = FilterBadge;
|
|
|
12934
13242
|
exports.FilterItem = FilterItem;
|
|
12935
13243
|
exports.Filters = Filters;
|
|
12936
13244
|
exports.FloatingActionButton = FloatingActionButton;
|
|
13245
|
+
exports.FloatingLabelInput = FloatingLabelInput;
|
|
12937
13246
|
exports.FloatingThemePicker = FloatingThemePicker;
|
|
13247
|
+
exports.FormControl = FormControl;
|
|
13248
|
+
exports.FormDescription = FormDescription;
|
|
13249
|
+
exports.FormField = FormField;
|
|
13250
|
+
exports.FormItem = FormItem;
|
|
13251
|
+
exports.FormLabel = FormLabel;
|
|
13252
|
+
exports.FormMessage = FormMessage;
|
|
12938
13253
|
exports.Gantt = Gantt;
|
|
12939
13254
|
exports.GradientBackground = GradientBackground;
|
|
12940
13255
|
exports.GradientHeading = GradientHeading;
|
|
@@ -13033,10 +13348,12 @@ exports.Popover = Popover;
|
|
|
13033
13348
|
exports.PopoverAnchor = PopoverAnchor;
|
|
13034
13349
|
exports.PopoverContent = PopoverContent;
|
|
13035
13350
|
exports.PopoverTrigger = PopoverTrigger;
|
|
13351
|
+
exports.PriceTag = PriceTag;
|
|
13036
13352
|
exports.Progress = Progress;
|
|
13037
13353
|
exports.PropertyItem = PropertyItem;
|
|
13038
13354
|
exports.PropertyList = PropertyList;
|
|
13039
13355
|
exports.QrCode = QrCode;
|
|
13356
|
+
exports.QuantityStepper = QuantityStepper;
|
|
13040
13357
|
exports.RadioGroup = RadioGroup4;
|
|
13041
13358
|
exports.RadioGroupItem = RadioGroupItem;
|
|
13042
13359
|
exports.Rating = Rating;
|
|
@@ -13159,6 +13476,7 @@ exports.Tree = Tree;
|
|
|
13159
13476
|
exports.Typewriter = Typewriter;
|
|
13160
13477
|
exports.UserMenu = UserMenu;
|
|
13161
13478
|
exports.VStack = VStack;
|
|
13479
|
+
exports.VariantPicker = VariantPicker;
|
|
13162
13480
|
exports.VideoPlayer = VideoPlayer;
|
|
13163
13481
|
exports.WorkspaceMembers = WorkspaceMembers;
|
|
13164
13482
|
exports.WorkspacesMenu = WorkspacesMenu;
|
|
@@ -13172,7 +13490,6 @@ exports.toggleVariants = toggleVariants;
|
|
|
13172
13490
|
exports.useAppShell = useAppShell;
|
|
13173
13491
|
exports.useCommandBar = useCommandBar;
|
|
13174
13492
|
exports.useCommandPalette = useCommandPalette;
|
|
13175
|
-
exports.useFormField = useFormField;
|
|
13176
13493
|
exports.useHotkeys = useHotkeys;
|
|
13177
13494
|
exports.useLayoutId = useLayoutId;
|
|
13178
13495
|
exports.useSidebar = useSidebar;
|