Jump to content
Search Community

text highlight effect on scroll

michael_feh test
Moderator Tag

Go to solution Solved by PointC,

Recommended Posts

hey there,

 

i just started messing around with gsap and scroll trigger and im already loving it.

i need some effects for a website and almost got everything running with gsap and ScrollTrigger except for this one effect.

 

you can see it in action here:
https://www.nembodesign.com/

its this font color changing effect on scroll of the first paragraph "We know that developing a new project is a complex..."
I think you would have to split the text into characters with SplitText and animate the color with gsap.to + ScrollTrigger + scrub.

But i cant find a way to animate all characters individually based on the scroll position of the paragraph.

Does anybody know how do do this?

Kind regards,
Thanks in advance,

Michael

 

Link to comment
Share on other sites

  • Solution

Hi @michael_feh

 

Welcome to the forum.

 

We've had a few threads about that effect and you're correct - it's pretty easy with SplitText. Here are a couple demos I posted as answers for one of the older threads. They should point you in the right direction.

 

See the Pen MWQJWqJ by PointC (@PointC) on CodePen

 

See the Pen NWybQow by PointC (@PointC) on CodePen

 

Happy tweening and welcome aboard.

:)  

  • Like 2
  • Thanks 1
Link to comment
Share on other sites

@Rodrigo even better. becuase the letters actually change colour as in the example.
is it even possible to change the color twice to generate a fade/blend effect? 
would i need to have various ".set"s or what would be the right approach?

also, if i get the pricing right: to use split text on a production site is 149$/y, right?

Link to comment
Share on other sites

Hi,

 

Sure thing GSAP Timelines are super flexible:

See the Pen WNmOQoj by GreenSock (@GreenSock) on CodePen

 

Thanks for considering joining the GSAP Club! That amount ($149 per year) gives you access to every update for the bonus tools for that amount of time. Also you can use every bonus tool on all the sites/apps you want, there is no limit on that. Our tools don't have a phone home code in them, we base our entire business model on the honor system, so once you deployed something with the bonus stuff on a site it will stay there as long as you/your client wants. But if at some point a bug shows up and your Club membership is not renewed, you just won't get access to the necessary update. If no bug shows everything will just keep working. Same thing if we add new features to a bonus plugin or create a new tool, if your membership is not active you won't have access to them, but you'll be able to keep the files you downloaded from your account's dashboard.

 

Hopefully this helps and let us know if you have more questions.

Happy Tweening!

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