Skip to content
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

Give Sprites Comment Attribute and allow comment duplication #5111

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

Victor-Crawshaw
Copy link

@Victor-Crawshaw Victor-Crawshaw commented Dec 7, 2024

Resolves

Resolves scratchfoundation/scratch-gui#3687

Proposed Changes

Create comment attribute in Sprite, and modify duplicate() method to copy over that comment attribute. Targets now take comments as an argument so that they may be copied over in Rendered Target as well.

Duplicate.Comments.Demo.mp4

Reason for Changes

Comments should be an attribute in Sprite because if comments want to be duplicated when sprites are duplicated, then it would make sense for them to be part of a sprite, rather than merely part of a target,

Test Coverage

Added unit tests in test/unit/sprites_rendered-target.js to ensure comments are duplicated along with a sprite, also made sure all other tests still pass.
image

Copy link

github-actions bot commented Dec 7, 2024

All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.

@John-Crawshaw
Copy link

I have read the CLA Document and I hereby sign the CLA

@John-Crawshaw
Copy link

recheck

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Duplicated sprites lose their comments
2 participants