$(document).ready(function(){
$(".news").css("background-color","#e9edf3");//default
$(".news h3").css("color","#4a4b50");//default h3
$(".news_txt").css("color","#464549");//default news txt
});
Β
$(document.body).on("mouseenter", ".news", function(event) {
$(this).css("background-color","#18171c");//color change
$(this).children("h3").css("color","#ffc300");//color change h3
$(this).children(".news_txt").css("color","#fff");//color change news txt
$(this).children('.news_inf').show(100);
});
Β
$(document.body).on("mouseleave", ".news", function(event) {
$(this).css("background-color","#e9edf3");//default
$(this).children("h3").css("color","#4a4b50");//default h3
$(this).children(".news_txt").css("color","#464549");//default news txt
$(this).children('.news_inf').hide();
});
Comments
0 B
|π
/π