@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,21 @@
|
|
|
1
|
+
import { DiffLine } from "./code-diff.js";
|
|
2
|
+
import { ComponentProps } from "react";
|
|
3
|
+
declare namespace reviewable_diff_d_exports {
|
|
4
|
+
export { DiffHunk, HunkDecision, ReviewableDiff };
|
|
5
|
+
}
|
|
6
|
+
export type HunkDecision = "pending" | "kept" | "discarded";
|
|
7
|
+
export interface DiffHunk {
|
|
8
|
+
id: string;
|
|
9
|
+
range: string;
|
|
10
|
+
decision: HunkDecision;
|
|
11
|
+
lines: readonly DiffLine[];
|
|
12
|
+
}
|
|
13
|
+
export declare function ReviewableDiff({ filename, hunks, onKeep, onDiscard, onApply, className, ...props }: Omit<ComponentProps<"div">, "children" | "filename" | "hunks" | "onKeep" | "onDiscard" | "onApply"> & {
|
|
14
|
+
filename: string;
|
|
15
|
+
hunks: readonly DiffHunk[];
|
|
16
|
+
onKeep?: (id: string) => void;
|
|
17
|
+
onDiscard?: (id: string) => void;
|
|
18
|
+
onApply?: () => void;
|
|
19
|
+
}): import("react").JSX.Element;
|
|
20
|
+
//#endregion
|
|
21
|
+
export { reviewable_diff_d_exports };
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { __exportAll } from "../../../_virtual/_rolldown/runtime.js";
|
|
3
|
+
import { cn } from "../../../lib/utils.js";
|
|
4
|
+
import { codeScroll, codeSurface, mono, paper } from "./surfaces.js";
|
|
5
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
+
import { CheckIcon, XIcon } from "lucide-react";
|
|
7
|
+
//#region src/components/assistant-ui/elements/reviewable-diff.tsx
|
|
8
|
+
var reviewable_diff_exports = /* @__PURE__ */ __exportAll({ ReviewableDiff: () => ReviewableDiff });
|
|
9
|
+
const GUTTER = {
|
|
10
|
+
context: "",
|
|
11
|
+
added: "+",
|
|
12
|
+
removed: "−"
|
|
13
|
+
};
|
|
14
|
+
function ReviewableDiff({ filename, hunks, onKeep, onDiscard, onApply, className, ...props }) {
|
|
15
|
+
const kept = hunks.filter((hunk) => hunk.decision === "kept").length;
|
|
16
|
+
const pending = hunks.filter((hunk) => hunk.decision === "pending").length;
|
|
17
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
18
|
+
"data-slot": "reviewable-diff",
|
|
19
|
+
className: cn(paper, "flex w-full max-w-md flex-col overflow-hidden rounded-2xl", className),
|
|
20
|
+
...props,
|
|
21
|
+
children: [
|
|
22
|
+
/* @__PURE__ */ jsxs("div", {
|
|
23
|
+
className: "flex items-center justify-between px-4 pt-3 pb-2",
|
|
24
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
25
|
+
className: "font-mono text-xs",
|
|
26
|
+
children: filename
|
|
27
|
+
}), /* @__PURE__ */ jsxs("span", {
|
|
28
|
+
className: cn(mono, "text-muted-foreground tabular-nums"),
|
|
29
|
+
children: [
|
|
30
|
+
kept,
|
|
31
|
+
" of ",
|
|
32
|
+
hunks.length,
|
|
33
|
+
" kept"
|
|
34
|
+
]
|
|
35
|
+
})]
|
|
36
|
+
}),
|
|
37
|
+
/* @__PURE__ */ jsx("div", {
|
|
38
|
+
className: "flex flex-col",
|
|
39
|
+
children: hunks.map((hunk) => /* @__PURE__ */ jsxs("div", {
|
|
40
|
+
className: "border-foreground/[0.06] border-t",
|
|
41
|
+
children: [/* @__PURE__ */ jsxs("div", {
|
|
42
|
+
className: "flex items-center gap-2 px-4 py-1.5",
|
|
43
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
44
|
+
className: cn(mono, "text-muted-foreground"),
|
|
45
|
+
children: hunk.range
|
|
46
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
47
|
+
className: "ms-auto flex items-center gap-1",
|
|
48
|
+
children: hunk.decision === "pending" && (onKeep || onDiscard) ? /* @__PURE__ */ jsxs(Fragment, { children: [onDiscard && /* @__PURE__ */ jsxs("button", {
|
|
49
|
+
type: "button",
|
|
50
|
+
"aria-label": `Discard hunk ${hunk.range}`,
|
|
51
|
+
onClick: () => onDiscard(hunk.id),
|
|
52
|
+
className: "text-muted-foreground hover:bg-foreground/[0.06] hover:text-foreground/90 flex h-6 items-center gap-1 rounded-full px-2 text-[11px] font-medium transition-[background-color,color,scale] duration-150 active:scale-[0.96]",
|
|
53
|
+
children: [/* @__PURE__ */ jsx(XIcon, { className: "size-3" }), "Discard"]
|
|
54
|
+
}), onKeep && /* @__PURE__ */ jsxs("button", {
|
|
55
|
+
type: "button",
|
|
56
|
+
"aria-label": `Keep hunk ${hunk.range}`,
|
|
57
|
+
onClick: () => onKeep(hunk.id),
|
|
58
|
+
className: "flex h-6 items-center gap-1 rounded-full bg-success/12 px-2 text-[11px] font-medium text-success transition-[background-color,scale] duration-150 hover:bg-success/20 active:scale-[0.96] dark:text-success",
|
|
59
|
+
children: [/* @__PURE__ */ jsx(CheckIcon, { className: "size-3" }), "Keep"]
|
|
60
|
+
})] }) : /* @__PURE__ */ jsx("span", {
|
|
61
|
+
className: cn(mono, "fade-in animate-in duration-300", hunk.decision === "kept" ? "text-success dark:text-success" : "text-muted-foreground"),
|
|
62
|
+
children: hunk.decision
|
|
63
|
+
})
|
|
64
|
+
})]
|
|
65
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
66
|
+
className: cn(codeScroll, "pb-1.5 font-mono text-xs"),
|
|
67
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
68
|
+
className: codeSurface,
|
|
69
|
+
children: hunk.lines.map((line, i) => {
|
|
70
|
+
const body = line.text.trimStart();
|
|
71
|
+
const indent = line.text.slice(0, line.text.length - body.length);
|
|
72
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
73
|
+
className: cn("flex px-4 py-0.5 leading-relaxed whitespace-pre", (line.kind === "context" || hunk.decision === "discarded") && "text-muted-foreground", hunk.decision !== "discarded" && line.kind === "added" && "bg-success/10 text-success dark:text-success", hunk.decision !== "discarded" && line.kind === "removed" && "bg-destructive/10 text-destructive dark:text-destructive"),
|
|
74
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
75
|
+
className: "w-4 shrink-0 select-none",
|
|
76
|
+
children: GUTTER[line.kind]
|
|
77
|
+
}), /* @__PURE__ */ jsxs("span", { children: [indent, /* @__PURE__ */ jsx("span", {
|
|
78
|
+
className: cn(hunk.decision === "discarded" && line.kind !== "context" && "line-through"),
|
|
79
|
+
children: body
|
|
80
|
+
})] })]
|
|
81
|
+
}, `${hunk.id}-${i}`);
|
|
82
|
+
})
|
|
83
|
+
})
|
|
84
|
+
})]
|
|
85
|
+
}, hunk.id))
|
|
86
|
+
}),
|
|
87
|
+
/* @__PURE__ */ jsxs("div", {
|
|
88
|
+
className: "border-foreground/[0.06] flex items-center justify-between border-t px-4 py-2.5",
|
|
89
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
90
|
+
className: cn(mono, "text-muted-foreground"),
|
|
91
|
+
children: pending > 0 ? `${pending} left to review` : "All reviewed"
|
|
92
|
+
}), onApply && /* @__PURE__ */ jsxs("button", {
|
|
93
|
+
type: "button",
|
|
94
|
+
disabled: pending > 0,
|
|
95
|
+
onClick: onApply,
|
|
96
|
+
className: cn("bg-foreground text-background transition-[opacity,scale] duration-150 ease-[cubic-bezier(0.23,1,0.32,1)] hover:opacity-90 active:scale-[0.96] motion-reduce:transition-none", "flex h-7 items-center rounded-full px-3 text-xs font-medium disabled:pointer-events-none disabled:opacity-30"),
|
|
97
|
+
children: ["Apply ", kept]
|
|
98
|
+
})]
|
|
99
|
+
})
|
|
100
|
+
]
|
|
101
|
+
});
|
|
102
|
+
}
|
|
103
|
+
//#endregion
|
|
104
|
+
export { ReviewableDiff, reviewable_diff_exports };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ComponentProps } from "react";
|
|
2
|
+
declare namespace schedule_card_d_exports {
|
|
3
|
+
export { ScheduleCard, ScheduleRun };
|
|
4
|
+
}
|
|
5
|
+
export interface ScheduleRun {
|
|
6
|
+
id: string;
|
|
7
|
+
at: string;
|
|
8
|
+
ok: boolean;
|
|
9
|
+
}
|
|
10
|
+
export declare function ScheduleCard({ name, cadence, nextRun, enabled, history, onToggle, className, ...props }: Omit<ComponentProps<"div">, "children" | "name" | "cadence" | "nextRun" | "enabled" | "history" | "onToggle"> & {
|
|
11
|
+
name: string;
|
|
12
|
+
cadence: string;
|
|
13
|
+
nextRun: string;
|
|
14
|
+
enabled: boolean;
|
|
15
|
+
history: readonly ScheduleRun[];
|
|
16
|
+
onToggle?: () => void;
|
|
17
|
+
}): import("react").JSX.Element;
|
|
18
|
+
//#endregion
|
|
19
|
+
export { schedule_card_d_exports };
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { __exportAll } from "../../../_virtual/_rolldown/runtime.js";
|
|
3
|
+
import { cn } from "../../../lib/utils.js";
|
|
4
|
+
import { field, mono, paper } from "./surfaces.js";
|
|
5
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
+
import { CheckIcon, ClockIcon, XIcon } from "lucide-react";
|
|
7
|
+
//#region src/components/assistant-ui/elements/schedule-card.tsx
|
|
8
|
+
var schedule_card_exports = /* @__PURE__ */ __exportAll({ ScheduleCard: () => ScheduleCard });
|
|
9
|
+
function ScheduleCard({ name, cadence, nextRun, enabled, history, onToggle, className, ...props }) {
|
|
10
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
11
|
+
"data-slot": "schedule-card",
|
|
12
|
+
className: cn(paper, "flex w-full max-w-sm flex-col gap-3 rounded-2xl p-4", className),
|
|
13
|
+
...props,
|
|
14
|
+
children: [
|
|
15
|
+
/* @__PURE__ */ jsxs("div", {
|
|
16
|
+
className: "flex items-center gap-2.5",
|
|
17
|
+
children: [
|
|
18
|
+
/* @__PURE__ */ jsx("span", {
|
|
19
|
+
className: "bg-foreground/[0.05] text-muted-foreground flex size-7 shrink-0 items-center justify-center rounded-lg",
|
|
20
|
+
children: /* @__PURE__ */ jsx(ClockIcon, { className: "size-3.5" })
|
|
21
|
+
}),
|
|
22
|
+
/* @__PURE__ */ jsxs("div", {
|
|
23
|
+
className: "flex min-w-0 flex-1 flex-col",
|
|
24
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
25
|
+
className: "truncate text-[13.5px] font-medium",
|
|
26
|
+
children: name
|
|
27
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
28
|
+
className: cn(mono, "text-muted-foreground"),
|
|
29
|
+
children: cadence
|
|
30
|
+
})]
|
|
31
|
+
}),
|
|
32
|
+
/* @__PURE__ */ jsx("button", {
|
|
33
|
+
type: "button",
|
|
34
|
+
role: "switch",
|
|
35
|
+
"aria-checked": enabled,
|
|
36
|
+
"aria-label": `${enabled ? "Pause" : "Resume"} ${name}`,
|
|
37
|
+
onClick: onToggle,
|
|
38
|
+
className: cn("flex h-5 w-9 shrink-0 items-center rounded-full p-0.5 transition-colors duration-200", enabled ? "bg-foreground/80" : "bg-foreground/15"),
|
|
39
|
+
children: /* @__PURE__ */ jsx("span", { className: cn("size-4 rounded-full transition-transform duration-200 motion-reduce:transition-none", enabled ? "bg-background" : "bg-background dark:bg-foreground", enabled && "translate-x-4") })
|
|
40
|
+
})
|
|
41
|
+
]
|
|
42
|
+
}),
|
|
43
|
+
/* @__PURE__ */ jsxs("div", {
|
|
44
|
+
className: cn(field, "flex items-baseline gap-2 rounded-xl px-3 py-2"),
|
|
45
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
46
|
+
className: cn(mono, "text-muted-foreground"),
|
|
47
|
+
children: "next"
|
|
48
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
49
|
+
className: cn("text-[13px]", enabled ? "text-foreground/80" : "text-muted-foreground"),
|
|
50
|
+
children: enabled ? nextRun : "paused"
|
|
51
|
+
})]
|
|
52
|
+
}),
|
|
53
|
+
/* @__PURE__ */ jsxs("div", {
|
|
54
|
+
className: "flex flex-col gap-1",
|
|
55
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
56
|
+
className: cn(mono, "text-muted-foreground"),
|
|
57
|
+
children: "recent runs"
|
|
58
|
+
}), history.length === 0 ? /* @__PURE__ */ jsx("span", {
|
|
59
|
+
className: "text-muted-foreground text-xs",
|
|
60
|
+
children: "No runs yet"
|
|
61
|
+
}) : history.map((run) => /* @__PURE__ */ jsxs("div", {
|
|
62
|
+
className: "flex items-baseline gap-2",
|
|
63
|
+
children: [
|
|
64
|
+
run.ok ? /* @__PURE__ */ jsx(CheckIcon, { className: "size-3 shrink-0 translate-y-0.5 text-success" }) : /* @__PURE__ */ jsx(XIcon, { className: "size-3 shrink-0 translate-y-0.5 text-destructive" }),
|
|
65
|
+
/* @__PURE__ */ jsx("span", {
|
|
66
|
+
className: "text-muted-foreground min-w-0 flex-1 truncate text-xs",
|
|
67
|
+
children: run.at
|
|
68
|
+
}),
|
|
69
|
+
/* @__PURE__ */ jsx("span", {
|
|
70
|
+
className: cn(mono, "text-muted-foreground shrink-0"),
|
|
71
|
+
children: run.ok ? "ok" : "failed"
|
|
72
|
+
})
|
|
73
|
+
]
|
|
74
|
+
}, run.id))]
|
|
75
|
+
})
|
|
76
|
+
]
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
//#endregion
|
|
80
|
+
export { ScheduleCard, schedule_card_exports };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ComponentProps } from "react";
|
|
2
|
+
declare namespace score_breakdown_d_exports {
|
|
3
|
+
export { ScoreBreakdown, ScoreCriterion };
|
|
4
|
+
}
|
|
5
|
+
export interface ScoreCriterion {
|
|
6
|
+
label: string;
|
|
7
|
+
score: number;
|
|
8
|
+
weight: number;
|
|
9
|
+
note?: string;
|
|
10
|
+
}
|
|
11
|
+
export declare function ScoreBreakdown({ verdict, total, outOf, criteria, visibleCount, className, ...props }: Omit<ComponentProps<"div">, "children" | "verdict" | "total" | "outOf" | "criteria" | "visibleCount"> & {
|
|
12
|
+
verdict: string;
|
|
13
|
+
total: number;
|
|
14
|
+
outOf: number;
|
|
15
|
+
criteria: readonly ScoreCriterion[];
|
|
16
|
+
visibleCount: number;
|
|
17
|
+
}): import("react").JSX.Element;
|
|
18
|
+
//#endregion
|
|
19
|
+
export { score_breakdown_d_exports };
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { __exportAll } from "../../../_virtual/_rolldown/runtime.js";
|
|
3
|
+
import { cn } from "../../../lib/utils.js";
|
|
4
|
+
import { mono, paper } from "./surfaces.js";
|
|
5
|
+
import { announced, pct, take } from "../utils/range.js";
|
|
6
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
+
//#region src/components/assistant-ui/elements/score-breakdown.tsx
|
|
8
|
+
var score_breakdown_exports = /* @__PURE__ */ __exportAll({ ScoreBreakdown: () => ScoreBreakdown });
|
|
9
|
+
function ScoreBreakdown({ verdict, total, outOf, criteria, visibleCount, className, ...props }) {
|
|
10
|
+
const shown = take(criteria, visibleCount);
|
|
11
|
+
const grading = shown.length < criteria.length;
|
|
12
|
+
const ratio = outOf === 0 ? 0 : total / outOf;
|
|
13
|
+
const band = ratio >= .75 ? {
|
|
14
|
+
dot: "bg-success",
|
|
15
|
+
text: "text-success dark:text-success"
|
|
16
|
+
} : ratio >= .5 ? {
|
|
17
|
+
dot: "bg-warning",
|
|
18
|
+
text: "text-warning dark:text-warning"
|
|
19
|
+
} : {
|
|
20
|
+
dot: "bg-destructive",
|
|
21
|
+
text: "text-destructive dark:text-destructive"
|
|
22
|
+
};
|
|
23
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
24
|
+
"data-slot": "score-breakdown",
|
|
25
|
+
"aria-busy": grading || void 0,
|
|
26
|
+
className: cn(paper, "flex w-full max-w-sm flex-col gap-3 rounded-2xl p-4", className),
|
|
27
|
+
...props,
|
|
28
|
+
children: [/* @__PURE__ */ jsxs("div", {
|
|
29
|
+
className: "flex items-baseline gap-2",
|
|
30
|
+
children: [
|
|
31
|
+
grading ? /* @__PURE__ */ jsx("span", {
|
|
32
|
+
"aria-hidden": true,
|
|
33
|
+
className: "bg-foreground/10 h-6 w-10 animate-pulse self-center rounded-md"
|
|
34
|
+
}) : /* @__PURE__ */ jsx("span", {
|
|
35
|
+
className: "text-2xl font-medium tracking-tight tabular-nums",
|
|
36
|
+
children: total.toFixed(1)
|
|
37
|
+
}),
|
|
38
|
+
/* @__PURE__ */ jsxs("span", {
|
|
39
|
+
className: cn(mono, "text-muted-foreground tabular-nums"),
|
|
40
|
+
children: ["/ ", outOf]
|
|
41
|
+
}),
|
|
42
|
+
grading ? /* @__PURE__ */ jsxs("span", {
|
|
43
|
+
className: "text-muted-foreground ms-auto flex items-center gap-1.5 text-xs font-medium",
|
|
44
|
+
children: [
|
|
45
|
+
/* @__PURE__ */ jsx("span", {
|
|
46
|
+
"aria-hidden": true,
|
|
47
|
+
className: "bg-muted-foreground/50 size-1.5 animate-pulse rounded-full"
|
|
48
|
+
}),
|
|
49
|
+
"Grading ",
|
|
50
|
+
shown.length,
|
|
51
|
+
" of ",
|
|
52
|
+
criteria.length
|
|
53
|
+
]
|
|
54
|
+
}) : /* @__PURE__ */ jsxs("span", {
|
|
55
|
+
className: cn("ms-auto flex items-center gap-1.5 text-xs font-medium", band.text),
|
|
56
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
57
|
+
"aria-hidden": true,
|
|
58
|
+
className: cn("size-1.5 rounded-full", band.dot)
|
|
59
|
+
}), verdict]
|
|
60
|
+
})
|
|
61
|
+
]
|
|
62
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
63
|
+
className: "flex flex-col gap-2",
|
|
64
|
+
children: shown.map((criterion) => /* @__PURE__ */ jsxs("div", {
|
|
65
|
+
className: "fade-in slide-in-from-bottom-1 animate-in fill-mode-both flex flex-col gap-1 duration-300",
|
|
66
|
+
children: [
|
|
67
|
+
/* @__PURE__ */ jsxs("div", {
|
|
68
|
+
className: "flex items-baseline gap-2",
|
|
69
|
+
children: [
|
|
70
|
+
/* @__PURE__ */ jsx("span", {
|
|
71
|
+
className: "text-foreground/75 min-w-0 flex-1 truncate text-[13px]",
|
|
72
|
+
children: criterion.label
|
|
73
|
+
}),
|
|
74
|
+
/* @__PURE__ */ jsxs("span", {
|
|
75
|
+
className: cn(mono, "text-muted-foreground shrink-0"),
|
|
76
|
+
children: ["×", criterion.weight]
|
|
77
|
+
}),
|
|
78
|
+
/* @__PURE__ */ jsx("span", {
|
|
79
|
+
className: cn(mono, "text-muted-foreground shrink-0 tabular-nums"),
|
|
80
|
+
children: criterion.score.toFixed(1)
|
|
81
|
+
})
|
|
82
|
+
]
|
|
83
|
+
}),
|
|
84
|
+
/* @__PURE__ */ jsx("span", {
|
|
85
|
+
role: "meter",
|
|
86
|
+
"aria-label": `${criterion.label} score`,
|
|
87
|
+
"aria-valuemin": 0,
|
|
88
|
+
"aria-valuemax": 100,
|
|
89
|
+
"aria-valuenow": announced(pct(criterion.score, outOf)),
|
|
90
|
+
"aria-valuetext": `${criterion.score.toFixed(1)} of ${outOf}`,
|
|
91
|
+
className: "bg-foreground/[0.06] h-[3px] w-full overflow-hidden rounded-full",
|
|
92
|
+
children: /* @__PURE__ */ jsx("span", {
|
|
93
|
+
className: "block h-full rounded-full bg-info transition-[width] duration-500 motion-reduce:transition-none dark:bg-info",
|
|
94
|
+
style: { width: `${pct(criterion.score, outOf)}%` }
|
|
95
|
+
})
|
|
96
|
+
}),
|
|
97
|
+
criterion.note && /* @__PURE__ */ jsx("span", {
|
|
98
|
+
className: "text-muted-foreground text-xs leading-relaxed break-words",
|
|
99
|
+
children: criterion.note
|
|
100
|
+
})
|
|
101
|
+
]
|
|
102
|
+
}, criterion.label))
|
|
103
|
+
})]
|
|
104
|
+
});
|
|
105
|
+
}
|
|
106
|
+
//#endregion
|
|
107
|
+
export { ScoreBreakdown, score_breakdown_exports };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ComponentProps } from "react";
|
|
2
|
+
declare namespace scroll_anchor_d_exports {
|
|
3
|
+
export { ScrollAnchor, ScrollAnchorMessage };
|
|
4
|
+
}
|
|
5
|
+
export interface ScrollAnchorMessage {
|
|
6
|
+
role: "user" | "assistant";
|
|
7
|
+
text: string;
|
|
8
|
+
}
|
|
9
|
+
export declare function ScrollAnchor({ messages, paused, onSettled, className, ...props }: Omit<ComponentProps<"div">, "children" | "messages" | "paused" | "onSettled"> & {
|
|
10
|
+
messages: ScrollAnchorMessage[];
|
|
11
|
+
paused?: boolean;
|
|
12
|
+
onSettled?: () => void;
|
|
13
|
+
}): import("react").JSX.Element;
|
|
14
|
+
//#endregion
|
|
15
|
+
export { scroll_anchor_d_exports };
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { __exportAll } from "../../../_virtual/_rolldown/runtime.js";
|
|
3
|
+
import { cn } from "../../../lib/utils.js";
|
|
4
|
+
import { field, paper } from "./surfaces.js";
|
|
5
|
+
import { useCallback, useEffect, useRef, useState } from "react";
|
|
6
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
+
import { ArrowDownIcon } from "lucide-react";
|
|
8
|
+
//#region src/components/assistant-ui/elements/scroll-anchor.tsx
|
|
9
|
+
var scroll_anchor_exports = /* @__PURE__ */ __exportAll({ ScrollAnchor: () => ScrollAnchor });
|
|
10
|
+
const INITIAL_COUNT = 3;
|
|
11
|
+
const APPEND_MS = 1300;
|
|
12
|
+
function ScrollAnchor({ messages, paused = false, onSettled, className, ...props }) {
|
|
13
|
+
const viewportRef = useRef(null);
|
|
14
|
+
const [count, setCount] = useState(INITIAL_COUNT);
|
|
15
|
+
const [pinned, setPinned] = useState(true);
|
|
16
|
+
const [seenCount, setSeenCount] = useState(INITIAL_COUNT);
|
|
17
|
+
useEffect(() => {
|
|
18
|
+
if (paused) return;
|
|
19
|
+
const id = setInterval(() => {
|
|
20
|
+
setCount((current) => {
|
|
21
|
+
if (current >= messages.length) return current;
|
|
22
|
+
return current + 1;
|
|
23
|
+
});
|
|
24
|
+
}, APPEND_MS);
|
|
25
|
+
return () => clearInterval(id);
|
|
26
|
+
}, [messages.length, paused]);
|
|
27
|
+
useEffect(() => {
|
|
28
|
+
if (count >= messages.length && pinned) onSettled?.();
|
|
29
|
+
}, [
|
|
30
|
+
count,
|
|
31
|
+
pinned,
|
|
32
|
+
messages.length,
|
|
33
|
+
onSettled
|
|
34
|
+
]);
|
|
35
|
+
useEffect(() => {
|
|
36
|
+
if (count === 4) {
|
|
37
|
+
setPinned(false);
|
|
38
|
+
setSeenCount(count);
|
|
39
|
+
const viewport = viewportRef.current;
|
|
40
|
+
if (viewport) viewport.scrollTo({
|
|
41
|
+
top: 0,
|
|
42
|
+
behavior: "smooth"
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
}, [count]);
|
|
46
|
+
useEffect(() => {
|
|
47
|
+
if (!pinned) return;
|
|
48
|
+
const viewport = viewportRef.current;
|
|
49
|
+
if (viewport) viewport.scrollTo({ top: viewport.scrollHeight });
|
|
50
|
+
}, [count, pinned]);
|
|
51
|
+
const jump = useCallback(() => {
|
|
52
|
+
const viewport = viewportRef.current;
|
|
53
|
+
if (viewport) viewport.scrollTo({
|
|
54
|
+
top: viewport.scrollHeight,
|
|
55
|
+
behavior: "smooth"
|
|
56
|
+
});
|
|
57
|
+
setPinned(true);
|
|
58
|
+
setSeenCount(count);
|
|
59
|
+
}, [count]);
|
|
60
|
+
useEffect(() => {
|
|
61
|
+
if (paused || pinned || count - seenCount < 2) return;
|
|
62
|
+
const id = setTimeout(jump, 2400);
|
|
63
|
+
return () => clearTimeout(id);
|
|
64
|
+
}, [
|
|
65
|
+
paused,
|
|
66
|
+
pinned,
|
|
67
|
+
count,
|
|
68
|
+
seenCount,
|
|
69
|
+
jump
|
|
70
|
+
]);
|
|
71
|
+
const newCount = pinned ? 0 : count - seenCount;
|
|
72
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
73
|
+
"data-slot": "scroll-anchor",
|
|
74
|
+
className: cn(paper, "relative h-64 w-full max-w-sm overflow-hidden rounded-2xl", className),
|
|
75
|
+
...props,
|
|
76
|
+
children: [
|
|
77
|
+
/* @__PURE__ */ jsx("div", {
|
|
78
|
+
ref: viewportRef,
|
|
79
|
+
className: "flex h-full flex-col gap-2.5 overflow-y-hidden scroll-smooth p-4",
|
|
80
|
+
children: messages.slice(0, count).map((message, i) => /* @__PURE__ */ jsx("div", {
|
|
81
|
+
className: cn("fade-in slide-in-from-bottom-1 animate-in text-xs leading-relaxed duration-300 motion-reduce:animate-none", message.role === "user" ? cn(field, "max-w-[85%] self-end rounded-2xl px-3 py-1.5") : "text-muted-foreground self-start"),
|
|
82
|
+
children: message.text
|
|
83
|
+
}, i))
|
|
84
|
+
}),
|
|
85
|
+
/* @__PURE__ */ jsx("div", {
|
|
86
|
+
"aria-hidden": true,
|
|
87
|
+
className: "from-background dark:from-popover pointer-events-none absolute inset-x-0 top-0 h-6 bg-gradient-to-b to-transparent"
|
|
88
|
+
}),
|
|
89
|
+
!pinned && newCount > 0 && /* @__PURE__ */ jsxs("button", {
|
|
90
|
+
type: "button",
|
|
91
|
+
onClick: jump,
|
|
92
|
+
className: cn("bg-popover border border-border shadow-lg", "fade-in slide-in-from-bottom-2 animate-in absolute inset-x-0 bottom-3 mx-auto flex w-fit items-center gap-1.5 rounded-full px-3.5 py-1.5 text-xs transition-transform duration-200 hover:-translate-y-px"),
|
|
93
|
+
children: [
|
|
94
|
+
/* @__PURE__ */ jsx(ArrowDownIcon, { className: "size-3 opacity-60" }),
|
|
95
|
+
newCount,
|
|
96
|
+
" new ",
|
|
97
|
+
newCount === 1 ? "message" : "messages"
|
|
98
|
+
]
|
|
99
|
+
})
|
|
100
|
+
]
|
|
101
|
+
});
|
|
102
|
+
}
|
|
103
|
+
//#endregion
|
|
104
|
+
export { ScrollAnchor, scroll_anchor_exports };
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { ComponentProps } from "react";
|
|
2
|
+
declare namespace settings_panel_d_exports {
|
|
3
|
+
export { SettingToggle, SettingsPanel };
|
|
4
|
+
}
|
|
5
|
+
export interface SettingToggle {
|
|
6
|
+
key: string;
|
|
7
|
+
label: string;
|
|
8
|
+
detail: string;
|
|
9
|
+
on: boolean;
|
|
10
|
+
}
|
|
11
|
+
export declare function SettingsPanel({ model, models, systemPrompt, temperature, toggles, onModelChange, onSystemPromptChange, onTemperatureChange, onToggle, className, ...props }: Omit<ComponentProps<"div">, "children" | "model" | "models" | "systemPrompt" | "temperature" | "toggles" | "onModelChange" | "onSystemPromptChange" | "onTemperatureChange" | "onToggle"> & {
|
|
12
|
+
model: string;
|
|
13
|
+
models: readonly string[];
|
|
14
|
+
systemPrompt: string;
|
|
15
|
+
temperature: number;
|
|
16
|
+
toggles: readonly SettingToggle[];
|
|
17
|
+
onModelChange?: (model: string) => void;
|
|
18
|
+
onSystemPromptChange?: (prompt: string) => void;
|
|
19
|
+
onTemperatureChange?: (temperature: number) => void;
|
|
20
|
+
onToggle?: (key: string) => void;
|
|
21
|
+
}): import("react").JSX.Element;
|
|
22
|
+
//#endregion
|
|
23
|
+
export { settings_panel_d_exports };
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { __exportAll } from "../../../_virtual/_rolldown/runtime.js";
|
|
3
|
+
import { cn } from "../../../lib/utils.js";
|
|
4
|
+
import { field, mono, paper } from "./surfaces.js";
|
|
5
|
+
import { clamp } from "../utils/range.js";
|
|
6
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
+
//#region src/components/assistant-ui/elements/settings-panel.tsx
|
|
8
|
+
var settings_panel_exports = /* @__PURE__ */ __exportAll({ SettingsPanel: () => SettingsPanel });
|
|
9
|
+
function SettingsPanel({ model, models, systemPrompt, temperature, toggles, onModelChange, onSystemPromptChange, onTemperatureChange, onToggle, className, ...props }) {
|
|
10
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
11
|
+
"data-slot": "settings-panel",
|
|
12
|
+
className: cn(paper, "flex w-full max-w-sm flex-col gap-4 rounded-[20px] p-4", className),
|
|
13
|
+
...props,
|
|
14
|
+
children: [
|
|
15
|
+
/* @__PURE__ */ jsxs("div", {
|
|
16
|
+
className: "flex flex-col gap-1.5",
|
|
17
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
18
|
+
className: cn(mono, "text-muted-foreground"),
|
|
19
|
+
children: "model"
|
|
20
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
21
|
+
className: cn(field, "flex gap-0.5 rounded-full p-0.5"),
|
|
22
|
+
children: models.map((option) => {
|
|
23
|
+
const className = cn("flex-1 rounded-full py-1 text-center text-xs font-medium transition-[background-color,color,scale] duration-150", onModelChange && "active:scale-[0.97]", option === model ? "bg-background text-foreground/90" : onModelChange ? "text-muted-foreground hover:text-muted-foreground" : "text-muted-foreground");
|
|
24
|
+
return onModelChange ? /* @__PURE__ */ jsx("button", {
|
|
25
|
+
type: "button",
|
|
26
|
+
"aria-pressed": option === model,
|
|
27
|
+
onClick: () => onModelChange(option),
|
|
28
|
+
className,
|
|
29
|
+
children: option
|
|
30
|
+
}, option) : /* @__PURE__ */ jsx("span", {
|
|
31
|
+
"aria-current": option === model ? "true" : void 0,
|
|
32
|
+
className,
|
|
33
|
+
children: option
|
|
34
|
+
}, option);
|
|
35
|
+
})
|
|
36
|
+
})]
|
|
37
|
+
}),
|
|
38
|
+
/* @__PURE__ */ jsxs("div", {
|
|
39
|
+
className: "flex flex-col gap-1.5",
|
|
40
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
41
|
+
className: cn(mono, "text-muted-foreground"),
|
|
42
|
+
children: "system prompt"
|
|
43
|
+
}), /* @__PURE__ */ jsx("textarea", {
|
|
44
|
+
value: systemPrompt,
|
|
45
|
+
onChange: (event) => onSystemPromptChange?.(event.target.value),
|
|
46
|
+
rows: 3,
|
|
47
|
+
"aria-label": "System prompt",
|
|
48
|
+
className: cn(field, "text-foreground/80 focus-visible:ring-foreground/20 resize-none rounded-xl px-3 py-2 text-xs leading-relaxed outline-none focus-visible:ring-1")
|
|
49
|
+
})]
|
|
50
|
+
}),
|
|
51
|
+
/* @__PURE__ */ jsxs("div", {
|
|
52
|
+
className: "flex flex-col gap-1.5",
|
|
53
|
+
children: [/* @__PURE__ */ jsxs("span", {
|
|
54
|
+
className: "flex items-baseline justify-between",
|
|
55
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
56
|
+
className: cn(mono, "text-muted-foreground"),
|
|
57
|
+
children: "temperature"
|
|
58
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
59
|
+
className: cn(mono, "text-muted-foreground tabular-nums"),
|
|
60
|
+
children: clamp(temperature, 0, 2).toFixed(1)
|
|
61
|
+
})]
|
|
62
|
+
}), /* @__PURE__ */ jsx("input", {
|
|
63
|
+
type: "range",
|
|
64
|
+
min: 0,
|
|
65
|
+
max: 2,
|
|
66
|
+
step: .1,
|
|
67
|
+
value: clamp(temperature, 0, 2),
|
|
68
|
+
"aria-label": "Temperature",
|
|
69
|
+
onChange: (event) => onTemperatureChange?.(Number(event.target.value)),
|
|
70
|
+
className: "accent-foreground/80 h-1 w-full cursor-pointer"
|
|
71
|
+
})]
|
|
72
|
+
}),
|
|
73
|
+
/* @__PURE__ */ jsx("div", {
|
|
74
|
+
className: "flex flex-col gap-2.5",
|
|
75
|
+
children: toggles.map((toggle) => /* @__PURE__ */ jsxs("div", {
|
|
76
|
+
className: "flex items-center gap-3",
|
|
77
|
+
children: [/* @__PURE__ */ jsxs("span", {
|
|
78
|
+
className: "flex min-w-0 flex-1 flex-col",
|
|
79
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
80
|
+
className: "truncate text-[13px]",
|
|
81
|
+
children: toggle.label
|
|
82
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
83
|
+
className: "text-muted-foreground truncate text-xs",
|
|
84
|
+
children: toggle.detail
|
|
85
|
+
})]
|
|
86
|
+
}), onToggle ? /* @__PURE__ */ jsx("button", {
|
|
87
|
+
type: "button",
|
|
88
|
+
role: "switch",
|
|
89
|
+
"aria-checked": toggle.on,
|
|
90
|
+
"aria-label": toggle.label,
|
|
91
|
+
onClick: () => onToggle(toggle.key),
|
|
92
|
+
className: cn("flex h-5 w-9 shrink-0 items-center rounded-full p-0.5 transition-colors duration-200", toggle.on ? "bg-foreground/80" : "bg-foreground/15"),
|
|
93
|
+
children: /* @__PURE__ */ jsx("span", { className: cn("size-4 rounded-full transition-transform duration-200 motion-reduce:transition-none", toggle.on ? "bg-background" : "bg-background dark:bg-foreground", toggle.on && "translate-x-4") })
|
|
94
|
+
}) : /* @__PURE__ */ jsx("span", {
|
|
95
|
+
role: "switch",
|
|
96
|
+
"aria-checked": toggle.on,
|
|
97
|
+
"aria-disabled": "true",
|
|
98
|
+
"aria-label": toggle.label,
|
|
99
|
+
className: cn("flex h-5 w-9 shrink-0 items-center rounded-full p-0.5 opacity-50 cursor-not-allowed", toggle.on ? "bg-foreground/80" : "bg-foreground/15"),
|
|
100
|
+
children: /* @__PURE__ */ jsx("span", { className: cn("size-4 rounded-full", toggle.on ? "bg-background" : "bg-background dark:bg-foreground", toggle.on && "translate-x-4") })
|
|
101
|
+
})]
|
|
102
|
+
}, toggle.key))
|
|
103
|
+
})
|
|
104
|
+
]
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
//#endregion
|
|
108
|
+
export { SettingsPanel, settings_panel_exports };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ComponentProps } from "react";
|
|
2
|
+
declare namespace shared_conversation_d_exports {
|
|
3
|
+
export { SharedConversation, SharedTurn };
|
|
4
|
+
}
|
|
5
|
+
export interface SharedTurn {
|
|
6
|
+
id: string;
|
|
7
|
+
role: "user" | "assistant";
|
|
8
|
+
text: string;
|
|
9
|
+
}
|
|
10
|
+
export declare function SharedConversation({ title, sharedBy, sharedAt, turns, onContinue, className, ...props }: Omit<ComponentProps<"div">, "children" | "title" | "sharedBy" | "sharedAt" | "turns" | "onContinue"> & {
|
|
11
|
+
title: string;
|
|
12
|
+
sharedBy: string;
|
|
13
|
+
sharedAt: string;
|
|
14
|
+
turns: readonly SharedTurn[];
|
|
15
|
+
onContinue?: () => void;
|
|
16
|
+
}): import("react").JSX.Element;
|
|
17
|
+
//#endregion
|
|
18
|
+
export { shared_conversation_d_exports };
|