Skip to content

fix(datepicker): wait for exit animation to finish before detaching content #12440

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

Closed

Conversation

crisbeto
Copy link
Member

This is something I ran into while working on aligning the datepicker with the most-recent Material design spec. Since #9639 we use a portal outlet to render the calendar header. The portal outlet directive will detach in ngOnDestroy and it won't wait for the parent animation to finish, which ends up shifting the entire calendar up while it's animating away. The only reason that this isn't visible at the moment is because the current animation isn't configured correctly, which causes it to go to opacity: 0 immediately.

For reference:
demo

@crisbeto crisbeto added the target: patch This PR is targeted for the next patch release label Jul 30, 2018
@crisbeto crisbeto requested a review from mmalerba as a code owner July 30, 2018 19:48
@googlebot googlebot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Jul 30, 2018
@mmalerba mmalerba added pr: lgtm action: merge The PR is ready for merge by the caretaker labels Jul 30, 2018
Copy link
Contributor

@mmalerba mmalerba left a comment

Choose a reason for hiding this comment

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

I suspect we might have to bump this to a minor or major change, but lets see what happens when we presubmit

@mmalerba mmalerba 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 Jul 30, 2018
@crisbeto crisbeto force-pushed the datepicker-animation-element-destroy branch 3 times, most recently from 399b6b3 to e11fa08 Compare October 2, 2018 18:16
@crisbeto crisbeto force-pushed the datepicker-animation-element-destroy branch from e11fa08 to 79f79ce Compare December 13, 2018 17:40
@crisbeto crisbeto force-pushed the datepicker-animation-element-destroy branch from 79f79ce to 37559cc Compare January 2, 2019 11:10
@mmalerba mmalerba added aaa and removed aaa labels Apr 25, 2019
@crisbeto crisbeto force-pushed the datepicker-animation-element-destroy branch from 37559cc to beea098 Compare May 30, 2019 06:24
…ontent

This is something I ran into while working on aligning the datepicker with the most-recent Material design spec. Since angular#9639 we use a portal outlet to render the calendar header. The portal outlet directive will detach in `ngOnDestroy` and it won't wait for the parent animation to finish, which ends up shifting the entire calendar up while it's animating away. The only reason that this isn't visible at the moment is because the current animation isn't configured correctly, which causes it to go to `opacity: 0` immediately.
@crisbeto crisbeto force-pushed the datepicker-animation-element-destroy branch from beea098 to bace7f9 Compare May 30, 2019 06:30
@mmalerba mmalerba removed their assignment Aug 12, 2019
@mmalerba mmalerba removed the lgtm label Jul 31, 2020
@andrewseguin andrewseguin added needs rebase and removed cla: yes PR author has agreed to Google's Contributor License Agreement labels Dec 29, 2021
@crisbeto
Copy link
Member Author

I went back to rebase this, but I think that the issue was addressed as a part of the refactor in 7039d3e.

@crisbeto crisbeto closed this Mar 25, 2022
@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 Apr 25, 2022
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 merge: caretaker note Alert the caretaker performing the merge to check the PR for an out of normal action needed or note target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants