-
-
Notifications
You must be signed in to change notification settings - Fork 4.9k
fix: render layer detachment when destroying. #11384
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Your PR title doesn't match the required format. The title should be in this format:
chore: update Text docs
fix: text not rendering
feat: add new feature to Text
breaking: remove Text#resolution
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This pull request fixes an issue where destroying a container did not remove its children from their render layers. The changes include detaching a child from its render layer in the helper mixin before emitting the removal event and adding tests for verifying both the container and render layer behavior upon destruction.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
File | Description |
---|---|
src/scene/container/container-mixins/childrenHelperMixin.ts | Added a conditional render layer detachment call before re-emitting the 'childRemoved' event. |
src/scene/container/tests/Container.test.ts | Added tests to confirm that children are detached from their render layers and destroyed appropriately. |
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit 5a1951b:
|
Co-authored-by: Matt Karl <matt@mattkarl.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Your PR title doesn't match the required format. The title should be in this format:
chore: update Text docs
fix: text not rendering
feat: add new feature to Text
breaking: remove Text#resolution
Description of change
Fix issue where when destroying a container - the children were not being removed from the render layers.
Added test too.
fixes #11373
Pre-Merge Checklist
npm run lint
)npm run test
)