Jump to content
Search Community

className not Tweening?

danehansen test
Moderator Tag

Warning: Please note

This thread was started before GSAP 3 was released. Some information, especially the syntax, may be out of date for GSAP 3. Please see the GSAP 3 migration guide and release notes for more information about how to update the code to GSAP 3's syntax. 

Recommended Posts

When I attempt to tween using className, I am not seeing a tween of that classes properties as it is applied/removed, but rather an instantaneous application/removal of the class. I have had this problem on a few projects, and it is usually in a menu when I am trying to tween the activated menu item. I am using this version of greensock:http://code.jquery.com/jquery-latest.min.js

 

ex:

 

//to activate:

TweenLite.to(element, 1, {className:"active" ,ease:Linear.easeNone});

 

 

//to deactivate:

TweenLite.to(element, 1, {className:"" ,ease:Linear.easeNone});

 

Is there something I am doing wrong or not understanding?

Link to comment
Share on other sites

Hey Dane. The link you mentioned was for jQuery, not any GreenSock files, but I assume you meant to say you're using TweenLite or TweenMax 1.9.1 - is that correct?

 

It's tough to say what the problem is without seeing the problem in context - can you post a codepen or jsfiddle or HTML file or something that clearly demonstrates the issue? 

 

Also, please make sure you're using the latest version (1.9.3 as of today). We made some enhancements to the className overwriting routines. The CDN isn't updated quite yet, but the zip file and github both have the update. 

 

http://www.greensock.com/?download=GSAP-JS

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...