@alexgorbatchev/shadcn 0.0.18 → 0.0.20
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/README.md +32 -9
- package/dist/{chunk-q2ewq67a.js → chunk-02qymemz.js} +1 -1
- package/dist/{chunk-q9qm7skj.js → chunk-0ewzb2ax.js} +4 -4
- package/dist/{chunk-rrd9fsz6.js → chunk-14qj6w54.js} +5 -5
- package/dist/{chunk-yn3e9w1j.js → chunk-1c5jjkhw.js} +1 -1
- package/dist/{chunk-6aqm34nb.js → chunk-1qhf8gh8.js} +4 -3
- package/dist/{chunk-tsekdy3w.js → chunk-1tgrhacr.js} +12 -3
- package/dist/{chunk-zgpdhtkw.js → chunk-21x1n6gn.js} +6 -6
- package/dist/{chunk-22678d2t.js → chunk-24pefkd5.js} +1 -1
- package/dist/{chunk-msave608.js → chunk-2bx2r98r.js} +1 -1
- package/dist/{chunk-41wykzq3.js → chunk-2tmvz090.js} +1 -1
- package/dist/{chunk-gknaq8ep.js → chunk-3d9v39ga.js} +1 -1
- package/dist/{chunk-2b9agdrf.js → chunk-3dyqen8w.js} +1 -1
- package/dist/{chunk-f63f8w58.js → chunk-3jrsp186.js} +1 -1
- package/dist/{chunk-njzam0hx.js → chunk-3qqdfft7.js} +1 -0
- package/dist/{chunk-gfm2arhj.js → chunk-43hfchxf.js} +1 -1
- package/dist/{chunk-6xr41wyr.js → chunk-46jdxdzy.js} +3 -3
- package/dist/{chunk-x7z9jzyf.js → chunk-4djw71cv.js} +22 -12
- package/dist/{chunk-fh3nme7f.js → chunk-4drqqqz1.js} +1 -1
- package/dist/{chunk-mjpc4qf7.js → chunk-52e8a05a.js} +1 -1
- package/dist/{chunk-1hbge1cb.js → chunk-553bzh59.js} +1 -1
- package/dist/{chunk-a6e11wj6.js → chunk-5ayp2vkw.js} +1 -1
- package/dist/{chunk-19441s27.js → chunk-5pvyxayg.js} +2 -2
- package/dist/{chunk-vx7c2xhq.js → chunk-5v4typ39.js} +3 -3
- package/dist/{chunk-gt8m0zeq.js → chunk-5wndb6hx.js} +1 -1
- package/dist/{chunk-550z7s64.js → chunk-6432235c.js} +3 -3
- package/dist/{chunk-0xrvhezs.js → chunk-6f3qpy7v.js} +1 -1
- package/dist/{chunk-2gten6a1.js → chunk-6wvhq8wq.js} +2 -2
- package/dist/{chunk-zhnwybhq.js → chunk-70vndezn.js} +16 -5
- package/dist/{chunk-r7fy89jq.js → chunk-79667fz5.js} +3 -3
- package/dist/{chunk-4gby2v61.js → chunk-7pyt4e5t.js} +1 -1
- package/dist/{chunk-c6nvc3ft.js → chunk-84ca0dpc.js} +2 -2
- package/dist/{chunk-9msk1t9e.js → chunk-8a15x4a8.js} +1 -1
- package/dist/{chunk-0qcknj5n.js → chunk-8fcjx3he.js} +5 -5
- package/dist/{chunk-h8awhm19.js → chunk-96wh7ccv.js} +1 -1
- package/dist/{chunk-pe1vvkp7.js → chunk-9jct7hv0.js} +3 -3
- package/dist/{chunk-xqn8mef3.js → chunk-a6kyjjfk.js} +1 -0
- package/dist/chunk-aa7m22zj.js +22 -0
- package/dist/{chunk-h77yk9sn.js → chunk-bcpy6gpz.js} +1 -1
- package/dist/chunk-bygq5yqf.js +139 -0
- package/dist/{chunk-2m0zpzbm.js → chunk-cn81dnqb.js} +1 -0
- package/dist/{chunk-m1a9e1py.js → chunk-d2z4gebj.js} +1 -1
- package/dist/{chunk-mx21wpq0.js → chunk-d4bm5rzy.js} +12 -2
- package/dist/{chunk-jy6nfnbx.js → chunk-d9jbqd99.js} +2 -2
- package/dist/{chunk-3hvpcsb4.js → chunk-dgkj6442.js} +1 -1
- package/dist/{chunk-wwfj7ga3.js → chunk-djm7qq62.js} +1 -1
- package/dist/{chunk-9dw4dyzq.js → chunk-e0pv0me5.js} +1 -1
- package/dist/{chunk-dd53t01w.js → chunk-ecmk3vgd.js} +1 -1
- package/dist/{chunk-0yqwq0ev.js → chunk-eq88qk1d.js} +10 -10
- package/dist/{chunk-jq6tc65r.js → chunk-f5hphka1.js} +7 -1
- package/dist/{chunk-7g39g3h8.js → chunk-fb6h4fzt.js} +1 -1
- package/dist/{chunk-fq8taatb.js → chunk-fba5hr7b.js} +1 -1
- package/dist/{chunk-3esarnmt.js → chunk-g03nphs1.js} +1 -1
- package/dist/{chunk-jxwfkmdh.js → chunk-gabqzfq0.js} +3 -3
- package/dist/{chunk-zcwynyr0.js → chunk-gykrcxd1.js} +1 -0
- package/dist/{chunk-xvs5y4v7.js → chunk-h979cxnh.js} +15 -4
- package/dist/{chunk-m54kq3he.js → chunk-hh43wg05.js} +22 -12
- package/dist/{chunk-6hbx647r.js → chunk-j4gd5awk.js} +6 -6
- package/dist/{chunk-j5wk4ffj.js → chunk-jba22682.js} +3 -3
- package/dist/{chunk-5h7vkgvz.js → chunk-jf0y740b.js} +1 -1
- package/dist/{chunk-avrh238b.js → chunk-jpamrhdk.js} +1 -1
- package/dist/{chunk-gyg2s982.js → chunk-k4qz4q7r.js} +1 -0
- package/dist/{chunk-erpzgt57.js → chunk-kv1akmf5.js} +1 -1
- package/dist/{chunk-2g0zzx6f.js → chunk-m2ct74my.js} +1 -0
- package/dist/{chunk-34ndz1gf.js → chunk-mrrbycgx.js} +3 -3
- package/dist/chunk-mz3e810d.js +83 -0
- package/dist/{chunk-serw27sv.js → chunk-nkw2vsf3.js} +1 -0
- package/dist/{chunk-wf5cnpdg.js → chunk-p45ytcc2.js} +3 -3
- package/dist/{chunk-86211e5a.js → chunk-p8gshf3k.js} +1 -1
- package/dist/{chunk-dnja1pz5.js → chunk-p8qtk151.js} +1 -1
- package/dist/{chunk-3552jz55.js → chunk-qcsxnn16.js} +1 -0
- package/dist/{chunk-q40gqpwh.js → chunk-qgjjcmpa.js} +1 -1
- package/dist/{chunk-jwajmmfb.js → chunk-qv19jhdk.js} +1 -1
- package/dist/{chunk-1x2ch0xc.js → chunk-rffrerg5.js} +3 -1
- package/dist/{chunk-hhvp5352.js → chunk-s46hvhjw.js} +1 -1
- package/dist/{chunk-h561m2ae.js → chunk-s83v0taa.js} +1 -1
- package/dist/{chunk-emasqc8x.js → chunk-sat9hjv7.js} +1 -1
- package/dist/{chunk-ets9h67e.js → chunk-tea1nrwn.js} +2 -2
- package/dist/{chunk-47xfhw4f.js → chunk-v9r6t8bz.js} +1 -0
- package/dist/{chunk-48b1ya7g.js → chunk-ve9gpkxd.js} +1 -1
- package/dist/{chunk-jacxpetf.js → chunk-vjtbpkht.js} +2 -2
- package/dist/{chunk-1apg76a7.js → chunk-vq8nc5xa.js} +1 -1
- package/dist/{chunk-55bcw5ff.js → chunk-w1w71edg.js} +1 -0
- package/dist/{chunk-9zyam2cn.js → chunk-wkpf4bv7.js} +1 -1
- package/dist/{chunk-ed49y20r.js → chunk-ws4y7ctw.js} +1 -1
- package/dist/{chunk-ha24sd50.js → chunk-ykt5sv7n.js} +1 -1
- package/dist/{chunk-yncp9nsv.js → chunk-z4jpedvh.js} +1 -0
- package/dist/{chunk-b12s32e3.js → chunk-zj06vvcz.js} +1 -1
- package/dist/{chunk-5h6m9dsm.js → chunk-ztcbee24.js} +1 -1
- package/dist/components/AlertDialog.d.ts +1 -1
- package/dist/components/ButtonLink.d.ts +12 -0
- package/dist/components/Card.d.ts +6 -2
- package/dist/components/ContextMenu.d.ts +1 -1
- package/dist/components/DensityProvider.d.ts +9 -4
- package/dist/components/Dialog.d.ts +1 -1
- package/dist/components/Drawer.d.ts +1 -1
- package/dist/components/DropdownMenu.d.ts +1 -1
- package/dist/components/ScrollGuard.d.ts +6 -0
- package/dist/components/Toast.d.ts +1 -1
- package/dist/components/assistant-ui/elements/AgentCard.js +1 -1
- package/dist/components/assistant-ui/elements/ApprovalCard.js +1 -1
- package/dist/components/assistant-ui/elements/ArtifactCard.js +1 -1
- package/dist/components/assistant-ui/elements/BackgroundInbox.js +2 -2
- package/dist/components/assistant-ui/elements/Chart.js +2 -2
- package/dist/components/assistant-ui/elements/ChatPanel.js +1 -1
- package/dist/components/assistant-ui/elements/Citation.js +3 -2
- package/dist/components/assistant-ui/elements/CodeDiff.js +2 -2
- package/dist/components/assistant-ui/elements/CommandPalette.js +4 -3
- package/dist/components/assistant-ui/elements/ComparisonCard.js +1 -1
- package/dist/components/assistant-ui/elements/ComposerContext.js +3 -2
- package/dist/components/assistant-ui/elements/ContextDisplay.js +9 -8
- package/dist/components/assistant-ui/elements/ContextDisplayBar.js +6 -5
- package/dist/components/assistant-ui/elements/ContextDisplayContent.js +3 -2
- package/dist/components/assistant-ui/elements/ContextDisplayRing.js +6 -5
- package/dist/components/assistant-ui/elements/ContextDisplayRoot.js +3 -2
- package/dist/components/assistant-ui/elements/ContextDisplayText.js +6 -5
- package/dist/components/assistant-ui/elements/ContextDisplayTrigger.js +3 -2
- package/dist/components/assistant-ui/elements/ConversationMap.js +3 -2
- package/dist/components/assistant-ui/elements/DataTable.js +2 -2
- package/dist/components/assistant-ui/elements/EditMessage.js +2 -2
- package/dist/components/assistant-ui/elements/ElicitationForm.js +2 -2
- package/dist/components/assistant-ui/elements/FeedbackDialog.js +2 -2
- package/dist/components/assistant-ui/elements/FileTree.js +2 -2
- package/dist/components/assistant-ui/elements/FlowGraph.js +2 -2
- package/dist/components/assistant-ui/elements/GenerativeUi.js +5 -4
- package/dist/components/assistant-ui/elements/Image.js +3 -2
- package/dist/components/assistant-ui/elements/ImageGallery.js +3 -2
- package/dist/components/assistant-ui/elements/MarkdownText.js +4 -3
- package/dist/components/assistant-ui/elements/McpServerPanel.js +2 -2
- package/dist/components/assistant-ui/elements/MermaidDiagram.js +4 -3
- package/dist/components/assistant-ui/elements/MermaidZoom.js +3 -2
- package/dist/components/assistant-ui/elements/ModelPicker.js +2 -2
- package/dist/components/assistant-ui/elements/ModelSelector.js +13 -12
- package/dist/components/assistant-ui/elements/ModelSelectorContent.js +10 -9
- package/dist/components/assistant-ui/elements/ModelSelectorEmpty.js +4 -3
- package/dist/components/assistant-ui/elements/ModelSelectorFocusAnchor.js +4 -3
- package/dist/components/assistant-ui/elements/ModelSelectorGroup.js +4 -3
- package/dist/components/assistant-ui/elements/ModelSelectorItem.js +4 -3
- package/dist/components/assistant-ui/elements/ModelSelectorList.js +6 -5
- package/dist/components/assistant-ui/elements/ModelSelectorRoot.js +3 -2
- package/dist/components/assistant-ui/elements/ModelSelectorSearch.js +4 -3
- package/dist/components/assistant-ui/elements/ModelSelectorSeparator.js +4 -3
- package/dist/components/assistant-ui/elements/ModelSelectorTrigger.js +3 -2
- package/dist/components/assistant-ui/elements/ReasoningPanel.js +1 -1
- package/dist/components/assistant-ui/elements/RecommendationCard.js +1 -1
- package/dist/components/assistant-ui/elements/RegenerateMenu.js +3 -2
- package/dist/components/assistant-ui/elements/ScheduleCard.js +1 -1
- package/dist/components/assistant-ui/elements/ScrollAnchor.js +1 -1
- package/dist/components/assistant-ui/elements/SettingsPanel.js +1 -1
- package/dist/components/assistant-ui/elements/SpecSheet.js +1 -1
- package/dist/components/assistant-ui/elements/TaskCard.js +1 -1
- package/dist/components/assistant-ui/elements/TooltipIconButton.js +3 -2
- package/dist/components/assistant-ui/index.js +61 -60
- package/dist/components/assistant-ui/native/AssistantModal.js +11 -10
- package/dist/components/assistant-ui/native/AssistantSidebar.js +11 -10
- package/dist/components/assistant-ui/native/AttachmentPreview.js +5 -4
- package/dist/components/assistant-ui/native/ComposerTriggerPopover.js +1 -1
- package/dist/components/assistant-ui/native/ContextDisplay.js +11 -10
- package/dist/components/assistant-ui/native/ContextDisplayBar.js +8 -7
- package/dist/components/assistant-ui/native/ContextDisplayRing.js +8 -7
- package/dist/components/assistant-ui/native/ContextDisplayRoot.js +5 -4
- package/dist/components/assistant-ui/native/ContextDisplayRuntimeRoot.js +4 -3
- package/dist/components/assistant-ui/native/ContextDisplayText.js +8 -7
- package/dist/components/assistant-ui/native/ConversationMapAui.js +4 -3
- package/dist/components/assistant-ui/native/McpConfigDialog.js +3 -2
- package/dist/components/assistant-ui/native/MermaidDiagram.js +5 -4
- package/dist/components/assistant-ui/native/MessageTiming.js +3 -2
- package/dist/components/assistant-ui/native/ModelSelector.js +15 -14
- package/dist/components/assistant-ui/native/Reasoning.js +5 -4
- package/dist/components/assistant-ui/native/TaskCard.js +6 -5
- package/dist/components/assistant-ui/native/TaskGroup.js +7 -6
- package/dist/components/assistant-ui/native/TaskTray.js +3 -2
- package/dist/components/assistant-ui/native/Thread.js +9 -8
- package/dist/components/assistant-ui/native/ThreadList.js +1 -1
- package/dist/components/assistant-ui/native/ThreadListSidebar.js +5 -4
- package/dist/components/assistant-ui/native/VoiceControl.js +6 -5
- package/dist/components/assistant-ui/native/VoiceDisconnectButton.js +4 -3
- package/dist/components/assistant-ui/native/VoiceMuteButton.js +4 -3
- package/dist/components/assistant-ui/native/index.js +53 -52
- package/dist/components/command/index.js +3 -2
- package/dist/components/questionnaire/index.js +2 -2
- package/dist/components/resizable/Resizable.d.ts +1 -1
- package/dist/components/resizable/index.js +1 -1
- package/dist/hooks/useCardSpotlight.d.ts +7 -0
- package/dist/hooks/usePortalNode.d.ts +14 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +649 -435
- package/dist/theme.css +91 -16
- package/dist/utils/observeScrollGuards.d.ts +4 -0
- package/llms/components/actions/Button.md +433 -0
- package/llms/components/actions/ButtonGroup.md +278 -0
- package/llms/components/actions/ButtonLink.md +189 -0
- package/llms/components/actions/Toggle.md +191 -0
- package/llms/components/actions/ToggleGroup.md +161 -0
- package/llms/components/assistant-ui/elements/agents-tasks/AgentCard.md +60 -0
- package/llms/components/assistant-ui/elements/agents-tasks/AgentHandoff.md +78 -0
- package/llms/components/assistant-ui/elements/agents-tasks/AgentPlan.md +57 -0
- package/llms/components/assistant-ui/elements/agents-tasks/AgentStatus.md +88 -0
- package/llms/components/assistant-ui/elements/agents-tasks/JobProgress.md +84 -0
- package/llms/components/assistant-ui/elements/agents-tasks/RunActivity.md +75 -0
- package/llms/components/assistant-ui/elements/agents-tasks/ScheduleCard.md +91 -0
- package/llms/components/assistant-ui/elements/agents-tasks/StoppedRun.md +54 -0
- package/llms/components/assistant-ui/elements/agents-tasks/SubagentList.md +72 -0
- package/llms/components/assistant-ui/elements/agents-tasks/TaskCard.md +101 -0
- package/llms/components/assistant-ui/elements/agents-tasks/TaskStateIcon.md +86 -0
- package/llms/components/assistant-ui/elements/agents-tasks/TodoList.md +99 -0
- package/llms/components/assistant-ui/elements/branding/ClaudeLogo.md +36 -0
- package/llms/components/assistant-ui/elements/branding/GeminiLogo.md +47 -0
- package/llms/components/assistant-ui/elements/branding/GitHubIcon.md +41 -0
- package/llms/components/assistant-ui/elements/branding/OpenAILogo.md +36 -0
- package/llms/components/assistant-ui/elements/code-diffs/CodeDiff.md +67 -0
- package/llms/components/assistant-ui/elements/code-diffs/CodeRunner.md +66 -0
- package/llms/components/assistant-ui/elements/code-diffs/DiffViewer.md +144 -0
- package/llms/components/assistant-ui/elements/code-diffs/DiffViewerContent.md +50 -0
- package/llms/components/assistant-ui/elements/code-diffs/DiffViewerFile.md +50 -0
- package/llms/components/assistant-ui/elements/code-diffs/DiffViewerFileBadge.md +50 -0
- package/llms/components/assistant-ui/elements/code-diffs/DiffViewerFileContent.md +59 -0
- package/llms/components/assistant-ui/elements/code-diffs/DiffViewerHeader.md +81 -0
- package/llms/components/assistant-ui/elements/code-diffs/DiffViewerLine.md +50 -0
- package/llms/components/assistant-ui/elements/code-diffs/DiffViewerSplitLine.md +55 -0
- package/llms/components/assistant-ui/elements/code-diffs/DiffViewerStats.md +50 -0
- package/llms/components/assistant-ui/elements/code-diffs/DiffViewerText.md +44 -0
- package/llms/components/assistant-ui/elements/code-diffs/ReviewableDiff.md +102 -0
- package/llms/components/assistant-ui/elements/code-diffs/ShikiHighlighter.md +131 -0
- package/llms/components/assistant-ui/elements/code-diffs/SyntaxHighlighter.md +62 -0
- package/llms/components/assistant-ui/elements/code-diffs/TerminalAnsiFragment.md +66 -0
- package/llms/components/assistant-ui/elements/code-diffs/TerminalBlock.md +131 -0
- package/llms/components/assistant-ui/elements/composer/CommandPalette.md +79 -0
- package/llms/components/assistant-ui/elements/composer/Composer.md +62 -0
- package/llms/components/assistant-ui/elements/composer/ComposerActions.md +34 -0
- package/llms/components/assistant-ui/elements/composer/ComposerAttachButton.md +50 -0
- package/llms/components/assistant-ui/elements/composer/ComposerAttachmentChip.md +58 -0
- package/llms/components/assistant-ui/elements/composer/ComposerAttachments.md +42 -0
- package/llms/components/assistant-ui/elements/composer/ComposerBar.md +42 -0
- package/llms/components/assistant-ui/elements/composer/ComposerCommandItem.md +42 -0
- package/llms/components/assistant-ui/elements/composer/ComposerContext.md +50 -0
- package/llms/components/assistant-ui/elements/composer/ComposerInput.md +56 -0
- package/llms/components/assistant-ui/elements/composer/ComposerMenu.md +59 -0
- package/llms/components/assistant-ui/elements/composer/ComposerMenuItem.md +50 -0
- package/llms/components/assistant-ui/elements/composer/ComposerModelItem.md +42 -0
- package/llms/components/assistant-ui/elements/composer/ComposerModelTrigger.md +42 -0
- package/llms/components/assistant-ui/elements/composer/ComposerPersonItem.md +42 -0
- package/llms/components/assistant-ui/elements/composer/ComposerSend.md +58 -0
- package/llms/components/assistant-ui/elements/composer/ComposerToolbar.md +34 -0
- package/llms/components/assistant-ui/elements/composer/ComposerVoice.md +58 -0
- package/llms/components/assistant-ui/elements/composer/ComposerVoiceButton.md +50 -0
- package/llms/components/assistant-ui/elements/composer/MobileComposer.md +82 -0
- package/llms/components/assistant-ui/elements/composer/PromptLibrary.md +99 -0
- package/llms/components/assistant-ui/elements/composer/Suggestions.md +62 -0
- package/llms/components/assistant-ui/elements/context/ContextBreakdown.md +58 -0
- package/llms/components/assistant-ui/elements/context/ContextDisplay.md +37 -0
- package/llms/components/assistant-ui/elements/context/ContextDisplayBar.md +28 -0
- package/llms/components/assistant-ui/elements/context/ContextDisplayContent.md +31 -0
- package/llms/components/assistant-ui/elements/context/ContextDisplayRing.md +28 -0
- package/llms/components/assistant-ui/elements/context/ContextDisplayRoot.md +54 -0
- package/llms/components/assistant-ui/elements/context/ContextDisplayText.md +28 -0
- package/llms/components/assistant-ui/elements/context/ContextDisplayTrigger.md +51 -0
- package/llms/components/assistant-ui/elements/context/ContextDisplayValue.md +58 -0
- package/llms/components/assistant-ui/elements/context/MemoryChips.md +57 -0
- package/llms/components/assistant-ui/elements/conversations/BackgroundInbox.md +57 -0
- package/llms/components/assistant-ui/elements/conversations/CanvasSplit.md +68 -0
- package/llms/components/assistant-ui/elements/conversations/ChatPanel.md +82 -0
- package/llms/components/assistant-ui/elements/conversations/CheckpointHistory.md +57 -0
- package/llms/components/assistant-ui/elements/conversations/ConversationMap.md +59 -0
- package/llms/components/assistant-ui/elements/conversations/ConversationSearch.md +83 -0
- package/llms/components/assistant-ui/elements/conversations/DaySeparator.md +44 -0
- package/llms/components/assistant-ui/elements/conversations/DraftRestore.md +48 -0
- package/llms/components/assistant-ui/elements/conversations/EditMessage.md +97 -0
- package/llms/components/assistant-ui/elements/conversations/LauncherBubble.md +79 -0
- package/llms/components/assistant-ui/elements/conversations/MessageActions.md +68 -0
- package/llms/components/assistant-ui/elements/conversations/MessageAttachments.md +57 -0
- package/llms/components/assistant-ui/elements/conversations/MessageBranches.md +76 -0
- package/llms/components/assistant-ui/elements/conversations/MessagePair.md +57 -0
- package/llms/components/assistant-ui/elements/conversations/MessageQueue.md +54 -0
- package/llms/components/assistant-ui/elements/conversations/MessageTiming.md +78 -0
- package/llms/components/assistant-ui/elements/conversations/QuoteReply.md +83 -0
- package/llms/components/assistant-ui/elements/conversations/RegenerateMenu.md +117 -0
- package/llms/components/assistant-ui/elements/conversations/ScrollAnchor.md +56 -0
- package/llms/components/assistant-ui/elements/conversations/SharedConversation.md +81 -0
- package/llms/components/assistant-ui/elements/conversations/ThreadList.md +121 -0
- package/llms/components/assistant-ui/elements/conversations/ThreadSearch.md +131 -0
- package/llms/components/assistant-ui/elements/data-visualization/ActivityGraph.md +51 -0
- package/llms/components/assistant-ui/elements/data-visualization/ArtifactCard.md +50 -0
- package/llms/components/assistant-ui/elements/data-visualization/Chart.md +58 -0
- package/llms/components/assistant-ui/elements/data-visualization/ComparisonCard.md +58 -0
- package/llms/components/assistant-ui/elements/data-visualization/CostMeter.md +49 -0
- package/llms/components/assistant-ui/elements/data-visualization/DataTable.md +240 -0
- package/llms/components/assistant-ui/elements/data-visualization/Diagram.md +77 -0
- package/llms/components/assistant-ui/elements/data-visualization/DotMatrix.md +188 -0
- package/llms/components/assistant-ui/elements/data-visualization/FlowGraph.md +61 -0
- package/llms/components/assistant-ui/elements/data-visualization/GenerativeUi.md +110 -0
- package/llms/components/assistant-ui/elements/data-visualization/GenerativeUiTheme.md +67 -0
- package/llms/components/assistant-ui/elements/data-visualization/GeoMap.md +91 -0
- package/llms/components/assistant-ui/elements/data-visualization/HeatGraph.md +57 -0
- package/llms/components/assistant-ui/elements/data-visualization/MapAnswer.md +58 -0
- package/llms/components/assistant-ui/elements/data-visualization/MermaidDiagram.md +66 -0
- package/llms/components/assistant-ui/elements/data-visualization/NumberRoll.md +88 -0
- package/llms/components/assistant-ui/elements/data-visualization/NumberRollDigit.md +28 -0
- package/llms/components/assistant-ui/elements/data-visualization/NumberRollPart.md +28 -0
- package/llms/components/assistant-ui/elements/data-visualization/NumberTicker.md +87 -0
- package/llms/components/assistant-ui/elements/data-visualization/RecommendationCard.md +86 -0
- package/llms/components/assistant-ui/elements/data-visualization/ScoreBreakdown.md +72 -0
- package/llms/components/assistant-ui/elements/data-visualization/ShareMeter.md +50 -0
- package/llms/components/assistant-ui/elements/data-visualization/SpecSheet.md +69 -0
- package/llms/components/assistant-ui/elements/data-visualization/Timeline.md +72 -0
- package/llms/components/assistant-ui/elements/data-visualization/TraceWaterfall.md +88 -0
- package/llms/components/assistant-ui/elements/media-voice/AudioPlayer.md +50 -0
- package/llms/components/assistant-ui/elements/media-voice/File.md +122 -0
- package/llms/components/assistant-ui/elements/media-voice/FileTree.md +59 -0
- package/llms/components/assistant-ui/elements/media-voice/Image.md +201 -0
- package/llms/components/assistant-ui/elements/media-voice/ImageGallery.md +64 -0
- package/llms/components/assistant-ui/elements/media-voice/ImageGeneration.md +50 -0
- package/llms/components/assistant-ui/elements/media-voice/ReadAloud.md +89 -0
- package/llms/components/assistant-ui/elements/media-voice/SpeakerIdentity.md +60 -0
- package/llms/components/assistant-ui/elements/media-voice/VideoPlayer.md +42 -0
- package/llms/components/assistant-ui/elements/media-voice/VoiceConversation.md +78 -0
- package/llms/components/assistant-ui/elements/media-voice/VoiceOrb.md +110 -0
- package/llms/components/assistant-ui/elements/models/ModelPicker.md +79 -0
- package/llms/components/assistant-ui/elements/models/ModelSelector.md +48 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorContent.md +45 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorEffort.md +31 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorEmpty.md +30 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorFocusAnchor.md +31 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorGroup.md +40 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorItem.md +38 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorList.md +30 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorRoot.md +72 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorSearch.md +31 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorSeparator.md +34 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorTrigger.md +66 -0
- package/llms/components/assistant-ui/elements/models/ModelSelectorValue.md +32 -0
- package/llms/components/assistant-ui/elements/models/ReasoningEffort.md +86 -0
- package/llms/components/assistant-ui/elements/reasoning/GenerationLoader.md +88 -0
- package/llms/components/assistant-ui/elements/reasoning/ReasoningContent.md +59 -0
- package/llms/components/assistant-ui/elements/reasoning/ReasoningFade.md +62 -0
- package/llms/components/assistant-ui/elements/reasoning/ReasoningPanel.md +75 -0
- package/llms/components/assistant-ui/elements/reasoning/ReasoningRoot.md +101 -0
- package/llms/components/assistant-ui/elements/reasoning/ReasoningText.md +59 -0
- package/llms/components/assistant-ui/elements/reasoning/ReasoningTrigger.md +59 -0
- package/llms/components/assistant-ui/elements/reasoning/ThinkingIndicator.md +54 -0
- package/llms/components/assistant-ui/elements/reasoning/TypingIndicator.md +62 -0
- package/llms/components/assistant-ui/elements/sources-research/Citation.md +103 -0
- package/llms/components/assistant-ui/elements/sources-research/ConfidenceMarker.md +94 -0
- package/llms/components/assistant-ui/elements/sources-research/DocumentReference.md +60 -0
- package/llms/components/assistant-ui/elements/sources-research/InlineCitation.md +56 -0
- package/llms/components/assistant-ui/elements/sources-research/LinkPreview.md +65 -0
- package/llms/components/assistant-ui/elements/sources-research/ResearchReport.md +72 -0
- package/llms/components/assistant-ui/elements/sources-research/RetrievalChunks.md +75 -0
- package/llms/components/assistant-ui/elements/sources-research/SourceGlyph.md +54 -0
- package/llms/components/assistant-ui/elements/sources-research/Sources.md +150 -0
- package/llms/components/assistant-ui/elements/sources-research/WebPreview.md +80 -0
- package/llms/components/assistant-ui/elements/sources-research/WebSearch.md +72 -0
- package/llms/components/assistant-ui/elements/states-settings/ConnectionState.md +58 -0
- package/llms/components/assistant-ui/elements/states-settings/ElicitationForm.md +101 -0
- package/llms/components/assistant-ui/elements/states-settings/EmptyState.md +64 -0
- package/llms/components/assistant-ui/elements/states-settings/EmptyStateComposer.md +88 -0
- package/llms/components/assistant-ui/elements/states-settings/EmptyStateGreeting.md +56 -0
- package/llms/components/assistant-ui/elements/states-settings/EmptyStateSuggestion.md +66 -0
- package/llms/components/assistant-ui/elements/states-settings/EmptyStateSuggestions.md +61 -0
- package/llms/components/assistant-ui/elements/states-settings/ErrorState.md +47 -0
- package/llms/components/assistant-ui/elements/states-settings/EveAskQuestion.md +166 -0
- package/llms/components/assistant-ui/elements/states-settings/FeedbackDialog.md +85 -0
- package/llms/components/assistant-ui/elements/states-settings/Onboarding.md +84 -0
- package/llms/components/assistant-ui/elements/states-settings/OptionList.md +74 -0
- package/llms/components/assistant-ui/elements/states-settings/OptionText.md +38 -0
- package/llms/components/assistant-ui/elements/states-settings/QuestionFlow.md +85 -0
- package/llms/components/assistant-ui/elements/states-settings/QuotaBanner.md +91 -0
- package/llms/components/assistant-ui/elements/states-settings/SettingsPanel.md +92 -0
- package/llms/components/assistant-ui/elements/text-formatting/DirectiveText.md +94 -0
- package/llms/components/assistant-ui/elements/text-formatting/Frac.md +28 -0
- package/llms/components/assistant-ui/elements/text-formatting/MarkdownText.md +66 -0
- package/llms/components/assistant-ui/elements/text-formatting/MathBlock.md +67 -0
- package/llms/components/assistant-ui/elements/text-formatting/StreamingText.md +62 -0
- package/llms/components/assistant-ui/elements/text-formatting/Sub.md +28 -0
- package/llms/components/assistant-ui/elements/text-formatting/Sup.md +28 -0
- package/llms/components/assistant-ui/elements/tools-approvals/ApprovalCard.md +96 -0
- package/llms/components/assistant-ui/elements/tools-approvals/ComputerUse.md +58 -0
- package/llms/components/assistant-ui/elements/tools-approvals/GuardrailNotice.md +78 -0
- package/llms/components/assistant-ui/elements/tools-approvals/McpServerPanel.md +73 -0
- package/llms/components/assistant-ui/elements/tools-approvals/PermissionGrant.md +104 -0
- package/llms/components/assistant-ui/elements/tools-approvals/ToolCall.md +81 -0
- package/llms/components/assistant-ui/elements/tools-approvals/ToolError.md +89 -0
- package/llms/components/assistant-ui/elements/tools-approvals/ToolGroup.md +101 -0
- package/llms/components/assistant-ui/elements/tools-approvals/ToolTimeline.md +87 -0
- package/llms/components/assistant-ui/native/agents-tasks/AgentStatus.md +87 -0
- package/llms/components/assistant-ui/native/agents-tasks/TaskCard.md +111 -0
- package/llms/components/assistant-ui/native/agents-tasks/TaskGroup.md +82 -0
- package/llms/components/assistant-ui/native/agents-tasks/TaskTray.md +66 -0
- package/llms/components/assistant-ui/native/code-diffs/SyntaxHighlighter.md +48 -0
- package/llms/components/assistant-ui/native/composer/AttachmentPreview.md +58 -0
- package/llms/components/assistant-ui/native/composer/ComposerTriggerPopover.md +42 -0
- package/llms/components/assistant-ui/native/composer/FollowupSuggestionsRow.md +36 -0
- package/llms/components/assistant-ui/native/context/ContextDisplay.md +42 -0
- package/llms/components/assistant-ui/native/context/ContextDisplayBar.md +52 -0
- package/llms/components/assistant-ui/native/context/ContextDisplayRing.md +52 -0
- package/llms/components/assistant-ui/native/context/ContextDisplayRoot.md +42 -0
- package/llms/components/assistant-ui/native/context/ContextDisplayRuntimeRoot.md +42 -0
- package/llms/components/assistant-ui/native/context/ContextDisplayText.md +52 -0
- package/llms/components/assistant-ui/native/conversations/AssistantModal.md +60 -0
- package/llms/components/assistant-ui/native/conversations/AssistantSidebar.md +44 -0
- package/llms/components/assistant-ui/native/conversations/ConversationMapAui.md +50 -0
- package/llms/components/assistant-ui/native/conversations/MessageTiming.md +83 -0
- package/llms/components/assistant-ui/native/conversations/QuoteBlock.md +34 -0
- package/llms/components/assistant-ui/native/conversations/SelectionToolbar.md +53 -0
- package/llms/components/assistant-ui/native/conversations/Thread.md +144 -0
- package/llms/components/assistant-ui/native/conversations/ThreadList.md +67 -0
- package/llms/components/assistant-ui/native/conversations/ThreadListSidebar.md +45 -0
- package/llms/components/assistant-ui/native/data-visualization/MermaidDiagram.md +34 -0
- package/llms/components/assistant-ui/native/media-voice/VoiceConnectButton.md +69 -0
- package/llms/components/assistant-ui/native/media-voice/VoiceControl.md +52 -0
- package/llms/components/assistant-ui/native/media-voice/VoiceConversation.md +64 -0
- package/llms/components/assistant-ui/native/media-voice/VoiceDisconnectButton.md +53 -0
- package/llms/components/assistant-ui/native/media-voice/VoiceMuteButton.md +59 -0
- package/llms/components/assistant-ui/native/media-voice/VoiceOrb.md +66 -0
- package/llms/components/assistant-ui/native/media-voice/VoiceStatusDot.md +58 -0
- package/llms/components/assistant-ui/native/models/ModelSelector.md +50 -0
- package/llms/components/assistant-ui/native/reasoning/Reasoning.md +87 -0
- package/llms/components/assistant-ui/native/sources-research/Sources.md +145 -0
- package/llms/components/assistant-ui/native/text-formatting/DirectiveText.md +42 -0
- package/llms/components/assistant-ui/native/tools-approvals/McpConfigDialog.md +54 -0
- package/llms/components/assistant-ui/native/tools-approvals/ToolFallbackApproval.md +352 -0
- package/llms/components/assistant-ui/native/tools-approvals/ToolFallbackRoot.md +84 -0
- package/llms/components/assistant-ui/native/tools-approvals/ToolGroup.md +63 -0
- package/llms/components/data-display/Avatar.md +254 -0
- package/llms/components/data-display/Badge.md +221 -0
- package/llms/components/data-display/Carousel.md +465 -0
- package/llms/components/data-display/Chart.md +546 -0
- package/llms/components/data-display/Item.md +502 -0
- package/llms/components/data-display/JsonViewer.md +38 -0
- package/llms/components/data-display/Kbd.md +99 -0
- package/llms/components/data-display/Table.md +254 -0
- package/llms/components/data-display/VirtualTable.md +57 -0
- package/llms/components/dates/Calendar.md +539 -0
- package/llms/components/dates/PersianCalendar.md +117 -0
- package/llms/components/drag-drop/DragDropPreview.md +46 -0
- package/llms/components/drag-drop/DragDropProvider.md +28 -0
- package/llms/components/feedback/Alert.md +117 -0
- package/llms/components/feedback/Empty.md +193 -0
- package/llms/components/feedback/EmptyState.md +38 -0
- package/llms/components/feedback/PageMessage.md +49 -0
- package/llms/components/feedback/Progress.md +140 -0
- package/llms/components/feedback/Skeleton.md +157 -0
- package/llms/components/feedback/Sonner.md +325 -0
- package/llms/components/feedback/Spinner.md +119 -0
- package/llms/components/feedback/Toast.md +242 -0
- package/llms/components/forms/Checkbox.md +204 -0
- package/llms/components/forms/Combobox.md +594 -0
- package/llms/components/forms/Field.md +511 -0
- package/llms/components/forms/ImagePicker.md +63 -0
- package/llms/components/forms/InlineEdit.md +67 -0
- package/llms/components/forms/Input.md +380 -0
- package/llms/components/forms/InputGroup.md +628 -0
- package/llms/components/forms/InputOTP.md +400 -0
- package/llms/components/forms/Label.md +181 -0
- package/llms/components/forms/NativeSelect.md +128 -0
- package/llms/components/forms/Questionnaire.md +267 -0
- package/llms/components/forms/RadioGroup.md +401 -0
- package/llms/components/forms/Select.md +575 -0
- package/llms/components/forms/Slider.md +234 -0
- package/llms/components/forms/StarRating.md +60 -0
- package/llms/components/forms/Switch.md +240 -0
- package/llms/components/forms/Textarea.md +219 -0
- package/llms/components/layout/Accordion.md +249 -0
- package/llms/components/layout/AspectRatio.md +68 -0
- package/llms/components/layout/Card.md +391 -0
- package/llms/components/layout/Collapsible.md +231 -0
- package/llms/components/layout/Resizable.md +267 -0
- package/llms/components/layout/ScrollArea.md +170 -0
- package/llms/components/layout/Separator.md +104 -0
- package/llms/components/layout/SplitView.md +92 -0
- package/llms/components/messaging/Attachment.md +324 -0
- package/llms/components/messaging/Bubble.md +411 -0
- package/llms/components/messaging/Marker.md +203 -0
- package/llms/components/messaging/Message.md +268 -0
- package/llms/components/messaging/MessageScroller.md +227 -0
- package/llms/components/navigation/Breadcrumb.md +159 -0
- package/llms/components/navigation/Command.md +471 -0
- package/llms/components/navigation/ContextMenu.md +596 -0
- package/llms/components/navigation/DropdownMenu.md +602 -0
- package/llms/components/navigation/Menubar.md +397 -0
- package/llms/components/navigation/NavigationMenu.md +379 -0
- package/llms/components/navigation/Pagination.md +222 -0
- package/llms/components/navigation/Sidebar.md +330 -0
- package/llms/components/navigation/Tabs.md +418 -0
- package/llms/components/overlays/AlertDialog.md +365 -0
- package/llms/components/overlays/ConfirmationDialog.md +77 -0
- package/llms/components/overlays/Dialog.md +559 -0
- package/llms/components/overlays/Drawer.md +597 -0
- package/llms/components/overlays/HoverCard.md +276 -0
- package/llms/components/overlays/Popover.md +286 -0
- package/llms/components/overlays/Sheet.md +433 -0
- package/llms/components/overlays/Tooltip.md +318 -0
- package/llms/components/providers/DensityProvider.md +171 -0
- package/llms/components/providers/DirectionProvider.md +39 -0
- package/llms/components/providers/PortalProvider.md +264 -0
- package/llms/components/providers/ScrollGuard.md +24 -0
- package/llms/components/providers/ThemeProvider.md +71 -0
- package/llms/setup.md +380 -0
- package/llms.txt +428 -0
- package/package.json +8 -5
- package/dist/chunk-czg9p52v.js +0 -74
- package/dist/chunk-fqekyjkh.js +0 -65
package/dist/index.js
CHANGED
|
@@ -10,9 +10,12 @@ import {
|
|
|
10
10
|
useDensity
|
|
11
11
|
} from "./chunk-e6hk39ev.js";
|
|
12
12
|
import {
|
|
13
|
-
PortalContext,
|
|
14
13
|
usePortalContainer2
|
|
15
14
|
} from "./chunk-j89xg1ak.js";
|
|
15
|
+
import {
|
|
16
|
+
usePortalNode,
|
|
17
|
+
PortalProvider2
|
|
18
|
+
} from "./chunk-aa7m22zj.js";
|
|
16
19
|
import {
|
|
17
20
|
DirectionProvider2,
|
|
18
21
|
useDirection2
|
|
@@ -33,7 +36,7 @@ import {
|
|
|
33
36
|
DropdownMenuRadioItem2,
|
|
34
37
|
DropdownMenuSeparator2,
|
|
35
38
|
DropdownMenuShortcut2
|
|
36
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-d4bm5rzy.js";
|
|
37
40
|
import {
|
|
38
41
|
Popover2,
|
|
39
42
|
PopoverTrigger2,
|
|
@@ -41,7 +44,7 @@ import {
|
|
|
41
44
|
PopoverHeader2,
|
|
42
45
|
PopoverTitle2,
|
|
43
46
|
PopoverDescription2
|
|
44
|
-
} from "./chunk-
|
|
47
|
+
} from "./chunk-4djw71cv.js";
|
|
45
48
|
import {
|
|
46
49
|
Skeleton2
|
|
47
50
|
} from "./chunk-d70rcwk7.js";
|
|
@@ -77,7 +80,7 @@ import {
|
|
|
77
80
|
DialogFooter2,
|
|
78
81
|
DialogTitle2,
|
|
79
82
|
DialogDescription2
|
|
80
|
-
} from "./chunk-
|
|
83
|
+
} from "./chunk-70vndezn.js";
|
|
81
84
|
import {
|
|
82
85
|
Slider2
|
|
83
86
|
} from "./chunk-644cnngf.js";
|
|
@@ -92,7 +95,7 @@ import {
|
|
|
92
95
|
Tooltip2,
|
|
93
96
|
TooltipTrigger2,
|
|
94
97
|
TooltipContent2
|
|
95
|
-
} from "./chunk-
|
|
98
|
+
} from "./chunk-mz3e810d.js";
|
|
96
99
|
import {
|
|
97
100
|
RadioGroup2,
|
|
98
101
|
RadioGroupItem2
|
|
@@ -105,7 +108,7 @@ import {
|
|
|
105
108
|
CardAction2,
|
|
106
109
|
CardContent2,
|
|
107
110
|
CardFooter2
|
|
108
|
-
} from "./chunk-
|
|
111
|
+
} from "./chunk-bygq5yqf.js";
|
|
109
112
|
import {
|
|
110
113
|
InputGroup2,
|
|
111
114
|
InputGroupAddon2,
|
|
@@ -187,7 +190,7 @@ import {
|
|
|
187
190
|
HoverCard2,
|
|
188
191
|
HoverCardTrigger2,
|
|
189
192
|
HoverCardContent2
|
|
190
|
-
} from "./chunk-
|
|
193
|
+
} from "./chunk-hh43wg05.js";
|
|
191
194
|
import {
|
|
192
195
|
Sheet2,
|
|
193
196
|
SheetTrigger2,
|
|
@@ -221,13 +224,45 @@ import {
|
|
|
221
224
|
SidebarMenuSub2,
|
|
222
225
|
SidebarMenuSubItem2,
|
|
223
226
|
SidebarMenuSubButton2
|
|
224
|
-
} from "./chunk-
|
|
227
|
+
} from "./chunk-h979cxnh.js";
|
|
228
|
+
// src/components/ButtonLink.tsx
|
|
229
|
+
import { mergeProps } from "@base-ui/react/merge-props";
|
|
230
|
+
import { useRender } from "@base-ui/react/use-render";
|
|
231
|
+
import { jsx } from "react/jsx-runtime";
|
|
232
|
+
function ButtonLink({
|
|
233
|
+
density,
|
|
234
|
+
className,
|
|
235
|
+
variant = "default",
|
|
236
|
+
size = "default",
|
|
237
|
+
align = "center",
|
|
238
|
+
truncate = false,
|
|
239
|
+
fullWidth = false,
|
|
240
|
+
render,
|
|
241
|
+
children,
|
|
242
|
+
...props
|
|
243
|
+
}) {
|
|
244
|
+
return useRender({
|
|
245
|
+
defaultTagName: "a",
|
|
246
|
+
props: mergeProps({
|
|
247
|
+
className: cn2(buttonVariants2({ variant, size, align, truncate, fullWidth }), className),
|
|
248
|
+
children: truncate ? /* @__PURE__ */ jsx("span", {
|
|
249
|
+
className: "min-w-0 truncate",
|
|
250
|
+
children
|
|
251
|
+
}) : children
|
|
252
|
+
}, props),
|
|
253
|
+
render,
|
|
254
|
+
state: {
|
|
255
|
+
slot: "button-link",
|
|
256
|
+
density
|
|
257
|
+
}
|
|
258
|
+
});
|
|
259
|
+
}
|
|
225
260
|
// src/components/Accordion.tsx
|
|
226
261
|
import { Accordion as AccordionPrimitive } from "@base-ui/react/accordion";
|
|
227
262
|
import { ChevronDownIcon, ChevronUpIcon } from "lucide-react";
|
|
228
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
263
|
+
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
229
264
|
function Accordion({ density, className, ...props }) {
|
|
230
|
-
return /* @__PURE__ */
|
|
265
|
+
return /* @__PURE__ */ jsx2(AccordionPrimitive.Root, {
|
|
231
266
|
"data-density": density,
|
|
232
267
|
"data-slot": "accordion",
|
|
233
268
|
className: (state) => cn2("flex w-full flex-col", typeof className === "function" ? className(state) : className),
|
|
@@ -235,7 +270,7 @@ function Accordion({ density, className, ...props }) {
|
|
|
235
270
|
});
|
|
236
271
|
}
|
|
237
272
|
function AccordionItem({ density, className, ...props }) {
|
|
238
|
-
return /* @__PURE__ */
|
|
273
|
+
return /* @__PURE__ */ jsx2(AccordionPrimitive.Item, {
|
|
239
274
|
"data-density": density,
|
|
240
275
|
"data-slot": "accordion-item",
|
|
241
276
|
className: (state) => cn2("not-last:border-b", typeof className === "function" ? className(state) : className),
|
|
@@ -243,7 +278,7 @@ function AccordionItem({ density, className, ...props }) {
|
|
|
243
278
|
});
|
|
244
279
|
}
|
|
245
280
|
function AccordionTrigger({ density, className, children, ...props }) {
|
|
246
|
-
return /* @__PURE__ */
|
|
281
|
+
return /* @__PURE__ */ jsx2(AccordionPrimitive.Header, {
|
|
247
282
|
className: "flex",
|
|
248
283
|
children: /* @__PURE__ */ jsxs(AccordionPrimitive.Trigger, {
|
|
249
284
|
"data-density": density,
|
|
@@ -252,11 +287,11 @@ function AccordionTrigger({ density, className, children, ...props }) {
|
|
|
252
287
|
...props,
|
|
253
288
|
children: [
|
|
254
289
|
children,
|
|
255
|
-
/* @__PURE__ */
|
|
290
|
+
/* @__PURE__ */ jsx2(ChevronDownIcon, {
|
|
256
291
|
"data-slot": "accordion-trigger-icon",
|
|
257
292
|
className: "pointer-events-none shrink-0 group-aria-expanded/accordion-trigger:hidden"
|
|
258
293
|
}),
|
|
259
|
-
/* @__PURE__ */
|
|
294
|
+
/* @__PURE__ */ jsx2(ChevronUpIcon, {
|
|
260
295
|
"data-slot": "accordion-trigger-icon",
|
|
261
296
|
className: "pointer-events-none hidden shrink-0 group-aria-expanded/accordion-trigger:inline"
|
|
262
297
|
})
|
|
@@ -265,12 +300,12 @@ function AccordionTrigger({ density, className, children, ...props }) {
|
|
|
265
300
|
});
|
|
266
301
|
}
|
|
267
302
|
function AccordionContent({ density, className, children, ...props }) {
|
|
268
|
-
return /* @__PURE__ */
|
|
303
|
+
return /* @__PURE__ */ jsx2(AccordionPrimitive.Panel, {
|
|
269
304
|
"data-density": density,
|
|
270
305
|
"data-slot": "accordion-content",
|
|
271
306
|
className: (state) => cn2("h-(--accordion-panel-height) overflow-hidden text-sm transition-[height] duration-200 ease-out data-ending-style:h-0 data-starting-style:h-0", typeof className === "function" ? className(state) : className),
|
|
272
307
|
...props,
|
|
273
|
-
children: /* @__PURE__ */
|
|
308
|
+
children: /* @__PURE__ */ jsx2("div", {
|
|
274
309
|
className: "pt-0 pb-2.5 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4",
|
|
275
310
|
children
|
|
276
311
|
})
|
|
@@ -280,10 +315,10 @@ function AccordionContent({ density, className, children, ...props }) {
|
|
|
280
315
|
import { useDirection } from "@base-ui/react/direction-provider";
|
|
281
316
|
import { Combobox as ComboboxPrimitive } from "@base-ui/react/combobox";
|
|
282
317
|
import { ChevronDownIcon as ChevronDownIcon2, XIcon, CheckIcon } from "lucide-react";
|
|
283
|
-
import { jsx as
|
|
318
|
+
import { jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
284
319
|
var Combobox = ComboboxPrimitive.Root;
|
|
285
320
|
function ComboboxValue({ ...props }) {
|
|
286
|
-
return /* @__PURE__ */
|
|
321
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.Value, {
|
|
287
322
|
...props
|
|
288
323
|
});
|
|
289
324
|
}
|
|
@@ -295,23 +330,23 @@ function ComboboxTrigger({ density, className, children, ...props }) {
|
|
|
295
330
|
...props,
|
|
296
331
|
children: [
|
|
297
332
|
children,
|
|
298
|
-
/* @__PURE__ */
|
|
333
|
+
/* @__PURE__ */ jsx3(ChevronDownIcon2, {
|
|
299
334
|
className: "pointer-events-none size-4 text-muted-foreground"
|
|
300
335
|
})
|
|
301
336
|
]
|
|
302
337
|
});
|
|
303
338
|
}
|
|
304
339
|
function ComboboxClear({ density, className, ...props }) {
|
|
305
|
-
return /* @__PURE__ */
|
|
340
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.Clear, {
|
|
306
341
|
"data-density": density,
|
|
307
342
|
"data-slot": "combobox-clear",
|
|
308
|
-
render: /* @__PURE__ */
|
|
343
|
+
render: /* @__PURE__ */ jsx3(InputGroupButton2, {
|
|
309
344
|
variant: "ghost",
|
|
310
345
|
size: "icon-xs"
|
|
311
346
|
}),
|
|
312
347
|
className: (state) => cn2(typeof className === "function" ? className(state) : className),
|
|
313
348
|
...props,
|
|
314
|
-
children: /* @__PURE__ */
|
|
349
|
+
children: /* @__PURE__ */ jsx3(XIcon, {
|
|
315
350
|
className: "pointer-events-none"
|
|
316
351
|
})
|
|
317
352
|
});
|
|
@@ -332,26 +367,26 @@ function ComboboxInput({
|
|
|
332
367
|
density,
|
|
333
368
|
className: cn2("w-auto", frameClassName),
|
|
334
369
|
children: [
|
|
335
|
-
/* @__PURE__ */
|
|
370
|
+
/* @__PURE__ */ jsx3(ComboboxPrimitive.Input, {
|
|
336
371
|
disabled,
|
|
337
372
|
className,
|
|
338
|
-
render: /* @__PURE__ */
|
|
373
|
+
render: /* @__PURE__ */ jsx3(InputGroupInput2, {}),
|
|
339
374
|
...props
|
|
340
375
|
}),
|
|
341
376
|
/* @__PURE__ */ jsxs2(InputGroupAddon2, {
|
|
342
377
|
align: "inline-end",
|
|
343
378
|
children: [
|
|
344
|
-
showTrigger && /* @__PURE__ */
|
|
379
|
+
showTrigger && /* @__PURE__ */ jsx3(InputGroupButton2, {
|
|
345
380
|
size: "icon-xs",
|
|
346
381
|
variant: "ghost",
|
|
347
|
-
render: /* @__PURE__ */
|
|
382
|
+
render: /* @__PURE__ */ jsx3(ComboboxTrigger, {}),
|
|
348
383
|
"aria-label": triggerLabel,
|
|
349
384
|
"data-density": density,
|
|
350
385
|
"data-slot": "input-group-button",
|
|
351
386
|
className: "group-has-data-[slot=combobox-clear]/input-group:hidden data-pressed:bg-transparent",
|
|
352
387
|
disabled
|
|
353
388
|
}),
|
|
354
|
-
showClear && /* @__PURE__ */
|
|
389
|
+
showClear && /* @__PURE__ */ jsx3(ComboboxClear, {
|
|
355
390
|
disabled,
|
|
356
391
|
"aria-label": clearLabel
|
|
357
392
|
})
|
|
@@ -374,28 +409,33 @@ function ComboboxContent({
|
|
|
374
409
|
const resolvedDensity = useDensity(density);
|
|
375
410
|
const direction = useDirection();
|
|
376
411
|
const container = usePortalContainer2();
|
|
377
|
-
|
|
412
|
+
const portal = usePortalNode();
|
|
413
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.Portal, {
|
|
378
414
|
container,
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
"
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
415
|
+
ref: portal.ref,
|
|
416
|
+
children: /* @__PURE__ */ jsx3(PortalProvider2, {
|
|
417
|
+
container: portal.node,
|
|
418
|
+
children: /* @__PURE__ */ jsx3(ComboboxPrimitive.Positioner, {
|
|
419
|
+
side,
|
|
420
|
+
sideOffset,
|
|
421
|
+
align,
|
|
422
|
+
alignOffset,
|
|
423
|
+
anchor,
|
|
424
|
+
className: "isolate ",
|
|
425
|
+
children: /* @__PURE__ */ jsx3(ComboboxPrimitive.Popup, {
|
|
426
|
+
dir: direction,
|
|
427
|
+
"data-density": resolvedDensity,
|
|
428
|
+
"data-slot": "combobox-content",
|
|
429
|
+
"data-chips": !!anchor,
|
|
430
|
+
className: (state) => cn2("group/combobox-content relative max-h-(--available-height) w-(--anchor-width) max-w-(--available-width) min-w-[calc(var(--anchor-width)+--spacing(7))] origin-(--transform-origin) overflow-hidden rounded-md bg-popover text-popover-foreground border border-frame-edge shadow-frame duration-120 data-[chips=true]:min-w-(--anchor-width) *:data-[slot=input-group]:m-1 *:data-[slot=input-group]:mb-0 *:data-[slot=input-group]:h-control *:data-[slot=input-group]:border-input/30 *:data-[slot=input-group]:bg-input/30 *:data-[slot=input-group]:shadow-none data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0 motion-reduce:data-open:animate-none motion-reduce:data-closed:animate-none", typeof className === "function" ? className(state) : className),
|
|
431
|
+
...props
|
|
432
|
+
})
|
|
393
433
|
})
|
|
394
434
|
})
|
|
395
435
|
});
|
|
396
436
|
}
|
|
397
437
|
function ComboboxList({ density, className, ...props }) {
|
|
398
|
-
return /* @__PURE__ */
|
|
438
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.List, {
|
|
399
439
|
"data-density": density,
|
|
400
440
|
"data-slot": "combobox-list",
|
|
401
441
|
className: (state) => cn2("no-scrollbar max-h-[min(calc(--spacing(72)---spacing(9)),calc(var(--available-height)---spacing(9)))] scroll-py-1 overflow-y-auto overscroll-contain p-1 data-empty:p-0", typeof className === "function" ? className(state) : className),
|
|
@@ -410,11 +450,11 @@ function ComboboxItem({ density, className, children, ...props }) {
|
|
|
410
450
|
...props,
|
|
411
451
|
children: [
|
|
412
452
|
children,
|
|
413
|
-
/* @__PURE__ */
|
|
414
|
-
render: /* @__PURE__ */
|
|
453
|
+
/* @__PURE__ */ jsx3(ComboboxPrimitive.ItemIndicator, {
|
|
454
|
+
render: /* @__PURE__ */ jsx3("span", {
|
|
415
455
|
className: "pointer-events-none absolute end-2 flex size-4 items-center justify-center"
|
|
416
456
|
}),
|
|
417
|
-
children: /* @__PURE__ */
|
|
457
|
+
children: /* @__PURE__ */ jsx3(CheckIcon, {
|
|
418
458
|
className: "pointer-events-none"
|
|
419
459
|
})
|
|
420
460
|
})
|
|
@@ -422,7 +462,7 @@ function ComboboxItem({ density, className, children, ...props }) {
|
|
|
422
462
|
});
|
|
423
463
|
}
|
|
424
464
|
function ComboboxGroup({ density, className, ...props }) {
|
|
425
|
-
return /* @__PURE__ */
|
|
465
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.Group, {
|
|
426
466
|
"data-density": density,
|
|
427
467
|
"data-slot": "combobox-group",
|
|
428
468
|
className: (state) => cn2(typeof className === "function" ? className(state) : className),
|
|
@@ -430,7 +470,7 @@ function ComboboxGroup({ density, className, ...props }) {
|
|
|
430
470
|
});
|
|
431
471
|
}
|
|
432
472
|
function ComboboxLabel({ density, className, ...props }) {
|
|
433
|
-
return /* @__PURE__ */
|
|
473
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.GroupLabel, {
|
|
434
474
|
"data-density": density,
|
|
435
475
|
"data-slot": "combobox-label",
|
|
436
476
|
className: (state) => cn2("px-2 py-1.5 text-xs text-muted-foreground", typeof className === "function" ? className(state) : className),
|
|
@@ -438,12 +478,12 @@ function ComboboxLabel({ density, className, ...props }) {
|
|
|
438
478
|
});
|
|
439
479
|
}
|
|
440
480
|
function ComboboxCollection({ ...props }) {
|
|
441
|
-
return /* @__PURE__ */
|
|
481
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.Collection, {
|
|
442
482
|
...props
|
|
443
483
|
});
|
|
444
484
|
}
|
|
445
485
|
function ComboboxEmpty({ density, className, ...props }) {
|
|
446
|
-
return /* @__PURE__ */
|
|
486
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.Empty, {
|
|
447
487
|
"data-density": density,
|
|
448
488
|
"data-slot": "combobox-empty",
|
|
449
489
|
className: (state) => cn2("flex w-full justify-center py-2 empty:p-0 text-center text-sm text-muted-foreground", typeof className === "function" ? className(state) : className),
|
|
@@ -451,7 +491,7 @@ function ComboboxEmpty({ density, className, ...props }) {
|
|
|
451
491
|
});
|
|
452
492
|
}
|
|
453
493
|
function ComboboxSeparator({ density, className, ...props }) {
|
|
454
|
-
return /* @__PURE__ */
|
|
494
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.Separator, {
|
|
455
495
|
"data-density": density,
|
|
456
496
|
"data-slot": "combobox-separator",
|
|
457
497
|
className: (state) => cn2("-mx-1 my-1 h-px bg-border", typeof className === "function" ? className(state) : className),
|
|
@@ -459,7 +499,7 @@ function ComboboxSeparator({ density, className, ...props }) {
|
|
|
459
499
|
});
|
|
460
500
|
}
|
|
461
501
|
function ComboboxChips({ density, className, ...props }) {
|
|
462
|
-
return /* @__PURE__ */
|
|
502
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.Chips, {
|
|
463
503
|
"data-density": density,
|
|
464
504
|
"data-slot": "combobox-chips",
|
|
465
505
|
className: (state) => cn2("flex min-h-control flex-wrap items-center gap-1 rounded-sm border border-input bg-transparent bg-clip-padding px-control-x py-px text-sm transition-colors focus-within:border-ring focus-within:ring-1 focus-within:ring-ring has-aria-invalid:border-destructive has-aria-invalid:ring-3 has-aria-invalid:ring-destructive has-data-[slot=combobox-chip]:px-1", typeof className === "function" ? className(state) : className),
|
|
@@ -474,15 +514,15 @@ function ComboboxChip({ density, className, children, showRemove = true, ...prop
|
|
|
474
514
|
...props,
|
|
475
515
|
children: [
|
|
476
516
|
children,
|
|
477
|
-
showRemove && /* @__PURE__ */
|
|
478
|
-
render: /* @__PURE__ */
|
|
517
|
+
showRemove && /* @__PURE__ */ jsx3(ComboboxPrimitive.ChipRemove, {
|
|
518
|
+
render: /* @__PURE__ */ jsx3(Button2, {
|
|
479
519
|
variant: "ghost",
|
|
480
520
|
size: "icon-xs"
|
|
481
521
|
}),
|
|
482
522
|
className: "size-tag -ms-1 opacity-50 hover:opacity-100",
|
|
483
523
|
"data-slot": "combobox-chip-remove",
|
|
484
524
|
"aria-label": "Remove item",
|
|
485
|
-
children: /* @__PURE__ */
|
|
525
|
+
children: /* @__PURE__ */ jsx3(XIcon, {
|
|
486
526
|
className: "pointer-events-none"
|
|
487
527
|
})
|
|
488
528
|
})
|
|
@@ -490,7 +530,7 @@ function ComboboxChip({ density, className, children, showRemove = true, ...prop
|
|
|
490
530
|
});
|
|
491
531
|
}
|
|
492
532
|
function ComboboxChipsInput({ density, className, ...props }) {
|
|
493
|
-
return /* @__PURE__ */
|
|
533
|
+
return /* @__PURE__ */ jsx3(ComboboxPrimitive.Input, {
|
|
494
534
|
"data-density": density,
|
|
495
535
|
"data-slot": "combobox-chip-input",
|
|
496
536
|
className: (state) => cn2("h-tag min-w-16 flex-1 py-0 text-sm leading-none outline-none", typeof className === "function" ? className(state) : className),
|
|
@@ -500,9 +540,9 @@ function ComboboxChipsInput({ density, className, ...props }) {
|
|
|
500
540
|
// src/components/Tabs.tsx
|
|
501
541
|
import { Tabs as TabsPrimitive } from "@base-ui/react/tabs";
|
|
502
542
|
import { cva } from "class-variance-authority";
|
|
503
|
-
import { jsx as
|
|
543
|
+
import { jsx as jsx4 } from "react/jsx-runtime";
|
|
504
544
|
function Tabs({ density, className, orientation = "horizontal", ...props }) {
|
|
505
|
-
return /* @__PURE__ */
|
|
545
|
+
return /* @__PURE__ */ jsx4(TabsPrimitive.Root, {
|
|
506
546
|
"data-density": density,
|
|
507
547
|
"data-slot": "tabs",
|
|
508
548
|
orientation,
|
|
@@ -522,7 +562,7 @@ var tabsListVariants = cva("group/tabs-list inline-flex w-fit items-center justi
|
|
|
522
562
|
}
|
|
523
563
|
});
|
|
524
564
|
function TabsList({ density, className, variant = "default", ...props }) {
|
|
525
|
-
return /* @__PURE__ */
|
|
565
|
+
return /* @__PURE__ */ jsx4(TabsPrimitive.List, {
|
|
526
566
|
"data-density": density,
|
|
527
567
|
"data-slot": "tabs-list",
|
|
528
568
|
"data-variant": variant,
|
|
@@ -531,7 +571,7 @@ function TabsList({ density, className, variant = "default", ...props }) {
|
|
|
531
571
|
});
|
|
532
572
|
}
|
|
533
573
|
function TabsTrigger({ density, className, ...props }) {
|
|
534
|
-
return /* @__PURE__ */
|
|
574
|
+
return /* @__PURE__ */ jsx4(TabsPrimitive.Tab, {
|
|
535
575
|
"data-density": density,
|
|
536
576
|
"data-slot": "tabs-trigger",
|
|
537
577
|
className: (state) => cn2("relative inline-flex h-full flex-1 items-center justify-center gap-control-gap rounded-md border border-transparent px-1.5 py-0.5 text-sm font-medium whitespace-nowrap text-foreground/60 transition-colors group-data-[orientation=vertical]/tabs:w-full group-data-[orientation=vertical]/tabs:justify-start hover:text-foreground focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring focus-visible:outline-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 has-data-[icon=inline-end]:pe-1 has-data-[icon=inline-start]:ps-1 aria-disabled:pointer-events-none aria-disabled:opacity-50 group-data-[variant=default]/tabs-list:data-active:shadow-sm group-data-[variant=line]/tabs-list:data-active:shadow-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", "group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent", "data-active:bg-background data-active:text-foreground", "after:absolute after:bg-foreground after:opacity-0 after:transition-opacity group-data-[orientation=horizontal]/tabs:after:inset-x-0 group-data-[orientation=horizontal]/tabs:after:bottom-[-5px] group-data-[orientation=horizontal]/tabs:after:h-0.5 group-data-[orientation=vertical]/tabs:after:inset-y-0 group-data-[orientation=vertical]/tabs:after:-end-1 group-data-[orientation=vertical]/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100", typeof className === "function" ? className(state) : className),
|
|
@@ -539,9 +579,10 @@ function TabsTrigger({ density, className, ...props }) {
|
|
|
539
579
|
});
|
|
540
580
|
}
|
|
541
581
|
function TabsContent({ density, className, ...props }) {
|
|
542
|
-
return /* @__PURE__ */
|
|
582
|
+
return /* @__PURE__ */ jsx4(TabsPrimitive.Panel, {
|
|
543
583
|
"data-density": density,
|
|
544
584
|
"data-slot": "tabs-content",
|
|
585
|
+
"data-scroll": "none",
|
|
545
586
|
className: (state) => cn2("flex-1 text-sm outline-none", typeof className === "function" ? className(state) : className),
|
|
546
587
|
...props
|
|
547
588
|
});
|
|
@@ -555,17 +596,17 @@ import { createContext } from "react";
|
|
|
555
596
|
var DragDropContext = createContext(null);
|
|
556
597
|
|
|
557
598
|
// src/components/DragDropPreview.tsx
|
|
558
|
-
import { jsx as
|
|
599
|
+
import { jsx as jsx5, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
559
600
|
function DragDropPreview({ labels, maxItems = 5 }) {
|
|
560
601
|
const limit = Math.max(1, Math.floor(maxItems));
|
|
561
602
|
return /* @__PURE__ */ jsxs3("div", {
|
|
562
603
|
"data-slot": "drag-drop-preview",
|
|
563
604
|
className: "flex w-max max-w-64 flex-col items-start gap-1",
|
|
564
605
|
children: [
|
|
565
|
-
labels.slice(0, limit).map((label, index) => /* @__PURE__ */
|
|
606
|
+
labels.slice(0, limit).map((label, index) => /* @__PURE__ */ jsx5(Badge2, {
|
|
566
607
|
variant: "secondary",
|
|
567
608
|
density: "compact",
|
|
568
|
-
children: /* @__PURE__ */
|
|
609
|
+
children: /* @__PURE__ */ jsx5("span", {
|
|
569
610
|
className: "max-w-60 truncate",
|
|
570
611
|
children: label
|
|
571
612
|
})
|
|
@@ -584,7 +625,7 @@ function DragDropPreview({ labels, maxItems = 5 }) {
|
|
|
584
625
|
}
|
|
585
626
|
|
|
586
627
|
// src/components/DragDropProvider.tsx
|
|
587
|
-
import { jsx as
|
|
628
|
+
import { jsx as jsx6, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
588
629
|
function DragDropProvider({ children, maxPreviewItems = 5 }) {
|
|
589
630
|
const [active, setActive] = useState(null);
|
|
590
631
|
const [over, setOver] = useState(null);
|
|
@@ -619,16 +660,16 @@ function DragDropProvider({ children, maxPreviewItems = 5 }) {
|
|
|
619
660
|
value: { active, over, start, end, enter, leave },
|
|
620
661
|
children: [
|
|
621
662
|
children,
|
|
622
|
-
/* @__PURE__ */
|
|
663
|
+
/* @__PURE__ */ jsx6("div", {
|
|
623
664
|
ref: preview,
|
|
624
665
|
"aria-hidden": "true",
|
|
625
666
|
className: "pointer-events-none fixed -left-[10000px] top-0 w-max",
|
|
626
|
-
children: /* @__PURE__ */
|
|
667
|
+
children: /* @__PURE__ */ jsx6(DragDropPreview, {
|
|
627
668
|
labels: active?.labels ?? [],
|
|
628
669
|
maxItems: maxPreviewItems
|
|
629
670
|
})
|
|
630
671
|
}),
|
|
631
|
-
/* @__PURE__ */
|
|
672
|
+
/* @__PURE__ */ jsx6("span", {
|
|
632
673
|
role: "status",
|
|
633
674
|
"aria-label": "Drag status",
|
|
634
675
|
className: "sr-only",
|
|
@@ -638,8 +679,8 @@ function DragDropProvider({ children, maxPreviewItems = 5 }) {
|
|
|
638
679
|
});
|
|
639
680
|
}
|
|
640
681
|
// src/components/DragSource.tsx
|
|
641
|
-
import { useRender } from "@base-ui/react/use-render";
|
|
642
|
-
import { mergeProps } from "@base-ui/react/merge-props";
|
|
682
|
+
import { useRender as useRender2 } from "@base-ui/react/use-render";
|
|
683
|
+
import { mergeProps as mergeProps2 } from "@base-ui/react/merge-props";
|
|
643
684
|
|
|
644
685
|
// src/hooks/useDragSource.ts
|
|
645
686
|
import { useId } from "react";
|
|
@@ -693,16 +734,16 @@ function DragSource({
|
|
|
693
734
|
...props
|
|
694
735
|
}) {
|
|
695
736
|
const source = useDragSource({ type, data, labels, effectAllowed, disabled });
|
|
696
|
-
return
|
|
737
|
+
return useRender2({
|
|
697
738
|
defaultTagName: "div",
|
|
698
739
|
render,
|
|
699
|
-
props:
|
|
740
|
+
props: mergeProps2(props, source.props),
|
|
700
741
|
state: { slot: "drag-source", dragging: source.isDragging }
|
|
701
742
|
});
|
|
702
743
|
}
|
|
703
744
|
// src/components/DropTarget.tsx
|
|
704
|
-
import { useRender as
|
|
705
|
-
import { mergeProps as
|
|
745
|
+
import { useRender as useRender3 } from "@base-ui/react/use-render";
|
|
746
|
+
import { mergeProps as mergeProps3 } from "@base-ui/react/merge-props";
|
|
706
747
|
|
|
707
748
|
// src/hooks/useDropTarget.ts
|
|
708
749
|
import { useId as useId2, useState as useState2 } from "react";
|
|
@@ -770,29 +811,29 @@ function DropTarget({
|
|
|
770
811
|
...props
|
|
771
812
|
}) {
|
|
772
813
|
const target = useDropTarget({ accept, canDrop, getDropEffect, onDrop });
|
|
773
|
-
return
|
|
814
|
+
return useRender3({
|
|
774
815
|
defaultTagName: "div",
|
|
775
816
|
render,
|
|
776
|
-
props:
|
|
817
|
+
props: mergeProps3(props, target.props),
|
|
777
818
|
state: { slot: "drop-target", over: target.isOver, effect: target.effect }
|
|
778
819
|
});
|
|
779
820
|
}
|
|
780
821
|
// src/components/EmptyState.tsx
|
|
781
|
-
import { jsx as
|
|
822
|
+
import { jsx as jsx7, jsxs as jsxs5 } from "react/jsx-runtime";
|
|
782
823
|
function EmptyState({ title, description, children }) {
|
|
783
824
|
return /* @__PURE__ */ jsxs5(Empty2, {
|
|
784
825
|
children: [
|
|
785
826
|
/* @__PURE__ */ jsxs5(EmptyHeader2, {
|
|
786
827
|
children: [
|
|
787
|
-
/* @__PURE__ */
|
|
828
|
+
/* @__PURE__ */ jsx7(EmptyTitle2, {
|
|
788
829
|
children: title
|
|
789
830
|
}),
|
|
790
|
-
/* @__PURE__ */
|
|
831
|
+
/* @__PURE__ */ jsx7(EmptyDescription2, {
|
|
791
832
|
children: description
|
|
792
833
|
})
|
|
793
834
|
]
|
|
794
835
|
}),
|
|
795
|
-
children && /* @__PURE__ */
|
|
836
|
+
children && /* @__PURE__ */ jsx7(EmptyContent2, {
|
|
796
837
|
children
|
|
797
838
|
})
|
|
798
839
|
]
|
|
@@ -800,11 +841,11 @@ function EmptyState({ title, description, children }) {
|
|
|
800
841
|
}
|
|
801
842
|
// src/components/PageMessage.tsx
|
|
802
843
|
import { useId as useId3 } from "react";
|
|
803
|
-
import { jsx as
|
|
844
|
+
import { jsx as jsx8, jsxs as jsxs6 } from "react/jsx-runtime";
|
|
804
845
|
function PageMessage({ title, description, children }) {
|
|
805
846
|
const titleId = useId3();
|
|
806
847
|
const descriptionId = useId3();
|
|
807
|
-
return /* @__PURE__ */
|
|
848
|
+
return /* @__PURE__ */ jsx8("main", {
|
|
808
849
|
"aria-labelledby": titleId,
|
|
809
850
|
"aria-describedby": description == null ? undefined : descriptionId,
|
|
810
851
|
className: "grid min-h-dvh w-full place-items-center bg-background text-foreground",
|
|
@@ -812,19 +853,19 @@ function PageMessage({ title, description, children }) {
|
|
|
812
853
|
children: [
|
|
813
854
|
/* @__PURE__ */ jsxs6(EmptyHeader2, {
|
|
814
855
|
children: [
|
|
815
|
-
/* @__PURE__ */
|
|
816
|
-
children: /* @__PURE__ */
|
|
856
|
+
/* @__PURE__ */ jsx8(EmptyTitle2, {
|
|
857
|
+
children: /* @__PURE__ */ jsx8("h1", {
|
|
817
858
|
id: titleId,
|
|
818
859
|
children: title
|
|
819
860
|
})
|
|
820
861
|
}),
|
|
821
|
-
description != null && /* @__PURE__ */
|
|
862
|
+
description != null && /* @__PURE__ */ jsx8(EmptyDescription2, {
|
|
822
863
|
id: descriptionId,
|
|
823
864
|
children: description
|
|
824
865
|
})
|
|
825
866
|
]
|
|
826
867
|
}),
|
|
827
|
-
children != null && /* @__PURE__ */
|
|
868
|
+
children != null && /* @__PURE__ */ jsx8(EmptyContent2, {
|
|
828
869
|
children
|
|
829
870
|
})
|
|
830
871
|
]
|
|
@@ -832,9 +873,9 @@ function PageMessage({ title, description, children }) {
|
|
|
832
873
|
});
|
|
833
874
|
}
|
|
834
875
|
// src/components/JsonViewer.tsx
|
|
835
|
-
import { jsx as
|
|
876
|
+
import { jsx as jsx9 } from "react/jsx-runtime";
|
|
836
877
|
function JsonViewer({ value, label = "JSON", rows = 12 }) {
|
|
837
|
-
return /* @__PURE__ */
|
|
878
|
+
return /* @__PURE__ */ jsx9(Textarea2, {
|
|
838
879
|
readOnly: true,
|
|
839
880
|
rows,
|
|
840
881
|
"aria-label": label,
|
|
@@ -844,31 +885,37 @@ function JsonViewer({ value, label = "JSON", rows = 12 }) {
|
|
|
844
885
|
// src/components/AlertDialog.tsx
|
|
845
886
|
import { AlertDialog as AlertDialogPrimitive } from "@base-ui/react/alert-dialog";
|
|
846
887
|
import { useDirection as useDirection3 } from "@base-ui/react/direction-provider";
|
|
847
|
-
import { jsx as
|
|
888
|
+
import { jsx as jsx10, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
848
889
|
"use client";
|
|
849
890
|
function AlertDialog({ ...props }) {
|
|
850
|
-
return /* @__PURE__ */
|
|
891
|
+
return /* @__PURE__ */ jsx10(AlertDialogPrimitive.Root, {
|
|
851
892
|
"data-slot": "alert-dialog",
|
|
852
893
|
...props
|
|
853
894
|
});
|
|
854
895
|
}
|
|
855
896
|
function AlertDialogTrigger({ ...props }) {
|
|
856
|
-
return /* @__PURE__ */
|
|
897
|
+
return /* @__PURE__ */ jsx10(AlertDialogPrimitive.Trigger, {
|
|
857
898
|
"data-slot": "alert-dialog-trigger",
|
|
858
899
|
...props
|
|
859
900
|
});
|
|
860
901
|
}
|
|
861
|
-
function AlertDialogPortal({ container, ...props }) {
|
|
902
|
+
function AlertDialogPortal({ container, ref, children, ...props }) {
|
|
862
903
|
const resolvedContainer = usePortalContainer2(container);
|
|
863
|
-
|
|
904
|
+
const portal = usePortalNode(ref);
|
|
905
|
+
return /* @__PURE__ */ jsx10(AlertDialogPrimitive.Portal, {
|
|
864
906
|
"data-slot": "alert-dialog-portal",
|
|
865
907
|
container: resolvedContainer,
|
|
866
|
-
|
|
908
|
+
ref: portal.ref,
|
|
909
|
+
...props,
|
|
910
|
+
children: /* @__PURE__ */ jsx10(PortalProvider2, {
|
|
911
|
+
container: portal.node,
|
|
912
|
+
children
|
|
913
|
+
})
|
|
867
914
|
});
|
|
868
915
|
}
|
|
869
916
|
function AlertDialogOverlay({ density, className, ...props }) {
|
|
870
917
|
const resolvedDensity = useDensity(density);
|
|
871
|
-
return /* @__PURE__ */
|
|
918
|
+
return /* @__PURE__ */ jsx10(AlertDialogPrimitive.Backdrop, {
|
|
872
919
|
"data-density": resolvedDensity,
|
|
873
920
|
"data-slot": "alert-dialog-overlay",
|
|
874
921
|
className: (state) => cn2("fixed inset-0 isolate bg-backdrop duration-120 data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0 motion-reduce:data-open:animate-none motion-reduce:data-closed:animate-none", typeof className === "function" ? className(state) : className),
|
|
@@ -880,11 +927,12 @@ function AlertDialogContent({ density, className, size = "default", ...props })
|
|
|
880
927
|
const direction = useDirection3();
|
|
881
928
|
return /* @__PURE__ */ jsxs7(AlertDialogPortal, {
|
|
882
929
|
children: [
|
|
883
|
-
/* @__PURE__ */
|
|
884
|
-
/* @__PURE__ */
|
|
930
|
+
/* @__PURE__ */ jsx10(AlertDialogOverlay, {}),
|
|
931
|
+
/* @__PURE__ */ jsx10(AlertDialogPrimitive.Popup, {
|
|
885
932
|
dir: direction,
|
|
886
933
|
"data-density": resolvedDensity,
|
|
887
934
|
"data-slot": "alert-dialog-content",
|
|
935
|
+
"data-scroll": "none",
|
|
888
936
|
"data-size": size,
|
|
889
937
|
className: (state) => cn2("group/alert-dialog-content fixed top-1/2 left-1/2 grid w-full -translate-x-1/2 -translate-y-1/2 gap-panel rounded-md bg-popover p-panel text-popover-foreground border border-frame-edge shadow-frame duration-120 outline-none data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0 motion-reduce:data-open:animate-none motion-reduce:data-closed:animate-none", typeof className === "function" ? className(state) : className),
|
|
890
938
|
...props
|
|
@@ -893,7 +941,7 @@ function AlertDialogContent({ density, className, size = "default", ...props })
|
|
|
893
941
|
});
|
|
894
942
|
}
|
|
895
943
|
function AlertDialogHeader({ density, className, ...props }) {
|
|
896
|
-
return /* @__PURE__ */
|
|
944
|
+
return /* @__PURE__ */ jsx10("div", {
|
|
897
945
|
"data-density": density,
|
|
898
946
|
"data-slot": "alert-dialog-header",
|
|
899
947
|
className: cn2("grid grid-rows-[auto_1fr] place-items-center gap-control-gap text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-start sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]", className),
|
|
@@ -901,7 +949,7 @@ function AlertDialogHeader({ density, className, ...props }) {
|
|
|
901
949
|
});
|
|
902
950
|
}
|
|
903
951
|
function AlertDialogFooter({ density, className, ...props }) {
|
|
904
|
-
return /* @__PURE__ */
|
|
952
|
+
return /* @__PURE__ */ jsx10("div", {
|
|
905
953
|
"data-density": density,
|
|
906
954
|
"data-slot": "alert-dialog-footer",
|
|
907
955
|
className: cn2("-mx-panel -mb-panel flex flex-col-reverse gap-2 rounded-b-md border-t bg-muted/50 p-panel group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end", className),
|
|
@@ -909,7 +957,7 @@ function AlertDialogFooter({ density, className, ...props }) {
|
|
|
909
957
|
});
|
|
910
958
|
}
|
|
911
959
|
function AlertDialogMedia({ density, className, ...props }) {
|
|
912
|
-
return /* @__PURE__ */
|
|
960
|
+
return /* @__PURE__ */ jsx10("div", {
|
|
913
961
|
"data-density": density,
|
|
914
962
|
"data-slot": "alert-dialog-media",
|
|
915
963
|
className: cn2("mb-2 inline-flex size-10 items-center justify-center rounded-md bg-muted sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-control-xs", className),
|
|
@@ -917,7 +965,7 @@ function AlertDialogMedia({ density, className, ...props }) {
|
|
|
917
965
|
});
|
|
918
966
|
}
|
|
919
967
|
function AlertDialogTitle({ density, className, ...props }) {
|
|
920
|
-
return /* @__PURE__ */
|
|
968
|
+
return /* @__PURE__ */ jsx10(AlertDialogPrimitive.Title, {
|
|
921
969
|
"data-density": density,
|
|
922
970
|
"data-slot": "alert-dialog-title",
|
|
923
971
|
className: (state) => cn2("text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2", typeof className === "function" ? className(state) : className),
|
|
@@ -925,7 +973,7 @@ function AlertDialogTitle({ density, className, ...props }) {
|
|
|
925
973
|
});
|
|
926
974
|
}
|
|
927
975
|
function AlertDialogDescription({ density, className, ...props }) {
|
|
928
|
-
return /* @__PURE__ */
|
|
976
|
+
return /* @__PURE__ */ jsx10(AlertDialogPrimitive.Description, {
|
|
929
977
|
"data-density": density,
|
|
930
978
|
"data-slot": "alert-dialog-description",
|
|
931
979
|
className: (state) => cn2("text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground", typeof className === "function" ? className(state) : className),
|
|
@@ -933,7 +981,7 @@ function AlertDialogDescription({ density, className, ...props }) {
|
|
|
933
981
|
});
|
|
934
982
|
}
|
|
935
983
|
function AlertDialogAction({ density, className, ...props }) {
|
|
936
|
-
return /* @__PURE__ */
|
|
984
|
+
return /* @__PURE__ */ jsx10(Button2, {
|
|
937
985
|
"data-density": density,
|
|
938
986
|
"data-slot": "alert-dialog-action",
|
|
939
987
|
className,
|
|
@@ -947,11 +995,11 @@ function AlertDialogCancel({
|
|
|
947
995
|
size = "default",
|
|
948
996
|
...props
|
|
949
997
|
}) {
|
|
950
|
-
return /* @__PURE__ */
|
|
998
|
+
return /* @__PURE__ */ jsx10(AlertDialogPrimitive.Close, {
|
|
951
999
|
"data-density": density,
|
|
952
1000
|
"data-slot": "alert-dialog-cancel",
|
|
953
1001
|
className,
|
|
954
|
-
render: /* @__PURE__ */
|
|
1002
|
+
render: /* @__PURE__ */ jsx10(Button2, {
|
|
955
1003
|
variant,
|
|
956
1004
|
size
|
|
957
1005
|
}),
|
|
@@ -962,11 +1010,11 @@ function AlertDialogCancel({
|
|
|
962
1010
|
import { Select as SelectPrimitive } from "@base-ui/react/select";
|
|
963
1011
|
import { useDirection as useDirection4 } from "@base-ui/react/direction-provider";
|
|
964
1012
|
import { ChevronDownIcon as ChevronDownIcon3, CheckIcon as CheckIcon2, ChevronUpIcon as ChevronUpIcon2 } from "lucide-react";
|
|
965
|
-
import { jsx as
|
|
1013
|
+
import { jsx as jsx11, jsxs as jsxs8 } from "react/jsx-runtime";
|
|
966
1014
|
"use client";
|
|
967
1015
|
var Select = SelectPrimitive.Root;
|
|
968
1016
|
function SelectGroup({ density, className, ...props }) {
|
|
969
|
-
return /* @__PURE__ */
|
|
1017
|
+
return /* @__PURE__ */ jsx11(SelectPrimitive.Group, {
|
|
970
1018
|
"data-density": density,
|
|
971
1019
|
"data-slot": "select-group",
|
|
972
1020
|
className: (state) => cn2("scroll-my-1 p-1", typeof className === "function" ? className(state) : className),
|
|
@@ -974,7 +1022,7 @@ function SelectGroup({ density, className, ...props }) {
|
|
|
974
1022
|
});
|
|
975
1023
|
}
|
|
976
1024
|
function SelectValue({ density, className, ...props }) {
|
|
977
|
-
return /* @__PURE__ */
|
|
1025
|
+
return /* @__PURE__ */ jsx11(SelectPrimitive.Value, {
|
|
978
1026
|
"data-density": density,
|
|
979
1027
|
"data-slot": "select-value",
|
|
980
1028
|
className: (state) => cn2("flex flex-1 text-start", typeof className === "function" ? className(state) : className),
|
|
@@ -990,8 +1038,8 @@ function SelectTrigger({ density, className, size = "default", children, ...prop
|
|
|
990
1038
|
...props,
|
|
991
1039
|
children: [
|
|
992
1040
|
children,
|
|
993
|
-
/* @__PURE__ */
|
|
994
|
-
render: /* @__PURE__ */
|
|
1041
|
+
/* @__PURE__ */ jsx11(SelectPrimitive.Icon, {
|
|
1042
|
+
render: /* @__PURE__ */ jsx11(ChevronDownIcon3, {
|
|
995
1043
|
className: "pointer-events-none size-4 text-muted-foreground"
|
|
996
1044
|
})
|
|
997
1045
|
})
|
|
@@ -1012,35 +1060,40 @@ function SelectContent({
|
|
|
1012
1060
|
const resolvedDensity = useDensity(density);
|
|
1013
1061
|
const direction = useDirection4();
|
|
1014
1062
|
const container = usePortalContainer2();
|
|
1015
|
-
|
|
1063
|
+
const portal = usePortalNode();
|
|
1064
|
+
return /* @__PURE__ */ jsx11(SelectPrimitive.Portal, {
|
|
1016
1065
|
container,
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
"
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1066
|
+
ref: portal.ref,
|
|
1067
|
+
children: /* @__PURE__ */ jsx11(PortalProvider2, {
|
|
1068
|
+
container: portal.node,
|
|
1069
|
+
children: /* @__PURE__ */ jsx11(SelectPrimitive.Positioner, {
|
|
1070
|
+
side,
|
|
1071
|
+
sideOffset,
|
|
1072
|
+
align,
|
|
1073
|
+
alignOffset,
|
|
1074
|
+
alignItemWithTrigger,
|
|
1075
|
+
className: "isolate ",
|
|
1076
|
+
children: /* @__PURE__ */ jsxs8(SelectPrimitive.Popup, {
|
|
1077
|
+
dir: direction,
|
|
1078
|
+
"data-density": resolvedDensity,
|
|
1079
|
+
"data-slot": "select-content",
|
|
1080
|
+
"data-align-trigger": alignItemWithTrigger,
|
|
1081
|
+
className: (state) => cn2("relative isolate max-h-(--available-height) w-(--anchor-width) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-md bg-popover text-popover-foreground border border-frame-edge shadow-frame duration-120 data-[align-trigger=true]:animate-none data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0 motion-reduce:animate-none", typeof className === "function" ? className(state) : className),
|
|
1082
|
+
...props,
|
|
1083
|
+
children: [
|
|
1084
|
+
/* @__PURE__ */ jsx11(SelectScrollUpButton, {}),
|
|
1085
|
+
/* @__PURE__ */ jsx11(SelectPrimitive.List, {
|
|
1086
|
+
children
|
|
1087
|
+
}),
|
|
1088
|
+
/* @__PURE__ */ jsx11(SelectScrollDownButton, {})
|
|
1089
|
+
]
|
|
1090
|
+
})
|
|
1038
1091
|
})
|
|
1039
1092
|
})
|
|
1040
1093
|
});
|
|
1041
1094
|
}
|
|
1042
1095
|
function SelectLabel({ density, className, ...props }) {
|
|
1043
|
-
return /* @__PURE__ */
|
|
1096
|
+
return /* @__PURE__ */ jsx11(SelectPrimitive.GroupLabel, {
|
|
1044
1097
|
"data-density": density,
|
|
1045
1098
|
"data-slot": "select-label",
|
|
1046
1099
|
className: (state) => cn2("px-1.5 py-1 text-xs text-muted-foreground", typeof className === "function" ? className(state) : className),
|
|
@@ -1054,15 +1107,15 @@ function SelectItem({ density, className, children, ...props }) {
|
|
|
1054
1107
|
className: (state) => cn2("relative flex w-full cursor-default items-center gap-control-gap rounded-md py-1 pe-8 ps-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2", typeof className === "function" ? className(state) : className),
|
|
1055
1108
|
...props,
|
|
1056
1109
|
children: [
|
|
1057
|
-
/* @__PURE__ */
|
|
1110
|
+
/* @__PURE__ */ jsx11(SelectPrimitive.ItemText, {
|
|
1058
1111
|
className: "flex flex-1 shrink-0 gap-2 whitespace-nowrap",
|
|
1059
1112
|
children
|
|
1060
1113
|
}),
|
|
1061
|
-
/* @__PURE__ */
|
|
1062
|
-
render: /* @__PURE__ */
|
|
1114
|
+
/* @__PURE__ */ jsx11(SelectPrimitive.ItemIndicator, {
|
|
1115
|
+
render: /* @__PURE__ */ jsx11("span", {
|
|
1063
1116
|
className: "pointer-events-none absolute end-2 flex size-4 items-center justify-center"
|
|
1064
1117
|
}),
|
|
1065
|
-
children: /* @__PURE__ */
|
|
1118
|
+
children: /* @__PURE__ */ jsx11(CheckIcon2, {
|
|
1066
1119
|
className: "pointer-events-none"
|
|
1067
1120
|
})
|
|
1068
1121
|
})
|
|
@@ -1070,7 +1123,7 @@ function SelectItem({ density, className, children, ...props }) {
|
|
|
1070
1123
|
});
|
|
1071
1124
|
}
|
|
1072
1125
|
function SelectSeparator({ density, className, ...props }) {
|
|
1073
|
-
return /* @__PURE__ */
|
|
1126
|
+
return /* @__PURE__ */ jsx11(SelectPrimitive.Separator, {
|
|
1074
1127
|
"data-density": density,
|
|
1075
1128
|
"data-slot": "select-separator",
|
|
1076
1129
|
className: (state) => cn2("pointer-events-none -mx-1 my-1 h-px bg-border", typeof className === "function" ? className(state) : className),
|
|
@@ -1078,39 +1131,178 @@ function SelectSeparator({ density, className, ...props }) {
|
|
|
1078
1131
|
});
|
|
1079
1132
|
}
|
|
1080
1133
|
function SelectScrollUpButton({ density, className, ...props }) {
|
|
1081
|
-
return /* @__PURE__ */
|
|
1134
|
+
return /* @__PURE__ */ jsx11(SelectPrimitive.ScrollUpArrow, {
|
|
1082
1135
|
"data-density": density,
|
|
1083
1136
|
"data-slot": "select-scroll-up-button",
|
|
1084
1137
|
className: (state) => cn2("top-0 flex w-full cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4", typeof className === "function" ? className(state) : className),
|
|
1085
1138
|
...props,
|
|
1086
|
-
children: /* @__PURE__ */
|
|
1139
|
+
children: /* @__PURE__ */ jsx11(ChevronUpIcon2, {})
|
|
1087
1140
|
});
|
|
1088
1141
|
}
|
|
1089
1142
|
function SelectScrollDownButton({ density, className, ...props }) {
|
|
1090
|
-
return /* @__PURE__ */
|
|
1143
|
+
return /* @__PURE__ */ jsx11(SelectPrimitive.ScrollDownArrow, {
|
|
1091
1144
|
"data-density": density,
|
|
1092
1145
|
"data-slot": "select-scroll-down-button",
|
|
1093
1146
|
className: (state) => cn2("bottom-0 flex w-full cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4", typeof className === "function" ? className(state) : className),
|
|
1094
1147
|
...props,
|
|
1095
|
-
children: /* @__PURE__ */
|
|
1148
|
+
children: /* @__PURE__ */ jsx11(ChevronDownIcon3, {})
|
|
1096
1149
|
});
|
|
1097
1150
|
}
|
|
1098
1151
|
// src/components/DensityProvider.tsx
|
|
1099
|
-
import {
|
|
1100
|
-
|
|
1101
|
-
|
|
1152
|
+
import { mergeProps as mergeProps4 } from "@base-ui/react/merge-props";
|
|
1153
|
+
import { useRender as useRender4 } from "@base-ui/react/use-render";
|
|
1154
|
+
import { jsx as jsx12 } from "react/jsx-runtime";
|
|
1155
|
+
function DensityProvider({
|
|
1156
|
+
density = "comfortable",
|
|
1157
|
+
className,
|
|
1158
|
+
render,
|
|
1159
|
+
...props
|
|
1160
|
+
}) {
|
|
1161
|
+
const element = useRender4({
|
|
1162
|
+
defaultTagName: "div",
|
|
1163
|
+
props: mergeProps4({ className: cn2("font-sans text-base leading-(--ag-leading)", className) }, props),
|
|
1164
|
+
render,
|
|
1165
|
+
state: { slot: "density-provider", density }
|
|
1166
|
+
});
|
|
1167
|
+
return /* @__PURE__ */ jsx12(DensityContext.Provider, {
|
|
1102
1168
|
value: density,
|
|
1103
|
-
children:
|
|
1104
|
-
"data-density": density,
|
|
1105
|
-
className: "font-sans text-base leading-(--ag-leading)",
|
|
1106
|
-
children
|
|
1107
|
-
})
|
|
1169
|
+
children: element
|
|
1108
1170
|
});
|
|
1109
1171
|
}
|
|
1110
1172
|
// src/components/ThemeProvider.tsx
|
|
1111
1173
|
import { useMemo } from "react";
|
|
1112
1174
|
import { useIsomorphicLayoutEffect, useTernaryDarkMode } from "usehooks-ts";
|
|
1113
|
-
|
|
1175
|
+
|
|
1176
|
+
// src/components/ScrollGuard.tsx
|
|
1177
|
+
import { useEffect as useEffect2 } from "react";
|
|
1178
|
+
|
|
1179
|
+
// src/utils/observeScrollGuards.ts
|
|
1180
|
+
function throwViolation(error) {
|
|
1181
|
+
throw error;
|
|
1182
|
+
}
|
|
1183
|
+
function getViolation(element, view) {
|
|
1184
|
+
if (!element.getClientRects().length)
|
|
1185
|
+
return;
|
|
1186
|
+
const style = view.getComputedStyle(element);
|
|
1187
|
+
if (style.visibility !== "visible")
|
|
1188
|
+
return;
|
|
1189
|
+
const axes = [];
|
|
1190
|
+
if (["auto", "scroll"].includes(style.overflowX) && element.scrollWidth > element.clientWidth) {
|
|
1191
|
+
axes.push(`horizontal: ${element.scrollWidth}px > ${element.clientWidth}px`);
|
|
1192
|
+
}
|
|
1193
|
+
if (["auto", "scroll"].includes(style.overflowY) && element.scrollHeight > element.clientHeight) {
|
|
1194
|
+
axes.push(`vertical: ${element.scrollHeight}px > ${element.clientHeight}px`);
|
|
1195
|
+
}
|
|
1196
|
+
if (!axes.length)
|
|
1197
|
+
return;
|
|
1198
|
+
const slot = element.getAttribute("data-slot");
|
|
1199
|
+
const identity = element.id ? ` id="${element.id}"` : slot ? ` data-slot="${slot}"` : "";
|
|
1200
|
+
return `<${element.localName}${identity}> (${axes.join(", ")})`;
|
|
1201
|
+
}
|
|
1202
|
+
function observeScrollGuards(ownerDocument, reportViolation = throwViolation) {
|
|
1203
|
+
const view = ownerDocument.defaultView;
|
|
1204
|
+
if (!view)
|
|
1205
|
+
return () => {};
|
|
1206
|
+
let frame;
|
|
1207
|
+
let needsRefresh = true;
|
|
1208
|
+
let guarded = [];
|
|
1209
|
+
const observed = new Set;
|
|
1210
|
+
const reported = new WeakSet;
|
|
1211
|
+
const schedule = () => {
|
|
1212
|
+
frame ??= view.requestAnimationFrame(check);
|
|
1213
|
+
};
|
|
1214
|
+
const resizeObserver = new view.ResizeObserver(schedule);
|
|
1215
|
+
const refresh = () => {
|
|
1216
|
+
guarded = [...ownerDocument.querySelectorAll('[data-scroll="none"]')];
|
|
1217
|
+
const targets = new Set(guarded.flatMap((element) => [element, ...element.querySelectorAll("*")]));
|
|
1218
|
+
for (const element of observed) {
|
|
1219
|
+
if (!targets.has(element)) {
|
|
1220
|
+
resizeObserver.unobserve(element);
|
|
1221
|
+
observed.delete(element);
|
|
1222
|
+
}
|
|
1223
|
+
}
|
|
1224
|
+
for (const element of targets) {
|
|
1225
|
+
if (!observed.has(element)) {
|
|
1226
|
+
resizeObserver.observe(element);
|
|
1227
|
+
observed.add(element);
|
|
1228
|
+
}
|
|
1229
|
+
}
|
|
1230
|
+
needsRefresh = false;
|
|
1231
|
+
};
|
|
1232
|
+
const check = () => {
|
|
1233
|
+
frame = undefined;
|
|
1234
|
+
if (needsRefresh)
|
|
1235
|
+
refresh();
|
|
1236
|
+
const violations = [];
|
|
1237
|
+
for (const element of guarded) {
|
|
1238
|
+
const violation = getViolation(element, view);
|
|
1239
|
+
if (!violation) {
|
|
1240
|
+
reported.delete(element);
|
|
1241
|
+
} else if (!reported.has(element)) {
|
|
1242
|
+
reported.add(element);
|
|
1243
|
+
violations.push(violation);
|
|
1244
|
+
}
|
|
1245
|
+
}
|
|
1246
|
+
if (violations.length) {
|
|
1247
|
+
reportViolation(new Error(`[shadcn] Scrolling is forbidden by data-scroll="none": ${violations.join("; ")}. ` + "Move scrolling content into a nested ScrollArea or another explicit scroll viewport."));
|
|
1248
|
+
}
|
|
1249
|
+
};
|
|
1250
|
+
const mutations = new view.MutationObserver((records) => {
|
|
1251
|
+
needsRefresh ||= records.some((record) => record.type === "childList" || record.attributeName === "data-scroll");
|
|
1252
|
+
schedule();
|
|
1253
|
+
});
|
|
1254
|
+
mutations.observe(ownerDocument.documentElement, {
|
|
1255
|
+
subtree: true,
|
|
1256
|
+
childList: true,
|
|
1257
|
+
characterData: true,
|
|
1258
|
+
attributes: true
|
|
1259
|
+
});
|
|
1260
|
+
view.addEventListener("resize", schedule);
|
|
1261
|
+
ownerDocument.addEventListener("load", schedule, true);
|
|
1262
|
+
ownerDocument.addEventListener("transitionend", schedule, true);
|
|
1263
|
+
ownerDocument.addEventListener("animationend", schedule, true);
|
|
1264
|
+
ownerDocument.fonts.addEventListener("loadingdone", schedule);
|
|
1265
|
+
schedule();
|
|
1266
|
+
return () => {
|
|
1267
|
+
mutations.disconnect();
|
|
1268
|
+
resizeObserver.disconnect();
|
|
1269
|
+
if (frame !== undefined)
|
|
1270
|
+
view.cancelAnimationFrame(frame);
|
|
1271
|
+
view.removeEventListener("resize", schedule);
|
|
1272
|
+
ownerDocument.removeEventListener("load", schedule, true);
|
|
1273
|
+
ownerDocument.removeEventListener("transitionend", schedule, true);
|
|
1274
|
+
ownerDocument.removeEventListener("animationend", schedule, true);
|
|
1275
|
+
ownerDocument.fonts.removeEventListener("loadingdone", schedule);
|
|
1276
|
+
};
|
|
1277
|
+
}
|
|
1278
|
+
|
|
1279
|
+
// src/components/ScrollGuard.tsx
|
|
1280
|
+
"use client";
|
|
1281
|
+
var registrations = new WeakMap;
|
|
1282
|
+
function ScrollGuard({ ownerDocument }) {
|
|
1283
|
+
useEffect2(() => {
|
|
1284
|
+
if (process.env.NODE_ENV === "production")
|
|
1285
|
+
return;
|
|
1286
|
+
const target = ownerDocument ?? document;
|
|
1287
|
+
let registration = registrations.get(target);
|
|
1288
|
+
if (!registration) {
|
|
1289
|
+
registration = { users: 0, disconnect: observeScrollGuards(target) };
|
|
1290
|
+
registrations.set(target, registration);
|
|
1291
|
+
}
|
|
1292
|
+
registration.users++;
|
|
1293
|
+
return () => {
|
|
1294
|
+
registration.users--;
|
|
1295
|
+
if (!registration.users) {
|
|
1296
|
+
registration.disconnect();
|
|
1297
|
+
registrations.delete(target);
|
|
1298
|
+
}
|
|
1299
|
+
};
|
|
1300
|
+
}, [ownerDocument]);
|
|
1301
|
+
return null;
|
|
1302
|
+
}
|
|
1303
|
+
|
|
1304
|
+
// src/components/ThemeProvider.tsx
|
|
1305
|
+
import { jsx as jsx13, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
1114
1306
|
function StoredThemeProvider({
|
|
1115
1307
|
children,
|
|
1116
1308
|
defaultTheme = "system",
|
|
@@ -1121,7 +1313,7 @@ function StoredThemeProvider({
|
|
|
1121
1313
|
defaultValue: defaultTheme,
|
|
1122
1314
|
localStorageKey: storageKey
|
|
1123
1315
|
});
|
|
1124
|
-
return /* @__PURE__ */
|
|
1316
|
+
return /* @__PURE__ */ jsx13(ThemePalette, {
|
|
1125
1317
|
theme: forcedTheme ?? ternaryDarkMode,
|
|
1126
1318
|
resolvedTheme: forcedTheme ?? (isDarkMode ? "dark" : "light"),
|
|
1127
1319
|
setTheme: setTernaryDarkMode,
|
|
@@ -1139,9 +1331,12 @@ function ThemePalette({
|
|
|
1139
1331
|
document.documentElement.style.colorScheme = resolvedTheme;
|
|
1140
1332
|
}, [resolvedTheme]);
|
|
1141
1333
|
const value = useMemo(() => ({ theme, resolvedTheme, setTheme }), [theme, resolvedTheme, setTheme]);
|
|
1142
|
-
return /* @__PURE__ */
|
|
1334
|
+
return /* @__PURE__ */ jsxs9(ThemeContext.Provider, {
|
|
1143
1335
|
value,
|
|
1144
|
-
children
|
|
1336
|
+
children: [
|
|
1337
|
+
/* @__PURE__ */ jsx13(ScrollGuard, {}),
|
|
1338
|
+
children
|
|
1339
|
+
]
|
|
1145
1340
|
});
|
|
1146
1341
|
}
|
|
1147
1342
|
function ControlledThemeProvider({
|
|
@@ -1152,7 +1347,7 @@ function ControlledThemeProvider({
|
|
|
1152
1347
|
const isDark = useMediaQuery("(prefers-color-scheme: dark)");
|
|
1153
1348
|
const { theme, setTheme } = controlledTheme;
|
|
1154
1349
|
const resolvedTheme = forcedTheme ?? (theme === "system" ? isDark ? "dark" : "light" : theme);
|
|
1155
|
-
return /* @__PURE__ */
|
|
1350
|
+
return /* @__PURE__ */ jsx13(ThemePalette, {
|
|
1156
1351
|
theme: forcedTheme ?? theme,
|
|
1157
1352
|
resolvedTheme,
|
|
1158
1353
|
setTheme,
|
|
@@ -1161,11 +1356,11 @@ function ControlledThemeProvider({
|
|
|
1161
1356
|
}
|
|
1162
1357
|
function ThemeProvider(props) {
|
|
1163
1358
|
if (props.controlledTheme)
|
|
1164
|
-
return /* @__PURE__ */
|
|
1359
|
+
return /* @__PURE__ */ jsx13(ControlledThemeProvider, {
|
|
1165
1360
|
...props,
|
|
1166
1361
|
controlledTheme: props.controlledTheme
|
|
1167
1362
|
});
|
|
1168
|
-
return /* @__PURE__ */
|
|
1363
|
+
return /* @__PURE__ */ jsx13(StoredThemeProvider, {
|
|
1169
1364
|
...props
|
|
1170
1365
|
});
|
|
1171
1366
|
}
|
|
@@ -1175,9 +1370,9 @@ function useComboboxAnchor() {
|
|
|
1175
1370
|
return useRef2(null);
|
|
1176
1371
|
}
|
|
1177
1372
|
// src/components/AspectRatio.tsx
|
|
1178
|
-
import { jsx as
|
|
1373
|
+
import { jsx as jsx14 } from "react/jsx-runtime";
|
|
1179
1374
|
function AspectRatio({ ratio, className, style, ...props }) {
|
|
1180
|
-
return /* @__PURE__ */
|
|
1375
|
+
return /* @__PURE__ */ jsx14("div", {
|
|
1181
1376
|
"data-slot": "aspect-ratio",
|
|
1182
1377
|
className: cn2("relative", className),
|
|
1183
1378
|
style: { aspectRatio: ratio, ...style },
|
|
@@ -1186,11 +1381,11 @@ function AspectRatio({ ratio, className, style, ...props }) {
|
|
|
1186
1381
|
}
|
|
1187
1382
|
// src/components/Breadcrumb.tsx
|
|
1188
1383
|
import { ChevronRightIcon, MoreHorizontalIcon } from "lucide-react";
|
|
1189
|
-
import { mergeProps as
|
|
1190
|
-
import { useRender as
|
|
1191
|
-
import { jsx as
|
|
1384
|
+
import { mergeProps as mergeProps5 } from "@base-ui/react/merge-props";
|
|
1385
|
+
import { useRender as useRender5 } from "@base-ui/react/use-render";
|
|
1386
|
+
import { jsx as jsx15, jsxs as jsxs10 } from "react/jsx-runtime";
|
|
1192
1387
|
function Breadcrumb({ density, className, ...props }) {
|
|
1193
|
-
return /* @__PURE__ */
|
|
1388
|
+
return /* @__PURE__ */ jsx15("nav", {
|
|
1194
1389
|
"aria-label": "breadcrumb",
|
|
1195
1390
|
"data-density": density,
|
|
1196
1391
|
"data-slot": "breadcrumb",
|
|
@@ -1199,7 +1394,7 @@ function Breadcrumb({ density, className, ...props }) {
|
|
|
1199
1394
|
});
|
|
1200
1395
|
}
|
|
1201
1396
|
function BreadcrumbList({ density, className, ...props }) {
|
|
1202
|
-
return /* @__PURE__ */
|
|
1397
|
+
return /* @__PURE__ */ jsx15("ol", {
|
|
1203
1398
|
"data-density": density,
|
|
1204
1399
|
"data-slot": "breadcrumb-list",
|
|
1205
1400
|
className: cn2("flex flex-wrap items-center gap-control-gap text-sm wrap-break-word text-muted-foreground", className),
|
|
@@ -1207,7 +1402,7 @@ function BreadcrumbList({ density, className, ...props }) {
|
|
|
1207
1402
|
});
|
|
1208
1403
|
}
|
|
1209
1404
|
function BreadcrumbItem({ density, className, ...props }) {
|
|
1210
|
-
return /* @__PURE__ */
|
|
1405
|
+
return /* @__PURE__ */ jsx15("li", {
|
|
1211
1406
|
"data-density": density,
|
|
1212
1407
|
"data-slot": "breadcrumb-item",
|
|
1213
1408
|
className: cn2("inline-flex items-center gap-1", className),
|
|
@@ -1215,9 +1410,9 @@ function BreadcrumbItem({ density, className, ...props }) {
|
|
|
1215
1410
|
});
|
|
1216
1411
|
}
|
|
1217
1412
|
function BreadcrumbLink({ density, className, render, ...props }) {
|
|
1218
|
-
return
|
|
1413
|
+
return useRender5({
|
|
1219
1414
|
defaultTagName: "a",
|
|
1220
|
-
props:
|
|
1415
|
+
props: mergeProps5({
|
|
1221
1416
|
className: cn2("transition-colors hover:text-foreground", className)
|
|
1222
1417
|
}, props),
|
|
1223
1418
|
render,
|
|
@@ -1228,7 +1423,7 @@ function BreadcrumbLink({ density, className, render, ...props }) {
|
|
|
1228
1423
|
});
|
|
1229
1424
|
}
|
|
1230
1425
|
function BreadcrumbPage({ density, className, ...props }) {
|
|
1231
|
-
return /* @__PURE__ */
|
|
1426
|
+
return /* @__PURE__ */ jsx15("span", {
|
|
1232
1427
|
"data-density": density,
|
|
1233
1428
|
"data-slot": "breadcrumb-page",
|
|
1234
1429
|
role: "link",
|
|
@@ -1239,20 +1434,20 @@ function BreadcrumbPage({ density, className, ...props }) {
|
|
|
1239
1434
|
});
|
|
1240
1435
|
}
|
|
1241
1436
|
function BreadcrumbSeparator({ density, children, className, ...props }) {
|
|
1242
|
-
return /* @__PURE__ */
|
|
1437
|
+
return /* @__PURE__ */ jsx15("li", {
|
|
1243
1438
|
"data-density": density,
|
|
1244
1439
|
"data-slot": "breadcrumb-separator",
|
|
1245
1440
|
role: "presentation",
|
|
1246
1441
|
"aria-hidden": "true",
|
|
1247
1442
|
className: cn2("[&>svg]:size-3.5", className),
|
|
1248
1443
|
...props,
|
|
1249
|
-
children: children ?? /* @__PURE__ */
|
|
1444
|
+
children: children ?? /* @__PURE__ */ jsx15(ChevronRightIcon, {
|
|
1250
1445
|
className: "rtl:rotate-180"
|
|
1251
1446
|
})
|
|
1252
1447
|
});
|
|
1253
1448
|
}
|
|
1254
1449
|
function BreadcrumbEllipsis({ density, className, ...props }) {
|
|
1255
|
-
return /* @__PURE__ */
|
|
1450
|
+
return /* @__PURE__ */ jsxs10("span", {
|
|
1256
1451
|
"data-density": density,
|
|
1257
1452
|
"data-slot": "breadcrumb-ellipsis",
|
|
1258
1453
|
role: "presentation",
|
|
@@ -1260,8 +1455,8 @@ function BreadcrumbEllipsis({ density, className, ...props }) {
|
|
|
1260
1455
|
className: cn2("flex size-5 items-center justify-center [&>svg]:size-4", className),
|
|
1261
1456
|
...props,
|
|
1262
1457
|
children: [
|
|
1263
|
-
/* @__PURE__ */
|
|
1264
|
-
/* @__PURE__ */
|
|
1458
|
+
/* @__PURE__ */ jsx15(MoreHorizontalIcon, {}),
|
|
1459
|
+
/* @__PURE__ */ jsx15("span", {
|
|
1265
1460
|
className: "sr-only",
|
|
1266
1461
|
children: "More"
|
|
1267
1462
|
})
|
|
@@ -1269,10 +1464,10 @@ function BreadcrumbEllipsis({ density, className, ...props }) {
|
|
|
1269
1464
|
});
|
|
1270
1465
|
}
|
|
1271
1466
|
// src/components/ButtonGroup.tsx
|
|
1272
|
-
import { mergeProps as
|
|
1273
|
-
import { useRender as
|
|
1467
|
+
import { mergeProps as mergeProps6 } from "@base-ui/react/merge-props";
|
|
1468
|
+
import { useRender as useRender6 } from "@base-ui/react/use-render";
|
|
1274
1469
|
import { cva as cva2 } from "class-variance-authority";
|
|
1275
|
-
import { jsx as
|
|
1470
|
+
import { jsx as jsx16 } from "react/jsx-runtime";
|
|
1276
1471
|
var buttonGroupVariants = cva2("flex w-fit items-stretch *:focus-visible:relative *:focus-visible:z-10 has-[>[data-slot=button-group]]:gap-2 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-e-sm [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1", {
|
|
1277
1472
|
variants: {
|
|
1278
1473
|
orientation: {
|
|
@@ -1285,7 +1480,7 @@ var buttonGroupVariants = cva2("flex w-fit items-stretch *:focus-visible:relativ
|
|
|
1285
1480
|
}
|
|
1286
1481
|
});
|
|
1287
1482
|
function ButtonGroup({ density, className, orientation, ...props }) {
|
|
1288
|
-
return /* @__PURE__ */
|
|
1483
|
+
return /* @__PURE__ */ jsx16("div", {
|
|
1289
1484
|
role: "group",
|
|
1290
1485
|
"data-density": density,
|
|
1291
1486
|
"data-slot": "button-group",
|
|
@@ -1295,9 +1490,9 @@ function ButtonGroup({ density, className, orientation, ...props }) {
|
|
|
1295
1490
|
});
|
|
1296
1491
|
}
|
|
1297
1492
|
function ButtonGroupText({ density, className, render, ...props }) {
|
|
1298
|
-
return
|
|
1493
|
+
return useRender6({
|
|
1299
1494
|
defaultTagName: "div",
|
|
1300
|
-
props:
|
|
1495
|
+
props: mergeProps6({
|
|
1301
1496
|
className: cn2("flex items-center gap-2 rounded-sm border bg-muted px-control-x text-sm font-medium [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4", className)
|
|
1302
1497
|
}, props),
|
|
1303
1498
|
render,
|
|
@@ -1313,7 +1508,7 @@ function ButtonGroupSeparator({
|
|
|
1313
1508
|
orientation = "vertical",
|
|
1314
1509
|
...props
|
|
1315
1510
|
}) {
|
|
1316
|
-
return /* @__PURE__ */
|
|
1511
|
+
return /* @__PURE__ */ jsx16(Separator2, {
|
|
1317
1512
|
"data-density": density,
|
|
1318
1513
|
"data-slot": "button-group-separator",
|
|
1319
1514
|
orientation,
|
|
@@ -1323,7 +1518,7 @@ function ButtonGroupSeparator({
|
|
|
1323
1518
|
}
|
|
1324
1519
|
// src/components/NativeSelect.tsx
|
|
1325
1520
|
import { ChevronDownIcon as ChevronDownIcon4 } from "lucide-react";
|
|
1326
|
-
import { jsx as
|
|
1521
|
+
import { jsx as jsx17, jsxs as jsxs11 } from "react/jsx-runtime";
|
|
1327
1522
|
function NativeSelect({
|
|
1328
1523
|
density,
|
|
1329
1524
|
className,
|
|
@@ -1331,21 +1526,21 @@ function NativeSelect({
|
|
|
1331
1526
|
size = "default",
|
|
1332
1527
|
...props
|
|
1333
1528
|
}) {
|
|
1334
|
-
return /* @__PURE__ */
|
|
1529
|
+
return /* @__PURE__ */ jsxs11("div", {
|
|
1335
1530
|
dir,
|
|
1336
1531
|
className: cn2("group/native-select relative w-fit has-[select:disabled]:opacity-50", className),
|
|
1337
1532
|
"data-density": density,
|
|
1338
1533
|
"data-slot": "native-select-wrapper",
|
|
1339
1534
|
"data-size": size,
|
|
1340
1535
|
children: [
|
|
1341
|
-
/* @__PURE__ */
|
|
1536
|
+
/* @__PURE__ */ jsx17("select", {
|
|
1342
1537
|
dir,
|
|
1343
1538
|
"data-slot": "native-select",
|
|
1344
1539
|
"data-size": size,
|
|
1345
1540
|
className: "h-control w-full min-w-0 appearance-none rounded-sm border border-input bg-secondary py-1 pe-8 ps-2.5 text-sm transition-colors outline-none select-none selection:bg-primary selection:text-primary-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:cursor-not-allowed aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive data-[size=sm]:h-control-sm data-[size=sm]:rounded-sm data-[size=sm]:py-0.5",
|
|
1346
1541
|
...props
|
|
1347
1542
|
}),
|
|
1348
|
-
/* @__PURE__ */
|
|
1543
|
+
/* @__PURE__ */ jsx17(ChevronDownIcon4, {
|
|
1349
1544
|
className: "pointer-events-none absolute top-1/2 end-2.5 size-4 -translate-y-1/2 text-muted-foreground select-none",
|
|
1350
1545
|
"aria-hidden": "true",
|
|
1351
1546
|
"data-slot": "native-select-icon"
|
|
@@ -1354,7 +1549,7 @@ function NativeSelect({
|
|
|
1354
1549
|
});
|
|
1355
1550
|
}
|
|
1356
1551
|
function NativeSelectOption({ density, className, ...props }) {
|
|
1357
|
-
return /* @__PURE__ */
|
|
1552
|
+
return /* @__PURE__ */ jsx17("option", {
|
|
1358
1553
|
"data-density": density,
|
|
1359
1554
|
"data-slot": "native-select-option",
|
|
1360
1555
|
className: cn2("bg-[Canvas] text-[CanvasText]", className),
|
|
@@ -1362,7 +1557,7 @@ function NativeSelectOption({ density, className, ...props }) {
|
|
|
1362
1557
|
});
|
|
1363
1558
|
}
|
|
1364
1559
|
function NativeSelectOptGroup({ density, className, ...props }) {
|
|
1365
|
-
return /* @__PURE__ */
|
|
1560
|
+
return /* @__PURE__ */ jsx17("optgroup", {
|
|
1366
1561
|
"data-density": density,
|
|
1367
1562
|
"data-slot": "native-select-optgroup",
|
|
1368
1563
|
className: cn2("bg-[Canvas] text-[CanvasText]", className),
|
|
@@ -1370,12 +1565,12 @@ function NativeSelectOptGroup({ density, className, ...props }) {
|
|
|
1370
1565
|
});
|
|
1371
1566
|
}
|
|
1372
1567
|
// src/components/Item.tsx
|
|
1373
|
-
import { mergeProps as
|
|
1374
|
-
import { useRender as
|
|
1568
|
+
import { mergeProps as mergeProps7 } from "@base-ui/react/merge-props";
|
|
1569
|
+
import { useRender as useRender7 } from "@base-ui/react/use-render";
|
|
1375
1570
|
import { cva as cva3 } from "class-variance-authority";
|
|
1376
|
-
import { jsx as
|
|
1571
|
+
import { jsx as jsx18 } from "react/jsx-runtime";
|
|
1377
1572
|
function ItemGroup({ density, className, ...props }) {
|
|
1378
|
-
return /* @__PURE__ */
|
|
1573
|
+
return /* @__PURE__ */ jsx18("div", {
|
|
1379
1574
|
role: "list",
|
|
1380
1575
|
"data-density": density,
|
|
1381
1576
|
"data-slot": "item-group",
|
|
@@ -1384,7 +1579,7 @@ function ItemGroup({ density, className, ...props }) {
|
|
|
1384
1579
|
});
|
|
1385
1580
|
}
|
|
1386
1581
|
function ItemSeparator({ density, className, ...props }) {
|
|
1387
|
-
return /* @__PURE__ */
|
|
1582
|
+
return /* @__PURE__ */ jsx18(Separator2, {
|
|
1388
1583
|
"data-density": density,
|
|
1389
1584
|
"data-slot": "item-separator",
|
|
1390
1585
|
orientation: "horizontal",
|
|
@@ -1418,9 +1613,9 @@ function Item({
|
|
|
1418
1613
|
render,
|
|
1419
1614
|
...props
|
|
1420
1615
|
}) {
|
|
1421
|
-
return
|
|
1616
|
+
return useRender7({
|
|
1422
1617
|
defaultTagName: "div",
|
|
1423
|
-
props:
|
|
1618
|
+
props: mergeProps7({
|
|
1424
1619
|
className: cn2(itemVariants({ variant, size, className }))
|
|
1425
1620
|
}, props),
|
|
1426
1621
|
render,
|
|
@@ -1445,7 +1640,7 @@ var itemMediaVariants = cva3("flex shrink-0 items-center justify-center gap-2 gr
|
|
|
1445
1640
|
}
|
|
1446
1641
|
});
|
|
1447
1642
|
function ItemMedia({ density, className, variant = "default", ...props }) {
|
|
1448
|
-
return /* @__PURE__ */
|
|
1643
|
+
return /* @__PURE__ */ jsx18("div", {
|
|
1449
1644
|
"data-density": density,
|
|
1450
1645
|
"data-slot": "item-media",
|
|
1451
1646
|
"data-variant": variant,
|
|
@@ -1454,7 +1649,7 @@ function ItemMedia({ density, className, variant = "default", ...props }) {
|
|
|
1454
1649
|
});
|
|
1455
1650
|
}
|
|
1456
1651
|
function ItemContent({ density, className, ...props }) {
|
|
1457
|
-
return /* @__PURE__ */
|
|
1652
|
+
return /* @__PURE__ */ jsx18("div", {
|
|
1458
1653
|
"data-density": density,
|
|
1459
1654
|
"data-slot": "item-content",
|
|
1460
1655
|
className: cn2("flex flex-1 flex-col gap-1 group-data-[size=xs]/item:gap-0 [&+[data-slot=item-content]]:flex-none", className),
|
|
@@ -1462,7 +1657,7 @@ function ItemContent({ density, className, ...props }) {
|
|
|
1462
1657
|
});
|
|
1463
1658
|
}
|
|
1464
1659
|
function ItemTitle({ density, className, ...props }) {
|
|
1465
|
-
return /* @__PURE__ */
|
|
1660
|
+
return /* @__PURE__ */ jsx18("div", {
|
|
1466
1661
|
"data-density": density,
|
|
1467
1662
|
"data-slot": "item-title",
|
|
1468
1663
|
className: cn2("line-clamp-1 flex w-fit items-center gap-2 text-sm leading-snug font-medium underline-offset-4", className),
|
|
@@ -1470,7 +1665,7 @@ function ItemTitle({ density, className, ...props }) {
|
|
|
1470
1665
|
});
|
|
1471
1666
|
}
|
|
1472
1667
|
function ItemDescription({ density, className, ...props }) {
|
|
1473
|
-
return /* @__PURE__ */
|
|
1668
|
+
return /* @__PURE__ */ jsx18("p", {
|
|
1474
1669
|
"data-density": density,
|
|
1475
1670
|
"data-slot": "item-description",
|
|
1476
1671
|
className: cn2("line-clamp-2 text-start text-sm leading-normal font-normal text-muted-foreground group-data-[size=xs]/item:text-xs [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary", className),
|
|
@@ -1478,7 +1673,7 @@ function ItemDescription({ density, className, ...props }) {
|
|
|
1478
1673
|
});
|
|
1479
1674
|
}
|
|
1480
1675
|
function ItemActions({ density, className, ...props }) {
|
|
1481
|
-
return /* @__PURE__ */
|
|
1676
|
+
return /* @__PURE__ */ jsx18("div", {
|
|
1482
1677
|
"data-density": density,
|
|
1483
1678
|
"data-slot": "item-actions",
|
|
1484
1679
|
className: cn2("flex items-center gap-2", className),
|
|
@@ -1486,7 +1681,7 @@ function ItemActions({ density, className, ...props }) {
|
|
|
1486
1681
|
});
|
|
1487
1682
|
}
|
|
1488
1683
|
function ItemHeader({ density, className, ...props }) {
|
|
1489
|
-
return /* @__PURE__ */
|
|
1684
|
+
return /* @__PURE__ */ jsx18("div", {
|
|
1490
1685
|
"data-density": density,
|
|
1491
1686
|
"data-slot": "item-header",
|
|
1492
1687
|
className: cn2("flex basis-full items-center justify-between gap-2", className),
|
|
@@ -1494,7 +1689,7 @@ function ItemHeader({ density, className, ...props }) {
|
|
|
1494
1689
|
});
|
|
1495
1690
|
}
|
|
1496
1691
|
function ItemFooter({ density, className, ...props }) {
|
|
1497
|
-
return /* @__PURE__ */
|
|
1692
|
+
return /* @__PURE__ */ jsx18("div", {
|
|
1498
1693
|
"data-density": density,
|
|
1499
1694
|
"data-slot": "item-footer",
|
|
1500
1695
|
className: cn2("flex basis-full items-center justify-between gap-2", className),
|
|
@@ -1503,9 +1698,9 @@ function ItemFooter({ density, className, ...props }) {
|
|
|
1503
1698
|
}
|
|
1504
1699
|
// src/components/Pagination.tsx
|
|
1505
1700
|
import { ChevronLeftIcon, ChevronRightIcon as ChevronRightIcon2, MoreHorizontalIcon as MoreHorizontalIcon2 } from "lucide-react";
|
|
1506
|
-
import { jsx as
|
|
1701
|
+
import { jsx as jsx19, jsxs as jsxs12 } from "react/jsx-runtime";
|
|
1507
1702
|
function Pagination({ density, className, ...props }) {
|
|
1508
|
-
return /* @__PURE__ */
|
|
1703
|
+
return /* @__PURE__ */ jsx19("nav", {
|
|
1509
1704
|
role: "navigation",
|
|
1510
1705
|
"aria-label": "pagination",
|
|
1511
1706
|
"data-density": density,
|
|
@@ -1515,7 +1710,7 @@ function Pagination({ density, className, ...props }) {
|
|
|
1515
1710
|
});
|
|
1516
1711
|
}
|
|
1517
1712
|
function PaginationContent({ density, className, ...props }) {
|
|
1518
|
-
return /* @__PURE__ */
|
|
1713
|
+
return /* @__PURE__ */ jsx19("ul", {
|
|
1519
1714
|
"data-density": density,
|
|
1520
1715
|
"data-slot": "pagination-content",
|
|
1521
1716
|
className: cn2("flex items-center gap-0.5", className),
|
|
@@ -1523,7 +1718,7 @@ function PaginationContent({ density, className, ...props }) {
|
|
|
1523
1718
|
});
|
|
1524
1719
|
}
|
|
1525
1720
|
function PaginationItem({ ...props }) {
|
|
1526
|
-
return /* @__PURE__ */
|
|
1721
|
+
return /* @__PURE__ */ jsx19("li", {
|
|
1527
1722
|
"data-slot": "pagination-item",
|
|
1528
1723
|
...props
|
|
1529
1724
|
});
|
|
@@ -1535,7 +1730,7 @@ function PaginationLink({
|
|
|
1535
1730
|
size = "icon",
|
|
1536
1731
|
...props
|
|
1537
1732
|
}) {
|
|
1538
|
-
return /* @__PURE__ */
|
|
1733
|
+
return /* @__PURE__ */ jsx19("a", {
|
|
1539
1734
|
"data-density": density,
|
|
1540
1735
|
className: cn2(buttonVariants2({ variant: isActive ? "outline" : "ghost", size }), className),
|
|
1541
1736
|
"aria-current": isActive ? "page" : undefined,
|
|
@@ -1550,18 +1745,18 @@ function PaginationPrevious({
|
|
|
1550
1745
|
text = "Previous",
|
|
1551
1746
|
...props
|
|
1552
1747
|
}) {
|
|
1553
|
-
return /* @__PURE__ */
|
|
1748
|
+
return /* @__PURE__ */ jsxs12(PaginationLink, {
|
|
1554
1749
|
density,
|
|
1555
1750
|
"aria-label": "Go to previous page",
|
|
1556
1751
|
size: "default",
|
|
1557
1752
|
className: cn2("ps-1.5!", className),
|
|
1558
1753
|
...props,
|
|
1559
1754
|
children: [
|
|
1560
|
-
/* @__PURE__ */
|
|
1755
|
+
/* @__PURE__ */ jsx19(ChevronLeftIcon, {
|
|
1561
1756
|
"data-icon": "inline-start",
|
|
1562
1757
|
className: "rtl:rotate-180"
|
|
1563
1758
|
}),
|
|
1564
|
-
/* @__PURE__ */
|
|
1759
|
+
/* @__PURE__ */ jsx19("span", {
|
|
1565
1760
|
className: "hidden sm:block",
|
|
1566
1761
|
children: text
|
|
1567
1762
|
})
|
|
@@ -1569,18 +1764,18 @@ function PaginationPrevious({
|
|
|
1569
1764
|
});
|
|
1570
1765
|
}
|
|
1571
1766
|
function PaginationNext({ density, className, text = "Next", ...props }) {
|
|
1572
|
-
return /* @__PURE__ */
|
|
1767
|
+
return /* @__PURE__ */ jsxs12(PaginationLink, {
|
|
1573
1768
|
density,
|
|
1574
1769
|
"aria-label": "Go to next page",
|
|
1575
1770
|
size: "default",
|
|
1576
1771
|
className: cn2("pe-1.5!", className),
|
|
1577
1772
|
...props,
|
|
1578
1773
|
children: [
|
|
1579
|
-
/* @__PURE__ */
|
|
1774
|
+
/* @__PURE__ */ jsx19("span", {
|
|
1580
1775
|
className: "hidden sm:block",
|
|
1581
1776
|
children: text
|
|
1582
1777
|
}),
|
|
1583
|
-
/* @__PURE__ */
|
|
1778
|
+
/* @__PURE__ */ jsx19(ChevronRightIcon2, {
|
|
1584
1779
|
"data-icon": "inline-end",
|
|
1585
1780
|
className: "rtl:rotate-180"
|
|
1586
1781
|
})
|
|
@@ -1588,15 +1783,15 @@ function PaginationNext({ density, className, text = "Next", ...props }) {
|
|
|
1588
1783
|
});
|
|
1589
1784
|
}
|
|
1590
1785
|
function PaginationEllipsis({ density, className, ...props }) {
|
|
1591
|
-
return /* @__PURE__ */
|
|
1786
|
+
return /* @__PURE__ */ jsxs12("span", {
|
|
1592
1787
|
"aria-hidden": true,
|
|
1593
1788
|
"data-density": density,
|
|
1594
1789
|
"data-slot": "pagination-ellipsis",
|
|
1595
1790
|
className: cn2("flex size-control items-center justify-center [&_svg:not([class*='size-'])]:size-4", className),
|
|
1596
1791
|
...props,
|
|
1597
1792
|
children: [
|
|
1598
|
-
/* @__PURE__ */
|
|
1599
|
-
/* @__PURE__ */
|
|
1793
|
+
/* @__PURE__ */ jsx19(MoreHorizontalIcon2, {}),
|
|
1794
|
+
/* @__PURE__ */ jsx19("span", {
|
|
1600
1795
|
className: "sr-only",
|
|
1601
1796
|
children: "More pages"
|
|
1602
1797
|
})
|
|
@@ -1605,39 +1800,39 @@ function PaginationEllipsis({ density, className, ...props }) {
|
|
|
1605
1800
|
}
|
|
1606
1801
|
// src/components/ScrollArea.tsx
|
|
1607
1802
|
import { ScrollArea as ScrollAreaPrimitive } from "@base-ui/react/scroll-area";
|
|
1608
|
-
import { jsx as
|
|
1803
|
+
import { jsx as jsx20, jsxs as jsxs13 } from "react/jsx-runtime";
|
|
1609
1804
|
function ScrollArea({
|
|
1610
1805
|
density,
|
|
1611
1806
|
className,
|
|
1612
1807
|
children,
|
|
1613
|
-
scrollbars = /* @__PURE__ */
|
|
1808
|
+
scrollbars = /* @__PURE__ */ jsx20(ScrollBar, {}),
|
|
1614
1809
|
...props
|
|
1615
1810
|
}) {
|
|
1616
|
-
return /* @__PURE__ */
|
|
1811
|
+
return /* @__PURE__ */ jsxs13(ScrollAreaPrimitive.Root, {
|
|
1617
1812
|
"data-density": density,
|
|
1618
1813
|
"data-slot": "scroll-area",
|
|
1619
|
-
className: (state) => cn2("relative", typeof className === "function" ? className(state) : className),
|
|
1814
|
+
className: (state) => cn2("relative flex min-h-0 flex-col", typeof className === "function" ? className(state) : className),
|
|
1620
1815
|
...props,
|
|
1621
1816
|
children: [
|
|
1622
|
-
/* @__PURE__ */
|
|
1817
|
+
/* @__PURE__ */ jsx20(ScrollAreaPrimitive.Viewport, {
|
|
1623
1818
|
"data-slot": "scroll-area-viewport",
|
|
1624
|
-
className: "size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:outline-1",
|
|
1819
|
+
className: "size-full min-h-0 flex-1 rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:outline-1",
|
|
1625
1820
|
children
|
|
1626
1821
|
}),
|
|
1627
1822
|
scrollbars,
|
|
1628
|
-
/* @__PURE__ */
|
|
1823
|
+
/* @__PURE__ */ jsx20(ScrollAreaPrimitive.Corner, {})
|
|
1629
1824
|
]
|
|
1630
1825
|
});
|
|
1631
1826
|
}
|
|
1632
1827
|
function ScrollBar({ density, className, orientation = "vertical", ...props }) {
|
|
1633
|
-
return /* @__PURE__ */
|
|
1828
|
+
return /* @__PURE__ */ jsx20(ScrollAreaPrimitive.Scrollbar, {
|
|
1634
1829
|
"data-density": density,
|
|
1635
1830
|
"data-slot": "scroll-area-scrollbar",
|
|
1636
1831
|
"data-orientation": orientation,
|
|
1637
1832
|
orientation,
|
|
1638
1833
|
className: (state) => cn2("flex touch-none p-px transition-colors select-none data-[orientation=horizontal]:h-2.5 data-[orientation=horizontal]:flex-col data-[orientation=horizontal]:border-t data-[orientation=horizontal]:border-t-transparent data-[orientation=vertical]:w-2.5 data-[orientation=vertical]:border-s data-[orientation=vertical]:border-s-transparent", typeof className === "function" ? className(state) : className),
|
|
1639
1834
|
...props,
|
|
1640
|
-
children: /* @__PURE__ */
|
|
1835
|
+
children: /* @__PURE__ */ jsx20(ScrollAreaPrimitive.Thumb, {
|
|
1641
1836
|
"data-slot": "scroll-area-thumb",
|
|
1642
1837
|
className: "relative flex-1 rounded-full bg-border"
|
|
1643
1838
|
})
|
|
@@ -1662,7 +1857,7 @@ function useDrawer() {
|
|
|
1662
1857
|
|
|
1663
1858
|
// src/components/Drawer.tsx
|
|
1664
1859
|
import { Drawer as DrawerPrimitive } from "@base-ui/react/drawer";
|
|
1665
|
-
import { jsx as
|
|
1860
|
+
import { jsx as jsx21, jsxs as jsxs14 } from "react/jsx-runtime";
|
|
1666
1861
|
function Drawer({
|
|
1667
1862
|
modal = true,
|
|
1668
1863
|
showSwipeHandle = false,
|
|
@@ -1672,9 +1867,9 @@ function Drawer({
|
|
|
1672
1867
|
}) {
|
|
1673
1868
|
const hasSnapPoints = snapPoints != null && snapPoints.length > 0;
|
|
1674
1869
|
const contextValue = useMemo2(() => ({ hasSnapPoints, modal, showSwipeHandle, swipeDirection }), [hasSnapPoints, modal, showSwipeHandle, swipeDirection]);
|
|
1675
|
-
return /* @__PURE__ */
|
|
1870
|
+
return /* @__PURE__ */ jsx21(DrawerContext.Provider, {
|
|
1676
1871
|
value: contextValue,
|
|
1677
|
-
children: /* @__PURE__ */
|
|
1872
|
+
children: /* @__PURE__ */ jsx21(DrawerPrimitive.Root, {
|
|
1678
1873
|
"data-slot": "drawer",
|
|
1679
1874
|
modal,
|
|
1680
1875
|
snapPoints,
|
|
@@ -1684,28 +1879,34 @@ function Drawer({
|
|
|
1684
1879
|
});
|
|
1685
1880
|
}
|
|
1686
1881
|
function DrawerTrigger({ ...props }) {
|
|
1687
|
-
return /* @__PURE__ */
|
|
1882
|
+
return /* @__PURE__ */ jsx21(DrawerPrimitive.Trigger, {
|
|
1688
1883
|
"data-slot": "drawer-trigger",
|
|
1689
1884
|
...props
|
|
1690
1885
|
});
|
|
1691
1886
|
}
|
|
1692
|
-
function DrawerPortal({ container, ...props }) {
|
|
1887
|
+
function DrawerPortal({ container, ref, children, ...props }) {
|
|
1693
1888
|
const resolvedContainer = usePortalContainer2(container);
|
|
1694
|
-
|
|
1889
|
+
const portal = usePortalNode(ref);
|
|
1890
|
+
return /* @__PURE__ */ jsx21(DrawerPrimitive.Portal, {
|
|
1695
1891
|
"data-slot": "drawer-portal",
|
|
1696
1892
|
container: resolvedContainer,
|
|
1697
|
-
|
|
1893
|
+
ref: portal.ref,
|
|
1894
|
+
...props,
|
|
1895
|
+
children: /* @__PURE__ */ jsx21(PortalProvider2, {
|
|
1896
|
+
container: portal.node,
|
|
1897
|
+
children
|
|
1898
|
+
})
|
|
1698
1899
|
});
|
|
1699
1900
|
}
|
|
1700
1901
|
function DrawerClose({ ...props }) {
|
|
1701
|
-
return /* @__PURE__ */
|
|
1902
|
+
return /* @__PURE__ */ jsx21(DrawerPrimitive.Close, {
|
|
1702
1903
|
"data-slot": "drawer-close",
|
|
1703
1904
|
...props
|
|
1704
1905
|
});
|
|
1705
1906
|
}
|
|
1706
1907
|
function DrawerOverlay({ density, className, ...props }) {
|
|
1707
1908
|
const resolvedDensity = useDensity(density);
|
|
1708
|
-
return /* @__PURE__ */
|
|
1909
|
+
return /* @__PURE__ */ jsx21(DrawerPrimitive.Backdrop, {
|
|
1709
1910
|
"data-density": resolvedDensity,
|
|
1710
1911
|
"data-slot": "drawer-overlay",
|
|
1711
1912
|
className: (state) => cn2("fixed inset-0 min-h-dvh bg-backdrop 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-[-webkit-touch-callout:none]:absolute", typeof className === "function" ? className(state) : className),
|
|
@@ -1713,7 +1914,7 @@ function DrawerOverlay({ density, className, ...props }) {
|
|
|
1713
1914
|
});
|
|
1714
1915
|
}
|
|
1715
1916
|
function DrawerSwipeHandle({ density, className, ...props }) {
|
|
1716
|
-
return /* @__PURE__ */
|
|
1917
|
+
return /* @__PURE__ */ jsx21("div", {
|
|
1717
1918
|
"data-density": density,
|
|
1718
1919
|
"data-slot": "drawer-swipe-handle",
|
|
1719
1920
|
"aria-hidden": "true",
|
|
@@ -1726,28 +1927,30 @@ function DrawerContent({ density, className, children, ...props }) {
|
|
|
1726
1927
|
const direction = useDirection2();
|
|
1727
1928
|
const { hasSnapPoints, modal, showSwipeHandle, swipeDirection } = useDrawer();
|
|
1728
1929
|
const swipeAxis = swipeDirection === "down" || swipeDirection === "up" ? "y" : "x";
|
|
1729
|
-
return /* @__PURE__ */
|
|
1930
|
+
return /* @__PURE__ */ jsxs14(DrawerPortal, {
|
|
1730
1931
|
"data-slot": "drawer-portal",
|
|
1731
1932
|
children: [
|
|
1732
|
-
modal === true && /* @__PURE__ */
|
|
1933
|
+
modal === true && /* @__PURE__ */ jsx21(DrawerOverlay, {
|
|
1733
1934
|
"data-snap-points": hasSnapPoints ? "" : undefined
|
|
1734
1935
|
}),
|
|
1735
|
-
/* @__PURE__ */
|
|
1936
|
+
/* @__PURE__ */ jsx21(DrawerPrimitive.Viewport, {
|
|
1736
1937
|
dir: direction,
|
|
1737
1938
|
"data-slot": "drawer-viewport",
|
|
1738
1939
|
"data-modal": modal,
|
|
1739
1940
|
className: "pointer-events-none fixed inset-0 select-none data-[modal=true]:pointer-events-auto",
|
|
1740
|
-
children: /* @__PURE__ */
|
|
1941
|
+
children: /* @__PURE__ */ jsxs14(DrawerPrimitive.Popup, {
|
|
1741
1942
|
"data-density": resolvedDensity,
|
|
1742
1943
|
"data-slot": "drawer-popup",
|
|
1944
|
+
"data-scroll": "none",
|
|
1743
1945
|
"data-swipe-axis": swipeAxis,
|
|
1744
1946
|
"data-snap-points": hasSnapPoints ? "" : undefined,
|
|
1745
1947
|
className: (state) => cn2("group/drawer-popup pointer-events-auto fixed 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)] flex-col border border-frame-edge shadow-frame bg-popover text-sm 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 [interpolate-size:allow-keywords] data-[swipe-direction=down]:rounded-t-md data-[swipe-direction=down]:border-t data-[swipe-direction=left]:rounded-r-md data-[swipe-direction=left]:border-r data-[swipe-direction=right]:rounded-l-md data-[swipe-direction=right]:border-l data-[swipe-direction=up]:rounded-b-md data-[swipe-direction=up]:border-b", "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-shrink:0]", "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%))]", typeof className === "function" ? className(state) : className),
|
|
1746
1948
|
...props,
|
|
1747
1949
|
children: [
|
|
1748
|
-
showSwipeHandle && /* @__PURE__ */
|
|
1749
|
-
/* @__PURE__ */
|
|
1950
|
+
showSwipeHandle && /* @__PURE__ */ jsx21(DrawerSwipeHandle, {}),
|
|
1951
|
+
/* @__PURE__ */ jsx21(DrawerPrimitive.Content, {
|
|
1750
1952
|
"data-slot": "drawer-content",
|
|
1953
|
+
"data-scroll": "none",
|
|
1751
1954
|
className: "flex min-h-0 flex-1 flex-col overflow-hidden overscroll-contain rounded-[inherit] transition-opacity duration-300 ease-out 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",
|
|
1752
1955
|
children
|
|
1753
1956
|
})
|
|
@@ -1758,7 +1961,7 @@ function DrawerContent({ density, className, children, ...props }) {
|
|
|
1758
1961
|
});
|
|
1759
1962
|
}
|
|
1760
1963
|
function DrawerHeader({ density, className, ...props }) {
|
|
1761
|
-
return /* @__PURE__ */
|
|
1964
|
+
return /* @__PURE__ */ jsx21("div", {
|
|
1762
1965
|
"data-density": density,
|
|
1763
1966
|
"data-slot": "drawer-header",
|
|
1764
1967
|
className: cn2("flex shrink-0 flex-col gap-0.5 p-panel pb-0 group-data-[swipe-axis=y]/drawer-popup:text-center md:gap-0.5 md:text-start md:group-data-[swipe-axis=y]/drawer-popup:text-start", className),
|
|
@@ -1766,7 +1969,7 @@ function DrawerHeader({ density, className, ...props }) {
|
|
|
1766
1969
|
});
|
|
1767
1970
|
}
|
|
1768
1971
|
function DrawerFooter({ density, className, ...props }) {
|
|
1769
|
-
return /* @__PURE__ */
|
|
1972
|
+
return /* @__PURE__ */ jsx21("div", {
|
|
1770
1973
|
"data-density": density,
|
|
1771
1974
|
"data-slot": "drawer-footer",
|
|
1772
1975
|
className: cn2("mt-auto flex shrink-0 flex-col gap-2 p-panel pt-0", className),
|
|
@@ -1774,7 +1977,7 @@ function DrawerFooter({ density, className, ...props }) {
|
|
|
1774
1977
|
});
|
|
1775
1978
|
}
|
|
1776
1979
|
function DrawerTitle({ density, className, ...props }) {
|
|
1777
|
-
return /* @__PURE__ */
|
|
1980
|
+
return /* @__PURE__ */ jsx21(DrawerPrimitive.Title, {
|
|
1778
1981
|
"data-density": density,
|
|
1779
1982
|
"data-slot": "drawer-title",
|
|
1780
1983
|
className: (state) => cn2(" text-base font-medium text-foreground", typeof className === "function" ? className(state) : className),
|
|
@@ -1782,7 +1985,7 @@ function DrawerTitle({ density, className, ...props }) {
|
|
|
1782
1985
|
});
|
|
1783
1986
|
}
|
|
1784
1987
|
function DrawerDescription({ density, className, ...props }) {
|
|
1785
|
-
return /* @__PURE__ */
|
|
1988
|
+
return /* @__PURE__ */ jsx21(DrawerPrimitive.Description, {
|
|
1786
1989
|
"data-density": density,
|
|
1787
1990
|
"data-slot": "drawer-description",
|
|
1788
1991
|
className: (state) => cn2("text-sm text-balance text-muted-foreground", typeof className === "function" ? className(state) : className),
|
|
@@ -1793,23 +1996,29 @@ function DrawerDescription({ density, className, ...props }) {
|
|
|
1793
1996
|
import { ChevronRightIcon as ChevronRightIcon3, CheckIcon as CheckIcon3 } from "lucide-react";
|
|
1794
1997
|
import { useDirection as useDirection5 } from "@base-ui/react/direction-provider";
|
|
1795
1998
|
import { ContextMenu as ContextMenuPrimitive } from "@base-ui/react/context-menu";
|
|
1796
|
-
import { jsx as
|
|
1999
|
+
import { jsx as jsx22, jsxs as jsxs15 } from "react/jsx-runtime";
|
|
1797
2000
|
function ContextMenu({ ...props }) {
|
|
1798
|
-
return /* @__PURE__ */
|
|
2001
|
+
return /* @__PURE__ */ jsx22(ContextMenuPrimitive.Root, {
|
|
1799
2002
|
"data-slot": "context-menu",
|
|
1800
2003
|
...props
|
|
1801
2004
|
});
|
|
1802
2005
|
}
|
|
1803
|
-
function ContextMenuPortal({ container, ...props }) {
|
|
2006
|
+
function ContextMenuPortal({ container, ref, children, ...props }) {
|
|
1804
2007
|
const resolvedContainer = usePortalContainer2(container);
|
|
1805
|
-
|
|
2008
|
+
const portal = usePortalNode(ref);
|
|
2009
|
+
return /* @__PURE__ */ jsx22(ContextMenuPrimitive.Portal, {
|
|
1806
2010
|
"data-slot": "context-menu-portal",
|
|
1807
2011
|
container: resolvedContainer,
|
|
1808
|
-
|
|
2012
|
+
ref: portal.ref,
|
|
2013
|
+
...props,
|
|
2014
|
+
children: /* @__PURE__ */ jsx22(PortalProvider2, {
|
|
2015
|
+
container: portal.node,
|
|
2016
|
+
children
|
|
2017
|
+
})
|
|
1809
2018
|
});
|
|
1810
2019
|
}
|
|
1811
2020
|
function ContextMenuTrigger({ density, className, ...props }) {
|
|
1812
|
-
return /* @__PURE__ */
|
|
2021
|
+
return /* @__PURE__ */ jsx22(ContextMenuPrimitive.Trigger, {
|
|
1813
2022
|
"data-density": density,
|
|
1814
2023
|
"data-slot": "context-menu-trigger",
|
|
1815
2024
|
className: (state) => cn2("select-none", typeof className === "function" ? className(state) : className),
|
|
@@ -1827,15 +2036,15 @@ function ContextMenuContent({
|
|
|
1827
2036
|
}) {
|
|
1828
2037
|
const resolvedDensity = useDensity(density);
|
|
1829
2038
|
const direction = useDirection5();
|
|
1830
|
-
return /* @__PURE__ */
|
|
1831
|
-
children: /* @__PURE__ */
|
|
2039
|
+
return /* @__PURE__ */ jsx22(ContextMenuPortal, {
|
|
2040
|
+
children: /* @__PURE__ */ jsx22(ContextMenuPrimitive.Positioner, {
|
|
1832
2041
|
dir: direction,
|
|
1833
2042
|
className: "isolate outline-none",
|
|
1834
2043
|
align,
|
|
1835
2044
|
alignOffset,
|
|
1836
2045
|
side,
|
|
1837
2046
|
sideOffset,
|
|
1838
|
-
children: /* @__PURE__ */
|
|
2047
|
+
children: /* @__PURE__ */ jsx22(ContextMenuPrimitive.Popup, {
|
|
1839
2048
|
dir: direction,
|
|
1840
2049
|
"data-density": resolvedDensity,
|
|
1841
2050
|
"data-slot": "context-menu-content",
|
|
@@ -1846,13 +2055,13 @@ function ContextMenuContent({
|
|
|
1846
2055
|
});
|
|
1847
2056
|
}
|
|
1848
2057
|
function ContextMenuGroup({ ...props }) {
|
|
1849
|
-
return /* @__PURE__ */
|
|
2058
|
+
return /* @__PURE__ */ jsx22(ContextMenuPrimitive.Group, {
|
|
1850
2059
|
"data-slot": "context-menu-group",
|
|
1851
2060
|
...props
|
|
1852
2061
|
});
|
|
1853
2062
|
}
|
|
1854
2063
|
function ContextMenuLabel({ density, className, inset, ...props }) {
|
|
1855
|
-
return /* @__PURE__ */
|
|
2064
|
+
return /* @__PURE__ */ jsx22(ContextMenuPrimitive.GroupLabel, {
|
|
1856
2065
|
"data-density": density,
|
|
1857
2066
|
"data-slot": "context-menu-label",
|
|
1858
2067
|
"data-inset": inset,
|
|
@@ -1861,7 +2070,7 @@ function ContextMenuLabel({ density, className, inset, ...props }) {
|
|
|
1861
2070
|
});
|
|
1862
2071
|
}
|
|
1863
2072
|
function ContextMenuItem({ density, className, inset, variant = "default", ...props }) {
|
|
1864
|
-
return /* @__PURE__ */
|
|
2073
|
+
return /* @__PURE__ */ jsx22(ContextMenuPrimitive.Item, {
|
|
1865
2074
|
"data-density": density,
|
|
1866
2075
|
"data-slot": "context-menu-item",
|
|
1867
2076
|
"data-inset": inset,
|
|
@@ -1871,13 +2080,13 @@ function ContextMenuItem({ density, className, inset, variant = "default", ...pr
|
|
|
1871
2080
|
});
|
|
1872
2081
|
}
|
|
1873
2082
|
function ContextMenuSub({ ...props }) {
|
|
1874
|
-
return /* @__PURE__ */
|
|
2083
|
+
return /* @__PURE__ */ jsx22(ContextMenuPrimitive.SubmenuRoot, {
|
|
1875
2084
|
"data-slot": "context-menu-sub",
|
|
1876
2085
|
...props
|
|
1877
2086
|
});
|
|
1878
2087
|
}
|
|
1879
2088
|
function ContextMenuSubTrigger({ density, className, inset, children, ...props }) {
|
|
1880
|
-
return /* @__PURE__ */
|
|
2089
|
+
return /* @__PURE__ */ jsxs15(ContextMenuPrimitive.SubmenuTrigger, {
|
|
1881
2090
|
"data-density": density,
|
|
1882
2091
|
"data-slot": "context-menu-sub-trigger",
|
|
1883
2092
|
"data-inset": inset,
|
|
@@ -1885,14 +2094,14 @@ function ContextMenuSubTrigger({ density, className, inset, children, ...props }
|
|
|
1885
2094
|
...props,
|
|
1886
2095
|
children: [
|
|
1887
2096
|
children,
|
|
1888
|
-
/* @__PURE__ */
|
|
2097
|
+
/* @__PURE__ */ jsx22(ChevronRightIcon3, {
|
|
1889
2098
|
className: "rtl:rotate-180 ms-auto"
|
|
1890
2099
|
})
|
|
1891
2100
|
]
|
|
1892
2101
|
});
|
|
1893
2102
|
}
|
|
1894
2103
|
function ContextMenuSubContent({ ...props }) {
|
|
1895
|
-
return /* @__PURE__ */
|
|
2104
|
+
return /* @__PURE__ */ jsx22(ContextMenuContent, {
|
|
1896
2105
|
"data-slot": "context-menu-sub-content",
|
|
1897
2106
|
className: " shadow-frame border border-frame-edge",
|
|
1898
2107
|
side: "inline-end",
|
|
@@ -1907,7 +2116,7 @@ function ContextMenuCheckboxItem({
|
|
|
1907
2116
|
inset,
|
|
1908
2117
|
...props
|
|
1909
2118
|
}) {
|
|
1910
|
-
return /* @__PURE__ */
|
|
2119
|
+
return /* @__PURE__ */ jsxs15(ContextMenuPrimitive.CheckboxItem, {
|
|
1911
2120
|
"data-density": density,
|
|
1912
2121
|
"data-slot": "context-menu-checkbox-item",
|
|
1913
2122
|
"data-inset": inset,
|
|
@@ -1915,10 +2124,10 @@ function ContextMenuCheckboxItem({
|
|
|
1915
2124
|
checked,
|
|
1916
2125
|
...props,
|
|
1917
2126
|
children: [
|
|
1918
|
-
/* @__PURE__ */
|
|
2127
|
+
/* @__PURE__ */ jsx22("span", {
|
|
1919
2128
|
className: "pointer-events-none absolute end-2",
|
|
1920
|
-
children: /* @__PURE__ */
|
|
1921
|
-
children: /* @__PURE__ */
|
|
2129
|
+
children: /* @__PURE__ */ jsx22(ContextMenuPrimitive.CheckboxItemIndicator, {
|
|
2130
|
+
children: /* @__PURE__ */ jsx22(CheckIcon3, {})
|
|
1922
2131
|
})
|
|
1923
2132
|
}),
|
|
1924
2133
|
children
|
|
@@ -1926,23 +2135,23 @@ function ContextMenuCheckboxItem({
|
|
|
1926
2135
|
});
|
|
1927
2136
|
}
|
|
1928
2137
|
function ContextMenuRadioGroup({ ...props }) {
|
|
1929
|
-
return /* @__PURE__ */
|
|
2138
|
+
return /* @__PURE__ */ jsx22(ContextMenuPrimitive.RadioGroup, {
|
|
1930
2139
|
"data-slot": "context-menu-radio-group",
|
|
1931
2140
|
...props
|
|
1932
2141
|
});
|
|
1933
2142
|
}
|
|
1934
2143
|
function ContextMenuRadioItem({ density, className, children, inset, ...props }) {
|
|
1935
|
-
return /* @__PURE__ */
|
|
2144
|
+
return /* @__PURE__ */ jsxs15(ContextMenuPrimitive.RadioItem, {
|
|
1936
2145
|
"data-density": density,
|
|
1937
2146
|
"data-slot": "context-menu-radio-item",
|
|
1938
2147
|
"data-inset": inset,
|
|
1939
2148
|
className: (state) => cn2("relative flex cursor-default items-center gap-control-gap rounded-md py-1 pe-8 ps-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-inset:ps-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", typeof className === "function" ? className(state) : className),
|
|
1940
2149
|
...props,
|
|
1941
2150
|
children: [
|
|
1942
|
-
/* @__PURE__ */
|
|
2151
|
+
/* @__PURE__ */ jsx22("span", {
|
|
1943
2152
|
className: "pointer-events-none absolute end-2",
|
|
1944
|
-
children: /* @__PURE__ */
|
|
1945
|
-
children: /* @__PURE__ */
|
|
2153
|
+
children: /* @__PURE__ */ jsx22(ContextMenuPrimitive.RadioItemIndicator, {
|
|
2154
|
+
children: /* @__PURE__ */ jsx22(CheckIcon3, {})
|
|
1946
2155
|
})
|
|
1947
2156
|
}),
|
|
1948
2157
|
children
|
|
@@ -1950,7 +2159,7 @@ function ContextMenuRadioItem({ density, className, children, inset, ...props })
|
|
|
1950
2159
|
});
|
|
1951
2160
|
}
|
|
1952
2161
|
function ContextMenuSeparator({ density, className, ...props }) {
|
|
1953
|
-
return /* @__PURE__ */
|
|
2162
|
+
return /* @__PURE__ */ jsx22(ContextMenuPrimitive.Separator, {
|
|
1954
2163
|
"data-density": density,
|
|
1955
2164
|
"data-slot": "context-menu-separator",
|
|
1956
2165
|
className: (state) => cn2("-mx-1 my-1 h-px bg-border", typeof className === "function" ? className(state) : className),
|
|
@@ -1958,7 +2167,7 @@ function ContextMenuSeparator({ density, className, ...props }) {
|
|
|
1958
2167
|
});
|
|
1959
2168
|
}
|
|
1960
2169
|
function ContextMenuShortcut({ density, className, ...props }) {
|
|
1961
|
-
return /* @__PURE__ */
|
|
2170
|
+
return /* @__PURE__ */ jsx22("span", {
|
|
1962
2171
|
"data-density": density,
|
|
1963
2172
|
"data-slot": "context-menu-shortcut",
|
|
1964
2173
|
className: cn2("ms-auto text-xs tracking-widest text-muted-foreground group-focus/context-menu-item:text-accent-foreground", className),
|
|
@@ -1969,9 +2178,9 @@ function ContextMenuShortcut({ density, className, ...props }) {
|
|
|
1969
2178
|
import { CheckIcon as CheckIcon4 } from "lucide-react";
|
|
1970
2179
|
import { Menu as MenuPrimitive } from "@base-ui/react/menu";
|
|
1971
2180
|
import { Menubar as MenubarPrimitive } from "@base-ui/react/menubar";
|
|
1972
|
-
import { jsx as
|
|
2181
|
+
import { jsx as jsx23, jsxs as jsxs16 } from "react/jsx-runtime";
|
|
1973
2182
|
function Menubar({ density, className, ...props }) {
|
|
1974
|
-
return /* @__PURE__ */
|
|
2183
|
+
return /* @__PURE__ */ jsx23(MenubarPrimitive, {
|
|
1975
2184
|
"data-density": density,
|
|
1976
2185
|
"data-slot": "menubar",
|
|
1977
2186
|
className: (state) => cn2("flex h-control items-center gap-0.5 rounded-sm border p-px", typeof className === "function" ? className(state) : className),
|
|
@@ -1979,25 +2188,25 @@ function Menubar({ density, className, ...props }) {
|
|
|
1979
2188
|
});
|
|
1980
2189
|
}
|
|
1981
2190
|
function MenubarMenu({ ...props }) {
|
|
1982
|
-
return /* @__PURE__ */
|
|
2191
|
+
return /* @__PURE__ */ jsx23(DropdownMenu2, {
|
|
1983
2192
|
"data-slot": "menubar-menu",
|
|
1984
2193
|
...props
|
|
1985
2194
|
});
|
|
1986
2195
|
}
|
|
1987
2196
|
function MenubarGroup({ ...props }) {
|
|
1988
|
-
return /* @__PURE__ */
|
|
2197
|
+
return /* @__PURE__ */ jsx23(DropdownMenuGroup2, {
|
|
1989
2198
|
"data-slot": "menubar-group",
|
|
1990
2199
|
...props
|
|
1991
2200
|
});
|
|
1992
2201
|
}
|
|
1993
2202
|
function MenubarPortal({ ...props }) {
|
|
1994
|
-
return /* @__PURE__ */
|
|
2203
|
+
return /* @__PURE__ */ jsx23(DropdownMenuPortal2, {
|
|
1995
2204
|
"data-slot": "menubar-portal",
|
|
1996
2205
|
...props
|
|
1997
2206
|
});
|
|
1998
2207
|
}
|
|
1999
2208
|
function MenubarTrigger({ density, className, ...props }) {
|
|
2000
|
-
return /* @__PURE__ */
|
|
2209
|
+
return /* @__PURE__ */ jsx23(DropdownMenuTrigger2, {
|
|
2001
2210
|
"data-density": density,
|
|
2002
2211
|
"data-slot": "menubar-trigger",
|
|
2003
2212
|
className: (state) => cn2("flex h-full items-center rounded-sm px-control-x text-sm leading-none font-medium outline-hidden select-none hover:bg-muted aria-expanded:bg-muted", typeof className === "function" ? className(state) : className),
|
|
@@ -2012,7 +2221,7 @@ function MenubarContent({
|
|
|
2012
2221
|
sideOffset = 8,
|
|
2013
2222
|
...props
|
|
2014
2223
|
}) {
|
|
2015
|
-
return /* @__PURE__ */
|
|
2224
|
+
return /* @__PURE__ */ jsx23(DropdownMenuContent2, {
|
|
2016
2225
|
density,
|
|
2017
2226
|
"data-slot": "menubar-content",
|
|
2018
2227
|
align,
|
|
@@ -2023,7 +2232,7 @@ function MenubarContent({
|
|
|
2023
2232
|
});
|
|
2024
2233
|
}
|
|
2025
2234
|
function MenubarItem({ density, className, inset, variant = "default", ...props }) {
|
|
2026
|
-
return /* @__PURE__ */
|
|
2235
|
+
return /* @__PURE__ */ jsx23(DropdownMenuItem2, {
|
|
2027
2236
|
density,
|
|
2028
2237
|
"data-slot": "menubar-item",
|
|
2029
2238
|
inset,
|
|
@@ -2040,7 +2249,7 @@ function MenubarCheckboxItem({
|
|
|
2040
2249
|
inset,
|
|
2041
2250
|
...props
|
|
2042
2251
|
}) {
|
|
2043
|
-
return /* @__PURE__ */
|
|
2252
|
+
return /* @__PURE__ */ jsxs16(MenuPrimitive.CheckboxItem, {
|
|
2044
2253
|
"data-density": density,
|
|
2045
2254
|
"data-slot": "menubar-checkbox-item",
|
|
2046
2255
|
"data-inset": inset,
|
|
@@ -2048,10 +2257,10 @@ function MenubarCheckboxItem({
|
|
|
2048
2257
|
checked,
|
|
2049
2258
|
...props,
|
|
2050
2259
|
children: [
|
|
2051
|
-
/* @__PURE__ */
|
|
2260
|
+
/* @__PURE__ */ jsx23("span", {
|
|
2052
2261
|
className: "pointer-events-none absolute start-1.5 flex size-4 items-center justify-center [&_svg:not([class*='size-'])]:size-4",
|
|
2053
|
-
children: /* @__PURE__ */
|
|
2054
|
-
children: /* @__PURE__ */
|
|
2262
|
+
children: /* @__PURE__ */ jsx23(MenuPrimitive.CheckboxItemIndicator, {
|
|
2263
|
+
children: /* @__PURE__ */ jsx23(CheckIcon4, {})
|
|
2055
2264
|
})
|
|
2056
2265
|
}),
|
|
2057
2266
|
children
|
|
@@ -2059,23 +2268,23 @@ function MenubarCheckboxItem({
|
|
|
2059
2268
|
});
|
|
2060
2269
|
}
|
|
2061
2270
|
function MenubarRadioGroup({ ...props }) {
|
|
2062
|
-
return /* @__PURE__ */
|
|
2271
|
+
return /* @__PURE__ */ jsx23(DropdownMenuRadioGroup2, {
|
|
2063
2272
|
"data-slot": "menubar-radio-group",
|
|
2064
2273
|
...props
|
|
2065
2274
|
});
|
|
2066
2275
|
}
|
|
2067
2276
|
function MenubarRadioItem({ density, className, children, inset, ...props }) {
|
|
2068
|
-
return /* @__PURE__ */
|
|
2277
|
+
return /* @__PURE__ */ jsxs16(MenuPrimitive.RadioItem, {
|
|
2069
2278
|
"data-density": density,
|
|
2070
2279
|
"data-slot": "menubar-radio-item",
|
|
2071
2280
|
"data-inset": inset,
|
|
2072
2281
|
className: (state) => cn2("relative flex cursor-default items-center gap-control-gap rounded-md py-1 pe-1.5 ps-7 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-inset:ps-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", typeof className === "function" ? className(state) : className),
|
|
2073
2282
|
...props,
|
|
2074
2283
|
children: [
|
|
2075
|
-
/* @__PURE__ */
|
|
2284
|
+
/* @__PURE__ */ jsx23("span", {
|
|
2076
2285
|
className: "pointer-events-none absolute start-1.5 flex size-4 items-center justify-center [&_svg:not([class*='size-'])]:size-4",
|
|
2077
|
-
children: /* @__PURE__ */
|
|
2078
|
-
children: /* @__PURE__ */
|
|
2286
|
+
children: /* @__PURE__ */ jsx23(MenuPrimitive.RadioItemIndicator, {
|
|
2287
|
+
children: /* @__PURE__ */ jsx23(CheckIcon4, {})
|
|
2079
2288
|
})
|
|
2080
2289
|
}),
|
|
2081
2290
|
children
|
|
@@ -2083,7 +2292,7 @@ function MenubarRadioItem({ density, className, children, inset, ...props }) {
|
|
|
2083
2292
|
});
|
|
2084
2293
|
}
|
|
2085
2294
|
function MenubarLabel({ density, className, inset, ...props }) {
|
|
2086
|
-
return /* @__PURE__ */
|
|
2295
|
+
return /* @__PURE__ */ jsx23(DropdownMenuLabel2, {
|
|
2087
2296
|
density,
|
|
2088
2297
|
"data-slot": "menubar-label",
|
|
2089
2298
|
inset,
|
|
@@ -2092,7 +2301,7 @@ function MenubarLabel({ density, className, inset, ...props }) {
|
|
|
2092
2301
|
});
|
|
2093
2302
|
}
|
|
2094
2303
|
function MenubarSeparator({ density, className, ...props }) {
|
|
2095
|
-
return /* @__PURE__ */
|
|
2304
|
+
return /* @__PURE__ */ jsx23(DropdownMenuSeparator2, {
|
|
2096
2305
|
density,
|
|
2097
2306
|
"data-slot": "menubar-separator",
|
|
2098
2307
|
className: (state) => cn2("-mx-1 my-1 h-px bg-border", typeof className === "function" ? className(state) : className),
|
|
@@ -2100,7 +2309,7 @@ function MenubarSeparator({ density, className, ...props }) {
|
|
|
2100
2309
|
});
|
|
2101
2310
|
}
|
|
2102
2311
|
function MenubarShortcut({ density, className, ...props }) {
|
|
2103
|
-
return /* @__PURE__ */
|
|
2312
|
+
return /* @__PURE__ */ jsx23(DropdownMenuShortcut2, {
|
|
2104
2313
|
"data-density": density,
|
|
2105
2314
|
"data-slot": "menubar-shortcut",
|
|
2106
2315
|
className: cn2("ms-auto text-xs tracking-widest text-muted-foreground group-focus/menubar-item:text-accent-foreground", className),
|
|
@@ -2108,13 +2317,13 @@ function MenubarShortcut({ density, className, ...props }) {
|
|
|
2108
2317
|
});
|
|
2109
2318
|
}
|
|
2110
2319
|
function MenubarSub({ ...props }) {
|
|
2111
|
-
return /* @__PURE__ */
|
|
2320
|
+
return /* @__PURE__ */ jsx23(DropdownMenuSub2, {
|
|
2112
2321
|
"data-slot": "menubar-sub",
|
|
2113
2322
|
...props
|
|
2114
2323
|
});
|
|
2115
2324
|
}
|
|
2116
2325
|
function MenubarSubTrigger({ density, className, inset, ...props }) {
|
|
2117
|
-
return /* @__PURE__ */
|
|
2326
|
+
return /* @__PURE__ */ jsx23(DropdownMenuSubTrigger2, {
|
|
2118
2327
|
density,
|
|
2119
2328
|
"data-slot": "menubar-sub-trigger",
|
|
2120
2329
|
inset,
|
|
@@ -2123,7 +2332,7 @@ function MenubarSubTrigger({ density, className, inset, ...props }) {
|
|
|
2123
2332
|
});
|
|
2124
2333
|
}
|
|
2125
2334
|
function MenubarSubContent({ density, className, ...props }) {
|
|
2126
|
-
return /* @__PURE__ */
|
|
2335
|
+
return /* @__PURE__ */ jsx23(DropdownMenuSubContent2, {
|
|
2127
2336
|
density,
|
|
2128
2337
|
"data-slot": "menubar-sub-content",
|
|
2129
2338
|
className: (state) => cn2(" min-w-32 rounded-sm bg-popover p-1 text-popover-foreground shadow-frame border border-frame-edge border border-frame-edge shadow-frame duration-100 data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0 ", typeof className === "function" ? className(state) : className),
|
|
@@ -2134,7 +2343,7 @@ function MenubarSubContent({ density, className, ...props }) {
|
|
|
2134
2343
|
import { ChevronDownIcon as ChevronDownIcon5 } from "lucide-react";
|
|
2135
2344
|
import { NavigationMenu as NavigationMenuPrimitive } from "@base-ui/react/navigation-menu";
|
|
2136
2345
|
import { cva as cva4 } from "class-variance-authority";
|
|
2137
|
-
import { jsx as
|
|
2346
|
+
import { jsx as jsx24, jsxs as jsxs17 } from "react/jsx-runtime";
|
|
2138
2347
|
function NavigationMenu({
|
|
2139
2348
|
density,
|
|
2140
2349
|
align = "start",
|
|
@@ -2143,14 +2352,14 @@ function NavigationMenu({
|
|
|
2143
2352
|
...props
|
|
2144
2353
|
}) {
|
|
2145
2354
|
const resolvedDensity = useDensity(density);
|
|
2146
|
-
return /* @__PURE__ */
|
|
2355
|
+
return /* @__PURE__ */ jsxs17(NavigationMenuPrimitive.Root, {
|
|
2147
2356
|
"data-density": resolvedDensity,
|
|
2148
2357
|
"data-slot": "navigation-menu",
|
|
2149
2358
|
className: (state) => cn2("group/navigation-menu relative flex max-w-max flex-1 items-center justify-center", typeof className === "function" ? className(state) : className),
|
|
2150
2359
|
...props,
|
|
2151
2360
|
children: [
|
|
2152
2361
|
children,
|
|
2153
|
-
/* @__PURE__ */
|
|
2362
|
+
/* @__PURE__ */ jsx24(NavigationMenuPositioner, {
|
|
2154
2363
|
density: resolvedDensity,
|
|
2155
2364
|
align
|
|
2156
2365
|
})
|
|
@@ -2158,7 +2367,7 @@ function NavigationMenu({
|
|
|
2158
2367
|
});
|
|
2159
2368
|
}
|
|
2160
2369
|
function NavigationMenuList({ density, className, ...props }) {
|
|
2161
|
-
return /* @__PURE__ */
|
|
2370
|
+
return /* @__PURE__ */ jsx24(NavigationMenuPrimitive.List, {
|
|
2162
2371
|
"data-density": density,
|
|
2163
2372
|
"data-slot": "navigation-menu-list",
|
|
2164
2373
|
className: (state) => cn2("group flex flex-1 list-none items-center justify-center gap-0", typeof className === "function" ? className(state) : className),
|
|
@@ -2166,7 +2375,7 @@ function NavigationMenuList({ density, className, ...props }) {
|
|
|
2166
2375
|
});
|
|
2167
2376
|
}
|
|
2168
2377
|
function NavigationMenuItem({ density, className, ...props }) {
|
|
2169
|
-
return /* @__PURE__ */
|
|
2378
|
+
return /* @__PURE__ */ jsx24(NavigationMenuPrimitive.Item, {
|
|
2170
2379
|
"data-density": density,
|
|
2171
2380
|
"data-slot": "navigation-menu-item",
|
|
2172
2381
|
className: (state) => cn2("relative", typeof className === "function" ? className(state) : className),
|
|
@@ -2175,7 +2384,7 @@ function NavigationMenuItem({ density, className, ...props }) {
|
|
|
2175
2384
|
}
|
|
2176
2385
|
var navigationMenuTriggerStyle = cva4("group/navigation-menu-trigger inline-flex h-control-lg w-max items-center justify-center rounded-sm px-control-x py-1.5 text-sm font-medium transition-colors outline-none hover:bg-muted focus:bg-muted focus-visible:ring-1 focus-visible:ring-ring focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-popup-open:bg-muted/50 data-popup-open:hover:bg-muted data-open:bg-muted/50 data-open:hover:bg-muted data-open:focus:bg-muted");
|
|
2177
2386
|
function NavigationMenuTrigger({ density, className, children, ...props }) {
|
|
2178
|
-
return /* @__PURE__ */
|
|
2387
|
+
return /* @__PURE__ */ jsxs17(NavigationMenuPrimitive.Trigger, {
|
|
2179
2388
|
"data-density": density,
|
|
2180
2389
|
"data-slot": "navigation-menu-trigger",
|
|
2181
2390
|
className: (state) => cn2(navigationMenuTriggerStyle(), "group", typeof className === "function" ? className(state) : className),
|
|
@@ -2183,12 +2392,12 @@ function NavigationMenuTrigger({ density, className, children, ...props }) {
|
|
|
2183
2392
|
children: [
|
|
2184
2393
|
children,
|
|
2185
2394
|
" ",
|
|
2186
|
-
/* @__PURE__ */
|
|
2395
|
+
/* @__PURE__ */ jsx24(NavigationMenuIndicator, {})
|
|
2187
2396
|
]
|
|
2188
2397
|
});
|
|
2189
2398
|
}
|
|
2190
2399
|
function NavigationMenuContent({ density, className, ...props }) {
|
|
2191
|
-
return /* @__PURE__ */
|
|
2400
|
+
return /* @__PURE__ */ jsx24(NavigationMenuPrimitive.Content, {
|
|
2192
2401
|
"data-density": density,
|
|
2193
2402
|
"data-slot": "navigation-menu-content",
|
|
2194
2403
|
className: (state) => cn2("data-ending-style:data-activation-direction=left:translate-x-[50%] data-ending-style:data-activation-direction=right:translate-x-[-50%] data-starting-style:data-activation-direction=left:translate-x-[-50%] data-starting-style:data-activation-direction=right:translate-x-[50%] h-full w-auto p-1 transition-[opacity,transform,translate] duration-[0.35s] ease-[cubic-bezier(0.22,1,0.36,1)] data-ending-style:opacity-0 data-starting-style:opacity-0 ", typeof className === "function" ? className(state) : className),
|
|
@@ -2207,29 +2416,34 @@ function NavigationMenuPositioner({
|
|
|
2207
2416
|
const resolvedDensity = useDensity(density);
|
|
2208
2417
|
const direction = useDirection2();
|
|
2209
2418
|
const container = usePortalContainer2();
|
|
2210
|
-
|
|
2419
|
+
const portal = usePortalNode();
|
|
2420
|
+
return /* @__PURE__ */ jsx24(NavigationMenuPrimitive.Portal, {
|
|
2211
2421
|
container,
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
|
|
2216
|
-
|
|
2217
|
-
|
|
2218
|
-
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
"data-
|
|
2222
|
-
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
|
|
2422
|
+
ref: portal.ref,
|
|
2423
|
+
children: /* @__PURE__ */ jsx24(PortalProvider2, {
|
|
2424
|
+
container: portal.node,
|
|
2425
|
+
children: /* @__PURE__ */ jsx24(NavigationMenuPrimitive.Positioner, {
|
|
2426
|
+
dir: direction,
|
|
2427
|
+
side,
|
|
2428
|
+
sideOffset,
|
|
2429
|
+
align,
|
|
2430
|
+
alignOffset,
|
|
2431
|
+
className: (state) => cn2("isolate h-(--positioner-height) w-(--positioner-width) max-w-(--available-width) transition-[top,left,right,bottom] duration-[0.35s] ease-[cubic-bezier(0.22,1,0.36,1)] data-instant:transition-none data-[side=bottom]:before:top-[-10px] data-[side=bottom]:before:right-0 data-[side=bottom]:before:left-0", typeof className === "function" ? className(state) : className),
|
|
2432
|
+
...props,
|
|
2433
|
+
children: /* @__PURE__ */ jsx24(NavigationMenuPrimitive.Popup, {
|
|
2434
|
+
"data-density": resolvedDensity,
|
|
2435
|
+
"data-slot": "navigation-menu-popup",
|
|
2436
|
+
className: "data-[ending-style]:easing-[ease] xs:w-(--popup-width) relative h-(--popup-height) w-(--popup-width) origin-(--transform-origin) rounded-sm bg-popover text-popover-foreground border border-frame-edge shadow-frame transition-[opacity,transform,width,height,translate] duration-[0.35s] ease-[cubic-bezier(0.22,1,0.36,1)] outline-none data-ending-style:opacity-0 data-ending-style:duration-150 data-starting-style:opacity-0",
|
|
2437
|
+
children: /* @__PURE__ */ jsx24(NavigationMenuPrimitive.Viewport, {
|
|
2438
|
+
className: "relative size-full overflow-hidden"
|
|
2439
|
+
})
|
|
2226
2440
|
})
|
|
2227
2441
|
})
|
|
2228
2442
|
})
|
|
2229
2443
|
});
|
|
2230
2444
|
}
|
|
2231
2445
|
function NavigationMenuLink({ density, className, ...props }) {
|
|
2232
|
-
return /* @__PURE__ */
|
|
2446
|
+
return /* @__PURE__ */ jsx24(NavigationMenuPrimitive.Link, {
|
|
2233
2447
|
"data-density": density,
|
|
2234
2448
|
"data-slot": "navigation-menu-link",
|
|
2235
2449
|
className: (state) => cn2("flex items-center gap-2 rounded-sm p-2 text-sm transition-colors outline-none hover:bg-muted focus:bg-muted focus-visible:ring-1 focus-visible:ring-ring focus-visible:outline-1 in-data-[slot=navigation-menu-content]:rounded-md data-active:bg-muted/50 data-active:hover:bg-muted data-active:focus:bg-muted [&_svg:not([class*='size-'])]:size-4", typeof className === "function" ? className(state) : className),
|
|
@@ -2242,35 +2456,41 @@ function NavigationMenuIndicator({
|
|
|
2242
2456
|
children,
|
|
2243
2457
|
...props
|
|
2244
2458
|
}) {
|
|
2245
|
-
return /* @__PURE__ */
|
|
2459
|
+
return /* @__PURE__ */ jsx24(NavigationMenuPrimitive.Icon, {
|
|
2246
2460
|
"data-density": density,
|
|
2247
2461
|
"data-slot": "navigation-menu-indicator",
|
|
2248
2462
|
className: (state) => cn2("ms-1 inline-flex size-3 shrink-0 items-center justify-center transition-transform duration-120 data-popup-open:rotate-180 [&_svg]:size-full", typeof className === "function" ? className(state) : className),
|
|
2249
2463
|
...props,
|
|
2250
|
-
children: children ?? /* @__PURE__ */
|
|
2464
|
+
children: children ?? /* @__PURE__ */ jsx24(ChevronDownIcon5, {})
|
|
2251
2465
|
});
|
|
2252
2466
|
}
|
|
2253
2467
|
// src/components/Toast.tsx
|
|
2254
2468
|
import { Toast as ToastPrimitive } from "@base-ui/react/toast";
|
|
2255
2469
|
import { CircleCheckIcon, InfoIcon, TriangleAlertIcon, OctagonXIcon, LoaderCircleIcon, XIcon as XIcon2 } from "lucide-react";
|
|
2256
|
-
import { jsx as
|
|
2470
|
+
import { jsx as jsx25, jsxs as jsxs18, Fragment } from "react/jsx-runtime";
|
|
2257
2471
|
function ToastProvider(props) {
|
|
2258
|
-
return /* @__PURE__ */
|
|
2472
|
+
return /* @__PURE__ */ jsx25(ToastPrimitive.Provider, {
|
|
2259
2473
|
...props
|
|
2260
2474
|
});
|
|
2261
2475
|
}
|
|
2262
|
-
function ToastPortal({ container, ...props }) {
|
|
2476
|
+
function ToastPortal({ container, ref, children, ...props }) {
|
|
2263
2477
|
const resolvedContainer = usePortalContainer2(container);
|
|
2264
|
-
|
|
2478
|
+
const portal = usePortalNode(ref);
|
|
2479
|
+
return /* @__PURE__ */ jsx25(ToastPrimitive.Portal, {
|
|
2265
2480
|
"data-slot": "toast-portal",
|
|
2266
2481
|
container: resolvedContainer,
|
|
2267
|
-
|
|
2482
|
+
ref: portal.ref,
|
|
2483
|
+
...props,
|
|
2484
|
+
children: /* @__PURE__ */ jsx25(PortalProvider2, {
|
|
2485
|
+
container: portal.node,
|
|
2486
|
+
children
|
|
2487
|
+
})
|
|
2268
2488
|
});
|
|
2269
2489
|
}
|
|
2270
2490
|
function ToastViewport({ density, dir, className, ...props }) {
|
|
2271
2491
|
const resolvedDensity = useDensity(density);
|
|
2272
2492
|
const inheritedDirection = useDirection2();
|
|
2273
|
-
return /* @__PURE__ */
|
|
2493
|
+
return /* @__PURE__ */ jsx25(ToastPrimitive.Viewport, {
|
|
2274
2494
|
dir: dir ?? inheritedDirection,
|
|
2275
2495
|
"data-density": resolvedDensity,
|
|
2276
2496
|
"data-slot": "toast-viewport",
|
|
@@ -2279,7 +2499,7 @@ function ToastViewport({ density, dir, className, ...props }) {
|
|
|
2279
2499
|
});
|
|
2280
2500
|
}
|
|
2281
2501
|
function Toast({ density, className, ...props }) {
|
|
2282
|
-
return /* @__PURE__ */
|
|
2502
|
+
return /* @__PURE__ */ jsx25(ToastPrimitive.Root, {
|
|
2283
2503
|
"data-density": density,
|
|
2284
2504
|
"data-slot": "toast",
|
|
2285
2505
|
className: (state) => cn2("group/toast pointer-events-auto absolute right-0 bottom-0 w-full rounded-md border border-frame-edge bg-popover text-popover-foreground shadow-frame outline-none select-none focus-visible:ring-1 focus-visible:ring-ring [--offset-y:calc(var(--toast-offset-y)*-1-var(--toast-index)*var(--spacing-panel))] [transform:translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--offset-y)+var(--toast-swipe-movement-y)))] transition-[transform,opacity] duration-120 ease-out data-limited:opacity-0 data-starting-style:opacity-0 data-ending-style:opacity-0 motion-reduce:transition-none", typeof className === "function" ? className(state) : className),
|
|
@@ -2287,21 +2507,21 @@ function Toast({ density, className, ...props }) {
|
|
|
2287
2507
|
});
|
|
2288
2508
|
}
|
|
2289
2509
|
function ToastContent({ className, ...props }) {
|
|
2290
|
-
return /* @__PURE__ */
|
|
2510
|
+
return /* @__PURE__ */ jsx25(ToastPrimitive.Content, {
|
|
2291
2511
|
"data-slot": "toast-content",
|
|
2292
2512
|
className: (state) => cn2("flex items-center gap-control-gap p-panel", typeof className === "function" ? className(state) : className),
|
|
2293
2513
|
...props
|
|
2294
2514
|
});
|
|
2295
2515
|
}
|
|
2296
2516
|
function ToastTitle({ className, ...props }) {
|
|
2297
|
-
return /* @__PURE__ */
|
|
2517
|
+
return /* @__PURE__ */ jsx25(ToastPrimitive.Title, {
|
|
2298
2518
|
"data-slot": "toast-title",
|
|
2299
2519
|
className: (state) => cn2("text-sm font-medium", typeof className === "function" ? className(state) : className),
|
|
2300
2520
|
...props
|
|
2301
2521
|
});
|
|
2302
2522
|
}
|
|
2303
2523
|
function ToastDescription({ className, ...props }) {
|
|
2304
|
-
return /* @__PURE__ */
|
|
2524
|
+
return /* @__PURE__ */ jsx25(ToastPrimitive.Description, {
|
|
2305
2525
|
"data-slot": "toast-description",
|
|
2306
2526
|
className: (state) => cn2("text-sm text-muted-foreground", typeof className === "function" ? className(state) : className),
|
|
2307
2527
|
...props
|
|
@@ -2309,13 +2529,13 @@ function ToastDescription({ className, ...props }) {
|
|
|
2309
2529
|
}
|
|
2310
2530
|
function ToastAction({
|
|
2311
2531
|
className,
|
|
2312
|
-
render = /* @__PURE__ */
|
|
2532
|
+
render = /* @__PURE__ */ jsx25(Button2, {
|
|
2313
2533
|
variant: "outline",
|
|
2314
2534
|
size: "sm"
|
|
2315
2535
|
}),
|
|
2316
2536
|
...props
|
|
2317
2537
|
}) {
|
|
2318
|
-
return /* @__PURE__ */
|
|
2538
|
+
return /* @__PURE__ */ jsx25(ToastPrimitive.Action, {
|
|
2319
2539
|
"data-slot": "toast-action",
|
|
2320
2540
|
render,
|
|
2321
2541
|
className: (state) => cn2("shrink-0", typeof className === "function" ? className(state) : className),
|
|
@@ -2325,19 +2545,19 @@ function ToastAction({
|
|
|
2325
2545
|
function ToastClose({
|
|
2326
2546
|
className,
|
|
2327
2547
|
children,
|
|
2328
|
-
render = /* @__PURE__ */
|
|
2548
|
+
render = /* @__PURE__ */ jsx25(Button2, {
|
|
2329
2549
|
variant: "ghost",
|
|
2330
2550
|
size: "icon-sm"
|
|
2331
2551
|
}),
|
|
2332
2552
|
...props
|
|
2333
2553
|
}) {
|
|
2334
|
-
return /* @__PURE__ */
|
|
2554
|
+
return /* @__PURE__ */ jsx25(ToastPrimitive.Close, {
|
|
2335
2555
|
"data-slot": "toast-close",
|
|
2336
2556
|
"aria-label": "Close toast",
|
|
2337
2557
|
render,
|
|
2338
2558
|
className: (state) => cn2("relative shrink-0 text-muted-foreground hover:text-foreground", typeof className === "function" ? className(state) : className),
|
|
2339
2559
|
...props,
|
|
2340
|
-
children: children ?? /* @__PURE__ */
|
|
2560
|
+
children: children ?? /* @__PURE__ */ jsx25(XIcon2, {
|
|
2341
2561
|
"aria-hidden": "true"
|
|
2342
2562
|
})
|
|
2343
2563
|
});
|
|
@@ -2345,24 +2565,24 @@ function ToastClose({
|
|
|
2345
2565
|
function ToastIcon({ type }) {
|
|
2346
2566
|
switch (type) {
|
|
2347
2567
|
case "success":
|
|
2348
|
-
return /* @__PURE__ */
|
|
2568
|
+
return /* @__PURE__ */ jsx25(CircleCheckIcon, {
|
|
2349
2569
|
"aria-hidden": "true"
|
|
2350
2570
|
});
|
|
2351
2571
|
case "info":
|
|
2352
|
-
return /* @__PURE__ */
|
|
2572
|
+
return /* @__PURE__ */ jsx25(InfoIcon, {
|
|
2353
2573
|
"aria-hidden": "true"
|
|
2354
2574
|
});
|
|
2355
2575
|
case "warning":
|
|
2356
|
-
return /* @__PURE__ */
|
|
2576
|
+
return /* @__PURE__ */ jsx25(TriangleAlertIcon, {
|
|
2357
2577
|
"aria-hidden": "true"
|
|
2358
2578
|
});
|
|
2359
2579
|
case "error":
|
|
2360
|
-
return /* @__PURE__ */
|
|
2580
|
+
return /* @__PURE__ */ jsx25(OctagonXIcon, {
|
|
2361
2581
|
"aria-hidden": "true",
|
|
2362
2582
|
className: "text-destructive"
|
|
2363
2583
|
});
|
|
2364
2584
|
case "loading":
|
|
2365
|
-
return /* @__PURE__ */
|
|
2585
|
+
return /* @__PURE__ */ jsx25(LoaderCircleIcon, {
|
|
2366
2586
|
"aria-hidden": "true",
|
|
2367
2587
|
className: "animate-spin motion-reduce:animate-none"
|
|
2368
2588
|
});
|
|
@@ -2372,41 +2592,41 @@ function ToastIcon({ type }) {
|
|
|
2372
2592
|
}
|
|
2373
2593
|
function ToastList() {
|
|
2374
2594
|
const { toasts } = ToastPrimitive.useToastManager();
|
|
2375
|
-
return /* @__PURE__ */
|
|
2376
|
-
children: toasts.map((toastItem) => /* @__PURE__ */
|
|
2595
|
+
return /* @__PURE__ */ jsx25(Fragment, {
|
|
2596
|
+
children: toasts.map((toastItem) => /* @__PURE__ */ jsx25(Toast, {
|
|
2377
2597
|
toast: toastItem,
|
|
2378
|
-
children: /* @__PURE__ */
|
|
2598
|
+
children: /* @__PURE__ */ jsxs18(ToastContent, {
|
|
2379
2599
|
children: [
|
|
2380
|
-
/* @__PURE__ */
|
|
2600
|
+
/* @__PURE__ */ jsx25("span", {
|
|
2381
2601
|
"data-slot": "toast-icon",
|
|
2382
2602
|
className: "shrink-0 empty:hidden [&_svg]:size-4",
|
|
2383
|
-
children: /* @__PURE__ */
|
|
2603
|
+
children: /* @__PURE__ */ jsx25(ToastIcon, {
|
|
2384
2604
|
type: toastItem.type
|
|
2385
2605
|
})
|
|
2386
2606
|
}),
|
|
2387
|
-
/* @__PURE__ */
|
|
2607
|
+
/* @__PURE__ */ jsxs18("div", {
|
|
2388
2608
|
className: "flex min-w-0 flex-1 flex-col gap-1",
|
|
2389
2609
|
children: [
|
|
2390
|
-
/* @__PURE__ */
|
|
2391
|
-
/* @__PURE__ */
|
|
2610
|
+
/* @__PURE__ */ jsx25(ToastTitle, {}),
|
|
2611
|
+
/* @__PURE__ */ jsx25(ToastDescription, {})
|
|
2392
2612
|
]
|
|
2393
2613
|
}),
|
|
2394
|
-
/* @__PURE__ */
|
|
2395
|
-
/* @__PURE__ */
|
|
2614
|
+
/* @__PURE__ */ jsx25(ToastAction, {}),
|
|
2615
|
+
/* @__PURE__ */ jsx25(ToastClose, {})
|
|
2396
2616
|
]
|
|
2397
2617
|
})
|
|
2398
2618
|
}, toastItem.id))
|
|
2399
2619
|
});
|
|
2400
2620
|
}
|
|
2401
2621
|
function ToastToaster({ children, density, ...props }) {
|
|
2402
|
-
return /* @__PURE__ */
|
|
2622
|
+
return /* @__PURE__ */ jsxs18(ToastProvider, {
|
|
2403
2623
|
...props,
|
|
2404
2624
|
children: [
|
|
2405
2625
|
children,
|
|
2406
|
-
/* @__PURE__ */
|
|
2407
|
-
children: /* @__PURE__ */
|
|
2626
|
+
/* @__PURE__ */ jsx25(ToastPortal, {
|
|
2627
|
+
children: /* @__PURE__ */ jsx25(ToastViewport, {
|
|
2408
2628
|
density,
|
|
2409
|
-
children: /* @__PURE__ */
|
|
2629
|
+
children: /* @__PURE__ */ jsx25(ToastList, {})
|
|
2410
2630
|
})
|
|
2411
2631
|
})
|
|
2412
2632
|
]
|
|
@@ -2419,10 +2639,10 @@ function useToastManager() {
|
|
|
2419
2639
|
return Toast2.useToastManager();
|
|
2420
2640
|
}
|
|
2421
2641
|
// src/components/Marker.tsx
|
|
2422
|
-
import { mergeProps as
|
|
2423
|
-
import { useRender as
|
|
2642
|
+
import { mergeProps as mergeProps8 } from "@base-ui/react/merge-props";
|
|
2643
|
+
import { useRender as useRender8 } from "@base-ui/react/use-render";
|
|
2424
2644
|
import { cva as cva5 } from "class-variance-authority";
|
|
2425
|
-
import { jsx as
|
|
2645
|
+
import { jsx as jsx26 } from "react/jsx-runtime";
|
|
2426
2646
|
var markerVariants = cva5("group/marker relative flex min-h-4 w-full items-center gap-control-gap text-start text-sm text-muted-foreground [&_svg:not([class*='size-'])]:size-4 [a]:underline [a]:underline-offset-3 [a]:hover:text-foreground [&:is(a,button)]:outline-none [&:is(a,button)]:focus-visible:outline-1 [&:is(a,button)]:focus-visible:outline-ring", {
|
|
2427
2647
|
variants: {
|
|
2428
2648
|
variant: {
|
|
@@ -2433,15 +2653,15 @@ var markerVariants = cva5("group/marker relative flex min-h-4 w-full items-cente
|
|
|
2433
2653
|
}
|
|
2434
2654
|
});
|
|
2435
2655
|
function Marker({ density, className, variant = "default", render, ...props }) {
|
|
2436
|
-
return
|
|
2656
|
+
return useRender8({
|
|
2437
2657
|
defaultTagName: "div",
|
|
2438
|
-
props:
|
|
2658
|
+
props: mergeProps8({ className: cn2(markerVariants({ variant, className })) }, props),
|
|
2439
2659
|
render,
|
|
2440
2660
|
state: { slot: "marker", variant, density }
|
|
2441
2661
|
});
|
|
2442
2662
|
}
|
|
2443
2663
|
function MarkerIcon({ density, className, ...props }) {
|
|
2444
|
-
return /* @__PURE__ */
|
|
2664
|
+
return /* @__PURE__ */ jsx26("span", {
|
|
2445
2665
|
"data-density": density,
|
|
2446
2666
|
"data-slot": "marker-icon",
|
|
2447
2667
|
"aria-hidden": "true",
|
|
@@ -2450,7 +2670,7 @@ function MarkerIcon({ density, className, ...props }) {
|
|
|
2450
2670
|
});
|
|
2451
2671
|
}
|
|
2452
2672
|
function MarkerContent({ density, className, ...props }) {
|
|
2453
|
-
return /* @__PURE__ */
|
|
2673
|
+
return /* @__PURE__ */ jsx26("span", {
|
|
2454
2674
|
"data-density": density,
|
|
2455
2675
|
"data-slot": "marker-content",
|
|
2456
2676
|
className: cn2("min-w-0 wrap-break-word group-data-[variant=separator]/marker:text-center [&>a]:underline [&>a]:underline-offset-3 [&>a:hover]:text-foreground", className),
|
|
@@ -2458,12 +2678,12 @@ function MarkerContent({ density, className, ...props }) {
|
|
|
2458
2678
|
});
|
|
2459
2679
|
}
|
|
2460
2680
|
// src/components/Bubble.tsx
|
|
2461
|
-
import { mergeProps as
|
|
2462
|
-
import { useRender as
|
|
2681
|
+
import { mergeProps as mergeProps9 } from "@base-ui/react/merge-props";
|
|
2682
|
+
import { useRender as useRender9 } from "@base-ui/react/use-render";
|
|
2463
2683
|
import { cva as cva6 } from "class-variance-authority";
|
|
2464
|
-
import { jsx as
|
|
2684
|
+
import { jsx as jsx27 } from "react/jsx-runtime";
|
|
2465
2685
|
function BubbleGroup({ density, className, ...props }) {
|
|
2466
|
-
return /* @__PURE__ */
|
|
2686
|
+
return /* @__PURE__ */ jsx27("div", {
|
|
2467
2687
|
"data-density": density,
|
|
2468
2688
|
"data-slot": "bubble-group",
|
|
2469
2689
|
className: cn2("flex min-w-0 flex-col gap-control-gap", className),
|
|
@@ -2485,7 +2705,7 @@ var bubbleVariants = cva6("group/bubble relative flex w-fit max-w-[80%] min-w-0
|
|
|
2485
2705
|
defaultVariants: { variant: "default" }
|
|
2486
2706
|
});
|
|
2487
2707
|
function Bubble({ density, variant = "default", align = "start", className, ...props }) {
|
|
2488
|
-
return /* @__PURE__ */
|
|
2708
|
+
return /* @__PURE__ */ jsx27("div", {
|
|
2489
2709
|
"data-density": density,
|
|
2490
2710
|
"data-slot": "bubble",
|
|
2491
2711
|
"data-variant": variant,
|
|
@@ -2495,9 +2715,9 @@ function Bubble({ density, variant = "default", align = "start", className, ...p
|
|
|
2495
2715
|
});
|
|
2496
2716
|
}
|
|
2497
2717
|
function BubbleContent({ density, className, render, ...props }) {
|
|
2498
|
-
return
|
|
2718
|
+
return useRender9({
|
|
2499
2719
|
defaultTagName: "div",
|
|
2500
|
-
props:
|
|
2720
|
+
props: mergeProps9({
|
|
2501
2721
|
className: cn2("w-fit max-w-full min-w-0 overflow-hidden rounded-sm border border-transparent px-control-x py-control-gap text-sm leading-relaxed wrap-break-word group-data-[align=end]/bubble:self-end [&:is(button)]:text-start [&:is(button,a)]:transition-colors motion-reduce:transition-none [&:is(button,a)]:outline-none [&:is(button,a)]:focus-visible:border-ring [&:is(button,a)]:focus-visible:ring-1 [&:is(button,a)]:focus-visible:ring-ring", className)
|
|
2502
2722
|
}, props),
|
|
2503
2723
|
render,
|
|
@@ -2518,7 +2738,7 @@ function BubbleReactions({
|
|
|
2518
2738
|
className,
|
|
2519
2739
|
...props
|
|
2520
2740
|
}) {
|
|
2521
|
-
return /* @__PURE__ */
|
|
2741
|
+
return /* @__PURE__ */ jsx27("div", {
|
|
2522
2742
|
"data-density": density,
|
|
2523
2743
|
"data-slot": "bubble-reactions",
|
|
2524
2744
|
"data-align": align,
|
|
@@ -2529,16 +2749,16 @@ function BubbleReactions({
|
|
|
2529
2749
|
}
|
|
2530
2750
|
// src/components/Message.tsx
|
|
2531
2751
|
import { useContext as useContext3, useLayoutEffect, useMemo as useMemo3, useRef as useRef3, useState as useState3 } from "react";
|
|
2532
|
-
import { useRender as
|
|
2752
|
+
import { useRender as useRender10 } from "@base-ui/react/use-render";
|
|
2533
2753
|
|
|
2534
2754
|
// src/message/MessageContext.ts
|
|
2535
2755
|
import { createContext as createContext3 } from "react";
|
|
2536
2756
|
var MessageContext = createContext3(null);
|
|
2537
2757
|
|
|
2538
2758
|
// src/components/Message.tsx
|
|
2539
|
-
import { jsx as
|
|
2759
|
+
import { jsx as jsx28 } from "react/jsx-runtime";
|
|
2540
2760
|
function MessageGroup({ density, className, ...props }) {
|
|
2541
|
-
return /* @__PURE__ */
|
|
2761
|
+
return /* @__PURE__ */ jsx28("div", {
|
|
2542
2762
|
"data-density": density,
|
|
2543
2763
|
"data-slot": "message-group",
|
|
2544
2764
|
className: cn2("flex min-w-0 flex-col gap-control-gap", className),
|
|
@@ -2549,9 +2769,9 @@ function Message({ density, className, align = "start", style, ...props }) {
|
|
|
2549
2769
|
const [footerOffset, setFooterOffset] = useState3(0);
|
|
2550
2770
|
const context = useMemo3(() => ({ setFooterOffset }), []);
|
|
2551
2771
|
const messageStyle = { ...style, "--message-footer-offset": `${footerOffset}px` };
|
|
2552
|
-
return /* @__PURE__ */
|
|
2772
|
+
return /* @__PURE__ */ jsx28(MessageContext.Provider, {
|
|
2553
2773
|
value: context,
|
|
2554
|
-
children: /* @__PURE__ */
|
|
2774
|
+
children: /* @__PURE__ */ jsx28("div", {
|
|
2555
2775
|
"data-density": density,
|
|
2556
2776
|
"data-slot": "message",
|
|
2557
2777
|
"data-align": align,
|
|
@@ -2562,7 +2782,7 @@ function Message({ density, className, align = "start", style, ...props }) {
|
|
|
2562
2782
|
});
|
|
2563
2783
|
}
|
|
2564
2784
|
function MessageAvatar({ density, className, ...props }) {
|
|
2565
|
-
return /* @__PURE__ */
|
|
2785
|
+
return /* @__PURE__ */ jsx28("div", {
|
|
2566
2786
|
"data-density": density,
|
|
2567
2787
|
"data-slot": "message-avatar",
|
|
2568
2788
|
className: cn2("flex w-fit min-w-8 shrink-0 items-center justify-center self-end overflow-hidden rounded-full bg-muted group-has-data-[slot=message-footer]/message:-translate-y-(--message-footer-offset)", className),
|
|
@@ -2570,7 +2790,7 @@ function MessageAvatar({ density, className, ...props }) {
|
|
|
2570
2790
|
});
|
|
2571
2791
|
}
|
|
2572
2792
|
function MessageContent({ density, className, ...props }) {
|
|
2573
|
-
return /* @__PURE__ */
|
|
2793
|
+
return /* @__PURE__ */ jsx28("div", {
|
|
2574
2794
|
"data-density": density,
|
|
2575
2795
|
"data-slot": "message-content",
|
|
2576
2796
|
className: cn2("flex w-full min-w-0 flex-col gap-control-gap wrap-break-word group-data-[align=end]/message:[&>[data-slot]:not([data-slot=message-header])]:self-end", className),
|
|
@@ -2578,7 +2798,7 @@ function MessageContent({ density, className, ...props }) {
|
|
|
2578
2798
|
});
|
|
2579
2799
|
}
|
|
2580
2800
|
function MessageHeader({ density, className, ...props }) {
|
|
2581
|
-
return /* @__PURE__ */
|
|
2801
|
+
return /* @__PURE__ */ jsx28("div", {
|
|
2582
2802
|
"data-density": density,
|
|
2583
2803
|
"data-slot": "message-header",
|
|
2584
2804
|
className: cn2("flex max-w-full min-w-0 items-center px-control-x text-xs font-medium text-muted-foreground group-has-data-[variant=ghost]/message:px-0", className),
|
|
@@ -2606,7 +2826,7 @@ function MessageFooter({ density, className, ...props }) {
|
|
|
2606
2826
|
context.setFooterOffset(0);
|
|
2607
2827
|
};
|
|
2608
2828
|
}, [context]);
|
|
2609
|
-
return
|
|
2829
|
+
return useRender10({
|
|
2610
2830
|
defaultTagName: "div",
|
|
2611
2831
|
ref: footerRef,
|
|
2612
2832
|
state: { slot: "message-footer", density },
|
|
@@ -2617,10 +2837,10 @@ function MessageFooter({ density, className, ...props }) {
|
|
|
2617
2837
|
});
|
|
2618
2838
|
}
|
|
2619
2839
|
// src/components/Attachment.tsx
|
|
2620
|
-
import { mergeProps as
|
|
2621
|
-
import { useRender as
|
|
2840
|
+
import { mergeProps as mergeProps10 } from "@base-ui/react/merge-props";
|
|
2841
|
+
import { useRender as useRender11 } from "@base-ui/react/use-render";
|
|
2622
2842
|
import { cva as cva7 } from "class-variance-authority";
|
|
2623
|
-
import { jsx as
|
|
2843
|
+
import { jsx as jsx29 } from "react/jsx-runtime";
|
|
2624
2844
|
var attachmentVariants = cva7("group/attachment relative flex w-fit max-w-full min-w-0 shrink-0 flex-wrap rounded-md border bg-card text-card-foreground transition-colors motion-reduce:transition-none focus-within:ring-1 focus-within:ring-ring has-[>a,>button]:hover:bg-muted/50 data-[state=error]:border-destructive data-[state=idle]:border-dashed", {
|
|
2625
2845
|
variants: {
|
|
2626
2846
|
size: {
|
|
@@ -2642,7 +2862,7 @@ function Attachment({
|
|
|
2642
2862
|
orientation = "horizontal",
|
|
2643
2863
|
...props
|
|
2644
2864
|
}) {
|
|
2645
|
-
return /* @__PURE__ */
|
|
2865
|
+
return /* @__PURE__ */ jsx29("div", {
|
|
2646
2866
|
"data-slot": "attachment",
|
|
2647
2867
|
"data-density": density,
|
|
2648
2868
|
"data-state": state,
|
|
@@ -2662,7 +2882,7 @@ var attachmentMediaVariants = cva7("relative flex aspect-square w-10 shrink-0 it
|
|
|
2662
2882
|
defaultVariants: { variant: "icon" }
|
|
2663
2883
|
});
|
|
2664
2884
|
function AttachmentMedia({ density, className, variant = "icon", ...props }) {
|
|
2665
|
-
return /* @__PURE__ */
|
|
2885
|
+
return /* @__PURE__ */ jsx29("div", {
|
|
2666
2886
|
"data-slot": "attachment-media",
|
|
2667
2887
|
"data-density": density,
|
|
2668
2888
|
"data-variant": variant,
|
|
@@ -2671,7 +2891,7 @@ function AttachmentMedia({ density, className, variant = "icon", ...props }) {
|
|
|
2671
2891
|
});
|
|
2672
2892
|
}
|
|
2673
2893
|
function AttachmentContent({ density, className, ...props }) {
|
|
2674
|
-
return /* @__PURE__ */
|
|
2894
|
+
return /* @__PURE__ */ jsx29("div", {
|
|
2675
2895
|
"data-slot": "attachment-content",
|
|
2676
2896
|
"data-density": density,
|
|
2677
2897
|
className: cn2("max-w-full min-w-0 flex-1 leading-tight group-data-[orientation=vertical]/attachment:px-1", className),
|
|
@@ -2679,7 +2899,7 @@ function AttachmentContent({ density, className, ...props }) {
|
|
|
2679
2899
|
});
|
|
2680
2900
|
}
|
|
2681
2901
|
function AttachmentTitle({ density, className, ...props }) {
|
|
2682
|
-
return /* @__PURE__ */
|
|
2902
|
+
return /* @__PURE__ */ jsx29("span", {
|
|
2683
2903
|
"data-slot": "attachment-title",
|
|
2684
2904
|
"data-density": density,
|
|
2685
2905
|
className: cn2("block max-w-full min-w-0 truncate font-medium group-data-[state=processing]/attachment:shimmer group-data-[state=uploading]/attachment:shimmer", className),
|
|
@@ -2687,7 +2907,7 @@ function AttachmentTitle({ density, className, ...props }) {
|
|
|
2687
2907
|
});
|
|
2688
2908
|
}
|
|
2689
2909
|
function AttachmentDescription({ density, className, ...props }) {
|
|
2690
|
-
return /* @__PURE__ */
|
|
2910
|
+
return /* @__PURE__ */ jsx29("span", {
|
|
2691
2911
|
"data-slot": "attachment-description",
|
|
2692
2912
|
"data-density": density,
|
|
2693
2913
|
className: cn2("mt-0.5 block max-w-full min-w-0 truncate text-xs text-muted-foreground group-data-[state=error]/attachment:text-destructive", className),
|
|
@@ -2695,7 +2915,7 @@ function AttachmentDescription({ density, className, ...props }) {
|
|
|
2695
2915
|
});
|
|
2696
2916
|
}
|
|
2697
2917
|
function AttachmentActions({ density, className, ...props }) {
|
|
2698
|
-
return /* @__PURE__ */
|
|
2918
|
+
return /* @__PURE__ */ jsx29("div", {
|
|
2699
2919
|
"data-slot": "attachment-actions",
|
|
2700
2920
|
"data-density": density,
|
|
2701
2921
|
className: cn2("relative z-20 flex shrink-0 items-center group-data-[orientation=vertical]/attachment:absolute group-data-[orientation=vertical]/attachment:top-3 group-data-[orientation=vertical]/attachment:end-3 group-data-[orientation=vertical]/attachment:gap-1", className),
|
|
@@ -2708,7 +2928,7 @@ function AttachmentAction({
|
|
|
2708
2928
|
size = "icon-xs",
|
|
2709
2929
|
...props
|
|
2710
2930
|
}) {
|
|
2711
|
-
return /* @__PURE__ */
|
|
2931
|
+
return /* @__PURE__ */ jsx29(Button2, {
|
|
2712
2932
|
"data-slot": "attachment-action",
|
|
2713
2933
|
variant,
|
|
2714
2934
|
size,
|
|
@@ -2717,15 +2937,15 @@ function AttachmentAction({
|
|
|
2717
2937
|
});
|
|
2718
2938
|
}
|
|
2719
2939
|
function AttachmentTrigger({ density, className, render, type, ...props }) {
|
|
2720
|
-
return
|
|
2940
|
+
return useRender11({
|
|
2721
2941
|
defaultTagName: "button",
|
|
2722
|
-
props:
|
|
2942
|
+
props: mergeProps10({ type: render ? type : type ?? "button", className: cn2("absolute inset-0 z-10 outline-none", className) }, props),
|
|
2723
2943
|
render,
|
|
2724
2944
|
state: { slot: "attachment-trigger", density }
|
|
2725
2945
|
});
|
|
2726
2946
|
}
|
|
2727
2947
|
function AttachmentGroup({ density, className, ...props }) {
|
|
2728
|
-
return /* @__PURE__ */
|
|
2948
|
+
return /* @__PURE__ */ jsx29("div", {
|
|
2729
2949
|
"data-slot": "attachment-group",
|
|
2730
2950
|
"data-density": density,
|
|
2731
2951
|
className: cn2("flex min-w-0 scroll-fade-x snap-x snap-mandatory scroll-px-1 no-scrollbar gap-3 overflow-x-auto overscroll-x-contain py-1 *:data-[slot=attachment]:flex-none *:data-[slot=attachment]:snap-start", className),
|
|
@@ -2733,8 +2953,8 @@ function AttachmentGroup({ density, className, ...props }) {
|
|
|
2733
2953
|
});
|
|
2734
2954
|
}
|
|
2735
2955
|
// src/components/InlineEdit.tsx
|
|
2736
|
-
import { useEffect as
|
|
2737
|
-
import { jsx as
|
|
2956
|
+
import { useEffect as useEffect3, useRef as useRef4, useState as useState4 } from "react";
|
|
2957
|
+
import { jsx as jsx30, jsxs as jsxs19 } from "react/jsx-runtime";
|
|
2738
2958
|
function InlineEdit({
|
|
2739
2959
|
label,
|
|
2740
2960
|
value,
|
|
@@ -2749,7 +2969,7 @@ function InlineEdit({
|
|
|
2749
2969
|
const isFinished = useRef4(false);
|
|
2750
2970
|
const [isSaving, setSaving] = useState4(false);
|
|
2751
2971
|
const [error, setError] = useState4("");
|
|
2752
|
-
|
|
2972
|
+
useEffect3(() => {
|
|
2753
2973
|
input.current?.focus();
|
|
2754
2974
|
if (shouldSelectOnMount)
|
|
2755
2975
|
input.current?.select();
|
|
@@ -2769,14 +2989,14 @@ function InlineEdit({
|
|
|
2769
2989
|
setSaving(false);
|
|
2770
2990
|
}
|
|
2771
2991
|
};
|
|
2772
|
-
return /* @__PURE__ */
|
|
2992
|
+
return /* @__PURE__ */ jsxs19("form", {
|
|
2773
2993
|
className: "flex min-w-0 flex-col gap-1",
|
|
2774
2994
|
onSubmit: (event) => {
|
|
2775
2995
|
event.preventDefault();
|
|
2776
2996
|
save();
|
|
2777
2997
|
},
|
|
2778
2998
|
children: [
|
|
2779
|
-
/* @__PURE__ */
|
|
2999
|
+
/* @__PURE__ */ jsx30(Input2, {
|
|
2780
3000
|
ref: input,
|
|
2781
3001
|
density,
|
|
2782
3002
|
"aria-label": label,
|
|
@@ -2797,7 +3017,7 @@ function InlineEdit({
|
|
|
2797
3017
|
}
|
|
2798
3018
|
}
|
|
2799
3019
|
}),
|
|
2800
|
-
error && /* @__PURE__ */
|
|
3020
|
+
error && /* @__PURE__ */ jsx30("p", {
|
|
2801
3021
|
role: "alert",
|
|
2802
3022
|
className: "text-xs text-destructive",
|
|
2803
3023
|
children: error
|
|
@@ -2809,28 +3029,28 @@ function InlineEdit({
|
|
|
2809
3029
|
import { Radio } from "@base-ui/react/radio";
|
|
2810
3030
|
import { RadioGroup } from "@base-ui/react/radio-group";
|
|
2811
3031
|
import { StarIcon, CircleOffIcon } from "lucide-react";
|
|
2812
|
-
import { jsx as
|
|
3032
|
+
import { jsx as jsx31 } from "react/jsx-runtime";
|
|
2813
3033
|
function StarRating({ label, value, disabled, density, onValueChange }) {
|
|
2814
|
-
return /* @__PURE__ */
|
|
3034
|
+
return /* @__PURE__ */ jsx31(RadioGroup, {
|
|
2815
3035
|
"aria-label": label,
|
|
2816
3036
|
value,
|
|
2817
3037
|
disabled,
|
|
2818
3038
|
"data-density": density,
|
|
2819
3039
|
className: "inline-flex w-fit shrink-0 items-center gap-0.5",
|
|
2820
3040
|
onValueChange,
|
|
2821
|
-
children: [1, 2, 3, 4, 5, 0].map((star) => /* @__PURE__ */
|
|
3041
|
+
children: [1, 2, 3, 4, 5, 0].map((star) => /* @__PURE__ */ jsx31(Radio.Root, {
|
|
2822
3042
|
value: star,
|
|
2823
3043
|
nativeButton: true,
|
|
2824
|
-
render: /* @__PURE__ */
|
|
3044
|
+
render: /* @__PURE__ */ jsx31("button", {
|
|
2825
3045
|
type: "button"
|
|
2826
3046
|
}),
|
|
2827
3047
|
"aria-label": star === 0 ? "Unrated" : `${star} ${star === 1 ? "star" : "stars"}`,
|
|
2828
3048
|
title: star === 0 ? "Clear rating" : `${star} stars`,
|
|
2829
3049
|
className: "inline-flex size-5 shrink-0 items-center justify-center rounded-sm text-muted-foreground outline-none hover:text-primary focus-visible:ring-1 focus-visible:ring-ring data-disabled:cursor-not-allowed data-disabled:opacity-50",
|
|
2830
|
-
children: star === 0 ? /* @__PURE__ */
|
|
3050
|
+
children: star === 0 ? /* @__PURE__ */ jsx31(CircleOffIcon, {
|
|
2831
3051
|
"aria-hidden": "true",
|
|
2832
3052
|
className: "size-3"
|
|
2833
|
-
}) : /* @__PURE__ */
|
|
3053
|
+
}) : /* @__PURE__ */ jsx31(StarIcon, {
|
|
2834
3054
|
"aria-hidden": "true",
|
|
2835
3055
|
className: star <= value ? "size-3.5 fill-primary text-primary" : "size-3.5"
|
|
2836
3056
|
})
|
|
@@ -2839,7 +3059,7 @@ function StarRating({ label, value, disabled, density, onValueChange }) {
|
|
|
2839
3059
|
}
|
|
2840
3060
|
// src/components/ConfirmationDialog.tsx
|
|
2841
3061
|
import { useState as useState5 } from "react";
|
|
2842
|
-
import { jsx as
|
|
3062
|
+
import { jsx as jsx32, jsxs as jsxs20 } from "react/jsx-runtime";
|
|
2843
3063
|
function ConfirmationDialog({
|
|
2844
3064
|
open,
|
|
2845
3065
|
title,
|
|
@@ -2850,7 +3070,7 @@ function ConfirmationDialog({
|
|
|
2850
3070
|
}) {
|
|
2851
3071
|
const [isPending, setPending] = useState5(false);
|
|
2852
3072
|
const [error, setError] = useState5("");
|
|
2853
|
-
return /* @__PURE__ */
|
|
3073
|
+
return /* @__PURE__ */ jsx32(AlertDialog, {
|
|
2854
3074
|
open,
|
|
2855
3075
|
onOpenChange: (next) => {
|
|
2856
3076
|
if (!isPending) {
|
|
@@ -2858,31 +3078,31 @@ function ConfirmationDialog({
|
|
|
2858
3078
|
onOpenChange(next);
|
|
2859
3079
|
}
|
|
2860
3080
|
},
|
|
2861
|
-
children: /* @__PURE__ */
|
|
3081
|
+
children: /* @__PURE__ */ jsxs20(AlertDialogContent, {
|
|
2862
3082
|
children: [
|
|
2863
|
-
/* @__PURE__ */
|
|
3083
|
+
/* @__PURE__ */ jsxs20(AlertDialogHeader, {
|
|
2864
3084
|
children: [
|
|
2865
|
-
/* @__PURE__ */
|
|
3085
|
+
/* @__PURE__ */ jsx32(AlertDialogTitle, {
|
|
2866
3086
|
children: title
|
|
2867
3087
|
}),
|
|
2868
|
-
/* @__PURE__ */
|
|
3088
|
+
/* @__PURE__ */ jsx32(AlertDialogDescription, {
|
|
2869
3089
|
children: description
|
|
2870
3090
|
})
|
|
2871
3091
|
]
|
|
2872
3092
|
}),
|
|
2873
|
-
error && /* @__PURE__ */
|
|
3093
|
+
error && /* @__PURE__ */ jsx32(Alert2, {
|
|
2874
3094
|
variant: "destructive",
|
|
2875
|
-
children: /* @__PURE__ */
|
|
3095
|
+
children: /* @__PURE__ */ jsx32(AlertDescription2, {
|
|
2876
3096
|
children: error
|
|
2877
3097
|
})
|
|
2878
3098
|
}),
|
|
2879
|
-
/* @__PURE__ */
|
|
3099
|
+
/* @__PURE__ */ jsxs20(AlertDialogFooter, {
|
|
2880
3100
|
children: [
|
|
2881
|
-
/* @__PURE__ */
|
|
3101
|
+
/* @__PURE__ */ jsx32(AlertDialogCancel, {
|
|
2882
3102
|
disabled: isPending,
|
|
2883
3103
|
children: "Cancel"
|
|
2884
3104
|
}),
|
|
2885
|
-
/* @__PURE__ */
|
|
3105
|
+
/* @__PURE__ */ jsx32(Button2, {
|
|
2886
3106
|
variant: "destructive",
|
|
2887
3107
|
disabled: isPending,
|
|
2888
3108
|
onClick: async () => {
|
|
@@ -2910,10 +3130,10 @@ import { useRef as useRef5 } from "react";
|
|
|
2910
3130
|
import { ImageIcon, UploadIcon } from "lucide-react";
|
|
2911
3131
|
|
|
2912
3132
|
// src/hooks/useObjectURL.ts
|
|
2913
|
-
import { useEffect as
|
|
3133
|
+
import { useEffect as useEffect4, useState as useState6 } from "react";
|
|
2914
3134
|
function useObjectURL(file) {
|
|
2915
3135
|
const [url, setURL] = useState6();
|
|
2916
|
-
|
|
3136
|
+
useEffect4(() => {
|
|
2917
3137
|
if (!file) {
|
|
2918
3138
|
setURL(undefined);
|
|
2919
3139
|
return;
|
|
@@ -2926,32 +3146,32 @@ function useObjectURL(file) {
|
|
|
2926
3146
|
}
|
|
2927
3147
|
|
|
2928
3148
|
// src/components/ImagePicker.tsx
|
|
2929
|
-
import { jsx as
|
|
3149
|
+
import { jsx as jsx33, jsxs as jsxs21 } from "react/jsx-runtime";
|
|
2930
3150
|
function ImagePicker({ src, file, label, disabled, onFileChange, onClear }) {
|
|
2931
3151
|
const input = useRef5(null);
|
|
2932
3152
|
const preview = useObjectURL(file);
|
|
2933
3153
|
const image = file === null ? undefined : preview ?? src;
|
|
2934
|
-
return /* @__PURE__ */
|
|
3154
|
+
return /* @__PURE__ */ jsxs21("figure", {
|
|
2935
3155
|
className: "flex min-w-0 flex-col items-center gap-3",
|
|
2936
3156
|
"aria-label": label,
|
|
2937
3157
|
children: [
|
|
2938
|
-
/* @__PURE__ */
|
|
3158
|
+
/* @__PURE__ */ jsxs21(Avatar2, {
|
|
2939
3159
|
size: "preview",
|
|
2940
3160
|
shape: "square",
|
|
2941
3161
|
children: [
|
|
2942
|
-
/* @__PURE__ */
|
|
3162
|
+
/* @__PURE__ */ jsx33(AvatarImage2, {
|
|
2943
3163
|
src: image,
|
|
2944
3164
|
alt: label
|
|
2945
3165
|
}),
|
|
2946
|
-
/* @__PURE__ */
|
|
2947
|
-
children: /* @__PURE__ */
|
|
3166
|
+
/* @__PURE__ */ jsx33(AvatarFallback2, {
|
|
3167
|
+
children: /* @__PURE__ */ jsx33(ImageIcon, {
|
|
2948
3168
|
className: "size-12",
|
|
2949
3169
|
"aria-hidden": "true"
|
|
2950
3170
|
})
|
|
2951
3171
|
})
|
|
2952
3172
|
]
|
|
2953
3173
|
}),
|
|
2954
|
-
/* @__PURE__ */
|
|
3174
|
+
/* @__PURE__ */ jsx33("input", {
|
|
2955
3175
|
ref: input,
|
|
2956
3176
|
hidden: true,
|
|
2957
3177
|
type: "file",
|
|
@@ -2965,22 +3185,22 @@ function ImagePicker({ src, file, label, disabled, onFileChange, onClear }) {
|
|
|
2965
3185
|
event.currentTarget.value = "";
|
|
2966
3186
|
}
|
|
2967
3187
|
}),
|
|
2968
|
-
/* @__PURE__ */
|
|
3188
|
+
/* @__PURE__ */ jsxs21("div", {
|
|
2969
3189
|
className: "flex flex-wrap justify-center gap-2",
|
|
2970
3190
|
children: [
|
|
2971
|
-
/* @__PURE__ */
|
|
3191
|
+
/* @__PURE__ */ jsxs21(Button2, {
|
|
2972
3192
|
type: "button",
|
|
2973
3193
|
variant: "outline",
|
|
2974
3194
|
disabled,
|
|
2975
3195
|
onClick: () => input.current?.click(),
|
|
2976
3196
|
children: [
|
|
2977
|
-
/* @__PURE__ */
|
|
3197
|
+
/* @__PURE__ */ jsx33(UploadIcon, {
|
|
2978
3198
|
"data-icon": "inline-start"
|
|
2979
3199
|
}),
|
|
2980
3200
|
"Upload image"
|
|
2981
3201
|
]
|
|
2982
3202
|
}),
|
|
2983
|
-
/* @__PURE__ */
|
|
3203
|
+
/* @__PURE__ */ jsx33(Button2, {
|
|
2984
3204
|
type: "button",
|
|
2985
3205
|
variant: "outline",
|
|
2986
3206
|
disabled: disabled || !image,
|
|
@@ -2992,14 +3212,6 @@ function ImagePicker({ src, file, label, disabled, onFileChange, onClear }) {
|
|
|
2992
3212
|
]
|
|
2993
3213
|
});
|
|
2994
3214
|
}
|
|
2995
|
-
// src/components/PortalProvider.tsx
|
|
2996
|
-
import { jsx as jsx33 } from "react/jsx-runtime";
|
|
2997
|
-
function PortalProvider({ container, children }) {
|
|
2998
|
-
return /* @__PURE__ */ jsx33(PortalContext.Provider, {
|
|
2999
|
-
value: container,
|
|
3000
|
-
children
|
|
3001
|
-
});
|
|
3002
|
-
}
|
|
3003
3215
|
export {
|
|
3004
3216
|
Accordion,
|
|
3005
3217
|
AccordionContent,
|
|
@@ -3053,6 +3265,7 @@ export {
|
|
|
3053
3265
|
ButtonGroup,
|
|
3054
3266
|
ButtonGroupSeparator,
|
|
3055
3267
|
ButtonGroupText,
|
|
3268
|
+
ButtonLink,
|
|
3056
3269
|
Card2 as Card,
|
|
3057
3270
|
CardAction2 as CardAction,
|
|
3058
3271
|
CardContent2 as CardContent,
|
|
@@ -3230,7 +3443,7 @@ export {
|
|
|
3230
3443
|
PopoverHeader2 as PopoverHeader,
|
|
3231
3444
|
PopoverTitle2 as PopoverTitle,
|
|
3232
3445
|
PopoverTrigger2 as PopoverTrigger,
|
|
3233
|
-
PortalProvider,
|
|
3446
|
+
PortalProvider2 as PortalProvider,
|
|
3234
3447
|
Progress2 as Progress,
|
|
3235
3448
|
ProgressIndicator2 as ProgressIndicator,
|
|
3236
3449
|
ProgressLabel2 as ProgressLabel,
|
|
@@ -3240,6 +3453,7 @@ export {
|
|
|
3240
3453
|
RadioGroupItem2 as RadioGroupItem,
|
|
3241
3454
|
ScrollArea,
|
|
3242
3455
|
ScrollBar,
|
|
3456
|
+
ScrollGuard,
|
|
3243
3457
|
Select,
|
|
3244
3458
|
SelectContent,
|
|
3245
3459
|
SelectGroup,
|