[Resolved] How to add animation to submenu

Home Forums Support [Resolved] How to add animation to submenu

Home Forums Support How to add animation to submenu

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #476511
    Manuel

    Hi Tom, hi Leo,

    how can i add animations to the submenu? So, it shouldn’t just slide down when you hover it should use this animation:

    animation: scale-up-hor-center 0.4s cubic-bezier(0.390, 0.575, 0.565, 1.000) both;
    
    @-webkit-keyframes scale-up-hor-center {
      0% {
        -webkit-transform: scaleX(0.4);
                transform: scaleX(0.4);
      }
      100% {
        -webkit-transform: scaleX(1);
                transform: scaleX(1);
      }
    }
    @keyframes scale-up-hor-center {
      0% {
        -webkit-transform: scaleX(0.4);
                transform: scaleX(0.4);
      }
      100% {
        -webkit-transform: scaleX(1);
                transform: scaleX(1);
      }
    }

    Best regards

    #476756
    Tom
    Lead Developer
    Lead Developer

    I supposed you could use this:

    .main-navigation ul ul {
        animation: scale-up-hor-center 0.4s cubic-bezier(0.390, 0.575, 0.565, 1.000) both;
    }

    Not sure if it will work, but that’s the correct element to target.

    #476790
    Manuel

    Thanksfor the fast answer.
    That’s what I’ve already tried before but it doesn’t work.
    Any other idea how I can get it working?

    #477650
    Tom
    Lead Developer
    Lead Developer

    Is there an example out there you can point me to?

    #478770
    Manuel

    Sorry, no example just an idea. Maybe I’ll find one soon.

    #479014
    Tom
    Lead Developer
    Lead Developer

    It would definitely help – I’m not overly familiar with keyframes, so it’s hard to know why it wouldn’t be working without seeing an example.

    #479435
    Manuel

    Hey Tom, I appreciate your help very much. No Theme or Plugin has a better support then GP. Thanks a lot.
    Here’s the solution

    .dropdown-hover .main-navigation ul li:hover > ul {
    	        animation: scale-up-hor-center 0.4s cubic-bezier(0.390, 0.575, 0.565, 1.000) none;
    }

    Here you can see an example on a testsite:
    Testsite

    #479914
    Tom
    Lead Developer
    Lead Developer

    Very cool! Thanks for posting the solution 🙂

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.