@datatechsolutions/ui 2.11.2 → 2.11.4
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/astrlabe/contracts.d.mts +293 -0
- package/dist/astrlabe/contracts.d.ts +293 -0
- package/dist/astrlabe/graph-node.d.mts +28 -0
- package/dist/astrlabe/graph-node.d.ts +28 -0
- package/dist/astrlabe/index.d.mts +707 -0
- package/dist/astrlabe/index.d.ts +707 -0
- package/dist/astrlabe/index.js +141 -141
- package/dist/astrlabe/index.js.map +1 -1
- package/dist/astrlabe/index.mjs +27 -27
- package/dist/astrlabe/index.mjs.map +1 -1
- package/dist/astrlabe/utils.d.mts +71 -0
- package/dist/astrlabe/utils.d.ts +71 -0
- package/dist/astrlabe/utils.js +4 -4
- package/dist/astrlabe/utils.mjs +1 -1
- package/dist/astrlabe/workflow-canvas.d.mts +5 -0
- package/dist/astrlabe/workflow-canvas.d.ts +5 -0
- package/dist/astrlabe/workflow-canvas.js +6 -6
- package/dist/astrlabe/workflow-canvas.mjs +5 -5
- package/dist/astrlabe/workflow-preview-canvas.d.mts +10 -0
- package/dist/astrlabe/workflow-preview-canvas.d.ts +10 -0
- package/dist/{chunk-4TZNBT5V.js → chunk-AZ3BXAI6.js} +129 -119
- package/dist/chunk-AZ3BXAI6.js.map +1 -0
- package/dist/{chunk-ZEYHIEHE.mjs → chunk-BHKBEP2Y.mjs} +72 -62
- package/dist/chunk-BHKBEP2Y.mjs.map +1 -0
- package/dist/{chunk-NMXHJMGI.js → chunk-EVX2CFNL.js} +4 -4
- package/dist/chunk-EVX2CFNL.js.map +1 -0
- package/dist/{chunk-VB45EBH5.mjs → chunk-F6EBSQF6.mjs} +4 -4
- package/dist/chunk-F6EBSQF6.mjs.map +1 -0
- package/dist/{chunk-DFR6CMJH.js → chunk-PWBWP5FJ.js} +2 -2
- package/dist/{chunk-DFR6CMJH.js.map → chunk-PWBWP5FJ.js.map} +1 -1
- package/dist/{chunk-AM2TTPYM.mjs → chunk-TLPPVL3W.mjs} +2 -2
- package/dist/{chunk-AM2TTPYM.mjs.map → chunk-TLPPVL3W.mjs.map} +1 -1
- package/dist/dynamic-island-confirm-Cbxh-sta.d.mts +52 -0
- package/dist/dynamic-island-confirm-Cbxh-sta.d.ts +52 -0
- package/dist/index.d.mts +4771 -0
- package/dist/index.d.ts +4771 -0
- package/dist/index.js +727 -727
- package/dist/index.mjs +2 -2
- package/dist/lib/i18n-context.d.mts +36 -0
- package/dist/lib/i18n-context.d.ts +36 -0
- package/dist/lib/router-context.d.mts +35 -0
- package/dist/lib/router-context.d.ts +35 -0
- package/dist/workflow-canvas-CQtkR4Y6.d.ts +241 -0
- package/dist/workflow-canvas-D9kHlmev.d.mts +241 -0
- package/package.json +3 -2
- package/dist/chunk-4TZNBT5V.js.map +0 -1
- package/dist/chunk-NMXHJMGI.js.map +0 -1
- package/dist/chunk-VB45EBH5.mjs.map +0 -1
- package/dist/chunk-ZEYHIEHE.mjs.map +0 -1
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { WorkflowNodeType, LogicNodeConfig, WorkflowGraph } from './contracts.mjs';
|
|
2
|
+
import { Node, Edge } from '@xyflow/react';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Layout Engine
|
|
6
|
+
* =============
|
|
7
|
+
* Auto-layout for workflow graphs using @dagrejs/dagre.
|
|
8
|
+
* Pure utility — no React dependencies.
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
/** Layout direction: free means no auto-layout is applied. */
|
|
12
|
+
type LayoutDirection = 'free' | 'LR' | 'TB';
|
|
13
|
+
/**
|
|
14
|
+
* Apply dagre layout to the given nodes and edges.
|
|
15
|
+
* Returns a new array of nodes with updated positions.
|
|
16
|
+
* Group child nodes (parentId set) and note nodes are excluded from layout.
|
|
17
|
+
*/
|
|
18
|
+
declare function applyDagreLayout(nodes: Node[], edges: Edge[], direction: Exclude<LayoutDirection, 'free'>): Node[];
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Logic Node Default Configs
|
|
22
|
+
* ==========================
|
|
23
|
+
* Factory function to create default configs for each logic node type.
|
|
24
|
+
*/
|
|
25
|
+
|
|
26
|
+
declare function createDefaultLogicNodeConfig(nodeType: WorkflowNodeType): LogicNodeConfig | null;
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* Workflow Validator
|
|
30
|
+
* =================
|
|
31
|
+
* Validates the workflow graph before publishing.
|
|
32
|
+
* Ensures the graph forms a valid DAG with proper node connections.
|
|
33
|
+
*/
|
|
34
|
+
|
|
35
|
+
type ValidationResult = {
|
|
36
|
+
valid: boolean;
|
|
37
|
+
errors: string[];
|
|
38
|
+
};
|
|
39
|
+
/**
|
|
40
|
+
* Validate a workflow graph for publishing.
|
|
41
|
+
* Checks:
|
|
42
|
+
* - At least one agent node exists
|
|
43
|
+
* - All edges have valid source/target nodes
|
|
44
|
+
* - No orphan nodes (every node has at least one connection, except note nodes)
|
|
45
|
+
* - Tool nodes connect to agent nodes only
|
|
46
|
+
* - Agent chain forms a valid DAG (no cycles)
|
|
47
|
+
* - Rule nodes have incoming edges from agents
|
|
48
|
+
* - Logic node constraints (start/end uniqueness, config validation)
|
|
49
|
+
* - New node type validations (answer, question_classifier, parameter_extractor, etc.)
|
|
50
|
+
*/
|
|
51
|
+
declare function validateWorkflowGraph(graph: WorkflowGraph): ValidationResult;
|
|
52
|
+
/**
|
|
53
|
+
* Topologically sort agent nodes from the graph edges.
|
|
54
|
+
* Returns agent entityIds in execution order.
|
|
55
|
+
* Logic nodes are skipped — only agent entityIds are returned.
|
|
56
|
+
*/
|
|
57
|
+
declare function topologicalSortAgents(graph: WorkflowGraph): string[];
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* Agent ELO Tier
|
|
61
|
+
* ==============
|
|
62
|
+
* Derives difficulty tier from agent ELO rating.
|
|
63
|
+
* Used in node palette, agent flow node, and agent modal.
|
|
64
|
+
*/
|
|
65
|
+
type AgentTier = {
|
|
66
|
+
key: 'beginner' | 'intermediate' | 'advanced' | 'expert';
|
|
67
|
+
pillColor: string;
|
|
68
|
+
};
|
|
69
|
+
declare function getAgentTier(elo: number | undefined): AgentTier;
|
|
70
|
+
|
|
71
|
+
export { type AgentTier, type LayoutDirection, applyDagreLayout, createDefaultLogicNodeConfig, getAgentTier, topologicalSortAgents, validateWorkflowGraph };
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { WorkflowNodeType, LogicNodeConfig, WorkflowGraph } from './contracts.js';
|
|
2
|
+
import { Node, Edge } from '@xyflow/react';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Layout Engine
|
|
6
|
+
* =============
|
|
7
|
+
* Auto-layout for workflow graphs using @dagrejs/dagre.
|
|
8
|
+
* Pure utility — no React dependencies.
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
/** Layout direction: free means no auto-layout is applied. */
|
|
12
|
+
type LayoutDirection = 'free' | 'LR' | 'TB';
|
|
13
|
+
/**
|
|
14
|
+
* Apply dagre layout to the given nodes and edges.
|
|
15
|
+
* Returns a new array of nodes with updated positions.
|
|
16
|
+
* Group child nodes (parentId set) and note nodes are excluded from layout.
|
|
17
|
+
*/
|
|
18
|
+
declare function applyDagreLayout(nodes: Node[], edges: Edge[], direction: Exclude<LayoutDirection, 'free'>): Node[];
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Logic Node Default Configs
|
|
22
|
+
* ==========================
|
|
23
|
+
* Factory function to create default configs for each logic node type.
|
|
24
|
+
*/
|
|
25
|
+
|
|
26
|
+
declare function createDefaultLogicNodeConfig(nodeType: WorkflowNodeType): LogicNodeConfig | null;
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* Workflow Validator
|
|
30
|
+
* =================
|
|
31
|
+
* Validates the workflow graph before publishing.
|
|
32
|
+
* Ensures the graph forms a valid DAG with proper node connections.
|
|
33
|
+
*/
|
|
34
|
+
|
|
35
|
+
type ValidationResult = {
|
|
36
|
+
valid: boolean;
|
|
37
|
+
errors: string[];
|
|
38
|
+
};
|
|
39
|
+
/**
|
|
40
|
+
* Validate a workflow graph for publishing.
|
|
41
|
+
* Checks:
|
|
42
|
+
* - At least one agent node exists
|
|
43
|
+
* - All edges have valid source/target nodes
|
|
44
|
+
* - No orphan nodes (every node has at least one connection, except note nodes)
|
|
45
|
+
* - Tool nodes connect to agent nodes only
|
|
46
|
+
* - Agent chain forms a valid DAG (no cycles)
|
|
47
|
+
* - Rule nodes have incoming edges from agents
|
|
48
|
+
* - Logic node constraints (start/end uniqueness, config validation)
|
|
49
|
+
* - New node type validations (answer, question_classifier, parameter_extractor, etc.)
|
|
50
|
+
*/
|
|
51
|
+
declare function validateWorkflowGraph(graph: WorkflowGraph): ValidationResult;
|
|
52
|
+
/**
|
|
53
|
+
* Topologically sort agent nodes from the graph edges.
|
|
54
|
+
* Returns agent entityIds in execution order.
|
|
55
|
+
* Logic nodes are skipped — only agent entityIds are returned.
|
|
56
|
+
*/
|
|
57
|
+
declare function topologicalSortAgents(graph: WorkflowGraph): string[];
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* Agent ELO Tier
|
|
61
|
+
* ==============
|
|
62
|
+
* Derives difficulty tier from agent ELO rating.
|
|
63
|
+
* Used in node palette, agent flow node, and agent modal.
|
|
64
|
+
*/
|
|
65
|
+
type AgentTier = {
|
|
66
|
+
key: 'beginner' | 'intermediate' | 'advanced' | 'expert';
|
|
67
|
+
pillColor: string;
|
|
68
|
+
};
|
|
69
|
+
declare function getAgentTier(elo: number | undefined): AgentTier;
|
|
70
|
+
|
|
71
|
+
export { type AgentTier, type LayoutDirection, applyDagreLayout, createDefaultLogicNodeConfig, getAgentTier, topologicalSortAgents, validateWorkflowGraph };
|
package/dist/astrlabe/utils.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
4
|
var chunk3GE3MBUZ_js = require('../chunk-3GE3MBUZ.js');
|
|
5
|
-
var
|
|
5
|
+
var chunkPWBWP5FJ_js = require('../chunk-PWBWP5FJ.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
@@ -16,15 +16,15 @@ Object.defineProperty(exports, "validateWorkflowGraph", {
|
|
|
16
16
|
});
|
|
17
17
|
Object.defineProperty(exports, "applyDagreLayout", {
|
|
18
18
|
enumerable: true,
|
|
19
|
-
get: function () { return
|
|
19
|
+
get: function () { return chunkPWBWP5FJ_js.applyDagreLayout; }
|
|
20
20
|
});
|
|
21
21
|
Object.defineProperty(exports, "createDefaultLogicNodeConfig", {
|
|
22
22
|
enumerable: true,
|
|
23
|
-
get: function () { return
|
|
23
|
+
get: function () { return chunkPWBWP5FJ_js.createDefaultLogicNodeConfig; }
|
|
24
24
|
});
|
|
25
25
|
Object.defineProperty(exports, "getAgentTier", {
|
|
26
26
|
enumerable: true,
|
|
27
|
-
get: function () { return
|
|
27
|
+
get: function () { return chunkPWBWP5FJ_js.getAgentTier; }
|
|
28
28
|
});
|
|
29
29
|
//# sourceMappingURL=utils.js.map
|
|
30
30
|
//# sourceMappingURL=utils.js.map
|
package/dist/astrlabe/utils.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
export { topologicalSortAgents, validateWorkflowGraph } from '../chunk-BLNXRUC4.mjs';
|
|
3
|
-
export { applyDagreLayout, createDefaultLogicNodeConfig, getAgentTier } from '../chunk-
|
|
3
|
+
export { applyDagreLayout, createDefaultLogicNodeConfig, getAgentTier } from '../chunk-TLPPVL3W.mjs';
|
|
4
4
|
//# sourceMappingURL=utils.mjs.map
|
|
5
5
|
//# sourceMappingURL=utils.mjs.map
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('../chunk-
|
|
6
|
-
require('../chunk-UZ3CMNUJ.js');
|
|
7
|
-
require('../chunk-YXN2K77G.js');
|
|
4
|
+
var chunkAZ3BXAI6_js = require('../chunk-AZ3BXAI6.js');
|
|
5
|
+
require('../chunk-EVX2CFNL.js');
|
|
8
6
|
require('../chunk-S7KHTUHA.js');
|
|
7
|
+
require('../chunk-UZ3CMNUJ.js');
|
|
9
8
|
require('../chunk-P4YYEM4B.js');
|
|
10
|
-
require('../chunk-
|
|
9
|
+
require('../chunk-PWBWP5FJ.js');
|
|
10
|
+
require('../chunk-YXN2K77G.js');
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
Object.defineProperty(exports, "Workspace", {
|
|
15
15
|
enumerable: true,
|
|
16
|
-
get: function () { return
|
|
16
|
+
get: function () { return chunkAZ3BXAI6_js.Workspace; }
|
|
17
17
|
});
|
|
18
18
|
//# sourceMappingURL=workflow-canvas.js.map
|
|
19
19
|
//# sourceMappingURL=workflow-canvas.js.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
export { Workspace } from '../chunk-
|
|
3
|
-
import '../chunk-
|
|
4
|
-
import '../chunk-D2JF6C3E.mjs';
|
|
5
|
-
import '../chunk-7VJ7CMMT.mjs';
|
|
2
|
+
export { Workspace } from '../chunk-BHKBEP2Y.mjs';
|
|
3
|
+
import '../chunk-F6EBSQF6.mjs';
|
|
6
4
|
import '../chunk-QWG2FMUN.mjs';
|
|
5
|
+
import '../chunk-D2JF6C3E.mjs';
|
|
7
6
|
import '../chunk-OZNTQROP.mjs';
|
|
8
|
-
import '../chunk-
|
|
7
|
+
import '../chunk-TLPPVL3W.mjs';
|
|
8
|
+
import '../chunk-7VJ7CMMT.mjs';
|
|
9
9
|
//# sourceMappingURL=workflow-canvas.mjs.map
|
|
10
10
|
//# sourceMappingURL=workflow-canvas.mjs.map
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { WorkflowGraph } from './contracts.mjs';
|
|
3
|
+
|
|
4
|
+
type WorkflowPreviewCanvasProps = {
|
|
5
|
+
graph: WorkflowGraph;
|
|
6
|
+
className?: string;
|
|
7
|
+
};
|
|
8
|
+
declare function WorkflowPreviewCanvas({ graph, className }: WorkflowPreviewCanvasProps): react_jsx_runtime.JSX.Element;
|
|
9
|
+
|
|
10
|
+
export { WorkflowPreviewCanvas, type WorkflowPreviewCanvasProps };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { WorkflowGraph } from './contracts.js';
|
|
3
|
+
|
|
4
|
+
type WorkflowPreviewCanvasProps = {
|
|
5
|
+
graph: WorkflowGraph;
|
|
6
|
+
className?: string;
|
|
7
|
+
};
|
|
8
|
+
declare function WorkflowPreviewCanvas({ graph, className }: WorkflowPreviewCanvasProps): react_jsx_runtime.JSX.Element;
|
|
9
|
+
|
|
10
|
+
export { WorkflowPreviewCanvas, type WorkflowPreviewCanvasProps };
|