mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-09-02 07:07:06 +02:00
Regenerate roughjs shape only when the item is updated (#316)
* Regenerate roughjs shape only when the item is updated * Remove shape object during export and history undo/redo * Remove shape element during copying * Fix shape generation during creation
This commit is contained in:

committed by
Christopher Chedeau

parent
1bf18fe4ed
commit
74764b06eb
@@ -7,7 +7,10 @@ class SceneHistory {
|
||||
|
||||
generateCurrentEntry(elements: readonly ExcalidrawElement[]) {
|
||||
return JSON.stringify(
|
||||
elements.map(element => ({ ...element, isSelected: false }))
|
||||
elements.map(({ shape, ...element }) => ({
|
||||
...element,
|
||||
isSelected: false
|
||||
}))
|
||||
);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user