Sidebar menu treeview not open when .active
See original GitHub issueHello,
First, thank you for your work, it’s great. But (yes, there is a “but”), I’ve got a problem with the left sidebar (treeview).
With this markup, the ul.treeview-menu is not displayed and I think it should be.
<ul class="sidebar-menu">
<li class="treeview active">
<a href="#">
<i class="fa fa-users"></i>
<span>Users</span>
<i class="fa fa-angle-left pull-right"></i>
</a>
<ul class="treeview-menu">
<li class="active">
<a href="##">
Permissions
</a>
</li>
<li>
<a href="##">
Other submenu
</a>
</li>
</ul>
</li>
</ul>
Result
Expected
To “solve” this, I added this CSS rule in my stylesheet, but I don’t know if it’s really good :
.sidebar .sidebar-menu .active .treeview-menu {
display: block;
}
Issue Analytics
- State:
- Created 9 years ago
- Comments:18 (1 by maintainers)
Top Results From Across the Web
Sidebar menu treeview not opening when active through ...
I am having some problem while activating the side menu tree in my page. My JQuery code is: $(document).ready(function () { alert("hi"); ...
Read more >AdminLTE 3 expend menu doesn't close/collapsed when ...
Right now all menu items are opening one by one and they can only be closed by clicking on the item again. any...
Read more >Main Sidebar Component | AdminLTE 3 Documentation
Additional Classes. Sidebar .sidebar-no-expand Disables Auto Expand on Hover/Focus. Navbar .nav ...
Read more >Ability to set active class/property to a selected menu ... - Drupal
I have my sidebar menu setup with menu and submenu items. What I want that whenever someone clicks on a menu item, it...
Read more >adminlte sidebar menu active not working
This issue has been solved in AdminLTE 2.0. The app.js version you are using @Adysone contains the issue since it is responsible of...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
In react after login, I had problem with resize and treeview. I solved the problem using jquery on componentDidMount() method.
export default class App extends React.Component { componentDidMount () { jquery(‘body’).layout(‘fix’); jquery(‘body’).layout(‘fixSidebar’); jquery(document).ready(() => { const trees = jquery(‘[data-widget=“tree”]’); trees.tree(); }); } render() { return ( … ); } }
I have found it works when I enter full URL instead of relative URL. Example: Instead of using
<a href="/food">Food</a>
I used<a href="http://zubaer.com/food">Food</a>
And it works fine.