@dungle-scrubs/admin-ui-soft 0.0.0-stage → 0.0.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/GUIDE.md +110 -0
- package/LICENSE +21 -0
- package/README.md +36 -2
- package/THIRD-PARTY-NOTICES.md +25 -0
- package/UPSTREAM-VENDORED-CHANGES.md +317 -0
- package/VENDORED-CHANGES.md +60 -0
- package/dist/_virtual/_rolldown/runtime.js +13 -0
- package/dist/ai/compositions/agent-console/agent-console.d.ts +109 -0
- package/dist/ai/compositions/agent-console/agent-console.js +644 -0
- package/dist/ai/compositions/attention-feed/attention-feed.d.ts +127 -0
- package/dist/ai/compositions/attention-feed/attention-feed.js +626 -0
- package/dist/ai/compositions/conversation-browser/conversation-browser.d.ts +126 -0
- package/dist/ai/compositions/conversation-browser/conversation-browser.js +364 -0
- package/dist/ai/compositions/redaction-marker/redaction-marker.d.ts +42 -0
- package/dist/ai/compositions/redaction-marker/redaction-marker.js +202 -0
- package/dist/ai/compositions/run-inspector/json-view.js +164 -0
- package/dist/ai/compositions/run-inspector/run-inspector.d.ts +66 -0
- package/dist/ai/compositions/run-inspector/run-inspector.js +703 -0
- package/dist/ai/compositions/run-inspector/run-model.js +155 -0
- package/dist/ai/compositions/tool-approval/json-args.js +54 -0
- package/dist/ai/compositions/tool-approval/tool-approval.d.ts +57 -0
- package/dist/ai/compositions/tool-approval/tool-approval.js +331 -0
- package/dist/ai/compositions/tool-call-row/tool-call-row.js +74 -0
- package/dist/ai/compositions/transcript-viewer/to-thread-messages.js +65 -0
- package/dist/ai/compositions/transcript-viewer/transcript-viewer.d.ts +63 -0
- package/dist/ai/compositions/transcript-viewer/transcript-viewer.js +471 -0
- package/dist/ai/compositions/usage-meter/usage-format.js +107 -0
- package/dist/ai/compositions/usage-meter/usage-meter.d.ts +32 -0
- package/dist/ai/compositions/usage-meter/usage-meter.js +258 -0
- package/dist/ai/testing/mock-clock.d.ts +31 -0
- package/dist/ai/testing/mock-clock.js +66 -0
- package/dist/ai/testing/mock-reply.d.ts +70 -0
- package/dist/ai/testing/mock-reply.js +100 -0
- package/dist/ai/testing/mock-runtime.d.ts +86 -0
- package/dist/ai/testing/mock-runtime.js +384 -0
- package/dist/ai/types.d.ts +323 -0
- package/dist/ai.css +1088 -0
- package/dist/ai.d.ts +160 -0
- package/dist/ai.js +158 -0
- package/dist/components/assistant-ui/elements/activity-graph.d.ts +14 -0
- package/dist/components/assistant-ui/elements/activity-graph.js +69 -0
- package/dist/components/assistant-ui/elements/agent-card.d.ts +21 -0
- package/dist/components/assistant-ui/elements/agent-card.js +75 -0
- package/dist/components/assistant-ui/elements/agent-handoff.d.ts +13 -0
- package/dist/components/assistant-ui/elements/agent-handoff.js +47 -0
- package/dist/components/assistant-ui/elements/agent-plan.d.ts +16 -0
- package/dist/components/assistant-ui/elements/agent-plan.js +93 -0
- package/dist/components/assistant-ui/elements/agent-status.aui.d.ts +24 -0
- package/dist/components/assistant-ui/elements/agent-status.aui.js +161 -0
- package/dist/components/assistant-ui/elements/agent-status.d.ts +17 -0
- package/dist/components/assistant-ui/elements/agent-status.js +47 -0
- package/dist/components/assistant-ui/elements/approval-card.d.ts +31 -0
- package/dist/components/assistant-ui/elements/approval-card.js +99 -0
- package/dist/components/assistant-ui/elements/artifact-card.d.ts +12 -0
- package/dist/components/assistant-ui/elements/artifact-card.js +47 -0
- package/dist/components/assistant-ui/elements/assistant-modal.aui.d.ts +7 -0
- package/dist/components/assistant-ui/elements/assistant-modal.aui.js +276 -0
- package/dist/components/assistant-ui/elements/assistant-sidebar.aui.d.ts +7 -0
- package/dist/components/assistant-ui/elements/assistant-sidebar.aui.js +18 -0
- package/dist/components/assistant-ui/elements/attachment.aui.d.ts +9 -0
- package/dist/components/assistant-ui/elements/attachment.aui.js +143 -0
- package/dist/components/assistant-ui/elements/background-inbox.d.ts +18 -0
- package/dist/components/assistant-ui/elements/background-inbox.js +65 -0
- package/dist/components/assistant-ui/elements/canvas-split.d.ts +25 -0
- package/dist/components/assistant-ui/elements/canvas-split.js +106 -0
- package/dist/components/assistant-ui/elements/chart.d.ts +19 -0
- package/dist/components/assistant-ui/elements/chart.js +105 -0
- package/dist/components/assistant-ui/elements/chat-panel.d.ts +15 -0
- package/dist/components/assistant-ui/elements/chat-panel.js +82 -0
- package/dist/components/assistant-ui/elements/checkpoint-history.d.ts +17 -0
- package/dist/components/assistant-ui/elements/checkpoint-history.js +60 -0
- package/dist/components/assistant-ui/elements/code-diff.d.ts +18 -0
- package/dist/components/assistant-ui/elements/code-diff.js +89 -0
- package/dist/components/assistant-ui/elements/code-runner.d.ts +15 -0
- package/dist/components/assistant-ui/elements/code-runner.js +108 -0
- package/dist/components/assistant-ui/elements/command-palette.d.ts +20 -0
- package/dist/components/assistant-ui/elements/command-palette.js +129 -0
- package/dist/components/assistant-ui/elements/comparison-card.d.ts +18 -0
- package/dist/components/assistant-ui/elements/comparison-card.js +58 -0
- package/dist/components/assistant-ui/elements/composer-trigger-popover.aui.d.ts +51 -0
- package/dist/components/assistant-ui/elements/composer-trigger-popover.aui.js +104 -0
- package/dist/components/assistant-ui/elements/composer.d.ts +91 -0
- package/dist/components/assistant-ui/elements/composer.js +416 -0
- package/dist/components/assistant-ui/elements/computer-use.d.ts +19 -0
- package/dist/components/assistant-ui/elements/computer-use.js +84 -0
- package/dist/components/assistant-ui/elements/confidence-marker.d.ts +20 -0
- package/dist/components/assistant-ui/elements/confidence-marker.js +58 -0
- package/dist/components/assistant-ui/elements/connection-state.d.ts +13 -0
- package/dist/components/assistant-ui/elements/connection-state.js +59 -0
- package/dist/components/assistant-ui/elements/context-breakdown.d.ts +15 -0
- package/dist/components/assistant-ui/elements/context-breakdown.js +91 -0
- package/dist/components/assistant-ui/elements/context-display.aui.d.ts +25 -0
- package/dist/components/assistant-ui/elements/context-display.aui.js +26 -0
- package/dist/components/assistant-ui/elements/context-display.d.ts +43 -0
- package/dist/components/assistant-ui/elements/context-display.js +300 -0
- package/dist/components/assistant-ui/elements/conversation-map.aui.d.ts +9 -0
- package/dist/components/assistant-ui/elements/conversation-map.aui.js +177 -0
- package/dist/components/assistant-ui/elements/conversation-map.d.ts +19 -0
- package/dist/components/assistant-ui/elements/conversation-map.js +84 -0
- package/dist/components/assistant-ui/elements/conversation-search.d.ts +20 -0
- package/dist/components/assistant-ui/elements/conversation-search.js +75 -0
- package/dist/components/assistant-ui/elements/cost-meter.d.ts +19 -0
- package/dist/components/assistant-ui/elements/cost-meter.js +76 -0
- package/dist/components/assistant-ui/elements/data-table.d.ts +72 -0
- package/dist/components/assistant-ui/elements/data-table.js +368 -0
- package/dist/components/assistant-ui/elements/day-separator.d.ts +16 -0
- package/dist/components/assistant-ui/elements/day-separator.js +44 -0
- package/dist/components/assistant-ui/elements/diagram.d.ts +15 -0
- package/dist/components/assistant-ui/elements/diagram.js +65 -0
- package/dist/components/assistant-ui/elements/directive-text.aui.d.ts +11 -0
- package/dist/components/assistant-ui/elements/directive-text.aui.js +18 -0
- package/dist/components/assistant-ui/elements/directive-text.d.ts +32 -0
- package/dist/components/assistant-ui/elements/directive-text.js +35 -0
- package/dist/components/assistant-ui/elements/document-reference.d.ts +17 -0
- package/dist/components/assistant-ui/elements/document-reference.js +62 -0
- package/dist/components/assistant-ui/elements/draft-restore.d.ts +12 -0
- package/dist/components/assistant-ui/elements/draft-restore.js +43 -0
- package/dist/components/assistant-ui/elements/edit-message.d.ts +15 -0
- package/dist/components/assistant-ui/elements/edit-message.js +63 -0
- package/dist/components/assistant-ui/elements/elicitation-form.d.ts +23 -0
- package/dist/components/assistant-ui/elements/elicitation-form.js +112 -0
- package/dist/components/assistant-ui/elements/empty-state.d.ts +16 -0
- package/dist/components/assistant-ui/elements/empty-state.js +71 -0
- package/dist/components/assistant-ui/elements/error-state.d.ts +13 -0
- package/dist/components/assistant-ui/elements/error-state.js +52 -0
- package/dist/components/assistant-ui/elements/feedback-dialog.d.ts +15 -0
- package/dist/components/assistant-ui/elements/feedback-dialog.js +77 -0
- package/dist/components/assistant-ui/elements/file-tree.d.ts +20 -0
- package/dist/components/assistant-ui/elements/file-tree.js +74 -0
- package/dist/components/assistant-ui/elements/file.d.ts +52 -0
- package/dist/components/assistant-ui/elements/file.js +222 -0
- package/dist/components/assistant-ui/elements/flow-graph.d.ts +23 -0
- package/dist/components/assistant-ui/elements/flow-graph.js +72 -0
- package/dist/components/assistant-ui/elements/follow-up-suggestions.aui.d.ts +7 -0
- package/dist/components/assistant-ui/elements/follow-up-suggestions.aui.js +30 -0
- package/dist/components/assistant-ui/elements/generative-ui.d.ts +8 -0
- package/dist/components/assistant-ui/elements/generative-ui.js +27 -0
- package/dist/components/assistant-ui/elements/geo-map.d.ts +29 -0
- package/dist/components/assistant-ui/elements/geo-map.js +190 -0
- package/dist/components/assistant-ui/elements/guardrail-notice.d.ts +15 -0
- package/dist/components/assistant-ui/elements/guardrail-notice.js +59 -0
- package/dist/components/assistant-ui/elements/heat-graph.d.ts +9 -0
- package/dist/components/assistant-ui/elements/heat-graph.js +90 -0
- package/dist/components/assistant-ui/elements/image-gallery.d.ts +22 -0
- package/dist/components/assistant-ui/elements/image-gallery.js +192 -0
- package/dist/components/assistant-ui/elements/image-generation.d.ts +11 -0
- package/dist/components/assistant-ui/elements/image-generation.js +64 -0
- package/dist/components/assistant-ui/elements/image.d.ts +59 -0
- package/dist/components/assistant-ui/elements/image.js +416 -0
- package/dist/components/assistant-ui/elements/inline-citation.d.ts +23 -0
- package/dist/components/assistant-ui/elements/inline-citation.js +90 -0
- package/dist/components/assistant-ui/elements/job-progress.d.ts +25 -0
- package/dist/components/assistant-ui/elements/job-progress.js +102 -0
- package/dist/components/assistant-ui/elements/launcher-bubble.d.ts +15 -0
- package/dist/components/assistant-ui/elements/launcher-bubble.js +71 -0
- package/dist/components/assistant-ui/elements/link-preview.d.ts +17 -0
- package/dist/components/assistant-ui/elements/link-preview.js +77 -0
- package/dist/components/assistant-ui/elements/loading-state.d.ts +13 -0
- package/dist/components/assistant-ui/elements/loading-state.js +33 -0
- package/dist/components/assistant-ui/elements/logos.d.ts +10 -0
- package/dist/components/assistant-ui/elements/logos.js +63 -0
- package/dist/components/assistant-ui/elements/map-answer.d.ts +19 -0
- package/dist/components/assistant-ui/elements/map-answer.js +120 -0
- package/dist/components/assistant-ui/elements/markdown-text.d.ts +11 -0
- package/dist/components/assistant-ui/elements/markdown-text.js +152 -0
- package/dist/components/assistant-ui/elements/math-block.d.ts +25 -0
- package/dist/components/assistant-ui/elements/math-block.js +60 -0
- package/dist/components/assistant-ui/elements/mcp-config.aui.d.ts +28 -0
- package/dist/components/assistant-ui/elements/mcp-config.aui.js +380 -0
- package/dist/components/assistant-ui/elements/mcp-server-panel.d.ts +20 -0
- package/dist/components/assistant-ui/elements/mcp-server-panel.js +114 -0
- package/dist/components/assistant-ui/elements/media-player.d.ts +21 -0
- package/dist/components/assistant-ui/elements/media-player.js +302 -0
- package/dist/components/assistant-ui/elements/memory-chips.d.ts +16 -0
- package/dist/components/assistant-ui/elements/memory-chips.js +44 -0
- package/dist/components/assistant-ui/elements/mermaid-diagram.aui.d.ts +14 -0
- package/dist/components/assistant-ui/elements/mermaid-diagram.aui.js +43 -0
- package/dist/components/assistant-ui/elements/mermaid-diagram.d.ts +20 -0
- package/dist/components/assistant-ui/elements/mermaid-diagram.js +258 -0
- package/dist/components/assistant-ui/elements/message-actions.d.ts +17 -0
- package/dist/components/assistant-ui/elements/message-actions.js +57 -0
- package/dist/components/assistant-ui/elements/message-attachment.d.ts +18 -0
- package/dist/components/assistant-ui/elements/message-attachment.js +58 -0
- package/dist/components/assistant-ui/elements/message-branches.d.ts +12 -0
- package/dist/components/assistant-ui/elements/message-branches.js +55 -0
- package/dist/components/assistant-ui/elements/message-pair.d.ts +16 -0
- package/dist/components/assistant-ui/elements/message-pair.js +63 -0
- package/dist/components/assistant-ui/elements/message-queue.d.ts +15 -0
- package/dist/components/assistant-ui/elements/message-queue.js +70 -0
- package/dist/components/assistant-ui/elements/message-timing.aui.d.ts +30 -0
- package/dist/components/assistant-ui/elements/message-timing.aui.js +98 -0
- package/dist/components/assistant-ui/elements/message-timing.d.ts +14 -0
- package/dist/components/assistant-ui/elements/message-timing.js +26 -0
- package/dist/components/assistant-ui/elements/mobile-composer.d.ts +18 -0
- package/dist/components/assistant-ui/elements/mobile-composer.js +76 -0
- package/dist/components/assistant-ui/elements/model-picker.d.ts +19 -0
- package/dist/components/assistant-ui/elements/model-picker.js +68 -0
- package/dist/components/assistant-ui/elements/model-selector.aui.d.ts +23 -0
- package/dist/components/assistant-ui/elements/model-selector.aui.js +79 -0
- package/dist/components/assistant-ui/elements/model-selector.d.ts +130 -0
- package/dist/components/assistant-ui/elements/model-selector.js +399 -0
- package/dist/components/assistant-ui/elements/number-ticker.d.ts +10 -0
- package/dist/components/assistant-ui/elements/number-ticker.js +41 -0
- package/dist/components/assistant-ui/elements/onboarding.d.ts +17 -0
- package/dist/components/assistant-ui/elements/onboarding.js +69 -0
- package/dist/components/assistant-ui/elements/option-list.d.ts +39 -0
- package/dist/components/assistant-ui/elements/option-list.js +176 -0
- package/dist/components/assistant-ui/elements/permission-grant.d.ts +14 -0
- package/dist/components/assistant-ui/elements/permission-grant.js +84 -0
- package/dist/components/assistant-ui/elements/prompt-library.d.ts +20 -0
- package/dist/components/assistant-ui/elements/prompt-library.js +121 -0
- package/dist/components/assistant-ui/elements/question-flow.d.ts +24 -0
- package/dist/components/assistant-ui/elements/question-flow.js +180 -0
- package/dist/components/assistant-ui/elements/quota-banner.d.ts +14 -0
- package/dist/components/assistant-ui/elements/quota-banner.js +68 -0
- package/dist/components/assistant-ui/elements/quote-reply.d.ts +20 -0
- package/dist/components/assistant-ui/elements/quote-reply.js +66 -0
- package/dist/components/assistant-ui/elements/quote.aui.d.ts +61 -0
- package/dist/components/assistant-ui/elements/quote.aui.js +170 -0
- package/dist/components/assistant-ui/elements/read-aloud.d.ts +16 -0
- package/dist/components/assistant-ui/elements/read-aloud.js +66 -0
- package/dist/components/assistant-ui/elements/reasoning-effort.d.ts +17 -0
- package/dist/components/assistant-ui/elements/reasoning-effort.js +67 -0
- package/dist/components/assistant-ui/elements/reasoning-panel.d.ts +20 -0
- package/dist/components/assistant-ui/elements/reasoning-panel.js +60 -0
- package/dist/components/assistant-ui/elements/reasoning.aui.d.ts +24 -0
- package/dist/components/assistant-ui/elements/reasoning.aui.js +70 -0
- package/dist/components/assistant-ui/elements/reasoning.d.ts +38 -0
- package/dist/components/assistant-ui/elements/reasoning.js +194 -0
- package/dist/components/assistant-ui/elements/recommendation-card.d.ts +16 -0
- package/dist/components/assistant-ui/elements/recommendation-card.js +65 -0
- package/dist/components/assistant-ui/elements/regenerate-menu.d.ts +18 -0
- package/dist/components/assistant-ui/elements/regenerate-menu.js +46 -0
- package/dist/components/assistant-ui/elements/research-report.d.ts +19 -0
- package/dist/components/assistant-ui/elements/research-report.js +63 -0
- package/dist/components/assistant-ui/elements/retrieval-chunks.d.ts +19 -0
- package/dist/components/assistant-ui/elements/retrieval-chunks.js +86 -0
- package/dist/components/assistant-ui/elements/reviewable-diff.d.ts +21 -0
- package/dist/components/assistant-ui/elements/reviewable-diff.js +104 -0
- package/dist/components/assistant-ui/elements/schedule-card.d.ts +19 -0
- package/dist/components/assistant-ui/elements/schedule-card.js +80 -0
- package/dist/components/assistant-ui/elements/score-breakdown.d.ts +19 -0
- package/dist/components/assistant-ui/elements/score-breakdown.js +107 -0
- package/dist/components/assistant-ui/elements/scroll-anchor.d.ts +15 -0
- package/dist/components/assistant-ui/elements/scroll-anchor.js +104 -0
- package/dist/components/assistant-ui/elements/settings-panel.d.ts +23 -0
- package/dist/components/assistant-ui/elements/settings-panel.js +108 -0
- package/dist/components/assistant-ui/elements/shared-conversation.d.ts +18 -0
- package/dist/components/assistant-ui/elements/shared-conversation.js +56 -0
- package/dist/components/assistant-ui/elements/shiki-highlighter.aui.d.ts +29 -0
- package/dist/components/assistant-ui/elements/shiki-highlighter.aui.js +31 -0
- package/dist/components/assistant-ui/elements/shiki-highlighter.d.ts +26 -0
- package/dist/components/assistant-ui/elements/shiki-highlighter.js +49 -0
- package/dist/components/assistant-ui/elements/sources.aui.d.ts +24 -0
- package/dist/components/assistant-ui/elements/sources.aui.js +121 -0
- package/dist/components/assistant-ui/elements/sources.d.ts +21 -0
- package/dist/components/assistant-ui/elements/sources.js +109 -0
- package/dist/components/assistant-ui/elements/speaker-identity.d.ts +17 -0
- package/dist/components/assistant-ui/elements/speaker-identity.js +45 -0
- package/dist/components/assistant-ui/elements/spec-sheet.d.ts +17 -0
- package/dist/components/assistant-ui/elements/spec-sheet.js +39 -0
- package/dist/components/assistant-ui/elements/stopped-run.d.ts +12 -0
- package/dist/components/assistant-ui/elements/stopped-run.js +44 -0
- package/dist/components/assistant-ui/elements/streaming-text.d.ts +15 -0
- package/dist/components/assistant-ui/elements/streaming-text.js +45 -0
- package/dist/components/assistant-ui/elements/subagent-list.d.ts +17 -0
- package/dist/components/assistant-ui/elements/subagent-list.js +74 -0
- package/dist/components/assistant-ui/elements/suggestions.d.ts +14 -0
- package/dist/components/assistant-ui/elements/suggestions.js +25 -0
- package/dist/components/assistant-ui/elements/surfaces.d.ts +42 -0
- package/dist/components/assistant-ui/elements/surfaces.js +87 -0
- package/dist/components/assistant-ui/elements/syntax-highlighter.d.ts +7 -0
- package/dist/components/assistant-ui/elements/syntax-highlighter.js +41 -0
- package/dist/components/assistant-ui/elements/task-card.aui.d.ts +24 -0
- package/dist/components/assistant-ui/elements/task-card.aui.js +136 -0
- package/dist/components/assistant-ui/elements/task-card.d.ts +22 -0
- package/dist/components/assistant-ui/elements/task-card.js +104 -0
- package/dist/components/assistant-ui/elements/terminal-block.d.ts +27 -0
- package/dist/components/assistant-ui/elements/terminal-block.js +266 -0
- package/dist/components/assistant-ui/elements/thinking-indicator.d.ts +10 -0
- package/dist/components/assistant-ui/elements/thinking-indicator.js +30 -0
- package/dist/components/assistant-ui/elements/thread-list.aui.d.ts +39 -0
- package/dist/components/assistant-ui/elements/thread-list.aui.js +331 -0
- package/dist/components/assistant-ui/elements/thread-list.d.ts +19 -0
- package/dist/components/assistant-ui/elements/thread-list.js +72 -0
- package/dist/components/assistant-ui/elements/thread-search.d.ts +20 -0
- package/dist/components/assistant-ui/elements/thread-search.js +94 -0
- package/dist/components/assistant-ui/elements/thread.aui.d.ts +36 -0
- package/dist/components/assistant-ui/elements/thread.aui.js +625 -0
- package/dist/components/assistant-ui/elements/threadlist-sidebar.aui.d.ts +19 -0
- package/dist/components/assistant-ui/elements/threadlist-sidebar.aui.js +75 -0
- package/dist/components/assistant-ui/elements/timeline.d.ts +18 -0
- package/dist/components/assistant-ui/elements/timeline.js +40 -0
- package/dist/components/assistant-ui/elements/todo-list.d.ts +21 -0
- package/dist/components/assistant-ui/elements/todo-list.js +100 -0
- package/dist/components/assistant-ui/elements/tool-call.d.ts +17 -0
- package/dist/components/assistant-ui/elements/tool-call.js +70 -0
- package/dist/components/assistant-ui/elements/tool-error.d.ts +16 -0
- package/dist/components/assistant-ui/elements/tool-error.js +62 -0
- package/dist/components/assistant-ui/elements/tool-fallback.aui.d.ts +44 -0
- package/dist/components/assistant-ui/elements/tool-fallback.aui.js +542 -0
- package/dist/components/assistant-ui/elements/tool-group.aui.d.ts +37 -0
- package/dist/components/assistant-ui/elements/tool-group.aui.js +104 -0
- package/dist/components/assistant-ui/elements/tool-group.d.ts +20 -0
- package/dist/components/assistant-ui/elements/tool-group.js +71 -0
- package/dist/components/assistant-ui/elements/tool-timeline.d.ts +44 -0
- package/dist/components/assistant-ui/elements/tool-timeline.js +109 -0
- package/dist/components/assistant-ui/elements/tooltip-icon-button.d.ts +12 -0
- package/dist/components/assistant-ui/elements/tooltip-icon-button.js +30 -0
- package/dist/components/assistant-ui/elements/trace-waterfall.d.ts +33 -0
- package/dist/components/assistant-ui/elements/trace-waterfall.js +102 -0
- package/dist/components/assistant-ui/elements/typing-indicator.d.ts +9 -0
- package/dist/components/assistant-ui/elements/typing-indicator.js +45 -0
- package/dist/components/assistant-ui/elements/voice-conversation.aui.d.ts +11 -0
- package/dist/components/assistant-ui/elements/voice-conversation.aui.js +54 -0
- package/dist/components/assistant-ui/elements/voice-conversation.d.ts +21 -0
- package/dist/components/assistant-ui/elements/voice-conversation.js +110 -0
- package/dist/components/assistant-ui/elements/voice.aui.d.ts +22 -0
- package/dist/components/assistant-ui/elements/voice.aui.js +100 -0
- package/dist/components/assistant-ui/elements/voice.d.ts +15 -0
- package/dist/components/assistant-ui/elements/voice.js +400 -0
- package/dist/components/assistant-ui/elements/web-preview.d.ts +18 -0
- package/dist/components/assistant-ui/elements/web-preview.js +61 -0
- package/dist/components/assistant-ui/elements/web-search.d.ts +17 -0
- package/dist/components/assistant-ui/elements/web-search.js +54 -0
- package/dist/components/assistant-ui/utils/href.d.ts +13 -0
- package/dist/components/assistant-ui/utils/href.js +39 -0
- package/dist/components/assistant-ui/utils/range.d.ts +22 -0
- package/dist/components/assistant-ui/utils/range.js +48 -0
- package/dist/components/assistant-ui/utils/task.d.ts +14 -0
- package/dist/components/assistant-ui/utils/task.js +75 -0
- package/dist/components/icons/github.js +13 -0
- package/dist/components/theme-provider.d.ts +16 -0
- package/dist/components/theme-provider.js +116 -0
- package/dist/components/ui/accordion.d.ts +8 -0
- package/dist/components/ui/accordion.js +53 -0
- package/dist/components/ui/alert-dialog.d.ts +20 -0
- package/dist/components/ui/alert-dialog.js +93 -0
- package/dist/components/ui/alert.d.ts +12 -0
- package/dist/components/ui/alert.js +42 -0
- package/dist/components/ui/aspect-ratio.d.ts +6 -0
- package/dist/components/ui/aspect-ratio.js +13 -0
- package/dist/components/ui/attachment.d.ts +25 -0
- package/dist/components/ui/attachment.js +103 -0
- package/dist/components/ui/avatar.d.ts +13 -0
- package/dist/components/ui/avatar.js +50 -0
- package/dist/components/ui/badge.d.ts +14 -0
- package/dist/components/ui/badge.js +30 -0
- package/dist/components/ui/breadcrumb.d.ts +12 -0
- package/dist/components/ui/breadcrumb.js +71 -0
- package/dist/components/ui/bubble.d.ts +18 -0
- package/dist/components/ui/bubble.js +72 -0
- package/dist/components/ui/button-group.d.ts +12 -0
- package/dist/components/ui/button-group.js +41 -0
- package/dist/components/ui/button.d.ts +19 -0
- package/dist/components/ui/button.js +71 -0
- package/dist/components/ui/calendar.d.ts +12 -0
- package/dist/components/ui/calendar.js +108 -0
- package/dist/components/ui/card.d.ts +13 -0
- package/dist/components/ui/card.js +55 -0
- package/dist/components/ui/carousel.d.ts +30 -0
- package/dist/components/ui/carousel.js +131 -0
- package/dist/components/ui/chart.d.ts +46 -0
- package/dist/components/ui/chart.js +148 -0
- package/dist/components/ui/checkbox.d.ts +5 -0
- package/dist/components/ui/checkbox.js +20 -0
- package/dist/components/ui/collapsible.d.ts +7 -0
- package/dist/components/ui/collapsible.js +23 -0
- package/dist/components/ui/combobox.d.ts +26 -0
- package/dist/components/ui/combobox.js +161 -0
- package/dist/components/ui/command.d.ts +21 -0
- package/dist/components/ui/command.js +87 -0
- package/dist/components/ui/context-menu.d.ts +31 -0
- package/dist/components/ui/context-menu.js +132 -0
- package/dist/components/ui/dialog.d.ts +19 -0
- package/dist/components/ui/dialog.js +91 -0
- package/dist/components/ui/diff-viewer.d.ts +100 -0
- package/dist/components/ui/diff-viewer.js +461 -0
- package/dist/components/ui/direction.d.ts +2 -0
- package/dist/components/ui/direction.js +2 -0
- package/dist/components/ui/dot-matrix.d.ts +150 -0
- package/dist/components/ui/dot-matrix.js +248 -0
- package/dist/components/ui/drawer.d.ts +18 -0
- package/dist/components/ui/drawer.js +123 -0
- package/dist/components/ui/dropdown-menu.d.ts +31 -0
- package/dist/components/ui/dropdown-menu.js +136 -0
- package/dist/components/ui/empty.d.ts +13 -0
- package/dist/components/ui/empty.js +59 -0
- package/dist/components/ui/field.d.ts +26 -0
- package/dist/components/ui/field.js +109 -0
- package/dist/components/ui/hover-card.d.ts +7 -0
- package/dist/components/ui/hover-card.js +36 -0
- package/dist/components/ui/input-group.d.ts +20 -0
- package/dist/components/ui/input-group.js +77 -0
- package/dist/components/ui/input-otp.d.ts +13 -0
- package/dist/components/ui/input-otp.js +46 -0
- package/dist/components/ui/input.d.ts +5 -0
- package/dist/components/ui/input.js +14 -0
- package/dist/components/ui/item.d.ts +24 -0
- package/dist/components/ui/item.js +120 -0
- package/dist/components/ui/kbd.d.ts +5 -0
- package/dist/components/ui/kbd.js +19 -0
- package/dist/components/ui/label.d.ts +5 -0
- package/dist/components/ui/label.js +12 -0
- package/dist/components/ui/marker.d.ts +12 -0
- package/dist/components/ui/marker.js +42 -0
- package/dist/components/ui/menubar.d.ts +31 -0
- package/dist/components/ui/menubar.js +135 -0
- package/dist/components/ui/message-scroller.d.ts +12 -0
- package/dist/components/ui/message-scroller.js +59 -0
- package/dist/components/ui/message.d.ts +12 -0
- package/dist/components/ui/message.js +48 -0
- package/dist/components/ui/native-select.d.ts +10 -0
- package/dist/components/ui/native-select.js +37 -0
- package/dist/components/ui/navigation-menu.d.ts +13 -0
- package/dist/components/ui/navigation-menu.js +82 -0
- package/dist/components/ui/number-roll.d.ts +21 -0
- package/dist/components/ui/number-roll.js +269 -0
- package/dist/components/ui/pagination.d.ts +19 -0
- package/dist/components/ui/pagination.js +79 -0
- package/dist/components/ui/popover.d.ts +11 -0
- package/dist/components/ui/popover.js +54 -0
- package/dist/components/ui/progress.d.ts +9 -0
- package/dist/components/ui/progress.js +44 -0
- package/dist/components/ui/questionnaire.d.ts +21 -0
- package/dist/components/ui/questionnaire.js +169 -0
- package/dist/components/ui/radio-group.d.ts +7 -0
- package/dist/components/ui/radio-group.js +26 -0
- package/dist/components/ui/resizable.d.ts +9 -0
- package/dist/components/ui/resizable.js +28 -0
- package/dist/components/ui/scroll-area.d.ts +6 -0
- package/dist/components/ui/scroll-area.js +35 -0
- package/dist/components/ui/select.d.ts +17 -0
- package/dist/components/ui/select.js +96 -0
- package/dist/components/ui/separator.d.ts +5 -0
- package/dist/components/ui/separator.js +14 -0
- package/dist/components/ui/sheet.d.ts +16 -0
- package/dist/components/ui/sheet.js +87 -0
- package/dist/components/ui/sidebar.d.ts +65 -0
- package/dist/components/ui/sidebar.js +386 -0
- package/dist/components/ui/skeleton.d.ts +4 -0
- package/dist/components/ui/skeleton.js +12 -0
- package/dist/components/ui/slider.d.ts +5 -0
- package/dist/components/ui/slider.js +33 -0
- package/dist/components/ui/spinner.d.ts +4 -0
- package/dist/components/ui/spinner.js +15 -0
- package/dist/components/ui/switch.d.ts +7 -0
- package/dist/components/ui/switch.js +19 -0
- package/dist/components/ui/table.d.ts +12 -0
- package/dist/components/ui/table.js +65 -0
- package/dist/components/ui/tabs.d.ts +12 -0
- package/dist/components/ui/tabs.js +45 -0
- package/dist/components/ui/textarea.d.ts +5 -0
- package/dist/components/ui/textarea.js +12 -0
- package/dist/components/ui/toast.d.ts +18 -0
- package/dist/components/ui/toast.js +121 -0
- package/dist/components/ui/toggle-group.d.ts +13 -0
- package/dist/components/ui/toggle-group.js +51 -0
- package/dist/components/ui/toggle.d.ts +10 -0
- package/dist/components/ui/toggle.js +35 -0
- package/dist/components/ui/tooltip.d.ts +8 -0
- package/dist/components/ui/tooltip.js +43 -0
- package/dist/compositions/app-rail/app-rail.d.ts +19 -0
- package/dist/compositions/app-rail/app-rail.js +58 -0
- package/dist/compositions/app-shell/app-shell.d.ts +56 -0
- package/dist/compositions/app-shell/app-shell.js +143 -0
- package/dist/compositions/app-shell/theme-toggle.d.ts +10 -0
- package/dist/compositions/app-shell/theme-toggle.js +65 -0
- package/dist/compositions/confirm-action/confirm-action.d.ts +48 -0
- package/dist/compositions/confirm-action/confirm-action.js +48 -0
- package/dist/compositions/data-table/data-table-state.d.ts +23 -0
- package/dist/compositions/data-table/data-table-state.js +46 -0
- package/dist/compositions/data-table/data-table.d.ts +185 -0
- package/dist/compositions/data-table/data-table.js +615 -0
- package/dist/compositions/date-range-picker/date-range-options.d.ts +28 -0
- package/dist/compositions/date-range-picker/date-range-options.js +61 -0
- package/dist/compositions/date-range-picker/date-range-picker.d.ts +55 -0
- package/dist/compositions/date-range-picker/date-range-picker.js +409 -0
- package/dist/compositions/decision-queue/decision-queue.d.ts +114 -0
- package/dist/compositions/decision-queue/decision-queue.js +478 -0
- package/dist/compositions/event-feed/event-feed.d.ts +59 -0
- package/dist/compositions/event-feed/event-feed.js +105 -0
- package/dist/compositions/feedback.d.ts +20 -0
- package/dist/compositions/feedback.js +49 -0
- package/dist/compositions/fields.d.ts +64 -0
- package/dist/compositions/fields.js +293 -0
- package/dist/compositions/form-kit/form-context.d.ts +10 -0
- package/dist/compositions/form-kit/form-context.js +12 -0
- package/dist/compositions/form-kit/form-fields.d.ts +95 -0
- package/dist/compositions/form-kit/form-fields.js +233 -0
- package/dist/compositions/form-kit/form-kit.d.ts +128 -0
- package/dist/compositions/form-kit/form-kit.js +119 -0
- package/dist/compositions/inspector/inspector.d.ts +53 -0
- package/dist/compositions/inspector/inspector.js +80 -0
- package/dist/compositions/layout.d.ts +36 -0
- package/dist/compositions/layout.js +86 -0
- package/dist/compositions/state-blocks/state-blocks.d.ts +42 -0
- package/dist/compositions/state-blocks/state-blocks.js +81 -0
- package/dist/compositions/status-panel/status-panel.d.ts +94 -0
- package/dist/compositions/status-panel/status-panel.js +189 -0
- package/dist/fonts/InterVariable.woff2 +0 -0
- package/dist/fonts/inter.css +15 -0
- package/dist/hooks/use-attachment-src.js +35 -0
- package/dist/hooks/use-copy-to-clipboard.js +34 -0
- package/dist/hooks/use-mobile.d.ts +3 -0
- package/dist/hooks/use-mobile.js +18 -0
- package/dist/index.d.ts +102 -0
- package/dist/index.js +102 -0
- package/dist/lib/context-level.js +7 -0
- package/dist/lib/elapsed.js +61 -0
- package/dist/lib/iso-date.js +30 -0
- package/dist/lib/motion-loop.js +41 -0
- package/dist/lib/pointer.js +14 -0
- package/dist/lib/status-tone.d.ts +7 -0
- package/dist/lib/status-tone.js +55 -0
- package/dist/lib/triage-keys.js +229 -0
- package/dist/lib/utils.js +2 -0
- package/dist/motion/alert-toast/alert-toast.d.ts +51 -0
- package/dist/motion/alert-toast/alert-toast.js +226 -0
- package/dist/motion/branch-menu/branch-menu.d.ts +47 -0
- package/dist/motion/branch-menu/branch-menu.js +287 -0
- package/dist/motion/check-item/check-item.d.ts +24 -0
- package/dist/motion/check-item/check-item.js +110 -0
- package/dist/motion/dial/dial.d.ts +39 -0
- package/dist/motion/dial/dial.js +290 -0
- package/dist/motion/dictation-button/dictation-button.d.ts +45 -0
- package/dist/motion/dictation-button/dictation-button.js +232 -0
- package/dist/motion/hold-button/hold-button.d.ts +37 -0
- package/dist/motion/hold-button/hold-button.js +192 -0
- package/dist/motion/masonry-grid/masonry-grid.d.ts +42 -0
- package/dist/motion/masonry-grid/masonry-grid.js +145 -0
- package/dist/motion/prompt-composer/prompt-composer.d.ts +90 -0
- package/dist/motion/prompt-composer/prompt-composer.js +374 -0
- package/dist/motion/scrub-select/scrub-select.d.ts +33 -0
- package/dist/motion/scrub-select/scrub-select.js +346 -0
- package/dist/motion/spotlight-grid/spotlight-grid.d.ts +40 -0
- package/dist/motion/spotlight-grid/spotlight-grid.js +171 -0
- package/dist/motion/star-rating/star-rating.d.ts +32 -0
- package/dist/motion/star-rating/star-rating.js +191 -0
- package/dist/motion/status-glyph/status-glyph.d.ts +28 -0
- package/dist/motion/status-glyph/status-glyph.js +171 -0
- package/dist/motion/stepper/stepper.d.ts +56 -0
- package/dist/motion/stepper/stepper.js +211 -0
- package/dist/motion/swipe-row/swipe-row.d.ts +52 -0
- package/dist/motion/swipe-row/swipe-row.js +208 -0
- package/dist/motion/thinking-trace/thinking-trace.d.ts +32 -0
- package/dist/motion/thinking-trace/thinking-trace.js +186 -0
- package/dist/motion/tool-call-chip/tool-call-chip.d.ts +36 -0
- package/dist/motion/tool-call-chip/tool-call-chip.js +135 -0
- package/dist/motion/working-indicator/working-indicator.d.ts +38 -0
- package/dist/motion/working-indicator/working-indicator.js +171 -0
- package/dist/styles.css +828 -0
- package/dist/tokens.css +230 -0
- package/licenses/Inter-OFL.txt +92 -0
- package/licenses/assistant-ui-MIT.txt +21 -0
- package/licenses/shadcn-MIT.md +21 -0
- package/package.json +133 -4
|
@@ -0,0 +1,248 @@
|
|
|
1
|
+
import { cn } from "../../lib/utils.js";
|
|
2
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
//#region src/components/ui/dot-matrix.tsx
|
|
4
|
+
const GRID = 5;
|
|
5
|
+
const CENTER = 2;
|
|
6
|
+
const DOT_INDEXES = Array.from({ length: 25 }, (_, i) => i);
|
|
7
|
+
const hash = (n, salt, range) => {
|
|
8
|
+
let h = Math.imul(n, 374761393) + Math.imul(salt, 668265263) >>> 0;
|
|
9
|
+
h = Math.imul(h ^ h >>> 13, 1274126177) >>> 0;
|
|
10
|
+
return (h ^ h >>> 16) % range / 1e3;
|
|
11
|
+
};
|
|
12
|
+
const glyph = (dots) => new Set(dots.map(([row, col]) => row * GRID + col));
|
|
13
|
+
const CHECK = glyph([
|
|
14
|
+
[1, 4],
|
|
15
|
+
[2, 3],
|
|
16
|
+
[3, 0],
|
|
17
|
+
[3, 2],
|
|
18
|
+
[4, 1]
|
|
19
|
+
]);
|
|
20
|
+
const CROSS = glyph([
|
|
21
|
+
[0, 0],
|
|
22
|
+
[0, 4],
|
|
23
|
+
[1, 1],
|
|
24
|
+
[1, 3],
|
|
25
|
+
[2, 2],
|
|
26
|
+
[3, 1],
|
|
27
|
+
[3, 3],
|
|
28
|
+
[4, 0],
|
|
29
|
+
[4, 4]
|
|
30
|
+
]);
|
|
31
|
+
const BANG = glyph([
|
|
32
|
+
[0, 2],
|
|
33
|
+
[1, 2],
|
|
34
|
+
[2, 2],
|
|
35
|
+
[4, 2]
|
|
36
|
+
]);
|
|
37
|
+
const INFO = glyph([
|
|
38
|
+
[0, 2],
|
|
39
|
+
[2, 2],
|
|
40
|
+
[3, 2],
|
|
41
|
+
[4, 2]
|
|
42
|
+
]);
|
|
43
|
+
const PAUSE = glyph([
|
|
44
|
+
[1, 1],
|
|
45
|
+
[2, 1],
|
|
46
|
+
[3, 1],
|
|
47
|
+
[1, 3],
|
|
48
|
+
[2, 3],
|
|
49
|
+
[3, 3]
|
|
50
|
+
]);
|
|
51
|
+
const STOP = glyph([
|
|
52
|
+
[1, 1],
|
|
53
|
+
[1, 2],
|
|
54
|
+
[1, 3],
|
|
55
|
+
[2, 1],
|
|
56
|
+
[2, 2],
|
|
57
|
+
[2, 3],
|
|
58
|
+
[3, 1],
|
|
59
|
+
[3, 2],
|
|
60
|
+
[3, 3]
|
|
61
|
+
]);
|
|
62
|
+
const RECORD = glyph([
|
|
63
|
+
[1, 2],
|
|
64
|
+
[2, 1],
|
|
65
|
+
[2, 2],
|
|
66
|
+
[2, 3],
|
|
67
|
+
[3, 2]
|
|
68
|
+
]);
|
|
69
|
+
const STATES = {
|
|
70
|
+
idle: {
|
|
71
|
+
color: "text-muted-foreground",
|
|
72
|
+
base: .3
|
|
73
|
+
},
|
|
74
|
+
loading: { blink: (i) => ({
|
|
75
|
+
duration: .9 + hash(i, 2, 700),
|
|
76
|
+
delay: -hash(i, 1, 1200),
|
|
77
|
+
lo: .15
|
|
78
|
+
}) },
|
|
79
|
+
thinking: { blink: (_i, row, col) => ({
|
|
80
|
+
duration: 1.2,
|
|
81
|
+
delay: -(row + col) * .09,
|
|
82
|
+
lo: .2
|
|
83
|
+
}) },
|
|
84
|
+
streaming: { blink: (_i, row, col) => ({
|
|
85
|
+
duration: .9,
|
|
86
|
+
delay: -(row * .12 + hash(col, 3, 900)),
|
|
87
|
+
lo: .15
|
|
88
|
+
}) },
|
|
89
|
+
searching: { blink: (_i, _row, col) => ({
|
|
90
|
+
duration: 1.1,
|
|
91
|
+
delay: -col * .12,
|
|
92
|
+
lo: .2
|
|
93
|
+
}) },
|
|
94
|
+
syncing: { blink: (_i, row, col) => {
|
|
95
|
+
return {
|
|
96
|
+
duration: 1.3,
|
|
97
|
+
delay: -((Math.atan2(row - CENTER, col - CENTER) + Math.PI) / (2 * Math.PI)) * 1.3,
|
|
98
|
+
lo: .2
|
|
99
|
+
};
|
|
100
|
+
} },
|
|
101
|
+
connecting: { blink: (_i, row, col) => ({
|
|
102
|
+
duration: 1.4,
|
|
103
|
+
delay: -Math.max(Math.abs(row - CENTER), Math.abs(col - CENTER)) * .18,
|
|
104
|
+
lo: .15
|
|
105
|
+
}) },
|
|
106
|
+
waiting: {
|
|
107
|
+
glyph: glyph([
|
|
108
|
+
[2, 0],
|
|
109
|
+
[2, 2],
|
|
110
|
+
[2, 4]
|
|
111
|
+
]),
|
|
112
|
+
blink: (_i, _row, col) => ({
|
|
113
|
+
duration: 1.2,
|
|
114
|
+
delay: -col * .09,
|
|
115
|
+
lo: .2
|
|
116
|
+
})
|
|
117
|
+
},
|
|
118
|
+
uploading: { blink: (_i, row) => ({
|
|
119
|
+
duration: 1,
|
|
120
|
+
delay: -(4 - row) * .12,
|
|
121
|
+
lo: .2
|
|
122
|
+
}) },
|
|
123
|
+
downloading: { blink: (_i, row) => ({
|
|
124
|
+
duration: 1,
|
|
125
|
+
delay: -row * .12,
|
|
126
|
+
lo: .2
|
|
127
|
+
}) },
|
|
128
|
+
listening: { blink: (_i, _row, col) => ({
|
|
129
|
+
duration: .7 + hash(col, 4, 500),
|
|
130
|
+
delay: -hash(col, 5, 900),
|
|
131
|
+
lo: .25
|
|
132
|
+
}) },
|
|
133
|
+
speaking: { blink: (_i, _row, col) => ({
|
|
134
|
+
duration: .4 + hash(col, 6, 350),
|
|
135
|
+
delay: -hash(col, 7, 700),
|
|
136
|
+
lo: .2
|
|
137
|
+
}) },
|
|
138
|
+
recording: {
|
|
139
|
+
color: "text-destructive",
|
|
140
|
+
glyph: RECORD,
|
|
141
|
+
dim: .12,
|
|
142
|
+
blink: () => ({
|
|
143
|
+
duration: 1.4,
|
|
144
|
+
delay: 0,
|
|
145
|
+
lo: .3
|
|
146
|
+
})
|
|
147
|
+
},
|
|
148
|
+
success: {
|
|
149
|
+
color: "text-success",
|
|
150
|
+
glyph: CHECK
|
|
151
|
+
},
|
|
152
|
+
error: {
|
|
153
|
+
color: "text-destructive",
|
|
154
|
+
glyph: CROSS,
|
|
155
|
+
blink: () => ({
|
|
156
|
+
duration: 1.1,
|
|
157
|
+
delay: 0,
|
|
158
|
+
lo: .4
|
|
159
|
+
})
|
|
160
|
+
},
|
|
161
|
+
warning: {
|
|
162
|
+
color: "text-warning",
|
|
163
|
+
glyph: BANG,
|
|
164
|
+
blink: () => ({
|
|
165
|
+
duration: 1.6,
|
|
166
|
+
delay: 0,
|
|
167
|
+
lo: .45
|
|
168
|
+
})
|
|
169
|
+
},
|
|
170
|
+
info: {
|
|
171
|
+
color: "text-info",
|
|
172
|
+
glyph: INFO
|
|
173
|
+
},
|
|
174
|
+
paused: {
|
|
175
|
+
color: "text-muted-foreground",
|
|
176
|
+
glyph: PAUSE
|
|
177
|
+
},
|
|
178
|
+
stopped: {
|
|
179
|
+
color: "text-muted-foreground",
|
|
180
|
+
glyph: STOP
|
|
181
|
+
},
|
|
182
|
+
offline: {
|
|
183
|
+
color: "text-muted-foreground",
|
|
184
|
+
base: .15
|
|
185
|
+
}
|
|
186
|
+
};
|
|
187
|
+
const dotMatrixStates = Object.keys(STATES);
|
|
188
|
+
const DOT_MATRIX_CSS = "@property --aui-dot-matrix-hi{syntax:\"<number>\";inherits:false;initial-value:1}@property --aui-dot-matrix-lo{syntax:\"<number>\";inherits:false;initial-value:0.15}@keyframes aui-dot-matrix-blink{0%,100%{opacity:var(--aui-dot-matrix-hi,1)}50%{opacity:var(--aui-dot-matrix-lo,0.15)}}";
|
|
189
|
+
const HOISTED_STYLE = {
|
|
190
|
+
href: "aui-dot-matrix",
|
|
191
|
+
precedence: "low"
|
|
192
|
+
};
|
|
193
|
+
/**
|
|
194
|
+
* Tiny 5x5 dot-matrix status indicator with 20 built-in states. Dots inherit the text color and animate in state-specific patterns: twinkle, waves, ripples, sweeps, equalizer columns, and check/cross/bang glyphs. State changes cross-fade per dot.
|
|
195
|
+
*
|
|
196
|
+
* ```tsx
|
|
197
|
+
* <DotMatrix state={isRunning ? "loading" : "success"} />
|
|
198
|
+
* ```
|
|
199
|
+
*/
|
|
200
|
+
function DotMatrix({ className, state = "loading", label, ...props }) {
|
|
201
|
+
const config = STATES[state];
|
|
202
|
+
return /* @__PURE__ */ jsxs("span", {
|
|
203
|
+
"data-slot": "dot-matrix",
|
|
204
|
+
"data-state": state,
|
|
205
|
+
role: "status",
|
|
206
|
+
className: cn("inline-block size-4 shrink-0", config.color, className),
|
|
207
|
+
...props,
|
|
208
|
+
children: [
|
|
209
|
+
/* @__PURE__ */ jsx("span", {
|
|
210
|
+
className: "sr-only",
|
|
211
|
+
children: label ?? state
|
|
212
|
+
}),
|
|
213
|
+
/* @__PURE__ */ jsx("style", {
|
|
214
|
+
...HOISTED_STYLE,
|
|
215
|
+
children: DOT_MATRIX_CSS
|
|
216
|
+
}),
|
|
217
|
+
/* @__PURE__ */ jsx("svg", {
|
|
218
|
+
"aria-hidden": true,
|
|
219
|
+
viewBox: "0 0 20 20",
|
|
220
|
+
fill: "currentColor",
|
|
221
|
+
className: "size-full",
|
|
222
|
+
children: DOT_INDEXES.map((i) => {
|
|
223
|
+
const row = Math.floor(i / GRID);
|
|
224
|
+
const col = i % GRID;
|
|
225
|
+
const on = !config.glyph || config.glyph.has(i);
|
|
226
|
+
const hi = on ? config.base ?? 1 : config.dim ?? .15;
|
|
227
|
+
const blink = on ? config.blink?.(i, row, col) : void 0;
|
|
228
|
+
return /* @__PURE__ */ jsx("circle", {
|
|
229
|
+
"data-slot": "dot-matrix-dot",
|
|
230
|
+
cx: 2 + col * 4,
|
|
231
|
+
cy: 2 + row * 4,
|
|
232
|
+
r: 1.3,
|
|
233
|
+
className: "[transition-property:--aui-dot-matrix-hi,--aui-dot-matrix-lo,opacity] duration-300 [animation-iteration-count:infinite] [animation-name:aui-dot-matrix-blink] [animation-timing-function:ease-in-out] motion-reduce:[animation-name:none]",
|
|
234
|
+
style: {
|
|
235
|
+
opacity: hi,
|
|
236
|
+
animationDuration: `${blink?.duration ?? 1}s`,
|
|
237
|
+
animationDelay: `${blink?.delay ?? 0}s`,
|
|
238
|
+
"--aui-dot-matrix-hi": hi,
|
|
239
|
+
"--aui-dot-matrix-lo": blink?.lo ?? hi
|
|
240
|
+
}
|
|
241
|
+
}, i);
|
|
242
|
+
})
|
|
243
|
+
})
|
|
244
|
+
]
|
|
245
|
+
});
|
|
246
|
+
}
|
|
247
|
+
//#endregion
|
|
248
|
+
export { DotMatrix, dotMatrixStates };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Drawer } from "@base-ui/react/drawer";
|
|
3
|
+
//#region src/components/ui/drawer.d.ts
|
|
4
|
+
declare function Drawer$1({ modal, showSwipeHandle, snapPoints, swipeDirection, ...props }: Drawer.Root.Props & {
|
|
5
|
+
showSwipeHandle?: boolean;
|
|
6
|
+
}): React.JSX.Element;
|
|
7
|
+
declare function DrawerTrigger({ ...props }: Drawer.Trigger.Props): React.JSX.Element;
|
|
8
|
+
declare function DrawerPortal({ ...props }: Drawer.Portal.Props): React.JSX.Element;
|
|
9
|
+
declare function DrawerClose({ ...props }: Drawer.Close.Props): React.JSX.Element;
|
|
10
|
+
declare function DrawerOverlay({ className, ...props }: Drawer.Backdrop.Props): React.JSX.Element;
|
|
11
|
+
declare function DrawerSwipeHandle({ className, ...props }: React.ComponentProps<"div">): React.JSX.Element;
|
|
12
|
+
declare function DrawerContent({ className, children, ...props }: Drawer.Popup.Props): React.JSX.Element;
|
|
13
|
+
declare function DrawerHeader({ className, ...props }: React.ComponentProps<"div">): React.JSX.Element;
|
|
14
|
+
declare function DrawerFooter({ className, ...props }: React.ComponentProps<"div">): React.JSX.Element;
|
|
15
|
+
declare function DrawerTitle({ className, ...props }: Drawer.Title.Props): React.JSX.Element;
|
|
16
|
+
declare function DrawerDescription({ className, ...props }: Drawer.Description.Props): React.JSX.Element;
|
|
17
|
+
//#endregion
|
|
18
|
+
export { Drawer$1 as Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerSwipeHandle, DrawerTitle, DrawerTrigger };
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
4
|
+
import { cn } from "cn";
|
|
5
|
+
import { Drawer } from "@base-ui/react/drawer";
|
|
6
|
+
//#region src/components/ui/drawer.tsx
|
|
7
|
+
const DrawerContext = React.createContext(null);
|
|
8
|
+
function useDrawer() {
|
|
9
|
+
const context = React.useContext(DrawerContext);
|
|
10
|
+
if (!context) throw new Error("useDrawer must be used within a Drawer.");
|
|
11
|
+
return context;
|
|
12
|
+
}
|
|
13
|
+
function Drawer$1({ modal = true, showSwipeHandle = false, snapPoints, swipeDirection = "down", ...props }) {
|
|
14
|
+
const hasSnapPoints = snapPoints != null && snapPoints.length > 0;
|
|
15
|
+
const contextValue = React.useMemo(() => ({
|
|
16
|
+
hasSnapPoints,
|
|
17
|
+
modal,
|
|
18
|
+
showSwipeHandle,
|
|
19
|
+
swipeDirection
|
|
20
|
+
}), [
|
|
21
|
+
hasSnapPoints,
|
|
22
|
+
modal,
|
|
23
|
+
showSwipeHandle,
|
|
24
|
+
swipeDirection
|
|
25
|
+
]);
|
|
26
|
+
return /* @__PURE__ */ jsx(DrawerContext.Provider, {
|
|
27
|
+
value: contextValue,
|
|
28
|
+
children: /* @__PURE__ */ jsx(Drawer.Root, {
|
|
29
|
+
"data-slot": "drawer",
|
|
30
|
+
modal,
|
|
31
|
+
snapPoints,
|
|
32
|
+
swipeDirection,
|
|
33
|
+
...props
|
|
34
|
+
})
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
function DrawerTrigger({ ...props }) {
|
|
38
|
+
return /* @__PURE__ */ jsx(Drawer.Trigger, {
|
|
39
|
+
"data-slot": "drawer-trigger",
|
|
40
|
+
...props
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
function DrawerPortal({ ...props }) {
|
|
44
|
+
return /* @__PURE__ */ jsx(Drawer.Portal, {
|
|
45
|
+
"data-slot": "drawer-portal",
|
|
46
|
+
...props
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
function DrawerClose({ ...props }) {
|
|
50
|
+
return /* @__PURE__ */ jsx(Drawer.Close, {
|
|
51
|
+
"data-slot": "drawer-close",
|
|
52
|
+
...props
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
function DrawerOverlay({ className, ...props }) {
|
|
56
|
+
return /* @__PURE__ */ jsx(Drawer.Backdrop, {
|
|
57
|
+
"data-slot": "drawer-overlay",
|
|
58
|
+
className: cn("fixed inset-0 z-50 min-h-dvh bg-black/80 opacity-[max(var(--drawer-overlay-min-opacity,0),calc(1-var(--drawer-swipe-progress)))] transition-opacity duration-450 ease-[cubic-bezier(0.32,0.72,0,1)] select-none data-ending-style:pointer-events-none data-ending-style:opacity-0 data-ending-style:duration-[calc(var(--drawer-swipe-strength)*400ms)] data-snap-points:[--drawer-overlay-min-opacity:0.5] data-starting-style:opacity-0 data-swiping:duration-0 supports-backdrop-filter:backdrop-blur-xs supports-[-webkit-touch-callout:none]:absolute", className),
|
|
59
|
+
...props
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
function DrawerSwipeHandle({ className, ...props }) {
|
|
63
|
+
return /* @__PURE__ */ jsx("div", {
|
|
64
|
+
"data-slot": "drawer-swipe-handle",
|
|
65
|
+
"aria-hidden": "true",
|
|
66
|
+
className: cn("relative z-10 flex shrink-0 cursor-grab transition-opacity duration-200 group-data-nested-drawer-open/drawer-popup:opacity-0 group-data-nested-drawer-swiping/drawer-popup:opacity-100 group-data-[swipe-axis=x]/drawer-popup:h-full group-data-[swipe-axis=x]/drawer-popup:w-3 group-data-[swipe-axis=x]/drawer-popup:items-center group-data-[swipe-axis=y]/drawer-popup:h-3 group-data-[swipe-axis=y]/drawer-popup:w-full group-data-[swipe-axis=y]/drawer-popup:justify-center group-data-[swipe-direction=down]/drawer-popup:items-end group-data-[swipe-direction=left]/drawer-popup:order-last group-data-[swipe-direction=left]/drawer-popup:justify-start group-data-[swipe-direction=right]/drawer-popup:justify-end group-data-[swipe-direction=up]/drawer-popup:order-last group-data-[swipe-direction=up]/drawer-popup:items-start after:block after:shrink-0 after:rounded-full after:bg-muted group-data-[swipe-axis=x]/drawer-popup:after:h-12 group-data-[swipe-axis=x]/drawer-popup:after:w-1 group-data-[swipe-axis=y]/drawer-popup:after:h-1 group-data-[swipe-axis=y]/drawer-popup:after:w-12 active:cursor-grabbing", className),
|
|
67
|
+
...props
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
function DrawerContent({ className, children, ...props }) {
|
|
71
|
+
const { hasSnapPoints, modal, showSwipeHandle, swipeDirection } = useDrawer();
|
|
72
|
+
const swipeAxis = swipeDirection === "down" || swipeDirection === "up" ? "y" : "x";
|
|
73
|
+
return /* @__PURE__ */ jsxs(DrawerPortal, {
|
|
74
|
+
"data-slot": "drawer-portal",
|
|
75
|
+
children: [modal === true && /* @__PURE__ */ jsx(DrawerOverlay, { "data-snap-points": hasSnapPoints ? "" : void 0 }), /* @__PURE__ */ jsx(Drawer.Viewport, {
|
|
76
|
+
"data-slot": "drawer-viewport",
|
|
77
|
+
"data-modal": modal,
|
|
78
|
+
className: "pointer-events-none fixed inset-0 z-50 select-none data-[modal=true]:pointer-events-auto",
|
|
79
|
+
children: /* @__PURE__ */ jsxs(Drawer.Popup, {
|
|
80
|
+
"data-slot": "drawer-popup",
|
|
81
|
+
"data-swipe-axis": swipeAxis,
|
|
82
|
+
"data-snap-points": hasSnapPoints ? "" : void 0,
|
|
83
|
+
className: cn("group/drawer-popup pointer-events-auto fixed z-50 m-(--drawer-inset,0px) flex h-(--drawer-content-height) max-h-(--drawer-content-max-height,none) min-h-0 w-(--drawer-content-width,auto) transform-[translate3d(var(--translate-x,0px),var(--translate-y,0px),0)_scale(var(--stack-scale))] flex-col rounded-xl border border-popover bg-popover text-xs/relaxed text-popover-foreground transition-[transform,height,opacity,filter] duration-450 ease-[cubic-bezier(0.22,1,0.36,1)] will-change-transform outline-none select-none [--drawer-bleed-background:transparent] [--drawer-inset:--spacing(2)] [interpolate-size:allow-keywords] dark:border-border", "data-nested-drawer-open:overflow-hidden data-nested-drawer-open:brightness-95", "after:pointer-events-none after:absolute after:bg-(--drawer-bleed-background,var(--color-popover)) data-[swipe-axis=x]:after:inset-y-0 data-[swipe-axis=x]:after:w-(--bleed) data-[swipe-axis=y]:after:inset-x-0 data-[swipe-axis=y]:after:h-(--bleed) data-[swipe-direction=down]:after:top-full data-[swipe-direction=left]:after:right-full data-[swipe-direction=right]:after:left-full data-[swipe-direction=up]:after:bottom-full", "[--drawer-content-height:var(--drawer-height,auto)] data-[swipe-axis=x]:[--drawer-content-width:75%] data-[swipe-axis=y]:[--drawer-content-max-height:calc(100dvh-6rem)] data-[swipe-axis=y]:data-snap-points:[--drawer-content-height:100dvh] data-[swipe-axis=x]:sm:[--drawer-content-width:24rem]", "[--bleed:3rem] [--peek:1rem] [--stack-height:var(--drawer-frontmost-height,var(--drawer-height,0px))] [--stack-peek-offset:max(0px,calc((var(--nested-drawers)-var(--stack-progress))*var(--peek)))] [--stack-progress:clamp(0,var(--drawer-swipe-progress),1)] [--stack-scale-base:max(0,calc(1-(var(--nested-drawers)*var(--stack-step))))] [--stack-scale:clamp(0,calc(var(--stack-scale-base)+(var(--stack-step)*var(--stack-progress))),1)] [--stack-shrink:calc(1-var(--stack-scale))] [--stack-step:0.05]", "data-ending-style:transform-(--closed-transform) data-ending-style:opacity-[0.9999] data-ending-style:duration-[calc(var(--drawer-swipe-strength)*400ms)] data-nested-drawer-swiping:duration-0 data-ending-style:data-nested-drawer-swiping:duration-[calc(var(--drawer-swipe-strength)*400ms)] data-starting-style:transform-(--closed-transform) data-swiping:duration-0 data-ending-style:data-swiping:duration-[calc(var(--drawer-swipe-strength)*400ms)]", "data-[swipe-axis=y]:inset-x-0 data-[swipe-axis=y]:data-nested-drawer-open:h-(--stack-height)", "data-[swipe-axis=x]:inset-y-0 data-[swipe-axis=x]:flex-row", "data-[swipe-direction=down]:bottom-0 data-[swipe-direction=down]:origin-bottom data-[swipe-direction=down]:[--closed-transform:translate3d(0,calc(100%+var(--drawer-inset,0px)+2px),0)] data-[swipe-direction=down]:[--translate-y:calc(var(--drawer-snap-point-offset,0px)+var(--drawer-swipe-movement-y)-var(--stack-peek-offset)-(var(--stack-shrink)*var(--stack-height)))]", "data-[swipe-direction=up]:top-0 data-[swipe-direction=up]:origin-top data-[swipe-direction=up]:[--closed-transform:translate3d(0,calc(-100%-var(--drawer-inset,0px)-2px),0)] data-[swipe-direction=up]:[--translate-y:calc(var(--drawer-snap-point-offset,0px)+var(--drawer-swipe-movement-y)+var(--stack-peek-offset)+(var(--stack-shrink)*var(--stack-height)))]", "data-[swipe-direction=left]:left-0 data-[swipe-direction=left]:origin-left data-[swipe-direction=left]:[--closed-transform:translate3d(calc(-100%-var(--drawer-inset,0px)-2px),0,0)] data-[swipe-direction=left]:[--translate-x:calc(var(--drawer-swipe-movement-x)+var(--stack-peek-offset)+(var(--stack-shrink)*100%))]", "data-[swipe-direction=right]:right-0 data-[swipe-direction=right]:origin-right data-[swipe-direction=right]:[--closed-transform:translate3d(calc(100%+var(--drawer-inset,0px)+2px),0,0)] data-[swipe-direction=right]:[--translate-x:calc(var(--drawer-swipe-movement-x)-var(--stack-peek-offset)-(var(--stack-shrink)*100%))]", className),
|
|
84
|
+
...props,
|
|
85
|
+
children: [showSwipeHandle && /* @__PURE__ */ jsx(DrawerSwipeHandle, {}), /* @__PURE__ */ jsx(Drawer.Content, {
|
|
86
|
+
"data-slot": "drawer-content",
|
|
87
|
+
className: cn("flex min-h-0 flex-1 flex-col overflow-hidden overscroll-contain rounded-[inherit] transition-opacity duration-300 ease-[cubic-bezier(0.45,1.005,0,1.005)] select-text group-data-nested-drawer-open/drawer-popup:opacity-0 group-data-nested-drawer-swiping/drawer-popup:opacity-100 group-data-swiping/drawer-popup:select-none"),
|
|
88
|
+
children
|
|
89
|
+
})]
|
|
90
|
+
})
|
|
91
|
+
})]
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
function DrawerHeader({ className, ...props }) {
|
|
95
|
+
return /* @__PURE__ */ jsx("div", {
|
|
96
|
+
"data-slot": "drawer-header",
|
|
97
|
+
className: cn("flex shrink-0 flex-col gap-1 p-4 pb-0 group-data-[swipe-axis=y]/drawer-popup:text-center md:text-left", className),
|
|
98
|
+
...props
|
|
99
|
+
});
|
|
100
|
+
}
|
|
101
|
+
function DrawerFooter({ className, ...props }) {
|
|
102
|
+
return /* @__PURE__ */ jsx("div", {
|
|
103
|
+
"data-slot": "drawer-footer",
|
|
104
|
+
className: cn("mt-auto flex shrink-0 flex-col gap-2 p-4 pt-0", className),
|
|
105
|
+
...props
|
|
106
|
+
});
|
|
107
|
+
}
|
|
108
|
+
function DrawerTitle({ className, ...props }) {
|
|
109
|
+
return /* @__PURE__ */ jsx(Drawer.Title, {
|
|
110
|
+
"data-slot": "drawer-title",
|
|
111
|
+
className: cn("font-heading text-sm font-medium text-foreground", className),
|
|
112
|
+
...props
|
|
113
|
+
});
|
|
114
|
+
}
|
|
115
|
+
function DrawerDescription({ className, ...props }) {
|
|
116
|
+
return /* @__PURE__ */ jsx(Drawer.Description, {
|
|
117
|
+
"data-slot": "drawer-description",
|
|
118
|
+
className: cn("text-xs/relaxed text-balance text-muted-foreground", className),
|
|
119
|
+
...props
|
|
120
|
+
});
|
|
121
|
+
}
|
|
122
|
+
//#endregion
|
|
123
|
+
export { Drawer$1 as Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerSwipeHandle, DrawerTitle, DrawerTrigger };
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Menu } from "@base-ui/react/menu";
|
|
3
|
+
//#region src/components/ui/dropdown-menu.d.ts
|
|
4
|
+
declare function DropdownMenu({ ...props }: Menu.Root.Props): React.JSX.Element;
|
|
5
|
+
declare function DropdownMenuPortal({ ...props }: Menu.Portal.Props): React.JSX.Element;
|
|
6
|
+
declare function DropdownMenuTrigger({ ...props }: Menu.Trigger.Props): React.JSX.Element;
|
|
7
|
+
declare function DropdownMenuContent({ align, alignOffset, side, sideOffset, className, ...props }: Menu.Popup.Props & Pick<Menu.Positioner.Props, "align" | "alignOffset" | "side" | "sideOffset">): React.JSX.Element;
|
|
8
|
+
declare function DropdownMenuGroup({ ...props }: Menu.Group.Props): React.JSX.Element;
|
|
9
|
+
declare function DropdownMenuLabel({ className, inset, ...props }: Menu.GroupLabel.Props & {
|
|
10
|
+
inset?: boolean;
|
|
11
|
+
}): React.JSX.Element;
|
|
12
|
+
declare function DropdownMenuItem({ className, inset, variant, ...props }: Menu.Item.Props & {
|
|
13
|
+
inset?: boolean;
|
|
14
|
+
variant?: "default" | "destructive";
|
|
15
|
+
}): React.JSX.Element;
|
|
16
|
+
declare function DropdownMenuSub({ ...props }: Menu.SubmenuRoot.Props): React.JSX.Element;
|
|
17
|
+
declare function DropdownMenuSubTrigger({ className, inset, children, ...props }: Menu.SubmenuTrigger.Props & {
|
|
18
|
+
inset?: boolean;
|
|
19
|
+
}): React.JSX.Element;
|
|
20
|
+
declare function DropdownMenuSubContent({ align, alignOffset, side, sideOffset, className, ...props }: React.ComponentProps<typeof DropdownMenuContent>): React.JSX.Element;
|
|
21
|
+
declare function DropdownMenuCheckboxItem({ className, children, checked, inset, ...props }: Menu.CheckboxItem.Props & {
|
|
22
|
+
inset?: boolean;
|
|
23
|
+
}): React.JSX.Element;
|
|
24
|
+
declare function DropdownMenuRadioGroup({ ...props }: Menu.RadioGroup.Props): React.JSX.Element;
|
|
25
|
+
declare function DropdownMenuRadioItem({ className, children, inset, ...props }: Menu.RadioItem.Props & {
|
|
26
|
+
inset?: boolean;
|
|
27
|
+
}): React.JSX.Element;
|
|
28
|
+
declare function DropdownMenuSeparator({ className, ...props }: Menu.Separator.Props): React.JSX.Element;
|
|
29
|
+
declare function DropdownMenuShortcut({ className, ...props }: React.ComponentProps<"span">): React.JSX.Element;
|
|
30
|
+
//#endregion
|
|
31
|
+
export { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger };
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { cn } from "cn";
|
|
4
|
+
import { CheckIcon, ChevronRightIcon } from "lucide-react";
|
|
5
|
+
import { Menu } from "@base-ui/react/menu";
|
|
6
|
+
//#region src/components/ui/dropdown-menu.tsx
|
|
7
|
+
function DropdownMenu({ ...props }) {
|
|
8
|
+
return /* @__PURE__ */ jsx(Menu.Root, {
|
|
9
|
+
"data-slot": "dropdown-menu",
|
|
10
|
+
...props
|
|
11
|
+
});
|
|
12
|
+
}
|
|
13
|
+
function DropdownMenuPortal({ ...props }) {
|
|
14
|
+
return /* @__PURE__ */ jsx(Menu.Portal, {
|
|
15
|
+
"data-slot": "dropdown-menu-portal",
|
|
16
|
+
...props
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
function DropdownMenuTrigger({ ...props }) {
|
|
20
|
+
return /* @__PURE__ */ jsx(Menu.Trigger, {
|
|
21
|
+
"data-slot": "dropdown-menu-trigger",
|
|
22
|
+
...props
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
function DropdownMenuContent({ align = "start", alignOffset = 0, side = "bottom", sideOffset = 4, className, ...props }) {
|
|
26
|
+
return /* @__PURE__ */ jsx(Menu.Portal, { children: /* @__PURE__ */ jsx(Menu.Positioner, {
|
|
27
|
+
className: "isolate z-50 outline-none",
|
|
28
|
+
align,
|
|
29
|
+
alignOffset,
|
|
30
|
+
side,
|
|
31
|
+
sideOffset,
|
|
32
|
+
children: /* @__PURE__ */ jsx(Menu.Popup, {
|
|
33
|
+
"data-slot": "dropdown-menu-content",
|
|
34
|
+
className: cn("z-50 max-h-(--available-height) w-(--anchor-width) min-w-32 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:overflow-hidden data-closed:fade-out-0 data-closed:zoom-out-95", className),
|
|
35
|
+
...props
|
|
36
|
+
})
|
|
37
|
+
}) });
|
|
38
|
+
}
|
|
39
|
+
function DropdownMenuGroup({ ...props }) {
|
|
40
|
+
return /* @__PURE__ */ jsx(Menu.Group, {
|
|
41
|
+
"data-slot": "dropdown-menu-group",
|
|
42
|
+
...props
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
function DropdownMenuLabel({ className, inset, ...props }) {
|
|
46
|
+
return /* @__PURE__ */ jsx(Menu.GroupLabel, {
|
|
47
|
+
"data-slot": "dropdown-menu-label",
|
|
48
|
+
"data-inset": inset,
|
|
49
|
+
className: cn("px-2 py-1.5 text-xs text-muted-foreground data-inset:pl-7.5", className),
|
|
50
|
+
...props
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
function DropdownMenuItem({ className, inset, variant = "default", ...props }) {
|
|
54
|
+
return /* @__PURE__ */ jsx(Menu.Item, {
|
|
55
|
+
"data-slot": "dropdown-menu-item",
|
|
56
|
+
"data-inset": inset,
|
|
57
|
+
"data-variant": variant,
|
|
58
|
+
className: cn("group/dropdown-menu-item relative flex min-h-7 cursor-default items-center gap-2 rounded-md px-2 py-1 text-xs/relaxed outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:pl-7.5 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-3.5 data-[variant=destructive]:*:[svg]:text-destructive", className),
|
|
59
|
+
...props
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
function DropdownMenuSub({ ...props }) {
|
|
63
|
+
return /* @__PURE__ */ jsx(Menu.SubmenuRoot, {
|
|
64
|
+
"data-slot": "dropdown-menu-sub",
|
|
65
|
+
...props
|
|
66
|
+
});
|
|
67
|
+
}
|
|
68
|
+
function DropdownMenuSubTrigger({ className, inset, children, ...props }) {
|
|
69
|
+
return /* @__PURE__ */ jsxs(Menu.SubmenuTrigger, {
|
|
70
|
+
"data-slot": "dropdown-menu-sub-trigger",
|
|
71
|
+
"data-inset": inset,
|
|
72
|
+
className: cn("flex min-h-7 cursor-default items-center gap-2 rounded-md px-2 py-1 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:pl-7.5 data-popup-open:bg-accent data-popup-open:text-accent-foreground data-open:bg-accent data-open:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-3.5", className),
|
|
73
|
+
...props,
|
|
74
|
+
children: [children, /* @__PURE__ */ jsx(ChevronRightIcon, { className: "ml-auto" })]
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
function DropdownMenuSubContent({ align = "start", alignOffset = -3, side = "right", sideOffset = 0, className, ...props }) {
|
|
78
|
+
return /* @__PURE__ */ jsx(DropdownMenuContent, {
|
|
79
|
+
"data-slot": "dropdown-menu-sub-content",
|
|
80
|
+
className: cn("w-auto min-w-32 rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className),
|
|
81
|
+
align,
|
|
82
|
+
alignOffset,
|
|
83
|
+
side,
|
|
84
|
+
sideOffset,
|
|
85
|
+
...props
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
function DropdownMenuCheckboxItem({ className, children, checked, inset, ...props }) {
|
|
89
|
+
return /* @__PURE__ */ jsxs(Menu.CheckboxItem, {
|
|
90
|
+
"data-slot": "dropdown-menu-checkbox-item",
|
|
91
|
+
"data-inset": inset,
|
|
92
|
+
className: cn("relative flex min-h-7 cursor-default items-center gap-2 rounded-md py-1.5 pr-8 pl-2 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-inset:pl-7.5 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-3.5", className),
|
|
93
|
+
checked,
|
|
94
|
+
...props,
|
|
95
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
96
|
+
className: "pointer-events-none absolute right-2 flex items-center justify-center",
|
|
97
|
+
"data-slot": "dropdown-menu-checkbox-item-indicator",
|
|
98
|
+
children: /* @__PURE__ */ jsx(Menu.CheckboxItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, {}) })
|
|
99
|
+
}), children]
|
|
100
|
+
});
|
|
101
|
+
}
|
|
102
|
+
function DropdownMenuRadioGroup({ ...props }) {
|
|
103
|
+
return /* @__PURE__ */ jsx(Menu.RadioGroup, {
|
|
104
|
+
"data-slot": "dropdown-menu-radio-group",
|
|
105
|
+
...props
|
|
106
|
+
});
|
|
107
|
+
}
|
|
108
|
+
function DropdownMenuRadioItem({ className, children, inset, ...props }) {
|
|
109
|
+
return /* @__PURE__ */ jsxs(Menu.RadioItem, {
|
|
110
|
+
"data-slot": "dropdown-menu-radio-item",
|
|
111
|
+
"data-inset": inset,
|
|
112
|
+
className: cn("relative flex min-h-7 cursor-default items-center gap-2 rounded-md py-1.5 pr-8 pl-2 text-xs outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-inset:pl-7.5 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-3.5", className),
|
|
113
|
+
...props,
|
|
114
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
115
|
+
className: "pointer-events-none absolute right-2 flex items-center justify-center",
|
|
116
|
+
"data-slot": "dropdown-menu-radio-item-indicator",
|
|
117
|
+
children: /* @__PURE__ */ jsx(Menu.RadioItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, {}) })
|
|
118
|
+
}), children]
|
|
119
|
+
});
|
|
120
|
+
}
|
|
121
|
+
function DropdownMenuSeparator({ className, ...props }) {
|
|
122
|
+
return /* @__PURE__ */ jsx(Menu.Separator, {
|
|
123
|
+
"data-slot": "dropdown-menu-separator",
|
|
124
|
+
className: cn("-mx-1 my-1 h-px bg-border/50", className),
|
|
125
|
+
...props
|
|
126
|
+
});
|
|
127
|
+
}
|
|
128
|
+
function DropdownMenuShortcut({ className, ...props }) {
|
|
129
|
+
return /* @__PURE__ */ jsx("span", {
|
|
130
|
+
"data-slot": "dropdown-menu-shortcut",
|
|
131
|
+
className: cn("ml-auto text-[0.625rem] tracking-widest text-muted-foreground group-focus/dropdown-menu-item:text-accent-foreground", className),
|
|
132
|
+
...props
|
|
133
|
+
});
|
|
134
|
+
}
|
|
135
|
+
//#endregion
|
|
136
|
+
export { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { VariantProps } from "class-variance-authority";
|
|
2
|
+
//#region src/components/ui/empty.d.ts
|
|
3
|
+
declare function Empty({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
|
|
4
|
+
declare function EmptyHeader({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
|
|
5
|
+
declare const emptyMediaVariants: (props?: ({
|
|
6
|
+
variant?: "default" | "icon" | null | undefined;
|
|
7
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
8
|
+
declare function EmptyMedia({ className, variant, ...props }: React.ComponentProps<"div"> & VariantProps<typeof emptyMediaVariants>): import("react").JSX.Element;
|
|
9
|
+
declare function EmptyTitle({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
|
|
10
|
+
declare function EmptyDescription({ className, ...props }: React.ComponentProps<"p">): import("react").JSX.Element;
|
|
11
|
+
declare function EmptyContent({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
|
|
12
|
+
//#endregion
|
|
13
|
+
export { Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle };
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { cn } from "cn";
|
|
3
|
+
import { cva } from "class-variance-authority";
|
|
4
|
+
//#region src/components/ui/empty.tsx
|
|
5
|
+
function Empty({ className, ...props }) {
|
|
6
|
+
return /* @__PURE__ */ jsx("div", {
|
|
7
|
+
"data-slot": "empty",
|
|
8
|
+
className: cn("flex w-full min-w-0 flex-1 flex-col items-center justify-center gap-4 rounded-xl border-dashed p-6 text-center text-balance", className),
|
|
9
|
+
...props
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
function EmptyHeader({ className, ...props }) {
|
|
13
|
+
return /* @__PURE__ */ jsx("div", {
|
|
14
|
+
"data-slot": "empty-header",
|
|
15
|
+
className: cn("flex max-w-sm flex-col items-center gap-1", className),
|
|
16
|
+
...props
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
const emptyMediaVariants = cva("mb-2 flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0", {
|
|
20
|
+
variants: { variant: {
|
|
21
|
+
default: "bg-transparent",
|
|
22
|
+
icon: "flex size-8 shrink-0 items-center justify-center rounded-md bg-muted text-foreground [&_svg:not([class*='size-'])]:size-4"
|
|
23
|
+
} },
|
|
24
|
+
defaultVariants: { variant: "default" }
|
|
25
|
+
});
|
|
26
|
+
function EmptyMedia({ className, variant = "default", ...props }) {
|
|
27
|
+
return /* @__PURE__ */ jsx("div", {
|
|
28
|
+
"data-slot": "empty-icon",
|
|
29
|
+
"data-variant": variant,
|
|
30
|
+
className: cn(emptyMediaVariants({
|
|
31
|
+
variant,
|
|
32
|
+
className
|
|
33
|
+
})),
|
|
34
|
+
...props
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
function EmptyTitle({ className, ...props }) {
|
|
38
|
+
return /* @__PURE__ */ jsx("div", {
|
|
39
|
+
"data-slot": "empty-title",
|
|
40
|
+
className: cn("font-heading text-sm font-medium tracking-tight", className),
|
|
41
|
+
...props
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
function EmptyDescription({ className, ...props }) {
|
|
45
|
+
return /* @__PURE__ */ jsx("div", {
|
|
46
|
+
"data-slot": "empty-description",
|
|
47
|
+
className: cn("text-xs/relaxed text-muted-foreground [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary", className),
|
|
48
|
+
...props
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
function EmptyContent({ className, ...props }) {
|
|
52
|
+
return /* @__PURE__ */ jsx("div", {
|
|
53
|
+
"data-slot": "empty-content",
|
|
54
|
+
className: cn("flex w-full max-w-sm min-w-0 flex-col items-center gap-2 text-xs/relaxed text-balance", className),
|
|
55
|
+
...props
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
//#endregion
|
|
59
|
+
export { Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle };
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { Label } from "./label.js";
|
|
2
|
+
import { VariantProps } from "class-variance-authority";
|
|
3
|
+
//#region src/components/ui/field.d.ts
|
|
4
|
+
declare function FieldSet({ className, ...props }: React.ComponentProps<"fieldset">): import("react").JSX.Element;
|
|
5
|
+
declare function FieldLegend({ className, variant, ...props }: React.ComponentProps<"legend"> & {
|
|
6
|
+
variant?: "legend" | "label";
|
|
7
|
+
}): import("react").JSX.Element;
|
|
8
|
+
declare function FieldGroup({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
|
|
9
|
+
declare const fieldVariants: (props?: ({
|
|
10
|
+
orientation?: "horizontal" | "responsive" | "vertical" | null | undefined;
|
|
11
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
12
|
+
declare function Field({ className, orientation, ...props }: React.ComponentProps<"div"> & VariantProps<typeof fieldVariants>): import("react").JSX.Element;
|
|
13
|
+
declare function FieldContent({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
|
|
14
|
+
declare function FieldLabel({ className, ...props }: React.ComponentProps<typeof Label>): import("react").JSX.Element;
|
|
15
|
+
declare function FieldTitle({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
|
|
16
|
+
declare function FieldDescription({ className, ...props }: React.ComponentProps<"p">): import("react").JSX.Element;
|
|
17
|
+
declare function FieldSeparator({ children, className, ...props }: React.ComponentProps<"div"> & {
|
|
18
|
+
children?: React.ReactNode;
|
|
19
|
+
}): import("react").JSX.Element;
|
|
20
|
+
declare function FieldError({ className, children, errors, ...props }: React.ComponentProps<"div"> & {
|
|
21
|
+
errors?: Array<{
|
|
22
|
+
message?: string;
|
|
23
|
+
} | undefined>;
|
|
24
|
+
}): import("react").JSX.Element | null;
|
|
25
|
+
//#endregion
|
|
26
|
+
export { Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle };
|