Jump to content
Search Community

Div animations with a mask?

SLSCoder test
Moderator Tag

Recommended Posts

This may not be specifically GSAP but nobody knows this stuff like you guys.
I have a container div on a page that could be anywhere on the page and any size but usually about 400px wide X 500px high.

I have another div the same size that will move (animation) into the container.  That much is easy.

 

I need the page to be fully visible except for the animation div when it is outside the container div.

As the animation div moves into the container div I need the part of the animation div that is inside the container div to be visible but the part of the animation div that is outside the container div to be invisible.

I'm looking at css clip and mask but so far I can't figure it out.
Is it even possible?

I'd really appreciate your help.

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