Jump to content
Search Community

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

Posted

hi

i want these actions to occur when the mouse enters in class of  "block-detile"

  the width of "line-type" reduces , the "text-type" moves left and "text-info" appears

 

and when mouse goes to another side, return to its main states

See the Pen xrXqOG by milika (@milika) on CodePen.

Posted

hi carl tanx . but i have another problem: how this works if there are two different classes ?

 

1- block-detile

2- block-date

 

Posted

Hi milika,

 

I´m not sure what you mean. 2 classes = 2 'buttons'?

 

If so look at this example:

 

See the Pen qrgVve by mikeK (@mikeK) on CodePen.

 

 

If not please provide a modified codepen.

  • Like 2
Posted

tnx mikel

???

When two blocks are together. Each one does not work alone.





See the Pen xrXqOG by milika (@milika) on CodePen.

Posted

tnx mikel

How to get back to the original after leaving the mouse?

Now in the code above, one of the objects remains in the same state after leaving the mouse.

Posted

Hi milika,

 

add a mouseleave function to tween all objects to the start position:

 

See the Pen BZmJaR by mikeK (@mikeK) on CodePen.

 

 

  • Like 2
Posted

hi thanks mikel

for your correct answer.

i send another codepen in which the movement of each part is different how to these to work to together ?

 

See the Pen mwprMr by milika (@milika) on CodePen.

 

Posted

Hi milika,

 

You need in both buttons the same classes for the animation:

 

See the Pen EXoZbE by mikeK (@mikeK) on CodePen.


so use separate classes for style in addition.

  • Like 3
Posted

Hi milika,

 

Please be aware that you have different styles: mirror inverted.

 

So you need to adjust style and add a tween - for example the right line.

I tried it in the pen above ...

 

  • Like 1
Posted

hi mikel

 

ok. but still there is a problem with the type project. it should move to right and close to the right line but it moves to the left

Posted
21 minutes ago, mikel said:

Hi milika,

 

Please be aware that you have different styles: mirror inverted.

 

So you need to adjust style and add a tween - for example the right line.

I tried it in the pen above ...

 

i get it.

i changed that and now it works .

 

thank you .

i like greensock

Posted

Hi milika,

 

Ok, ok ...

 

I modified - see the above pen -  the animation of 'textProject' plus some css attributes.

 

  • Like 1

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