feat: Added global warning for incomplete program chain

ref: N25B-450
This commit is contained in:
JGerla
2026-01-20 11:53:51 +01:00
parent 23a02b2b4a
commit 5d55ebaaa2
4 changed files with 47 additions and 6 deletions

View File

@@ -9,7 +9,7 @@ import {
type XYPosition,
} from '@xyflow/react';
import '@xyflow/react/dist/style.css';
import { editorWarningRegistry } from "./components/EditorWarnings.tsx";
import {editorWarningRegistry} from "./components/EditorWarnings.tsx";
import type { FlowState } from './VisProgTypes';
import {
NodeDefaults,
@@ -50,7 +50,7 @@ function createNode(id: string, type: string, position: XYPosition, data: Record
const endNode = createNode('end', 'end', {x: 590, y: 100}, {label: "End"}, false)
const initialPhaseNode = createNode(crypto.randomUUID(), 'phase', {x:235, y:100}, {label: "Phase 1", children : [], isFirstPhase: false, nextPhaseId: null})
const initialNodes : Node[] = [startNode, endNode, initialPhaseNode,];
const initialNodes : Node[] = [startNode, endNode, initialPhaseNode];
// Initial edges, leave empty as setting initial edges...
// ...breaks logic that is dependent on connection events
@@ -312,4 +312,7 @@ const useFlowStore = create<FlowState>(UndoRedo((set, get) => ({
}))
);
export default useFlowStore;