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

Ensure animations are flushed when ApplicationRef.tick happens #55132

Closed
wants to merge 2 commits into from

Conversation

atscott
Copy link
Contributor

@atscott atscott commented Mar 29, 2024

Commit 1

fix(core): Ensure DOM removal happens when no app views need refresh

This change ensures that ApplicationRef.tick flushes animations by
calling rendererFactory2.end. This might not have happened before if
there were no views that needed to be refreshed.

This is also likely to fix a potential regression caused by #53718 even
in zone apps where animations don't get flushed when no views attached
to ApplicationRef are dirty.

Commit 2

fix(animations): Ensure async animations applies changes when loaded in zoneless

Async animations currently works in Zones because the render factory
promise resolve causes change detection to happen.

fixes #54919

@atscott atscott added the target: minor This PR is targeted for the next minor release label Mar 29, 2024
@pullapprove pullapprove bot requested a review from crisbeto March 29, 2024 23:14
@atscott atscott added area: animations area: core Issues related to the framework runtime labels Mar 29, 2024
@ngbot ngbot bot modified the milestone: Backlog Mar 29, 2024
@atscott atscott requested review from JeanMeche and alxhub and removed request for crisbeto March 29, 2024 23:15
Copy link
Member

@JeanMeche JeanMeche left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The change for async animations lgtm.

@atscott atscott force-pushed the animationsscheduler branch 6 times, most recently from ae49578 to b4036d9 Compare April 12, 2024 15:34
@atscott atscott force-pushed the animationsscheduler branch 4 times, most recently from 50579e0 to 1d6c438 Compare April 18, 2024 21:18
@atscott atscott added the action: merge The PR is ready for merge by the caretaker label Apr 18, 2024
…resh

This change ensures that `ApplicationRef.tick` flushes animations by
calling `rendererFactory2.end`. This might not have happened before if
there were no views that needed to be refreshed.

This is also likely to fix a potential regression caused by angular#53718 even
in zone apps where animations don't get flushed when no views attached
to ApplicationRef are dirty.
@atscott atscott added the merge: caretaker note Alert the caretaker performing the merge to check the PR for an out of normal action needed or note label Apr 23, 2024
@atscott
Copy link
Contributor Author

atscott commented Apr 23, 2024

merge assistance: Please help get this green and/or merge with pending reviews

@alxhub alxhub self-assigned this Apr 23, 2024
@atscott atscott removed action: merge The PR is ready for merge by the caretaker merge: caretaker note Alert the caretaker performing the merge to check the PR for an out of normal action needed or note labels Apr 23, 2024
…aded in zoneless

Async animations currently works in Zones because the render factory
promise resolve causes change detection to happen.

fixes angular#54919
@atscott atscott added the action: merge The PR is ready for merge by the caretaker label Apr 24, 2024
@AndrewKushnir
Copy link
Contributor

This PR was merged into the repository by commit 9ab36cf.

AndrewKushnir pushed a commit that referenced this pull request Apr 24, 2024
…aded in zoneless (#55132)

Async animations currently works in Zones because the render factory
promise resolve causes change detection to happen.

fixes #54919

PR Close #55132
AndrewKushnir added a commit to AndrewKushnir/angular that referenced this pull request Apr 24, 2024
AndrewKushnir added a commit to AndrewKushnir/angular that referenced this pull request Apr 24, 2024
atscott added a commit to atscott/angular that referenced this pull request Apr 24, 2024
atscott added a commit to atscott/angular that referenced this pull request Apr 24, 2024
AndrewKushnir added a commit that referenced this pull request Apr 24, 2024
… when loaded in zoneless (#55132)" (#55524)

This reverts commit 9ab36cf.

PR Close #55524
AndrewKushnir added a commit that referenced this pull request Apr 24, 2024
atscott added a commit to atscott/angular that referenced this pull request Apr 26, 2024
atscott added a commit to atscott/angular that referenced this pull request Apr 26, 2024
…resh (angular#55132)

This reverts commit e3d5607 - reapplies
original changes.
atscott added a commit to atscott/angular that referenced this pull request Apr 26, 2024
…resh (angular#55132)

This reverts commit e3d5607 - reapplies
original changes.
atscott added a commit to atscott/angular that referenced this pull request Apr 26, 2024
…resh (angular#55132)

This reverts commit e3d5607 - reapplies
original changes.
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators May 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker area: animations area: core Issues related to the framework runtime target: minor This PR is targeted for the next minor release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Animation not initialized when using ZonelessChangeDetection
4 participants