Refactor DiagramEditor for modularity and enhanced link handling: See merge request pratyush/simple-workflow-editor!16