feat: node creation and serialization logic in workflow editor

This commit is contained in:
alam00000 committed 2026-02-26 20:28:16 +05:30
1 parent 88260c26ab
commit 85d90c3382
5 files changed
+230 -174

No files matched your search

+3 -1
View File
@@ -593,7 +593,9 @@ export const nodeRegistry: Record<string, NodeRegistryEntry> = {
export function createNodeByType(type: string): BaseWorkflowNode | null {
const entry = nodeRegistry[type];
if (!entry) return null;
return entry.factory();
const node = entry.factory();
node.nodeType = type;
return node;
}
export function getNodesByCategory(): Record<