@particle-academy/fancy-flow 0.3.1 → 0.4.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/dist/{chunk-GJSFZR6J.js → chunk-2BZ6OE5H.js} +168 -109
- package/dist/chunk-2BZ6OE5H.js.map +1 -0
- package/dist/{chunk-4YBSEMF2.js → chunk-35OXF6W3.js} +3 -3
- package/dist/{chunk-4YBSEMF2.js.map → chunk-35OXF6W3.js.map} +1 -1
- package/dist/chunk-4PZQRN5Y.js +114 -0
- package/dist/chunk-4PZQRN5Y.js.map +1 -0
- package/dist/chunk-DW66NGU5.js +138 -0
- package/dist/chunk-DW66NGU5.js.map +1 -0
- package/dist/{chunk-OZPQAUZD.js → engine.cjs} +4 -111
- package/dist/engine.cjs.map +1 -0
- package/dist/engine.d.cts +35 -0
- package/dist/engine.d.ts +35 -0
- package/dist/engine.js +3 -0
- package/dist/engine.js.map +1 -0
- package/dist/index.cjs +167 -108
- package/dist/index.cjs.map +1 -1
- package/dist/index.css +1 -0
- package/dist/index.css.map +1 -1
- package/dist/index.d.cts +19 -19
- package/dist/index.d.ts +19 -19
- package/dist/index.js +6 -5
- package/dist/index.js.map +1 -1
- package/dist/registry/index.d.cts +2 -3
- package/dist/registry/index.d.ts +2 -3
- package/dist/registry.cjs +165 -106
- package/dist/registry.cjs.map +1 -1
- package/dist/registry.js +2 -2
- package/dist/runtime/index.d.cts +4 -32
- package/dist/runtime/index.d.ts +4 -32
- package/dist/runtime.cjs +166 -107
- package/dist/runtime.cjs.map +1 -1
- package/dist/runtime.js +3 -2
- package/dist/schema/index.d.cts +1 -1
- package/dist/schema/index.d.ts +1 -1
- package/dist/{types-Ch4sAvum.d.cts → types-TemTtb04.d.cts} +1 -1
- package/dist/{types-Ch4sAvum.d.ts → types-TemTtb04.d.ts} +1 -1
- package/package.json +46 -9
- package/dist/chunk-GJSFZR6J.js.map +0 -1
- package/dist/chunk-OZPQAUZD.js.map +0 -1
package/dist/registry.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { BUILTIN_KINDS, RegistryNode, buildNodeTypes, registerBuiltinKinds } from './chunk-
|
|
2
|
-
import './chunk-
|
|
1
|
+
export { BUILTIN_KINDS, RegistryNode, buildNodeTypes, registerBuiltinKinds } from './chunk-35OXF6W3.js';
|
|
2
|
+
import './chunk-2BZ6OE5H.js';
|
|
3
3
|
export { categoryAccent, defaultConfigFor, getNodeKind, listNodeKinds, onNodeKindsChanged, registerNodeKind, validateConfig } from './chunk-WNVBXXOL.js';
|
|
4
4
|
//# sourceMappingURL=registry.js.map
|
|
5
5
|
//# sourceMappingURL=registry.js.map
|
package/dist/runtime/index.d.cts
CHANGED
|
@@ -1,36 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { RunResult, RunOptions } from '../engine.cjs';
|
|
2
|
+
export { runFlow } from '../engine.cjs';
|
|
3
|
+
import { e as NodeRunStatus, a as FlowGraph, E as ExecutorRegistry, F as FlowNode, b as FlowEdge } from '../types-TemTtb04.cjs';
|
|
2
4
|
import { NodeChange, EdgeChange, Connection } from '@xyflow/react';
|
|
3
5
|
|
|
4
|
-
type RunOptions = {
|
|
5
|
-
/** Stop the run after this many ms. Default: no timeout. */
|
|
6
|
-
timeoutMs?: number;
|
|
7
|
-
/** Abort signal — host can cancel the run. */
|
|
8
|
-
signal?: AbortSignal;
|
|
9
|
-
/** Initial inputs supplied to entry-point nodes (no incoming edges). */
|
|
10
|
-
initialInputs?: Record<string, Record<string, unknown>>;
|
|
11
|
-
};
|
|
12
|
-
type RunResult = {
|
|
13
|
-
ok: boolean;
|
|
14
|
-
/** Outputs collected per node, keyed by node id. */
|
|
15
|
-
outputs: Record<string, unknown>;
|
|
16
|
-
/** Error captured if any node threw. */
|
|
17
|
-
error?: string;
|
|
18
|
-
};
|
|
19
|
-
/**
|
|
20
|
-
* runFlow — topological execution of a FlowGraph against an ExecutorRegistry.
|
|
21
|
-
*
|
|
22
|
-
* Each node runs once, when all upstream nodes have produced outputs on the
|
|
23
|
-
* connected ports. Decision nodes (or any executor that returns `{ branch:
|
|
24
|
-
* 'true' }`) can short-circuit specific output ports — only edges leaving
|
|
25
|
-
* an "active" port propagate to downstream nodes.
|
|
26
|
-
*
|
|
27
|
-
* Cycles are detected and abort the run with an error.
|
|
28
|
-
*
|
|
29
|
-
* The `onEvent` callback receives a stream of `RunEvent`s — wire it to a
|
|
30
|
-
* status feed, log panel, or store.
|
|
31
|
-
*/
|
|
32
|
-
declare function runFlow(graph: FlowGraph, executors: ExecutorRegistry, onEvent?: (event: RunEvent) => void, options?: RunOptions): Promise<RunResult>;
|
|
33
|
-
|
|
34
6
|
type FlowRunFeedEntry = {
|
|
35
7
|
id: string;
|
|
36
8
|
at: number;
|
|
@@ -90,4 +62,4 @@ type UseFlowStateReturn = {
|
|
|
90
62
|
*/
|
|
91
63
|
declare function useFlowState(initial: FlowGraph): UseFlowStateReturn;
|
|
92
64
|
|
|
93
|
-
export { type FlowRunFeedEntry,
|
|
65
|
+
export { type FlowRunFeedEntry, RunOptions, RunResult, type UseFlowRunOptions, type UseFlowRunReturn, type UseFlowStateReturn, applyStatusesToNodes, useFlowRun, useFlowState };
|
package/dist/runtime/index.d.ts
CHANGED
|
@@ -1,36 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { RunResult, RunOptions } from '../engine.js';
|
|
2
|
+
export { runFlow } from '../engine.js';
|
|
3
|
+
import { e as NodeRunStatus, a as FlowGraph, E as ExecutorRegistry, F as FlowNode, b as FlowEdge } from '../types-TemTtb04.js';
|
|
2
4
|
import { NodeChange, EdgeChange, Connection } from '@xyflow/react';
|
|
3
5
|
|
|
4
|
-
type RunOptions = {
|
|
5
|
-
/** Stop the run after this many ms. Default: no timeout. */
|
|
6
|
-
timeoutMs?: number;
|
|
7
|
-
/** Abort signal — host can cancel the run. */
|
|
8
|
-
signal?: AbortSignal;
|
|
9
|
-
/** Initial inputs supplied to entry-point nodes (no incoming edges). */
|
|
10
|
-
initialInputs?: Record<string, Record<string, unknown>>;
|
|
11
|
-
};
|
|
12
|
-
type RunResult = {
|
|
13
|
-
ok: boolean;
|
|
14
|
-
/** Outputs collected per node, keyed by node id. */
|
|
15
|
-
outputs: Record<string, unknown>;
|
|
16
|
-
/** Error captured if any node threw. */
|
|
17
|
-
error?: string;
|
|
18
|
-
};
|
|
19
|
-
/**
|
|
20
|
-
* runFlow — topological execution of a FlowGraph against an ExecutorRegistry.
|
|
21
|
-
*
|
|
22
|
-
* Each node runs once, when all upstream nodes have produced outputs on the
|
|
23
|
-
* connected ports. Decision nodes (or any executor that returns `{ branch:
|
|
24
|
-
* 'true' }`) can short-circuit specific output ports — only edges leaving
|
|
25
|
-
* an "active" port propagate to downstream nodes.
|
|
26
|
-
*
|
|
27
|
-
* Cycles are detected and abort the run with an error.
|
|
28
|
-
*
|
|
29
|
-
* The `onEvent` callback receives a stream of `RunEvent`s — wire it to a
|
|
30
|
-
* status feed, log panel, or store.
|
|
31
|
-
*/
|
|
32
|
-
declare function runFlow(graph: FlowGraph, executors: ExecutorRegistry, onEvent?: (event: RunEvent) => void, options?: RunOptions): Promise<RunResult>;
|
|
33
|
-
|
|
34
6
|
type FlowRunFeedEntry = {
|
|
35
7
|
id: string;
|
|
36
8
|
at: number;
|
|
@@ -90,4 +62,4 @@ type UseFlowStateReturn = {
|
|
|
90
62
|
*/
|
|
91
63
|
declare function useFlowState(initial: FlowGraph): UseFlowStateReturn;
|
|
92
64
|
|
|
93
|
-
export { type FlowRunFeedEntry,
|
|
65
|
+
export { type FlowRunFeedEntry, RunOptions, RunResult, type UseFlowRunOptions, type UseFlowRunReturn, type UseFlowStateReturn, applyStatusesToNodes, useFlowRun, useFlowState };
|