Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...
Sign in to follow this  
Vahid-Designer

A problem in easing

Recommended Posts

Hello all. I have a container as below:

 

.section-fixed{
position:fixed;
width:0px;
height:0px;
top:-280px;
right:-280px;
overflow:hidden;
-webkit-border-radius:50%;
-moz-border-radius:50%;
border-radius:50%;
background:transparent;
opacity:0;
z-index:10;
}

which there is a few items within it:

.item-f{
text-decoration:none;
top:calc(50% - 15px);
left:calc(50% - 15px);
position:absolute;
border-radius:50%;
width:30px;
height:30px;
text-align:center;
color:black;
font-size:25px;
cursor:pointer;
}
<section class="section-fixed">
<div class="main-menu-f">
<div id="HomeButton" class="item-f">A</div>

I wrote a code with TweenLite as below:

if(//some condition){
TweenLite.to('.item-f:nth-child(1)', 0.6, {x:0.98 * -220.56290407832017,y:0.98 * 30.932307155207802,rotation:360,autoAlpha:1,ease:Back.easeOut.config(1.87)});
else{
TweenLite.to(".item-f:nth-child(1)", 0.6, {x:0,y:0,rotation:-360,autoAlpha:0,ease:Back.easeIn});
}

The problem is for when if condition is true, unfortunately ease function doesn't work correctly and the element moves in its way, simply. But when the else condition is true, Back.easeIn done correctly. What's going on? Can everybody help me at this?

 

 

Link to post
Share on other sites

Hi Diaco

Thank you very much. I've had a problem in my css3 codes. It's solved. The problem was non-related gsap. Thanks for your help.

Link to post
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
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×