@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.
Files changed (115) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +28 -41
  3. package/dist/index.js +206 -125
  4. package/dist/index.mjs +194 -124
  5. package/package.json +5 -4
  6. package/src/advanced/BulkActions/BulkActions.tsx +2 -2
  7. package/src/advanced/CommandBar/CommandBar.tsx +2 -2
  8. package/src/advanced/Filters/Filters.tsx +6 -6
  9. package/src/advanced/Kanban/Kanban.tsx +1 -1
  10. package/src/advanced/ToggleButton/ToggleButton.tsx +1 -1
  11. package/src/advanced/bulk-actions.tsx +1 -46
  12. package/src/advanced/command-bar.tsx +1 -115
  13. package/src/advanced/filters.tsx +1 -103
  14. package/src/advanced/kanban.tsx +1 -95
  15. package/src/advanced/toggle-button.tsx +1 -78
  16. package/src/blocks/ChatDetail/ChatDetail.tsx +4 -4
  17. package/src/blocks/FeedbackModal/FeedbackModal.tsx +3 -3
  18. package/src/blocks/FileCards/FileCards.tsx +2 -2
  19. package/src/blocks/FilesList/FilesList.tsx +3 -3
  20. package/src/blocks/IntegrationCard/IntegrationCard.tsx +3 -3
  21. package/src/blocks/InviteModal/InviteModal.tsx +7 -7
  22. package/src/blocks/ManageTagsModal/ManageTagsModal.tsx +4 -4
  23. package/src/blocks/MessagesCard/MessagesCard.tsx +3 -3
  24. package/src/blocks/MetricCard/MetricCard.tsx +3 -3
  25. package/src/blocks/NotificationSettings/NotificationSettings.tsx +4 -4
  26. package/src/blocks/OrganizationMenu/OrganizationMenu.tsx +30 -11
  27. package/src/blocks/RolesMenu/RolesMenu.tsx +4 -4
  28. package/src/blocks/SelectUsersModal/SelectUsersModal.tsx +5 -5
  29. package/src/blocks/SidebarLayoutDashboard/SidebarLayoutDashboard.tsx +5 -5
  30. package/src/blocks/SidebarLayoutGroups/SidebarLayoutGroups.tsx +2 -2
  31. package/src/blocks/SidebarLayoutMinimal/SidebarLayoutMinimal.tsx +3 -3
  32. package/src/blocks/SidebarLayoutSearch/SidebarLayoutSearch.tsx +3 -3
  33. package/src/blocks/SidebarLayoutUser/SidebarLayoutUser.tsx +4 -4
  34. package/src/blocks/SortableTaskList/SortableTaskList.tsx +3 -3
  35. package/src/blocks/StackedLayoutBranded/StackedLayoutBranded.tsx +4 -4
  36. package/src/blocks/StackedLayoutTabs/StackedLayoutTabs.tsx +4 -4
  37. package/src/blocks/TaskCard/TaskCard.tsx +4 -4
  38. package/src/blocks/UserMenu/UserMenu.tsx +3 -3
  39. package/src/blocks/WorkspaceMembers/WorkspaceMembers.tsx +5 -5
  40. package/src/blocks/chat-detail.tsx +1 -73
  41. package/src/blocks/feedback-modal.tsx +1 -68
  42. package/src/blocks/file-cards.tsx +1 -56
  43. package/src/blocks/files-list.tsx +1 -72
  44. package/src/blocks/integration-card.tsx +1 -50
  45. package/src/blocks/invite-modal.tsx +1 -69
  46. package/src/blocks/manage-tags-modal.tsx +1 -63
  47. package/src/blocks/messages-card.tsx +1 -59
  48. package/src/blocks/metric-card.tsx +1 -79
  49. package/src/blocks/notification-settings.tsx +1 -61
  50. package/src/blocks/organization-menu.tsx +1 -85
  51. package/src/blocks/roles-menu.tsx +1 -61
  52. package/src/blocks/select-users-modal.tsx +1 -64
  53. package/src/blocks/sidebar-layout-dashboard.tsx +1 -97
  54. package/src/blocks/sidebar-layout-groups.tsx +1 -79
  55. package/src/blocks/sidebar-layout-minimal.tsx +1 -73
  56. package/src/blocks/sidebar-layout-search.tsx +1 -79
  57. package/src/blocks/sidebar-layout-user.tsx +1 -82
  58. package/src/blocks/sortable-task-list.tsx +1 -70
  59. package/src/blocks/stacked-layout-branded.tsx +1 -64
  60. package/src/blocks/stacked-layout-tabs.tsx +1 -80
  61. package/src/blocks/task-card.tsx +1 -88
  62. package/src/blocks/user-menu.tsx +1 -62
  63. package/src/blocks/workspace-members.tsx +1 -61
  64. package/src/charts/sparkline.tsx +1 -1
  65. package/src/components/DataGrid/DataGrid.tsx +1 -1
  66. package/src/components/DataTable/DataTable.tsx +4 -4
  67. package/src/components/EmptyState/EmptyState.tsx +6 -22
  68. package/src/components/Persona/Persona.tsx +1 -1
  69. package/src/components/Stat/Stat.tsx +1 -1
  70. package/src/components/Stepper/Stepper.tsx +13 -2
  71. package/src/components/banner.tsx +1 -203
  72. package/src/components/breadcrumb.tsx +1 -58
  73. package/src/components/command-item.tsx +1 -36
  74. package/src/components/data-grid.tsx +1 -125
  75. package/src/components/data-table.tsx +1 -139
  76. package/src/components/empty-state.tsx +1 -31
  77. package/src/components/hotkeys.tsx +1 -31
  78. package/src/components/icon-badge.tsx +1 -35
  79. package/src/components/loading-overlay.tsx +1 -38
  80. package/src/components/persona.tsx +1 -38
  81. package/src/components/property-list.tsx +1 -29
  82. package/src/components/stat.tsx +1 -51
  83. package/src/components/stepper.tsx +1 -69
  84. package/src/components/structured-list.tsx +1 -51
  85. package/src/components/timeline.tsx +1 -69
  86. package/src/components/toaster.tsx +1 -42
  87. package/src/data/DataList.tsx +1 -1
  88. package/src/engagement/Tour/Tour.tsx +1 -1
  89. package/src/engagement/beacon.tsx +1 -50
  90. package/src/engagement/tour.tsx +1 -106
  91. package/src/forms/ArrayField/ArrayField.tsx +2 -2
  92. package/src/forms/AutoForm/AutoForm.tsx +9 -8
  93. package/src/forms/DatePicker/DatePicker.tsx +3 -3
  94. package/src/forms/FloatingLabelInput/FloatingLabelInput.tsx +104 -0
  95. package/src/forms/FloatingLabelInput/index.ts +1 -0
  96. package/src/forms/PasswordInput/PasswordInput.tsx +2 -2
  97. package/src/forms/SearchInput/SearchInput.tsx +2 -2
  98. package/src/forms/StepForm/StepForm.tsx +2 -2
  99. package/src/forms/array-field.tsx +1 -61
  100. package/src/forms/auto-form.tsx +1 -133
  101. package/src/forms/date-picker.tsx +1 -109
  102. package/src/forms/field.tsx +1 -62
  103. package/src/forms/file-upload.tsx +1 -101
  104. package/src/forms/floating-label-input.tsx +1 -0
  105. package/src/forms/form.tsx +1 -57
  106. package/src/forms/object-field.tsx +1 -53
  107. package/src/forms/password-input.tsx +1 -54
  108. package/src/forms/search-input.tsx +1 -64
  109. package/src/forms/step-form.tsx +1 -113
  110. package/src/index.ts +6 -3
  111. package/src/primitives/Button/Button.tsx +18 -0
  112. package/src/primitives/code-block.tsx +1 -1
  113. package/src/primitives/comparison.tsx +1 -1
  114. package/src/primitives/qr-code.tsx +5 -1
  115. package/src/themes/base.css +18 -0
package/dist/index.mjs CHANGED
@@ -21,10 +21,9 @@ import * as DialogPrimitive from '@radix-ui/react-dialog';
21
21
  import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
22
22
  import { Drawer as Drawer$1 } from 'vaul';
23
23
  import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
24
- import { useFormContext, useForm } from 'react-hook-form';
25
- import * as LabelPrimitive from '@radix-ui/react-label';
26
24
  import * as HoverCardPrimitive from '@radix-ui/react-hover-card';
27
25
  import { OTPInput, OTPInputContext } from 'input-otp';
26
+ import * as LabelPrimitive from '@radix-ui/react-label';
28
27
  import * as MenubarPrimitive from '@radix-ui/react-menubar';
29
28
  import * as NavigationMenuPrimitive from '@radix-ui/react-navigation-menu';
30
29
  import * as PopoverPrimitive from '@radix-ui/react-popover';
@@ -56,6 +55,8 @@ import { Table as Table$1 } from '@tiptap/extension-table';
56
55
  import { TableRow as TableRow$1 } from '@tiptap/extension-table-row';
57
56
  import { TableCell as TableCell$1 } from '@tiptap/extension-table-cell';
58
57
  import { TableHeader as TableHeader$1 } from '@tiptap/extension-table-header';
58
+ import { useForm, Controller, useFormContext } from 'react-hook-form';
59
+ export { FormProvider as Form } from 'react-hook-form';
59
60
  import { zodResolver } from '@hookform/resolvers/zod';
60
61
  import * as z from 'zod';
61
62
  import { HexAlphaColorPicker, HexColorPicker, RgbStringColorPicker, HslStringColorPicker } from 'react-colorful';
@@ -1580,104 +1581,6 @@ var DropdownMenuSubContent = React131__default.forwardRef(({ className, ...props
1580
1581
  DropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;
1581
1582
  var DropdownMenuShortcut = ({ className, ...props }) => /* @__PURE__ */ jsx("span", { className: cn("ml-auto text-xs tracking-widest opacity-60", className), ...props });
1582
1583
  DropdownMenuShortcut.displayName = "DropdownMenuShortcut";
1583
- var labelVariants = cva(
1584
- "text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
1585
- );
1586
- var Label3 = React131.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
1587
- LabelPrimitive.Root,
1588
- {
1589
- ref,
1590
- className: cn(labelVariants(), className),
1591
- ...props
1592
- }
1593
- ));
1594
- Label3.displayName = LabelPrimitive.Root.displayName;
1595
- var FormFieldContext = React131.createContext(null);
1596
- var useFormField = () => {
1597
- const fieldContext = React131.useContext(FormFieldContext);
1598
- const itemContext = React131.useContext(FormItemContext);
1599
- const { getFieldState, formState } = useFormContext();
1600
- if (!fieldContext) {
1601
- throw new Error("useFormField should be used within <FormField>");
1602
- }
1603
- if (!itemContext) {
1604
- throw new Error("useFormField should be used within <FormItem>");
1605
- }
1606
- const fieldState = getFieldState(fieldContext.name, formState);
1607
- const { id } = itemContext;
1608
- return {
1609
- id,
1610
- name: fieldContext.name,
1611
- formItemId: `${id}-form-item`,
1612
- formDescriptionId: `${id}-form-item-description`,
1613
- formMessageId: `${id}-form-item-message`,
1614
- ...fieldState
1615
- };
1616
- };
1617
- var FormItemContext = React131.createContext(null);
1618
- var FormItem = React131.forwardRef(({ className, ...props }, ref) => {
1619
- const id = React131.useId();
1620
- return /* @__PURE__ */ jsx(FormItemContext.Provider, { value: { id }, children: /* @__PURE__ */ jsx("div", { ref, className: cn("space-y-2", className), ...props }) });
1621
- });
1622
- FormItem.displayName = "FormItem";
1623
- var FormLabel = React131.forwardRef(({ className, ...props }, ref) => {
1624
- const { error, formItemId } = useFormField();
1625
- return /* @__PURE__ */ jsx(
1626
- Label3,
1627
- {
1628
- ref,
1629
- className: cn(error && "text-destructive", className),
1630
- htmlFor: formItemId,
1631
- ...props
1632
- }
1633
- );
1634
- });
1635
- FormLabel.displayName = "FormLabel";
1636
- var FormControl = React131.forwardRef(({ ...props }, ref) => {
1637
- const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
1638
- return /* @__PURE__ */ jsx(
1639
- Slot,
1640
- {
1641
- ref,
1642
- id: formItemId,
1643
- "aria-describedby": !error ? `${formDescriptionId}` : `${formDescriptionId} ${formMessageId}`,
1644
- "aria-invalid": !!error,
1645
- ...props
1646
- }
1647
- );
1648
- });
1649
- FormControl.displayName = "FormControl";
1650
- var FormDescription = React131.forwardRef(({ className, ...props }, ref) => {
1651
- const { formDescriptionId } = useFormField();
1652
- return /* @__PURE__ */ jsx(
1653
- "p",
1654
- {
1655
- ref,
1656
- id: formDescriptionId,
1657
- className: cn("text-[0.8rem] text-muted-foreground", className),
1658
- ...props
1659
- }
1660
- );
1661
- });
1662
- FormDescription.displayName = "FormDescription";
1663
- var FormMessage = React131.forwardRef(({ className, children, ...props }, ref) => {
1664
- const { error, formMessageId } = useFormField();
1665
- const body = error ? String(error?.message ?? "") : children;
1666
- if (!body) {
1667
- return null;
1668
- }
1669
- return /* @__PURE__ */ jsx(
1670
- "p",
1671
- {
1672
- ref,
1673
- id: formMessageId,
1674
- className: cn("text-[0.8rem] font-medium text-destructive", className),
1675
- ...props,
1676
- children: body
1677
- }
1678
- );
1679
- });
1680
- FormMessage.displayName = "FormMessage";
1681
1584
  var HoverCard = HoverCardPrimitive.Root;
1682
1585
  var HoverCardTrigger = HoverCardPrimitive.Trigger;
1683
1586
  var HoverCardContent = React131.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ jsx(
@@ -1751,6 +1654,18 @@ var Input = React131__default.forwardRef(
1751
1654
  )
1752
1655
  );
1753
1656
  Input.displayName = "Input";
1657
+ var labelVariants = cva(
1658
+ "text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
1659
+ );
1660
+ var Label3 = React131.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
1661
+ LabelPrimitive.Root,
1662
+ {
1663
+ ref,
1664
+ className: cn(labelVariants(), className),
1665
+ ...props
1666
+ }
1667
+ ));
1668
+ Label3.displayName = LabelPrimitive.Root.displayName;
1754
1669
  var LogoCarousel = React131__default.forwardRef(
1755
1670
  ({
1756
1671
  className,
@@ -3162,6 +3077,27 @@ function Breadcrumb({ children, className }) {
3162
3077
  });
3163
3078
  return /* @__PURE__ */ jsx("nav", { "aria-label": "breadcrumb", children: /* @__PURE__ */ jsx("ol", { className: cn("flex flex-wrap items-center gap-1", className), children: withSeparators }) });
3164
3079
  }
3080
+ function CommandItem2({ icon, label, description, shortcut, active, onClick, className }) {
3081
+ return /* @__PURE__ */ jsxs(
3082
+ "div",
3083
+ {
3084
+ onClick,
3085
+ className: cn(
3086
+ "flex items-center gap-3 rounded-md px-3 py-2 cursor-pointer transition-colors",
3087
+ active ? "bg-[hsl(var(--accent))] text-[hsl(var(--accent-foreground))]" : "hover:bg-[hsl(var(--accent)/0.6)]",
3088
+ className
3089
+ ),
3090
+ children: [
3091
+ icon && /* @__PURE__ */ jsx("span", { className: "shrink-0 text-[hsl(var(--muted-foreground))] h-4 w-4 flex items-center justify-center", children: icon }),
3092
+ /* @__PURE__ */ jsxs("div", { className: "min-w-0 flex-1", children: [
3093
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-medium truncate", children: label }),
3094
+ description && /* @__PURE__ */ jsx("p", { className: "text-xs text-[hsl(var(--muted-foreground))] truncate", children: description })
3095
+ ] }),
3096
+ shortcut && /* @__PURE__ */ 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 })
3097
+ ]
3098
+ }
3099
+ );
3100
+ }
3165
3101
  function EditableCell({ value: initial, onSave }) {
3166
3102
  const [editing, setEditing] = React131__default.useState(false);
3167
3103
  const [val, setVal] = React131__default.useState(String(initial ?? ""));
@@ -3317,14 +3253,53 @@ var EmptyStateIcon = React131__default.forwardRef(
3317
3253
  ({ className, ...props }, ref) => /* @__PURE__ */ 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 })
3318
3254
  );
3319
3255
  EmptyStateIcon.displayName = "EmptyStateIcon";
3320
- function EmptyState({ icon, title, description, action, className }) {
3321
- return /* @__PURE__ */ jsxs("div", { className: cn("flex flex-col items-center justify-center gap-3 py-12 text-center", className), children: [
3322
- icon && /* @__PURE__ */ jsx(EmptyStateIcon, { children: icon }),
3323
- /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
3324
- /* @__PURE__ */ jsx("h3", { className: "font-semibold text-[hsl(var(--foreground))]", children: title }),
3325
- description && /* @__PURE__ */ jsx("p", { className: "text-sm text-[hsl(var(--muted-foreground))]", children: description })
3256
+ var sizeMap = {
3257
+ sm: "py-8 gap-2",
3258
+ default: "py-12 gap-3",
3259
+ lg: "py-20 gap-4"
3260
+ };
3261
+ var titleSizeMap = {
3262
+ sm: "text-sm font-semibold",
3263
+ default: "text-base font-semibold",
3264
+ lg: "text-lg font-semibold"
3265
+ };
3266
+ var descSizeMap = {
3267
+ sm: "text-xs",
3268
+ default: "text-sm",
3269
+ lg: "text-base"
3270
+ };
3271
+ var iconSizeMap = {
3272
+ sm: "h-10 w-10",
3273
+ default: "h-12 w-12",
3274
+ lg: "h-16 w-16"
3275
+ };
3276
+ function EmptyState({
3277
+ icon,
3278
+ title,
3279
+ description,
3280
+ action,
3281
+ secondaryAction,
3282
+ size = "default",
3283
+ className
3284
+ }) {
3285
+ return /* @__PURE__ */ jsxs("div", { className: cn("flex flex-col items-center justify-center text-center", sizeMap[size], className), children: [
3286
+ icon && /* @__PURE__ */ jsx(EmptyStateIcon, { className: iconSizeMap[size], children: icon }),
3287
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1 max-w-sm", children: [
3288
+ /* @__PURE__ */ jsx("h3", { className: cn(titleSizeMap[size], "text-[hsl(var(--foreground))]"), children: title }),
3289
+ description && /* @__PURE__ */ jsx("p", { className: cn(descSizeMap[size], "text-[hsl(var(--muted-foreground))]"), children: description })
3326
3290
  ] }),
3327
- action && /* @__PURE__ */ jsx(Button, { onClick: action.onClick, className: "mt-1", children: action.label })
3291
+ (action || secondaryAction) && /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 mt-1", children: [
3292
+ action && /* @__PURE__ */ jsx(Button, { size: size === "sm" ? "sm" : "default", onClick: action.onClick, children: action.label }),
3293
+ secondaryAction && /* @__PURE__ */ jsx(
3294
+ Button,
3295
+ {
3296
+ variant: "outline",
3297
+ size: size === "sm" ? "sm" : "default",
3298
+ onClick: secondaryAction.onClick,
3299
+ children: secondaryAction.label
3300
+ }
3301
+ )
3302
+ ] })
3328
3303
  ] });
3329
3304
  }
3330
3305
  function HotkeyBadge({ children, className }) {
@@ -3344,13 +3319,13 @@ var colorMap = {
3344
3319
  error: "bg-red-100 text-red-700 dark:bg-red-900/30 dark:text-red-400",
3345
3320
  purple: "bg-purple-100 text-purple-700 dark:bg-purple-900/30 dark:text-purple-400"
3346
3321
  };
3347
- var sizeMap = {
3322
+ var sizeMap2 = {
3348
3323
  sm: "h-7 w-7 [&>*]:h-3.5 [&>*]:w-3.5",
3349
3324
  md: "h-10 w-10 [&>*]:h-5 [&>*]:w-5",
3350
3325
  lg: "h-14 w-14 [&>*]:h-7 [&>*]:w-7"
3351
3326
  };
3352
3327
  function IconBadge({ icon, color = "default", size = "md", className }) {
3353
- return /* @__PURE__ */ jsx("div", { className: cn("inline-flex items-center justify-center rounded-full shrink-0", colorMap[color], sizeMap[size], className), children: icon });
3328
+ return /* @__PURE__ */ jsx("div", { className: cn("inline-flex items-center justify-center rounded-full shrink-0", colorMap[color], sizeMap2[size], className), children: icon });
3354
3329
  }
3355
3330
  function LoadingOverlay({ loading, text, fullPage, children, className }) {
3356
3331
  if (fullPage) {
@@ -3367,13 +3342,13 @@ function LoadingOverlay({ loading, text, fullPage, children, className }) {
3367
3342
  ] }) })
3368
3343
  ] });
3369
3344
  }
3370
- var sizeMap2 = {
3345
+ var sizeMap3 = {
3371
3346
  sm: { avatar: "h-7 w-7", name: "text-sm", subtitle: "text-xs" },
3372
3347
  md: { avatar: "h-9 w-9", name: "text-sm font-medium", subtitle: "text-xs" },
3373
3348
  lg: { avatar: "h-12 w-12", name: "text-base font-medium", subtitle: "text-sm" }
3374
3349
  };
3375
3350
  function Persona({ name, subtitle, src, size = "md", badge, className }) {
3376
- const s = sizeMap2[size];
3351
+ const s = sizeMap3[size];
3377
3352
  const initials = name.split(" ").map((w) => w[0]).slice(0, 2).join("").toUpperCase();
3378
3353
  return /* @__PURE__ */ jsxs("div", { className: cn("flex items-center gap-2.5", className), children: [
3379
3354
  /* @__PURE__ */ jsxs("div", { className: "relative shrink-0", children: [
@@ -3774,7 +3749,7 @@ function InviteModal({ className }) {
3774
3749
  pending.length > 0 && /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
3775
3750
  /* @__PURE__ */ jsx("p", { className: "text-xs font-medium text-[hsl(var(--muted-foreground))]", children: "Pending invites" }),
3776
3751
  /* @__PURE__ */ jsx("div", { className: "divide-y divide-[hsl(var(--border))] rounded-md border border-[hsl(var(--border))]", children: pending.map((p, i) => /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 px-3 py-2", children: [
3777
- /* @__PURE__ */ jsx(Avatar, { className: "h-6 w-6", children: /* @__PURE__ */ jsx(AvatarFallback, { className: "text-[10px]", children: p.email[0].toUpperCase() }) }),
3752
+ /* @__PURE__ */ jsx(Avatar, { className: "h-6 w-6", children: /* @__PURE__ */ jsx(AvatarFallback, { className: "text-[10px]", children: p.email.charAt(0).toUpperCase() }) }),
3778
3753
  /* @__PURE__ */ jsx("span", { className: "flex-1 text-sm truncate", children: p.email }),
3779
3754
  /* @__PURE__ */ jsx(Badge, { variant: "outline", className: "text-[10px] px-1.5 py-0.5 shrink-0", children: p.role }),
3780
3755
  /* @__PURE__ */ jsx("button", { onClick: () => setPending((ps) => ps.filter((_, j) => j !== i)), children: /* @__PURE__ */ jsx(X, { className: "h-3.5 w-3.5 text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))]" }) })
@@ -4467,7 +4442,7 @@ function NotificationSettings({ className }) {
4467
4442
  NotifRow,
4468
4443
  {
4469
4444
  ...n,
4470
- checked: states[n.id],
4445
+ checked: states[n.id] ?? false,
4471
4446
  onChange: (val) => setStates((s) => ({ ...s, [n.id]: val }))
4472
4447
  },
4473
4448
  n.id
@@ -4669,7 +4644,7 @@ var ROLES = [
4669
4644
  ];
4670
4645
  function RolesMenu({ value = "member", onChange, className }) {
4671
4646
  const [role, setRole] = useState(value);
4672
- const current = ROLES.find((r) => r.value === role) ?? ROLES[2];
4647
+ const current = ROLES.find((r) => r.value === role) ?? ROLES[0];
4673
4648
  const handleChange = (v) => {
4674
4649
  setRole(v);
4675
4650
  onChange?.(v);
@@ -7014,7 +6989,7 @@ function Sparkline({
7014
6989
  const max = Math.max(...data);
7015
6990
  const range = max - min || 1;
7016
6991
  const pad = 2;
7017
- const lastY = pad + (1 - (data[data.length - 1] - min) / range) * (height - pad * 2);
6992
+ const lastY = pad + (1 - ((data.at(-1) ?? 0) - min) / range) * (height - pad * 2);
7018
6993
  const areaPath = type === "area" ? `${path} L ${width - pad},${height - pad} L ${pad},${height - pad} Z` : void 0;
7019
6994
  return /* @__PURE__ */ jsxs(
7020
6995
  "svg",
@@ -7038,7 +7013,7 @@ var colorMap2 = {
7038
7013
  warning: "bg-yellow-500",
7039
7014
  error: "bg-red-500"
7040
7015
  };
7041
- var sizeMap3 = {
7016
+ var sizeMap4 = {
7042
7017
  sm: "h-1.5 w-1.5",
7043
7018
  md: "h-2.5 w-2.5",
7044
7019
  lg: "h-3.5 w-3.5"
@@ -7046,7 +7021,7 @@ var sizeMap3 = {
7046
7021
  function BeaconDot({ color = "primary", size = "md" }) {
7047
7022
  return /* @__PURE__ */ jsxs("span", { className: "relative flex", children: [
7048
7023
  /* @__PURE__ */ jsx("span", { className: cn("animate-ping absolute inline-flex h-full w-full rounded-full opacity-75", colorMap2[color]) }),
7049
- /* @__PURE__ */ jsx("span", { className: cn("relative inline-flex rounded-full", sizeMap3[size], colorMap2[color]) })
7024
+ /* @__PURE__ */ jsx("span", { className: cn("relative inline-flex rounded-full", sizeMap4[size], colorMap2[color]) })
7050
7025
  ] });
7051
7026
  }
7052
7027
  function Beacon({ color = "primary", size = "md", children, className }) {
@@ -7666,6 +7641,7 @@ function FieldRenderer({ name, field, register, setValue, watch, error }) {
7666
7641
  }
7667
7642
  function AutoForm({ schema, onSubmit, defaultValues, submitLabel = "Submit" }) {
7668
7643
  const { register, handleSubmit, setValue, watch, formState } = useForm({
7644
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
7669
7645
  resolver: zodResolver(schema),
7670
7646
  defaultValues
7671
7647
  });
@@ -7969,7 +7945,91 @@ function FileUploadPreview({ files, onRemove, className }) {
7969
7945
  ] })
7970
7946
  ] }, i)) });
7971
7947
  }
7972
- var FormLabel2 = React131__default.forwardRef(
7948
+ var FloatingLabelInput = React131__default.forwardRef(
7949
+ ({ label, error, hint, wrapperClassName, className, id, value, defaultValue, onFocus, onBlur, onChange, ...props }, ref) => {
7950
+ const autoId = useId();
7951
+ const inputId = id ?? autoId;
7952
+ const errorId = error ? `${inputId}-error` : void 0;
7953
+ const hintId = hint ? `${inputId}-hint` : void 0;
7954
+ const describedBy = [errorId, hintId].filter(Boolean).join(" ") || void 0;
7955
+ const [focused, setFocused] = useState(false);
7956
+ const [filled, setFilled] = useState(() => {
7957
+ if (value !== void 0 && value !== null && value !== "") return true;
7958
+ if (defaultValue !== void 0 && defaultValue !== null && defaultValue !== "") return true;
7959
+ return false;
7960
+ });
7961
+ const isFloated = focused || filled;
7962
+ return /* @__PURE__ */ jsxs("div", { "data-slot": "floating-label-input", className: cn("flex flex-col gap-1.5", wrapperClassName), children: [
7963
+ /* @__PURE__ */ jsxs("div", { className: "relative", children: [
7964
+ /* @__PURE__ */ jsx(
7965
+ "input",
7966
+ {
7967
+ ref,
7968
+ id: inputId,
7969
+ value,
7970
+ defaultValue,
7971
+ "data-slot": "input",
7972
+ "data-state": isFloated ? "floated" : "rest",
7973
+ "aria-invalid": Boolean(error) || void 0,
7974
+ "aria-describedby": describedBy,
7975
+ onFocus: (e) => {
7976
+ setFocused(true);
7977
+ onFocus?.(e);
7978
+ },
7979
+ onBlur: (e) => {
7980
+ setFocused(false);
7981
+ onBlur?.(e);
7982
+ },
7983
+ onChange: (e) => {
7984
+ setFilled(e.target.value.length > 0);
7985
+ onChange?.(e);
7986
+ },
7987
+ className: cn(
7988
+ // Reset + structure
7989
+ "peer w-full appearance-none bg-transparent",
7990
+ "h-14 rounded-md border px-3 pt-5 pb-1.5",
7991
+ "text-base text-foreground leading-tight",
7992
+ // Border / focus ring colors
7993
+ "border-input focus:border-ring focus:outline-none focus:ring-2 focus:ring-ring/30",
7994
+ error && "border-destructive focus:border-destructive focus:ring-destructive/30",
7995
+ "disabled:cursor-not-allowed disabled:opacity-50",
7996
+ "placeholder:text-transparent",
7997
+ // hide native placeholder; label takes its job
7998
+ className
7999
+ ),
8000
+ ...props
8001
+ }
8002
+ ),
8003
+ /* @__PURE__ */ jsx(
8004
+ "label",
8005
+ {
8006
+ htmlFor: inputId,
8007
+ className: cn(
8008
+ "pointer-events-none absolute left-3",
8009
+ "origin-[0_50%] transition-all duration-150 ease-out",
8010
+ "text-muted-foreground",
8011
+ // Rest: centered vertically inside the field, full size
8012
+ !isFloated && "top-1/2 -translate-y-1/2 text-base",
8013
+ // Floated: tucked into the top with a small subtle background
8014
+ isFloated && "top-1.5 text-[11px] uppercase tracking-wider text-foreground/85",
8015
+ error && "text-destructive"
8016
+ ),
8017
+ children: label
8018
+ }
8019
+ )
8020
+ ] }),
8021
+ error ? /* @__PURE__ */ jsx("p", { id: errorId, className: "text-xs text-destructive", children: error }) : hint ? /* @__PURE__ */ jsx("p", { id: hintId, className: "text-xs text-muted-foreground", children: hint }) : null
8022
+ ] });
8023
+ }
8024
+ );
8025
+ FloatingLabelInput.displayName = "FloatingLabelInput";
8026
+ function FormField(props) {
8027
+ return /* @__PURE__ */ jsx(Controller, { ...props });
8028
+ }
8029
+ function FormItem({ className, ...props }) {
8030
+ return /* @__PURE__ */ jsx("div", { className: cn("flex flex-col gap-1.5", className), ...props });
8031
+ }
8032
+ var FormLabel = React131__default.forwardRef(
7973
8033
  ({ className, error, ...props }, ref) => /* @__PURE__ */ jsx(
7974
8034
  "label",
7975
8035
  {
@@ -7983,14 +8043,24 @@ var FormLabel2 = React131__default.forwardRef(
7983
8043
  }
7984
8044
  )
7985
8045
  );
7986
- FormLabel2.displayName = "FormLabel";
7987
- var FormControl2 = React131__default.forwardRef(
8046
+ FormLabel.displayName = "FormLabel";
8047
+ var FormControl = React131__default.forwardRef(
7988
8048
  ({ ...props }, ref) => {
7989
8049
  const id = useId();
7990
8050
  return /* @__PURE__ */ jsx("div", { ref, id, ...props });
7991
8051
  }
7992
8052
  );
7993
- FormControl2.displayName = "FormControl";
8053
+ FormControl.displayName = "FormControl";
8054
+ function FormDescription({ className, ...props }) {
8055
+ return /* @__PURE__ */ jsx("p", { className: cn("text-xs text-[hsl(var(--muted-foreground))]", className), ...props });
8056
+ }
8057
+ function FormMessage({ className, children, name }) {
8058
+ const { formState } = useFormContext();
8059
+ const error = name ? formState.errors[name] : void 0;
8060
+ const message = error?.message ? String(error.message) : children;
8061
+ if (!message) return null;
8062
+ return /* @__PURE__ */ jsx("p", { className: cn("text-xs text-[hsl(var(--destructive))]", className), children: message });
8063
+ }
7994
8064
  function ObjectField({
7995
8065
  title,
7996
8066
  description,
@@ -8473,7 +8543,7 @@ var MobileSidebarTrigger = React131__default.forwardRef(
8473
8543
  }
8474
8544
  );
8475
8545
  MobileSidebarTrigger.displayName = "MobileSidebarTrigger";
8476
- var sizeMap4 = {
8546
+ var sizeMap5 = {
8477
8547
  sm: "max-w-screen-sm",
8478
8548
  md: "max-w-screen-md",
8479
8549
  lg: "max-w-screen-lg",
@@ -8487,7 +8557,7 @@ var Container = React131__default.forwardRef(
8487
8557
  ref,
8488
8558
  className: cn(
8489
8559
  "mx-auto w-full",
8490
- sizeMap4[size],
8560
+ sizeMap5[size],
8491
8561
  !noPadding && "px-4 sm:px-6 lg:px-8",
8492
8562
  className
8493
8563
  ),
@@ -12679,6 +12749,6 @@ function SortableNav({ items, onReorder, className }) {
12679
12749
  return /* @__PURE__ */ jsx(DndContext, { sensors, collisionDetection: closestCenter, onDragEnd: handleDragEnd, children: /* @__PURE__ */ jsx(SortableContext, { items: items.map((i) => i.id), strategy: verticalListSortingStrategy, children: /* @__PURE__ */ jsx("nav", { "data-slot": "sortable-nav", className: cn("space-y-0.5 px-2 py-1", className), children: items.map((item) => /* @__PURE__ */ jsx(SortableNavItemWrapper, { item }, item.id)) }) }) });
12680
12750
  }
12681
12751
 
12682
- export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, ActivityHeatmap, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AnimatedGradient, AnimatedNumber, AppShell, AppShellMain, AppShellSidebar, AppShellUserMenu, Sidebar as AppSidebar, AreaChart, ArrayField, AspectRatio, AutoForm, Avatar, AvatarFallback, AvatarGroup, AvatarImage, Badge, Banner, BarChart, BarList, Beacon, BillingStatus, Body, Breadcrumb, BreadcrumbItem, BreadcrumbPage, BreadcrumbSeparator, BulkActions, Button, Calendar, CalendarDayButton, Caption, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, ChatDetail, Checkbox, Checklist, ChecklistItem, Code3 as Code, CodeBlock, Collapsible, CollapsibleContent2 as CollapsibleContent, CollapsibleTrigger2 as CollapsibleTrigger, ColorPicker, ColorSchemeSelect, Combobox, Command, CommandBar, CommandBarEmpty, CommandBarGroup, CommandBarItem, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandList, CommandPalette, CommandPaletteProvider, CommandSeparator, CommandShortcut, Comparison, Container, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, DEFAULT_THEME_OPTIONS, DEFAULT_TRANSITION, DataGrid, DataList, DataListItem, DataTable, DataTableColumnHeader, DataTablePagination, DataTableToolbar, DatePicker, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DottedBackground, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EmptyState, EmptyStateIcon, EventCalendar, FadeIn, FeedbackModal, Field, FieldDescription, FieldError, FieldLabel, FileCards, FileUpload, FileUploadPreview, FilesList, FilterBadge, FilterItem, Filters, FloatingActionButton, FloatingThemePicker, Gantt, GradientBackground, GradientHeading, GridList, GridListItem, HStack, Heading, Heatmap, HelpSheet, HeroShaderA, HotkeyBadge, Hotkeys, HotkeysProvider, HoverCard, HoverCardContent, HoverCardTrigger, IconBadge, ImageCrop, Input, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, IntegrationCard, IntroDisclosure, InviteModal, Kanban, KanbanCard, KanbanColumn, Label3 as Label, LineChart, LoadingOverlay, LogoCarousel, MOTION_PRESETS, ManageTagsModal, Marquee, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, MessagesCard, MetricCard, MetricCardWithButton, MetricCardWithIcon, MobileSidebarTrigger, Morph, Navbar, NavbarBrand, NavbarContent, NavbarItem, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, NoiseBackground, NotificationSettings, ObjectField, OrgMenu, Page, PageActions, PageBody, PageContainer, PageDescription, PageHeader, PageLayout, PageMain, PageTitle, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, PaletteSwatches, Parallax, PasswordInput, Persona, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, Progress, PropertyItem, PropertyList, QrCode, RadioGroup4 as RadioGroup, RadioGroupItem, Rating, ResizableHandle, ResizablePanel, ResizablePanelGroup, ResizeBox, ResizeHandle, Reveal, RichEditor, Ripple, RolesMenu, ScaleIn, ScrollArea, ScrollBar, ScrollHeader, SearchInput, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectUsersModal, SelectValue, Separator6 as Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, AppShell2 as Shell, Sidebar2 as Sidebar, SidebarContent, SidebarFooter2 as SidebarFooter, SidebarGroup, SidebarGroupLabel, SidebarHeader2 as SidebarHeader, SidebarItem2 as SidebarItem, SidebarLayoutDashboard, SidebarLayoutGroups, SidebarLayoutMinimal, SidebarLayoutSearch, SidebarLayoutUser, SidebarResizer, SidebarSeparator2 as SidebarSeparator, Skeleton, SlideIn, Slider, SortableNav, SortableTaskList, Sparkline, Spinner, SplitPage, SplitPageDetail, SplitPageList, Stack, StackedLayoutBranded, StackedLayoutTabs, Stagger, Stat, StatGroup, StepForm, StepFormNavigation, StepFormStep, Stepper, StepperStep, StructuredList, StructuredListItem, StructuredListSection, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Tags, TaskCard, TaskCardWithLabels, TextReveal, Textarea, TextureCard, TextureCardDescription, TextureCardHeader, TextureCardTitle, ThemeSwitch, Timeline, TimelineConnector, TimelineContent, TimelineItem, Toaster, Toggle, ToggleButton, ToggleButtonGroup, ToggleGroup, ToggleGroupItem, Tooltip2 as Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, Tour, TourStep, Transition, Tree, Typewriter, UserMenu, VStack, VideoPlayer, WorkspaceMembers, WorkspacesMenu, badgeVariants, buttonVariants, cn, navigationMenuTriggerStyle, toastFn as toast, toastEmitter, toggleVariants, useAppShell, useCommandBar, useCommandPalette, useFormField, useHotkeys, useLayoutId, useSidebar, useTour };
12752
+ export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, ActivityHeatmap, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AnimatedGradient, AnimatedNumber, AppShell, AppShellMain, AppShellSidebar, AppShellUserMenu, Sidebar as AppSidebar, AreaChart, ArrayField, AspectRatio, AutoForm, Avatar, AvatarFallback, AvatarGroup, AvatarImage, Badge, Banner, BarChart, BarList, Beacon, BillingStatus, Body, Breadcrumb, BreadcrumbItem, BreadcrumbPage, BreadcrumbSeparator, BulkActions, Button, Calendar, CalendarDayButton, Caption, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, ChatDetail, Checkbox, Checklist, ChecklistItem, Code3 as Code, CodeBlock, Collapsible, CollapsibleContent2 as CollapsibleContent, CollapsibleTrigger2 as CollapsibleTrigger, ColorPicker, ColorSchemeSelect, Combobox, Command, CommandBar, CommandBarEmpty, CommandBarGroup, CommandBarItem, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandItem2 as CommandListItem, CommandPalette, CommandPaletteProvider, CommandSeparator, CommandShortcut, Comparison, Container, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, DEFAULT_THEME_OPTIONS, DEFAULT_TRANSITION, DataGrid, DataList, DataListItem, DataTable, DataTableColumnHeader, DataTablePagination, DataTableToolbar, DatePicker, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DottedBackground, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EmptyState, EmptyStateIcon, EventCalendar, FadeIn, FeedbackModal, Field, FieldDescription, FieldError, FieldLabel, FileCards, FileUpload, FileUploadPreview, FilesList, FilterBadge, FilterItem, Filters, FloatingActionButton, FloatingLabelInput, FloatingThemePicker, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, Gantt, GradientBackground, GradientHeading, GridList, GridListItem, HStack, Heading, Heatmap, HelpSheet, HeroShaderA, HotkeyBadge, Hotkeys, HotkeysProvider, HoverCard, HoverCardContent, HoverCardTrigger, IconBadge, ImageCrop, Input, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, IntegrationCard, IntroDisclosure, InviteModal, Kanban, KanbanCard, KanbanColumn, Label3 as Label, LineChart, LoadingOverlay, LogoCarousel, MOTION_PRESETS, ManageTagsModal, Marquee, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, MessagesCard, MetricCard, MetricCardWithButton, MetricCardWithIcon, MobileSidebarTrigger, Morph, Navbar, NavbarBrand, NavbarContent, NavbarItem, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, NoiseBackground, NotificationSettings, ObjectField, OrgMenu, Page, PageActions, PageBody, PageContainer, PageDescription, PageHeader, PageLayout, PageMain, PageTitle, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, PaletteSwatches, Parallax, PasswordInput, Persona, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, Progress, PropertyItem, PropertyList, QrCode, RadioGroup4 as RadioGroup, RadioGroupItem, Rating, ResizableHandle, ResizablePanel, ResizablePanelGroup, ResizeBox, ResizeHandle, Reveal, RichEditor, Ripple, RolesMenu, ScaleIn, ScrollArea, ScrollBar, ScrollHeader, SearchInput, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectUsersModal, SelectValue, Separator6 as Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, AppShell2 as Shell, Sidebar2 as Sidebar, SidebarContent, SidebarFooter2 as SidebarFooter, SidebarGroup, SidebarGroupLabel, SidebarHeader2 as SidebarHeader, SidebarItem2 as SidebarItem, SidebarLayoutDashboard, SidebarLayoutGroups, SidebarLayoutMinimal, SidebarLayoutSearch, SidebarLayoutUser, SidebarResizer, SidebarSeparator2 as SidebarSeparator, Skeleton, SlideIn, Slider, SortableNav, SortableTaskList, Sparkline, Spinner, SplitPage, SplitPageDetail, SplitPageList, Stack, StackedLayoutBranded, StackedLayoutTabs, Stagger, Stat, StatGroup, StepForm, StepFormNavigation, StepFormStep, Stepper, StepperStep, StructuredList, StructuredListItem, StructuredListSection, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Tags, TaskCard, TaskCardWithLabels, TextReveal, Textarea, TextureCard, TextureCardDescription, TextureCardHeader, TextureCardTitle, ThemeSwitch, Timeline, TimelineConnector, TimelineContent, TimelineItem, Toaster, Toggle, ToggleButton, ToggleButtonGroup, ToggleGroup, ToggleGroupItem, Tooltip2 as Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, Tour, TourStep, Transition, Tree, Typewriter, UserMenu, VStack, VideoPlayer, WorkspaceMembers, WorkspacesMenu, badgeVariants, buttonVariants, cn, navigationMenuTriggerStyle, toastFn as toast, toastEmitter, toggleVariants, useAppShell, useCommandBar, useCommandPalette, useHotkeys, useLayoutId, useSidebar, useTour };
12683
12753
  //# sourceMappingURL=index.mjs.map
12684
12754
  //# sourceMappingURL=index.mjs.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@otfdashkit/ui",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "OTF UI — production-quality React component library. 98 primitives + blocks + layouts + charts on Radix + Tailwind v4. Cross-platform parity API with @otfdashkit/ui-native.",
5
5
  "keywords": [
6
6
  "otfdashkit",
@@ -17,16 +17,17 @@
17
17
  "accessible"
18
18
  ],
19
19
  "license": "MIT",
20
- "author": "otfdashkit <dave@otf-kit.dev>",
21
- "homepage": "https://github.com/otf-kit/sdk/tree/main/packages/ui#readme",
20
+ "author": "otf-kit <dave@otf-kit.dev>",
21
+ "homepage": "https://otf-kit.dev",
22
22
  "repository": {
23
23
  "type": "git",
24
- "url": "https://github.com/otf-kit/sdk.git",
24
+ "url": "git+https://github.com/otf-kit/sdk.git",
25
25
  "directory": "packages/ui"
26
26
  },
27
27
  "bugs": {
28
28
  "url": "https://github.com/otf-kit/sdk/issues"
29
29
  },
30
+ "funding": "https://otf-kit.dev/pricing",
30
31
  "main": "dist/index.js",
31
32
  "module": "dist/index.mjs",
32
33
  "types": "dist/index.d.ts",
@@ -1,7 +1,7 @@
1
1
  import React from 'react'
2
2
  import { X } from 'lucide-react'
3
- import { cn } from '../utils/cn'
4
- import { Button } from '../primitives/button'
3
+ import { cn } from '../../utils/cn'
4
+ import { Button } from '../../primitives/button'
5
5
 
6
6
  interface ActionDef {
7
7
  label: string
@@ -1,7 +1,7 @@
1
1
  import React from 'react'
2
2
  import { Search, X } from 'lucide-react'
3
- import { cn } from '../utils/cn'
4
- import { Dialog, DialogContent, DialogTitle } from '../primitives/dialog'
3
+ import { cn } from '../../utils/cn'
4
+ import { Dialog, DialogContent, DialogTitle } from '../../primitives/dialog'
5
5
 
6
6
  interface UseCommandBarReturn { open: boolean; setOpen: (v: boolean) => void }
7
7
 
@@ -1,10 +1,10 @@
1
1
  import React from 'react'
2
2
  import { Plus, X } from 'lucide-react'
3
- import { cn } from '../utils/cn'
4
- import { Button } from '../primitives/button'
5
- import { Popover, PopoverContent, PopoverTrigger } from '../primitives/popover'
6
- import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from '../primitives/select'
7
- import { Input } from '../primitives/input'
3
+ import { cn } from '../../utils/cn'
4
+ import { Button } from '../../primitives/button'
5
+ import { Popover, PopoverContent, PopoverTrigger } from '../../primitives/popover'
6
+ import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from '../../primitives/select'
7
+ import { Input } from '../../primitives/input'
8
8
 
9
9
  export interface FilterDef {
10
10
  key: string
@@ -33,7 +33,7 @@ function AddFilterPopover({ filters, onAdd }: { filters: FilterDef[]; onAdd: (v:
33
33
 
34
34
  const handleAdd = () => {
35
35
  if (!key || !val) return
36
- onAdd({ key, operator: op || ops[0], value: val })
36
+ onAdd({ key, operator: op || ops[0]!, value: val })
37
37
  setKey(''); setOp(''); setVal('')
38
38
  setOpen(false)
39
39
  }
@@ -2,7 +2,7 @@ import React from 'react'
2
2
  import { DndContext, DragEndEvent, DragOverEvent, DragOverlay, DragStartEvent, PointerSensor, useSensor, useSensors } from '@dnd-kit/core'
3
3
  import { SortableContext, useSortable, verticalListSortingStrategy } from '@dnd-kit/sortable'
4
4
  import { CSS } from '@dnd-kit/utilities'
5
- import { cn } from '../utils/cn'
5
+ import { cn } from '../../utils/cn'
6
6
 
7
7
  export interface KanbanCardDef { id: string; title: string; description?: string; badge?: string }
8
8
  export interface KanbanColumnDef { id: string; title: string; cards: KanbanCardDef[] }
@@ -1,5 +1,5 @@
1
1
  import React from 'react'
2
- import { cn } from '../utils/cn'
2
+ import { cn } from '../../utils/cn'
3
3
 
4
4
  interface ToggleButtonProps {
5
5
  value: string
@@ -1,46 +1 @@
1
- import React from 'react'
2
- import { X } from 'lucide-react'
3
- import { cn } from '../utils/cn'
4
- import { Button } from '../primitives/button'
5
-
6
- interface ActionDef {
7
- label: string
8
- icon?: React.ReactNode
9
- onClick: () => void
10
- variant?: 'default' | 'destructive'
11
- }
12
-
13
- interface BulkActionsProps {
14
- count: number
15
- actions: ActionDef[]
16
- onClear: () => void
17
- className?: string
18
- }
19
-
20
- export function BulkActions({ count, actions, onClear, className }: BulkActionsProps) {
21
- if (count === 0) return null
22
- return (
23
- <div className={cn('fixed bottom-6 left-1/2 -translate-x-1/2 z-50 flex items-center gap-2 rounded-full border border-[hsl(var(--border))] bg-[hsl(var(--card))] px-4 py-2 shadow-lg', className)}>
24
- <span className="text-sm font-medium text-[hsl(var(--foreground))] pr-2 border-r border-[hsl(var(--border))]">
25
- {count} selected
26
- </span>
27
- <div className="flex items-center gap-1">
28
- {actions.map((action, i) => (
29
- <Button
30
- key={i}
31
- variant={action.variant === 'destructive' ? 'destructive' : 'ghost'}
32
- size="sm"
33
- className="h-7 gap-1.5 text-xs rounded-full px-3"
34
- onClick={action.onClick}
35
- >
36
- {action.icon}
37
- {action.label}
38
- </Button>
39
- ))}
40
- </div>
41
- <button onClick={onClear} className="ml-1 rounded-full p-0.5 text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))] transition-colors">
42
- <X className="h-4 w-4" />
43
- </button>
44
- </div>
45
- )
46
- }
1
+ export * from './BulkActions'