@rkmodules/rules 0.0.141 → 0.0.143
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/index.cjs.js +30 -9
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +29 -10
- package/dist/index.esm.js.map +1 -1
- package/dist/lib/Engine/index.d.ts +1 -0
- package/dist/lib/Engine/util.d.ts +1 -0
- package/dist/lib/hooks/useFlow.d.ts +9 -0
- package/package.json +1 -1
|
@@ -15,6 +15,7 @@ export declare function topSort(fn: GraphedFunction): GraphedFunction;
|
|
|
15
15
|
export interface ExecutionContext {
|
|
16
16
|
scope: Record<string, Record<string, Tree<any>>>;
|
|
17
17
|
inputs: Record<string, Record<string, Tree<any>>>;
|
|
18
|
+
params: Record<string, Record<string, any>>;
|
|
18
19
|
timings: Record<string, number>;
|
|
19
20
|
activations: Record<string, boolean>;
|
|
20
21
|
}
|
|
@@ -5,4 +5,5 @@ export declare function hasReference(value: any): value is string;
|
|
|
5
5
|
export declare function parseReference(ref: string): string;
|
|
6
6
|
export declare function uid(): string;
|
|
7
7
|
export declare function getValue(obj: Record<string, any>, path: string): any;
|
|
8
|
+
export declare function safeName(name: string): string;
|
|
8
9
|
export declare function interpolate(inputs: VarRef, scope: Record<string, Record<string, Tree<any>>>): Record<string, Tree<any>>;
|
|
@@ -11,6 +11,15 @@ export interface FlowOptions {
|
|
|
11
11
|
onDataChange?: (id: string) => (newData: Partial<FunctionNode["data"]>) => void;
|
|
12
12
|
onIOChange?: (callback: (fn: GraphedFunction) => Partial<GraphedFunction>) => void;
|
|
13
13
|
}
|
|
14
|
+
/**
|
|
15
|
+
* gets the source and target node and field from an edge by de-referencing the handles
|
|
16
|
+
* the handles are in the format `${nodeId}-${fieldName}`
|
|
17
|
+
* returns an object with the source node id, target node id, source field name and target field name
|
|
18
|
+
*/
|
|
19
|
+
export declare function deRefEdgeHandle(handle: string): {
|
|
20
|
+
node: string;
|
|
21
|
+
field: string;
|
|
22
|
+
};
|
|
14
23
|
/**
|
|
15
24
|
* creates a flow state and provides handlers to update nodes and edges
|
|
16
25
|
*/
|