fix (note_map): map overflows when switching map type in ribbon

This commit is contained in:
SiriusXT 2025-12-05 11:21:33 +08:00
parent b8585594cd
commit eec6f7336c

View File

@ -101,7 +101,7 @@ export default function NoteMap({ note, widgetMode, parentRef }: NoteMapProps) {
useEffect(() => {
if (!containerSize || !graphRef.current) return;
graphRef.current.width(containerSize.width).height(containerSize.height);
}, [ containerSize?.width, containerSize?.height ]);
}, [ containerSize?.width, containerSize?.height, mapType ]);
// Fixing nodes when dragged.
useEffect(() => {