mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-04-14 16:40:58 -04:00
use commitToHistory prop for handling draw history (#1595)
This commit is contained in:
parent
d9b8dcfbb4
commit
828c9c4d65
2 changed files with 1 additions and 2 deletions
|
@ -89,7 +89,7 @@ export const actionFinalize = register({
|
||||||
}
|
}
|
||||||
: appState.selectedElementIds,
|
: appState.selectedElementIds,
|
||||||
},
|
},
|
||||||
commitToHistory: false,
|
commitToHistory: appState.elementType === "draw",
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
keyTest: (event, appState) =>
|
keyTest: (event, appState) =>
|
||||||
|
|
|
@ -2340,7 +2340,6 @@ class App extends React.Component<any, AppState> {
|
||||||
|
|
||||||
if (draggingElement?.type === "draw") {
|
if (draggingElement?.type === "draw") {
|
||||||
this.actionManager.executeAction(actionFinalize);
|
this.actionManager.executeAction(actionFinalize);
|
||||||
history.resumeRecording();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (isLinearElement(draggingElement)) {
|
if (isLinearElement(draggingElement)) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue