@flikk/ui 1.0.0-beta.26 → 1.0.0-beta.29
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/dist/bg/1.webp +0 -0
- package/dist/bg/10.webp +0 -0
- package/dist/bg/11.webp +0 -0
- package/dist/bg/12.webp +0 -0
- package/dist/bg/13.webp +0 -0
- package/dist/bg/14.webp +0 -0
- package/dist/bg/15.webp +0 -0
- package/dist/bg/16.webp +0 -0
- package/dist/bg/17.webp +0 -0
- package/dist/bg/18.webp +0 -0
- package/dist/bg/19.webp +0 -0
- package/dist/bg/2.webp +0 -0
- package/dist/bg/20.webp +0 -0
- package/dist/bg/21.webp +0 -0
- package/dist/bg/22.webp +0 -0
- package/dist/bg/3.webp +0 -0
- package/dist/bg/4.webp +0 -0
- package/dist/bg/5.webp +0 -0
- package/dist/bg/6.webp +0 -0
- package/dist/bg/7.webp +0 -0
- package/dist/bg/8.webp +0 -0
- package/dist/bg/9.webp +0 -0
- package/dist/components/ai/CodeBlock/CodeBlock.theme.js +1 -1
- package/dist/components/ai/PromptInput/PromptInput.js +7 -140
- package/dist/components/ai/PromptInput/VoiceRecorder.js +0 -85
- package/dist/components/ai/TokenCounter/TokenCounter.theme.js +1 -1
- package/dist/components/canvas/Background.d.ts +19 -0
- package/dist/components/canvas/Background.js +23 -0
- package/dist/components/canvas/BaseNode.d.ts +15 -0
- package/dist/components/canvas/BaseNode.js +20 -0
- package/dist/components/canvas/CanvasToolbar.d.ts +34 -0
- package/dist/components/canvas/CanvasToolbar.js +34 -0
- package/dist/components/canvas/Edge.d.ts +35 -0
- package/dist/components/canvas/Edge.js +97 -0
- package/dist/components/canvas/EdgeLayer.d.ts +18 -0
- package/dist/components/canvas/EdgeLayer.js +111 -0
- package/dist/components/canvas/Handle.d.ts +11 -0
- package/dist/components/canvas/Handle.js +63 -0
- package/dist/components/canvas/MiniMap.d.ts +22 -0
- package/dist/components/canvas/MiniMap.js +105 -0
- package/dist/components/canvas/NodeCanvas.d.ts +10 -0
- package/dist/components/canvas/NodeCanvas.js +477 -0
- package/dist/components/canvas/NodeCanvas.theme.d.ts +7 -0
- package/dist/components/canvas/NodeCanvas.theme.js +9 -0
- package/dist/components/canvas/NodeCanvas.types.d.ts +187 -0
- package/dist/components/canvas/NodeControls.d.ts +25 -0
- package/dist/components/canvas/NodeControls.js +40 -0
- package/dist/components/canvas/NodeRenderer.d.ts +19 -0
- package/dist/components/canvas/NodeRenderer.js +117 -0
- package/dist/components/canvas/changes.d.ts +11 -0
- package/dist/components/canvas/changes.js +76 -0
- package/dist/components/canvas/context/CanvasContext.d.ts +32 -0
- package/dist/components/canvas/context/CanvasContext.js +14 -0
- package/dist/components/canvas/context/ConnectionContext.d.ts +33 -0
- package/dist/components/canvas/context/ConnectionContext.js +13 -0
- package/dist/components/canvas/context/HandleRegistry.d.ts +24 -0
- package/dist/components/canvas/context/HandleRegistry.js +15 -0
- package/dist/components/canvas/context/InteractionContext.d.ts +18 -0
- package/dist/components/canvas/context/InteractionContext.js +14 -0
- package/dist/components/canvas/context/NodeIdContext.d.ts +3 -0
- package/dist/components/canvas/context/NodeIdContext.js +15 -0
- package/dist/components/canvas/hooks/useConnection.d.ts +17 -0
- package/dist/components/canvas/hooks/useConnection.js +29 -0
- package/dist/components/canvas/hooks/useMarquee.d.ts +25 -0
- package/dist/components/canvas/hooks/useMarquee.js +91 -0
- package/dist/components/canvas/hooks/useNodeDrag.d.ts +23 -0
- package/dist/components/canvas/hooks/useNodeDrag.js +110 -0
- package/dist/components/canvas/hooks/usePanZoom.d.ts +30 -0
- package/dist/components/canvas/hooks/usePanZoom.js +189 -0
- package/dist/components/canvas/hooks/useViewport.d.ts +21 -0
- package/dist/components/canvas/hooks/useViewport.js +35 -0
- package/dist/components/canvas/index.d.ts +14 -0
- package/dist/components/canvas/index.js +12 -0
- package/dist/components/canvas/layout.d.ts +22 -0
- package/dist/components/canvas/layout.js +67 -0
- package/dist/components/canvas/utils.d.ts +4 -0
- package/dist/components/canvas/utils.js +16 -0
- package/dist/components/charts/AreaChart/AreaChart.js +136 -101
- package/dist/components/charts/AreaChart/AreaChart.types.d.ts +5 -5
- package/dist/components/charts/AreaChart/AreaChart.types.js +1 -0
- package/dist/components/charts/BarChart/BarChart.js +207 -143
- package/dist/components/charts/BarChart/BarChart.types.d.ts +4 -4
- package/dist/components/charts/BarChart/BarChart.types.js +1 -0
- package/dist/components/charts/ComboChart/ComboChart.types.d.ts +2 -2
- package/dist/components/charts/LineChart/LineChart.js +88 -72
- package/dist/components/charts/LineChart/LineChart.types.d.ts +3 -3
- package/dist/components/charts/RadarChart/RadarChart.js +1 -1
- package/dist/components/charts/RadarChart/RadarChart.theme.js +5 -2
- package/dist/components/charts/ScatterPlot/ScatterPlot.js +62 -72
- package/dist/components/charts/ScatterPlot/ScatterPlot.theme.js +10 -1
- package/dist/components/charts/ScatterPlot/ScatterPlot.types.d.ts +3 -9
- package/dist/components/charts/StackedBarChart/StackedBarChart.js +33 -33
- package/dist/components/charts/StackedBarChart/StackedBarChart.types.d.ts +2 -2
- package/dist/components/charts/hooks/index.d.ts +2 -0
- package/dist/components/charts/hooks/useChartDimensions.d.ts +29 -0
- package/dist/components/charts/hooks/useChartDimensions.js +42 -0
- package/dist/components/charts/shared/ChartTooltip/ChartTooltip.theme.js +1 -1
- package/dist/components/charts/types/chart.types.d.ts +11 -2
- package/dist/components/charts/types/chart.types.js +10 -3
- package/dist/components/core/Avatar/Avatar.js +5 -1
- package/dist/components/core/AvatarGroup/AvatarGroup.js +5 -1
- package/dist/components/core/AvatarGroup/AvatarGroup.theme.js +4 -2
- package/dist/components/core/Badge/Badge.js +1 -1
- package/dist/components/core/Badge/Badge.theme.js +16 -15
- package/dist/components/core/Button/Button.js +1 -1
- package/dist/components/core/Button/Button.theme.js +3 -3
- package/dist/components/core/Calendar/Calendar.theme.js +1 -1
- package/dist/components/core/Card/Card.js +7 -3
- package/dist/components/core/Card/Card.theme.js +3 -3
- package/dist/components/core/Card/Card.types.d.ts +27 -2
- package/dist/components/core/CommandPalette/CommandItem.js +4 -5
- package/dist/components/core/CommandPalette/CommandPalette.js +1 -1
- package/dist/components/core/CommandPalette/CommandPalette.theme.js +11 -13
- package/dist/components/core/CommandPalette/CommandPalette.types.d.ts +0 -2
- package/dist/components/core/ContextMenu/ContextMenu.theme.js +14 -15
- package/dist/components/core/ContextMenu/ContextMenuItem.js +1 -1
- package/dist/components/core/ContextMenu/ContextMenuSubTrigger.js +1 -1
- package/dist/components/core/DotSeparator/DotSeparator.d.ts +3 -0
- package/dist/components/core/DotSeparator/DotSeparator.js +19 -0
- package/dist/components/core/DotSeparator/DotSeparator.theme.d.ts +2 -0
- package/dist/components/core/DotSeparator/DotSeparator.theme.js +10 -0
- package/dist/components/core/DotSeparator/DotSeparator.types.d.ts +25 -0
- package/dist/components/core/DotSeparator/index.d.ts +3 -0
- package/dist/components/core/Dropdown/Dropdown.theme.js +5 -6
- package/dist/components/core/Dropdown/DropdownItem.js +1 -1
- package/dist/components/core/Dropdown/DropdownMenu.js +58 -30
- package/dist/components/core/HeroCard/HeroCard.d.ts +5 -0
- package/dist/components/core/HeroCard/HeroCard.js +99 -0
- package/dist/components/core/HeroCard/HeroCard.theme.d.ts +3 -0
- package/dist/components/core/HeroCard/HeroCard.theme.js +8 -0
- package/dist/components/core/HeroCard/HeroCard.types.d.ts +70 -0
- package/dist/components/core/HeroCard/index.d.ts +4 -0
- package/dist/components/core/Kbd/Kbd.theme.js +1 -1
- package/dist/components/core/MenuItem/MenuItem.js +5 -2
- package/dist/components/core/MenuItem/MenuItem.theme.d.ts +6 -0
- package/dist/components/core/MenuItem/MenuItem.theme.js +19 -16
- package/dist/components/core/MenuItem/MenuItem.types.d.ts +2 -0
- package/dist/components/core/Modal/Modal.d.ts +1 -1
- package/dist/components/core/Modal/Modal.js +2 -7
- package/dist/components/core/Modal/Modal.theme.js +4 -8
- package/dist/components/core/Modal/Modal.types.d.ts +0 -10
- package/dist/components/core/Modal/index.d.ts +1 -1
- package/dist/components/core/ModalStack/ModalStack.d.ts +1 -1
- package/dist/components/core/ModalStack/ModalStack.types.d.ts +1 -2
- package/dist/components/core/ModalStack/ModalStackModal.d.ts +1 -1
- package/dist/components/core/ModalStack/ModalStackModal.js +2 -7
- package/dist/components/core/NavItem/NavItem.js +20 -4
- package/dist/components/core/NavItem/NavItem.theme.js +13 -2
- package/dist/components/core/PageHeading/PageHeading.theme.js +2 -2
- package/dist/components/core/Popover/Popover.theme.js +1 -1
- package/dist/components/core/Popover/Popover.types.d.ts +6 -2
- package/dist/components/core/Popover/PopoverBody.js +10 -3
- package/dist/components/core/ScrollArea/ScrollArea.js +242 -4
- package/dist/components/core/ScrollArea/ScrollArea.types.d.ts +12 -1
- package/dist/components/core/ScrollArea/smooth/SmoothScrollEngine.d.ts +4 -0
- package/dist/components/core/ScrollArea/smooth/SmoothScrollEngine.js +23 -0
- package/dist/components/core/ScrollArea/smooth/useSmoothScroll.js +4 -0
- package/dist/components/core/ScrollArea/smooth/useSmoothScroll.types.d.ts +5 -0
- package/dist/components/core/Segmented/Segmented.theme.js +2 -2
- package/dist/components/core/Sidebar/Sidebar.d.ts +2 -0
- package/dist/components/core/Sidebar/Sidebar.js +15 -7
- package/dist/components/core/Sidebar/Sidebar.types.d.ts +92 -4
- package/dist/components/core/Sidebar/SidebarCard.d.ts +25 -0
- package/dist/components/core/Sidebar/SidebarCard.js +68 -0
- package/dist/components/core/Sidebar/SidebarCard.theme.d.ts +8 -0
- package/dist/components/core/Sidebar/SidebarCard.theme.js +18 -0
- package/dist/components/core/Sidebar/SidebarContent.js +5 -1
- package/dist/components/core/Sidebar/SidebarContext.js +1 -1
- package/dist/components/core/Sidebar/SidebarHeader.js +10 -2
- package/dist/components/core/Sidebar/SidebarLogo.js +38 -3
- package/dist/components/core/Sidebar/SidebarSearch.d.ts +22 -0
- package/dist/components/core/Sidebar/SidebarSearch.js +135 -0
- package/dist/components/core/Sidebar/SidebarToggle.js +1 -1
- package/dist/components/core/Sidebar/SidebarUserProfile.js +2 -2
- package/dist/components/core/Sidebar/index.d.ts +3 -1
- package/dist/components/core/Tag/Tag.js +29 -5
- package/dist/components/core/Tag/Tag.theme.js +13 -8
- package/dist/components/core/Tag/Tag.types.d.ts +7 -0
- package/dist/components/core/Tooltip/Tooltip.js +1 -1
- package/dist/components/core/Tooltip/Tooltip.theme.js +1 -2
- package/dist/components/core/index.d.ts +2 -0
- package/dist/components/core/index.js +6 -0
- package/dist/components/data-display/DescriptionList/DescriptionList.js +23 -7
- package/dist/components/data-display/DescriptionList/DescriptionList.theme.js +10 -3
- package/dist/components/data-display/DescriptionList/DescriptionList.types.d.ts +49 -10
- package/dist/components/data-display/DescriptionList/index.d.ts +1 -1
- package/dist/components/data-display/Feed/Feed.js +28 -5
- package/dist/components/data-display/Feed/Feed.theme.js +1 -1
- package/dist/components/data-display/Feed/Feed.types.d.ts +32 -1
- package/dist/components/data-display/Feed/index.d.ts +1 -1
- package/dist/components/data-display/GanttChart/GanttChart.d.ts +1 -1
- package/dist/components/data-display/GanttChart/GanttChart.js +31 -4
- package/dist/components/data-display/GanttChart/GanttChart.theme.js +19 -17
- package/dist/components/data-display/GanttChart/GanttChart.types.d.ts +19 -0
- package/dist/components/data-display/GanttChart/GanttChart.utils.js +1 -1
- package/dist/components/data-display/GanttChart/GanttChartPanel.d.ts +1 -1
- package/dist/components/data-display/GanttChart/GanttChartPanel.js +3 -3
- package/dist/components/data-display/GanttChart/GanttDependencyArrows.js +7 -4
- package/dist/components/data-display/GanttChart/GanttMilestone.js +5 -5
- package/dist/components/data-display/GanttChart/GanttTablePanel.js +1 -1
- package/dist/components/data-display/GanttChart/GanttTableTaskRow.js +2 -2
- package/dist/components/data-display/GanttChart/GanttTaskBar.js +37 -16
- package/dist/components/data-display/GanttChart/GanttTimelineGrid.js +2 -1
- package/dist/components/data-display/GanttChart/GanttTimelineHeader.js +35 -11
- package/dist/components/data-display/GanttChart/GanttToolbar.js +2 -2
- package/dist/components/data-display/GanttChart/hooks/useGanttDrag.js +3 -2
- package/dist/components/data-display/GanttChart/index.d.ts +1 -1
- package/dist/components/data-display/Metric/Metric.js +8 -8
- package/dist/components/data-display/Metric/Metric.theme.d.ts +3 -2
- package/dist/components/data-display/Metric/Metric.theme.js +50 -68
- package/dist/components/data-display/Metric/Metric.types.d.ts +19 -21
- package/dist/components/data-display/Table/Table.js +2 -2
- package/dist/components/data-display/Table/Table.theme.js +27 -9
- package/dist/components/data-display/Table/Table.types.d.ts +8 -0
- package/dist/components/data-display/Table/TableBody.js +2 -2
- package/dist/components/data-display/Table/TableCell.js +1 -1
- package/dist/components/data-display/Table/TableRow.d.ts +1 -1
- package/dist/components/data-display/Table/TableRow.js +9 -2
- package/dist/components/data-display/Timeline/Timeline.js +27 -5
- package/dist/components/data-display/Timeline/Timeline.theme.d.ts +10 -2
- package/dist/components/data-display/Timeline/Timeline.theme.js +14 -8
- package/dist/components/data-display/Timeline/Timeline.types.d.ts +48 -16
- package/dist/components/data-display/Timeline/Timeline.utils.d.ts +6 -0
- package/dist/components/data-display/Timeline/Timeline.utils.js +11 -0
- package/dist/components/data-display/Timeline/TimelineItem.js +13 -20
- package/dist/components/data-display/Timeline/TimelineMarker.js +10 -8
- package/dist/components/data-display/Timeline/index.d.ts +2 -2
- package/dist/components/effects/3d/index.d.ts +0 -2
- package/dist/components/effects/3d/index.js +0 -1
- package/dist/components/effects/Aurora/Aurora.d.ts +6 -17
- package/dist/components/effects/Aurora/Aurora.js +297 -131
- package/dist/components/effects/Aurora/Aurora.types.d.ts +6 -0
- package/dist/components/effects/DotPattern/DotPattern.js +1 -1
- package/dist/components/effects/Overlay/Overlay.theme.js +1 -2
- package/dist/components/effects/Preloader/Preloader.animations.d.ts +23 -0
- package/dist/components/effects/Preloader/Preloader.animations.js +150 -0
- package/dist/components/effects/Preloader/Preloader.d.ts +3 -0
- package/dist/components/effects/Preloader/Preloader.js +119 -0
- package/dist/components/effects/Preloader/Preloader.types.d.ts +63 -0
- package/dist/components/effects/Preloader/index.d.ts +2 -0
- package/dist/components/effects/ProgressiveBlur/ProgressiveBlur.js +25 -14
- package/dist/components/effects/ProgressiveBlur/ProgressiveBlur.types.d.ts +2 -0
- package/dist/components/effects/TiltCard/TiltCard.d.ts +12 -0
- package/dist/components/effects/TiltCard/TiltCard.glow.d.ts +28 -0
- package/dist/components/effects/TiltCard/TiltCard.glow.js +114 -0
- package/dist/components/effects/TiltCard/TiltCard.js +177 -0
- package/dist/components/effects/{SpotlightBorder/SpotlightBorder.shaders.d.ts → TiltCard/TiltCard.shaders.d.ts} +1 -1
- package/dist/components/effects/{SpotlightBorder/SpotlightBorder.shaders.js → TiltCard/TiltCard.shaders.js} +1 -1
- package/dist/components/effects/TiltCard/TiltCard.types.d.ts +88 -0
- package/dist/components/effects/TiltCard/index.d.ts +2 -0
- package/dist/components/effects/index.d.ts +4 -12
- package/dist/components/effects/index.js +2 -6
- package/dist/components/forms/Checkbox/Checkbox.js +7 -1
- package/dist/components/forms/Combobox/Combobox.js +1 -1
- package/dist/components/forms/Combobox/Combobox.theme.js +2 -4
- package/dist/components/forms/DatePicker/DatePicker.theme.js +11 -18
- package/dist/components/forms/DatePicker/DatePickerTrigger.js +1 -1
- package/dist/components/forms/DateRangePicker/DateRangePicker.theme.js +6 -13
- package/dist/components/forms/DateRangePicker/DateRangePickerTrigger.js +1 -1
- package/dist/components/forms/FileUpload/FileUpload.animations.d.ts +29 -0
- package/dist/components/forms/FileUpload/FileUpload.animations.js +19 -0
- package/dist/components/forms/FileUpload/FileUpload.js +85 -134
- package/dist/components/forms/FileUpload/FileUpload.theme.d.ts +2 -10
- package/dist/components/forms/FileUpload/FileUpload.theme.js +16 -30
- package/dist/components/forms/FileUpload/FileUpload.types.d.ts +26 -10
- package/dist/components/forms/FormLabel/FormLabel.theme.js +1 -1
- package/dist/components/forms/Input/Input.theme.js +13 -10
- package/dist/components/forms/InputCounter/InputCounter.theme.js +1 -1
- package/dist/components/forms/Mention/Mention.js +152 -57
- package/dist/components/forms/Mention/Mention.theme.js +16 -23
- package/dist/components/forms/Mention/Mention.types.d.ts +12 -12
- package/dist/components/forms/Mention/Mention.utils.js +32 -4
- package/dist/components/forms/RichTextEditor/RichTextEditor.js +3 -3
- package/dist/components/forms/RichTextEditor/RichTextEditor.theme.js +5 -5
- package/dist/components/forms/Select/Select.js +2 -2
- package/dist/components/forms/Select/Select.theme.js +3 -3
- package/dist/components/forms/Slider/Slider.theme.js +1 -1
- package/dist/components/forms/Switch/Switch.js +27 -15
- package/dist/components/forms/Switch/Switch.theme.d.ts +36 -6
- package/dist/components/forms/Switch/Switch.theme.js +33 -4
- package/dist/components/forms/Switch/Switch.types.d.ts +12 -2
- package/dist/components/forms/TimePicker/TimePicker.theme.js +1 -2
- package/dist/components/forms/TimePicker/TimePickerContent.js +1 -87
- package/dist/components/forms/TimePicker/TimePickerTrigger.js +1 -1
- package/dist/components/forms/forms.theme.js +21 -16
- package/dist/components/forms/index.d.ts +0 -4
- package/dist/components/forms/index.js +0 -89
- package/dist/components/generative/GenerativeView.d.ts +21 -0
- package/dist/components/generative/GenerativeView.js +116 -0
- package/dist/components/generative/actions.d.ts +26 -0
- package/dist/components/generative/actions.js +51 -0
- package/dist/components/generative/index.d.ts +11 -0
- package/dist/components/generative/index.js +9 -0
- package/dist/components/generative/registry.d.ts +43 -0
- package/dist/components/generative/registry.js +114 -0
- package/dist/components/generative/resolvers.d.ts +35 -0
- package/dist/components/generative/resolvers.js +93 -0
- package/dist/components/generative/schema.generated.d.ts +2 -0
- package/dist/components/generative/schema.generated.js +1639 -0
- package/dist/components/generative/schemaTypes.d.ts +30 -0
- package/dist/components/generative/streaming.d.ts +39 -0
- package/dist/components/generative/streaming.js +283 -0
- package/dist/components/generative/tools.d.ts +21 -0
- package/dist/components/generative/tools.js +54 -0
- package/dist/components/generative/types.d.ts +41 -0
- package/dist/components/generative/useGenerativeStream.d.ts +37 -0
- package/dist/components/generative/useGenerativeStream.js +36 -0
- package/dist/components/generative/validate.d.ts +24 -0
- package/dist/components/generative/validate.js +259 -0
- package/dist/components/layout/AppShell/AppShell.d.ts +10 -0
- package/dist/components/layout/AppShell/AppShell.js +84 -0
- package/dist/components/layout/AppShell/AppShell.theme.d.ts +3 -0
- package/dist/components/layout/AppShell/AppShell.theme.js +42 -0
- package/dist/components/layout/AppShell/AppShell.types.d.ts +127 -0
- package/dist/components/layout/AppShell/AppShellContext.d.ts +14 -0
- package/dist/components/layout/AppShell/AppShellContext.js +19 -0
- package/dist/components/layout/AppShell/AppShellFooter.d.ts +3 -0
- package/dist/components/layout/AppShell/AppShellFooter.js +12 -0
- package/dist/components/layout/AppShell/AppShellHeader.d.ts +3 -0
- package/dist/components/layout/AppShell/AppShellHeader.js +12 -0
- package/dist/components/layout/AppShell/AppShellMain.d.ts +3 -0
- package/dist/components/layout/AppShell/AppShellMain.js +19 -0
- package/dist/components/layout/AppShell/AppShellRightPanel.d.ts +3 -0
- package/dist/components/layout/AppShell/AppShellRightPanel.js +16 -0
- package/dist/components/layout/AppShell/AppShellSidebar.d.ts +3 -0
- package/dist/components/layout/AppShell/AppShellSidebar.js +16 -0
- package/dist/components/layout/AppShell/AppShellTopbar.d.ts +3 -0
- package/dist/components/layout/AppShell/AppShellTopbar.js +12 -0
- package/dist/components/layout/AppShell/index.d.ts +3 -0
- package/dist/components/layout/FormLayout/FormLayout.js +1 -87
- package/dist/components/layout/Grid/Grid.d.ts +3 -0
- package/dist/components/layout/Grid/Grid.js +50 -0
- package/dist/components/layout/Grid/Grid.theme.d.ts +2 -0
- package/dist/components/layout/Grid/Grid.theme.js +35 -0
- package/dist/components/layout/Grid/Grid.types.d.ts +57 -0
- package/dist/components/layout/Grid/index.d.ts +3 -0
- package/dist/components/layout/Section/Section.d.ts +3 -0
- package/dist/components/layout/Section/Section.js +18 -0
- package/dist/components/layout/Section/Section.theme.d.ts +2 -0
- package/dist/components/layout/Section/Section.theme.js +10 -0
- package/dist/components/layout/Section/Section.types.d.ts +34 -0
- package/dist/components/layout/Section/index.d.ts +3 -0
- package/dist/components/layout/Stack/Stack.d.ts +3 -0
- package/dist/components/layout/Stack/Stack.js +19 -0
- package/dist/components/layout/Stack/Stack.theme.d.ts +2 -0
- package/dist/components/layout/Stack/Stack.theme.js +10 -0
- package/dist/components/layout/Stack/Stack.types.d.ts +39 -0
- package/dist/components/layout/Stack/index.d.ts +3 -0
- package/dist/components/layout/index.d.ts +4 -0
- package/dist/components/layout/index.js +8 -0
- package/dist/generative.schema.json +1637 -0
- package/dist/hooks/useSelectPortal.d.ts +10 -2
- package/dist/hooks/useSelectPortal.js +45 -24
- package/dist/index.js +180 -174
- package/dist/registry.json +10205 -0
- package/dist/styles.css +1 -1
- package/dist/tools.json +1731 -0
- package/dist/utils/dateUtils.js +11 -1
- package/package.json +19 -4
- package/src/global.scss +82 -109
- package/src/styles/theme.css +707 -474
- package/dist/bg/1.jpg +0 -0
- package/dist/bg/10.jpg +0 -0
- package/dist/bg/11.jpg +0 -0
- package/dist/bg/14.jpg +0 -0
- package/dist/bg/15.jpg +0 -0
- package/dist/bg/16.jpg +0 -0
- package/dist/bg/17.jpg +0 -0
- package/dist/bg/18.jpg +0 -0
- package/dist/bg/19.jpg +0 -0
- package/dist/bg/2.jpg +0 -0
- package/dist/bg/20.jpg +0 -0
- package/dist/bg/21.jpg +0 -0
- package/dist/bg/22.jpg +0 -0
- package/dist/bg/23.jpg +0 -0
- package/dist/bg/24.jpg +0 -0
- package/dist/bg/3.jpg +0 -0
- package/dist/bg/4.jpg +0 -0
- package/dist/bg/5.jpg +0 -0
- package/dist/bg/6.jpg +0 -0
- package/dist/bg/7.jpg +0 -0
- package/dist/bg/8.jpg +0 -0
- package/dist/bg/9.jpg +0 -0
- package/dist/components/effects/MorphingText/MorphingText.d.ts +0 -17
- package/dist/components/effects/MorphingText/MorphingText.js +0 -125
- package/dist/components/effects/MorphingText/MorphingText.types.d.ts +0 -18
- package/dist/components/effects/MorphingText/index.d.ts +0 -2
- package/dist/components/effects/PageTransition/PageTransition.animations.d.ts +0 -8
- package/dist/components/effects/PageTransition/PageTransition.animations.js +0 -53
- package/dist/components/effects/PageTransition/PageTransition.d.ts +0 -3
- package/dist/components/effects/PageTransition/PageTransition.js +0 -82
- package/dist/components/effects/PageTransition/PageTransition.types.d.ts +0 -15
- package/dist/components/effects/PageTransition/index.d.ts +0 -2
- package/dist/components/effects/ParallaxSection/ParallaxSection.d.ts +0 -26
- package/dist/components/effects/ParallaxSection/ParallaxSection.js +0 -71
- package/dist/components/effects/ParallaxSection/ParallaxSection.types.d.ts +0 -11
- package/dist/components/effects/ParallaxSection/index.d.ts +0 -2
- package/dist/components/effects/Spotlight/Spotlight.d.ts +0 -36
- package/dist/components/effects/Spotlight/Spotlight.js +0 -112
- package/dist/components/effects/Spotlight/Spotlight.types.d.ts +0 -29
- package/dist/components/effects/Spotlight/index.d.ts +0 -2
- package/dist/components/effects/SpotlightBorder/SpotlightBorder.d.ts +0 -18
- package/dist/components/effects/SpotlightBorder/SpotlightBorder.js +0 -213
- package/dist/components/effects/SpotlightBorder/SpotlightBorder.types.d.ts +0 -61
- package/dist/components/effects/SpotlightBorder/index.d.ts +0 -2
- package/dist/components/effects/StickyScroll/StickyScroll.d.ts +0 -30
- package/dist/components/effects/StickyScroll/StickyScroll.js +0 -128
- package/dist/components/effects/StickyScroll/StickyScroll.types.d.ts +0 -19
- package/dist/components/effects/StickyScroll/index.d.ts +0 -2
- package/dist/components/forms/CronInput/CronInput.d.ts +0 -3
- package/dist/components/forms/CronInput/CronInput.js +0 -113
- package/dist/components/forms/CronInput/CronInput.theme.d.ts +0 -6
- package/dist/components/forms/CronInput/CronInput.theme.js +0 -84
- package/dist/components/forms/CronInput/CronInput.types.d.ts +0 -109
- package/dist/components/forms/CronInput/CronInput.utils.d.ts +0 -67
- package/dist/components/forms/CronInput/CronInput.utils.js +0 -505
- package/dist/components/forms/CronInput/index.d.ts +0 -4
- /package/dist/components/effects/{SpotlightBorder/SpotlightBorder.types.js → TiltCard/TiltCard.types.js} +0 -0
|
@@ -10,7 +10,7 @@ const sliderTheme = {
|
|
|
10
10
|
// Root container with layout
|
|
11
11
|
rootStyle: "relative flex items-center w-full touch-none select-none data-[orientation=vertical]:flex-col data-[orientation=vertical]:h-full",
|
|
12
12
|
// Track (background)
|
|
13
|
-
trackStyle: "relative w-full h-2 grow rounded-full bg-[var(--color-surface-sunken)] overflow-hidden data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50 data-[orientation=vertical]:w-2 data-[orientation=vertical]:h-full shadow-inner",
|
|
13
|
+
trackStyle: "relative w-full h-2 grow rounded-full bg-[var(--color-surface-sunken)] overflow-hidden data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50 data-[orientation=vertical]:w-2 data-[orientation=vertical]:h-full shadow-inner-real-sm",
|
|
14
14
|
// Range (filled portion) - rounded to match track clipping
|
|
15
15
|
rangeStyle: "absolute h-full bg-gradient-to-r from-[var(--color-primary-500)] to-[var(--color-primary-700)] transition-all rounded-full data-[disabled]:bg-[var(--color-background-disabled)] data-[invalid]:bg-[var(--color-danger)]",
|
|
16
16
|
// Thumb (draggable handle)
|
|
@@ -1,23 +1,27 @@
|
|
|
1
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
2
|
import React__default, { useState } from 'react';
|
|
3
3
|
import { FormLabel } from '../FormLabel/FormLabel.js';
|
|
4
|
-
import { motion } from 'motion/react';
|
|
4
|
+
import { useReducedMotion, motion } from 'motion/react';
|
|
5
5
|
import { switchTheme, thumbPositions } from './Switch.theme.js';
|
|
6
6
|
import { cn } from '../../../utils/cn.js';
|
|
7
7
|
|
|
8
|
+
const indicatorTransition = {
|
|
9
|
+
duration: 0.6,
|
|
10
|
+
ease: [0.22, 1, 0.36, 1],
|
|
11
|
+
};
|
|
8
12
|
/**
|
|
9
13
|
* Switch component for toggling between two states
|
|
10
14
|
*/
|
|
11
15
|
const Switch = React__default.forwardRef(({ id, checked: controlledChecked, defaultChecked, onChange, label, description, state = "default", labelPosition = "end", size = "md", theme, className, name, value, required, form, ...rest }, ref) => {
|
|
12
16
|
const generatedId = React__default.useId();
|
|
13
17
|
const switchId = id !== null && id !== void 0 ? id : generatedId;
|
|
18
|
+
const shouldReduceMotion = useReducedMotion();
|
|
14
19
|
const [internalChecked, setInternalChecked] = useState(defaultChecked !== null && defaultChecked !== void 0 ? defaultChecked : false);
|
|
15
20
|
// Determine if component is controlled or uncontrolled
|
|
16
21
|
const isControlled = controlledChecked !== undefined;
|
|
17
22
|
const isChecked = isControlled ? controlledChecked : internalChecked;
|
|
18
23
|
// Derive state flags
|
|
19
24
|
const isDisabled = state === "disabled";
|
|
20
|
-
const isInvalid = state === "invalid";
|
|
21
25
|
const handleChange = (e) => {
|
|
22
26
|
if (isDisabled)
|
|
23
27
|
return;
|
|
@@ -30,22 +34,30 @@ const Switch = React__default.forwardRef(({ id, checked: controlledChecked, defa
|
|
|
30
34
|
const labelContent = label || description ? (jsxs("div", { className: "flex grow flex-col", children: [label &&
|
|
31
35
|
(typeof label === "string" ? (jsx(FormLabel, { htmlFor: switchId, state: state, children: label })) : (label)), description &&
|
|
32
36
|
(typeof description === "string" ? (jsx("div", { className: cn(switchTheme.description, theme === null || theme === void 0 ? void 0 : theme.description), children: description })) : (description))] })) : null;
|
|
33
|
-
//
|
|
37
|
+
// Hook only — emitted as `data-state` for consumer CSS / tests, NOT used for styling
|
|
34
38
|
const trackDataState = isDisabled
|
|
35
39
|
? "disabled"
|
|
36
|
-
:
|
|
37
|
-
? "
|
|
38
|
-
:
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
const
|
|
40
|
+
: isChecked
|
|
41
|
+
? "checked"
|
|
42
|
+
: "unchecked";
|
|
43
|
+
// Resolve track state styling in JS (base theme + per-state theme override),
|
|
44
|
+
// layered so `className`/`theme` overrides win — see Switch.theme.ts rationale.
|
|
45
|
+
const resolveTrackState = (key) => { var _a; return cn(switchTheme.trackStates[key], (_a = theme === null || theme === void 0 ? void 0 : theme.trackStates) === null || _a === void 0 ? void 0 : _a[key]); };
|
|
46
|
+
const trackStateClasses = cn(isChecked ? resolveTrackState("checked") : resolveTrackState("unchecked"), isDisabled && resolveTrackState("disabled"));
|
|
42
47
|
// Switch toggle component
|
|
43
|
-
const switchToggle = (
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
48
|
+
const switchToggle = (jsx("div", { className: "relative flex items-center h-6", children: jsxs("label", { htmlFor: switchId, className: "contents", children: [jsx("input", { ref: ref, type: "checkbox", id: switchId, checked: isChecked, onChange: handleChange, disabled: isDisabled, className: "peer sr-only", name: name, value: value, required: required, form: form }), jsxs("div", { className: cn(switchTheme.track, switchTheme.trackSizes[size], trackStateClasses, theme === null || theme === void 0 ? void 0 : theme.track), "data-state": trackDataState, "aria-hidden": "true", children: [jsx(motion.div, { className: cn(switchTheme.thumb, switchTheme.thumbSizes[size], !isDisabled && "group-hover:shadow-xl", theme === null || theme === void 0 ? void 0 : theme.thumb), initial: false, animate: isChecked
|
|
49
|
+
? thumbPositions[size].checked
|
|
50
|
+
: thumbPositions[size].unchecked, transition: shouldReduceMotion
|
|
51
|
+
? { duration: 0 }
|
|
52
|
+
: { type: "spring", stiffness: 500, damping: 30 }, whileTap: isDisabled || shouldReduceMotion ? undefined : { scale: 0.94 } }), jsx(motion.div, { className: "pointer-events-none absolute inset-y-0 left-1.5 inline-flex w-2.5 items-center justify-center", initial: false, animate: shouldReduceMotion
|
|
53
|
+
? { opacity: isChecked ? 1 : 0, x: 0, scale: 1 }
|
|
54
|
+
: isChecked
|
|
55
|
+
? { opacity: 1, x: 0, scale: 1 }
|
|
56
|
+
: { opacity: 0, x: -4, scale: 0.78 }, transition: shouldReduceMotion ? { duration: 0 } : indicatorTransition, children: jsx("div", { className: "size-2 rounded-full border-[1.5px] border-white/50" }) }), jsx(motion.div, { className: "pointer-events-none absolute inset-y-0 right-1.5 inline-flex w-2.5 items-center justify-center", initial: false, animate: shouldReduceMotion
|
|
57
|
+
? { opacity: isChecked ? 0 : 1, x: 0, scaleY: 1 }
|
|
58
|
+
: isChecked
|
|
59
|
+
? { opacity: 0, x: 4, scaleY: 0.6 }
|
|
60
|
+
: { opacity: 1, x: 0, scaleY: 1 }, transition: shouldReduceMotion ? { duration: 0 } : indicatorTransition, children: jsx("div", { className: "w-[1.5px] h-2 rounded-full bg-white/50" }) })] })] }) }));
|
|
49
61
|
return (jsxs("div", { className: cn(switchTheme.container, labelPosition === "start" ? "flex-row-reverse" : "flex-row", theme === null || theme === void 0 ? void 0 : theme.container, className), ...rest, children: [labelContent, switchToggle] }));
|
|
50
62
|
});
|
|
51
63
|
Switch.displayName = "Switch";
|
|
@@ -1,18 +1,48 @@
|
|
|
1
1
|
import { SwitchTheme } from "./Switch.types";
|
|
2
2
|
/**
|
|
3
3
|
* Default theme configuration for the Switch component
|
|
4
|
+
*
|
|
5
|
+
* Gold-standard state styling: track state classes live in `trackStates` as
|
|
6
|
+
* plain utility strings and are resolved in JS at render time (see Switch.tsx),
|
|
7
|
+
* NOT as `data-[state=*]:` Tailwind variants. A data-variant compiles to a
|
|
8
|
+
* class + attribute selector (specificity 0,2,0) that beats a plain `className`
|
|
9
|
+
* override (0,1,0) regardless of order, silently breaking the shadcn rule
|
|
10
|
+
* "className override = highest priority". We still emit `data-state` on the
|
|
11
|
+
* track as a hook for consumer CSS / tests — we just don't *style* with it.
|
|
4
12
|
*/
|
|
5
13
|
export declare const switchTheme: SwitchTheme;
|
|
6
14
|
/**
|
|
7
15
|
* Thumb position values for animation
|
|
8
16
|
*/
|
|
9
17
|
export declare const thumbPositions: {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
18
|
+
sm: {
|
|
19
|
+
checked: {
|
|
20
|
+
x: number;
|
|
21
|
+
y: number;
|
|
22
|
+
};
|
|
23
|
+
unchecked: {
|
|
24
|
+
x: number;
|
|
25
|
+
y: number;
|
|
26
|
+
};
|
|
13
27
|
};
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
28
|
+
md: {
|
|
29
|
+
checked: {
|
|
30
|
+
x: number;
|
|
31
|
+
y: number;
|
|
32
|
+
};
|
|
33
|
+
unchecked: {
|
|
34
|
+
x: number;
|
|
35
|
+
y: number;
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
lg: {
|
|
39
|
+
checked: {
|
|
40
|
+
x: number;
|
|
41
|
+
y: number;
|
|
42
|
+
};
|
|
43
|
+
unchecked: {
|
|
44
|
+
x: number;
|
|
45
|
+
y: number;
|
|
46
|
+
};
|
|
17
47
|
};
|
|
18
48
|
};
|
|
@@ -1,10 +1,29 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Default theme configuration for the Switch component
|
|
3
|
+
*
|
|
4
|
+
* Gold-standard state styling: track state classes live in `trackStates` as
|
|
5
|
+
* plain utility strings and are resolved in JS at render time (see Switch.tsx),
|
|
6
|
+
* NOT as `data-[state=*]:` Tailwind variants. A data-variant compiles to a
|
|
7
|
+
* class + attribute selector (specificity 0,2,0) that beats a plain `className`
|
|
8
|
+
* override (0,1,0) regardless of order, silently breaking the shadcn rule
|
|
9
|
+
* "className override = highest priority". We still emit `data-state` on the
|
|
10
|
+
* track as a hook for consumer CSS / tests — we just don't *style* with it.
|
|
3
11
|
*/
|
|
4
12
|
const switchTheme = {
|
|
5
13
|
container: "flex w-full justify-between items-center gap-4",
|
|
6
|
-
|
|
7
|
-
|
|
14
|
+
// Structural base only — no state colors (those live in `trackStates`)
|
|
15
|
+
track: "group rounded-full cursor-pointer shadow-inner-real-sm transition-colors duration-500 motion-reduce:transition-none outline-1 outline-[var(--color-border)] peer-focus-visible:outline-2 peer-focus-visible:outline-offset-2 peer-focus-visible:outline-[var(--color-primary-600)]",
|
|
16
|
+
// Resolved in JS and layered via cn() so later keys win (tailwind-merge dedupes bg-*).
|
|
17
|
+
// No `invalid` key: a switch is binary — on and off are both valid values, so there is
|
|
18
|
+
// nothing to validate. (See §9 carve-out: invalid only applies to controls with a value.)
|
|
19
|
+
trackStates: {
|
|
20
|
+
unchecked: "bg-[var(--color-neutral-200)] dark:bg-[var(--color-neutral-700)]",
|
|
21
|
+
checked: "bg-[var(--color-primary)]",
|
|
22
|
+
disabled: "bg-[var(--color-background-disabled)] cursor-not-allowed",
|
|
23
|
+
},
|
|
24
|
+
// Thumb knob — solid fill + soft elevation. White reads on both the sunken/raised track
|
|
25
|
+
// (light) and the primary/dark track (dark); the faint border separates it on near-white tracks.
|
|
26
|
+
thumb: "rounded-full bg-gradient-to-b from-neutral-200 via-neutral-50 to-white shadow-real-lg border border-white/80 transition-shadow duration-300 motion-reduce:transition-none",
|
|
8
27
|
description: "text-sm text-[var(--color-text-muted)] -mt-1.5",
|
|
9
28
|
trackSizes: {
|
|
10
29
|
sm: "w-9 h-5",
|
|
@@ -21,8 +40,18 @@ const switchTheme = {
|
|
|
21
40
|
* Thumb position values for animation
|
|
22
41
|
*/
|
|
23
42
|
const thumbPositions = {
|
|
24
|
-
|
|
25
|
-
|
|
43
|
+
sm: {
|
|
44
|
+
checked: { x: 14, y: 2 },
|
|
45
|
+
unchecked: { x: 2, y: 2 },
|
|
46
|
+
},
|
|
47
|
+
md: {
|
|
48
|
+
checked: { x: 18, y: 2 },
|
|
49
|
+
unchecked: { x: 2, y: 2 },
|
|
50
|
+
},
|
|
51
|
+
lg: {
|
|
52
|
+
checked: { x: 22, y: 2 },
|
|
53
|
+
unchecked: { x: 2, y: 2 },
|
|
54
|
+
},
|
|
26
55
|
};
|
|
27
56
|
|
|
28
57
|
export { switchTheme, thumbPositions };
|
|
@@ -3,13 +3,21 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export type SwitchLabelPosition = "start" | "end";
|
|
5
5
|
/**
|
|
6
|
-
* State variants for the switch component
|
|
6
|
+
* State variants for the switch component.
|
|
7
|
+
*
|
|
8
|
+
* No `invalid`: a switch is binary — on and off are both valid values, so there is
|
|
9
|
+
* nothing to validate (unlike Input/Checkbox, which can hold/require a specific value).
|
|
7
10
|
*/
|
|
8
|
-
export type SwitchState = 'default' | 'disabled'
|
|
11
|
+
export type SwitchState = 'default' | 'disabled';
|
|
9
12
|
/**
|
|
10
13
|
* Size variants for the switch component
|
|
11
14
|
*/
|
|
12
15
|
export type SwitchSize = 'sm' | 'md' | 'lg';
|
|
16
|
+
/**
|
|
17
|
+
* Resolvable visual states for the track. Layered additively in JS (see Switch.tsx)
|
|
18
|
+
* rather than via `data-[state=*]:` variants, so `className`/`theme` overrides win.
|
|
19
|
+
*/
|
|
20
|
+
export type SwitchTrackState = 'unchecked' | 'checked' | 'disabled';
|
|
13
21
|
/**
|
|
14
22
|
* Switch component props
|
|
15
23
|
*/
|
|
@@ -49,6 +57,7 @@ export interface SwitchProps extends Omit<React.HTMLAttributes<HTMLDivElement>,
|
|
|
49
57
|
export interface SwitchTheme {
|
|
50
58
|
container: string;
|
|
51
59
|
track: string;
|
|
60
|
+
trackStates: Record<SwitchTrackState, string>;
|
|
52
61
|
thumb: string;
|
|
53
62
|
description: string;
|
|
54
63
|
trackSizes: Record<SwitchSize, string>;
|
|
@@ -60,6 +69,7 @@ export interface SwitchTheme {
|
|
|
60
69
|
export interface SwitchThemeOverrides {
|
|
61
70
|
container?: string;
|
|
62
71
|
track?: string;
|
|
72
|
+
trackStates?: Partial<Record<SwitchTrackState, string>>;
|
|
63
73
|
thumb?: string;
|
|
64
74
|
description?: string;
|
|
65
75
|
}
|
|
@@ -38,8 +38,7 @@ const timePickerTheme = {
|
|
|
38
38
|
clearButtonStyle: "absolute right-8 top-1/2 -translate-y-1/2 p-1 rounded text-[var(--color-text-muted)] hover:text-[var(--color-text-primary)] hover:bg-[var(--color-background-secondary)] transition-colors z-10",
|
|
39
39
|
// Dropdown container styles (TimePicker-specific)
|
|
40
40
|
// Width is controlled by trigger size via estimatedWidth parameter
|
|
41
|
-
dropdownStyle: "fixed z-[1000] bg-
|
|
42
|
-
"dark:bg-[var(--color-background-secondary)] ",
|
|
41
|
+
dropdownStyle: "fixed z-[1000] bg-[var(--color-surface-overlay)]/80 backdrop-blur-md border border-[var(--color-border)] rounded-[var(--form-radius)] shadow-lg overflow-hidden",
|
|
43
42
|
// Dropdown size variants - primarily for internal spacing/padding
|
|
44
43
|
dropdownSizes: {
|
|
45
44
|
sm: "",
|
|
@@ -6,95 +6,9 @@ import { cn } from '../../../utils/cn.js';
|
|
|
6
6
|
import { TimePickerContext } from './TimePicker.js';
|
|
7
7
|
import { useSelectPortal } from '../../../hooks/useSelectPortal.js';
|
|
8
8
|
import { createDropdownAnimations } from '../Select/Select.animations.js';
|
|
9
|
-
import '../../core/Accordion/Accordion.js';
|
|
10
|
-
import '../../core/AlertDialog/AlertDialog.js';
|
|
11
|
-
import '../../core/AspectRatio/AspectRatio.js';
|
|
12
|
-
import '../../core/Avatar/Avatar.js';
|
|
13
|
-
import '../../core/AvatarGroup/AvatarGroup.js';
|
|
14
|
-
import '../../core/Badge/Badge.js';
|
|
15
|
-
import '../../core/Breadcrumbs/Breadcrumbs.js';
|
|
16
|
-
import '../../core/Breadcrumbs/Breadcrumbs.theme.js';
|
|
17
|
-
import { Button } from '../../core/Button/Button.js';
|
|
18
|
-
import '../../core/ButtonGroup/ButtonGroup.js';
|
|
19
|
-
import '../../core/ButtonGroup/ButtonGroupSeparator.js';
|
|
20
|
-
import '../../core/ButtonGroup/ButtonGroupText.js';
|
|
21
|
-
import '../../core/Calendar/Calendar.js';
|
|
22
|
-
import '../../core/Calendar/CalendarMini/CalendarMini.js';
|
|
23
|
-
import '../../core/Card/Card.js';
|
|
24
|
-
import '../../core/CardStack/CardStack.js';
|
|
25
|
-
import '../../core/Carousel/Carousel.js';
|
|
26
|
-
import '../../core/Carousel/CarouselBody.js';
|
|
27
|
-
import '../../core/CommandPalette/CommandPalette.js';
|
|
28
|
-
import '../../core/Separator/Separator.js';
|
|
29
|
-
import '../../core/Drawer/Drawer.js';
|
|
30
|
-
import '../../core/Drawer/DrawerBody.js';
|
|
31
|
-
import '../../core/Dropdown/Dropdown.js';
|
|
32
|
-
import '../../core/Dropdown/DropdownTrigger.js';
|
|
33
|
-
import '../../core/Dropdown/DropdownMenu.js';
|
|
34
|
-
import '../../core/Dropdown/DropdownItem.js';
|
|
35
|
-
import '../../core/Dropdown/DropdownSection.js';
|
|
36
|
-
import '../../core/Dropdown/DropdownSeparator.js';
|
|
37
|
-
import '../../core/Dropdown/Dropdown.theme.js';
|
|
38
|
-
import '../../core/Kbd/Kbd.js';
|
|
39
|
-
import '../../core/MenuItem/MenuItem.js';
|
|
40
|
-
import '../../core/Link/Link.js';
|
|
41
|
-
import '../../core/Modal/Modal.js';
|
|
42
|
-
import '../../core/ModalStack/ModalStack.js';
|
|
43
|
-
import '../../core/PageHeading/PageHeading.js';
|
|
44
|
-
import '../../core/Pagination/Pagination.js';
|
|
45
|
-
import '../../core/Popover/Popover.js';
|
|
46
|
-
import '../../core/Popover/PopoverContext.js';
|
|
47
|
-
import '../../core/Popover/PopoverBody.js';
|
|
48
|
-
import '../../core/Progress/Progress.js';
|
|
49
|
-
import '../../core/Rating/Rating.js';
|
|
50
|
-
import '../../core/ScrollArea/ScrollArea.js';
|
|
51
|
-
import '../../core/ScrollArea/smooth/SmoothScrollEngine.js';
|
|
52
|
-
import '../../core/Segmented/Segmented.js';
|
|
53
|
-
import '../../core/Skeleton/Skeleton.js';
|
|
54
|
-
import '../../core/SlidingNumber/SlidingNumber.js';
|
|
55
|
-
import '../../core/Tabs/Tabs.js';
|
|
56
|
-
import '../../core/Tabs/TabsList.js';
|
|
57
|
-
import '../../core/Tabs/TabsTrigger.js';
|
|
58
|
-
import '../../core/Tabs/TabsBody.js';
|
|
59
|
-
import '../../core/Tabs/TabsContext.js';
|
|
60
|
-
import '../../core/Tooltip/Tooltip.js';
|
|
61
|
-
import '../../core/Tooltip/Tooltip.animations.js';
|
|
62
|
-
import '../../core/Tree/Tree.js';
|
|
63
|
-
import '../../core/Tag/Tag.js';
|
|
64
|
-
import '../../core/Alert/Alert.js';
|
|
65
|
-
import '../../core/Toast/Toast.js';
|
|
66
|
-
import '../../core/Toast/ToastProvider.js';
|
|
67
|
-
import '@heroicons/react/24/solid';
|
|
68
|
-
import '../../core/Spinner/Spinner.js';
|
|
69
|
-
import '../../core/Message/Message.js';
|
|
70
|
-
import '../../core/Message/TypeWriter.js';
|
|
71
|
-
import '../../core/Message/MessageBody.js';
|
|
72
|
-
import '@heroicons/react/16/solid';
|
|
73
|
-
import '@heroicons/react/24/outline';
|
|
74
|
-
import '../../core/Empty/Empty.js';
|
|
75
|
-
import '../../core/Masonry/Masonry.js';
|
|
76
|
-
import '../../core/DragDrop/DragDrop.js';
|
|
77
|
-
import '../../core/Sortable/Sortable.js';
|
|
78
|
-
import '../../core/NavItem/NavItem.js';
|
|
79
|
-
import '../../core/Sidebar/Sidebar.js';
|
|
80
|
-
import '../../core/Sidebar/SidebarHeader.js';
|
|
81
|
-
import '../../core/Sidebar/SidebarContent.js';
|
|
82
|
-
import '../../core/Sidebar/SidebarFooter.js';
|
|
83
|
-
import '../../core/Sidebar/SidebarNav.js';
|
|
84
|
-
import '../../core/Sidebar/SidebarNavGroup.js';
|
|
85
|
-
import '../../core/Sidebar/SidebarToggle.js';
|
|
86
|
-
import '../../core/Sidebar/SidebarMobileTrigger.js';
|
|
87
|
-
import '../../core/Sidebar/SidebarUserProfile.js';
|
|
88
|
-
import '../../core/Sidebar/SidebarLogo.js';
|
|
89
|
-
import '../../core/Sidebar/SidebarContext.js';
|
|
90
|
-
import '../../core/OfflineIndicator/OfflineIndicator.js';
|
|
91
|
-
import '../../core/ContextMenu/ContextMenu.js';
|
|
92
|
-
import '../../core/ContextMenu/ContextMenu.theme.js';
|
|
93
|
-
import '../../core/Pill/Pill.js';
|
|
94
|
-
import '../../core/Icon/Icon.js';
|
|
95
|
-
import '../../core/ImagePlaceholder/ImagePlaceholder.js';
|
|
96
9
|
import { useIsClient } from '../../../hooks/useIsClient.js';
|
|
97
10
|
import { useDarkMode } from '../../../hooks/useDarkMode.js';
|
|
11
|
+
import { Button } from '../../core/Button/Button.js';
|
|
98
12
|
|
|
99
13
|
/**
|
|
100
14
|
* TimePickerContent Component - contains the time selector dropdown
|
|
@@ -25,7 +25,7 @@ const TimePickerTrigger = ({ id, disabled, isOpen, state = 'default', size = 'md
|
|
|
25
25
|
const periodToggleStyle = theme.periodToggleStyle || "";
|
|
26
26
|
// Apply focused styles when open — same pattern as SelectButton and DatePickerTrigger
|
|
27
27
|
const activeFocusState = isOpen
|
|
28
|
-
? ((_d = theme.triggerFocusStates) === null || _d === void 0 ? void 0 : _d[state]) || "shadow-[
|
|
28
|
+
? ((_d = theme.triggerFocusStates) === null || _d === void 0 ? void 0 : _d[state]) || "shadow-[inset_0_0_0_1px_var(--color-primary-600)] ring-4 ring-[var(--color-primary)]/10 dark:shadow-[inset_0_0_0_1px_var(--color-primary-500)] dark:ring-[var(--color-primary-500)]/20"
|
|
29
29
|
: "";
|
|
30
30
|
// Determine whether start icon is present (for input padding)
|
|
31
31
|
const hasStartIcon = iconStart !== undefined ? Boolean(iconStart) : true;
|
|
@@ -9,11 +9,13 @@ const formsBaseTheme = {
|
|
|
9
9
|
wrapperStyle: "relative w-full",
|
|
10
10
|
// Common input group style with focus, hover, and state variations
|
|
11
11
|
inputGroupBaseStyle: "relative flex rounded-[var(--form-radius)] outline-none shadow-[inset_0_0_0_1px_var(--color-border)] " +
|
|
12
|
-
"focus-within:shadow-[
|
|
13
|
-
"focus-within:ring-4 focus-within:ring-[var(--color-primary)]/10 bg-
|
|
14
|
-
//
|
|
15
|
-
|
|
16
|
-
"
|
|
12
|
+
"focus-within:shadow-[inset_0_0_0_1px_var(--color-primary-600)] " +
|
|
13
|
+
"focus-within:ring-4 focus-within:ring-[var(--color-primary)]/10 bg-[var(--color-surface)] transition-all " +
|
|
14
|
+
// Hover edge: strengthen the border to --color-border-secondary on hover. Scoped with
|
|
15
|
+
// not-focus-within so focus (primary border) always wins; the token flips for dark mode.
|
|
16
|
+
"not-focus-within:hover:shadow-[inset_0_0_0_1px_var(--color-border-secondary)] " +
|
|
17
|
+
// Dark focus mirror (fill comes from --color-surface, which flips automatically)
|
|
18
|
+
"dark:focus-within:shadow-[inset_0_0_0_1px_var(--color-primary-500)] dark:focus-within:ring-[var(--color-primary-500)]/20",
|
|
17
19
|
// Common base input/control style
|
|
18
20
|
controlBaseStyle: "w-full bg-transparent text-sm text-[var(--color-text-primary)] " +
|
|
19
21
|
"placeholder:text-[var(--color-text-placeholder)] focus:outline-none " +
|
|
@@ -45,24 +47,28 @@ const formsBaseTheme = {
|
|
|
45
47
|
states: {
|
|
46
48
|
default: "",
|
|
47
49
|
disabled: "cursor-not-allowed bg-[var(--color-background-disabled)] shadow-[inset_0_0_0_1px_var(--color-border)] " +
|
|
50
|
+
// Suppress the hover-edge change while disabled (keep the resting border)
|
|
51
|
+
"not-focus-within:hover:shadow-[inset_0_0_0_1px_var(--color-border)] " +
|
|
48
52
|
"[&_input]:text-[var(--color-text-disabled)] [&_textarea]:text-[var(--color-text-disabled)] " +
|
|
49
53
|
"[&_select]:text-[var(--color-text-disabled)] [&_input]:cursor-not-allowed " +
|
|
50
54
|
"[&_textarea]:cursor-not-allowed [&_select]:cursor-not-allowed " +
|
|
51
55
|
"[&_input]:placeholder:text-[var(--color-text-placeholder)] " +
|
|
52
56
|
"[&_textarea]:placeholder:text-[var(--color-text-placeholder)] " +
|
|
53
|
-
"[&_select]:placeholder:text-[var(--color-text-placeholder)] [&_button]:cursor-not-allowed
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
+
"[&_select]:placeholder:text-[var(--color-text-placeholder)] [&_button]:cursor-not-allowed",
|
|
58
|
+
// (--color-background-disabled already flips for dark mode)
|
|
59
|
+
invalid: "shadow-[inset_0_0_0_1px_var(--color-danger)] bg-[var(--color-danger-50)] focus-within:shadow-[inset_0_0_0_1px_var(--color-danger)] " +
|
|
60
|
+
// Keep the danger border on hover (don't let the hover edge override it)
|
|
61
|
+
"not-focus-within:hover:shadow-[inset_0_0_0_1px_var(--color-danger)] " +
|
|
57
62
|
// Dark mode
|
|
58
|
-
"dark:bg-[var(--color-danger-950)]/30 dark:shadow-[inset_0_0_0_1px_var(--color-danger-500)]"
|
|
63
|
+
"dark:bg-[var(--color-danger-950)]/30 dark:shadow-[inset_0_0_0_1px_var(--color-danger-500)] " +
|
|
64
|
+
"dark:not-focus-within:hover:shadow-[inset_0_0_0_1px_var(--color-danger-500)]",
|
|
59
65
|
},
|
|
60
66
|
// Common focus state variants
|
|
61
67
|
focusStates: {
|
|
62
|
-
default: "shadow-[
|
|
63
|
-
"dark:shadow-[
|
|
68
|
+
default: "shadow-[inset_0_0_0_1px_var(--color-primary-600)] ring-4 ring-[var(--color-primary)]/10 " +
|
|
69
|
+
"dark:shadow-[inset_0_0_0_1px_var(--color-primary-500)] dark:ring-[var(--color-primary-500)]/20",
|
|
64
70
|
disabled: "shadow-none",
|
|
65
|
-
invalid: "shadow-[
|
|
71
|
+
invalid: "shadow-[inset_0_0_0_1px_var(--color-danger-500)] ring-4 ring-[var(--color-danger-500)]/10 " +
|
|
66
72
|
"dark:ring-[var(--color-danger-500)]/20",
|
|
67
73
|
},
|
|
68
74
|
// Common hover state variants
|
|
@@ -89,9 +95,8 @@ const formsBaseTheme = {
|
|
|
89
95
|
dropdownStyles: {
|
|
90
96
|
// Container for dropdown panel
|
|
91
97
|
container: "fixed z-[1000] max-h-[var(--select-content-available-height,20rem)] overflow-auto overscroll-contain " +
|
|
92
|
-
"rounded-[var(--form-radius)] bg-
|
|
93
|
-
"shadow-real-lg ring-1 ring-[var(--color-border)] focus:outline-none
|
|
94
|
-
"dark:bg-[var(--color-neutral-900)]/90 dark:ring-[var(--color-neutral-700)]",
|
|
98
|
+
"rounded-[var(--form-radius)] bg-[var(--color-surface-overlay)]/80 backdrop-blur-md text-sm border border-[var(--color-border)] " +
|
|
99
|
+
"shadow-real-lg ring-1 ring-[var(--color-border)] focus:outline-none",
|
|
95
100
|
// Base option style
|
|
96
101
|
option: "relative cursor-pointer select-none py-2 px-3 text-[var(--color-text-primary)] " +
|
|
97
102
|
"hover:text-[var(--color-primary)] hover:bg-[var(--color-primary-50)]/50 " +
|
|
@@ -72,7 +72,3 @@ export { selectableCardTheme } from "./SelectableCard";
|
|
|
72
72
|
export { Mention } from "./Mention";
|
|
73
73
|
export type { MentionProps, MentionSuggestion, MentionTrigger, MentionSize, MentionTheme, MentionThemeOverrides, } from "./Mention";
|
|
74
74
|
export { mentionTheme } from "./Mention";
|
|
75
|
-
export { CronInput } from "./CronInput";
|
|
76
|
-
export type { CronInputProps, CronInputSize, CronInputMode, CronInputTheme, CronInputThemeOverrides, CronFields, CronPreset, } from "./CronInput";
|
|
77
|
-
export { cronInputTheme } from "./CronInput";
|
|
78
|
-
export { parseCron, fieldsToCron, validateCron, cronToDescription, getNextRuns, formatNextRun, CRON_PRESETS, } from "./CronInput";
|
|
@@ -29,92 +29,6 @@ import 'clsx';
|
|
|
29
29
|
import 'tailwind-merge';
|
|
30
30
|
import 'motion/react';
|
|
31
31
|
import 'react-dom';
|
|
32
|
-
import '../core/Accordion/Accordion.js';
|
|
33
|
-
import '../core/AlertDialog/AlertDialog.js';
|
|
34
|
-
import '../core/AspectRatio/AspectRatio.js';
|
|
35
|
-
import '../core/Avatar/Avatar.js';
|
|
36
|
-
import '../core/AvatarGroup/AvatarGroup.js';
|
|
37
|
-
import '../core/Badge/Badge.js';
|
|
38
|
-
import '../core/Breadcrumbs/Breadcrumbs.js';
|
|
39
|
-
import '../core/Breadcrumbs/Breadcrumbs.theme.js';
|
|
40
|
-
import '../core/Button/Button.js';
|
|
41
|
-
import '../core/ButtonGroup/ButtonGroup.js';
|
|
42
|
-
import '../core/ButtonGroup/ButtonGroupSeparator.js';
|
|
43
|
-
import '../core/ButtonGroup/ButtonGroupText.js';
|
|
44
|
-
import '../core/Calendar/Calendar.js';
|
|
45
|
-
import '../core/Calendar/CalendarMini/CalendarMini.js';
|
|
46
|
-
import '../core/Card/Card.js';
|
|
47
|
-
import '../core/CardStack/CardStack.js';
|
|
48
|
-
import '../core/Carousel/Carousel.js';
|
|
49
|
-
import '../core/Carousel/CarouselBody.js';
|
|
50
|
-
import '../core/CommandPalette/CommandPalette.js';
|
|
51
|
-
import '../core/Separator/Separator.js';
|
|
52
|
-
import '../core/Drawer/Drawer.js';
|
|
53
|
-
import '../core/Drawer/DrawerBody.js';
|
|
54
|
-
import '../core/Dropdown/Dropdown.js';
|
|
55
|
-
import '../core/Dropdown/DropdownTrigger.js';
|
|
56
|
-
import '../core/Dropdown/DropdownMenu.js';
|
|
57
|
-
import '../core/Dropdown/DropdownItem.js';
|
|
58
|
-
import '../core/Dropdown/DropdownSection.js';
|
|
59
|
-
import '../core/Dropdown/DropdownSeparator.js';
|
|
60
|
-
import '../core/Dropdown/Dropdown.theme.js';
|
|
61
|
-
import '../core/Kbd/Kbd.js';
|
|
62
|
-
import '../core/MenuItem/MenuItem.js';
|
|
63
|
-
import '../core/Link/Link.js';
|
|
64
|
-
import '../core/Modal/Modal.js';
|
|
65
|
-
import '../core/ModalStack/ModalStack.js';
|
|
66
|
-
import '../core/PageHeading/PageHeading.js';
|
|
67
|
-
import '../core/Pagination/Pagination.js';
|
|
68
|
-
import '../core/Popover/Popover.js';
|
|
69
|
-
import '../core/Popover/PopoverContext.js';
|
|
70
|
-
import '../core/Popover/PopoverBody.js';
|
|
71
|
-
import '../core/Progress/Progress.js';
|
|
72
|
-
import '../core/Rating/Rating.js';
|
|
73
|
-
import '../core/ScrollArea/ScrollArea.js';
|
|
74
|
-
import '../core/ScrollArea/smooth/SmoothScrollEngine.js';
|
|
75
|
-
import '../core/Segmented/Segmented.js';
|
|
76
|
-
import '../core/Skeleton/Skeleton.js';
|
|
77
|
-
import '../core/SlidingNumber/SlidingNumber.js';
|
|
78
|
-
import '../core/Tabs/Tabs.js';
|
|
79
|
-
import '../core/Tabs/TabsList.js';
|
|
80
|
-
import '../core/Tabs/TabsTrigger.js';
|
|
81
|
-
import '../core/Tabs/TabsBody.js';
|
|
82
|
-
import '../core/Tabs/TabsContext.js';
|
|
83
|
-
import '../core/Tooltip/Tooltip.js';
|
|
84
|
-
import '../core/Tooltip/Tooltip.animations.js';
|
|
85
|
-
import '../core/Tree/Tree.js';
|
|
86
|
-
import '../core/Tag/Tag.js';
|
|
87
|
-
import '../core/Alert/Alert.js';
|
|
88
|
-
import '../core/Toast/Toast.js';
|
|
89
|
-
import '../core/Toast/ToastProvider.js';
|
|
90
|
-
import '@heroicons/react/24/solid';
|
|
91
|
-
import '../core/Spinner/Spinner.js';
|
|
92
|
-
import '../core/Message/Message.js';
|
|
93
|
-
import '../core/Message/TypeWriter.js';
|
|
94
|
-
import '../core/Message/MessageBody.js';
|
|
95
|
-
import '@heroicons/react/16/solid';
|
|
96
|
-
import '../core/Empty/Empty.js';
|
|
97
|
-
import '../core/Masonry/Masonry.js';
|
|
98
|
-
import '../core/DragDrop/DragDrop.js';
|
|
99
|
-
import '../core/Sortable/Sortable.js';
|
|
100
|
-
import '../core/NavItem/NavItem.js';
|
|
101
|
-
import '../core/Sidebar/Sidebar.js';
|
|
102
|
-
import '../core/Sidebar/SidebarHeader.js';
|
|
103
|
-
import '../core/Sidebar/SidebarContent.js';
|
|
104
|
-
import '../core/Sidebar/SidebarFooter.js';
|
|
105
|
-
import '../core/Sidebar/SidebarNav.js';
|
|
106
|
-
import '../core/Sidebar/SidebarNavGroup.js';
|
|
107
|
-
import '../core/Sidebar/SidebarToggle.js';
|
|
108
|
-
import '../core/Sidebar/SidebarMobileTrigger.js';
|
|
109
|
-
import '../core/Sidebar/SidebarUserProfile.js';
|
|
110
|
-
import '../core/Sidebar/SidebarLogo.js';
|
|
111
|
-
import '../core/Sidebar/SidebarContext.js';
|
|
112
|
-
import '../core/OfflineIndicator/OfflineIndicator.js';
|
|
113
|
-
import '../core/ContextMenu/ContextMenu.js';
|
|
114
|
-
import '../core/ContextMenu/ContextMenu.theme.js';
|
|
115
|
-
import '../core/Pill/Pill.js';
|
|
116
|
-
import '../core/Icon/Icon.js';
|
|
117
|
-
import '../core/ImagePlaceholder/ImagePlaceholder.js';
|
|
118
32
|
import './TimePicker/WheelColumn.js';
|
|
119
33
|
export { timePickerTheme } from './TimePicker/TimePicker.theme.js';
|
|
120
34
|
export { Slider } from './Slider/Slider.js';
|
|
@@ -158,9 +72,6 @@ export { SelectableCard } from './SelectableCard/SelectableCard.js';
|
|
|
158
72
|
export { selectableCardTheme } from './SelectableCard/SelectableCard.theme.js';
|
|
159
73
|
export { Mention } from './Mention/Mention.js';
|
|
160
74
|
export { mentionTheme } from './Mention/Mention.theme.js';
|
|
161
|
-
export { CronInput } from './CronInput/CronInput.js';
|
|
162
|
-
export { cronInputTheme } from './CronInput/CronInput.theme.js';
|
|
163
|
-
export { CRON_PRESETS, cronToDescription, fieldsToCron, formatNextRun, getNextRuns, parseCron, validateCron } from './CronInput/CronInput.utils.js';
|
|
164
75
|
export { DatePickerBody } from './DatePicker/DatePickerBody.js';
|
|
165
76
|
export { DatePickerPresets } from './DatePicker/DatePickerPresets.js';
|
|
166
77
|
export { DatePickerTrigger } from './DatePicker/DatePickerTrigger.js';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { UISpec } from "./types";
|
|
2
|
+
import { GenerativeRegistry } from "./registry";
|
|
3
|
+
import { ActionHandler } from "./actions";
|
|
4
|
+
export interface GenerativeViewProps {
|
|
5
|
+
/** The serializable spec tree (one root or top-level siblings). */
|
|
6
|
+
spec: UISpec;
|
|
7
|
+
/** Component/icon/resolver registry. @default defaultRegistry */
|
|
8
|
+
registry?: GenerativeRegistry;
|
|
9
|
+
/**
|
|
10
|
+
* Receives spec actions: the EXACT descriptor from the node plus a
|
|
11
|
+
* serializable context (component, nodeId, callback data such as the
|
|
12
|
+
* clicked Table row). Omit it and action-bound elements are inert.
|
|
13
|
+
*/
|
|
14
|
+
onAction?: ActionHandler;
|
|
15
|
+
className?: string;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Render a serializable UINode spec with the given registry.
|
|
19
|
+
* Render-only in P1 — streaming (P3) and action dispatch (P4) layer on top.
|
|
20
|
+
*/
|
|
21
|
+
export declare function GenerativeView({ spec, registry, onAction, className, }: GenerativeViewProps): import("react/jsx-runtime").JSX.Element;
|