Parallax Pro – jQuery Responsive Menu

Community Forums Forums General Discussion Parallax Pro – jQuery Responsive Menu

This topic is: resolved

This topic contains 2 replies, has 2 voices, and was last updated by  Treefungus 8 months, 1 week ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #98725

    Treefungus
    Participant
    Post count: 51

    Hi

    In the responsive-menu.js file in Parallax Pro I find this code:

    $(window).resize(function(){
    if(window.innerWidth > 768) {
    $(“header .genesis-nav-menu”).removeAttr(“style”);
    }
    });

    What does this mean exactly? The .removeAttr(“style”) part means it will remove styling for header .genesis-nav-menu but that does not make sense to me in this example. Besides when resizing the window I am not seeing anything change whether I got this code in or not.

    Responsive icon is display none unless media query is max 768 so what is the above line of code doing?

    Any skilled jQuery users who could explain this to me?

    Thanks in advance!

    #99916

    Sridhar Katakam
    Participant
    Post count: 1071

    Try this:

    Comment out that piece of code.

    Resize the browser down to 768px or below. Now when you increase the width and decrease the width, you should see everything to be fine.

    Now expand the menu by clicking the hamburger icon. Increase the browser width and decrease. Everything should be fine again.

    Now collapse the menu and try increasing and decreasing width. This time the menu would not be visible (at least in my testing).

    If the code is present, this problem will not arise.


    #100144

    Treefungus
    Participant
    Post count: 51

    I just tried and yes that is correct. Can’t believe I missed that.

    Thank you for the help.

    Sridhar, you are a great help to the Genesis community.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.