Restore previous position in set-path-point-position-command

This commit is contained in:
2026-04-13 22:32:33 +02:00
parent 59f2d78125
commit 05d8f75cb4

View File

@@ -99,6 +99,8 @@ export function createSetPathPointPositionCommand(
return;
}
const restoredPosition = cloneVec3(previousPosition);
const currentDocument = context.getDocument();
const path = currentDocument.paths[options.pathId];
@@ -122,7 +124,7 @@ export function createSetPathPointPositionCommand(
index === pointIndex
? {
...point,
position: cloneVec3(previousPosition)
position: cloneVec3(restoredPosition)
}
: point
)