@devalok/shilp-sutra 0.53.0 → 0.55.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +7 -1
- package/BREAKING.json +29 -0
- package/MIGRATION.md +83 -0
- package/dist/_chunks/badge-group.js +1 -1
- package/dist/_chunks/popover.js +38 -37
- package/dist/_chunks/popover.js.map +1 -1
- package/dist/_chunks/primitives/react-accordion.js +270 -0
- package/dist/_chunks/primitives/react-accordion.js.map +1 -0
- package/dist/_chunks/primitives/react-alert-dialog.js +857 -0
- package/dist/_chunks/primitives/react-alert-dialog.js.map +1 -0
- package/dist/_chunks/primitives/react-aspect-ratio.js +32 -0
- package/dist/_chunks/primitives/react-aspect-ratio.js.map +1 -0
- package/dist/_chunks/primitives/react-avatar.js +69 -0
- package/dist/_chunks/primitives/react-avatar.js.map +1 -0
- package/dist/_chunks/primitives/react-checkbox.js +151 -0
- package/dist/_chunks/primitives/react-checkbox.js.map +1 -0
- package/dist/_chunks/primitives/react-context-menu.js +905 -0
- package/dist/_chunks/primitives/react-context-menu.js.map +1 -0
- package/dist/_chunks/primitives/react-dropdown-menu.js +220 -0
- package/dist/_chunks/primitives/react-dropdown-menu.js.map +1 -0
- package/dist/_chunks/primitives/react-hover-card.js +153 -0
- package/dist/_chunks/primitives/react-hover-card.js.map +1 -0
- package/dist/_chunks/primitives/react-label.js +16 -0
- package/dist/_chunks/primitives/react-label.js.map +1 -0
- package/dist/_chunks/primitives/react-menubar.js +304 -0
- package/dist/_chunks/primitives/react-menubar.js.map +1 -0
- package/dist/_chunks/primitives/react-navigation-menu.js +560 -0
- package/dist/_chunks/primitives/react-navigation-menu.js.map +1 -0
- package/dist/_chunks/primitives/react-popover.js +186 -0
- package/dist/_chunks/primitives/react-popover.js.map +1 -0
- package/dist/_chunks/primitives/react-progress.js +70 -0
- package/dist/_chunks/primitives/react-progress.js.map +1 -0
- package/dist/_chunks/primitives/react-radio-group.js +170 -0
- package/dist/_chunks/primitives/react-radio-group.js.map +1 -0
- package/dist/_chunks/primitives/react-select.js +671 -0
- package/dist/_chunks/primitives/react-select.js.map +1 -0
- package/dist/_chunks/primitives/react-separator.js +24 -0
- package/dist/_chunks/primitives/react-separator.js.map +1 -0
- package/dist/_chunks/primitives/react-slider.js +349 -0
- package/dist/_chunks/primitives/react-slider.js.map +1 -0
- package/dist/_chunks/primitives/react-switch.js +92 -0
- package/dist/_chunks/primitives/react-switch.js.map +1 -0
- package/dist/_chunks/primitives/react-tabs.js +114 -0
- package/dist/_chunks/primitives/react-tabs.js.map +1 -0
- package/dist/_chunks/primitives/react-toggle-group.js +122 -0
- package/dist/_chunks/primitives/react-toggle-group.js.map +1 -0
- package/dist/_chunks/primitives/react-toggle.js +28 -0
- package/dist/_chunks/primitives/react-toggle.js.map +1 -0
- package/dist/_chunks/primitives/react-tooltip.js +341 -0
- package/dist/_chunks/primitives/react-tooltip.js.map +1 -0
- package/dist/_chunks/primitives-internal.js +2071 -0
- package/dist/_chunks/primitives-internal.js.map +1 -0
- package/dist/_chunks/shared.js +32 -32
- package/dist/_chunks/tiptap.js +1 -1
- package/dist/ai/ai-command-provider.d.ts +2 -3
- package/dist/ai/block-renderer.d.ts +1 -2
- package/dist/ai/blocks/block-shell.d.ts +0 -1
- package/dist/ai/blocks/block-table.d.ts +1 -2
- package/dist/ai/blocks/confirm.d.ts +1 -2
- package/dist/ai/blocks/divider.d.ts +1 -2
- package/dist/ai/blocks/error.d.ts +1 -2
- package/dist/ai/blocks/index.d.ts +7 -8
- package/dist/ai/blocks/info.d.ts +1 -2
- package/dist/ai/blocks/loading.d.ts +1 -2
- package/dist/ai/blocks/stat-row.d.ts +1 -2
- package/dist/ai/blocks/success.d.ts +1 -2
- package/dist/ai/blocks/text.d.ts +1 -2
- package/dist/ai/command-bar.d.ts +1 -2
- package/dist/ai/conversation.d.ts +2 -3
- package/dist/ai/devadoot-icon.d.ts +0 -1
- package/dist/ai/index.d.ts +16 -17
- package/dist/ai/types.js +1 -0
- package/dist/composed/activity-feed.d.ts +1 -2
- package/dist/composed/avatar-group.d.ts +11 -10
- package/dist/composed/avatar-group.d.ts.map +1 -1
- package/dist/composed/avatar-group.js +108 -140
- package/dist/composed/avatar-group.js.map +1 -1
- package/dist/composed/bulk-action-bar.d.ts +20 -13
- package/dist/composed/bulk-action-bar.d.ts.map +1 -1
- package/dist/composed/bulk-action-bar.js +81 -110
- package/dist/composed/bulk-action-bar.js.map +1 -1
- package/dist/composed/command-palette.d.ts +1 -2
- package/dist/composed/confirm-dialog.d.ts +0 -1
- package/dist/composed/date-picker/calendar-grid.d.ts +0 -1
- package/dist/composed/date-picker/date-picker.d.ts +0 -1
- package/dist/composed/date-picker/date-range-picker.d.ts +1 -2
- package/dist/composed/date-picker/date-time-picker.d.ts +0 -1
- package/dist/composed/date-picker/index.d.ts +17 -18
- package/dist/composed/date-picker/month-picker.d.ts +0 -1
- package/dist/composed/date-picker/presets.d.ts +0 -1
- package/dist/composed/date-picker/time-picker.d.ts +0 -1
- package/dist/composed/date-picker/use-calendar.d.ts +0 -1
- package/dist/composed/date-picker/year-picker.d.ts +0 -1
- package/dist/composed/deadline-indicator.d.ts +0 -1
- package/dist/composed/diff.d.ts +0 -1
- package/dist/composed/emoji-picker.d.ts +0 -1
- package/dist/composed/empty-state.d.ts +1 -2
- package/dist/composed/error-boundary.d.ts +15 -4
- package/dist/composed/error-boundary.d.ts.map +1 -1
- package/dist/composed/error-boundary.js +43 -26
- package/dist/composed/error-boundary.js.map +1 -1
- package/dist/composed/extensions/emoji-data.d.ts +0 -1
- package/dist/composed/extensions/emoji-node.d.ts +0 -1
- package/dist/composed/extensions/emoji-suggestion.d.ts +1 -2
- package/dist/composed/extensions/file-attachment.d.ts +0 -1
- package/dist/composed/extensions/mention-suggestion.d.ts +1 -2
- package/dist/composed/extensions/slash-command.d.ts +0 -1
- package/dist/composed/file-preview/audio-preview.d.ts +0 -1
- package/dist/composed/file-preview/document-preview.d.ts +0 -1
- package/dist/composed/file-preview/embed-preview.d.ts +0 -1
- package/dist/composed/file-preview/image-preview.d.ts +0 -1
- package/dist/composed/file-preview/shared.d.ts +0 -1
- package/dist/composed/file-preview/video-preview.d.ts +0 -1
- package/dist/composed/file-preview.d.ts +0 -1
- package/dist/composed/filter-bar.d.ts +0 -1
- package/dist/composed/form-section.d.ts +0 -1
- package/dist/composed/global-loading.d.ts +0 -1
- package/dist/composed/index.d.ts +49 -50
- package/dist/composed/inline-edit.d.ts +0 -1
- package/dist/composed/loading-skeleton.d.ts +2 -0
- package/dist/composed/loading-skeleton.d.ts.map +1 -1
- package/dist/composed/loading-skeleton.js +79 -56
- package/dist/composed/loading-skeleton.js.map +1 -1
- package/dist/composed/markdown-viewer.d.ts +0 -1
- package/dist/composed/master-detail.d.ts +21 -9
- package/dist/composed/master-detail.d.ts.map +1 -1
- package/dist/composed/master-detail.js +91 -77
- package/dist/composed/master-detail.js.map +1 -1
- package/dist/composed/member-picker.d.ts +0 -1
- package/dist/composed/multi-select-popover.d.ts +0 -1
- package/dist/composed/page-skeletons.d.ts +6 -0
- package/dist/composed/page-skeletons.d.ts.map +1 -1
- package/dist/composed/page-skeletons.js +93 -71
- package/dist/composed/page-skeletons.js.map +1 -1
- package/dist/composed/priority-indicator.d.ts +0 -1
- package/dist/composed/responsive-modal.d.ts +1 -2
- package/dist/composed/responsive-modal.js +47 -47
- package/dist/composed/rich-chat-input/attachment-strip.d.ts +0 -1
- package/dist/composed/rich-chat-input/audio-player.d.ts +0 -1
- package/dist/composed/rich-chat-input/audio-waveform.d.ts +0 -1
- package/dist/composed/rich-chat-input/chat-toolbar.d.ts +0 -1
- package/dist/composed/rich-chat-input/recording-overlay.d.ts +0 -1
- package/dist/composed/rich-chat-input/reply-banner.d.ts +0 -1
- package/dist/composed/rich-chat-input/schedule-send.d.ts +0 -1
- package/dist/composed/rich-chat-input/use-voice-recorder.d.ts +0 -1
- package/dist/composed/rich-chat-input.d.ts +9 -10
- package/dist/composed/rich-chat-input.js +1 -1
- package/dist/composed/rich-text-editor.d.ts +1 -2
- package/dist/composed/schedule-view.d.ts +0 -1
- package/dist/composed/simple-tooltip.d.ts +0 -1
- package/dist/composed/status-badge.d.ts +1 -2
- package/dist/hooks/index.d.ts +6 -7
- package/dist/hooks/use-color-mode.d.ts +0 -1
- package/dist/hooks/use-mobile.d.ts +0 -1
- package/dist/hooks/use-touch-device.d.ts +0 -1
- package/dist/hooks/use-viewport-height.d.ts +0 -1
- package/dist/motion/check-motion-provider.d.ts +0 -1
- package/dist/motion/index.d.ts +2 -3
- package/dist/motion/motion-provider.d.ts +1 -2
- package/dist/motion/primitives-index.d.ts +1 -2
- package/dist/motion/primitives.d.ts +1 -2
- package/dist/primitives/_internal/react-arrow.d.ts +1 -1
- package/dist/primitives/_internal/react-collection.d.ts +2 -2
- package/dist/primitives/_internal/react-dismissable-layer.d.ts +1 -1
- package/dist/primitives/_internal/react-focus-scope.d.ts +1 -1
- package/dist/primitives/_internal/react-popper.d.ts +4 -4
- package/dist/primitives/_internal/react-portal.d.ts +1 -1
- package/dist/primitives/_internal/react-use-rect.d.ts +1 -1
- package/dist/primitives/react-accordion.d.ts +3 -3
- package/dist/primitives/react-alert-dialog.d.ts +2 -2
- package/dist/primitives/react-aspect-ratio.d.ts +1 -1
- package/dist/primitives/react-avatar.d.ts +2 -2
- package/dist/primitives/react-checkbox.d.ts +3 -3
- package/dist/primitives/react-collapsible.d.ts +2 -2
- package/dist/primitives/react-context-menu.d.ts +3 -3
- package/dist/primitives/react-dialog.d.ts +5 -5
- package/dist/primitives/react-dropdown-menu.d.ts +3 -3
- package/dist/primitives/react-hover-card.d.ts +5 -5
- package/dist/primitives/react-label.d.ts +1 -1
- package/dist/primitives/react-menu.d.ts +7 -7
- package/dist/primitives/react-menubar.d.ts +5 -5
- package/dist/primitives/react-navigation-menu.d.ts +5 -5
- package/dist/primitives/react-popover.d.ts +6 -6
- package/dist/primitives/react-progress.d.ts +2 -2
- package/dist/primitives/react-radio-group.d.ts +3 -3
- package/dist/primitives/react-roving-focus.d.ts +2 -2
- package/dist/primitives/react-select.d.ts +6 -6
- package/dist/primitives/react-separator.d.ts +1 -1
- package/dist/primitives/react-slider.d.ts +2 -2
- package/dist/primitives/react-switch.d.ts +2 -2
- package/dist/primitives/react-tabs.d.ts +3 -3
- package/dist/primitives/react-toast.d.ts +3 -3
- package/dist/primitives/react-toggle-group.d.ts +4 -4
- package/dist/primitives/react-toggle.d.ts +1 -1
- package/dist/primitives/react-tooltip.d.ts +5 -5
- package/dist/primitives/react-visually-hidden.d.ts +1 -1
- package/dist/shell/app-command-palette.d.ts +2 -3
- package/dist/shell/bottom-navbar.d.ts +1 -2
- package/dist/shell/command-registry.d.ts +1 -2
- package/dist/shell/index.d.ts +12 -11
- package/dist/shell/index.d.ts.map +1 -1
- package/dist/shell/index.js +2 -3
- package/dist/shell/link-context.d.ts +2 -3
- package/dist/shell/notification-center.d.ts +0 -1
- package/dist/shell/notification-preferences.d.ts +0 -1
- package/dist/shell/notification-preferences.d.ts.map +1 -1
- package/dist/shell/notification-preferences.js +2 -0
- package/dist/shell/notification-preferences.js.map +1 -1
- package/dist/shell/top-bar.d.ts +1 -2
- package/dist/test-utils/conformance.d.ts +0 -1
- package/dist/ui/accordion.d.ts +1 -2
- package/dist/ui/accordion.js +1 -1
- package/dist/ui/alert-dialog.d.ts +1 -2
- package/dist/ui/alert-dialog.js +52 -52
- package/dist/ui/alert.d.ts +0 -1
- package/dist/ui/aspect-ratio.d.ts +1 -2
- package/dist/ui/aspect-ratio.js +4 -4
- package/dist/ui/autocomplete.d.ts +1 -2
- package/dist/ui/autocomplete.js +1 -1
- package/dist/ui/avatar.d.ts +1 -2
- package/dist/ui/avatar.js +33 -33
- package/dist/ui/badge-group.d.ts +1 -2
- package/dist/ui/badge-indicator.d.ts +0 -1
- package/dist/ui/badge.d.ts +3 -4
- package/dist/ui/banner.d.ts +0 -1
- package/dist/ui/breadcrumb.js +1 -1
- package/dist/ui/button-group.d.ts +1 -2
- package/dist/ui/button-processing.d.ts +0 -1
- package/dist/ui/button.d.ts +1 -2
- package/dist/ui/button.js +1 -1
- package/dist/ui/card.d.ts +0 -1
- package/dist/ui/charts/_internal/animation.d.ts +0 -1
- package/dist/ui/charts/_internal/axes.d.ts +0 -1
- package/dist/ui/charts/_internal/colors.d.ts +1 -2
- package/dist/ui/charts/_internal/grid-lines.d.ts +0 -1
- package/dist/ui/charts/_internal/legend.d.ts +0 -1
- package/dist/ui/charts/_internal/scales.d.ts +0 -1
- package/dist/ui/charts/_internal/tooltip.d.ts +0 -1
- package/dist/ui/charts/_internal/types.d.ts +0 -1
- package/dist/ui/charts/area-chart.d.ts +1 -2
- package/dist/ui/charts/bar-chart.d.ts +1 -2
- package/dist/ui/charts/chart-container.d.ts +1 -2
- package/dist/ui/charts/gauge-chart.d.ts +0 -1
- package/dist/ui/charts/index.d.ts +9 -10
- package/dist/ui/charts/line-chart.d.ts +1 -2
- package/dist/ui/charts/pie-chart.d.ts +0 -1
- package/dist/ui/charts/radar-chart.d.ts +0 -1
- package/dist/ui/charts/sparkline.d.ts +0 -1
- package/dist/ui/chat/date-separator.d.ts +0 -1
- package/dist/ui/chat/index.d.ts +7 -8
- package/dist/ui/chat/message-input.d.ts +0 -1
- package/dist/ui/chat/message-list.d.ts +0 -1
- package/dist/ui/chat/message.d.ts +1 -2
- package/dist/ui/chat/system-message.d.ts +1 -2
- package/dist/ui/chat/typing-indicator.d.ts +0 -1
- package/dist/ui/chat/unread-separator.d.ts +0 -1
- package/dist/ui/checkbox.d.ts +2 -3
- package/dist/ui/checkbox.js +13 -13
- package/dist/ui/collapsible.d.ts +1 -2
- package/dist/ui/collapsible.js +1 -1
- package/dist/ui/color-input.d.ts +0 -1
- package/dist/ui/color-swatch.d.ts +0 -1
- package/dist/ui/combobox.d.ts +3 -4
- package/dist/ui/combobox.d.ts.map +1 -1
- package/dist/ui/combobox.js +146 -141
- package/dist/ui/combobox.js.map +1 -1
- package/dist/ui/context-menu.d.ts +1 -2
- package/dist/ui/context-menu.js +58 -58
- package/dist/ui/data-table-body.d.ts +0 -1
- package/dist/ui/data-table-bulk-actions.d.ts +0 -1
- package/dist/ui/data-table-card.d.ts +0 -1
- package/dist/ui/data-table-context.d.ts +0 -1
- package/dist/ui/data-table-header.d.ts +0 -1
- package/dist/ui/data-table-pagination.d.ts +0 -1
- package/dist/ui/data-table-toolbar.d.ts +0 -1
- package/dist/ui/data-table.d.ts +3 -4
- package/dist/ui/devalok-grain.d.ts +0 -1
- package/dist/ui/dialog.d.ts +1 -2
- package/dist/ui/dialog.js +43 -43
- package/dist/ui/dot.d.ts +0 -1
- package/dist/ui/dropdown-menu.d.ts +1 -2
- package/dist/ui/dropdown-menu.js +69 -69
- package/dist/ui/file-upload.d.ts +0 -1
- package/dist/ui/file-upload.d.ts.map +1 -1
- package/dist/ui/file-upload.js +124 -138
- package/dist/ui/file-upload.js.map +1 -1
- package/dist/ui/form.d.ts +7 -1
- package/dist/ui/form.d.ts.map +1 -1
- package/dist/ui/form.js +4 -2
- package/dist/ui/form.js.map +1 -1
- package/dist/ui/hover-card.d.ts +1 -2
- package/dist/ui/hover-card.js +16 -16
- package/dist/ui/icon-button.d.ts +4 -4
- package/dist/ui/icon-button.d.ts.map +1 -1
- package/dist/ui/icon-button.js +1 -1
- package/dist/ui/icon-button.js.map +1 -1
- package/dist/ui/icon-context.d.ts +0 -1
- package/dist/ui/icon-group.d.ts +1 -2
- package/dist/ui/icon.d.ts +1 -2
- package/dist/ui/index.d.ts +78 -79
- package/dist/ui/index.d.ts.map +1 -1
- package/dist/ui/index.js.map +1 -1
- package/dist/ui/input-otp.d.ts +0 -1
- package/dist/ui/input.d.ts +1 -2
- package/dist/ui/label.d.ts +1 -2
- package/dist/ui/label.d.ts.map +1 -1
- package/dist/ui/label.js +13 -12
- package/dist/ui/label.js.map +1 -1
- package/dist/ui/lib/bottom-sheet.d.ts +0 -1
- package/dist/ui/lib/check-tokens.d.ts +0 -1
- package/dist/ui/lib/field-state.d.ts +0 -1
- package/dist/ui/lib/icon-input.d.ts +0 -1
- package/dist/ui/lib/index.d.ts +6 -7
- package/dist/ui/lib/keybinding.d.ts +0 -1
- package/dist/ui/lib/link-context.d.ts +0 -1
- package/dist/ui/lib/mention.d.ts +0 -1
- package/dist/ui/lib/normalize-icon.d.ts +2 -2
- package/dist/ui/lib/slot.d.ts +2 -3
- package/dist/ui/lib/use-controllable-open.d.ts +0 -1
- package/dist/ui/link.d.ts +0 -1
- package/dist/ui/link.js +1 -1
- package/dist/ui/menubar.d.ts +1 -2
- package/dist/ui/menubar.js +64 -64
- package/dist/ui/navigation-menu.d.ts +1 -2
- package/dist/ui/navigation-menu.js +67 -67
- package/dist/ui/number-input.d.ts +1 -2
- package/dist/ui/oauth-button/index.d.ts +1 -2
- package/dist/ui/oauth-button/oauth-button.d.ts +2 -3
- package/dist/ui/pagination.d.ts +0 -1
- package/dist/ui/pagination.js +1 -1
- package/dist/ui/popover.d.ts +1 -2
- package/dist/ui/progress-ring.d.ts +0 -1
- package/dist/ui/progress.d.ts +1 -2
- package/dist/ui/progress.js +30 -30
- package/dist/ui/radio.d.ts +2 -3
- package/dist/ui/radio.js +18 -18
- package/dist/ui/search-input.d.ts +0 -1
- package/dist/ui/segmented-control.d.ts +1 -2
- package/dist/ui/select.d.ts +1 -2
- package/dist/ui/select.js +55 -55
- package/dist/ui/separator.d.ts +1 -2
- package/dist/ui/separator.js +5 -5
- package/dist/ui/sheet.d.ts +1 -2
- package/dist/ui/sheet.js +45 -45
- package/dist/ui/sidebar.d.ts +4 -5
- package/dist/ui/sidebar.js +1 -1
- package/dist/ui/slider.d.ts +1 -2
- package/dist/ui/slider.js +14 -14
- package/dist/ui/spinner.d.ts +0 -1
- package/dist/ui/spinner.d.ts.map +1 -1
- package/dist/ui/spinner.js +50 -44
- package/dist/ui/spinner.js.map +1 -1
- package/dist/ui/split-button.d.ts +14 -4
- package/dist/ui/split-button.d.ts.map +1 -1
- package/dist/ui/split-button.js.map +1 -1
- package/dist/ui/stat-card.d.ts +3 -4
- package/dist/ui/stat-flash.d.ts +1 -2
- package/dist/ui/stepper.d.ts +1 -2
- package/dist/ui/surface.js +1 -1
- package/dist/ui/switch.d.ts +2 -3
- package/dist/ui/switch.d.ts.map +1 -1
- package/dist/ui/switch.js +31 -31
- package/dist/ui/switch.js.map +1 -1
- package/dist/ui/table-row-link.d.ts +0 -1
- package/dist/ui/table.js +1 -1
- package/dist/ui/table.js.map +1 -1
- package/dist/ui/tabs.d.ts +1 -2
- package/dist/ui/tabs.js +35 -35
- package/dist/ui/textarea.d.ts +1 -2
- package/dist/ui/toast-registry.d.ts +0 -1
- package/dist/ui/toast-types.js +1 -0
- package/dist/ui/toast.d.ts +2 -3
- package/dist/ui/toaster.d.ts +0 -1
- package/dist/ui/toggle-group.d.ts +2 -3
- package/dist/ui/toggle-group.js +14 -14
- package/dist/ui/toggle.d.ts +1 -2
- package/dist/ui/toggle.js +12 -12
- package/dist/ui/tooltip.d.ts +1 -2
- package/dist/ui/tooltip.js +21 -21
- package/dist/ui/tree-view/index.d.ts +3 -4
- package/dist/ui/tree-view/tree-item.d.ts +1 -2
- package/dist/ui/tree-view/tree-view.d.ts +1 -2
- package/dist/ui/tree-view/use-tree.d.ts +1 -2
- package/dist/ui/truncated-text.d.ts +0 -1
- package/docs/components/composed/bulk-action-bar.md +9 -3
- package/docs/components/composed/error-boundary.md +18 -2
- package/docs/components/composed/master-detail.md +12 -2
- package/docs/components/composed/page-skeletons.md +2 -2
- package/docs/components/composed/rich-chat-input.md +18 -6
- package/docs/components/composed/simple-tooltip.md +1 -1
- package/docs/components/shell/app-command-palette.md +2 -1
- package/docs/components/shell/bottom-navbar.md +4 -4
- package/docs/components/shell/command-registry.md +2 -2
- package/docs/components/shell/link-context.md +2 -2
- package/docs/components/shell/top-bar.md +1 -1
- package/docs/components/ui/search-input.md +2 -2
- package/docs/components/ui/slider.md +2 -2
- package/docs/components/ui/split-button.md +3 -3
- package/docs/recipes/install-astro.md +2 -0
- package/docs/recipes/install-next-app-router.md +2 -0
- package/docs/recipes/install-remix.md +2 -0
- package/docs/recipes/install-tanstack-start.md +2 -0
- package/docs/recipes/install-vite.md +2 -0
- package/docs/recipes/troubleshoot.md +80 -0
- package/llms.txt +2 -2
- package/make-kit/Guidelines.md +1 -1
- package/make-kit/components/overview.md +2 -2
- package/make-kit/foundations/surfaces.md +1 -1
- package/mcp-manifest.json +411 -147
- package/package.json +30 -10
- package/skill/SKILL.md +1 -1
- package/skill/chat-skill/README.md +18 -0
- package/skill/chat-skill/SKILL.md +78 -0
- package/skill/chat-skill/chatgpt-instructions.md +26 -0
- package/skill/chat-skill/gemini-instructions.md +25 -0
- package/skill/references/components.md +2 -2
- package/skill/references/setup-astro.md +2 -0
- package/skill/references/setup-next-app-router.md +2 -0
- package/skill/references/setup-remix.md +2 -0
- package/skill/references/setup-tanstack-start.md +2 -0
- package/skill/references/setup-vite.md +2 -0
- package/skill/references/troubleshoot.md +80 -0
- package/dist/_chunks/primitives.js +0 -7596
- package/dist/_chunks/primitives.js.map +0 -1
- package/dist/shell/sidebar.d.ts +0 -113
- package/dist/shell/sidebar.d.ts.map +0 -1
- package/dist/shell/sidebar.js +0 -293
- package/dist/shell/sidebar.js.map +0 -1
- package/docs/components/shell/sidebar.md +0 -103
package/dist/ui/checkbox.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
import
|
|
3
|
-
import * as CheckboxPrimitive from '../primitives/react-checkbox';
|
|
1
|
+
import { FieldState } from './lib/field-state.js';
|
|
2
|
+
import * as CheckboxPrimitive from '../primitives/react-checkbox.js';
|
|
4
3
|
import * as React from 'react';
|
|
5
4
|
/**
|
|
6
5
|
* Props for Checkbox — a Radix-powered accessible checkbox with error state styling and
|
package/dist/ui/checkbox.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
2
|
+
import { durations as e } from "./lib/motion.js";
|
|
3
|
+
import { cn as t } from "./lib/utils.js";
|
|
4
|
+
import { useFormField as n } from "./form.js";
|
|
5
|
+
import { resolveFieldState as r } from "../_chunks/field-state.js";
|
|
6
|
+
import { Checkbox as i, CheckboxIndicator as a } from "../_chunks/primitives/react-checkbox.js";
|
|
7
7
|
import * as o from "react";
|
|
8
8
|
import { jsx as s } from "react/jsx-runtime";
|
|
9
9
|
import { AnimatePresence as c, motion as l } from "framer-motion";
|
|
@@ -21,20 +21,20 @@ var u = {
|
|
|
21
21
|
md: "h-[18px] w-[18px]",
|
|
22
22
|
lg: "h-5 w-5"
|
|
23
23
|
}, p = o.forwardRef(({ className: p, state: m, indeterminate: h, size: g = "md", checked: _, onCheckedChange: v, defaultChecked: y, ...b }, x) => {
|
|
24
|
-
let S = _ !== void 0, [C, w] = o.useState(h ? "indeterminate" : !!y), T =
|
|
24
|
+
let S = _ !== void 0, [C, w] = o.useState(h ? "indeterminate" : !!y), T = n(), E = r(m, T.state), D = b["aria-describedby"] ?? T.helperTextId, O = b["aria-required"] ?? T.required, k = h ? "indeterminate" : S ? _ : C, A = k === !0 || k === "indeterminate", j = o.useCallback((e) => {
|
|
25
25
|
S || w(e), v?.(e);
|
|
26
26
|
}, [S, v]);
|
|
27
|
-
return /* @__PURE__ */ s(
|
|
27
|
+
return /* @__PURE__ */ s(i, {
|
|
28
28
|
ref: x,
|
|
29
29
|
checked: S || h ? k : void 0,
|
|
30
30
|
defaultChecked: !S && !h ? y : void 0,
|
|
31
31
|
onCheckedChange: j,
|
|
32
|
-
className:
|
|
32
|
+
className: t("touch-target peer flex items-center justify-center shrink-0 rounded-control-inner", d[g], "border border-surface-border-strong", "bg-surface-raised-hover", "transition-colors duration-fast-01 ease-productive-standard", "focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-accent-9 focus-visible:ring-offset-2", "disabled:cursor-not-allowed disabled:opacity-action-disabled", "data-[state=unchecked]:hover:border-accent-7 data-[state=unchecked]:hover:bg-surface-raised-active", "data-[state=checked]:bg-accent-9 data-[state=checked]:border-accent-7 data-[state=checked]:text-accent-fg", "data-[state=indeterminate]:bg-accent-9 data-[state=indeterminate]:border-accent-7 data-[state=indeterminate]:text-accent-fg", E && u[E], p),
|
|
33
33
|
"aria-invalid": E === "error" || void 0,
|
|
34
34
|
"aria-describedby": D,
|
|
35
35
|
"aria-required": O || void 0,
|
|
36
36
|
...b,
|
|
37
|
-
children: /* @__PURE__ */ s(c, { children: A && /* @__PURE__ */ s(
|
|
37
|
+
children: /* @__PURE__ */ s(c, { children: A && /* @__PURE__ */ s(a, {
|
|
38
38
|
forceMount: !0,
|
|
39
39
|
asChild: !0,
|
|
40
40
|
children: /* @__PURE__ */ s(l.span, {
|
|
@@ -42,7 +42,7 @@ var u = {
|
|
|
42
42
|
initial: { opacity: 0 },
|
|
43
43
|
animate: { opacity: 1 },
|
|
44
44
|
exit: { opacity: 0 },
|
|
45
|
-
transition: { duration:
|
|
45
|
+
transition: { duration: e.fast01 },
|
|
46
46
|
children: /* @__PURE__ */ s("svg", {
|
|
47
47
|
width: "16",
|
|
48
48
|
height: "16",
|
|
@@ -61,7 +61,7 @@ var u = {
|
|
|
61
61
|
animate: { pathLength: 1 },
|
|
62
62
|
exit: { pathLength: 0 },
|
|
63
63
|
transition: {
|
|
64
|
-
duration:
|
|
64
|
+
duration: e.moderate02,
|
|
65
65
|
ease: "easeOut"
|
|
66
66
|
}
|
|
67
67
|
}) : /* @__PURE__ */ s(l.path, {
|
|
@@ -75,7 +75,7 @@ var u = {
|
|
|
75
75
|
animate: { pathLength: 1 },
|
|
76
76
|
exit: { pathLength: 0 },
|
|
77
77
|
transition: {
|
|
78
|
-
duration:
|
|
78
|
+
duration: e.moderate02,
|
|
79
79
|
ease: "easeOut"
|
|
80
80
|
}
|
|
81
81
|
})
|
|
@@ -84,6 +84,6 @@ var u = {
|
|
|
84
84
|
}) })
|
|
85
85
|
});
|
|
86
86
|
});
|
|
87
|
-
p.displayName =
|
|
87
|
+
p.displayName = i.displayName;
|
|
88
88
|
//#endregion
|
|
89
89
|
export { p as Checkbox };
|
package/dist/ui/collapsible.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import * as CollapsiblePrimitive from '../primitives/react-collapsible';
|
|
1
|
+
import * as CollapsiblePrimitive from '../primitives/react-collapsible.js';
|
|
3
2
|
import * as React from 'react';
|
|
4
3
|
declare const Collapsible: React.ForwardRefExoticComponent<CollapsiblePrimitive.CollapsibleProps & React.RefAttributes<HTMLDivElement>>;
|
|
5
4
|
declare const CollapsibleTrigger: React.ForwardRefExoticComponent<CollapsiblePrimitive.CollapsibleTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
package/dist/ui/collapsible.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { Content
|
|
2
|
+
import { Content as e, Root as t, Trigger as n } from "../_chunks/primitives/react-accordion.js";
|
|
3
3
|
import { tweens as r } from "./lib/motion.js";
|
|
4
4
|
import { cn as i } from "./lib/utils.js";
|
|
5
5
|
import * as a from "react";
|
package/dist/ui/color-input.d.ts
CHANGED
package/dist/ui/combobox.d.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
"use client";
|
|
2
1
|
import { VariantProps } from 'class-variance-authority';
|
|
3
|
-
import { FieldState } from './lib/field-state';
|
|
4
|
-
import { IconInput } from './lib/icon-input';
|
|
2
|
+
import { FieldState } from './lib/field-state.js';
|
|
3
|
+
import { IconInput } from './lib/icon-input.js';
|
|
5
4
|
import * as React from 'react';
|
|
6
5
|
export declare const comboboxTriggerVariants: (props?: ({
|
|
7
6
|
size?: "xs" | "sm" | "md" | "lg" | null | undefined;
|
|
@@ -98,6 +97,6 @@ interface ComboboxMultipleProps extends ComboboxBaseProps {
|
|
|
98
97
|
onValueChange: (value: string[]) => void;
|
|
99
98
|
}
|
|
100
99
|
export type ComboboxProps = ComboboxSingleProps | ComboboxMultipleProps;
|
|
101
|
-
declare const Combobox: React.ForwardRefExoticComponent<ComboboxProps & React.RefAttributes<
|
|
100
|
+
declare const Combobox: React.ForwardRefExoticComponent<ComboboxProps & React.RefAttributes<HTMLDivElement>>;
|
|
102
101
|
export { Combobox };
|
|
103
102
|
//# sourceMappingURL=combobox.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"combobox.d.ts","sourceRoot":"","sources":["../../src/ui/combobox.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAEjE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAK9B,OAAO,EAAE,KAAK,UAAU,EAAqB,MAAM,mBAAmB,CAAA;AACtE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAA;AAYjD,eAAO,MAAM,uBAAuB;;
|
|
1
|
+
{"version":3,"file":"combobox.d.ts","sourceRoot":"","sources":["../../src/ui/combobox.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAEjE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAK9B,OAAO,EAAE,KAAK,UAAU,EAAqB,MAAM,mBAAmB,CAAA;AACtE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAA;AAYjD,eAAO,MAAM,uBAAuB;;8EAsBnC,CAAA;AAED,MAAM,MAAM,YAAY,GAAG,WAAW,CAAC,YAAY,CAAC,OAAO,uBAAuB,CAAC,CAAC,MAAM,CAAC,CAAC,CAAA;AA0B5F;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,MAAM,CAAA;IACb,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,IAAI,CAAC,EAAE,SAAS,CAAA;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH,UAAU,iBAAkB,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,UAAU,CAAC;IACxF,+CAA+C;IAC/C,OAAO,EAAE,cAAc,EAAE,CAAA;IACzB,kEAAkE;IAClE,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,4DAA4D;IAC5D,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,uDAAuD;IACvD,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB,mEAAmE;IACnE,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,oGAAoG;IACpG,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,cAAc,EAAE,QAAQ,EAAE,OAAO,KAAK,KAAK,CAAC,SAAS,CAAA;IAC7E,4FAA4F;IAC5F,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,iFAAiF;IACjF,IAAI,CAAC,EAAE,YAAY,CAAA;IACnB,8GAA8G;IAC9G,KAAK,CAAC,EAAE,UAAU,CAAA;CACnB;AAED,UAAU,mBAAoB,SAAQ,iBAAiB;IACrD,QAAQ,CAAC,EAAE,KAAK,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;CACvC;AAED,UAAU,qBAAsB,SAAQ,iBAAiB;IACvD,QAAQ,EAAE,IAAI,CAAA;IACd,KAAK,CAAC,EAAE,MAAM,EAAE,CAAA;IAChB,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,IAAI,CAAA;CACzC;AAED,MAAM,MAAM,aAAa,GAAG,mBAAmB,GAAG,qBAAqB,CAAA;AAQvE,QAAA,MAAM,QAAQ,sFAyab,CAAA;AAGD,OAAO,EAAE,QAAQ,EAAE,CAAA"}
|
package/dist/ui/combobox.js
CHANGED
|
@@ -1,28 +1,28 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import * as
|
|
12
|
-
import { Fragment as
|
|
13
|
-
import { IconCheck as
|
|
14
|
-
import { motion as
|
|
2
|
+
import { IconProvider as e } from "./icon-context.js";
|
|
3
|
+
import { springs as t, tweens as n } from "./lib/motion.js";
|
|
4
|
+
import { cva as r } from "../_chunks/vendor-utils.js";
|
|
5
|
+
import { cn as i } from "./lib/utils.js";
|
|
6
|
+
import { Icon as a } from "./icon.js";
|
|
7
|
+
import { useFormField as o } from "./form.js";
|
|
8
|
+
import { resolveFieldState as s } from "../_chunks/field-state.js";
|
|
9
|
+
import { normalizeIcon as c } from "../_chunks/normalize-icon.js";
|
|
10
|
+
import { Content2 as l, Portal as u, Root2 as ee, Trigger as te } from "../_chunks/primitives/react-popover.js";
|
|
11
|
+
import * as d from "react";
|
|
12
|
+
import { Fragment as f, jsx as p, jsxs as m } from "react/jsx-runtime";
|
|
13
|
+
import { IconCheck as h, IconChevronDown as ne, IconSearch as re, IconX as ie } from "@tabler/icons-react";
|
|
14
|
+
import { motion as ae } from "framer-motion";
|
|
15
15
|
//#region src/ui/combobox.tsx
|
|
16
|
-
var
|
|
16
|
+
var oe = {
|
|
17
17
|
error: "border-error-7",
|
|
18
18
|
warning: "border-warning-7",
|
|
19
19
|
success: "border-success-7"
|
|
20
|
-
},
|
|
20
|
+
}, g = r([
|
|
21
21
|
"flex w-full items-center justify-between whitespace-nowrap rounded-control",
|
|
22
22
|
"border border-surface-border-strong bg-surface-raised-hover",
|
|
23
23
|
"transition-colors duration-fast-01 ease-productive-standard",
|
|
24
24
|
"focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-accent-9 focus-visible:ring-offset-2 focus-visible:border-accent-7",
|
|
25
|
-
"disabled:cursor-not-allowed disabled:opacity-action-disabled"
|
|
25
|
+
"data-[disabled]:cursor-not-allowed data-[disabled]:opacity-action-disabled"
|
|
26
26
|
], {
|
|
27
27
|
variants: { size: {
|
|
28
28
|
xs: "h-ds-xs-plus text-body-sm px-ds-02",
|
|
@@ -31,122 +31,122 @@ var se = {
|
|
|
31
31
|
lg: "h-ds-lg text-body-md px-ds-05"
|
|
32
32
|
} },
|
|
33
33
|
defaultVariants: { size: "md" }
|
|
34
|
-
}),
|
|
34
|
+
}), _ = {
|
|
35
35
|
xs: "xs",
|
|
36
36
|
sm: "sm",
|
|
37
37
|
md: "sm",
|
|
38
38
|
lg: "md"
|
|
39
|
-
},
|
|
39
|
+
}, v = {
|
|
40
40
|
xs: "px-ds-02 py-0 text-body-xs",
|
|
41
41
|
sm: "px-ds-02 py-0 text-body-xs",
|
|
42
42
|
md: "px-ds-03 py-[1px] text-body-sm",
|
|
43
43
|
lg: "px-ds-03 py-[2px] text-body-sm"
|
|
44
|
-
},
|
|
44
|
+
}, y = {
|
|
45
45
|
xs: "text-body-xs",
|
|
46
46
|
sm: "text-body-xs",
|
|
47
47
|
md: "text-body-sm",
|
|
48
48
|
lg: "text-body-sm"
|
|
49
|
-
},
|
|
50
|
-
let
|
|
51
|
-
|
|
49
|
+
}, b = 2, x = 36, S = d.forwardRef(({ options: r, value: S, onValueChange: C, placeholder: w = "Select...", searchPlaceholder: se = "Search...", emptyMessage: ce = "No results found", multiple: T = !1, disabled: E = !1, className: le, triggerClassName: ue, maxVisible: de = 6, renderOption: D, accessibleLabel: O, id: k, size: A = "md", state: j, ...M }, N) => {
|
|
50
|
+
let P = A ?? "md", [F, I] = d.useState(!1), [L, R] = d.useState(""), [z, B] = d.useState(-1), V = d.useRef(null), H = d.useRef(null), U = d.useId(), W = d.useId(), G = d.useMemo(() => S == null ? [] : Array.isArray(S) ? S : [S], [S]), K = d.useMemo(() => L ? r.filter((e) => e.label.toLowerCase().includes(L.toLowerCase())) : r, [r, L]), fe = d.useCallback((e) => G.includes(e), [G]), q = d.useCallback((e) => {
|
|
51
|
+
T ? C(G.includes(e) ? G.filter((t) => t !== e) : [...G, e]) : (C(e), I(!1));
|
|
52
52
|
}, [
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
]),
|
|
57
|
-
e.stopPropagation(), e.preventDefault(),
|
|
58
|
-
}, [
|
|
59
|
-
|
|
60
|
-
}, [
|
|
61
|
-
|
|
62
|
-
if (
|
|
53
|
+
T,
|
|
54
|
+
G,
|
|
55
|
+
C
|
|
56
|
+
]), pe = d.useCallback((e, t) => {
|
|
57
|
+
e.stopPropagation(), e.preventDefault(), C(G.filter((e) => e !== t));
|
|
58
|
+
}, [G, C]), J = d.useCallback((e) => {
|
|
59
|
+
E || (I(e), e || (R(""), B(-1)));
|
|
60
|
+
}, [E]);
|
|
61
|
+
d.useEffect(() => {
|
|
62
|
+
if (F) {
|
|
63
63
|
let e = setTimeout(() => {
|
|
64
|
-
|
|
64
|
+
V.current?.focus();
|
|
65
65
|
}, 0);
|
|
66
66
|
return () => clearTimeout(e);
|
|
67
67
|
}
|
|
68
|
-
}, [
|
|
69
|
-
let
|
|
70
|
-
let n =
|
|
68
|
+
}, [F]);
|
|
69
|
+
let Y = d.useCallback((e, t) => {
|
|
70
|
+
let n = K.length;
|
|
71
71
|
if (n === 0) return -1;
|
|
72
72
|
let r = e + t;
|
|
73
73
|
for (; r >= 0 && r < n;) {
|
|
74
|
-
if (!
|
|
74
|
+
if (!K[r].disabled) return r;
|
|
75
75
|
r += t;
|
|
76
76
|
}
|
|
77
77
|
return e;
|
|
78
|
-
}, [
|
|
78
|
+
}, [K]), me = d.useCallback((e) => {
|
|
79
79
|
switch (e.key) {
|
|
80
80
|
case "ArrowDown": {
|
|
81
81
|
e.preventDefault();
|
|
82
|
-
let t =
|
|
83
|
-
|
|
82
|
+
let t = Y(z, 1);
|
|
83
|
+
B(t);
|
|
84
84
|
break;
|
|
85
85
|
}
|
|
86
86
|
case "ArrowUp": {
|
|
87
87
|
e.preventDefault();
|
|
88
|
-
let t =
|
|
89
|
-
|
|
88
|
+
let t = Y(z, -1);
|
|
89
|
+
B(t);
|
|
90
90
|
break;
|
|
91
91
|
}
|
|
92
92
|
case "Home": {
|
|
93
93
|
e.preventDefault();
|
|
94
|
-
let t =
|
|
95
|
-
|
|
94
|
+
let t = K.findIndex((e) => !e.disabled);
|
|
95
|
+
B(t);
|
|
96
96
|
break;
|
|
97
97
|
}
|
|
98
98
|
case "End": {
|
|
99
99
|
e.preventDefault();
|
|
100
100
|
let t = -1;
|
|
101
|
-
for (let e =
|
|
101
|
+
for (let e = K.length - 1; e >= 0; e--) if (!K[e].disabled) {
|
|
102
102
|
t = e;
|
|
103
103
|
break;
|
|
104
104
|
}
|
|
105
|
-
|
|
105
|
+
B(t);
|
|
106
106
|
break;
|
|
107
107
|
}
|
|
108
108
|
case "Enter":
|
|
109
|
-
e.preventDefault(),
|
|
109
|
+
e.preventDefault(), z >= 0 && z < K.length && !K[z].disabled && q(K[z].value);
|
|
110
110
|
break;
|
|
111
111
|
case "Escape":
|
|
112
|
-
e.preventDefault(),
|
|
112
|
+
e.preventDefault(), I(!1), R(""), B(-1);
|
|
113
113
|
break;
|
|
114
114
|
}
|
|
115
115
|
}, [
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
116
|
+
z,
|
|
117
|
+
K,
|
|
118
|
+
Y,
|
|
119
|
+
q
|
|
120
120
|
]);
|
|
121
|
-
|
|
122
|
-
if (
|
|
123
|
-
let e =
|
|
121
|
+
d.useEffect(() => {
|
|
122
|
+
if (z >= 0 && H.current) {
|
|
123
|
+
let e = H.current.children[z];
|
|
124
124
|
e && e.scrollIntoView?.({ block: "nearest" });
|
|
125
125
|
}
|
|
126
|
-
}, [
|
|
127
|
-
let
|
|
128
|
-
if (
|
|
129
|
-
let e =
|
|
130
|
-
return /* @__PURE__ */
|
|
126
|
+
}, [z]);
|
|
127
|
+
let X = d.useCallback(() => G.length === 0 ? null : r.find((e) => e.value === G[0])?.label ?? null, [G, r]), Z = _[P], he = v[P], ge = y[P], _e = () => {
|
|
128
|
+
if (T && G.length > 0) {
|
|
129
|
+
let e = G.slice(0, b), t = G.length - b;
|
|
130
|
+
return /* @__PURE__ */ m("span", {
|
|
131
131
|
className: "flex flex-1 flex-wrap items-center gap-ds-02 overflow-hidden",
|
|
132
132
|
children: [e.map((e) => {
|
|
133
|
-
let t =
|
|
134
|
-
return t ? /* @__PURE__ */
|
|
135
|
-
className:
|
|
136
|
-
children: [t.label, /* @__PURE__ */
|
|
133
|
+
let t = r.find((t) => t.value === e);
|
|
134
|
+
return t ? /* @__PURE__ */ m("span", {
|
|
135
|
+
className: i("inline-flex items-center gap-ds-01 rounded-control-inner bg-accent-2", he),
|
|
136
|
+
children: [t.label, /* @__PURE__ */ p("button", {
|
|
137
137
|
type: "button",
|
|
138
138
|
className: "inline-flex items-center justify-center rounded-pill outline-hidden hover:bg-surface-raised-hover transition-colors duration-fast-01 ease-productive-standard",
|
|
139
|
-
onClick: (t) =>
|
|
139
|
+
onClick: (t) => pe(t, e),
|
|
140
140
|
"aria-label": `Remove ${t.label}`,
|
|
141
141
|
tabIndex: -1,
|
|
142
|
-
children: /* @__PURE__ */
|
|
143
|
-
icon:
|
|
142
|
+
children: /* @__PURE__ */ p(a, {
|
|
143
|
+
icon: ie,
|
|
144
144
|
size: Z
|
|
145
145
|
})
|
|
146
146
|
})]
|
|
147
147
|
}, e) : null;
|
|
148
|
-
}), t > 0 && /* @__PURE__ */
|
|
149
|
-
className:
|
|
148
|
+
}), t > 0 && /* @__PURE__ */ m("span", {
|
|
149
|
+
className: i("text-surface-fg-muted", ge),
|
|
150
150
|
children: [
|
|
151
151
|
"+",
|
|
152
152
|
t,
|
|
@@ -155,55 +155,60 @@ var se = {
|
|
|
155
155
|
})]
|
|
156
156
|
});
|
|
157
157
|
}
|
|
158
|
-
if (!
|
|
159
|
-
let e =
|
|
160
|
-
if (e) return /* @__PURE__ */
|
|
158
|
+
if (!T && G.length === 1) {
|
|
159
|
+
let e = X();
|
|
160
|
+
if (e) return /* @__PURE__ */ p("span", {
|
|
161
161
|
className: "min-w-0 flex-1 truncate text-left",
|
|
162
162
|
children: e
|
|
163
163
|
});
|
|
164
164
|
}
|
|
165
|
-
return /* @__PURE__ */
|
|
165
|
+
return /* @__PURE__ */ p("span", {
|
|
166
166
|
className: "min-w-0 flex-1 truncate text-left text-surface-fg-subtle",
|
|
167
|
-
children:
|
|
167
|
+
children: w
|
|
168
168
|
});
|
|
169
|
-
}, Q =
|
|
170
|
-
return /* @__PURE__ */
|
|
171
|
-
open:
|
|
172
|
-
onOpenChange:
|
|
173
|
-
children: /* @__PURE__ */
|
|
174
|
-
className:
|
|
175
|
-
...
|
|
176
|
-
children: [/* @__PURE__ */
|
|
169
|
+
}, Q = o(), $ = s(j, Q.state), ve = $ === "error", ye = Q.helperTextId, be = Q.required;
|
|
170
|
+
return /* @__PURE__ */ p(ee, {
|
|
171
|
+
open: F,
|
|
172
|
+
onOpenChange: J,
|
|
173
|
+
children: /* @__PURE__ */ m("div", {
|
|
174
|
+
className: i("relative", le),
|
|
175
|
+
...M,
|
|
176
|
+
children: [/* @__PURE__ */ p(te, {
|
|
177
177
|
asChild: !0,
|
|
178
|
-
disabled:
|
|
179
|
-
children: /* @__PURE__ */
|
|
180
|
-
ref:
|
|
181
|
-
type: "button",
|
|
178
|
+
disabled: E,
|
|
179
|
+
children: /* @__PURE__ */ m("div", {
|
|
180
|
+
ref: N,
|
|
182
181
|
role: "combobox",
|
|
183
|
-
|
|
184
|
-
"
|
|
185
|
-
|
|
182
|
+
tabIndex: E ? -1 : 0,
|
|
183
|
+
"data-disabled": E || void 0,
|
|
184
|
+
id: k,
|
|
185
|
+
"aria-expanded": F,
|
|
186
|
+
"aria-controls": W,
|
|
186
187
|
"aria-haspopup": "listbox",
|
|
187
|
-
"aria-
|
|
188
|
+
"aria-disabled": E || void 0,
|
|
189
|
+
"aria-labelledby": O ? void 0 : Q.labelId,
|
|
190
|
+
"aria-label": O ?? (Q.labelId ? void 0 : w),
|
|
188
191
|
"aria-invalid": ve || void 0,
|
|
189
192
|
"aria-describedby": ye,
|
|
190
193
|
"aria-required": be || void 0,
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
194
|
+
onKeyDown: (e) => {
|
|
195
|
+
E || (e.key === "Enter" || e.key === " " || e.key === "ArrowDown") && (e.preventDefault(), J(!0));
|
|
196
|
+
},
|
|
197
|
+
className: i(g({ size: P }), "cursor-pointer", F && "border-accent-7", $ && oe[$], ue),
|
|
198
|
+
children: [_e(), /* @__PURE__ */ p(a, {
|
|
199
|
+
icon: ne,
|
|
195
200
|
size: Z,
|
|
196
|
-
className:
|
|
201
|
+
className: i("ml-ds-02 shrink-0 opacity-50 transition-transform duration-fast-01 ease-productive-standard", F && "rotate-180")
|
|
197
202
|
})]
|
|
198
203
|
})
|
|
199
|
-
}), /* @__PURE__ */
|
|
204
|
+
}), /* @__PURE__ */ p(u, { children: /* @__PURE__ */ p(l, {
|
|
200
205
|
asChild: !0,
|
|
201
206
|
sideOffset: 4,
|
|
202
207
|
align: "start",
|
|
203
208
|
onOpenAutoFocus: (e) => {
|
|
204
|
-
e.preventDefault(),
|
|
209
|
+
e.preventDefault(), V.current?.focus();
|
|
205
210
|
},
|
|
206
|
-
children: /* @__PURE__ */
|
|
211
|
+
children: /* @__PURE__ */ m(ae.div, {
|
|
207
212
|
initial: {
|
|
208
213
|
opacity: 0,
|
|
209
214
|
scale: .95
|
|
@@ -213,80 +218,80 @@ var se = {
|
|
|
213
218
|
scale: 1
|
|
214
219
|
},
|
|
215
220
|
transition: {
|
|
216
|
-
...
|
|
217
|
-
opacity:
|
|
221
|
+
...t.snappy,
|
|
222
|
+
opacity: n.fade
|
|
218
223
|
},
|
|
219
|
-
className:
|
|
220
|
-
children: [/* @__PURE__ */
|
|
224
|
+
className: i("z-popover w-[var(--radix-popover-trigger-width)] overflow-hidden rounded-overlay bg-surface-overlay shadow-floating"),
|
|
225
|
+
children: [/* @__PURE__ */ m("div", {
|
|
221
226
|
className: "flex items-center gap-ds-02 border-b border-surface-border px-ds-04",
|
|
222
|
-
children: [/* @__PURE__ */
|
|
223
|
-
icon:
|
|
227
|
+
children: [/* @__PURE__ */ p(a, {
|
|
228
|
+
icon: re,
|
|
224
229
|
size: "sm",
|
|
225
230
|
className: "shrink-0 text-surface-fg-subtle"
|
|
226
|
-
}), /* @__PURE__ */
|
|
227
|
-
ref:
|
|
231
|
+
}), /* @__PURE__ */ p("input", {
|
|
232
|
+
ref: V,
|
|
228
233
|
type: "text",
|
|
229
234
|
className: "flex-1 bg-transparent py-ds-03 text-body-md outline-hidden placeholder:text-surface-fg-subtle",
|
|
230
|
-
placeholder:
|
|
231
|
-
value:
|
|
235
|
+
placeholder: se,
|
|
236
|
+
value: L,
|
|
232
237
|
onChange: (e) => {
|
|
233
|
-
|
|
238
|
+
R(e.target.value), B(-1);
|
|
234
239
|
},
|
|
235
|
-
onKeyDown:
|
|
240
|
+
onKeyDown: me,
|
|
236
241
|
"aria-autocomplete": "list",
|
|
237
|
-
"aria-controls":
|
|
238
|
-
"aria-activedescendant":
|
|
242
|
+
"aria-controls": W,
|
|
243
|
+
"aria-activedescendant": z >= 0 ? `${U}-option-${z}` : void 0,
|
|
239
244
|
"aria-label": "Search options"
|
|
240
245
|
})]
|
|
241
|
-
}),
|
|
246
|
+
}), K.length === 0 ? /* @__PURE__ */ p("div", {
|
|
242
247
|
className: "px-ds-04 py-ds-05 text-center text-body-md text-surface-fg-subtle",
|
|
243
|
-
children:
|
|
244
|
-
}) : /* @__PURE__ */
|
|
245
|
-
ref:
|
|
246
|
-
id:
|
|
248
|
+
children: ce
|
|
249
|
+
}) : /* @__PURE__ */ p("ul", {
|
|
250
|
+
ref: H,
|
|
251
|
+
id: W,
|
|
247
252
|
role: "listbox",
|
|
248
|
-
"aria-multiselectable":
|
|
253
|
+
"aria-multiselectable": T || void 0,
|
|
249
254
|
className: "overflow-auto p-ds-02",
|
|
250
|
-
style: { maxHeight: `${
|
|
251
|
-
children:
|
|
252
|
-
let
|
|
253
|
-
return /* @__PURE__ */
|
|
254
|
-
id: `${
|
|
255
|
+
style: { maxHeight: `${de * x}px` },
|
|
256
|
+
children: K.map((t, n) => {
|
|
257
|
+
let r = fe(t.value);
|
|
258
|
+
return /* @__PURE__ */ m("li", {
|
|
259
|
+
id: `${U}-option-${n}`,
|
|
255
260
|
role: "option",
|
|
256
|
-
"aria-selected":
|
|
257
|
-
"aria-disabled":
|
|
258
|
-
className:
|
|
261
|
+
"aria-selected": r,
|
|
262
|
+
"aria-disabled": t.disabled || void 0,
|
|
263
|
+
className: i("relative flex cursor-pointer select-none items-center gap-ds-03 rounded-control px-ds-04 py-ds-03 text-body-md outline-hidden", "transition-colors duration-fast-01 ease-productive-standard", z === n && "bg-accent-2", r && "text-accent-11", t.disabled && "pointer-events-none opacity-action-disabled"),
|
|
259
264
|
onClick: () => {
|
|
260
|
-
|
|
265
|
+
t.disabled || q(t.value);
|
|
261
266
|
},
|
|
262
|
-
onKeyDown: (
|
|
263
|
-
!
|
|
267
|
+
onKeyDown: (e) => {
|
|
268
|
+
!t.disabled && (e.key === "Enter" || e.key === " ") && (e.preventDefault(), q(t.value));
|
|
264
269
|
},
|
|
265
270
|
onMouseEnter: () => {
|
|
266
|
-
|
|
271
|
+
t.disabled || B(n);
|
|
267
272
|
},
|
|
268
273
|
children: [
|
|
269
|
-
|
|
274
|
+
t.icon && /* @__PURE__ */ p("span", {
|
|
270
275
|
className: "flex h-ico-sm w-ico-sm items-center justify-center shrink-0",
|
|
271
|
-
children: /* @__PURE__ */
|
|
276
|
+
children: /* @__PURE__ */ p(e, {
|
|
272
277
|
size: Z,
|
|
273
|
-
children:
|
|
278
|
+
children: c(t.icon)
|
|
274
279
|
})
|
|
275
280
|
}),
|
|
276
|
-
/* @__PURE__ */
|
|
281
|
+
/* @__PURE__ */ p("span", {
|
|
277
282
|
className: "flex flex-1 flex-col",
|
|
278
|
-
children:
|
|
283
|
+
children: D ? D(t, r) : /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p("span", { children: t.label }), t.description && /* @__PURE__ */ p("span", {
|
|
279
284
|
className: "text-body-sm text-surface-fg-muted",
|
|
280
|
-
children:
|
|
285
|
+
children: t.description
|
|
281
286
|
})] })
|
|
282
287
|
}),
|
|
283
|
-
|
|
284
|
-
icon:
|
|
288
|
+
r && /* @__PURE__ */ p(a, {
|
|
289
|
+
icon: h,
|
|
285
290
|
size: "sm",
|
|
286
291
|
className: "shrink-0"
|
|
287
292
|
})
|
|
288
293
|
]
|
|
289
|
-
},
|
|
294
|
+
}, t.value);
|
|
290
295
|
})
|
|
291
296
|
})]
|
|
292
297
|
})
|
|
@@ -294,6 +299,6 @@ var se = {
|
|
|
294
299
|
})
|
|
295
300
|
});
|
|
296
301
|
});
|
|
297
|
-
|
|
302
|
+
S.displayName = "Combobox";
|
|
298
303
|
//#endregion
|
|
299
|
-
export {
|
|
304
|
+
export { S as Combobox, g as comboboxTriggerVariants };
|