Treeview header link

Topic: Treeview header link

lede pro premium asked 2 years ago

Expected behavior On the plain treeview, you can make the header link. On the colourful treeview, because the link surrounds the entire element, you can't make the text within a link

Actual behavior Adding a link to the text within the span doesn't work because it is already within another element

Resources (screenshots, code snippets etc.)

Could we get a version of the animated/colourful treeviews which allow the header to be a link, like the plain version?

lede pro premium answered 2 years ago

Also, there doesn't seem to be an .active class for treeview-colorful-element

lede pro premium answered 2 years ago

I figured out the active. I think you should standardise these class names. It has active, open and opened on various elements. It should just be .active on all of them.

I also had to alter the js to make it possible to have some treeview elements open on page load.

Lines 3524 and 3537 I changed it to prevent the hiding of nested ul elements set to active from




Marta Szymanska staff pro premium answered 2 years ago


we will take into consideration your suggestions, thank you for that.

Best, Marta

lede pro premium commented 2 years ago

I updated to the new version and my treeview reverted to closing when it has the active class so I've had to make the change again. Please can you get it in the next version because it's very inconvenient and it's a really small change to fix it

Marta Szymanska staff pro premium commented 2 years ago

OK, I'll check this.

Please insert min. 20 characters.


Specification of the issue
  • User: Pro
  • Premium support: No
  • Technology: MDB jQuery
  • MDB Version: 4.9.0
  • Device: PC
  • Browser: Chrome
  • OS: Windows 10
  • Provided sample code: No
  • Provided link: Yes