@otfdashkit/ui 0.1.1 → 0.1.2
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 +206 -125
- package/dist/index.mjs +194 -124
- 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 +6 -3
- package/src/primitives/Button/Button.tsx +18 -0
- package/src/primitives/code-block.tsx +1 -1
- package/src/primitives/comparison.tsx +1 -1
- package/src/primitives/qr-code.tsx +5 -1
- package/src/themes/base.css +18 -0
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
<h1 align="center">@otfdashkit/ui</h1>
|
|
2
2
|
|
|
3
3
|
<p align="center">
|
|
4
|
-
|
|
5
|
-
Radix UI under the hood, Tailwind v4 on top, AI-coding-tool-native by design.
|
|
4
|
+
137 React components for builders shipping production apps — Radix under the hood, Tailwind v4 on top, AI-agent-readable by design.
|
|
6
5
|
</p>
|
|
7
6
|
|
|
8
7
|
<p align="center">
|
|
@@ -19,13 +18,22 @@
|
|
|
19
18
|
|
|
20
19
|
---
|
|
21
20
|
|
|
22
|
-
##
|
|
21
|
+
## What you get
|
|
23
22
|
|
|
24
|
-
|
|
23
|
+
- **Primitives** — Accordion, Alert, AlertDialog, AspectRatio, Avatar, Badge, Button, Calendar, Card, Carousel, Checkbox, Collapsible, Command, ContextMenu, Dialog, Drawer, DropdownMenu, Form, HoverCard, Input, InputOtp, Label, Menubar, NavigationMenu, Pagination, Popover, Progress, Radio, Resizable, ScrollArea, Select, Separator, Sheet, Skeleton, Slider, Sonner, Spinner, Switch, Table, Tabs, Textarea, Toast, Toggle, Tooltip — full Radix-backed set
|
|
24
|
+
- **App-shell layouts** — AppShell, Sidebar, NavigationMenu, CommandPalette (`⌘K` everywhere)
|
|
25
|
+
- **Blocks** — DataGrid, DataTable, Banner, Breadcrumb, EmptyState, Hotkeys, IconBadge, LoadingOverlay, Persona, PropertyList, Stat, Stepper, StructuredList, Timeline, Toaster
|
|
26
|
+
- **Charts** — BarChart, LineChart, AreaChart, BarList, Sparkline, Heatmap, ActivityHeatmap (recharts under the hood, token-driven colors)
|
|
27
|
+
- **Advanced** — Tiptap editor, ImageCrop, file uploaders, marquees, shiki-powered code blocks, video player
|
|
28
|
+
- **17 themes** out of the box from [`@otfdashkit/tokens`](https://www.npmjs.com/package/@otfdashkit/tokens) — swap palette by changing one attribute on `<html>`
|
|
25
29
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
30
|
+
137 components in [`src/`](src/). Full catalog at the Storybook below.
|
|
31
|
+
|
|
32
|
+
## Live demos
|
|
33
|
+
|
|
34
|
+
- **[ui.otf-kit.dev](https://ui.otf-kit.dev/)** — full Storybook: every component, every variant, every state
|
|
35
|
+
- **[saas.otf-kit.dev](https://saas.otf-kit.dev/)** — production SaaS app built end-to-end on this library
|
|
36
|
+
- **[fitness-preview.otf-kit.dev](https://fitness-preview.otf-kit.dev/)** — same component language, different theme
|
|
29
37
|
|
|
30
38
|
## Install
|
|
31
39
|
|
|
@@ -56,57 +64,36 @@ export default function SignInCard() {
|
|
|
56
64
|
}
|
|
57
65
|
```
|
|
58
66
|
|
|
59
|
-
## What's included
|
|
60
|
-
|
|
61
|
-
- **98 primitives** — Accordion, Alert, AlertDialog, AspectRatio, Avatar, Badge, Button, Calendar, Card, Carousel, Chart, Checkbox, Collapsible, Command, ContextMenu, Dialog, Drawer, DropdownMenu, Form, HoverCard, Input, InputOtp, Label, Menubar, NavigationMenu, Pagination, Popover, Progress, Radio, Resizable, ScrollArea, Select, Separator, Sheet, Skeleton, Slider, Sonner, Spinner, Switch, Table, Tabs, Textarea, Toast, Toggle, Tooltip, … (full list in [`src/primitives/`](https://github.com/otf-kit/sdk/tree/main/packages/ui/src/primitives))
|
|
62
|
-
- **App-shell layouts** — AppShell, Sidebar, NavigationMenu, CommandPalette
|
|
63
|
-
- **Blocks** — DataGrid, DataTable, Banner, Breadcrumb, EmptyState, Hotkeys, IconBadge, LoadingOverlay, Persona, PropertyList, Stat, Stepper, StructuredList, Timeline, Toaster
|
|
64
|
-
- **Charts** — BarChart, LineChart, AreaChart, BarList, Sparkline, Heatmap, ActivityHeatmap (recharts under the hood)
|
|
65
|
-
- **17 themes** out of the box from [`@otfdashkit/tokens`](https://www.npmjs.com/package/@otfdashkit/tokens)
|
|
66
|
-
|
|
67
67
|
## Theming
|
|
68
68
|
|
|
69
|
-
Pick a theme by setting an attribute — tokens cascade to every component:
|
|
70
|
-
|
|
71
69
|
```html
|
|
72
70
|
<html data-theme="ocean-teal" class="dark">
|
|
73
71
|
```
|
|
74
72
|
|
|
75
|
-
|
|
73
|
+
Tokens cascade to every component. Built-in themes: `mono`, `ocean-teal`, `warm-amber`, `rose-coral`, `lavender`, `glacier`, `forest`, `obsidian`, `solar`, `orchid`, `indigo`, `cosmic-night`, `soft-pop`, `neo-brutalism`, `vintage-paper`, `modern-minimal`, `bubblegum`.
|
|
76
74
|
|
|
77
|
-
##
|
|
75
|
+
## Works with
|
|
78
76
|
|
|
79
|
-
Every component ships
|
|
77
|
+
Every component ships structured JSDoc and tested prompts. These agents generate correct usage on the first try:
|
|
80
78
|
|
|
81
|
-
|
|
82
|
-
import { Button } from '@otfdashkit/ui'
|
|
79
|
+
- **Claude Code**, **Cursor**, **Lovable**, **Bolt**, **Copilot**
|
|
83
80
|
|
|
84
|
-
|
|
85
|
-
// variant: 'primary' | 'secondary' | 'destructive' | 'ghost' | 'outline'
|
|
86
|
-
// size: 'sm' | 'md' | 'lg'
|
|
87
|
-
// See ai/prompts/add-button.md for tested usage patterns.
|
|
88
|
-
```
|
|
89
|
-
|
|
90
|
-
## Lint your design system
|
|
91
|
-
|
|
92
|
-
Pair with [`@otfdashkit/eslint-plugin-otf-design`](https://www.npmjs.com/package/@otfdashkit/eslint-plugin-otf-design) to reject hex literals and default Tailwind palette classes (`gray-500`, `blue-600`, etc.) at lint time. Tokens or it doesn't ship.
|
|
81
|
+
Pair with [`@otfdashkit/eslint-plugin-otf-design`](https://www.npmjs.com/package/@otfdashkit/eslint-plugin-otf-design) to reject hex literals and default Tailwind palette classes (`gray-500`, `blue-600`, …) at lint time. Tokens or it doesn't ship.
|
|
93
82
|
|
|
94
|
-
##
|
|
83
|
+
## Related packages
|
|
95
84
|
|
|
96
|
-
-
|
|
97
|
-
-
|
|
98
|
-
-
|
|
85
|
+
- [`@otfdashkit/ui-native`](https://www.npmjs.com/package/@otfdashkit/ui-native) — mobile counterpart, same component API
|
|
86
|
+
- [`@otfdashkit/tokens`](https://www.npmjs.com/package/@otfdashkit/tokens) — design tokens (CSS vars + Tamagui config)
|
|
87
|
+
- [`@otfdashkit/cli`](https://www.npmjs.com/package/@otfdashkit/cli) — heavy-peer component installer (Skia, Reanimated, MMKV)
|
|
99
88
|
|
|
100
|
-
##
|
|
89
|
+
## Community
|
|
101
90
|
|
|
102
|
-
|
|
103
|
-
- [`@otfdashkit/tokens`](https://www.npmjs.com/package/@otfdashkit/tokens) — the design tokens this package consumes
|
|
104
|
-
- [`@otfdashkit/eslint-plugin-otf-design`](https://www.npmjs.com/package/@otfdashkit/eslint-plugin-otf-design) — design-system lint rules
|
|
91
|
+
Questions, bugs, feature requests: **[discord.gg/gpXyu7SqNZ](https://discord.gg/gpXyu7SqNZ)**.
|
|
105
92
|
|
|
106
93
|
## Status
|
|
107
94
|
|
|
108
|
-
`v0.1.x`
|
|
95
|
+
`v0.1.x` — alpha. APIs may change before `1.0`. Pin exact versions in production.
|
|
109
96
|
|
|
110
97
|
## License
|
|
111
98
|
|
|
112
|
-
MIT © otfdashkit
|
|
99
|
+
MIT. You own the source. Eject any time. Copyright © otfdashkit.
|
package/dist/index.js
CHANGED
|
@@ -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');
|
|
@@ -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);
|
|
@@ -1634,104 +1634,6 @@ var DropdownMenuSubContent = React131__namespace.default.forwardRef(({ className
|
|
|
1634
1634
|
DropdownMenuSubContent.displayName = DropdownMenuPrimitive__namespace.SubContent.displayName;
|
|
1635
1635
|
var DropdownMenuShortcut = ({ className, ...props }) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("ml-auto text-xs tracking-widest opacity-60", className), ...props });
|
|
1636
1636
|
DropdownMenuShortcut.displayName = "DropdownMenuShortcut";
|
|
1637
|
-
var labelVariants = classVarianceAuthority.cva(
|
|
1638
|
-
"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
|
|
1639
|
-
);
|
|
1640
|
-
var Label3 = React131__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1641
|
-
LabelPrimitive__namespace.Root,
|
|
1642
|
-
{
|
|
1643
|
-
ref,
|
|
1644
|
-
className: cn(labelVariants(), className),
|
|
1645
|
-
...props
|
|
1646
|
-
}
|
|
1647
|
-
));
|
|
1648
|
-
Label3.displayName = LabelPrimitive__namespace.Root.displayName;
|
|
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";
|
|
1735
1637
|
var HoverCard = HoverCardPrimitive__namespace.Root;
|
|
1736
1638
|
var HoverCardTrigger = HoverCardPrimitive__namespace.Trigger;
|
|
1737
1639
|
var HoverCardContent = React131__namespace.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1805,6 +1707,18 @@ var Input = React131__namespace.default.forwardRef(
|
|
|
1805
1707
|
)
|
|
1806
1708
|
);
|
|
1807
1709
|
Input.displayName = "Input";
|
|
1710
|
+
var labelVariants = classVarianceAuthority.cva(
|
|
1711
|
+
"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
|
|
1712
|
+
);
|
|
1713
|
+
var Label3 = React131__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1714
|
+
LabelPrimitive__namespace.Root,
|
|
1715
|
+
{
|
|
1716
|
+
ref,
|
|
1717
|
+
className: cn(labelVariants(), className),
|
|
1718
|
+
...props
|
|
1719
|
+
}
|
|
1720
|
+
));
|
|
1721
|
+
Label3.displayName = LabelPrimitive__namespace.Root.displayName;
|
|
1808
1722
|
var LogoCarousel = React131__namespace.default.forwardRef(
|
|
1809
1723
|
({
|
|
1810
1724
|
className,
|
|
@@ -3216,6 +3130,27 @@ function Breadcrumb({ children, className }) {
|
|
|
3216
3130
|
});
|
|
3217
3131
|
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
3132
|
}
|
|
3133
|
+
function CommandItem2({ icon, label, description, shortcut, active, onClick, className }) {
|
|
3134
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
3135
|
+
"div",
|
|
3136
|
+
{
|
|
3137
|
+
onClick,
|
|
3138
|
+
className: cn(
|
|
3139
|
+
"flex items-center gap-3 rounded-md px-3 py-2 cursor-pointer transition-colors",
|
|
3140
|
+
active ? "bg-[hsl(var(--accent))] text-[hsl(var(--accent-foreground))]" : "hover:bg-[hsl(var(--accent)/0.6)]",
|
|
3141
|
+
className
|
|
3142
|
+
),
|
|
3143
|
+
children: [
|
|
3144
|
+
icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "shrink-0 text-[hsl(var(--muted-foreground))] h-4 w-4 flex items-center justify-center", children: icon }),
|
|
3145
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0 flex-1", children: [
|
|
3146
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-medium truncate", children: label }),
|
|
3147
|
+
description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-[hsl(var(--muted-foreground))] truncate", children: description })
|
|
3148
|
+
] }),
|
|
3149
|
+
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 })
|
|
3150
|
+
]
|
|
3151
|
+
}
|
|
3152
|
+
);
|
|
3153
|
+
}
|
|
3219
3154
|
function EditableCell({ value: initial, onSave }) {
|
|
3220
3155
|
const [editing, setEditing] = React131__namespace.default.useState(false);
|
|
3221
3156
|
const [val, setVal] = React131__namespace.default.useState(String(initial ?? ""));
|
|
@@ -3371,14 +3306,53 @@ var EmptyStateIcon = React131__namespace.default.forwardRef(
|
|
|
3371
3306
|
({ 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
3307
|
);
|
|
3373
3308
|
EmptyStateIcon.displayName = "EmptyStateIcon";
|
|
3374
|
-
|
|
3375
|
-
|
|
3376
|
-
|
|
3377
|
-
|
|
3378
|
-
|
|
3379
|
-
|
|
3309
|
+
var sizeMap = {
|
|
3310
|
+
sm: "py-8 gap-2",
|
|
3311
|
+
default: "py-12 gap-3",
|
|
3312
|
+
lg: "py-20 gap-4"
|
|
3313
|
+
};
|
|
3314
|
+
var titleSizeMap = {
|
|
3315
|
+
sm: "text-sm font-semibold",
|
|
3316
|
+
default: "text-base font-semibold",
|
|
3317
|
+
lg: "text-lg font-semibold"
|
|
3318
|
+
};
|
|
3319
|
+
var descSizeMap = {
|
|
3320
|
+
sm: "text-xs",
|
|
3321
|
+
default: "text-sm",
|
|
3322
|
+
lg: "text-base"
|
|
3323
|
+
};
|
|
3324
|
+
var iconSizeMap = {
|
|
3325
|
+
sm: "h-10 w-10",
|
|
3326
|
+
default: "h-12 w-12",
|
|
3327
|
+
lg: "h-16 w-16"
|
|
3328
|
+
};
|
|
3329
|
+
function EmptyState({
|
|
3330
|
+
icon,
|
|
3331
|
+
title,
|
|
3332
|
+
description,
|
|
3333
|
+
action,
|
|
3334
|
+
secondaryAction,
|
|
3335
|
+
size = "default",
|
|
3336
|
+
className
|
|
3337
|
+
}) {
|
|
3338
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex flex-col items-center justify-center text-center", sizeMap[size], className), children: [
|
|
3339
|
+
icon && /* @__PURE__ */ jsxRuntime.jsx(EmptyStateIcon, { className: iconSizeMap[size], children: icon }),
|
|
3340
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1 max-w-sm", children: [
|
|
3341
|
+
/* @__PURE__ */ jsxRuntime.jsx("h3", { className: cn(titleSizeMap[size], "text-[hsl(var(--foreground))]"), children: title }),
|
|
3342
|
+
description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: cn(descSizeMap[size], "text-[hsl(var(--muted-foreground))]"), children: description })
|
|
3380
3343
|
] }),
|
|
3381
|
-
action && /* @__PURE__ */ jsxRuntime.
|
|
3344
|
+
(action || secondaryAction) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 mt-1", children: [
|
|
3345
|
+
action && /* @__PURE__ */ jsxRuntime.jsx(Button, { size: size === "sm" ? "sm" : "default", onClick: action.onClick, children: action.label }),
|
|
3346
|
+
secondaryAction && /* @__PURE__ */ jsxRuntime.jsx(
|
|
3347
|
+
Button,
|
|
3348
|
+
{
|
|
3349
|
+
variant: "outline",
|
|
3350
|
+
size: size === "sm" ? "sm" : "default",
|
|
3351
|
+
onClick: secondaryAction.onClick,
|
|
3352
|
+
children: secondaryAction.label
|
|
3353
|
+
}
|
|
3354
|
+
)
|
|
3355
|
+
] })
|
|
3382
3356
|
] });
|
|
3383
3357
|
}
|
|
3384
3358
|
function HotkeyBadge({ children, className }) {
|
|
@@ -3398,13 +3372,13 @@ var colorMap = {
|
|
|
3398
3372
|
error: "bg-red-100 text-red-700 dark:bg-red-900/30 dark:text-red-400",
|
|
3399
3373
|
purple: "bg-purple-100 text-purple-700 dark:bg-purple-900/30 dark:text-purple-400"
|
|
3400
3374
|
};
|
|
3401
|
-
var
|
|
3375
|
+
var sizeMap2 = {
|
|
3402
3376
|
sm: "h-7 w-7 [&>*]:h-3.5 [&>*]:w-3.5",
|
|
3403
3377
|
md: "h-10 w-10 [&>*]:h-5 [&>*]:w-5",
|
|
3404
3378
|
lg: "h-14 w-14 [&>*]:h-7 [&>*]:w-7"
|
|
3405
3379
|
};
|
|
3406
3380
|
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],
|
|
3381
|
+
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
3382
|
}
|
|
3409
3383
|
function LoadingOverlay({ loading, text, fullPage, children, className }) {
|
|
3410
3384
|
if (fullPage) {
|
|
@@ -3421,13 +3395,13 @@ function LoadingOverlay({ loading, text, fullPage, children, className }) {
|
|
|
3421
3395
|
] }) })
|
|
3422
3396
|
] });
|
|
3423
3397
|
}
|
|
3424
|
-
var
|
|
3398
|
+
var sizeMap3 = {
|
|
3425
3399
|
sm: { avatar: "h-7 w-7", name: "text-sm", subtitle: "text-xs" },
|
|
3426
3400
|
md: { avatar: "h-9 w-9", name: "text-sm font-medium", subtitle: "text-xs" },
|
|
3427
3401
|
lg: { avatar: "h-12 w-12", name: "text-base font-medium", subtitle: "text-sm" }
|
|
3428
3402
|
};
|
|
3429
3403
|
function Persona({ name, subtitle, src, size = "md", badge, className }) {
|
|
3430
|
-
const s =
|
|
3404
|
+
const s = sizeMap3[size];
|
|
3431
3405
|
const initials = name.split(" ").map((w) => w[0]).slice(0, 2).join("").toUpperCase();
|
|
3432
3406
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("flex items-center gap-2.5", className), children: [
|
|
3433
3407
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative shrink-0", children: [
|
|
@@ -3828,7 +3802,7 @@ function InviteModal({ className }) {
|
|
|
3828
3802
|
pending.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", children: [
|
|
3829
3803
|
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs font-medium text-[hsl(var(--muted-foreground))]", children: "Pending invites" }),
|
|
3830
3804
|
/* @__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
|
|
3805
|
+
/* @__PURE__ */ jsxRuntime.jsx(Avatar, { className: "h-6 w-6", children: /* @__PURE__ */ jsxRuntime.jsx(AvatarFallback, { className: "text-[10px]", children: p.email.charAt(0).toUpperCase() }) }),
|
|
3832
3806
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex-1 text-sm truncate", children: p.email }),
|
|
3833
3807
|
/* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: "outline", className: "text-[10px] px-1.5 py-0.5 shrink-0", children: p.role }),
|
|
3834
3808
|
/* @__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))]" }) })
|
|
@@ -4521,7 +4495,7 @@ function NotificationSettings({ className }) {
|
|
|
4521
4495
|
NotifRow,
|
|
4522
4496
|
{
|
|
4523
4497
|
...n,
|
|
4524
|
-
checked: states[n.id],
|
|
4498
|
+
checked: states[n.id] ?? false,
|
|
4525
4499
|
onChange: (val) => setStates((s) => ({ ...s, [n.id]: val }))
|
|
4526
4500
|
},
|
|
4527
4501
|
n.id
|
|
@@ -4723,7 +4697,7 @@ var ROLES = [
|
|
|
4723
4697
|
];
|
|
4724
4698
|
function RolesMenu({ value = "member", onChange, className }) {
|
|
4725
4699
|
const [role, setRole] = React131.useState(value);
|
|
4726
|
-
const current = ROLES.find((r) => r.value === role) ?? ROLES[
|
|
4700
|
+
const current = ROLES.find((r) => r.value === role) ?? ROLES[0];
|
|
4727
4701
|
const handleChange = (v) => {
|
|
4728
4702
|
setRole(v);
|
|
4729
4703
|
onChange?.(v);
|
|
@@ -7068,7 +7042,7 @@ function Sparkline({
|
|
|
7068
7042
|
const max = Math.max(...data);
|
|
7069
7043
|
const range = max - min || 1;
|
|
7070
7044
|
const pad = 2;
|
|
7071
|
-
const lastY = pad + (1 - (data
|
|
7045
|
+
const lastY = pad + (1 - ((data.at(-1) ?? 0) - min) / range) * (height - pad * 2);
|
|
7072
7046
|
const areaPath = type === "area" ? `${path} L ${width - pad},${height - pad} L ${pad},${height - pad} Z` : void 0;
|
|
7073
7047
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7074
7048
|
"svg",
|
|
@@ -7092,7 +7066,7 @@ var colorMap2 = {
|
|
|
7092
7066
|
warning: "bg-yellow-500",
|
|
7093
7067
|
error: "bg-red-500"
|
|
7094
7068
|
};
|
|
7095
|
-
var
|
|
7069
|
+
var sizeMap4 = {
|
|
7096
7070
|
sm: "h-1.5 w-1.5",
|
|
7097
7071
|
md: "h-2.5 w-2.5",
|
|
7098
7072
|
lg: "h-3.5 w-3.5"
|
|
@@ -7100,7 +7074,7 @@ var sizeMap3 = {
|
|
|
7100
7074
|
function BeaconDot({ color = "primary", size = "md" }) {
|
|
7101
7075
|
return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "relative flex", children: [
|
|
7102
7076
|
/* @__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",
|
|
7077
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("relative inline-flex rounded-full", sizeMap4[size], colorMap2[color]) })
|
|
7104
7078
|
] });
|
|
7105
7079
|
}
|
|
7106
7080
|
function Beacon({ color = "primary", size = "md", children, className }) {
|
|
@@ -7720,6 +7694,7 @@ function FieldRenderer({ name, field, register, setValue, watch, error }) {
|
|
|
7720
7694
|
}
|
|
7721
7695
|
function AutoForm({ schema, onSubmit, defaultValues, submitLabel = "Submit" }) {
|
|
7722
7696
|
const { register, handleSubmit, setValue, watch, formState } = reactHookForm.useForm({
|
|
7697
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
7723
7698
|
resolver: zod.zodResolver(schema),
|
|
7724
7699
|
defaultValues
|
|
7725
7700
|
});
|
|
@@ -8023,7 +7998,91 @@ function FileUploadPreview({ files, onRemove, className }) {
|
|
|
8023
7998
|
] })
|
|
8024
7999
|
] }, i)) });
|
|
8025
8000
|
}
|
|
8026
|
-
var
|
|
8001
|
+
var FloatingLabelInput = React131__namespace.default.forwardRef(
|
|
8002
|
+
({ label, error, hint, wrapperClassName, className, id, value, defaultValue, onFocus, onBlur, onChange, ...props }, ref) => {
|
|
8003
|
+
const autoId = React131.useId();
|
|
8004
|
+
const inputId = id ?? autoId;
|
|
8005
|
+
const errorId = error ? `${inputId}-error` : void 0;
|
|
8006
|
+
const hintId = hint ? `${inputId}-hint` : void 0;
|
|
8007
|
+
const describedBy = [errorId, hintId].filter(Boolean).join(" ") || void 0;
|
|
8008
|
+
const [focused, setFocused] = React131.useState(false);
|
|
8009
|
+
const [filled, setFilled] = React131.useState(() => {
|
|
8010
|
+
if (value !== void 0 && value !== null && value !== "") return true;
|
|
8011
|
+
if (defaultValue !== void 0 && defaultValue !== null && defaultValue !== "") return true;
|
|
8012
|
+
return false;
|
|
8013
|
+
});
|
|
8014
|
+
const isFloated = focused || filled;
|
|
8015
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "floating-label-input", className: cn("flex flex-col gap-1.5", wrapperClassName), children: [
|
|
8016
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
|
|
8017
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8018
|
+
"input",
|
|
8019
|
+
{
|
|
8020
|
+
ref,
|
|
8021
|
+
id: inputId,
|
|
8022
|
+
value,
|
|
8023
|
+
defaultValue,
|
|
8024
|
+
"data-slot": "input",
|
|
8025
|
+
"data-state": isFloated ? "floated" : "rest",
|
|
8026
|
+
"aria-invalid": Boolean(error) || void 0,
|
|
8027
|
+
"aria-describedby": describedBy,
|
|
8028
|
+
onFocus: (e) => {
|
|
8029
|
+
setFocused(true);
|
|
8030
|
+
onFocus?.(e);
|
|
8031
|
+
},
|
|
8032
|
+
onBlur: (e) => {
|
|
8033
|
+
setFocused(false);
|
|
8034
|
+
onBlur?.(e);
|
|
8035
|
+
},
|
|
8036
|
+
onChange: (e) => {
|
|
8037
|
+
setFilled(e.target.value.length > 0);
|
|
8038
|
+
onChange?.(e);
|
|
8039
|
+
},
|
|
8040
|
+
className: cn(
|
|
8041
|
+
// Reset + structure
|
|
8042
|
+
"peer w-full appearance-none bg-transparent",
|
|
8043
|
+
"h-14 rounded-md border px-3 pt-5 pb-1.5",
|
|
8044
|
+
"text-base text-foreground leading-tight",
|
|
8045
|
+
// Border / focus ring colors
|
|
8046
|
+
"border-input focus:border-ring focus:outline-none focus:ring-2 focus:ring-ring/30",
|
|
8047
|
+
error && "border-destructive focus:border-destructive focus:ring-destructive/30",
|
|
8048
|
+
"disabled:cursor-not-allowed disabled:opacity-50",
|
|
8049
|
+
"placeholder:text-transparent",
|
|
8050
|
+
// hide native placeholder; label takes its job
|
|
8051
|
+
className
|
|
8052
|
+
),
|
|
8053
|
+
...props
|
|
8054
|
+
}
|
|
8055
|
+
),
|
|
8056
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8057
|
+
"label",
|
|
8058
|
+
{
|
|
8059
|
+
htmlFor: inputId,
|
|
8060
|
+
className: cn(
|
|
8061
|
+
"pointer-events-none absolute left-3",
|
|
8062
|
+
"origin-[0_50%] transition-all duration-150 ease-out",
|
|
8063
|
+
"text-muted-foreground",
|
|
8064
|
+
// Rest: centered vertically inside the field, full size
|
|
8065
|
+
!isFloated && "top-1/2 -translate-y-1/2 text-base",
|
|
8066
|
+
// Floated: tucked into the top with a small subtle background
|
|
8067
|
+
isFloated && "top-1.5 text-[11px] uppercase tracking-wider text-foreground/85",
|
|
8068
|
+
error && "text-destructive"
|
|
8069
|
+
),
|
|
8070
|
+
children: label
|
|
8071
|
+
}
|
|
8072
|
+
)
|
|
8073
|
+
] }),
|
|
8074
|
+
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
|
|
8075
|
+
] });
|
|
8076
|
+
}
|
|
8077
|
+
);
|
|
8078
|
+
FloatingLabelInput.displayName = "FloatingLabelInput";
|
|
8079
|
+
function FormField(props) {
|
|
8080
|
+
return /* @__PURE__ */ jsxRuntime.jsx(reactHookForm.Controller, { ...props });
|
|
8081
|
+
}
|
|
8082
|
+
function FormItem({ className, ...props }) {
|
|
8083
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("flex flex-col gap-1.5", className), ...props });
|
|
8084
|
+
}
|
|
8085
|
+
var FormLabel = React131__namespace.default.forwardRef(
|
|
8027
8086
|
({ className, error, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8028
8087
|
"label",
|
|
8029
8088
|
{
|
|
@@ -8037,14 +8096,24 @@ var FormLabel2 = React131__namespace.default.forwardRef(
|
|
|
8037
8096
|
}
|
|
8038
8097
|
)
|
|
8039
8098
|
);
|
|
8040
|
-
|
|
8041
|
-
var
|
|
8099
|
+
FormLabel.displayName = "FormLabel";
|
|
8100
|
+
var FormControl = React131__namespace.default.forwardRef(
|
|
8042
8101
|
({ ...props }, ref) => {
|
|
8043
8102
|
const id = React131.useId();
|
|
8044
8103
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { ref, id, ...props });
|
|
8045
8104
|
}
|
|
8046
8105
|
);
|
|
8047
|
-
|
|
8106
|
+
FormControl.displayName = "FormControl";
|
|
8107
|
+
function FormDescription({ className, ...props }) {
|
|
8108
|
+
return /* @__PURE__ */ jsxRuntime.jsx("p", { className: cn("text-xs text-[hsl(var(--muted-foreground))]", className), ...props });
|
|
8109
|
+
}
|
|
8110
|
+
function FormMessage({ className, children, name }) {
|
|
8111
|
+
const { formState } = reactHookForm.useFormContext();
|
|
8112
|
+
const error = name ? formState.errors[name] : void 0;
|
|
8113
|
+
const message = error?.message ? String(error.message) : children;
|
|
8114
|
+
if (!message) return null;
|
|
8115
|
+
return /* @__PURE__ */ jsxRuntime.jsx("p", { className: cn("text-xs text-[hsl(var(--destructive))]", className), children: message });
|
|
8116
|
+
}
|
|
8048
8117
|
function ObjectField({
|
|
8049
8118
|
title,
|
|
8050
8119
|
description,
|
|
@@ -8527,7 +8596,7 @@ var MobileSidebarTrigger = React131__namespace.default.forwardRef(
|
|
|
8527
8596
|
}
|
|
8528
8597
|
);
|
|
8529
8598
|
MobileSidebarTrigger.displayName = "MobileSidebarTrigger";
|
|
8530
|
-
var
|
|
8599
|
+
var sizeMap5 = {
|
|
8531
8600
|
sm: "max-w-screen-sm",
|
|
8532
8601
|
md: "max-w-screen-md",
|
|
8533
8602
|
lg: "max-w-screen-lg",
|
|
@@ -8541,7 +8610,7 @@ var Container = React131__namespace.default.forwardRef(
|
|
|
8541
8610
|
ref,
|
|
8542
8611
|
className: cn(
|
|
8543
8612
|
"mx-auto w-full",
|
|
8544
|
-
|
|
8613
|
+
sizeMap5[size],
|
|
8545
8614
|
!noPadding && "px-4 sm:px-6 lg:px-8",
|
|
8546
8615
|
className
|
|
8547
8616
|
),
|
|
@@ -12733,6 +12802,10 @@ function SortableNav({ items, onReorder, className }) {
|
|
|
12733
12802
|
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
12803
|
}
|
|
12735
12804
|
|
|
12805
|
+
Object.defineProperty(exports, "Form", {
|
|
12806
|
+
enumerable: true,
|
|
12807
|
+
get: function () { return reactHookForm.FormProvider; }
|
|
12808
|
+
});
|
|
12736
12809
|
Object.defineProperty(exports, "AnimatePresence", {
|
|
12737
12810
|
enumerable: true,
|
|
12738
12811
|
get: function () { return react.AnimatePresence; }
|
|
@@ -12849,7 +12922,9 @@ exports.CommandDialog = CommandDialog;
|
|
|
12849
12922
|
exports.CommandEmpty = CommandEmpty;
|
|
12850
12923
|
exports.CommandGroup = CommandGroup;
|
|
12851
12924
|
exports.CommandInput = CommandInput;
|
|
12925
|
+
exports.CommandItem = CommandItem;
|
|
12852
12926
|
exports.CommandList = CommandList;
|
|
12927
|
+
exports.CommandListItem = CommandItem2;
|
|
12853
12928
|
exports.CommandPalette = CommandPalette;
|
|
12854
12929
|
exports.CommandPaletteProvider = CommandPaletteProvider;
|
|
12855
12930
|
exports.CommandSeparator = CommandSeparator;
|
|
@@ -12934,7 +13009,14 @@ exports.FilterBadge = FilterBadge;
|
|
|
12934
13009
|
exports.FilterItem = FilterItem;
|
|
12935
13010
|
exports.Filters = Filters;
|
|
12936
13011
|
exports.FloatingActionButton = FloatingActionButton;
|
|
13012
|
+
exports.FloatingLabelInput = FloatingLabelInput;
|
|
12937
13013
|
exports.FloatingThemePicker = FloatingThemePicker;
|
|
13014
|
+
exports.FormControl = FormControl;
|
|
13015
|
+
exports.FormDescription = FormDescription;
|
|
13016
|
+
exports.FormField = FormField;
|
|
13017
|
+
exports.FormItem = FormItem;
|
|
13018
|
+
exports.FormLabel = FormLabel;
|
|
13019
|
+
exports.FormMessage = FormMessage;
|
|
12938
13020
|
exports.Gantt = Gantt;
|
|
12939
13021
|
exports.GradientBackground = GradientBackground;
|
|
12940
13022
|
exports.GradientHeading = GradientHeading;
|
|
@@ -13172,7 +13254,6 @@ exports.toggleVariants = toggleVariants;
|
|
|
13172
13254
|
exports.useAppShell = useAppShell;
|
|
13173
13255
|
exports.useCommandBar = useCommandBar;
|
|
13174
13256
|
exports.useCommandPalette = useCommandPalette;
|
|
13175
|
-
exports.useFormField = useFormField;
|
|
13176
13257
|
exports.useHotkeys = useHotkeys;
|
|
13177
13258
|
exports.useLayoutId = useLayoutId;
|
|
13178
13259
|
exports.useSidebar = useSidebar;
|