Skip to content

Instantly share code, notes, and snippets.

@ilumin
Created March 21, 2013 13:30
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 ilumin/5213010 to your computer and use it in GitHub Desktop.
Save ilumin/5213010 to your computer and use it in GitHub Desktop.
hover intent example
var showMenu = function(){
$(this)
.find(' > a')
.stop().animate({
backgroundColor: menuBGHilight,
color: menuColorHilight
}, 'fast');
$(this).find('.sub-navigator').length>0 &&
$(this).find('.sub-navigator').stop(true,true).slideDown(1000, 'easeInOutBack');
};
var hideMenu = function(){
$(this)
.find(' > a')
.stop().animate({
backgroundColor: menuBGNormal,
color: menuColorNormal
}, 'fast');
$(this).find('.sub-navigator').length>0 &&
$(this).find('.sub-navigator').stop(true,true).fadeOut('fast');
};
$('.page-navigator .nav-item').hoverIntent({
over: showMenu,
out: hideMenu,
timeout: 400
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment