How to Hide Hamburger button in Boost before log in

Re: How to Hide Hamburger button in Boost before log in

by Ray Pierce -
Number of replies: 3

Mary,


This worked great to remove the Hamburger button. However, when I run this code the Log In/Log out link link and dropdown for changing roles is also removed. Is there a workaround to this?


Ray

In reply to Ray Pierce

Re: How to Hide Hamburger button in Boost before log in

by Jean-Roch Meurisse -
Picture of Core developers Picture of Plugin developers Picture of Testers

Hi Ray,

Do you want to remove the nav-drawer after login as well? In this case, try this (otherwise write .notloggedin before the rest 

[data-region="drawer-toggle"] button {
    display:none;
}

Be careful though. If the drawer has been used before, people having left it open on last logout will see the drawer on their next login and won't be able to hide it !
I you want to completely remove the nav-drawer from your moodle instance you'll have to reset to false "drawer-open-nav" user preference in your database for all user.

Cheers

In reply to Jean-Roch Meurisse

Re: How to Hide Hamburger button in Boost before log in

by Ray Pierce -
Hi Jean-Roch,



I want to keep the nav drawer open permanently and eliminate the Hamburger button. It is confusing to many. The code that Mary provided does the trick with one exception, it also eliminates the Log In/Log Out link at the top right and also the drop down menu that allows me to change roles.



Is there a way to:



1. Remove the hamburger button yet keep the Nav Drawer open

2. Do that without losing the Log In/Log Out Link and drop down menu
In reply to Ray Pierce

Re: How to Hide Hamburger button in Boost before log in

by Jean-Roch Meurisse -
Picture of Core developers Picture of Plugin developers Picture of Testers

Hi Ray,


To keep the nav-drawer open permanently:

  1. Use the css code from my previous post (that css rule will target the hamburger button only and so will keep log in log out links and dropdown menu
  2. Set "drawer-open-nav" user preference to "true" for all users in your database, so that people having hidden the nav-drawer before will have it displayed again (otherwise, such users will never be able to make it appear again)

Cheers