I'm trying to convert a hover event for a degraded jquery flip piece of my script. I've done this for the css3d transform but I'm not sure how to convert the hover event for the degraded portion. Here is what I have so far:
if($("html").hasClass("csstransforms3d")){
$('.card').click(function () {
if ($(this).hasClass('flip')) {
$(this).removeClass('flip');
}
else {
$(this).addClass('flip');
}
});
/*
$('.card').hover(function(){
$(this).addClass('flip');
},function(){
$(this).removeClass('flip');
});
*/
}
else{
// How do I add a click event here instead of hover?
$('.card').hover(function(){
$(this).find(".front").animate({top: -190}, 'fast');
},function(){
$(this).find(".front").animate({top: 0}, 'fast');
});
}
How do I convert the hover event for a click event for the degraded section?