@fluxo-dev/shell-workflow 26.1.1 → 26.1.3

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.
Files changed (102) hide show
  1. package/index.esm.css +761 -0
  2. package/index.esm.js +113730 -7381
  3. package/package.json +4 -4
  4. package/src/index.d.ts +5 -1
  5. package/src/lib/etl/browse/etl-browse.d.ts +6 -0
  6. package/src/lib/etl/browse/index.d.ts +2 -0
  7. package/src/lib/etl/components/nodes/EtlBlockNode.d.ts +3 -0
  8. package/src/lib/etl/components/nodes/index.d.ts +1 -0
  9. package/src/lib/etl/components/panels/BlockConfigPanel.d.ts +10 -0
  10. package/src/lib/etl/components/panels/BlocksPanel.d.ts +8 -0
  11. package/src/lib/etl/components/panels/PreviewDataPanel.d.ts +8 -0
  12. package/src/lib/etl/components/panels/index.d.ts +3 -0
  13. package/src/lib/etl/constants/index.d.ts +22 -0
  14. package/src/lib/etl/designer/EtlDesignerContext.d.ts +14 -0
  15. package/src/lib/etl/designer/etl-designer.d.ts +7 -0
  16. package/src/lib/etl/designer/index.d.ts +1 -0
  17. package/src/lib/etl/hooks/index.d.ts +6 -0
  18. package/src/lib/etl/hooks/useBlockDefinitions.d.ts +12 -0
  19. package/src/lib/etl/hooks/useExecutionHistory.d.ts +13 -0
  20. package/src/lib/etl/hooks/useNodeOperations.d.ts +15 -0
  21. package/src/lib/etl/hooks/usePipelineActions.d.ts +25 -0
  22. package/src/lib/etl/hooks/usePipelineLiveDebug.d.ts +20 -0
  23. package/src/lib/etl/hooks/usePipelineState.d.ts +16 -0
  24. package/src/lib/etl/services/etl-debug-hub.service.d.ts +13 -0
  25. package/src/lib/etl/types/etl-block.types.d.ts +2 -0
  26. package/src/lib/etl/types/etl-config-field.types.d.ts +9 -0
  27. package/src/lib/etl/types/etl-live-debug.types.d.ts +56 -0
  28. package/src/lib/etl/types/etl-pipeline.types.d.ts +243 -0
  29. package/src/lib/etl/types/index.d.ts +4 -0
  30. package/src/lib/etl/utils/config-field-utils.d.ts +26 -0
  31. package/src/lib/etl/utils/dynamic-ports.d.ts +12 -0
  32. package/src/lib/etl/utils/icon-mapper.d.ts +12 -0
  33. package/src/lib/etl/utils/index.d.ts +6 -0
  34. package/src/lib/etl/utils/pipeline-converter.d.ts +14 -0
  35. package/src/lib/etl/utils/status-utils.d.ts +19 -0
  36. package/src/lib/etl/utils/validation.d.ts +17 -0
  37. package/src/lib/fluxo-module.d.ts +1 -2
  38. package/src/lib/workflow/browse/workflow-browse.d.ts +6 -0
  39. package/src/lib/workflow/browse/workflow-executions-panel.d.ts +8 -0
  40. package/src/lib/workflow/designer-v2/components/canvas/FlowCanvas.d.ts +16 -0
  41. package/src/lib/workflow/designer-v2/components/edges/CustomEdge.d.ts +3 -0
  42. package/src/lib/workflow/designer-v2/components/modals/TriggerInputModal.d.ts +10 -0
  43. package/src/lib/workflow/designer-v2/components/nodes/CustomNode.d.ts +3 -0
  44. package/src/lib/workflow/designer-v2/components/panels/ActionsPanel/ActionsPanel.d.ts +12 -0
  45. package/src/lib/workflow/designer-v2/components/panels/NodeConfigPanel/CollapsibleGroup.d.ts +12 -0
  46. package/src/lib/workflow/designer-v2/components/panels/NodeConfigPanel/ConditionalInput.d.ts +17 -0
  47. package/src/lib/workflow/designer-v2/components/panels/NodeConfigPanel/ExpressionEditor.d.ts +19 -0
  48. package/src/lib/workflow/designer-v2/components/panels/NodeConfigPanel/InputField.d.ts +26 -0
  49. package/src/lib/workflow/designer-v2/components/panels/NodeConfigPanel/InputsSection.d.ts +13 -0
  50. package/src/lib/workflow/designer-v2/components/panels/NodeConfigPanel/NodeConfigPanel.d.ts +12 -0
  51. package/src/lib/workflow/designer-v2/components/panels/NodeConfigPanel/OutcomesSection.d.ts +5 -0
  52. package/src/lib/workflow/designer-v2/components/panels/NodeConfigPanel/OutputsSection.d.ts +6 -0
  53. package/src/lib/workflow/designer-v2/components/panels/NodeConfigPanel/PrimitiveInputsSection.d.ts +13 -0
  54. package/src/lib/workflow/designer-v2/components/panels/NodeConfigPanel/TypedValueEditor.d.ts +17 -0
  55. package/src/lib/workflow/designer-v2/components/toolbar/WorkflowToolbar.d.ts +9 -0
  56. package/src/lib/workflow/designer-v2/constants/index.d.ts +3 -0
  57. package/src/lib/workflow/designer-v2/constants/primitives.d.ts +27 -0
  58. package/src/lib/workflow/designer-v2/constants/styles.d.ts +61 -0
  59. package/src/lib/workflow/designer-v2/constants/triggers.d.ts +10 -0
  60. package/src/lib/workflow/designer-v2/constants/ui-hints.d.ts +22 -0
  61. package/src/lib/workflow/designer-v2/hooks/index.d.ts +9 -0
  62. package/src/lib/workflow/designer-v2/hooks/useActionDefinitions.d.ts +11 -0
  63. package/src/lib/workflow/designer-v2/hooks/useAvailableOutputs.d.ts +14 -0
  64. package/src/lib/workflow/designer-v2/hooks/useInputDependencies.d.ts +9 -0
  65. package/src/lib/workflow/designer-v2/hooks/useInputValidation.d.ts +9 -0
  66. package/src/lib/workflow/designer-v2/hooks/useNodeInputs.d.ts +18 -0
  67. package/src/lib/workflow/designer-v2/hooks/useNodeOperations.d.ts +15 -0
  68. package/src/lib/workflow/designer-v2/hooks/useTriggerDefinitions.d.ts +11 -0
  69. package/src/lib/workflow/designer-v2/hooks/useWorkflowActions.d.ts +15 -0
  70. package/src/lib/workflow/designer-v2/hooks/useWorkflowState.d.ts +17 -0
  71. package/src/lib/workflow/designer-v2/index.d.ts +2 -0
  72. package/src/lib/workflow/designer-v2/types/index.d.ts +6 -0
  73. package/src/lib/workflow/designer-v2/types/input-config.types.d.ts +32 -0
  74. package/src/lib/workflow/designer-v2/types/input-dependency.types.d.ts +17 -0
  75. package/src/lib/workflow/designer-v2/types/input-group.types.d.ts +10 -0
  76. package/src/lib/workflow/designer-v2/types/input-validation.types.d.ts +11 -0
  77. package/src/lib/workflow/designer-v2/types/node-data.types.d.ts +52 -0
  78. package/src/lib/workflow/designer-v2/types/workflow-state.types.d.ts +28 -0
  79. package/src/lib/workflow/designer-v2/utils/branch-validation.d.ts +43 -0
  80. package/src/lib/workflow/designer-v2/utils/handle-helpers.d.ts +8 -0
  81. package/src/lib/workflow/designer-v2/utils/icon-mapper.d.ts +5 -0
  82. package/src/lib/workflow/designer-v2/utils/index.d.ts +8 -0
  83. package/src/lib/workflow/designer-v2/utils/node-factory.d.ts +31 -0
  84. package/src/lib/workflow/designer-v2/utils/parallel-detection.d.ts +32 -0
  85. package/src/lib/workflow/designer-v2/utils/transformers.d.ts +23 -0
  86. package/src/lib/workflow/designer-v2/utils/validation.d.ts +22 -0
  87. package/src/lib/workflow/designer-v2/utils/while-visual-edges.d.ts +7 -0
  88. package/src/lib/workflow/designer-v2/workflow-designer-v2.d.ts +8 -0
  89. package/src/lib/designer/components/action/action-card.d.ts +0 -5
  90. package/src/lib/designer/components/action/action-inputs.d.ts +0 -7
  91. package/src/lib/designer/components/action/outputs-picker.d.ts +0 -6
  92. package/src/lib/designer/components/action-chooser.d.ts +0 -5
  93. package/src/lib/designer/components/connectors/action-button.d.ts +0 -8
  94. package/src/lib/designer/components/connectors/action-connector-vertical-fill.d.ts +0 -10
  95. package/src/lib/designer/components/connectors/action-connector-vertical.d.ts +0 -9
  96. package/src/lib/designer/components/connectors/action-connector.d.ts +0 -7
  97. package/src/lib/designer/components/trigger/trigger-card.d.ts +0 -5
  98. package/src/lib/designer/components/trigger-chooser.d.ts +0 -5
  99. package/src/lib/designer/provider/workflow-designer-provider.d.ts +0 -27
  100. package/src/lib/designer/services/workflow-manager-interface.d.ts +0 -13
  101. package/src/lib/designer/services/workflow-manager.d.ts +0 -75
  102. package/src/lib/designer/workflow-designer.d.ts +0 -5
@@ -0,0 +1,19 @@
1
+ import { PipelineStatus } from '../types';
2
+ /**
3
+ * Check if a status represents a running/active state
4
+ */
5
+ export declare function isRunningStatus(status: string | number | PipelineStatus): boolean;
6
+ /**
7
+ * Normalize pipeline status to PipelineStatus enum.
8
+ * Falls back to PipelineStatus.Pending for unknown values.
9
+ */
10
+ export declare function normalizePipelineStatus(status: string | number): PipelineStatus;
11
+ /**
12
+ * Get badge color for a status
13
+ */
14
+ export declare function getStatusColor(status: string | number | PipelineStatus): string;
15
+ /**
16
+ * Get display label for a status.
17
+ * Utility pubblica utilizzabile nei componenti che mostrano lo status in italiano.
18
+ */
19
+ export declare function getStatusLabel(status: PipelineStatus): string;
@@ -0,0 +1,17 @@
1
+ import { Node, Edge } from '@xyflow/react';
2
+ import { EtlNodeData } from '../types';
3
+ /**
4
+ * Validate connection between two nodes
5
+ */
6
+ export declare function validateConnection(sourceId: string, targetId: string, edges: Edge[], nodes: Node<EtlNodeData>[], sourceHandle?: string | null, targetHandle?: string | null): {
7
+ isValid: boolean;
8
+ error?: string;
9
+ };
10
+ /**
11
+ * Validate pipeline before execution
12
+ */
13
+ export declare function validatePipeline(nodes: Node<EtlNodeData>[], edges: Edge[]): {
14
+ isValid: boolean;
15
+ errors: string[];
16
+ warnings: string[];
17
+ };
@@ -1,3 +1,2 @@
1
- import { EmbeddedModule, EmbeddedModuleNavigation } from "@fluxo-dev/api-client-base";
2
- export declare const workflowNavigation: EmbeddedModuleNavigation;
1
+ import { EmbeddedModule } from "@fluxo-dev/api-client-base";
3
2
  export declare const workflowModule: EmbeddedModule;
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import { ShellPageRef } from '@fluxo-dev/ui-components';
3
+ export interface WorkflowBrowseProps {
4
+ shellPageRef: React.RefObject<ShellPageRef>;
5
+ }
6
+ export declare function WorkflowBrowse({ shellPageRef }: WorkflowBrowseProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,8 @@
1
+ import React from 'react';
2
+ import { ShellPageRef } from '@fluxo-dev/ui-components';
3
+ export interface WorkflowExecutionsPanelProps {
4
+ workflowId: number;
5
+ workflowName: string;
6
+ shellPageRef: React.RefObject<ShellPageRef>;
7
+ }
8
+ export declare function WorkflowExecutionsPanel({ workflowId, workflowName, shellPageRef, }: WorkflowExecutionsPanelProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,16 @@
1
+ import React from 'react';
2
+ import { Node, Edge, OnNodesChange, OnEdgesChange, OnConnect, NodeTypes, EdgeTypes } from '@xyflow/react';
3
+ import '@xyflow/react/dist/style.css';
4
+ import { NodeData } from '../../types';
5
+ export interface FlowCanvasProps {
6
+ nodes: Node<NodeData>[];
7
+ edges: Edge[];
8
+ onNodesChange: OnNodesChange;
9
+ onEdgesChange: OnEdgesChange;
10
+ onConnect: OnConnect;
11
+ onNodeClick?: (event: React.MouseEvent, node: Node) => void;
12
+ nodeTypes: NodeTypes;
13
+ edgeTypes: EdgeTypes;
14
+ showConfigPanel?: boolean;
15
+ }
16
+ export declare const FlowCanvas: React.MemoExoticComponent<({ nodes, edges, onNodesChange, onEdgesChange, onConnect, onNodeClick, nodeTypes, edgeTypes, showConfigPanel, }: FlowCanvasProps) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ import { EdgeProps } from '@xyflow/react';
3
+ export declare const CustomEdge: React.MemoExoticComponent<({ id, sourceX, sourceY, targetX, targetY, sourcePosition, targetPosition, style, markerEnd, sourceHandleId, selected, data, }: EdgeProps) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ import { ActionInputDescriptor, ActionInput } from '@fluxo-dev/api-client-base';
3
+ export interface TriggerInputModalProps {
4
+ opened: boolean;
5
+ onClose: () => void;
6
+ triggerName: string;
7
+ inputs: ActionInputDescriptor[];
8
+ onStart: (inputValues: Record<string, ActionInput>) => void;
9
+ }
10
+ export declare const TriggerInputModal: React.MemoExoticComponent<({ opened, onClose, triggerName, inputs, onStart }: TriggerInputModalProps) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ import { NodeProps } from '@xyflow/react';
3
+ export declare const CustomNode: React.MemoExoticComponent<({ data, selected, id }: NodeProps) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { NodeTypeEnum, WorkflowActionCategoryDto, WorkflowActionDto, WorkflowTriggerCategoryDto, WorkflowTriggerDto } from '@fluxo-dev/api-client-base';
3
+ export interface ActionsPanelProps {
4
+ actions: WorkflowActionCategoryDto[];
5
+ triggers: WorkflowTriggerCategoryDto[];
6
+ onAddAction: (action: WorkflowActionDto) => void;
7
+ onAddTrigger: (trigger: WorkflowTriggerDto) => void;
8
+ onAddPrimitive: (primitiveType: NodeTypeEnum, label: string) => void;
9
+ loading?: boolean;
10
+ triggersLoading?: boolean;
11
+ }
12
+ export declare const ActionsPanel: React.MemoExoticComponent<({ actions, triggers, onAddAction, onAddTrigger, onAddPrimitive, triggersLoading }: ActionsPanelProps) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ export interface CollapsibleGroupProps {
3
+ id: string;
4
+ title: string;
5
+ description?: string;
6
+ defaultCollapsed?: boolean;
7
+ children: React.ReactNode;
8
+ }
9
+ /**
10
+ * Collapsible group component for organizing inputs
11
+ */
12
+ export declare const CollapsibleGroup: React.FC<CollapsibleGroupProps>;
@@ -0,0 +1,17 @@
1
+ import React from 'react';
2
+ import { ActionInputDescriptor, ActionInputTypeEnum } from '@fluxo-dev/api-client-base';
3
+ import { AvailableOutput } from '../../../types';
4
+ export interface ConditionalInputProps {
5
+ input: ActionInputDescriptor;
6
+ value: any;
7
+ inputType: ActionInputTypeEnum;
8
+ onChange: (value: any) => void;
9
+ onTypeChange: (type: ActionInputTypeEnum) => void;
10
+ availableOutputs: AvailableOutput[];
11
+ allInputValues: Record<string, any>;
12
+ isTrigger?: boolean;
13
+ }
14
+ /**
15
+ * Wrapper for InputField that handles conditional visibility, enabled state, and required state
16
+ */
17
+ export declare const ConditionalInput: React.FC<ConditionalInputProps>;
@@ -0,0 +1,19 @@
1
+ import React from 'react';
2
+ import { AvailableOutput } from '../../../types';
3
+ import './ExpressionEditor.module.css';
4
+ export interface ExpressionEditorProps {
5
+ value: string;
6
+ onChange: (value: string) => void;
7
+ availableOutputs?: AvailableOutput[];
8
+ placeholder?: string;
9
+ minHeight?: number;
10
+ disabled?: boolean;
11
+ }
12
+ /**
13
+ * Expression editor component with Monaco Editor
14
+ * Features:
15
+ * - Inline compact editor
16
+ * - Expandable modal for full-screen editing
17
+ * - Step output insertion helper
18
+ */
19
+ export declare const ExpressionEditor: React.MemoExoticComponent<({ value, onChange, availableOutputs, placeholder, minHeight, disabled, }: ExpressionEditorProps) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,26 @@
1
+ import React from 'react';
2
+ import { ActionInputTypeEnum, InputValidation } from '@fluxo-dev/api-client-base';
3
+ import { AvailableOutput } from '../../../types';
4
+ export interface InputFieldProps {
5
+ inputId: string;
6
+ inputName: string;
7
+ description?: string;
8
+ helpText?: string;
9
+ placeholder?: string;
10
+ required?: boolean;
11
+ disabled?: boolean;
12
+ inputType: ActionInputTypeEnum;
13
+ value: any;
14
+ onChange: (value: any) => void;
15
+ onTypeChange: (type: ActionInputTypeEnum) => void;
16
+ availableOutputs?: AvailableOutput[];
17
+ dataType?: string;
18
+ uiHint?: string;
19
+ isTrigger?: boolean;
20
+ validation?: InputValidation;
21
+ }
22
+ /**
23
+ * Input field component with type selector and appropriate editor
24
+ * Fixes the non-editable input issue from v1
25
+ */
26
+ export declare const InputField: React.MemoExoticComponent<({ inputId, inputName, description, helpText, placeholder, required, disabled, inputType, value, onChange, onTypeChange, availableOutputs, dataType, uiHint, isTrigger, validation, }: InputFieldProps) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ import { ActionInputTypeEnum, WorkflowActionDto } from '@fluxo-dev/api-client-base';
3
+ import { AvailableOutput } from '../../../types';
4
+ export interface InputsSectionProps {
5
+ actionDefinition: WorkflowActionDto;
6
+ onInputChange: (inputId: string, value: any, type: ActionInputTypeEnum) => void;
7
+ onInputTypeChange: (inputId: string, type: ActionInputTypeEnum) => void;
8
+ getInputValue: (inputId: string) => any;
9
+ getInputType: (inputId: string) => ActionInputTypeEnum;
10
+ availableOutputs: AvailableOutput[];
11
+ isTrigger?: boolean;
12
+ }
13
+ export declare const InputsSection: React.MemoExoticComponent<({ actionDefinition, onInputChange, onInputTypeChange, getInputValue, getInputType, availableOutputs, isTrigger, }: InputsSectionProps) => import("react/jsx-runtime").JSX.Element | null>;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { WorkflowActionCategoryDto, WorkflowTriggerCategoryDto } from '@fluxo-dev/api-client-base';
3
+ import { NodeData, AvailableOutput } from '../../../types';
4
+ export interface NodeConfigPanelProps {
5
+ nodeData: NodeData;
6
+ actions: WorkflowActionCategoryDto[];
7
+ triggers?: WorkflowTriggerCategoryDto[];
8
+ availableOutputs: AvailableOutput[];
9
+ onUpdateData: (data: Partial<NodeData>) => void;
10
+ onClose: () => void;
11
+ }
12
+ export declare const NodeConfigPanel: React.MemoExoticComponent<({ nodeData, actions, triggers, availableOutputs, onUpdateData, onClose, }: NodeConfigPanelProps) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ export interface OutcomesSectionProps {
3
+ outcomes: string[];
4
+ }
5
+ export declare const OutcomesSection: React.MemoExoticComponent<({ outcomes }: OutcomesSectionProps) => import("react/jsx-runtime").JSX.Element | null>;
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import { ActionOutputDescriptor } from '@fluxo-dev/api-client-base';
3
+ export interface OutputsSectionProps {
4
+ outputs: ActionOutputDescriptor[];
5
+ }
6
+ export declare const OutputsSection: React.MemoExoticComponent<({ outputs }: OutputsSectionProps) => import("react/jsx-runtime").JSX.Element | null>;
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ import { PrimitiveInput, NodeData } from '../../../types';
3
+ import { AvailableOutput } from '../../../types';
4
+ export interface PrimitiveInputsSectionProps {
5
+ inputs: PrimitiveInput[];
6
+ nodeData: NodeData;
7
+ onUpdateData: (data: Partial<NodeData>) => void;
8
+ availableOutputs: AvailableOutput[];
9
+ }
10
+ /**
11
+ * Section for primitive node inputs (While, ForEach, Decision, etc.)
12
+ */
13
+ export declare const PrimitiveInputsSection: React.MemoExoticComponent<({ inputs, nodeData, onUpdateData, availableOutputs, }: PrimitiveInputsSectionProps) => import("react/jsx-runtime").JSX.Element | null>;
@@ -0,0 +1,17 @@
1
+ import React from 'react';
2
+ export interface TypedValue {
3
+ dataType: 'integer' | 'decimal' | 'string' | 'boolean';
4
+ value: string | number | boolean;
5
+ }
6
+ export interface TypedValueEditorProps {
7
+ value: string | number | boolean | null;
8
+ onChange: (value: string | number | boolean) => void;
9
+ placeholder?: string;
10
+ disabled?: boolean;
11
+ }
12
+ /**
13
+ * Editor for typed values (int, decimal, string, boolean)
14
+ * Allows user to select a data type and then enter the value
15
+ * Saves ONLY the primitive value (not the TypedValue object)
16
+ */
17
+ export declare const TypedValueEditor: React.MemoExoticComponent<({ value, onChange, placeholder, disabled }: TypedValueEditorProps) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ export interface WorkflowToolbarProps {
3
+ workflowName: string;
4
+ workflowDescription?: string;
5
+ onSave: () => void;
6
+ onClose: () => void;
7
+ saving?: boolean;
8
+ }
9
+ export declare const WorkflowToolbar: React.MemoExoticComponent<({ workflowName, workflowDescription, onSave, onClose, saving }: WorkflowToolbarProps) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,3 @@
1
+ export * from './primitives';
2
+ export * from './styles';
3
+ export * from './triggers';
@@ -0,0 +1,27 @@
1
+ import { WorkflowPrimitive } from '../types';
2
+ /**
3
+ * Available workflow primitives (control flow nodes)
4
+ *
5
+ * NOTE: Parallel execution is NOT a node type!
6
+ * It's automatically created when multiple edges share the same source+sourceHandle.
7
+ * The backend detects this pattern and creates a Parallel construct automatically.
8
+ */
9
+ export declare const WORKFLOW_PRIMITIVES: WorkflowPrimitive[];
10
+ /**
11
+ * Get handles configuration for primitive nodes
12
+ *
13
+ * NOTE: Parallel is not included here - it's automatic based on edge connections
14
+ * NOTE: Join has a single 'default' target handle that can receive multiple edges from parallel branches
15
+ */
16
+ export declare const getPrimitiveHandles: (primitiveType: number) => {
17
+ source: string[];
18
+ target: string[];
19
+ };
20
+ /**
21
+ * Get input configuration for a primitive node
22
+ */
23
+ export declare const getPrimitiveInputs: (primitiveType: number) => import("../types").PrimitiveInput[];
24
+ /**
25
+ * Get primitive definition by type
26
+ */
27
+ export declare const getPrimitiveByType: (primitiveType: number) => WorkflowPrimitive | undefined;
@@ -0,0 +1,61 @@
1
+ /**
2
+ * Color scheme for workflow designer (Attio style)
3
+ */
4
+ export declare const COLORS: {
5
+ node: {
6
+ background: string;
7
+ border: string;
8
+ borderSelected: string;
9
+ shadow: string;
10
+ shadowSelected: string;
11
+ };
12
+ handle: {
13
+ default: string;
14
+ success: string;
15
+ fail: string;
16
+ error: string;
17
+ timeout: string;
18
+ warning: string;
19
+ true: string;
20
+ false: string;
21
+ neutral: string;
22
+ };
23
+ text: {
24
+ primary: string;
25
+ secondary: string;
26
+ tertiary: string;
27
+ };
28
+ background: {
29
+ canvas: string;
30
+ panel: string;
31
+ hover: string;
32
+ };
33
+ border: {
34
+ light: string;
35
+ default: string;
36
+ dark: string;
37
+ };
38
+ status: {
39
+ start: string;
40
+ end: string;
41
+ configured: string;
42
+ };
43
+ };
44
+ /**
45
+ * Spacing constants
46
+ */
47
+ export declare const SPACING: {
48
+ xs: number;
49
+ sm: number;
50
+ md: number;
51
+ lg: number;
52
+ xl: number;
53
+ };
54
+ /**
55
+ * Border radius
56
+ */
57
+ export declare const RADIUS: {
58
+ sm: number;
59
+ md: number;
60
+ lg: number;
61
+ };
@@ -0,0 +1,10 @@
1
+ import { WorkflowTriggerDto } from '@fluxo-dev/api-client-base';
2
+ /**
3
+ * Built-in Manual Trigger
4
+ * This is the default trigger that allows manual workflow execution
5
+ */
6
+ export declare const MANUAL_TRIGGER: WorkflowTriggerDto;
7
+ /**
8
+ * Get icon name for a trigger based on its category or type
9
+ */
10
+ export declare const getTriggerIcon: (trigger: WorkflowTriggerDto) => string;
@@ -0,0 +1,22 @@
1
+ /**
2
+ * UI Hints for Action Inputs
3
+ * These constants match the backend ActionInputUIHints class
4
+ */
5
+ export declare const ActionInputUIHints: {
6
+ readonly SingleLine: "single-line";
7
+ readonly MultiLine: "multi-line";
8
+ readonly Checkbox: "checkbox";
9
+ readonly CheckList: "check-list";
10
+ readonly RadioList: "radio-list";
11
+ readonly Dropdown: "dropdown";
12
+ readonly MultiText: "multi-text";
13
+ readonly CodeEditor: "code-editor";
14
+ readonly Dictionary: "dictionary";
15
+ readonly Integer: "integer";
16
+ readonly Decimal: "decimal";
17
+ readonly Lookup: "lookup";
18
+ readonly Json: "json";
19
+ readonly TypedValue: "typed-value";
20
+ readonly Number: "number";
21
+ };
22
+ export type ActionInputUIHint = typeof ActionInputUIHints[keyof typeof ActionInputUIHints];
@@ -0,0 +1,9 @@
1
+ export * from './useNodeInputs';
2
+ export * from './useAvailableOutputs';
3
+ export * from './useActionDefinitions';
4
+ export * from './useTriggerDefinitions';
5
+ export * from './useNodeOperations';
6
+ export * from './useWorkflowState';
7
+ export * from './useWorkflowActions';
8
+ export * from './useInputValidation';
9
+ export * from './useInputDependencies';
@@ -0,0 +1,11 @@
1
+ import { WorkflowActionCategoryDto } from '@fluxo-dev/api-client-base';
2
+ export interface UseActionDefinitionsReturn {
3
+ actions: WorkflowActionCategoryDto[];
4
+ loading: boolean;
5
+ error: Error | null;
6
+ reload: () => Promise<void>;
7
+ }
8
+ /**
9
+ * Hook to load and manage action definitions from API
10
+ */
11
+ export declare const useActionDefinitions: () => UseActionDefinitionsReturn;
@@ -0,0 +1,14 @@
1
+ import { Node, Edge } from '@xyflow/react';
2
+ import { NodeData, AvailableOutput } from '../types';
3
+ import { WorkflowActionCategoryDto, WorkflowTriggerCategoryDto } from '@fluxo-dev/api-client-base';
4
+ /**
5
+ * Hook to get available outputs from predecessor nodes (ancestors in the graph)
6
+ *
7
+ * Returns outputs from:
8
+ * 1. Action definitions (from backend WorkflowActionDto)
9
+ * 2. Trigger definitions (from backend WorkflowTriggerDto)
10
+ * 3. Custom outputs configured by user
11
+ *
12
+ * Navigates recursively through all ancestors, not just direct predecessors
13
+ */
14
+ export declare const useAvailableOutputs: (nodes: Node<NodeData>[], edges: Edge[], actionCategories: WorkflowActionCategoryDto[], triggerCategories?: WorkflowTriggerCategoryDto[]) => (nodeId: string, filterType?: string) => AvailableOutput[];
@@ -0,0 +1,9 @@
1
+ import type { ActionInputDescriptor } from '@fluxo-dev/api-client-base';
2
+ /**
3
+ * Hook to evaluate input dependencies and determine visibility, enabled state, and required state
4
+ */
5
+ export declare function useInputDependencies(input: ActionInputDescriptor, allValues: Record<string, any>): {
6
+ isVisible: boolean;
7
+ isEnabled: boolean;
8
+ isRequired: boolean;
9
+ };
@@ -0,0 +1,9 @@
1
+ import { ActionInputDescriptor } from '@fluxo-dev/api-client-base';
2
+ /**
3
+ * Hook to validate input value based on validation rules
4
+ */
5
+ export declare function useInputValidation(input: ActionInputDescriptor | null, value: any): {
6
+ validate: () => string | null;
7
+ error: string | null;
8
+ isValid: boolean;
9
+ };
@@ -0,0 +1,18 @@
1
+ import { ActionInput, ActionInputTypeEnum } from '@fluxo-dev/api-client-base';
2
+ import { NodeData } from '../types';
3
+ export interface UseNodeInputsProps {
4
+ nodeData: NodeData;
5
+ onUpdate: (data: Partial<NodeData>) => void;
6
+ }
7
+ export interface UseNodeInputsReturn {
8
+ inputs: Record<string, ActionInput>;
9
+ handleInputChange: (inputId: string, value: any, type: ActionInputTypeEnum) => void;
10
+ handleInputTypeChange: (inputId: string, type: ActionInputTypeEnum) => void;
11
+ getInputValue: (inputId: string) => any;
12
+ getInputType: (inputId: string) => ActionInputTypeEnum;
13
+ }
14
+ /**
15
+ * Hook for managing node inputs with proper typing and debouncing
16
+ * Solves the issue of non-editable inputs in v1
17
+ */
18
+ export declare const useNodeInputs: ({ nodeData, onUpdate, }: UseNodeInputsProps) => UseNodeInputsReturn;
@@ -0,0 +1,15 @@
1
+ import { Node } from '@xyflow/react';
2
+ import { NodeTypeEnum, WorkflowActionDto, WorkflowTriggerDto } from '@fluxo-dev/api-client-base';
3
+ import { NodeData } from '../types';
4
+ export interface UseNodeOperationsReturn {
5
+ addActionNode: (action: WorkflowActionDto) => void;
6
+ addPrimitiveNode: (primitiveType: NodeTypeEnum, label: string) => void;
7
+ addTriggerNode: (trigger: WorkflowTriggerDto) => void;
8
+ addStartNode: () => void;
9
+ updateNodeData: (nodeId: string, data: Partial<NodeData>) => void;
10
+ deleteNode: (nodeId: string) => void;
11
+ }
12
+ /**
13
+ * Hook for node operations (add, update, delete)
14
+ */
15
+ export declare const useNodeOperations: (nodes: Node<NodeData>[], setNodes: React.Dispatch<React.SetStateAction<Node<NodeData>[]>>, workflowId?: number) => UseNodeOperationsReturn;
@@ -0,0 +1,11 @@
1
+ import { WorkflowTriggerCategoryDto } from '@fluxo-dev/api-client-base';
2
+ export interface UseTriggerDefinitionsReturn {
3
+ triggers: WorkflowTriggerCategoryDto[];
4
+ loading: boolean;
5
+ error: Error | null;
6
+ }
7
+ /**
8
+ * Hook to load available trigger definitions from backend
9
+ * Includes built-in Manual trigger
10
+ */
11
+ export declare const useTriggerDefinitions: () => UseTriggerDefinitionsReturn;
@@ -0,0 +1,15 @@
1
+ import { Node, Edge } from '@xyflow/react';
2
+ import { NodeData, WorkflowMetadata } from '../types';
3
+ export interface UseWorkflowActionsReturn {
4
+ saveWorkflow: (data: {
5
+ nodes: Node<NodeData>[];
6
+ edges: Edge[];
7
+ metadata: WorkflowMetadata;
8
+ }) => Promise<boolean>;
9
+ loading: boolean;
10
+ error: Error | null;
11
+ }
12
+ /**
13
+ * Hook for workflow actions (save, validate)
14
+ */
15
+ export declare const useWorkflowActions: (workflowId?: number) => UseWorkflowActionsReturn;
@@ -0,0 +1,17 @@
1
+ import { Node, Edge } from '@xyflow/react';
2
+ import { WorkflowTriggerCategoryDto } from '@fluxo-dev/api-client-base';
3
+ import { NodeData, WorkflowMetadata } from '../types';
4
+ export interface UseWorkflowStateReturn {
5
+ nodes: Node<NodeData>[];
6
+ edges: Edge[];
7
+ metadata: WorkflowMetadata | null;
8
+ setNodes: React.Dispatch<React.SetStateAction<Node<NodeData>[]>>;
9
+ setEdges: React.Dispatch<React.SetStateAction<Edge[]>>;
10
+ onNodesChange: any;
11
+ onEdgesChange: any;
12
+ }
13
+ /**
14
+ * Hook to manage workflow state (nodes and edges)
15
+ * Loads workflow from backend if workflowId is provided
16
+ */
17
+ export declare const useWorkflowState: (workflowId?: number, triggers?: WorkflowTriggerCategoryDto[]) => UseWorkflowStateReturn;
@@ -0,0 +1,2 @@
1
+ export { WorkflowDesignerV2 } from './workflow-designer-v2';
2
+ export type { WorkflowDesignerV2Props } from './workflow-designer-v2';
@@ -0,0 +1,6 @@
1
+ export * from './node-data.types';
2
+ export * from './workflow-state.types';
3
+ export * from './input-config.types';
4
+ export * from './input-group.types';
5
+ export * from './input-validation.types';
6
+ export * from './input-dependency.types';
@@ -0,0 +1,32 @@
1
+ import { ActionInputTypeEnum } from '@fluxo-dev/api-client-base';
2
+ import { AvailableOutput } from './node-data.types';
3
+ /**
4
+ * Input configuration with type selection
5
+ */
6
+ export interface InputConfig {
7
+ inputType: ActionInputTypeEnum;
8
+ value: any;
9
+ }
10
+ /**
11
+ * Props for input type selector
12
+ */
13
+ export interface InputTypeSelectorProps {
14
+ currentType: ActionInputTypeEnum;
15
+ onTypeChange: (type: ActionInputTypeEnum) => void;
16
+ }
17
+ /**
18
+ * Props for input value editor based on type
19
+ */
20
+ export interface InputValueEditorProps {
21
+ inputType: ActionInputTypeEnum;
22
+ value: any;
23
+ onChange: (value: any) => void;
24
+ availableOutputs?: AvailableOutput[];
25
+ inputDescriptor: {
26
+ id: string;
27
+ name: string;
28
+ description?: string;
29
+ type: string;
30
+ required: boolean;
31
+ };
32
+ }
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Input dependency for conditional visibility/enabled/required
3
+ */
4
+ export interface InputDependency {
5
+ dependsOn: string;
6
+ operator: DependencyOperator;
7
+ value?: any;
8
+ action: DependencyAction;
9
+ }
10
+ /**
11
+ * Dependency operators for condition evaluation
12
+ */
13
+ export type DependencyOperator = 'equals' | 'notEquals' | 'in' | 'notIn' | 'greaterThan' | 'lessThan' | 'greaterThanOrEqual' | 'lessThanOrEqual' | 'isNotEmpty' | 'isEmpty';
14
+ /**
15
+ * Dependency actions (what happens when condition is true)
16
+ */
17
+ export type DependencyAction = 'visible' | 'enabled' | 'required';
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Input group for organizing inputs in sections
3
+ */
4
+ export interface InputGroup {
5
+ id: string;
6
+ displayName: string;
7
+ order: number;
8
+ collapsed: boolean;
9
+ description?: string;
10
+ }