From 58b14ae31ccc34895c25047a5fb9ef6fc7afb697 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Sun, 21 Sep 2025 10:32:01 +0300 Subject: [PATCH] fix(react/type_widget): mind map attachment incorrect --- apps/client/src/widgets/type_widgets/MindMap.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/client/src/widgets/type_widgets/MindMap.tsx b/apps/client/src/widgets/type_widgets/MindMap.tsx index ffe4d8aa8..611dffbc0 100644 --- a/apps/client/src/widgets/type_widgets/MindMap.tsx +++ b/apps/client/src/widgets/type_widgets/MindMap.tsx @@ -26,7 +26,7 @@ export default function MindMap({ note, ntxId }: TypeWidgetProps) { const containerRef = useRef(null); const spacedUpdate = useEditorSpacedUpdate({ note, - getData: () => { + getData: async () => { if (!apiRef.current) return; return { content: apiRef.current.getDataString(), @@ -35,7 +35,7 @@ export default function MindMap({ note, ntxId }: TypeWidgetProps) { role: "image", title: "mindmap-export.svg", mime: "image/svg+xml", - content: apiRef.current.exportSvg().text(), + content: await apiRef.current.exportSvg().text(), position: 0 } ]