Is there a way to collapse the navigation block as the default for all users

Is there a way to collapse the navigation block as the default for all users

by Mark Whitington -
Number of replies: 2

Hi all,

We are attempting to find a way to have the "navigation" block available within courses but to reduce/collapse its size. 

As we have a large number of courses users are finding the expanded "My courses" and "Courses" lists distracting.

I know we can set the number of courses to display here > Site Admin > Appearance > Navigation

  • By changing the number of courses to display affects both the course page and the user's "dashboard"... we would like to have the user's "dashboard" display in full.

I know individual users can collapse or dock the navigation block but hope we can do it by default site-wide. It would be nice if users could expand the navigation block if required.

  • Moodle ver: 3.2.4
  • Theme: Essential: 3.2.1.2 (Build: 2017021003)

Hope someone can assist.

Regards

Mark

navigation block image

 

Average of ratings: -
In reply to Mark Whitington

Re: Is there a way to collapse the navigation block as the default for all users

by Mary Evans -
Picture of Core developers Picture of Documentation writers Picture of Peer reviewers Picture of Plugin developers Picture of Testers

Hi,

You can certainily change the size of the block height which will generate a scroller so users can scroll up & down relatively easily. Once opened the Navigation block should stay open, same goes for if the block was docked, it stays docked. So get the users to enable that block and then forget about it.

Here is the CSS which you can add in the Essentilal -> General settings -> Custom CSS

.block_navigation.block {
    max-height: 250px;
    overflow-y: auto;
}

Hope this helps?

Mary

Average of ratings: Useful (1)
In reply to Mary Evans

Re: Is there a way to collapse the navigation block as the default for all users

by Mark Whitington -

Hi Mary,

Thank you soooo much for this code.

It has helped greatly!!!

Cheers

Mark