@automa8e/ui 0.2.0
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 +21 -0
- package/README.md +2 -0
- package/dist/_virtual/index.js +6 -0
- package/dist/_virtual/index.js.map +1 -0
- package/dist/_virtual/index2.js +5 -0
- package/dist/_virtual/index2.js.map +1 -0
- package/dist/_virtual/use-sync-external-store-shim.development.js +5 -0
- package/dist/_virtual/use-sync-external-store-shim.development.js.map +1 -0
- package/dist/_virtual/use-sync-external-store-shim.production.js +5 -0
- package/dist/_virtual/use-sync-external-store-shim.production.js.map +1 -0
- package/dist/automa8e-ui.css +226 -0
- package/dist/components/automation/metric-card.d.ts +19 -0
- package/dist/components/automation/metric-card.d.ts.map +1 -0
- package/dist/components/automation/metric-card.js +59 -0
- package/dist/components/automation/metric-card.js.map +1 -0
- package/dist/components/automation/status-badge.d.ts +27 -0
- package/dist/components/automation/status-badge.d.ts.map +1 -0
- package/dist/components/automation/status-badge.js +112 -0
- package/dist/components/automation/status-badge.js.map +1 -0
- package/dist/components/automation/task-card.d.ts +14 -0
- package/dist/components/automation/task-card.d.ts.map +1 -0
- package/dist/components/automation/task-card.js +114 -0
- package/dist/components/automation/task-card.js.map +1 -0
- package/dist/components/automation/workflow-node.d.ts +20 -0
- package/dist/components/automation/workflow-node.d.ts.map +1 -0
- package/dist/components/automation/workflow-node.js +132 -0
- package/dist/components/automation/workflow-node.js.map +1 -0
- package/dist/components/layout/app-shell.d.ts +21 -0
- package/dist/components/layout/app-shell.d.ts.map +1 -0
- package/dist/components/layout/app-shell.js +35 -0
- package/dist/components/layout/app-shell.js.map +1 -0
- package/dist/components/layout/header.d.ts +16 -0
- package/dist/components/layout/header.d.ts.map +1 -0
- package/dist/components/layout/header.js +30 -0
- package/dist/components/layout/header.js.map +1 -0
- package/dist/components/layout/page-header.d.ts +16 -0
- package/dist/components/layout/page-header.d.ts.map +1 -0
- package/dist/components/layout/page-header.js +29 -0
- package/dist/components/layout/page-header.js.map +1 -0
- package/dist/components/layout/sidebar.d.ts +35 -0
- package/dist/components/layout/sidebar.d.ts.map +1 -0
- package/dist/components/layout/sidebar.js +103 -0
- package/dist/components/layout/sidebar.js.map +1 -0
- package/dist/components/ui/accordion.d.ts +8 -0
- package/dist/components/ui/accordion.d.ts.map +1 -0
- package/dist/components/ui/accordion.js +51 -0
- package/dist/components/ui/accordion.js.map +1 -0
- package/dist/components/ui/alert.d.ts +18 -0
- package/dist/components/ui/alert.d.ts.map +1 -0
- package/dist/components/ui/alert.js +89 -0
- package/dist/components/ui/alert.js.map +1 -0
- package/dist/components/ui/avatar.d.ts +20 -0
- package/dist/components/ui/avatar.d.ts.map +1 -0
- package/dist/components/ui/avatar.js +72 -0
- package/dist/components/ui/avatar.js.map +1 -0
- package/dist/components/ui/badge.d.ts +13 -0
- package/dist/components/ui/badge.d.ts.map +1 -0
- package/dist/components/ui/badge.js +54 -0
- package/dist/components/ui/badge.js.map +1 -0
- package/dist/components/ui/button.d.ts +15 -0
- package/dist/components/ui/button.d.ts.map +1 -0
- package/dist/components/ui/button.js +96 -0
- package/dist/components/ui/button.js.map +1 -0
- package/dist/components/ui/card.d.ts +16 -0
- package/dist/components/ui/card.d.ts.map +1 -0
- package/dist/components/ui/card.js +96 -0
- package/dist/components/ui/card.js.map +1 -0
- package/dist/components/ui/checkbox.d.ts +9 -0
- package/dist/components/ui/checkbox.d.ts.map +1 -0
- package/dist/components/ui/checkbox.js +29 -0
- package/dist/components/ui/checkbox.js.map +1 -0
- package/dist/components/ui/dialog.d.ts +28 -0
- package/dist/components/ui/dialog.d.ts.map +1 -0
- package/dist/components/ui/dialog.js +105 -0
- package/dist/components/ui/dialog.js.map +1 -0
- package/dist/components/ui/dropdown-menu.d.ts +29 -0
- package/dist/components/ui/dropdown-menu.d.ts.map +1 -0
- package/dist/components/ui/dropdown-menu.js +160 -0
- package/dist/components/ui/dropdown-menu.js.map +1 -0
- package/dist/components/ui/input.d.ts +14 -0
- package/dist/components/ui/input.d.ts.map +1 -0
- package/dist/components/ui/input.js +60 -0
- package/dist/components/ui/input.js.map +1 -0
- package/dist/components/ui/label.d.ts +13 -0
- package/dist/components/ui/label.d.ts.map +1 -0
- package/dist/components/ui/label.js +26 -0
- package/dist/components/ui/label.js.map +1 -0
- package/dist/components/ui/popover.d.ts +8 -0
- package/dist/components/ui/popover.d.ts.map +1 -0
- package/dist/components/ui/popover.js +29 -0
- package/dist/components/ui/popover.js.map +1 -0
- package/dist/components/ui/progress.d.ts +17 -0
- package/dist/components/ui/progress.d.ts.map +1 -0
- package/dist/components/ui/progress.js +80 -0
- package/dist/components/ui/progress.js.map +1 -0
- package/dist/components/ui/scroll-area.d.ts +6 -0
- package/dist/components/ui/scroll-area.d.ts.map +1 -0
- package/dist/components/ui/scroll-area.js +39 -0
- package/dist/components/ui/scroll-area.js.map +1 -0
- package/dist/components/ui/select.d.ts +16 -0
- package/dist/components/ui/select.d.ts.map +1 -0
- package/dist/components/ui/select.js +131 -0
- package/dist/components/ui/select.js.map +1 -0
- package/dist/components/ui/separator.d.ts +9 -0
- package/dist/components/ui/separator.d.ts.map +1 -0
- package/dist/components/ui/separator.js +50 -0
- package/dist/components/ui/separator.js.map +1 -0
- package/dist/components/ui/skeleton.d.ts +10 -0
- package/dist/components/ui/skeleton.d.ts.map +1 -0
- package/dist/components/ui/skeleton.js +30 -0
- package/dist/components/ui/skeleton.js.map +1 -0
- package/dist/components/ui/spinner.d.ts +14 -0
- package/dist/components/ui/spinner.d.ts.map +1 -0
- package/dist/components/ui/spinner.js +44 -0
- package/dist/components/ui/spinner.js.map +1 -0
- package/dist/components/ui/switch.d.ts +8 -0
- package/dist/components/ui/switch.d.ts.map +1 -0
- package/dist/components/ui/switch.js +43 -0
- package/dist/components/ui/switch.js.map +1 -0
- package/dist/components/ui/table.d.ts +11 -0
- package/dist/components/ui/table.d.ts.map +1 -0
- package/dist/components/ui/table.js +95 -0
- package/dist/components/ui/table.js.map +1 -0
- package/dist/components/ui/tabs.d.ts +20 -0
- package/dist/components/ui/tabs.d.ts.map +1 -0
- package/dist/components/ui/tabs.js +92 -0
- package/dist/components/ui/tabs.js.map +1 -0
- package/dist/components/ui/textarea.d.ts +12 -0
- package/dist/components/ui/textarea.d.ts.map +1 -0
- package/dist/components/ui/textarea.js +41 -0
- package/dist/components/ui/textarea.js.map +1 -0
- package/dist/components/ui/toast.d.ts +16 -0
- package/dist/components/ui/toast.d.ts.map +1 -0
- package/dist/components/ui/toast.js +113 -0
- package/dist/components/ui/toast.js.map +1 -0
- package/dist/components/ui/tooltip.d.ts +8 -0
- package/dist/components/ui/tooltip.d.ts.map +1 -0
- package/dist/components/ui/tooltip.js +28 -0
- package/dist/components/ui/tooltip.js.map +1 -0
- package/dist/hooks/use-debounce.d.ts +15 -0
- package/dist/hooks/use-debounce.d.ts.map +1 -0
- package/dist/hooks/use-debounce.js +15 -0
- package/dist/hooks/use-debounce.js.map +1 -0
- package/dist/hooks/use-local-storage.d.ts +9 -0
- package/dist/hooks/use-local-storage.d.ts.map +1 -0
- package/dist/hooks/use-local-storage.js +49 -0
- package/dist/hooks/use-local-storage.js.map +1 -0
- package/dist/hooks/use-media-query.d.ts +9 -0
- package/dist/hooks/use-media-query.d.ts.map +1 -0
- package/dist/hooks/use-media-query.js +20 -0
- package/dist/hooks/use-media-query.js.map +1 -0
- package/dist/index.d.ts +66 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +153 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/colors.d.ts +73 -0
- package/dist/lib/colors.d.ts.map +1 -0
- package/dist/lib/colors.js +64 -0
- package/dist/lib/colors.js.map +1 -0
- package/dist/lib/utils.d.ts +7 -0
- package/dist/lib/utils.d.ts.map +1 -0
- package/dist/lib/utils.js +9 -0
- package/dist/lib/utils.js.map +1 -0
- package/dist/node_modules/@floating-ui/core/dist/floating-ui.core.js +729 -0
- package/dist/node_modules/@floating-ui/core/dist/floating-ui.core.js.map +1 -0
- package/dist/node_modules/@floating-ui/dom/dist/floating-ui.dom.js +630 -0
- package/dist/node_modules/@floating-ui/dom/dist/floating-ui.dom.js.map +1 -0
- package/dist/node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.js +325 -0
- package/dist/node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.js.map +1 -0
- package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.js +177 -0
- package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.js.map +1 -0
- package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.js +152 -0
- package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.js.map +1 -0
- package/dist/node_modules/@radix-ui/number/dist/index.js +7 -0
- package/dist/node_modules/@radix-ui/number/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/primitive/dist/index.js +12 -0
- package/dist/node_modules/@radix-ui/primitive/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-accordion/dist/index.js +319 -0
- package/dist/node_modules/@radix-ui/react-accordion/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-arrow/dist/index.js +26 -0
- package/dist/node_modules/@radix-ui/react-arrow/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-avatar/dist/index.js +124 -0
- package/dist/node_modules/@radix-ui/react-avatar/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-avatar/node_modules/@radix-ui/react-context/dist/index.js +66 -0
- package/dist/node_modules/@radix-ui/react-avatar/node_modules/@radix-ui/react-context/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-avatar/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-avatar/node_modules/@radix-ui/react-primitive/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-checkbox/dist/index.js +280 -0
- package/dist/node_modules/@radix-ui/react-checkbox/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-collapsible/dist/index.js +152 -0
- package/dist/node_modules/@radix-ui/react-collapsible/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-collection/dist/index.js +71 -0
- package/dist/node_modules/@radix-ui/react-collection/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-collection/node_modules/@radix-ui/react-slot/dist/index.js +90 -0
- package/dist/node_modules/@radix-ui/react-collection/node_modules/@radix-ui/react-slot/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-compose-refs/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-compose-refs/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-context/dist/index.js +82 -0
- package/dist/node_modules/@radix-ui/react-context/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-dialog/dist/index.js +342 -0
- package/dist/node_modules/@radix-ui/react-dialog/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot/dist/index.js +90 -0
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-direction/dist/index.js +11 -0
- package/dist/node_modules/@radix-ui/react-direction/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +217 -0
- package/dist/node_modules/@radix-ui/react-dismissable-layer/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/dist/index.js +299 -0
- package/dist/node_modules/@radix-ui/react-dropdown-menu/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-focus-guards/dist/index.js +30 -0
- package/dist/node_modules/@radix-ui/react-focus-guards/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-focus-scope/dist/index.js +209 -0
- package/dist/node_modules/@radix-ui/react-focus-scope/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-id/dist/index.js +15 -0
- package/dist/node_modules/@radix-ui/react-id/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-label/dist/index.js +27 -0
- package/dist/node_modules/@radix-ui/react-label/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-label/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-label/node_modules/@radix-ui/react-primitive/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-menu/dist/index.js +881 -0
- package/dist/node_modules/@radix-ui/react-menu/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-slot/dist/index.js +90 -0
- package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-slot/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-popover/dist/index.js +314 -0
- package/dist/node_modules/@radix-ui/react-popover/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-slot/dist/index.js +90 -0
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-slot/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-popper/dist/index.js +294 -0
- package/dist/node_modules/@radix-ui/react-popper/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-portal/dist/index.js +19 -0
- package/dist/node_modules/@radix-ui/react-portal/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-presence/dist/index.js +130 -0
- package/dist/node_modules/@radix-ui/react-presence/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-primitive/dist/index.js +44 -0
- package/dist/node_modules/@radix-ui/react-primitive/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-primitive/node_modules/@radix-ui/react-slot/dist/index.js +90 -0
- package/dist/node_modules/@radix-ui/react-primitive/node_modules/@radix-ui/react-slot/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-progress/dist/index.js +97 -0
- package/dist/node_modules/@radix-ui/react-progress/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-progress/node_modules/@radix-ui/react-context/dist/index.js +66 -0
- package/dist/node_modules/@radix-ui/react-progress/node_modules/@radix-ui/react-context/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-progress/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-progress/node_modules/@radix-ui/react-primitive/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-roving-focus/dist/index.js +228 -0
- package/dist/node_modules/@radix-ui/react-roving-focus/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-scroll-area/dist/index.js +728 -0
- package/dist/node_modules/@radix-ui/react-scroll-area/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-select/dist/index.js +1200 -0
- package/dist/node_modules/@radix-ui/react-select/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-slot/dist/index.js +90 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-slot/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-separator/dist/index.js +31 -0
- package/dist/node_modules/@radix-ui/react-separator/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-separator/node_modules/@radix-ui/react-primitive/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-separator/node_modules/@radix-ui/react-primitive/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-slot/dist/index.js +107 -0
- package/dist/node_modules/@radix-ui/react-slot/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-switch/dist/index.js +156 -0
- package/dist/node_modules/@radix-ui/react-switch/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-tabs/dist/index.js +195 -0
- package/dist/node_modules/@radix-ui/react-tabs/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-toast/dist/index.js +645 -0
- package/dist/node_modules/@radix-ui/react-toast/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-tooltip/dist/index.js +501 -0
- package/dist/node_modules/@radix-ui/react-tooltip/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-slot/dist/index.js +16 -0
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-slot/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-use-callback-ref/dist/index.js +15 -0
- package/dist/node_modules/@radix-ui/react-use-callback-ref/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-use-controllable-state/dist/index.js +72 -0
- package/dist/node_modules/@radix-ui/react-use-controllable-state/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-use-escape-keydown/dist/index.js +18 -0
- package/dist/node_modules/@radix-ui/react-use-escape-keydown/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-use-is-hydrated/dist/index.js +16 -0
- package/dist/node_modules/@radix-ui/react-use-is-hydrated/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-use-layout-effect/dist/index.js +7 -0
- package/dist/node_modules/@radix-ui/react-use-layout-effect/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-use-previous/dist/index.js +15 -0
- package/dist/node_modules/@radix-ui/react-use-previous/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-use-size/dist/index.js +40 -0
- package/dist/node_modules/@radix-ui/react-use-size/dist/index.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-visually-hidden/dist/index.js +37 -0
- package/dist/node_modules/@radix-ui/react-visually-hidden/dist/index.js.map +1 -0
- package/dist/node_modules/aria-hidden/dist/es2015/index.js +123 -0
- package/dist/node_modules/aria-hidden/dist/es2015/index.js.map +1 -0
- package/dist/node_modules/class-variance-authority/dist/index.js +46 -0
- package/dist/node_modules/class-variance-authority/dist/index.js.map +1 -0
- package/dist/node_modules/clsx/dist/clsx.js +17 -0
- package/dist/node_modules/clsx/dist/clsx.js.map +1 -0
- package/dist/node_modules/get-nonce/dist/es2015/index.js +10 -0
- package/dist/node_modules/get-nonce/dist/es2015/index.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/Icon.js +43 -0
- package/dist/node_modules/lucide-react/dist/esm/Icon.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/createLucideIcon.js +25 -0
- package/dist/node_modules/lucide-react/dist/esm/createLucideIcon.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/defaultAttributes.js +21 -0
- package/dist/node_modules/lucide-react/dist/esm/defaultAttributes.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/ban.js +15 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/ban.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/calendar.js +17 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/calendar.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/check.js +12 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/check.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-down.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-down.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-left.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-left.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-right.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-right.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-up.js +12 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/chevron-up.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-alert.js +16 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-alert.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-check.js +15 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-check.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-minus.js +15 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-minus.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-x.js +16 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle-x.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/circle.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/clock.js +15 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/clock.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/flag.js +15 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/flag.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/git-branch.js +17 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/git-branch.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/info.js +16 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/info.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/loader-circle.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/loader-circle.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/minus.js +12 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/minus.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/pause.js +15 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/pause.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/play.js +14 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/play.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/send.js +21 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/send.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/tag.js +21 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/tag.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/timer.js +16 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/timer.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/trending-down.js +15 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/trending-down.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/trending-up.js +15 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/trending-up.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/triangle-alert.js +22 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/triangle-alert.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/x.js +15 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/x.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/zap.js +20 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/zap.js.map +1 -0
- package/dist/node_modules/lucide-react/dist/esm/shared/src/utils.js +15 -0
- package/dist/node_modules/lucide-react/dist/esm/shared/src/utils.js.map +1 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/Combination.js +12 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/Combination.js.map +1 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.js +181 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.js.map +1 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/UI.js +39 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/UI.js.map +1 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js +20 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js.map +1 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.js +103 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.js.map +1 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/medium.js +6 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/medium.js.map +1 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/sidecar.js +8 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/sidecar.js.map +1 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.js +48 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.js.map +1 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/constants.js +11 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/constants.js.map +1 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/utils.js +38 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/utils.js.map +1 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/component.js +14 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/component.js.map +1 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/hook.js +17 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/hook.js.map +1 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/singleton.js +49 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/singleton.js.map +1 -0
- package/dist/node_modules/tailwind-merge/dist/bundle-mjs.js +2467 -0
- package/dist/node_modules/tailwind-merge/dist/bundle-mjs.js.map +1 -0
- package/dist/node_modules/tslib/tslib.es6.js +40 -0
- package/dist/node_modules/tslib/tslib.es6.js.map +1 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/assignRef.js +12 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/assignRef.js.map +1 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.js +36 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.js.map +1 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/useRef.js +30 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/useRef.js.map +1 -0
- package/dist/node_modules/use-sidecar/dist/es2015/exports.js +22 -0
- package/dist/node_modules/use-sidecar/dist/es2015/exports.js.map +1 -0
- package/dist/node_modules/use-sidecar/dist/es2015/medium.js +89 -0
- package/dist/node_modules/use-sidecar/dist/es2015/medium.js.map +1 -0
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js +78 -0
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js.map +1 -0
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js +63 -0
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js.map +1 -0
- package/dist/node_modules/use-sync-external-store/shim/index.js +18 -0
- package/dist/node_modules/use-sync-external-store/shim/index.js.map +1 -0
- package/dist/types/automation.d.ts +59 -0
- package/dist/types/automation.d.ts.map +1 -0
- package/dist/types/common.d.ts +38 -0
- package/dist/types/common.d.ts.map +1 -0
- package/package.json +119 -0
- package/registry/registry.json +218 -0
- package/src/components/automation/metric-card.tsx +113 -0
- package/src/components/automation/status-badge.tsx +136 -0
- package/src/components/automation/task-card.tsx +164 -0
- package/src/components/automation/workflow-node.tsx +186 -0
- package/src/components/layout/app-shell.tsx +58 -0
- package/src/components/layout/header.tsx +39 -0
- package/src/components/layout/page-header.tsx +42 -0
- package/src/components/layout/sidebar.tsx +190 -0
- package/src/components/ui/accordion.tsx +57 -0
- package/src/components/ui/alert.tsx +93 -0
- package/src/components/ui/avatar.tsx +94 -0
- package/src/components/ui/badge.tsx +69 -0
- package/src/components/ui/button.tsx +106 -0
- package/src/components/ui/card.tsx +96 -0
- package/src/components/ui/checkbox.tsx +40 -0
- package/src/components/ui/dialog.tsx +129 -0
- package/src/components/ui/dropdown-menu.tsx +194 -0
- package/src/components/ui/input.tsx +80 -0
- package/src/components/ui/label.tsx +37 -0
- package/src/components/ui/popover.tsx +29 -0
- package/src/components/ui/progress.tsx +92 -0
- package/src/components/ui/scroll-area.tsx +43 -0
- package/src/components/ui/select.tsx +157 -0
- package/src/components/ui/separator.tsx +56 -0
- package/src/components/ui/skeleton.tsx +41 -0
- package/src/components/ui/spinner.tsx +50 -0
- package/src/components/ui/switch.tsx +46 -0
- package/src/components/ui/table.tsx +117 -0
- package/src/components/ui/tabs.tsx +107 -0
- package/src/components/ui/textarea.tsx +50 -0
- package/src/components/ui/toast.tsx +139 -0
- package/src/components/ui/tooltip.tsx +28 -0
- package/src/hooks/use-debounce.ts +28 -0
- package/src/hooks/use-local-storage.ts +63 -0
- package/src/hooks/use-media-query.ts +29 -0
- package/src/index.ts +197 -0
- package/src/lib/colors.ts +102 -0
- package/src/lib/utils.ts +10 -0
- package/src/styles/globals.css +230 -0
- package/src/types/automation.ts +74 -0
- package/src/types/common.ts +48 -0
- package/tailwind/preset.cjs +98 -0
- package/tailwind/preset.css +5 -0
- package/tailwind/preset.ts +159 -0
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import * as React from 'react'
|
|
2
|
+
import { cn } from '@/lib/utils'
|
|
3
|
+
|
|
4
|
+
export interface SkeletonProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
5
|
+
/** Shape variant */
|
|
6
|
+
variant?: 'rectangle' | 'circle' | 'text'
|
|
7
|
+
/** Number of text lines to render (only when variant='text') */
|
|
8
|
+
lines?: number
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
function Skeleton({ className, variant = 'rectangle', lines = 1, ...props }: SkeletonProps) {
|
|
12
|
+
const base = cn(
|
|
13
|
+
'bg-muted animate-[shimmer_2s_linear_infinite]',
|
|
14
|
+
'[background:linear-gradient(90deg,hsl(var(--muted))_25%,hsl(var(--muted-foreground)/0.1)_50%,hsl(var(--muted))_75%)]',
|
|
15
|
+
'[background-size:200%_100%]',
|
|
16
|
+
variant === 'circle' && 'rounded-full',
|
|
17
|
+
variant !== 'circle' && 'rounded-md',
|
|
18
|
+
className
|
|
19
|
+
)
|
|
20
|
+
|
|
21
|
+
if (variant === 'text') {
|
|
22
|
+
return (
|
|
23
|
+
<div className="space-y-2" {...props}>
|
|
24
|
+
{Array.from({ length: lines }, (_, i) => (
|
|
25
|
+
<div
|
|
26
|
+
key={i}
|
|
27
|
+
className={cn(
|
|
28
|
+
base,
|
|
29
|
+
'h-4',
|
|
30
|
+
i === lines - 1 && lines > 1 ? 'w-4/5' : 'w-full'
|
|
31
|
+
)}
|
|
32
|
+
/>
|
|
33
|
+
))}
|
|
34
|
+
</div>
|
|
35
|
+
)
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
return <div className={base} {...props} />
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export { Skeleton }
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import * as React from 'react'
|
|
2
|
+
import { cva } from 'class-variance-authority'
|
|
3
|
+
import { cn } from '@/lib/utils'
|
|
4
|
+
|
|
5
|
+
const spinnerVariants = cva(
|
|
6
|
+
'animate-spin rounded-full border-2 border-current border-t-transparent',
|
|
7
|
+
{
|
|
8
|
+
variants: {
|
|
9
|
+
size: {
|
|
10
|
+
xs: 'h-3 w-3',
|
|
11
|
+
sm: 'h-4 w-4',
|
|
12
|
+
md: 'h-6 w-6',
|
|
13
|
+
lg: 'h-8 w-8',
|
|
14
|
+
xl: 'h-12 w-12',
|
|
15
|
+
},
|
|
16
|
+
color: {
|
|
17
|
+
default: 'text-muted-foreground',
|
|
18
|
+
primary: 'text-primary',
|
|
19
|
+
foreground: 'text-foreground',
|
|
20
|
+
white: 'text-white',
|
|
21
|
+
},
|
|
22
|
+
},
|
|
23
|
+
defaultVariants: {
|
|
24
|
+
size: 'md',
|
|
25
|
+
color: 'primary',
|
|
26
|
+
},
|
|
27
|
+
}
|
|
28
|
+
)
|
|
29
|
+
|
|
30
|
+
export interface SpinnerProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
31
|
+
size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl'
|
|
32
|
+
color?: 'default' | 'primary' | 'foreground' | 'white'
|
|
33
|
+
/** Accessible label for screen readers */
|
|
34
|
+
label?: string
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
function Spinner({ className, size, color, label = 'Loading...', ...props }: SpinnerProps) {
|
|
38
|
+
return (
|
|
39
|
+
<div
|
|
40
|
+
role="status"
|
|
41
|
+
aria-label={label}
|
|
42
|
+
className={cn(spinnerVariants({ size, color }), className)}
|
|
43
|
+
{...props}
|
|
44
|
+
>
|
|
45
|
+
<span className="sr-only">{label}</span>
|
|
46
|
+
</div>
|
|
47
|
+
)
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export { Spinner, spinnerVariants }
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import * as React from 'react'
|
|
2
|
+
import * as SwitchPrimitive from '@radix-ui/react-switch'
|
|
3
|
+
import { cn } from '@/lib/utils'
|
|
4
|
+
|
|
5
|
+
export interface SwitchProps extends React.ComponentPropsWithoutRef<typeof SwitchPrimitive.Root> {
|
|
6
|
+
size?: 'sm' | 'md' | 'lg'
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
const Switch = React.forwardRef<
|
|
10
|
+
React.ElementRef<typeof SwitchPrimitive.Root>,
|
|
11
|
+
SwitchProps
|
|
12
|
+
>(({ className, size = 'md', ...props }, ref) => {
|
|
13
|
+
const sizeClasses = {
|
|
14
|
+
sm: { root: 'h-4 w-7', thumb: 'h-3 w-3 data-[state=checked]:translate-x-3' },
|
|
15
|
+
md: { root: 'h-5 w-9', thumb: 'h-4 w-4 data-[state=checked]:translate-x-4' },
|
|
16
|
+
lg: { root: 'h-6 w-11', thumb: 'h-5 w-5 data-[state=checked]:translate-x-5' },
|
|
17
|
+
}[size]
|
|
18
|
+
|
|
19
|
+
return (
|
|
20
|
+
<SwitchPrimitive.Root
|
|
21
|
+
className={cn(
|
|
22
|
+
'peer inline-flex shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent',
|
|
23
|
+
'transition-colors duration-200',
|
|
24
|
+
'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background',
|
|
25
|
+
'disabled:cursor-not-allowed disabled:opacity-50',
|
|
26
|
+
'data-[state=unchecked]:bg-input data-[state=checked]:bg-primary',
|
|
27
|
+
sizeClasses.root,
|
|
28
|
+
className
|
|
29
|
+
)}
|
|
30
|
+
{...props}
|
|
31
|
+
ref={ref}
|
|
32
|
+
>
|
|
33
|
+
<SwitchPrimitive.Thumb
|
|
34
|
+
className={cn(
|
|
35
|
+
'pointer-events-none block rounded-full bg-background shadow-lg ring-0',
|
|
36
|
+
'transition-transform duration-200',
|
|
37
|
+
'data-[state=unchecked]:translate-x-0',
|
|
38
|
+
sizeClasses.thumb
|
|
39
|
+
)}
|
|
40
|
+
/>
|
|
41
|
+
</SwitchPrimitive.Root>
|
|
42
|
+
)
|
|
43
|
+
})
|
|
44
|
+
Switch.displayName = SwitchPrimitive.Root.displayName
|
|
45
|
+
|
|
46
|
+
export { Switch }
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
import * as React from 'react'
|
|
2
|
+
import { cn } from '@/lib/utils'
|
|
3
|
+
|
|
4
|
+
const Table = React.forwardRef<HTMLTableElement, React.HTMLAttributes<HTMLTableElement>>(
|
|
5
|
+
({ className, ...props }, ref) => (
|
|
6
|
+
<div className="relative w-full overflow-auto">
|
|
7
|
+
<table
|
|
8
|
+
ref={ref}
|
|
9
|
+
className={cn('w-full caption-bottom text-sm', className)}
|
|
10
|
+
{...props}
|
|
11
|
+
/>
|
|
12
|
+
</div>
|
|
13
|
+
)
|
|
14
|
+
)
|
|
15
|
+
Table.displayName = 'Table'
|
|
16
|
+
|
|
17
|
+
const TableHeader = React.forwardRef<
|
|
18
|
+
HTMLTableSectionElement,
|
|
19
|
+
React.HTMLAttributes<HTMLTableSectionElement>
|
|
20
|
+
>(({ className, ...props }, ref) => (
|
|
21
|
+
<thead ref={ref} className={cn('[&_tr]:border-b [&_tr]:border-border', className)} {...props} />
|
|
22
|
+
))
|
|
23
|
+
TableHeader.displayName = 'TableHeader'
|
|
24
|
+
|
|
25
|
+
const TableBody = React.forwardRef<
|
|
26
|
+
HTMLTableSectionElement,
|
|
27
|
+
React.HTMLAttributes<HTMLTableSectionElement>
|
|
28
|
+
>(({ className, ...props }, ref) => (
|
|
29
|
+
<tbody
|
|
30
|
+
ref={ref}
|
|
31
|
+
className={cn('[&_tr:last-child]:border-0', className)}
|
|
32
|
+
{...props}
|
|
33
|
+
/>
|
|
34
|
+
))
|
|
35
|
+
TableBody.displayName = 'TableBody'
|
|
36
|
+
|
|
37
|
+
const TableFooter = React.forwardRef<
|
|
38
|
+
HTMLTableSectionElement,
|
|
39
|
+
React.HTMLAttributes<HTMLTableSectionElement>
|
|
40
|
+
>(({ className, ...props }, ref) => (
|
|
41
|
+
<tfoot
|
|
42
|
+
ref={ref}
|
|
43
|
+
className={cn('border-t border-border bg-muted/50 font-medium [&>tr]:last:border-b-0', className)}
|
|
44
|
+
{...props}
|
|
45
|
+
/>
|
|
46
|
+
))
|
|
47
|
+
TableFooter.displayName = 'TableFooter'
|
|
48
|
+
|
|
49
|
+
const TableRow = React.forwardRef<HTMLTableRowElement, React.HTMLAttributes<HTMLTableRowElement>>(
|
|
50
|
+
({ className, ...props }, ref) => (
|
|
51
|
+
<tr
|
|
52
|
+
ref={ref}
|
|
53
|
+
className={cn(
|
|
54
|
+
'border-b border-border transition-colors duration-100',
|
|
55
|
+
'hover:bg-muted/50 data-[state=selected]:bg-muted',
|
|
56
|
+
className
|
|
57
|
+
)}
|
|
58
|
+
{...props}
|
|
59
|
+
/>
|
|
60
|
+
)
|
|
61
|
+
)
|
|
62
|
+
TableRow.displayName = 'TableRow'
|
|
63
|
+
|
|
64
|
+
const TableHead = React.forwardRef<
|
|
65
|
+
HTMLTableCellElement,
|
|
66
|
+
React.ThHTMLAttributes<HTMLTableCellElement>
|
|
67
|
+
>(({ className, ...props }, ref) => (
|
|
68
|
+
<th
|
|
69
|
+
ref={ref}
|
|
70
|
+
className={cn(
|
|
71
|
+
'h-10 px-4 text-left align-middle font-medium text-muted-foreground',
|
|
72
|
+
'[&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]',
|
|
73
|
+
className
|
|
74
|
+
)}
|
|
75
|
+
{...props}
|
|
76
|
+
/>
|
|
77
|
+
))
|
|
78
|
+
TableHead.displayName = 'TableHead'
|
|
79
|
+
|
|
80
|
+
const TableCell = React.forwardRef<
|
|
81
|
+
HTMLTableCellElement,
|
|
82
|
+
React.TdHTMLAttributes<HTMLTableCellElement>
|
|
83
|
+
>(({ className, ...props }, ref) => (
|
|
84
|
+
<td
|
|
85
|
+
ref={ref}
|
|
86
|
+
className={cn(
|
|
87
|
+
'p-4 align-middle',
|
|
88
|
+
'[&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]',
|
|
89
|
+
className
|
|
90
|
+
)}
|
|
91
|
+
{...props}
|
|
92
|
+
/>
|
|
93
|
+
))
|
|
94
|
+
TableCell.displayName = 'TableCell'
|
|
95
|
+
|
|
96
|
+
const TableCaption = React.forwardRef<
|
|
97
|
+
HTMLTableCaptionElement,
|
|
98
|
+
React.HTMLAttributes<HTMLTableCaptionElement>
|
|
99
|
+
>(({ className, ...props }, ref) => (
|
|
100
|
+
<caption
|
|
101
|
+
ref={ref}
|
|
102
|
+
className={cn('mt-4 text-sm text-muted-foreground', className)}
|
|
103
|
+
{...props}
|
|
104
|
+
/>
|
|
105
|
+
))
|
|
106
|
+
TableCaption.displayName = 'TableCaption'
|
|
107
|
+
|
|
108
|
+
export {
|
|
109
|
+
Table,
|
|
110
|
+
TableHeader,
|
|
111
|
+
TableBody,
|
|
112
|
+
TableFooter,
|
|
113
|
+
TableHead,
|
|
114
|
+
TableRow,
|
|
115
|
+
TableCell,
|
|
116
|
+
TableCaption,
|
|
117
|
+
}
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import * as React from 'react'
|
|
2
|
+
import * as TabsPrimitive from '@radix-ui/react-tabs'
|
|
3
|
+
import { cva, type VariantProps } from 'class-variance-authority'
|
|
4
|
+
import { cn } from '@/lib/utils'
|
|
5
|
+
|
|
6
|
+
const Tabs = TabsPrimitive.Root
|
|
7
|
+
|
|
8
|
+
const tabsListVariants = cva(
|
|
9
|
+
'inline-flex items-center',
|
|
10
|
+
{
|
|
11
|
+
variants: {
|
|
12
|
+
variant: {
|
|
13
|
+
default: 'h-9 rounded-lg bg-muted p-1 text-muted-foreground',
|
|
14
|
+
underline: 'border-b border-border gap-0',
|
|
15
|
+
pills: 'gap-1',
|
|
16
|
+
},
|
|
17
|
+
},
|
|
18
|
+
defaultVariants: {
|
|
19
|
+
variant: 'default',
|
|
20
|
+
},
|
|
21
|
+
}
|
|
22
|
+
)
|
|
23
|
+
|
|
24
|
+
const tabsTriggerVariants = cva(
|
|
25
|
+
'inline-flex items-center justify-center whitespace-nowrap text-sm font-medium transition-all',
|
|
26
|
+
{
|
|
27
|
+
variants: {
|
|
28
|
+
variant: {
|
|
29
|
+
default: [
|
|
30
|
+
'rounded-md px-3 py-1 ring-offset-background',
|
|
31
|
+
'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2',
|
|
32
|
+
'disabled:pointer-events-none disabled:opacity-50',
|
|
33
|
+
'data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm',
|
|
34
|
+
],
|
|
35
|
+
underline: [
|
|
36
|
+
'px-4 py-2 border-b-2 border-transparent rounded-none -mb-px',
|
|
37
|
+
'focus-visible:outline-none',
|
|
38
|
+
'disabled:pointer-events-none disabled:opacity-50',
|
|
39
|
+
'data-[state=active]:border-primary data-[state=active]:text-foreground',
|
|
40
|
+
'text-muted-foreground hover:text-foreground',
|
|
41
|
+
],
|
|
42
|
+
pills: [
|
|
43
|
+
'rounded-full px-4 py-1.5',
|
|
44
|
+
'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring',
|
|
45
|
+
'disabled:pointer-events-none disabled:opacity-50',
|
|
46
|
+
'data-[state=active]:bg-primary data-[state=active]:text-primary-foreground',
|
|
47
|
+
'text-muted-foreground hover:text-foreground hover:bg-muted',
|
|
48
|
+
],
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
defaultVariants: {
|
|
52
|
+
variant: 'default',
|
|
53
|
+
},
|
|
54
|
+
}
|
|
55
|
+
)
|
|
56
|
+
|
|
57
|
+
interface TabsListProps
|
|
58
|
+
extends React.ComponentPropsWithoutRef<typeof TabsPrimitive.List>,
|
|
59
|
+
VariantProps<typeof tabsListVariants> {}
|
|
60
|
+
|
|
61
|
+
const TabsList = React.forwardRef<
|
|
62
|
+
React.ElementRef<typeof TabsPrimitive.List>,
|
|
63
|
+
TabsListProps
|
|
64
|
+
>(({ className, variant, ...props }, ref) => (
|
|
65
|
+
<TabsPrimitive.List
|
|
66
|
+
ref={ref}
|
|
67
|
+
className={cn(tabsListVariants({ variant }), className)}
|
|
68
|
+
{...props}
|
|
69
|
+
/>
|
|
70
|
+
))
|
|
71
|
+
TabsList.displayName = TabsPrimitive.List.displayName
|
|
72
|
+
|
|
73
|
+
interface TabsTriggerProps
|
|
74
|
+
extends React.ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>,
|
|
75
|
+
VariantProps<typeof tabsTriggerVariants> {}
|
|
76
|
+
|
|
77
|
+
const TabsTrigger = React.forwardRef<
|
|
78
|
+
React.ElementRef<typeof TabsPrimitive.Trigger>,
|
|
79
|
+
TabsTriggerProps
|
|
80
|
+
>(({ className, variant, ...props }, ref) => (
|
|
81
|
+
<TabsPrimitive.Trigger
|
|
82
|
+
ref={ref}
|
|
83
|
+
className={cn(tabsTriggerVariants({ variant }), className)}
|
|
84
|
+
{...props}
|
|
85
|
+
/>
|
|
86
|
+
))
|
|
87
|
+
TabsTrigger.displayName = TabsPrimitive.Trigger.displayName
|
|
88
|
+
|
|
89
|
+
const TabsContent = React.forwardRef<
|
|
90
|
+
React.ElementRef<typeof TabsPrimitive.Content>,
|
|
91
|
+
React.ComponentPropsWithoutRef<typeof TabsPrimitive.Content>
|
|
92
|
+
>(({ className, ...props }, ref) => (
|
|
93
|
+
<TabsPrimitive.Content
|
|
94
|
+
ref={ref}
|
|
95
|
+
className={cn(
|
|
96
|
+
'mt-2 ring-offset-background',
|
|
97
|
+
'focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2',
|
|
98
|
+
'animate-fade-in',
|
|
99
|
+
className
|
|
100
|
+
)}
|
|
101
|
+
{...props}
|
|
102
|
+
/>
|
|
103
|
+
))
|
|
104
|
+
TabsContent.displayName = TabsPrimitive.Content.displayName
|
|
105
|
+
|
|
106
|
+
export { Tabs, TabsList, TabsTrigger, TabsContent }
|
|
107
|
+
export type { TabsListProps, TabsTriggerProps }
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import * as React from 'react'
|
|
2
|
+
import { cn } from '@/lib/utils'
|
|
3
|
+
|
|
4
|
+
export interface TextareaProps extends React.TextareaHTMLAttributes<HTMLTextAreaElement> {
|
|
5
|
+
/** Error state */
|
|
6
|
+
error?: boolean
|
|
7
|
+
/** Error message shown below */
|
|
8
|
+
errorMessage?: string
|
|
9
|
+
/** Auto-resize based on content */
|
|
10
|
+
autoResize?: boolean
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
const Textarea = React.forwardRef<HTMLTextAreaElement, TextareaProps>(
|
|
14
|
+
({ className, error, errorMessage, autoResize, onChange, ...props }, ref) => {
|
|
15
|
+
const handleChange = (e: React.ChangeEvent<HTMLTextAreaElement>) => {
|
|
16
|
+
if (autoResize) {
|
|
17
|
+
e.target.style.height = 'auto'
|
|
18
|
+
e.target.style.height = `${e.target.scrollHeight}px`
|
|
19
|
+
}
|
|
20
|
+
onChange?.(e)
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
return (
|
|
24
|
+
<div className="w-full">
|
|
25
|
+
<textarea
|
|
26
|
+
className={cn(
|
|
27
|
+
'flex min-h-[80px] w-full rounded-md border border-input bg-transparent px-3 py-2 text-sm shadow-sm',
|
|
28
|
+
'placeholder:text-muted-foreground',
|
|
29
|
+
'transition-colors duration-150',
|
|
30
|
+
'focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring',
|
|
31
|
+
'disabled:cursor-not-allowed disabled:opacity-50',
|
|
32
|
+
'resize-y',
|
|
33
|
+
error && 'border-destructive focus-visible:ring-destructive',
|
|
34
|
+
autoResize && 'resize-none overflow-hidden',
|
|
35
|
+
className
|
|
36
|
+
)}
|
|
37
|
+
ref={ref}
|
|
38
|
+
onChange={handleChange}
|
|
39
|
+
{...props}
|
|
40
|
+
/>
|
|
41
|
+
{errorMessage && (
|
|
42
|
+
<p className="mt-1 text-xs text-destructive">{errorMessage}</p>
|
|
43
|
+
)}
|
|
44
|
+
</div>
|
|
45
|
+
)
|
|
46
|
+
}
|
|
47
|
+
)
|
|
48
|
+
Textarea.displayName = 'Textarea'
|
|
49
|
+
|
|
50
|
+
export { Textarea }
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
import * as React from 'react'
|
|
2
|
+
import * as ToastPrimitive from '@radix-ui/react-toast'
|
|
3
|
+
import { cva, type VariantProps } from 'class-variance-authority'
|
|
4
|
+
import { X } from 'lucide-react'
|
|
5
|
+
import { cn } from '@/lib/utils'
|
|
6
|
+
|
|
7
|
+
const ToastProvider = ToastPrimitive.Provider
|
|
8
|
+
|
|
9
|
+
const ToastViewport = React.forwardRef<
|
|
10
|
+
React.ElementRef<typeof ToastPrimitive.Viewport>,
|
|
11
|
+
React.ComponentPropsWithoutRef<typeof ToastPrimitive.Viewport>
|
|
12
|
+
>(({ className, ...props }, ref) => (
|
|
13
|
+
<ToastPrimitive.Viewport
|
|
14
|
+
ref={ref}
|
|
15
|
+
className={cn(
|
|
16
|
+
'fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4',
|
|
17
|
+
'sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]',
|
|
18
|
+
className
|
|
19
|
+
)}
|
|
20
|
+
{...props}
|
|
21
|
+
/>
|
|
22
|
+
))
|
|
23
|
+
ToastViewport.displayName = ToastPrimitive.Viewport.displayName
|
|
24
|
+
|
|
25
|
+
const toastVariants = cva(
|
|
26
|
+
[
|
|
27
|
+
'group pointer-events-auto relative flex w-full items-center justify-between space-x-2 overflow-hidden rounded-md border p-4 pr-6 shadow-lg',
|
|
28
|
+
'transition-all duration-200',
|
|
29
|
+
'data-[swipe=cancel]:translate-x-0',
|
|
30
|
+
'data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)]',
|
|
31
|
+
'data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)]',
|
|
32
|
+
'data-[swipe=move]:transition-none',
|
|
33
|
+
'data-[state=open]:animate-slide-in-right',
|
|
34
|
+
'data-[state=closed]:opacity-0',
|
|
35
|
+
],
|
|
36
|
+
{
|
|
37
|
+
variants: {
|
|
38
|
+
variant: {
|
|
39
|
+
default: 'border-border bg-background text-foreground',
|
|
40
|
+
success: 'border-success/30 bg-success/10 text-foreground',
|
|
41
|
+
destructive: 'border-destructive/30 bg-destructive/10 text-foreground',
|
|
42
|
+
warning: 'border-warning/30 bg-warning/10 text-foreground',
|
|
43
|
+
info: 'border-info/30 bg-info/10 text-foreground',
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
defaultVariants: {
|
|
47
|
+
variant: 'default',
|
|
48
|
+
},
|
|
49
|
+
}
|
|
50
|
+
)
|
|
51
|
+
|
|
52
|
+
const Toast = React.forwardRef<
|
|
53
|
+
React.ElementRef<typeof ToastPrimitive.Root>,
|
|
54
|
+
React.ComponentPropsWithoutRef<typeof ToastPrimitive.Root> &
|
|
55
|
+
VariantProps<typeof toastVariants>
|
|
56
|
+
>(({ className, variant, ...props }, ref) => (
|
|
57
|
+
<ToastPrimitive.Root
|
|
58
|
+
ref={ref}
|
|
59
|
+
className={cn(toastVariants({ variant }), className)}
|
|
60
|
+
{...props}
|
|
61
|
+
/>
|
|
62
|
+
))
|
|
63
|
+
Toast.displayName = ToastPrimitive.Root.displayName
|
|
64
|
+
|
|
65
|
+
const ToastAction = React.forwardRef<
|
|
66
|
+
React.ElementRef<typeof ToastPrimitive.Action>,
|
|
67
|
+
React.ComponentPropsWithoutRef<typeof ToastPrimitive.Action>
|
|
68
|
+
>(({ className, ...props }, ref) => (
|
|
69
|
+
<ToastPrimitive.Action
|
|
70
|
+
ref={ref}
|
|
71
|
+
className={cn(
|
|
72
|
+
'inline-flex h-8 shrink-0 items-center justify-center rounded-md border border-border bg-transparent px-3 text-sm font-medium',
|
|
73
|
+
'transition-colors hover:bg-secondary focus:outline-none focus:ring-1 focus:ring-ring',
|
|
74
|
+
'disabled:pointer-events-none disabled:opacity-50',
|
|
75
|
+
className
|
|
76
|
+
)}
|
|
77
|
+
{...props}
|
|
78
|
+
/>
|
|
79
|
+
))
|
|
80
|
+
ToastAction.displayName = ToastPrimitive.Action.displayName
|
|
81
|
+
|
|
82
|
+
const ToastClose = React.forwardRef<
|
|
83
|
+
React.ElementRef<typeof ToastPrimitive.Close>,
|
|
84
|
+
React.ComponentPropsWithoutRef<typeof ToastPrimitive.Close>
|
|
85
|
+
>(({ className, ...props }, ref) => (
|
|
86
|
+
<ToastPrimitive.Close
|
|
87
|
+
ref={ref}
|
|
88
|
+
className={cn(
|
|
89
|
+
'absolute right-1 top-1 rounded-md p-1 text-muted-foreground opacity-0 transition-opacity',
|
|
90
|
+
'hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-1 focus:ring-ring',
|
|
91
|
+
'group-hover:opacity-100',
|
|
92
|
+
className
|
|
93
|
+
)}
|
|
94
|
+
toast-close=""
|
|
95
|
+
{...props}
|
|
96
|
+
>
|
|
97
|
+
<X className="h-4 w-4" />
|
|
98
|
+
</ToastPrimitive.Close>
|
|
99
|
+
))
|
|
100
|
+
ToastClose.displayName = ToastPrimitive.Close.displayName
|
|
101
|
+
|
|
102
|
+
const ToastTitle = React.forwardRef<
|
|
103
|
+
React.ElementRef<typeof ToastPrimitive.Title>,
|
|
104
|
+
React.ComponentPropsWithoutRef<typeof ToastPrimitive.Title>
|
|
105
|
+
>(({ className, ...props }, ref) => (
|
|
106
|
+
<ToastPrimitive.Title
|
|
107
|
+
ref={ref}
|
|
108
|
+
className={cn('text-sm font-semibold [&+div]:text-xs', className)}
|
|
109
|
+
{...props}
|
|
110
|
+
/>
|
|
111
|
+
))
|
|
112
|
+
ToastTitle.displayName = ToastPrimitive.Title.displayName
|
|
113
|
+
|
|
114
|
+
const ToastDescription = React.forwardRef<
|
|
115
|
+
React.ElementRef<typeof ToastPrimitive.Description>,
|
|
116
|
+
React.ComponentPropsWithoutRef<typeof ToastPrimitive.Description>
|
|
117
|
+
>(({ className, ...props }, ref) => (
|
|
118
|
+
<ToastPrimitive.Description
|
|
119
|
+
ref={ref}
|
|
120
|
+
className={cn('text-sm text-muted-foreground', className)}
|
|
121
|
+
{...props}
|
|
122
|
+
/>
|
|
123
|
+
))
|
|
124
|
+
ToastDescription.displayName = ToastPrimitive.Description.displayName
|
|
125
|
+
|
|
126
|
+
type ToastProps = React.ComponentPropsWithoutRef<typeof Toast>
|
|
127
|
+
type ToastActionElement = React.ReactElement<typeof ToastAction>
|
|
128
|
+
|
|
129
|
+
export {
|
|
130
|
+
type ToastProps,
|
|
131
|
+
type ToastActionElement,
|
|
132
|
+
ToastProvider,
|
|
133
|
+
ToastViewport,
|
|
134
|
+
Toast,
|
|
135
|
+
ToastTitle,
|
|
136
|
+
ToastDescription,
|
|
137
|
+
ToastClose,
|
|
138
|
+
ToastAction,
|
|
139
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as React from 'react'
|
|
2
|
+
import * as TooltipPrimitive from '@radix-ui/react-tooltip'
|
|
3
|
+
import { cn } from '@/lib/utils'
|
|
4
|
+
|
|
5
|
+
const TooltipProvider = TooltipPrimitive.Provider
|
|
6
|
+
const Tooltip = TooltipPrimitive.Root
|
|
7
|
+
const TooltipTrigger = TooltipPrimitive.Trigger
|
|
8
|
+
|
|
9
|
+
const TooltipContent = React.forwardRef<
|
|
10
|
+
React.ElementRef<typeof TooltipPrimitive.Content>,
|
|
11
|
+
React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Content>
|
|
12
|
+
>(({ className, sideOffset = 4, ...props }, ref) => (
|
|
13
|
+
<TooltipPrimitive.Portal>
|
|
14
|
+
<TooltipPrimitive.Content
|
|
15
|
+
ref={ref}
|
|
16
|
+
sideOffset={sideOffset}
|
|
17
|
+
className={cn(
|
|
18
|
+
'z-50 overflow-hidden rounded-md border border-border bg-popover px-3 py-1.5 text-xs text-popover-foreground shadow-md',
|
|
19
|
+
'animate-fade-in',
|
|
20
|
+
className
|
|
21
|
+
)}
|
|
22
|
+
{...props}
|
|
23
|
+
/>
|
|
24
|
+
</TooltipPrimitive.Portal>
|
|
25
|
+
))
|
|
26
|
+
TooltipContent.displayName = TooltipPrimitive.Content.displayName
|
|
27
|
+
|
|
28
|
+
export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider }
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { useState, useEffect } from 'react'
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Returns a debounced version of the given value.
|
|
5
|
+
* Useful for search inputs and API calls.
|
|
6
|
+
*
|
|
7
|
+
* @example
|
|
8
|
+
* const [search, setSearch] = useState('')
|
|
9
|
+
* const debouncedSearch = useDebounce(search, 300)
|
|
10
|
+
*
|
|
11
|
+
* useEffect(() => {
|
|
12
|
+
* // Only fires 300ms after the user stops typing
|
|
13
|
+
* fetchResults(debouncedSearch)
|
|
14
|
+
* }, [debouncedSearch])
|
|
15
|
+
*/
|
|
16
|
+
export function useDebounce<T>(value: T, delay = 300): T {
|
|
17
|
+
const [debouncedValue, setDebouncedValue] = useState<T>(value)
|
|
18
|
+
|
|
19
|
+
useEffect(() => {
|
|
20
|
+
const timer = setTimeout(() => {
|
|
21
|
+
setDebouncedValue(value)
|
|
22
|
+
}, delay)
|
|
23
|
+
|
|
24
|
+
return () => clearTimeout(timer)
|
|
25
|
+
}, [value, delay])
|
|
26
|
+
|
|
27
|
+
return debouncedValue
|
|
28
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { useState, useEffect, useCallback } from 'react'
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Persists state in localStorage with JSON serialization.
|
|
5
|
+
* SSR-safe — reads from storage only on the client.
|
|
6
|
+
*
|
|
7
|
+
* @example
|
|
8
|
+
* const [theme, setTheme] = useLocalStorage('theme', 'dark')
|
|
9
|
+
*/
|
|
10
|
+
export function useLocalStorage<T>(
|
|
11
|
+
key: string,
|
|
12
|
+
initialValue: T
|
|
13
|
+
): [T, (value: T | ((prev: T) => T)) => void, () => void] {
|
|
14
|
+
const [storedValue, setStoredValue] = useState<T>(() => {
|
|
15
|
+
if (typeof window === 'undefined') return initialValue
|
|
16
|
+
try {
|
|
17
|
+
const item = window.localStorage.getItem(key)
|
|
18
|
+
return item !== null ? (JSON.parse(item) as T) : initialValue
|
|
19
|
+
} catch {
|
|
20
|
+
return initialValue
|
|
21
|
+
}
|
|
22
|
+
})
|
|
23
|
+
|
|
24
|
+
useEffect(() => {
|
|
25
|
+
if (typeof window === 'undefined') return
|
|
26
|
+
try {
|
|
27
|
+
const item = window.localStorage.getItem(key)
|
|
28
|
+
if (item !== null) {
|
|
29
|
+
setStoredValue(JSON.parse(item) as T)
|
|
30
|
+
}
|
|
31
|
+
} catch {
|
|
32
|
+
// ignore
|
|
33
|
+
}
|
|
34
|
+
}, [key])
|
|
35
|
+
|
|
36
|
+
const setValue = useCallback(
|
|
37
|
+
(value: T | ((prev: T) => T)) => {
|
|
38
|
+
try {
|
|
39
|
+
const valueToStore = value instanceof Function ? value(storedValue) : value
|
|
40
|
+
setStoredValue(valueToStore)
|
|
41
|
+
if (typeof window !== 'undefined') {
|
|
42
|
+
window.localStorage.setItem(key, JSON.stringify(valueToStore))
|
|
43
|
+
}
|
|
44
|
+
} catch {
|
|
45
|
+
// ignore
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
[key, storedValue]
|
|
49
|
+
)
|
|
50
|
+
|
|
51
|
+
const removeValue = useCallback(() => {
|
|
52
|
+
try {
|
|
53
|
+
setStoredValue(initialValue)
|
|
54
|
+
if (typeof window !== 'undefined') {
|
|
55
|
+
window.localStorage.removeItem(key)
|
|
56
|
+
}
|
|
57
|
+
} catch {
|
|
58
|
+
// ignore
|
|
59
|
+
}
|
|
60
|
+
}, [key, initialValue])
|
|
61
|
+
|
|
62
|
+
return [storedValue, setValue, removeValue]
|
|
63
|
+
}
|