Skip to content

Instantly share code, notes, and snippets.

@iamryanyu
Created April 24, 2016 10:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save iamryanyu/7f5cec334ddbb77f0e294dc8edf166fc to your computer and use it in GitHub Desktop.
Save iamryanyu/7f5cec334ddbb77f0e294dc8edf166fc to your computer and use it in GitHub Desktop.
var $graphStarRed = $('.graph__star--red'),
$graphStarGreen = $('.graph__star--green'),
$graphStarYellow = $('.graph__star--yellow');
// hover over
TweenMax.to($graphStarRed, 1.2, {
y: -25,
ease: Elastic.easeOut.config(1, 0.2)
});
TweenMax.to($graphStarGreen, 1.2, {
y: 45,
ease: Elastic.easeOut.config(1, 0.2)
});
TweenMax.to($graphStarYellow, 1.2, {
y: -17,
ease: Elastic.easeOut.config(1, 0.2)
});
// hover out
TweenMax.to($graphStarRed, 1.2, {
y: 0,
ease: Elastic.easeOut.config(1, 0.2)
});
TweenMax.to($graphStarGreen, 1.2, {
y: 0,
ease: Elastic.easeOut.config(1, 0.2)
});
TweenMax.to($graphStarYellow, 1.2, {
y: 0,
ease: Elastic.easeOut.config(1, 0.2)
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment