Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

if Submenu is active #70

Open
xshakox opened this issue Mar 4, 2015 · 0 comments
Open

if Submenu is active #70

xshakox opened this issue Mar 4, 2015 · 0 comments

Comments

@xshakox
Copy link

xshakox commented Mar 4, 2015

Hi, I love this project, but as I am very new to jquery, I cant make some specific action work.

I want to achieve double animation effect in menu. When I hover the mouse first time, I want the popover div to fade in, but if I hover mouse on another menu, I don't want fadein animation anymore.

Here is my code:

            function activateSubmenu(row) {
            var $row = $(row),
            submenuId = $row.data("submenuId"),
            $submenu = $("#" + submenuId),
            height = $menu.outerHeight(),
            width = $menu.outerWidth();

      if (// popover div is activated) 
          {
           $submenu.css({
    display: "block",
            top: -1,
            left: width - 0,  // main should overlay submenu
            height: height - 4, // padding for main dropdown's arrow
            }); } 

            else // if popover is not activated.
            {
    $submenu.css({
            top: -1,
            left: width - 0,  // main should overlay submenu
            height: height - 4, // padding for main dropdown's arrow
            })  .fadeIn(150);           
        }

            $row.find("a").addClass("maintainHover");
            }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant