-
Notifications
You must be signed in to change notification settings - Fork 179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Group Layers: Editor crashed when using keyboard shortcut while layers menu is open #13479
Comments
Good find! Thanks for the super detailed report, I was able to reproduce this at first try. Looks like this is where the crash happens:
|
@swissspidy When user perform undo operation, in context of this issue (GroupLayer) - web-stories-wp/packages/story-editor/src/components/panels/layer/useLayers.js Lines 29 to 35 in a3c73c2
But, when we perform We may need to update story state somehow in the below functions - which will trigger updating of story state and solves this issue:
web-stories-wp/packages/story-editor/src/app/rightClickMenu/hooks/useElementActions.js Line 66 in cd9b8fe
|
I'm afraid that's not possible. The whole history provider is explicitly 100% decoupled from story provider and doesn't really know about it. So we'd need to find another way for this. What makes the final story state be different when pressing undo? Can we simply add some safeguards to the relevant components to avoid throwing errors? When I briefly looked at it last time, I was wondering if it had anything to do with how |
Bug Description
Editor crashes when the layers menu is open, apply group layers on elements, and keying CMD+Z
Crash Report
Expected Behaviour
Editor does not crash.
Steps to Reproduce
Screenshots
Screen.Recording.2023-10-18.at.10.18.42.AM.mov
Additional Context
The text was updated successfully, but these errors were encountered: