@flowdrop/flowdrop 2.13.0 → 2.15.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 +82 -0
- package/dist/commands/executor.js +58 -8
- package/dist/commands/parser.js +3 -3
- package/dist/commands/types.d.ts +8 -2
- package/dist/commands/uiActionTarget.d.ts +24 -0
- package/dist/commands/uiActionTarget.js +31 -0
- package/dist/commands/validate.d.ts +15 -0
- package/dist/commands/validate.js +115 -0
- package/dist/components/App.svelte +44 -2
- package/dist/components/App.svelte.d.ts +3 -1
- package/dist/components/Button.svelte +7 -7
- package/dist/components/Button.svelte.d.ts +10 -0
- package/dist/components/CanvasBanner.svelte +19 -6
- package/dist/components/CanvasBanner.svelte.d.ts +15 -3
- package/dist/components/CanvasContextMenu.svelte +9 -9
- package/dist/components/CanvasContextMenu.svelte.d.ts +10 -0
- package/dist/components/CanvasToolbar.svelte +8 -7
- package/dist/components/CanvasToolbar.svelte.d.ts +10 -0
- package/dist/components/CanvasZoomControls.svelte +10 -9
- package/dist/components/CanvasZoomControls.svelte.d.ts +13 -0
- package/dist/components/ConfigForm.svelte +51 -18
- package/dist/components/ConfigForm.svelte.d.ts +20 -1
- package/dist/components/ConfigPanel.svelte +9 -5
- package/dist/components/ConfigPanel.svelte.d.ts +10 -0
- package/dist/components/EditorStatusBar.svelte +6 -5
- package/dist/components/EditorStatusBar.svelte.d.ts +7 -0
- package/dist/components/ExternalLinkRow.svelte +16 -1
- package/dist/components/ExternalLinkRow.svelte.d.ts +5 -0
- package/dist/components/FlowDropEdge.svelte +15 -12
- package/dist/components/FlowDropEdge.svelte.d.ts +16 -0
- package/dist/components/InterfaceTag.svelte +13 -15
- package/dist/components/InterfaceTag.svelte.d.ts +19 -0
- package/dist/components/LoadingSpinner.svelte +8 -2
- package/dist/components/LoadingSpinner.svelte.d.ts +9 -0
- package/dist/components/Logo.svelte +11 -0
- package/dist/components/Logo.svelte.d.ts +9 -0
- package/dist/components/LogoWordmark.svelte +8 -3
- package/dist/components/LogoWordmark.svelte.d.ts +9 -0
- package/dist/components/LoopbackLanes.svelte +12 -6
- package/dist/components/LoopbackLanes.svelte.d.ts +13 -0
- package/dist/components/MarkdownDisplay.svelte +10 -3
- package/dist/components/MarkdownDisplay.svelte.d.ts +11 -0
- package/dist/components/Navbar.svelte +13 -5
- package/dist/components/Navbar.svelte.d.ts +14 -0
- package/dist/components/NodeInspector.svelte +7 -8
- package/dist/components/NodeInspector.svelte.d.ts +10 -0
- package/dist/components/NodeSidebar.svelte +9 -3
- package/dist/components/NodeSidebar.svelte.d.ts +10 -0
- package/dist/components/NodeStatusOverlay.svelte +30 -19
- package/dist/components/NodeStatusOverlay.svelte.d.ts +19 -0
- package/dist/components/NodeSwapPicker.svelte +1 -1
- package/dist/components/RunBar.svelte +10 -13
- package/dist/components/RunBar.svelte.d.ts +15 -0
- package/dist/components/RunsMenu.svelte +14 -13
- package/dist/components/RunsMenu.svelte.d.ts +15 -0
- package/dist/components/SchemaForm.svelte +10 -13
- package/dist/components/SchemaForm.svelte.d.ts +51 -0
- package/dist/components/SettingsPanel.svelte +5 -5
- package/dist/components/StatusIcon.svelte +14 -3
- package/dist/components/StatusIcon.svelte.d.ts +15 -0
- package/dist/components/StatusLabel.svelte +10 -2
- package/dist/components/StatusLabel.svelte.d.ts +11 -0
- package/dist/components/ThemeToggle.svelte +8 -5
- package/dist/components/ThemeToggle.svelte.d.ts +10 -0
- package/dist/components/UniversalNode.svelte +13 -5
- package/dist/components/UniversalNode.svelte.d.ts +15 -0
- package/dist/components/WorkflowInterfaceEntryCard.svelte +1 -1
- package/dist/components/WorkflowInterfaceEntryComposer.svelte +1 -2
- package/dist/components/ZoomTier.svelte +13 -10
- package/dist/components/ZoomTier.svelte.d.ts +14 -0
- package/dist/components/console/CommandConsole.svelte +9 -3
- package/dist/components/console/CommandConsole.svelte.d.ts +10 -0
- package/dist/components/console/ConsoleAutocomplete.svelte +4 -4
- package/dist/components/console/ConsoleAutocomplete.svelte.d.ts +5 -0
- package/dist/components/console/ConsoleInput.svelte +6 -4
- package/dist/components/console/ConsoleInput.svelte.d.ts +7 -0
- package/dist/components/console/ConsoleOutput.svelte +5 -3
- package/dist/components/console/ConsoleOutput.svelte.d.ts +6 -0
- package/dist/components/console/ConsoleStrip.svelte +9 -5
- package/dist/components/console/ConsoleStrip.svelte.d.ts +10 -0
- package/dist/components/form/FieldFactory.svelte +6 -2
- package/dist/components/form/FieldFactory.svelte.d.ts +46 -0
- package/dist/components/form/FormArray.svelte +9 -16
- package/dist/components/form/FormArray.svelte.d.ts +10 -0
- package/dist/components/form/FormArrayRows.svelte +8 -8
- package/dist/components/form/FormArrayRows.svelte.d.ts +11 -0
- package/dist/components/form/FormAutocomplete.svelte +6 -3
- package/dist/components/form/FormAutocomplete.svelte.d.ts +23 -0
- package/dist/components/form/FormCheckboxGroup.svelte +5 -5
- package/dist/components/form/FormCheckboxGroup.svelte.d.ts +6 -0
- package/dist/components/form/FormCodeEditor.svelte +8 -13
- package/dist/components/form/FormCodeEditor.svelte.d.ts +9 -0
- package/dist/components/form/FormField.svelte +7 -8
- package/dist/components/form/FormField.svelte.d.ts +10 -0
- package/dist/components/form/FormFieldLight.svelte +6 -5
- package/dist/components/form/FormFieldLight.svelte.d.ts +8 -0
- package/dist/components/form/FormFieldWrapper.svelte +8 -8
- package/dist/components/form/FormFieldWrapper.svelte.d.ts +9 -0
- package/dist/components/form/FormFieldset.svelte +6 -12
- package/dist/components/form/FormFieldset.svelte.d.ts +7 -0
- package/dist/components/form/FormMarkdownEditor.svelte +8 -15
- package/dist/components/form/FormMarkdownEditor.svelte.d.ts +9 -0
- package/dist/components/form/FormNumberField.svelte +5 -7
- package/dist/components/form/FormNumberField.svelte.d.ts +6 -0
- package/dist/components/form/FormPorts.svelte +133 -27
- package/dist/components/form/FormPorts.svelte.d.ts +19 -0
- package/dist/components/form/FormRangeField.svelte +5 -9
- package/dist/components/form/FormRangeField.svelte.d.ts +6 -0
- package/dist/components/form/FormSelect.svelte +5 -7
- package/dist/components/form/FormSelect.svelte.d.ts +6 -0
- package/dist/components/form/FormTemplateEditor.svelte +8 -16
- package/dist/components/form/FormTemplateEditor.svelte.d.ts +9 -0
- package/dist/components/form/FormTextField.svelte +5 -7
- package/dist/components/form/FormTextField.svelte.d.ts +6 -0
- package/dist/components/form/FormTextarea.svelte +5 -7
- package/dist/components/form/FormTextarea.svelte.d.ts +6 -0
- package/dist/components/form/FormToggle.svelte +6 -8
- package/dist/components/form/FormToggle.svelte.d.ts +7 -0
- package/dist/components/form/FormUISchemaRenderer.svelte +5 -9
- package/dist/components/form/FormUISchemaRenderer.svelte.d.ts +7 -0
- package/dist/components/interrupt/ChoicePrompt.svelte +6 -6
- package/dist/components/interrupt/ChoicePrompt.svelte.d.ts +7 -0
- package/dist/components/interrupt/ConfirmationPrompt.svelte +6 -5
- package/dist/components/interrupt/ConfirmationPrompt.svelte.d.ts +7 -0
- package/dist/components/interrupt/FormPrompt.svelte +6 -6
- package/dist/components/interrupt/FormPrompt.svelte.d.ts +7 -0
- package/dist/components/interrupt/InterruptBubble.svelte +10 -9
- package/dist/components/interrupt/InterruptBubble.svelte.d.ts +11 -0
- package/dist/components/interrupt/ReviewPrompt.svelte +5 -6
- package/dist/components/interrupt/ReviewPrompt.svelte.d.ts +7 -0
- package/dist/components/interrupt/TextInputPrompt.svelte +6 -6
- package/dist/components/interrupt/TextInputPrompt.svelte.d.ts +7 -0
- package/dist/components/nodes/AtomNode.svelte +31 -6
- package/dist/components/nodes/AtomNode.svelte.d.ts +15 -0
- package/dist/components/nodes/CaptionNode.svelte +50 -7
- package/dist/components/nodes/CaptionNode.svelte.d.ts +13 -0
- package/dist/components/nodes/GatewayNode.svelte +18 -11
- package/dist/components/nodes/GatewayNode.svelte.d.ts +21 -0
- package/dist/components/nodes/IdeaNode.svelte +47 -6
- package/dist/components/nodes/IdeaNode.svelte.d.ts +17 -0
- package/dist/components/nodes/NodeCard.svelte +26 -18
- package/dist/components/nodes/NodeCard.svelte.d.ts +20 -0
- package/dist/components/nodes/NodeConfigButton.svelte +15 -2
- package/dist/components/nodes/NodeConfigButton.svelte.d.ts +11 -0
- package/dist/components/nodes/NodeProblemMark.svelte +15 -10
- package/dist/components/nodes/NodeProblemMark.svelte.d.ts +16 -0
- package/dist/components/nodes/NodeTip.svelte +10 -7
- package/dist/components/nodes/NodeTip.svelte.d.ts +13 -0
- package/dist/components/nodes/NotesNode.svelte +30 -0
- package/dist/components/nodes/NotesNode.svelte.d.ts +14 -0
- package/dist/components/nodes/SimpleNode.svelte +35 -8
- package/dist/components/nodes/SimpleNode.svelte.d.ts +17 -0
- package/dist/components/nodes/SquareNode.svelte +38 -8
- package/dist/components/nodes/SquareNode.svelte.d.ts +17 -0
- package/dist/components/nodes/TerminalNode.svelte +24 -10
- package/dist/components/nodes/TerminalNode.svelte.d.ts +17 -0
- package/dist/components/nodes/ToolNode.svelte +14 -5
- package/dist/components/nodes/ToolNode.svelte.d.ts +15 -0
- package/dist/components/nodes/WorkflowNode.svelte +18 -15
- package/dist/components/nodes/WorkflowNode.svelte.d.ts +21 -0
- package/dist/components/playground/ChatBubble.svelte +4 -3
- package/dist/components/playground/ChatBubble.svelte.d.ts +5 -0
- package/dist/components/playground/ChatInput.svelte +11 -6
- package/dist/components/playground/ChatInput.svelte.d.ts +14 -0
- package/dist/components/playground/ChatPanel.svelte +15 -7
- package/dist/components/playground/ChatPanel.svelte.d.ts +17 -0
- package/dist/components/playground/ControlPanel.svelte +26 -9
- package/dist/components/playground/ControlPanel.svelte.d.ts +29 -0
- package/dist/components/playground/DockedPlayground.svelte +7 -10
- package/dist/components/playground/DockedPlayground.svelte.d.ts +10 -0
- package/dist/components/playground/ExecutionConsole.svelte +10 -5
- package/dist/components/playground/ExecutionConsole.svelte.d.ts +12 -0
- package/dist/components/playground/ExecutionList.svelte +13 -0
- package/dist/components/playground/ExecutionList.svelte.d.ts +11 -0
- package/dist/components/playground/ExecutionLogs.svelte +6 -9
- package/dist/components/playground/ExecutionLogs.svelte.d.ts +7 -0
- package/dist/components/playground/HeaderMenu.svelte +6 -8
- package/dist/components/playground/HeaderMenu.svelte.d.ts +9 -0
- package/dist/components/playground/HierarchyTrail.svelte +6 -6
- package/dist/components/playground/HierarchyTrail.svelte.d.ts +8 -0
- package/dist/components/playground/InputCollector.svelte +6 -5
- package/dist/components/playground/InputCollector.svelte.d.ts +7 -0
- package/dist/components/playground/InputFields.svelte +8 -12
- package/dist/components/playground/InputFields.svelte.d.ts +9 -0
- package/dist/components/playground/InterfaceInputForm.svelte +6 -13
- package/dist/components/playground/InterfaceInputForm.svelte.d.ts +9 -0
- package/dist/components/playground/InterfaceJsonInput.svelte +6 -5
- package/dist/components/playground/InterfaceJsonInput.svelte.d.ts +8 -0
- package/dist/components/playground/LogRow.svelte +4 -5
- package/dist/components/playground/LogRow.svelte.d.ts +6 -0
- package/dist/components/playground/MessageBubble.svelte +13 -7
- package/dist/components/playground/MessageBubble.svelte.d.ts +15 -0
- package/dist/components/playground/MessageCard.svelte +5 -2
- package/dist/components/playground/MessageCard.svelte.d.ts +6 -0
- package/dist/components/playground/MessageMarkdown.svelte +8 -9
- package/dist/components/playground/MessageMarkdown.svelte.d.ts +11 -0
- package/dist/components/playground/MessageNotice.svelte +7 -0
- package/dist/components/playground/MessageNotice.svelte.d.ts +5 -0
- package/dist/components/playground/MessageStream.svelte +8 -6
- package/dist/components/playground/MessageStream.svelte.d.ts +11 -0
- package/dist/components/playground/MessageTagChip.svelte +7 -7
- package/dist/components/playground/MessageTagChip.svelte.d.ts +10 -0
- package/dist/components/playground/MessageTagStrip.svelte +6 -3
- package/dist/components/playground/MessageTagStrip.svelte.d.ts +8 -0
- package/dist/components/playground/OriginBadge.svelte +7 -4
- package/dist/components/playground/OriginBadge.svelte.d.ts +8 -0
- package/dist/components/playground/PipelineKanbanView.svelte +14 -0
- package/dist/components/playground/PipelineKanbanView.svelte.d.ts +12 -0
- package/dist/components/playground/PipelinePanel.svelte +14 -0
- package/dist/components/playground/PipelinePanel.svelte.d.ts +12 -0
- package/dist/components/playground/PipelineTableView.svelte +14 -0
- package/dist/components/playground/PipelineTableView.svelte.d.ts +12 -0
- package/dist/components/playground/Playground.svelte +17 -11
- package/dist/components/playground/Playground.svelte.d.ts +20 -0
- package/dist/components/playground/PlaygroundApp.svelte +24 -10
- package/dist/components/playground/PlaygroundApp.svelte.d.ts +26 -0
- package/dist/components/playground/PlaygroundHeader.svelte +8 -12
- package/dist/components/playground/PlaygroundHeader.svelte.d.ts +11 -0
- package/dist/components/playground/PlaygroundModal.svelte +6 -8
- package/dist/components/playground/PlaygroundModal.svelte.d.ts +7 -0
- package/dist/components/playground/PlaygroundStudio.svelte +9 -0
- package/dist/components/playground/PlaygroundStudio.svelte.d.ts +7 -0
- package/dist/components/playground/PlaygroundSurface.svelte +19 -14
- package/dist/components/playground/PlaygroundSurface.svelte.d.ts +20 -0
- package/dist/components/playground/SessionManager.svelte +6 -5
- package/dist/components/playground/SessionManager.svelte.d.ts +7 -0
- package/dist/components/playground/StepsSummary.svelte +8 -9
- package/dist/components/playground/StepsSummary.svelte.d.ts +10 -0
- package/dist/components/primitives/Button.svelte +15 -7
- package/dist/components/primitives/Button.svelte.d.ts +18 -1
- package/dist/components/primitives/Card.svelte +8 -6
- package/dist/components/primitives/Card.svelte.d.ts +11 -0
- package/dist/components/primitives/Checkbox.svelte +8 -5
- package/dist/components/primitives/Checkbox.svelte.d.ts +11 -0
- package/dist/components/primitives/Chip.svelte +8 -4
- package/dist/components/primitives/Chip.svelte.d.ts +11 -0
- package/dist/components/primitives/Combobox.svelte +27 -18
- package/dist/components/primitives/Combobox.svelte.d.ts +33 -0
- package/dist/components/primitives/Composer.svelte +15 -16
- package/dist/components/primitives/Composer.svelte.d.ts +20 -0
- package/dist/components/primitives/EmptyState.svelte +9 -3
- package/dist/components/primitives/EmptyState.svelte.d.ts +11 -0
- package/dist/components/primitives/Field.svelte +12 -9
- package/dist/components/primitives/Field.svelte.d.ts +16 -0
- package/dist/components/primitives/IconButton.svelte +10 -5
- package/dist/components/primitives/IconButton.svelte.d.ts +13 -0
- package/dist/components/primitives/Menu.svelte +15 -14
- package/dist/components/primitives/Menu.svelte.d.ts +20 -0
- package/dist/components/primitives/Notice.svelte +11 -8
- package/dist/components/primitives/Notice.svelte.d.ts +14 -0
- package/dist/components/primitives/PanelHeader.svelte +10 -7
- package/dist/components/primitives/PanelHeader.svelte.d.ts +13 -0
- package/dist/components/primitives/Segmented.svelte +11 -4
- package/dist/components/primitives/Segmented.svelte.d.ts +14 -0
- package/dist/components/primitives/Select.svelte +13 -16
- package/dist/components/primitives/Select.svelte.d.ts +18 -0
- package/dist/components/primitives/StatusPill.svelte +11 -8
- package/dist/components/primitives/StatusPill.svelte.d.ts +15 -0
- package/dist/components/primitives/Switch.svelte +9 -6
- package/dist/components/primitives/Switch.svelte.d.ts +12 -0
- package/dist/components/primitives/Tabs.svelte +16 -15
- package/dist/components/primitives/Tabs.svelte.d.ts +22 -0
- package/dist/components/primitives/Toolbar.svelte +14 -13
- package/dist/components/primitives/Toolbar.svelte.d.ts +18 -0
- package/dist/components/primitives/ToolbarSeparator.svelte +5 -4
- package/dist/components/primitives/ToolbarSeparator.svelte.d.ts +7 -0
- package/dist/core/index.d.ts +2 -2
- package/dist/core/index.js +1 -1
- package/dist/editor/index.d.ts +3 -3
- package/dist/index.d.ts +3 -2
- package/dist/layout/index.d.ts +1 -1
- package/dist/layout/index.js +1 -1
- package/dist/layout/toWorkflow.d.ts +8 -7
- package/dist/layout/toWorkflow.js +20 -40
- package/dist/messages/defaults.d.ts +24 -0
- package/dist/messages/defaults.js +15 -0
- package/dist/skins/graphite.d.ts +1 -1
- package/dist/skins/graphite.js +1 -1
- package/dist/stores/settingsStore.svelte.js +3 -0
- package/dist/stores/workflowStore.svelte.d.ts +10 -0
- package/dist/stores/workflowStore.svelte.js +65 -20
- package/dist/styles/base.css +2 -126
- package/dist/styles/tokenAliases.js +1 -0
- package/dist/styles/tokens.css +9 -5
- package/dist/svelte-app.d.ts +63 -2
- package/dist/svelte-app.js +144 -1
- package/dist/themes/classic.d.ts +9 -0
- package/dist/themes/classic.js +16 -0
- package/dist/themes/index.d.ts +7 -2
- package/dist/themes/index.js +20 -10
- package/dist/types/events.d.ts +18 -1
- package/dist/types/index.d.ts +10 -0
- package/dist/types/settings.d.ts +6 -2
- package/dist/types/theme.d.ts +6 -2
- package/dist/utils/externalEdit.svelte.d.ts +48 -0
- package/dist/utils/externalEdit.svelte.js +62 -0
- package/dist/utils/inspectorContext.d.ts +5 -0
- package/dist/utils/playgroundChat.d.ts +10 -0
- package/dist/utils/playgroundChat.js +25 -0
- package/dist/utils/portExposure.d.ts +24 -1
- package/dist/utils/portExposure.js +46 -13
- package/dist/utils/portUtils.d.ts +5 -1
- package/dist/utils/portUtils.js +15 -4
- package/package.json +2 -1
- package/dist/components/IconButton.svelte +0 -80
- package/dist/components/IconButton.svelte.d.ts +0 -30
- package/dist/themes/default.d.ts +0 -2
- package/dist/themes/default.js +0 -9
|
@@ -1,15 +1,18 @@
|
|
|
1
1
|
<!--
|
|
2
|
-
|
|
2
|
+
@component
|
|
3
|
+
StatusPill: a compact run-status chip with an icon, a label and an optional count.
|
|
3
4
|
|
|
4
|
-
Colours come from the
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
the status through the node it belongs to.
|
|
5
|
+
Colours come from the `--fd-status-*` tokens. It is not a live region on purpose: a canvas
|
|
6
|
+
can carry dozens of pills, and each change would be announced. Screen readers reach the
|
|
7
|
+
status through the node it belongs to.
|
|
8
8
|
|
|
9
|
-
With `screenSize`, the pill
|
|
10
|
-
|
|
9
|
+
With `screenSize`, the pill scales against the canvas zoom so it stays readable when the
|
|
10
|
+
canvas is zoomed out. It is meant to sit centred on a node's top edge.
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
**Use it for** the run status of a node or a run on the canvas.
|
|
13
|
+
**Not for** a free-form tag; use `Chip`.
|
|
14
|
+
|
|
15
|
+
Not exported from the package; the API may still change.
|
|
13
16
|
-->
|
|
14
17
|
|
|
15
18
|
<script module lang="ts">
|
|
@@ -19,6 +19,21 @@ interface Props {
|
|
|
19
19
|
/** Extra classes on the root. */
|
|
20
20
|
class?: string;
|
|
21
21
|
}
|
|
22
|
+
/**
|
|
23
|
+
* StatusPill: a compact run-status chip with an icon, a label and an optional count.
|
|
24
|
+
*
|
|
25
|
+
* Colours come from the `--fd-status-*` tokens. It is not a live region on purpose: a canvas
|
|
26
|
+
* can carry dozens of pills, and each change would be announced. Screen readers reach the
|
|
27
|
+
* status through the node it belongs to.
|
|
28
|
+
*
|
|
29
|
+
* With `screenSize`, the pill scales against the canvas zoom so it stays readable when the
|
|
30
|
+
* canvas is zoomed out. It is meant to sit centred on a node's top edge.
|
|
31
|
+
*
|
|
32
|
+
* **Use it for** the run status of a node or a run on the canvas.
|
|
33
|
+
* **Not for** a free-form tag; use `Chip`.
|
|
34
|
+
*
|
|
35
|
+
* Not exported from the package; the API may still change.
|
|
36
|
+
*/
|
|
22
37
|
declare const StatusPill: import("svelte").Component<Props, {}, "">;
|
|
23
38
|
type StatusPill = ReturnType<typeof StatusPill>;
|
|
24
39
|
export default StatusPill;
|
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
<!--
|
|
2
|
-
|
|
2
|
+
@component
|
|
3
|
+
Switch: an on/off control with a 28x16 track and a round thumb.
|
|
3
4
|
|
|
4
|
-
A real checkbox with `role="switch"`, so keyboard, form and screen-reader
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
putting it inside / next to a <label for={id}>.
|
|
5
|
+
A real checkbox with `role="switch"`, so keyboard, form and screen-reader behaviour come
|
|
6
|
+
from the browser. There is no state word: the track colour and `aria-checked` show the
|
|
7
|
+
state. Name it with `label` (hidden visually) or put it next to a `<label for={id}>`.
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
**Use it for** a setting that takes effect right away.
|
|
10
|
+
**Not for** an option that is saved later with a form; use `Checkbox`.
|
|
11
|
+
|
|
12
|
+
Not exported from the package; the API may still change.
|
|
10
13
|
-->
|
|
11
14
|
|
|
12
15
|
<script lang="ts">
|
|
@@ -9,6 +9,18 @@ interface Props extends Omit<HTMLInputAttributes, 'type' | 'checked' | 'onchange
|
|
|
9
9
|
/** Extra classes on the root. */
|
|
10
10
|
class?: string;
|
|
11
11
|
}
|
|
12
|
+
/**
|
|
13
|
+
* Switch: an on/off control with a 28x16 track and a round thumb.
|
|
14
|
+
*
|
|
15
|
+
* A real checkbox with `role="switch"`, so keyboard, form and screen-reader behaviour come
|
|
16
|
+
* from the browser. There is no state word: the track colour and `aria-checked` show the
|
|
17
|
+
* state. Name it with `label` (hidden visually) or put it next to a `<label for={id}>`.
|
|
18
|
+
*
|
|
19
|
+
* **Use it for** a setting that takes effect right away.
|
|
20
|
+
* **Not for** an option that is saved later with a form; use `Checkbox`.
|
|
21
|
+
*
|
|
22
|
+
* Not exported from the package; the API may still change.
|
|
23
|
+
*/
|
|
12
24
|
declare const Switch: import("svelte").Component<Props, {}, "">;
|
|
13
25
|
type Switch = ReturnType<typeof Switch>;
|
|
14
26
|
export default Switch;
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
<!--
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
these are the two selected-tab styles of the editor chrome.
|
|
2
|
+
@component
|
|
3
|
+
Tabs: underline tabs for switching a VIEW (`role="tablist"` / `"tab"`).
|
|
5
4
|
|
|
6
|
-
|
|
7
|
-
(
|
|
8
|
-
|
|
5
|
+
**Tabs, Segmented or Toolbar?** Use Tabs for views of the same content (Form | JSON | Steps).
|
|
6
|
+
Use `Segmented` to switch a MODE (Edit | Test). Use `Toolbar` to group different controls
|
|
7
|
+
for arrow-key navigation.
|
|
9
8
|
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
The tab stop is the selected tab. Left/Right (or Up/Down) move focus and select at once;
|
|
10
|
+
Home/End jump. The selected tab is drawn in ink with a 2px underline; the others are muted.
|
|
12
11
|
|
|
13
|
-
|
|
14
|
-
<div role="tabpanel" id={tabPanelId('pg', value)}
|
|
15
|
-
aria-labelledby={tabId('pg', value)} tabindex="0">...</div>
|
|
12
|
+
Panels are yours. Wire them with the exported helpers, using the same `idBase` you pass here:
|
|
16
13
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
14
|
+
<Tabs idBase="pg" tabs={tabs} bind:value ariaLabel="Views" />
|
|
15
|
+
<div role="tabpanel" id={tabPanelId('pg', value)}
|
|
16
|
+
aria-labelledby={tabId('pg', value)} tabindex="0">...</div>
|
|
20
17
|
|
|
21
|
-
|
|
18
|
+
Each tab has `id={tabId(idBase, value)}` and `aria-controls={tabPanelId(idBase, value)}`.
|
|
19
|
+
Without `idBase` an id is generated that you cannot know, so pass `idBase` whenever panels exist.
|
|
20
|
+
|
|
21
|
+
Not exported from the package; the API may still change.
|
|
22
22
|
-->
|
|
23
23
|
|
|
24
24
|
<script lang="ts" module>
|
|
@@ -47,6 +47,7 @@
|
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
interface Props {
|
|
50
|
+
/** The tabs, in order. */
|
|
50
51
|
tabs: TabItem[];
|
|
51
52
|
/** Selected tab value (bindable) */
|
|
52
53
|
value?: string;
|
|
@@ -13,6 +13,7 @@ interface TabItem {
|
|
|
13
13
|
count?: number;
|
|
14
14
|
}
|
|
15
15
|
interface Props {
|
|
16
|
+
/** The tabs, in order. */
|
|
16
17
|
tabs: TabItem[];
|
|
17
18
|
/** Selected tab value (bindable) */
|
|
18
19
|
value?: string;
|
|
@@ -27,6 +28,27 @@ interface Props {
|
|
|
27
28
|
/** Extra classes on the root */
|
|
28
29
|
class?: string;
|
|
29
30
|
}
|
|
31
|
+
/**
|
|
32
|
+
* Tabs: underline tabs for switching a VIEW (`role="tablist"` / `"tab"`).
|
|
33
|
+
*
|
|
34
|
+
* **Tabs, Segmented or Toolbar?** Use Tabs for views of the same content (Form | JSON | Steps).
|
|
35
|
+
* Use `Segmented` to switch a MODE (Edit | Test). Use `Toolbar` to group different controls
|
|
36
|
+
* for arrow-key navigation.
|
|
37
|
+
*
|
|
38
|
+
* The tab stop is the selected tab. Left/Right (or Up/Down) move focus and select at once;
|
|
39
|
+
* Home/End jump. The selected tab is drawn in ink with a 2px underline; the others are muted.
|
|
40
|
+
*
|
|
41
|
+
* Panels are yours. Wire them with the exported helpers, using the same `idBase` you pass here:
|
|
42
|
+
*
|
|
43
|
+
* <Tabs idBase="pg" tabs={tabs} bind:value ariaLabel="Views" />
|
|
44
|
+
* <div role="tabpanel" id={tabPanelId('pg', value)}
|
|
45
|
+
* aria-labelledby={tabId('pg', value)} tabindex="0">...</div>
|
|
46
|
+
*
|
|
47
|
+
* Each tab has `id={tabId(idBase, value)}` and `aria-controls={tabPanelId(idBase, value)}`.
|
|
48
|
+
* Without `idBase` an id is generated that you cannot know, so pass `idBase` whenever panels exist.
|
|
49
|
+
*
|
|
50
|
+
* Not exported from the package; the API may still change.
|
|
51
|
+
*/
|
|
30
52
|
declare const Tabs: import("svelte").Component<Props, {}, "value">;
|
|
31
53
|
type Tabs = ReturnType<typeof Tabs>;
|
|
32
54
|
export default Tabs;
|
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
<!--
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
own (Segmented `float`, a FloatingControl, the run pill).
|
|
2
|
+
@component
|
|
3
|
+
Toolbar: a bare row (or column) that groups controls so arrow keys move between them.
|
|
5
4
|
|
|
6
|
-
role="toolbar"
|
|
7
|
-
horizontal, Up/Down
|
|
8
|
-
children.
|
|
9
|
-
the Tab order
|
|
10
|
-
|
|
11
|
-
ToolbarSeparator. Native focusable elements only (buttons, links, inputs,
|
|
12
|
-
elements with a non-negative tabindex).
|
|
5
|
+
It draws nothing itself; each control inside floats on its own. `role="toolbar"`: the arrow
|
|
6
|
+
keys (Left/Right when horizontal, Up/Down when vertical), Home and End move focus between
|
|
7
|
+
the focusable children. This is a shortcut on top of Tab, not a replacement: every control
|
|
8
|
+
keeps its place in the Tab order. A `Segmented` inside keeps its own arrow keys; the
|
|
9
|
+
toolbar skips events a child already handled.
|
|
13
10
|
|
|
14
|
-
|
|
15
|
-
|
|
11
|
+
**Toolbar, Segmented or Tabs?** Toolbar groups several different controls. `Segmented` picks
|
|
12
|
+
a mode. `Tabs` picks a view.
|
|
16
13
|
|
|
17
|
-
|
|
14
|
+
**Use it for** a group of buttons and switches. The real canvas toolbar is `CanvasToolbar`
|
|
15
|
+
(Editor/Canvas).
|
|
16
|
+
**Not for** drawing a bar; it has no surface of its own.
|
|
17
|
+
|
|
18
|
+
Not exported from the package; not public API yet.
|
|
18
19
|
-->
|
|
19
20
|
|
|
20
21
|
<script lang="ts">
|
|
@@ -9,6 +9,24 @@ interface Props {
|
|
|
9
9
|
/** Toolbar content */
|
|
10
10
|
children: Snippet;
|
|
11
11
|
}
|
|
12
|
+
/**
|
|
13
|
+
* Toolbar: a bare row (or column) that groups controls so arrow keys move between them.
|
|
14
|
+
*
|
|
15
|
+
* It draws nothing itself; each control inside floats on its own. `role="toolbar"`: the arrow
|
|
16
|
+
* keys (Left/Right when horizontal, Up/Down when vertical), Home and End move focus between
|
|
17
|
+
* the focusable children. This is a shortcut on top of Tab, not a replacement: every control
|
|
18
|
+
* keeps its place in the Tab order. A `Segmented` inside keeps its own arrow keys; the
|
|
19
|
+
* toolbar skips events a child already handled.
|
|
20
|
+
*
|
|
21
|
+
* **Toolbar, Segmented or Tabs?** Toolbar groups several different controls. `Segmented` picks
|
|
22
|
+
* a mode. `Tabs` picks a view.
|
|
23
|
+
*
|
|
24
|
+
* **Use it for** a group of buttons and switches. The real canvas toolbar is `CanvasToolbar`
|
|
25
|
+
* (Editor/Canvas).
|
|
26
|
+
* **Not for** drawing a bar; it has no surface of its own.
|
|
27
|
+
*
|
|
28
|
+
* Not exported from the package; not public API yet.
|
|
29
|
+
*/
|
|
12
30
|
declare const Toolbar: import("svelte").Component<Props, {}, "">;
|
|
13
31
|
type Toolbar = ReturnType<typeof Toolbar>;
|
|
14
32
|
export default Toolbar;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
<!--
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
perpendicular axis of the toolbar, so it is set explicitly here).
|
|
2
|
+
@component
|
|
3
|
+
ToolbarSeparator: a thin divider between groups inside a `Toolbar`.
|
|
5
4
|
|
|
6
|
-
|
|
5
|
+
Pass the same `orientation` as the toolbar. The line is drawn across that axis.
|
|
6
|
+
|
|
7
|
+
Not exported from the package; not public API yet.
|
|
7
8
|
-->
|
|
8
9
|
|
|
9
10
|
<script lang="ts">
|
|
@@ -2,6 +2,13 @@ interface Props {
|
|
|
2
2
|
/** Axis of the toolbar this sits in; the line is drawn across it */
|
|
3
3
|
orientation?: 'horizontal' | 'vertical';
|
|
4
4
|
}
|
|
5
|
+
/**
|
|
6
|
+
* ToolbarSeparator: a thin divider between groups inside a `Toolbar`.
|
|
7
|
+
*
|
|
8
|
+
* Pass the same `orientation` as the toolbar. The line is drawn across that axis.
|
|
9
|
+
*
|
|
10
|
+
* Not exported from the package; not public API yet.
|
|
11
|
+
*/
|
|
5
12
|
declare const ToolbarSeparator: import("svelte").Component<Props, {}, "">;
|
|
6
13
|
type ToolbarSeparator = ReturnType<typeof ToolbarSeparator>;
|
|
7
14
|
export default ToolbarSeparator;
|
package/dist/core/index.d.ts
CHANGED
|
@@ -38,7 +38,7 @@ export type { NodeStatusScope } from '../stores/playgroundStore.svelte.js';
|
|
|
38
38
|
export type { RunController, RunControllerOptions } from '../stores/runController.svelte.js';
|
|
39
39
|
export type { EditorMode, EditorModeStore } from '../stores/editorModeStore.svelte.js';
|
|
40
40
|
export type { EndpointConfig } from '../config/endpoints.js';
|
|
41
|
-
export type { FlowDropMountOptions, MountedFlowDropApp, NavbarAction, NavbarBranding } from '../svelte-app.js';
|
|
41
|
+
export type { FlowDropMountOptions, MountedFlowDropApp, RunCommandOptions, NavbarAction, NavbarBranding } from '../svelte-app.js';
|
|
42
42
|
export { StaticAuthProvider, CallbackAuthProvider, NoAuthProvider } from '../types/auth.js';
|
|
43
43
|
export { DEFAULT_FEATURES, mergeFeatures } from '../types/events.js';
|
|
44
44
|
export { getStatusColor, getStatusIcon, getStatusLabel, getStatusBackgroundColor, getStatusTextColor, createDefaultExecutionInfo, updateExecutionStart, updateExecutionComplete, updateExecutionFailed, resetExecutionInfo, stripExecutionInfo, formatExecutionDuration, formatLastExecuted } from '../utils/nodeStatus.js';
|
|
@@ -78,7 +78,7 @@ export { AgentSpecExecutionService } from '../services/agentSpecExecutionService
|
|
|
78
78
|
export type { AgentSpecExecutionHandle } from '../services/agentSpecExecutionService.js';
|
|
79
79
|
export { workflowSchema, WORKFLOW_SCHEMA_VERSION } from '../schemas/index.js';
|
|
80
80
|
export type { FlowDropTheme, FlowDropThemeName, FlowDropThemeConfig, FlowDropDisplayConfig } from '../types/theme.js';
|
|
81
|
-
export { defaultTheme, minimalTheme, resolveTheme } from '../themes/index.js';
|
|
81
|
+
export { classicTheme, defaultTheme, minimalTheme, normalizeThemeName, resolveTheme } from '../themes/index.js';
|
|
82
82
|
export type { FlowDropSkin, FlowDropSkinName, FlowDropSkinTokens } from '../types/skin.js';
|
|
83
83
|
export { slateSkin, defaultSkin } from '../skins/index.js';
|
|
84
84
|
export type { ThemePreference, ResolvedTheme, ColorSchemeOption, HostColorSchemeValue } from '../stores/settingsStore.svelte.js';
|
package/dist/core/index.js
CHANGED
|
@@ -87,7 +87,7 @@ export { AgentSpecExecutionService } from '../services/agentSpecExecutionService
|
|
|
87
87
|
// Workflow JSON Schema
|
|
88
88
|
// ============================================================================
|
|
89
89
|
export { workflowSchema, WORKFLOW_SCHEMA_VERSION } from '../schemas/index.js';
|
|
90
|
-
export { defaultTheme, minimalTheme, resolveTheme } from '../themes/index.js';
|
|
90
|
+
export { classicTheme, defaultTheme, minimalTheme, normalizeThemeName, resolveTheme } from '../themes/index.js';
|
|
91
91
|
export { slateSkin, defaultSkin } from '../skins/index.js';
|
|
92
92
|
export { getTheme as theme, getResolvedTheme as resolvedTheme, setTheme, toggleTheme, cycleTheme, initializeTheme, isThemeInitialized } from '../stores/settingsStore.svelte.js';
|
|
93
93
|
// ============================================================================
|
package/dist/editor/index.d.ts
CHANGED
|
@@ -92,13 +92,13 @@ export type { PortShape } from '../utils/portShape.js';
|
|
|
92
92
|
export { default as PortTypeBadge } from '../components/ports/PortTypeBadge.svelte';
|
|
93
93
|
export { fetchRuntimeConfig, getRuntimeConfig, clearRuntimeConfigCache, initRuntimeConfig } from '../config/runtimeConfig.js';
|
|
94
94
|
export type { RuntimeConfig } from '../config/runtimeConfig.js';
|
|
95
|
-
export type { Workflow, WorkflowNode, WorkflowEdge, NodeMetadata, NodePort, DynamicPort, Branch, ExecutionStatus, ExecutionResult, FlowDropConfig, PortConfig, ConfigSchema, ConfigProperty, ConfigEditOptions } from '../types/index.js';
|
|
95
|
+
export type { Workflow, WorkflowNode, WorkflowEdge, NodeMetadata, NodePort, DynamicPort, Branch, ExecutionStatus, ExecutionResult, FlowDropConfig, PortConfig, ConfigSchema, ConfigProperty, ConfigEditOptions, ConfigValues, ExternalEditLink } from '../types/index.js';
|
|
96
96
|
export type { WorkflowEditorConfig, EditorFeatures, UIConfig, APIConfig } from '../types/config.js';
|
|
97
97
|
export type { AuthProvider, StaticAuthConfig, CallbackAuthConfig } from '../types/auth.js';
|
|
98
98
|
export type { FlowDropEventHandlers, FlowDropFeatures, WorkflowChangeType } from '../types/events.js';
|
|
99
99
|
export type { EndpointConfig } from '../config/endpoints.js';
|
|
100
|
-
export type { UIAction } from '../commands/types.js';
|
|
100
|
+
export type { UIAction, Command, CommandResult, CommandErrorCode } from '../commands/types.js';
|
|
101
101
|
export type { EditorPlaygroundConfig } from '../types/playground.js';
|
|
102
|
-
export type { FlowDropMountOptions, MountedFlowDropApp, NavbarAction, NavbarBranding } from '../svelte-app.js';
|
|
102
|
+
export type { FlowDropMountOptions, MountedFlowDropApp, RunCommandOptions, NavbarAction, NavbarBranding } from '../svelte-app.js';
|
|
103
103
|
export type { ContextMenuActions, ContextMenuContext, ContextMenuEntry, ContextMenuOptions, ContextMenuTarget } from './contextMenu.js';
|
|
104
104
|
export type { NodeComponentProps, NodeComponentRegistration, FlowDropPluginConfig, PluginNodeDefinition } from '../registry/index.js';
|
package/dist/index.d.ts
CHANGED
|
@@ -32,10 +32,11 @@ export { createFlowDropInstance } from './stores/instanceContainer.svelte.js';
|
|
|
32
32
|
export { getInstance, provideInstance } from './stores/getInstance.svelte.js';
|
|
33
33
|
export { createEndpointConfig, defaultEndpointConfig, sessionsEndpoints } from './config/endpoints.js';
|
|
34
34
|
export { NoAuthProvider, StaticAuthProvider, CallbackAuthProvider } from './types/auth.js';
|
|
35
|
-
export type { Workflow, WorkflowNode, WorkflowEdge, NodeMetadata, ConfigSchema } from './types/index.js';
|
|
35
|
+
export type { Workflow, WorkflowNode, WorkflowEdge, NodeMetadata, ConfigSchema, ConfigValues, ExternalEditLink } from './types/index.js';
|
|
36
|
+
export type { Command, CommandResult, CommandErrorCode } from './commands/types.js';
|
|
36
37
|
export type { EndpointConfig } from './config/endpoints.js';
|
|
37
38
|
export type { AuthProvider } from './types/auth.js';
|
|
38
39
|
export type { FlowDropInstance } from './stores/instanceContainer.svelte.js';
|
|
39
|
-
export type { FlowDropMountOptions, MountedFlowDropApp } from './svelte-app.js';
|
|
40
|
+
export type { FlowDropMountOptions, MountedFlowDropApp, RunCommandOptions } from './svelte-app.js';
|
|
40
41
|
export type { FlowDropEventHandlers } from './types/events.js';
|
|
41
42
|
export type { Messages, MessagesOverride } from './messages/index.js';
|
package/dist/layout/index.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ export type { LayoutPrimitive, LayoutStrategy, LayoutProposal, LayoutChanges, Be
|
|
|
13
13
|
export { inspect } from './inspect.js';
|
|
14
14
|
export { sweep, formatSweep } from './sweep.js';
|
|
15
15
|
export type { SweepPhase, SweepResult } from './sweep.js';
|
|
16
|
-
export { applyProposalToNodes, applySweepToNodes,
|
|
16
|
+
export { applyProposalToNodes, applySweepToNodes, portsConfigForOrder } from './toWorkflow.js';
|
|
17
17
|
export type { NodeLayoutUpdate } from './toWorkflow.js';
|
|
18
18
|
export { loopbackLanes } from './geometry.js';
|
|
19
19
|
export type { LoopbackLane } from './geometry.js';
|
package/dist/layout/index.js
CHANGED
|
@@ -9,6 +9,6 @@ export { fromWorkflow } from './fromWorkflow.js';
|
|
|
9
9
|
export { propose, beautify, columnRanks, columnGrid, formatProposal, formatBeautify, STRATEGY_ORDER } from './primitives.js';
|
|
10
10
|
export { inspect } from './inspect.js';
|
|
11
11
|
export { sweep, formatSweep } from './sweep.js';
|
|
12
|
-
export { applyProposalToNodes, applySweepToNodes,
|
|
12
|
+
export { applyProposalToNodes, applySweepToNodes, portsConfigForOrder } from './toWorkflow.js';
|
|
13
13
|
export { loopbackLanes } from './geometry.js';
|
|
14
14
|
export { lanePath } from './lanePath.js';
|
|
@@ -3,10 +3,10 @@
|
|
|
3
3
|
*
|
|
4
4
|
* The executor dispatches the result: a new `position`, and for a port reorder the node's whole
|
|
5
5
|
* next `data.config` with `ports` rebuilt so the stored order matches the new handle order (D6).
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* a direction that ends up in default order with no exposure
|
|
9
|
-
* ports are always written last.
|
|
6
|
+
* Hidden ports, and entries for ports the node does not have, keep their places; only the visible
|
|
7
|
+
* ports trade places, among the slots the visible ports already held. The write itself is the
|
|
8
|
+
* Ports tab's (`buildPortsConfig`), so a direction that ends up in default order with no exposure
|
|
9
|
+
* override stores nothing. Reserved ports are always written last.
|
|
10
10
|
*
|
|
11
11
|
* @module layout/toWorkflow
|
|
12
12
|
*/
|
|
@@ -25,10 +25,11 @@ export interface NodeLayoutUpdate {
|
|
|
25
25
|
}
|
|
26
26
|
type Direction = 'inputs' | 'outputs';
|
|
27
27
|
/**
|
|
28
|
-
* The `ports` config after the visible ports of one direction take the order `to`.
|
|
29
|
-
*
|
|
28
|
+
* The `ports` config after the visible ports of one direction take the order `to`. The visible
|
|
29
|
+
* ports trade places among the slots they already held; hidden ports keep theirs. Written by
|
|
30
|
+
* `buildPortsConfig`, like every other `ports` edit; `undefined` when nothing needs storing.
|
|
30
31
|
*/
|
|
31
|
-
export declare function
|
|
32
|
+
export declare function portsConfigForOrder(node: WorkflowNode, direction: Direction, to: readonly string[]): PortsConfig | undefined;
|
|
32
33
|
/**
|
|
33
34
|
* The updates for the accepted proposals, one per node touched, in node order of first use.
|
|
34
35
|
* Refused proposals are skipped. Several proposals for one node apply in sequence.
|
|
@@ -3,15 +3,15 @@
|
|
|
3
3
|
*
|
|
4
4
|
* The executor dispatches the result: a new `position`, and for a port reorder the node's whole
|
|
5
5
|
* next `data.config` with `ports` rebuilt so the stored order matches the new handle order (D6).
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* a direction that ends up in default order with no exposure
|
|
9
|
-
* ports are always written last.
|
|
6
|
+
* Hidden ports, and entries for ports the node does not have, keep their places; only the visible
|
|
7
|
+
* ports trade places, among the slots the visible ports already held. The write itself is the
|
|
8
|
+
* Ports tab's (`buildPortsConfig`), so a direction that ends up in default order with no exposure
|
|
9
|
+
* override stores nothing. Reserved ports are always written last.
|
|
10
10
|
*
|
|
11
11
|
* @module layout/toWorkflow
|
|
12
12
|
*/
|
|
13
13
|
import { dynamicPortToNodePort } from '../types/index.js';
|
|
14
|
-
import {
|
|
14
|
+
import { buildPortsConfig, isPortExposed, isReservedPort, orderPortsFor } from '../utils/portUtils.js';
|
|
15
15
|
/** Every port of a direction the node has (hidden ones too), as the card builds them. */
|
|
16
16
|
function allPorts(node, direction) {
|
|
17
17
|
const metadata = node.data?.metadata;
|
|
@@ -24,48 +24,28 @@ function allPorts(node, direction) {
|
|
|
24
24
|
];
|
|
25
25
|
}
|
|
26
26
|
/**
|
|
27
|
-
* The `ports` config after the visible ports of one direction take the order `to`.
|
|
28
|
-
*
|
|
27
|
+
* The `ports` config after the visible ports of one direction take the order `to`. The visible
|
|
28
|
+
* ports trade places among the slots they already held; hidden ports keep theirs. Written by
|
|
29
|
+
* `buildPortsConfig`, like every other `ports` edit; `undefined` when nothing needs storing.
|
|
29
30
|
*/
|
|
30
|
-
export function
|
|
31
|
-
const stored = node.data?.config?.ports
|
|
32
|
-
const entries = stored[direction];
|
|
31
|
+
export function portsConfigForOrder(node, direction, to) {
|
|
32
|
+
const stored = node.data?.config?.ports;
|
|
33
|
+
const entries = stored?.[direction];
|
|
33
34
|
const ports = allPorts(node, direction);
|
|
34
|
-
const
|
|
35
|
-
const current = orderPortsFor(ports, entries).map((p) => p.id);
|
|
35
|
+
const current = orderPortsFor(ports, entries);
|
|
36
36
|
// The visible ports hold slots in the current order; `to` refills them. Hidden ports stay put.
|
|
37
|
+
const byId = new Map(ports.map((p) => [p.id, p]));
|
|
37
38
|
const wanted = new Set(to);
|
|
38
|
-
const
|
|
39
|
-
|
|
40
|
-
const order = [
|
|
41
|
-
slots.forEach((slot, i) => {
|
|
42
|
-
order[slot] = refill[i];
|
|
43
|
-
});
|
|
39
|
+
const refill = to.flatMap((id) => byId.get(id) ?? []);
|
|
40
|
+
let next = 0;
|
|
41
|
+
const order = current.map((p) => (wanted.has(p.id) ? (refill[next++] ?? p) : p));
|
|
44
42
|
// Reserved ports (trigger, tool, error, loop_back) are written last, the way the card shows
|
|
45
43
|
// them, whatever slot an older stored order gave them (Q3).
|
|
46
|
-
const reserved = new Set(ports.filter(isReservedPort).map((p) => p.id));
|
|
47
44
|
const tidy = [
|
|
48
|
-
...order.filter((
|
|
49
|
-
...order.filter((
|
|
45
|
+
...order.filter((p) => !isReservedPort(p)),
|
|
46
|
+
...order.filter((p) => isReservedPort(p))
|
|
50
47
|
];
|
|
51
|
-
|
|
52
|
-
const next = tidy.map((id) => ({ ...(byId.get(id) ?? { id }) }));
|
|
53
|
-
// Entries for ports the node no longer has stay as they were.
|
|
54
|
-
for (const entry of entries ?? [])
|
|
55
|
-
if (!known.has(entry.id))
|
|
56
|
-
next.push({ ...entry });
|
|
57
|
-
const defaultOrder = byDefaultOrder(ports).map((p) => p.id);
|
|
58
|
-
const keep = next.some((e, i) => e.id !== defaultOrder[i]) || next.some((e) => e.exposed !== undefined);
|
|
59
|
-
const result = { ...stored };
|
|
60
|
-
if (keep)
|
|
61
|
-
result[direction] = next;
|
|
62
|
-
else
|
|
63
|
-
delete result[direction];
|
|
64
|
-
for (const key of ['inputs', 'outputs']) {
|
|
65
|
-
if (result[key]?.length === 0)
|
|
66
|
-
delete result[key];
|
|
67
|
-
}
|
|
68
|
-
return Object.keys(result).length === 0 ? undefined : result;
|
|
48
|
+
return buildPortsConfig(stored, direction, tidy, ports, (p) => isPortExposed(p, entries));
|
|
69
49
|
}
|
|
70
50
|
/**
|
|
71
51
|
* The updates for the accepted proposals, one per node touched, in node order of first use.
|
|
@@ -92,7 +72,7 @@ export function applyProposalToNodes(nodes, proposals) {
|
|
|
92
72
|
const change = proposal.changes.ports?.[direction];
|
|
93
73
|
if (!change)
|
|
94
74
|
continue;
|
|
95
|
-
const ports =
|
|
75
|
+
const ports = portsConfigForOrder(next, direction, change.to);
|
|
96
76
|
const config = { ...(next.data?.config ?? {}) };
|
|
97
77
|
if (ports)
|
|
98
78
|
config.ports = ports;
|
|
@@ -28,6 +28,30 @@ export declare const defaultMessages: {
|
|
|
28
28
|
readonly no: "No";
|
|
29
29
|
};
|
|
30
30
|
readonly form: {
|
|
31
|
+
readonly ports: {
|
|
32
|
+
readonly hide: ({ port }: {
|
|
33
|
+
port: string;
|
|
34
|
+
}) => string;
|
|
35
|
+
readonly show: ({ port }: {
|
|
36
|
+
port: string;
|
|
37
|
+
}) => string;
|
|
38
|
+
readonly shown: "Shown on the canvas";
|
|
39
|
+
readonly hidden: "Hidden from the canvas";
|
|
40
|
+
readonly locked: ({ port }: {
|
|
41
|
+
port: string;
|
|
42
|
+
}) => string;
|
|
43
|
+
readonly lockedHint: "Always shown. The node type decides this port.";
|
|
44
|
+
readonly wired: ({ port }: {
|
|
45
|
+
port: string;
|
|
46
|
+
}) => string;
|
|
47
|
+
readonly wiredHint: ({ n }: {
|
|
48
|
+
n: number;
|
|
49
|
+
}) => string;
|
|
50
|
+
readonly published: ({ port }: {
|
|
51
|
+
port: string;
|
|
52
|
+
}) => string;
|
|
53
|
+
readonly publishedHint: "On the workflow interface. Remove it from the interface to hide it.";
|
|
54
|
+
};
|
|
31
55
|
readonly array: {
|
|
32
56
|
readonly itemLabel: ({ n }: {
|
|
33
57
|
n: number;
|
|
@@ -28,6 +28,21 @@ export const defaultMessages = {
|
|
|
28
28
|
no: 'No'
|
|
29
29
|
},
|
|
30
30
|
form: {
|
|
31
|
+
// The Ports tab: Show/Hide per port.
|
|
32
|
+
ports: {
|
|
33
|
+
hide: ({ port }) => `Hide port ${port}`,
|
|
34
|
+
show: ({ port }) => `Show port ${port}`,
|
|
35
|
+
shown: 'Shown on the canvas',
|
|
36
|
+
hidden: 'Hidden from the canvas',
|
|
37
|
+
locked: ({ port }) => `${port} is always shown`,
|
|
38
|
+
lockedHint: 'Always shown. The node type decides this port.',
|
|
39
|
+
wired: ({ port }) => `${port} is connected and can't be hidden`,
|
|
40
|
+
wiredHint: ({ n }) => n === 1
|
|
41
|
+
? 'Connected (1). Remove its connection on the canvas to hide it.'
|
|
42
|
+
: `Connected (${n}). Remove its connections on the canvas to hide it.`,
|
|
43
|
+
published: ({ port }) => `${port} is on the workflow interface and can't be hidden`,
|
|
44
|
+
publishedHint: 'On the workflow interface. Remove it from the interface to hide it.'
|
|
45
|
+
},
|
|
31
46
|
array: {
|
|
32
47
|
// Item-level controls — `n` is the 1-based item position the user sees.
|
|
33
48
|
itemLabel: ({ n }) => `Item ${n}`,
|
package/dist/skins/graphite.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ import type { FlowDropSkin } from '../types/skin.js';
|
|
|
12
12
|
*
|
|
13
13
|
* This is not the flowdrop.io or Factorial brand kit. Every token a colour
|
|
14
14
|
* role needs is set here in both modes, so nothing falls back to the blue
|
|
15
|
-
* of the
|
|
15
|
+
* of the Classic theme.
|
|
16
16
|
*
|
|
17
17
|
* The font is named, not loaded: import `@flowdrop/flowdrop/styles/fonts/inter.css`
|
|
18
18
|
* (or serve the same @font-face) to get Inter; without it the stack falls
|
package/dist/skins/graphite.js
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
*
|
|
12
12
|
* This is not the flowdrop.io or Factorial brand kit. Every token a colour
|
|
13
13
|
* role needs is set here in both modes, so nothing falls back to the blue
|
|
14
|
-
* of the
|
|
14
|
+
* of the Classic theme.
|
|
15
15
|
*
|
|
16
16
|
* The font is named, not loaded: import `@flowdrop/flowdrop/styles/fonts/inter.css`
|
|
17
17
|
* (or serve the same @font-face) to get Inter; without it the stack falls
|
|
@@ -13,6 +13,7 @@ import { untrack } from 'svelte';
|
|
|
13
13
|
import { DEFAULT_SETTINGS, SETTINGS_STORAGE_KEY, normalizeGridSize, normalizeLayoutGap } from '../types/settings.js';
|
|
14
14
|
import { DEFAULT_LAYOUT_GAP_X, DEFAULT_LAYOUT_GAP_Y } from '../layout/types.js';
|
|
15
15
|
import { logger } from '../utils/logger.js';
|
|
16
|
+
import { normalizeThemeName } from '../themes/index.js';
|
|
16
17
|
// =========================================================================
|
|
17
18
|
// Internal State
|
|
18
19
|
// =========================================================================
|
|
@@ -114,6 +115,8 @@ function deepMergeSettings(target, source) {
|
|
|
114
115
|
result.ui.sheetWidths = { ...target.ui.sheetWidths, ...source.ui.sheetWidths };
|
|
115
116
|
}
|
|
116
117
|
}
|
|
118
|
+
// A theme saved under its old name ('default', until 2.14) loads as 'classic'.
|
|
119
|
+
result.ui.theme = normalizeThemeName(result.ui.theme);
|
|
117
120
|
// Merge behavior settings
|
|
118
121
|
if (source.behavior) {
|
|
119
122
|
result.behavior = { ...result.behavior, ...source.behavior };
|
|
@@ -194,6 +194,16 @@ export declare class WorkflowStore {
|
|
|
194
194
|
revision?: Workflow['revision'];
|
|
195
195
|
can?: Workflow['can'];
|
|
196
196
|
}): void;
|
|
197
|
+
/**
|
|
198
|
+
* Stop calling the dirty-state and workflow-change callbacks until the
|
|
199
|
+
* returned release is called, e.g. while a change is made and then taken as
|
|
200
|
+
* the workflow's new clean state, which the host should not hear about.
|
|
201
|
+
*
|
|
202
|
+
* On release the host hears only what is still true: the dirty state when it
|
|
203
|
+
* differs from the one at muting, and one `'metadata'` change when the
|
|
204
|
+
* workflow is dirty and was replaced meanwhile. Release is idempotent.
|
|
205
|
+
*/
|
|
206
|
+
muteCallbacks(): () => void;
|
|
197
207
|
/**
|
|
198
208
|
* Set the restoring from history flag.
|
|
199
209
|
*
|