I have a list with several images, and when with hover
, there are 4 animations, one overlay , another bg of overlay , the image caption appears and another "read more" text also appears.
All the animations I've done with jQuery, except for the other text that has this "read more" I made with GreenSock. What happens is that hover
in any of the images activates the GreenSock animation in all others, this does not happen with the animations in jQuery because I used this
.
How would I make the animation only happen in the image I give hover
?
Follow the code, .plus
is the animated "read more" widget that is not working.
function animatePublications() {
$( ".menu-publications li" ).hover(function() {
// var self = $(this);
$( ".overlay", this).stop().animate({'opacity' : 1}, 400);
$( ".overlay-plus", this).stop().animate({'bottom': '0', 'opacity' : 1}, 400);
$( ".caption", this).css( "color", "#ffffff" ).stop().animate({'top': '-175px'}, 400);
TweenLite.to(plus, 1, {bottom:"24px", ease:Bounce.easeOut});
}, function() {
$( ".overlay", this).stop().animate({'opacity' : 0}, 400);
$( ".overlay-plus", this).stop().animate({'bottom': '-148px', 'opacity' : 0}, 400);
$( ".caption", this).css( "color", "#737373" ).stop().animate({'top': '0'}, 400);
// $( ".plus").stop().animate({'bottom': '-105px'}, 400);
TweenLite.to(plus, 0.5, {bottom:"-105px"});
})
}