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

ReactCSSTransitionGroup delayed animation #5575

Closed
LKay opened this issue Dec 1, 2015 · 5 comments
Closed

ReactCSSTransitionGroup delayed animation #5575

LKay opened this issue Dec 1, 2015 · 5 comments

Comments

@LKay
Copy link

LKay commented Dec 1, 2015

I have something similar to this to handle sliding up-down content (kind of accordion like behaviour).

<ReactCSSTransitionGroup 
  transitionName="slide"
  transitionEnterTimeout={ TRANSITION_TIMEOUT }
  transitionLeaveTimeout={ TRANSITION_TIMEOUT }
  component="div">
  { expanded && children }
</ReactCSSTransitionGroup>

It works fine, when there was no content and children are being mounted. The problem occurs when there were some nodes than need to be hidden and replaced by false value. In that case it seems that onEnter animation is fired for empty node before executing onLeave animation for previous children node making leaving animation delayed by the time of enter animation for empty node. This shouldn't be happening, I think. Empty node shouldn't be animated when entering DOM or onEnter and onLeave animation should be triggered simultaneously.

I'm using react-addons-css-transition-group in version 0.14.3.

@pnuzhdin
Copy link

There are bad news that animation still unstable in the latest React. I wonder does Facebook use animation in it's own products? Anyway I guess following PR #5028 could fix this issue and it could improve stability of the animation moreover.

@sbialobok
Copy link

I'm running into a similar issue where all my onleave calls are delayed by the onEnter animation time. . I'm on v 0.14.7 of react-addons-css-transition-group

@gaearon
Copy link
Collaborator

gaearon commented Mar 27, 2016

@pnuzhdin Have you had a chance to verify whether #5028 fixes this issue for you?

@pnuzhdin
Copy link

@gaearon nope, it has become not so important for me

@gaearon
Copy link
Collaborator

gaearon commented Jan 27, 2017

I’m going to close since we don’t plan any more changes to TransitionGroup in React repo. Instead, it now is maintained by the community, and you can file an issue in the new repository if this is still affecting you. Thanks!

@gaearon gaearon closed this as completed Jan 27, 2017
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

No branches or pull requests

5 participants