Grow your CSS skills. Land your dream job.

How do I integrate hoverIntent with this dropdown?

  • # July 26, 2010 at 4:07 pm

    I have a dropdown menu that I’d like to integrate hoverIntent on.

    I’d like it to display immediately when you hover over the menu, but have a slight delay when the mouse leaves it. Here is my current code:

    Code:
    jQuery(document).ready(function() {
    jQuery(‘.main-nav ul li’).hover(function() {
    jQuery(this).find(‘ul.children’).animate( {
    opacity:1
    }
    , {
    queue:false,duration:500
    }
    );
    }
    , function() {
    jQuery(this).find(‘ul.children’).animate( {
    opacity:0
    }
    , {
    queue:false,duration:500
    }
    );
    }
    );
    }
    );

    How do I integrate hoverIntent to work with this dropdown?

    Here is the link to the hoverIntent plugin:

    http://cherne.net/brian/resources/jquer … ntent.html

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".