mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
Reset selectedElementIds when deleting selected elements (#875)
This commit is contained in:
parent
ccbbdb75a6
commit
c89584832d
3 changed files with 23 additions and 5 deletions
|
@ -34,7 +34,13 @@ export function deleteSelectedElements(
|
|||
elements: readonly ExcalidrawElement[],
|
||||
appState: AppState,
|
||||
) {
|
||||
return elements.filter(el => !appState.selectedElementIds[el.id]);
|
||||
return {
|
||||
elements: elements.filter(el => !appState.selectedElementIds[el.id]),
|
||||
appState: {
|
||||
...appState,
|
||||
selectedElementIds: {},
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
export function getSelectedIndices(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue