• Resolved Vesa90

    (@vesa90)


    Hi all,

    i am starting to create new page in Neve theme and i want some help with menu… If i am on homepage all menu items are highlighted (red) as active, but it should be active if i am inside wrapper section.

    Second question if i will click to menu item it jumps to this section, but there should be some “transition scroll down effect”. Can you help me?

    Thank you!

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi @vesa90,

    Here is our documentation for the header: https://docs.themeisle.com/article/1226-header-primary-menu

    If you are using anchor links and your menu items are actually the sections of the front-page so all of them are active because all of them are on the same page – your homepage. WordPress checks that there is no slash after the domain it means no other page link and marks the item as active – current page.

    You can add this CSS to Appearance->Customize->Additional CSS section for smooth scrolling:

    html {
      scroll-behavior: smooth;
    }

    I hope it helps!

    Thread Starter Vesa90

    (@vesa90)

    Hi @bvytis,

    thank you very much, smooth scroll is working!

    I have question to menu items marked as active. Because i used Zerif lite template with WP 4.7 and there was active only item where you are on the front-page, it is there: https://vam-servis.vesely-pes.cz/. So is this problem of WordPress or Neve theme?

    Thank you!

    Hi @vesa90,

    It’s not a problem of WordPress or Neve it’s just how WordPress works because out of the box it’s designed that menu items are dedicated for separate pages, that’s the reason no additional classes are added on click and the menu is not made item if content lives on the same page.

    Some themes, like the mentioned by you, that have desired content on the front-page or are one-page themes have additional functionality that adds classes using JavaScript.

    You can achieve the same with Neve using custom JavaScript (jQuery).

    You can use this script:

    <script>
    jQuery(".menu-item-home").click(function () {
        jQuery(".menu-item-home").removeClass("current");
        jQuery(this).addClass("current");   
    });
    </script>

    Guide about the module of the OrbitFox plugin: https://docs.themeisle.com/article/1277-header-footer-scripts-orbit-fox-module

    Also, add that class to Appearance->Customize->Additional CSS section:

    li.menu-item-home a {
     color: red!important;
    }

    I hope this helps!

    Thread Starter Vesa90

    (@vesa90)

    Thank you very much for help, it is solved now.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Menu transition scroll not working’ is closed to new replies.