@flowdrop/flowdrop 2.11.0 → 2.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +233 -0
- package/dist/adapters/agentspec/autoLayout.d.ts +18 -36
- package/dist/adapters/agentspec/autoLayout.js +75 -93
- package/dist/chat/activity.d.ts +49 -0
- package/dist/chat/activity.js +65 -0
- package/dist/chat/commandClassifier.js +2 -1
- package/dist/commands/executor.js +186 -27
- package/dist/commands/index.d.ts +2 -1
- package/dist/commands/index.js +2 -0
- package/dist/commands/parser.js +43 -3
- package/dist/commands/session.d.ts +60 -0
- package/dist/commands/session.js +332 -0
- package/dist/commands/storeIntegration.svelte.js +18 -1
- package/dist/commands/types.d.ts +77 -4
- package/dist/components/App.svelte +976 -226
- package/dist/components/App.svelte.d.ts +34 -2
- package/dist/components/BindablePortListbox.svelte +68 -369
- package/dist/components/Button.svelte +17 -14
- package/dist/components/Button.svelte.d.ts +2 -2
- package/dist/components/CanvasContextMenu.svelte +31 -10
- package/dist/components/CanvasController.svelte +146 -3
- package/dist/components/CanvasController.svelte.d.ts +25 -33
- package/dist/components/CanvasIconButton.svelte +6 -6
- package/dist/components/CanvasToolbar.svelte +103 -0
- package/dist/components/CanvasToolbar.svelte.d.ts +23 -0
- package/dist/components/CanvasZoomControls.svelte +122 -0
- package/dist/components/CanvasZoomControls.svelte.d.ts +15 -0
- package/dist/components/ConfigForm.svelte +159 -121
- package/dist/components/ConfigModal.svelte +11 -54
- package/dist/components/ConfigPanel.svelte +98 -228
- package/dist/components/ConfigPanel.svelte.d.ts +2 -2
- package/dist/components/ConnectPortPicker.svelte +153 -0
- package/dist/components/ConnectPortPicker.svelte.d.ts +22 -0
- package/dist/components/DoctorMenu.svelte +422 -0
- package/dist/components/DoctorMenu.svelte.d.ts +7 -0
- package/dist/components/ExternalLinkRow.svelte +82 -0
- package/dist/components/ExternalLinkRow.svelte.d.ts +14 -0
- package/dist/components/FlowDropEdge.svelte +52 -2
- package/dist/components/FlowDropEdge.svelte.d.ts +5 -1
- package/dist/components/InterfaceNameInput.svelte +103 -0
- package/dist/components/InterfaceNameInput.svelte.d.ts +13 -0
- package/dist/components/InterfaceTag.svelte +215 -0
- package/dist/components/InterfaceTag.svelte.d.ts +20 -0
- package/dist/components/InterfaceTagAnchor.svelte +103 -0
- package/dist/components/InterfaceTagAnchor.svelte.d.ts +12 -0
- package/dist/components/InterfaceTagLayer.svelte +314 -0
- package/dist/components/InterfaceTagLayer.svelte.d.ts +28 -0
- package/dist/components/LogsSidebar.svelte +43 -43
- package/dist/components/LoopbackLanes.svelte +54 -0
- package/dist/components/LoopbackLanes.svelte.d.ts +8 -0
- package/dist/components/Navbar.svelte +539 -169
- package/dist/components/Navbar.svelte.d.ts +20 -1
- package/dist/components/NodeInspector.svelte +153 -0
- package/dist/components/NodeInspector.svelte.d.ts +19 -0
- package/dist/components/NodeLastRun.svelte +212 -0
- package/dist/components/NodeLastRun.svelte.d.ts +13 -0
- package/dist/components/NodeSidebar.svelte +279 -23
- package/dist/components/NodeSidebar.svelte.d.ts +11 -0
- package/dist/components/NodeStatusOverlay.svelte +144 -353
- package/dist/components/NodeStatusOverlay.svelte.d.ts +4 -1
- package/dist/components/PortMappingRow.svelte +28 -44
- package/dist/components/PortPickerListbox.svelte +475 -0
- package/dist/components/PortPickerListbox.svelte.d.ts +73 -0
- package/dist/components/ReadOnlyDetails.svelte +52 -89
- package/dist/components/RunBar.svelte +222 -0
- package/dist/components/RunBar.svelte.d.ts +20 -0
- package/dist/components/RunsMenu.svelte +649 -0
- package/dist/components/RunsMenu.svelte.d.ts +14 -0
- package/dist/components/SettingsModal.svelte +27 -59
- package/dist/components/SettingsPanel.svelte +515 -241
- package/dist/components/StraightGuides.svelte +46 -0
- package/dist/components/StraightGuides.svelte.d.ts +7 -0
- package/dist/components/ThemeToggle.svelte +14 -4
- package/dist/components/UniversalNode.svelte +152 -51
- package/dist/components/WebMCPBridgeMenu.svelte +336 -0
- package/dist/components/WebMCPBridgeMenu.svelte.d.ts +3 -0
- package/dist/components/WorkflowEditor.svelte +789 -136
- package/dist/components/WorkflowEditor.svelte.d.ts +43 -1
- package/dist/components/WorkflowInterfaceEditor.svelte +63 -92
- package/dist/components/WorkflowInterfaceEntryCard.svelte +478 -549
- package/dist/components/WorkflowInterfaceEntryComposer.svelte +23 -67
- package/dist/components/WorkflowPlaygroundSettings.svelte +48 -85
- package/dist/components/WorkflowSettingsPanel.svelte +311 -0
- package/dist/components/WorkflowSettingsPanel.svelte.d.ts +20 -0
- package/dist/components/ZoomTier.svelte +56 -0
- package/dist/components/ZoomTier.svelte.d.ts +4 -0
- package/dist/components/chat/AIChatPanel.svelte +463 -312
- package/dist/components/chat/ActivityList.svelte +130 -0
- package/dist/components/chat/ActivityList.svelte.d.ts +11 -0
- package/dist/components/chat/ActivityRow.svelte +179 -0
- package/dist/components/chat/ActivityRow.svelte.d.ts +16 -0
- package/dist/components/chat/CommandPreview.svelte +42 -64
- package/dist/components/console/CommandConsole.svelte +106 -41
- package/dist/components/console/CommandConsole.svelte.d.ts +2 -0
- package/dist/components/console/ConsoleAutocomplete.svelte +14 -13
- package/dist/components/console/ConsoleInput.svelte +60 -27
- package/dist/components/console/ConsoleOutput.svelte +86 -24
- package/dist/components/console/ConsoleStrip.svelte +80 -0
- package/dist/components/console/ConsoleStrip.svelte.d.ts +13 -0
- package/dist/components/form/FieldFactory.svelte +30 -4
- package/dist/components/form/FormArray.svelte +306 -339
- package/dist/components/form/FormArray.svelte.d.ts +10 -0
- package/dist/components/form/FormArrayRows.svelte +443 -0
- package/dist/components/form/FormArrayRows.svelte.d.ts +18 -0
- package/dist/components/form/FormAutocomplete.svelte +2 -2
- package/dist/components/form/FormCheckboxGroup.svelte +10 -85
- package/dist/components/form/FormCodeEditor.svelte +3 -3
- package/dist/components/form/FormFieldWrapper.svelte +98 -18
- package/dist/components/form/FormFieldWrapper.svelte.d.ts +10 -0
- package/dist/components/form/FormFieldset.svelte +44 -28
- package/dist/components/form/FormMarkdownEditor.svelte +6 -6
- package/dist/components/form/FormPorts.svelte +437 -141
- package/dist/components/form/FormSelect.svelte +1 -1
- package/dist/components/form/FormTemplateEditor.svelte +22 -26
- package/dist/components/form/FormToggle.svelte +15 -106
- package/dist/components/form/FormToggle.svelte.d.ts +3 -2
- package/dist/components/form/FormUISchemaRenderer.svelte +38 -3
- package/dist/components/form/humanizeKey.d.ts +7 -0
- package/dist/components/form/humanizeKey.js +21 -0
- package/dist/components/form/types.d.ts +6 -0
- package/dist/components/icons/MenuOpenIcon.svelte +8 -1
- package/dist/components/interrupt/ChoicePrompt.svelte +51 -152
- package/dist/components/interrupt/ChoicePrompt.svelte.d.ts +0 -2
- package/dist/components/interrupt/ConfirmationPrompt.svelte +18 -201
- package/dist/components/interrupt/ConfirmationPrompt.svelte.d.ts +0 -4
- package/dist/components/interrupt/FormPrompt.svelte +22 -147
- package/dist/components/interrupt/FormPrompt.svelte.d.ts +0 -4
- package/dist/components/interrupt/InterruptBubble.svelte +198 -355
- package/dist/components/interrupt/InterruptBubble.svelte.d.ts +0 -2
- package/dist/components/interrupt/ReviewPrompt.svelte +0 -10
- package/dist/components/interrupt/TextInputPrompt.svelte +23 -120
- package/dist/components/interrupt/TextInputPrompt.svelte.d.ts +0 -2
- package/dist/components/layouts/MainLayout.svelte +110 -75
- package/dist/components/layouts/MainLayout.svelte.d.ts +17 -0
- package/dist/components/nodes/CaptionNode.svelte +7 -0
- package/dist/components/nodes/GatewayNode.svelte +66 -431
- package/dist/components/nodes/IdeaNode.svelte +6 -5
- package/dist/components/nodes/NodeCard.svelte +1051 -0
- package/dist/components/nodes/NodeCard.svelte.d.ts +30 -0
- package/dist/components/nodes/NodeConfigButton.svelte +28 -9
- package/dist/components/nodes/NodeProblemMark.svelte +113 -0
- package/dist/components/nodes/NodeProblemMark.svelte.d.ts +8 -0
- package/dist/components/nodes/NodeTip.svelte +104 -0
- package/dist/components/nodes/NodeTip.svelte.d.ts +15 -0
- package/dist/components/nodes/NotesNode.svelte +183 -150
- package/dist/components/nodes/SimpleNode.svelte +176 -44
- package/dist/components/nodes/SquareNode.svelte +127 -34
- package/dist/components/nodes/TerminalNode.svelte +232 -88
- package/dist/components/nodes/ToolNode.svelte +49 -381
- package/dist/components/nodes/WorkflowNode.svelte +40 -399
- package/dist/components/playground/ChatBubble.svelte +248 -62
- package/dist/components/playground/ChatInput.svelte +134 -297
- package/dist/components/playground/ChatInput.svelte.d.ts +17 -0
- package/dist/components/playground/ControlPanel.svelte +290 -190
- package/dist/components/playground/ControlPanel.svelte.d.ts +10 -2
- package/dist/components/playground/DockedPlayground.svelte +82 -0
- package/dist/components/playground/DockedPlayground.svelte.d.ts +30 -0
- package/dist/components/playground/ExecutionConsole.svelte +54 -36
- package/dist/components/playground/ExecutionConsole.svelte.d.ts +12 -0
- package/dist/components/playground/ExecutionLogs.svelte +4 -0
- package/dist/components/playground/HeaderMenu.svelte +170 -0
- package/dist/components/playground/HeaderMenu.svelte.d.ts +22 -0
- package/dist/components/playground/InputCollector.svelte +8 -32
- package/dist/components/playground/InputFields.svelte +246 -0
- package/dist/components/playground/InputFields.svelte.d.ts +16 -0
- package/dist/components/playground/InterfaceInputForm.svelte +285 -30
- package/dist/components/playground/InterfaceInputForm.svelte.d.ts +20 -0
- package/dist/components/playground/InterfaceJsonInput.svelte +92 -0
- package/dist/components/playground/InterfaceJsonInput.svelte.d.ts +10 -0
- package/dist/components/playground/LogRow.svelte +12 -12
- package/dist/components/playground/MessageMarkdown.svelte +11 -11
- package/dist/components/playground/MessageStream.svelte +154 -182
- package/dist/components/playground/Playground.svelte +17 -1139
- package/dist/components/playground/PlaygroundApp.svelte +12 -2
- package/dist/components/playground/PlaygroundApp.svelte.d.ts +2 -1
- package/dist/components/playground/PlaygroundHeader.svelte +309 -0
- package/dist/components/playground/PlaygroundHeader.svelte.d.ts +22 -0
- package/dist/components/playground/PlaygroundModal.svelte +6 -0
- package/dist/components/playground/PlaygroundStudio.svelte +30 -32
- package/dist/components/playground/PlaygroundSurface.svelte +648 -0
- package/dist/components/playground/PlaygroundSurface.svelte.d.ts +79 -0
- package/dist/components/playground/StepsSummary.svelte +312 -0
- package/dist/components/playground/StepsSummary.svelte.d.ts +11 -0
- package/dist/components/playground/messageDisplay.d.ts +9 -0
- package/dist/components/playground/messageDisplay.js +24 -2
- package/dist/components/playground/stepSummary.d.ts +71 -0
- package/dist/components/playground/stepSummary.js +152 -0
- package/dist/components/ports/PortTypeBadge.svelte +13 -1
- package/dist/components/primitives/Button.svelte +226 -0
- package/dist/components/primitives/Button.svelte.d.ts +31 -0
- package/dist/components/primitives/Card.svelte +110 -0
- package/dist/components/primitives/Card.svelte.d.ts +20 -0
- package/dist/components/primitives/Checkbox.svelte +126 -0
- package/dist/components/primitives/Checkbox.svelte.d.ts +15 -0
- package/dist/components/primitives/Chip.svelte +143 -0
- package/dist/components/primitives/Chip.svelte.d.ts +22 -0
- package/dist/components/primitives/Combobox.svelte +444 -0
- package/dist/components/primitives/Combobox.svelte.d.ts +22 -0
- package/dist/components/primitives/Composer.svelte +293 -0
- package/dist/components/primitives/Composer.svelte.d.ts +47 -0
- package/dist/components/primitives/EmptyState.svelte +113 -0
- package/dist/components/primitives/EmptyState.svelte.d.ts +18 -0
- package/dist/components/primitives/Field.svelte +178 -0
- package/dist/components/primitives/Field.svelte.d.ts +30 -0
- package/dist/components/primitives/IconButton.svelte +156 -0
- package/dist/components/primitives/IconButton.svelte.d.ts +27 -0
- package/dist/components/primitives/Menu.svelte +435 -0
- package/dist/components/primitives/Menu.svelte.d.ts +61 -0
- package/dist/components/primitives/Notice.svelte +161 -0
- package/dist/components/primitives/Notice.svelte.d.ts +22 -0
- package/dist/components/primitives/PanelHeader.svelte +134 -0
- package/dist/components/primitives/PanelHeader.svelte.d.ts +23 -0
- package/dist/components/primitives/Segmented.svelte +198 -0
- package/dist/components/primitives/Segmented.svelte.d.ts +32 -0
- package/dist/components/primitives/Select.svelte +130 -0
- package/dist/components/primitives/Select.svelte.d.ts +26 -0
- package/dist/components/primitives/StatusPill.svelte +218 -0
- package/dist/components/primitives/StatusPill.svelte.d.ts +24 -0
- package/dist/components/primitives/Switch.svelte +113 -0
- package/dist/components/primitives/Switch.svelte.d.ts +14 -0
- package/dist/components/primitives/Tabs.svelte +209 -0
- package/dist/components/primitives/Tabs.svelte.d.ts +32 -0
- package/dist/components/primitives/Toolbar.svelte +94 -0
- package/dist/components/primitives/Toolbar.svelte.d.ts +14 -0
- package/dist/components/primitives/ToolbarSeparator.svelte +40 -0
- package/dist/components/primitives/ToolbarSeparator.svelte.d.ts +7 -0
- package/dist/components/surfaces/SurfaceOverlay.svelte +10 -40
- package/dist/components/surfaces/TabbedSurface.svelte +49 -39
- package/dist/components/surfaces/TabbedSurface.svelte.d.ts +8 -0
- package/dist/components/toast/DismissibleToast.svelte +94 -32
- package/dist/components/toast/DismissibleToast.svelte.d.ts +17 -7
- package/dist/config/endpoints.d.ts +43 -1
- package/dist/config/endpoints.js +21 -3
- package/dist/core/index.d.ts +8 -5
- package/dist/core/index.js +1 -1
- package/dist/editor/connectCandidates.d.ts +56 -0
- package/dist/editor/connectCandidates.js +131 -0
- package/dist/editor/contextMenu.d.ts +31 -2
- package/dist/editor/contextMenu.js +96 -9
- package/dist/editor/index.d.ts +4 -1
- package/dist/editor/index.js +1 -0
- package/dist/editor/interfaceMenu.d.ts +35 -0
- package/dist/editor/interfaceMenu.js +47 -0
- package/dist/editor/portMenu.d.ts +23 -0
- package/dist/editor/portMenu.js +34 -0
- package/dist/editor/tidy.d.ts +30 -0
- package/dist/editor/tidy.js +66 -0
- package/dist/helpers/workflowEditorHelper.d.ts +3 -0
- package/dist/helpers/workflowEditorHelper.js +8 -3
- package/dist/layout/fromWorkflow.d.ts +42 -0
- package/dist/layout/fromWorkflow.js +135 -0
- package/dist/layout/geometry.d.ts +102 -0
- package/dist/layout/geometry.js +317 -0
- package/dist/layout/index.d.ts +21 -0
- package/dist/layout/index.js +14 -0
- package/dist/layout/inspect.d.ts +18 -0
- package/dist/layout/inspect.js +81 -0
- package/dist/layout/lanePath.d.ts +23 -0
- package/dist/layout/lanePath.js +47 -0
- package/dist/layout/measure.d.ts +141 -0
- package/dist/layout/measure.js +477 -0
- package/dist/layout/primitives.d.ts +124 -0
- package/dist/layout/primitives.js +461 -0
- package/dist/layout/sweep.d.ts +59 -0
- package/dist/layout/sweep.js +257 -0
- package/dist/layout/toWorkflow.d.ts +43 -0
- package/dist/layout/toWorkflow.js +131 -0
- package/dist/layout/types.d.ts +93 -0
- package/dist/layout/types.js +35 -0
- package/dist/messages/defaults.d.ts +641 -26
- package/dist/messages/defaults.js +578 -25
- package/dist/messages/types.d.ts +21 -1
- package/dist/openapi/v1/openapi.yaml +109 -0
- package/dist/playground/index.d.ts +28 -1
- package/dist/playground/index.js +29 -0
- package/dist/playground/mount.d.ts +28 -2
- package/dist/playground/mount.js +41 -15
- package/dist/playground/runAction.d.ts +29 -0
- package/dist/playground/runAction.js +38 -0
- package/dist/services/doctorService.d.ts +52 -0
- package/dist/services/doctorService.js +113 -0
- package/dist/services/globalSave.js +12 -29
- package/dist/services/nodeExecutionService.d.ts +12 -1
- package/dist/services/nodeExecutionService.js +58 -58
- package/dist/services/playgroundService.d.ts +17 -2
- package/dist/services/playgroundService.js +48 -5
- package/dist/services/runsService.d.ts +42 -0
- package/dist/services/runsService.js +87 -0
- package/dist/services/toastQueue.d.ts +33 -0
- package/dist/services/toastQueue.js +38 -0
- package/dist/services/toastService.d.ts +30 -9
- package/dist/services/toastService.js +81 -46
- package/dist/settings/index.d.ts +1 -0
- package/dist/skins/graphite.d.ts +26 -0
- package/dist/skins/graphite.js +473 -0
- package/dist/skins/index.d.ts +2 -1
- package/dist/skins/index.js +4 -2
- package/dist/skins/slate.js +4 -4
- package/dist/stores/attachedRunStore.svelte.d.ts +35 -0
- package/dist/stores/attachedRunStore.svelte.js +47 -0
- package/dist/stores/connectDragStore.svelte.d.ts +39 -0
- package/dist/stores/connectDragStore.svelte.js +42 -0
- package/dist/stores/doctorStore.svelte.d.ts +79 -0
- package/dist/stores/doctorStore.svelte.js +244 -0
- package/dist/stores/editedNodesStore.svelte.d.ts +42 -0
- package/dist/stores/editedNodesStore.svelte.js +84 -0
- package/dist/stores/editorModeStore.svelte.d.ts +34 -0
- package/dist/stores/editorModeStore.svelte.js +55 -0
- package/dist/stores/instanceContainer.svelte.d.ts +53 -0
- package/dist/stores/instanceContainer.svelte.js +38 -1
- package/dist/stores/loopbackLanesStore.svelte.d.ts +18 -0
- package/dist/stores/loopbackLanesStore.svelte.js +25 -0
- package/dist/stores/nodeHighlightStore.svelte.d.ts +34 -0
- package/dist/stores/nodeHighlightStore.svelte.js +56 -0
- package/dist/stores/playgroundStore.svelte.d.ts +66 -2
- package/dist/stores/playgroundStore.svelte.js +164 -2
- package/dist/stores/runController.svelte.d.ts +382 -0
- package/dist/stores/runController.svelte.js +1217 -0
- package/dist/stores/settingsStore.svelte.d.ts +80 -18
- package/dist/stores/settingsStore.svelte.js +180 -62
- package/dist/stores/workflowStore.svelte.d.ts +14 -0
- package/dist/stores/workflowStore.svelte.js +22 -1
- package/dist/styles/base.css +286 -25
- package/dist/styles/fonts/Inter-LICENSE.txt +93 -0
- package/dist/styles/fonts/inter-latin-wght-normal.woff2 +0 -0
- package/dist/styles/fonts/inter.css +19 -0
- package/dist/styles/toast.css +100 -20
- package/dist/styles/tokenAliases.js +118 -1
- package/dist/styles/tokens.css +586 -14
- package/dist/svelte-app.d.ts +47 -5
- package/dist/svelte-app.js +15 -3
- package/dist/themes/graphite.d.ts +2 -0
- package/dist/themes/graphite.js +15 -0
- package/dist/themes/index.d.ts +2 -1
- package/dist/themes/index.js +22 -3
- package/dist/themes/minimal.js +10 -0
- package/dist/themes/scopedSkinCss.d.ts +22 -5
- package/dist/themes/scopedSkinCss.js +136 -11
- package/dist/types/chat.d.ts +6 -0
- package/dist/types/doctor.d.ts +82 -0
- package/dist/types/doctor.js +11 -0
- package/dist/types/events.d.ts +35 -0
- package/dist/types/events.js +4 -1
- package/dist/types/index.d.ts +17 -2
- package/dist/types/navbar.d.ts +36 -0
- package/dist/types/playground.d.ts +75 -0
- package/dist/types/settings.d.ts +120 -7
- package/dist/types/settings.js +35 -3
- package/dist/types/skin.d.ts +21 -8
- package/dist/types/theme.d.ts +40 -2
- package/dist/utils/appearance.d.ts +19 -0
- package/dist/utils/appearance.js +13 -0
- package/dist/utils/canvasFit.d.ts +41 -0
- package/dist/utils/canvasFit.js +44 -0
- package/dist/utils/chipTitles.d.ts +9 -0
- package/dist/utils/chipTitles.js +19 -0
- package/dist/utils/connections.js +8 -0
- package/dist/utils/consoleHighlight.d.ts +28 -0
- package/dist/utils/consoleHighlight.js +269 -0
- package/dist/utils/deprecation.d.ts +17 -0
- package/dist/utils/deprecation.js +29 -0
- package/dist/utils/doctorOperations.d.ts +40 -0
- package/dist/utils/doctorOperations.js +237 -0
- package/dist/utils/duration.d.ts +13 -0
- package/dist/utils/duration.js +40 -0
- package/dist/utils/inspectorContext.d.ts +19 -0
- package/dist/utils/inspectorContext.js +12 -0
- package/dist/utils/inspectorSections.d.ts +20 -0
- package/dist/utils/inspectorSections.js +44 -0
- package/dist/utils/inspectorSurface.d.ts +46 -0
- package/dist/utils/inspectorSurface.js +51 -0
- package/dist/utils/interfaceTags.d.ts +102 -0
- package/dist/utils/interfaceTags.js +211 -0
- package/dist/utils/itemRef.d.ts +86 -0
- package/dist/utils/itemRef.js +106 -0
- package/dist/utils/lastRun.d.ts +35 -0
- package/dist/utils/lastRun.js +73 -0
- package/dist/utils/messageNodeLink.d.ts +17 -0
- package/dist/utils/messageNodeLink.js +16 -0
- package/dist/utils/minimapVisibility.d.ts +28 -0
- package/dist/utils/minimapVisibility.js +34 -0
- package/dist/utils/nodeAriaLabel.d.ts +12 -0
- package/dist/utils/nodeAriaLabel.js +17 -0
- package/dist/utils/nodeFingerprint.d.ts +27 -0
- package/dist/utils/nodeFingerprint.js +66 -0
- package/dist/utils/nodeFormSchema.d.ts +10 -0
- package/dist/utils/nodeFormSchema.js +2 -2
- package/dist/utils/nodeGeometry.d.ts +168 -0
- package/dist/utils/nodeGeometry.js +204 -0
- package/dist/utils/nodeProblem.d.ts +19 -0
- package/dist/utils/nodeProblem.js +9 -0
- package/dist/utils/nodeStatus.d.ts +38 -3
- package/dist/utils/nodeStatus.js +67 -39
- package/dist/utils/nodeSwap.js +9 -1
- package/dist/utils/nodeWrapper.d.ts +1 -0
- package/dist/utils/playgroundHistory.d.ts +48 -0
- package/dist/utils/playgroundHistory.js +38 -0
- package/dist/utils/playgroundInputRuns.d.ts +26 -0
- package/dist/utils/playgroundInputRuns.js +50 -0
- package/dist/utils/portExposure.d.ts +49 -0
- package/dist/utils/portExposure.js +122 -0
- package/dist/utils/portUtils.d.ts +16 -0
- package/dist/utils/portUtils.js +37 -0
- package/dist/utils/portal.d.ts +0 -19
- package/dist/utils/portal.js +8 -1
- package/dist/utils/reservedPorts.d.ts +59 -0
- package/dist/utils/reservedPorts.js +60 -0
- package/dist/utils/runEdges.d.ts +24 -0
- package/dist/utils/runEdges.js +35 -0
- package/dist/utils/runsList.d.ts +69 -0
- package/dist/utils/runsList.js +134 -0
- package/dist/utils/selectOptions.d.ts +62 -0
- package/dist/utils/selectOptions.js +137 -0
- package/dist/utils/sessionRuns.d.ts +62 -0
- package/dist/utils/sessionRuns.js +123 -0
- package/dist/utils/sheetWidths.d.ts +29 -0
- package/dist/utils/sheetWidths.js +41 -0
- package/dist/utils/sidebarWidths.d.ts +34 -0
- package/dist/utils/sidebarWidths.js +47 -0
- package/dist/utils/straightWires.d.ts +73 -0
- package/dist/utils/straightWires.js +99 -0
- package/dist/utils/themeScope.svelte.d.ts +10 -0
- package/dist/utils/themeScope.svelte.js +80 -0
- package/dist/utils/wiredHandles.d.ts +10 -0
- package/dist/utils/wiredHandles.js +14 -0
- package/dist/utils/workflowDraft.d.ts +9 -0
- package/dist/utils/workflowDraft.js +39 -0
- package/dist/utils/workflowInterface.d.ts +40 -7
- package/dist/utils/workflowInterface.js +66 -16
- package/dist/utils/zoomTier.d.ts +43 -0
- package/dist/utils/zoomTier.js +107 -0
- package/dist/utils/zoomTierRows.d.ts +41 -0
- package/dist/utils/zoomTierRows.js +103 -0
- package/dist/webmcp/WebMCPConfirm.svelte +1 -1
- package/dist/webmcp/bridge.d.ts +5 -0
- package/dist/webmcp/bridge.js +8 -0
- package/dist/webmcp/bridgeController.svelte.d.ts +84 -0
- package/dist/webmcp/bridgeController.svelte.js +224 -0
- package/dist/webmcp/descriptors.d.ts +1 -1
- package/dist/webmcp/descriptors.js +66 -5
- package/dist/webmcp/fakeWidget.d.ts +34 -0
- package/dist/webmcp/fakeWidget.js +75 -0
- package/dist/webmcp/gate.js +4 -0
- package/dist/webmcp/index.d.ts +2 -0
- package/dist/webmcp/index.js +1 -0
- package/dist/webmcp/runtime.js +4 -1
- package/dist/webmcp/types.d.ts +2 -0
- package/dist/webmcp/validate.js +5 -1
- package/package.json +8 -2
- package/dist/components/Select.svelte +0 -53
- package/dist/components/Select.svelte.d.ts +0 -15
- package/dist/components/icons/CommandLineIcon.svelte +0 -15
- package/dist/components/icons/CommandLineIcon.svelte.d.ts +0 -26
- package/dist/components/toast/WarningIcon.svelte +0 -28
- package/dist/components/toast/WarningIcon.svelte.d.ts +0 -26
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
DockedPlayground
|
|
3
|
+
|
|
4
|
+
The Playground of the editor's Test mode: the conversation surface beside
|
|
5
|
+
the canvas, for the editor's current workflow and the instance's current test
|
|
6
|
+
session (`fd.runs`). Compact by design: no minimum width and no pipeline
|
|
7
|
+
panel (the canvas shows the run). Its header is two controls: the history
|
|
8
|
+
chip (conversations and runs) and the ⋯ menu (PlaygroundHeader). Built on
|
|
9
|
+
PlaygroundSurface, not on the standalone Playground, so it does not go when
|
|
10
|
+
that one is removed in 3.0.
|
|
11
|
+
|
|
12
|
+
The session outlives this component: switching back to Edit unmounts it, the
|
|
13
|
+
run goes on, and Test finds the conversation where it was left.
|
|
14
|
+
-->
|
|
15
|
+
|
|
16
|
+
<script lang="ts">
|
|
17
|
+
import type { Snippet } from 'svelte';
|
|
18
|
+
import PlaygroundSurface from './PlaygroundSurface.svelte';
|
|
19
|
+
import type { Workflow } from '../../types/index.js';
|
|
20
|
+
import type { EditorPlaygroundConfig } from '../../types/playground.js';
|
|
21
|
+
|
|
22
|
+
interface Props {
|
|
23
|
+
/** The editor's workflow, live: its unsaved edits are what the next turn runs. */
|
|
24
|
+
workflow: Workflow;
|
|
25
|
+
/** Opens the workflow's Playground settings in the inspector. */
|
|
26
|
+
onOpenSettings?: () => void;
|
|
27
|
+
/**
|
|
28
|
+
* The editor's save, so Send reads "Save & send" while the workflow has
|
|
29
|
+
* unsaved edits. Resolves `true` when written; throws when it fails.
|
|
30
|
+
*/
|
|
31
|
+
onSave?: () => Promise<boolean>;
|
|
32
|
+
/**
|
|
33
|
+
* Extra entries at the end of the header's ⋯ menu (buttons with
|
|
34
|
+
* `class="header-menu__item"` and `role="menuitem"`; call `close()` after
|
|
35
|
+
* acting). The editor's own actions for a run go here.
|
|
36
|
+
*/
|
|
37
|
+
menuItems?: Snippet<[{ close: () => void }]>;
|
|
38
|
+
/**
|
|
39
|
+
* How the surface follows a run (`pollingInterval`, `shouldStopPolling`).
|
|
40
|
+
* Forwarded to PlaygroundSurface's `config`; unset, the defaults apply.
|
|
41
|
+
*/
|
|
42
|
+
config?: EditorPlaygroundConfig;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
let { workflow, onOpenSettings, onSave, menuItems, config }: Props = $props();
|
|
46
|
+
</script>
|
|
47
|
+
|
|
48
|
+
<div class="docked-playground" data-testid="docked-playground">
|
|
49
|
+
{#key workflow.id}
|
|
50
|
+
<PlaygroundSurface
|
|
51
|
+
workflowId={workflow.id}
|
|
52
|
+
{workflow}
|
|
53
|
+
mode="embedded"
|
|
54
|
+
retainSession
|
|
55
|
+
followWorkflow
|
|
56
|
+
sessionOptional
|
|
57
|
+
playgroundSessionsOnly
|
|
58
|
+
historyHeader
|
|
59
|
+
{config}
|
|
60
|
+
{menuItems}
|
|
61
|
+
{onSave}
|
|
62
|
+
{onOpenSettings}
|
|
63
|
+
/>
|
|
64
|
+
{/key}
|
|
65
|
+
</div>
|
|
66
|
+
|
|
67
|
+
<style>
|
|
68
|
+
.docked-playground {
|
|
69
|
+
height: 100%;
|
|
70
|
+
min-width: 0;
|
|
71
|
+
min-height: 0;
|
|
72
|
+
display: flex;
|
|
73
|
+
flex-direction: column;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
/* The surface's embedded look is a right-hand drawer; docked on the left it
|
|
77
|
+
is separated from the canvas by the layout's own border. */
|
|
78
|
+
.docked-playground :global(.playground--embedded) {
|
|
79
|
+
border-left: 0;
|
|
80
|
+
box-shadow: none;
|
|
81
|
+
}
|
|
82
|
+
</style>
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import type { Snippet } from 'svelte';
|
|
2
|
+
import type { Workflow } from '../../types/index.js';
|
|
3
|
+
import type { EditorPlaygroundConfig } from '../../types/playground.js';
|
|
4
|
+
interface Props {
|
|
5
|
+
/** The editor's workflow, live: its unsaved edits are what the next turn runs. */
|
|
6
|
+
workflow: Workflow;
|
|
7
|
+
/** Opens the workflow's Playground settings in the inspector. */
|
|
8
|
+
onOpenSettings?: () => void;
|
|
9
|
+
/**
|
|
10
|
+
* The editor's save, so Send reads "Save & send" while the workflow has
|
|
11
|
+
* unsaved edits. Resolves `true` when written; throws when it fails.
|
|
12
|
+
*/
|
|
13
|
+
onSave?: () => Promise<boolean>;
|
|
14
|
+
/**
|
|
15
|
+
* Extra entries at the end of the header's ⋯ menu (buttons with
|
|
16
|
+
* `class="header-menu__item"` and `role="menuitem"`; call `close()` after
|
|
17
|
+
* acting). The editor's own actions for a run go here.
|
|
18
|
+
*/
|
|
19
|
+
menuItems?: Snippet<[{
|
|
20
|
+
close: () => void;
|
|
21
|
+
}]>;
|
|
22
|
+
/**
|
|
23
|
+
* How the surface follows a run (`pollingInterval`, `shouldStopPolling`).
|
|
24
|
+
* Forwarded to PlaygroundSurface's `config`; unset, the defaults apply.
|
|
25
|
+
*/
|
|
26
|
+
config?: EditorPlaygroundConfig;
|
|
27
|
+
}
|
|
28
|
+
declare const DockedPlayground: import("svelte").Component<Props, {}, "">;
|
|
29
|
+
type DockedPlayground = ReturnType<typeof DockedPlayground>;
|
|
30
|
+
export default DockedPlayground;
|
|
@@ -10,6 +10,8 @@
|
|
|
10
10
|
<script lang="ts">
|
|
11
11
|
import Icon from '@iconify/svelte';
|
|
12
12
|
import MessageStream from './MessageStream.svelte';
|
|
13
|
+
import Button from '../primitives/Button.svelte';
|
|
14
|
+
import Notice from '../primitives/Notice.svelte';
|
|
13
15
|
import { m } from '../../messages/index.js';
|
|
14
16
|
|
|
15
17
|
interface Props {
|
|
@@ -24,6 +26,18 @@
|
|
|
24
26
|
onCreateSession?: () => void;
|
|
25
27
|
/** Called when the user scrolls near the top to load older messages */
|
|
26
28
|
onLoadOlder?: () => void | Promise<void>;
|
|
29
|
+
/**
|
|
30
|
+
* The first send creates the session, so "no session yet" is the ready
|
|
31
|
+
* state, not a prompt to create one.
|
|
32
|
+
*/
|
|
33
|
+
sessionOptional?: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* One line shown in the empty conversation (the chat cannot reply yet) and
|
|
36
|
+
* gone once any message exists. Absent renders nothing.
|
|
37
|
+
*/
|
|
38
|
+
notice?: string;
|
|
39
|
+
/** Adds a "Playground settings" action to the notice. */
|
|
40
|
+
onOpenSettings?: () => void;
|
|
27
41
|
}
|
|
28
42
|
|
|
29
43
|
let {
|
|
@@ -34,18 +48,17 @@
|
|
|
34
48
|
compactSystemMessages = true,
|
|
35
49
|
onInterruptResolved,
|
|
36
50
|
onCreateSession,
|
|
37
|
-
onLoadOlder
|
|
51
|
+
onLoadOlder,
|
|
52
|
+
sessionOptional = false,
|
|
53
|
+
notice,
|
|
54
|
+
onOpenSettings
|
|
38
55
|
}: Props = $props();
|
|
39
56
|
|
|
40
57
|
const ec = $derived(m().playground.executionConsole);
|
|
58
|
+
const settingsLabel = $derived(m().playground.header.playgroundSettings);
|
|
41
59
|
</script>
|
|
42
60
|
|
|
43
61
|
<section class="execution-console">
|
|
44
|
-
<header class="execution-console__header">
|
|
45
|
-
<Icon icon="mdi:console-line" class="execution-console__icon" />
|
|
46
|
-
<span class="execution-console__title">{ec.header}</span>
|
|
47
|
-
</header>
|
|
48
|
-
|
|
49
62
|
<MessageStream
|
|
50
63
|
{showTimestamps}
|
|
51
64
|
{autoScroll}
|
|
@@ -54,8 +67,8 @@
|
|
|
54
67
|
{compactSystemMessages}
|
|
55
68
|
{onInterruptResolved}
|
|
56
69
|
{onLoadOlder}
|
|
57
|
-
welcome={welcomeState}
|
|
58
|
-
emptySession={
|
|
70
|
+
welcome={sessionOptional ? (notice ? noticeState : undefined) : welcomeState}
|
|
71
|
+
emptySession={notice ? noticeState : undefined}
|
|
59
72
|
/>
|
|
60
73
|
</section>
|
|
61
74
|
|
|
@@ -64,6 +77,9 @@
|
|
|
64
77
|
<Icon icon="mdi:play-circle-outline" class="execution-console__placeholder-icon" />
|
|
65
78
|
<h2 class="execution-console__placeholder-title">{ec.noExecutionTitle}</h2>
|
|
66
79
|
<p class="execution-console__placeholder-text">{ec.noExecutionText}</p>
|
|
80
|
+
{#if notice}
|
|
81
|
+
{@render noticeBlock()}
|
|
82
|
+
{/if}
|
|
67
83
|
{#if onCreateSession}
|
|
68
84
|
<button type="button" class="execution-console__cta" onclick={onCreateSession}>
|
|
69
85
|
<Icon icon="mdi:plus" />
|
|
@@ -73,15 +89,40 @@
|
|
|
73
89
|
</div>
|
|
74
90
|
{/snippet}
|
|
75
91
|
|
|
76
|
-
{#snippet
|
|
77
|
-
<div class="execution-
|
|
78
|
-
<
|
|
79
|
-
|
|
80
|
-
|
|
92
|
+
{#snippet noticeBlock()}
|
|
93
|
+
<div class="execution-console__notice" data-testid="playground-notice">
|
|
94
|
+
<Notice tone="info" role="note">
|
|
95
|
+
{notice}
|
|
96
|
+
{#snippet actions()}
|
|
97
|
+
{#if onOpenSettings}
|
|
98
|
+
<Button size="sm" onclick={onOpenSettings}>{settingsLabel}</Button>
|
|
99
|
+
{/if}
|
|
100
|
+
{/snippet}
|
|
101
|
+
</Notice>
|
|
102
|
+
</div>
|
|
103
|
+
{/snippet}
|
|
104
|
+
|
|
105
|
+
{#snippet noticeState()}
|
|
106
|
+
<div class="execution-console__empty">
|
|
107
|
+
{@render noticeBlock()}
|
|
81
108
|
</div>
|
|
82
109
|
{/snippet}
|
|
83
110
|
|
|
84
111
|
<style>
|
|
112
|
+
.execution-console__empty {
|
|
113
|
+
display: flex;
|
|
114
|
+
align-items: center;
|
|
115
|
+
justify-content: center;
|
|
116
|
+
height: 100%;
|
|
117
|
+
padding: var(--fd-space-md);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.execution-console__notice {
|
|
121
|
+
max-width: 420px;
|
|
122
|
+
margin-top: var(--fd-space-xl);
|
|
123
|
+
text-align: left;
|
|
124
|
+
}
|
|
125
|
+
|
|
85
126
|
.execution-console {
|
|
86
127
|
flex: 1;
|
|
87
128
|
min-height: 0;
|
|
@@ -91,29 +132,6 @@
|
|
|
91
132
|
background-color: var(--fd-background);
|
|
92
133
|
}
|
|
93
134
|
|
|
94
|
-
.execution-console__header {
|
|
95
|
-
display: flex;
|
|
96
|
-
align-items: center;
|
|
97
|
-
gap: var(--fd-space-xs);
|
|
98
|
-
padding: 0 var(--fd-space-xl);
|
|
99
|
-
height: var(--fd-playground-header-height);
|
|
100
|
-
min-height: var(--fd-playground-header-height);
|
|
101
|
-
border-bottom: 1px solid var(--fd-border);
|
|
102
|
-
flex-shrink: 0;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
:global(.execution-console__icon) {
|
|
106
|
-
font-size: var(--fd-text-base);
|
|
107
|
-
color: var(--fd-muted-foreground);
|
|
108
|
-
flex-shrink: 0;
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
.execution-console__title {
|
|
112
|
-
font-size: var(--fd-text-sm);
|
|
113
|
-
font-weight: 600;
|
|
114
|
-
color: var(--fd-foreground);
|
|
115
|
-
}
|
|
116
|
-
|
|
117
135
|
.execution-console__placeholder {
|
|
118
136
|
display: flex;
|
|
119
137
|
flex-direction: column;
|
|
@@ -10,6 +10,18 @@ interface Props {
|
|
|
10
10
|
onCreateSession?: () => void;
|
|
11
11
|
/** Called when the user scrolls near the top to load older messages */
|
|
12
12
|
onLoadOlder?: () => void | Promise<void>;
|
|
13
|
+
/**
|
|
14
|
+
* The first send creates the session, so "no session yet" is the ready
|
|
15
|
+
* state, not a prompt to create one.
|
|
16
|
+
*/
|
|
17
|
+
sessionOptional?: boolean;
|
|
18
|
+
/**
|
|
19
|
+
* One line shown in the empty conversation (the chat cannot reply yet) and
|
|
20
|
+
* gone once any message exists. Absent renders nothing.
|
|
21
|
+
*/
|
|
22
|
+
notice?: string;
|
|
23
|
+
/** Adds a "Playground settings" action to the notice. */
|
|
24
|
+
onOpenSettings?: () => void;
|
|
13
25
|
}
|
|
14
26
|
declare const ExecutionConsole: import("svelte").Component<Props, {}, "">;
|
|
15
27
|
type ExecutionConsole = ReturnType<typeof ExecutionConsole>;
|
|
@@ -4,6 +4,10 @@
|
|
|
4
4
|
Collapsible panel for displaying execution logs in the playground.
|
|
5
5
|
Shows real-time log entries with filtering and export capabilities.
|
|
6
6
|
Styled with BEM syntax.
|
|
7
|
+
|
|
8
|
+
@deprecated Not used by the Playground surfaces any more: the conversation
|
|
9
|
+
folds each turn's steps into one summary row (StepsSummary). Kept exported
|
|
10
|
+
for existing consumers.
|
|
7
11
|
-->
|
|
8
12
|
|
|
9
13
|
<script lang="ts">
|
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
HeaderMenu
|
|
3
|
+
|
|
4
|
+
A button that opens a menu: the one control behind both the history chip and
|
|
5
|
+
the ⋯ menu of the docked Playground's header. A thin skin over the `Menu`
|
|
6
|
+
primitive, which owns keyboard handling (arrows, Home/End, typeahead, Escape,
|
|
7
|
+
Tab), ARIA and positioning.
|
|
8
|
+
|
|
9
|
+
Items are any element with `role="menuitem"`, `menuitemcheckbox` or
|
|
10
|
+
`menuitemradio` inside `children`, which receives `close` so an item can
|
|
11
|
+
close the menu after it acts.
|
|
12
|
+
-->
|
|
13
|
+
|
|
14
|
+
<script lang="ts">
|
|
15
|
+
import type { Snippet } from 'svelte';
|
|
16
|
+
import Menu from '../primitives/Menu.svelte';
|
|
17
|
+
|
|
18
|
+
interface Props {
|
|
19
|
+
/** Accessible name of the button (and of the menu). */
|
|
20
|
+
label: string;
|
|
21
|
+
/** Test hook, put on the button. */
|
|
22
|
+
testId?: string;
|
|
23
|
+
/** Button content. */
|
|
24
|
+
trigger: Snippet;
|
|
25
|
+
/** The menu's items. */
|
|
26
|
+
children: Snippet<[{ close: () => void }]>;
|
|
27
|
+
/** Which edge of the button the menu lines up with. @default 'start' */
|
|
28
|
+
align?: 'start' | 'end';
|
|
29
|
+
/** Runs when the menu opens (refresh what it lists). */
|
|
30
|
+
onOpen?: () => void;
|
|
31
|
+
/** `chip` is a labelled pill, `icon` a square icon button. @default 'chip' */
|
|
32
|
+
variant?: 'chip' | 'icon';
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
let {
|
|
36
|
+
label,
|
|
37
|
+
testId,
|
|
38
|
+
trigger,
|
|
39
|
+
children,
|
|
40
|
+
align = 'start',
|
|
41
|
+
onOpen,
|
|
42
|
+
variant = 'chip'
|
|
43
|
+
}: Props = $props();
|
|
44
|
+
</script>
|
|
45
|
+
|
|
46
|
+
<Menu
|
|
47
|
+
class="header-menu"
|
|
48
|
+
{label}
|
|
49
|
+
{testId}
|
|
50
|
+
{align}
|
|
51
|
+
{onOpen}
|
|
52
|
+
{trigger}
|
|
53
|
+
{children}
|
|
54
|
+
minWidth={220}
|
|
55
|
+
triggerClass="header-menu__button header-menu__button--{variant}"
|
|
56
|
+
/>
|
|
57
|
+
|
|
58
|
+
<style>
|
|
59
|
+
:global(.header-menu__button) {
|
|
60
|
+
display: inline-flex;
|
|
61
|
+
align-items: center;
|
|
62
|
+
gap: var(--fd-space-xs);
|
|
63
|
+
min-width: 0;
|
|
64
|
+
border: 0;
|
|
65
|
+
background: transparent;
|
|
66
|
+
color: var(--fd-foreground);
|
|
67
|
+
font-size: var(--fd-text-sm);
|
|
68
|
+
font-weight: 500;
|
|
69
|
+
line-height: 1;
|
|
70
|
+
cursor: pointer;
|
|
71
|
+
transition: background-color var(--fd-transition-fast);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
/* The session chip is a label with a chevron, not a box: a fill appears on hover. */
|
|
75
|
+
:global(.header-menu__button--chip) {
|
|
76
|
+
height: var(--fd-control-md);
|
|
77
|
+
padding: 0 var(--fd-space-xs);
|
|
78
|
+
border-radius: var(--fd-control-radius);
|
|
79
|
+
font-weight: 600;
|
|
80
|
+
max-width: 100%;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
:global(.header-menu__button--icon) {
|
|
84
|
+
justify-content: center;
|
|
85
|
+
width: var(--fd-size-icon-btn);
|
|
86
|
+
height: var(--fd-size-icon-btn);
|
|
87
|
+
padding: 0;
|
|
88
|
+
border-radius: var(--fd-control-radius);
|
|
89
|
+
color: var(--fd-muted-foreground);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
:global(.header-menu__button:hover),
|
|
93
|
+
:global(.header-menu__button.flowdrop-ui-menu__trigger--open) {
|
|
94
|
+
background-color: var(--fd-muted);
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
:global(.header-menu__button:focus-visible) {
|
|
98
|
+
outline: 2px solid var(--fd-primary);
|
|
99
|
+
outline-offset: 1px;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
/* Shared by every item the header (or a host, through `menuItems`) renders. */
|
|
103
|
+
:global(.header-menu__item) {
|
|
104
|
+
display: flex;
|
|
105
|
+
flex-direction: column;
|
|
106
|
+
align-items: flex-start;
|
|
107
|
+
gap: 1px;
|
|
108
|
+
width: 100%;
|
|
109
|
+
padding: var(--fd-space-sm);
|
|
110
|
+
border: none;
|
|
111
|
+
border-radius: var(--fd-radius-sm);
|
|
112
|
+
background: transparent;
|
|
113
|
+
color: var(--fd-foreground);
|
|
114
|
+
font: inherit;
|
|
115
|
+
font-size: var(--fd-text-sm);
|
|
116
|
+
text-align: left;
|
|
117
|
+
cursor: pointer;
|
|
118
|
+
transition: background-color var(--fd-transition-fast);
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
:global(.header-menu__item:hover:not(:disabled)),
|
|
122
|
+
:global(.header-menu__item:focus-visible) {
|
|
123
|
+
background-color: var(--fd-muted);
|
|
124
|
+
outline: none;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
:global(.header-menu__item:disabled) {
|
|
128
|
+
opacity: 0.45;
|
|
129
|
+
cursor: not-allowed;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
:global(.header-menu__item-label) {
|
|
133
|
+
display: flex;
|
|
134
|
+
align-items: center;
|
|
135
|
+
gap: var(--fd-space-xs);
|
|
136
|
+
max-width: 100%;
|
|
137
|
+
font-weight: 500;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
:global(.header-menu__item-label > span) {
|
|
141
|
+
overflow: hidden;
|
|
142
|
+
text-overflow: ellipsis;
|
|
143
|
+
white-space: nowrap;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
:global(.header-menu__item-hint) {
|
|
147
|
+
max-width: 100%;
|
|
148
|
+
color: var(--fd-muted-foreground);
|
|
149
|
+
font-size: var(--fd-text-xs);
|
|
150
|
+
font-weight: 400;
|
|
151
|
+
overflow: hidden;
|
|
152
|
+
text-overflow: ellipsis;
|
|
153
|
+
white-space: nowrap;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
:global(.header-menu__group) {
|
|
157
|
+
padding: var(--fd-space-xs) var(--fd-space-sm) var(--fd-space-3xs);
|
|
158
|
+
color: var(--fd-muted-foreground);
|
|
159
|
+
font-size: var(--fd-text-xs);
|
|
160
|
+
font-weight: 600;
|
|
161
|
+
text-transform: uppercase;
|
|
162
|
+
letter-spacing: 0.04em;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
:global(.header-menu__divider) {
|
|
166
|
+
height: 1px;
|
|
167
|
+
margin: var(--fd-space-xs) 0;
|
|
168
|
+
background-color: var(--fd-border-muted);
|
|
169
|
+
}
|
|
170
|
+
</style>
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { Snippet } from 'svelte';
|
|
2
|
+
interface Props {
|
|
3
|
+
/** Accessible name of the button (and of the menu). */
|
|
4
|
+
label: string;
|
|
5
|
+
/** Test hook, put on the button. */
|
|
6
|
+
testId?: string;
|
|
7
|
+
/** Button content. */
|
|
8
|
+
trigger: Snippet;
|
|
9
|
+
/** The menu's items. */
|
|
10
|
+
children: Snippet<[{
|
|
11
|
+
close: () => void;
|
|
12
|
+
}]>;
|
|
13
|
+
/** Which edge of the button the menu lines up with. @default 'start' */
|
|
14
|
+
align?: 'start' | 'end';
|
|
15
|
+
/** Runs when the menu opens (refresh what it lists). */
|
|
16
|
+
onOpen?: () => void;
|
|
17
|
+
/** `chip` is a labelled pill, `icon` a square icon button. @default 'chip' */
|
|
18
|
+
variant?: 'chip' | 'icon';
|
|
19
|
+
}
|
|
20
|
+
declare const HeaderMenu: import("svelte").Component<Props, {}, "">;
|
|
21
|
+
type HeaderMenu = ReturnType<typeof HeaderMenu>;
|
|
22
|
+
export default HeaderMenu;
|
|
@@ -9,7 +9,8 @@
|
|
|
9
9
|
<script lang="ts">
|
|
10
10
|
import Icon from '@iconify/svelte';
|
|
11
11
|
import Input from '../Input.svelte';
|
|
12
|
-
import Select from '../Select.svelte';
|
|
12
|
+
import Select from '../primitives/Select.svelte';
|
|
13
|
+
import Checkbox from '../primitives/Checkbox.svelte';
|
|
13
14
|
import Textarea from '../Textarea.svelte';
|
|
14
15
|
import { slide } from 'svelte/transition';
|
|
15
16
|
import type { PlaygroundInputField } from '../../types/playground.js';
|
|
@@ -195,18 +196,12 @@
|
|
|
195
196
|
/>
|
|
196
197
|
{:else if getInputType(field) === 'checkbox'}
|
|
197
198
|
<!-- Checkbox for boolean -->
|
|
198
|
-
<
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
onchange={(e) => updateValue(field, e.currentTarget.checked)}
|
|
205
|
-
/>
|
|
206
|
-
<span class="input-collector__checkbox-label">
|
|
207
|
-
{field.schema?.description ?? 'Enable'}
|
|
208
|
-
</span>
|
|
209
|
-
</label>
|
|
199
|
+
<Checkbox
|
|
200
|
+
id="input-{field.nodeId}-{field.fieldId}"
|
|
201
|
+
checked={Boolean(getValue(field))}
|
|
202
|
+
label={field.schema?.description ?? 'Enable'}
|
|
203
|
+
onchange={(on) => updateValue(field, on)}
|
|
204
|
+
/>
|
|
210
205
|
{:else if getInputType(field) === 'number'}
|
|
211
206
|
<!-- Number input -->
|
|
212
207
|
<Input
|
|
@@ -351,25 +346,6 @@
|
|
|
351
346
|
color: var(--fd-error);
|
|
352
347
|
}
|
|
353
348
|
|
|
354
|
-
.input-collector__checkbox-wrapper {
|
|
355
|
-
display: flex;
|
|
356
|
-
align-items: center;
|
|
357
|
-
gap: var(--fd-space-xs);
|
|
358
|
-
cursor: pointer;
|
|
359
|
-
}
|
|
360
|
-
|
|
361
|
-
.input-collector__checkbox {
|
|
362
|
-
width: 1rem;
|
|
363
|
-
height: 1rem;
|
|
364
|
-
accent-color: var(--fd-primary);
|
|
365
|
-
cursor: pointer;
|
|
366
|
-
}
|
|
367
|
-
|
|
368
|
-
.input-collector__checkbox-label {
|
|
369
|
-
font-size: var(--fd-text-sm);
|
|
370
|
-
color: var(--fd-muted-foreground);
|
|
371
|
-
}
|
|
372
|
-
|
|
373
349
|
.input-collector__description {
|
|
374
350
|
font-size: var(--fd-text-xs);
|
|
375
351
|
color: var(--fd-muted-foreground);
|