Fix elbow arrow

This commit is contained in:
Mark Tolmacs 2025-07-27 12:09:58 +02:00
parent 9111fda080
commit 027a74acfc
No known key found for this signature in database
2 changed files with 25 additions and 18 deletions

View File

@ -474,7 +474,14 @@ export const getBindingStrategyForDraggingBindingElementEndpoints = (
appState.zoom,
);
return {
return isElbowArrow(arrow)
? {
start: hovered
? { element: hovered, mode: "orbit" }
: { mode: undefined },
end: { mode: undefined },
}
: {
start: hovered
? hit
? { element: hovered, mode: "inside" }

View File

@ -8077,7 +8077,7 @@ class App extends React.Component<AppProps, AppState> {
}
this.scene.mutateElement(element, {
points: [...element.points, pointFrom<LocalPoint>(0, 0)],
points: [pointFrom<LocalPoint>(0, 0), pointFrom<LocalPoint>(0, 0)],
});
this.scene.insertElement(element);
if (isBindingElement(element)) {