Jump to content
Search Community

text animation question

bluekai test
Moderator Tag

Go to solution Solved by Carl,

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

  • Solution

Yes, here is a basic implementation using the same sort of setup as the original:



var rule = CSSRulePlugin.getRule(".reveal-text:after");

var tl = new TimelineMax({repeat:4, yoyo:true, repeatDelay:0.5})
tl.to(rule, 1, {cssRule:{scaleX:1}})
  .set(".reveal-text", {clipPath: "inset(0 0 0 0)"})
  .to(rule, 1, {cssRule:{scaleX:0, transformOrigin:"right"}});




It seems the original pen you posted didn't work so well in Safari and FireFox due to the clip-path: inset stuff. 

I would probably try to hide the text another way. 


Regarding animation of pseudo elements: https://greensock.com/forums/topic/6133-is-it-possible-to-tween-css-pseudo-elements-like-after/

  • Like 4
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...