-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Closed
Labels
issue: feature requestDescribes a new feature and why it should be addedDescribes a new feature and why it should be added
Description
Check for duplicates
- I have searched for similar issues before opening a new one.
Problem
Currently, the location of block comments in the workspace are not preserved/restored when (de)serializing them, unlike workspace comments.
Request
To do this, we should:
- Extend
ICommentIconand its implementation withsetBubbleLocation(location: Coordinate): voidandgetBubbleLocation(): Coordinatemethods. - Update
blockToDom()to callgetBubbleLocation()and persist the coordinate underxandyattributes in the block comment XML, and updateapplyCommentTagNodes()to move the comment to the specified location when deserializing. I realize we're not adding new functionality to XML serialization in general, but this particular change makes work on upgrading Scratch easier and is quite small/contained. - Update
saveState()andloadState()inCommentIconto persist and restore the comment coordinates when using JSON serialization. - Update the tests to exercise moving the comment and (de)serialization
Alternatives considered
No response
Additional context
No response
Metadata
Metadata
Assignees
Labels
issue: feature requestDescribes a new feature and why it should be addedDescribes a new feature and why it should be added