Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1326528
    brendanduggan11
    Participant

    Have a problem with the nav bar sliding to the left when I scroll down on mobile. I cant find the problem. I attached some screen shots.

    when the page loads the nav bar is pushed all the way to the top of the screen like it should be. But when i scroll down it shifts to the left like the screen shots. Then the nav bar is no longer pushed to the top.

    Thanks for the help.

    http://www.sunshinesalsatours.com

    #1326538
    brendanduggan11
    Participant
    This reply has been marked as private.
    #1326776
    Paul R
    Moderator

    Hi,

    To fix it, you can add this under Custom > Edit Global CSS in the Customizer.

    
    @media (max-width: 979px) {
    .masthead-stacked .x-navbar.x-navbar-fixed-top {
        width:100%;
        position: fixed;
        clear:both;
        float:none;
    }
    
    body.x-navbar-fixed-top-active .x-navbar-wrap {
        height: 90px;
    }
    }
    

    Please make sure to clear your browser cache before checking again.

    Thanks

    #1327415
    brendanduggan11
    Participant

    The above did not fix the problem. I ended up finding the problem code to be

    .x-navbar {
    transition: all 0.5s ease 0s; } }

    How can I keep the transition on the navbar in the desktop while keeping it fixed in the mobile?

    #1327638
    Jade
    Moderator

    HI there,

    Please update your code to:

    @media (min-width: 980px) {
        .x-navbar {
            transition: all 0.5s ease 0s; 	
        }
    }

    Hope this helps.

  • <script> jQuery(function($){ $("#no-reply-1326528 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>