mirror of
https://github.com/DayuanJiang/next-ai-draw-io.git
synced 2026-01-03 06:42:27 +08:00
- Add extractCompleteMxCells() to extract only complete mxCell elements from partial XML - Remove useEffect cleanup that was killing debounce timeouts on every re-render - Wrap XML in <root> tags for proper DOMParser validation Previously, diagrams only rendered after ALL XML finished streaming because: 1. useEffect cleanup cleared the 150ms debounce timeout on every message change 2. DOMParser rejected partial XML like '<mxCell id="2" value="...' (incomplete) Now each complete mxCell renders progressively as it finishes streaming.