Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...
Marc Taule

Mask in chars and lines with Split Text

Recommended Posts

Hi!

I'm having problems with Split Text. I'll try to explain...

I split lines and chars and I make a mask to show char by char in each lines, but in some letters like g, y, ... they have some part hidden.

I can revert the splits after complete but you can see for a second that these letters have some parts hidden.

Someone knows how to fix that? 

Thanks!

See the Pen eYWLawR by marctaule (@marctaule) on CodePen

Link to comment
Share on other sites

Hey Marc. This is simply because of how your CSS is set up. Each line has the overflow hidden, but some characters go more than the current line height. You can see that it's the issue if you remove your CSS for the line height.

 

There's not a simple fix for that sort of situation. One solution is to use the default line height and translate the lines minorly instead. Then when SplitText is done and you revert the HTML you could add back in your line height.

  • 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.
×