From 662baa3df218ca1766d4d6ea1c41930c481aff6a Mon Sep 17 00:00:00 2001 From: Ryan Di Date: Fri, 25 Apr 2025 21:44:58 +1000 Subject: [PATCH] set roudness to null to fix drag points offset for elbows --- packages/excalidraw/components/ShapeSwitch.tsx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/packages/excalidraw/components/ShapeSwitch.tsx b/packages/excalidraw/components/ShapeSwitch.tsx index 4ae2b7f5d..e8da4955c 100644 --- a/packages/excalidraw/components/ShapeSwitch.tsx +++ b/packages/excalidraw/components/ShapeSwitch.tsx @@ -608,7 +608,9 @@ export const switchShapes = ( fixedSegments, }, ); - mutateElement(element, app.scene.getNonDeletedElementsMap(), updates); + mutateElement(element, app.scene.getNonDeletedElementsMap(), { + ...updates, + }); } } } @@ -776,7 +778,7 @@ const getElbowArrowProperties = ( endArrowhead: element.endArrowhead, startBinding: element.startBinding, endBinding: element.endBinding, - roundness: element.roundness, + roundness: null, fixedSegments: element.fixedSegments, startIsSpecial: element.startIsSpecial, endIsSpecial: element.endIsSpecial, @@ -1061,6 +1063,7 @@ export const convertElementType = < type: "arrow", elbowed: true, fixedSegments: null, + roundness: null, }); return bumpVersion(nextElement);