Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript

Abhishek Kambli
Abhishek Kambli
2,657 Points

React Animation

Hi, I am working on a react chrome extension, aI am using React css transition group for animation, problem is my leave animation is not working,

Here is my code

<CSSTransitionGroup transitionName="calenderPopupAnimation" transitionEnter={true} transitionAppear={true} transitionLeave={true} transitionAppearTimeout={600} transitionEnterTimeout={600} transitionLeaveTimeout={1000}> ...

</CSSTransitionGroup>

@keyframes fadeIn { from { opacity: 0; -webkit-transform: scaleY(0); transform: scaleY(0); visibility: visible; }

to { opacity: 1; -webkit-transform: scaleY(1); transform: scaleY(1); } }

.calenderPopupAnimation-appear { animation: fadeIn 600ms ease; transform-origin: bottom left; }

.calenderPopupAnimation-appear-active { animation: fadeIn 450ms ease; }

.calenderPopupAnimation-enter { animation: fadeIn 600ms ease; transform-origin: bottom left; }

.calenderPopupAnimation-enter-active { animation: fadeIn 450ms ease; }

.calenderPopupAnimation-leave, .calenderPopupAnimation-leave-active{ transform: translate3d(0,0,0); opacity: 0; transition: all 1000ms ease-in; }

1 Answer

Sorry, but I don't know react well enough to help. I would google search sarah drasner, as she is one of the experts on animation out there. She probably has a few blog post about this.

Sorry that I can't give you more info.