@flowdrop/flowdrop 2.11.0 → 2.12.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 +223 -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 +966 -226
- package/dist/components/App.svelte.d.ts +26 -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 +75 -0
- package/dist/components/playground/DockedPlayground.svelte.d.ts +24 -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 +3 -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 +38 -5
- package/dist/svelte-app.js +14 -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 +66 -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,94 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
Toolbar primitive — a bare row (or column) that groups canvas controls for
|
|
3
|
+
keyboard navigation. It draws nothing itself: each control inside floats on its
|
|
4
|
+
own (Segmented `float`, a FloatingControl, the run pill).
|
|
5
|
+
|
|
6
|
+
role="toolbar" with arrow-key navigation: arrow keys (Left/Right for
|
|
7
|
+
horizontal, Up/Down for vertical), Home and End move between the focusable
|
|
8
|
+
children. It is not a roving tabindex: every control keeps its own place in
|
|
9
|
+
the Tab order (the children own their tabindex, and Segmented already roves
|
|
10
|
+
its radios), so the arrows are a shortcut on top of Tab, not a replacement. Compose with Segmented, IconButton, Chip, and
|
|
11
|
+
ToolbarSeparator. Native focusable elements only (buttons, links, inputs,
|
|
12
|
+
elements with a non-negative tabindex).
|
|
13
|
+
|
|
14
|
+
Note: a Segmented inside the toolbar keeps its own arrow-key handling; the
|
|
15
|
+
toolbar skips events that a child already handled (defaultPrevented).
|
|
16
|
+
|
|
17
|
+
@internal Not exported from any package entry; not public API yet.
|
|
18
|
+
-->
|
|
19
|
+
|
|
20
|
+
<script lang="ts">
|
|
21
|
+
import type { Snippet } from 'svelte';
|
|
22
|
+
|
|
23
|
+
interface Props {
|
|
24
|
+
/** Accessible name of the toolbar */
|
|
25
|
+
ariaLabel: string;
|
|
26
|
+
/** Layout and arrow-key axis */
|
|
27
|
+
orientation?: 'horizontal' | 'vertical';
|
|
28
|
+
/** Extra classes appended to the root */
|
|
29
|
+
class?: string;
|
|
30
|
+
/** Toolbar content */
|
|
31
|
+
children: Snippet;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
let { ariaLabel, orientation = 'horizontal', class: className = '', children }: Props = $props();
|
|
35
|
+
|
|
36
|
+
let root: HTMLDivElement | undefined = $state();
|
|
37
|
+
|
|
38
|
+
const FOCUSABLE =
|
|
39
|
+
'button:not(:disabled), a[href], input:not(:disabled), select:not(:disabled), textarea:not(:disabled), [tabindex]:not([tabindex^="-"])';
|
|
40
|
+
|
|
41
|
+
function items(): HTMLElement[] {
|
|
42
|
+
if (!root) return [];
|
|
43
|
+
// Radios of a Segmented count too: their roving tabindex (-1) hides the
|
|
44
|
+
// unselected ones from the plain focusable selector.
|
|
45
|
+
return Array.from(
|
|
46
|
+
root.querySelectorAll<HTMLElement>(`${FOCUSABLE}, [role="radio"]:not(:disabled)`)
|
|
47
|
+
);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
function onkeydown(event: KeyboardEvent): void {
|
|
51
|
+
if (event.defaultPrevented) return;
|
|
52
|
+
const next = orientation === 'horizontal' ? 'ArrowRight' : 'ArrowDown';
|
|
53
|
+
const prev = orientation === 'horizontal' ? 'ArrowLeft' : 'ArrowUp';
|
|
54
|
+
if (![next, prev, 'Home', 'End'].includes(event.key)) return;
|
|
55
|
+
const list = items();
|
|
56
|
+
if (list.length === 0) return;
|
|
57
|
+
const current = list.indexOf(document.activeElement as HTMLElement);
|
|
58
|
+
if (current === -1) return;
|
|
59
|
+
let target = current;
|
|
60
|
+
if (event.key === next) target = (current + 1) % list.length;
|
|
61
|
+
else if (event.key === prev) target = (current - 1 + list.length) % list.length;
|
|
62
|
+
else if (event.key === 'Home') target = 0;
|
|
63
|
+
else target = list.length - 1;
|
|
64
|
+
event.preventDefault();
|
|
65
|
+
list[target]?.focus();
|
|
66
|
+
}
|
|
67
|
+
</script>
|
|
68
|
+
|
|
69
|
+
<!-- svelte-ignore a11y_interactive_supports_focus -->
|
|
70
|
+
<div
|
|
71
|
+
bind:this={root}
|
|
72
|
+
class="flowdrop-ui-toolbar flowdrop-ui-toolbar--{orientation} {className}"
|
|
73
|
+
role="toolbar"
|
|
74
|
+
aria-label={ariaLabel}
|
|
75
|
+
aria-orientation={orientation}
|
|
76
|
+
{onkeydown}
|
|
77
|
+
>
|
|
78
|
+
{@render children()}
|
|
79
|
+
</div>
|
|
80
|
+
|
|
81
|
+
<style>
|
|
82
|
+
.flowdrop-ui-toolbar {
|
|
83
|
+
display: inline-flex;
|
|
84
|
+
align-items: center;
|
|
85
|
+
box-sizing: border-box;
|
|
86
|
+
gap: 6px;
|
|
87
|
+
color: var(--fd-foreground);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.flowdrop-ui-toolbar--vertical {
|
|
91
|
+
flex-direction: column;
|
|
92
|
+
align-items: stretch;
|
|
93
|
+
}
|
|
94
|
+
</style>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { Snippet } from 'svelte';
|
|
2
|
+
interface Props {
|
|
3
|
+
/** Accessible name of the toolbar */
|
|
4
|
+
ariaLabel: string;
|
|
5
|
+
/** Layout and arrow-key axis */
|
|
6
|
+
orientation?: 'horizontal' | 'vertical';
|
|
7
|
+
/** Extra classes appended to the root */
|
|
8
|
+
class?: string;
|
|
9
|
+
/** Toolbar content */
|
|
10
|
+
children: Snippet;
|
|
11
|
+
}
|
|
12
|
+
declare const Toolbar: import("svelte").Component<Props, {}, "">;
|
|
13
|
+
type Toolbar = ReturnType<typeof Toolbar>;
|
|
14
|
+
export default Toolbar;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
ToolbarSeparator — a thin divider between Toolbar groups. Orientation is
|
|
3
|
+
inherited from the surrounding Toolbar via CSS (`aria-orientation` is the
|
|
4
|
+
perpendicular axis of the toolbar, so it is set explicitly here).
|
|
5
|
+
|
|
6
|
+
@internal Not exported from any package entry; not public API yet.
|
|
7
|
+
-->
|
|
8
|
+
|
|
9
|
+
<script lang="ts">
|
|
10
|
+
interface Props {
|
|
11
|
+
/** Axis of the toolbar this sits in; the line is drawn across it */
|
|
12
|
+
orientation?: 'horizontal' | 'vertical';
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
let { orientation = 'horizontal' }: Props = $props();
|
|
16
|
+
</script>
|
|
17
|
+
|
|
18
|
+
<span
|
|
19
|
+
class="flowdrop-ui-toolbar-separator flowdrop-ui-toolbar-separator--{orientation}"
|
|
20
|
+
role="separator"
|
|
21
|
+
aria-orientation={orientation === 'horizontal' ? 'vertical' : 'horizontal'}
|
|
22
|
+
></span>
|
|
23
|
+
|
|
24
|
+
<style>
|
|
25
|
+
.flowdrop-ui-toolbar-separator {
|
|
26
|
+
flex: none;
|
|
27
|
+
background-color: var(--fd-border);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.flowdrop-ui-toolbar-separator--horizontal {
|
|
31
|
+
align-self: stretch;
|
|
32
|
+
width: 1px;
|
|
33
|
+
margin: var(--fd-space-3xs) var(--fd-space-3xs);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.flowdrop-ui-toolbar-separator--vertical {
|
|
37
|
+
height: 1px;
|
|
38
|
+
margin: var(--fd-space-3xs) var(--fd-space-3xs);
|
|
39
|
+
}
|
|
40
|
+
</style>
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
interface Props {
|
|
2
|
+
/** Axis of the toolbar this sits in; the line is drawn across it */
|
|
3
|
+
orientation?: 'horizontal' | 'vertical';
|
|
4
|
+
}
|
|
5
|
+
declare const ToolbarSeparator: import("svelte").Component<Props, {}, "">;
|
|
6
|
+
type ToolbarSeparator = ReturnType<typeof ToolbarSeparator>;
|
|
7
|
+
export default ToolbarSeparator;
|
|
@@ -11,6 +11,9 @@
|
|
|
11
11
|
|
|
12
12
|
<script lang="ts">
|
|
13
13
|
import type { Snippet } from 'svelte';
|
|
14
|
+
import Icon from '@iconify/svelte';
|
|
15
|
+
import PanelHeader from '../primitives/PanelHeader.svelte';
|
|
16
|
+
import IconButton from '../primitives/IconButton.svelte';
|
|
14
17
|
import { portal } from '../../utils/portal.js';
|
|
15
18
|
|
|
16
19
|
interface Props {
|
|
@@ -57,10 +60,13 @@
|
|
|
57
60
|
aria-labelledby={titleId}
|
|
58
61
|
tabindex="-1"
|
|
59
62
|
>
|
|
60
|
-
<
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
63
|
+
<PanelHeader {title} {titleId}>
|
|
64
|
+
{#snippet actions()}
|
|
65
|
+
<IconButton ariaLabel={closeLabel} onclick={onClose}>
|
|
66
|
+
<Icon icon="mdi:close" />
|
|
67
|
+
</IconButton>
|
|
68
|
+
{/snippet}
|
|
69
|
+
</PanelHeader>
|
|
64
70
|
<div class="surface-overlay__body">
|
|
65
71
|
{@render children()}
|
|
66
72
|
</div>
|
|
@@ -99,42 +105,6 @@
|
|
|
99
105
|
overflow: hidden;
|
|
100
106
|
}
|
|
101
107
|
|
|
102
|
-
.surface-overlay__header {
|
|
103
|
-
display: flex;
|
|
104
|
-
justify-content: space-between;
|
|
105
|
-
align-items: center;
|
|
106
|
-
padding: 0.875rem 1rem;
|
|
107
|
-
border-bottom: 1px solid var(--fd-border);
|
|
108
|
-
background-color: var(--fd-card);
|
|
109
|
-
flex-shrink: 0;
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
.surface-overlay__title {
|
|
113
|
-
margin: 0;
|
|
114
|
-
font-size: 1rem;
|
|
115
|
-
font-weight: 600;
|
|
116
|
-
color: var(--fd-foreground);
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
.surface-overlay__close {
|
|
120
|
-
background: none;
|
|
121
|
-
border: none;
|
|
122
|
-
font-size: 1.25rem;
|
|
123
|
-
line-height: 1;
|
|
124
|
-
cursor: pointer;
|
|
125
|
-
color: var(--fd-muted-foreground);
|
|
126
|
-
padding: 0.25rem;
|
|
127
|
-
border-radius: var(--fd-radius-sm);
|
|
128
|
-
transition:
|
|
129
|
-
color var(--fd-transition-fast),
|
|
130
|
-
background-color var(--fd-transition-fast);
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
.surface-overlay__close:hover {
|
|
134
|
-
color: var(--fd-foreground);
|
|
135
|
-
background-color: var(--fd-subtle);
|
|
136
|
-
}
|
|
137
|
-
|
|
138
108
|
.surface-overlay__body {
|
|
139
109
|
flex: 1;
|
|
140
110
|
min-height: 0;
|
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
|
|
13
13
|
<script lang="ts">
|
|
14
14
|
import type { Snippet } from 'svelte';
|
|
15
|
+
import PanelHeader from '../primitives/PanelHeader.svelte';
|
|
16
|
+
import Tabs, { tabId, tabPanelId } from '../primitives/Tabs.svelte';
|
|
15
17
|
|
|
16
18
|
/** A single hostable surface. */
|
|
17
19
|
export interface SurfaceTab {
|
|
@@ -36,9 +38,20 @@
|
|
|
36
38
|
activeId: string;
|
|
37
39
|
/** Called when a tab is selected. */
|
|
38
40
|
onSelect: (id: string) => void;
|
|
41
|
+
/**
|
|
42
|
+
* Right-aligned controls in the 40px panel header (e.g. the sidebar collapse
|
|
43
|
+
* button). Giving it also shows the header for a lone surface, with that
|
|
44
|
+
* surface's label as the title.
|
|
45
|
+
*/
|
|
46
|
+
headerActions?: Snippet;
|
|
47
|
+
/** Accessible name of the tab list. */
|
|
48
|
+
ariaLabel?: string;
|
|
39
49
|
}
|
|
40
50
|
|
|
41
|
-
const { tabs, activeId, onSelect }: Props = $props();
|
|
51
|
+
const { tabs, activeId, onSelect, headerActions, ariaLabel = 'Panels' }: Props = $props();
|
|
52
|
+
|
|
53
|
+
const generatedId = $props.id();
|
|
54
|
+
const idBase = `flowdrop-surface-${generatedId}`;
|
|
42
55
|
|
|
43
56
|
// Fall back to the first tab when `activeId` doesn't match any present tab
|
|
44
57
|
// (e.g. the active surface was just routed to a different host).
|
|
@@ -48,27 +61,34 @@
|
|
|
48
61
|
</script>
|
|
49
62
|
|
|
50
63
|
<div class="tabbed-surface">
|
|
51
|
-
{#if tabs.length > 1}
|
|
52
|
-
<
|
|
53
|
-
{#
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
64
|
+
{#if tabs.length > 1 || headerActions}
|
|
65
|
+
<PanelHeader class="tabbed-surface__header">
|
|
66
|
+
{#snippet leading()}
|
|
67
|
+
{#if tabs.length > 1}
|
|
68
|
+
<Tabs
|
|
69
|
+
{idBase}
|
|
70
|
+
{ariaLabel}
|
|
71
|
+
tabs={tabs.map((t) => ({ value: t.id, label: t.label }))}
|
|
72
|
+
value={resolvedActiveId}
|
|
73
|
+
onchange={onSelect}
|
|
74
|
+
/>
|
|
75
|
+
{:else}
|
|
76
|
+
<h2 class="tabbed-surface__title">{tabs[0]?.label}</h2>
|
|
77
|
+
{/if}
|
|
78
|
+
{/snippet}
|
|
79
|
+
{#snippet actions()}
|
|
80
|
+
{@render headerActions?.()}
|
|
81
|
+
{/snippet}
|
|
82
|
+
</PanelHeader>
|
|
66
83
|
{/if}
|
|
67
84
|
|
|
68
85
|
<div class="tabbed-surface__content">
|
|
69
86
|
{#each tabs as tab (tab.id)}
|
|
70
87
|
<div
|
|
71
88
|
class="tabbed-surface__panel"
|
|
89
|
+
role={tabs.length > 1 ? 'tabpanel' : undefined}
|
|
90
|
+
id={tabs.length > 1 ? tabPanelId(idBase, tab.id) : undefined}
|
|
91
|
+
aria-labelledby={tabs.length > 1 ? tabId(idBase, tab.id) : undefined}
|
|
72
92
|
style:display={tab.id === resolvedActiveId ? (tab.display ?? 'flex') : 'none'}
|
|
73
93
|
>
|
|
74
94
|
{@render tab.content()}
|
|
@@ -85,35 +105,25 @@
|
|
|
85
105
|
overflow: hidden;
|
|
86
106
|
}
|
|
87
107
|
|
|
88
|
-
.tabbed-
|
|
89
|
-
|
|
90
|
-
gap: 0;
|
|
91
|
-
background: var(--fd-muted);
|
|
92
|
-
border-bottom: 1px solid var(--fd-border);
|
|
93
|
-
flex-shrink: 0;
|
|
108
|
+
.tabbed-surface :global(.tabbed-surface__header) {
|
|
109
|
+
padding-inline: var(--fd-space-xl) var(--fd-space-xs);
|
|
94
110
|
}
|
|
95
111
|
|
|
96
|
-
.
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
cursor: pointer;
|
|
101
|
-
border: none;
|
|
102
|
-
border-bottom: 2px solid transparent;
|
|
103
|
-
background: transparent;
|
|
104
|
-
color: var(--fd-muted-foreground);
|
|
105
|
-
transition: all var(--fd-transition-fast);
|
|
112
|
+
/* View tabs fill the header, so the underline sits on its rule. */
|
|
113
|
+
.tabbed-surface :global(.flowdrop-ui-panel-header__lead) {
|
|
114
|
+
align-self: stretch;
|
|
115
|
+
align-items: stretch;
|
|
106
116
|
}
|
|
107
117
|
|
|
108
|
-
.tabbed-
|
|
109
|
-
|
|
110
|
-
background: var(--fd-background);
|
|
118
|
+
.tabbed-surface :global(.flowdrop-ui-tabs__tab) {
|
|
119
|
+
height: 100%;
|
|
111
120
|
}
|
|
112
121
|
|
|
113
|
-
.tabbed-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
122
|
+
.tabbed-surface__title {
|
|
123
|
+
margin: 0;
|
|
124
|
+
padding-inline: var(--fd-space-xs);
|
|
125
|
+
font-size: var(--fd-text-sm);
|
|
126
|
+
font-weight: 600;
|
|
117
127
|
}
|
|
118
128
|
|
|
119
129
|
.tabbed-surface__content {
|
|
@@ -21,6 +21,14 @@ interface Props {
|
|
|
21
21
|
activeId: string;
|
|
22
22
|
/** Called when a tab is selected. */
|
|
23
23
|
onSelect: (id: string) => void;
|
|
24
|
+
/**
|
|
25
|
+
* Right-aligned controls in the 40px panel header (e.g. the sidebar collapse
|
|
26
|
+
* button). Giving it also shows the header for a lone surface, with that
|
|
27
|
+
* surface's label as the title.
|
|
28
|
+
*/
|
|
29
|
+
headerActions?: Snippet;
|
|
30
|
+
/** Accessible name of the tab list. */
|
|
31
|
+
ariaLabel?: string;
|
|
24
32
|
}
|
|
25
33
|
declare const TabbedSurface: import("svelte").Component<Props, {}, "">;
|
|
26
34
|
type TabbedSurface = ReturnType<typeof TabbedSurface>;
|
|
@@ -1,53 +1,115 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
/**
|
|
3
|
-
* Toast body
|
|
3
|
+
* Toast body: status glyph, title, optional body, reasons and an action.
|
|
4
4
|
*
|
|
5
5
|
* svelte-5-french-toast renders a component message as
|
|
6
6
|
* `<toast.message {toast} {...toast.props} />`, so this receives the live
|
|
7
|
-
* toast (for its id) plus the props the service passes.
|
|
8
|
-
*
|
|
9
|
-
* the
|
|
7
|
+
* toast (for its id) plus the props the service passes. The service uses a
|
|
8
|
+
* "blank" toast, so the library draws no icon of its own: the glyph sits on
|
|
9
|
+
* the first line, next to the title, instead of centred on the whole block.
|
|
10
10
|
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
11
|
+
* The message is built from parts (title = what happened, body = why,
|
|
12
|
+
* details = the server's reasons, action = what to do next) rather than one
|
|
13
|
+
* joined string. Errors and warnings stay until closed; a success is one
|
|
14
|
+
* line and goes by itself, so it has no close button (`dismissible`).
|
|
15
|
+
*
|
|
16
|
+
* The reason list is keyed by index on purpose: two reasons may share their
|
|
14
17
|
* wording, and keying on the text throws `each_key_duplicate` — in
|
|
15
18
|
* production too. The list never changes for the life of a toast.
|
|
16
19
|
*/
|
|
17
20
|
import { toast as toastApi, type Toast } from 'svelte-5-french-toast';
|
|
21
|
+
import Button from '../primitives/Button.svelte';
|
|
22
|
+
import { m } from '../../messages/context.js';
|
|
23
|
+
import type { ToastAction, ToastKind } from '../../services/toastQueue.js';
|
|
18
24
|
|
|
19
25
|
interface Props {
|
|
20
26
|
toast: Toast;
|
|
27
|
+
/** The headline: what happened. */
|
|
21
28
|
text: string;
|
|
29
|
+
/** Why it happened, one short paragraph. */
|
|
30
|
+
body?: string;
|
|
22
31
|
details?: readonly string[];
|
|
32
|
+
action?: ToastAction;
|
|
33
|
+
kind?: ToastKind;
|
|
34
|
+
dismissible?: boolean;
|
|
23
35
|
}
|
|
24
36
|
|
|
25
|
-
let {
|
|
37
|
+
let {
|
|
38
|
+
toast,
|
|
39
|
+
text,
|
|
40
|
+
body,
|
|
41
|
+
details = [],
|
|
42
|
+
action,
|
|
43
|
+
kind = 'info',
|
|
44
|
+
dismissible = true
|
|
45
|
+
}: Props = $props();
|
|
46
|
+
|
|
47
|
+
function runAction(): void {
|
|
48
|
+
action?.onClick();
|
|
49
|
+
toastApi.dismiss(toast.id);
|
|
50
|
+
}
|
|
26
51
|
</script>
|
|
27
52
|
|
|
28
|
-
<div class="flowdrop-toast-
|
|
29
|
-
<
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
</ul>
|
|
36
|
-
{/if}
|
|
37
|
-
</div>
|
|
38
|
-
<button
|
|
39
|
-
type="button"
|
|
40
|
-
class="flowdrop-toast-close"
|
|
41
|
-
aria-label="Dismiss"
|
|
42
|
-
onclick={() => toastApi.dismiss(toast.id)}
|
|
43
|
-
>
|
|
44
|
-
<svg viewBox="0 0 16 16" width="14" height="14" aria-hidden="true" focusable="false">
|
|
45
|
-
<path
|
|
46
|
-
d="M4 4l8 8M12 4l-8 8"
|
|
53
|
+
<div class="flowdrop-toast-row" data-kind={kind}>
|
|
54
|
+
<span class="flowdrop-toast-glyph" aria-hidden="true">
|
|
55
|
+
<svg
|
|
56
|
+
viewBox="0 0 16 16"
|
|
57
|
+
width="16"
|
|
58
|
+
height="16"
|
|
59
|
+
fill="none"
|
|
47
60
|
stroke="currentColor"
|
|
48
|
-
stroke-width="1.
|
|
61
|
+
stroke-width="1.9"
|
|
49
62
|
stroke-linecap="round"
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
63
|
+
stroke-linejoin="round"
|
|
64
|
+
focusable="false"
|
|
65
|
+
>
|
|
66
|
+
{#if kind === 'success'}
|
|
67
|
+
<path d="M4.5 8.4l2.4 2.4 4.6-5.2" />
|
|
68
|
+
{:else if kind === 'error'}
|
|
69
|
+
<path d="M5.4 5.4l5.2 5.2M10.6 5.4l-5.2 5.2" />
|
|
70
|
+
{:else if kind === 'warning'}
|
|
71
|
+
<path d="M8 4.4v4.2" />
|
|
72
|
+
<path d="M8 11.3v.01" />
|
|
73
|
+
{:else}
|
|
74
|
+
<path d="M8 7.4v4" />
|
|
75
|
+
<path d="M8 4.7v.01" />
|
|
76
|
+
{/if}
|
|
77
|
+
</svg>
|
|
78
|
+
</span>
|
|
79
|
+
<div class="flowdrop-toast-text">
|
|
80
|
+
<p class="flowdrop-toast-headline">{text}</p>
|
|
81
|
+
{#if body}
|
|
82
|
+
<p class="flowdrop-toast-body">{body}</p>
|
|
83
|
+
{/if}
|
|
84
|
+
{#if details.length}
|
|
85
|
+
<ul class="flowdrop-toast-details">
|
|
86
|
+
{#each details as detail, i (i)}
|
|
87
|
+
<li>{detail}</li>
|
|
88
|
+
{/each}
|
|
89
|
+
</ul>
|
|
90
|
+
{/if}
|
|
91
|
+
{#if action}
|
|
92
|
+
<div class="flowdrop-toast-actions">
|
|
93
|
+
<Button variant="ghost" size="sm" onclick={runAction}>{action.label}</Button>
|
|
94
|
+
</div>
|
|
95
|
+
{/if}
|
|
96
|
+
</div>
|
|
97
|
+
{#if dismissible}
|
|
98
|
+
<button
|
|
99
|
+
type="button"
|
|
100
|
+
class="flowdrop-toast-close"
|
|
101
|
+
aria-label={m().notice.dismiss}
|
|
102
|
+
onclick={() => toastApi.dismiss(toast.id)}
|
|
103
|
+
>
|
|
104
|
+
<svg viewBox="0 0 16 16" width="14" height="14" aria-hidden="true" focusable="false">
|
|
105
|
+
<path
|
|
106
|
+
d="M4 4l8 8M12 4l-8 8"
|
|
107
|
+
stroke="currentColor"
|
|
108
|
+
stroke-width="1.75"
|
|
109
|
+
stroke-linecap="round"
|
|
110
|
+
fill="none"
|
|
111
|
+
/>
|
|
112
|
+
</svg>
|
|
113
|
+
</button>
|
|
114
|
+
{/if}
|
|
115
|
+
</div>
|
|
@@ -1,23 +1,33 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Toast body
|
|
2
|
+
* Toast body: status glyph, title, optional body, reasons and an action.
|
|
3
3
|
*
|
|
4
4
|
* svelte-5-french-toast renders a component message as
|
|
5
5
|
* `<toast.message {toast} {...toast.props} />`, so this receives the live
|
|
6
|
-
* toast (for its id) plus the props the service passes.
|
|
7
|
-
*
|
|
8
|
-
* the
|
|
6
|
+
* toast (for its id) plus the props the service passes. The service uses a
|
|
7
|
+
* "blank" toast, so the library draws no icon of its own: the glyph sits on
|
|
8
|
+
* the first line, next to the title, instead of centred on the whole block.
|
|
9
9
|
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
10
|
+
* The message is built from parts (title = what happened, body = why,
|
|
11
|
+
* details = the server's reasons, action = what to do next) rather than one
|
|
12
|
+
* joined string. Errors and warnings stay until closed; a success is one
|
|
13
|
+
* line and goes by itself, so it has no close button (`dismissible`).
|
|
14
|
+
*
|
|
15
|
+
* The reason list is keyed by index on purpose: two reasons may share their
|
|
13
16
|
* wording, and keying on the text throws `each_key_duplicate` — in
|
|
14
17
|
* production too. The list never changes for the life of a toast.
|
|
15
18
|
*/
|
|
16
19
|
import { type Toast } from 'svelte-5-french-toast';
|
|
20
|
+
import type { ToastAction, ToastKind } from '../../services/toastQueue.js';
|
|
17
21
|
interface Props {
|
|
18
22
|
toast: Toast;
|
|
23
|
+
/** The headline: what happened. */
|
|
19
24
|
text: string;
|
|
25
|
+
/** Why it happened, one short paragraph. */
|
|
26
|
+
body?: string;
|
|
20
27
|
details?: readonly string[];
|
|
28
|
+
action?: ToastAction;
|
|
29
|
+
kind?: ToastKind;
|
|
30
|
+
dismissible?: boolean;
|
|
21
31
|
}
|
|
22
32
|
declare const DismissibleToast: import("svelte").Component<Props, {}, "">;
|
|
23
33
|
type DismissibleToast = ReturnType<typeof DismissibleToast>;
|
|
@@ -37,6 +37,20 @@ export interface EndpointConfig {
|
|
|
37
37
|
* `/run` command is not offered.
|
|
38
38
|
*/
|
|
39
39
|
run?: string;
|
|
40
|
+
/**
|
|
41
|
+
* Diagnose the editor's draft (`POST`, body = the workflow as the editor
|
|
42
|
+
* would save it, `{id}` = the saved workflow's id). Answers
|
|
43
|
+
* `{ success, data: { problems } }`. The Problems indicator in the
|
|
44
|
+
* navbar, the node badges and the remedies exist only while this and
|
|
45
|
+
* `remedy` are set; a backend without a Doctor omits them.
|
|
46
|
+
*/
|
|
47
|
+
diagnose?: string;
|
|
48
|
+
/**
|
|
49
|
+
* Build the fix for one problem (`POST`, body `{ draft, code, target,
|
|
50
|
+
* remedy, params? }`). Answers `{ success, data: { operations } }`, which
|
|
51
|
+
* the editor applies as one undoable edit. Needs `diagnose`.
|
|
52
|
+
*/
|
|
53
|
+
remedy?: string;
|
|
40
54
|
};
|
|
41
55
|
executions: {
|
|
42
56
|
execute: string;
|
|
@@ -55,6 +69,18 @@ export interface EndpointConfig {
|
|
|
55
69
|
logs: string;
|
|
56
70
|
execute: string;
|
|
57
71
|
stop: string;
|
|
72
|
+
/**
|
|
73
|
+
* Re-run a finished pipeline (`POST`, answers
|
|
74
|
+
* `{ success, data: { pipeline_id, status } }`). The Runs list in Test
|
|
75
|
+
* mode offers Re-run only when this is set.
|
|
76
|
+
*/
|
|
77
|
+
rerun?: string;
|
|
78
|
+
/**
|
|
79
|
+
* Cancel a pipeline that has not finished (`POST`, no body). The Runs
|
|
80
|
+
* list offers Cancel only when this or `signals` is set; this key wins
|
|
81
|
+
* when both are.
|
|
82
|
+
*/
|
|
83
|
+
cancel?: string;
|
|
58
84
|
};
|
|
59
85
|
/**
|
|
60
86
|
* Playground endpoints. `listSessions` and `createSession` are always read
|
|
@@ -122,6 +148,14 @@ export interface EndpointConfig {
|
|
|
122
148
|
stop: string;
|
|
123
149
|
/** Reset a stuck session to idle (`POST`). Optional, as `playground.resetSession`. */
|
|
124
150
|
reset?: string;
|
|
151
|
+
/**
|
|
152
|
+
* The runs a session started, each stamped with the workflow version it
|
|
153
|
+
* ran (`GET`, `limit` query parameter). Optional: a server without it
|
|
154
|
+
* answers 404 and the editor shows no version dividers. When the group
|
|
155
|
+
* is configured and this key is left out, the editor still tries
|
|
156
|
+
* {@link sessionsEndpoints}'s path and stops after the first 404.
|
|
157
|
+
*/
|
|
158
|
+
runs?: string;
|
|
125
159
|
};
|
|
126
160
|
/**
|
|
127
161
|
* Operator signals into a *running* pipeline — pause, resume, cancel.
|
|
@@ -248,7 +282,7 @@ export declare const defaultEndpointConfig: EndpointConfig;
|
|
|
248
282
|
*/
|
|
249
283
|
export declare const sessionsEndpoints: NonNullable<EndpointConfig['endpoints']['sessions']>;
|
|
250
284
|
/** One per-session call, named as the `sessions` group names it. */
|
|
251
|
-
export type SessionEndpointKey = keyof NonNullable<EndpointConfig['endpoints']['sessions']>;
|
|
285
|
+
export type SessionEndpointKey = Exclude<keyof NonNullable<EndpointConfig['endpoints']['sessions']>, 'runs'>;
|
|
252
286
|
/** A resolved per-session endpoint: its path and the group it came from. */
|
|
253
287
|
export interface ResolvedSessionEndpoint {
|
|
254
288
|
path: string;
|
|
@@ -263,6 +297,14 @@ export interface ResolvedSessionEndpoint {
|
|
|
263
297
|
* returns `undefined` rather than borrowing the other group's path.
|
|
264
298
|
*/
|
|
265
299
|
export declare function resolveSessionEndpoint(config: EndpointConfig, key: SessionEndpointKey): ResolvedSessionEndpoint | undefined;
|
|
300
|
+
/**
|
|
301
|
+
* The path of a session's runs, or `undefined` when the backend has no
|
|
302
|
+
* `sessions` group (servers that predate the session surface have no runs
|
|
303
|
+
* endpoint either). Unlike the other per-session calls there is no legacy
|
|
304
|
+
* `playground` key, and a `sessions` group without a `runs` key falls back to
|
|
305
|
+
* the reference path: the call is optional and a 404 switches it off.
|
|
306
|
+
*/
|
|
307
|
+
export declare function resolveSessionRunsEndpoint(config: EndpointConfig): string | undefined;
|
|
266
308
|
/**
|
|
267
309
|
* Create endpoint configuration with custom base URL
|
|
268
310
|
*/
|