@devalok/shilp-sutra 0.34.1 → 0.36.1
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 -21
- package/dist/_chunks/badge-group.js +95 -95
- package/dist/_chunks/badge-group.js.map +1 -0
- package/dist/_chunks/chat.js +7 -2
- package/dist/_chunks/chat.js.map +1 -0
- package/dist/_chunks/date-picker.js.map +1 -0
- package/dist/_chunks/document-preview.js.map +1 -0
- package/dist/_chunks/file-preview.js.map +1 -0
- package/dist/_chunks/framer.js +62 -62
- package/dist/_chunks/framer.js.map +1 -0
- package/dist/_chunks/image-preview.js +1 -1
- package/dist/_chunks/image-preview.js.map +1 -0
- package/dist/_chunks/keybinding.js.map +1 -0
- package/dist/_chunks/link-context.js.map +1 -0
- package/dist/_chunks/mention-suggestion.js.map +1 -0
- package/dist/_chunks/motion-provider.js.map +1 -0
- package/dist/_chunks/popover.js +32 -36
- package/dist/_chunks/popover.js.map +1 -0
- package/dist/_chunks/primitives.js +686 -686
- package/dist/_chunks/primitives.js.map +1 -0
- package/dist/_chunks/rich-chat-input.js +651 -650
- package/dist/_chunks/rich-chat-input.js.map +1 -0
- package/dist/_chunks/shared.js.map +1 -0
- package/dist/_chunks/sonner.js.map +1 -0
- package/dist/_chunks/stat-row.js +158 -158
- package/dist/_chunks/stat-row.js.map +1 -0
- package/dist/_chunks/tiptap.js +11 -11
- package/dist/_chunks/tiptap.js.map +1 -0
- package/dist/_chunks/tree-view.js +1 -1
- package/dist/_chunks/tree-view.js.map +1 -0
- package/dist/_chunks/use-calendar.js.map +1 -0
- package/dist/_chunks/vendor-client.js +1 -1
- package/dist/_chunks/vendor-client.js.map +1 -0
- package/dist/_chunks/vendor-utils.js.map +1 -0
- package/dist/ai/ai-command-provider.js.map +1 -0
- package/dist/ai/block-renderer.js.map +1 -0
- package/dist/ai/blocks/loading.d.ts.map +1 -1
- package/dist/ai/command-bar.js.map +1 -0
- package/dist/ai/conversation.js +76 -76
- package/dist/ai/conversation.js.map +1 -0
- package/dist/ai/devadoot-icon.d.ts.map +1 -1
- package/dist/ai/index.js.map +1 -0
- package/dist/composed/activity-feed.js.map +1 -0
- package/dist/composed/avatar-group.js +1 -1
- package/dist/composed/avatar-group.js.map +1 -0
- package/dist/composed/bulk-action-bar.js +13 -21
- package/dist/composed/bulk-action-bar.js.map +1 -0
- package/dist/composed/command-palette.js.map +1 -0
- package/dist/composed/confirm-dialog.js.map +1 -0
- package/dist/composed/content-card.js.map +1 -0
- package/dist/composed/deadline-indicator.js.map +1 -0
- package/dist/composed/emoji-picker.js.map +1 -0
- package/dist/composed/empty-state.d.ts.map +1 -1
- package/dist/composed/empty-state.js +30 -30
- package/dist/composed/empty-state.js.map +1 -0
- package/dist/composed/error-boundary.js.map +1 -0
- package/dist/composed/filter-bar.js.map +1 -0
- package/dist/composed/form-section.js.map +1 -0
- package/dist/composed/global-loading.js.map +1 -0
- package/dist/composed/inline-edit.js.map +1 -0
- package/dist/composed/lib/string-utils.js.map +1 -0
- package/dist/composed/loading-skeleton.js.map +1 -0
- package/dist/composed/markdown-viewer.js.map +1 -0
- package/dist/composed/master-detail.js.map +1 -0
- package/dist/composed/member-picker.js.map +1 -0
- package/dist/composed/multi-select-popover.d.ts.map +1 -1
- package/dist/composed/multi-select-popover.js +4 -0
- package/dist/composed/multi-select-popover.js.map +1 -0
- package/dist/composed/page-header.js.map +1 -0
- package/dist/composed/page-skeletons.js.map +1 -0
- package/dist/composed/priority-indicator.js.map +1 -0
- package/dist/composed/responsive-overlay.js.map +1 -0
- package/dist/composed/rich-chat-input/attachment-strip.d.ts.map +1 -1
- package/dist/composed/rich-chat-input/reply-banner.d.ts.map +1 -1
- package/dist/composed/rich-chat-input/schedule-send.d.ts.map +1 -1
- package/dist/composed/rich-chat-input.d.ts.map +1 -1
- package/dist/composed/rich-text-editor.js +1 -1
- package/dist/composed/rich-text-editor.js.map +1 -0
- package/dist/composed/schedule-view.js.map +1 -0
- package/dist/composed/simple-tooltip.js.map +1 -0
- package/dist/composed/status-badge.d.ts.map +1 -1
- package/dist/composed/status-badge.js.map +1 -0
- package/dist/hooks/use-color-mode.js.map +1 -0
- package/dist/hooks/use-mobile.js.map +1 -0
- package/dist/hooks/use-touch-device.js.map +1 -0
- package/dist/hooks/use-viewport-height.js.map +1 -0
- package/dist/motion/check-motion-provider.d.ts +3 -0
- package/dist/motion/check-motion-provider.d.ts.map +1 -0
- package/dist/motion/index.js +14 -0
- package/dist/motion/index.js.map +1 -0
- package/dist/motion/primitives-index.js.map +1 -0
- package/dist/primitives/react-accordion.d.ts +114 -114
- package/dist/primitives/react-alert-dialog.d.ts +51 -51
- package/dist/primitives/react-aspect-ratio.d.ts +11 -11
- package/dist/primitives/react-avatar.d.ts +24 -24
- package/dist/primitives/react-checkbox.d.ts +50 -50
- package/dist/primitives/react-collapsible.d.ts +33 -33
- package/dist/primitives/react-context-menu.d.ts +96 -96
- package/dist/primitives/react-dialog.d.ts +103 -103
- package/dist/primitives/react-dropdown-menu.d.ts +97 -97
- package/dist/primitives/react-hover-card.d.ts +79 -79
- package/dist/primitives/react-label.d.ts +10 -10
- package/dist/primitives/react-menu.d.ts +169 -169
- package/dist/primitives/react-menubar.d.ts +115 -115
- package/dist/primitives/react-navigation-menu.d.ts +126 -126
- package/dist/primitives/react-popover.d.ts +85 -85
- package/dist/primitives/react-progress.d.ts +19 -19
- package/dist/primitives/react-radio-group.d.ts +58 -58
- package/dist/primitives/react-roving-focus.d.ts +49 -49
- package/dist/primitives/react-select.d.ts +137 -137
- package/dist/primitives/react-separator.d.ts +21 -21
- package/dist/primitives/react-slider.d.ts +75 -75
- package/dist/primitives/react-switch.d.ts +21 -21
- package/dist/primitives/react-tabs.d.ts +56 -56
- package/dist/primitives/react-toast.d.ts +120 -120
- package/dist/primitives/react-toggle-group.d.ts +75 -75
- package/dist/primitives/react-toggle.d.ts +24 -24
- package/dist/primitives/react-tooltip.d.ts +101 -101
- package/dist/primitives/react-visually-hidden.d.ts +22 -22
- package/dist/shell/app-command-palette.d.ts +2 -0
- package/dist/shell/app-command-palette.d.ts.map +1 -1
- package/dist/shell/app-command-palette.js +42 -155
- package/dist/shell/app-command-palette.js.map +1 -0
- package/dist/shell/bottom-navbar.js +1 -1
- package/dist/shell/bottom-navbar.js.map +1 -0
- package/dist/shell/command-registry.js.map +1 -0
- package/dist/shell/notification-center.d.ts.map +1 -1
- package/dist/shell/notification-center.js +194 -169
- package/dist/shell/notification-center.js.map +1 -0
- package/dist/shell/notification-preferences.js.map +1 -0
- package/dist/shell/sidebar.js.map +1 -0
- package/dist/shell/top-bar.js +1 -1
- package/dist/shell/top-bar.js.map +1 -0
- package/dist/tailwind/index.cjs +48 -1
- package/dist/tailwind/preset.d.ts.map +1 -1
- package/dist/tailwind/preset.js +48 -1
- package/dist/tailwind/preset.js.map +1 -0
- package/dist/tokens/index.css +4 -4
- package/dist/tokens/primitives.css +442 -442
- package/dist/tokens/semantic.css +742 -547
- package/dist/tokens/typography-semantic.css +123 -100
- package/dist/tokens/typography.css +422 -422
- package/dist/ui/accordion.js +13 -13
- package/dist/ui/accordion.js.map +1 -0
- package/dist/ui/alert-dialog.d.ts +6 -2
- package/dist/ui/alert-dialog.d.ts.map +1 -1
- package/dist/ui/alert-dialog.js +43 -42
- package/dist/ui/alert-dialog.js.map +1 -0
- package/dist/ui/alert.d.ts +3 -2
- package/dist/ui/alert.d.ts.map +1 -1
- package/dist/ui/alert.js +31 -5
- package/dist/ui/alert.js.map +1 -0
- package/dist/ui/aspect-ratio.js +1 -1
- package/dist/ui/aspect-ratio.js.map +1 -0
- package/dist/ui/autocomplete.d.ts.map +1 -1
- package/dist/ui/autocomplete.js +92 -67
- package/dist/ui/autocomplete.js.map +1 -0
- package/dist/ui/avatar.js +9 -9
- package/dist/ui/avatar.js.map +1 -0
- package/dist/ui/badge-indicator.js.map +1 -0
- package/dist/ui/banner.js.map +1 -0
- package/dist/ui/breadcrumb.js +1 -1
- package/dist/ui/breadcrumb.js.map +1 -0
- package/dist/ui/button-group.js.map +1 -0
- package/dist/ui/button-processing.d.ts.map +1 -1
- package/dist/ui/button-processing.js +61 -40
- package/dist/ui/button-processing.js.map +1 -0
- package/dist/ui/button.js +8 -8
- package/dist/ui/button.js.map +1 -0
- package/dist/ui/card.js.map +1 -0
- package/dist/ui/charts/bar-chart.d.ts.map +1 -1
- package/dist/ui/charts/chart-container.d.ts +2 -0
- package/dist/ui/charts/chart-container.d.ts.map +1 -1
- package/dist/ui/charts/index.js +88 -65
- package/dist/ui/charts/index.js.map +1 -0
- package/dist/ui/charts/line-chart.d.ts.map +1 -1
- package/dist/ui/chat/message-input.d.ts.map +1 -1
- package/dist/ui/chat/message-list.d.ts +1 -1
- package/dist/ui/chat/message-list.d.ts.map +1 -1
- package/dist/ui/chat/message.d.ts.map +1 -1
- package/dist/ui/chat/system-message.d.ts.map +1 -1
- package/dist/ui/checkbox.d.ts.map +1 -1
- package/dist/ui/checkbox.js +33 -28
- package/dist/ui/checkbox.js.map +1 -0
- package/dist/ui/code.js.map +1 -0
- package/dist/ui/collapsible.js +1 -1
- package/dist/ui/collapsible.js.map +1 -0
- package/dist/ui/color-input.d.ts.map +1 -1
- package/dist/ui/color-input.js +165 -163
- package/dist/ui/color-input.js.map +1 -0
- package/dist/ui/color-swatch.js.map +1 -0
- package/dist/ui/combobox.d.ts +7 -0
- package/dist/ui/combobox.d.ts.map +1 -1
- package/dist/ui/combobox.js +147 -113
- package/dist/ui/combobox.js.map +1 -0
- package/dist/ui/container.js +1 -1
- package/dist/ui/container.js.map +1 -0
- package/dist/ui/context-menu.js.map +1 -0
- package/dist/ui/data-table-body.js.map +1 -0
- package/dist/ui/data-table-bulk-actions.js +1 -1
- package/dist/ui/data-table-bulk-actions.js.map +1 -0
- package/dist/ui/data-table-card.js.map +1 -0
- package/dist/ui/data-table-context.js.map +1 -0
- package/dist/ui/data-table-header.js.map +1 -0
- package/dist/ui/data-table-pagination.js.map +1 -0
- package/dist/ui/data-table-toolbar.js.map +1 -0
- package/dist/ui/data-table.js +34 -31
- package/dist/ui/data-table.js.map +1 -0
- package/dist/ui/devalok-grain.js.map +1 -0
- package/dist/ui/dialog.js +31 -35
- package/dist/ui/dialog.js.map +1 -0
- package/dist/ui/dropdown-menu.js.map +1 -0
- package/dist/ui/file-upload.js +120 -120
- package/dist/ui/file-upload.js.map +1 -0
- package/dist/ui/form.d.ts +8 -0
- package/dist/ui/form.d.ts.map +1 -1
- package/dist/ui/form.js +14 -12
- package/dist/ui/form.js.map +1 -0
- package/dist/ui/hover-card.js.map +1 -0
- package/dist/ui/icon-button.js.map +1 -0
- package/dist/ui/icon-context.js.map +1 -0
- package/dist/ui/icon-group.js.map +1 -0
- package/dist/ui/icon.js.map +1 -0
- package/dist/ui/index.d.ts +4 -4
- package/dist/ui/index.d.ts.map +1 -1
- package/dist/ui/index.js +82 -66
- package/dist/ui/index.js.map +1 -0
- package/dist/ui/input-otp.d.ts +12 -3
- package/dist/ui/input-otp.d.ts.map +1 -1
- package/dist/ui/input-otp.js +41 -27
- package/dist/ui/input-otp.js.map +1 -0
- package/dist/ui/input.d.ts.map +1 -1
- package/dist/ui/input.js +16 -15
- package/dist/ui/input.js.map +1 -0
- package/dist/ui/label.d.ts.map +1 -1
- package/dist/ui/label.js +19 -14
- package/dist/ui/label.js.map +1 -0
- package/dist/ui/lib/check-tokens.d.ts +3 -0
- package/dist/ui/lib/check-tokens.d.ts.map +1 -0
- package/dist/ui/lib/date-utils.js.map +1 -0
- package/dist/ui/lib/motion.d.ts +15 -4
- package/dist/ui/lib/motion.d.ts.map +1 -1
- package/dist/ui/lib/motion.js +18 -9
- package/dist/ui/lib/motion.js.map +1 -0
- package/dist/ui/lib/utils.js.map +1 -0
- package/dist/ui/link.js +2 -2
- package/dist/ui/link.js.map +1 -0
- package/dist/ui/menubar.js.map +1 -0
- package/dist/ui/navigation-menu.js.map +1 -0
- package/dist/ui/number-input.d.ts +16 -1
- package/dist/ui/number-input.d.ts.map +1 -1
- package/dist/ui/number-input.js +79 -49
- package/dist/ui/number-input.js.map +1 -0
- package/dist/ui/pagination.js +1 -1
- package/dist/ui/pagination.js.map +1 -0
- package/dist/ui/progress-ring.d.ts.map +1 -1
- package/dist/ui/progress-ring.js.map +1 -0
- package/dist/ui/progress.js.map +1 -0
- package/dist/ui/radio.d.ts.map +1 -1
- package/dist/ui/radio.js +27 -20
- package/dist/ui/radio.js.map +1 -0
- package/dist/ui/search-input.js.map +1 -0
- package/dist/ui/segmented-control.d.ts +1 -1
- package/dist/ui/segmented-control.d.ts.map +1 -1
- package/dist/ui/segmented-control.js +3 -1
- package/dist/ui/segmented-control.js.map +1 -0
- package/dist/ui/select.d.ts.map +1 -1
- package/dist/ui/select.js +54 -48
- package/dist/ui/select.js.map +1 -0
- package/dist/ui/separator.d.ts.map +1 -1
- package/dist/ui/separator.js +10 -7
- package/dist/ui/separator.js.map +1 -0
- package/dist/ui/sheet.js +29 -29
- package/dist/ui/sheet.js.map +1 -0
- package/dist/ui/sidebar.js +9 -9
- package/dist/ui/sidebar.js.map +1 -0
- package/dist/ui/skeleton.js.map +1 -0
- package/dist/ui/slider.d.ts +22 -3
- package/dist/ui/slider.d.ts.map +1 -1
- package/dist/ui/slider.js +57 -19
- package/dist/ui/slider.js.map +1 -0
- package/dist/ui/spinner.js.map +1 -0
- package/dist/ui/split-button.d.ts.map +1 -1
- package/dist/ui/split-button.js +77 -76
- package/dist/ui/split-button.js.map +1 -0
- package/dist/ui/stack.js.map +1 -0
- package/dist/ui/stat-card.js.map +1 -0
- package/dist/ui/status-dot.js.map +1 -0
- package/dist/ui/stepper.d.ts +10 -0
- package/dist/ui/stepper.d.ts.map +1 -1
- package/dist/ui/stepper.js +80 -75
- package/dist/ui/stepper.js.map +1 -0
- package/dist/ui/switch.d.ts.map +1 -1
- package/dist/ui/switch.js +26 -22
- package/dist/ui/switch.js.map +1 -0
- package/dist/ui/table.js.map +1 -0
- package/dist/ui/tabs.d.ts +3 -1
- package/dist/ui/tabs.d.ts.map +1 -1
- package/dist/ui/tabs.js +68 -48
- package/dist/ui/tabs.js.map +1 -0
- package/dist/ui/text.d.ts +1 -1
- package/dist/ui/text.d.ts.map +1 -1
- package/dist/ui/text.js +10 -2
- package/dist/ui/text.js.map +1 -0
- package/dist/ui/textarea.js +1 -1
- package/dist/ui/textarea.js.map +1 -0
- package/dist/ui/toast-registry.d.ts +8 -0
- package/dist/ui/toast-registry.d.ts.map +1 -0
- package/dist/ui/toast-registry.js +13 -0
- package/dist/ui/toast-registry.js.map +1 -0
- package/dist/ui/toast.d.ts.map +1 -1
- package/dist/ui/toast.js +141 -136
- package/dist/ui/toast.js.map +1 -0
- package/dist/ui/toaster.d.ts.map +1 -1
- package/dist/ui/toaster.js +15 -14
- package/dist/ui/toaster.js.map +1 -0
- package/dist/ui/toggle-group.d.ts +2 -0
- package/dist/ui/toggle-group.d.ts.map +1 -1
- package/dist/ui/toggle-group.js +23 -16
- package/dist/ui/toggle-group.js.map +1 -0
- package/dist/ui/toggle.d.ts +2 -0
- package/dist/ui/toggle.d.ts.map +1 -1
- package/dist/ui/toggle.js +14 -6
- package/dist/ui/toggle.js.map +1 -0
- package/dist/ui/tooltip.js.map +1 -0
- package/dist/ui/visually-hidden.js.map +1 -0
- package/docs/components/_header.md +85 -85
- package/docs/components/composed/activity-feed.md +62 -62
- package/docs/components/composed/avatar-group.md +65 -65
- package/docs/components/composed/bulk-action-bar.md +40 -40
- package/docs/components/composed/command-palette.md +40 -40
- package/docs/components/composed/confirm-dialog.md +46 -46
- package/docs/components/composed/content-card.md +36 -36
- package/docs/components/composed/date-picker.md +130 -130
- package/docs/components/composed/deadline-indicator.md +27 -27
- package/docs/components/composed/emoji-picker.md +52 -52
- package/docs/components/composed/empty-state.md +53 -53
- package/docs/components/composed/error-boundary.md +29 -29
- package/docs/components/composed/file-preview.md +40 -40
- package/docs/components/composed/filter-bar.md +57 -57
- package/docs/components/composed/form-section.md +31 -31
- package/docs/components/composed/global-loading.md +27 -27
- package/docs/components/composed/inline-edit.md +35 -35
- package/docs/components/composed/loading-skeleton.md +51 -51
- package/docs/components/composed/markdown-viewer.md +27 -27
- package/docs/components/composed/master-detail.md +48 -48
- package/docs/components/composed/member-picker.md +35 -35
- package/docs/components/composed/multi-select-popover.md +62 -62
- package/docs/components/composed/page-header.md +41 -41
- package/docs/components/composed/page-skeletons.md +32 -32
- package/docs/components/composed/priority-indicator.md +32 -32
- package/docs/components/composed/responsive-overlay.md +34 -34
- package/docs/components/composed/rich-text-editor.md +82 -82
- package/docs/components/composed/schedule-view.md +39 -39
- package/docs/components/composed/simple-tooltip.md +33 -33
- package/docs/components/composed/status-badge.md +55 -55
- package/docs/components/shell/app-command-palette.md +44 -44
- package/docs/components/shell/bottom-navbar.md +52 -52
- package/docs/components/shell/command-registry.md +48 -48
- package/docs/components/shell/link-context.md +41 -41
- package/docs/components/shell/notification-center.md +63 -63
- package/docs/components/shell/notification-preferences.md +42 -42
- package/docs/components/shell/sidebar.md +92 -92
- package/docs/components/shell/top-bar.md +143 -143
- package/docs/components/ui/accordion.md +51 -51
- package/docs/components/ui/alert-dialog.md +61 -61
- package/docs/components/ui/alert.md +46 -46
- package/docs/components/ui/aspect-ratio.md +25 -25
- package/docs/components/ui/autocomplete.md +48 -48
- package/docs/components/ui/avatar.md +56 -56
- package/docs/components/ui/badge.md +83 -82
- package/docs/components/ui/banner.md +42 -42
- package/docs/components/ui/breadcrumb.md +37 -37
- package/docs/components/ui/button-group.md +41 -41
- package/docs/components/ui/button.md +94 -93
- package/docs/components/ui/card.md +52 -52
- package/docs/components/ui/charts.md +43 -43
- package/docs/components/ui/checkbox.md +36 -36
- package/docs/components/ui/chip.md +47 -47
- package/docs/components/ui/code.md +28 -28
- package/docs/components/ui/collapsible.md +40 -40
- package/docs/components/ui/color-input.md +91 -91
- package/docs/components/ui/color-swatch.md +25 -25
- package/docs/components/ui/combobox.md +54 -54
- package/docs/components/ui/container.md +26 -26
- package/docs/components/ui/context-menu.md +43 -43
- package/docs/components/ui/data-table-body.md +1 -1
- package/docs/components/ui/data-table-bulk-actions.md +1 -1
- package/docs/components/ui/data-table-card.md +1 -1
- package/docs/components/ui/data-table-context.md +1 -1
- package/docs/components/ui/data-table-header.md +1 -1
- package/docs/components/ui/data-table-pagination.md +1 -1
- package/docs/components/ui/data-table-toolbar.md +44 -44
- package/docs/components/ui/data-table.md +94 -94
- package/docs/components/ui/dialog.md +54 -54
- package/docs/components/ui/dropdown-menu.md +48 -48
- package/docs/components/ui/file-upload.md +41 -41
- package/docs/components/ui/form.md +51 -51
- package/docs/components/ui/hover-card.md +32 -32
- package/docs/components/ui/icon-button.md +40 -40
- package/docs/components/ui/input-otp.md +44 -44
- package/docs/components/ui/input.md +74 -74
- package/docs/components/ui/label.md +25 -25
- package/docs/components/ui/link.md +29 -29
- package/docs/components/ui/menubar.md +44 -44
- package/docs/components/ui/navigation-menu.md +46 -46
- package/docs/components/ui/number-input.md +44 -44
- package/docs/components/ui/pagination.md +48 -48
- package/docs/components/ui/popover.md +30 -30
- package/docs/components/ui/progress-ring.md +41 -41
- package/docs/components/ui/progress.md +34 -34
- package/docs/components/ui/radio.md +34 -34
- package/docs/components/ui/search-input.md +43 -43
- package/docs/components/ui/segmented-control.md +50 -50
- package/docs/components/ui/select.md +53 -53
- package/docs/components/ui/separator.md +32 -32
- package/docs/components/ui/sheet.md +47 -47
- package/docs/components/ui/sidebar.md +72 -72
- package/docs/components/ui/skeleton.md +77 -77
- package/docs/components/ui/slider.md +29 -29
- package/docs/components/ui/spinner.md +54 -54
- package/docs/components/ui/stack.md +39 -39
- package/docs/components/ui/stat-card.md +61 -61
- package/docs/components/ui/status-dot.md +26 -26
- package/docs/components/ui/stepper.md +49 -49
- package/docs/components/ui/switch.md +47 -47
- package/docs/components/ui/table.md +47 -47
- package/docs/components/ui/tabs.md +60 -60
- package/docs/components/ui/text.md +37 -37
- package/docs/components/ui/textarea.md +39 -39
- package/docs/components/ui/toast.md +65 -65
- package/docs/components/ui/toaster.md +47 -47
- package/docs/components/ui/toggle-group.md +43 -43
- package/docs/components/ui/toggle.md +37 -37
- package/docs/components/ui/tooltip.md +38 -38
- package/docs/components/ui/tree-view.md +65 -65
- package/docs/components/ui/visually-hidden.md +21 -21
- package/llms-full.txt +5266 -5264
- package/llms.txt +624 -580
- package/package.json +7 -8
package/dist/_chunks/stat-row.js
CHANGED
|
@@ -1,47 +1,47 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { a as e } from "./framer.js";
|
|
3
|
-
import {
|
|
4
|
-
import { cn as
|
|
5
|
-
import { Icon as
|
|
6
|
-
import { Alert as
|
|
7
|
-
import { n as
|
|
8
|
-
import { Button as
|
|
9
|
-
import { Collapsible as
|
|
10
|
-
import { Table as
|
|
11
|
-
import { Skeleton as
|
|
12
|
-
import { Separator as
|
|
13
|
-
import { StatCard as
|
|
14
|
-
import { n as
|
|
15
|
-
import * as
|
|
16
|
-
import { jsx as
|
|
17
|
-
import { IconCircle as
|
|
18
|
-
import
|
|
19
|
-
import
|
|
3
|
+
import { durations as t, springs as n, tweens as r } from "../ui/lib/motion.js";
|
|
4
|
+
import { cn as i } from "../ui/lib/utils.js";
|
|
5
|
+
import { Icon as a } from "../ui/icon.js";
|
|
6
|
+
import { Alert as o } from "../ui/alert.js";
|
|
7
|
+
import { n as s } from "./badge-group.js";
|
|
8
|
+
import { Button as c } from "../ui/button.js";
|
|
9
|
+
import { Collapsible as l, CollapsibleContent as u, CollapsibleTrigger as d } from "../ui/collapsible.js";
|
|
10
|
+
import { Table as f, TableBody as p, TableCaption as m, TableCell as h, TableHead as g, TableHeader as _, TableRow as v } from "../ui/table.js";
|
|
11
|
+
import { Skeleton as y } from "../ui/skeleton.js";
|
|
12
|
+
import { Separator as b } from "../ui/separator.js";
|
|
13
|
+
import { StatCard as x } from "../ui/stat-card.js";
|
|
14
|
+
import { n as S } from "./motion-provider.js";
|
|
15
|
+
import * as C from "react";
|
|
16
|
+
import { jsx as w, jsxs as T } from "react/jsx-runtime";
|
|
17
|
+
import { IconCircle as E, IconCircleCheck as D, IconCircleX as O } from "@tabler/icons-react";
|
|
18
|
+
import k from "react-markdown";
|
|
19
|
+
import A from "remark-gfm";
|
|
20
20
|
//#region src/ai/blocks/text.tsx
|
|
21
|
-
var
|
|
22
|
-
return /* @__PURE__ */
|
|
23
|
-
className:
|
|
24
|
-
children: /* @__PURE__ */
|
|
25
|
-
remarkPlugins: [
|
|
21
|
+
var j = C.memo(function({ data: e, confidence: t }) {
|
|
22
|
+
return /* @__PURE__ */ w("div", {
|
|
23
|
+
className: i("prose prose-sm", "text-surface-fg", "prose-headings:text-surface-fg", "prose-a:text-accent-11 prose-a:underline", "prose-code:text-accent-11 prose-code:bg-surface-raised prose-code:rounded prose-code:px-1", "prose-strong:text-surface-fg", t === "low" && "border-l-2 border-warning-7 pl-3"),
|
|
24
|
+
children: /* @__PURE__ */ w(k, {
|
|
25
|
+
remarkPlugins: [A],
|
|
26
26
|
children: e.content
|
|
27
27
|
})
|
|
28
28
|
});
|
|
29
29
|
});
|
|
30
|
-
|
|
30
|
+
j.displayName = "TextBlock";
|
|
31
31
|
//#endregion
|
|
32
32
|
//#region src/ai/blocks/block-table.tsx
|
|
33
|
-
function
|
|
33
|
+
function M(e, t) {
|
|
34
34
|
if (t.variant === "badge") {
|
|
35
35
|
if (e && typeof e == "object" && "label" in e) {
|
|
36
36
|
let t = e;
|
|
37
|
-
return /* @__PURE__ */
|
|
37
|
+
return /* @__PURE__ */ w(s, {
|
|
38
38
|
variant: "subtle",
|
|
39
39
|
size: "sm",
|
|
40
40
|
color: t.color,
|
|
41
41
|
children: t.label
|
|
42
42
|
});
|
|
43
43
|
}
|
|
44
|
-
return /* @__PURE__ */
|
|
44
|
+
return /* @__PURE__ */ w(s, {
|
|
45
45
|
variant: "subtle",
|
|
46
46
|
size: "sm",
|
|
47
47
|
children: String(e ?? "")
|
|
@@ -49,7 +49,7 @@ function j(e, t) {
|
|
|
49
49
|
}
|
|
50
50
|
return String(e ?? "");
|
|
51
51
|
}
|
|
52
|
-
function
|
|
52
|
+
function N(e, t, n) {
|
|
53
53
|
return !t || !n ? e : [...e].sort((e, r) => {
|
|
54
54
|
let i = e[t], a = r[t], o = String(i ?? ""), s = String(a ?? ""), c = Number(i), l = Number(a);
|
|
55
55
|
if (!Number.isNaN(c) && !Number.isNaN(l)) return n === "asc" ? c - l : l - c;
|
|
@@ -57,38 +57,38 @@ function M(e, t, n) {
|
|
|
57
57
|
return n === "asc" ? u : -u;
|
|
58
58
|
});
|
|
59
59
|
}
|
|
60
|
-
var
|
|
61
|
-
let { reducedMotion: a } =
|
|
62
|
-
|
|
60
|
+
var P = C.memo(function({ data: t, confidence: r }) {
|
|
61
|
+
let { reducedMotion: a } = S(), [o, s] = C.useState(null), [c, l] = C.useState(null), u = C.useCallback((e) => {
|
|
62
|
+
t.sortable && (o === e ? c === "asc" ? l("desc") : c === "desc" && (s(null), l(null)) : (s(e), l("asc")));
|
|
63
63
|
}, [
|
|
64
|
-
|
|
64
|
+
t.sortable,
|
|
65
65
|
o,
|
|
66
66
|
c
|
|
67
|
-
]),
|
|
68
|
-
return /* @__PURE__ */
|
|
69
|
-
className:
|
|
70
|
-
children: /* @__PURE__ */
|
|
71
|
-
|
|
72
|
-
/* @__PURE__ */
|
|
73
|
-
let
|
|
74
|
-
return /* @__PURE__ */
|
|
67
|
+
]), d = t.columns ?? [], y = N(t.rows ?? [], o, c);
|
|
68
|
+
return /* @__PURE__ */ w("div", {
|
|
69
|
+
className: i("overflow-x-auto", r === "low" && "border-l-2 border-warning-7 pl-3"),
|
|
70
|
+
children: /* @__PURE__ */ T(f, { children: [
|
|
71
|
+
t.caption && /* @__PURE__ */ w(m, { children: t.caption }),
|
|
72
|
+
/* @__PURE__ */ w(_, { children: /* @__PURE__ */ w(v, { children: d.map((e) => {
|
|
73
|
+
let n = o === e.key, r = t.sortable ? n ? c === "asc" ? "ascending" : "descending" : "none" : void 0;
|
|
74
|
+
return /* @__PURE__ */ w(g, {
|
|
75
75
|
role: "columnheader",
|
|
76
|
-
className:
|
|
77
|
-
tabIndex:
|
|
78
|
-
onClick:
|
|
79
|
-
onKeyDown:
|
|
76
|
+
className: i(e.variant === "number" && "text-right", t.sortable && "cursor-pointer select-none"),
|
|
77
|
+
tabIndex: t.sortable ? 0 : void 0,
|
|
78
|
+
onClick: t.sortable ? () => u(e.key) : void 0,
|
|
79
|
+
onKeyDown: t.sortable ? (t) => {
|
|
80
80
|
(t.key === "Enter" || t.key === " ") && (t.preventDefault(), u(e.key));
|
|
81
81
|
} : void 0,
|
|
82
|
-
"aria-sort":
|
|
83
|
-
children: /* @__PURE__ */
|
|
82
|
+
"aria-sort": r,
|
|
83
|
+
children: /* @__PURE__ */ T("span", {
|
|
84
84
|
className: "inline-flex items-center gap-1",
|
|
85
85
|
children: [
|
|
86
86
|
e.label,
|
|
87
|
-
|
|
87
|
+
n && c === "asc" && /* @__PURE__ */ w("span", {
|
|
88
88
|
"aria-hidden": "true",
|
|
89
89
|
children: "▲"
|
|
90
90
|
}),
|
|
91
|
-
|
|
91
|
+
n && c === "desc" && /* @__PURE__ */ w("span", {
|
|
92
92
|
"aria-hidden": "true",
|
|
93
93
|
children: "▼"
|
|
94
94
|
})
|
|
@@ -96,9 +96,9 @@ var N = S.memo(function({ data: n, confidence: i }) {
|
|
|
96
96
|
})
|
|
97
97
|
}, e.key);
|
|
98
98
|
}) }) }),
|
|
99
|
-
/* @__PURE__ */
|
|
100
|
-
let o = typeof
|
|
101
|
-
return /* @__PURE__ */
|
|
99
|
+
/* @__PURE__ */ w(p, { children: y.map((t, r) => {
|
|
100
|
+
let o = typeof t.id == "string" || typeof t.id == "number" ? String(t.id) : `row-${r}`;
|
|
101
|
+
return /* @__PURE__ */ w(a ? "tr" : e.tr, {
|
|
102
102
|
className: "hover:bg-surface-raised-hover transition-colors",
|
|
103
103
|
...a ? {} : {
|
|
104
104
|
initial: {
|
|
@@ -110,58 +110,58 @@ var N = S.memo(function({ data: n, confidence: i }) {
|
|
|
110
110
|
y: 0
|
|
111
111
|
},
|
|
112
112
|
transition: {
|
|
113
|
-
...
|
|
114
|
-
delay:
|
|
113
|
+
...n.responsive,
|
|
114
|
+
delay: r * .03
|
|
115
115
|
}
|
|
116
116
|
},
|
|
117
|
-
children:
|
|
118
|
-
className:
|
|
119
|
-
children:
|
|
117
|
+
children: d.map((e) => /* @__PURE__ */ w(h, {
|
|
118
|
+
className: i("text-ds-sm py-ds-02b px-ds-04", e.variant === "number" && "text-right tabular-nums font-medium"),
|
|
119
|
+
children: M(t[e.key], e)
|
|
120
120
|
}, e.key))
|
|
121
121
|
}, o);
|
|
122
122
|
}) })
|
|
123
123
|
] })
|
|
124
124
|
});
|
|
125
125
|
});
|
|
126
|
-
|
|
126
|
+
P.displayName = "BlockTable";
|
|
127
127
|
//#endregion
|
|
128
128
|
//#region src/ai/blocks/confirm.tsx
|
|
129
|
-
var
|
|
130
|
-
let
|
|
129
|
+
var F = C.memo(function({ data: e, confidence: t, onAction: n }) {
|
|
130
|
+
let r = C.useCallback(() => {
|
|
131
131
|
n?.(e.actionId, "confirm");
|
|
132
|
-
}, [e.actionId, n]), a =
|
|
132
|
+
}, [e.actionId, n]), a = C.useCallback(() => {
|
|
133
133
|
n?.(e.actionId, "cancel");
|
|
134
134
|
}, [e.actionId, n]);
|
|
135
|
-
return /* @__PURE__ */
|
|
136
|
-
className:
|
|
135
|
+
return /* @__PURE__ */ T("div", {
|
|
136
|
+
className: i(t === "low" && "border-l-2 border-warning-7 pl-3"),
|
|
137
137
|
children: [
|
|
138
|
-
e.description && /* @__PURE__ */
|
|
138
|
+
e.description && /* @__PURE__ */ w("p", {
|
|
139
139
|
className: "text-ds-sm text-surface-fg-muted mb-3",
|
|
140
140
|
children: e.description
|
|
141
141
|
}),
|
|
142
|
-
/* @__PURE__ */
|
|
142
|
+
/* @__PURE__ */ T("div", {
|
|
143
143
|
className: "flex items-center gap-3",
|
|
144
|
-
children: [/* @__PURE__ */
|
|
144
|
+
children: [/* @__PURE__ */ w(c, {
|
|
145
145
|
variant: "solid",
|
|
146
146
|
color: e.destructive ? "error" : void 0,
|
|
147
|
-
onClick:
|
|
147
|
+
onClick: r,
|
|
148
148
|
children: e.label
|
|
149
|
-
}), /* @__PURE__ */
|
|
149
|
+
}), /* @__PURE__ */ w(c, {
|
|
150
150
|
variant: "ghost",
|
|
151
151
|
onClick: a,
|
|
152
152
|
children: "Cancel"
|
|
153
153
|
})]
|
|
154
154
|
}),
|
|
155
|
-
e.rationale && /* @__PURE__ */
|
|
155
|
+
e.rationale && /* @__PURE__ */ T(l, {
|
|
156
156
|
className: "mt-3",
|
|
157
|
-
children: [/* @__PURE__ */
|
|
157
|
+
children: [/* @__PURE__ */ w(d, {
|
|
158
158
|
asChild: !0,
|
|
159
|
-
children: /* @__PURE__ */
|
|
159
|
+
children: /* @__PURE__ */ w("button", {
|
|
160
160
|
type: "button",
|
|
161
161
|
className: "text-ds-xs text-surface-fg-subtle underline cursor-pointer",
|
|
162
162
|
children: "Why this action?"
|
|
163
163
|
})
|
|
164
|
-
}), /* @__PURE__ */
|
|
164
|
+
}), /* @__PURE__ */ w(u, { children: /* @__PURE__ */ w("p", {
|
|
165
165
|
className: "text-ds-sm text-surface-fg-muted mt-2 p-3 bg-surface-raised rounded-ds-lg",
|
|
166
166
|
children: e.rationale
|
|
167
167
|
}) })]
|
|
@@ -169,12 +169,12 @@ var P = S.memo(function({ data: e, confidence: t, onAction: n }) {
|
|
|
169
169
|
]
|
|
170
170
|
});
|
|
171
171
|
});
|
|
172
|
-
|
|
172
|
+
F.displayName = "ConfirmBlock";
|
|
173
173
|
//#endregion
|
|
174
174
|
//#region src/ai/blocks/success.tsx
|
|
175
|
-
var
|
|
176
|
-
let { reducedMotion:
|
|
177
|
-
|
|
175
|
+
var I = 5e3, L = C.memo(function({ data: t, blockId: n, confidence: r, onAction: a }) {
|
|
176
|
+
let { reducedMotion: s } = S(), l = s, u = t.undoTimeout ?? I, [d, f] = C.useState(u), [p, m] = C.useState(!!t.undoable);
|
|
177
|
+
C.useEffect(() => {
|
|
178
178
|
if (!t.undoable) return;
|
|
179
179
|
let e = setInterval(() => {
|
|
180
180
|
f((t) => {
|
|
@@ -184,32 +184,32 @@ var F = 5e3, I = S.memo(function({ data: t, blockId: n, confidence: i, onAction:
|
|
|
184
184
|
}, 100);
|
|
185
185
|
return () => clearInterval(e);
|
|
186
186
|
}, [t.undoable, u]);
|
|
187
|
-
let h =
|
|
188
|
-
|
|
189
|
-
}, [n,
|
|
190
|
-
return /* @__PURE__ */
|
|
191
|
-
className: r
|
|
192
|
-
children: [/* @__PURE__ */
|
|
187
|
+
let h = C.useCallback(() => {
|
|
188
|
+
a?.(n || "unknown", "undo");
|
|
189
|
+
}, [n, a]), g = Math.ceil(d / 1e3), _ = 2 * Math.PI * 9;
|
|
190
|
+
return /* @__PURE__ */ T("div", {
|
|
191
|
+
className: i(r === "low" && "border-l-2 border-warning-7 pl-3"),
|
|
192
|
+
children: [/* @__PURE__ */ w(o, {
|
|
193
193
|
color: "success",
|
|
194
194
|
variant: "subtle",
|
|
195
195
|
title: t.title,
|
|
196
196
|
children: t.message
|
|
197
|
-
}), p && t.undoable && /* @__PURE__ */
|
|
197
|
+
}), p && t.undoable && /* @__PURE__ */ w("div", {
|
|
198
198
|
className: "mt-2 flex items-center gap-2",
|
|
199
|
-
children: /* @__PURE__ */
|
|
199
|
+
children: /* @__PURE__ */ w(c, {
|
|
200
200
|
variant: "ghost",
|
|
201
201
|
size: "sm",
|
|
202
202
|
onClick: h,
|
|
203
203
|
"aria-label": `Undo action, ${g} seconds remaining`,
|
|
204
|
-
children: /* @__PURE__ */
|
|
204
|
+
children: /* @__PURE__ */ T("span", {
|
|
205
205
|
className: "flex items-center gap-1.5",
|
|
206
|
-
children: [/* @__PURE__ */
|
|
206
|
+
children: [/* @__PURE__ */ T("svg", {
|
|
207
207
|
width: 20,
|
|
208
208
|
height: 20,
|
|
209
209
|
viewBox: "0 0 20 20",
|
|
210
210
|
className: "shrink-0 -rotate-90",
|
|
211
211
|
"aria-hidden": "true",
|
|
212
|
-
children: [/* @__PURE__ */
|
|
212
|
+
children: [/* @__PURE__ */ w("circle", {
|
|
213
213
|
cx: 20 / 2,
|
|
214
214
|
cy: 20 / 2,
|
|
215
215
|
r: 9,
|
|
@@ -217,7 +217,7 @@ var F = 5e3, I = S.memo(function({ data: t, blockId: n, confidence: i, onAction:
|
|
|
217
217
|
stroke: "currentColor",
|
|
218
218
|
strokeWidth: 2,
|
|
219
219
|
opacity: .2
|
|
220
|
-
}), /* @__PURE__ */
|
|
220
|
+
}), /* @__PURE__ */ w(e.circle, {
|
|
221
221
|
cx: 20 / 2,
|
|
222
222
|
cy: 20 / 2,
|
|
223
223
|
r: 9,
|
|
@@ -238,45 +238,45 @@ var F = 5e3, I = S.memo(function({ data: t, blockId: n, confidence: i, onAction:
|
|
|
238
238
|
})]
|
|
239
239
|
});
|
|
240
240
|
});
|
|
241
|
-
|
|
241
|
+
L.displayName = "SuccessBlock";
|
|
242
242
|
//#endregion
|
|
243
243
|
//#region src/ai/blocks/error.tsx
|
|
244
|
-
var
|
|
245
|
-
return /* @__PURE__ */
|
|
246
|
-
className:
|
|
247
|
-
children: [/* @__PURE__ */
|
|
244
|
+
var R = C.memo(function({ data: e, confidence: t }) {
|
|
245
|
+
return /* @__PURE__ */ T("div", {
|
|
246
|
+
className: i(t === "low" && "border-l-2 border-warning-7 pl-3"),
|
|
247
|
+
children: [/* @__PURE__ */ w(o, {
|
|
248
248
|
color: "error",
|
|
249
249
|
variant: "subtle",
|
|
250
250
|
title: e.title,
|
|
251
|
-
children: /* @__PURE__ */
|
|
251
|
+
children: /* @__PURE__ */ w("div", {
|
|
252
252
|
className: "prose prose-sm",
|
|
253
|
-
children: /* @__PURE__ */
|
|
254
|
-
remarkPlugins: [
|
|
253
|
+
children: /* @__PURE__ */ w(k, {
|
|
254
|
+
remarkPlugins: [A],
|
|
255
255
|
children: e.message
|
|
256
256
|
})
|
|
257
257
|
})
|
|
258
|
-
}), e.suggestion && /* @__PURE__ */
|
|
258
|
+
}), e.suggestion && /* @__PURE__ */ w("p", {
|
|
259
259
|
className: "mt-2 text-ds-sm text-surface-fg-muted",
|
|
260
260
|
children: e.suggestion
|
|
261
261
|
})]
|
|
262
262
|
});
|
|
263
263
|
});
|
|
264
|
-
|
|
264
|
+
R.displayName = "ErrorBlock";
|
|
265
265
|
//#endregion
|
|
266
266
|
//#region src/ai/blocks/info.tsx
|
|
267
|
-
var
|
|
268
|
-
return /* @__PURE__ */
|
|
267
|
+
var z = C.memo(function({ data: e }) {
|
|
268
|
+
return /* @__PURE__ */ w(o, {
|
|
269
269
|
color: "info",
|
|
270
270
|
variant: "subtle",
|
|
271
271
|
role: "status",
|
|
272
272
|
children: e.message
|
|
273
273
|
});
|
|
274
274
|
});
|
|
275
|
-
|
|
275
|
+
z.displayName = "InfoBlock";
|
|
276
276
|
//#endregion
|
|
277
277
|
//#region src/ai/blocks/loading.tsx
|
|
278
|
-
function
|
|
279
|
-
return /* @__PURE__ */
|
|
278
|
+
function B() {
|
|
279
|
+
return /* @__PURE__ */ w(e.span, {
|
|
280
280
|
className: "inline-block h-4 w-4 rounded-full border-2 border-current border-t-transparent text-accent-9",
|
|
281
281
|
animate: { rotate: 360 },
|
|
282
282
|
transition: {
|
|
@@ -288,61 +288,61 @@ function z() {
|
|
|
288
288
|
"data-testid": "step-spinner"
|
|
289
289
|
});
|
|
290
290
|
}
|
|
291
|
-
function
|
|
291
|
+
function V({ status: e }) {
|
|
292
292
|
switch (e) {
|
|
293
|
-
case "done": return /* @__PURE__ */
|
|
293
|
+
case "done": return /* @__PURE__ */ w("span", {
|
|
294
294
|
"data-testid": "step-icon-done",
|
|
295
|
-
children: /* @__PURE__ */
|
|
296
|
-
icon:
|
|
295
|
+
children: /* @__PURE__ */ w(a, {
|
|
296
|
+
icon: D,
|
|
297
297
|
size: "sm",
|
|
298
298
|
className: "text-success-11"
|
|
299
299
|
})
|
|
300
300
|
});
|
|
301
|
-
case "active": return /* @__PURE__ */
|
|
302
|
-
case "error": return /* @__PURE__ */
|
|
301
|
+
case "active": return /* @__PURE__ */ w(B, {});
|
|
302
|
+
case "error": return /* @__PURE__ */ w("span", {
|
|
303
303
|
"data-testid": "step-icon-error",
|
|
304
|
-
children: /* @__PURE__ */
|
|
305
|
-
icon:
|
|
304
|
+
children: /* @__PURE__ */ w(a, {
|
|
305
|
+
icon: O,
|
|
306
306
|
size: "sm",
|
|
307
307
|
className: "text-error-11"
|
|
308
308
|
})
|
|
309
309
|
});
|
|
310
|
-
default: return /* @__PURE__ */
|
|
310
|
+
default: return /* @__PURE__ */ w("span", {
|
|
311
311
|
"data-testid": "step-icon-pending",
|
|
312
|
-
children: /* @__PURE__ */
|
|
313
|
-
icon:
|
|
312
|
+
children: /* @__PURE__ */ w(a, {
|
|
313
|
+
icon: E,
|
|
314
314
|
size: "sm",
|
|
315
315
|
className: "text-surface-fg-subtle opacity-50"
|
|
316
316
|
})
|
|
317
317
|
});
|
|
318
318
|
}
|
|
319
319
|
}
|
|
320
|
-
var
|
|
321
|
-
let { reducedMotion:
|
|
322
|
-
if (
|
|
323
|
-
let e = Math.max(1,
|
|
324
|
-
return /* @__PURE__ */
|
|
320
|
+
var H = C.memo(function({ data: n }) {
|
|
321
|
+
let { reducedMotion: r } = S(), a = r;
|
|
322
|
+
if (n.lines != null) {
|
|
323
|
+
let e = Math.max(1, n.lines);
|
|
324
|
+
return /* @__PURE__ */ T("div", {
|
|
325
325
|
role: "status",
|
|
326
326
|
"aria-busy": "true",
|
|
327
327
|
"aria-label": "Loading",
|
|
328
328
|
className: "flex flex-col gap-2",
|
|
329
|
-
children: [Array.from({ length: e }).map((t, n) => /* @__PURE__ */
|
|
329
|
+
children: [Array.from({ length: e }).map((t, n) => /* @__PURE__ */ w(y, {
|
|
330
330
|
animation: "shimmer",
|
|
331
|
-
className:
|
|
332
|
-
}, n)), /* @__PURE__ */
|
|
331
|
+
className: i("h-4", n === e - 1 ? "w-3/5" : "w-full")
|
|
332
|
+
}, n)), /* @__PURE__ */ w("span", {
|
|
333
333
|
className: "sr-only",
|
|
334
334
|
children: "Loading"
|
|
335
335
|
})]
|
|
336
336
|
});
|
|
337
337
|
}
|
|
338
|
-
return
|
|
338
|
+
return n.steps ? /* @__PURE__ */ T("div", {
|
|
339
339
|
role: "status",
|
|
340
340
|
"aria-busy": "true",
|
|
341
341
|
"aria-label": "Processing",
|
|
342
342
|
className: "flex flex-col gap-2",
|
|
343
|
-
children: [
|
|
343
|
+
children: [n.steps.map((n, r) => /* @__PURE__ */ T(e.div, {
|
|
344
344
|
className: "flex items-center gap-2",
|
|
345
|
-
initial:
|
|
345
|
+
initial: a ? void 0 : {
|
|
346
346
|
opacity: 0,
|
|
347
347
|
x: -8
|
|
348
348
|
},
|
|
@@ -350,61 +350,61 @@ var V = S.memo(function({ data: t }) {
|
|
|
350
350
|
opacity: 1,
|
|
351
351
|
x: 0
|
|
352
352
|
},
|
|
353
|
-
transition:
|
|
354
|
-
duration: .
|
|
355
|
-
delay:
|
|
353
|
+
transition: a ? { duration: 0 } : {
|
|
354
|
+
duration: t.moderate01b,
|
|
355
|
+
delay: r * .06
|
|
356
356
|
},
|
|
357
|
-
children: [/* @__PURE__ */
|
|
358
|
-
className:
|
|
359
|
-
children:
|
|
357
|
+
children: [/* @__PURE__ */ w(V, { status: n.status }), /* @__PURE__ */ w("span", {
|
|
358
|
+
className: i("text-ds-sm", n.status === "done" || n.status === "active" ? "text-surface-fg" : "text-surface-fg-subtle"),
|
|
359
|
+
children: n.label
|
|
360
360
|
})]
|
|
361
|
-
},
|
|
361
|
+
}, n.id)), /* @__PURE__ */ w("span", {
|
|
362
362
|
className: "sr-only",
|
|
363
363
|
children: "Processing"
|
|
364
364
|
})]
|
|
365
|
-
}) : /* @__PURE__ */
|
|
365
|
+
}) : /* @__PURE__ */ w("div", {
|
|
366
366
|
role: "status",
|
|
367
367
|
"aria-busy": "true",
|
|
368
368
|
"aria-label": "Loading",
|
|
369
|
-
children: /* @__PURE__ */
|
|
369
|
+
children: /* @__PURE__ */ w("span", {
|
|
370
370
|
className: "sr-only",
|
|
371
371
|
children: "Loading"
|
|
372
372
|
})
|
|
373
373
|
});
|
|
374
374
|
});
|
|
375
|
-
|
|
375
|
+
H.displayName = "LoadingBlock";
|
|
376
376
|
//#endregion
|
|
377
377
|
//#region src/ai/blocks/divider.tsx
|
|
378
|
-
var
|
|
379
|
-
let { reducedMotion:
|
|
380
|
-
return
|
|
378
|
+
var U = C.memo(function(t) {
|
|
379
|
+
let { reducedMotion: n } = S();
|
|
380
|
+
return n ? /* @__PURE__ */ w(b, {}) : /* @__PURE__ */ w(e.div, {
|
|
381
381
|
initial: { scaleX: 0 },
|
|
382
382
|
animate: { scaleX: 1 },
|
|
383
383
|
style: { originX: .5 },
|
|
384
|
-
transition:
|
|
385
|
-
children: /* @__PURE__ */
|
|
384
|
+
transition: r.elegant,
|
|
385
|
+
children: /* @__PURE__ */ w(b, {})
|
|
386
386
|
});
|
|
387
387
|
});
|
|
388
|
-
|
|
388
|
+
U.displayName = "DividerBlock";
|
|
389
389
|
//#endregion
|
|
390
390
|
//#region src/ai/blocks/stat-row.tsx
|
|
391
|
-
var
|
|
392
|
-
let { reducedMotion: r } =
|
|
393
|
-
return i.length === 0 ? null : /* @__PURE__ */
|
|
391
|
+
var W = C.memo(function({ data: t }) {
|
|
392
|
+
let { reducedMotion: r } = S(), i = t.stats ?? [];
|
|
393
|
+
return i.length === 0 ? null : /* @__PURE__ */ w("div", {
|
|
394
394
|
className: "flex flex-wrap gap-ds-05",
|
|
395
|
-
children: i.map((
|
|
396
|
-
let a =
|
|
397
|
-
value:
|
|
398
|
-
direction:
|
|
395
|
+
children: i.map((t, i) => {
|
|
396
|
+
let a = t.change ? {
|
|
397
|
+
value: t.change.value,
|
|
398
|
+
direction: t.change.direction
|
|
399
399
|
} : void 0;
|
|
400
|
-
return r ? /* @__PURE__ */
|
|
400
|
+
return r ? /* @__PURE__ */ w("div", {
|
|
401
401
|
className: "flex-1 min-w-[140px]",
|
|
402
|
-
children: /* @__PURE__ */
|
|
403
|
-
label:
|
|
404
|
-
value:
|
|
402
|
+
children: /* @__PURE__ */ w(x, {
|
|
403
|
+
label: t.label,
|
|
404
|
+
value: t.value,
|
|
405
405
|
delta: a
|
|
406
406
|
})
|
|
407
|
-
},
|
|
407
|
+
}, t.label) : /* @__PURE__ */ w(e.div, {
|
|
408
408
|
className: "flex-1 min-w-[140px]",
|
|
409
409
|
initial: {
|
|
410
410
|
opacity: 0,
|
|
@@ -415,18 +415,18 @@ var U = S.memo(function({ data: n }) {
|
|
|
415
415
|
y: 0
|
|
416
416
|
},
|
|
417
417
|
transition: {
|
|
418
|
-
...
|
|
418
|
+
...n.responsive,
|
|
419
419
|
delay: i * .08
|
|
420
420
|
},
|
|
421
|
-
children: /* @__PURE__ */
|
|
422
|
-
label:
|
|
423
|
-
value:
|
|
421
|
+
children: /* @__PURE__ */ w(x, {
|
|
422
|
+
label: t.label,
|
|
423
|
+
value: t.value,
|
|
424
424
|
delta: a
|
|
425
425
|
})
|
|
426
|
-
},
|
|
426
|
+
}, t.label);
|
|
427
427
|
})
|
|
428
428
|
});
|
|
429
429
|
});
|
|
430
|
-
|
|
430
|
+
W.displayName = "StatRowBlock";
|
|
431
431
|
//#endregion
|
|
432
|
-
export {
|
|
432
|
+
export { R as a, P as c, z as i, j as l, U as n, L as o, H as r, F as s, W as t };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stat-row.js","names":[],"sources":["../../src/ai/blocks/text.tsx","../../src/ai/blocks/block-table.tsx","../../src/ai/blocks/confirm.tsx","../../src/ai/blocks/success.tsx","../../src/ai/blocks/error.tsx","../../src/ai/blocks/info.tsx","../../src/ai/blocks/loading.tsx","../../src/ai/blocks/divider.tsx","../../src/ai/blocks/stat-row.tsx"],"sourcesContent":["'use client'\n\nimport * as React from 'react'\nimport Markdown from 'react-markdown'\nimport remarkGfm from 'remark-gfm'\nimport { cn } from '../../ui/lib/utils'\nimport type { BlockComponentProps } from '../types'\n\nconst TextBlock = React.memo(function TextBlock({\n data,\n confidence,\n}: BlockComponentProps<{ content: string }>) {\n return (\n <div\n className={cn(\n 'prose prose-sm',\n 'text-surface-fg',\n 'prose-headings:text-surface-fg',\n 'prose-a:text-accent-11 prose-a:underline',\n 'prose-code:text-accent-11 prose-code:bg-surface-raised prose-code:rounded prose-code:px-1',\n 'prose-strong:text-surface-fg',\n confidence === 'low' && 'border-l-2 border-warning-7 pl-3',\n )}\n >\n <Markdown remarkPlugins={[remarkGfm]}>{data.content}</Markdown>\n </div>\n )\n})\n\nTextBlock.displayName = 'TextBlock'\n\nexport { TextBlock }\n","'use client'\n\nimport * as React from 'react'\nimport { motion } from 'framer-motion'\nimport { cn } from '../../ui/lib/utils'\nimport { springs } from '../../ui/lib/motion'\nimport { useMotion } from '../../motion/motion-provider'\nimport {\n Table,\n TableHeader,\n TableBody,\n TableRow,\n TableHead,\n TableCell,\n TableCaption,\n} from '../../ui/table'\nimport { Badge } from '../../ui/badge'\nimport type { BlockComponentProps, BlockTableData, BlockTableColumn } from '../types'\n\ntype SortDir = 'asc' | 'desc' | null\n\nfunction renderCellValue(value: unknown, column: BlockTableColumn) {\n if (column.variant === 'badge') {\n if (value && typeof value === 'object' && 'label' in value) {\n const badgeObj = value as { label: string; color: string }\n return (\n <Badge variant=\"subtle\" size=\"sm\" color={badgeObj.color as 'default'}>\n {badgeObj.label}\n </Badge>\n )\n }\n return (\n <Badge variant=\"subtle\" size=\"sm\">\n {String(value ?? '')}\n </Badge>\n )\n }\n\n return String(value ?? '')\n}\n\nfunction sortRows(\n rows: Record<string, unknown>[],\n sortKey: string | null,\n sortDir: SortDir,\n): Record<string, unknown>[] {\n if (!sortKey || !sortDir) return rows\n return [...rows].sort((a, b) => {\n const aVal = a[sortKey]\n const bVal = b[sortKey]\n const aStr = String(aVal ?? '')\n const bStr = String(bVal ?? '')\n const aNum = Number(aVal)\n const bNum = Number(bVal)\n\n // If both are numeric, sort numerically\n if (!Number.isNaN(aNum) && !Number.isNaN(bNum)) {\n return sortDir === 'asc' ? aNum - bNum : bNum - aNum\n }\n\n // Otherwise sort lexicographically\n const cmp = aStr.localeCompare(bStr)\n return sortDir === 'asc' ? cmp : -cmp\n })\n}\n\nconst BlockTable = React.memo(function BlockTable({\n data,\n confidence,\n}: BlockComponentProps<BlockTableData>) {\n const { reducedMotion } = useMotion()\n const [sortKey, setSortKey] = React.useState<string | null>(null)\n const [sortDir, setSortDir] = React.useState<SortDir>(null)\n\n const handleHeaderClick = React.useCallback(\n (key: string) => {\n if (!data.sortable) return\n if (sortKey !== key) {\n setSortKey(key)\n setSortDir('asc')\n } else if (sortDir === 'asc') {\n setSortDir('desc')\n } else if (sortDir === 'desc') {\n setSortKey(null)\n setSortDir(null)\n }\n },\n [data.sortable, sortKey, sortDir],\n )\n\n const columns = data.columns ?? []\n const sortedRows = sortRows(data.rows ?? [], sortKey, sortDir)\n\n return (\n <div\n className={cn(\n 'overflow-x-auto',\n confidence === 'low' && 'border-l-2 border-warning-7 pl-3',\n )}\n >\n <Table>\n {data.caption && <TableCaption>{data.caption}</TableCaption>}\n <TableHeader>\n <TableRow>\n {columns.map((col) => {\n const isSorted = sortKey === col.key\n const ariaSort = data.sortable\n ? isSorted\n ? sortDir === 'asc'\n ? ('ascending' as const)\n : ('descending' as const)\n : ('none' as const)\n : undefined\n\n return (\n <TableHead\n key={col.key}\n role=\"columnheader\"\n className={cn(\n col.variant === 'number' && 'text-right',\n data.sortable && 'cursor-pointer select-none',\n )}\n tabIndex={data.sortable ? 0 : undefined}\n onClick={\n data.sortable\n ? () => handleHeaderClick(col.key)\n : undefined\n }\n onKeyDown={\n data.sortable\n ? (e: React.KeyboardEvent) => {\n if (e.key === 'Enter' || e.key === ' ') {\n e.preventDefault()\n handleHeaderClick(col.key)\n }\n }\n : undefined\n }\n aria-sort={ariaSort}\n >\n <span className=\"inline-flex items-center gap-1\">\n {col.label}\n {isSorted && sortDir === 'asc' && (\n <span aria-hidden=\"true\">▲</span>\n )}\n {isSorted && sortDir === 'desc' && (\n <span aria-hidden=\"true\">▼</span>\n )}\n </span>\n </TableHead>\n )\n })}\n </TableRow>\n </TableHeader>\n <TableBody>\n {sortedRows.map((row, rowIndex) => {\n const rowKey =\n typeof row.id === 'string' || typeof row.id === 'number'\n ? String(row.id)\n : `row-${rowIndex}`\n\n const RowWrapper = reducedMotion ? 'tr' : motion.tr\n\n const motionProps = reducedMotion\n ? {}\n : {\n initial: { opacity: 0, y: 6 } as const,\n animate: { opacity: 1, y: 0 } as const,\n transition: { ...springs.responsive, delay: rowIndex * 0.03 },\n }\n\n return (\n <RowWrapper\n key={rowKey}\n className=\"hover:bg-surface-raised-hover transition-colors\"\n {...motionProps}\n >\n {columns.map((col) => (\n <TableCell\n key={col.key}\n className={cn(\n 'text-ds-sm py-ds-02b px-ds-04',\n col.variant === 'number' &&\n 'text-right tabular-nums font-medium',\n )}\n >\n {renderCellValue(row[col.key], col)}\n </TableCell>\n ))}\n </RowWrapper>\n )\n })}\n </TableBody>\n </Table>\n </div>\n )\n})\n\nBlockTable.displayName = 'BlockTable'\n\nexport { BlockTable }\n","'use client'\n\nimport * as React from 'react'\nimport { cn } from '../../ui/lib/utils'\nimport { Button } from '../../ui/button'\nimport {\n Collapsible,\n CollapsibleTrigger,\n CollapsibleContent,\n} from '../../ui/collapsible'\nimport type { BlockComponentProps, ConfirmBlockData } from '../types'\n\nconst ConfirmBlock = React.memo(function ConfirmBlock({\n data,\n confidence,\n onAction,\n}: BlockComponentProps<ConfirmBlockData>) {\n const handleConfirm = React.useCallback(() => {\n onAction?.(data.actionId, 'confirm')\n }, [data.actionId, onAction])\n\n const handleCancel = React.useCallback(() => {\n onAction?.(data.actionId, 'cancel')\n }, [data.actionId, onAction])\n\n return (\n <div\n className={cn(\n confidence === 'low' && 'border-l-2 border-warning-7 pl-3',\n )}\n >\n {data.description && (\n <p className=\"text-ds-sm text-surface-fg-muted mb-3\">\n {data.description}\n </p>\n )}\n\n <div className=\"flex items-center gap-3\">\n <Button\n variant=\"solid\"\n color={data.destructive ? 'error' : undefined}\n onClick={handleConfirm}\n >\n {data.label}\n </Button>\n <Button variant=\"ghost\" onClick={handleCancel}>\n Cancel\n </Button>\n </div>\n\n {data.rationale && (\n <Collapsible className=\"mt-3\">\n <CollapsibleTrigger asChild>\n <button\n type=\"button\"\n className=\"text-ds-xs text-surface-fg-subtle underline cursor-pointer\"\n >\n Why this action?\n </button>\n </CollapsibleTrigger>\n <CollapsibleContent>\n <p className=\"text-ds-sm text-surface-fg-muted mt-2 p-3 bg-surface-raised rounded-ds-lg\">\n {data.rationale}\n </p>\n </CollapsibleContent>\n </Collapsible>\n )}\n </div>\n )\n})\n\nConfirmBlock.displayName = 'ConfirmBlock'\n\nexport { ConfirmBlock }\n","'use client'\n\nimport * as React from 'react'\nimport { motion } from 'framer-motion'\nimport { cn } from '../../ui/lib/utils'\nimport { Alert } from '../../ui/alert'\nimport { Button } from '../../ui/button'\nimport { useMotion } from '../../motion/motion-provider'\nimport type { BlockComponentProps, SuccessBlockData } from '../types'\n\nconst DEFAULT_UNDO_TIMEOUT = 5000\n\nconst SuccessBlock = React.memo(function SuccessBlock({\n data,\n blockId,\n confidence,\n onAction,\n}: BlockComponentProps<SuccessBlockData>) {\n const { reducedMotion } = useMotion()\n const isReduced = reducedMotion\n const undoTimeout = data.undoTimeout ?? DEFAULT_UNDO_TIMEOUT\n const [remaining, setRemaining] = React.useState(undoTimeout)\n const [showUndo, setShowUndo] = React.useState(!!data.undoable)\n\n React.useEffect(() => {\n if (!data.undoable) return\n\n const interval = setInterval(() => {\n setRemaining((prev) => {\n const next = prev - 100\n if (next <= 0) {\n clearInterval(interval)\n setShowUndo(false)\n return 0\n }\n return next\n })\n }, 100)\n\n return () => clearInterval(interval)\n }, [data.undoable, undoTimeout])\n\n const handleUndo = React.useCallback(() => {\n onAction?.(blockId || 'unknown', 'undo')\n }, [blockId, onAction])\n\n const remainingSeconds = Math.ceil(remaining / 1000)\n\n // Countdown ring dimensions\n const ringSize = 20\n const ringStroke = 2\n const ringRadius = (ringSize - ringStroke) / 2\n const ringCircumference = 2 * Math.PI * ringRadius\n\n return (\n <div\n className={cn(\n confidence === 'low' && 'border-l-2 border-warning-7 pl-3',\n )}\n >\n <Alert\n color=\"success\"\n variant=\"subtle\"\n title={data.title}\n >\n {data.message}\n </Alert>\n\n {showUndo && data.undoable && (\n <div className=\"mt-2 flex items-center gap-2\">\n <Button\n variant=\"ghost\"\n size=\"sm\"\n onClick={handleUndo}\n aria-label={`Undo action, ${remainingSeconds} seconds remaining`}\n >\n <span className=\"flex items-center gap-1.5\">\n <svg\n width={ringSize}\n height={ringSize}\n viewBox={`0 0 ${ringSize} ${ringSize}`}\n className=\"shrink-0 -rotate-90\"\n aria-hidden=\"true\"\n >\n <circle\n cx={ringSize / 2}\n cy={ringSize / 2}\n r={ringRadius}\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth={ringStroke}\n opacity={0.2}\n />\n <motion.circle\n cx={ringSize / 2}\n cy={ringSize / 2}\n r={ringRadius}\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth={ringStroke}\n strokeDasharray={ringCircumference}\n initial={isReduced ? undefined : { strokeDashoffset: 0 }}\n animate={{\n strokeDashoffset: ringCircumference,\n }}\n transition={\n isReduced\n ? { duration: 0 }\n : {\n duration: undoTimeout / 1000,\n ease: 'linear',\n }\n }\n />\n </svg>\n Undo\n </span>\n </Button>\n </div>\n )}\n\n </div>\n )\n})\n\nSuccessBlock.displayName = 'SuccessBlock'\n\nexport { SuccessBlock }\n","'use client'\n\nimport * as React from 'react'\nimport Markdown from 'react-markdown'\nimport remarkGfm from 'remark-gfm'\nimport { cn } from '../../ui/lib/utils'\nimport { Alert } from '../../ui/alert'\nimport type { BlockComponentProps, ErrorBlockData } from '../types'\n\nconst ErrorBlock = React.memo(function ErrorBlock({\n data,\n confidence,\n}: BlockComponentProps<ErrorBlockData>) {\n return (\n <div\n className={cn(\n confidence === 'low' && 'border-l-2 border-warning-7 pl-3',\n )}\n >\n <Alert color=\"error\" variant=\"subtle\" title={data.title}>\n <div className=\"prose prose-sm\">\n <Markdown remarkPlugins={[remarkGfm]}>{data.message}</Markdown>\n </div>\n </Alert>\n {data.suggestion && (\n <p className=\"mt-2 text-ds-sm text-surface-fg-muted\">\n {data.suggestion}\n </p>\n )}\n </div>\n )\n})\n\nErrorBlock.displayName = 'ErrorBlock'\n\nexport { ErrorBlock }\n","'use client'\n\nimport * as React from 'react'\nimport { Alert } from '../../ui/alert'\nimport type { BlockComponentProps } from '../types'\n\nconst InfoBlock = React.memo(function InfoBlock({\n data,\n}: BlockComponentProps<{ message: string }>) {\n return (\n <Alert color=\"info\" variant=\"subtle\" role=\"status\">\n {data.message}\n </Alert>\n )\n})\n\nInfoBlock.displayName = 'InfoBlock'\n\nexport { InfoBlock }\n","'use client'\n\nimport * as React from 'react'\nimport { motion } from 'framer-motion'\nimport {\n IconCircleCheck,\n IconCircle,\n IconCircleX,\n} from '@tabler/icons-react'\nimport { Icon } from '../../ui/icon'\nimport { cn } from '../../ui/lib/utils'\nimport { Skeleton } from '../../ui/skeleton'\nimport { useMotion } from '../../motion/motion-provider'\nimport { durations } from '../../ui/lib/motion'\nimport type { BlockComponentProps, LoadingBlockData, ProcessingStep } from '../types'\n\n/** Spinning indicator for active steps */\nfunction StepSpinner() {\n return (\n <motion.span\n className=\"inline-block h-4 w-4 rounded-full border-2 border-current border-t-transparent text-accent-9\"\n animate={{ rotate: 360 }}\n transition={{ repeat: Infinity, duration: 1, ease: 'linear' }}\n aria-hidden=\"true\"\n data-testid=\"step-spinner\"\n />\n )\n}\n\n/** Icon for a processing step based on its status */\nfunction StepIcon({ status }: { status: ProcessingStep['status'] }) {\n switch (status) {\n case 'done':\n return (\n <span data-testid=\"step-icon-done\">\n <Icon icon={IconCircleCheck} size=\"sm\" className=\"text-success-11\" />\n </span>\n )\n case 'active':\n return <StepSpinner />\n case 'error':\n return (\n <span data-testid=\"step-icon-error\">\n <Icon icon={IconCircleX} size=\"sm\" className=\"text-error-11\" />\n </span>\n )\n case 'pending':\n default:\n return (\n <span data-testid=\"step-icon-pending\">\n <Icon icon={IconCircle} size=\"sm\" className=\"text-surface-fg-subtle opacity-50\" />\n </span>\n )\n }\n}\n\nconst LoadingBlock = React.memo(function LoadingBlock({\n data,\n}: BlockComponentProps<LoadingBlockData>) {\n const { reducedMotion } = useMotion()\n const isReduced = reducedMotion\n\n // Mode A: Skeleton lines\n if (data.lines != null) {\n const lineCount = Math.max(1, data.lines)\n return (\n <div\n role=\"status\"\n aria-busy=\"true\"\n aria-label=\"Loading\"\n className=\"flex flex-col gap-2\"\n >\n {Array.from({ length: lineCount }).map((_, i) => (\n <Skeleton\n key={i}\n animation=\"shimmer\"\n className={cn(\n 'h-4',\n i === lineCount - 1 ? 'w-3/5' : 'w-full',\n )}\n />\n ))}\n <span className=\"sr-only\">Loading</span>\n </div>\n )\n }\n\n // Mode B: Processing steps\n if (data.steps) {\n return (\n <div\n role=\"status\"\n aria-busy=\"true\"\n aria-label=\"Processing\"\n className=\"flex flex-col gap-2\"\n >\n {data.steps.map((step, index) => (\n <motion.div\n key={step.id}\n className=\"flex items-center gap-2\"\n initial={isReduced ? undefined : { opacity: 0, x: -8 }}\n animate={{ opacity: 1, x: 0 }}\n transition={\n isReduced\n ? { duration: 0 }\n : { duration: durations.moderate01b, delay: index * 0.06 }\n }\n >\n <StepIcon status={step.status} />\n <span\n className={cn(\n 'text-ds-sm',\n step.status === 'done' || step.status === 'active'\n ? 'text-surface-fg'\n : 'text-surface-fg-subtle',\n )}\n >\n {step.label}\n </span>\n </motion.div>\n ))}\n <span className=\"sr-only\">Processing</span>\n </div>\n )\n }\n\n // Fallback: empty status container\n return (\n <div role=\"status\" aria-busy=\"true\" aria-label=\"Loading\">\n <span className=\"sr-only\">Loading</span>\n </div>\n )\n})\n\nLoadingBlock.displayName = 'LoadingBlock'\n\nexport { LoadingBlock }\n","'use client'\n\nimport * as React from 'react'\nimport { motion } from 'framer-motion'\nimport { Separator } from '../../ui/separator'\nimport { tweens } from '../../ui/lib/motion'\nimport { useMotion } from '../../motion/motion-provider'\n\nimport type { BlockComponentProps } from '../types'\n\nconst DividerBlock = React.memo(function DividerBlock(\n _props: BlockComponentProps<Record<string, never>>,\n) {\n const { reducedMotion } = useMotion()\n\n if (reducedMotion) {\n return <Separator />\n }\n\n return (\n <motion.div\n initial={{ scaleX: 0 }}\n animate={{ scaleX: 1 }}\n style={{ originX: 0.5 }}\n transition={tweens.elegant}\n >\n <Separator />\n </motion.div>\n )\n})\n\nDividerBlock.displayName = 'DividerBlock'\n\nexport { DividerBlock }\n","'use client'\n\nimport * as React from 'react'\nimport { motion } from 'framer-motion'\nimport { springs } from '../../ui/lib/motion'\nimport { useMotion } from '../../motion/motion-provider'\nimport { StatCard } from '../../ui/stat-card'\nimport type { BlockComponentProps, StatRowBlockData } from '../types'\n\nconst StatRowBlock = React.memo(function StatRowBlock({\n data,\n}: BlockComponentProps<StatRowBlockData>) {\n const { reducedMotion } = useMotion()\n const stats = data.stats ?? []\n\n if (stats.length === 0) return null\n\n return (\n <div className=\"flex flex-wrap gap-ds-05\">\n {stats.map((stat, index) => {\n const delta = stat.change\n ? {\n value: stat.change.value,\n direction: stat.change.direction,\n }\n : undefined\n\n if (reducedMotion) {\n return (\n <div key={stat.label} className=\"flex-1 min-w-[140px]\">\n <StatCard\n label={stat.label}\n value={stat.value}\n delta={delta}\n />\n </div>\n )\n }\n\n return (\n <motion.div\n key={stat.label}\n className=\"flex-1 min-w-[140px]\"\n initial={{ opacity: 0, y: 8 }}\n animate={{ opacity: 1, y: 0 }}\n transition={{ ...springs.responsive, delay: index * 0.08 }}\n >\n <StatCard\n label={stat.label}\n value={stat.value}\n delta={delta}\n />\n </motion.div>\n )\n })}\n </div>\n )\n})\n\nStatRowBlock.displayName = 'StatRowBlock'\n\nexport { StatRowBlock }\n"],"mappings":";;;;;;;;;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