Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1201402
    jdfrizzell
    Participant

    I would like the background of my collapsed mobile menu button to be transparent. I want to keep the way I have the background/body once it is clicked on, however.

    http://01d.753.myftpupload.com/

    #1201567
    Rupok
    Member

    Hi there,

    It seems you have added the below code :

    body .x-navbar {
      background-color: black;
      margin-left: 75%;
      opacity: 0.6;
      position: fixed;
      transition: all 0.6s ease 0s;
      width: 25%;
    }

    Let’s remove this or the background-color and opacity properties from here to get expected result.

    #1202205
    jdfrizzell
    Participant

    I would like that to appear once the menu is opened, though. Is there a way to do that?

    #1202308
    Rupok
    Member

    Hi there,

    In that case you can update the above CSS to following :

    body .x-navbar {
      margin-left: 75%;
      position: fixed;
      transition: all 0.6s ease 0s;
      width: 25%;
    }
    
    .x-navbar.opaque-navbar {
      background-color: rgba(0,0,0, .75);
    }

    Then add this under Custom > JavaScript in the Customizer.

    jQuery( function($) {    
          $(window).on("scroll", function () {    
        if($('.x-nav-wrap.mobile').hasClass('in')) {
          $('.x-navbar').addClass('opaque-navbar');
                    }else {
                            $('.x-navbar').removeClass('opaque-navbar');
                    }   
      }).scroll();
    });

    Let us know if that works for you.

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